brd-ui-kit 0.1.30 → 0.1.32
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/brd-ui-kit.css +1 -1
- package/dist/components/select-groups/index.d.ts +2 -0
- package/dist/components/select-groups/select-groups.d.ts +22 -0
- package/dist/components/select-groups/select-groups.stories.d.ts +38 -0
- package/dist/components/ui/icon/icon-dictionary.d.ts +1 -0
- package/dist/components/ui/icon/icon.stories.d.ts +1 -1
- package/dist/components/ui/select/index.d.ts +1 -0
- package/dist/components/ui/select/select.d.ts +25 -0
- package/dist/components/ui/select/select.stories.d.ts +38 -0
- package/dist/components/ui/select/select.styles.d.ts +10 -0
- package/dist/index.cjs +119 -90
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.js +14066 -13047
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const P=require("react/jsx-runtime"),j=require("react"),Up=require("react-dom");function mR(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 x=mR(j),la=mR(Up);function vR(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=vR(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function Pt(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=vR(e))&&(r&&(r+=" "),r+=t);return r}const CW=(e,t)=>{const n=new Array(e.length+t.length);for(let r=0;r<e.length;r++)n[r]=e[r];for(let r=0;r<t.length;r++)n[e.length+r]=t[r];return n},SW=(e,t)=>({classGroupId:e,validator:t}),yR=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),Td="-",sS=[],EW="arbitrary..",_W=e=>{const t=PW(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:a=>{if(a.startsWith("[")&&a.endsWith("]"))return OW(a);const s=a.split(Td),u=s[0]===""&&s.length>1?1:0;return bR(s,u,t)},getConflictingClassGroupIds:(a,s)=>{if(s){const u=r[a],c=n[a];return u?c?CW(c,u):u:c||sS}return n[a]||sS}}},bR=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;const i=e[t],o=n.nextPart.get(i);if(o){const c=bR(e,t+1,o);if(c)return c}const a=n.validators;if(a===null)return;const s=t===0?e.join(Td):e.slice(t).join(Td),u=a.length;for(let c=0;c<u;c++){const d=a[c];if(d.validator(s))return d.classGroupId}},OW=e=>e.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const t=e.slice(1,-1),n=t.indexOf(":"),r=t.slice(0,n);return r?EW+r:void 0})(),PW=e=>{const{theme:t,classGroups:n}=e;return AW(n,t)},AW=(e,t)=>{const n=yR();for(const r in e){const i=e[r];qb(i,n,r,t)}return n},qb=(e,t,n,r)=>{const i=e.length;for(let o=0;o<i;o++){const a=e[o];RW(a,t,n,r)}},RW=(e,t,n,r)=>{if(typeof e=="string"){IW(e,t,n);return}if(typeof e=="function"){TW(e,t,n,r);return}kW(e,t,n,r)},IW=(e,t,n)=>{const r=e===""?t:xR(t,e);r.classGroupId=n},TW=(e,t,n,r)=>{if(NW(e)){qb(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(SW(n,e))},kW=(e,t,n,r)=>{const i=Object.entries(e),o=i.length;for(let a=0;a<o;a++){const[s,u]=i[a];qb(u,xR(t,s),n,r)}},xR=(e,t)=>{let n=e;const r=t.split(Td),i=r.length;for(let o=0;o<i;o++){const a=r[o];let s=n.nextPart.get(a);s||(s=yR(),n.nextPart.set(a,s)),n=s}return n},NW=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,MW=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=Object.create(null),r=Object.create(null);const i=(o,a)=>{n[o]=a,t++,t>e&&(t=0,r=n,n=Object.create(null))};return{get(o){let a=n[o];if(a!==void 0)return a;if((a=r[o])!==void 0)return i(o,a),a},set(o,a){o in n?n[o]=a:i(o,a)}}},vy="!",lS=":",DW=[],uS=(e,t,n,r,i)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:i}),jW=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=i=>{const o=[];let a=0,s=0,u=0,c;const d=i.length;for(let b=0;b<d;b++){const y=i[b];if(a===0&&s===0){if(y===lS){o.push(i.slice(u,b)),u=b+1;continue}if(y==="/"){c=b;continue}}y==="["?a++:y==="]"?a--:y==="("?s++:y===")"&&s--}const p=o.length===0?i:i.slice(u);let g=p,h=!1;p.endsWith(vy)?(g=p.slice(0,-1),h=!0):p.startsWith(vy)&&(g=p.slice(1),h=!0);const v=c&&c>u?c-u:void 0;return uS(o,h,g,v)};if(t){const i=t+lS,o=r;r=a=>a.startsWith(i)?o(a.slice(i.length)):uS(DW,!1,a,void 0,!0)}if(n){const i=r;r=o=>n({className:o,parseClassName:i})}return r},LW=e=>{const t=new Map;return e.orderSensitiveModifiers.forEach((n,r)=>{t.set(n,1e6+r)}),n=>{const r=[];let i=[];for(let o=0;o<n.length;o++){const a=n[o],s=a[0]==="[",u=t.has(a);s||u?(i.length>0&&(i.sort(),r.push(...i),i=[]),r.push(a)):i.push(a)}return i.length>0&&(i.sort(),r.push(...i)),r}},$W=e=>({cache:MW(e.cacheSize),parseClassName:jW(e),sortModifiers:LW(e),..._W(e)}),FW=/\s+/,VW=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:o}=t,a=[],s=e.trim().split(FW);let u="";for(let c=s.length-1;c>=0;c-=1){const d=s[c],{isExternal:p,modifiers:g,hasImportantModifier:h,baseClassName:v,maybePostfixModifierPosition:b}=n(d);if(p){u=d+(u.length>0?" "+u:u);continue}let y=!!b,w=r(y?v.substring(0,b):v);if(!w){if(!y){u=d+(u.length>0?" "+u:u);continue}if(w=r(v),!w){u=d+(u.length>0?" "+u:u);continue}y=!1}const C=g.length===0?"":g.length===1?g[0]:o(g).join(":"),E=h?C+vy:C,_=E+w;if(a.indexOf(_)>-1)continue;a.push(_);const O=i(w,y);for(let R=0;R<O.length;++R){const I=O[R];a.push(E+I)}u=d+(u.length>0?" "+u:u)}return u},BW=(...e)=>{let t=0,n,r,i="";for(;t<e.length;)(n=e[t++])&&(r=wR(n))&&(i&&(i+=" "),i+=r);return i},wR=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=wR(e[r]))&&(n&&(n+=" "),n+=t);return n},cS=(e,...t)=>{let n,r,i,o;const a=u=>{const c=t.reduce((d,p)=>p(d),e());return n=$W(c),r=n.cache.get,i=n.cache.set,o=s,s(u)},s=u=>{const c=r(u);if(c)return c;const d=VW(u,n);return i(u,d),d};return o=a,(...u)=>o(BW(...u))},zW=[],ln=e=>{const t=n=>n[e]||zW;return t.isThemeGetter=!0,t},CR=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,SR=/^\((?:(\w[\w-]*):)?(.+)\)$/i,WW=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,HW=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,UW=/\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$/,GW=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,qW=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,KW=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Vo=e=>WW.test(e),nt=e=>!!e&&!Number.isNaN(Number(e)),Bo=e=>!!e&&Number.isInteger(Number(e)),gm=e=>e.endsWith("%")&&nt(e.slice(0,-1)),Zi=e=>HW.test(e),ER=()=>!0,YW=e=>UW.test(e)&&!GW.test(e),Kb=()=>!1,XW=e=>qW.test(e),ZW=e=>KW.test(e),QW=e=>!Oe(e)&&!Pe(e),JW=e=>ua(e,PR,Kb),Oe=e=>CR.test(e),Ta=e=>ua(e,AR,YW),fS=e=>ua(e,sH,nt),eH=e=>ua(e,IR,ER),tH=e=>ua(e,RR,Kb),dS=e=>ua(e,_R,Kb),nH=e=>ua(e,OR,ZW),Tf=e=>ua(e,TR,XW),Pe=e=>SR.test(e),au=e=>ls(e,AR),rH=e=>ls(e,RR),pS=e=>ls(e,_R),iH=e=>ls(e,PR),oH=e=>ls(e,OR),kf=e=>ls(e,TR,!0),aH=e=>ls(e,IR,!0),ua=(e,t,n)=>{const r=CR.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},ls=(e,t,n=!1)=>{const r=SR.exec(e);return r?r[1]?t(r[1]):n:!1},_R=e=>e==="position"||e==="percentage",OR=e=>e==="image"||e==="url",PR=e=>e==="length"||e==="size"||e==="bg-size",AR=e=>e==="length",sH=e=>e==="number",RR=e=>e==="family-name",IR=e=>e==="number"||e==="weight",TR=e=>e==="shadow",hS=()=>{const e=ln("color"),t=ln("font"),n=ln("text"),r=ln("font-weight"),i=ln("tracking"),o=ln("leading"),a=ln("breakpoint"),s=ln("container"),u=ln("spacing"),c=ln("radius"),d=ln("shadow"),p=ln("inset-shadow"),g=ln("text-shadow"),h=ln("drop-shadow"),v=ln("blur"),b=ln("perspective"),y=ln("aspect"),w=ln("ease"),C=ln("animate"),E=()=>["auto","avoid","all","avoid-page","page","left","right","column"],_=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],O=()=>[..._(),Pe,Oe],R=()=>["auto","hidden","clip","visible","scroll"],I=()=>["auto","contain","none"],k=()=>[Pe,Oe,u],B=()=>[Vo,"full","auto",...k()],L=()=>[Bo,"none","subgrid",Pe,Oe],V=()=>["auto",{span:["full",Bo,Pe,Oe]},Bo,Pe,Oe],D=()=>[Bo,"auto",Pe,Oe],H=()=>["auto","min","max","fr",Pe,Oe],J=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],te=()=>["start","end","center","stretch","center-safe","end-safe"],G=()=>["auto",...k()],ee=()=>[Vo,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...k()],Q=()=>[Vo,"screen","full","dvw","lvw","svw","min","max","fit",...k()],pe=()=>[Vo,"screen","full","lh","dvh","lvh","svh","min","max","fit",...k()],K=()=>[e,Pe,Oe],Ae=()=>[..._(),pS,dS,{position:[Pe,Oe]}],Se=()=>["no-repeat",{repeat:["","x","y","space","round"]}],$e=()=>["auto","cover","contain",iH,JW,{size:[Pe,Oe]}],we=()=>[gm,au,Ta],Ce=()=>["","none","full",c,Pe,Oe],ze=()=>["",nt,au,Ta],Ke=()=>["solid","dashed","dotted","double"],Fe=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],Y=()=>[nt,gm,pS,dS],oe=()=>["","none",v,Pe,Oe],ne=()=>["none",nt,Pe,Oe],$=()=>["none",nt,Pe,Oe],ie=()=>[nt,Pe,Oe],Z=()=>[Vo,"full",...k()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[Zi],breakpoint:[Zi],color:[ER],container:[Zi],"drop-shadow":[Zi],ease:["in","out","in-out"],font:[QW],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[Zi],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[Zi],shadow:[Zi],spacing:["px",nt],text:[Zi],"text-shadow":[Zi],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Vo,Oe,Pe,y]}],container:["container"],columns:[{columns:[nt,Oe,Pe,s]}],"break-after":[{"break-after":E()}],"break-before":[{"break-before":E()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:O()}],overflow:[{overflow:R()}],"overflow-x":[{"overflow-x":R()}],"overflow-y":[{"overflow-y":R()}],overscroll:[{overscroll:I()}],"overscroll-x":[{"overscroll-x":I()}],"overscroll-y":[{"overscroll-y":I()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:B()}],"inset-x":[{"inset-x":B()}],"inset-y":[{"inset-y":B()}],start:[{"inset-s":B(),start:B()}],end:[{"inset-e":B(),end:B()}],"inset-bs":[{"inset-bs":B()}],"inset-be":[{"inset-be":B()}],top:[{top:B()}],right:[{right:B()}],bottom:[{bottom:B()}],left:[{left:B()}],visibility:["visible","invisible","collapse"],z:[{z:[Bo,"auto",Pe,Oe]}],basis:[{basis:[Vo,"full","auto",s,...k()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[nt,Vo,"auto","initial","none",Oe]}],grow:[{grow:["",nt,Pe,Oe]}],shrink:[{shrink:["",nt,Pe,Oe]}],order:[{order:[Bo,"first","last","none",Pe,Oe]}],"grid-cols":[{"grid-cols":L()}],"col-start-end":[{col:V()}],"col-start":[{"col-start":D()}],"col-end":[{"col-end":D()}],"grid-rows":[{"grid-rows":L()}],"row-start-end":[{row:V()}],"row-start":[{"row-start":D()}],"row-end":[{"row-end":D()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":H()}],"auto-rows":[{"auto-rows":H()}],gap:[{gap:k()}],"gap-x":[{"gap-x":k()}],"gap-y":[{"gap-y":k()}],"justify-content":[{justify:[...J(),"normal"]}],"justify-items":[{"justify-items":[...te(),"normal"]}],"justify-self":[{"justify-self":["auto",...te()]}],"align-content":[{content:["normal",...J()]}],"align-items":[{items:[...te(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...te(),{baseline:["","last"]}]}],"place-content":[{"place-content":J()}],"place-items":[{"place-items":[...te(),"baseline"]}],"place-self":[{"place-self":["auto",...te()]}],p:[{p:k()}],px:[{px:k()}],py:[{py:k()}],ps:[{ps:k()}],pe:[{pe:k()}],pbs:[{pbs:k()}],pbe:[{pbe:k()}],pt:[{pt:k()}],pr:[{pr:k()}],pb:[{pb:k()}],pl:[{pl:k()}],m:[{m:G()}],mx:[{mx:G()}],my:[{my:G()}],ms:[{ms:G()}],me:[{me:G()}],mbs:[{mbs:G()}],mbe:[{mbe:G()}],mt:[{mt:G()}],mr:[{mr:G()}],mb:[{mb:G()}],ml:[{ml:G()}],"space-x":[{"space-x":k()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":k()}],"space-y-reverse":["space-y-reverse"],size:[{size:ee()}],"inline-size":[{inline:["auto",...Q()]}],"min-inline-size":[{"min-inline":["auto",...Q()]}],"max-inline-size":[{"max-inline":["none",...Q()]}],"block-size":[{block:["auto",...pe()]}],"min-block-size":[{"min-block":["auto",...pe()]}],"max-block-size":[{"max-block":["none",...pe()]}],w:[{w:[s,"screen",...ee()]}],"min-w":[{"min-w":[s,"screen","none",...ee()]}],"max-w":[{"max-w":[s,"screen","none","prose",{screen:[a]},...ee()]}],h:[{h:["screen","lh",...ee()]}],"min-h":[{"min-h":["screen","lh","none",...ee()]}],"max-h":[{"max-h":["screen","lh",...ee()]}],"font-size":[{text:["base",n,au,Ta]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,aH,eH]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",gm,Oe]}],"font-family":[{font:[rH,tH,t]}],"font-features":[{"font-features":[Oe]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[i,Pe,Oe]}],"line-clamp":[{"line-clamp":[nt,"none",Pe,fS]}],leading:[{leading:[o,...k()]}],"list-image":[{"list-image":["none",Pe,Oe]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",Pe,Oe]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:K()}],"text-color":[{text:K()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...Ke(),"wavy"]}],"text-decoration-thickness":[{decoration:[nt,"from-font","auto",Pe,Ta]}],"text-decoration-color":[{decoration:K()}],"underline-offset":[{"underline-offset":[nt,"auto",Pe,Oe]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:k()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Pe,Oe]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Pe,Oe]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:Ae()}],"bg-repeat":[{bg:Se()}],"bg-size":[{bg:$e()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Bo,Pe,Oe],radial:["",Pe,Oe],conic:[Bo,Pe,Oe]},oH,nH]}],"bg-color":[{bg:K()}],"gradient-from-pos":[{from:we()}],"gradient-via-pos":[{via:we()}],"gradient-to-pos":[{to:we()}],"gradient-from":[{from:K()}],"gradient-via":[{via:K()}],"gradient-to":[{to:K()}],rounded:[{rounded:Ce()}],"rounded-s":[{"rounded-s":Ce()}],"rounded-e":[{"rounded-e":Ce()}],"rounded-t":[{"rounded-t":Ce()}],"rounded-r":[{"rounded-r":Ce()}],"rounded-b":[{"rounded-b":Ce()}],"rounded-l":[{"rounded-l":Ce()}],"rounded-ss":[{"rounded-ss":Ce()}],"rounded-se":[{"rounded-se":Ce()}],"rounded-ee":[{"rounded-ee":Ce()}],"rounded-es":[{"rounded-es":Ce()}],"rounded-tl":[{"rounded-tl":Ce()}],"rounded-tr":[{"rounded-tr":Ce()}],"rounded-br":[{"rounded-br":Ce()}],"rounded-bl":[{"rounded-bl":Ce()}],"border-w":[{border:ze()}],"border-w-x":[{"border-x":ze()}],"border-w-y":[{"border-y":ze()}],"border-w-s":[{"border-s":ze()}],"border-w-e":[{"border-e":ze()}],"border-w-bs":[{"border-bs":ze()}],"border-w-be":[{"border-be":ze()}],"border-w-t":[{"border-t":ze()}],"border-w-r":[{"border-r":ze()}],"border-w-b":[{"border-b":ze()}],"border-w-l":[{"border-l":ze()}],"divide-x":[{"divide-x":ze()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":ze()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...Ke(),"hidden","none"]}],"divide-style":[{divide:[...Ke(),"hidden","none"]}],"border-color":[{border:K()}],"border-color-x":[{"border-x":K()}],"border-color-y":[{"border-y":K()}],"border-color-s":[{"border-s":K()}],"border-color-e":[{"border-e":K()}],"border-color-bs":[{"border-bs":K()}],"border-color-be":[{"border-be":K()}],"border-color-t":[{"border-t":K()}],"border-color-r":[{"border-r":K()}],"border-color-b":[{"border-b":K()}],"border-color-l":[{"border-l":K()}],"divide-color":[{divide:K()}],"outline-style":[{outline:[...Ke(),"none","hidden"]}],"outline-offset":[{"outline-offset":[nt,Pe,Oe]}],"outline-w":[{outline:["",nt,au,Ta]}],"outline-color":[{outline:K()}],shadow:[{shadow:["","none",d,kf,Tf]}],"shadow-color":[{shadow:K()}],"inset-shadow":[{"inset-shadow":["none",p,kf,Tf]}],"inset-shadow-color":[{"inset-shadow":K()}],"ring-w":[{ring:ze()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:K()}],"ring-offset-w":[{"ring-offset":[nt,Ta]}],"ring-offset-color":[{"ring-offset":K()}],"inset-ring-w":[{"inset-ring":ze()}],"inset-ring-color":[{"inset-ring":K()}],"text-shadow":[{"text-shadow":["none",g,kf,Tf]}],"text-shadow-color":[{"text-shadow":K()}],opacity:[{opacity:[nt,Pe,Oe]}],"mix-blend":[{"mix-blend":[...Fe(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":Fe()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[nt]}],"mask-image-linear-from-pos":[{"mask-linear-from":Y()}],"mask-image-linear-to-pos":[{"mask-linear-to":Y()}],"mask-image-linear-from-color":[{"mask-linear-from":K()}],"mask-image-linear-to-color":[{"mask-linear-to":K()}],"mask-image-t-from-pos":[{"mask-t-from":Y()}],"mask-image-t-to-pos":[{"mask-t-to":Y()}],"mask-image-t-from-color":[{"mask-t-from":K()}],"mask-image-t-to-color":[{"mask-t-to":K()}],"mask-image-r-from-pos":[{"mask-r-from":Y()}],"mask-image-r-to-pos":[{"mask-r-to":Y()}],"mask-image-r-from-color":[{"mask-r-from":K()}],"mask-image-r-to-color":[{"mask-r-to":K()}],"mask-image-b-from-pos":[{"mask-b-from":Y()}],"mask-image-b-to-pos":[{"mask-b-to":Y()}],"mask-image-b-from-color":[{"mask-b-from":K()}],"mask-image-b-to-color":[{"mask-b-to":K()}],"mask-image-l-from-pos":[{"mask-l-from":Y()}],"mask-image-l-to-pos":[{"mask-l-to":Y()}],"mask-image-l-from-color":[{"mask-l-from":K()}],"mask-image-l-to-color":[{"mask-l-to":K()}],"mask-image-x-from-pos":[{"mask-x-from":Y()}],"mask-image-x-to-pos":[{"mask-x-to":Y()}],"mask-image-x-from-color":[{"mask-x-from":K()}],"mask-image-x-to-color":[{"mask-x-to":K()}],"mask-image-y-from-pos":[{"mask-y-from":Y()}],"mask-image-y-to-pos":[{"mask-y-to":Y()}],"mask-image-y-from-color":[{"mask-y-from":K()}],"mask-image-y-to-color":[{"mask-y-to":K()}],"mask-image-radial":[{"mask-radial":[Pe,Oe]}],"mask-image-radial-from-pos":[{"mask-radial-from":Y()}],"mask-image-radial-to-pos":[{"mask-radial-to":Y()}],"mask-image-radial-from-color":[{"mask-radial-from":K()}],"mask-image-radial-to-color":[{"mask-radial-to":K()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":_()}],"mask-image-conic-pos":[{"mask-conic":[nt]}],"mask-image-conic-from-pos":[{"mask-conic-from":Y()}],"mask-image-conic-to-pos":[{"mask-conic-to":Y()}],"mask-image-conic-from-color":[{"mask-conic-from":K()}],"mask-image-conic-to-color":[{"mask-conic-to":K()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:Ae()}],"mask-repeat":[{mask:Se()}],"mask-size":[{mask:$e()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",Pe,Oe]}],filter:[{filter:["","none",Pe,Oe]}],blur:[{blur:oe()}],brightness:[{brightness:[nt,Pe,Oe]}],contrast:[{contrast:[nt,Pe,Oe]}],"drop-shadow":[{"drop-shadow":["","none",h,kf,Tf]}],"drop-shadow-color":[{"drop-shadow":K()}],grayscale:[{grayscale:["",nt,Pe,Oe]}],"hue-rotate":[{"hue-rotate":[nt,Pe,Oe]}],invert:[{invert:["",nt,Pe,Oe]}],saturate:[{saturate:[nt,Pe,Oe]}],sepia:[{sepia:["",nt,Pe,Oe]}],"backdrop-filter":[{"backdrop-filter":["","none",Pe,Oe]}],"backdrop-blur":[{"backdrop-blur":oe()}],"backdrop-brightness":[{"backdrop-brightness":[nt,Pe,Oe]}],"backdrop-contrast":[{"backdrop-contrast":[nt,Pe,Oe]}],"backdrop-grayscale":[{"backdrop-grayscale":["",nt,Pe,Oe]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[nt,Pe,Oe]}],"backdrop-invert":[{"backdrop-invert":["",nt,Pe,Oe]}],"backdrop-opacity":[{"backdrop-opacity":[nt,Pe,Oe]}],"backdrop-saturate":[{"backdrop-saturate":[nt,Pe,Oe]}],"backdrop-sepia":[{"backdrop-sepia":["",nt,Pe,Oe]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":k()}],"border-spacing-x":[{"border-spacing-x":k()}],"border-spacing-y":[{"border-spacing-y":k()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",Pe,Oe]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[nt,"initial",Pe,Oe]}],ease:[{ease:["linear","initial",w,Pe,Oe]}],delay:[{delay:[nt,Pe,Oe]}],animate:[{animate:["none",C,Pe,Oe]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[b,Pe,Oe]}],"perspective-origin":[{"perspective-origin":O()}],rotate:[{rotate:ne()}],"rotate-x":[{"rotate-x":ne()}],"rotate-y":[{"rotate-y":ne()}],"rotate-z":[{"rotate-z":ne()}],scale:[{scale:$()}],"scale-x":[{"scale-x":$()}],"scale-y":[{"scale-y":$()}],"scale-z":[{"scale-z":$()}],"scale-3d":["scale-3d"],skew:[{skew:ie()}],"skew-x":[{"skew-x":ie()}],"skew-y":[{"skew-y":ie()}],transform:[{transform:[Pe,Oe,"","none","gpu","cpu"]}],"transform-origin":[{origin:O()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:Z()}],"translate-x":[{"translate-x":Z()}],"translate-y":[{"translate-y":Z()}],"translate-z":[{"translate-z":Z()}],"translate-none":["translate-none"],accent:[{accent:K()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:K()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",Pe,Oe]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":k()}],"scroll-mx":[{"scroll-mx":k()}],"scroll-my":[{"scroll-my":k()}],"scroll-ms":[{"scroll-ms":k()}],"scroll-me":[{"scroll-me":k()}],"scroll-mbs":[{"scroll-mbs":k()}],"scroll-mbe":[{"scroll-mbe":k()}],"scroll-mt":[{"scroll-mt":k()}],"scroll-mr":[{"scroll-mr":k()}],"scroll-mb":[{"scroll-mb":k()}],"scroll-ml":[{"scroll-ml":k()}],"scroll-p":[{"scroll-p":k()}],"scroll-px":[{"scroll-px":k()}],"scroll-py":[{"scroll-py":k()}],"scroll-ps":[{"scroll-ps":k()}],"scroll-pe":[{"scroll-pe":k()}],"scroll-pbs":[{"scroll-pbs":k()}],"scroll-pbe":[{"scroll-pbe":k()}],"scroll-pt":[{"scroll-pt":k()}],"scroll-pr":[{"scroll-pr":k()}],"scroll-pb":[{"scroll-pb":k()}],"scroll-pl":[{"scroll-pl":k()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",Pe,Oe]}],fill:[{fill:["none",...K()]}],"stroke-w":[{stroke:[nt,au,Ta,fS]}],stroke:[{stroke:["none",...K()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","inset-bs","inset-be","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pbs","pbe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mbs","mbe","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-bs","border-w-be","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-bs","border-color-be","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mbs","scroll-mbe","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pbs","scroll-pbe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},lH=(e,{cacheSize:t,prefix:n,experimentalParseClassName:r,extend:i={},override:o={}})=>(Cu(e,"cacheSize",t),Cu(e,"prefix",n),Cu(e,"experimentalParseClassName",r),Nf(e.theme,o.theme),Nf(e.classGroups,o.classGroups),Nf(e.conflictingClassGroups,o.conflictingClassGroups),Nf(e.conflictingClassGroupModifiers,o.conflictingClassGroupModifiers),Cu(e,"orderSensitiveModifiers",o.orderSensitiveModifiers),Mf(e.theme,i.theme),Mf(e.classGroups,i.classGroups),Mf(e.conflictingClassGroups,i.conflictingClassGroups),Mf(e.conflictingClassGroupModifiers,i.conflictingClassGroupModifiers),kR(e,i,"orderSensitiveModifiers"),e),Cu=(e,t,n)=>{n!==void 0&&(e[t]=n)},Nf=(e,t)=>{if(t)for(const n in t)Cu(e,n,t[n])},Mf=(e,t)=>{if(t)for(const n in t)kR(e,t,n)},kR=(e,t,n)=>{const r=t[n];r!==void 0&&(e[n]=e[n]?e[n].concat(r):r)},uH=(e,...t)=>typeof e=="function"?cS(hS,e,...t):cS(()=>lH(hS(),e),...t),cH=uH({extend:{theme:{text:["xxs","xxl","h-xs","h-sm","h-md","h-lg","h-xl","h-xxl"]}}});function ue(...e){return cH(Pt(e))}const gS=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,mS=Pt,xt=(e,t)=>n=>{var r;if(t?.variants==null)return mS(e,n?.class,n?.className);const{variants:i,defaultVariants:o}=t,a=Object.keys(i).map(c=>{const d=n?.[c],p=o?.[c];if(d===null)return null;const g=gS(d)||gS(p);return i[c][g]}),s=n&&Object.entries(n).reduce((c,d)=>{let[p,g]=d;return g===void 0||(c[p]=g),c},{}),u=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((c,d)=>{let{class:p,className:g,...h}=d;return Object.entries(h).every(v=>{let[b,y]=v;return Array.isArray(y)?y.includes({...o,...s}[b]):{...o,...s}[b]===y})?[...c,p,g]:c},[]);return mS(e,a,u,n?.class,n?.className)},fH=["h-xxl-regular","h-xxl-medium","h-xl-regular","h-xl-medium","h-lg-regular","h-lg-medium","h-md-regular","h-md-medium","h-sm-regular","h-sm-medium","h-xs-regular","h-xs-medium","body-xxl-regular","body-xxl-medium","body-xxl-semibold","body-xl-regular","body-xl-medium","body-xl-semibold","body-lg-regular","body-lg-medium","body-lg-semibold","body-md-regular","body-md-medium","body-md-semibold","body-sm-regular","body-sm-medium","body-sm-semibold","body-xs-regular","body-xs-medium","body-xs-semibold","body-xxs-regular","body-xxs-medium","body-xxs-semibold"],dH={"h-xxl-regular":"text-h-xxl font-normal","h-xxl-medium":"text-h-xxl font-medium","h-xl-regular":"text-h-xl font-normal","h-xl-medium":"text-h-xl font-medium","h-lg-regular":"text-h-lg font-normal","h-lg-medium":"text-h-lg font-medium","h-md-regular":"text-h-md font-normal","h-md-medium":"text-h-md font-medium","h-sm-regular":"text-h-sm font-normal","h-sm-medium":"text-h-sm font-medium","h-xs-regular":"text-h-xs font-normal","h-xs-medium":"text-h-xs font-medium","body-xxl-regular":"text-xxl font-normal","body-xxl-medium":"text-xxl font-medium","body-xxl-semibold":"text-xxl font-semibold","body-xl-regular":"text-xl font-normal","body-xl-medium":"text-xl font-medium","body-xl-semibold":"text-xl font-semibold","body-lg-regular":"text-lg font-normal","body-lg-medium":"text-lg font-medium","body-lg-semibold":"text-lg font-semibold","body-md-regular":"text-base font-normal","body-md-medium":"text-base font-medium","body-md-semibold":"text-base font-semibold","body-sm-regular":"text-sm font-normal","body-sm-medium":"text-sm font-medium","body-sm-semibold":"text-sm font-semibold","body-xs-regular":"text-xs font-normal","body-xs-medium":"text-xs font-medium","body-xs-semibold":"text-xs font-semibold","body-xxs-regular":"text-xxs font-normal","body-xxs-medium":"text-xxs font-medium","body-xxs-semibold":"text-xxs font-semibold"},Yb=xt("tracking-normal",{variants:{variant:dH},defaultVariants:{variant:"body-md-regular"}}),dn=(e="body-md-regular")=>Yb({variant:e}),pH=e=>e.startsWith("h-xxl")?"h1":e.startsWith("h-xl")?"h2":e.startsWith("h-lg")?"h3":e.startsWith("h-md")?"h4":e.startsWith("h-sm")?"h5":e.startsWith("h-xs")?"h6":"p",yy=({as:e,className:t,variant:n,...r})=>{const i=n??"body-md-regular",o=e??pH(i);return x.createElement(o,{...r,className:ue(Yb({variant:i}),t)})},Xb=xt(`inline-flex items-center justify-center gap-2 px-2 transition-colors
|
|
2
|
-
focus:outline-none`,{variants:{variant:{waiting:"bg-warning-bg text-warning-text",in_progress:"bg-success-bg text-success-text",negotiation:"bg-negotiation-bg text-negotiation-text",documents:"bg-invalid-bg text-invalid-text",new:"bg-info-new-bg text-info-new-text",followup:"bg-follow-up-bg text-follow-up-text",interested:"bg-warning-bg text-warning-text",proposal:"bg-proposal-bg text-proposal-text",action_required:"bg-error-bg text-error-text",contract:"bg-contract-bg text-contract-text",completed:"bg-success-bg text-success-text",invalid:"bg-invalid-bg text-invalid-text"},kind:{status:"rounded-[0.875rem] py-1",priority:"rounded py-1"},dotPosition:{left:"py-1.5",right:"flex-row-reverse py-1.5"}},defaultVariants:{variant:"waiting",kind:"status"}}),
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const O=require("react/jsx-runtime"),$=require("react"),Jp=require("react-dom");function FR(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 x=FR($),Wi=FR(Jp);function VR(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=VR(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function At(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=VR(e))&&(r&&(r+=" "),r+=t);return r}const OH=(e,t)=>{const n=new Array(e.length+t.length);for(let r=0;r<e.length;r++)n[r]=e[r];for(let r=0;r<t.length;r++)n[e.length+r]=t[r];return n},PH=(e,t)=>({classGroupId:e,validator:t}),BR=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),Fd="-",PC=[],AH="arbitrary..",RH=e=>{const t=TH(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:a=>{if(a.startsWith("[")&&a.endsWith("]"))return IH(a);const s=a.split(Fd),u=s[0]===""&&s.length>1?1:0;return zR(s,u,t)},getConflictingClassGroupIds:(a,s)=>{if(s){const u=r[a],c=n[a];return u?c?OH(c,u):u:c||PC}return n[a]||PC}}},zR=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;const i=e[t],o=n.nextPart.get(i);if(o){const c=zR(e,t+1,o);if(c)return c}const a=n.validators;if(a===null)return;const s=t===0?e.join(Fd):e.slice(t).join(Fd),u=a.length;for(let c=0;c<u;c++){const f=a[c];if(f.validator(s))return f.classGroupId}},IH=e=>e.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const t=e.slice(1,-1),n=t.indexOf(":"),r=t.slice(0,n);return r?AH+r:void 0})(),TH=e=>{const{theme:t,classGroups:n}=e;return kH(n,t)},kH=(e,t)=>{const n=BR();for(const r in e){const i=e[r];hx(i,n,r,t)}return n},hx=(e,t,n,r)=>{const i=e.length;for(let o=0;o<i;o++){const a=e[o];NH(a,t,n,r)}},NH=(e,t,n,r)=>{if(typeof e=="string"){MH(e,t,n);return}if(typeof e=="function"){DH(e,t,n,r);return}jH(e,t,n,r)},MH=(e,t,n)=>{const r=e===""?t:WR(t,e);r.classGroupId=n},DH=(e,t,n,r)=>{if(LH(e)){hx(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(PH(n,e))},jH=(e,t,n,r)=>{const i=Object.entries(e),o=i.length;for(let a=0;a<o;a++){const[s,u]=i[a];hx(u,WR(t,s),n,r)}},WR=(e,t)=>{let n=e;const r=t.split(Fd),i=r.length;for(let o=0;o<i;o++){const a=r[o];let s=n.nextPart.get(a);s||(s=BR(),n.nextPart.set(a,s)),n=s}return n},LH=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,$H=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=Object.create(null),r=Object.create(null);const i=(o,a)=>{n[o]=a,t++,t>e&&(t=0,r=n,n=Object.create(null))};return{get(o){let a=n[o];if(a!==void 0)return a;if((a=r[o])!==void 0)return i(o,a),a},set(o,a){o in n?n[o]=a:i(o,a)}}},Ny="!",AC=":",FH=[],RC=(e,t,n,r,i)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:i}),VH=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=i=>{const o=[];let a=0,s=0,u=0,c;const f=i.length;for(let b=0;b<f;b++){const y=i[b];if(a===0&&s===0){if(y===AC){o.push(i.slice(u,b)),u=b+1;continue}if(y==="/"){c=b;continue}}y==="["?a++:y==="]"?a--:y==="("?s++:y===")"&&s--}const p=o.length===0?i:i.slice(u);let g=p,h=!1;p.endsWith(Ny)?(g=p.slice(0,-1),h=!0):p.startsWith(Ny)&&(g=p.slice(1),h=!0);const v=c&&c>u?c-u:void 0;return RC(o,h,g,v)};if(t){const i=t+AC,o=r;r=a=>a.startsWith(i)?o(a.slice(i.length)):RC(FH,!1,a,void 0,!0)}if(n){const i=r;r=o=>n({className:o,parseClassName:i})}return r},BH=e=>{const t=new Map;return e.orderSensitiveModifiers.forEach((n,r)=>{t.set(n,1e6+r)}),n=>{const r=[];let i=[];for(let o=0;o<n.length;o++){const a=n[o],s=a[0]==="[",u=t.has(a);s||u?(i.length>0&&(i.sort(),r.push(...i),i=[]),r.push(a)):i.push(a)}return i.length>0&&(i.sort(),r.push(...i)),r}},zH=e=>({cache:$H(e.cacheSize),parseClassName:VH(e),sortModifiers:BH(e),...RH(e)}),WH=/\s+/,HH=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:o}=t,a=[],s=e.trim().split(WH);let u="";for(let c=s.length-1;c>=0;c-=1){const f=s[c],{isExternal:p,modifiers:g,hasImportantModifier:h,baseClassName:v,maybePostfixModifierPosition:b}=n(f);if(p){u=f+(u.length>0?" "+u:u);continue}let y=!!b,w=r(y?v.substring(0,b):v);if(!w){if(!y){u=f+(u.length>0?" "+u:u);continue}if(w=r(v),!w){u=f+(u.length>0?" "+u:u);continue}y=!1}const S=g.length===0?"":g.length===1?g[0]:o(g).join(":"),E=h?S+Ny:S,_=E+w;if(a.indexOf(_)>-1)continue;a.push(_);const P=i(w,y);for(let R=0;R<P.length;++R){const I=P[R];a.push(E+I)}u=f+(u.length>0?" "+u:u)}return u},UH=(...e)=>{let t=0,n,r,i="";for(;t<e.length;)(n=e[t++])&&(r=HR(n))&&(i&&(i+=" "),i+=r);return i},HR=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=HR(e[r]))&&(n&&(n+=" "),n+=t);return n},IC=(e,...t)=>{let n,r,i,o;const a=u=>{const c=t.reduce((f,p)=>p(f),e());return n=zH(c),r=n.cache.get,i=n.cache.set,o=s,s(u)},s=u=>{const c=r(u);if(c)return c;const f=HH(u,n);return i(u,f),f};return o=a,(...u)=>o(UH(...u))},GH=[],ln=e=>{const t=n=>n[e]||GH;return t.isThemeGetter=!0,t},UR=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,GR=/^\((?:(\w[\w-]*):)?(.+)\)$/i,qH=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,KH=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,YH=/\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$/,XH=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,ZH=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,QH=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Uo=e=>qH.test(e),it=e=>!!e&&!Number.isNaN(Number(e)),Go=e=>!!e&&Number.isInteger(Number(e)),Tm=e=>e.endsWith("%")&&it(e.slice(0,-1)),to=e=>KH.test(e),qR=()=>!0,JH=e=>YH.test(e)&&!XH.test(e),gx=()=>!1,eU=e=>ZH.test(e),tU=e=>QH.test(e),nU=e=>!Ie(e)&&!Te(e),rU=e=>pa(e,XR,gx),Ie=e=>UR.test(e),La=e=>pa(e,ZR,JH),TC=e=>pa(e,fU,it),iU=e=>pa(e,JR,qR),oU=e=>pa(e,QR,gx),kC=e=>pa(e,KR,gx),aU=e=>pa(e,YR,tU),Ff=e=>pa(e,eI,eU),Te=e=>GR.test(e),du=e=>gs(e,ZR),sU=e=>gs(e,QR),NC=e=>gs(e,KR),lU=e=>gs(e,XR),uU=e=>gs(e,YR),Vf=e=>gs(e,eI,!0),cU=e=>gs(e,JR,!0),pa=(e,t,n)=>{const r=UR.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},gs=(e,t,n=!1)=>{const r=GR.exec(e);return r?r[1]?t(r[1]):n:!1},KR=e=>e==="position"||e==="percentage",YR=e=>e==="image"||e==="url",XR=e=>e==="length"||e==="size"||e==="bg-size",ZR=e=>e==="length",fU=e=>e==="number",QR=e=>e==="family-name",JR=e=>e==="number"||e==="weight",eI=e=>e==="shadow",MC=()=>{const e=ln("color"),t=ln("font"),n=ln("text"),r=ln("font-weight"),i=ln("tracking"),o=ln("leading"),a=ln("breakpoint"),s=ln("container"),u=ln("spacing"),c=ln("radius"),f=ln("shadow"),p=ln("inset-shadow"),g=ln("text-shadow"),h=ln("drop-shadow"),v=ln("blur"),b=ln("perspective"),y=ln("aspect"),w=ln("ease"),S=ln("animate"),E=()=>["auto","avoid","all","avoid-page","page","left","right","column"],_=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],P=()=>[..._(),Te,Ie],R=()=>["auto","hidden","clip","visible","scroll"],I=()=>["auto","contain","none"],k=()=>[Te,Ie,u],B=()=>[Uo,"full","auto",...k()],L=()=>[Go,"none","subgrid",Te,Ie],V=()=>["auto",{span:["full",Go,Te,Ie]},Go,Te,Ie],D=()=>[Go,"auto",Te,Ie],W=()=>["auto","min","max","fr",Te,Ie],J=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],re=()=>["start","end","center","stretch","center-safe","end-safe"],U=()=>["auto",...k()],ee=()=>[Uo,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...k()],Z=()=>[Uo,"screen","full","dvw","lvw","svw","min","max","fit",...k()],ue=()=>[Uo,"screen","full","lh","dvh","lvh","svh","min","max","fit",...k()],X=()=>[e,Te,Ie],Oe=()=>[..._(),NC,kC,{position:[Te,Ie]}],Ee=()=>["no-repeat",{repeat:["","x","y","space","round"]}],Me=()=>["auto","cover","contain",lU,rU,{size:[Te,Ie]}],ye=()=>[Tm,du,La],be=()=>["","none","full",c,Te,Ie],$e=()=>["",it,du,La],me=()=>["solid","dashed","dotted","double"],Se=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],q=()=>[it,Tm,NC,kC],te=()=>["","none",v,Te,Ie],Y=()=>["none",it,Te,Ie],j=()=>["none",it,Te,Ie],ie=()=>[it,Te,Ie],Q=()=>[Uo,"full",...k()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[to],breakpoint:[to],color:[qR],container:[to],"drop-shadow":[to],ease:["in","out","in-out"],font:[nU],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[to],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[to],shadow:[to],spacing:["px",it],text:[to],"text-shadow":[to],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Uo,Ie,Te,y]}],container:["container"],columns:[{columns:[it,Ie,Te,s]}],"break-after":[{"break-after":E()}],"break-before":[{"break-before":E()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:P()}],overflow:[{overflow:R()}],"overflow-x":[{"overflow-x":R()}],"overflow-y":[{"overflow-y":R()}],overscroll:[{overscroll:I()}],"overscroll-x":[{"overscroll-x":I()}],"overscroll-y":[{"overscroll-y":I()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:B()}],"inset-x":[{"inset-x":B()}],"inset-y":[{"inset-y":B()}],start:[{"inset-s":B(),start:B()}],end:[{"inset-e":B(),end:B()}],"inset-bs":[{"inset-bs":B()}],"inset-be":[{"inset-be":B()}],top:[{top:B()}],right:[{right:B()}],bottom:[{bottom:B()}],left:[{left:B()}],visibility:["visible","invisible","collapse"],z:[{z:[Go,"auto",Te,Ie]}],basis:[{basis:[Uo,"full","auto",s,...k()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[it,Uo,"auto","initial","none",Ie]}],grow:[{grow:["",it,Te,Ie]}],shrink:[{shrink:["",it,Te,Ie]}],order:[{order:[Go,"first","last","none",Te,Ie]}],"grid-cols":[{"grid-cols":L()}],"col-start-end":[{col:V()}],"col-start":[{"col-start":D()}],"col-end":[{"col-end":D()}],"grid-rows":[{"grid-rows":L()}],"row-start-end":[{row:V()}],"row-start":[{"row-start":D()}],"row-end":[{"row-end":D()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":W()}],"auto-rows":[{"auto-rows":W()}],gap:[{gap:k()}],"gap-x":[{"gap-x":k()}],"gap-y":[{"gap-y":k()}],"justify-content":[{justify:[...J(),"normal"]}],"justify-items":[{"justify-items":[...re(),"normal"]}],"justify-self":[{"justify-self":["auto",...re()]}],"align-content":[{content:["normal",...J()]}],"align-items":[{items:[...re(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...re(),{baseline:["","last"]}]}],"place-content":[{"place-content":J()}],"place-items":[{"place-items":[...re(),"baseline"]}],"place-self":[{"place-self":["auto",...re()]}],p:[{p:k()}],px:[{px:k()}],py:[{py:k()}],ps:[{ps:k()}],pe:[{pe:k()}],pbs:[{pbs:k()}],pbe:[{pbe:k()}],pt:[{pt:k()}],pr:[{pr:k()}],pb:[{pb:k()}],pl:[{pl:k()}],m:[{m:U()}],mx:[{mx:U()}],my:[{my:U()}],ms:[{ms:U()}],me:[{me:U()}],mbs:[{mbs:U()}],mbe:[{mbe:U()}],mt:[{mt:U()}],mr:[{mr:U()}],mb:[{mb:U()}],ml:[{ml:U()}],"space-x":[{"space-x":k()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":k()}],"space-y-reverse":["space-y-reverse"],size:[{size:ee()}],"inline-size":[{inline:["auto",...Z()]}],"min-inline-size":[{"min-inline":["auto",...Z()]}],"max-inline-size":[{"max-inline":["none",...Z()]}],"block-size":[{block:["auto",...ue()]}],"min-block-size":[{"min-block":["auto",...ue()]}],"max-block-size":[{"max-block":["none",...ue()]}],w:[{w:[s,"screen",...ee()]}],"min-w":[{"min-w":[s,"screen","none",...ee()]}],"max-w":[{"max-w":[s,"screen","none","prose",{screen:[a]},...ee()]}],h:[{h:["screen","lh",...ee()]}],"min-h":[{"min-h":["screen","lh","none",...ee()]}],"max-h":[{"max-h":["screen","lh",...ee()]}],"font-size":[{text:["base",n,du,La]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,cU,iU]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",Tm,Ie]}],"font-family":[{font:[sU,oU,t]}],"font-features":[{"font-features":[Ie]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[i,Te,Ie]}],"line-clamp":[{"line-clamp":[it,"none",Te,TC]}],leading:[{leading:[o,...k()]}],"list-image":[{"list-image":["none",Te,Ie]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",Te,Ie]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:X()}],"text-color":[{text:X()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...me(),"wavy"]}],"text-decoration-thickness":[{decoration:[it,"from-font","auto",Te,La]}],"text-decoration-color":[{decoration:X()}],"underline-offset":[{"underline-offset":[it,"auto",Te,Ie]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:k()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Te,Ie]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Te,Ie]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:Oe()}],"bg-repeat":[{bg:Ee()}],"bg-size":[{bg:Me()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Go,Te,Ie],radial:["",Te,Ie],conic:[Go,Te,Ie]},uU,aU]}],"bg-color":[{bg:X()}],"gradient-from-pos":[{from:ye()}],"gradient-via-pos":[{via:ye()}],"gradient-to-pos":[{to:ye()}],"gradient-from":[{from:X()}],"gradient-via":[{via:X()}],"gradient-to":[{to:X()}],rounded:[{rounded:be()}],"rounded-s":[{"rounded-s":be()}],"rounded-e":[{"rounded-e":be()}],"rounded-t":[{"rounded-t":be()}],"rounded-r":[{"rounded-r":be()}],"rounded-b":[{"rounded-b":be()}],"rounded-l":[{"rounded-l":be()}],"rounded-ss":[{"rounded-ss":be()}],"rounded-se":[{"rounded-se":be()}],"rounded-ee":[{"rounded-ee":be()}],"rounded-es":[{"rounded-es":be()}],"rounded-tl":[{"rounded-tl":be()}],"rounded-tr":[{"rounded-tr":be()}],"rounded-br":[{"rounded-br":be()}],"rounded-bl":[{"rounded-bl":be()}],"border-w":[{border:$e()}],"border-w-x":[{"border-x":$e()}],"border-w-y":[{"border-y":$e()}],"border-w-s":[{"border-s":$e()}],"border-w-e":[{"border-e":$e()}],"border-w-bs":[{"border-bs":$e()}],"border-w-be":[{"border-be":$e()}],"border-w-t":[{"border-t":$e()}],"border-w-r":[{"border-r":$e()}],"border-w-b":[{"border-b":$e()}],"border-w-l":[{"border-l":$e()}],"divide-x":[{"divide-x":$e()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":$e()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...me(),"hidden","none"]}],"divide-style":[{divide:[...me(),"hidden","none"]}],"border-color":[{border:X()}],"border-color-x":[{"border-x":X()}],"border-color-y":[{"border-y":X()}],"border-color-s":[{"border-s":X()}],"border-color-e":[{"border-e":X()}],"border-color-bs":[{"border-bs":X()}],"border-color-be":[{"border-be":X()}],"border-color-t":[{"border-t":X()}],"border-color-r":[{"border-r":X()}],"border-color-b":[{"border-b":X()}],"border-color-l":[{"border-l":X()}],"divide-color":[{divide:X()}],"outline-style":[{outline:[...me(),"none","hidden"]}],"outline-offset":[{"outline-offset":[it,Te,Ie]}],"outline-w":[{outline:["",it,du,La]}],"outline-color":[{outline:X()}],shadow:[{shadow:["","none",f,Vf,Ff]}],"shadow-color":[{shadow:X()}],"inset-shadow":[{"inset-shadow":["none",p,Vf,Ff]}],"inset-shadow-color":[{"inset-shadow":X()}],"ring-w":[{ring:$e()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:X()}],"ring-offset-w":[{"ring-offset":[it,La]}],"ring-offset-color":[{"ring-offset":X()}],"inset-ring-w":[{"inset-ring":$e()}],"inset-ring-color":[{"inset-ring":X()}],"text-shadow":[{"text-shadow":["none",g,Vf,Ff]}],"text-shadow-color":[{"text-shadow":X()}],opacity:[{opacity:[it,Te,Ie]}],"mix-blend":[{"mix-blend":[...Se(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":Se()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[it]}],"mask-image-linear-from-pos":[{"mask-linear-from":q()}],"mask-image-linear-to-pos":[{"mask-linear-to":q()}],"mask-image-linear-from-color":[{"mask-linear-from":X()}],"mask-image-linear-to-color":[{"mask-linear-to":X()}],"mask-image-t-from-pos":[{"mask-t-from":q()}],"mask-image-t-to-pos":[{"mask-t-to":q()}],"mask-image-t-from-color":[{"mask-t-from":X()}],"mask-image-t-to-color":[{"mask-t-to":X()}],"mask-image-r-from-pos":[{"mask-r-from":q()}],"mask-image-r-to-pos":[{"mask-r-to":q()}],"mask-image-r-from-color":[{"mask-r-from":X()}],"mask-image-r-to-color":[{"mask-r-to":X()}],"mask-image-b-from-pos":[{"mask-b-from":q()}],"mask-image-b-to-pos":[{"mask-b-to":q()}],"mask-image-b-from-color":[{"mask-b-from":X()}],"mask-image-b-to-color":[{"mask-b-to":X()}],"mask-image-l-from-pos":[{"mask-l-from":q()}],"mask-image-l-to-pos":[{"mask-l-to":q()}],"mask-image-l-from-color":[{"mask-l-from":X()}],"mask-image-l-to-color":[{"mask-l-to":X()}],"mask-image-x-from-pos":[{"mask-x-from":q()}],"mask-image-x-to-pos":[{"mask-x-to":q()}],"mask-image-x-from-color":[{"mask-x-from":X()}],"mask-image-x-to-color":[{"mask-x-to":X()}],"mask-image-y-from-pos":[{"mask-y-from":q()}],"mask-image-y-to-pos":[{"mask-y-to":q()}],"mask-image-y-from-color":[{"mask-y-from":X()}],"mask-image-y-to-color":[{"mask-y-to":X()}],"mask-image-radial":[{"mask-radial":[Te,Ie]}],"mask-image-radial-from-pos":[{"mask-radial-from":q()}],"mask-image-radial-to-pos":[{"mask-radial-to":q()}],"mask-image-radial-from-color":[{"mask-radial-from":X()}],"mask-image-radial-to-color":[{"mask-radial-to":X()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":_()}],"mask-image-conic-pos":[{"mask-conic":[it]}],"mask-image-conic-from-pos":[{"mask-conic-from":q()}],"mask-image-conic-to-pos":[{"mask-conic-to":q()}],"mask-image-conic-from-color":[{"mask-conic-from":X()}],"mask-image-conic-to-color":[{"mask-conic-to":X()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:Oe()}],"mask-repeat":[{mask:Ee()}],"mask-size":[{mask:Me()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",Te,Ie]}],filter:[{filter:["","none",Te,Ie]}],blur:[{blur:te()}],brightness:[{brightness:[it,Te,Ie]}],contrast:[{contrast:[it,Te,Ie]}],"drop-shadow":[{"drop-shadow":["","none",h,Vf,Ff]}],"drop-shadow-color":[{"drop-shadow":X()}],grayscale:[{grayscale:["",it,Te,Ie]}],"hue-rotate":[{"hue-rotate":[it,Te,Ie]}],invert:[{invert:["",it,Te,Ie]}],saturate:[{saturate:[it,Te,Ie]}],sepia:[{sepia:["",it,Te,Ie]}],"backdrop-filter":[{"backdrop-filter":["","none",Te,Ie]}],"backdrop-blur":[{"backdrop-blur":te()}],"backdrop-brightness":[{"backdrop-brightness":[it,Te,Ie]}],"backdrop-contrast":[{"backdrop-contrast":[it,Te,Ie]}],"backdrop-grayscale":[{"backdrop-grayscale":["",it,Te,Ie]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[it,Te,Ie]}],"backdrop-invert":[{"backdrop-invert":["",it,Te,Ie]}],"backdrop-opacity":[{"backdrop-opacity":[it,Te,Ie]}],"backdrop-saturate":[{"backdrop-saturate":[it,Te,Ie]}],"backdrop-sepia":[{"backdrop-sepia":["",it,Te,Ie]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":k()}],"border-spacing-x":[{"border-spacing-x":k()}],"border-spacing-y":[{"border-spacing-y":k()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",Te,Ie]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[it,"initial",Te,Ie]}],ease:[{ease:["linear","initial",w,Te,Ie]}],delay:[{delay:[it,Te,Ie]}],animate:[{animate:["none",S,Te,Ie]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[b,Te,Ie]}],"perspective-origin":[{"perspective-origin":P()}],rotate:[{rotate:Y()}],"rotate-x":[{"rotate-x":Y()}],"rotate-y":[{"rotate-y":Y()}],"rotate-z":[{"rotate-z":Y()}],scale:[{scale:j()}],"scale-x":[{"scale-x":j()}],"scale-y":[{"scale-y":j()}],"scale-z":[{"scale-z":j()}],"scale-3d":["scale-3d"],skew:[{skew:ie()}],"skew-x":[{"skew-x":ie()}],"skew-y":[{"skew-y":ie()}],transform:[{transform:[Te,Ie,"","none","gpu","cpu"]}],"transform-origin":[{origin:P()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:Q()}],"translate-x":[{"translate-x":Q()}],"translate-y":[{"translate-y":Q()}],"translate-z":[{"translate-z":Q()}],"translate-none":["translate-none"],accent:[{accent:X()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:X()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",Te,Ie]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":k()}],"scroll-mx":[{"scroll-mx":k()}],"scroll-my":[{"scroll-my":k()}],"scroll-ms":[{"scroll-ms":k()}],"scroll-me":[{"scroll-me":k()}],"scroll-mbs":[{"scroll-mbs":k()}],"scroll-mbe":[{"scroll-mbe":k()}],"scroll-mt":[{"scroll-mt":k()}],"scroll-mr":[{"scroll-mr":k()}],"scroll-mb":[{"scroll-mb":k()}],"scroll-ml":[{"scroll-ml":k()}],"scroll-p":[{"scroll-p":k()}],"scroll-px":[{"scroll-px":k()}],"scroll-py":[{"scroll-py":k()}],"scroll-ps":[{"scroll-ps":k()}],"scroll-pe":[{"scroll-pe":k()}],"scroll-pbs":[{"scroll-pbs":k()}],"scroll-pbe":[{"scroll-pbe":k()}],"scroll-pt":[{"scroll-pt":k()}],"scroll-pr":[{"scroll-pr":k()}],"scroll-pb":[{"scroll-pb":k()}],"scroll-pl":[{"scroll-pl":k()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",Te,Ie]}],fill:[{fill:["none",...X()]}],"stroke-w":[{stroke:[it,du,La,TC]}],stroke:[{stroke:["none",...X()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","inset-bs","inset-be","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pbs","pbe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mbs","mbe","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-bs","border-w-be","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-bs","border-color-be","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mbs","scroll-mbe","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pbs","scroll-pbe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},dU=(e,{cacheSize:t,prefix:n,experimentalParseClassName:r,extend:i={},override:o={}})=>(Au(e,"cacheSize",t),Au(e,"prefix",n),Au(e,"experimentalParseClassName",r),Bf(e.theme,o.theme),Bf(e.classGroups,o.classGroups),Bf(e.conflictingClassGroups,o.conflictingClassGroups),Bf(e.conflictingClassGroupModifiers,o.conflictingClassGroupModifiers),Au(e,"orderSensitiveModifiers",o.orderSensitiveModifiers),zf(e.theme,i.theme),zf(e.classGroups,i.classGroups),zf(e.conflictingClassGroups,i.conflictingClassGroups),zf(e.conflictingClassGroupModifiers,i.conflictingClassGroupModifiers),tI(e,i,"orderSensitiveModifiers"),e),Au=(e,t,n)=>{n!==void 0&&(e[t]=n)},Bf=(e,t)=>{if(t)for(const n in t)Au(e,n,t[n])},zf=(e,t)=>{if(t)for(const n in t)tI(e,t,n)},tI=(e,t,n)=>{const r=t[n];r!==void 0&&(e[n]=e[n]?e[n].concat(r):r)},pU=(e,...t)=>typeof e=="function"?IC(MC,e,...t):IC(()=>dU(MC(),e),...t),hU=pU({extend:{theme:{text:["xxs","xxl","h-xs","h-sm","h-md","h-lg","h-xl","h-xxl"]}}});function ae(...e){return hU(At(e))}const DC=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,jC=At,St=(e,t)=>n=>{var r;if(t?.variants==null)return jC(e,n?.class,n?.className);const{variants:i,defaultVariants:o}=t,a=Object.keys(i).map(c=>{const f=n?.[c],p=o?.[c];if(f===null)return null;const g=DC(f)||DC(p);return i[c][g]}),s=n&&Object.entries(n).reduce((c,f)=>{let[p,g]=f;return g===void 0||(c[p]=g),c},{}),u=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((c,f)=>{let{class:p,className:g,...h}=f;return Object.entries(h).every(v=>{let[b,y]=v;return Array.isArray(y)?y.includes({...o,...s}[b]):{...o,...s}[b]===y})?[...c,p,g]:c},[]);return jC(e,a,u,n?.class,n?.className)},gU=["h-xxl-regular","h-xxl-medium","h-xl-regular","h-xl-medium","h-lg-regular","h-lg-medium","h-md-regular","h-md-medium","h-sm-regular","h-sm-medium","h-xs-regular","h-xs-medium","body-xxl-regular","body-xxl-medium","body-xxl-semibold","body-xl-regular","body-xl-medium","body-xl-semibold","body-lg-regular","body-lg-medium","body-lg-semibold","body-md-regular","body-md-medium","body-md-semibold","body-sm-regular","body-sm-medium","body-sm-semibold","body-xs-regular","body-xs-medium","body-xs-semibold","body-xxs-regular","body-xxs-medium","body-xxs-semibold"],mU={"h-xxl-regular":"text-h-xxl font-normal","h-xxl-medium":"text-h-xxl font-medium","h-xl-regular":"text-h-xl font-normal","h-xl-medium":"text-h-xl font-medium","h-lg-regular":"text-h-lg font-normal","h-lg-medium":"text-h-lg font-medium","h-md-regular":"text-h-md font-normal","h-md-medium":"text-h-md font-medium","h-sm-regular":"text-h-sm font-normal","h-sm-medium":"text-h-sm font-medium","h-xs-regular":"text-h-xs font-normal","h-xs-medium":"text-h-xs font-medium","body-xxl-regular":"text-xxl font-normal","body-xxl-medium":"text-xxl font-medium","body-xxl-semibold":"text-xxl font-semibold","body-xl-regular":"text-xl font-normal","body-xl-medium":"text-xl font-medium","body-xl-semibold":"text-xl font-semibold","body-lg-regular":"text-lg font-normal","body-lg-medium":"text-lg font-medium","body-lg-semibold":"text-lg font-semibold","body-md-regular":"text-base font-normal","body-md-medium":"text-base font-medium","body-md-semibold":"text-base font-semibold","body-sm-regular":"text-sm font-normal","body-sm-medium":"text-sm font-medium","body-sm-semibold":"text-sm font-semibold","body-xs-regular":"text-xs font-normal","body-xs-medium":"text-xs font-medium","body-xs-semibold":"text-xs font-semibold","body-xxs-regular":"text-xxs font-normal","body-xxs-medium":"text-xxs font-medium","body-xxs-semibold":"text-xxs font-semibold"},mx=St("tracking-normal",{variants:{variant:mU},defaultVariants:{variant:"body-md-regular"}}),dn=(e="body-md-regular")=>mx({variant:e}),vU=e=>e.startsWith("h-xxl")?"h1":e.startsWith("h-xl")?"h2":e.startsWith("h-lg")?"h3":e.startsWith("h-md")?"h4":e.startsWith("h-sm")?"h5":e.startsWith("h-xs")?"h6":"p",My=({as:e,className:t,variant:n,...r})=>{const i=n??"body-md-regular",o=e??vU(i);return x.createElement(o,{...r,className:ae(mx({variant:i}),t)})},vx=St(`inline-flex items-center justify-center gap-2 px-2 transition-colors
|
|
2
|
+
focus:outline-none`,{variants:{variant:{waiting:"bg-warning-bg text-warning-text",in_progress:"bg-success-bg text-success-text",negotiation:"bg-negotiation-bg text-negotiation-text",documents:"bg-invalid-bg text-invalid-text",new:"bg-info-new-bg text-info-new-text",followup:"bg-follow-up-bg text-follow-up-text",interested:"bg-warning-bg text-warning-text",proposal:"bg-proposal-bg text-proposal-text",action_required:"bg-error-bg text-error-text",contract:"bg-contract-bg text-contract-text",completed:"bg-success-bg text-success-text",invalid:"bg-invalid-bg text-invalid-text"},kind:{status:"rounded-[0.875rem] py-1",priority:"rounded py-1"},dotPosition:{left:"py-1.5",right:"flex-row-reverse py-1.5"}},defaultVariants:{variant:"waiting",kind:"status"}}),yU=St("tracking-normal whitespace-nowrap",{variants:{kind:{status:dn("body-xs-medium"),priority:dn("body-sm-regular")}},defaultVariants:{kind:"status"}});function Dy({variant:e,kind:t="status",dotPosition:n,classNames:r={},children:i,...o}){const a=!!n,{className:s,dotClassName:u,labelClassName:c}=r;return O.jsxs("div",{className:ae(vx({variant:e,kind:t,dotPosition:n}),s),...o,children:[a&&O.jsx("span",{className:ae("inline-block h-2 w-2 rounded-full bg-current",u),"aria-hidden":"true"}),O.jsx("span",{className:ae(yU({kind:t}),c),children:i})]})}function LC(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function yx(...e){return t=>{let n=!1;const r=e.map(i=>{const o=LC(i,t);return!n&&typeof o=="function"&&(n=!0),o});if(n)return()=>{for(let i=0;i<r.length;i++){const o=r[i];typeof o=="function"?o():LC(e[i],null)}}}}function bt(...e){return x.useCallback(yx(...e),e)}var bU=Symbol.for("react.lazy"),Vd=x[" use ".trim().toString()];function xU(e){return typeof e=="object"&&e!==null&&"then"in e}function nI(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===bU&&"_payload"in e&&xU(e._payload)}function rI(e){const t=SU(e),n=x.forwardRef((r,i)=>{let{children:o,...a}=r;nI(o)&&typeof Vd=="function"&&(o=Vd(o._payload));const s=x.Children.toArray(o),u=s.find(EU);if(u){const c=u.props.children,f=s.map(p=>p===u?x.Children.count(c)>1?x.Children.only(null):x.isValidElement(c)?c.props.children:null:p);return O.jsx(t,{...a,ref:i,children:x.isValidElement(c)?x.cloneElement(c,void 0,f):null})}return O.jsx(t,{...a,ref:i,children:o})});return n.displayName=`${e}.Slot`,n}var wU=rI("Slot");function SU(e){const t=x.forwardRef((n,r)=>{let{children:i,...o}=n;if(nI(i)&&typeof Vd=="function"&&(i=Vd(i._payload)),x.isValidElement(i)){const a=OU(i),s=_U(o,i.props);return i.type!==x.Fragment&&(s.ref=r?yx(r,a):a),x.cloneElement(i,s)}return x.Children.count(i)>1?x.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var CU=Symbol("radix.slottable");function EU(e){return x.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===CU}function _U(e,t){const n={...t};for(const r in t){const i=e[r],o=t[r];/^on[A-Z]/.test(r)?i&&o?n[r]=(...s)=>{const u=o(...s);return i(...s),u}:i&&(n[r]=i):r==="style"?n[r]={...i,...o}:r==="className"&&(n[r]=[i,o].filter(Boolean).join(" "))}return{...e,...n}}function OU(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}const bx=St(["inline-flex cursor-pointer items-center justify-center rounded-xl font-medium tracking-normal whitespace-nowrap transition-colors","[&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg]:origin-center","disabled:bg-disabled-bg disabled:text-disabled-text disabled:pointer-events-none"].join(" "),{variants:{variant:{primary:`bg-primary-inverse-bg text-primary-inverse-text
|
|
3
3
|
hover:bg-primary-inverse-hover-bg`,secondary:"bg-secondary-bg text-primary-text hover:bg-primary-hover-bg",secondaryBorder:`bg-primary-bg text-primary-text hover:bg-primary-hover-bg
|
|
4
4
|
disabled:border-inp-disabled-border border`,link:"text-primary-text hover:text-secondary-text underline underline-offset-3",ghost:`hover:bg-tertiary-bg hover:text-primary-text aria-expanded:bg-tertiary-bg
|
|
5
5
|
aria-expanded:text-primary-text`},size:{lg:`${dn("body-lg-medium")} w-fit gap-2 px-4.5 py-3
|
|
6
6
|
[&_svg]:size-[18px]`,md:`${dn("body-md-medium")} w-fit gap-2 px-4.5 py-2
|
|
7
7
|
[&_svg]:size-4`,sm:`${dn("body-sm-medium")} w-fit gap-2 px-3 py-2
|
|
8
8
|
[&_svg]:size-4`,xs:`${dn("body-xs-medium")} w-fit gap-1 px-3 py-2
|
|
9
|
-
[&_svg]:size-[14px]`,default:`${dn("body-sm-medium")} size-9 [&_svg]:size-4`}},compoundVariants:[{variant:"link",size:"lg",className:"[&_svg]:size-5"}],defaultVariants:{variant:"primary",size:"md"}}),
|
|
9
|
+
[&_svg]:size-[14px]`,default:`${dn("body-sm-medium")} size-9 [&_svg]:size-4`}},compoundVariants:[{variant:"link",size:"lg",className:"[&_svg]:size-5"}],defaultVariants:{variant:"primary",size:"md"}}),uo=({className:e,variant:t,size:n,asChild:r=!1,ref:i,...o})=>{const a=r?wU:"button";return O.jsx(a,{className:ae(bx({variant:t,size:n,className:e})),ref:i,...o})};uo.displayName="Button";const PU=St("group/card rounded-lg",{variants:{variant:{light:`bg-primary-bg text-primary-text border-delicate-border
|
|
10
10
|
hover:border-default-border hover:bg-secondary-bg shadow-[0_2px_6px_rgba(0,0,0,0.1)]
|
|
11
11
|
hover:shadow-[0_2px_6px_rgba(0,0,0,0.12)]`,dark:`bg-secondary-inverse-bg text-primary-inverse-text
|
|
12
12
|
hover:bg-tertiary-inverse-bg border-transparent shadow-[0_1px_3px_rgba(0,0,0,0.2)]
|
|
13
|
-
hover:shadow-[0_6px_16px_rgba(0,0,0,0.30)]`},active:{true:"",false:""}},defaultVariants:{variant:"light",active:!1},compoundVariants:[{variant:"light",active:!0,class:"bg-tertiary-bg border-default-border shadow-[0_2px_6px_rgba(0,0,0,0.1)]"},{variant:"dark",active:!0,class:"bg-tertiary-inverse-bg shadow-[0_2px_6px_rgba(0,0,0,0.25)]"}]}),
|
|
14
|
-
tracking-tight`),
|
|
15
|
-
group-data-[disabled=true]/card:text-disabled-text`),PH=xt("group-data-[disabled=true]/card:text-disabled-text p-6 pt-0"),AH=xt("group-data-[disabled=true]/card:text-disabled-text flex items-center p-6 pt-0"),DR=({ref:e,className:t,variant:n,disabled:r,active:i,...o})=>P.jsx("div",{ref:e,"data-disabled":r||void 0,className:ue(SH({variant:n,active:i}),t),...o});DR.displayName="Card";const jR=({ref:e,className:t,...n})=>P.jsx("div",{ref:e,className:ue(EH(),t),...n});jR.displayName="CardHeader";const LR=({ref:e,className:t,...n})=>P.jsx("div",{ref:e,className:ue(_H(),t),...n});LR.displayName="CardTitle";const $R=({ref:e,className:t,...n})=>P.jsx("div",{ref:e,className:ue(OH(),t),...n});$R.displayName="CardDescription";const FR=({ref:e,className:t,...n})=>P.jsx("div",{ref:e,className:ue(PH(),t),...n});FR.displayName="CardContent";const VR=({ref:e,className:t,...n})=>P.jsx("div",{ref:e,className:ue(AH(),t),...n});VR.displayName="CardFooter";function RH(e,t){const n=x.createContext(t),r=o=>{const{children:a,...s}=o,u=x.useMemo(()=>s,Object.values(s));return P.jsx(n.Provider,{value:u,children:a})};r.displayName=e+"Provider";function i(o){const a=x.useContext(n);if(a)return a;if(t!==void 0)return t;throw new Error(`\`${o}\` must be used within \`${e}\``)}return[r,i]}function Fi(e,t=[]){let n=[];function r(o,a){const s=x.createContext(a),u=n.length;n=[...n,a];const c=p=>{const{scope:g,children:h,...v}=p,b=g?.[e]?.[u]||s,y=x.useMemo(()=>v,Object.values(v));return P.jsx(b.Provider,{value:y,children:h})};c.displayName=o+"Provider";function d(p,g){const h=g?.[e]?.[u]||s,v=x.useContext(h);if(v)return v;if(a!==void 0)return a;throw new Error(`\`${p}\` must be used within \`${o}\``)}return[c,d]}const i=()=>{const o=n.map(a=>x.createContext(a));return function(s){const u=s?.[e]||o;return x.useMemo(()=>({[`__scope${e}`]:{...s,[e]:u}}),[s,u])}};return i.scopeName=e,[r,IH(i,...t)]}function IH(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(o){const a=r.reduce((s,{useScope:u,scopeName:c})=>{const p=u(o)[`__scope${c}`];return{...s,...p}},{});return x.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function bt(e,t,{checkForDefaultPrevented:n=!0}={}){return function(i){if(e?.(i),n===!1||!i.defaultPrevented)return t?.(i)}}var ia=globalThis?.document?x.useLayoutEffect:()=>{},TH=x[" useInsertionEffect ".trim().toString()]||ia;function us({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[i,o,a]=kH({defaultProp:t,onChange:n}),s=e!==void 0,u=s?e:i;{const d=x.useRef(e!==void 0);x.useEffect(()=>{const p=d.current;p!==s&&console.warn(`${r} is changing from ${p?"controlled":"uncontrolled"} to ${s?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),d.current=s},[s,r])}const c=x.useCallback(d=>{if(s){const p=NH(d)?d(e):d;p!==e&&a.current?.(p)}else o(d)},[s,e,o,a]);return[u,c]}function kH({defaultProp:e,onChange:t}){const[n,r]=x.useState(e),i=x.useRef(n),o=x.useRef(t);return TH(()=>{o.current=t},[t]),x.useEffect(()=>{i.current!==n&&(o.current?.(n),i.current=n)},[n,i]),[n,r,o]}function NH(e){return typeof e=="function"}function Jb(e){const t=x.useRef({value:e,previous:e});return x.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}function Gp(e){const[t,n]=x.useState(void 0);return ia(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(i=>{if(!Array.isArray(i)||!i.length)return;const o=i[0];let a,s;if("borderBoxSize"in o){const u=o.borderBoxSize,c=Array.isArray(u)?u[0]:u;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 MH(e,t){return x.useReducer((n,r)=>t[n][r]??n,e)}var yo=e=>{const{present:t,children:n}=e,r=DH(t),i=typeof n=="function"?n({present:r.isPresent}):x.Children.only(n),o=Zt(r.ref,jH(i));return typeof n=="function"||r.isPresent?x.cloneElement(i,{ref:o}):null};yo.displayName="Presence";function DH(e){const[t,n]=x.useState(),r=x.useRef(null),i=x.useRef(e),o=x.useRef("none"),a=e?"mounted":"unmounted",[s,u]=MH(a,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return x.useEffect(()=>{const c=Df(r.current);o.current=s==="mounted"?c:"none"},[s]),ia(()=>{const c=r.current,d=i.current;if(d!==e){const g=o.current,h=Df(c);e?u("MOUNT"):h==="none"||c?.display==="none"?u("UNMOUNT"):u(d&&g!==h?"ANIMATION_OUT":"UNMOUNT"),i.current=e}},[e,u]),ia(()=>{if(t){let c;const d=t.ownerDocument.defaultView??window,p=h=>{const b=Df(r.current).includes(CSS.escape(h.animationName));if(h.target===t&&b&&(u("ANIMATION_END"),!i.current)){const y=t.style.animationFillMode;t.style.animationFillMode="forwards",c=d.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=y)})}},g=h=>{h.target===t&&(o.current=Df(r.current))};return t.addEventListener("animationstart",g),t.addEventListener("animationcancel",p),t.addEventListener("animationend",p),()=>{d.clearTimeout(c),t.removeEventListener("animationstart",g),t.removeEventListener("animationcancel",p),t.removeEventListener("animationend",p)}}else u("ANIMATION_END")},[t,u]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:x.useCallback(c=>{r.current=c?getComputedStyle(c):null,n(c)},[])}}function Df(e){return e?.animationName||"none"}function jH(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function Nd(e){const t=LH(e),n=x.forwardRef((r,i)=>{const{children:o,...a}=r,s=x.Children.toArray(o),u=s.find(FH);if(u){const c=u.props.children,d=s.map(p=>p===u?x.Children.count(c)>1?x.Children.only(null):x.isValidElement(c)?c.props.children:null:p);return P.jsx(t,{...a,ref:i,children:x.isValidElement(c)?x.cloneElement(c,void 0,d):null})}return P.jsx(t,{...a,ref:i,children:o})});return n.displayName=`${e}.Slot`,n}function LH(e){const t=x.forwardRef((n,r)=>{const{children:i,...o}=n;if(x.isValidElement(i)){const a=BH(i),s=VH(o,i.props);return i.type!==x.Fragment&&(s.ref=r?Zb(r,a):a),x.cloneElement(i,s)}return x.Children.count(i)>1?x.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var BR=Symbol("radix.slottable");function $H(e){const t=({children:n})=>P.jsx(P.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=BR,t}function FH(e){return x.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===BR}function VH(e,t){const n={...t};for(const r in t){const i=e[r],o=t[r];/^on[A-Z]/.test(r)?i&&o?n[r]=(...s)=>{const u=o(...s);return i(...s),u}:i&&(n[r]=i):r==="style"?n[r]={...i,...o}:r==="className"&&(n[r]=[i,o].filter(Boolean).join(" "))}return{...e,...n}}function BH(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var zH=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],wt=zH.reduce((e,t)=>{const n=Nd(`Primitive.${t}`),r=x.forwardRef((i,o)=>{const{asChild:a,...s}=i,u=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),P.jsx(u,{...s,ref:o})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function WH(e,t){e&&la.flushSync(()=>e.dispatchEvent(t))}var qp="Checkbox",[HH]=Fi(qp),[UH,e0]=HH(qp);function GH(e){const{__scopeCheckbox:t,checked:n,children:r,defaultChecked:i,disabled:o,form:a,name:s,onCheckedChange:u,required:c,value:d="on",internal_do_not_use_render:p}=e,[g,h]=us({prop:n,defaultProp:i??!1,onChange:u,caller:qp}),[v,b]=x.useState(null),[y,w]=x.useState(null),C=x.useRef(!1),E=v?!!a||!!v.closest("form"):!0,_={checked:g,disabled:o,setChecked:h,control:v,setControl:b,name:s,form:a,value:d,hasConsumerStoppedPropagationRef:C,required:c,defaultChecked:Qo(i)?!1:i,isFormControl:E,bubbleInput:y,setBubbleInput:w};return P.jsx(UH,{scope:t,..._,children:qH(p)?p(_):r})}var zR="CheckboxTrigger",WR=x.forwardRef(({__scopeCheckbox:e,onKeyDown:t,onClick:n,...r},i)=>{const{control:o,value:a,disabled:s,checked:u,required:c,setControl:d,setChecked:p,hasConsumerStoppedPropagationRef:g,isFormControl:h,bubbleInput:v}=e0(zR,e),b=Zt(i,d),y=x.useRef(u);return x.useEffect(()=>{const w=o?.form;if(w){const C=()=>p(y.current);return w.addEventListener("reset",C),()=>w.removeEventListener("reset",C)}},[o,p]),P.jsx(wt.button,{type:"button",role:"checkbox","aria-checked":Qo(u)?"mixed":u,"aria-required":c,"data-state":KR(u),"data-disabled":s?"":void 0,disabled:s,value:a,...r,ref:b,onKeyDown:bt(t,w=>{w.key==="Enter"&&w.preventDefault()}),onClick:bt(n,w=>{p(C=>Qo(C)?!0:!C),v&&h&&(g.current=w.isPropagationStopped(),g.current||w.stopPropagation())})})});WR.displayName=zR;var t0=x.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:r,checked:i,defaultChecked:o,required:a,disabled:s,value:u,onCheckedChange:c,form:d,...p}=e;return P.jsx(GH,{__scopeCheckbox:n,checked:i,defaultChecked:o,disabled:s,required:a,onCheckedChange:c,name:r,form:d,value:u,internal_do_not_use_render:({isFormControl:g})=>P.jsxs(P.Fragment,{children:[P.jsx(WR,{...p,ref:t,__scopeCheckbox:n}),g&&P.jsx(qR,{__scopeCheckbox:n})]})})});t0.displayName=qp;var HR="CheckboxIndicator",UR=x.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...i}=e,o=e0(HR,n);return P.jsx(yo,{present:r||Qo(o.checked)||o.checked===!0,children:P.jsx(wt.span,{"data-state":KR(o.checked),"data-disabled":o.disabled?"":void 0,...i,ref:t,style:{pointerEvents:"none",...e.style}})})});UR.displayName=HR;var GR="CheckboxBubbleInput",qR=x.forwardRef(({__scopeCheckbox:e,...t},n)=>{const{control:r,hasConsumerStoppedPropagationRef:i,checked:o,defaultChecked:a,required:s,disabled:u,name:c,value:d,form:p,bubbleInput:g,setBubbleInput:h}=e0(GR,e),v=Zt(n,h),b=Jb(o),y=Gp(r);x.useEffect(()=>{const C=g;if(!C)return;const E=window.HTMLInputElement.prototype,O=Object.getOwnPropertyDescriptor(E,"checked").set,R=!i.current;if(b!==o&&O){const I=new Event("click",{bubbles:R});C.indeterminate=Qo(o),O.call(C,Qo(o)?!1:o),C.dispatchEvent(I)}},[g,b,o,i]);const w=x.useRef(Qo(o)?!1:o);return P.jsx(wt.input,{type:"checkbox","aria-hidden":!0,defaultChecked:a??w.current,required:s,disabled:u,name:c,value:d,form:p,...t,tabIndex:-1,ref:v,style:{...t.style,...y,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});qR.displayName=GR;function qH(e){return typeof e=="function"}function Qo(e){return e==="indeterminate"}function KR(e){return Qo(e)?"indeterminate":e?"checked":"unchecked"}const YR=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();const KH=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();const YH=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,n,r)=>r?r.toUpperCase():n.toLowerCase());const yS=e=>{const t=YH(e);return t.charAt(0).toUpperCase()+t.slice(1)};var XH={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 ZH=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0;return!1};const QH=j.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:i="",children:o,iconNode:a,...s},u)=>j.createElement("svg",{ref:u,...XH,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:YR("lucide",i),...!o&&!ZH(s)&&{"aria-hidden":"true"},...s},[...a.map(([c,d])=>j.createElement(c,d)),...Array.isArray(o)?o:[o]]));const st=(e,t)=>{const n=j.forwardRef(({className:r,...i},o)=>j.createElement(QH,{ref:o,iconNode:t,className:YR(`lucide-${KH(yS(e))}`,`lucide-${e}`,r),...i}));return n.displayName=yS(e),n};const JH=[["path",{d:"M10.268 21a2 2 0 0 0 3.464 0",key:"vwvbt9"}],["path",{d:"M22 8c0-2.3-.8-4.3-2-6",key:"5bb3ad"}],["path",{d:"M3.262 15.326A1 1 0 0 0 4 17h16a1 1 0 0 0 .74-1.673C19.41 13.956 18 12.499 18 8A6 6 0 0 0 6 8c0 4.499-1.411 5.956-2.738 7.326",key:"11g9vi"}],["path",{d:"M4 2C2.8 3.7 2 5.7 2 8",key:"tap9e0"}]],eU=st("bell-ring",JH);const tU=[["path",{d:"M15 13a3 3 0 1 0-6 0",key:"10j68g"}],["path",{d:"M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H19a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5a1 1 0 0 1 0-5H20",key:"k3hazp"}],["circle",{cx:"12",cy:"8",r:"2",key:"1822b1"}]],nU=st("book-user",tU);const rU=[["path",{d:"M12 12h.01",key:"1mp3jc"}],["path",{d:"M16 6V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v2",key:"1ksdt3"}],["path",{d:"M22 13a18.15 18.15 0 0 1-20 0",key:"12hx5q"}],["rect",{width:"20",height:"14",x:"2",y:"6",rx:"2",key:"i6l2r4"}]],iU=st("briefcase-business",rU);const oU=[["path",{d:"M10 12h4",key:"a56b0p"}],["path",{d:"M10 8h4",key:"1sr2af"}],["path",{d:"M14 21v-3a2 2 0 0 0-4 0v3",key:"1rgiei"}],["path",{d:"M6 10H4a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-2",key:"secmi2"}],["path",{d:"M6 21V5a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v16",key:"16ra0t"}]],aU=st("building-2",oU);const sU=[["path",{d:"M11 14h1v4",key:"fy54vd"}],["path",{d:"M16 2v4",key:"4m81vk"}],["path",{d:"M3 10h18",key:"8toen8"}],["path",{d:"M8 2v4",key:"1cmpym"}],["rect",{x:"3",y:"4",width:"18",height:"18",rx:"2",key:"12vinp"}]],lU=st("calendar-1",sU);const uU=[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"m19 9-5 5-4-4-3 3",key:"2osh9i"}]],cU=st("chart-line",uU);const fU=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],dU=st("chevron-down",fU);const pU=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],XR=st("chevron-left",pU);const hU=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],ZR=st("chevron-right",hU);const gU=[["path",{d:"m7 15 5 5 5-5",key:"1hf1tw"}],["path",{d:"m7 9 5-5 5 5",key:"sgt6xg"}]],mU=st("chevrons-up-down",gU);const vU=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]],yU=st("circle-alert",vU);const bU=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]],xU=st("circle-question-mark",bU);const wU=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 6v6h4",key:"135r8i"}]],CU=st("clock-3",wU);const SU=[["rect",{width:"20",height:"14",x:"2",y:"5",rx:"2",key:"ynyp8z"}],["line",{x1:"2",x2:"22",y1:"10",y2:"10",key:"1b3vmo"}]],EU=st("credit-card",SU);const _U=[["line",{x1:"12",x2:"12",y1:"2",y2:"22",key:"7eqyqh"}],["path",{d:"M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6",key:"1b0p4s"}]],OU=st("dollar-sign",_U);const PU=[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]],QR=st("ellipsis",PU);const AU=[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]],RU=st("eye-off",AU);const IU=[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],TU=st("eye",IU);const kU=[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]],NU=st("folder-open",kU);const MU=[["path",{d:"M10 20a1 1 0 0 0 .553.895l2 1A1 1 0 0 0 14 21v-7a2 2 0 0 1 .517-1.341L21.74 4.67A1 1 0 0 0 21 3H3a1 1 0 0 0-.742 1.67l7.225 7.989A2 2 0 0 1 10 14z",key:"sc7q7i"}]],DU=st("funnel",MU);const jU=[["rect",{width:"7",height:"7",x:"3",y:"3",rx:"1",key:"1g98yp"}],["rect",{width:"7",height:"7",x:"14",y:"3",rx:"1",key:"6d4xhi"}],["rect",{width:"7",height:"7",x:"14",y:"14",rx:"1",key:"nxv5o0"}],["rect",{width:"7",height:"7",x:"3",y:"14",rx:"1",key:"1bb6yr"}]],LU=st("layout-grid",jU);const $U=[["path",{d:"M2 5h20",key:"1fs1ex"}],["path",{d:"M6 12h12",key:"8npq4p"}],["path",{d:"M9 19h6",key:"456am0"}]],FU=st("list-filter",$U);const VU=[["path",{d:"M13 5h8",key:"a7qcls"}],["path",{d:"M13 12h8",key:"h98zly"}],["path",{d:"M13 19h8",key:"c3s6r1"}],["path",{d:"m3 17 2 2 4-4",key:"1jhpwq"}],["rect",{x:"3",y:"4",width:"6",height:"6",rx:"1",key:"cif1o7"}]],BU=st("list-todo",VU);const zU=[["path",{d:"M2.992 16.342a2 2 0 0 1 .094 1.167l-1.065 3.29a1 1 0 0 0 1.236 1.168l3.413-.998a2 2 0 0 1 1.099.092 10 10 0 1 0-4.777-4.719",key:"1sd12s"}]],WU=st("message-circle",zU);const HU=[["path",{d:"M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z",key:"1a0edw"}],["path",{d:"M12 22V12",key:"d0xqtd"}],["polyline",{points:"3.29 7 12 12 20.71 7",key:"ousv84"}],["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}]],UU=st("package",HU);const GU=[["path",{d:"M12 22a1 1 0 0 1 0-20 10 9 0 0 1 10 9 5 5 0 0 1-5 5h-2.25a1.75 1.75 0 0 0-1.4 2.8l.3.4a1.75 1.75 0 0 1-1.4 2.8z",key:"e79jfc"}],["circle",{cx:"13.5",cy:"6.5",r:".5",fill:"currentColor",key:"1okk4w"}],["circle",{cx:"17.5",cy:"10.5",r:".5",fill:"currentColor",key:"f64h9f"}],["circle",{cx:"6.5",cy:"12.5",r:".5",fill:"currentColor",key:"qy21gx"}],["circle",{cx:"8.5",cy:"7.5",r:".5",fill:"currentColor",key:"fotxhn"}]],qU=st("palette",GU);const KU=[["path",{d:"M13.832 16.568a1 1 0 0 0 1.213-.303l.355-.465A2 2 0 0 1 17 15h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2A18 18 0 0 1 2 4a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-.8 1.6l-.468.351a1 1 0 0 0-.292 1.233 14 14 0 0 0 6.392 6.384",key:"9njp5v"}]],YU=st("phone",KU);const XU=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],ZU=st("plus",XU);const QU=[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]],JU=st("rotate-ccw",QU);const eG=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],tG=st("search",eG);const nG=[["path",{d:"M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915",key:"1i5ecw"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],rG=st("settings",nG);const iG=[["path",{d:"M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z",key:"vktsd0"}],["circle",{cx:"7.5",cy:"7.5",r:".5",fill:"currentColor",key:"kqv944"}]],oG=st("tag",iG);const aG=[["path",{d:"M10 15H6a4 4 0 0 0-4 4v2",key:"1nfge6"}],["path",{d:"m14.305 16.53.923-.382",key:"1itpsq"}],["path",{d:"m15.228 13.852-.923-.383",key:"eplpkm"}],["path",{d:"m16.852 12.228-.383-.923",key:"13v3q0"}],["path",{d:"m16.852 17.772-.383.924",key:"1i8mnm"}],["path",{d:"m19.148 12.228.383-.923",key:"1q8j1v"}],["path",{d:"m19.53 18.696-.382-.924",key:"vk1qj3"}],["path",{d:"m20.772 13.852.924-.383",key:"n880s0"}],["path",{d:"m20.772 16.148.924.383",key:"1g6xey"}],["circle",{cx:"18",cy:"15",r:"3",key:"gjjjvw"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]],sG=st("user-cog",aG);const lG=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["path",{d:"M16 3.128a4 4 0 0 1 0 7.744",key:"16gr8j"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]],uG=st("users",lG);const cG=[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z",key:"1ngwbx"}]],fG=st("wrench",cG);const dG=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],pG=st("x",dG);function JR({ref:e,className:t,color:n="currentColor",size:r=24,...i}){return P.jsx("svg",{ref:e,xmlns:"http://www.w3.org/2000/svg",width:r,height:r,fill:"none",stroke:n,strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round",className:t,...i,children:P.jsx("path",{d:"M13.4375 8.125L8.85414 12.5L6.5625 10.3125"})})}function eI({ref:e,className:t,color:n="currentColor",size:r=24,...i}){return P.jsxs("svg",{ref:e,xmlns:"http://www.w3.org/2000/svg",width:r,height:r,fill:"none",stroke:n,strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round",className:t,...i,children:[P.jsx("path",{d:"M13.4375 8.125L8.85414 12.5L6.5625 10.3125"}),P.jsx("path",{d:"M10 17.5C14.1421 17.5 17.5 14.1421 17.5 10C17.5 5.85786 14.1421 2.5 10 2.5C5.85786 2.5 2.5 5.85786 2.5 10C2.5 14.1421 5.85786 17.5 10 17.5Z"})]})}JR.displayName="Check";eI.displayName="CircleCheck";const hG={settings:rG,plus:ZU,wrench:fG,phone:YU,palette:qU,building:aU,close:pG,done:JR,check:eI,users:uG,"layout-grid":LU,bell:eU,"book-user":nU,"user-gear":sG,folder:NU,"briefcase-business":iU,calendar:lU,"chart-line":cU,message:WU,search:tG,"list-filter":FU,funnel:DU,dots:QR,"check-list":BU,tag:oG,chevron:dU,chevrons:mU,"rotate-ccw":JU,question:xU,clock:CU,eye:TU,"eye-off":RU,package:UU,"credit-card":EU,"dollar-sign":OU,"circle-alert":yU},gG={xs:"w-2.5 h-2.5",sm:"w-3.75 h-3.75",md:"w-5 h-5",lg:"w-6.25 h-6.25"},uo=({type:e,size:t="md",viewBox:n="0 0 24 24",strokeWidth:r=1.5,classes:i,color:o,...a})=>{const s=hG[e],u=gG[t],c=ue(u,i?.icon);return P.jsx("div",{...a,className:i?.wrapper,children:P.jsx(s,{viewBox:n,strokeWidth:r,className:c,color:o})})},mG=["peer bg-primary-bg border-inp-default-border grid size-5 shrink-0 cursor-pointer place-content-center rounded border","focus-visible:ring-inp-focus-border focus-visible:ring-1 focus-visible:outline-none","text-transparent transition-all duration-200","disabled:cursor-not-allowed","disabled:border-disabled-border disabled:bg-disabled-bg","disabled:data-[state=checked]:bg-disabled-bg","disabled:data-[state=checked]:border-disabled-border","disabled:data-[state=checked]:text-disabled-text","data-[state=checked]:border-primary-inverse-bg","data-[state=checked]:bg-primary-inverse-bg data-[state=checked]:text-primary-inverse-text","enabled:hover:border-inp-hover-border","enabled:hover:data-[state=checked]:bg-primary-inverse-hover-bg","enabled:hover:data-[state=checked]:border-primary-inverse-hover-bg"].join(" "),vG="grid place-content-center text-current",n0=({className:e,ref:t,...n})=>P.jsx(t0,{ref:t,className:ue(mG,e),...n,children:P.jsx(UR,{className:ue(vG),children:P.jsx(uo,{type:"done",viewBox:"3 3 14 14"})})});n0.displayName=t0.displayName;function mm({controlled:e,default:t,name:n,state:r="value"}){const{current:i}=x.useRef(e!==void 0),[o,a]=x.useState(t),s=i?e:o;if(process.env.NODE_ENV!=="production"){x.useEffect(()=>{i!==(e!==void 0)&&console.error([`Base UI: A component is changing the ${i?"":"un"}controlled ${r} state of ${n} to be ${i?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(`
|
|
13
|
+
hover:shadow-[0_6px_16px_rgba(0,0,0,0.30)]`},active:{true:"",false:""}},defaultVariants:{variant:"light",active:!1},compoundVariants:[{variant:"light",active:!0,class:"bg-tertiary-bg border-default-border shadow-[0_2px_6px_rgba(0,0,0,0.1)]"},{variant:"dark",active:!0,class:"bg-tertiary-inverse-bg shadow-[0_2px_6px_rgba(0,0,0,0.25)]"}]}),AU=St("flex flex-col space-y-1.5 p-6"),RU=St(`group-data-[disabled=true]/card:text-disabled-text leading-none font-semibold
|
|
14
|
+
tracking-tight`),IU=St(`${dn("body-sm-regular")} text-muted-foreground
|
|
15
|
+
group-data-[disabled=true]/card:text-disabled-text`),TU=St("group-data-[disabled=true]/card:text-disabled-text p-6 pt-0"),kU=St("group-data-[disabled=true]/card:text-disabled-text flex items-center p-6 pt-0"),iI=({ref:e,className:t,variant:n,disabled:r,active:i,...o})=>O.jsx("div",{ref:e,"data-disabled":r||void 0,className:ae(PU({variant:n,active:i}),t),...o});iI.displayName="Card";const oI=({ref:e,className:t,...n})=>O.jsx("div",{ref:e,className:ae(AU(),t),...n});oI.displayName="CardHeader";const aI=({ref:e,className:t,...n})=>O.jsx("div",{ref:e,className:ae(RU(),t),...n});aI.displayName="CardTitle";const sI=({ref:e,className:t,...n})=>O.jsx("div",{ref:e,className:ae(IU(),t),...n});sI.displayName="CardDescription";const lI=({ref:e,className:t,...n})=>O.jsx("div",{ref:e,className:ae(TU(),t),...n});lI.displayName="CardContent";const uI=({ref:e,className:t,...n})=>O.jsx("div",{ref:e,className:ae(kU(),t),...n});uI.displayName="CardFooter";function NU(e,t){const n=x.createContext(t),r=o=>{const{children:a,...s}=o,u=x.useMemo(()=>s,Object.values(s));return O.jsx(n.Provider,{value:u,children:a})};r.displayName=e+"Provider";function i(o){const a=x.useContext(n);if(a)return a;if(t!==void 0)return t;throw new Error(`\`${o}\` must be used within \`${e}\``)}return[r,i]}function gi(e,t=[]){let n=[];function r(o,a){const s=x.createContext(a),u=n.length;n=[...n,a];const c=p=>{const{scope:g,children:h,...v}=p,b=g?.[e]?.[u]||s,y=x.useMemo(()=>v,Object.values(v));return O.jsx(b.Provider,{value:y,children:h})};c.displayName=o+"Provider";function f(p,g){const h=g?.[e]?.[u]||s,v=x.useContext(h);if(v)return v;if(a!==void 0)return a;throw new Error(`\`${p}\` must be used within \`${o}\``)}return[c,f]}const i=()=>{const o=n.map(a=>x.createContext(a));return function(s){const u=s?.[e]||o;return x.useMemo(()=>({[`__scope${e}`]:{...s,[e]:u}}),[s,u])}};return i.scopeName=e,[r,MU(i,...t)]}function MU(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(o){const a=r.reduce((s,{useScope:u,scopeName:c})=>{const p=u(o)[`__scope${c}`];return{...s,...p}},{});return x.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function Ke(e,t,{checkForDefaultPrevented:n=!0}={}){return function(i){if(e?.(i),n===!1||!i.defaultPrevented)return t?.(i)}}var Wn=globalThis?.document?x.useLayoutEffect:()=>{},DU=x[" useInsertionEffect ".trim().toString()]||Wn;function go({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[i,o,a]=jU({defaultProp:t,onChange:n}),s=e!==void 0,u=s?e:i;{const f=x.useRef(e!==void 0);x.useEffect(()=>{const p=f.current;p!==s&&console.warn(`${r} is changing from ${p?"controlled":"uncontrolled"} to ${s?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),f.current=s},[s,r])}const c=x.useCallback(f=>{if(s){const p=LU(f)?f(e):f;p!==e&&a.current?.(p)}else o(f)},[s,e,o,a]);return[u,c]}function jU({defaultProp:e,onChange:t}){const[n,r]=x.useState(e),i=x.useRef(n),o=x.useRef(t);return DU(()=>{o.current=t},[t]),x.useEffect(()=>{i.current!==n&&(o.current?.(n),i.current=n)},[n,i]),[n,r,o]}function LU(e){return typeof e=="function"}function eh(e){const t=x.useRef({value:e,previous:e});return x.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}function th(e){const[t,n]=x.useState(void 0);return Wn(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(i=>{if(!Array.isArray(i)||!i.length)return;const o=i[0];let a,s;if("borderBoxSize"in o){const u=o.borderBoxSize,c=Array.isArray(u)?u[0]:u;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 $U(e,t){return x.useReducer((n,r)=>t[n][r]??n,e)}var Co=e=>{const{present:t,children:n}=e,r=FU(t),i=typeof n=="function"?n({present:r.isPresent}):x.Children.only(n),o=bt(r.ref,VU(i));return typeof n=="function"||r.isPresent?x.cloneElement(i,{ref:o}):null};Co.displayName="Presence";function FU(e){const[t,n]=x.useState(),r=x.useRef(null),i=x.useRef(e),o=x.useRef("none"),a=e?"mounted":"unmounted",[s,u]=$U(a,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return x.useEffect(()=>{const c=Wf(r.current);o.current=s==="mounted"?c:"none"},[s]),Wn(()=>{const c=r.current,f=i.current;if(f!==e){const g=o.current,h=Wf(c);e?u("MOUNT"):h==="none"||c?.display==="none"?u("UNMOUNT"):u(f&&g!==h?"ANIMATION_OUT":"UNMOUNT"),i.current=e}},[e,u]),Wn(()=>{if(t){let c;const f=t.ownerDocument.defaultView??window,p=h=>{const b=Wf(r.current).includes(CSS.escape(h.animationName));if(h.target===t&&b&&(u("ANIMATION_END"),!i.current)){const y=t.style.animationFillMode;t.style.animationFillMode="forwards",c=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=y)})}},g=h=>{h.target===t&&(o.current=Wf(r.current))};return t.addEventListener("animationstart",g),t.addEventListener("animationcancel",p),t.addEventListener("animationend",p),()=>{f.clearTimeout(c),t.removeEventListener("animationstart",g),t.removeEventListener("animationcancel",p),t.removeEventListener("animationend",p)}}else u("ANIMATION_END")},[t,u]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:x.useCallback(c=>{r.current=c?getComputedStyle(c):null,n(c)},[])}}function Wf(e){return e?.animationName||"none"}function VU(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function Hu(e){const t=BU(e),n=x.forwardRef((r,i)=>{const{children:o,...a}=r,s=x.Children.toArray(o),u=s.find(WU);if(u){const c=u.props.children,f=s.map(p=>p===u?x.Children.count(c)>1?x.Children.only(null):x.isValidElement(c)?c.props.children:null:p);return O.jsx(t,{...a,ref:i,children:x.isValidElement(c)?x.cloneElement(c,void 0,f):null})}return O.jsx(t,{...a,ref:i,children:o})});return n.displayName=`${e}.Slot`,n}function BU(e){const t=x.forwardRef((n,r)=>{const{children:i,...o}=n;if(x.isValidElement(i)){const a=UU(i),s=HU(o,i.props);return i.type!==x.Fragment&&(s.ref=r?yx(r,a):a),x.cloneElement(i,s)}return x.Children.count(i)>1?x.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var cI=Symbol("radix.slottable");function zU(e){const t=({children:n})=>O.jsx(O.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=cI,t}function WU(e){return x.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===cI}function HU(e,t){const n={...t};for(const r in t){const i=e[r],o=t[r];/^on[A-Z]/.test(r)?i&&o?n[r]=(...s)=>{const u=o(...s);return i(...s),u}:i&&(n[r]=i):r==="style"?n[r]={...i,...o}:r==="className"&&(n[r]=[i,o].filter(Boolean).join(" "))}return{...e,...n}}function UU(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var GU=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Qe=GU.reduce((e,t)=>{const n=Hu(`Primitive.${t}`),r=x.forwardRef((i,o)=>{const{asChild:a,...s}=i,u=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),O.jsx(u,{...s,ref:o})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function qU(e,t){e&&Wi.flushSync(()=>e.dispatchEvent(t))}var nh="Checkbox",[KU]=gi(nh),[YU,xx]=KU(nh);function XU(e){const{__scopeCheckbox:t,checked:n,children:r,defaultChecked:i,disabled:o,form:a,name:s,onCheckedChange:u,required:c,value:f="on",internal_do_not_use_render:p}=e,[g,h]=go({prop:n,defaultProp:i??!1,onChange:u,caller:nh}),[v,b]=x.useState(null),[y,w]=x.useState(null),S=x.useRef(!1),E=v?!!a||!!v.closest("form"):!0,_={checked:g,disabled:o,setChecked:h,control:v,setControl:b,name:s,form:a,value:f,hasConsumerStoppedPropagationRef:S,required:c,defaultChecked:ra(i)?!1:i,isFormControl:E,bubbleInput:y,setBubbleInput:w};return O.jsx(YU,{scope:t,..._,children:ZU(p)?p(_):r})}var fI="CheckboxTrigger",dI=x.forwardRef(({__scopeCheckbox:e,onKeyDown:t,onClick:n,...r},i)=>{const{control:o,value:a,disabled:s,checked:u,required:c,setControl:f,setChecked:p,hasConsumerStoppedPropagationRef:g,isFormControl:h,bubbleInput:v}=xx(fI,e),b=bt(i,f),y=x.useRef(u);return x.useEffect(()=>{const w=o?.form;if(w){const S=()=>p(y.current);return w.addEventListener("reset",S),()=>w.removeEventListener("reset",S)}},[o,p]),O.jsx(Qe.button,{type:"button",role:"checkbox","aria-checked":ra(u)?"mixed":u,"aria-required":c,"data-state":vI(u),"data-disabled":s?"":void 0,disabled:s,value:a,...r,ref:b,onKeyDown:Ke(t,w=>{w.key==="Enter"&&w.preventDefault()}),onClick:Ke(n,w=>{p(S=>ra(S)?!0:!S),v&&h&&(g.current=w.isPropagationStopped(),g.current||w.stopPropagation())})})});dI.displayName=fI;var wx=x.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:r,checked:i,defaultChecked:o,required:a,disabled:s,value:u,onCheckedChange:c,form:f,...p}=e;return O.jsx(XU,{__scopeCheckbox:n,checked:i,defaultChecked:o,disabled:s,required:a,onCheckedChange:c,name:r,form:f,value:u,internal_do_not_use_render:({isFormControl:g})=>O.jsxs(O.Fragment,{children:[O.jsx(dI,{...p,ref:t,__scopeCheckbox:n}),g&&O.jsx(mI,{__scopeCheckbox:n})]})})});wx.displayName=nh;var pI="CheckboxIndicator",hI=x.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...i}=e,o=xx(pI,n);return O.jsx(Co,{present:r||ra(o.checked)||o.checked===!0,children:O.jsx(Qe.span,{"data-state":vI(o.checked),"data-disabled":o.disabled?"":void 0,...i,ref:t,style:{pointerEvents:"none",...e.style}})})});hI.displayName=pI;var gI="CheckboxBubbleInput",mI=x.forwardRef(({__scopeCheckbox:e,...t},n)=>{const{control:r,hasConsumerStoppedPropagationRef:i,checked:o,defaultChecked:a,required:s,disabled:u,name:c,value:f,form:p,bubbleInput:g,setBubbleInput:h}=xx(gI,e),v=bt(n,h),b=eh(o),y=th(r);x.useEffect(()=>{const S=g;if(!S)return;const E=window.HTMLInputElement.prototype,P=Object.getOwnPropertyDescriptor(E,"checked").set,R=!i.current;if(b!==o&&P){const I=new Event("click",{bubbles:R});S.indeterminate=ra(o),P.call(S,ra(o)?!1:o),S.dispatchEvent(I)}},[g,b,o,i]);const w=x.useRef(ra(o)?!1:o);return O.jsx(Qe.input,{type:"checkbox","aria-hidden":!0,defaultChecked:a??w.current,required:s,disabled:u,name:c,value:f,form:p,...t,tabIndex:-1,ref:v,style:{...t.style,...y,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});mI.displayName=gI;function ZU(e){return typeof e=="function"}function ra(e){return e==="indeterminate"}function vI(e){return ra(e)?"indeterminate":e?"checked":"unchecked"}const yI=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();const QU=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();const JU=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,n,r)=>r?r.toUpperCase():n.toLowerCase());const $C=e=>{const t=JU(e);return t.charAt(0).toUpperCase()+t.slice(1)};var eG={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 tG=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0;return!1};const nG=$.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:i="",children:o,iconNode:a,...s},u)=>$.createElement("svg",{ref:u,...eG,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:yI("lucide",i),...!o&&!tG(s)&&{"aria-hidden":"true"},...s},[...a.map(([c,f])=>$.createElement(c,f)),...Array.isArray(o)?o:[o]]));const st=(e,t)=>{const n=$.forwardRef(({className:r,...i},o)=>$.createElement(nG,{ref:o,iconNode:t,className:yI(`lucide-${QU($C(e))}`,`lucide-${e}`,r),...i}));return n.displayName=$C(e),n};const rG=[["path",{d:"M10.268 21a2 2 0 0 0 3.464 0",key:"vwvbt9"}],["path",{d:"M22 8c0-2.3-.8-4.3-2-6",key:"5bb3ad"}],["path",{d:"M3.262 15.326A1 1 0 0 0 4 17h16a1 1 0 0 0 .74-1.673C19.41 13.956 18 12.499 18 8A6 6 0 0 0 6 8c0 4.499-1.411 5.956-2.738 7.326",key:"11g9vi"}],["path",{d:"M4 2C2.8 3.7 2 5.7 2 8",key:"tap9e0"}]],iG=st("bell-ring",rG);const oG=[["path",{d:"M15 13a3 3 0 1 0-6 0",key:"10j68g"}],["path",{d:"M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H19a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5a1 1 0 0 1 0-5H20",key:"k3hazp"}],["circle",{cx:"12",cy:"8",r:"2",key:"1822b1"}]],aG=st("book-user",oG);const sG=[["path",{d:"M12 12h.01",key:"1mp3jc"}],["path",{d:"M16 6V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v2",key:"1ksdt3"}],["path",{d:"M22 13a18.15 18.15 0 0 1-20 0",key:"12hx5q"}],["rect",{width:"20",height:"14",x:"2",y:"6",rx:"2",key:"i6l2r4"}]],lG=st("briefcase-business",sG);const uG=[["path",{d:"M10 12h4",key:"a56b0p"}],["path",{d:"M10 8h4",key:"1sr2af"}],["path",{d:"M14 21v-3a2 2 0 0 0-4 0v3",key:"1rgiei"}],["path",{d:"M6 10H4a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-2",key:"secmi2"}],["path",{d:"M6 21V5a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v16",key:"16ra0t"}]],cG=st("building-2",uG);const fG=[["path",{d:"M11 14h1v4",key:"fy54vd"}],["path",{d:"M16 2v4",key:"4m81vk"}],["path",{d:"M3 10h18",key:"8toen8"}],["path",{d:"M8 2v4",key:"1cmpym"}],["rect",{x:"3",y:"4",width:"18",height:"18",rx:"2",key:"12vinp"}]],dG=st("calendar-1",fG);const pG=[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"m19 9-5 5-4-4-3 3",key:"2osh9i"}]],hG=st("chart-line",pG);const gG=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],mG=st("chevron-down",gG);const vG=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],bI=st("chevron-left",vG);const yG=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],xI=st("chevron-right",yG);const bG=[["path",{d:"m7 15 5 5 5-5",key:"1hf1tw"}],["path",{d:"m7 9 5-5 5 5",key:"sgt6xg"}]],xG=st("chevrons-up-down",bG);const wG=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]],SG=st("circle-alert",wG);const CG=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]],EG=st("circle-question-mark",CG);const _G=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 6v6h4",key:"135r8i"}]],OG=st("clock-3",_G);const PG=[["rect",{width:"20",height:"14",x:"2",y:"5",rx:"2",key:"ynyp8z"}],["line",{x1:"2",x2:"22",y1:"10",y2:"10",key:"1b3vmo"}]],AG=st("credit-card",PG);const RG=[["line",{x1:"12",x2:"12",y1:"2",y2:"22",key:"7eqyqh"}],["path",{d:"M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6",key:"1b0p4s"}]],IG=st("dollar-sign",RG);const TG=[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]],wI=st("ellipsis",TG);const kG=[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]],NG=st("eye-off",kG);const MG=[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],DG=st("eye",MG);const jG=[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]],LG=st("folder-open",jG);const $G=[["path",{d:"M10 20a1 1 0 0 0 .553.895l2 1A1 1 0 0 0 14 21v-7a2 2 0 0 1 .517-1.341L21.74 4.67A1 1 0 0 0 21 3H3a1 1 0 0 0-.742 1.67l7.225 7.989A2 2 0 0 1 10 14z",key:"sc7q7i"}]],FG=st("funnel",$G);const VG=[["rect",{width:"7",height:"7",x:"3",y:"3",rx:"1",key:"1g98yp"}],["rect",{width:"7",height:"7",x:"14",y:"3",rx:"1",key:"6d4xhi"}],["rect",{width:"7",height:"7",x:"14",y:"14",rx:"1",key:"nxv5o0"}],["rect",{width:"7",height:"7",x:"3",y:"14",rx:"1",key:"1bb6yr"}]],BG=st("layout-grid",VG);const zG=[["path",{d:"M2 5h20",key:"1fs1ex"}],["path",{d:"M6 12h12",key:"8npq4p"}],["path",{d:"M9 19h6",key:"456am0"}]],WG=st("list-filter",zG);const HG=[["path",{d:"M13 5h8",key:"a7qcls"}],["path",{d:"M13 12h8",key:"h98zly"}],["path",{d:"M13 19h8",key:"c3s6r1"}],["path",{d:"m3 17 2 2 4-4",key:"1jhpwq"}],["rect",{x:"3",y:"4",width:"6",height:"6",rx:"1",key:"cif1o7"}]],UG=st("list-todo",HG);const GG=[["circle",{cx:"12",cy:"16",r:"1",key:"1au0dj"}],["rect",{x:"3",y:"10",width:"18",height:"12",rx:"2",key:"6s8ecr"}],["path",{d:"M7 10V7a5 5 0 0 1 10 0v3",key:"1pqi11"}]],qG=st("lock-keyhole",GG);const KG=[["path",{d:"M2.992 16.342a2 2 0 0 1 .094 1.167l-1.065 3.29a1 1 0 0 0 1.236 1.168l3.413-.998a2 2 0 0 1 1.099.092 10 10 0 1 0-4.777-4.719",key:"1sd12s"}]],YG=st("message-circle",KG);const XG=[["path",{d:"M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z",key:"1a0edw"}],["path",{d:"M12 22V12",key:"d0xqtd"}],["polyline",{points:"3.29 7 12 12 20.71 7",key:"ousv84"}],["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}]],ZG=st("package",XG);const QG=[["path",{d:"M12 22a1 1 0 0 1 0-20 10 9 0 0 1 10 9 5 5 0 0 1-5 5h-2.25a1.75 1.75 0 0 0-1.4 2.8l.3.4a1.75 1.75 0 0 1-1.4 2.8z",key:"e79jfc"}],["circle",{cx:"13.5",cy:"6.5",r:".5",fill:"currentColor",key:"1okk4w"}],["circle",{cx:"17.5",cy:"10.5",r:".5",fill:"currentColor",key:"f64h9f"}],["circle",{cx:"6.5",cy:"12.5",r:".5",fill:"currentColor",key:"qy21gx"}],["circle",{cx:"8.5",cy:"7.5",r:".5",fill:"currentColor",key:"fotxhn"}]],JG=st("palette",QG);const e4=[["path",{d:"M13.832 16.568a1 1 0 0 0 1.213-.303l.355-.465A2 2 0 0 1 17 15h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2A18 18 0 0 1 2 4a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-.8 1.6l-.468.351a1 1 0 0 0-.292 1.233 14 14 0 0 0 6.392 6.384",key:"9njp5v"}]],t4=st("phone",e4);const n4=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],r4=st("plus",n4);const i4=[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]],o4=st("rotate-ccw",i4);const a4=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],s4=st("search",a4);const l4=[["path",{d:"M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915",key:"1i5ecw"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],u4=st("settings",l4);const c4=[["path",{d:"M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z",key:"vktsd0"}],["circle",{cx:"7.5",cy:"7.5",r:".5",fill:"currentColor",key:"kqv944"}]],f4=st("tag",c4);const d4=[["path",{d:"M10 15H6a4 4 0 0 0-4 4v2",key:"1nfge6"}],["path",{d:"m14.305 16.53.923-.382",key:"1itpsq"}],["path",{d:"m15.228 13.852-.923-.383",key:"eplpkm"}],["path",{d:"m16.852 12.228-.383-.923",key:"13v3q0"}],["path",{d:"m16.852 17.772-.383.924",key:"1i8mnm"}],["path",{d:"m19.148 12.228.383-.923",key:"1q8j1v"}],["path",{d:"m19.53 18.696-.382-.924",key:"vk1qj3"}],["path",{d:"m20.772 13.852.924-.383",key:"n880s0"}],["path",{d:"m20.772 16.148.924.383",key:"1g6xey"}],["circle",{cx:"18",cy:"15",r:"3",key:"gjjjvw"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]],p4=st("user-cog",d4);const h4=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["path",{d:"M16 3.128a4 4 0 0 1 0 7.744",key:"16gr8j"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]],g4=st("users",h4);const m4=[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z",key:"1ngwbx"}]],v4=st("wrench",m4);const y4=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],b4=st("x",y4);function SI({ref:e,className:t,color:n="currentColor",size:r=24,...i}){return O.jsx("svg",{ref:e,xmlns:"http://www.w3.org/2000/svg",width:r,height:r,fill:"none",stroke:n,strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round",className:t,...i,children:O.jsx("path",{d:"M13.4375 8.125L8.85414 12.5L6.5625 10.3125"})})}function CI({ref:e,className:t,color:n="currentColor",size:r=24,...i}){return O.jsxs("svg",{ref:e,xmlns:"http://www.w3.org/2000/svg",width:r,height:r,fill:"none",stroke:n,strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round",className:t,...i,children:[O.jsx("path",{d:"M13.4375 8.125L8.85414 12.5L6.5625 10.3125"}),O.jsx("path",{d:"M10 17.5C14.1421 17.5 17.5 14.1421 17.5 10C17.5 5.85786 14.1421 2.5 10 2.5C5.85786 2.5 2.5 5.85786 2.5 10C2.5 14.1421 5.85786 17.5 10 17.5Z"})]})}SI.displayName="Check";CI.displayName="CircleCheck";const x4={settings:u4,plus:r4,wrench:v4,phone:t4,palette:JG,building:cG,close:b4,done:SI,check:CI,users:g4,"layout-grid":BG,bell:iG,"book-user":aG,"user-gear":p4,folder:LG,"briefcase-business":lG,calendar:dG,"chart-line":hG,message:YG,search:s4,"list-filter":WG,funnel:FG,dots:wI,"check-list":UG,tag:f4,chevron:mG,chevrons:xG,"rotate-ccw":o4,question:EG,clock:OG,eye:DG,"eye-off":NG,package:ZG,"credit-card":AG,"dollar-sign":IG,"circle-alert":SG,"lock-keyhole":qG},w4={xs:"w-2.5 h-2.5",sm:"w-3.75 h-3.75",md:"w-5 h-5",lg:"w-6.25 h-6.25"},ji=({type:e,size:t="md",viewBox:n="0 0 24 24",strokeWidth:r=1.5,classes:i,color:o,...a})=>{const s=x4[e],u=w4[t],c=ae(u,i?.icon);return O.jsx("div",{...a,className:i?.wrapper,children:O.jsx(s,{viewBox:n,strokeWidth:r,className:c,color:o})})},S4=["peer bg-primary-bg border-inp-default-border grid size-5 shrink-0 cursor-pointer place-content-center rounded border","focus-visible:ring-inp-focus-border focus-visible:ring-1 focus-visible:outline-none","text-transparent transition-all duration-200","disabled:cursor-not-allowed","disabled:border-disabled-border disabled:bg-disabled-bg","disabled:data-[state=checked]:bg-disabled-bg","disabled:data-[state=checked]:border-disabled-border","disabled:data-[state=checked]:text-disabled-text","data-[state=checked]:border-primary-inverse-bg","data-[state=checked]:bg-primary-inverse-bg data-[state=checked]:text-primary-inverse-text","enabled:hover:border-inp-hover-border","enabled:hover:data-[state=checked]:bg-primary-inverse-hover-bg","enabled:hover:data-[state=checked]:border-primary-inverse-hover-bg"].join(" "),C4="grid place-content-center text-current",Sx=({className:e,ref:t,...n})=>O.jsx(wx,{ref:t,className:ae(S4,e),...n,children:O.jsx(hI,{className:ae(C4),children:O.jsx(ji,{type:"done",viewBox:"3 3 14 14"})})});Sx.displayName=wx.displayName;function km({controlled:e,default:t,name:n,state:r="value"}){const{current:i}=x.useRef(e!==void 0),[o,a]=x.useState(t),s=i?e:o;if(process.env.NODE_ENV!=="production"){x.useEffect(()=>{i!==(e!==void 0)&&console.error([`Base UI: A component is changing the ${i?"":"un"}controlled ${r} state of ${n} to be ${i?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(`
|
|
16
16
|
`))},[r,n,e]);const{current:c}=x.useRef(t);x.useEffect(()=>{!i&&JSON.stringify(c)!==JSON.stringify(t)&&console.error([`Base UI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(`
|
|
17
|
-
`))},[JSON.stringify(t)])}const u=x.useCallback(c=>{i||a(c)},[]);return[s,u]}const
|
|
18
|
-
`));return x.cloneElement(o,i)}if(e&&typeof e=="string")return UG(e,n);throw new Error(process.env.NODE_ENV!=="production"?"Base UI: Render element or function are not defined.":pi(8))}function UG(e,t){return e==="button"?j.createElement("button",{type:"button",...t,key:t.key}):e==="img"?j.createElement("img",{alt:"",...t,key:t.key}):x.createElement(e,t)}const Yr="none",Sy="trigger-press",GG="trigger-hover",o0="outside-press",qG="item-press",wS="clear-press",KG="chip-remove-press",Js="input-change",Uo="input-clear",YG="input-press",Kp="focus-out",uI="escape-key",Ru="list-navigation";function Xe(e,t,n,r){let i=!1,o=!1;const a=Xn;return{reason:e,event:t??new Event("base-ui"),cancel(){i=!0},allowPropagation(){o=!0},get isCanceled(){return i},get isPropagationAllowed(){return o},trigger:n,...a}}function su(e,t,n){const r=n??Xn;return{reason:e,event:t??new Event("base-ui"),...r}}const Ey={...x};let CS=0;function XG(e,t="mui"){const[n,r]=x.useState(e),i=e||n;return x.useEffect(()=>{n==null&&(CS+=1,r(`${t}-${CS}`))},[n,t]),i}const SS=Ey.useId;function a0(e,t){if(SS!==void 0){const n=SS();return e??(t?`${t}-${n}`:n)}return XG(e,t)}function s0(e){return a0(e,"base-ui")}const ZG=[];function cI(e){x.useEffect(e,ZG)}const Lf=null;let ES=globalThis.requestAnimationFrame;class QG{callbacks=[];callbacksCount=0;nextId=1;startId=1;isScheduled=!1;tick=t=>{this.isScheduled=!1;const n=this.callbacks,r=this.callbacksCount;if(this.callbacks=[],this.callbacksCount=0,this.startId=this.nextId,r>0)for(let i=0;i<n.length;i+=1)n[i]?.(t)};request(t){const n=this.nextId;this.nextId+=1,this.callbacks.push(t),this.callbacksCount+=1;const r=process.env.NODE_ENV!=="production"&&ES!==requestAnimationFrame&&(ES=requestAnimationFrame,!0);return(!this.isScheduled||r)&&(requestAnimationFrame(this.tick),this.isScheduled=!0),n}cancel(t){const n=t-this.startId;n<0||n>=this.callbacks.length||(this.callbacks[n]=null,this.callbacksCount-=1)}}const $f=new QG;class Oi{static create(){return new Oi}static request(t){return $f.request(t)}static cancel(t){return $f.cancel(t)}currentId=Lf;request(t){this.cancel(),this.currentId=$f.request(()=>{this.currentId=Lf,t()})}cancel=()=>{this.currentId!==Lf&&($f.cancel(this.currentId),this.currentId=Lf)};disposeEffect=()=>this.cancel}function l0(){const e=ei(Oi.create).current;return cI(e.disposeEffect),e}function Qi(e){return e==null?e:"current"in e?e.current:e}let $u=(function(e){return e.startingStyle="data-starting-style",e.endingStyle="data-ending-style",e})({});const JG={[$u.startingStyle]:""},e4={[$u.endingStyle]:""},fI={transitionStatus(e){return e==="starting"?JG:e==="ending"?e4:null}};function t4(e,t=!1,n=!0){const r=l0();return Me((i,o=null)=>{r.cancel();function a(){la.flushSync(i)}const s=Qi(e);if(s==null)return;const u=s;if(typeof u.getAnimations!="function"||globalThis.BASE_UI_ANIMATIONS_DISABLED)i();else{let c=function(){const p=$u.startingStyle;if(!u.hasAttribute(p)){r.request(d);return}const g=new MutationObserver(()=>{u.hasAttribute(p)||(g.disconnect(),d())});g.observe(u,{attributes:!0,attributeFilter:[p]}),o?.addEventListener("abort",()=>g.disconnect(),{once:!0})},d=function(){Promise.all(u.getAnimations().map(p=>p.finished)).then(()=>{o?.aborted||a()}).catch(()=>{const p=u.getAnimations();if(n){if(o?.aborted)return;a()}else p.length>0&&p.some(g=>g.pending||g.playState!=="finished")&&d()})};if(t){c();return}r.request(d)}})}function dI(e,t=!1,n=!1){const[r,i]=x.useState(e&&t?"idle":void 0),[o,a]=x.useState(e);return e&&!o&&(a(!0),i("starting")),!e&&o&&r!=="ending"&&!n&&i("ending"),!e&&!o&&r==="ending"&&i(void 0),je(()=>{if(!e&&o&&r!=="ending"&&n){const s=Oi.request(()=>{i("ending")});return()=>{Oi.cancel(s)}}},[e,o,r,n]),je(()=>{if(!e||t)return;const s=Oi.request(()=>{i(void 0)});return()=>{Oi.cancel(s)}},[t,e]),je(()=>{if(!e||!t)return;e&&o&&r!=="idle"&&i("starting");const s=Oi.request(()=>{i("idle")});return()=>{Oi.cancel(s)}},[t,e,o,i,r]),x.useMemo(()=>({mounted:o,setMounted:a,transitionStatus:r}),[o,r])}let pI=(function(e){return e[e.None=0]="None",e[e.GuessFromOrder=1]="GuessFromOrder",e})({});function hI(e={}){const{label:t,metadata:n,textRef:r,indexGuessBehavior:i,index:o}=e,{register:a,unregister:s,subscribeMapChange:u,elementsRef:c,labelsRef:d,nextIndexRef:p}=CG(),g=x.useRef(-1),[h,v]=x.useState(o??(i===pI.GuessFromOrder?()=>{if(g.current===-1){const w=p.current;p.current+=1,g.current=w}return g.current}:-1)),b=x.useRef(null),y=x.useCallback(w=>{if(b.current=w,h!==-1&&w!==null&&(c.current[h]=w,d)){const C=t!==void 0;d.current[h]=C?t:r?.current?.textContent??w.textContent}},[h,c,d,t,r]);return je(()=>{if(o!=null)return;const w=b.current;if(w)return a(w,n),()=>{s(w)}},[o,a,s,n]),je(()=>{if(o==null)return u(w=>{const C=b.current?w.get(b.current)?.index:null;C!=null&&v(C)})},[o,u,v]),x.useMemo(()=>({ref:y,index:h}),[h,y])}function Yp(){return typeof window<"u"}function ca(e){return u0(e)?(e.nodeName||"").toLowerCase():"#document"}function Nn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Vi(e){var t;return(t=(u0(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function u0(e){return Yp()?e instanceof Node||e instanceof Nn(e).Node:!1}function Lt(e){return Yp()?e instanceof Element||e instanceof Nn(e).Element:!1}function nn(e){return Yp()?e instanceof HTMLElement||e instanceof Nn(e).HTMLElement:!1}function _y(e){return!Yp()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Nn(e).ShadowRoot}function fa(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=Rr(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&i!=="inline"&&i!=="contents"}function n4(e){return/^(table|td|th)$/.test(ca(e))}function Xp(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}const r4=/transform|translate|scale|rotate|perspective|filter/,i4=/paint|layout|strict|content/,ka=e=>!!e&&e!=="none";let ym;function c0(e){const t=Lt(e)?Rr(e):e;return ka(t.transform)||ka(t.translate)||ka(t.scale)||ka(t.rotate)||ka(t.perspective)||!Zp()&&(ka(t.backdropFilter)||ka(t.filter))||r4.test(t.willChange||"")||i4.test(t.contain||"")}function o4(e){let t=co(e);for(;nn(t)&&!ao(t);){if(c0(t))return t;if(Xp(t))return null;t=co(t)}return null}function Zp(){return ym==null&&(ym=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),ym}function ao(e){return/^(html|body|#document)$/.test(ca(e))}function Rr(e){return Nn(e).getComputedStyle(e)}function Qp(e){return Lt(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function co(e){if(ca(e)==="html")return e;const t=e.assignedSlot||e.parentNode||_y(e)&&e.host||Vi(e);return _y(t)?t.host:t}function gI(e){const t=co(e);return ao(t)?e.ownerDocument?e.ownerDocument.body:e.body:nn(t)&&fa(t)?t:gI(t)}function Jo(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const i=gI(e),o=i===((r=e.ownerDocument)==null?void 0:r.body),a=Nn(i);if(o){const s=Oy(a);return t.concat(a,a.visualViewport||[],fa(i)?i:[],s&&n?Jo(s):[])}else return t.concat(i,Jo(i,[],n))}function Oy(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}let Py;process.env.NODE_ENV!=="production"&&(Py=new Set);function _S(...e){if(process.env.NODE_ENV!=="production"){const t=e.join(" ");Py.has(t)||(Py.add(t),console.error(`Base UI: ${t}`))}}const mI=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(mI.displayName="CompositeRootContext");function a4(e=!1){const t=x.useContext(mI);if(t===void 0&&!e)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: CompositeRootContext is missing. Composite parts must be placed within <Composite.Root>.":pi(16));return t}function s4(e){const{focusableWhenDisabled:t,disabled:n,composite:r=!1,tabIndex:i=0,isNativeButton:o}=e,a=r&&t!==!1,s=r&&t===!1;return{props:x.useMemo(()=>{const c={onKeyDown(d){n&&t&&d.key!=="Tab"&&d.preventDefault()}};return r||(c.tabIndex=i,!o&&n&&(c.tabIndex=t?i:-1)),(o&&(t||a)||!o&&n)&&(c["aria-disabled"]=n),o&&(!t||s)&&(c.disabled=n),c},[r,n,t,a,s,o,i])}}function Jp(e={}){const{disabled:t=!1,focusableWhenDisabled:n,tabIndex:r=0,native:i=!0}=e,o=x.useRef(null),a=a4(!0)!==void 0,s=Me(()=>{const g=o.current;return!!(g?.tagName==="A"&&g?.href)}),{props:u}=s4({focusableWhenDisabled:n,disabled:t,composite:a,tabIndex:r,isNativeButton:i});process.env.NODE_ENV!=="production"&&x.useEffect(()=>{if(!o.current)return;const g=o.current.tagName==="BUTTON";if(i){if(!g){const h=Ey.captureOwnerStack?.()||"";_S(`A component that acts as a button expected a native <button> because the \`nativeButton\` prop is true. Rendering a non-<button> removes native button semantics, which can impact forms and accessibility. Use a real <button> in the \`render\` prop, or set \`nativeButton\` to \`false\`.${h}`)}}else if(g){const h=Ey.captureOwnerStack?.()||"";_S(`A component that acts as a button expected a non-<button> because the \`nativeButton\` prop is false. Rendering a <button> keeps native behavior while Base UI applies non-native attributes and handlers, which can add unintended extra attributes (such as \`role\` or \`aria-disabled\`). Use a non-<button> in the \`render\` prop, or set \`nativeButton\` to \`true\`.${h}`)}},[i]);const c=x.useCallback(()=>{const g=o.current;l4(g)&&a&&t&&u.disabled===void 0&&g.disabled&&(g.disabled=!1)},[t,u.disabled,a]);je(c,[c]);const d=x.useCallback((g={})=>{const{onClick:h,onMouseDown:v,onKeyUp:b,onKeyDown:y,onPointerDown:w,...C}=g;return aI({type:i?"button":void 0,onClick(_){if(t){_.preventDefault();return}h?.(_)},onMouseDown(_){t||v?.(_)},onKeyDown(_){if(t||(Cy(_),y?.(_)),_.baseUIHandlerPrevented)return;const O=_.target===_.currentTarget&&!i&&!s()&&!t,R=_.key==="Enter",I=_.key===" ";O&&((I||R)&&_.preventDefault(),R&&h?.(_))},onKeyUp(_){t||(Cy(_),b?.(_)),!_.baseUIHandlerPrevented&&_.target===_.currentTarget&&!i&&!t&&_.key===" "&&h?.(_)},onPointerDown(_){if(t){_.preventDefault();return}w?.(_)}},i?void 0:{role:"button"},u,C)},[t,u,i,s]),p=Me(g=>{o.current=g,c()});return{getButtonProps:d,buttonRef:p}}function l4(e){return nn(e)&&e.tagName==="BUTTON"}const cs=typeof navigator<"u",bm=f4(),vI=p4(),f0=d4(),yI=typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter:none"),bI=bm.platform==="MacIntel"&&bm.maxTouchPoints>1?!0:/iP(hone|ad|od)|iOS/.test(bm.platform),OS=cs&&/firefox/i.test(f0),u4=cs&&/apple/i.test(navigator.vendor),Md=cs&&/android/i.test(vI)||/android/i.test(f0);cs&&vI.toLowerCase().startsWith("mac")&&navigator.maxTouchPoints;const c4=f0.includes("jsdom/");function f4(){if(!cs)return{platform:"",maxTouchPoints:-1};const e=navigator.userAgentData;return e?.platform?{platform:e.platform,maxTouchPoints:navigator.maxTouchPoints}:{platform:navigator.platform??"",maxTouchPoints:navigator.maxTouchPoints??-1}}function d4(){if(!cs)return"";const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map(({brand:t,version:n})=>`${t}/${n}`).join(" "):navigator.userAgent}function p4(){if(!cs)return"";const e=navigator.userAgentData;return e?.platform?e.platform:navigator.platform??""}const Ay="data-base-ui-focusable",xI="active",wI="selected",h4="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])",ea="ArrowLeft",ta="ArrowRight",d0="ArrowUp",rc="ArrowDown";function eo(e){let t=e.activeElement;for(;t?.shadowRoot?.activeElement!=null;)t=t.shadowRoot.activeElement;return t}function ft(e,t){if(!e||!t)return!1;const n=t.getRootNode?.();if(e.contains(t))return!0;if(n&&_y(n)){let r=t;for(;r;){if(e===r)return!0;r=r.parentNode||r.host}}return!1}function lr(e){return"composedPath"in e?e.composedPath()[0]:e.target}function li(e,t){if(t==null)return!1;if("composedPath"in e)return e.composedPath().includes(t);const n=e;return n.target!=null&&t.contains(n.target)}function g4(e){return e.matches("html,body")}function p0(e){return nn(e)&&e.matches(h4)}function Ry(e){return e?e.getAttribute("role")==="combobox"&&p0(e):!1}function Iy(e){return e?e.hasAttribute(Ay)?e:e.querySelector(`[${Ay}]`)||e:null}function il(e,t,n=!0){return e.filter(i=>i.parentId===t&&(!n||i.context?.open)).flatMap(i=>[i,...il(e,i.id,n)])}function PS(e,t){let n=[],r=e.find(i=>i.id===t)?.parentId;for(;r;){const i=e.find(o=>o.id===r);r=i?.parentId,i&&(n=n.concat(i))}return n}function jt(e){e.preventDefault(),e.stopPropagation()}function m4(e){return"nativeEvent"in e}function CI(e){return e.pointerType===""&&e.isTrusted?!0:Md&&e.pointerType?e.type==="click"&&e.buttons===1:e.detail===0&&!e.pointerType}function SI(e){return c4?!1:!Md&&e.width===0&&e.height===0||Md&&e.width===1&&e.height===1&&e.pressure===0&&e.detail===0&&e.pointerType==="mouse"||e.width<1&&e.height<1&&e.pressure===0&&e.detail===0&&e.pointerType==="touch"}function AS(e,t){return["mouse","pen"].includes(e)}function EI(e){const t=e.type;return t==="click"||t==="mousedown"||t==="keydown"||t==="keyup"}const v4=["top","right","bottom","left"],oa=Math.min,Er=Math.max,Dd=Math.round,el=Math.floor,Ii=e=>({x:e,y:e}),y4={left:"right",right:"left",bottom:"top",top:"bottom"};function jd(e,t,n){return Er(e,oa(t,n))}function Ni(e,t){return typeof e=="function"?e(t):e}function Ar(e){return e.split("-")[0]}function bo(e){return e.split("-")[1]}function h0(e){return e==="x"?"y":"x"}function eh(e){return e==="y"?"height":"width"}function Zr(e){const t=e[0];return t==="t"||t==="b"?"y":"x"}function th(e){return h0(Zr(e))}function b4(e,t,n){n===void 0&&(n=!1);const r=bo(e),i=th(e),o=eh(i);let a=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[o]>t.floating[o]&&(a=Ld(a)),[a,Ld(a)]}function x4(e){const t=Ld(e);return[Ty(e),t,Ty(t)]}function Ty(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}const RS=["left","right"],IS=["right","left"],w4=["top","bottom"],C4=["bottom","top"];function S4(e,t,n){switch(e){case"top":case"bottom":return n?t?IS:RS:t?RS:IS;case"left":case"right":return t?w4:C4;default:return[]}}function E4(e,t,n,r){const i=bo(e);let o=S4(Ar(e),n==="start",r);return i&&(o=o.map(a=>a+"-"+i),t&&(o=o.concat(o.map(Ty)))),o}function Ld(e){const t=Ar(e);return y4[t]+e.slice(t.length)}function _4(e){return{top:0,right:0,bottom:0,left:0,...e}}function g0(e){return typeof e!="number"?_4(e):{top:e,right:e,bottom:e,left:e}}function $d(e){const{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function Ff(e,t,n){return Math.floor(e/t)!==n}function Iu(e,t){return t<0||t>=e.current.length}function xm(e,t){return Vn(e,{disabledIndices:t})}function TS(e,t){return Vn(e,{decrement:!0,startingIndex:e.current.length,disabledIndices:t})}function Vn(e,{startingIndex:t=-1,decrement:n=!1,disabledIndices:r,amount:i=1}={}){let o=t;do o+=n?-i:i;while(o>=0&&o<=e.current.length-1&&Tu(e,o,r));return o}function O4(e,{event:t,orientation:n,loopFocus:r,rtl:i,cols:o,disabledIndices:a,minIndex:s,maxIndex:u,prevIndex:c,stopEvent:d=!1}){let p=c;const g=[],h={};let v=!1;{let w=null,C=-1;e.current.forEach((E,_)=>{if(E==null)return;const O=E.closest('[role="row"]');O&&(v=!0),(O!==w||C===-1)&&(w=O,C+=1,g[C]=[]),g[C].push(_),h[_]=C})}const b=v&&g.length>0&&g.some(w=>w.length!==o);function y(w){if(!b||c===-1)return;const C=h[c];if(C==null)return;const E=g[C].indexOf(c);let _=w==="up"?C-1:C+1;r&&(_<0?_=g.length-1:_>=g.length&&(_=0));const O=new Set;for(;_>=0&&_<g.length&&!O.has(_);){O.add(_);const R=g[_];if(R.length===0){_=w==="up"?_-1:_+1;continue}const I=Math.min(E,R.length-1);for(let k=I;k>=0;k-=1){const B=R[k];if(!Tu(e,B,a))return B}_=w==="up"?_-1:_+1,r&&(_<0?_=g.length-1:_>=g.length&&(_=0))}}if(t.key===d0){const w=y("up");if(w!==void 0)d&&jt(t),p=w;else{if(d&&jt(t),c===-1)p=u;else if(p=Vn(e,{startingIndex:p,amount:o,decrement:!0,disabledIndices:a}),r&&(c-o<s||p<0)){const C=c%o,E=u%o,_=u-(E-C);E===C?p=u:p=E>C?_:_-o}Iu(e,p)&&(p=c)}}if(t.key===rc){const w=y("down");w!==void 0?(d&&jt(t),p=w):(d&&jt(t),c===-1?p=s:(p=Vn(e,{startingIndex:c,amount:o,disabledIndices:a}),r&&c+o>u&&(p=Vn(e,{startingIndex:c%o-o,amount:o,disabledIndices:a}))),Iu(e,p)&&(p=c))}if(n==="both"){const w=el(c/o);t.key===(i?ea:ta)&&(d&&jt(t),c%o!==o-1?(p=Vn(e,{startingIndex:c,disabledIndices:a}),r&&Ff(p,o,w)&&(p=Vn(e,{startingIndex:c-c%o-1,disabledIndices:a}))):r&&(p=Vn(e,{startingIndex:c-c%o-1,disabledIndices:a})),Ff(p,o,w)&&(p=c)),t.key===(i?ta:ea)&&(d&&jt(t),c%o!==0?(p=Vn(e,{startingIndex:c,decrement:!0,disabledIndices:a}),r&&Ff(p,o,w)&&(p=Vn(e,{startingIndex:c+(o-c%o),decrement:!0,disabledIndices:a}))):r&&(p=Vn(e,{startingIndex:c+(o-c%o),decrement:!0,disabledIndices:a})),Ff(p,o,w)&&(p=c));const C=el(u/o)===w;Iu(e,p)&&(r&&C?p=t.key===(i?ta:ea)?u:Vn(e,{startingIndex:c-c%o-1,disabledIndices:a}):p=c)}return p}function P4(e,t,n){const r=[];let i=0;return e.forEach(({width:o,height:a},s)=>{if(o>t&&process.env.NODE_ENV!=="production")throw new Error(`[Floating UI]: Invalid grid - item width at index ${s} is greater than grid columns`);let u=!1;for(;!u;){const c=[];for(let d=0;d<o;d+=1)for(let p=0;p<a;p+=1)c.push(i+d+p*t);i%t+o<=t&&c.every(d=>r[d]==null)?(c.forEach(d=>{r[d]=s}),u=!0):i+=1}}),[...r]}function A4(e,t,n,r,i){if(e===-1)return-1;const o=n.indexOf(e),a=t[e];switch(i){case"tl":return o;case"tr":return a?o+a.width-1:o;case"bl":return a?o+(a.height-1)*r:o;case"br":return n.lastIndexOf(e);default:return-1}}function R4(e,t){return t.flatMap((n,r)=>e.includes(n)?[r]:[])}function Tu(e,t,n){if(typeof n=="function")return n(t);if(n)return n.includes(t);const r=e.current[t];return r?r.hasAttribute("disabled")||r.getAttribute("aria-disabled")==="true":!1}var I4=["input:not([inert]):not([inert] *)","select:not([inert]):not([inert] *)","textarea:not([inert]):not([inert] *)","a[href]:not([inert]):not([inert] *)","button:not([inert]):not([inert] *)","[tabindex]:not(slot):not([inert]):not([inert] *)","audio[controls]:not([inert]):not([inert] *)","video[controls]:not([inert]):not([inert] *)",'[contenteditable]:not([contenteditable="false"]):not([inert]):not([inert] *)',"details>summary:first-of-type:not([inert]):not([inert] *)","details:not([inert]):not([inert] *)"],Fd=I4.join(","),_I=typeof Element>"u",dl=_I?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,Vd=!_I&&Element.prototype.getRootNode?function(e){var t;return e==null||(t=e.getRootNode)===null||t===void 0?void 0:t.call(e)}:function(e){return e?.ownerDocument},Bd=function(t,n){var r;n===void 0&&(n=!0);var i=t==null||(r=t.getAttribute)===null||r===void 0?void 0:r.call(t,"inert"),o=i===""||i==="true",a=o||n&&t&&(typeof t.closest=="function"?t.closest("[inert]"):Bd(t.parentNode));return a},T4=function(t){var n,r=t==null||(n=t.getAttribute)===null||n===void 0?void 0:n.call(t,"contenteditable");return r===""||r==="true"},OI=function(t,n,r){if(Bd(t))return[];var i=Array.prototype.slice.apply(t.querySelectorAll(Fd));return n&&dl.call(t,Fd)&&i.unshift(t),i=i.filter(r),i},zd=function(t,n,r){for(var i=[],o=Array.from(t);o.length;){var a=o.shift();if(!Bd(a,!1))if(a.tagName==="SLOT"){var s=a.assignedElements(),u=s.length?s:a.children,c=zd(u,!0,r);r.flatten?i.push.apply(i,c):i.push({scopeParent:a,candidates:c})}else{var d=dl.call(a,Fd);d&&r.filter(a)&&(n||!t.includes(a))&&i.push(a);var p=a.shadowRoot||typeof r.getShadowRoot=="function"&&r.getShadowRoot(a),g=!Bd(p,!1)&&(!r.shadowRootFilter||r.shadowRootFilter(a));if(p&&g){var h=zd(p===!0?a.children:p.children,!0,r);r.flatten?i.push.apply(i,h):i.push({scopeParent:a,candidates:h})}else o.unshift.apply(o,a.children)}}return i},PI=function(t){return!isNaN(parseInt(t.getAttribute("tabindex"),10))},AI=function(t){if(!t)throw new Error("No node provided");return t.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(t.tagName)||T4(t))&&!PI(t)?0:t.tabIndex},k4=function(t,n){var r=AI(t);return r<0&&n&&!PI(t)?0:r},N4=function(t,n){return t.tabIndex===n.tabIndex?t.documentOrder-n.documentOrder:t.tabIndex-n.tabIndex},RI=function(t){return t.tagName==="INPUT"},M4=function(t){return RI(t)&&t.type==="hidden"},D4=function(t){var n=t.tagName==="DETAILS"&&Array.prototype.slice.apply(t.children).some(function(r){return r.tagName==="SUMMARY"});return n},j4=function(t,n){for(var r=0;r<t.length;r++)if(t[r].checked&&t[r].form===n)return t[r]},L4=function(t){if(!t.name)return!0;var n=t.form||Vd(t),r=function(s){return n.querySelectorAll('input[type="radio"][name="'+s+'"]')},i;if(typeof window<"u"&&typeof window.CSS<"u"&&typeof window.CSS.escape=="function")i=r(window.CSS.escape(t.name));else try{i=r(t.name)}catch(a){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",a.message),!1}var o=j4(i,t.form);return!o||o===t},$4=function(t){return RI(t)&&t.type==="radio"},F4=function(t){return $4(t)&&!L4(t)},V4=function(t){var n,r=t&&Vd(t),i=(n=r)===null||n===void 0?void 0:n.host,o=!1;if(r&&r!==t){var a,s,u;for(o=!!((a=i)!==null&&a!==void 0&&(s=a.ownerDocument)!==null&&s!==void 0&&s.contains(i)||t!=null&&(u=t.ownerDocument)!==null&&u!==void 0&&u.contains(t));!o&&i;){var c,d,p;r=Vd(i),i=(c=r)===null||c===void 0?void 0:c.host,o=!!((d=i)!==null&&d!==void 0&&(p=d.ownerDocument)!==null&&p!==void 0&&p.contains(i))}}return o},kS=function(t){var n=t.getBoundingClientRect(),r=n.width,i=n.height;return r===0&&i===0},B4=function(t,n){var r=n.displayCheck,i=n.getShadowRoot;if(r==="full-native"&&"checkVisibility"in t){var o=t.checkVisibility({checkOpacity:!1,opacityProperty:!1,contentVisibilityAuto:!0,visibilityProperty:!0,checkVisibilityCSS:!0});return!o}if(getComputedStyle(t).visibility==="hidden")return!0;var a=dl.call(t,"details>summary:first-of-type"),s=a?t.parentElement:t;if(dl.call(s,"details:not([open]) *"))return!0;if(!r||r==="full"||r==="full-native"||r==="legacy-full"){if(typeof i=="function"){for(var u=t;t;){var c=t.parentElement,d=Vd(t);if(c&&!c.shadowRoot&&i(c)===!0)return kS(t);t.assignedSlot?t=t.assignedSlot:!c&&d!==t.ownerDocument?t=d.host:t=c}t=u}if(V4(t))return!t.getClientRects().length;if(r!=="legacy-full")return!0}else if(r==="non-zero-area")return kS(t);return!1},z4=function(t){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(t.tagName))for(var n=t.parentElement;n;){if(n.tagName==="FIELDSET"&&n.disabled){for(var r=0;r<n.children.length;r++){var i=n.children.item(r);if(i.tagName==="LEGEND")return dl.call(n,"fieldset[disabled] *")?!0:!i.contains(t)}return!0}n=n.parentElement}return!1},ky=function(t,n){return!(n.disabled||M4(n)||B4(n,t)||D4(n)||z4(n))},Ny=function(t,n){return!(F4(n)||AI(n)<0||!ky(t,n))},W4=function(t){var n=parseInt(t.getAttribute("tabindex"),10);return!!(isNaN(n)||n>=0)},II=function(t){var n=[],r=[];return t.forEach(function(i,o){var a=!!i.scopeParent,s=a?i.scopeParent:i,u=k4(s,a),c=a?II(i.candidates):s;u===0?a?n.push.apply(n,c):n.push(s):r.push({documentOrder:o,tabIndex:u,item:i,isScope:a,content:c})}),r.sort(N4).reduce(function(i,o){return o.isScope?i.push.apply(i,o.content):i.push(o.content),i},[]).concat(n)},nh=function(t,n){n=n||{};var r;return n.getShadowRoot?r=zd([t],n.includeContainer,{filter:Ny.bind(null,n),flatten:!1,getShadowRoot:n.getShadowRoot,shadowRootFilter:W4}):r=OI(t,n.includeContainer,Ny.bind(null,n)),II(r)},H4=function(t,n){n=n||{};var r;return n.getShadowRoot?r=zd([t],n.includeContainer,{filter:ky.bind(null,n),flatten:!0,getShadowRoot:n.getShadowRoot}):r=OI(t,n.includeContainer,ky.bind(null,n)),r},TI=function(t,n){if(n=n||{},!t)throw new Error("No node provided");return dl.call(t,Fd)===!1?!1:Ny(n,t)};function Xt(e){return e?.ownerDocument||document}const ic=()=>({getShadowRoot:!0,displayCheck:typeof ResizeObserver=="function"&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function kI(e,t){const n=nh(e,ic()),r=n.length;if(r===0)return;const i=eo(Xt(e)),o=n.indexOf(i),a=o===-1?t===1?0:r-1:o+t;return n[a]}function NI(e){return kI(Xt(e).body,1)||e}function MI(e){return kI(Xt(e).body,-1)||e}function ku(e,t){const n=t||e.currentTarget,r=e.relatedTarget;return!r||!ft(n,r)}function U4(e){nh(e,ic()).forEach(n=>{n.dataset.tabindex=n.getAttribute("tabindex")||"",n.setAttribute("tabindex","-1")})}function NS(e){e.querySelectorAll("[data-tabindex]").forEach(n=>{const r=n.dataset.tabindex;delete n.dataset.tabindex,r?n.setAttribute("tabindex",r):n.removeAttribute("tabindex")})}function m0(e){const{enabled:t=!0,open:n,ref:r,onComplete:i}=e,o=Me(i),a=t4(r,n,!1);x.useEffect(()=>{if(!t)return;const s=new AbortController;return a(o,s.signal),()=>{s.abort()}},[t,n,o,a])}const lu=0;class pl{static create(){return new pl}currentId=lu;start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=lu,n()},t)}isStarted(){return this.currentId!==lu}clear=()=>{this.currentId!==lu&&(clearTimeout(this.currentId),this.currentId=lu)};disposeEffect=()=>this.clear}function Xa(){const e=ei(pl.create).current;return cI(e.disposeEffect),e}let MS={},DS={},jS="";function G4(e){if(typeof document>"u")return!1;const t=Xt(e);return Nn(t).innerWidth-t.documentElement.clientWidth>0}function q4(e){if(!(typeof CSS<"u"&&CSS.supports&&CSS.supports("scrollbar-gutter","stable"))||typeof document>"u")return!1;const n=Xt(e),r=n.documentElement,i=n.body,o=fa(r)?r:i,a=o.style.overflowY,s=r.style.scrollbarGutter;r.style.scrollbarGutter="stable",o.style.overflowY="scroll";const u=o.offsetWidth;o.style.overflowY="hidden";const c=o.offsetWidth;return o.style.overflowY=a,r.style.scrollbarGutter=s,u===c}function K4(e){const t=Xt(e),n=t.documentElement,r=t.body,i=fa(n)?n:r,o={overflowY:i.style.overflowY,overflowX:i.style.overflowX};return Object.assign(i.style,{overflowY:"hidden",overflowX:"hidden"}),()=>{Object.assign(i.style,o)}}function Y4(e){const t=Xt(e),n=t.documentElement,r=t.body,i=Nn(n);let o=0,a=0,s=!1;const u=Oi.create();if(yI&&(i.visualViewport?.scale??1)!==1)return()=>{};function c(){const g=i.getComputedStyle(n),h=i.getComputedStyle(r),y=(g.scrollbarGutter||"").includes("both-edges")?"stable both-edges":"stable";o=n.scrollTop,a=n.scrollLeft,MS={scrollbarGutter:n.style.scrollbarGutter,overflowY:n.style.overflowY,overflowX:n.style.overflowX},jS=n.style.scrollBehavior,DS={position:r.style.position,height:r.style.height,width:r.style.width,boxSizing:r.style.boxSizing,overflowY:r.style.overflowY,overflowX:r.style.overflowX,scrollBehavior:r.style.scrollBehavior};const w=n.scrollHeight>n.clientHeight,C=n.scrollWidth>n.clientWidth,E=g.overflowY==="scroll"||h.overflowY==="scroll",_=g.overflowX==="scroll"||h.overflowX==="scroll",O=Math.max(0,i.innerWidth-r.clientWidth),R=Math.max(0,i.innerHeight-r.clientHeight),I=parseFloat(h.marginTop)+parseFloat(h.marginBottom),k=parseFloat(h.marginLeft)+parseFloat(h.marginRight),B=fa(n)?n:r;if(s=q4(e),s){n.style.scrollbarGutter=y,B.style.overflowY="hidden",B.style.overflowX="hidden";return}Object.assign(n.style,{scrollbarGutter:y,overflowY:"hidden",overflowX:"hidden"}),(w||E)&&(n.style.overflowY="scroll"),(C||_)&&(n.style.overflowX="scroll"),Object.assign(r.style,{position:"relative",height:I||R?`calc(100dvh - ${I+R}px)`:"100dvh",width:k||O?`calc(100vw - ${k+O}px)`:"100vw",boxSizing:"border-box",overflow:"hidden",scrollBehavior:"unset"}),r.scrollTop=o,r.scrollLeft=a,n.setAttribute("data-base-ui-scroll-locked",""),n.style.scrollBehavior="unset"}function d(){Object.assign(n.style,MS),Object.assign(r.style,DS),s||(n.scrollTop=o,n.scrollLeft=a,n.removeAttribute("data-base-ui-scroll-locked"),n.style.scrollBehavior=jS)}function p(){d(),u.request(c)}return c(),i.addEventListener("resize",p),()=>{u.cancel(),d(),typeof i.removeEventListener=="function"&&i.removeEventListener("resize",p)}}class X4{lockCount=0;restore=null;timeoutLock=pl.create();timeoutUnlock=pl.create();acquire(t){return this.lockCount+=1,this.lockCount===1&&this.restore===null&&this.timeoutLock.start(0,()=>this.lock(t)),this.release}release=()=>{this.lockCount-=1,this.lockCount===0&&this.restore&&this.timeoutUnlock.start(0,this.unlock)};unlock=()=>{this.lockCount===0&&this.restore&&(this.restore?.(),this.restore=null)};lock(t){if(this.lockCount===0||this.restore!==null)return;const r=Xt(t).documentElement,i=Nn(r).getComputedStyle(r).overflowY;if(i==="hidden"||i==="clip"){this.restore=Wt;return}const o=bI||!G4(t);this.restore=o?K4(t):Y4(t)}}const Z4=new X4;function Q4(e=!0,t=null){je(()=>{if(e)return Z4.acquire(t)},[e,t])}function Xr(e){const t=ei(J4,e).current;return t.next=e,je(t.effect),t}function J4(e){const t={current:e,next:e,effect:()=>{t.current=t.next}};return t}function eq(){const e=new Map;return{emit(t,n){e.get(t)?.forEach(r=>r(n))},on(t,n){e.has(t)||e.set(t,new Set),e.get(t).add(n)},off(t,n){e.get(t)?.delete(n)}}}const DI=x.createContext(null);process.env.NODE_ENV!=="production"&&(DI.displayName="FloatingNodeContext");const jI=x.createContext(null);process.env.NODE_ENV!=="production"&&(jI.displayName="FloatingTreeContext");const LI=()=>x.useContext(DI)?.id||null,rh=e=>{const t=x.useContext(jI);return e??t};function Wd(e){return`data-base-ui-${e}`}const $I={clipPath:"inset(50%)",overflow:"hidden",whiteSpace:"nowrap",border:0,padding:0,width:1,height:1,margin:-1},v0={...$I,position:"fixed",top:0,left:0},tq={...$I,position:"absolute"},Fu=x.forwardRef(function(t,n){const[r,i]=x.useState();je(()=>{u4&&i("button")},[]);const o={tabIndex:0,role:r};return P.jsx("span",{...t,ref:n,style:v0,"aria-hidden":r?void 0:!0,...o,"data-base-ui-focus-guard":""})});process.env.NODE_ENV!=="production"&&(Fu.displayName="FocusGuard");let LS=0;function Nu(e,t={}){const{preventScroll:n=!1,cancelPrevious:r=!0,sync:i=!1}=t;r&&cancelAnimationFrame(LS);const o=()=>e?.focus({preventScroll:n});i?o():LS=requestAnimationFrame(o)}const ol={inert:new WeakMap,"aria-hidden":new WeakMap,none:new WeakMap};function $S(e){return e==="inert"?ol.inert:e==="aria-hidden"?ol["aria-hidden"]:ol.none}let Vf=new WeakSet,Bf={},wm=0;const FI=e=>e&&(e.host||FI(e.parentNode)),nq=(e,t)=>t.map(n=>{if(e.contains(n))return n;const r=FI(n);return e.contains(r)?r:null}).filter(n=>n!=null);function rq(e,t,n,r){const i="data-base-ui-inert",o=r?"inert":n?"aria-hidden":null,a=nq(t,e),s=new Set,u=new Set(a),c=[];Bf[i]||(Bf[i]=new WeakMap);const d=Bf[i];a.forEach(p),g(t),s.clear();function p(h){!h||s.has(h)||(s.add(h),h.parentNode&&p(h.parentNode))}function g(h){!h||u.has(h)||[].forEach.call(h.children,v=>{if(ca(v)!=="script")if(s.has(v))g(v);else{const b=o?v.getAttribute(o):null,y=b!==null&&b!=="false",w=$S(o),C=(w.get(v)||0)+1,E=(d.get(v)||0)+1;w.set(v,C),d.set(v,E),c.push(v),C===1&&y&&Vf.add(v),E===1&&v.setAttribute(i,""),!y&&o&&v.setAttribute(o,o==="inert"?"":"true")}})}return wm+=1,()=>{c.forEach(h=>{const v=$S(o),y=(v.get(h)||0)-1,w=(d.get(h)||0)-1;v.set(h,y),d.set(h,w),y||(!Vf.has(h)&&o&&h.removeAttribute(o),Vf.delete(h)),w||h.removeAttribute(i)}),wm-=1,wm||(ol.inert=new WeakMap,ol["aria-hidden"]=new WeakMap,ol.none=new WeakMap,Vf=new WeakSet,Bf={})}}function iq(e,t=!1,n=!1){const r=Xt(e[0]).body;return rq(e.concat(Array.from(r.querySelectorAll("[aria-live]"))),r,t,n)}const y0=x.createContext(null);process.env.NODE_ENV!=="production"&&(y0.displayName="PortalContext");const VI=()=>x.useContext(y0),oq=Wd("portal");function aq(e={}){const{ref:t,container:n,componentProps:r=Xn,elementProps:i}=e,o=a0(),s=VI()?.portalNode,[u,c]=x.useState(null),[d,p]=x.useState(null),g=Me(y=>{y!==null&&p(y)}),h=x.useRef(null);je(()=>{if(n===null){h.current&&(h.current=null,p(null),c(null));return}if(o==null)return;const y=(n&&(u0(n)?n:n.current))??s??document.body;if(y==null){h.current&&(h.current=null,p(null),c(null));return}h.current!==y&&(h.current=y,p(null),c(y))},[n,s,o]);const v=er("div",r,{ref:[t,g],props:[{id:o,[oq]:""},i]});return{portalNode:d,portalSubtree:u&&v?la.createPortal(v,u):null}}const BI=x.forwardRef(function(t,n){const{children:r,container:i,className:o,render:a,renderGuards:s,...u}=t,{portalNode:c,portalSubtree:d}=aq({container:i,ref:n,componentProps:t,elementProps:u}),p=x.useRef(null),g=x.useRef(null),h=x.useRef(null),v=x.useRef(null),[b,y]=x.useState(null),w=b?.modal,C=b?.open,E=typeof s=="boolean"?s:!!b&&!b.modal&&b.open&&!!c;x.useEffect(()=>{if(!c||w)return;function O(R){c&&R.relatedTarget&&ku(R)&&(R.type==="focusin"?NS:U4)(c)}return c.addEventListener("focusin",O,!0),c.addEventListener("focusout",O,!0),()=>{c.removeEventListener("focusin",O,!0),c.removeEventListener("focusout",O,!0)}},[c,w]),x.useEffect(()=>{!c||C||NS(c)},[C,c]);const _=x.useMemo(()=>({beforeOutsideRef:p,afterOutsideRef:g,beforeInsideRef:h,afterInsideRef:v,portalNode:c,setFocusManagerState:y}),[c]);return P.jsxs(x.Fragment,{children:[d,P.jsxs(y0.Provider,{value:_,children:[E&&c&&P.jsx(Fu,{"data-type":"outside",ref:p,onFocus:O=>{if(ku(O,c))h.current?.focus();else{const R=b?b.domReference:null;MI(R)?.focus()}}}),E&&c&&P.jsx("span",{"aria-owns":c.id,style:BG}),c&&la.createPortal(r,c),E&&c&&P.jsx(Fu,{"data-type":"outside",ref:g,onFocus:O=>{if(ku(O,c))v.current?.focus();else{const R=b?b.domReference:null;NI(R)?.focus(),b?.closeOnFocusOut&&b?.onOpenChange(!1,Xe(Kp,O.nativeEvent))}}})]})]})});process.env.NODE_ENV!=="production"&&(BI.displayName="FloatingPortal");function sq(e,t){const n=Nn(e.target);return e instanceof n.KeyboardEvent?"keyboard":e instanceof n.FocusEvent?t||"keyboard":"pointerType"in e?e.pointerType||"keyboard":"touches"in e?"touch":e instanceof n.MouseEvent?t||(e.detail===0?"keyboard":"mouse"):""}const FS=20;let Yo=[];function b0(){Yo=Yo.filter(e=>e.deref()?.isConnected)}function lq(e){b0(),e&&ca(e)!=="body"&&(Yo.push(new WeakRef(e)),Yo.length>FS&&(Yo=Yo.slice(-FS)))}function Cm(){return b0(),Yo[Yo.length-1]?.deref()}function uq(e){if(!e)return null;const t=ic();return TI(e,t)?e:nh(e,t)[0]||e}function cq(e){return!e||!e.isConnected?!1:typeof e.checkVisibility=="function"?e.checkVisibility():Rr(e).display!=="none"}function VS(e,t){if(!t.current.includes("floating")&&!e.getAttribute("role")?.includes("dialog"))return;const n=ic(),i=H4(e,n).filter(a=>{const s=a.getAttribute("data-tabindex")||"";return TI(a,n)||a.hasAttribute("data-tabindex")&&!s.startsWith("-")}),o=e.getAttribute("tabindex");t.current.includes("floating")||i.length===0?o!=="0"&&e.setAttribute("tabindex","0"):(o!=="-1"||e.hasAttribute("data-tabindex")&&e.getAttribute("data-tabindex")!=="-1")&&(e.setAttribute("tabindex","-1"),e.setAttribute("data-tabindex","-1"))}function fq(e){const{context:t,children:n,disabled:r=!1,initialFocus:i=!0,returnFocus:o=!0,restoreFocus:a=!1,modal:s=!0,closeOnFocusOut:u=!0,openInteractionType:c="",nextFocusableElement:d,previousFocusableElement:p,beforeContentFocusGuardRef:g,externalTree:h}=e,v="rootStore"in t?t.rootStore:t,b=v.useState("open"),y=v.useState("domReferenceElement"),w=v.useState("floatingElement"),{events:C,dataRef:E}=v.context,_=Me(()=>E.current.floatingContext?.nodeId),O=i===!1,R=Ry(y)&&O,I=x.useRef(["content"]),k=Xr(i),B=Xr(o),L=Xr(c),V=rh(h),D=VI(),H=x.useRef(null),J=x.useRef(null),te=x.useRef(!1),G=x.useRef(!1),ee=x.useRef(!1),Q=x.useRef(-1),pe=x.useRef(""),K=x.useRef(""),Ae=x.useRef(null),Se=x.useRef(null),$e=Lu(Ae,g,D?.beforeInsideRef),we=Lu(Se,D?.afterInsideRef),Ce=Xa(),ze=Xa(),Ke=l0(),Fe=D!=null,Y=Iy(w),oe=Me((ie=Y)=>ie?nh(ie,ic()):[]),ne=Me(ie=>{const Z=oe(ie);return I.current.map(()=>Z).filter(Boolean).flat()});x.useEffect(()=>{if(r||!s)return;function ie(Re){Re.key==="Tab"&&ft(Y,eo(Xt(Y)))&&oe().length===0&&!R&&jt(Re)}const Z=Xt(Y);return Z.addEventListener("keydown",ie),()=>{Z.removeEventListener("keydown",ie)}},[r,y,Y,s,I,R,oe,ne]),x.useEffect(()=>{if(r||!b)return;const ie=Xt(Y);function Z(){ee.current=!1}function Re(fe){const me=lr(fe),de=ft(w,me)||ft(y,me)||ft(D?.portalNode,me);ee.current=!de,K.current=fe.pointerType||"keyboard",me?.closest(`[${FG}]`)&&(G.current=!0)}function U(){K.current="keyboard"}return ie.addEventListener("pointerdown",Re,!0),ie.addEventListener("pointerup",Z,!0),ie.addEventListener("pointercancel",Z,!0),ie.addEventListener("keydown",U,!0),()=>{ie.removeEventListener("pointerdown",Re,!0),ie.removeEventListener("pointerup",Z,!0),ie.removeEventListener("pointercancel",Z,!0),ie.removeEventListener("keydown",U,!0)}},[r,w,y,Y,b,D]),x.useEffect(()=>{if(r||!u)return;const ie=Xt(Y);function Z(){G.current=!0,ze.start(0,()=>{G.current=!1})}function Re(ve){const le=lr(ve),ke=oe().indexOf(le);ke!==-1&&(Q.current=ke)}function U(ve){const le=ve.relatedTarget,be=ve.currentTarget,ke=lr(ve);queueMicrotask(()=>{const et=_(),Tt=v.context.triggerElements,Dn=le?.hasAttribute(Wd("focus-guard"))&&[Ae.current,Se.current,D?.beforeInsideRef.current,D?.afterInsideRef.current,D?.beforeOutsideRef.current,D?.afterOutsideRef.current,Qi(p),Qi(d)].includes(le),Ct=!(ft(y,le)||ft(w,le)||ft(le,w)||ft(D?.portalNode,le)||le!=null&&Tt.hasElement(le)||Tt.hasMatchingElement(ot=>ft(ot,le))||Dn||V&&(il(V.nodesRef.current,et).find(ot=>ft(ot.context?.elements.floating,le)||ft(ot.context?.elements.domReference,le))||PS(V.nodesRef.current,et).find(ot=>[ot.context?.elements.floating,Iy(ot.context?.elements.floating)].includes(le)||ot.context?.elements.domReference===le)));if(be===y&&Y&&VS(Y,I),a&&be!==y&&!cq(ke)&&eo(ie)===ie.body){if(nn(Y)&&(Y.focus(),a==="popup")){Ke.request(()=>{Y.focus()});return}const ot=Q.current,kt=oe(),mn=kt[ot]||kt[kt.length-1]||Y;nn(mn)&&mn.focus()}if(E.current.insideReactTree){E.current.insideReactTree=!1;return}(R||!s)&&le&&Ct&&!G.current&&(R||le!==Cm())&&(te.current=!0,v.setOpen(!1,Xe(Kp,ve)))})}function fe(){ee.current||(E.current.insideReactTree=!0,Ce.start(0,()=>{E.current.insideReactTree=!1}))}const me=nn(y)?y:null,de=[];if(!(!w&&!me))return me&&(me.addEventListener("focusout",U),me.addEventListener("pointerdown",Z),de.push(()=>{me.removeEventListener("focusout",U),me.removeEventListener("pointerdown",Z)})),w&&(w.addEventListener("focusin",Re),w.addEventListener("focusout",U),D&&(w.addEventListener("focusout",fe,!0),de.push(()=>{w.removeEventListener("focusout",fe,!0)})),de.push(()=>{w.removeEventListener("focusin",Re),w.removeEventListener("focusout",U)})),()=>{de.forEach(ve=>{ve()})}},[r,y,w,Y,s,V,D,v,u,a,oe,R,_,I,E,Ce,ze,Ke,d,p]),x.useEffect(()=>{if(r||!w||!b)return;const ie=Array.from(D?.portalNode?.querySelectorAll(`[${Wd("portal")}]`)||[]),Re=(V?PS(V.nodesRef.current,_()):[]).find(fe=>Ry(fe.context?.elements.domReference||null))?.context?.elements.domReference,U=[w,Re,...ie,H.current,J.current,Ae.current,Se.current,D?.beforeOutsideRef.current,D?.afterOutsideRef.current,Qi(p),Qi(d),R?y:null].filter(fe=>fe!=null);return iq(U,s||R)},[b,r,y,w,s,I,D,R,V,_,d,p]),je(()=>{if(!b||r||!nn(Y))return;const ie=Xt(Y),Z=eo(ie);queueMicrotask(()=>{const Re=ne(Y),U=k.current,fe=typeof U=="function"?U(L.current||""):U;if(fe===void 0||fe===!1)return;let me;fe===!0||fe===null?me=Re[0]||Y:me=Qi(fe),me=me||Re[0]||Y,!ft(Y,Z)&&Nu(me,{preventScroll:me===Y})})},[r,b,Y,O,ne,k,L]),je(()=>{if(r||!Y)return;const ie=Xt(Y),Z=eo(ie);lq(Z);function Re(me){if(me.open||(pe.current=sq(me.nativeEvent,K.current)),me.reason===GG&&me.nativeEvent.type==="mouseleave"&&(te.current=!0),me.reason===o0)if(me.nested)te.current=!1;else if(CI(me.nativeEvent)||SI(me.nativeEvent))te.current=!1;else{let de=!1;document.createElement("div").focus({get preventScroll(){return de=!0,!1}}),de?te.current=!1:te.current=!0}}C.on("openchange",Re);const U=ie.createElement("span");U.setAttribute("tabindex","-1"),U.setAttribute("aria-hidden","true"),Object.assign(U.style,v0),Fe&&y&&y.insertAdjacentElement("afterend",U);function fe(){const me=B.current;let de=typeof me=="function"?me(pe.current):me;if(de===void 0||de===!1)return null;if(de===null&&(de=!0),typeof de=="boolean"){const le=y||Cm();return le&&le.isConnected?le:U}const ve=y||Cm()||U;return Qi(de)||ve}return()=>{C.off("openchange",Re);const me=eo(ie),de=ft(w,me)||V&&il(V.nodesRef.current,_(),!1).some(le=>ft(le.context?.elements.floating,me)),ve=fe();queueMicrotask(()=>{const le=uq(ve),be=typeof B.current!="boolean";B.current&&!te.current&&nn(le)&&(!(!be&&le!==me&&me!==ie.body)||de)&&le.focus({preventScroll:!0}),U.remove(),te.current=!1})}},[r,w,Y,B,E,C,V,Fe,y,_]),je(()=>{if(!yI||b||!w)return;const ie=eo(Xt(w));!nn(ie)||!p0(ie)||ft(w,ie)&&ie.blur()},[b,w]),je(()=>{if(!(r||!D))return D.setFocusManagerState({modal:s,closeOnFocusOut:u,open:b,onOpenChange:v.setOpen,domReference:y}),()=>{D.setFocusManagerState(null)}},[r,D,s,b,v,u,y]),je(()=>{if(!(r||!Y))return VS(Y,I),()=>{queueMicrotask(b0)}},[r,Y,I]);const $=!r&&(s?!R:!0)&&(Fe||s);return P.jsxs(x.Fragment,{children:[$&&P.jsx(Fu,{"data-type":"inside",ref:$e,onFocus:ie=>{if(s){const Z=ne();Nu(Z[Z.length-1])}else D?.portalNode&&(te.current=!1,ku(ie,D.portalNode)?NI(y)?.focus():Qi(p??D.beforeOutsideRef)?.focus())}}),n,$&&P.jsx(Fu,{"data-type":"inside",ref:we,onFocus:ie=>{s?Nu(ne()[0]):D?.portalNode&&(u&&(te.current=!0),ku(ie,D.portalNode)?MI(y)?.focus():Qi(d??D.afterOutsideRef)?.focus())}})]})}function zI(e,t={}){const n="rootStore"in e?e.rootStore:e,r=n.context.dataRef,{enabled:i=!0,event:o="click",toggle:a=!0,ignoreMouse:s=!1,stickIfOpen:u=!0,touchOpenDelay:c=0,reason:d=Sy}=t,p=x.useRef(void 0),g=l0(),h=Xa(),v=x.useMemo(()=>({onPointerDown(b){p.current=b.pointerType},onMouseDown(b){const y=p.current,w=b.nativeEvent,C=n.select("open");if(b.button!==0||o==="click"||AS(y)&&s)return;const E=r.current.openEvent,_=E?.type,O=n.select("domReferenceElement")!==b.currentTarget,R=C&&O||!(C&&a&&(!(E&&u)||_==="click"||_==="mousedown"));if(p0(w.target)){const k=Xe(d,w,w.target);R&&y==="touch"&&c>0?h.start(c,()=>{n.setOpen(!0,k)}):n.setOpen(R,k);return}const I=b.currentTarget;g.request(()=>{const k=Xe(d,w,I);R&&y==="touch"&&c>0?h.start(c,()=>{n.setOpen(!0,k)}):n.setOpen(R,k)})},onClick(b){if(o==="mousedown-only")return;const y=p.current;if(o==="mousedown"&&y){p.current=void 0;return}if(AS(y)&&s)return;const w=n.select("open"),C=r.current.openEvent,E=n.select("domReferenceElement")!==b.currentTarget,_=w&&E||!(w&&a&&(!(C&&u)||EI(C))),O=Xe(d,b.nativeEvent,b.currentTarget);_&&y==="touch"&&c>0?h.start(c,()=>{n.setOpen(!0,O)}):n.setOpen(_,O)},onKeyDown(){p.current=void 0}}),[r,o,s,n,u,a,g,h,c,d]);return x.useMemo(()=>i?{reference:v}:Xn,[i,v])}function BS(e,t,n){let{reference:r,floating:i}=e;const o=Zr(t),a=th(t),s=eh(a),u=Ar(t),c=o==="y",d=r.x+r.width/2-i.width/2,p=r.y+r.height/2-i.height/2,g=r[s]/2-i[s]/2;let h;switch(u){case"top":h={x:d,y:r.y-i.height};break;case"bottom":h={x:d,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:p};break;case"left":h={x:r.x-i.width,y:p};break;default:h={x:r.x,y:r.y}}switch(bo(t)){case"start":h[a]-=g*(n&&c?-1:1);break;case"end":h[a]+=g*(n&&c?-1:1);break}return h}async function dq(e,t){var n;t===void 0&&(t={});const{x:r,y:i,platform:o,rects:a,elements:s,strategy:u}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:p="floating",altBoundary:g=!1,padding:h=0}=Ni(t,e),v=g0(h),y=s[g?p==="floating"?"reference":"floating":p],w=$d(await o.getClippingRect({element:(n=await(o.isElement==null?void 0:o.isElement(y)))==null||n?y:y.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(s.floating)),boundary:c,rootBoundary:d,strategy:u})),C=p==="floating"?{x:r,y:i,width:a.floating.width,height:a.floating.height}:a.reference,E=await(o.getOffsetParent==null?void 0:o.getOffsetParent(s.floating)),_=await(o.isElement==null?void 0:o.isElement(E))?await(o.getScale==null?void 0:o.getScale(E))||{x:1,y:1}:{x:1,y:1},O=$d(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:C,offsetParent:E,strategy:u}):C);return{top:(w.top-O.top+v.top)/_.y,bottom:(O.bottom-w.bottom+v.bottom)/_.y,left:(w.left-O.left+v.left)/_.x,right:(O.right-w.right+v.right)/_.x}}const pq=50,hq=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:a}=n,s=a.detectOverflow?a:{...a,detectOverflow:dq},u=await(a.isRTL==null?void 0:a.isRTL(t));let c=await a.getElementRects({reference:e,floating:t,strategy:i}),{x:d,y:p}=BS(c,r,u),g=r,h=0;const v={};for(let b=0;b<o.length;b++){const y=o[b];if(!y)continue;const{name:w,fn:C}=y,{x:E,y:_,data:O,reset:R}=await C({x:d,y:p,initialPlacement:r,placement:g,strategy:i,middlewareData:v,rects:c,platform:s,elements:{reference:e,floating:t}});d=E??d,p=_??p,v[w]={...v[w],...O},R&&h<pq&&(h++,typeof R=="object"&&(R.placement&&(g=R.placement),R.rects&&(c=R.rects===!0?await a.getElementRects({reference:e,floating:t,strategy:i}):R.rects),{x:d,y:p}=BS(c,g,u)),b=-1)}return{x:d,y:p,placement:g,strategy:i,middlewareData:v}},gq=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:o,platform:a,elements:s,middlewareData:u}=t,{element:c,padding:d=0}=Ni(e,t)||{};if(c==null)return{};const p=g0(d),g={x:n,y:r},h=th(i),v=eh(h),b=await a.getDimensions(c),y=h==="y",w=y?"top":"left",C=y?"bottom":"right",E=y?"clientHeight":"clientWidth",_=o.reference[v]+o.reference[h]-g[h]-o.floating[v],O=g[h]-o.reference[h],R=await(a.getOffsetParent==null?void 0:a.getOffsetParent(c));let I=R?R[E]:0;(!I||!await(a.isElement==null?void 0:a.isElement(R)))&&(I=s.floating[E]||o.floating[v]);const k=_/2-O/2,B=I/2-b[v]/2-1,L=oa(p[w],B),V=oa(p[C],B),D=L,H=I-b[v]-V,J=I/2-b[v]/2+k,te=jd(D,J,H),G=!u.arrow&&bo(i)!=null&&J!==te&&o.reference[v]/2-(J<D?L:V)-b[v]/2<0,ee=G?J<D?J-D:J-H:0;return{[h]:g[h]+ee,data:{[h]:te,centerOffset:J-te-ee,...G&&{alignmentOffset:ee}},reset:G}}}),mq=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:i,middlewareData:o,rects:a,initialPlacement:s,platform:u,elements:c}=t,{mainAxis:d=!0,crossAxis:p=!0,fallbackPlacements:g,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:v="none",flipAlignment:b=!0,...y}=Ni(e,t);if((n=o.arrow)!=null&&n.alignmentOffset)return{};const w=Ar(i),C=Zr(s),E=Ar(s)===s,_=await(u.isRTL==null?void 0:u.isRTL(c.floating)),O=g||(E||!b?[Ld(s)]:x4(s)),R=v!=="none";!g&&R&&O.push(...E4(s,b,v,_));const I=[s,...O],k=await u.detectOverflow(t,y),B=[];let L=((r=o.flip)==null?void 0:r.overflows)||[];if(d&&B.push(k[w]),p){const J=b4(i,a,_);B.push(k[J[0]],k[J[1]])}if(L=[...L,{placement:i,overflows:B}],!B.every(J=>J<=0)){var V,D;const J=(((V=o.flip)==null?void 0:V.index)||0)+1,te=I[J];if(te&&(!(p==="alignment"?C!==Zr(te):!1)||L.every(Q=>Zr(Q.placement)===C?Q.overflows[0]>0:!0)))return{data:{index:J,overflows:L},reset:{placement:te}};let G=(D=L.filter(ee=>ee.overflows[0]<=0).sort((ee,Q)=>ee.overflows[1]-Q.overflows[1])[0])==null?void 0:D.placement;if(!G)switch(h){case"bestFit":{var H;const ee=(H=L.filter(Q=>{if(R){const pe=Zr(Q.placement);return pe===C||pe==="y"}return!0}).map(Q=>[Q.placement,Q.overflows.filter(pe=>pe>0).reduce((pe,K)=>pe+K,0)]).sort((Q,pe)=>Q[1]-pe[1])[0])==null?void 0:H[0];ee&&(G=ee);break}case"initialPlacement":G=s;break}if(i!==G)return{reset:{placement:G}}}return{}}}};function zS(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function WS(e){return v4.some(t=>e[t]>=0)}const vq=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n,platform:r}=t,{strategy:i="referenceHidden",...o}=Ni(e,t);switch(i){case"referenceHidden":{const a=await r.detectOverflow(t,{...o,elementContext:"reference"}),s=zS(a,n.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:WS(s)}}}case"escaped":{const a=await r.detectOverflow(t,{...o,altBoundary:!0}),s=zS(a,n.floating);return{data:{escapedOffsets:s,escaped:WS(s)}}}default:return{}}}}},WI=new Set(["left","top"]);async function yq(e,t){const{placement:n,platform:r,elements:i}=e,o=await(r.isRTL==null?void 0:r.isRTL(i.floating)),a=Ar(n),s=bo(n),u=Zr(n)==="y",c=WI.has(a)?-1:1,d=o&&u?-1:1,p=Ni(t,e);let{mainAxis:g,crossAxis:h,alignmentAxis:v}=typeof p=="number"?{mainAxis:p,crossAxis:0,alignmentAxis:null}:{mainAxis:p.mainAxis||0,crossAxis:p.crossAxis||0,alignmentAxis:p.alignmentAxis};return s&&typeof v=="number"&&(h=s==="end"?v*-1:v),u?{x:h*d,y:g*c}:{x:g*c,y:h*d}}const bq=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:i,y:o,placement:a,middlewareData:s}=t,u=await yq(t,e);return a===((n=s.offset)==null?void 0:n.placement)&&(r=s.arrow)!=null&&r.alignmentOffset?{}:{x:i+u.x,y:o+u.y,data:{...u,placement:a}}}}},xq=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:i,platform:o}=t,{mainAxis:a=!0,crossAxis:s=!1,limiter:u={fn:w=>{let{x:C,y:E}=w;return{x:C,y:E}}},...c}=Ni(e,t),d={x:n,y:r},p=await o.detectOverflow(t,c),g=Zr(Ar(i)),h=h0(g);let v=d[h],b=d[g];if(a){const w=h==="y"?"top":"left",C=h==="y"?"bottom":"right",E=v+p[w],_=v-p[C];v=jd(E,v,_)}if(s){const w=g==="y"?"top":"left",C=g==="y"?"bottom":"right",E=b+p[w],_=b-p[C];b=jd(E,b,_)}const y=u.fn({...t,[h]:v,[g]:b});return{...y,data:{x:y.x-n,y:y.y-r,enabled:{[h]:a,[g]:s}}}}}},wq=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:i,rects:o,middlewareData:a}=t,{offset:s=0,mainAxis:u=!0,crossAxis:c=!0}=Ni(e,t),d={x:n,y:r},p=Zr(i),g=h0(p);let h=d[g],v=d[p];const b=Ni(s,t),y=typeof b=="number"?{mainAxis:b,crossAxis:0}:{mainAxis:0,crossAxis:0,...b};if(u){const E=g==="y"?"height":"width",_=o.reference[g]-o.floating[E]+y.mainAxis,O=o.reference[g]+o.reference[E]-y.mainAxis;h<_?h=_:h>O&&(h=O)}if(c){var w,C;const E=g==="y"?"width":"height",_=WI.has(Ar(i)),O=o.reference[p]-o.floating[E]+(_&&((w=a.offset)==null?void 0:w[p])||0)+(_?0:y.crossAxis),R=o.reference[p]+o.reference[E]+(_?0:((C=a.offset)==null?void 0:C[p])||0)-(_?y.crossAxis:0);v<O?v=O:v>R&&(v=R)}return{[g]:h,[p]:v}}}},Cq=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:i,rects:o,platform:a,elements:s}=t,{apply:u=()=>{},...c}=Ni(e,t),d=await a.detectOverflow(t,c),p=Ar(i),g=bo(i),h=Zr(i)==="y",{width:v,height:b}=o.floating;let y,w;p==="top"||p==="bottom"?(y=p,w=g===(await(a.isRTL==null?void 0:a.isRTL(s.floating))?"start":"end")?"left":"right"):(w=p,y=g==="end"?"top":"bottom");const C=b-d.top-d.bottom,E=v-d.left-d.right,_=oa(b-d[y],C),O=oa(v-d[w],E),R=!t.middlewareData.shift;let I=_,k=O;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(k=E),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(I=C),R&&!g){const L=Er(d.left,0),V=Er(d.right,0),D=Er(d.top,0),H=Er(d.bottom,0);h?k=v-2*(L!==0||V!==0?L+V:Er(d.left,d.right)):I=b-2*(D!==0||H!==0?D+H:Er(d.top,d.bottom))}await u({...t,availableWidth:k,availableHeight:I});const B=await a.getDimensions(s.floating);return v!==B.width||b!==B.height?{reset:{rects:!0}}:{}}}};function HI(e){const t=Rr(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=nn(e),o=i?e.offsetWidth:n,a=i?e.offsetHeight:r,s=Dd(n)!==o||Dd(r)!==a;return s&&(n=o,r=a),{width:n,height:r,$:s}}function x0(e){return Lt(e)?e:e.contextElement}function al(e){const t=x0(e);if(!nn(t))return Ii(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:o}=HI(t);let a=(o?Dd(n.width):n.width)/r,s=(o?Dd(n.height):n.height)/i;return(!a||!Number.isFinite(a))&&(a=1),(!s||!Number.isFinite(s))&&(s=1),{x:a,y:s}}const Sq=Ii(0);function UI(e){const t=Nn(e);return!Zp()||!t.visualViewport?Sq:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Eq(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Nn(e)?!1:t}function Za(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const i=e.getBoundingClientRect(),o=x0(e);let a=Ii(1);t&&(r?Lt(r)&&(a=al(r)):a=al(e));const s=Eq(o,n,r)?UI(o):Ii(0);let u=(i.left+s.x)/a.x,c=(i.top+s.y)/a.y,d=i.width/a.x,p=i.height/a.y;if(o){const g=Nn(o),h=r&&Lt(r)?Nn(r):r;let v=g,b=Oy(v);for(;b&&r&&h!==v;){const y=al(b),w=b.getBoundingClientRect(),C=Rr(b),E=w.left+(b.clientLeft+parseFloat(C.paddingLeft))*y.x,_=w.top+(b.clientTop+parseFloat(C.paddingTop))*y.y;u*=y.x,c*=y.y,d*=y.x,p*=y.y,u+=E,c+=_,v=Nn(b),b=Oy(v)}}return $d({width:d,height:p,x:u,y:c})}function ih(e,t){const n=Qp(e).scrollLeft;return t?t.left+n:Za(Vi(e)).left+n}function GI(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-ih(e,n),i=n.top+t.scrollTop;return{x:r,y:i}}function _q(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e;const o=i==="fixed",a=Vi(r),s=t?Xp(t.floating):!1;if(r===a||s&&o)return n;let u={scrollLeft:0,scrollTop:0},c=Ii(1);const d=Ii(0),p=nn(r);if((p||!p&&!o)&&((ca(r)!=="body"||fa(a))&&(u=Qp(r)),p)){const h=Za(r);c=al(r),d.x=h.x+r.clientLeft,d.y=h.y+r.clientTop}const g=a&&!p&&!o?GI(a,u):Ii(0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-u.scrollLeft*c.x+d.x+g.x,y:n.y*c.y-u.scrollTop*c.y+d.y+g.y}}function Oq(e){return Array.from(e.getClientRects())}function Pq(e){const t=Vi(e),n=Qp(e),r=e.ownerDocument.body,i=Er(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),o=Er(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+ih(e);const s=-n.scrollTop;return Rr(r).direction==="rtl"&&(a+=Er(t.clientWidth,r.clientWidth)-i),{width:i,height:o,x:a,y:s}}const HS=25;function Aq(e,t){const n=Nn(e),r=Vi(e),i=n.visualViewport;let o=r.clientWidth,a=r.clientHeight,s=0,u=0;if(i){o=i.width,a=i.height;const d=Zp();(!d||d&&t==="fixed")&&(s=i.offsetLeft,u=i.offsetTop)}const c=ih(r);if(c<=0){const d=r.ownerDocument,p=d.body,g=getComputedStyle(p),h=d.compatMode==="CSS1Compat"&&parseFloat(g.marginLeft)+parseFloat(g.marginRight)||0,v=Math.abs(r.clientWidth-p.clientWidth-h);v<=HS&&(o-=v)}else c<=HS&&(o+=c);return{width:o,height:a,x:s,y:u}}function Rq(e,t){const n=Za(e,!0,t==="fixed"),r=n.top+e.clientTop,i=n.left+e.clientLeft,o=nn(e)?al(e):Ii(1),a=e.clientWidth*o.x,s=e.clientHeight*o.y,u=i*o.x,c=r*o.y;return{width:a,height:s,x:u,y:c}}function US(e,t,n){let r;if(t==="viewport")r=Aq(e,n);else if(t==="document")r=Pq(Vi(e));else if(Lt(t))r=Rq(t,n);else{const i=UI(e);r={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return $d(r)}function qI(e,t){const n=co(e);return n===t||!Lt(n)||ao(n)?!1:Rr(n).position==="fixed"||qI(n,t)}function Iq(e,t){const n=t.get(e);if(n)return n;let r=Jo(e,[],!1).filter(s=>Lt(s)&&ca(s)!=="body"),i=null;const o=Rr(e).position==="fixed";let a=o?co(e):e;for(;Lt(a)&&!ao(a);){const s=Rr(a),u=c0(a);!u&&s.position==="fixed"&&(i=null),(o?!u&&!i:!u&&s.position==="static"&&!!i&&(i.position==="absolute"||i.position==="fixed")||fa(a)&&!u&&qI(e,a))?r=r.filter(d=>d!==a):i=s,a=co(a)}return t.set(e,r),r}function Tq(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const a=[...n==="clippingAncestors"?Xp(t)?[]:Iq(t,this._c):[].concat(n),r],s=US(t,a[0],i);let u=s.top,c=s.right,d=s.bottom,p=s.left;for(let g=1;g<a.length;g++){const h=US(t,a[g],i);u=Er(h.top,u),c=oa(h.right,c),d=oa(h.bottom,d),p=Er(h.left,p)}return{width:c-p,height:d-u,x:p,y:u}}function kq(e){const{width:t,height:n}=HI(e);return{width:t,height:n}}function Nq(e,t,n){const r=nn(t),i=Vi(t),o=n==="fixed",a=Za(e,!0,o,t);let s={scrollLeft:0,scrollTop:0};const u=Ii(0);function c(){u.x=ih(i)}if(r||!r&&!o)if((ca(t)!=="body"||fa(i))&&(s=Qp(t)),r){const h=Za(t,!0,o,t);u.x=h.x+t.clientLeft,u.y=h.y+t.clientTop}else i&&c();o&&!r&&i&&c();const d=i&&!r&&!o?GI(i,s):Ii(0),p=a.left+s.scrollLeft-u.x-d.x,g=a.top+s.scrollTop-u.y-d.y;return{x:p,y:g,width:a.width,height:a.height}}function Sm(e){return Rr(e).position==="static"}function GS(e,t){if(!nn(e)||Rr(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Vi(e)===n&&(n=n.ownerDocument.body),n}function KI(e,t){const n=Nn(e);if(Xp(e))return n;if(!nn(e)){let i=co(e);for(;i&&!ao(i);){if(Lt(i)&&!Sm(i))return i;i=co(i)}return n}let r=GS(e,t);for(;r&&n4(r)&&Sm(r);)r=GS(r,t);return r&&ao(r)&&Sm(r)&&!c0(r)?n:r||o4(e)||n}const Mq=async function(e){const t=this.getOffsetParent||KI,n=this.getDimensions,r=await n(e.floating);return{reference:Nq(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Dq(e){return Rr(e).direction==="rtl"}const jq={convertOffsetParentRelativeRectToViewportRelativeRect:_q,getDocumentElement:Vi,getClippingRect:Tq,getOffsetParent:KI,getElementRects:Mq,getClientRects:Oq,getDimensions:kq,getScale:al,isElement:Lt,isRTL:Dq};function YI(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Lq(e,t){let n=null,r;const i=Vi(e);function o(){var s;clearTimeout(r),(s=n)==null||s.disconnect(),n=null}function a(s,u){s===void 0&&(s=!1),u===void 0&&(u=1),o();const c=e.getBoundingClientRect(),{left:d,top:p,width:g,height:h}=c;if(s||t(),!g||!h)return;const v=el(p),b=el(i.clientWidth-(d+g)),y=el(i.clientHeight-(p+h)),w=el(d),E={rootMargin:-v+"px "+-b+"px "+-y+"px "+-w+"px",threshold:Er(0,oa(1,u))||1};let _=!0;function O(R){const I=R[0].intersectionRatio;if(I!==u){if(!_)return a();I?a(!1,I):r=setTimeout(()=>{a(!1,1e-7)},1e3)}I===1&&!YI(c,e.getBoundingClientRect())&&a(),_=!1}try{n=new IntersectionObserver(O,{...E,root:i.ownerDocument})}catch{n=new IntersectionObserver(O,E)}n.observe(e)}return a(!0),o}function My(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:u=!1}=r,c=x0(e),d=i||o?[...c?Jo(c):[],...t?Jo(t):[]]:[];d.forEach(w=>{i&&w.addEventListener("scroll",n,{passive:!0}),o&&w.addEventListener("resize",n)});const p=c&&s?Lq(c,n):null;let g=-1,h=null;a&&(h=new ResizeObserver(w=>{let[C]=w;C&&C.target===c&&h&&t&&(h.unobserve(t),cancelAnimationFrame(g),g=requestAnimationFrame(()=>{var E;(E=h)==null||E.observe(t)})),n()}),c&&!u&&h.observe(c),t&&h.observe(t));let v,b=u?Za(e):null;u&&y();function y(){const w=Za(e);b&&!YI(b,w)&&n(),b=w,v=requestAnimationFrame(y)}return n(),()=>{var w;d.forEach(C=>{i&&C.removeEventListener("scroll",n),o&&C.removeEventListener("resize",n)}),p?.(),(w=h)==null||w.disconnect(),h=null,u&&cancelAnimationFrame(v)}}const $q=bq,Fq=xq,Vq=mq,Bq=Cq,zq=vq,qS=gq,Wq=wq,Hq=(e,t,n)=>{const r=new Map,i={platform:jq,...n},o={...i.platform,_c:r};return hq(e,t,{...i,platform:o})};var Uq=typeof document<"u",Gq=function(){},Sd=Uq?j.useLayoutEffect:Gq;function Hd(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Hd(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){const o=i[r];if(!(o==="_owner"&&e.$$typeof)&&!Hd(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}function XI(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function KS(e,t){const n=XI(e);return Math.round(t*n)/n}function Em(e){const t=x.useRef(e);return Sd(()=>{t.current=e}),t}function ZI(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:o,floating:a}={},transform:s=!0,whileElementsMounted:u,open:c}=e,[d,p]=x.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[g,h]=x.useState(r);Hd(g,r)||h(r);const[v,b]=x.useState(null),[y,w]=x.useState(null),C=x.useCallback(Q=>{Q!==R.current&&(R.current=Q,b(Q))},[]),E=x.useCallback(Q=>{Q!==I.current&&(I.current=Q,w(Q))},[]),_=o||v,O=a||y,R=x.useRef(null),I=x.useRef(null),k=x.useRef(d),B=u!=null,L=Em(u),V=Em(i),D=Em(c),H=x.useCallback(()=>{if(!R.current||!I.current)return;const Q={placement:t,strategy:n,middleware:g};V.current&&(Q.platform=V.current),Hq(R.current,I.current,Q).then(pe=>{const K={...pe,isPositioned:D.current!==!1};J.current&&!Hd(k.current,K)&&(k.current=K,la.flushSync(()=>{p(K)}))})},[g,t,n,V,D]);Sd(()=>{c===!1&&k.current.isPositioned&&(k.current.isPositioned=!1,p(Q=>({...Q,isPositioned:!1})))},[c]);const J=x.useRef(!1);Sd(()=>(J.current=!0,()=>{J.current=!1}),[]),Sd(()=>{if(_&&(R.current=_),O&&(I.current=O),_&&O){if(L.current)return L.current(_,O,H);H()}},[_,O,H,L,B]);const te=x.useMemo(()=>({reference:R,floating:I,setReference:C,setFloating:E}),[C,E]),G=x.useMemo(()=>({reference:_,floating:O}),[_,O]),ee=x.useMemo(()=>{const Q={position:n,left:0,top:0};if(!G.floating)return Q;const pe=KS(G.floating,d.x),K=KS(G.floating,d.y);return s?{...Q,transform:"translate("+pe+"px, "+K+"px)",...XI(G.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:pe,top:K}},[n,s,G.floating,d.x,d.y]);return x.useMemo(()=>({...d,update:H,refs:te,elements:G,floatingStyles:ee}),[d,H,te,G,ee])}const qq=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:i}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?qS({element:r.current,padding:i}).fn(n):{}:r?qS({element:r,padding:i}).fn(n):{}}}},QI=(e,t)=>{const n=$q(e);return{name:n.name,fn:n.fn,options:[e,t]}},JI=(e,t)=>{const n=Fq(e);return{name:n.name,fn:n.fn,options:[e,t]}},eT=(e,t)=>({fn:Wq(e).fn,options:[e,t]}),tT=(e,t)=>{const n=Vq(e);return{name:n.name,fn:n.fn,options:[e,t]}},nT=(e,t)=>{const n=Bq(e);return{name:n.name,fn:n.fn,options:[e,t]}},rT=(e,t)=>{const n=zq(e);return{name:n.name,fn:n.fn,options:[e,t]}},Kq=(e,t)=>{const n=qq(e);return{name:n.name,fn:n.fn,options:[e,t]}},Yq={intentional:"onClick",sloppy:"onPointerDown"};function Xq(e){return{escapeKey:typeof e=="boolean"?e:e?.escapeKey??!1,outsidePress:typeof e=="boolean"?e:e?.outsidePress??!0}}function Zq(e,t={}){const n="rootStore"in e?e.rootStore:e,r=n.useState("open"),i=n.useState("floatingElement"),o=n.useState("referenceElement"),a=n.useState("domReferenceElement"),{onOpenChange:s,dataRef:u}=n.context,{enabled:c=!0,escapeKey:d=!0,outsidePress:p=!0,outsidePressEvent:g="sloppy",referencePress:h=!1,referencePressEvent:v="sloppy",ancestorScroll:b=!1,bubbles:y,externalTree:w}=t,C=rh(w),E=Me(typeof p=="function"?p:()=>!1),_=typeof p=="function"?E:p,O=x.useRef(!1),{escapeKey:R,outsidePress:I}=Xq(y),k=x.useRef(null),B=Xa(),L=Xa(),V=Me(()=>{L.clear(),u.current.insideReactTree=!1}),D=x.useRef(!1),H=x.useRef(""),J=Me($=>{H.current=$.pointerType}),te=Me(()=>{const $=H.current,ie=$==="pen"||!$?"mouse":$,Z=typeof g=="function"?g():g;return typeof Z=="string"?Z:Z[ie]}),G=Me($=>{if(!r||!c||!d||$.key!=="Escape"||D.current)return;const ie=u.current.floatingContext?.nodeId,Z=C?il(C.nodesRef.current,ie):[];if(!R&&Z.length>0){let fe=!0;if(Z.forEach(me=>{me.context?.open&&!me.context.dataRef.current.__escapeKeyBubbles&&(fe=!1)}),!fe)return}const Re=m4($)?$.nativeEvent:$,U=Xe(uI,Re);n.setOpen(!1,U),!R&&!U.isPropagationAllowed&&$.stopPropagation()}),ee=Me($=>{const ie=te();return ie==="intentional"&&$.type!=="click"||ie==="sloppy"&&$.type==="click"}),Q=Me(()=>{u.current.insideReactTree=!0,L.start(0,V)}),pe=Me(($,ie=!1)=>{if(ee($)){V();return}if(u.current.insideReactTree){V();return}if(te()==="intentional"&&ie||typeof _=="function"&&!_($))return;const Z=lr($),Re=`[${Wd("inert")}]`,U=Xt(n.select("floatingElement")).querySelectorAll(Re),fe=n.context.triggerElements;if(Z&&(fe.hasElement(Z)||fe.hasMatchingElement(be=>ft(be,Z))))return;let me=Lt(Z)?Z:null;for(;me&&!ao(me);){const be=co(me);if(ao(be)||!Lt(be))break;me=be}if(U.length&&Lt(Z)&&!g4(Z)&&!ft(Z,n.select("floatingElement"))&&Array.from(U).every(be=>!ft(me,be)))return;if(nn(Z)&&!("touches"in $)){const be=ao(Z),ke=Rr(Z),et=/auto|scroll/,Tt=be||et.test(ke.overflowX),Dn=be||et.test(ke.overflowY),Ct=Tt&&Z.clientWidth>0&&Z.scrollWidth>Z.clientWidth,ot=Dn&&Z.clientHeight>0&&Z.scrollHeight>Z.clientHeight,kt=ke.direction==="rtl",mn=ot&&(kt?$.offsetX<=Z.offsetWidth-Z.clientWidth:$.offsetX>Z.clientWidth),on=Ct&&$.offsetY>Z.clientHeight;if(mn||on)return}const de=u.current.floatingContext?.nodeId,ve=C&&il(C.nodesRef.current,de).some(be=>li($,be.context?.elements.floating));if(li($,n.select("floatingElement"))||li($,n.select("domReferenceElement"))||ve)return;const le=C?il(C.nodesRef.current,de):[];if(le.length>0){let be=!0;if(le.forEach(ke=>{ke.context?.open&&!ke.context.dataRef.current.__outsidePressBubbles&&(be=!1)}),!be)return}n.setOpen(!1,Xe(o0,$)),V()}),K=Me($=>{te()!=="sloppy"||$.pointerType==="touch"||!n.select("open")||!c||li($,n.select("floatingElement"))||li($,n.select("domReferenceElement"))||pe($)}),Ae=Me($=>{if(te()!=="sloppy"||!n.select("open")||!c||li($,n.select("floatingElement"))||li($,n.select("domReferenceElement")))return;const ie=$.touches[0];ie&&(k.current={startTime:Date.now(),startX:ie.clientX,startY:ie.clientY,dismissOnTouchEnd:!1,dismissOnMouseDown:!0},B.start(1e3,()=>{k.current&&(k.current.dismissOnTouchEnd=!1,k.current.dismissOnMouseDown=!1)}))}),Se=Me($=>{const ie=lr($);function Z(){Ae($),ie?.removeEventListener($.type,Z)}ie?.addEventListener($.type,Z)}),$e=Me($=>{const ie=O.current;if(O.current=!1,B.clear(),$.type==="mousedown"&&k.current&&!k.current.dismissOnMouseDown)return;const Z=lr($);function Re(){$.type==="pointerdown"?K($):pe($,ie),Z?.removeEventListener($.type,Re)}Z?.addEventListener($.type,Re)}),we=Me($=>{if(te()!=="sloppy"||!k.current||li($,n.select("floatingElement"))||li($,n.select("domReferenceElement")))return;const ie=$.touches[0];if(!ie)return;const Z=Math.abs(ie.clientX-k.current.startX),Re=Math.abs(ie.clientY-k.current.startY),U=Math.sqrt(Z*Z+Re*Re);U>5&&(k.current.dismissOnTouchEnd=!0),U>10&&(pe($),B.clear(),k.current=null)}),Ce=Me($=>{const ie=lr($);function Z(){we($),ie?.removeEventListener($.type,Z)}ie?.addEventListener($.type,Z)}),ze=Me($=>{te()!=="sloppy"||!k.current||li($,n.select("floatingElement"))||li($,n.select("domReferenceElement"))||(k.current.dismissOnTouchEnd&&pe($),B.clear(),k.current=null)}),Ke=Me($=>{const ie=lr($);function Z(){ze($),ie?.removeEventListener($.type,Z)}ie?.addEventListener($.type,Z)});x.useEffect(()=>{if(!r||!c)return;u.current.__escapeKeyBubbles=R,u.current.__outsidePressBubbles=I;const $=new pl;function ie(me){n.setOpen(!1,Xe(Yr,me))}function Z(){$.clear(),D.current=!0}function Re(){$.start(Zp()?5:0,()=>{D.current=!1})}const U=Xt(i);U.addEventListener("pointerdown",J,!0),d&&(U.addEventListener("keydown",G),U.addEventListener("compositionstart",Z),U.addEventListener("compositionend",Re)),_&&(U.addEventListener("click",$e,!0),U.addEventListener("pointerdown",$e,!0),U.addEventListener("touchstart",Se,!0),U.addEventListener("touchmove",Ce,!0),U.addEventListener("touchend",Ke,!0),U.addEventListener("mousedown",$e,!0));let fe=[];return b&&(Lt(a)&&(fe=Jo(a)),Lt(i)&&(fe=fe.concat(Jo(i))),!Lt(o)&&o&&o.contextElement&&(fe=fe.concat(Jo(o.contextElement)))),fe=fe.filter(me=>me!==U.defaultView?.visualViewport),fe.forEach(me=>{me.addEventListener("scroll",ie,{passive:!0})}),()=>{U.removeEventListener("pointerdown",J,!0),d&&(U.removeEventListener("keydown",G),U.removeEventListener("compositionstart",Z),U.removeEventListener("compositionend",Re)),_&&(U.removeEventListener("click",$e,!0),U.removeEventListener("pointerdown",$e,!0),U.removeEventListener("touchstart",Se,!0),U.removeEventListener("touchmove",Ce,!0),U.removeEventListener("touchend",Ke,!0),U.removeEventListener("mousedown",$e,!0)),fe.forEach(me=>{me.removeEventListener("scroll",ie)}),$.clear(),O.current=!1}},[u,i,o,a,d,_,r,s,b,c,R,I,G,pe,$e,K,Se,Ce,Ke,J,n]),x.useEffect(V,[_,V]);const Fe=x.useMemo(()=>({onKeyDown:G,...h&&{[Yq[v]]:$=>{n.setOpen(!1,Xe(Sy,$.nativeEvent))},...v!=="intentional"&&{onClick($){n.setOpen(!1,Xe(Sy,$.nativeEvent))}}}}),[G,n,h,v]),Y=Me($=>{const ie=lr($.nativeEvent);!ft(n.select("floatingElement"),ie)||$.button!==0||(O.current=!0)}),oe=Me($=>{!r||!c||$.button!==0||(O.current=!0)}),ne=x.useMemo(()=>({onKeyDown:G,onPointerDown:Y,onMouseDown:Y,onMouseUp:Y,onClickCapture:Q,onMouseDownCapture($){Q(),oe($)},onPointerDownCapture($){Q(),oe($)},onMouseUpCapture:Q,onTouchEndCapture:Q,onTouchMoveCapture:Q}),[G,Y,Q,oe]);return x.useMemo(()=>c?{reference:Fe,floating:ne,trigger:Fe}:{},[c,Fe,ne])}var Qq=(e,t,n)=>{if(t.length===1&&t[0]===n){let r=!1;try{const i={};e(i)===i&&(r=!0)}catch{}if(r){let i;try{throw new Error}catch(o){({stack:i}=o)}console.warn(`The result function returned its own inputs without modification. e.g
|
|
17
|
+
`))},[JSON.stringify(t)])}const u=x.useCallback(c=>{i||a(c)},[]);return[s,u]}const FC={};function ti(e,t){const n=x.useRef(FC);return n.current===FC&&(n.current=e(t)),n}const Nm=x[`useInsertionEffect${Math.random().toFixed(1)}`.slice(0,-3)],E4=Nm&&Nm!==x.useLayoutEffect?Nm:e=>e();function Le(e){const t=ti(_4).current;return t.next=e,E4(t.effect),t.trampoline}function _4(){const e={next:void 0,callback:O4,trampoline:(...t)=>e.callback?.(...t),effect:()=>{e.callback=e.next}};return e}function O4(){if(process.env.NODE_ENV!=="production")throw new Error("Base UI: Cannot call an event handler while rendering.")}const P4=()=>{},Ve=typeof document<"u"?x.useLayoutEffect:P4,Cx=x.createContext({register:()=>{},unregister:()=>{},subscribeMapChange:()=>()=>{},elementsRef:{current:[]},nextIndexRef:{current:0}});process.env.NODE_ENV!=="production"&&(Cx.displayName="CompositeListContext");function A4(){return x.useContext(Cx)}function EI(e){const{children:t,elementsRef:n,labelsRef:r,onMapChange:i}=e,o=Le(i),a=x.useRef(0),s=ti(I4).current,u=ti(R4).current,[c,f]=x.useState(0),p=x.useRef(c),g=Le((w,S)=>{u.set(w,S??null),p.current+=1,f(p.current)}),h=Le(w=>{u.delete(w),p.current+=1,f(p.current)}),v=x.useMemo(()=>{const w=new Map;return Array.from(u.keys()).filter(E=>E.isConnected).sort(T4).forEach((E,_)=>{const P=u.get(E)??{};w.set(E,{...P,index:_})}),w},[u,c]);Ve(()=>{if(typeof MutationObserver!="function"||v.size===0)return;const w=new MutationObserver(S=>{const E=new Set,_=P=>E.has(P)?E.delete(P):E.add(P);S.forEach(P=>{P.removedNodes.forEach(_),P.addedNodes.forEach(_)}),E.size===0&&(p.current+=1,f(p.current))});return v.forEach((S,E)=>{E.parentElement&&w.observe(E.parentElement,{childList:!0})}),()=>{w.disconnect()}},[v]),Ve(()=>{p.current===c&&(n.current.length!==v.size&&(n.current.length=v.size),r&&r.current.length!==v.size&&(r.current.length=v.size),a.current=v.size),o(v)},[o,v,n,r,c]),Ve(()=>()=>{n.current=[]},[n]),Ve(()=>()=>{r&&(r.current=[])},[r]);const b=Le(w=>(s.add(w),()=>{s.delete(w)}));Ve(()=>{s.forEach(w=>w(v))},[s,v]);const y=x.useMemo(()=>({register:g,unregister:h,subscribeMapChange:b,elementsRef:n,labelsRef:r,nextIndexRef:a}),[g,h,b,n,r,a]);return O.jsx(Cx.Provider,{value:y,children:t})}function R4(){return new Map}function I4(){return new Set}function T4(e,t){const n=e.compareDocumentPosition(t);return n&Node.DOCUMENT_POSITION_FOLLOWING||n&Node.DOCUMENT_POSITION_CONTAINED_BY?-1:n&Node.DOCUMENT_POSITION_PRECEDING||n&Node.DOCUMENT_POSITION_CONTAINS?1:0}const _I=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(_I.displayName="DirectionContext");function OI(){return x.useContext(_I)?.direction??"ltr"}function mi(e,...t){const n=new URL("https://base-ui.com/production-error");return n.searchParams.set("code",e.toString()),t.forEach(r=>n.searchParams.append("args[]",r)),`Base UI error #${e}; visit ${n} for the full message.`}function Uu(e,t,n,r){const i=ti(PI).current;return N4(i,e,t,n,r)&&AI(i,[e,t,n,r]),i.callback}function k4(e){const t=ti(PI).current;return M4(t,e)&&AI(t,e),t.callback}function PI(){return{callback:null,cleanup:null,refs:[]}}function N4(e,t,n,r,i){return e.refs[0]!==t||e.refs[1]!==n||e.refs[2]!==r||e.refs[3]!==i}function M4(e,t){return e.refs.length!==t.length||e.refs.some((n,r)=>n!==t[r])}function AI(e,t){if(e.refs=t,t.every(n=>n==null)){e.callback=null;return}e.callback=n=>{if(e.cleanup&&(e.cleanup(),e.cleanup=null),n!=null){const r=Array(t.length).fill(null);for(let i=0;i<t.length;i+=1){const o=t[i];if(o!=null)switch(typeof o){case"function":{const a=o(n);typeof a=="function"&&(r[i]=a);break}case"object":{o.current=n;break}}}e.cleanup=()=>{for(let i=0;i<t.length;i+=1){const o=t[i];if(o!=null)switch(typeof o){case"function":{const a=r[i];typeof a=="function"?a():o(null);break}case"object":{o.current=null;break}}}}}}}const D4=parseInt(x.version,10);function Ex(e){return D4>=e}function VC(e){if(!x.isValidElement(e))return null;const t=e,n=t.props;return(Ex(19)?n?.ref:t.ref)??null}function jy(e,t){if(e&&!t)return e;if(!e&&t)return t;if(e||t)return{...e,...t}}function j4(e,t){const n={};for(const r in e){const i=e[r];if(t?.hasOwnProperty(r)){const o=t[r](i);o!=null&&Object.assign(n,o);continue}i===!0?n[`data-${r.toLowerCase()}`]="":i&&(n[`data-${r.toLowerCase()}`]=i.toString())}return n}function L4(e,t){return typeof e=="function"?e(t):e}function $4(e,t){return typeof e=="function"?e(t):e}const Du={};function RI(e,t,n,r,i){let o={...Ly(e,Du)};return t&&(o=Id(o,t)),n&&(o=Id(o,n)),r&&(o=Id(o,r)),o}function F4(e){if(e.length===0)return Du;if(e.length===1)return Ly(e[0],Du);let t={...Ly(e[0],Du)};for(let n=1;n<e.length;n+=1)t=Id(t,e[n]);return t}function Id(e,t){return II(t)?t(e):V4(e,t)}function V4(e,t){if(!t)return e;for(const n in t){const r=t[n];switch(n){case"style":{e[n]=jy(e.style,r);break}case"className":{e[n]=TI(e.className,r);break}default:B4(n,r)?e[n]=z4(e[n],r):e[n]=r}}return e}function B4(e,t){const n=e.charCodeAt(0),r=e.charCodeAt(1),i=e.charCodeAt(2);return n===111&&r===110&&i>=65&&i<=90&&(typeof t=="function"||typeof t>"u")}function II(e){return typeof e=="function"}function Ly(e,t){return II(e)?e(t):e??Du}function z4(e,t){return t?e?n=>{if(W4(n)){const i=n;$y(i);const o=t(i);return i.baseUIHandlerPrevented||e?.(i),o}const r=t(n);return e?.(n),r}:t:e}function $y(e){return e.preventBaseUIHandler=()=>{e.baseUIHandlerPrevented=!0},e}function TI(e,t){return t?e?t+" "+e:t:e}function W4(e){return e!=null&&typeof e=="object"&&"nativeEvent"in e}function Ht(){}const Hf=Object.freeze([]),Zn=Object.freeze({}),H4={style:{transition:"none"}},U4="data-base-ui-click-trigger",G4={fallbackAxisSide:"none"},q4={clipPath:"inset(50%)",position:"fixed",top:0,left:0};function tr(e,t,n={}){const r=t.render,i=K4(t,n);if(n.enabled===!1)return null;const o=n.state??Zn;return X4(e,r,i,o)}function K4(e,t={}){const{className:n,style:r,render:i}=e,{state:o=Zn,ref:a,props:s,stateAttributesMapping:u,enabled:c=!0}=t,f=c?L4(n,o):void 0,p=c?$4(r,o):void 0,g=c?j4(o,u):Zn,h=c?jy(g,Array.isArray(s)?F4(s):s)??Zn:Zn;return typeof document<"u"&&(c?Array.isArray(a)?h.ref=k4([h.ref,VC(i),...a]):h.ref=Uu(h.ref,VC(i),a):Uu(null,null)),c?(f!==void 0&&(h.className=TI(h.className,f)),p!==void 0&&(h.style=jy(h.style,p)),h):Zn}const Y4=Symbol.for("react.lazy");function X4(e,t,n,r){if(t){if(typeof t=="function")return t(n,r);const i=RI(n,t.props);i.ref=n.ref;let o=t;if(o?.$$typeof===Y4&&(o=x.Children.toArray(t)[0]),process.env.NODE_ENV!=="production"&&!x.isValidElement(o))throw new Error(["Base UI: The `render` prop was provided an invalid React element as `React.isValidElement(render)` is `false`.","A valid React element must be provided to the `render` prop because it is cloned with props to replace the default element.","https://base-ui.com/r/invalid-render-prop"].join(`
|
|
18
|
+
`));return x.cloneElement(o,i)}if(e&&typeof e=="string")return Z4(e,n);throw new Error(process.env.NODE_ENV!=="production"?"Base UI: Render element or function are not defined.":mi(8))}function Z4(e,t){return e==="button"?$.createElement("button",{type:"button",...t,key:t.key}):e==="img"?$.createElement("img",{alt:"",...t,key:t.key}):x.createElement(e,t)}const Xr="none",Fy="trigger-press",Q4="trigger-hover",_x="outside-press",J4="item-press",BC="clear-press",eq="chip-remove-press",ol="input-change",Xo="input-clear",tq="input-press",rh="focus-out",kI="escape-key",ju="list-navigation";function Ze(e,t,n,r){let i=!1,o=!1;const a=Zn;return{reason:e,event:t??new Event("base-ui"),cancel(){i=!0},allowPropagation(){o=!0},get isCanceled(){return i},get isPropagationAllowed(){return o},trigger:n,...a}}function pu(e,t,n){const r=n??Zn;return{reason:e,event:t??new Event("base-ui"),...r}}const Vy={...x};let zC=0;function nq(e,t="mui"){const[n,r]=x.useState(e),i=e||n;return x.useEffect(()=>{n==null&&(zC+=1,r(`${t}-${zC}`))},[n,t]),i}const WC=Vy.useId;function Ox(e,t){if(WC!==void 0){const n=WC();return e??(t?`${t}-${n}`:n)}return nq(e,t)}function Px(e){return Ox(e,"base-ui")}const rq=[];function NI(e){x.useEffect(e,rq)}const Uf=null;let HC=globalThis.requestAnimationFrame;class iq{callbacks=[];callbacksCount=0;nextId=1;startId=1;isScheduled=!1;tick=t=>{this.isScheduled=!1;const n=this.callbacks,r=this.callbacksCount;if(this.callbacks=[],this.callbacksCount=0,this.startId=this.nextId,r>0)for(let i=0;i<n.length;i+=1)n[i]?.(t)};request(t){const n=this.nextId;this.nextId+=1,this.callbacks.push(t),this.callbacksCount+=1;const r=process.env.NODE_ENV!=="production"&&HC!==requestAnimationFrame&&(HC=requestAnimationFrame,!0);return(!this.isScheduled||r)&&(requestAnimationFrame(this.tick),this.isScheduled=!0),n}cancel(t){const n=t-this.startId;n<0||n>=this.callbacks.length||(this.callbacks[n]=null,this.callbacksCount-=1)}}const Gf=new iq;class Ri{static create(){return new Ri}static request(t){return Gf.request(t)}static cancel(t){return Gf.cancel(t)}currentId=Uf;request(t){this.cancel(),this.currentId=Gf.request(()=>{this.currentId=Uf,t()})}cancel=()=>{this.currentId!==Uf&&(Gf.cancel(this.currentId),this.currentId=Uf)};disposeEffect=()=>this.cancel}function Ax(){const e=ti(Ri.create).current;return NI(e.disposeEffect),e}function no(e){return e==null?e:"current"in e?e.current:e}let Gu=(function(e){return e.startingStyle="data-starting-style",e.endingStyle="data-ending-style",e})({});const oq={[Gu.startingStyle]:""},aq={[Gu.endingStyle]:""},MI={transitionStatus(e){return e==="starting"?oq:e==="ending"?aq:null}};function sq(e,t=!1,n=!0){const r=Ax();return Le((i,o=null)=>{r.cancel();function a(){Wi.flushSync(i)}const s=no(e);if(s==null)return;const u=s;if(typeof u.getAnimations!="function"||globalThis.BASE_UI_ANIMATIONS_DISABLED)i();else{let c=function(){const p=Gu.startingStyle;if(!u.hasAttribute(p)){r.request(f);return}const g=new MutationObserver(()=>{u.hasAttribute(p)||(g.disconnect(),f())});g.observe(u,{attributes:!0,attributeFilter:[p]}),o?.addEventListener("abort",()=>g.disconnect(),{once:!0})},f=function(){Promise.all(u.getAnimations().map(p=>p.finished)).then(()=>{o?.aborted||a()}).catch(()=>{const p=u.getAnimations();if(n){if(o?.aborted)return;a()}else p.length>0&&p.some(g=>g.pending||g.playState!=="finished")&&f()})};if(t){c();return}r.request(f)}})}function DI(e,t=!1,n=!1){const[r,i]=x.useState(e&&t?"idle":void 0),[o,a]=x.useState(e);return e&&!o&&(a(!0),i("starting")),!e&&o&&r!=="ending"&&!n&&i("ending"),!e&&!o&&r==="ending"&&i(void 0),Ve(()=>{if(!e&&o&&r!=="ending"&&n){const s=Ri.request(()=>{i("ending")});return()=>{Ri.cancel(s)}}},[e,o,r,n]),Ve(()=>{if(!e||t)return;const s=Ri.request(()=>{i(void 0)});return()=>{Ri.cancel(s)}},[t,e]),Ve(()=>{if(!e||!t)return;e&&o&&r!=="idle"&&i("starting");const s=Ri.request(()=>{i("idle")});return()=>{Ri.cancel(s)}},[t,e,o,i,r]),x.useMemo(()=>({mounted:o,setMounted:a,transitionStatus:r}),[o,r])}let jI=(function(e){return e[e.None=0]="None",e[e.GuessFromOrder=1]="GuessFromOrder",e})({});function LI(e={}){const{label:t,metadata:n,textRef:r,indexGuessBehavior:i,index:o}=e,{register:a,unregister:s,subscribeMapChange:u,elementsRef:c,labelsRef:f,nextIndexRef:p}=A4(),g=x.useRef(-1),[h,v]=x.useState(o??(i===jI.GuessFromOrder?()=>{if(g.current===-1){const w=p.current;p.current+=1,g.current=w}return g.current}:-1)),b=x.useRef(null),y=x.useCallback(w=>{if(b.current=w,h!==-1&&w!==null&&(c.current[h]=w,f)){const S=t!==void 0;f.current[h]=S?t:r?.current?.textContent??w.textContent}},[h,c,f,t,r]);return Ve(()=>{if(o!=null)return;const w=b.current;if(w)return a(w,n),()=>{s(w)}},[o,a,s,n]),Ve(()=>{if(o==null)return u(w=>{const S=b.current?w.get(b.current)?.index:null;S!=null&&v(S)})},[o,u,v]),x.useMemo(()=>({ref:y,index:h}),[h,y])}function ih(){return typeof window<"u"}function ha(e){return Rx(e)?(e.nodeName||"").toLowerCase():"#document"}function Nn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Hi(e){var t;return(t=(Rx(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Rx(e){return ih()?e instanceof Node||e instanceof Nn(e).Node:!1}function $t(e){return ih()?e instanceof Element||e instanceof Nn(e).Element:!1}function nn(e){return ih()?e instanceof HTMLElement||e instanceof Nn(e).HTMLElement:!1}function By(e){return!ih()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Nn(e).ShadowRoot}function ga(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=Ir(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&i!=="inline"&&i!=="contents"}function lq(e){return/^(table|td|th)$/.test(ha(e))}function oh(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}const uq=/transform|translate|scale|rotate|perspective|filter/,cq=/paint|layout|strict|content/,$a=e=>!!e&&e!=="none";let Mm;function Ix(e){const t=$t(e)?Ir(e):e;return $a(t.transform)||$a(t.translate)||$a(t.scale)||$a(t.rotate)||$a(t.perspective)||!ah()&&($a(t.backdropFilter)||$a(t.filter))||uq.test(t.willChange||"")||cq.test(t.contain||"")}function fq(e){let t=mo(e);for(;nn(t)&&!co(t);){if(Ix(t))return t;if(oh(t))return null;t=mo(t)}return null}function ah(){return Mm==null&&(Mm=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),Mm}function co(e){return/^(html|body|#document)$/.test(ha(e))}function Ir(e){return Nn(e).getComputedStyle(e)}function sh(e){return $t(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function mo(e){if(ha(e)==="html")return e;const t=e.assignedSlot||e.parentNode||By(e)&&e.host||Hi(e);return By(t)?t.host:t}function $I(e){const t=mo(e);return co(t)?e.ownerDocument?e.ownerDocument.body:e.body:nn(t)&&ga(t)?t:$I(t)}function ia(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const i=$I(e),o=i===((r=e.ownerDocument)==null?void 0:r.body),a=Nn(i);if(o){const s=zy(a);return t.concat(a,a.visualViewport||[],ga(i)?i:[],s&&n?ia(s):[])}else return t.concat(i,ia(i,[],n))}function zy(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}let Wy;process.env.NODE_ENV!=="production"&&(Wy=new Set);function UC(...e){if(process.env.NODE_ENV!=="production"){const t=e.join(" ");Wy.has(t)||(Wy.add(t),console.error(`Base UI: ${t}`))}}const FI=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(FI.displayName="CompositeRootContext");function dq(e=!1){const t=x.useContext(FI);if(t===void 0&&!e)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: CompositeRootContext is missing. Composite parts must be placed within <Composite.Root>.":mi(16));return t}function pq(e){const{focusableWhenDisabled:t,disabled:n,composite:r=!1,tabIndex:i=0,isNativeButton:o}=e,a=r&&t!==!1,s=r&&t===!1;return{props:x.useMemo(()=>{const c={onKeyDown(f){n&&t&&f.key!=="Tab"&&f.preventDefault()}};return r||(c.tabIndex=i,!o&&n&&(c.tabIndex=t?i:-1)),(o&&(t||a)||!o&&n)&&(c["aria-disabled"]=n),o&&(!t||s)&&(c.disabled=n),c},[r,n,t,a,s,o,i])}}function lh(e={}){const{disabled:t=!1,focusableWhenDisabled:n,tabIndex:r=0,native:i=!0}=e,o=x.useRef(null),a=dq(!0)!==void 0,s=Le(()=>{const g=o.current;return!!(g?.tagName==="A"&&g?.href)}),{props:u}=pq({focusableWhenDisabled:n,disabled:t,composite:a,tabIndex:r,isNativeButton:i});process.env.NODE_ENV!=="production"&&x.useEffect(()=>{if(!o.current)return;const g=o.current.tagName==="BUTTON";if(i){if(!g){const h=Vy.captureOwnerStack?.()||"";UC(`A component that acts as a button expected a native <button> because the \`nativeButton\` prop is true. Rendering a non-<button> removes native button semantics, which can impact forms and accessibility. Use a real <button> in the \`render\` prop, or set \`nativeButton\` to \`false\`.${h}`)}}else if(g){const h=Vy.captureOwnerStack?.()||"";UC(`A component that acts as a button expected a non-<button> because the \`nativeButton\` prop is false. Rendering a <button> keeps native behavior while Base UI applies non-native attributes and handlers, which can add unintended extra attributes (such as \`role\` or \`aria-disabled\`). Use a non-<button> in the \`render\` prop, or set \`nativeButton\` to \`true\`.${h}`)}},[i]);const c=x.useCallback(()=>{const g=o.current;hq(g)&&a&&t&&u.disabled===void 0&&g.disabled&&(g.disabled=!1)},[t,u.disabled,a]);Ve(c,[c]);const f=x.useCallback((g={})=>{const{onClick:h,onMouseDown:v,onKeyUp:b,onKeyDown:y,onPointerDown:w,...S}=g;return RI({type:i?"button":void 0,onClick(_){if(t){_.preventDefault();return}h?.(_)},onMouseDown(_){t||v?.(_)},onKeyDown(_){if(t||($y(_),y?.(_)),_.baseUIHandlerPrevented)return;const P=_.target===_.currentTarget&&!i&&!s()&&!t,R=_.key==="Enter",I=_.key===" ";P&&((I||R)&&_.preventDefault(),R&&h?.(_))},onKeyUp(_){t||($y(_),b?.(_)),!_.baseUIHandlerPrevented&&_.target===_.currentTarget&&!i&&!t&&_.key===" "&&h?.(_)},onPointerDown(_){if(t){_.preventDefault();return}w?.(_)}},i?void 0:{role:"button"},u,S)},[t,u,i,s]),p=Le(g=>{o.current=g,c()});return{getButtonProps:f,buttonRef:p}}function hq(e){return nn(e)&&e.tagName==="BUTTON"}const ms=typeof navigator<"u",Dm=vq(),VI=bq(),Tx=yq(),BI=typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter:none"),zI=Dm.platform==="MacIntel"&&Dm.maxTouchPoints>1?!0:/iP(hone|ad|od)|iOS/.test(Dm.platform),GC=ms&&/firefox/i.test(Tx),gq=ms&&/apple/i.test(navigator.vendor),Bd=ms&&/android/i.test(VI)||/android/i.test(Tx);ms&&VI.toLowerCase().startsWith("mac")&&navigator.maxTouchPoints;const mq=Tx.includes("jsdom/");function vq(){if(!ms)return{platform:"",maxTouchPoints:-1};const e=navigator.userAgentData;return e?.platform?{platform:e.platform,maxTouchPoints:navigator.maxTouchPoints}:{platform:navigator.platform??"",maxTouchPoints:navigator.maxTouchPoints??-1}}function yq(){if(!ms)return"";const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map(({brand:t,version:n})=>`${t}/${n}`).join(" "):navigator.userAgent}function bq(){if(!ms)return"";const e=navigator.userAgentData;return e?.platform?e.platform:navigator.platform??""}const Hy="data-base-ui-focusable",WI="active",HI="selected",xq="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])",oa="ArrowLeft",aa="ArrowRight",kx="ArrowUp",fc="ArrowDown";function io(e){let t=e.activeElement;for(;t?.shadowRoot?.activeElement!=null;)t=t.shadowRoot.activeElement;return t}function pt(e,t){if(!e||!t)return!1;const n=t.getRootNode?.();if(e.contains(t))return!0;if(n&&By(n)){let r=t;for(;r;){if(e===r)return!0;r=r.parentNode||r.host}}return!1}function ur(e){return"composedPath"in e?e.composedPath()[0]:e.target}function ui(e,t){if(t==null)return!1;if("composedPath"in e)return e.composedPath().includes(t);const n=e;return n.target!=null&&t.contains(n.target)}function wq(e){return e.matches("html,body")}function Nx(e){return nn(e)&&e.matches(xq)}function Uy(e){return e?e.getAttribute("role")==="combobox"&&Nx(e):!1}function Gy(e){return e?e.hasAttribute(Hy)?e:e.querySelector(`[${Hy}]`)||e:null}function cl(e,t,n=!0){return e.filter(i=>i.parentId===t&&(!n||i.context?.open)).flatMap(i=>[i,...cl(e,i.id,n)])}function qC(e,t){let n=[],r=e.find(i=>i.id===t)?.parentId;for(;r;){const i=e.find(o=>o.id===r);r=i?.parentId,i&&(n=n.concat(i))}return n}function Lt(e){e.preventDefault(),e.stopPropagation()}function Sq(e){return"nativeEvent"in e}function UI(e){return e.pointerType===""&&e.isTrusted?!0:Bd&&e.pointerType?e.type==="click"&&e.buttons===1:e.detail===0&&!e.pointerType}function GI(e){return mq?!1:!Bd&&e.width===0&&e.height===0||Bd&&e.width===1&&e.height===1&&e.pressure===0&&e.detail===0&&e.pointerType==="mouse"||e.width<1&&e.height<1&&e.pressure===0&&e.detail===0&&e.pointerType==="touch"}function KC(e,t){return["mouse","pen"].includes(e)}function qI(e){const t=e.type;return t==="click"||t==="mousedown"||t==="keydown"||t==="keyup"}const Cq=["top","right","bottom","left"],ua=Math.min,_r=Math.max,zd=Math.round,al=Math.floor,Ni=e=>({x:e,y:e}),Eq={left:"right",right:"left",bottom:"top",top:"bottom"};function Wd(e,t,n){return _r(e,ua(t,n))}function Li(e,t){return typeof e=="function"?e(t):e}function Rr(e){return e.split("-")[0]}function Eo(e){return e.split("-")[1]}function Mx(e){return e==="x"?"y":"x"}function uh(e){return e==="y"?"height":"width"}function Qr(e){const t=e[0];return t==="t"||t==="b"?"y":"x"}function ch(e){return Mx(Qr(e))}function _q(e,t,n){n===void 0&&(n=!1);const r=Eo(e),i=ch(e),o=uh(i);let a=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[o]>t.floating[o]&&(a=Hd(a)),[a,Hd(a)]}function Oq(e){const t=Hd(e);return[qy(e),t,qy(t)]}function qy(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}const YC=["left","right"],XC=["right","left"],Pq=["top","bottom"],Aq=["bottom","top"];function Rq(e,t,n){switch(e){case"top":case"bottom":return n?t?XC:YC:t?YC:XC;case"left":case"right":return t?Pq:Aq;default:return[]}}function Iq(e,t,n,r){const i=Eo(e);let o=Rq(Rr(e),n==="start",r);return i&&(o=o.map(a=>a+"-"+i),t&&(o=o.concat(o.map(qy)))),o}function Hd(e){const t=Rr(e);return Eq[t]+e.slice(t.length)}function Tq(e){return{top:0,right:0,bottom:0,left:0,...e}}function Dx(e){return typeof e!="number"?Tq(e):{top:e,right:e,bottom:e,left:e}}function Ud(e){const{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function qf(e,t,n){return Math.floor(e/t)!==n}function Lu(e,t){return t<0||t>=e.current.length}function jm(e,t){return Vn(e,{disabledIndices:t})}function ZC(e,t){return Vn(e,{decrement:!0,startingIndex:e.current.length,disabledIndices:t})}function Vn(e,{startingIndex:t=-1,decrement:n=!1,disabledIndices:r,amount:i=1}={}){let o=t;do o+=n?-i:i;while(o>=0&&o<=e.current.length-1&&$u(e,o,r));return o}function kq(e,{event:t,orientation:n,loopFocus:r,rtl:i,cols:o,disabledIndices:a,minIndex:s,maxIndex:u,prevIndex:c,stopEvent:f=!1}){let p=c;const g=[],h={};let v=!1;{let w=null,S=-1;e.current.forEach((E,_)=>{if(E==null)return;const P=E.closest('[role="row"]');P&&(v=!0),(P!==w||S===-1)&&(w=P,S+=1,g[S]=[]),g[S].push(_),h[_]=S})}const b=v&&g.length>0&&g.some(w=>w.length!==o);function y(w){if(!b||c===-1)return;const S=h[c];if(S==null)return;const E=g[S].indexOf(c);let _=w==="up"?S-1:S+1;r&&(_<0?_=g.length-1:_>=g.length&&(_=0));const P=new Set;for(;_>=0&&_<g.length&&!P.has(_);){P.add(_);const R=g[_];if(R.length===0){_=w==="up"?_-1:_+1;continue}const I=Math.min(E,R.length-1);for(let k=I;k>=0;k-=1){const B=R[k];if(!$u(e,B,a))return B}_=w==="up"?_-1:_+1,r&&(_<0?_=g.length-1:_>=g.length&&(_=0))}}if(t.key===kx){const w=y("up");if(w!==void 0)f&&Lt(t),p=w;else{if(f&&Lt(t),c===-1)p=u;else if(p=Vn(e,{startingIndex:p,amount:o,decrement:!0,disabledIndices:a}),r&&(c-o<s||p<0)){const S=c%o,E=u%o,_=u-(E-S);E===S?p=u:p=E>S?_:_-o}Lu(e,p)&&(p=c)}}if(t.key===fc){const w=y("down");w!==void 0?(f&&Lt(t),p=w):(f&&Lt(t),c===-1?p=s:(p=Vn(e,{startingIndex:c,amount:o,disabledIndices:a}),r&&c+o>u&&(p=Vn(e,{startingIndex:c%o-o,amount:o,disabledIndices:a}))),Lu(e,p)&&(p=c))}if(n==="both"){const w=al(c/o);t.key===(i?oa:aa)&&(f&&Lt(t),c%o!==o-1?(p=Vn(e,{startingIndex:c,disabledIndices:a}),r&&qf(p,o,w)&&(p=Vn(e,{startingIndex:c-c%o-1,disabledIndices:a}))):r&&(p=Vn(e,{startingIndex:c-c%o-1,disabledIndices:a})),qf(p,o,w)&&(p=c)),t.key===(i?aa:oa)&&(f&&Lt(t),c%o!==0?(p=Vn(e,{startingIndex:c,decrement:!0,disabledIndices:a}),r&&qf(p,o,w)&&(p=Vn(e,{startingIndex:c+(o-c%o),decrement:!0,disabledIndices:a}))):r&&(p=Vn(e,{startingIndex:c+(o-c%o),decrement:!0,disabledIndices:a})),qf(p,o,w)&&(p=c));const S=al(u/o)===w;Lu(e,p)&&(r&&S?p=t.key===(i?aa:oa)?u:Vn(e,{startingIndex:c-c%o-1,disabledIndices:a}):p=c)}return p}function Nq(e,t,n){const r=[];let i=0;return e.forEach(({width:o,height:a},s)=>{if(o>t&&process.env.NODE_ENV!=="production")throw new Error(`[Floating UI]: Invalid grid - item width at index ${s} is greater than grid columns`);let u=!1;for(;!u;){const c=[];for(let f=0;f<o;f+=1)for(let p=0;p<a;p+=1)c.push(i+f+p*t);i%t+o<=t&&c.every(f=>r[f]==null)?(c.forEach(f=>{r[f]=s}),u=!0):i+=1}}),[...r]}function Mq(e,t,n,r,i){if(e===-1)return-1;const o=n.indexOf(e),a=t[e];switch(i){case"tl":return o;case"tr":return a?o+a.width-1:o;case"bl":return a?o+(a.height-1)*r:o;case"br":return n.lastIndexOf(e);default:return-1}}function Dq(e,t){return t.flatMap((n,r)=>e.includes(n)?[r]:[])}function $u(e,t,n){if(typeof n=="function")return n(t);if(n)return n.includes(t);const r=e.current[t];return r?r.hasAttribute("disabled")||r.getAttribute("aria-disabled")==="true":!1}var jq=["input:not([inert]):not([inert] *)","select:not([inert]):not([inert] *)","textarea:not([inert]):not([inert] *)","a[href]:not([inert]):not([inert] *)","button:not([inert]):not([inert] *)","[tabindex]:not(slot):not([inert]):not([inert] *)","audio[controls]:not([inert]):not([inert] *)","video[controls]:not([inert]):not([inert] *)",'[contenteditable]:not([contenteditable="false"]):not([inert]):not([inert] *)',"details>summary:first-of-type:not([inert]):not([inert] *)","details:not([inert]):not([inert] *)"],Gd=jq.join(","),KI=typeof Element>"u",vl=KI?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,qd=!KI&&Element.prototype.getRootNode?function(e){var t;return e==null||(t=e.getRootNode)===null||t===void 0?void 0:t.call(e)}:function(e){return e?.ownerDocument},Kd=function(t,n){var r;n===void 0&&(n=!0);var i=t==null||(r=t.getAttribute)===null||r===void 0?void 0:r.call(t,"inert"),o=i===""||i==="true",a=o||n&&t&&(typeof t.closest=="function"?t.closest("[inert]"):Kd(t.parentNode));return a},Lq=function(t){var n,r=t==null||(n=t.getAttribute)===null||n===void 0?void 0:n.call(t,"contenteditable");return r===""||r==="true"},YI=function(t,n,r){if(Kd(t))return[];var i=Array.prototype.slice.apply(t.querySelectorAll(Gd));return n&&vl.call(t,Gd)&&i.unshift(t),i=i.filter(r),i},Yd=function(t,n,r){for(var i=[],o=Array.from(t);o.length;){var a=o.shift();if(!Kd(a,!1))if(a.tagName==="SLOT"){var s=a.assignedElements(),u=s.length?s:a.children,c=Yd(u,!0,r);r.flatten?i.push.apply(i,c):i.push({scopeParent:a,candidates:c})}else{var f=vl.call(a,Gd);f&&r.filter(a)&&(n||!t.includes(a))&&i.push(a);var p=a.shadowRoot||typeof r.getShadowRoot=="function"&&r.getShadowRoot(a),g=!Kd(p,!1)&&(!r.shadowRootFilter||r.shadowRootFilter(a));if(p&&g){var h=Yd(p===!0?a.children:p.children,!0,r);r.flatten?i.push.apply(i,h):i.push({scopeParent:a,candidates:h})}else o.unshift.apply(o,a.children)}}return i},XI=function(t){return!isNaN(parseInt(t.getAttribute("tabindex"),10))},ZI=function(t){if(!t)throw new Error("No node provided");return t.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(t.tagName)||Lq(t))&&!XI(t)?0:t.tabIndex},$q=function(t,n){var r=ZI(t);return r<0&&n&&!XI(t)?0:r},Fq=function(t,n){return t.tabIndex===n.tabIndex?t.documentOrder-n.documentOrder:t.tabIndex-n.tabIndex},QI=function(t){return t.tagName==="INPUT"},Vq=function(t){return QI(t)&&t.type==="hidden"},Bq=function(t){var n=t.tagName==="DETAILS"&&Array.prototype.slice.apply(t.children).some(function(r){return r.tagName==="SUMMARY"});return n},zq=function(t,n){for(var r=0;r<t.length;r++)if(t[r].checked&&t[r].form===n)return t[r]},Wq=function(t){if(!t.name)return!0;var n=t.form||qd(t),r=function(s){return n.querySelectorAll('input[type="radio"][name="'+s+'"]')},i;if(typeof window<"u"&&typeof window.CSS<"u"&&typeof window.CSS.escape=="function")i=r(window.CSS.escape(t.name));else try{i=r(t.name)}catch(a){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",a.message),!1}var o=zq(i,t.form);return!o||o===t},Hq=function(t){return QI(t)&&t.type==="radio"},Uq=function(t){return Hq(t)&&!Wq(t)},Gq=function(t){var n,r=t&&qd(t),i=(n=r)===null||n===void 0?void 0:n.host,o=!1;if(r&&r!==t){var a,s,u;for(o=!!((a=i)!==null&&a!==void 0&&(s=a.ownerDocument)!==null&&s!==void 0&&s.contains(i)||t!=null&&(u=t.ownerDocument)!==null&&u!==void 0&&u.contains(t));!o&&i;){var c,f,p;r=qd(i),i=(c=r)===null||c===void 0?void 0:c.host,o=!!((f=i)!==null&&f!==void 0&&(p=f.ownerDocument)!==null&&p!==void 0&&p.contains(i))}}return o},QC=function(t){var n=t.getBoundingClientRect(),r=n.width,i=n.height;return r===0&&i===0},qq=function(t,n){var r=n.displayCheck,i=n.getShadowRoot;if(r==="full-native"&&"checkVisibility"in t){var o=t.checkVisibility({checkOpacity:!1,opacityProperty:!1,contentVisibilityAuto:!0,visibilityProperty:!0,checkVisibilityCSS:!0});return!o}if(getComputedStyle(t).visibility==="hidden")return!0;var a=vl.call(t,"details>summary:first-of-type"),s=a?t.parentElement:t;if(vl.call(s,"details:not([open]) *"))return!0;if(!r||r==="full"||r==="full-native"||r==="legacy-full"){if(typeof i=="function"){for(var u=t;t;){var c=t.parentElement,f=qd(t);if(c&&!c.shadowRoot&&i(c)===!0)return QC(t);t.assignedSlot?t=t.assignedSlot:!c&&f!==t.ownerDocument?t=f.host:t=c}t=u}if(Gq(t))return!t.getClientRects().length;if(r!=="legacy-full")return!0}else if(r==="non-zero-area")return QC(t);return!1},Kq=function(t){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(t.tagName))for(var n=t.parentElement;n;){if(n.tagName==="FIELDSET"&&n.disabled){for(var r=0;r<n.children.length;r++){var i=n.children.item(r);if(i.tagName==="LEGEND")return vl.call(n,"fieldset[disabled] *")?!0:!i.contains(t)}return!0}n=n.parentElement}return!1},Ky=function(t,n){return!(n.disabled||Vq(n)||qq(n,t)||Bq(n)||Kq(n))},Yy=function(t,n){return!(Uq(n)||ZI(n)<0||!Ky(t,n))},Yq=function(t){var n=parseInt(t.getAttribute("tabindex"),10);return!!(isNaN(n)||n>=0)},JI=function(t){var n=[],r=[];return t.forEach(function(i,o){var a=!!i.scopeParent,s=a?i.scopeParent:i,u=$q(s,a),c=a?JI(i.candidates):s;u===0?a?n.push.apply(n,c):n.push(s):r.push({documentOrder:o,tabIndex:u,item:i,isScope:a,content:c})}),r.sort(Fq).reduce(function(i,o){return o.isScope?i.push.apply(i,o.content):i.push(o.content),i},[]).concat(n)},fh=function(t,n){n=n||{};var r;return n.getShadowRoot?r=Yd([t],n.includeContainer,{filter:Yy.bind(null,n),flatten:!1,getShadowRoot:n.getShadowRoot,shadowRootFilter:Yq}):r=YI(t,n.includeContainer,Yy.bind(null,n)),JI(r)},Xq=function(t,n){n=n||{};var r;return n.getShadowRoot?r=Yd([t],n.includeContainer,{filter:Ky.bind(null,n),flatten:!0,getShadowRoot:n.getShadowRoot}):r=YI(t,n.includeContainer,Ky.bind(null,n)),r},eT=function(t,n){if(n=n||{},!t)throw new Error("No node provided");return vl.call(t,Gd)===!1?!1:Yy(n,t)};function Zt(e){return e?.ownerDocument||document}const dc=()=>({getShadowRoot:!0,displayCheck:typeof ResizeObserver=="function"&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function tT(e,t){const n=fh(e,dc()),r=n.length;if(r===0)return;const i=io(Zt(e)),o=n.indexOf(i),a=o===-1?t===1?0:r-1:o+t;return n[a]}function nT(e){return tT(Zt(e).body,1)||e}function rT(e){return tT(Zt(e).body,-1)||e}function Fu(e,t){const n=t||e.currentTarget,r=e.relatedTarget;return!r||!pt(n,r)}function Zq(e){fh(e,dc()).forEach(n=>{n.dataset.tabindex=n.getAttribute("tabindex")||"",n.setAttribute("tabindex","-1")})}function JC(e){e.querySelectorAll("[data-tabindex]").forEach(n=>{const r=n.dataset.tabindex;delete n.dataset.tabindex,r?n.setAttribute("tabindex",r):n.removeAttribute("tabindex")})}function jx(e){const{enabled:t=!0,open:n,ref:r,onComplete:i}=e,o=Le(i),a=sq(r,n,!1);x.useEffect(()=>{if(!t)return;const s=new AbortController;return a(o,s.signal),()=>{s.abort()}},[t,n,o,a])}const hu=0;class yl{static create(){return new yl}currentId=hu;start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=hu,n()},t)}isStarted(){return this.currentId!==hu}clear=()=>{this.currentId!==hu&&(clearTimeout(this.currentId),this.currentId=hu)};disposeEffect=()=>this.clear}function ns(){const e=ti(yl.create).current;return NI(e.disposeEffect),e}let eE={},tE={},nE="";function Qq(e){if(typeof document>"u")return!1;const t=Zt(e);return Nn(t).innerWidth-t.documentElement.clientWidth>0}function Jq(e){if(!(typeof CSS<"u"&&CSS.supports&&CSS.supports("scrollbar-gutter","stable"))||typeof document>"u")return!1;const n=Zt(e),r=n.documentElement,i=n.body,o=ga(r)?r:i,a=o.style.overflowY,s=r.style.scrollbarGutter;r.style.scrollbarGutter="stable",o.style.overflowY="scroll";const u=o.offsetWidth;o.style.overflowY="hidden";const c=o.offsetWidth;return o.style.overflowY=a,r.style.scrollbarGutter=s,u===c}function eK(e){const t=Zt(e),n=t.documentElement,r=t.body,i=ga(n)?n:r,o={overflowY:i.style.overflowY,overflowX:i.style.overflowX};return Object.assign(i.style,{overflowY:"hidden",overflowX:"hidden"}),()=>{Object.assign(i.style,o)}}function tK(e){const t=Zt(e),n=t.documentElement,r=t.body,i=Nn(n);let o=0,a=0,s=!1;const u=Ri.create();if(BI&&(i.visualViewport?.scale??1)!==1)return()=>{};function c(){const g=i.getComputedStyle(n),h=i.getComputedStyle(r),y=(g.scrollbarGutter||"").includes("both-edges")?"stable both-edges":"stable";o=n.scrollTop,a=n.scrollLeft,eE={scrollbarGutter:n.style.scrollbarGutter,overflowY:n.style.overflowY,overflowX:n.style.overflowX},nE=n.style.scrollBehavior,tE={position:r.style.position,height:r.style.height,width:r.style.width,boxSizing:r.style.boxSizing,overflowY:r.style.overflowY,overflowX:r.style.overflowX,scrollBehavior:r.style.scrollBehavior};const w=n.scrollHeight>n.clientHeight,S=n.scrollWidth>n.clientWidth,E=g.overflowY==="scroll"||h.overflowY==="scroll",_=g.overflowX==="scroll"||h.overflowX==="scroll",P=Math.max(0,i.innerWidth-r.clientWidth),R=Math.max(0,i.innerHeight-r.clientHeight),I=parseFloat(h.marginTop)+parseFloat(h.marginBottom),k=parseFloat(h.marginLeft)+parseFloat(h.marginRight),B=ga(n)?n:r;if(s=Jq(e),s){n.style.scrollbarGutter=y,B.style.overflowY="hidden",B.style.overflowX="hidden";return}Object.assign(n.style,{scrollbarGutter:y,overflowY:"hidden",overflowX:"hidden"}),(w||E)&&(n.style.overflowY="scroll"),(S||_)&&(n.style.overflowX="scroll"),Object.assign(r.style,{position:"relative",height:I||R?`calc(100dvh - ${I+R}px)`:"100dvh",width:k||P?`calc(100vw - ${k+P}px)`:"100vw",boxSizing:"border-box",overflow:"hidden",scrollBehavior:"unset"}),r.scrollTop=o,r.scrollLeft=a,n.setAttribute("data-base-ui-scroll-locked",""),n.style.scrollBehavior="unset"}function f(){Object.assign(n.style,eE),Object.assign(r.style,tE),s||(n.scrollTop=o,n.scrollLeft=a,n.removeAttribute("data-base-ui-scroll-locked"),n.style.scrollBehavior=nE)}function p(){f(),u.request(c)}return c(),i.addEventListener("resize",p),()=>{u.cancel(),f(),typeof i.removeEventListener=="function"&&i.removeEventListener("resize",p)}}class nK{lockCount=0;restore=null;timeoutLock=yl.create();timeoutUnlock=yl.create();acquire(t){return this.lockCount+=1,this.lockCount===1&&this.restore===null&&this.timeoutLock.start(0,()=>this.lock(t)),this.release}release=()=>{this.lockCount-=1,this.lockCount===0&&this.restore&&this.timeoutUnlock.start(0,this.unlock)};unlock=()=>{this.lockCount===0&&this.restore&&(this.restore?.(),this.restore=null)};lock(t){if(this.lockCount===0||this.restore!==null)return;const r=Zt(t).documentElement,i=Nn(r).getComputedStyle(r).overflowY;if(i==="hidden"||i==="clip"){this.restore=Ht;return}const o=zI||!Qq(t);this.restore=o?eK(t):tK(t)}}const rK=new nK;function iK(e=!0,t=null){Ve(()=>{if(e)return rK.acquire(t)},[e,t])}function Zr(e){const t=ti(oK,e).current;return t.next=e,Ve(t.effect),t}function oK(e){const t={current:e,next:e,effect:()=>{t.current=t.next}};return t}function aK(){const e=new Map;return{emit(t,n){e.get(t)?.forEach(r=>r(n))},on(t,n){e.has(t)||e.set(t,new Set),e.get(t).add(n)},off(t,n){e.get(t)?.delete(n)}}}const iT=x.createContext(null);process.env.NODE_ENV!=="production"&&(iT.displayName="FloatingNodeContext");const oT=x.createContext(null);process.env.NODE_ENV!=="production"&&(oT.displayName="FloatingTreeContext");const aT=()=>x.useContext(iT)?.id||null,dh=e=>{const t=x.useContext(oT);return e??t};function Xd(e){return`data-base-ui-${e}`}const sT={clipPath:"inset(50%)",overflow:"hidden",whiteSpace:"nowrap",border:0,padding:0,width:1,height:1,margin:-1},Lx={...sT,position:"fixed",top:0,left:0},sK={...sT,position:"absolute"},qu=x.forwardRef(function(t,n){const[r,i]=x.useState();Ve(()=>{gq&&i("button")},[]);const o={tabIndex:0,role:r};return O.jsx("span",{...t,ref:n,style:Lx,"aria-hidden":r?void 0:!0,...o,"data-base-ui-focus-guard":""})});process.env.NODE_ENV!=="production"&&(qu.displayName="FocusGuard");let rE=0;function Vu(e,t={}){const{preventScroll:n=!1,cancelPrevious:r=!0,sync:i=!1}=t;r&&cancelAnimationFrame(rE);const o=()=>e?.focus({preventScroll:n});i?o():rE=requestAnimationFrame(o)}const fl={inert:new WeakMap,"aria-hidden":new WeakMap,none:new WeakMap};function iE(e){return e==="inert"?fl.inert:e==="aria-hidden"?fl["aria-hidden"]:fl.none}let Kf=new WeakSet,Yf={},Lm=0;const lT=e=>e&&(e.host||lT(e.parentNode)),lK=(e,t)=>t.map(n=>{if(e.contains(n))return n;const r=lT(n);return e.contains(r)?r:null}).filter(n=>n!=null);function uK(e,t,n,r){const i="data-base-ui-inert",o=r?"inert":n?"aria-hidden":null,a=lK(t,e),s=new Set,u=new Set(a),c=[];Yf[i]||(Yf[i]=new WeakMap);const f=Yf[i];a.forEach(p),g(t),s.clear();function p(h){!h||s.has(h)||(s.add(h),h.parentNode&&p(h.parentNode))}function g(h){!h||u.has(h)||[].forEach.call(h.children,v=>{if(ha(v)!=="script")if(s.has(v))g(v);else{const b=o?v.getAttribute(o):null,y=b!==null&&b!=="false",w=iE(o),S=(w.get(v)||0)+1,E=(f.get(v)||0)+1;w.set(v,S),f.set(v,E),c.push(v),S===1&&y&&Kf.add(v),E===1&&v.setAttribute(i,""),!y&&o&&v.setAttribute(o,o==="inert"?"":"true")}})}return Lm+=1,()=>{c.forEach(h=>{const v=iE(o),y=(v.get(h)||0)-1,w=(f.get(h)||0)-1;v.set(h,y),f.set(h,w),y||(!Kf.has(h)&&o&&h.removeAttribute(o),Kf.delete(h)),w||h.removeAttribute(i)}),Lm-=1,Lm||(fl.inert=new WeakMap,fl["aria-hidden"]=new WeakMap,fl.none=new WeakMap,Kf=new WeakSet,Yf={})}}function cK(e,t=!1,n=!1){const r=Zt(e[0]).body;return uK(e.concat(Array.from(r.querySelectorAll("[aria-live]"))),r,t,n)}const $x=x.createContext(null);process.env.NODE_ENV!=="production"&&($x.displayName="PortalContext");const uT=()=>x.useContext($x),fK=Xd("portal");function dK(e={}){const{ref:t,container:n,componentProps:r=Zn,elementProps:i}=e,o=Ox(),s=uT()?.portalNode,[u,c]=x.useState(null),[f,p]=x.useState(null),g=Le(y=>{y!==null&&p(y)}),h=x.useRef(null);Ve(()=>{if(n===null){h.current&&(h.current=null,p(null),c(null));return}if(o==null)return;const y=(n&&(Rx(n)?n:n.current))??s??document.body;if(y==null){h.current&&(h.current=null,p(null),c(null));return}h.current!==y&&(h.current=y,p(null),c(y))},[n,s,o]);const v=tr("div",r,{ref:[t,g],props:[{id:o,[fK]:""},i]});return{portalNode:f,portalSubtree:u&&v?Wi.createPortal(v,u):null}}const cT=x.forwardRef(function(t,n){const{children:r,container:i,className:o,render:a,renderGuards:s,...u}=t,{portalNode:c,portalSubtree:f}=dK({container:i,ref:n,componentProps:t,elementProps:u}),p=x.useRef(null),g=x.useRef(null),h=x.useRef(null),v=x.useRef(null),[b,y]=x.useState(null),w=b?.modal,S=b?.open,E=typeof s=="boolean"?s:!!b&&!b.modal&&b.open&&!!c;x.useEffect(()=>{if(!c||w)return;function P(R){c&&R.relatedTarget&&Fu(R)&&(R.type==="focusin"?JC:Zq)(c)}return c.addEventListener("focusin",P,!0),c.addEventListener("focusout",P,!0),()=>{c.removeEventListener("focusin",P,!0),c.removeEventListener("focusout",P,!0)}},[c,w]),x.useEffect(()=>{!c||S||JC(c)},[S,c]);const _=x.useMemo(()=>({beforeOutsideRef:p,afterOutsideRef:g,beforeInsideRef:h,afterInsideRef:v,portalNode:c,setFocusManagerState:y}),[c]);return O.jsxs(x.Fragment,{children:[f,O.jsxs($x.Provider,{value:_,children:[E&&c&&O.jsx(qu,{"data-type":"outside",ref:p,onFocus:P=>{if(Fu(P,c))h.current?.focus();else{const R=b?b.domReference:null;rT(R)?.focus()}}}),E&&c&&O.jsx("span",{"aria-owns":c.id,style:q4}),c&&Wi.createPortal(r,c),E&&c&&O.jsx(qu,{"data-type":"outside",ref:g,onFocus:P=>{if(Fu(P,c))v.current?.focus();else{const R=b?b.domReference:null;nT(R)?.focus(),b?.closeOnFocusOut&&b?.onOpenChange(!1,Ze(rh,P.nativeEvent))}}})]})]})});process.env.NODE_ENV!=="production"&&(cT.displayName="FloatingPortal");function pK(e,t){const n=Nn(e.target);return e instanceof n.KeyboardEvent?"keyboard":e instanceof n.FocusEvent?t||"keyboard":"pointerType"in e?e.pointerType||"keyboard":"touches"in e?"touch":e instanceof n.MouseEvent?t||(e.detail===0?"keyboard":"mouse"):""}const oE=20;let ea=[];function Fx(){ea=ea.filter(e=>e.deref()?.isConnected)}function hK(e){Fx(),e&&ha(e)!=="body"&&(ea.push(new WeakRef(e)),ea.length>oE&&(ea=ea.slice(-oE)))}function $m(){return Fx(),ea[ea.length-1]?.deref()}function gK(e){if(!e)return null;const t=dc();return eT(e,t)?e:fh(e,t)[0]||e}function mK(e){return!e||!e.isConnected?!1:typeof e.checkVisibility=="function"?e.checkVisibility():Ir(e).display!=="none"}function aE(e,t){if(!t.current.includes("floating")&&!e.getAttribute("role")?.includes("dialog"))return;const n=dc(),i=Xq(e,n).filter(a=>{const s=a.getAttribute("data-tabindex")||"";return eT(a,n)||a.hasAttribute("data-tabindex")&&!s.startsWith("-")}),o=e.getAttribute("tabindex");t.current.includes("floating")||i.length===0?o!=="0"&&e.setAttribute("tabindex","0"):(o!=="-1"||e.hasAttribute("data-tabindex")&&e.getAttribute("data-tabindex")!=="-1")&&(e.setAttribute("tabindex","-1"),e.setAttribute("data-tabindex","-1"))}function vK(e){const{context:t,children:n,disabled:r=!1,initialFocus:i=!0,returnFocus:o=!0,restoreFocus:a=!1,modal:s=!0,closeOnFocusOut:u=!0,openInteractionType:c="",nextFocusableElement:f,previousFocusableElement:p,beforeContentFocusGuardRef:g,externalTree:h}=e,v="rootStore"in t?t.rootStore:t,b=v.useState("open"),y=v.useState("domReferenceElement"),w=v.useState("floatingElement"),{events:S,dataRef:E}=v.context,_=Le(()=>E.current.floatingContext?.nodeId),P=i===!1,R=Uy(y)&&P,I=x.useRef(["content"]),k=Zr(i),B=Zr(o),L=Zr(c),V=dh(h),D=uT(),W=x.useRef(null),J=x.useRef(null),re=x.useRef(!1),U=x.useRef(!1),ee=x.useRef(!1),Z=x.useRef(-1),ue=x.useRef(""),X=x.useRef(""),Oe=x.useRef(null),Ee=x.useRef(null),Me=Uu(Oe,g,D?.beforeInsideRef),ye=Uu(Ee,D?.afterInsideRef),be=ns(),$e=ns(),me=Ax(),Se=D!=null,q=Gy(w),te=Le((ie=q)=>ie?fh(ie,dc()):[]),Y=Le(ie=>{const Q=te(ie);return I.current.map(()=>Q).filter(Boolean).flat()});x.useEffect(()=>{if(r||!s)return;function ie(Ae){Ae.key==="Tab"&&pt(q,io(Zt(q)))&&te().length===0&&!R&&Lt(Ae)}const Q=Zt(q);return Q.addEventListener("keydown",ie),()=>{Q.removeEventListener("keydown",ie)}},[r,y,q,s,I,R,te,Y]),x.useEffect(()=>{if(r||!b)return;const ie=Zt(q);function Q(){ee.current=!1}function Ae(fe){const ve=ur(fe),pe=pt(w,ve)||pt(y,ve)||pt(D?.portalNode,ve);ee.current=!pe,X.current=fe.pointerType||"keyboard",ve?.closest(`[${U4}]`)&&(U.current=!0)}function G(){X.current="keyboard"}return ie.addEventListener("pointerdown",Ae,!0),ie.addEventListener("pointerup",Q,!0),ie.addEventListener("pointercancel",Q,!0),ie.addEventListener("keydown",G,!0),()=>{ie.removeEventListener("pointerdown",Ae,!0),ie.removeEventListener("pointerup",Q,!0),ie.removeEventListener("pointercancel",Q,!0),ie.removeEventListener("keydown",G,!0)}},[r,w,y,q,b,D]),x.useEffect(()=>{if(r||!u)return;const ie=Zt(q);function Q(){U.current=!0,$e.start(0,()=>{U.current=!1})}function Ae(xe){const ce=ur(xe),De=te().indexOf(ce);De!==-1&&(Z.current=De)}function G(xe){const ce=xe.relatedTarget,Ce=xe.currentTarget,De=ur(xe);queueMicrotask(()=>{const nt=_(),kt=v.context.triggerElements,Dn=ce?.hasAttribute(Xd("focus-guard"))&&[Oe.current,Ee.current,D?.beforeInsideRef.current,D?.afterInsideRef.current,D?.beforeOutsideRef.current,D?.afterOutsideRef.current,no(p),no(f)].includes(ce),Ct=!(pt(y,ce)||pt(w,ce)||pt(ce,w)||pt(D?.portalNode,ce)||ce!=null&&kt.hasElement(ce)||kt.hasMatchingElement(lt=>pt(lt,ce))||Dn||V&&(cl(V.nodesRef.current,nt).find(lt=>pt(lt.context?.elements.floating,ce)||pt(lt.context?.elements.domReference,ce))||qC(V.nodesRef.current,nt).find(lt=>[lt.context?.elements.floating,Gy(lt.context?.elements.floating)].includes(ce)||lt.context?.elements.domReference===ce)));if(Ce===y&&q&&aE(q,I),a&&Ce!==y&&!mK(De)&&io(ie)===ie.body){if(nn(q)&&(q.focus(),a==="popup")){me.request(()=>{q.focus()});return}const lt=Z.current,Nt=te(),mn=Nt[lt]||Nt[Nt.length-1]||q;nn(mn)&&mn.focus()}if(E.current.insideReactTree){E.current.insideReactTree=!1;return}(R||!s)&&ce&&Ct&&!U.current&&(R||ce!==$m())&&(re.current=!0,v.setOpen(!1,Ze(rh,xe)))})}function fe(){ee.current||(E.current.insideReactTree=!0,be.start(0,()=>{E.current.insideReactTree=!1}))}const ve=nn(y)?y:null,pe=[];if(!(!w&&!ve))return ve&&(ve.addEventListener("focusout",G),ve.addEventListener("pointerdown",Q),pe.push(()=>{ve.removeEventListener("focusout",G),ve.removeEventListener("pointerdown",Q)})),w&&(w.addEventListener("focusin",Ae),w.addEventListener("focusout",G),D&&(w.addEventListener("focusout",fe,!0),pe.push(()=>{w.removeEventListener("focusout",fe,!0)})),pe.push(()=>{w.removeEventListener("focusin",Ae),w.removeEventListener("focusout",G)})),()=>{pe.forEach(xe=>{xe()})}},[r,y,w,q,s,V,D,v,u,a,te,R,_,I,E,be,$e,me,f,p]),x.useEffect(()=>{if(r||!w||!b)return;const ie=Array.from(D?.portalNode?.querySelectorAll(`[${Xd("portal")}]`)||[]),Ae=(V?qC(V.nodesRef.current,_()):[]).find(fe=>Uy(fe.context?.elements.domReference||null))?.context?.elements.domReference,G=[w,Ae,...ie,W.current,J.current,Oe.current,Ee.current,D?.beforeOutsideRef.current,D?.afterOutsideRef.current,no(p),no(f),R?y:null].filter(fe=>fe!=null);return cK(G,s||R)},[b,r,y,w,s,I,D,R,V,_,f,p]),Ve(()=>{if(!b||r||!nn(q))return;const ie=Zt(q),Q=io(ie);queueMicrotask(()=>{const Ae=Y(q),G=k.current,fe=typeof G=="function"?G(L.current||""):G;if(fe===void 0||fe===!1)return;let ve;fe===!0||fe===null?ve=Ae[0]||q:ve=no(fe),ve=ve||Ae[0]||q,!pt(q,Q)&&Vu(ve,{preventScroll:ve===q})})},[r,b,q,P,Y,k,L]),Ve(()=>{if(r||!q)return;const ie=Zt(q),Q=io(ie);hK(Q);function Ae(ve){if(ve.open||(ue.current=pK(ve.nativeEvent,X.current)),ve.reason===Q4&&ve.nativeEvent.type==="mouseleave"&&(re.current=!0),ve.reason===_x)if(ve.nested)re.current=!1;else if(UI(ve.nativeEvent)||GI(ve.nativeEvent))re.current=!1;else{let pe=!1;document.createElement("div").focus({get preventScroll(){return pe=!0,!1}}),pe?re.current=!1:re.current=!0}}S.on("openchange",Ae);const G=ie.createElement("span");G.setAttribute("tabindex","-1"),G.setAttribute("aria-hidden","true"),Object.assign(G.style,Lx),Se&&y&&y.insertAdjacentElement("afterend",G);function fe(){const ve=B.current;let pe=typeof ve=="function"?ve(ue.current):ve;if(pe===void 0||pe===!1)return null;if(pe===null&&(pe=!0),typeof pe=="boolean"){const ce=y||$m();return ce&&ce.isConnected?ce:G}const xe=y||$m()||G;return no(pe)||xe}return()=>{S.off("openchange",Ae);const ve=io(ie),pe=pt(w,ve)||V&&cl(V.nodesRef.current,_(),!1).some(ce=>pt(ce.context?.elements.floating,ve)),xe=fe();queueMicrotask(()=>{const ce=gK(xe),Ce=typeof B.current!="boolean";B.current&&!re.current&&nn(ce)&&(!(!Ce&&ce!==ve&&ve!==ie.body)||pe)&&ce.focus({preventScroll:!0}),G.remove(),re.current=!1})}},[r,w,q,B,E,S,V,Se,y,_]),Ve(()=>{if(!BI||b||!w)return;const ie=io(Zt(w));!nn(ie)||!Nx(ie)||pt(w,ie)&&ie.blur()},[b,w]),Ve(()=>{if(!(r||!D))return D.setFocusManagerState({modal:s,closeOnFocusOut:u,open:b,onOpenChange:v.setOpen,domReference:y}),()=>{D.setFocusManagerState(null)}},[r,D,s,b,v,u,y]),Ve(()=>{if(!(r||!q))return aE(q,I),()=>{queueMicrotask(Fx)}},[r,q,I]);const j=!r&&(s?!R:!0)&&(Se||s);return O.jsxs(x.Fragment,{children:[j&&O.jsx(qu,{"data-type":"inside",ref:Me,onFocus:ie=>{if(s){const Q=Y();Vu(Q[Q.length-1])}else D?.portalNode&&(re.current=!1,Fu(ie,D.portalNode)?nT(y)?.focus():no(p??D.beforeOutsideRef)?.focus())}}),n,j&&O.jsx(qu,{"data-type":"inside",ref:ye,onFocus:ie=>{s?Vu(Y()[0]):D?.portalNode&&(u&&(re.current=!0),Fu(ie,D.portalNode)?rT(y)?.focus():no(f??D.afterOutsideRef)?.focus())}})]})}function fT(e,t={}){const n="rootStore"in e?e.rootStore:e,r=n.context.dataRef,{enabled:i=!0,event:o="click",toggle:a=!0,ignoreMouse:s=!1,stickIfOpen:u=!0,touchOpenDelay:c=0,reason:f=Fy}=t,p=x.useRef(void 0),g=Ax(),h=ns(),v=x.useMemo(()=>({onPointerDown(b){p.current=b.pointerType},onMouseDown(b){const y=p.current,w=b.nativeEvent,S=n.select("open");if(b.button!==0||o==="click"||KC(y)&&s)return;const E=r.current.openEvent,_=E?.type,P=n.select("domReferenceElement")!==b.currentTarget,R=S&&P||!(S&&a&&(!(E&&u)||_==="click"||_==="mousedown"));if(Nx(w.target)){const k=Ze(f,w,w.target);R&&y==="touch"&&c>0?h.start(c,()=>{n.setOpen(!0,k)}):n.setOpen(R,k);return}const I=b.currentTarget;g.request(()=>{const k=Ze(f,w,I);R&&y==="touch"&&c>0?h.start(c,()=>{n.setOpen(!0,k)}):n.setOpen(R,k)})},onClick(b){if(o==="mousedown-only")return;const y=p.current;if(o==="mousedown"&&y){p.current=void 0;return}if(KC(y)&&s)return;const w=n.select("open"),S=r.current.openEvent,E=n.select("domReferenceElement")!==b.currentTarget,_=w&&E||!(w&&a&&(!(S&&u)||qI(S))),P=Ze(f,b.nativeEvent,b.currentTarget);_&&y==="touch"&&c>0?h.start(c,()=>{n.setOpen(!0,P)}):n.setOpen(_,P)},onKeyDown(){p.current=void 0}}),[r,o,s,n,u,a,g,h,c,f]);return x.useMemo(()=>i?{reference:v}:Zn,[i,v])}function sE(e,t,n){let{reference:r,floating:i}=e;const o=Qr(t),a=ch(t),s=uh(a),u=Rr(t),c=o==="y",f=r.x+r.width/2-i.width/2,p=r.y+r.height/2-i.height/2,g=r[s]/2-i[s]/2;let h;switch(u){case"top":h={x:f,y:r.y-i.height};break;case"bottom":h={x:f,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:p};break;case"left":h={x:r.x-i.width,y:p};break;default:h={x:r.x,y:r.y}}switch(Eo(t)){case"start":h[a]-=g*(n&&c?-1:1);break;case"end":h[a]+=g*(n&&c?-1:1);break}return h}async function yK(e,t){var n;t===void 0&&(t={});const{x:r,y:i,platform:o,rects:a,elements:s,strategy:u}=e,{boundary:c="clippingAncestors",rootBoundary:f="viewport",elementContext:p="floating",altBoundary:g=!1,padding:h=0}=Li(t,e),v=Dx(h),y=s[g?p==="floating"?"reference":"floating":p],w=Ud(await o.getClippingRect({element:(n=await(o.isElement==null?void 0:o.isElement(y)))==null||n?y:y.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(s.floating)),boundary:c,rootBoundary:f,strategy:u})),S=p==="floating"?{x:r,y:i,width:a.floating.width,height:a.floating.height}:a.reference,E=await(o.getOffsetParent==null?void 0:o.getOffsetParent(s.floating)),_=await(o.isElement==null?void 0:o.isElement(E))?await(o.getScale==null?void 0:o.getScale(E))||{x:1,y:1}:{x:1,y:1},P=Ud(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:S,offsetParent:E,strategy:u}):S);return{top:(w.top-P.top+v.top)/_.y,bottom:(P.bottom-w.bottom+v.bottom)/_.y,left:(w.left-P.left+v.left)/_.x,right:(P.right-w.right+v.right)/_.x}}const bK=50,xK=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:a}=n,s=a.detectOverflow?a:{...a,detectOverflow:yK},u=await(a.isRTL==null?void 0:a.isRTL(t));let c=await a.getElementRects({reference:e,floating:t,strategy:i}),{x:f,y:p}=sE(c,r,u),g=r,h=0;const v={};for(let b=0;b<o.length;b++){const y=o[b];if(!y)continue;const{name:w,fn:S}=y,{x:E,y:_,data:P,reset:R}=await S({x:f,y:p,initialPlacement:r,placement:g,strategy:i,middlewareData:v,rects:c,platform:s,elements:{reference:e,floating:t}});f=E??f,p=_??p,v[w]={...v[w],...P},R&&h<bK&&(h++,typeof R=="object"&&(R.placement&&(g=R.placement),R.rects&&(c=R.rects===!0?await a.getElementRects({reference:e,floating:t,strategy:i}):R.rects),{x:f,y:p}=sE(c,g,u)),b=-1)}return{x:f,y:p,placement:g,strategy:i,middlewareData:v}},wK=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:o,platform:a,elements:s,middlewareData:u}=t,{element:c,padding:f=0}=Li(e,t)||{};if(c==null)return{};const p=Dx(f),g={x:n,y:r},h=ch(i),v=uh(h),b=await a.getDimensions(c),y=h==="y",w=y?"top":"left",S=y?"bottom":"right",E=y?"clientHeight":"clientWidth",_=o.reference[v]+o.reference[h]-g[h]-o.floating[v],P=g[h]-o.reference[h],R=await(a.getOffsetParent==null?void 0:a.getOffsetParent(c));let I=R?R[E]:0;(!I||!await(a.isElement==null?void 0:a.isElement(R)))&&(I=s.floating[E]||o.floating[v]);const k=_/2-P/2,B=I/2-b[v]/2-1,L=ua(p[w],B),V=ua(p[S],B),D=L,W=I-b[v]-V,J=I/2-b[v]/2+k,re=Wd(D,J,W),U=!u.arrow&&Eo(i)!=null&&J!==re&&o.reference[v]/2-(J<D?L:V)-b[v]/2<0,ee=U?J<D?J-D:J-W:0;return{[h]:g[h]+ee,data:{[h]:re,centerOffset:J-re-ee,...U&&{alignmentOffset:ee}},reset:U}}}),SK=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:i,middlewareData:o,rects:a,initialPlacement:s,platform:u,elements:c}=t,{mainAxis:f=!0,crossAxis:p=!0,fallbackPlacements:g,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:v="none",flipAlignment:b=!0,...y}=Li(e,t);if((n=o.arrow)!=null&&n.alignmentOffset)return{};const w=Rr(i),S=Qr(s),E=Rr(s)===s,_=await(u.isRTL==null?void 0:u.isRTL(c.floating)),P=g||(E||!b?[Hd(s)]:Oq(s)),R=v!=="none";!g&&R&&P.push(...Iq(s,b,v,_));const I=[s,...P],k=await u.detectOverflow(t,y),B=[];let L=((r=o.flip)==null?void 0:r.overflows)||[];if(f&&B.push(k[w]),p){const J=_q(i,a,_);B.push(k[J[0]],k[J[1]])}if(L=[...L,{placement:i,overflows:B}],!B.every(J=>J<=0)){var V,D;const J=(((V=o.flip)==null?void 0:V.index)||0)+1,re=I[J];if(re&&(!(p==="alignment"?S!==Qr(re):!1)||L.every(Z=>Qr(Z.placement)===S?Z.overflows[0]>0:!0)))return{data:{index:J,overflows:L},reset:{placement:re}};let U=(D=L.filter(ee=>ee.overflows[0]<=0).sort((ee,Z)=>ee.overflows[1]-Z.overflows[1])[0])==null?void 0:D.placement;if(!U)switch(h){case"bestFit":{var W;const ee=(W=L.filter(Z=>{if(R){const ue=Qr(Z.placement);return ue===S||ue==="y"}return!0}).map(Z=>[Z.placement,Z.overflows.filter(ue=>ue>0).reduce((ue,X)=>ue+X,0)]).sort((Z,ue)=>Z[1]-ue[1])[0])==null?void 0:W[0];ee&&(U=ee);break}case"initialPlacement":U=s;break}if(i!==U)return{reset:{placement:U}}}return{}}}};function lE(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function uE(e){return Cq.some(t=>e[t]>=0)}const CK=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n,platform:r}=t,{strategy:i="referenceHidden",...o}=Li(e,t);switch(i){case"referenceHidden":{const a=await r.detectOverflow(t,{...o,elementContext:"reference"}),s=lE(a,n.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:uE(s)}}}case"escaped":{const a=await r.detectOverflow(t,{...o,altBoundary:!0}),s=lE(a,n.floating);return{data:{escapedOffsets:s,escaped:uE(s)}}}default:return{}}}}},dT=new Set(["left","top"]);async function EK(e,t){const{placement:n,platform:r,elements:i}=e,o=await(r.isRTL==null?void 0:r.isRTL(i.floating)),a=Rr(n),s=Eo(n),u=Qr(n)==="y",c=dT.has(a)?-1:1,f=o&&u?-1:1,p=Li(t,e);let{mainAxis:g,crossAxis:h,alignmentAxis:v}=typeof p=="number"?{mainAxis:p,crossAxis:0,alignmentAxis:null}:{mainAxis:p.mainAxis||0,crossAxis:p.crossAxis||0,alignmentAxis:p.alignmentAxis};return s&&typeof v=="number"&&(h=s==="end"?v*-1:v),u?{x:h*f,y:g*c}:{x:g*c,y:h*f}}const _K=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:i,y:o,placement:a,middlewareData:s}=t,u=await EK(t,e);return a===((n=s.offset)==null?void 0:n.placement)&&(r=s.arrow)!=null&&r.alignmentOffset?{}:{x:i+u.x,y:o+u.y,data:{...u,placement:a}}}}},OK=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:i,platform:o}=t,{mainAxis:a=!0,crossAxis:s=!1,limiter:u={fn:w=>{let{x:S,y:E}=w;return{x:S,y:E}}},...c}=Li(e,t),f={x:n,y:r},p=await o.detectOverflow(t,c),g=Qr(Rr(i)),h=Mx(g);let v=f[h],b=f[g];if(a){const w=h==="y"?"top":"left",S=h==="y"?"bottom":"right",E=v+p[w],_=v-p[S];v=Wd(E,v,_)}if(s){const w=g==="y"?"top":"left",S=g==="y"?"bottom":"right",E=b+p[w],_=b-p[S];b=Wd(E,b,_)}const y=u.fn({...t,[h]:v,[g]:b});return{...y,data:{x:y.x-n,y:y.y-r,enabled:{[h]:a,[g]:s}}}}}},PK=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:i,rects:o,middlewareData:a}=t,{offset:s=0,mainAxis:u=!0,crossAxis:c=!0}=Li(e,t),f={x:n,y:r},p=Qr(i),g=Mx(p);let h=f[g],v=f[p];const b=Li(s,t),y=typeof b=="number"?{mainAxis:b,crossAxis:0}:{mainAxis:0,crossAxis:0,...b};if(u){const E=g==="y"?"height":"width",_=o.reference[g]-o.floating[E]+y.mainAxis,P=o.reference[g]+o.reference[E]-y.mainAxis;h<_?h=_:h>P&&(h=P)}if(c){var w,S;const E=g==="y"?"width":"height",_=dT.has(Rr(i)),P=o.reference[p]-o.floating[E]+(_&&((w=a.offset)==null?void 0:w[p])||0)+(_?0:y.crossAxis),R=o.reference[p]+o.reference[E]+(_?0:((S=a.offset)==null?void 0:S[p])||0)-(_?y.crossAxis:0);v<P?v=P:v>R&&(v=R)}return{[g]:h,[p]:v}}}},AK=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:i,rects:o,platform:a,elements:s}=t,{apply:u=()=>{},...c}=Li(e,t),f=await a.detectOverflow(t,c),p=Rr(i),g=Eo(i),h=Qr(i)==="y",{width:v,height:b}=o.floating;let y,w;p==="top"||p==="bottom"?(y=p,w=g===(await(a.isRTL==null?void 0:a.isRTL(s.floating))?"start":"end")?"left":"right"):(w=p,y=g==="end"?"top":"bottom");const S=b-f.top-f.bottom,E=v-f.left-f.right,_=ua(b-f[y],S),P=ua(v-f[w],E),R=!t.middlewareData.shift;let I=_,k=P;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(k=E),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(I=S),R&&!g){const L=_r(f.left,0),V=_r(f.right,0),D=_r(f.top,0),W=_r(f.bottom,0);h?k=v-2*(L!==0||V!==0?L+V:_r(f.left,f.right)):I=b-2*(D!==0||W!==0?D+W:_r(f.top,f.bottom))}await u({...t,availableWidth:k,availableHeight:I});const B=await a.getDimensions(s.floating);return v!==B.width||b!==B.height?{reset:{rects:!0}}:{}}}};function pT(e){const t=Ir(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=nn(e),o=i?e.offsetWidth:n,a=i?e.offsetHeight:r,s=zd(n)!==o||zd(r)!==a;return s&&(n=o,r=a),{width:n,height:r,$:s}}function Vx(e){return $t(e)?e:e.contextElement}function dl(e){const t=Vx(e);if(!nn(t))return Ni(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:o}=pT(t);let a=(o?zd(n.width):n.width)/r,s=(o?zd(n.height):n.height)/i;return(!a||!Number.isFinite(a))&&(a=1),(!s||!Number.isFinite(s))&&(s=1),{x:a,y:s}}const RK=Ni(0);function hT(e){const t=Nn(e);return!ah()||!t.visualViewport?RK:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function IK(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Nn(e)?!1:t}function rs(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const i=e.getBoundingClientRect(),o=Vx(e);let a=Ni(1);t&&(r?$t(r)&&(a=dl(r)):a=dl(e));const s=IK(o,n,r)?hT(o):Ni(0);let u=(i.left+s.x)/a.x,c=(i.top+s.y)/a.y,f=i.width/a.x,p=i.height/a.y;if(o){const g=Nn(o),h=r&&$t(r)?Nn(r):r;let v=g,b=zy(v);for(;b&&r&&h!==v;){const y=dl(b),w=b.getBoundingClientRect(),S=Ir(b),E=w.left+(b.clientLeft+parseFloat(S.paddingLeft))*y.x,_=w.top+(b.clientTop+parseFloat(S.paddingTop))*y.y;u*=y.x,c*=y.y,f*=y.x,p*=y.y,u+=E,c+=_,v=Nn(b),b=zy(v)}}return Ud({width:f,height:p,x:u,y:c})}function ph(e,t){const n=sh(e).scrollLeft;return t?t.left+n:rs(Hi(e)).left+n}function gT(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-ph(e,n),i=n.top+t.scrollTop;return{x:r,y:i}}function TK(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e;const o=i==="fixed",a=Hi(r),s=t?oh(t.floating):!1;if(r===a||s&&o)return n;let u={scrollLeft:0,scrollTop:0},c=Ni(1);const f=Ni(0),p=nn(r);if((p||!p&&!o)&&((ha(r)!=="body"||ga(a))&&(u=sh(r)),p)){const h=rs(r);c=dl(r),f.x=h.x+r.clientLeft,f.y=h.y+r.clientTop}const g=a&&!p&&!o?gT(a,u):Ni(0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-u.scrollLeft*c.x+f.x+g.x,y:n.y*c.y-u.scrollTop*c.y+f.y+g.y}}function kK(e){return Array.from(e.getClientRects())}function NK(e){const t=Hi(e),n=sh(e),r=e.ownerDocument.body,i=_r(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),o=_r(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+ph(e);const s=-n.scrollTop;return Ir(r).direction==="rtl"&&(a+=_r(t.clientWidth,r.clientWidth)-i),{width:i,height:o,x:a,y:s}}const cE=25;function MK(e,t){const n=Nn(e),r=Hi(e),i=n.visualViewport;let o=r.clientWidth,a=r.clientHeight,s=0,u=0;if(i){o=i.width,a=i.height;const f=ah();(!f||f&&t==="fixed")&&(s=i.offsetLeft,u=i.offsetTop)}const c=ph(r);if(c<=0){const f=r.ownerDocument,p=f.body,g=getComputedStyle(p),h=f.compatMode==="CSS1Compat"&&parseFloat(g.marginLeft)+parseFloat(g.marginRight)||0,v=Math.abs(r.clientWidth-p.clientWidth-h);v<=cE&&(o-=v)}else c<=cE&&(o+=c);return{width:o,height:a,x:s,y:u}}function DK(e,t){const n=rs(e,!0,t==="fixed"),r=n.top+e.clientTop,i=n.left+e.clientLeft,o=nn(e)?dl(e):Ni(1),a=e.clientWidth*o.x,s=e.clientHeight*o.y,u=i*o.x,c=r*o.y;return{width:a,height:s,x:u,y:c}}function fE(e,t,n){let r;if(t==="viewport")r=MK(e,n);else if(t==="document")r=NK(Hi(e));else if($t(t))r=DK(t,n);else{const i=hT(e);r={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return Ud(r)}function mT(e,t){const n=mo(e);return n===t||!$t(n)||co(n)?!1:Ir(n).position==="fixed"||mT(n,t)}function jK(e,t){const n=t.get(e);if(n)return n;let r=ia(e,[],!1).filter(s=>$t(s)&&ha(s)!=="body"),i=null;const o=Ir(e).position==="fixed";let a=o?mo(e):e;for(;$t(a)&&!co(a);){const s=Ir(a),u=Ix(a);!u&&s.position==="fixed"&&(i=null),(o?!u&&!i:!u&&s.position==="static"&&!!i&&(i.position==="absolute"||i.position==="fixed")||ga(a)&&!u&&mT(e,a))?r=r.filter(f=>f!==a):i=s,a=mo(a)}return t.set(e,r),r}function LK(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const a=[...n==="clippingAncestors"?oh(t)?[]:jK(t,this._c):[].concat(n),r],s=fE(t,a[0],i);let u=s.top,c=s.right,f=s.bottom,p=s.left;for(let g=1;g<a.length;g++){const h=fE(t,a[g],i);u=_r(h.top,u),c=ua(h.right,c),f=ua(h.bottom,f),p=_r(h.left,p)}return{width:c-p,height:f-u,x:p,y:u}}function $K(e){const{width:t,height:n}=pT(e);return{width:t,height:n}}function FK(e,t,n){const r=nn(t),i=Hi(t),o=n==="fixed",a=rs(e,!0,o,t);let s={scrollLeft:0,scrollTop:0};const u=Ni(0);function c(){u.x=ph(i)}if(r||!r&&!o)if((ha(t)!=="body"||ga(i))&&(s=sh(t)),r){const h=rs(t,!0,o,t);u.x=h.x+t.clientLeft,u.y=h.y+t.clientTop}else i&&c();o&&!r&&i&&c();const f=i&&!r&&!o?gT(i,s):Ni(0),p=a.left+s.scrollLeft-u.x-f.x,g=a.top+s.scrollTop-u.y-f.y;return{x:p,y:g,width:a.width,height:a.height}}function Fm(e){return Ir(e).position==="static"}function dE(e,t){if(!nn(e)||Ir(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Hi(e)===n&&(n=n.ownerDocument.body),n}function vT(e,t){const n=Nn(e);if(oh(e))return n;if(!nn(e)){let i=mo(e);for(;i&&!co(i);){if($t(i)&&!Fm(i))return i;i=mo(i)}return n}let r=dE(e,t);for(;r&&lq(r)&&Fm(r);)r=dE(r,t);return r&&co(r)&&Fm(r)&&!Ix(r)?n:r||fq(e)||n}const VK=async function(e){const t=this.getOffsetParent||vT,n=this.getDimensions,r=await n(e.floating);return{reference:FK(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function BK(e){return Ir(e).direction==="rtl"}const zK={convertOffsetParentRelativeRectToViewportRelativeRect:TK,getDocumentElement:Hi,getClippingRect:LK,getOffsetParent:vT,getElementRects:VK,getClientRects:kK,getDimensions:$K,getScale:dl,isElement:$t,isRTL:BK};function yT(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function WK(e,t){let n=null,r;const i=Hi(e);function o(){var s;clearTimeout(r),(s=n)==null||s.disconnect(),n=null}function a(s,u){s===void 0&&(s=!1),u===void 0&&(u=1),o();const c=e.getBoundingClientRect(),{left:f,top:p,width:g,height:h}=c;if(s||t(),!g||!h)return;const v=al(p),b=al(i.clientWidth-(f+g)),y=al(i.clientHeight-(p+h)),w=al(f),E={rootMargin:-v+"px "+-b+"px "+-y+"px "+-w+"px",threshold:_r(0,ua(1,u))||1};let _=!0;function P(R){const I=R[0].intersectionRatio;if(I!==u){if(!_)return a();I?a(!1,I):r=setTimeout(()=>{a(!1,1e-7)},1e3)}I===1&&!yT(c,e.getBoundingClientRect())&&a(),_=!1}try{n=new IntersectionObserver(P,{...E,root:i.ownerDocument})}catch{n=new IntersectionObserver(P,E)}n.observe(e)}return a(!0),o}function Xy(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:u=!1}=r,c=Vx(e),f=i||o?[...c?ia(c):[],...t?ia(t):[]]:[];f.forEach(w=>{i&&w.addEventListener("scroll",n,{passive:!0}),o&&w.addEventListener("resize",n)});const p=c&&s?WK(c,n):null;let g=-1,h=null;a&&(h=new ResizeObserver(w=>{let[S]=w;S&&S.target===c&&h&&t&&(h.unobserve(t),cancelAnimationFrame(g),g=requestAnimationFrame(()=>{var E;(E=h)==null||E.observe(t)})),n()}),c&&!u&&h.observe(c),t&&h.observe(t));let v,b=u?rs(e):null;u&&y();function y(){const w=rs(e);b&&!yT(b,w)&&n(),b=w,v=requestAnimationFrame(y)}return n(),()=>{var w;f.forEach(S=>{i&&S.removeEventListener("scroll",n),o&&S.removeEventListener("resize",n)}),p?.(),(w=h)==null||w.disconnect(),h=null,u&&cancelAnimationFrame(v)}}const HK=_K,UK=OK,GK=SK,qK=AK,KK=CK,pE=wK,YK=PK,XK=(e,t,n)=>{const r=new Map,i={platform:zK,...n},o={...i.platform,_c:r};return xK(e,t,{...i,platform:o})};var ZK=typeof document<"u",QK=function(){},Td=ZK?$.useLayoutEffect:QK;function Zd(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Zd(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){const o=i[r];if(!(o==="_owner"&&e.$$typeof)&&!Zd(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}function bT(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function hE(e,t){const n=bT(e);return Math.round(t*n)/n}function Vm(e){const t=x.useRef(e);return Td(()=>{t.current=e}),t}function xT(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:o,floating:a}={},transform:s=!0,whileElementsMounted:u,open:c}=e,[f,p]=x.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[g,h]=x.useState(r);Zd(g,r)||h(r);const[v,b]=x.useState(null),[y,w]=x.useState(null),S=x.useCallback(Z=>{Z!==R.current&&(R.current=Z,b(Z))},[]),E=x.useCallback(Z=>{Z!==I.current&&(I.current=Z,w(Z))},[]),_=o||v,P=a||y,R=x.useRef(null),I=x.useRef(null),k=x.useRef(f),B=u!=null,L=Vm(u),V=Vm(i),D=Vm(c),W=x.useCallback(()=>{if(!R.current||!I.current)return;const Z={placement:t,strategy:n,middleware:g};V.current&&(Z.platform=V.current),XK(R.current,I.current,Z).then(ue=>{const X={...ue,isPositioned:D.current!==!1};J.current&&!Zd(k.current,X)&&(k.current=X,Wi.flushSync(()=>{p(X)}))})},[g,t,n,V,D]);Td(()=>{c===!1&&k.current.isPositioned&&(k.current.isPositioned=!1,p(Z=>({...Z,isPositioned:!1})))},[c]);const J=x.useRef(!1);Td(()=>(J.current=!0,()=>{J.current=!1}),[]),Td(()=>{if(_&&(R.current=_),P&&(I.current=P),_&&P){if(L.current)return L.current(_,P,W);W()}},[_,P,W,L,B]);const re=x.useMemo(()=>({reference:R,floating:I,setReference:S,setFloating:E}),[S,E]),U=x.useMemo(()=>({reference:_,floating:P}),[_,P]),ee=x.useMemo(()=>{const Z={position:n,left:0,top:0};if(!U.floating)return Z;const ue=hE(U.floating,f.x),X=hE(U.floating,f.y);return s?{...Z,transform:"translate("+ue+"px, "+X+"px)",...bT(U.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:ue,top:X}},[n,s,U.floating,f.x,f.y]);return x.useMemo(()=>({...f,update:W,refs:re,elements:U,floatingStyles:ee}),[f,W,re,U,ee])}const JK=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:i}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?pE({element:r.current,padding:i}).fn(n):{}:r?pE({element:r,padding:i}).fn(n):{}}}},wT=(e,t)=>{const n=HK(e);return{name:n.name,fn:n.fn,options:[e,t]}},ST=(e,t)=>{const n=UK(e);return{name:n.name,fn:n.fn,options:[e,t]}},CT=(e,t)=>({fn:YK(e).fn,options:[e,t]}),ET=(e,t)=>{const n=GK(e);return{name:n.name,fn:n.fn,options:[e,t]}},_T=(e,t)=>{const n=qK(e);return{name:n.name,fn:n.fn,options:[e,t]}},OT=(e,t)=>{const n=KK(e);return{name:n.name,fn:n.fn,options:[e,t]}},e6=(e,t)=>{const n=JK(e);return{name:n.name,fn:n.fn,options:[e,t]}},t6={intentional:"onClick",sloppy:"onPointerDown"};function n6(e){return{escapeKey:typeof e=="boolean"?e:e?.escapeKey??!1,outsidePress:typeof e=="boolean"?e:e?.outsidePress??!0}}function r6(e,t={}){const n="rootStore"in e?e.rootStore:e,r=n.useState("open"),i=n.useState("floatingElement"),o=n.useState("referenceElement"),a=n.useState("domReferenceElement"),{onOpenChange:s,dataRef:u}=n.context,{enabled:c=!0,escapeKey:f=!0,outsidePress:p=!0,outsidePressEvent:g="sloppy",referencePress:h=!1,referencePressEvent:v="sloppy",ancestorScroll:b=!1,bubbles:y,externalTree:w}=t,S=dh(w),E=Le(typeof p=="function"?p:()=>!1),_=typeof p=="function"?E:p,P=x.useRef(!1),{escapeKey:R,outsidePress:I}=n6(y),k=x.useRef(null),B=ns(),L=ns(),V=Le(()=>{L.clear(),u.current.insideReactTree=!1}),D=x.useRef(!1),W=x.useRef(""),J=Le(j=>{W.current=j.pointerType}),re=Le(()=>{const j=W.current,ie=j==="pen"||!j?"mouse":j,Q=typeof g=="function"?g():g;return typeof Q=="string"?Q:Q[ie]}),U=Le(j=>{if(!r||!c||!f||j.key!=="Escape"||D.current)return;const ie=u.current.floatingContext?.nodeId,Q=S?cl(S.nodesRef.current,ie):[];if(!R&&Q.length>0){let fe=!0;if(Q.forEach(ve=>{ve.context?.open&&!ve.context.dataRef.current.__escapeKeyBubbles&&(fe=!1)}),!fe)return}const Ae=Sq(j)?j.nativeEvent:j,G=Ze(kI,Ae);n.setOpen(!1,G),!R&&!G.isPropagationAllowed&&j.stopPropagation()}),ee=Le(j=>{const ie=re();return ie==="intentional"&&j.type!=="click"||ie==="sloppy"&&j.type==="click"}),Z=Le(()=>{u.current.insideReactTree=!0,L.start(0,V)}),ue=Le((j,ie=!1)=>{if(ee(j)){V();return}if(u.current.insideReactTree){V();return}if(re()==="intentional"&&ie||typeof _=="function"&&!_(j))return;const Q=ur(j),Ae=`[${Xd("inert")}]`,G=Zt(n.select("floatingElement")).querySelectorAll(Ae),fe=n.context.triggerElements;if(Q&&(fe.hasElement(Q)||fe.hasMatchingElement(Ce=>pt(Ce,Q))))return;let ve=$t(Q)?Q:null;for(;ve&&!co(ve);){const Ce=mo(ve);if(co(Ce)||!$t(Ce))break;ve=Ce}if(G.length&&$t(Q)&&!wq(Q)&&!pt(Q,n.select("floatingElement"))&&Array.from(G).every(Ce=>!pt(ve,Ce)))return;if(nn(Q)&&!("touches"in j)){const Ce=co(Q),De=Ir(Q),nt=/auto|scroll/,kt=Ce||nt.test(De.overflowX),Dn=Ce||nt.test(De.overflowY),Ct=kt&&Q.clientWidth>0&&Q.scrollWidth>Q.clientWidth,lt=Dn&&Q.clientHeight>0&&Q.scrollHeight>Q.clientHeight,Nt=De.direction==="rtl",mn=lt&&(Nt?j.offsetX<=Q.offsetWidth-Q.clientWidth:j.offsetX>Q.clientWidth),on=Ct&&j.offsetY>Q.clientHeight;if(mn||on)return}const pe=u.current.floatingContext?.nodeId,xe=S&&cl(S.nodesRef.current,pe).some(Ce=>ui(j,Ce.context?.elements.floating));if(ui(j,n.select("floatingElement"))||ui(j,n.select("domReferenceElement"))||xe)return;const ce=S?cl(S.nodesRef.current,pe):[];if(ce.length>0){let Ce=!0;if(ce.forEach(De=>{De.context?.open&&!De.context.dataRef.current.__outsidePressBubbles&&(Ce=!1)}),!Ce)return}n.setOpen(!1,Ze(_x,j)),V()}),X=Le(j=>{re()!=="sloppy"||j.pointerType==="touch"||!n.select("open")||!c||ui(j,n.select("floatingElement"))||ui(j,n.select("domReferenceElement"))||ue(j)}),Oe=Le(j=>{if(re()!=="sloppy"||!n.select("open")||!c||ui(j,n.select("floatingElement"))||ui(j,n.select("domReferenceElement")))return;const ie=j.touches[0];ie&&(k.current={startTime:Date.now(),startX:ie.clientX,startY:ie.clientY,dismissOnTouchEnd:!1,dismissOnMouseDown:!0},B.start(1e3,()=>{k.current&&(k.current.dismissOnTouchEnd=!1,k.current.dismissOnMouseDown=!1)}))}),Ee=Le(j=>{const ie=ur(j);function Q(){Oe(j),ie?.removeEventListener(j.type,Q)}ie?.addEventListener(j.type,Q)}),Me=Le(j=>{const ie=P.current;if(P.current=!1,B.clear(),j.type==="mousedown"&&k.current&&!k.current.dismissOnMouseDown)return;const Q=ur(j);function Ae(){j.type==="pointerdown"?X(j):ue(j,ie),Q?.removeEventListener(j.type,Ae)}Q?.addEventListener(j.type,Ae)}),ye=Le(j=>{if(re()!=="sloppy"||!k.current||ui(j,n.select("floatingElement"))||ui(j,n.select("domReferenceElement")))return;const ie=j.touches[0];if(!ie)return;const Q=Math.abs(ie.clientX-k.current.startX),Ae=Math.abs(ie.clientY-k.current.startY),G=Math.sqrt(Q*Q+Ae*Ae);G>5&&(k.current.dismissOnTouchEnd=!0),G>10&&(ue(j),B.clear(),k.current=null)}),be=Le(j=>{const ie=ur(j);function Q(){ye(j),ie?.removeEventListener(j.type,Q)}ie?.addEventListener(j.type,Q)}),$e=Le(j=>{re()!=="sloppy"||!k.current||ui(j,n.select("floatingElement"))||ui(j,n.select("domReferenceElement"))||(k.current.dismissOnTouchEnd&&ue(j),B.clear(),k.current=null)}),me=Le(j=>{const ie=ur(j);function Q(){$e(j),ie?.removeEventListener(j.type,Q)}ie?.addEventListener(j.type,Q)});x.useEffect(()=>{if(!r||!c)return;u.current.__escapeKeyBubbles=R,u.current.__outsidePressBubbles=I;const j=new yl;function ie(ve){n.setOpen(!1,Ze(Xr,ve))}function Q(){j.clear(),D.current=!0}function Ae(){j.start(ah()?5:0,()=>{D.current=!1})}const G=Zt(i);G.addEventListener("pointerdown",J,!0),f&&(G.addEventListener("keydown",U),G.addEventListener("compositionstart",Q),G.addEventListener("compositionend",Ae)),_&&(G.addEventListener("click",Me,!0),G.addEventListener("pointerdown",Me,!0),G.addEventListener("touchstart",Ee,!0),G.addEventListener("touchmove",be,!0),G.addEventListener("touchend",me,!0),G.addEventListener("mousedown",Me,!0));let fe=[];return b&&($t(a)&&(fe=ia(a)),$t(i)&&(fe=fe.concat(ia(i))),!$t(o)&&o&&o.contextElement&&(fe=fe.concat(ia(o.contextElement)))),fe=fe.filter(ve=>ve!==G.defaultView?.visualViewport),fe.forEach(ve=>{ve.addEventListener("scroll",ie,{passive:!0})}),()=>{G.removeEventListener("pointerdown",J,!0),f&&(G.removeEventListener("keydown",U),G.removeEventListener("compositionstart",Q),G.removeEventListener("compositionend",Ae)),_&&(G.removeEventListener("click",Me,!0),G.removeEventListener("pointerdown",Me,!0),G.removeEventListener("touchstart",Ee,!0),G.removeEventListener("touchmove",be,!0),G.removeEventListener("touchend",me,!0),G.removeEventListener("mousedown",Me,!0)),fe.forEach(ve=>{ve.removeEventListener("scroll",ie)}),j.clear(),P.current=!1}},[u,i,o,a,f,_,r,s,b,c,R,I,U,ue,Me,X,Ee,be,me,J,n]),x.useEffect(V,[_,V]);const Se=x.useMemo(()=>({onKeyDown:U,...h&&{[t6[v]]:j=>{n.setOpen(!1,Ze(Fy,j.nativeEvent))},...v!=="intentional"&&{onClick(j){n.setOpen(!1,Ze(Fy,j.nativeEvent))}}}}),[U,n,h,v]),q=Le(j=>{const ie=ur(j.nativeEvent);!pt(n.select("floatingElement"),ie)||j.button!==0||(P.current=!0)}),te=Le(j=>{!r||!c||j.button!==0||(P.current=!0)}),Y=x.useMemo(()=>({onKeyDown:U,onPointerDown:q,onMouseDown:q,onMouseUp:q,onClickCapture:Z,onMouseDownCapture(j){Z(),te(j)},onPointerDownCapture(j){Z(),te(j)},onMouseUpCapture:Z,onTouchEndCapture:Z,onTouchMoveCapture:Z}),[U,q,Z,te]);return x.useMemo(()=>c?{reference:Se,floating:Y,trigger:Se}:{},[c,Se,Y])}var i6=(e,t,n)=>{if(t.length===1&&t[0]===n){let r=!1;try{const i={};e(i)===i&&(r=!0)}catch{}if(r){let i;try{throw new Error}catch(o){({stack:i}=o)}console.warn(`The result function returned its own inputs without modification. e.g
|
|
19
19
|
\`createSelector([state => state.todos], todos => todos)\`
|
|
20
20
|
This could lead to inefficient memoization and unnecessary re-renders.
|
|
21
|
-
Ensure transformation logic is in the result function, and extraction logic is in the input selectors.`,{stack:i})}}},
|
|
21
|
+
Ensure transformation logic is in the result function, and extraction logic is in the input selectors.`,{stack:i})}}},o6=(e,t,n)=>{const{memoize:r,memoizeOptions:i}=t,{inputSelectorResults:o,inputSelectorResultsCopy:a}=e,s=r(()=>({}),...i);if(!(s.apply(null,o)===s.apply(null,a))){let c;try{throw new Error}catch(f){({stack:c}=f)}console.warn(`An input selector returned a different result when passed same arguments.
|
|
22
22
|
This means your output selector will likely run more frequently than intended.
|
|
23
23
|
Avoid returning a new reference inside your input selector, e.g.
|
|
24
|
-
\`createSelector([state => state.todos.map(todo => todo.id)], todoIds => todoIds.length)\``,{arguments:n,firstInputs:o,secondInputs:a,stack:c})}},e6={inputStabilityCheck:"once",identityFunctionCheck:"once"},Ud=Symbol("NOT_FOUND");function t6(e,t=`expected a function, instead received ${typeof e}`){if(typeof e!="function")throw new TypeError(t)}function n6(e,t=`expected an object, instead received ${typeof e}`){if(typeof e!="object")throw new TypeError(t)}function r6(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(n=>typeof n=="function")){const n=e.map(r=>typeof r=="function"?`function ${r.name||"unnamed"}()`:typeof r).join(", ");throw new TypeError(`${t}[${n}]`)}}var YS=e=>Array.isArray(e)?e:[e];function i6(e){const t=Array.isArray(e[0])?e[0]:e;return r6(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function XS(e,t){const n=[],{length:r}=e;for(let i=0;i<r;i++)n.push(e[i].apply(null,t));return n}var o6=(e,t)=>{const{identityFunctionCheck:n,inputStabilityCheck:r}={...e6,...t};return{identityFunctionCheck:{shouldRun:n==="always"||n==="once"&&e,run:Qq},inputStabilityCheck:{shouldRun:r==="always"||r==="once"&&e,run:Jq}}};function a6(e){let t;return{get(n){return t&&e(t.key,n)?t.value:Ud},put(n,r){t={key:n,value:r}},getEntries(){return t?[t]:[]},clear(){t=void 0}}}function s6(e,t){let n=[];function r(s){const u=n.findIndex(c=>t(s,c.key));if(u>-1){const c=n[u];return u>0&&(n.splice(u,1),n.unshift(c)),c.value}return Ud}function i(s,u){r(s)===Ud&&(n.unshift({key:s,value:u}),n.length>e&&n.pop())}function o(){return n}function a(){n=[]}return{get:r,put:i,getEntries:o,clear:a}}var l6=(e,t)=>e===t;function u6(e){return function(n,r){if(n===null||r===null||n.length!==r.length)return!1;const{length:i}=n;for(let o=0;o<i;o++)if(!e(n[o],r[o]))return!1;return!0}}function c6(e,t){const n=typeof t=="object"?t:{equalityCheck:t},{equalityCheck:r=l6,maxSize:i=1,resultEqualityCheck:o}=n,a=u6(r);let s=0;const u=i<=1?a6(a):s6(i,a);function c(){let d=u.get(arguments);if(d===Ud){if(d=e.apply(null,arguments),s++,o){const g=u.getEntries().find(h=>o(h.value,d));g&&(d=g.value,s!==0&&s--)}u.put(arguments,d)}return d}return c.clearCache=()=>{u.clear(),c.resetResultsCount()},c.resultsCount=()=>s,c.resetResultsCount=()=>{s=0},c}var f6=class{constructor(e){this.value=e}deref(){return this.value}},d6=typeof WeakRef<"u"?WeakRef:f6,p6=0,ZS=1;function zf(){return{s:p6,v:void 0,o:null,p:null}}function iT(e,t={}){let n=zf();const{resultEqualityCheck:r}=t;let i,o=0;function a(){let s=n;const{length:u}=arguments;for(let p=0,g=u;p<g;p++){const h=arguments[p];if(typeof h=="function"||typeof h=="object"&&h!==null){let v=s.o;v===null&&(s.o=v=new WeakMap);const b=v.get(h);b===void 0?(s=zf(),v.set(h,s)):s=b}else{let v=s.p;v===null&&(s.p=v=new Map);const b=v.get(h);b===void 0?(s=zf(),v.set(h,s)):s=b}}const c=s;let d;if(s.s===ZS)d=s.v;else if(d=e.apply(null,arguments),o++,r){const p=i?.deref?.()??i;p!=null&&r(p,d)&&(d=p,o!==0&&o--),i=typeof d=="object"&&d!==null||typeof d=="function"?new d6(d):d}return c.s=ZS,c.v=d,d}return a.clearCache=()=>{n=zf(),a.resetResultsCount()},a.resultsCount=()=>o,a.resetResultsCount=()=>{o=0},a}function oT(e,...t){const n=typeof e=="function"?{memoize:e,memoizeOptions:t}:e,r=(...i)=>{let o=0,a=0,s,u={},c=i.pop();typeof c=="object"&&(u=c,c=i.pop()),t6(c,`createSelector expects an output function after the inputs, but received: [${typeof c}]`);const d={...n,...u},{memoize:p,memoizeOptions:g=[],argsMemoize:h=iT,argsMemoizeOptions:v=[],devModeChecks:b={}}=d,y=YS(g),w=YS(v),C=i6(i),E=p(function(){return o++,c.apply(null,arguments)},...y);let _=!0;const O=h(function(){a++;const I=XS(C,arguments);if(s=E.apply(null,I),process.env.NODE_ENV!=="production"){const{identityFunctionCheck:k,inputStabilityCheck:B}=o6(_,b);if(k.shouldRun&&k.run(c,I,s),B.shouldRun){const L=XS(C,arguments);B.run({inputSelectorResults:I,inputSelectorResultsCopy:L},{memoize:p,memoizeOptions:y},arguments)}_&&(_=!1)}return s},...w);return Object.assign(O,{resultFunc:c,memoizedResultFunc:E,dependencies:C,dependencyRecomputations:()=>a,resetDependencyRecomputations:()=>{a=0},lastResult:()=>s,recomputations:()=>o,resetRecomputations:()=>{o=0},memoize:p,argsMemoize:h})};return Object.assign(r,{withTypes:()=>r}),r}var q=oT(iT),h6=Object.assign((e,t=q)=>{n6(e,`createStructuredSelector expects first argument to be an object where each property is a selector, instead received a ${typeof e}`);const n=Object.keys(e),r=n.map(o=>e[o]);return t(r,(...o)=>o.reduce((a,s,u)=>(a[n[u]]=s,a),{}))},{withTypes:()=>h6});oT({memoize:c6,memoizeOptions:{maxSize:1,equalityCheck:Object.is}});const Ne=(e,t,n,r,i,o,...a)=>{if(a.length>0)throw new Error(process.env.NODE_ENV!=="production"?"Unsupported number of selectors":pi(1));let s;if(e)s=e;else throw new Error("Missing arguments");return s};var Wf=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function fs(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Hf={exports:{}},_m={};var QS;function g6(){if(QS)return _m;QS=1;var e=j;function t(p,g){return p===g&&(p!==0||1/p===1/g)||p!==p&&g!==g}var n=typeof Object.is=="function"?Object.is:t,r=e.useState,i=e.useEffect,o=e.useLayoutEffect,a=e.useDebugValue;function s(p,g){var h=g(),v=r({inst:{value:h,getSnapshot:g}}),b=v[0].inst,y=v[1];return o(function(){b.value=h,b.getSnapshot=g,u(b)&&y({inst:b})},[p,h,g]),i(function(){return u(b)&&y({inst:b}),p(function(){u(b)&&y({inst:b})})},[p]),a(h),h}function u(p){var g=p.getSnapshot;p=p.value;try{var h=g();return!n(p,h)}catch{return!0}}function c(p,g){return g()}var d=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?c:s;return _m.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:d,_m}var Om={};var JS;function m6(){return JS||(JS=1,process.env.NODE_ENV!=="production"&&(function(){function e(h,v){return h===v&&(h!==0||1/h===1/v)||h!==h&&v!==v}function t(h,v){d||i.startTransition===void 0||(d=!0,console.error("You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."));var b=v();if(!p){var y=v();o(b,y)||(console.error("The result of getSnapshot should be cached to avoid an infinite loop"),p=!0)}y=a({inst:{value:b,getSnapshot:v}});var w=y[0].inst,C=y[1];return u(function(){w.value=b,w.getSnapshot=v,n(w)&&C({inst:w})},[h,b,v]),s(function(){return n(w)&&C({inst:w}),h(function(){n(w)&&C({inst:w})})},[h]),c(b),b}function n(h){var v=h.getSnapshot;h=h.value;try{var b=v();return!o(h,b)}catch{return!0}}function r(h,v){return v()}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var i=j,o=typeof Object.is=="function"?Object.is:e,a=i.useState,s=i.useEffect,u=i.useLayoutEffect,c=i.useDebugValue,d=!1,p=!1,g=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?r:t;Om.useSyncExternalStore=i.useSyncExternalStore!==void 0?i.useSyncExternalStore:g,typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()),Om}var eE;function w0(){return eE||(eE=1,process.env.NODE_ENV==="production"?Hf.exports=g6():Hf.exports=m6()),Hf.exports}var v6=w0(),Uf={exports:{}},Pm={};var tE;function y6(){if(tE)return Pm;tE=1;var e=j,t=w0();function n(c,d){return c===d&&(c!==0||1/c===1/d)||c!==c&&d!==d}var r=typeof Object.is=="function"?Object.is:n,i=t.useSyncExternalStore,o=e.useRef,a=e.useEffect,s=e.useMemo,u=e.useDebugValue;return Pm.useSyncExternalStoreWithSelector=function(c,d,p,g,h){var v=o(null);if(v.current===null){var b={hasValue:!1,value:null};v.current=b}else b=v.current;v=s(function(){function w(R){if(!C){if(C=!0,E=R,R=g(R),h!==void 0&&b.hasValue){var I=b.value;if(h(I,R))return _=I}return _=R}if(I=_,r(E,R))return I;var k=g(R);return h!==void 0&&h(I,k)?(E=R,I):(E=R,_=k)}var C=!1,E,_,O=p===void 0?null:p;return[function(){return w(d())},O===null?void 0:function(){return w(O())}]},[d,p,g,h]);var y=i(c,v[0],v[1]);return a(function(){b.hasValue=!0,b.value=y},[y]),u(y),y},Pm}var Am={};var nE;function b6(){return nE||(nE=1,process.env.NODE_ENV!=="production"&&(function(){function e(c,d){return c===d&&(c!==0||1/c===1/d)||c!==c&&d!==d}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var t=j,n=w0(),r=typeof Object.is=="function"?Object.is:e,i=n.useSyncExternalStore,o=t.useRef,a=t.useEffect,s=t.useMemo,u=t.useDebugValue;Am.useSyncExternalStoreWithSelector=function(c,d,p,g,h){var v=o(null);if(v.current===null){var b={hasValue:!1,value:null};v.current=b}else b=v.current;v=s(function(){function w(R){if(!C){if(C=!0,E=R,R=g(R),h!==void 0&&b.hasValue){var I=b.value;if(h(I,R))return _=I}return _=R}if(I=_,r(E,R))return I;var k=g(R);return h!==void 0&&h(I,k)?(E=R,I):(E=R,_=k)}var C=!1,E,_,O=p===void 0?null:p;return[function(){return w(d())},O===null?void 0:function(){return w(O())}]},[d,p,g,h]);var y=i(c,v[0],v[1]);return a(function(){b.hasValue=!0,b.value=y},[y]),u(y),y},typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()),Am}var rE;function x6(){return rE||(rE=1,process.env.NODE_ENV==="production"?Uf.exports=y6():Uf.exports=b6()),Uf.exports}var aT=x6();const w6=i0(19),C6=w6?E6:_6;function he(e,t,n,r,i){return C6(e,t,n,r,i)}function S6(e,t,n,r,i){const o=x.useCallback(()=>t(e.getSnapshot(),n,r,i),[e,t,n,r,i]);return v6.useSyncExternalStore(e.subscribe,o,o)}function E6(e,t,n,r,i){return S6(e,t,n,r,i)}function _6(e,t,n,r,i){return aT.useSyncExternalStoreWithSelector(e.subscribe,e.getSnapshot,e.getSnapshot,o=>t(o,n,r,i))}class sT{constructor(t){this.state=t,this.listeners=new Set,this.updateTick=0}subscribe=t=>(this.listeners.add(t),()=>{this.listeners.delete(t)});getSnapshot=()=>this.state;setState(t){if(this.state===t)return;this.state=t,this.updateTick+=1;const n=this.updateTick;for(const r of this.listeners){if(n!==this.updateTick)return;r(t)}}update(t){for(const n in t)if(!Object.is(this.state[n],t[n])){this.setState({...this.state,...t});return}}set(t,n){Object.is(this.state[t],n)||this.setState({...this.state,[t]:n})}notifyAll(){const t={...this.state};this.setState(t)}use(t,n,r,i){return he(this,t,n,r,i)}}class O6 extends sT{constructor(t,n={},r){super(t),this.context=n,this.selectors=r}useSyncedValue(t,n){x.useDebugValue(t),je(()=>{this.state[t]!==n&&this.set(t,n)},[t,n])}useSyncedValueWithCleanup(t,n){const r=this;je(()=>(r.state[t]!==n&&r.set(t,n),()=>{r.set(t,void 0)}),[r,t,n])}useSyncedValues(t){const n=this;if(process.env.NODE_ENV!=="production"){x.useDebugValue(t,a=>Object.keys(a));const i=x.useRef(Object.keys(t)).current,o=Object.keys(t);(i.length!==o.length||i.some((a,s)=>a!==o[s]))&&console.error("ReactStore.useSyncedValues expects the same prop keys on every render. Keys should be stable.")}const r=Object.values(t);je(()=>{n.update(t)},[n,...r])}useControlledProp(t,n){x.useDebugValue(t);const r=n!==void 0;if(je(()=>{r&&!Object.is(this.state[t],n)&&super.setState({...this.state,[t]:n})},[t,n,r]),process.env.NODE_ENV!=="production"){const i=this.controlledValues??=new Map;i.has(t)||i.set(t,r);const o=i.get(t);o!==void 0&&o!==r&&console.error(`A component is changing the ${r?"":"un"}controlled state of ${t.toString()} to be ${r?"un":""}controlled. Elements should not switch from uncontrolled to controlled (or vice versa).`)}}select(t,n,r,i){const o=this.selectors[t];return o(this.state,n,r,i)}useState(t,n,r,i){return x.useDebugValue(t),he(this,this.selectors[t],n,r,i)}useContextCallback(t,n){x.useDebugValue(t);const r=Me(n??Wt);this.context[t]=r}useStateSetter(t){const n=x.useRef(void 0);return n.current===void 0&&(n.current=r=>{this.set(t,r)}),n.current}observe(t,n){let r;typeof t=="function"?r=t:r=this.selectors[t];let i=r(this.state);return n(i,i,this),this.subscribe(o=>{const a=r(o);if(!Object.is(i,a)){const s=i;i=a,n(a,s,this)}})}}const P6={open:Ne(e=>e.open),domReferenceElement:Ne(e=>e.domReferenceElement),referenceElement:Ne(e=>e.positionReference??e.referenceElement),floatingElement:Ne(e=>e.floatingElement),floatingId:Ne(e=>e.floatingId)};class A6 extends O6{constructor(t){const{nested:n,noEmit:r,onOpenChange:i,triggerElements:o,...a}=t;super({...a,positionReference:a.referenceElement,domReferenceElement:a.referenceElement},{onOpenChange:i,dataRef:{current:{}},events:eq(),nested:n,noEmit:r,triggerElements:o},P6)}setOpen=(t,n)=>{if((!t||!this.state.open||EI(n.event))&&(this.context.dataRef.current.openEvent=t?n.event:void 0),!this.context.noEmit){const r={open:t,reason:n.reason,nativeEvent:n.event,nested:this.context.nested,triggerElement:n.trigger};this.context.events.emit("openchange",r)}this.context.onOpenChange?.(t,n)}}class R6{constructor(){this.elementsSet=new Set,this.idMap=new Map}add(t,n){const r=this.idMap.get(t);if(r!==n&&(r!==void 0&&this.elementsSet.delete(r),this.elementsSet.add(n),this.idMap.set(t,n),process.env.NODE_ENV!=="production"&&this.elementsSet.size!==this.idMap.size))throw new Error("Base UI: A trigger element cannot be registered under multiple IDs in PopupTriggerMap.")}delete(t){const n=this.idMap.get(t);n&&(this.elementsSet.delete(n),this.idMap.delete(t))}hasElement(t){return this.elementsSet.has(t)}hasMatchingElement(t){for(const n of this.elementsSet)if(t(n))return!0;return!1}getById(t){return this.idMap.get(t)}entries(){return this.idMap.entries()}elements(){return this.elementsSet.values()}get size(){return this.idMap.size}}function lT(e){const{open:t=!1,onOpenChange:n,elements:r={}}=e,i=a0(),o=LI()!=null;if(process.env.NODE_ENV!=="production"){const s=r.reference;s&&!Lt(s)&&console.error("Cannot pass a virtual element to the `elements.reference` option,","as it must be a real DOM element. Use `context.setPositionReference()`","instead.")}const a=ei(()=>new A6({open:t,onOpenChange:n,referenceElement:r.reference??null,floatingElement:r.floating??null,triggerElements:new R6,floatingId:i,nested:o,noEmit:!1})).current;return je(()=>{const s={open:t,floatingId:i};r.reference!==void 0&&(s.referenceElement=r.reference,s.domReferenceElement=Lt(r.reference)?r.reference:null),r.floating!==void 0&&(s.floatingElement=r.floating),a.update(s)},[t,i,r.reference,r.floating,a]),a.context.onOpenChange=n,a.context.nested=o,a.context.noEmit=!1,a}function I6(e={}){const{nodeId:t,externalTree:n}=e,r=lT(e),i=e.rootContext||r,o={reference:i.useState("referenceElement"),floating:i.useState("floatingElement"),domReference:i.useState("domReferenceElement")},[a,s]=x.useState(null),u=x.useRef(null),c=rh(n);je(()=>{o.domReference&&(u.current=o.domReference)},[o.domReference]);const d=ZI({...e,elements:{...o,...a&&{reference:a}}}),p=x.useCallback(I=>{const k=Lt(I)?{getBoundingClientRect:()=>I.getBoundingClientRect(),getClientRects:()=>I.getClientRects(),contextElement:I}:I;s(k),d.refs.setReference(k)},[d.refs]),[g,h]=x.useState(null),[v,b]=x.useState(null);i.useSyncedValue("referenceElement",g),i.useSyncedValue("domReferenceElement",Lt(g)?g:null),i.useSyncedValue("floatingElement",v);const y=x.useCallback(I=>{(Lt(I)||I===null)&&(u.current=I,h(I)),(Lt(d.refs.reference.current)||d.refs.reference.current===null||I!==null&&!Lt(I))&&d.refs.setReference(I)},[d.refs,h]),w=x.useCallback(I=>{b(I),d.refs.setFloating(I)},[d.refs]),C=x.useMemo(()=>({...d.refs,setReference:y,setFloating:w,setPositionReference:p,domReference:u}),[d.refs,y,w,p]),E=x.useMemo(()=>({...d.elements,domReference:o.domReference}),[d.elements,o.domReference]),_=i.useState("open"),O=i.useState("floatingId"),R=x.useMemo(()=>({...d,dataRef:i.context.dataRef,open:_,onOpenChange:i.setOpen,events:i.context.events,floatingId:O,refs:C,elements:E,nodeId:t,rootStore:i}),[d,C,E,t,i,_,O]);return je(()=>{i.context.dataRef.current.floatingContext=R;const I=c?.nodesRef.current.find(k=>k.id===t);I&&(I.context=R)}),x.useMemo(()=>({...d,context:R,refs:C,elements:E,rootStore:i}),[d,C,E,R,i])}function T6(e=[]){const t=e.map(c=>c?.reference),n=e.map(c=>c?.floating),r=e.map(c=>c?.item),i=e.map(c=>c?.trigger),o=x.useCallback(c=>Gf(c,e,"reference"),t),a=x.useCallback(c=>Gf(c,e,"floating"),n),s=x.useCallback(c=>Gf(c,e,"item"),r),u=x.useCallback(c=>Gf(c,e,"trigger"),i);return x.useMemo(()=>({getReferenceProps:o,getFloatingProps:a,getItemProps:s,getTriggerProps:u}),[o,a,s,u])}function Gf(e,t,n){const r=new Map,i=n==="item",o={};n==="floating"&&(o.tabIndex=-1,o[Ay]="");for(const a in e)i&&e&&(a===xI||a===wI)||(o[a]=e[a]);for(let a=0;a<t.length;a+=1){let s;const u=t[a]?.[n];typeof u=="function"?s=e?u(e):null:s=u,s&&iE(o,s,i,r)}return iE(o,e,i,r),o}function iE(e,t,n,r){for(const i in t){const o=t[i];n&&(i===xI||i===wI)||(i.startsWith("on")?(r.has(i)||r.set(i,[]),typeof o=="function"&&(r.get(i)?.push(o),e[i]=(...a)=>r.get(i)?.map(s=>s(...a)).find(s=>s!==void 0))):e[i]=o)}}const k6="Escape";function oh(e,t,n){switch(e){case"vertical":return t;case"horizontal":return n;default:return t||n}}function qf(e,t){return oh(t,e===d0||e===rc,e===ea||e===ta)}function Rm(e,t,n){return oh(t,e===rc,n?e===ea:e===ta)||e==="Enter"||e===" "||e===""}function N6(e,t,n){return oh(t,n?e===ea:e===ta,e===rc)}function M6(e,t,n,r){const i=n?e===ta:e===ea,o=e===d0;return t==="both"||t==="horizontal"&&r&&r>1?e===k6:oh(t,i,o)}function D6(e,t){const n="rootStore"in e?e.rootStore:e,r=n.useState("open"),i=n.useState("floatingElement"),o=n.useState("domReferenceElement"),a=n.context.dataRef,{listRef:s,activeIndex:u,onNavigate:c=()=>{},enabled:d=!0,selectedIndex:p=null,allowEscape:g=!1,loopFocus:h=!1,nested:v=!1,rtl:b=!1,virtual:y=!1,focusItemOnOpen:w="auto",focusItemOnHover:C=!0,openOnArrowKeyDown:E=!0,disabledIndices:_=void 0,orientation:O="vertical",parentOrientation:R,cols:I=1,id:k,resetOnPointerLeave:B=!0,externalTree:L}=t;process.env.NODE_ENV!=="production"&&(g&&(h||console.warn("`useListNavigation` looping must be enabled to allow escaping."),y||console.warn("`useListNavigation` must be virtual to allow escaping.")),O==="vertical"&&I>1&&console.warn("In grid list navigation mode (`cols` > 1), the `orientation` should",'be either "horizontal" or "both".'));const V=Iy(i),D=Xr(V),H=LI(),J=rh(L);je(()=>{a.current.orientation=O},[a,O]);const te=Ry(o),G=x.useRef(w),ee=x.useRef(p??-1),Q=x.useRef(null),pe=x.useRef(!0),K=Me(de=>{c(ee.current===-1?null:ee.current,de)}),Ae=x.useRef(K),Se=x.useRef(!!i),$e=x.useRef(r),we=x.useRef(!1),Ce=x.useRef(!1),ze=Xr(_),Ke=Xr(r),Fe=Xr(p),Y=Xr(B),oe=Me(()=>{function de(ke){y?J?.events.emit("virtualfocus",ke):Nu(ke,{sync:we.current,preventScroll:!0})}const ve=s.current[ee.current],le=Ce.current;ve&&de(ve),(we.current?ke=>ke():requestAnimationFrame)(()=>{const ke=s.current[ee.current]||ve;if(!ke)return;ve||de(ke),$&&(le||!pe.current)&&ke.scrollIntoView?.({block:"nearest",inline:"nearest"})})});je(()=>{d&&(r&&i?(ee.current=p??-1,G.current&&p!=null&&(Ce.current=!0,K())):Se.current&&(ee.current=-1,Ae.current()))},[d,r,i,p,K]),je(()=>{if(d){if(!r){we.current=!1;return}if(i)if(u==null){if(we.current=!1,Fe.current!=null)return;if(Se.current&&(ee.current=-1,oe()),(!$e.current||!Se.current)&&G.current&&(Q.current!=null||G.current===!0&&Q.current==null)){let de=0;const ve=()=>{s.current[0]==null?(de<2&&(de?requestAnimationFrame:queueMicrotask)(ve),de+=1):(ee.current=Q.current==null||Rm(Q.current,O,b)||v?xm(s):TS(s),Q.current=null,K())};ve()}}else Iu(s,u)||(ee.current=u,oe(),Ce.current=!1)}},[d,r,i,u,Fe,v,s,O,b,K,oe,ze]),je(()=>{if(!d||i||!J||y||!Se.current)return;const de=J.nodesRef.current,ve=de.find(ke=>ke.id===H)?.context?.elements.floating,le=eo(Xt(i)),be=de.some(ke=>ke.context&&ft(ke.context.elements.floating,le));ve&&!be&&pe.current&&ve.focus({preventScroll:!0})},[d,i,J,H,y]),je(()=>{Ae.current=K,$e.current=r,Se.current=!!i}),je(()=>{r||(Q.current=null,G.current=w)},[r,w]);const ne=u!=null,$=x.useMemo(()=>{function de(le){if(!Ke.current)return;const be=s.current.indexOf(le.currentTarget);be!==-1&&ee.current!==be&&(ee.current=be,K(le))}return{onFocus(le){we.current=!0,de(le)},onClick:({currentTarget:le})=>le.focus({preventScroll:!0}),onMouseMove(le){we.current=!0,Ce.current=!1,C&&de(le)},onPointerLeave(le){if(!Ke.current||!pe.current||le.pointerType==="touch")return;we.current=!0;const be=le.relatedTarget;!C||s.current.includes(be)||Y.current&&(Nu(null,{sync:!0}),ee.current=-1,K(le),y||D.current?.focus({preventScroll:!0}))}}},[Ke,D,C,s,K,Y,y]),ie=x.useCallback(()=>R??J?.nodesRef.current.find(de=>de.id===H)?.context?.dataRef?.current.orientation,[H,J,R]),Z=Me(de=>{if(pe.current=!1,we.current=!0,de.which===229||!Ke.current&&de.currentTarget===D.current)return;if(v&&M6(de.key,O,b,I)){qf(de.key,ie())||jt(de),n.setOpen(!1,Xe(Ru,de.nativeEvent)),nn(o)&&(y?J?.events.emit("virtualfocus",o):o.focus());return}const ve=ee.current,le=xm(s,_),be=TS(s,_);if(te||(de.key==="Home"&&(jt(de),ee.current=le,K(de)),de.key==="End"&&(jt(de),ee.current=be,K(de))),I>1){const ke=Array.from({length:s.current.length},()=>({width:1,height:1})),et=P4(ke,I),Tt=et.findIndex(ot=>ot!=null&&!Tu(s,ot,_)),Dn=et.reduce((ot,kt,mn)=>kt!=null&&!Tu(s,kt,_)?mn:ot,-1),Ct=et[O4({current:et.map(ot=>ot!=null?s.current[ot]:null)},{event:de,orientation:O,loopFocus:h,rtl:b,cols:I,disabledIndices:R4([...(typeof _!="function"?_:null)||s.current.map((ot,kt)=>Tu(s,kt,_)?kt:void 0),void 0],et),minIndex:Tt,maxIndex:Dn,prevIndex:A4(ee.current>be?le:ee.current,ke,et,I,de.key===rc?"bl":de.key===(b?ea:ta)?"tr":"tl"),stopEvent:!0})];if(Ct!=null&&(ee.current=Ct,K(de)),O==="both")return}if(qf(de.key,O)){if(jt(de),r&&!y&&eo(de.currentTarget.ownerDocument)===de.currentTarget){ee.current=Rm(de.key,O,b)?le:be,K(de);return}Rm(de.key,O,b)?h?ve>=be?g&&ve!==s.current.length?ee.current=-1:(we.current=!1,ee.current=le):ee.current=Vn(s,{startingIndex:ve,disabledIndices:_}):ee.current=Math.min(be,Vn(s,{startingIndex:ve,disabledIndices:_})):h?ve<=le?g&&ve!==-1?ee.current=s.current.length:(we.current=!1,ee.current=be):ee.current=Vn(s,{startingIndex:ve,decrement:!0,disabledIndices:_}):ee.current=Math.max(le,Vn(s,{startingIndex:ve,decrement:!0,disabledIndices:_})),Iu(s,ee.current)&&(ee.current=-1),K(de)}}),Re=x.useMemo(()=>y&&r&&ne&&{"aria-activedescendant":`${k}-${u}`},[y,r,ne,k,u]),U=x.useMemo(()=>({"aria-orientation":O==="both"?void 0:O,...te?{}:Re,onKeyDown(de){if(de.key==="Tab"&&de.shiftKey&&r&&!y){const ve=lr(de.nativeEvent);if(ve&&!ft(D.current,ve))return;jt(de),n.setOpen(!1,Xe(Kp,de.nativeEvent)),nn(o)&&o.focus();return}Z(de)},onPointerMove(){pe.current=!0}}),[Re,Z,D,O,te,n,r,y,o]),fe=x.useMemo(()=>{function de(le){w==="auto"&&CI(le.nativeEvent)&&(G.current=!y)}function ve(le){G.current=w,w==="auto"&&SI(le.nativeEvent)&&(G.current=!0)}return{onKeyDown(le){const be=n.select("open");pe.current=!1;const ke=le.key.startsWith("Arrow"),et=N6(le.key,ie(),b),Tt=qf(le.key,O),Dn=(v?et:Tt)||le.key==="Enter"||le.key.trim()==="";if(y&&be)return Z(le);if(!(!be&&!E&&ke)){if(Dn){const Ct=qf(le.key,ie());Q.current=v&&Ct?null:le.key}if(v){et&&(jt(le),be?(ee.current=xm(s,ze.current),K(le)):n.setOpen(!0,Xe(Ru,le.nativeEvent,le.currentTarget)));return}Tt&&(Fe.current!=null&&(ee.current=Fe.current),jt(le),!be&&E?n.setOpen(!0,Xe(Ru,le.nativeEvent,le.currentTarget)):Z(le),be&&K(le))}},onFocus(le){n.select("open")&&!y&&(ee.current=-1,K(le))},onPointerDown:ve,onPointerEnter:ve,onMouseDown:de,onClick:de}},[Z,ze,w,s,v,K,n,E,O,ie,b,Fe,y]),me=x.useMemo(()=>({...Re,...fe}),[Re,fe]);return x.useMemo(()=>d?{reference:me,floating:U,item:$,trigger:fe}:{},[d,me,U,fe,$])}function j6(e,t){const n="rootStore"in e?e.rootStore:e,r=n.context.dataRef,i=n.useState("open"),{listRef:o,activeIndex:a,onMatch:s,onTypingChange:u,enabled:c=!0,resetMs:d=750,selectedIndex:p=null}=t,g=Xa(),h=x.useRef(""),v=x.useRef(p??a??-1),b=x.useRef(null);je(()=>{!i&&p!==null||(g.clear(),b.current=null,h.current!==""&&(h.current=""))},[i,p,g]),je(()=>{i&&h.current===""&&(v.current=p??a??-1)},[i,p,a]);const y=Me(O=>{O?r.current.typing||(r.current.typing=O,u?.(O)):r.current.typing&&(r.current.typing=O,u?.(O))}),w=Me(O=>{function R(D,H,J){const te=H.find(G=>G?.toLocaleLowerCase().indexOf(J.toLocaleLowerCase())===0);return te?D.indexOf(te):-1}const I=o.current;if(h.current.length>0&&h.current[0]!==" "&&(R(I,I,h.current)===-1?y(!1):O.key===" "&&jt(O)),I==null||O.key.length!==1||O.ctrlKey||O.metaKey||O.altKey)return;i&&O.key!==" "&&(jt(O),y(!0));const k=h.current==="";k&&(v.current=p??a??-1),I.every(D=>D?D[0]?.toLocaleLowerCase()!==D[1]?.toLocaleLowerCase():!0)&&h.current===O.key&&(h.current="",v.current=b.current),h.current+=O.key,g.start(d,()=>{h.current="",v.current=b.current,y(!1)});const L=k?p??a??-1:v.current,V=R(I,[...I.slice((L||0)+1),...I.slice(0,(L||0)+1)],h.current);V!==-1?(s?.(V),b.current=V):O.key!==" "&&(h.current="",y(!1))}),C=Me(O=>{const R=O.relatedTarget,I=n.select("domReferenceElement"),k=n.select("floatingElement"),B=ft(I,R),L=ft(k,R);B||L||(g.clear(),h.current="",v.current=b.current,y(!1))}),E=x.useMemo(()=>({onKeyDown:w,onBlur:C}),[w,C]),_=x.useMemo(()=>({onKeyDown:w,onKeyUp(O){O.key===" "&&y(!1)},onBlur:C}),[w,C,y]);return x.useMemo(()=>c?{reference:E,floating:_}:{},[c,E,_])}function L6(e){const t=x.useRef(""),n=x.useCallback(i=>{i.defaultPrevented||(t.current=i.pointerType,e(i,i.pointerType))},[e]);return{onClick:x.useCallback(i=>{if(i.detail===0){e(i,"keyboard");return}"pointerType"in i?e(i,i.pointerType):e(i,t.current),t.current=""},[e]),onPointerDown:n}}function $6(e){const[t,n]=x.useState(null),r=Me((s,u)=>{e||n(u||(bI?"touch":""))}),i=x.useCallback(()=>{n(null)},[]),{onClick:o,onPointerDown:a}=L6(r);return x.useMemo(()=>({openMethod:t,reset:i,triggerProps:{onClick:o,onPointerDown:a}}),[t,i,o,a])}let C0=(function(e){return e.open="data-open",e.closed="data-closed",e[e.startingStyle=$u.startingStyle]="startingStyle",e[e.endingStyle=$u.endingStyle]="endingStyle",e.anchorHidden="data-anchor-hidden",e.side="data-side",e.align="data-align",e})({}),Dy=(function(e){return e.popupOpen="data-popup-open",e.pressed="data-pressed",e})({});const F6={[Dy.popupOpen]:""},V6={[Dy.popupOpen]:"",[Dy.pressed]:""},B6={[C0.open]:""},z6={[C0.closed]:""},W6={[C0.anchorHidden]:""},H6={open(e){return e?F6:null}},U6={open(e){return e?V6:null}},uT={open(e){return e?B6:z6},anchorHidden(e){return e?W6:null}};function G6(e){return i0(19)?e:e?"true":void 0}const cT=x.forwardRef(function(t,n){const{cutout:r,...i}=t;let o;if(r){const a=r?.getBoundingClientRect();o=`polygon(
|
|
24
|
+
\`createSelector([state => state.todos.map(todo => todo.id)], todoIds => todoIds.length)\``,{arguments:n,firstInputs:o,secondInputs:a,stack:c})}},a6={inputStabilityCheck:"once",identityFunctionCheck:"once"},Qd=Symbol("NOT_FOUND");function s6(e,t=`expected a function, instead received ${typeof e}`){if(typeof e!="function")throw new TypeError(t)}function l6(e,t=`expected an object, instead received ${typeof e}`){if(typeof e!="object")throw new TypeError(t)}function u6(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(n=>typeof n=="function")){const n=e.map(r=>typeof r=="function"?`function ${r.name||"unnamed"}()`:typeof r).join(", ");throw new TypeError(`${t}[${n}]`)}}var gE=e=>Array.isArray(e)?e:[e];function c6(e){const t=Array.isArray(e[0])?e[0]:e;return u6(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function mE(e,t){const n=[],{length:r}=e;for(let i=0;i<r;i++)n.push(e[i].apply(null,t));return n}var f6=(e,t)=>{const{identityFunctionCheck:n,inputStabilityCheck:r}={...a6,...t};return{identityFunctionCheck:{shouldRun:n==="always"||n==="once"&&e,run:i6},inputStabilityCheck:{shouldRun:r==="always"||r==="once"&&e,run:o6}}};function d6(e){let t;return{get(n){return t&&e(t.key,n)?t.value:Qd},put(n,r){t={key:n,value:r}},getEntries(){return t?[t]:[]},clear(){t=void 0}}}function p6(e,t){let n=[];function r(s){const u=n.findIndex(c=>t(s,c.key));if(u>-1){const c=n[u];return u>0&&(n.splice(u,1),n.unshift(c)),c.value}return Qd}function i(s,u){r(s)===Qd&&(n.unshift({key:s,value:u}),n.length>e&&n.pop())}function o(){return n}function a(){n=[]}return{get:r,put:i,getEntries:o,clear:a}}var h6=(e,t)=>e===t;function g6(e){return function(n,r){if(n===null||r===null||n.length!==r.length)return!1;const{length:i}=n;for(let o=0;o<i;o++)if(!e(n[o],r[o]))return!1;return!0}}function m6(e,t){const n=typeof t=="object"?t:{equalityCheck:t},{equalityCheck:r=h6,maxSize:i=1,resultEqualityCheck:o}=n,a=g6(r);let s=0;const u=i<=1?d6(a):p6(i,a);function c(){let f=u.get(arguments);if(f===Qd){if(f=e.apply(null,arguments),s++,o){const g=u.getEntries().find(h=>o(h.value,f));g&&(f=g.value,s!==0&&s--)}u.put(arguments,f)}return f}return c.clearCache=()=>{u.clear(),c.resetResultsCount()},c.resultsCount=()=>s,c.resetResultsCount=()=>{s=0},c}var v6=class{constructor(e){this.value=e}deref(){return this.value}},y6=typeof WeakRef<"u"?WeakRef:v6,b6=0,vE=1;function Xf(){return{s:b6,v:void 0,o:null,p:null}}function PT(e,t={}){let n=Xf();const{resultEqualityCheck:r}=t;let i,o=0;function a(){let s=n;const{length:u}=arguments;for(let p=0,g=u;p<g;p++){const h=arguments[p];if(typeof h=="function"||typeof h=="object"&&h!==null){let v=s.o;v===null&&(s.o=v=new WeakMap);const b=v.get(h);b===void 0?(s=Xf(),v.set(h,s)):s=b}else{let v=s.p;v===null&&(s.p=v=new Map);const b=v.get(h);b===void 0?(s=Xf(),v.set(h,s)):s=b}}const c=s;let f;if(s.s===vE)f=s.v;else if(f=e.apply(null,arguments),o++,r){const p=i?.deref?.()??i;p!=null&&r(p,f)&&(f=p,o!==0&&o--),i=typeof f=="object"&&f!==null||typeof f=="function"?new y6(f):f}return c.s=vE,c.v=f,f}return a.clearCache=()=>{n=Xf(),a.resetResultsCount()},a.resultsCount=()=>o,a.resetResultsCount=()=>{o=0},a}function AT(e,...t){const n=typeof e=="function"?{memoize:e,memoizeOptions:t}:e,r=(...i)=>{let o=0,a=0,s,u={},c=i.pop();typeof c=="object"&&(u=c,c=i.pop()),s6(c,`createSelector expects an output function after the inputs, but received: [${typeof c}]`);const f={...n,...u},{memoize:p,memoizeOptions:g=[],argsMemoize:h=PT,argsMemoizeOptions:v=[],devModeChecks:b={}}=f,y=gE(g),w=gE(v),S=c6(i),E=p(function(){return o++,c.apply(null,arguments)},...y);let _=!0;const P=h(function(){a++;const I=mE(S,arguments);if(s=E.apply(null,I),process.env.NODE_ENV!=="production"){const{identityFunctionCheck:k,inputStabilityCheck:B}=f6(_,b);if(k.shouldRun&&k.run(c,I,s),B.shouldRun){const L=mE(S,arguments);B.run({inputSelectorResults:I,inputSelectorResultsCopy:L},{memoize:p,memoizeOptions:y},arguments)}_&&(_=!1)}return s},...w);return Object.assign(P,{resultFunc:c,memoizedResultFunc:E,dependencies:S,dependencyRecomputations:()=>a,resetDependencyRecomputations:()=>{a=0},lastResult:()=>s,recomputations:()=>o,resetRecomputations:()=>{o=0},memoize:p,argsMemoize:h})};return Object.assign(r,{withTypes:()=>r}),r}var K=AT(PT),x6=Object.assign((e,t=K)=>{l6(e,`createStructuredSelector expects first argument to be an object where each property is a selector, instead received a ${typeof e}`);const n=Object.keys(e),r=n.map(o=>e[o]);return t(r,(...o)=>o.reduce((a,s,u)=>(a[n[u]]=s,a),{}))},{withTypes:()=>x6});AT({memoize:m6,memoizeOptions:{maxSize:1,equalityCheck:Object.is}});const je=(e,t,n,r,i,o,...a)=>{if(a.length>0)throw new Error(process.env.NODE_ENV!=="production"?"Unsupported number of selectors":mi(1));let s;if(e)s=e;else throw new Error("Missing arguments");return s};var Zf=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function vs(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Qf={exports:{}},Bm={};var yE;function w6(){if(yE)return Bm;yE=1;var e=$;function t(p,g){return p===g&&(p!==0||1/p===1/g)||p!==p&&g!==g}var n=typeof Object.is=="function"?Object.is:t,r=e.useState,i=e.useEffect,o=e.useLayoutEffect,a=e.useDebugValue;function s(p,g){var h=g(),v=r({inst:{value:h,getSnapshot:g}}),b=v[0].inst,y=v[1];return o(function(){b.value=h,b.getSnapshot=g,u(b)&&y({inst:b})},[p,h,g]),i(function(){return u(b)&&y({inst:b}),p(function(){u(b)&&y({inst:b})})},[p]),a(h),h}function u(p){var g=p.getSnapshot;p=p.value;try{var h=g();return!n(p,h)}catch{return!0}}function c(p,g){return g()}var f=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?c:s;return Bm.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:f,Bm}var zm={};var bE;function S6(){return bE||(bE=1,process.env.NODE_ENV!=="production"&&(function(){function e(h,v){return h===v&&(h!==0||1/h===1/v)||h!==h&&v!==v}function t(h,v){f||i.startTransition===void 0||(f=!0,console.error("You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."));var b=v();if(!p){var y=v();o(b,y)||(console.error("The result of getSnapshot should be cached to avoid an infinite loop"),p=!0)}y=a({inst:{value:b,getSnapshot:v}});var w=y[0].inst,S=y[1];return u(function(){w.value=b,w.getSnapshot=v,n(w)&&S({inst:w})},[h,b,v]),s(function(){return n(w)&&S({inst:w}),h(function(){n(w)&&S({inst:w})})},[h]),c(b),b}function n(h){var v=h.getSnapshot;h=h.value;try{var b=v();return!o(h,b)}catch{return!0}}function r(h,v){return v()}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var i=$,o=typeof Object.is=="function"?Object.is:e,a=i.useState,s=i.useEffect,u=i.useLayoutEffect,c=i.useDebugValue,f=!1,p=!1,g=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?r:t;zm.useSyncExternalStore=i.useSyncExternalStore!==void 0?i.useSyncExternalStore:g,typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()),zm}var xE;function Bx(){return xE||(xE=1,process.env.NODE_ENV==="production"?Qf.exports=w6():Qf.exports=S6()),Qf.exports}var C6=Bx(),Jf={exports:{}},Wm={};var wE;function E6(){if(wE)return Wm;wE=1;var e=$,t=Bx();function n(c,f){return c===f&&(c!==0||1/c===1/f)||c!==c&&f!==f}var r=typeof Object.is=="function"?Object.is:n,i=t.useSyncExternalStore,o=e.useRef,a=e.useEffect,s=e.useMemo,u=e.useDebugValue;return Wm.useSyncExternalStoreWithSelector=function(c,f,p,g,h){var v=o(null);if(v.current===null){var b={hasValue:!1,value:null};v.current=b}else b=v.current;v=s(function(){function w(R){if(!S){if(S=!0,E=R,R=g(R),h!==void 0&&b.hasValue){var I=b.value;if(h(I,R))return _=I}return _=R}if(I=_,r(E,R))return I;var k=g(R);return h!==void 0&&h(I,k)?(E=R,I):(E=R,_=k)}var S=!1,E,_,P=p===void 0?null:p;return[function(){return w(f())},P===null?void 0:function(){return w(P())}]},[f,p,g,h]);var y=i(c,v[0],v[1]);return a(function(){b.hasValue=!0,b.value=y},[y]),u(y),y},Wm}var Hm={};var SE;function _6(){return SE||(SE=1,process.env.NODE_ENV!=="production"&&(function(){function e(c,f){return c===f&&(c!==0||1/c===1/f)||c!==c&&f!==f}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var t=$,n=Bx(),r=typeof Object.is=="function"?Object.is:e,i=n.useSyncExternalStore,o=t.useRef,a=t.useEffect,s=t.useMemo,u=t.useDebugValue;Hm.useSyncExternalStoreWithSelector=function(c,f,p,g,h){var v=o(null);if(v.current===null){var b={hasValue:!1,value:null};v.current=b}else b=v.current;v=s(function(){function w(R){if(!S){if(S=!0,E=R,R=g(R),h!==void 0&&b.hasValue){var I=b.value;if(h(I,R))return _=I}return _=R}if(I=_,r(E,R))return I;var k=g(R);return h!==void 0&&h(I,k)?(E=R,I):(E=R,_=k)}var S=!1,E,_,P=p===void 0?null:p;return[function(){return w(f())},P===null?void 0:function(){return w(P())}]},[f,p,g,h]);var y=i(c,v[0],v[1]);return a(function(){b.hasValue=!0,b.value=y},[y]),u(y),y},typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()),Hm}var CE;function O6(){return CE||(CE=1,process.env.NODE_ENV==="production"?Jf.exports=E6():Jf.exports=_6()),Jf.exports}var RT=O6();const P6=Ex(19),A6=P6?I6:T6;function he(e,t,n,r,i){return A6(e,t,n,r,i)}function R6(e,t,n,r,i){const o=x.useCallback(()=>t(e.getSnapshot(),n,r,i),[e,t,n,r,i]);return C6.useSyncExternalStore(e.subscribe,o,o)}function I6(e,t,n,r,i){return R6(e,t,n,r,i)}function T6(e,t,n,r,i){return RT.useSyncExternalStoreWithSelector(e.subscribe,e.getSnapshot,e.getSnapshot,o=>t(o,n,r,i))}class IT{constructor(t){this.state=t,this.listeners=new Set,this.updateTick=0}subscribe=t=>(this.listeners.add(t),()=>{this.listeners.delete(t)});getSnapshot=()=>this.state;setState(t){if(this.state===t)return;this.state=t,this.updateTick+=1;const n=this.updateTick;for(const r of this.listeners){if(n!==this.updateTick)return;r(t)}}update(t){for(const n in t)if(!Object.is(this.state[n],t[n])){this.setState({...this.state,...t});return}}set(t,n){Object.is(this.state[t],n)||this.setState({...this.state,[t]:n})}notifyAll(){const t={...this.state};this.setState(t)}use(t,n,r,i){return he(this,t,n,r,i)}}class k6 extends IT{constructor(t,n={},r){super(t),this.context=n,this.selectors=r}useSyncedValue(t,n){x.useDebugValue(t),Ve(()=>{this.state[t]!==n&&this.set(t,n)},[t,n])}useSyncedValueWithCleanup(t,n){const r=this;Ve(()=>(r.state[t]!==n&&r.set(t,n),()=>{r.set(t,void 0)}),[r,t,n])}useSyncedValues(t){const n=this;if(process.env.NODE_ENV!=="production"){x.useDebugValue(t,a=>Object.keys(a));const i=x.useRef(Object.keys(t)).current,o=Object.keys(t);(i.length!==o.length||i.some((a,s)=>a!==o[s]))&&console.error("ReactStore.useSyncedValues expects the same prop keys on every render. Keys should be stable.")}const r=Object.values(t);Ve(()=>{n.update(t)},[n,...r])}useControlledProp(t,n){x.useDebugValue(t);const r=n!==void 0;if(Ve(()=>{r&&!Object.is(this.state[t],n)&&super.setState({...this.state,[t]:n})},[t,n,r]),process.env.NODE_ENV!=="production"){const i=this.controlledValues??=new Map;i.has(t)||i.set(t,r);const o=i.get(t);o!==void 0&&o!==r&&console.error(`A component is changing the ${r?"":"un"}controlled state of ${t.toString()} to be ${r?"un":""}controlled. Elements should not switch from uncontrolled to controlled (or vice versa).`)}}select(t,n,r,i){const o=this.selectors[t];return o(this.state,n,r,i)}useState(t,n,r,i){return x.useDebugValue(t),he(this,this.selectors[t],n,r,i)}useContextCallback(t,n){x.useDebugValue(t);const r=Le(n??Ht);this.context[t]=r}useStateSetter(t){const n=x.useRef(void 0);return n.current===void 0&&(n.current=r=>{this.set(t,r)}),n.current}observe(t,n){let r;typeof t=="function"?r=t:r=this.selectors[t];let i=r(this.state);return n(i,i,this),this.subscribe(o=>{const a=r(o);if(!Object.is(i,a)){const s=i;i=a,n(a,s,this)}})}}const N6={open:je(e=>e.open),domReferenceElement:je(e=>e.domReferenceElement),referenceElement:je(e=>e.positionReference??e.referenceElement),floatingElement:je(e=>e.floatingElement),floatingId:je(e=>e.floatingId)};class M6 extends k6{constructor(t){const{nested:n,noEmit:r,onOpenChange:i,triggerElements:o,...a}=t;super({...a,positionReference:a.referenceElement,domReferenceElement:a.referenceElement},{onOpenChange:i,dataRef:{current:{}},events:aK(),nested:n,noEmit:r,triggerElements:o},N6)}setOpen=(t,n)=>{if((!t||!this.state.open||qI(n.event))&&(this.context.dataRef.current.openEvent=t?n.event:void 0),!this.context.noEmit){const r={open:t,reason:n.reason,nativeEvent:n.event,nested:this.context.nested,triggerElement:n.trigger};this.context.events.emit("openchange",r)}this.context.onOpenChange?.(t,n)}}class D6{constructor(){this.elementsSet=new Set,this.idMap=new Map}add(t,n){const r=this.idMap.get(t);if(r!==n&&(r!==void 0&&this.elementsSet.delete(r),this.elementsSet.add(n),this.idMap.set(t,n),process.env.NODE_ENV!=="production"&&this.elementsSet.size!==this.idMap.size))throw new Error("Base UI: A trigger element cannot be registered under multiple IDs in PopupTriggerMap.")}delete(t){const n=this.idMap.get(t);n&&(this.elementsSet.delete(n),this.idMap.delete(t))}hasElement(t){return this.elementsSet.has(t)}hasMatchingElement(t){for(const n of this.elementsSet)if(t(n))return!0;return!1}getById(t){return this.idMap.get(t)}entries(){return this.idMap.entries()}elements(){return this.elementsSet.values()}get size(){return this.idMap.size}}function TT(e){const{open:t=!1,onOpenChange:n,elements:r={}}=e,i=Ox(),o=aT()!=null;if(process.env.NODE_ENV!=="production"){const s=r.reference;s&&!$t(s)&&console.error("Cannot pass a virtual element to the `elements.reference` option,","as it must be a real DOM element. Use `context.setPositionReference()`","instead.")}const a=ti(()=>new M6({open:t,onOpenChange:n,referenceElement:r.reference??null,floatingElement:r.floating??null,triggerElements:new D6,floatingId:i,nested:o,noEmit:!1})).current;return Ve(()=>{const s={open:t,floatingId:i};r.reference!==void 0&&(s.referenceElement=r.reference,s.domReferenceElement=$t(r.reference)?r.reference:null),r.floating!==void 0&&(s.floatingElement=r.floating),a.update(s)},[t,i,r.reference,r.floating,a]),a.context.onOpenChange=n,a.context.nested=o,a.context.noEmit=!1,a}function j6(e={}){const{nodeId:t,externalTree:n}=e,r=TT(e),i=e.rootContext||r,o={reference:i.useState("referenceElement"),floating:i.useState("floatingElement"),domReference:i.useState("domReferenceElement")},[a,s]=x.useState(null),u=x.useRef(null),c=dh(n);Ve(()=>{o.domReference&&(u.current=o.domReference)},[o.domReference]);const f=xT({...e,elements:{...o,...a&&{reference:a}}}),p=x.useCallback(I=>{const k=$t(I)?{getBoundingClientRect:()=>I.getBoundingClientRect(),getClientRects:()=>I.getClientRects(),contextElement:I}:I;s(k),f.refs.setReference(k)},[f.refs]),[g,h]=x.useState(null),[v,b]=x.useState(null);i.useSyncedValue("referenceElement",g),i.useSyncedValue("domReferenceElement",$t(g)?g:null),i.useSyncedValue("floatingElement",v);const y=x.useCallback(I=>{($t(I)||I===null)&&(u.current=I,h(I)),($t(f.refs.reference.current)||f.refs.reference.current===null||I!==null&&!$t(I))&&f.refs.setReference(I)},[f.refs,h]),w=x.useCallback(I=>{b(I),f.refs.setFloating(I)},[f.refs]),S=x.useMemo(()=>({...f.refs,setReference:y,setFloating:w,setPositionReference:p,domReference:u}),[f.refs,y,w,p]),E=x.useMemo(()=>({...f.elements,domReference:o.domReference}),[f.elements,o.domReference]),_=i.useState("open"),P=i.useState("floatingId"),R=x.useMemo(()=>({...f,dataRef:i.context.dataRef,open:_,onOpenChange:i.setOpen,events:i.context.events,floatingId:P,refs:S,elements:E,nodeId:t,rootStore:i}),[f,S,E,t,i,_,P]);return Ve(()=>{i.context.dataRef.current.floatingContext=R;const I=c?.nodesRef.current.find(k=>k.id===t);I&&(I.context=R)}),x.useMemo(()=>({...f,context:R,refs:S,elements:E,rootStore:i}),[f,S,E,R,i])}function L6(e=[]){const t=e.map(c=>c?.reference),n=e.map(c=>c?.floating),r=e.map(c=>c?.item),i=e.map(c=>c?.trigger),o=x.useCallback(c=>ed(c,e,"reference"),t),a=x.useCallback(c=>ed(c,e,"floating"),n),s=x.useCallback(c=>ed(c,e,"item"),r),u=x.useCallback(c=>ed(c,e,"trigger"),i);return x.useMemo(()=>({getReferenceProps:o,getFloatingProps:a,getItemProps:s,getTriggerProps:u}),[o,a,s,u])}function ed(e,t,n){const r=new Map,i=n==="item",o={};n==="floating"&&(o.tabIndex=-1,o[Hy]="");for(const a in e)i&&e&&(a===WI||a===HI)||(o[a]=e[a]);for(let a=0;a<t.length;a+=1){let s;const u=t[a]?.[n];typeof u=="function"?s=e?u(e):null:s=u,s&&EE(o,s,i,r)}return EE(o,e,i,r),o}function EE(e,t,n,r){for(const i in t){const o=t[i];n&&(i===WI||i===HI)||(i.startsWith("on")?(r.has(i)||r.set(i,[]),typeof o=="function"&&(r.get(i)?.push(o),e[i]=(...a)=>r.get(i)?.map(s=>s(...a)).find(s=>s!==void 0))):e[i]=o)}}const $6="Escape";function hh(e,t,n){switch(e){case"vertical":return t;case"horizontal":return n;default:return t||n}}function td(e,t){return hh(t,e===kx||e===fc,e===oa||e===aa)}function Um(e,t,n){return hh(t,e===fc,n?e===oa:e===aa)||e==="Enter"||e===" "||e===""}function F6(e,t,n){return hh(t,n?e===oa:e===aa,e===fc)}function V6(e,t,n,r){const i=n?e===aa:e===oa,o=e===kx;return t==="both"||t==="horizontal"&&r&&r>1?e===$6:hh(t,i,o)}function B6(e,t){const n="rootStore"in e?e.rootStore:e,r=n.useState("open"),i=n.useState("floatingElement"),o=n.useState("domReferenceElement"),a=n.context.dataRef,{listRef:s,activeIndex:u,onNavigate:c=()=>{},enabled:f=!0,selectedIndex:p=null,allowEscape:g=!1,loopFocus:h=!1,nested:v=!1,rtl:b=!1,virtual:y=!1,focusItemOnOpen:w="auto",focusItemOnHover:S=!0,openOnArrowKeyDown:E=!0,disabledIndices:_=void 0,orientation:P="vertical",parentOrientation:R,cols:I=1,id:k,resetOnPointerLeave:B=!0,externalTree:L}=t;process.env.NODE_ENV!=="production"&&(g&&(h||console.warn("`useListNavigation` looping must be enabled to allow escaping."),y||console.warn("`useListNavigation` must be virtual to allow escaping.")),P==="vertical"&&I>1&&console.warn("In grid list navigation mode (`cols` > 1), the `orientation` should",'be either "horizontal" or "both".'));const V=Gy(i),D=Zr(V),W=aT(),J=dh(L);Ve(()=>{a.current.orientation=P},[a,P]);const re=Uy(o),U=x.useRef(w),ee=x.useRef(p??-1),Z=x.useRef(null),ue=x.useRef(!0),X=Le(pe=>{c(ee.current===-1?null:ee.current,pe)}),Oe=x.useRef(X),Ee=x.useRef(!!i),Me=x.useRef(r),ye=x.useRef(!1),be=x.useRef(!1),$e=Zr(_),me=Zr(r),Se=Zr(p),q=Zr(B),te=Le(()=>{function pe(De){y?J?.events.emit("virtualfocus",De):Vu(De,{sync:ye.current,preventScroll:!0})}const xe=s.current[ee.current],ce=be.current;xe&&pe(xe),(ye.current?De=>De():requestAnimationFrame)(()=>{const De=s.current[ee.current]||xe;if(!De)return;xe||pe(De),j&&(ce||!ue.current)&&De.scrollIntoView?.({block:"nearest",inline:"nearest"})})});Ve(()=>{f&&(r&&i?(ee.current=p??-1,U.current&&p!=null&&(be.current=!0,X())):Ee.current&&(ee.current=-1,Oe.current()))},[f,r,i,p,X]),Ve(()=>{if(f){if(!r){ye.current=!1;return}if(i)if(u==null){if(ye.current=!1,Se.current!=null)return;if(Ee.current&&(ee.current=-1,te()),(!Me.current||!Ee.current)&&U.current&&(Z.current!=null||U.current===!0&&Z.current==null)){let pe=0;const xe=()=>{s.current[0]==null?(pe<2&&(pe?requestAnimationFrame:queueMicrotask)(xe),pe+=1):(ee.current=Z.current==null||Um(Z.current,P,b)||v?jm(s):ZC(s),Z.current=null,X())};xe()}}else Lu(s,u)||(ee.current=u,te(),be.current=!1)}},[f,r,i,u,Se,v,s,P,b,X,te,$e]),Ve(()=>{if(!f||i||!J||y||!Ee.current)return;const pe=J.nodesRef.current,xe=pe.find(De=>De.id===W)?.context?.elements.floating,ce=io(Zt(i)),Ce=pe.some(De=>De.context&&pt(De.context.elements.floating,ce));xe&&!Ce&&ue.current&&xe.focus({preventScroll:!0})},[f,i,J,W,y]),Ve(()=>{Oe.current=X,Me.current=r,Ee.current=!!i}),Ve(()=>{r||(Z.current=null,U.current=w)},[r,w]);const Y=u!=null,j=x.useMemo(()=>{function pe(ce){if(!me.current)return;const Ce=s.current.indexOf(ce.currentTarget);Ce!==-1&&ee.current!==Ce&&(ee.current=Ce,X(ce))}return{onFocus(ce){ye.current=!0,pe(ce)},onClick:({currentTarget:ce})=>ce.focus({preventScroll:!0}),onMouseMove(ce){ye.current=!0,be.current=!1,S&&pe(ce)},onPointerLeave(ce){if(!me.current||!ue.current||ce.pointerType==="touch")return;ye.current=!0;const Ce=ce.relatedTarget;!S||s.current.includes(Ce)||q.current&&(Vu(null,{sync:!0}),ee.current=-1,X(ce),y||D.current?.focus({preventScroll:!0}))}}},[me,D,S,s,X,q,y]),ie=x.useCallback(()=>R??J?.nodesRef.current.find(pe=>pe.id===W)?.context?.dataRef?.current.orientation,[W,J,R]),Q=Le(pe=>{if(ue.current=!1,ye.current=!0,pe.which===229||!me.current&&pe.currentTarget===D.current)return;if(v&&V6(pe.key,P,b,I)){td(pe.key,ie())||Lt(pe),n.setOpen(!1,Ze(ju,pe.nativeEvent)),nn(o)&&(y?J?.events.emit("virtualfocus",o):o.focus());return}const xe=ee.current,ce=jm(s,_),Ce=ZC(s,_);if(re||(pe.key==="Home"&&(Lt(pe),ee.current=ce,X(pe)),pe.key==="End"&&(Lt(pe),ee.current=Ce,X(pe))),I>1){const De=Array.from({length:s.current.length},()=>({width:1,height:1})),nt=Nq(De,I),kt=nt.findIndex(lt=>lt!=null&&!$u(s,lt,_)),Dn=nt.reduce((lt,Nt,mn)=>Nt!=null&&!$u(s,Nt,_)?mn:lt,-1),Ct=nt[kq({current:nt.map(lt=>lt!=null?s.current[lt]:null)},{event:pe,orientation:P,loopFocus:h,rtl:b,cols:I,disabledIndices:Dq([...(typeof _!="function"?_:null)||s.current.map((lt,Nt)=>$u(s,Nt,_)?Nt:void 0),void 0],nt),minIndex:kt,maxIndex:Dn,prevIndex:Mq(ee.current>Ce?ce:ee.current,De,nt,I,pe.key===fc?"bl":pe.key===(b?oa:aa)?"tr":"tl"),stopEvent:!0})];if(Ct!=null&&(ee.current=Ct,X(pe)),P==="both")return}if(td(pe.key,P)){if(Lt(pe),r&&!y&&io(pe.currentTarget.ownerDocument)===pe.currentTarget){ee.current=Um(pe.key,P,b)?ce:Ce,X(pe);return}Um(pe.key,P,b)?h?xe>=Ce?g&&xe!==s.current.length?ee.current=-1:(ye.current=!1,ee.current=ce):ee.current=Vn(s,{startingIndex:xe,disabledIndices:_}):ee.current=Math.min(Ce,Vn(s,{startingIndex:xe,disabledIndices:_})):h?xe<=ce?g&&xe!==-1?ee.current=s.current.length:(ye.current=!1,ee.current=Ce):ee.current=Vn(s,{startingIndex:xe,decrement:!0,disabledIndices:_}):ee.current=Math.max(ce,Vn(s,{startingIndex:xe,decrement:!0,disabledIndices:_})),Lu(s,ee.current)&&(ee.current=-1),X(pe)}}),Ae=x.useMemo(()=>y&&r&&Y&&{"aria-activedescendant":`${k}-${u}`},[y,r,Y,k,u]),G=x.useMemo(()=>({"aria-orientation":P==="both"?void 0:P,...re?{}:Ae,onKeyDown(pe){if(pe.key==="Tab"&&pe.shiftKey&&r&&!y){const xe=ur(pe.nativeEvent);if(xe&&!pt(D.current,xe))return;Lt(pe),n.setOpen(!1,Ze(rh,pe.nativeEvent)),nn(o)&&o.focus();return}Q(pe)},onPointerMove(){ue.current=!0}}),[Ae,Q,D,P,re,n,r,y,o]),fe=x.useMemo(()=>{function pe(ce){w==="auto"&&UI(ce.nativeEvent)&&(U.current=!y)}function xe(ce){U.current=w,w==="auto"&&GI(ce.nativeEvent)&&(U.current=!0)}return{onKeyDown(ce){const Ce=n.select("open");ue.current=!1;const De=ce.key.startsWith("Arrow"),nt=F6(ce.key,ie(),b),kt=td(ce.key,P),Dn=(v?nt:kt)||ce.key==="Enter"||ce.key.trim()==="";if(y&&Ce)return Q(ce);if(!(!Ce&&!E&&De)){if(Dn){const Ct=td(ce.key,ie());Z.current=v&&Ct?null:ce.key}if(v){nt&&(Lt(ce),Ce?(ee.current=jm(s,$e.current),X(ce)):n.setOpen(!0,Ze(ju,ce.nativeEvent,ce.currentTarget)));return}kt&&(Se.current!=null&&(ee.current=Se.current),Lt(ce),!Ce&&E?n.setOpen(!0,Ze(ju,ce.nativeEvent,ce.currentTarget)):Q(ce),Ce&&X(ce))}},onFocus(ce){n.select("open")&&!y&&(ee.current=-1,X(ce))},onPointerDown:xe,onPointerEnter:xe,onMouseDown:pe,onClick:pe}},[Q,$e,w,s,v,X,n,E,P,ie,b,Se,y]),ve=x.useMemo(()=>({...Ae,...fe}),[Ae,fe]);return x.useMemo(()=>f?{reference:ve,floating:G,item:j,trigger:fe}:{},[f,ve,G,fe,j])}function z6(e,t){const n="rootStore"in e?e.rootStore:e,r=n.context.dataRef,i=n.useState("open"),{listRef:o,activeIndex:a,onMatch:s,onTypingChange:u,enabled:c=!0,resetMs:f=750,selectedIndex:p=null}=t,g=ns(),h=x.useRef(""),v=x.useRef(p??a??-1),b=x.useRef(null);Ve(()=>{!i&&p!==null||(g.clear(),b.current=null,h.current!==""&&(h.current=""))},[i,p,g]),Ve(()=>{i&&h.current===""&&(v.current=p??a??-1)},[i,p,a]);const y=Le(P=>{P?r.current.typing||(r.current.typing=P,u?.(P)):r.current.typing&&(r.current.typing=P,u?.(P))}),w=Le(P=>{function R(D,W,J){const re=W.find(U=>U?.toLocaleLowerCase().indexOf(J.toLocaleLowerCase())===0);return re?D.indexOf(re):-1}const I=o.current;if(h.current.length>0&&h.current[0]!==" "&&(R(I,I,h.current)===-1?y(!1):P.key===" "&&Lt(P)),I==null||P.key.length!==1||P.ctrlKey||P.metaKey||P.altKey)return;i&&P.key!==" "&&(Lt(P),y(!0));const k=h.current==="";k&&(v.current=p??a??-1),I.every(D=>D?D[0]?.toLocaleLowerCase()!==D[1]?.toLocaleLowerCase():!0)&&h.current===P.key&&(h.current="",v.current=b.current),h.current+=P.key,g.start(f,()=>{h.current="",v.current=b.current,y(!1)});const L=k?p??a??-1:v.current,V=R(I,[...I.slice((L||0)+1),...I.slice(0,(L||0)+1)],h.current);V!==-1?(s?.(V),b.current=V):P.key!==" "&&(h.current="",y(!1))}),S=Le(P=>{const R=P.relatedTarget,I=n.select("domReferenceElement"),k=n.select("floatingElement"),B=pt(I,R),L=pt(k,R);B||L||(g.clear(),h.current="",v.current=b.current,y(!1))}),E=x.useMemo(()=>({onKeyDown:w,onBlur:S}),[w,S]),_=x.useMemo(()=>({onKeyDown:w,onKeyUp(P){P.key===" "&&y(!1)},onBlur:S}),[w,S,y]);return x.useMemo(()=>c?{reference:E,floating:_}:{},[c,E,_])}function W6(e){const t=x.useRef(""),n=x.useCallback(i=>{i.defaultPrevented||(t.current=i.pointerType,e(i,i.pointerType))},[e]);return{onClick:x.useCallback(i=>{if(i.detail===0){e(i,"keyboard");return}"pointerType"in i?e(i,i.pointerType):e(i,t.current),t.current=""},[e]),onPointerDown:n}}function H6(e){const[t,n]=x.useState(null),r=Le((s,u)=>{e||n(u||(zI?"touch":""))}),i=x.useCallback(()=>{n(null)},[]),{onClick:o,onPointerDown:a}=W6(r);return x.useMemo(()=>({openMethod:t,reset:i,triggerProps:{onClick:o,onPointerDown:a}}),[t,i,o,a])}let zx=(function(e){return e.open="data-open",e.closed="data-closed",e[e.startingStyle=Gu.startingStyle]="startingStyle",e[e.endingStyle=Gu.endingStyle]="endingStyle",e.anchorHidden="data-anchor-hidden",e.side="data-side",e.align="data-align",e})({}),Zy=(function(e){return e.popupOpen="data-popup-open",e.pressed="data-pressed",e})({});const U6={[Zy.popupOpen]:""},G6={[Zy.popupOpen]:"",[Zy.pressed]:""},q6={[zx.open]:""},K6={[zx.closed]:""},Y6={[zx.anchorHidden]:""},X6={open(e){return e?U6:null}},Z6={open(e){return e?G6:null}},kT={open(e){return e?q6:K6},anchorHidden(e){return e?Y6:null}};function Q6(e){return Ex(19)?e:e?"true":void 0}const NT=x.forwardRef(function(t,n){const{cutout:r,...i}=t;let o;if(r){const a=r?.getBoundingClientRect();o=`polygon(
|
|
25
25
|
0% 0%,
|
|
26
26
|
100% 0%,
|
|
27
27
|
100% 100%,
|
|
@@ -32,49 +32,49 @@ Avoid returning a new reference inside your input selector, e.g.
|
|
|
32
32
|
${a.right}px ${a.bottom}px,
|
|
33
33
|
${a.right}px ${a.top}px,
|
|
34
34
|
${a.left}px ${a.top}px
|
|
35
|
-
)`}return P.jsx("div",{ref:n,role:"presentation","data-base-ui-inert":"",...i,style:{position:"fixed",inset:0,userSelect:"none",WebkitUserSelect:"none",clipPath:o}})});process.env.NODE_ENV!=="production"&&(cT.displayName="InternalBackdrop");function q6(e){const t=x.useRef(!0);t.current&&(t.current=!1,e())}const S0=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(S0.displayName="ComboboxRootContext");const E0=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(E0.displayName="ComboboxFloatingContext");const _0=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(_0.displayName="ComboboxDerivedItemsContext");const O0=x.createContext("");process.env.NODE_ENV!=="production"&&(O0.displayName="ComboboxInputValueContext");function Nr(){const e=x.useContext(S0);if(!e)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: ComboboxRootContext is missing. Combobox parts must be placed within <Combobox.Root>.":pi(22));return e}function ah(){const e=x.useContext(E0);if(!e)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: ComboboxFloatingContext is missing. Combobox parts must be placed within <Combobox.Root>.":pi(23));return e}function da(){const e=x.useContext(_0);if(!e)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: ComboboxItemsContext is missing. Combobox parts must be placed within <Combobox.Root>.":pi(24));return e}function P0(){return x.useContext(O0)}const K6=(e,t)=>Object.is(e,t);function Qa(e,t,n){return e==null||t==null?Object.is(e,t):n(e,t)}function Y6(e,t,n){return!e||e.length===0?!1:e.some(r=>r===void 0?!1:Qa(t,r,n))}function Gd(e,t,n){return!e||e.length===0?-1:e.findIndex(r=>r===void 0?!1:Qa(r,t,n))}function X6(e,t,n){return e.filter(r=>!Qa(t,r,n))}function jy(e){if(e==null)return"";if(typeof e=="string")return e;try{return JSON.stringify(e)}catch{return String(e)}}function A0(e){return e!=null&&e.length>0&&typeof e[0]=="object"&&e[0]!=null&&"items"in e[0]}function Z6(e){if(!Array.isArray(e))return e!=null&&!("null"in e);if(A0(e)){for(const t of e)for(const n of t.items)if(n&&n.value==null&&n.label!=null)return!0;return!1}for(const t of e)if(t&&t.value==null&&t.label!=null)return!0;return!1}function sr(e,t){if(t&&e!=null)return t(e)??"";if(e&&typeof e=="object"){if("label"in e&&e.label!=null)return String(e.label);if("value"in e)return String(e.value)}return jy(e)}function uu(e,t){return t&&e!=null?t(e)??"":e&&typeof e=="object"&&"value"in e&&"label"in e?jy(e.value):jy(e)}function fT(e,t,n){function r(){return sr(e,n)}if(n&&e!=null)return n(e);if(e&&typeof e=="object"&&"label"in e&&e.label!=null)return e.label;if(t&&!Array.isArray(t))return t[e]??r();if(Array.isArray(t)){const i=A0(t)?t.flatMap(o=>o.items):t;if(e==null||typeof e!="object"){const o=i.find(a=>a.value===e);return o&&o.label!=null?o.label:r()}if("value"in e){const o=i.find(a=>a&&a.value===e.value);if(o&&o.label!=null)return o.label}}return r()}function Q6(e,t,n){return e.reduce((r,i,o)=>(o>0&&r.push(", "),r.push(P.jsx(x.Fragment,{children:fT(i,t,n)},o)),r),[])}const ge={id:Ne(e=>e.id),query:Ne(e=>e.query),items:Ne(e=>e.items),selectedValue:Ne(e=>e.selectedValue),hasSelectionChips:Ne(e=>{const t=e.selectedValue;return Array.isArray(t)&&t.length>0}),hasSelectedValue:Ne(e=>{const{selectedValue:t,selectionMode:n}=e;return t==null?!1:n==="multiple"&&Array.isArray(t)?t.length>0:!0}),hasNullItemLabel:Ne((e,t)=>t?Z6(e.items):!1),open:Ne(e=>e.open),mounted:Ne(e=>e.mounted),forceMounted:Ne(e=>e.forceMounted),inline:Ne(e=>e.inline),activeIndex:Ne(e=>e.activeIndex),selectedIndex:Ne(e=>e.selectedIndex),isActive:Ne((e,t)=>e.activeIndex===t),isSelected:Ne((e,t)=>{const n=e.isItemEqualToValue,r=e.selectedValue;return Array.isArray(r)?r.some(i=>Qa(t,i,n)):Qa(t,r,n)}),transitionStatus:Ne(e=>e.transitionStatus),popupProps:Ne(e=>e.popupProps),inputProps:Ne(e=>e.inputProps),triggerProps:Ne(e=>e.triggerProps),getItemProps:Ne(e=>e.getItemProps),positionerElement:Ne(e=>e.positionerElement),listElement:Ne(e=>e.listElement),triggerElement:Ne(e=>e.triggerElement),inputElement:Ne(e=>e.inputElement),popupSide:Ne(e=>e.popupSide),openMethod:Ne(e=>e.openMethod),inputInsidePopup:Ne(e=>e.inputInsidePopup),selectionMode:Ne(e=>e.selectionMode),listRef:Ne(e=>e.listRef),labelsRef:Ne(e=>e.labelsRef),popupRef:Ne(e=>e.popupRef),emptyRef:Ne(e=>e.emptyRef),inputRef:Ne(e=>e.inputRef),keyboardActiveRef:Ne(e=>e.keyboardActiveRef),chipsContainerRef:Ne(e=>e.chipsContainerRef),clearRef:Ne(e=>e.clearRef),valuesRef:Ne(e=>e.valuesRef),allValuesRef:Ne(e=>e.allValuesRef),name:Ne(e=>e.name),disabled:Ne(e=>e.disabled),readOnly:Ne(e=>e.readOnly),required:Ne(e=>e.required),grid:Ne(e=>e.grid),isGrouped:Ne(e=>e.isGrouped),virtualized:Ne(e=>e.virtualized),onOpenChangeComplete:Ne(e=>e.onOpenChangeComplete),openOnInputClick:Ne(e=>e.openOnInputClick),itemToStringLabel:Ne(e=>e.itemToStringLabel),isItemEqualToValue:Ne(e=>e.isItemEqualToValue),modal:Ne(e=>e.modal),autoHighlight:Ne(e=>e.autoHighlight),submitOnItemClick:Ne(e=>e.submitOnItemClick)};let oE=(function(e){return e.disabled="data-disabled",e.valid="data-valid",e.invalid="data-invalid",e.touched="data-touched",e.dirty="data-dirty",e.filled="data-filled",e.focused="data-focused",e})({});const J6={badInput:!1,customError:!1,patternMismatch:!1,rangeOverflow:!1,rangeUnderflow:!1,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valid:null,valueMissing:!1},eK={valid(e){return e===null?null:e?{[oE.valid]:""}:{[oE.invalid]:""}}},dT=x.createContext({invalid:void 0,name:void 0,validityData:{state:J6,errors:[],error:"",value:"",initialValue:null},setValidityData:Wt,disabled:void 0,touched:!1,setTouched:Wt,dirty:!1,setDirty:Wt,filled:!1,setFilled:Wt,focused:!1,setFocused:Wt,validate:()=>null,validationMode:"onSubmit",validationDebounceTime:0,shouldValidateOnChange:()=>!1,state:{disabled:!1,valid:null,touched:!1,dirty:!1,filled:!1,focused:!1},markedDirtyRef:{current:!1},validation:{getValidationProps:(e=Xn)=>e,getInputValidationProps:(e=Xn)=>e,inputRef:{current:null},commit:async()=>{}}});process.env.NODE_ENV!=="production"&&(dT.displayName="FieldRootContext");function oc(e=!0){const t=x.useContext(dT);if(t.setValidityData===Wt&&!e)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: FieldRootContext is missing. Field parts must be placed within <Field.Root>.":pi(28));return t}function tK(e,t){return{...e,state:{...e.state,valid:!t&&e.state.valid}}}const pT=x.createContext({formRef:{current:{fields:new Map}},errors:{},clearErrors:Wt,validationMode:"onSubmit",submitAttemptedRef:{current:!1}});process.env.NODE_ENV!=="production"&&(pT.displayName="FormContext");function hT(){return x.useContext(pT)}function nK(e){const{enabled:t=!0,value:n,id:r,name:i,controlRef:o,commit:a}=e,{formRef:s}=hT(),{invalid:u,markedDirtyRef:c,validityData:d,setValidityData:p}=oc(),g=Me(e.getValue);je(()=>{if(!t)return;let h=n;h===void 0&&(h=g()),d.initialValue===null&&h!==null&&p(v=>({...v,initialValue:h}))},[t,p,n,d.initialValue,g]),je(()=>{!t||!r||s.current.fields.set(r,{getValue:g,name:i,controlRef:o,validityData:tK(d,u),validate(h=!0){let v=n;v===void 0&&(v=g()),c.current=!0,h?la.flushSync(()=>a(v)):a(v)}})},[a,o,t,s,g,r,u,c,i,d,n]),je(()=>{const h=s.current.fields;return()=>{r&&h.delete(r)}},[s,r])}const gT=x.createContext({controlId:void 0,registerControlId:Wt,labelId:void 0,setLabelId:Wt,messageIds:[],setMessageIds:Wt,getDescriptionProps:e=>e});process.env.NODE_ENV!=="production"&&(gT.displayName="LabelableContext");function R0(){return x.useContext(gT)}function mT(e={}){const{id:t,implicit:n=!1,controlRef:r}=e,{controlId:i,registerControlId:o}=R0(),a=s0(t),s=n?i:void 0,u=ei(()=>Symbol("labelable-control")),c=x.useRef(!1),d=x.useRef(t!=null),p=Me(()=>{!c.current||o===Wt||(c.current=!1,o(u.current,void 0))});return je(()=>{if(o===Wt)return;let g;if(n){const h=r?.current;Lt(h)&&h.closest("label")!=null?g=t??null:g=s??a}else if(t!=null)d.current=!0,g=t;else if(d.current)g=a;else{p();return}if(g===void 0){p();return}c.current=!0,o(u.current,g)},[t,r,s,o,n,a,u,p]),x.useEffect(()=>p,[p]),i??a}function rK(e,t){return(n,r)=>{if(n==null)return!1;const i=sr(n,t);return e.contains(i,r)}}function iK(e,t,n){return(r,i)=>{if(r==null)return!1;if(!i)return!0;const o=sr(r,t),a=n!=null?sr(n,t):"";return a&&e.contains(a,i)&&a.length===i.length?!0:e.contains(o,i)}}const aE=new Map;function vT(e){return Array.isArray(e)?e.map(t=>vT(t)).join(","):e==null?"":String(e)}function oK(e={}){const t={usage:"search",sensitivity:"base",ignorePunctuation:!0,...e},n=`${vT(e.locale)}|${JSON.stringify(t)}`,r=aE.get(n);if(r)return r;const i=new Intl.Collator(e.locale,t),o={contains(a,s,u){if(!s)return!0;const c=sr(a,u);for(let d=0;d<=c.length-s.length;d+=1)if(i.compare(c.slice(d,d+s.length),s)===0)return!0;return!1},startsWith(a,s,u){if(!s)return!0;const c=sr(a,u);return i.compare(c.slice(0,s.length),s)===0},endsWith(a,s,u){if(!s)return!0;const c=sr(a,u),d=s.length;return c.length>=d&&i.compare(c.slice(c.length-d),s)===0}};return aE.set(n,o),o}const aK=oK;function Kf(e,t){const n=x.useRef(e),r=Me(t);je(()=>{n.current!==e&&r(n.current)},[e,r]),je(()=>{n.current=e},[e])}const yT=Symbol("none"),Na={value:yT,index:-1};function sK(e){const{id:t,onOpenChangeComplete:n,defaultSelectedValue:r=null,selectedValue:i,onSelectedValueChange:o,defaultInputValue:a,inputValue:s,selectionMode:u="none",onItemHighlighted:c,name:d,disabled:p=!1,readOnly:g=!1,required:h=!1,inputRef:v,grid:b=!1,items:y,filteredItems:w,filter:C,openOnInputClick:E=!0,autoHighlight:_=!1,keepHighlight:O=!1,highlightItemOnHover:R=!0,loopFocus:I=!0,itemToStringLabel:k,itemToStringValue:B,isItemEqualToValue:L=K6,virtualized:V=!1,inline:D=!1,fillInputOnItemPress:H=!0,modal:J=!1,limit:te=-1,autoComplete:G="list",formAutoComplete:ee,locale:Q,submitOnItemClick:pe=!1}=e,{clearErrors:K}=hT(),{setDirty:Ae,validityData:Se,shouldValidateOnChange:$e,setFilled:we,name:Ce,disabled:ze,setTouched:Ke,setFocused:Fe,validationMode:Y,validation:oe}=oc(),ne=mT({id:t}),$=aK({locale:Q}),[ie,Z]=x.useState(!1),[Re,U]=x.useState(null),fe=x.useRef([]),me=x.useRef([]),de=x.useRef(null),ve=x.useRef(null),le=x.useRef(null),be=x.useRef(!0),ke=x.useRef(!1),et=x.useRef(null),Tt=x.useRef(null),Dn=x.useRef(null),Ct=x.useRef(Na),ot=x.useRef(null),kt=x.useRef([]),mn=x.useRef([]),on=ze||p,_n=Ce??d,Qt=u==="multiple",vn=u==="single",hr=s!==void 0||a!==void 0,Hn=y!==void 0,pt=w!==void 0;let ht;_==="always"?ht="always":ht=_?"input-change":!1;const[Ve,jn]=mm({controlled:i,default:Qt?r??jf:r,name:"Combobox",state:"selectedValue"}),On=x.useMemo(()=>C===null?()=>!0:C!==void 0?C:vn&&!ie?iK($,k,Ve):rK($,k),[C,vn,Ve,ie,$,k]),mi=ei(()=>hr?a??"":vn?sr(Ve,k):"").current,[Jt,ma]=mm({controlled:s,default:mi,name:"Combobox",state:"inputValue"}),[$t,Dl]=mm({controlled:e.open,default:e.defaultOpen,name:"Combobox",state:"open"}),nr=A0(y),yn=Re??(Jt===""?"":String(Jt).trim()),va=vn?sr(Ve,k):"",Ao=vn&&!ie&&yn!==""&&va!==""&&va.length===yn.length&&$.contains(va,yn),Dr=Ao?"":yn,vs=Hn&&pt&&Ao,jr=x.useMemo(()=>y?nr?y.flatMap(xe=>xe.items):y:jf,[y,nr]),gr=x.useMemo(()=>{if(w&&!vs)return w;if(!y)return jf;if(nr){const De=y,Ze=[];let Bt=0;for(const en of De){if(te>-1&&Bt>=te)break;const tn=Dr===""?en.items:en.items.filter(Rs=>On(Rs,Dr,k));if(tn.length===0)continue;const bi=te>-1?te-Bt:1/0,Bi=tn.slice(0,bi);if(Bi.length>0){const Rs={...en,items:Bi};Ze.push(Rs),Bt+=Bi.length}}return Ze}if(Dr==="")return te>-1?jr.slice(0,te):jr;const xe=[];for(const De of jr){if(te>-1&&xe.length>=te)break;On(De,Dr,k)&&xe.push(De)}return xe},[w,vs,y,nr,Dr,te,On,k,jr]),Un=x.useMemo(()=>nr?gr.flatMap(De=>De.items):gr,[gr,nr]),rt=ei(()=>new sT({id:ne,selectedValue:Ve,open:$t,filter:On,query:yn,items:y,selectionMode:u,listRef:fe,labelsRef:me,popupRef:de,emptyRef:le,inputRef:ve,keyboardActiveRef:be,chipsContainerRef:et,clearRef:Tt,valuesRef:kt,allValuesRef:mn,selectionEventRef:Dn,name:_n,disabled:on,readOnly:g,required:h,grid:b,isGrouped:nr,virtualized:V,openOnInputClick:E,itemToStringLabel:k,isItemEqualToValue:L,modal:J,autoHighlight:ht,submitOnItemClick:pe,hasInputValue:hr,mounted:!1,forceMounted:!1,transitionStatus:"idle",inline:D,activeIndex:null,selectedIndex:null,popupProps:{},inputProps:{},triggerProps:{},positionerElement:null,listElement:null,triggerElement:null,inputElement:null,popupSide:null,openMethod:null,inputInsidePopup:!0,onOpenChangeComplete:n||Wt,setOpen:Wt,setInputValue:Wt,setSelectedValue:Wt,setIndices:Wt,onItemHighlighted:Wt,handleSelection:Wt,getItemProps:()=>Xn,forceMount:Wt,requestSubmit:Wt})).current,vi=u==="none"?Jt:Ve,og=x.useMemo(()=>u==="none"?vi:Array.isArray(Ve)?Ve.map(xe=>uu(xe,B)):uu(Ve,B),[vi,B,u,Ve]),jl=Me(c),Ll=Me(n),ys=he(rt,ge.activeIndex),Nc=he(rt,ge.selectedIndex),bs=he(rt,ge.positionerElement),Mc=he(rt,ge.listElement),ya=he(rt,ge.triggerElement),$l=he(rt,ge.inputElement),mr=he(rt,ge.inline),yi=he(rt,ge.inputInsidePopup),xs=Xr(ya),{mounted:Dc,setMounted:ws,transitionStatus:Fl}=dI($t),{openMethod:jc,triggerProps:Vl,reset:Lc}=$6($t);nK({id:ne,name:_n,commit:oe.commit,value:vi,controlRef:yi?xs:ve,getValue:()=>og});const ba=Me(()=>{y?me.current=Un.map(xe=>sr(xe,k)):rt.set("forceMounted",!0)}),$c=x.useRef(Ve);je(()=>{Ve!==$c.current&&ba()},[ba,Ve]);const vr=Me(xe=>{rt.update(xe);const De=xe.type||"none";if(xe.activeIndex!==void 0)if(xe.activeIndex===null)Ct.current!==Na&&(Ct.current=Na,jl(void 0,su(De,void 0,{index:-1})));else{const Ze=kt.current[xe.activeIndex];Ct.current={value:Ze,index:xe.activeIndex},jl(Ze,su(De,void 0,{index:xe.activeIndex}))}}),Lr=Me((xe,De)=>{if(ke.current=De.reason===Uo,e.onInputValueChange?.(xe,De),!De.isCanceled){if(De.reason===Js){const Ze=De.event,Bt=Ze.inputType;if(Ze.type==="compositionend"||Bt!=null&&Bt!==""&&Bt!=="insertReplacementText"){const tn=xe.trim()!=="";tn&&Z(!0),ot.current={hasQuery:tn},tn&&ht&&rt.state.activeIndex==null&&rt.set("activeIndex",0)}}ma(xe)}}),xa=Me((xe,De)=>{if($t!==xe&&(De.reason==="escape-key"&&Hn&&Un.length===0&&!rt.state.emptyRef.current&&De.allowPropagation(),e.onOpenChange?.(xe,De),!De.isCanceled&&(!xe&&ie&&(vn?(mr||U(yn),yn===""&&Z(!1)):Qt&&(mr||yi?vr({activeIndex:null}):U(yn),Lr("",Xe(Uo,De.event)))),Dl(xe),!xe&&yi&&(De.reason===Kp||De.reason===o0)&&(Ke(!0),Fe(!1),Y==="onBlur")))){const Ze=u==="none"?Jt:Ve;oe.commit(Ze)}}),Cs=Me((xe,De)=>{if(o?.(xe,De),De.isCanceled)return;jn(xe),(u==="none"&&de.current&&H||vn&&!rt.state.inputInsidePopup)&&Lr(sr(xe,k),Xe(De.reason,De.event)),vn&&xe!=null&&De.reason!==Js&&ie&&!mr&&U(yn)}),Fc=Me((xe,De)=>{let Ze=De;if(Ze===void 0){if(ys===null)return;Ze=kt.current[ys]}const Bt=lr(xe),en=Dn.current??xe;Dn.current=null;const tn=Xe(qG,en),bi=Bt?.closest("a")?.getAttribute("href");if(bi){bi.startsWith("#")&&xa(!1,tn);return}if(Qt){const Bi=Array.isArray(Ve)?Ve:[],lg=Y6(Bi,Ze,rt.state.isItemEqualToValue)?X6(Bi,Ze,rt.state.isItemEqualToValue):[...Bi,Ze];if(Cs(lg,tn),!(ve.current?ve.current.value.trim()!=="":!1))return;rt.state.inputInsidePopup?Lr("",Xe(Uo,tn.event)):xa(!1,tn)}else Cs(Ze,tn),xa(!1,tn)}),Ss=Me(()=>{if(!rt.state.submitOnItemClick)return;const xe=rt.state.inputElement?.form;xe&&typeof xe.requestSubmit=="function"&&xe.requestSubmit()}),Es=Me(()=>{if(ws(!1),Ll?.(!1),Z(!1),Lc(),U(null),vr(u==="none"?{activeIndex:null,selectedIndex:null}:{activeIndex:null}),Qt&&ve.current&&ve.current.value!==""&&!ke.current&&Lr("",Xe(Uo)),vn)if(rt.state.inputInsidePopup)ve.current&&ve.current.value!==""&&Lr("",Xe(Uo));else{const xe=sr(Ve,k);ve.current&&ve.current.value!==xe&&Lr(xe,Xe(xe===""?Uo:Yr))}}),Bl=x.useMemo(()=>mr&&bs?{current:bs.closest('[role="dialog"]')}:de,[mr,bs]);m0({enabled:!e.actionsRef,open:$t,ref:Bl,onComplete(){$t||Es()}}),x.useImperativeHandle(e.actionsRef,()=>({unmount:Es}),[Es]),je(function(){if($t||u==="none")return;const De=y?jr:mn.current;if(Qt){const Ze=Array.isArray(Ve)?Ve:[],Bt=Ze[Ze.length-1],en=Gd(De,Bt,L);vr({selectedIndex:en===-1?null:en})}else{const Ze=Gd(De,Ve,L);vr({selectedIndex:Ze===-1?null:Ze})}},[$t,Ve,y,u,jr,Qt,L,vr]),je(()=>{y&&(kt.current=Un,fe.current.length=Un.length)},[y,Un]),je(()=>{const xe=ot.current;if(xe&&(xe.hasQuery?ht&&rt.set("activeIndex",0):ht==="always"&&rt.set("activeIndex",0),ot.current=null),!$t&&!mr)return;const Ze=Hn||pt?Un:kt.current,Bt=rt.state.activeIndex;if(Bt==null){if(ht==="always"&&Ze.length>0){rt.set("activeIndex",0);return}Ct.current!==Na&&(Ct.current=Na,rt.state.onItemHighlighted(void 0,su(Yr,void 0,{index:-1})));return}if(Bt>=Ze.length){Ct.current!==Na&&(Ct.current=Na,rt.state.onItemHighlighted(void 0,su(Yr,void 0,{index:-1}))),rt.set("activeIndex",null);return}const en=Ze[Bt],tn=Ct.current.value,bi=tn!==yT&&Qa(en,tn,rt.state.isItemEqualToValue);(Ct.current.index!==Bt||!bi)&&(Ct.current={value:en,index:Bt},rt.state.onItemHighlighted(en,su(Yr,void 0,{index:Bt})))},[ys,ht,pt,Hn,Un,mr,$t,rt]),je(()=>{if(u==="none"){we(String(Jt)!=="");return}we(Qt?Array.isArray(Ve)&&Ve.length>0:Ve!=null)},[we,u,Jt,Ve,Qt]),x.useEffect(()=>{Hn&&ht&&Un.length===0&&vr({activeIndex:null})},[Hn,ht,Un.length,vr]),Kf(yn,()=>{!$t||yn===""||yn===String(mi)||Z(!0)}),Kf(Ve,()=>{if(u!=="none"&&(K(_n),Ae(Ve!==Se.initialValue),$e()?oe.commit(Ve):oe.commit(Ve,!0),vn&&!hr&&!yi)){const xe=sr(Ve,k);Jt!==xe&&Lr(xe,Xe(Yr))}}),Kf(Jt,()=>{u==="none"&&(K(_n),Ae(Jt!==Se.initialValue),$e()?oe.commit(Jt):oe.commit(Jt,!0))}),Kf(y,()=>{if(!vn||hr||yi||ie)return;const xe=sr(Ve,k);Jt!==xe&&Lr(xe,Xe(Yr))});const _s=lT({open:mr?!0:$t,onOpenChange:xa,elements:{reference:yi?ya:$l,floating:bs}});let Os,Ro;mr||(Os=b?"grid":"listbox",Ro=$t?"true":"false");const Vc=x.useMemo(()=>{const xe=$l?.tagName==="INPUT",De=xe||$t,Ze=xe?{autoComplete:"off",spellCheck:"false",autoCorrect:"off",autoCapitalize:"none"}:{};return De&&(Ze.role="combobox",Ze["aria-expanded"]=Ro,Ze["aria-haspopup"]=Os,Ze["aria-controls"]=$t?Mc?.id:void 0,Ze["aria-autocomplete"]=G),{reference:Ze,floating:{role:"presentation"}}},[$l,$t,Ro,Os,Mc?.id,G]),ag=zI(_s,{enabled:!g&&!on&&E,event:"mousedown-only",toggle:!1,touchOpenDelay:yi?0:50,reason:YG}),Bc=Zq(_s,{enabled:!g&&!on&&!mr,outsidePressEvent:{mouse:"sloppy",touch:"intentional"},bubbles:mr?!0:void 0,outsidePress(xe){const De=lr(xe);return!ft(ya,De)&&!ft(Tt.current,De)&&!ft(et.current,De)}}),zc=D6(_s,{enabled:!g&&!on,id:ne,listRef:fe,activeIndex:ys,selectedIndex:Nc,virtual:!0,loopFocus:I,allowEscape:I&&!ht,focusItemOnOpen:ie||u==="none"&&!ht?!1:"auto",focusItemOnHover:R,resetOnPointerLeave:!O,cols:b?2:1,orientation:b?"horizontal":void 0,disabledIndices:jf,onNavigate(xe,De){!De&&!$t||Fl==="ending"||vr(De?{activeIndex:xe,type:be.current?"keyboard":"pointer"}:{activeIndex:xe})}}),{getReferenceProps:wa,getFloatingProps:zl,getItemProps:Ps}=T6([Vc,ag,Bc,zc]);q6(()=>{rt.update({inline:D,popupProps:zl(),inputProps:wa(),triggerProps:Vl,getItemProps:Ps,setOpen:xa,setInputValue:Lr,setSelectedValue:Cs,setIndices:vr,onItemHighlighted:jl,handleSelection:Fc,forceMount:ba,requestSubmit:Ss})}),je(()=>{rt.update({id:ne,selectedValue:Ve,open:$t,mounted:Dc,transitionStatus:Fl,items:y,inline:D,popupProps:zl(),inputProps:wa(),triggerProps:Vl,openMethod:jc,getItemProps:Ps,selectionMode:u,name:_n,disabled:on,readOnly:g,required:h,grid:b,isGrouped:nr,virtualized:V,onOpenChangeComplete:Ll,openOnInputClick:E,itemToStringLabel:k,modal:J,autoHighlight:ht,isItemEqualToValue:L,submitOnItemClick:pe,hasInputValue:hr,requestSubmit:Ss})},[rt,ne,Ve,$t,Dc,Fl,y,zl,wa,Ps,jc,Vl,u,_n,on,g,h,oe,b,nr,V,Ll,E,k,J,L,pe,hr,D,Ss,ht]);const Wl=Lu(v,oe.inputRef),Hl=x.useMemo(()=>({query:yn,hasItems:Hn,filteredItems:gr,flatFilteredItems:Un}),[yn,Hn,gr,Un]),Io=x.useMemo(()=>Array.isArray(vi)?"":uu(vi,B),[vi,B]),Wc=Qt&&Array.isArray(Ve)&&Ve.length>0,As=Qt||u==="none"?void 0:_n,sg=x.useMemo(()=>!Qt||!Array.isArray(Ve)||!_n?null:Ve.map(xe=>{const De=uu(xe,B);return P.jsx("input",{type:"hidden",name:_n,value:De},De)}),[Qt,Ve,_n,B]),Hc=P.jsxs(x.Fragment,{children:[e.children,P.jsx("input",{...oe.getInputValidationProps({onFocus(){if(yi){ya?.focus();return}(ve.current||ya)?.focus()},onChange(xe){if(xe.nativeEvent.defaultPrevented)return;const De=xe.target.value,Ze=Xe(Yr,xe.nativeEvent);function Bt(){if(Qt)return;if(u==="none"){Ae(De!==Se.initialValue),Lr(De,Ze),$e()&&oe.commit(De);return}const en=kt.current.find(tn=>uu(tn,B).toLowerCase()===De.toLowerCase());en!=null&&(Ae(en!==Se.initialValue),Cs?.(en,Ze),$e()&&oe.commit(en))}y?Bt():(ba(),queueMicrotask(Bt))}}),id:ne&&As==null?`${ne}-hidden-input`:void 0,name:As,autoComplete:ee,disabled:on,required:h&&!Wc,readOnly:g,value:Io,ref:Wl,style:As?tq:v0,tabIndex:-1,"aria-hidden":!0}),sg]});return P.jsx(S0.Provider,{value:rt,children:P.jsx(E0.Provider,{value:_s,children:P.jsx(_0.Provider,{value:Hl,children:P.jsx(O0.Provider,{value:Jt,children:Hc})})})})}const bT={...U6,...eK,popupSide:e=>e?{"data-popup-side":e}:null,listEmpty:e=>e?{"data-list-empty":""}:null};function lK(e){const t=e.getBoundingClientRect();if(process.env.NODE_ENV!=="production")return t;const n=window.getComputedStyle(e,"::before"),r=window.getComputedStyle(e,"::after");if(!(n.content!=="none"||r.content!=="none"))return t;const o=parseFloat(n.width)||0,a=parseFloat(n.height)||0,s=parseFloat(r.width)||0,u=parseFloat(r.height)||0,c=Math.max(t.width,o,s),d=Math.max(t.height,a,u),p=c-t.width,g=d-t.height;return{left:t.left-p/2,right:t.right+p/2,top:t.top-g/2,bottom:t.bottom+g/2}}const Yf=2,xT=x.forwardRef(function(t,n){const{render:r,className:i,nativeButton:o=!0,disabled:a=!1,id:s,...u}=t,{state:c,disabled:d,setTouched:p,setFocused:g,validationMode:h,validation:v}=oc(),{labelId:b}=R0(),y=Nr(),{filteredItems:w}=da(),C=he(y,ge.selectionMode),E=he(y,ge.disabled),_=he(y,ge.readOnly),O=he(y,ge.required),R=he(y,ge.mounted),I=he(y,ge.popupSide),k=he(y,ge.positionerElement),B=he(y,ge.listElement),L=he(y,ge.triggerProps),V=he(y,ge.triggerElement),D=he(y,ge.inputInsidePopup),H=he(y,ge.id),J=he(y,ge.open),te=he(y,ge.selectedValue),G=he(y,ge.activeIndex),ee=he(y,ge.selectedIndex),Q=he(y,ge.hasSelectedValue),pe=ah(),K=P0(),Ae=Xa(),Se=d||E||a,$e=w.length===0,we=R&&k?I:null;mT({id:D?s:void 0});const Ce=D?s??H:s,ze=x.useRef("");function Ke(U){ze.current=U.pointerType}const Fe=pe.useState("domReferenceElement");x.useEffect(()=>{D&&V&&V!==Fe&&pe.set("domReferenceElement",V)},[V,Fe,pe,D]);const{reference:Y}=j6(pe,{enabled:!J&&!_&&!E&&C==="single",listRef:y.state.labelsRef,activeIndex:G,selectedIndex:ee,onMatch(U){const fe=y.state.valuesRef.current[U];fe!==void 0&&y.state.setSelectedValue(fe,Xe("none"))}}),{reference:oe}=zI(pe,{enabled:!_&&!E,event:"mousedown"}),{buttonRef:ne,getButtonProps:$}=Jp({native:o,disabled:Se}),ie={...c,open:J,disabled:Se,popupSide:we,listEmpty:$e,placeholder:!Q},Z=Me(U=>{y.set("triggerElement",U)});return er("button",t,{ref:[n,ne,Z],state:ie,props:[L,oe,Y,{id:Ce,tabIndex:D?0:-1,role:D?"combobox":void 0,"aria-expanded":J?"true":"false","aria-haspopup":D?"dialog":"listbox","aria-controls":J?B?.id:void 0,"aria-required":D&&O||void 0,"aria-labelledby":b,onPointerDown:Ke,onPointerEnter:Ke,onFocus(){g(!0),!(Se||_)&&Ae.start(0,y.state.forceMount)},onBlur(U){if(!ft(k,U.relatedTarget)&&(p(!0),g(!1),h==="onBlur")){const fe=C==="none"?K:te;v.commit(fe)}},onMouseDown(U){if(Se||_||(D||pe.set("domReferenceElement",U.currentTarget),y.state.forceMount(),ze.current!=="touch"&&(y.state.inputRef.current?.focus(),D||U.preventDefault()),J))return;const fe=Xt(U.currentTarget);function me(de){if(!V)return;const ve=lr(de),le=y.state.positionerElement,be=y.state.listElement;if(ft(V,ve)||ft(le,ve)||ft(be,ve)||ve===V)return;const ke=lK(V),et=de.clientX>=ke.left-Yf&&de.clientX<=ke.right+Yf,Tt=de.clientY>=ke.top-Yf&&de.clientY<=ke.bottom+Yf;et&&Tt||y.state.setOpen(!1,Xe("cancel-open",de))}D&&fe.addEventListener("mouseup",me,{once:!0})},onKeyDown(U){Se||_||(U.key==="ArrowDown"||U.key==="ArrowUp")&&(jt(U),y.state.setOpen(!0,Xe(Ru,U.nativeEvent)),y.state.inputRef.current?.focus())}},v?v.getValidationProps(u):u,$],stateAttributesMapping:bT})});process.env.NODE_ENV!=="production"&&(xT.displayName="ComboboxTrigger");const I0=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(I0.displayName="ComboboxChipsContext");function wT(){return x.useContext(I0)}const T0=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(T0.displayName="ComboboxPositionerContext");function k0(e){const t=x.useContext(T0);if(t===void 0&&!e)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: <Combobox.Popup> and <Combobox.Arrow> must be used within the <Combobox.Positioner> component":pi(21));return t}const N0=x.forwardRef(function(t,n){const{render:r,className:i,disabled:o=!1,id:a,...s}=t,{state:u,disabled:c,setTouched:d,setFocused:p,validationMode:g,validation:h}=oc(),{labelId:v}=R0(),b=wT(),w=!!k0(!0),C=Nr(),{filteredItems:E}=da(),_=P0(),O=rI(),R=he(C,ge.required),I=he(C,ge.disabled),k=he(C,ge.readOnly),B=he(C,ge.name),L=he(C,ge.selectionMode),V=he(C,ge.autoHighlight),D=he(C,ge.inputProps),H=he(C,ge.triggerProps),J=he(C,ge.open),te=he(C,ge.mounted),G=he(C,ge.selectedValue),ee=he(C,ge.popupSide),Q=he(C,ge.positionerElement),pe=he(C,ge.id),K=he(C,ge.inline),Ae=!!V,Se=te&&Q?ee:null,$e=c||I||o,we=E.length===0,ze=s0(a??(w||K?void 0:pe)),[Ke,Fe]=x.useState(null),Y=x.useRef(!1),oe=x.useRef(null),ne=x.useRef(!1),$=Me(U=>{const fe=w||C.state.inline;fe&&!C.state.hasInputValue&&C.state.setInputValue("",Xe(Yr)),C.update({inputElement:U,inputInsidePopup:fe})}),ie={...u,open:J,disabled:$e,readOnly:k,popupSide:Se,listEmpty:we};function Z(U){if(!b)return;let fe;const{highlightedChipIndex:me}=b;if(me!==void 0){if(U.key==="ArrowLeft")U.preventDefault(),me>0?fe=me-1:fe=void 0;else if(U.key==="ArrowRight")U.preventDefault(),me<G.length-1?fe=me+1:fe=void 0;else if(U.key==="Backspace"||U.key==="Delete"){U.preventDefault();const de=me>=G.length-1?G.length-2:me;fe=de>=0?de:void 0,C.state.setIndices({activeIndex:null,selectedIndex:null,type:"keyboard"})}return fe}return U.key==="ArrowLeft"&&(U.currentTarget.selectionStart??0)===0&&G.length>0?(U.preventDefault(),fe=Math.max(G.length-1,0)):U.key==="Backspace"&&U.currentTarget.value===""&&G.length>0&&(C.state.setIndices({activeIndex:null,selectedIndex:null,type:"keyboard"}),U.preventDefault()),fe}return er("input",t,{state:ie,ref:[n,C.state.inputRef,$],props:[D,H,{type:"text",value:t.value??Ke??_,"aria-readonly":k||void 0,"aria-required":R||void 0,"aria-labelledby":v,disabled:$e,readOnly:k,required:L==="none"?R:void 0,...L==="none"&&B&&{name:B},id:ze,onFocus(){if(p(!0),!K||!ne.current)return;ne.current=!1;const U=oe.current;U==null||!Object.hasOwn(C.state.valuesRef.current,U)||C.state.setIndices({activeIndex:U})},onBlur(){d(!0),p(!1);const U=C.state.activeIndex;if(K&&U!==null&&V!=="always"&&(oe.current=U,ne.current=!0,C.state.setIndices({activeIndex:null})),g==="onBlur"){const fe=L==="none"?_:G;h.commit(fe)}},onCompositionStart(U){Md||(Y.current=!0,Fe(U.currentTarget.value))},onCompositionEnd(U){Y.current=!1;const fe=U.currentTarget.value;Fe(null),C.state.setInputValue(fe,Xe(Js,U.nativeEvent))},onChange(U){const fe=U.nativeEvent.inputType,me=!fe||fe==="insertReplacementText",de=Y.current||!me;if(Y.current){const ke=U.currentTarget.value;Fe(ke),ke===""&&!C.state.openOnInputClick&&!C.state.inputInsidePopup&&C.state.setOpen(!1,Xe(Uo,U.nativeEvent));const et=ke.trim(),Tt=Ae&&et!=="";!k&&!$e&&et&&de&&(C.state.setOpen(!0,Xe(Js,U.nativeEvent)),Ae||C.state.setIndices({activeIndex:null,selectedIndex:null,type:C.state.keyboardActiveRef.current?"keyboard":"pointer"})),J&&C.state.activeIndex!==null&&!Tt&&C.state.setIndices({activeIndex:null,selectedIndex:null,type:C.state.keyboardActiveRef.current?"keyboard":"pointer"});return}C.state.setInputValue(U.currentTarget.value,Xe(Js,U.nativeEvent));const ve=U.currentTarget.value==="",le=Xe(Uo,U.nativeEvent);ve&&!C.state.inputInsidePopup&&(L==="single"&&C.state.setSelectedValue(null,le),C.state.openOnInputClick||C.state.setOpen(!1,le));const be=U.currentTarget.value.trim();!k&&!$e&&be&&de&&(C.state.setOpen(!0,Xe(Js,U.nativeEvent)),Ae||C.state.setIndices({activeIndex:null,selectedIndex:null,type:C.state.keyboardActiveRef.current?"keyboard":"pointer"})),J&&C.state.activeIndex!==null&&!Ae&&C.state.setIndices({activeIndex:null,selectedIndex:null,type:C.state.keyboardActiveRef.current?"keyboard":"pointer"})},onKeyDown(U){if($e||k||U.ctrlKey||U.shiftKey||U.altKey||U.metaKey)return;C.state.keyboardActiveRef.current=!0;const fe=U.currentTarget,me=fe.scrollWidth-fe.clientWidth,de=O==="rtl";if(U.key==="Home"){jt(U);const be=OS&&de?fe.value.length:0;fe.setSelectionRange(be,be),fe.scrollLeft=0;return}if(U.key==="End"){jt(U);const be=OS&&de?0:fe.value.length;fe.setSelectionRange(be,be),fe.scrollLeft=de?-me:me;return}if(!te&&U.key==="Escape"){const be=L==="multiple"&&Array.isArray(G)?G.length===0:G===null,ke=Xe(uI,U.nativeEvent),et=L==="multiple"?[]:null;C.state.setInputValue("",ke),C.state.setSelectedValue(et,ke),!be&&!C.state.inline&&!ke.isPropagationAllowed&&U.stopPropagation();return}if(b&&U.key==="Backspace"&&fe.value===""&&b.highlightedChipIndex===void 0&&Array.isArray(G)&&G.length>0){const be=G.slice(0,-1);C.state.setIndices({activeIndex:null,selectedIndex:null,type:C.state.keyboardActiveRef.current?"keyboard":"pointer"}),C.state.setSelectedValue(be,Xe(Yr,U.nativeEvent));return}const ve=b?.highlightedChipIndex!==void 0,le=Z(U);if(b?.setHighlightedChipIndex(le),le!==void 0?b?.chipsRef.current[le]?.focus():ve&&C.state.inputRef.current?.focus(),U.which!==229&&U.key==="Enter"&&J){const be=C.state.activeIndex,ke=U.nativeEvent;if(be===null){C.state.setOpen(!1,Xe(Yr,ke));return}jt(U);const et=C.state.listRef.current[be];et&&(C.state.selectionEventRef.current=ke,et.click(),C.state.selectionEventRef.current=null)}},onPointerMove(){C.state.keyboardActiveRef.current=!1},onPointerDown(){C.state.keyboardActiveRef.current=!1}},h?h.getValidationProps(s):s],stateAttributesMapping:bT})});process.env.NODE_ENV!=="production"&&(N0.displayName="ComboboxInput");const uK={...fI,...H6},CT=x.forwardRef(function(t,n){const{render:r,className:i,disabled:o=!1,nativeButton:a=!0,keepMounted:s=!1,...u}=t,{disabled:c}=oc(),d=Nr(),p=he(d,ge.selectionMode),g=he(d,ge.disabled),h=he(d,ge.readOnly),v=he(d,ge.open),b=he(d,ge.selectedValue),y=he(d,ge.hasSelectionChips),w=P0();let C=!1;p==="none"?C=w!=="":p==="single"?C=b!=null:C=y;const E=c||g||o,{buttonRef:_,getButtonProps:O}=Jp({native:a,disabled:E}),{mounted:R,transitionStatus:I,setMounted:k}=dI(C),B={disabled:E,open:v,transitionStatus:I};m0({open:C,ref:d.state.clearRef,onComplete(){C||k(!1)}});const L=er("button",t,{state:B,ref:[n,_,d.state.clearRef],props:[{tabIndex:-1,children:"x",onMouseDown(D){D.preventDefault()},onClick(D){if(E||h)return;const H=d.state.keyboardActiveRef;d.state.setInputValue("",Xe(wS,D.nativeEvent)),p!=="none"?(d.state.setSelectedValue(Array.isArray(b)?[]:null,Xe(wS,D.nativeEvent)),d.state.setIndices({activeIndex:null,selectedIndex:null,type:H.current?"keyboard":"pointer"})):d.state.setIndices({activeIndex:null,type:H.current?"keyboard":"pointer"}),d.state.inputRef.current?.focus()}},u,O],stateAttributesMapping:uK});return s||R?L:null});process.env.NODE_ENV!=="production"&&(CT.displayName="ComboboxClear");const M0=x.createContext(null);process.env.NODE_ENV!=="production"&&(M0.displayName="GroupCollectionContext");function cK(){return x.useContext(M0)}function fK(e){const{children:t,items:n}=e,r=x.useMemo(()=>({items:n}),[n]);return P.jsx(M0.Provider,{value:r,children:t})}function ST(e){const{children:t}=e,{filteredItems:n}=da(),r=cK(),i=r?r.items:n;return i?P.jsx(x.Fragment,{children:i.map(t)}):null}const ET=x.forwardRef(function(t,n){var r;const{render:i,className:o,children:a,...s}=t,u=Nr(),c=ah(),d=!!k0(!0),{filteredItems:p}=da(),g=he(u,ge.items),h=he(u,ge.labelsRef),v=he(u,ge.listRef),b=he(u,ge.selectionMode),y=he(u,ge.grid),w=he(u,ge.popupProps),C=he(u,ge.disabled),E=he(u,ge.readOnly),_=he(u,ge.virtualized),O=b==="multiple",R=p.length===0,I=Me(H=>{u.set("positionerElement",H)}),k=Me(H=>{u.set("listElement",H)}),B=x.useMemo(()=>typeof a=="function"?r||(r=P.jsx(ST,{children:a})):a,[a]),L={empty:R},V=c.useState("floatingId"),D=er("div",t,{state:L,ref:[n,k,d?null:I],props:[w,{children:B,tabIndex:-1,id:V,role:y?"grid":"listbox","aria-multiselectable":O?"true":void 0,onKeyDown(H){if(!(C||E)&&H.key==="Enter"){const J=u.state.activeIndex;if(J==null)return;jt(H);const te=H.nativeEvent,G=u.state.listRef.current[J];G&&(u.state.selectionEventRef.current=te,G.click(),u.state.selectionEventRef.current=null)}},onKeyDownCapture(){u.state.keyboardActiveRef.current=!0},onPointerMoveCapture(){u.state.keyboardActiveRef.current=!1}},s]});return _?D:P.jsx(tI,{elementsRef:v,labelsRef:g?void 0:h,children:D})});process.env.NODE_ENV!=="production"&&(ET.displayName="ComboboxList");const D0=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(D0.displayName="ComboboxPortalContext");function dK(){const e=x.useContext(D0);if(e===void 0)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: <Combobox.Portal> is missing.":pi(20));return e}const _T=x.forwardRef(function(t,n){const{keepMounted:r=!1,...i}=t,o=Nr(),a=he(o,ge.mounted),s=he(o,ge.forceMounted);return a||r||s?P.jsx(D0.Provider,{value:r,children:P.jsx(BI,{ref:n,...i})}):null});process.env.NODE_ENV!=="production"&&(_T.displayName="ComboboxPortal");const pK=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:o,platform:a,elements:s,middlewareData:u}=t,{element:c,padding:d=0,offsetParent:p="real"}=Ni(e,t)||{};if(c==null)return{};const g=g0(d),h={x:n,y:r},v=th(i),b=eh(v),y=await a.getDimensions(c),w=v==="y",C=w?"top":"left",E=w?"bottom":"right",_=w?"clientHeight":"clientWidth",O=o.reference[b]+o.reference[v]-h[v]-o.floating[b],R=h[v]-o.reference[v],I=p==="real"?await a.getOffsetParent?.(c):s.floating;let k=s.floating[_]||o.floating[b];(!k||!await a.isElement?.(I))&&(k=s.floating[_]||o.floating[b]);const B=O/2-R/2,L=k/2-y[b]/2-1,V=Math.min(g[C],L),D=Math.min(g[E],L),H=V,J=k-y[b]-D,te=k/2-y[b]/2+B,G=jd(H,te,J),ee=!u.arrow&&bo(i)!=null&&te!==G&&o.reference[b]/2-(te<H?V:D)-y[b]/2<0,Q=ee?te<H?te-H:te-J:0;return{[v]:h[v]+Q,data:{[v]:G,centerOffset:te-G-Q,...ee&&{alignmentOffset:Q}},reset:ee}}}),hK=(e,t)=>({...pK(e),options:[e,t]}),gK={name:"hide",async fn(e){const{width:t,height:n,x:r,y:i}=e.rects.reference,o=t===0&&n===0&&r===0&&i===0;return{data:{referenceHidden:(await rT().fn(e)).data?.referenceHidden||o}}}},mK={sideX:"left",sideY:"top"};function OT(e,t,n){const r=e==="inline-start"||e==="inline-end";return{top:"top",right:r?n?"inline-start":"inline-end":"right",bottom:"bottom",left:r?n?"inline-end":"inline-start":"left"}[t]}function sE(e,t,n){const{rects:r,placement:i}=e;return{side:OT(t,Ar(i),n),align:bo(i)||"center",anchor:{width:r.reference.width,height:r.reference.height},positioner:{width:r.floating.width,height:r.floating.height}}}function vK(e){const{anchor:t,positionMethod:n="absolute",side:r="bottom",sideOffset:i=0,align:o="center",alignOffset:a=0,collisionBoundary:s,collisionPadding:u=5,sticky:c=!1,arrowPadding:d=5,disableAnchorTracking:p=!1,keepMounted:g=!1,floatingRootContext:h,mounted:v,collisionAvoidance:b,shiftCrossAxis:y=!1,nodeId:w,adaptiveOrigin:C,lazyFlip:E=!1,externalTree:_}=e,[O,R]=x.useState(null);!v&&O!==null&&R(null);const I=b.side||"flip",k=b.align||"flip",B=b.fallbackAxisSide||"end",L=typeof t=="function"?t:void 0,V=Me(L),D=L?V:t,H=Xr(t),te=rI()==="rtl",G=O||{top:"top",right:"right",bottom:"bottom",left:"left","inline-end":te?"left":"right","inline-start":te?"right":"left"}[r],ee=o==="center"?G:`${G}-${o}`;let Q=u;const pe=1,K=r==="bottom"?pe:0,Ae=r==="top"?pe:0,Se=r==="right"?pe:0,$e=r==="left"?pe:0;typeof Q=="number"?Q={top:Q+K,right:Q+$e,bottom:Q+Ae,left:Q+Se}:Q&&(Q={top:(Q.top||0)+K,right:(Q.right||0)+$e,bottom:(Q.bottom||0)+Ae,left:(Q.left||0)+Se});const we={boundary:s==="clipping-ancestors"?"clippingAncestors":s,padding:Q},Ce=x.useRef(null),ze=Xr(i),Ke=Xr(a),oe=[QI(pt=>{const ht=sE(pt,r,te),Ve=typeof ze.current=="function"?ze.current(ht):ze.current,jn=typeof Ke.current=="function"?Ke.current(ht):Ke.current;return{mainAxis:Ve,crossAxis:jn,alignmentAxis:jn}},[typeof i!="function"?i:0,typeof a!="function"?a:0,te,r])],ne=k==="none"&&I!=="shift",$=!ne&&(c||y||I==="shift"),ie=I==="none"?null:tT({...we,padding:{top:Q.top+pe,right:Q.right+pe,bottom:Q.bottom+pe,left:Q.left+pe},mainAxis:!y&&I==="flip",crossAxis:k==="flip"?"alignment":!1,fallbackAxisSideDirection:B}),Z=ne?null:JI(pt=>{const ht=Xt(pt.elements.floating).documentElement;return{...we,rootBoundary:y?{x:0,y:0,width:ht.clientWidth,height:ht.clientHeight}:void 0,mainAxis:k!=="none",crossAxis:$,limiter:c||y?void 0:eT(Ve=>{if(!Ce.current)return{};const{width:jn,height:On}=Ce.current.getBoundingClientRect(),mi=Zr(Ar(Ve.placement)),Jt=mi==="y"?jn:On,ma=mi==="y"?Q.left+Q.right:Q.top+Q.bottom;return{offset:Jt/2+ma/2}})}},[we,c,y,Q,k]);I==="shift"||k==="shift"||o==="center"?oe.push(Z,ie):oe.push(ie,Z),oe.push(nT({...we,apply({elements:{floating:pt},rects:{reference:ht},availableWidth:Ve,availableHeight:jn}){const On=pt.style;On.setProperty("--available-width",`${Ve}px`),On.setProperty("--available-height",`${jn}px`),On.setProperty("--anchor-width",`${ht.width}px`),On.setProperty("--anchor-height",`${ht.height}px`)}}),hK(()=>({element:Ce.current||document.createElement("div"),padding:d,offsetParent:"floating"}),[d]),{name:"transformOrigin",fn(pt){const{elements:ht,middlewareData:Ve,placement:jn,rects:On,y:mi}=pt,Jt=Ar(jn),ma=Zr(Jt),$t=Ce.current,Dl=Ve.arrow?.x||0,nr=Ve.arrow?.y||0,yn=$t?.clientWidth||0,va=$t?.clientHeight||0,Ao=Dl+yn/2,Dr=nr+va/2,vs=Math.abs(Ve.shift?.y||0),jr=On.reference.height/2,gr=typeof i=="function"?i(sE(pt,r,te)):i,Un=vs>gr,rt={top:`${Ao}px calc(100% + ${gr}px)`,bottom:`${Ao}px ${-gr}px`,left:`calc(100% + ${gr}px) ${Dr}px`,right:`${-gr}px ${Dr}px`}[Jt],vi=`${Ao}px ${On.reference.y+jr-mi}px`;return ht.floating.style.setProperty("--transform-origin",$&&ma==="y"&&Un?vi:rt),{}}},gK,C),je(()=>{!v&&h&&h.update({referenceElement:null,floatingElement:null,domReferenceElement:null})},[v,h]);const Re=x.useMemo(()=>({elementResize:!p&&typeof ResizeObserver<"u",layoutShift:!p&&typeof IntersectionObserver<"u"}),[p]),{refs:U,elements:fe,x:me,y:de,middlewareData:ve,update:le,placement:be,context:ke,isPositioned:et,floatingStyles:Tt}=I6({rootContext:h,placement:ee,middleware:oe,strategy:n,whileElementsMounted:g?void 0:(...pt)=>My(...pt,Re),nodeId:w,externalTree:_}),{sideX:Dn,sideY:Ct}=ve.adaptiveOrigin||mK,ot=et?n:"fixed",kt=x.useMemo(()=>{const pt=C?{position:ot,[Dn]:me,[Ct]:de}:{position:ot,...Tt};return et||(pt.opacity=0),pt},[C,ot,Dn,me,Ct,de,Tt,et]),mn=x.useRef(null);je(()=>{if(!v)return;const pt=H.current,ht=typeof pt=="function"?pt():pt,jn=(lE(ht)?ht.current:ht)||null||null;jn!==mn.current&&(U.setPositionReference(jn),mn.current=jn)},[v,U,D,H]),x.useEffect(()=>{if(!v)return;const pt=H.current;typeof pt!="function"&&lE(pt)&&pt.current!==mn.current&&(U.setPositionReference(pt.current),mn.current=pt.current)},[v,U,D,H]),x.useEffect(()=>{if(g&&v&&fe.domReference&&fe.floating)return My(fe.domReference,fe.floating,le,Re)},[g,v,fe,le,Re]);const on=Ar(be),_n=OT(r,on,te),Qt=bo(be)||"center",vn=!!ve.hide?.referenceHidden;je(()=>{E&&v&&et&&R(on)},[E,v,et,on]);const hr=x.useMemo(()=>({position:"absolute",top:ve.arrow?.y,left:ve.arrow?.x}),[ve.arrow]),Hn=ve.arrow?.centerOffset!==0;return x.useMemo(()=>({positionerStyles:kt,arrowStyles:hr,arrowRef:Ce,arrowUncentered:Hn,side:_n,align:Qt,physicalSide:on,anchorHidden:vn,refs:U,context:ke,isPositioned:et,update:le}),[kt,hr,Ce,Hn,_n,Qt,on,vn,U,ke,et,le])}function lE(e){return e!=null&&"current"in e}function PT(e){return e==="starting"?$G:Xn}const AT=x.forwardRef(function(t,n){const{render:r,className:i,anchor:o,positionMethod:a="absolute",side:s="bottom",align:u="center",sideOffset:c=0,alignOffset:d=0,collisionBoundary:p="clipping-ancestors",collisionPadding:g=5,arrowPadding:h=5,sticky:v=!1,disableAnchorTracking:b=!1,collisionAvoidance:y=VG,...w}=t,C=Nr(),{filteredItems:E}=da(),_=ah(),O=dK(),R=he(C,ge.modal),I=he(C,ge.open),k=he(C,ge.mounted),B=he(C,ge.openMethod),L=he(C,ge.triggerElement),V=he(C,ge.inputElement),D=he(C,ge.inputInsidePopup),H=he(C,ge.transitionStatus),J=E.length===0,G=vK({anchor:o??(D?L:V),floatingRootContext:_,positionMethod:a,mounted:k,side:s,sideOffset:c,align:u,alignOffset:d,arrowPadding:h,collisionBoundary:p,collisionPadding:g,sticky:v,disableAnchorTracking:b,keepMounted:O,collisionAvoidance:y,lazyFlip:!0});Q4(I&&R&&B!=="touch",L);const ee=x.useMemo(()=>{const Se={...G.positionerStyles};return I||(Se.pointerEvents="none"),{role:"presentation",hidden:!k,style:Se}},[I,k,G.positionerStyles]),Q={open:I,side:G.side,align:G.align,anchorHidden:G.anchorHidden,empty:J};je(()=>{C.set("popupSide",G.side)},[C,G.side]);const pe=x.useMemo(()=>({side:G.side,align:G.align,arrowRef:G.arrowRef,arrowUncentered:G.arrowUncentered,arrowStyles:G.arrowStyles,anchorHidden:G.anchorHidden,isPositioned:G.isPositioned}),[G.side,G.align,G.arrowRef,G.arrowUncentered,G.arrowStyles,G.anchorHidden,G.isPositioned]),K=Me(Se=>{C.set("positionerElement",Se)}),Ae=er("div",t,{state:Q,ref:[n,K],props:[ee,PT(H),w],stateAttributesMapping:uT});return P.jsxs(T0.Provider,{value:pe,children:[k&&R&&P.jsx(cT,{inert:G6(!I),cutout:V??L}),Ae]})});process.env.NODE_ENV!=="production"&&(AT.displayName="ComboboxPositioner");const yK={...uT,...fI},RT=x.forwardRef(function(t,n){const{render:r,className:i,initialFocus:o,finalFocus:a,...s}=t,u=Nr(),c=k0(),d=ah(),{filteredItems:p}=da(),g=he(u,ge.mounted),h=he(u,ge.open),v=he(u,ge.openMethod),b=he(u,ge.transitionStatus),y=he(u,ge.inputInsidePopup),w=he(u,ge.inputElement),C=p.length===0;m0({open:h,ref:u.state.popupRef,onComplete(){h&&u.state.onOpenChangeComplete(!0)}});const E={open:h,side:c.side,align:c.align,anchorHidden:c.anchorHidden,transitionStatus:b,empty:C},_=er("div",t,{state:E,ref:[n,u.state.popupRef],props:[{role:y?"dialog":"presentation",tabIndex:-1,onFocus(k){const B=lr(k.nativeEvent);v!=="touch"&&(ft(u.state.listElement,B)||B===k.currentTarget)&&u.state.inputRef.current?.focus()}},PT(b),s],stateAttributesMapping:yK}),R=o===void 0?y?k=>k==="touch"?u.state.popupRef.current:w:!1:o;let I;return a!=null?I=a:I=y?void 0:!1,P.jsx(fq,{context:d,disabled:!g,modal:!y,openInteractionType:v,initialFocus:R,returnFocus:I,children:_})});process.env.NODE_ENV!=="production"&&(RT.displayName="ComboboxPopup");const j0=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(j0.displayName="ComboboxGroupContext");function bK(){const e=x.useContext(j0);if(e===void 0)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: ComboboxGroupContext is missing. ComboboxGroup parts must be placed within <Combobox.Group>.":pi(18));return e}const IT=x.forwardRef(function(t,n){const{render:r,className:i,items:o,...a}=t,[s,u]=x.useState(),c=x.useMemo(()=>({labelId:s,setLabelId:u,items:o}),[s,u,o]),d=er("div",t,{ref:n,props:[{role:"group","aria-labelledby":s},a]}),p=P.jsx(j0.Provider,{value:c,children:d});return o?P.jsx(fK,{items:o,children:p}):p});process.env.NODE_ENV!=="production"&&(IT.displayName="ComboboxGroup");const TT=x.forwardRef(function(t,n){const{render:r,className:i,id:o,...a}=t,{setLabelId:s}=bK(),u=s0(o);return je(()=>(s(u),()=>{s(void 0)}),[u,s]),er("div",t,{ref:n,props:[{id:u},a]})});process.env.NODE_ENV!=="production"&&(TT.displayName="ComboboxGroupLabel");const kT=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(kT.displayName="ComboboxItemContext");const NT=x.createContext(!1);process.env.NODE_ENV!=="production"&&(NT.displayName="ComboboxRowContext");function xK(){return x.useContext(NT)}const MT=x.memo(x.forwardRef(function(t,n){const{render:r,className:i,value:o=null,index:a,disabled:s=!1,nativeButton:u=!1,...c}=t,d=x.useRef(!1),p=x.useRef(null),g=hI({index:a,textRef:p,indexGuessBehavior:pI.GuessFromOrder}),h=Nr(),v=xK(),{flatFilteredItems:b,hasItems:y}=da(),w=he(h,ge.open),C=he(h,ge.selectionMode),E=he(h,ge.readOnly),_=he(h,ge.virtualized),O=he(h,ge.isItemEqualToValue),R=C!=="none",I=a??(_?Gd(b,o,O):g.index),k=g.index!==-1,B=he(h,ge.id),L=he(h,ge.isActive,I),V=he(h,ge.isSelected,o),D=he(h,ge.getItemProps),H=x.useRef(null),J=B!=null&&k?`${B}-${I}`:void 0,te=V&&R;je(()=>{if(!(k&&(_||a!=null)))return;const Ce=h.state.listRef.current;return Ce[I]=H.current,()=>{delete Ce[I]}},[k,_,I,a,h]),je(()=>{if(!k||y)return;const we=h.state.valuesRef.current;return we[I]=o,C!=="none"&&h.state.allValuesRef.current.push(o),()=>{delete we[I]}},[k,y,I,o,h,C]),je(()=>{if(!w){d.current=!1;return}if(!k||y)return;const we=h.state.selectedValue,Ce=Array.isArray(we)?we[we.length-1]:we;Qa(o,Ce,O)&&h.set("selectedIndex",I)},[k,y,w,h,I,o,O]);const G={disabled:s,selected:te,highlighted:L},ee=D({active:L,selected:te});ee.id=void 0,ee.onFocus=void 0;const{getButtonProps:Q,buttonRef:pe}=Jp({disabled:s,focusableWhenDisabled:!0,native:u});function K(we){function Ce(){h.state.handleSelection(we,o)}h.state.submitOnItemClick?(la.flushSync(Ce),h.state.requestSubmit()):Ce()}const Ae={id:J,role:v?"gridcell":"option","aria-selected":R?te:void 0,tabIndex:void 0,onPointerDownCapture(we){d.current=!0,we.preventDefault()},onClick(we){s||E||K(we.nativeEvent)},onMouseUp(we){const Ce=d.current;d.current=!1,!(s||E||we.button!==0||Ce||!L)&&K(we.nativeEvent)}},Se=er("div",t,{ref:[pe,n,g.ref,H],state:G,props:[ee,Ae,c,Q]}),$e=x.useMemo(()=>({selected:te,textRef:p}),[te,p]);return P.jsx(kT.Provider,{value:$e,children:Se})}));process.env.NODE_ENV!=="production"&&(MT.displayName="ComboboxItem");const DT=x.forwardRef(function(t,n){const{render:r,className:i,children:o,...a}=t,{filteredItems:s}=da(),u=Nr(),c=s.length===0?o:null;return er("div",t,{ref:[n,u.state.emptyRef],props:[{children:c,role:"status","aria-live":"polite","aria-atomic":!0},a]})});process.env.NODE_ENV!=="production"&&(DT.displayName="ComboboxEmpty");const jT=x.forwardRef(function(t,n){const{className:r,render:i,orientation:o="horizontal",...a}=t;return er("div",t,{state:{orientation:o},ref:n,props:[{role:"separator","aria-orientation":o},a]})});process.env.NODE_ENV!=="production"&&(jT.displayName="Separator");function wK(e){const{multiple:t=!1,defaultValue:n,value:r,onValueChange:i,autoComplete:o,...a}=e;return P.jsx(sK,{...a,selectionMode:t?"multiple":"single",selectedValue:r,defaultSelectedValue:n,onSelectedValueChange:i,formAutoComplete:o})}function CK(e){const{children:t,placeholder:n}=e,r=Nr(),i=he(r,ge.itemToStringLabel),o=he(r,ge.selectedValue),a=he(r,ge.items),s=he(r,ge.selectionMode)==="multiple",u=he(r,ge.hasSelectedValue),c=!u&&n!=null&&t==null,d=he(r,ge.hasNullItemLabel,c);let p=null;return typeof t=="function"?p=t(o):t!=null?p=t:!u&&n!=null&&!d?p=n:s&&Array.isArray(o)?p=Q6(o,a,i):p=fT(o,a,i),P.jsx(x.Fragment,{children:p})}const LT=x.forwardRef(function(t,n){const{render:r,className:i,...o}=t,a=Nr(),s=he(a,ge.open),u=he(a,ge.hasSelectionChips),[c,d]=x.useState(void 0);s&&c!==void 0&&d(void 0);const p=x.useRef([]),g=er("div",t,{ref:[n,a.state.chipsContainerRef],props:[u?{role:"toolbar"}:Xn,o]}),h=x.useMemo(()=>({highlightedChipIndex:c,setHighlightedChipIndex:d,chipsRef:p}),[c,d,p]);return P.jsx(I0.Provider,{value:h,children:P.jsx(tI,{elementsRef:p,children:g})})});process.env.NODE_ENV!=="production"&&(LT.displayName="ComboboxChips");const L0=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(L0.displayName="ComboboxChipContext");function SK(){const e=x.useContext(L0);if(!e)throw new Error(process.env.NODE_ENV!=="production"?"useComboboxChipContext must be used within a ComboboxChip":pi(17));return e}const $T=x.forwardRef(function(t,n){const{render:r,className:i,...o}=t,a=Nr(),{setHighlightedChipIndex:s,chipsRef:u}=wT(),c=he(a,ge.disabled),d=he(a,ge.readOnly),p=he(a,ge.selectedValue),{ref:g,index:h}=hI();function v(C){let E=h;if(C.key==="ArrowLeft")C.preventDefault(),h>0?E=h-1:E=void 0;else if(C.key==="ArrowRight")C.preventDefault(),h<p.length-1?E=h+1:E=void 0;else if(C.key==="Backspace"||C.key==="Delete"){const _=h>=p.length-1?p.length-2:h;E=_>=0?_:void 0,jt(C),a.state.setIndices({activeIndex:null,selectedIndex:null,type:"keyboard"}),a.state.setSelectedValue(p.filter((O,R)=>R!==h),Xe(Yr,C.nativeEvent))}else C.key==="Enter"||C.key===" "?(jt(C),E=void 0):C.key==="ArrowDown"||C.key==="ArrowUp"?(jt(C),a.state.setOpen(!0,Xe(Ru,C.nativeEvent)),E=void 0):C.key.length===1&&!C.ctrlKey&&!C.metaKey&&!C.altKey&&(E=void 0);return E}const y=er("div",t,{ref:[n,g],state:{disabled:c},props:[{tabIndex:-1,"aria-disabled":c||void 0,"aria-readonly":d||void 0,onKeyDown(C){if(c||d)return;const E=v(C);la.flushSync(()=>{s(E)}),E===void 0?a.state.inputRef.current?.focus():u.current[E]?.focus()},onMouseDown(C){d||(C.preventDefault(),!c&&a.state.inputRef.current?.focus())}},o]}),w=x.useMemo(()=>({index:h}),[h]);return P.jsx(L0.Provider,{value:w,children:y})});process.env.NODE_ENV!=="production"&&($T.displayName="ComboboxChip");const FT=x.forwardRef(function(t,n){const{render:r,className:i,disabled:o=!1,nativeButton:a=!0,...s}=t,u=Nr(),{index:c}=SK(),d=he(u,ge.disabled),p=he(u,ge.readOnly),g=he(u,ge.selectedValue),h=he(u,ge.isItemEqualToValue),v=d||o,{buttonRef:b,getButtonProps:y}=Jp({native:a,disabled:v||p,focusableWhenDisabled:!0}),w={disabled:v};function C(O){const R=u.state.activeIndex;if(R==null)return;const I=Gd(u.state.valuesRef.current,O,h);I!==-1&&R===I&&u.state.setIndices({activeIndex:null,type:u.state.keyboardActiveRef.current?"keyboard":"pointer"})}function E(O){const R=Xe(KG,O.nativeEvent),I=g[c];return C(I),u.state.setSelectedValue(g.filter((k,B)=>B!==c),R),u.state.inputRef.current?.focus(),R}return er("button",t,{ref:[n,b],state:w,props:[{tabIndex:-1,onClick(O){if(v||p)return;E(O).isPropagationAllowed||O.stopPropagation()},onKeyDown(O){v||p||(O.key==="Enter"||O.key===" ")&&(E(O).isPropagationAllowed||jt(O))}},s,y]})});process.env.NODE_ENV!=="production"&&(FT.displayName="ComboboxChipRemove");var EK=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],sh=EK.reduce((e,t)=>{const n=MR(`Primitive.${t}`),r=x.forwardRef((i,o)=>{const{asChild:a,...s}=i,u=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),P.jsx(u,{...s,ref:o})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),_K="Label",VT=x.forwardRef((e,t)=>P.jsx(sh.label,{...e,ref:t,onMouseDown:n=>{n.target.closest("button, input, select, textarea")||(e.onMouseDown?.(n),!n.defaultPrevented&&n.detail>1&&n.preventDefault())}}));VT.displayName=_K;var BT=VT;const OK=xt(dn("body-sm-regular")),Vu=({className:e,ref:t,...n})=>P.jsx(BT,{ref:t,className:ue(OK(),e),...n});Vu.displayName=BT.displayName;var PK="Separator",uE="horizontal",AK=["horizontal","vertical"],zT=x.forwardRef((e,t)=>{const{decorative:n,orientation:r=uE,...i}=e,o=RK(r)?r:uE,s=n?{role:"none"}:{"aria-orientation":o==="vertical"?o:void 0,role:"separator"};return P.jsx(sh.div,{"data-orientation":o,...s,...i,ref:t})});zT.displayName=PK;function RK(e){return AK.includes(e)}var WT=zT;const $0=({className:e,orientation:t="horizontal",decorative:n=!0,ref:r,...i})=>P.jsx(WT,{ref:r,decorative:n,orientation:t,className:ue("bg-delicate-border shrink-0",t==="horizontal"?"h-px w-full":"h-full w-px",e),...i});$0.displayName=WT.displayName;const IK=xt("group/field data-[invalid=true]:text-error-text flex h-full w-full gap-2",{variants:{orientation:{vertical:["flex-col"],horizontal:["flex-row items-center","*:data-[slot=field-label]:flex-auto",`has-[>[data-slot=field-content]]:items-start
|
|
36
|
-
has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px`]}},defaultVariants:{orientation:"vertical"}}),
|
|
35
|
+
)`}return O.jsx("div",{ref:n,role:"presentation","data-base-ui-inert":"",...i,style:{position:"fixed",inset:0,userSelect:"none",WebkitUserSelect:"none",clipPath:o}})});process.env.NODE_ENV!=="production"&&(NT.displayName="InternalBackdrop");function J6(e){const t=x.useRef(!0);t.current&&(t.current=!1,e())}const Wx=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(Wx.displayName="ComboboxRootContext");const Hx=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(Hx.displayName="ComboboxFloatingContext");const Ux=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(Ux.displayName="ComboboxDerivedItemsContext");const Gx=x.createContext("");process.env.NODE_ENV!=="production"&&(Gx.displayName="ComboboxInputValueContext");function Mr(){const e=x.useContext(Wx);if(!e)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: ComboboxRootContext is missing. Combobox parts must be placed within <Combobox.Root>.":mi(22));return e}function gh(){const e=x.useContext(Hx);if(!e)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: ComboboxFloatingContext is missing. Combobox parts must be placed within <Combobox.Root>.":mi(23));return e}function ma(){const e=x.useContext(Ux);if(!e)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: ComboboxItemsContext is missing. Combobox parts must be placed within <Combobox.Root>.":mi(24));return e}function qx(){return x.useContext(Gx)}const e8=(e,t)=>Object.is(e,t);function is(e,t,n){return e==null||t==null?Object.is(e,t):n(e,t)}function t8(e,t,n){return!e||e.length===0?!1:e.some(r=>r===void 0?!1:is(t,r,n))}function Jd(e,t,n){return!e||e.length===0?-1:e.findIndex(r=>r===void 0?!1:is(r,t,n))}function n8(e,t,n){return e.filter(r=>!is(t,r,n))}function Qy(e){if(e==null)return"";if(typeof e=="string")return e;try{return JSON.stringify(e)}catch{return String(e)}}function Kx(e){return e!=null&&e.length>0&&typeof e[0]=="object"&&e[0]!=null&&"items"in e[0]}function r8(e){if(!Array.isArray(e))return e!=null&&!("null"in e);if(Kx(e)){for(const t of e)for(const n of t.items)if(n&&n.value==null&&n.label!=null)return!0;return!1}for(const t of e)if(t&&t.value==null&&t.label!=null)return!0;return!1}function lr(e,t){if(t&&e!=null)return t(e)??"";if(e&&typeof e=="object"){if("label"in e&&e.label!=null)return String(e.label);if("value"in e)return String(e.value)}return Qy(e)}function gu(e,t){return t&&e!=null?t(e)??"":e&&typeof e=="object"&&"value"in e&&"label"in e?Qy(e.value):Qy(e)}function MT(e,t,n){function r(){return lr(e,n)}if(n&&e!=null)return n(e);if(e&&typeof e=="object"&&"label"in e&&e.label!=null)return e.label;if(t&&!Array.isArray(t))return t[e]??r();if(Array.isArray(t)){const i=Kx(t)?t.flatMap(o=>o.items):t;if(e==null||typeof e!="object"){const o=i.find(a=>a.value===e);return o&&o.label!=null?o.label:r()}if("value"in e){const o=i.find(a=>a&&a.value===e.value);if(o&&o.label!=null)return o.label}}return r()}function i8(e,t,n){return e.reduce((r,i,o)=>(o>0&&r.push(", "),r.push(O.jsx(x.Fragment,{children:MT(i,t,n)},o)),r),[])}const ge={id:je(e=>e.id),query:je(e=>e.query),items:je(e=>e.items),selectedValue:je(e=>e.selectedValue),hasSelectionChips:je(e=>{const t=e.selectedValue;return Array.isArray(t)&&t.length>0}),hasSelectedValue:je(e=>{const{selectedValue:t,selectionMode:n}=e;return t==null?!1:n==="multiple"&&Array.isArray(t)?t.length>0:!0}),hasNullItemLabel:je((e,t)=>t?r8(e.items):!1),open:je(e=>e.open),mounted:je(e=>e.mounted),forceMounted:je(e=>e.forceMounted),inline:je(e=>e.inline),activeIndex:je(e=>e.activeIndex),selectedIndex:je(e=>e.selectedIndex),isActive:je((e,t)=>e.activeIndex===t),isSelected:je((e,t)=>{const n=e.isItemEqualToValue,r=e.selectedValue;return Array.isArray(r)?r.some(i=>is(t,i,n)):is(t,r,n)}),transitionStatus:je(e=>e.transitionStatus),popupProps:je(e=>e.popupProps),inputProps:je(e=>e.inputProps),triggerProps:je(e=>e.triggerProps),getItemProps:je(e=>e.getItemProps),positionerElement:je(e=>e.positionerElement),listElement:je(e=>e.listElement),triggerElement:je(e=>e.triggerElement),inputElement:je(e=>e.inputElement),popupSide:je(e=>e.popupSide),openMethod:je(e=>e.openMethod),inputInsidePopup:je(e=>e.inputInsidePopup),selectionMode:je(e=>e.selectionMode),listRef:je(e=>e.listRef),labelsRef:je(e=>e.labelsRef),popupRef:je(e=>e.popupRef),emptyRef:je(e=>e.emptyRef),inputRef:je(e=>e.inputRef),keyboardActiveRef:je(e=>e.keyboardActiveRef),chipsContainerRef:je(e=>e.chipsContainerRef),clearRef:je(e=>e.clearRef),valuesRef:je(e=>e.valuesRef),allValuesRef:je(e=>e.allValuesRef),name:je(e=>e.name),disabled:je(e=>e.disabled),readOnly:je(e=>e.readOnly),required:je(e=>e.required),grid:je(e=>e.grid),isGrouped:je(e=>e.isGrouped),virtualized:je(e=>e.virtualized),onOpenChangeComplete:je(e=>e.onOpenChangeComplete),openOnInputClick:je(e=>e.openOnInputClick),itemToStringLabel:je(e=>e.itemToStringLabel),isItemEqualToValue:je(e=>e.isItemEqualToValue),modal:je(e=>e.modal),autoHighlight:je(e=>e.autoHighlight),submitOnItemClick:je(e=>e.submitOnItemClick)};let _E=(function(e){return e.disabled="data-disabled",e.valid="data-valid",e.invalid="data-invalid",e.touched="data-touched",e.dirty="data-dirty",e.filled="data-filled",e.focused="data-focused",e})({});const o8={badInput:!1,customError:!1,patternMismatch:!1,rangeOverflow:!1,rangeUnderflow:!1,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valid:null,valueMissing:!1},a8={valid(e){return e===null?null:e?{[_E.valid]:""}:{[_E.invalid]:""}}},DT=x.createContext({invalid:void 0,name:void 0,validityData:{state:o8,errors:[],error:"",value:"",initialValue:null},setValidityData:Ht,disabled:void 0,touched:!1,setTouched:Ht,dirty:!1,setDirty:Ht,filled:!1,setFilled:Ht,focused:!1,setFocused:Ht,validate:()=>null,validationMode:"onSubmit",validationDebounceTime:0,shouldValidateOnChange:()=>!1,state:{disabled:!1,valid:null,touched:!1,dirty:!1,filled:!1,focused:!1},markedDirtyRef:{current:!1},validation:{getValidationProps:(e=Zn)=>e,getInputValidationProps:(e=Zn)=>e,inputRef:{current:null},commit:async()=>{}}});process.env.NODE_ENV!=="production"&&(DT.displayName="FieldRootContext");function pc(e=!0){const t=x.useContext(DT);if(t.setValidityData===Ht&&!e)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: FieldRootContext is missing. Field parts must be placed within <Field.Root>.":mi(28));return t}function s8(e,t){return{...e,state:{...e.state,valid:!t&&e.state.valid}}}const jT=x.createContext({formRef:{current:{fields:new Map}},errors:{},clearErrors:Ht,validationMode:"onSubmit",submitAttemptedRef:{current:!1}});process.env.NODE_ENV!=="production"&&(jT.displayName="FormContext");function LT(){return x.useContext(jT)}function l8(e){const{enabled:t=!0,value:n,id:r,name:i,controlRef:o,commit:a}=e,{formRef:s}=LT(),{invalid:u,markedDirtyRef:c,validityData:f,setValidityData:p}=pc(),g=Le(e.getValue);Ve(()=>{if(!t)return;let h=n;h===void 0&&(h=g()),f.initialValue===null&&h!==null&&p(v=>({...v,initialValue:h}))},[t,p,n,f.initialValue,g]),Ve(()=>{!t||!r||s.current.fields.set(r,{getValue:g,name:i,controlRef:o,validityData:s8(f,u),validate(h=!0){let v=n;v===void 0&&(v=g()),c.current=!0,h?Wi.flushSync(()=>a(v)):a(v)}})},[a,o,t,s,g,r,u,c,i,f,n]),Ve(()=>{const h=s.current.fields;return()=>{r&&h.delete(r)}},[s,r])}const $T=x.createContext({controlId:void 0,registerControlId:Ht,labelId:void 0,setLabelId:Ht,messageIds:[],setMessageIds:Ht,getDescriptionProps:e=>e});process.env.NODE_ENV!=="production"&&($T.displayName="LabelableContext");function Yx(){return x.useContext($T)}function FT(e={}){const{id:t,implicit:n=!1,controlRef:r}=e,{controlId:i,registerControlId:o}=Yx(),a=Px(t),s=n?i:void 0,u=ti(()=>Symbol("labelable-control")),c=x.useRef(!1),f=x.useRef(t!=null),p=Le(()=>{!c.current||o===Ht||(c.current=!1,o(u.current,void 0))});return Ve(()=>{if(o===Ht)return;let g;if(n){const h=r?.current;$t(h)&&h.closest("label")!=null?g=t??null:g=s??a}else if(t!=null)f.current=!0,g=t;else if(f.current)g=a;else{p();return}if(g===void 0){p();return}c.current=!0,o(u.current,g)},[t,r,s,o,n,a,u,p]),x.useEffect(()=>p,[p]),i??a}function u8(e,t){return(n,r)=>{if(n==null)return!1;const i=lr(n,t);return e.contains(i,r)}}function c8(e,t,n){return(r,i)=>{if(r==null)return!1;if(!i)return!0;const o=lr(r,t),a=n!=null?lr(n,t):"";return a&&e.contains(a,i)&&a.length===i.length?!0:e.contains(o,i)}}const OE=new Map;function VT(e){return Array.isArray(e)?e.map(t=>VT(t)).join(","):e==null?"":String(e)}function f8(e={}){const t={usage:"search",sensitivity:"base",ignorePunctuation:!0,...e},n=`${VT(e.locale)}|${JSON.stringify(t)}`,r=OE.get(n);if(r)return r;const i=new Intl.Collator(e.locale,t),o={contains(a,s,u){if(!s)return!0;const c=lr(a,u);for(let f=0;f<=c.length-s.length;f+=1)if(i.compare(c.slice(f,f+s.length),s)===0)return!0;return!1},startsWith(a,s,u){if(!s)return!0;const c=lr(a,u);return i.compare(c.slice(0,s.length),s)===0},endsWith(a,s,u){if(!s)return!0;const c=lr(a,u),f=s.length;return c.length>=f&&i.compare(c.slice(c.length-f),s)===0}};return OE.set(n,o),o}const d8=f8;function nd(e,t){const n=x.useRef(e),r=Le(t);Ve(()=>{n.current!==e&&r(n.current)},[e,r]),Ve(()=>{n.current=e},[e])}const BT=Symbol("none"),Fa={value:BT,index:-1};function p8(e){const{id:t,onOpenChangeComplete:n,defaultSelectedValue:r=null,selectedValue:i,onSelectedValueChange:o,defaultInputValue:a,inputValue:s,selectionMode:u="none",onItemHighlighted:c,name:f,disabled:p=!1,readOnly:g=!1,required:h=!1,inputRef:v,grid:b=!1,items:y,filteredItems:w,filter:S,openOnInputClick:E=!0,autoHighlight:_=!1,keepHighlight:P=!1,highlightItemOnHover:R=!0,loopFocus:I=!0,itemToStringLabel:k,itemToStringValue:B,isItemEqualToValue:L=e8,virtualized:V=!1,inline:D=!1,fillInputOnItemPress:W=!0,modal:J=!1,limit:re=-1,autoComplete:U="list",formAutoComplete:ee,locale:Z,submitOnItemClick:ue=!1}=e,{clearErrors:X}=LT(),{setDirty:Oe,validityData:Ee,shouldValidateOnChange:Me,setFilled:ye,name:be,disabled:$e,setTouched:me,setFocused:Se,validationMode:q,validation:te}=pc(),Y=FT({id:t}),j=d8({locale:Z}),[ie,Q]=x.useState(!1),[Ae,G]=x.useState(null),fe=x.useRef([]),ve=x.useRef([]),pe=x.useRef(null),xe=x.useRef(null),ce=x.useRef(null),Ce=x.useRef(!0),De=x.useRef(!1),nt=x.useRef(null),kt=x.useRef(null),Dn=x.useRef(null),Ct=x.useRef(Fa),lt=x.useRef(null),Nt=x.useRef([]),mn=x.useRef([]),on=$e||p,_n=be??f,Qt=u==="multiple",vn=u==="single",gr=s!==void 0||a!==void 0,Un=y!==void 0,gt=w!==void 0;let mt;_==="always"?mt="always":mt=_?"input-change":!1;const[ze,jn]=km({controlled:i,default:Qt?r??Hf:r,name:"Combobox",state:"selectedValue"}),On=x.useMemo(()=>S===null?()=>!0:S!==void 0?S:vn&&!ie?c8(j,k,ze):u8(j,k),[S,vn,ze,ie,j,k]),bi=ti(()=>gr?a??"":vn?lr(ze,k):"").current,[Jt,Sa]=km({controlled:s,default:bi,name:"Combobox",state:"inputValue"}),[Ft,Bl]=km({controlled:e.open,default:e.defaultOpen,name:"Combobox",state:"open"}),rr=Kx(y),yn=Ae??(Jt===""?"":String(Jt).trim()),Ca=vn?lr(ze,k):"",No=vn&&!ie&&yn!==""&&Ca!==""&&Ca.length===yn.length&&j.contains(Ca,yn),jr=No?"":yn,Cs=Un&>&&No,Lr=x.useMemo(()=>y?rr?y.flatMap(_e=>_e.items):y:Hf,[y,rr]),mr=x.useMemo(()=>{if(w&&!Cs)return w;if(!y)return Hf;if(rr){const Fe=y,Je=[];let zt=0;for(const en of Fe){if(re>-1&&zt>=re)break;const tn=jr===""?en.items:en.items.filter(Ds=>On(Ds,jr,k));if(tn.length===0)continue;const Si=re>-1?re-zt:1/0,Ui=tn.slice(0,Si);if(Ui.length>0){const Ds={...en,items:Ui};Je.push(Ds),zt+=Ui.length}}return Je}if(jr==="")return re>-1?Lr.slice(0,re):Lr;const _e=[];for(const Fe of Lr){if(re>-1&&_e.length>=re)break;On(Fe,jr,k)&&_e.push(Fe)}return _e},[w,Cs,y,rr,jr,re,On,k,Lr]),Gn=x.useMemo(()=>rr?mr.flatMap(Fe=>Fe.items):mr,[mr,rr]),ot=ti(()=>new IT({id:Y,selectedValue:ze,open:Ft,filter:On,query:yn,items:y,selectionMode:u,listRef:fe,labelsRef:ve,popupRef:pe,emptyRef:ce,inputRef:xe,keyboardActiveRef:Ce,chipsContainerRef:nt,clearRef:kt,valuesRef:Nt,allValuesRef:mn,selectionEventRef:Dn,name:_n,disabled:on,readOnly:g,required:h,grid:b,isGrouped:rr,virtualized:V,openOnInputClick:E,itemToStringLabel:k,isItemEqualToValue:L,modal:J,autoHighlight:mt,submitOnItemClick:ue,hasInputValue:gr,mounted:!1,forceMounted:!1,transitionStatus:"idle",inline:D,activeIndex:null,selectedIndex:null,popupProps:{},inputProps:{},triggerProps:{},positionerElement:null,listElement:null,triggerElement:null,inputElement:null,popupSide:null,openMethod:null,inputInsidePopup:!0,onOpenChangeComplete:n||Ht,setOpen:Ht,setInputValue:Ht,setSelectedValue:Ht,setIndices:Ht,onItemHighlighted:Ht,handleSelection:Ht,getItemProps:()=>Zn,forceMount:Ht,requestSubmit:Ht})).current,xi=u==="none"?Jt:ze,wg=x.useMemo(()=>u==="none"?xi:Array.isArray(ze)?ze.map(_e=>gu(_e,B)):gu(ze,B),[xi,B,u,ze]),zl=Le(c),Wl=Le(n),Es=he(ot,ge.activeIndex),Bc=he(ot,ge.selectedIndex),_s=he(ot,ge.positionerElement),zc=he(ot,ge.listElement),Ea=he(ot,ge.triggerElement),Hl=he(ot,ge.inputElement),vr=he(ot,ge.inline),wi=he(ot,ge.inputInsidePopup),Os=Zr(Ea),{mounted:Wc,setMounted:Ps,transitionStatus:Ul}=DI(Ft),{openMethod:Hc,triggerProps:Gl,reset:Uc}=H6(Ft);l8({id:Y,name:_n,commit:te.commit,value:xi,controlRef:wi?Os:xe,getValue:()=>wg});const _a=Le(()=>{y?ve.current=Gn.map(_e=>lr(_e,k)):ot.set("forceMounted",!0)}),Gc=x.useRef(ze);Ve(()=>{ze!==Gc.current&&_a()},[_a,ze]);const yr=Le(_e=>{ot.update(_e);const Fe=_e.type||"none";if(_e.activeIndex!==void 0)if(_e.activeIndex===null)Ct.current!==Fa&&(Ct.current=Fa,zl(void 0,pu(Fe,void 0,{index:-1})));else{const Je=Nt.current[_e.activeIndex];Ct.current={value:Je,index:_e.activeIndex},zl(Je,pu(Fe,void 0,{index:_e.activeIndex}))}}),$r=Le((_e,Fe)=>{if(De.current=Fe.reason===Xo,e.onInputValueChange?.(_e,Fe),!Fe.isCanceled){if(Fe.reason===ol){const Je=Fe.event,zt=Je.inputType;if(Je.type==="compositionend"||zt!=null&&zt!==""&&zt!=="insertReplacementText"){const tn=_e.trim()!=="";tn&&Q(!0),lt.current={hasQuery:tn},tn&&mt&&ot.state.activeIndex==null&&ot.set("activeIndex",0)}}Sa(_e)}}),Oa=Le((_e,Fe)=>{if(Ft!==_e&&(Fe.reason==="escape-key"&&Un&&Gn.length===0&&!ot.state.emptyRef.current&&Fe.allowPropagation(),e.onOpenChange?.(_e,Fe),!Fe.isCanceled&&(!_e&&ie&&(vn?(vr||G(yn),yn===""&&Q(!1)):Qt&&(vr||wi?yr({activeIndex:null}):G(yn),$r("",Ze(Xo,Fe.event)))),Bl(_e),!_e&&wi&&(Fe.reason===rh||Fe.reason===_x)&&(me(!0),Se(!1),q==="onBlur")))){const Je=u==="none"?Jt:ze;te.commit(Je)}}),As=Le((_e,Fe)=>{if(o?.(_e,Fe),Fe.isCanceled)return;jn(_e),(u==="none"&&pe.current&&W||vn&&!ot.state.inputInsidePopup)&&$r(lr(_e,k),Ze(Fe.reason,Fe.event)),vn&&_e!=null&&Fe.reason!==ol&&ie&&!vr&&G(yn)}),qc=Le((_e,Fe)=>{let Je=Fe;if(Je===void 0){if(Es===null)return;Je=Nt.current[Es]}const zt=ur(_e),en=Dn.current??_e;Dn.current=null;const tn=Ze(J4,en),Si=zt?.closest("a")?.getAttribute("href");if(Si){Si.startsWith("#")&&Oa(!1,tn);return}if(Qt){const Ui=Array.isArray(ze)?ze:[],Eg=t8(Ui,Je,ot.state.isItemEqualToValue)?n8(Ui,Je,ot.state.isItemEqualToValue):[...Ui,Je];if(As(Eg,tn),!(xe.current?xe.current.value.trim()!=="":!1))return;ot.state.inputInsidePopup?$r("",Ze(Xo,tn.event)):Oa(!1,tn)}else As(Je,tn),Oa(!1,tn)}),Rs=Le(()=>{if(!ot.state.submitOnItemClick)return;const _e=ot.state.inputElement?.form;_e&&typeof _e.requestSubmit=="function"&&_e.requestSubmit()}),Is=Le(()=>{if(Ps(!1),Wl?.(!1),Q(!1),Uc(),G(null),yr(u==="none"?{activeIndex:null,selectedIndex:null}:{activeIndex:null}),Qt&&xe.current&&xe.current.value!==""&&!De.current&&$r("",Ze(Xo)),vn)if(ot.state.inputInsidePopup)xe.current&&xe.current.value!==""&&$r("",Ze(Xo));else{const _e=lr(ze,k);xe.current&&xe.current.value!==_e&&$r(_e,Ze(_e===""?Xo:Xr))}}),ql=x.useMemo(()=>vr&&_s?{current:_s.closest('[role="dialog"]')}:pe,[vr,_s]);jx({enabled:!e.actionsRef,open:Ft,ref:ql,onComplete(){Ft||Is()}}),x.useImperativeHandle(e.actionsRef,()=>({unmount:Is}),[Is]),Ve(function(){if(Ft||u==="none")return;const Fe=y?Lr:mn.current;if(Qt){const Je=Array.isArray(ze)?ze:[],zt=Je[Je.length-1],en=Jd(Fe,zt,L);yr({selectedIndex:en===-1?null:en})}else{const Je=Jd(Fe,ze,L);yr({selectedIndex:Je===-1?null:Je})}},[Ft,ze,y,u,Lr,Qt,L,yr]),Ve(()=>{y&&(Nt.current=Gn,fe.current.length=Gn.length)},[y,Gn]),Ve(()=>{const _e=lt.current;if(_e&&(_e.hasQuery?mt&&ot.set("activeIndex",0):mt==="always"&&ot.set("activeIndex",0),lt.current=null),!Ft&&!vr)return;const Je=Un||gt?Gn:Nt.current,zt=ot.state.activeIndex;if(zt==null){if(mt==="always"&&Je.length>0){ot.set("activeIndex",0);return}Ct.current!==Fa&&(Ct.current=Fa,ot.state.onItemHighlighted(void 0,pu(Xr,void 0,{index:-1})));return}if(zt>=Je.length){Ct.current!==Fa&&(Ct.current=Fa,ot.state.onItemHighlighted(void 0,pu(Xr,void 0,{index:-1}))),ot.set("activeIndex",null);return}const en=Je[zt],tn=Ct.current.value,Si=tn!==BT&&is(en,tn,ot.state.isItemEqualToValue);(Ct.current.index!==zt||!Si)&&(Ct.current={value:en,index:zt},ot.state.onItemHighlighted(en,pu(Xr,void 0,{index:zt})))},[Es,mt,gt,Un,Gn,vr,Ft,ot]),Ve(()=>{if(u==="none"){ye(String(Jt)!=="");return}ye(Qt?Array.isArray(ze)&&ze.length>0:ze!=null)},[ye,u,Jt,ze,Qt]),x.useEffect(()=>{Un&&mt&&Gn.length===0&&yr({activeIndex:null})},[Un,mt,Gn.length,yr]),nd(yn,()=>{!Ft||yn===""||yn===String(bi)||Q(!0)}),nd(ze,()=>{if(u!=="none"&&(X(_n),Oe(ze!==Ee.initialValue),Me()?te.commit(ze):te.commit(ze,!0),vn&&!gr&&!wi)){const _e=lr(ze,k);Jt!==_e&&$r(_e,Ze(Xr))}}),nd(Jt,()=>{u==="none"&&(X(_n),Oe(Jt!==Ee.initialValue),Me()?te.commit(Jt):te.commit(Jt,!0))}),nd(y,()=>{if(!vn||gr||wi||ie)return;const _e=lr(ze,k);Jt!==_e&&$r(_e,Ze(Xr))});const Ts=TT({open:vr?!0:Ft,onOpenChange:Oa,elements:{reference:wi?Ea:Hl,floating:_s}});let ks,Mo;vr||(ks=b?"grid":"listbox",Mo=Ft?"true":"false");const Kc=x.useMemo(()=>{const _e=Hl?.tagName==="INPUT",Fe=_e||Ft,Je=_e?{autoComplete:"off",spellCheck:"false",autoCorrect:"off",autoCapitalize:"none"}:{};return Fe&&(Je.role="combobox",Je["aria-expanded"]=Mo,Je["aria-haspopup"]=ks,Je["aria-controls"]=Ft?zc?.id:void 0,Je["aria-autocomplete"]=U),{reference:Je,floating:{role:"presentation"}}},[Hl,Ft,Mo,ks,zc?.id,U]),Sg=fT(Ts,{enabled:!g&&!on&&E,event:"mousedown-only",toggle:!1,touchOpenDelay:wi?0:50,reason:tq}),Yc=r6(Ts,{enabled:!g&&!on&&!vr,outsidePressEvent:{mouse:"sloppy",touch:"intentional"},bubbles:vr?!0:void 0,outsidePress(_e){const Fe=ur(_e);return!pt(Ea,Fe)&&!pt(kt.current,Fe)&&!pt(nt.current,Fe)}}),Xc=B6(Ts,{enabled:!g&&!on,id:Y,listRef:fe,activeIndex:Es,selectedIndex:Bc,virtual:!0,loopFocus:I,allowEscape:I&&!mt,focusItemOnOpen:ie||u==="none"&&!mt?!1:"auto",focusItemOnHover:R,resetOnPointerLeave:!P,cols:b?2:1,orientation:b?"horizontal":void 0,disabledIndices:Hf,onNavigate(_e,Fe){!Fe&&!Ft||Ul==="ending"||yr(Fe?{activeIndex:_e,type:Ce.current?"keyboard":"pointer"}:{activeIndex:_e})}}),{getReferenceProps:Pa,getFloatingProps:Kl,getItemProps:Ns}=L6([Kc,Sg,Yc,Xc]);J6(()=>{ot.update({inline:D,popupProps:Kl(),inputProps:Pa(),triggerProps:Gl,getItemProps:Ns,setOpen:Oa,setInputValue:$r,setSelectedValue:As,setIndices:yr,onItemHighlighted:zl,handleSelection:qc,forceMount:_a,requestSubmit:Rs})}),Ve(()=>{ot.update({id:Y,selectedValue:ze,open:Ft,mounted:Wc,transitionStatus:Ul,items:y,inline:D,popupProps:Kl(),inputProps:Pa(),triggerProps:Gl,openMethod:Hc,getItemProps:Ns,selectionMode:u,name:_n,disabled:on,readOnly:g,required:h,grid:b,isGrouped:rr,virtualized:V,onOpenChangeComplete:Wl,openOnInputClick:E,itemToStringLabel:k,modal:J,autoHighlight:mt,isItemEqualToValue:L,submitOnItemClick:ue,hasInputValue:gr,requestSubmit:Rs})},[ot,Y,ze,Ft,Wc,Ul,y,Kl,Pa,Ns,Hc,Gl,u,_n,on,g,h,te,b,rr,V,Wl,E,k,J,L,ue,gr,D,Rs,mt]);const Yl=Uu(v,te.inputRef),Xl=x.useMemo(()=>({query:yn,hasItems:Un,filteredItems:mr,flatFilteredItems:Gn}),[yn,Un,mr,Gn]),Do=x.useMemo(()=>Array.isArray(xi)?"":gu(xi,B),[xi,B]),Zc=Qt&&Array.isArray(ze)&&ze.length>0,Ms=Qt||u==="none"?void 0:_n,Cg=x.useMemo(()=>!Qt||!Array.isArray(ze)||!_n?null:ze.map(_e=>{const Fe=gu(_e,B);return O.jsx("input",{type:"hidden",name:_n,value:Fe},Fe)}),[Qt,ze,_n,B]),Qc=O.jsxs(x.Fragment,{children:[e.children,O.jsx("input",{...te.getInputValidationProps({onFocus(){if(wi){Ea?.focus();return}(xe.current||Ea)?.focus()},onChange(_e){if(_e.nativeEvent.defaultPrevented)return;const Fe=_e.target.value,Je=Ze(Xr,_e.nativeEvent);function zt(){if(Qt)return;if(u==="none"){Oe(Fe!==Ee.initialValue),$r(Fe,Je),Me()&&te.commit(Fe);return}const en=Nt.current.find(tn=>gu(tn,B).toLowerCase()===Fe.toLowerCase());en!=null&&(Oe(en!==Ee.initialValue),As?.(en,Je),Me()&&te.commit(en))}y?zt():(_a(),queueMicrotask(zt))}}),id:Y&&Ms==null?`${Y}-hidden-input`:void 0,name:Ms,autoComplete:ee,disabled:on,required:h&&!Zc,readOnly:g,value:Do,ref:Yl,style:Ms?sK:Lx,tabIndex:-1,"aria-hidden":!0}),Cg]});return O.jsx(Wx.Provider,{value:ot,children:O.jsx(Hx.Provider,{value:Ts,children:O.jsx(Ux.Provider,{value:Xl,children:O.jsx(Gx.Provider,{value:Jt,children:Qc})})})})}const zT={...Z6,...a8,popupSide:e=>e?{"data-popup-side":e}:null,listEmpty:e=>e?{"data-list-empty":""}:null};function h8(e){const t=e.getBoundingClientRect();if(process.env.NODE_ENV!=="production")return t;const n=window.getComputedStyle(e,"::before"),r=window.getComputedStyle(e,"::after");if(!(n.content!=="none"||r.content!=="none"))return t;const o=parseFloat(n.width)||0,a=parseFloat(n.height)||0,s=parseFloat(r.width)||0,u=parseFloat(r.height)||0,c=Math.max(t.width,o,s),f=Math.max(t.height,a,u),p=c-t.width,g=f-t.height;return{left:t.left-p/2,right:t.right+p/2,top:t.top-g/2,bottom:t.bottom+g/2}}const rd=2,WT=x.forwardRef(function(t,n){const{render:r,className:i,nativeButton:o=!0,disabled:a=!1,id:s,...u}=t,{state:c,disabled:f,setTouched:p,setFocused:g,validationMode:h,validation:v}=pc(),{labelId:b}=Yx(),y=Mr(),{filteredItems:w}=ma(),S=he(y,ge.selectionMode),E=he(y,ge.disabled),_=he(y,ge.readOnly),P=he(y,ge.required),R=he(y,ge.mounted),I=he(y,ge.popupSide),k=he(y,ge.positionerElement),B=he(y,ge.listElement),L=he(y,ge.triggerProps),V=he(y,ge.triggerElement),D=he(y,ge.inputInsidePopup),W=he(y,ge.id),J=he(y,ge.open),re=he(y,ge.selectedValue),U=he(y,ge.activeIndex),ee=he(y,ge.selectedIndex),Z=he(y,ge.hasSelectedValue),ue=gh(),X=qx(),Oe=ns(),Ee=f||E||a,Me=w.length===0,ye=R&&k?I:null;FT({id:D?s:void 0});const be=D?s??W:s,$e=x.useRef("");function me(G){$e.current=G.pointerType}const Se=ue.useState("domReferenceElement");x.useEffect(()=>{D&&V&&V!==Se&&ue.set("domReferenceElement",V)},[V,Se,ue,D]);const{reference:q}=z6(ue,{enabled:!J&&!_&&!E&&S==="single",listRef:y.state.labelsRef,activeIndex:U,selectedIndex:ee,onMatch(G){const fe=y.state.valuesRef.current[G];fe!==void 0&&y.state.setSelectedValue(fe,Ze("none"))}}),{reference:te}=fT(ue,{enabled:!_&&!E,event:"mousedown"}),{buttonRef:Y,getButtonProps:j}=lh({native:o,disabled:Ee}),ie={...c,open:J,disabled:Ee,popupSide:ye,listEmpty:Me,placeholder:!Z},Q=Le(G=>{y.set("triggerElement",G)});return tr("button",t,{ref:[n,Y,Q],state:ie,props:[L,te,q,{id:be,tabIndex:D?0:-1,role:D?"combobox":void 0,"aria-expanded":J?"true":"false","aria-haspopup":D?"dialog":"listbox","aria-controls":J?B?.id:void 0,"aria-required":D&&P||void 0,"aria-labelledby":b,onPointerDown:me,onPointerEnter:me,onFocus(){g(!0),!(Ee||_)&&Oe.start(0,y.state.forceMount)},onBlur(G){if(!pt(k,G.relatedTarget)&&(p(!0),g(!1),h==="onBlur")){const fe=S==="none"?X:re;v.commit(fe)}},onMouseDown(G){if(Ee||_||(D||ue.set("domReferenceElement",G.currentTarget),y.state.forceMount(),$e.current!=="touch"&&(y.state.inputRef.current?.focus(),D||G.preventDefault()),J))return;const fe=Zt(G.currentTarget);function ve(pe){if(!V)return;const xe=ur(pe),ce=y.state.positionerElement,Ce=y.state.listElement;if(pt(V,xe)||pt(ce,xe)||pt(Ce,xe)||xe===V)return;const De=h8(V),nt=pe.clientX>=De.left-rd&&pe.clientX<=De.right+rd,kt=pe.clientY>=De.top-rd&&pe.clientY<=De.bottom+rd;nt&&kt||y.state.setOpen(!1,Ze("cancel-open",pe))}D&&fe.addEventListener("mouseup",ve,{once:!0})},onKeyDown(G){Ee||_||(G.key==="ArrowDown"||G.key==="ArrowUp")&&(Lt(G),y.state.setOpen(!0,Ze(ju,G.nativeEvent)),y.state.inputRef.current?.focus())}},v?v.getValidationProps(u):u,j],stateAttributesMapping:zT})});process.env.NODE_ENV!=="production"&&(WT.displayName="ComboboxTrigger");const Xx=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(Xx.displayName="ComboboxChipsContext");function HT(){return x.useContext(Xx)}const Zx=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(Zx.displayName="ComboboxPositionerContext");function Qx(e){const t=x.useContext(Zx);if(t===void 0&&!e)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: <Combobox.Popup> and <Combobox.Arrow> must be used within the <Combobox.Positioner> component":mi(21));return t}const Jx=x.forwardRef(function(t,n){const{render:r,className:i,disabled:o=!1,id:a,...s}=t,{state:u,disabled:c,setTouched:f,setFocused:p,validationMode:g,validation:h}=pc(),{labelId:v}=Yx(),b=HT(),w=!!Qx(!0),S=Mr(),{filteredItems:E}=ma(),_=qx(),P=OI(),R=he(S,ge.required),I=he(S,ge.disabled),k=he(S,ge.readOnly),B=he(S,ge.name),L=he(S,ge.selectionMode),V=he(S,ge.autoHighlight),D=he(S,ge.inputProps),W=he(S,ge.triggerProps),J=he(S,ge.open),re=he(S,ge.mounted),U=he(S,ge.selectedValue),ee=he(S,ge.popupSide),Z=he(S,ge.positionerElement),ue=he(S,ge.id),X=he(S,ge.inline),Oe=!!V,Ee=re&&Z?ee:null,Me=c||I||o,ye=E.length===0,$e=Px(a??(w||X?void 0:ue)),[me,Se]=x.useState(null),q=x.useRef(!1),te=x.useRef(null),Y=x.useRef(!1),j=Le(G=>{const fe=w||S.state.inline;fe&&!S.state.hasInputValue&&S.state.setInputValue("",Ze(Xr)),S.update({inputElement:G,inputInsidePopup:fe})}),ie={...u,open:J,disabled:Me,readOnly:k,popupSide:Ee,listEmpty:ye};function Q(G){if(!b)return;let fe;const{highlightedChipIndex:ve}=b;if(ve!==void 0){if(G.key==="ArrowLeft")G.preventDefault(),ve>0?fe=ve-1:fe=void 0;else if(G.key==="ArrowRight")G.preventDefault(),ve<U.length-1?fe=ve+1:fe=void 0;else if(G.key==="Backspace"||G.key==="Delete"){G.preventDefault();const pe=ve>=U.length-1?U.length-2:ve;fe=pe>=0?pe:void 0,S.state.setIndices({activeIndex:null,selectedIndex:null,type:"keyboard"})}return fe}return G.key==="ArrowLeft"&&(G.currentTarget.selectionStart??0)===0&&U.length>0?(G.preventDefault(),fe=Math.max(U.length-1,0)):G.key==="Backspace"&&G.currentTarget.value===""&&U.length>0&&(S.state.setIndices({activeIndex:null,selectedIndex:null,type:"keyboard"}),G.preventDefault()),fe}return tr("input",t,{state:ie,ref:[n,S.state.inputRef,j],props:[D,W,{type:"text",value:t.value??me??_,"aria-readonly":k||void 0,"aria-required":R||void 0,"aria-labelledby":v,disabled:Me,readOnly:k,required:L==="none"?R:void 0,...L==="none"&&B&&{name:B},id:$e,onFocus(){if(p(!0),!X||!Y.current)return;Y.current=!1;const G=te.current;G==null||!Object.hasOwn(S.state.valuesRef.current,G)||S.state.setIndices({activeIndex:G})},onBlur(){f(!0),p(!1);const G=S.state.activeIndex;if(X&&G!==null&&V!=="always"&&(te.current=G,Y.current=!0,S.state.setIndices({activeIndex:null})),g==="onBlur"){const fe=L==="none"?_:U;h.commit(fe)}},onCompositionStart(G){Bd||(q.current=!0,Se(G.currentTarget.value))},onCompositionEnd(G){q.current=!1;const fe=G.currentTarget.value;Se(null),S.state.setInputValue(fe,Ze(ol,G.nativeEvent))},onChange(G){const fe=G.nativeEvent.inputType,ve=!fe||fe==="insertReplacementText",pe=q.current||!ve;if(q.current){const De=G.currentTarget.value;Se(De),De===""&&!S.state.openOnInputClick&&!S.state.inputInsidePopup&&S.state.setOpen(!1,Ze(Xo,G.nativeEvent));const nt=De.trim(),kt=Oe&&nt!=="";!k&&!Me&&nt&&pe&&(S.state.setOpen(!0,Ze(ol,G.nativeEvent)),Oe||S.state.setIndices({activeIndex:null,selectedIndex:null,type:S.state.keyboardActiveRef.current?"keyboard":"pointer"})),J&&S.state.activeIndex!==null&&!kt&&S.state.setIndices({activeIndex:null,selectedIndex:null,type:S.state.keyboardActiveRef.current?"keyboard":"pointer"});return}S.state.setInputValue(G.currentTarget.value,Ze(ol,G.nativeEvent));const xe=G.currentTarget.value==="",ce=Ze(Xo,G.nativeEvent);xe&&!S.state.inputInsidePopup&&(L==="single"&&S.state.setSelectedValue(null,ce),S.state.openOnInputClick||S.state.setOpen(!1,ce));const Ce=G.currentTarget.value.trim();!k&&!Me&&Ce&&pe&&(S.state.setOpen(!0,Ze(ol,G.nativeEvent)),Oe||S.state.setIndices({activeIndex:null,selectedIndex:null,type:S.state.keyboardActiveRef.current?"keyboard":"pointer"})),J&&S.state.activeIndex!==null&&!Oe&&S.state.setIndices({activeIndex:null,selectedIndex:null,type:S.state.keyboardActiveRef.current?"keyboard":"pointer"})},onKeyDown(G){if(Me||k||G.ctrlKey||G.shiftKey||G.altKey||G.metaKey)return;S.state.keyboardActiveRef.current=!0;const fe=G.currentTarget,ve=fe.scrollWidth-fe.clientWidth,pe=P==="rtl";if(G.key==="Home"){Lt(G);const Ce=GC&&pe?fe.value.length:0;fe.setSelectionRange(Ce,Ce),fe.scrollLeft=0;return}if(G.key==="End"){Lt(G);const Ce=GC&&pe?0:fe.value.length;fe.setSelectionRange(Ce,Ce),fe.scrollLeft=pe?-ve:ve;return}if(!re&&G.key==="Escape"){const Ce=L==="multiple"&&Array.isArray(U)?U.length===0:U===null,De=Ze(kI,G.nativeEvent),nt=L==="multiple"?[]:null;S.state.setInputValue("",De),S.state.setSelectedValue(nt,De),!Ce&&!S.state.inline&&!De.isPropagationAllowed&&G.stopPropagation();return}if(b&&G.key==="Backspace"&&fe.value===""&&b.highlightedChipIndex===void 0&&Array.isArray(U)&&U.length>0){const Ce=U.slice(0,-1);S.state.setIndices({activeIndex:null,selectedIndex:null,type:S.state.keyboardActiveRef.current?"keyboard":"pointer"}),S.state.setSelectedValue(Ce,Ze(Xr,G.nativeEvent));return}const xe=b?.highlightedChipIndex!==void 0,ce=Q(G);if(b?.setHighlightedChipIndex(ce),ce!==void 0?b?.chipsRef.current[ce]?.focus():xe&&S.state.inputRef.current?.focus(),G.which!==229&&G.key==="Enter"&&J){const Ce=S.state.activeIndex,De=G.nativeEvent;if(Ce===null){S.state.setOpen(!1,Ze(Xr,De));return}Lt(G);const nt=S.state.listRef.current[Ce];nt&&(S.state.selectionEventRef.current=De,nt.click(),S.state.selectionEventRef.current=null)}},onPointerMove(){S.state.keyboardActiveRef.current=!1},onPointerDown(){S.state.keyboardActiveRef.current=!1}},h?h.getValidationProps(s):s],stateAttributesMapping:zT})});process.env.NODE_ENV!=="production"&&(Jx.displayName="ComboboxInput");const g8={...MI,...X6},UT=x.forwardRef(function(t,n){const{render:r,className:i,disabled:o=!1,nativeButton:a=!0,keepMounted:s=!1,...u}=t,{disabled:c}=pc(),f=Mr(),p=he(f,ge.selectionMode),g=he(f,ge.disabled),h=he(f,ge.readOnly),v=he(f,ge.open),b=he(f,ge.selectedValue),y=he(f,ge.hasSelectionChips),w=qx();let S=!1;p==="none"?S=w!=="":p==="single"?S=b!=null:S=y;const E=c||g||o,{buttonRef:_,getButtonProps:P}=lh({native:a,disabled:E}),{mounted:R,transitionStatus:I,setMounted:k}=DI(S),B={disabled:E,open:v,transitionStatus:I};jx({open:S,ref:f.state.clearRef,onComplete(){S||k(!1)}});const L=tr("button",t,{state:B,ref:[n,_,f.state.clearRef],props:[{tabIndex:-1,children:"x",onMouseDown(D){D.preventDefault()},onClick(D){if(E||h)return;const W=f.state.keyboardActiveRef;f.state.setInputValue("",Ze(BC,D.nativeEvent)),p!=="none"?(f.state.setSelectedValue(Array.isArray(b)?[]:null,Ze(BC,D.nativeEvent)),f.state.setIndices({activeIndex:null,selectedIndex:null,type:W.current?"keyboard":"pointer"})):f.state.setIndices({activeIndex:null,type:W.current?"keyboard":"pointer"}),f.state.inputRef.current?.focus()}},u,P],stateAttributesMapping:g8});return s||R?L:null});process.env.NODE_ENV!=="production"&&(UT.displayName="ComboboxClear");const e0=x.createContext(null);process.env.NODE_ENV!=="production"&&(e0.displayName="GroupCollectionContext");function m8(){return x.useContext(e0)}function v8(e){const{children:t,items:n}=e,r=x.useMemo(()=>({items:n}),[n]);return O.jsx(e0.Provider,{value:r,children:t})}function GT(e){const{children:t}=e,{filteredItems:n}=ma(),r=m8(),i=r?r.items:n;return i?O.jsx(x.Fragment,{children:i.map(t)}):null}const qT=x.forwardRef(function(t,n){var r;const{render:i,className:o,children:a,...s}=t,u=Mr(),c=gh(),f=!!Qx(!0),{filteredItems:p}=ma(),g=he(u,ge.items),h=he(u,ge.labelsRef),v=he(u,ge.listRef),b=he(u,ge.selectionMode),y=he(u,ge.grid),w=he(u,ge.popupProps),S=he(u,ge.disabled),E=he(u,ge.readOnly),_=he(u,ge.virtualized),P=b==="multiple",R=p.length===0,I=Le(W=>{u.set("positionerElement",W)}),k=Le(W=>{u.set("listElement",W)}),B=x.useMemo(()=>typeof a=="function"?r||(r=O.jsx(GT,{children:a})):a,[a]),L={empty:R},V=c.useState("floatingId"),D=tr("div",t,{state:L,ref:[n,k,f?null:I],props:[w,{children:B,tabIndex:-1,id:V,role:y?"grid":"listbox","aria-multiselectable":P?"true":void 0,onKeyDown(W){if(!(S||E)&&W.key==="Enter"){const J=u.state.activeIndex;if(J==null)return;Lt(W);const re=W.nativeEvent,U=u.state.listRef.current[J];U&&(u.state.selectionEventRef.current=re,U.click(),u.state.selectionEventRef.current=null)}},onKeyDownCapture(){u.state.keyboardActiveRef.current=!0},onPointerMoveCapture(){u.state.keyboardActiveRef.current=!1}},s]});return _?D:O.jsx(EI,{elementsRef:v,labelsRef:g?void 0:h,children:D})});process.env.NODE_ENV!=="production"&&(qT.displayName="ComboboxList");const t0=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(t0.displayName="ComboboxPortalContext");function y8(){const e=x.useContext(t0);if(e===void 0)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: <Combobox.Portal> is missing.":mi(20));return e}const KT=x.forwardRef(function(t,n){const{keepMounted:r=!1,...i}=t,o=Mr(),a=he(o,ge.mounted),s=he(o,ge.forceMounted);return a||r||s?O.jsx(t0.Provider,{value:r,children:O.jsx(cT,{ref:n,...i})}):null});process.env.NODE_ENV!=="production"&&(KT.displayName="ComboboxPortal");const b8=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:o,platform:a,elements:s,middlewareData:u}=t,{element:c,padding:f=0,offsetParent:p="real"}=Li(e,t)||{};if(c==null)return{};const g=Dx(f),h={x:n,y:r},v=ch(i),b=uh(v),y=await a.getDimensions(c),w=v==="y",S=w?"top":"left",E=w?"bottom":"right",_=w?"clientHeight":"clientWidth",P=o.reference[b]+o.reference[v]-h[v]-o.floating[b],R=h[v]-o.reference[v],I=p==="real"?await a.getOffsetParent?.(c):s.floating;let k=s.floating[_]||o.floating[b];(!k||!await a.isElement?.(I))&&(k=s.floating[_]||o.floating[b]);const B=P/2-R/2,L=k/2-y[b]/2-1,V=Math.min(g[S],L),D=Math.min(g[E],L),W=V,J=k-y[b]-D,re=k/2-y[b]/2+B,U=Wd(W,re,J),ee=!u.arrow&&Eo(i)!=null&&re!==U&&o.reference[b]/2-(re<W?V:D)-y[b]/2<0,Z=ee?re<W?re-W:re-J:0;return{[v]:h[v]+Z,data:{[v]:U,centerOffset:re-U-Z,...ee&&{alignmentOffset:Z}},reset:ee}}}),x8=(e,t)=>({...b8(e),options:[e,t]}),w8={name:"hide",async fn(e){const{width:t,height:n,x:r,y:i}=e.rects.reference,o=t===0&&n===0&&r===0&&i===0;return{data:{referenceHidden:(await OT().fn(e)).data?.referenceHidden||o}}}},S8={sideX:"left",sideY:"top"};function YT(e,t,n){const r=e==="inline-start"||e==="inline-end";return{top:"top",right:r?n?"inline-start":"inline-end":"right",bottom:"bottom",left:r?n?"inline-end":"inline-start":"left"}[t]}function PE(e,t,n){const{rects:r,placement:i}=e;return{side:YT(t,Rr(i),n),align:Eo(i)||"center",anchor:{width:r.reference.width,height:r.reference.height},positioner:{width:r.floating.width,height:r.floating.height}}}function C8(e){const{anchor:t,positionMethod:n="absolute",side:r="bottom",sideOffset:i=0,align:o="center",alignOffset:a=0,collisionBoundary:s,collisionPadding:u=5,sticky:c=!1,arrowPadding:f=5,disableAnchorTracking:p=!1,keepMounted:g=!1,floatingRootContext:h,mounted:v,collisionAvoidance:b,shiftCrossAxis:y=!1,nodeId:w,adaptiveOrigin:S,lazyFlip:E=!1,externalTree:_}=e,[P,R]=x.useState(null);!v&&P!==null&&R(null);const I=b.side||"flip",k=b.align||"flip",B=b.fallbackAxisSide||"end",L=typeof t=="function"?t:void 0,V=Le(L),D=L?V:t,W=Zr(t),re=OI()==="rtl",U=P||{top:"top",right:"right",bottom:"bottom",left:"left","inline-end":re?"left":"right","inline-start":re?"right":"left"}[r],ee=o==="center"?U:`${U}-${o}`;let Z=u;const ue=1,X=r==="bottom"?ue:0,Oe=r==="top"?ue:0,Ee=r==="right"?ue:0,Me=r==="left"?ue:0;typeof Z=="number"?Z={top:Z+X,right:Z+Me,bottom:Z+Oe,left:Z+Ee}:Z&&(Z={top:(Z.top||0)+X,right:(Z.right||0)+Me,bottom:(Z.bottom||0)+Oe,left:(Z.left||0)+Ee});const ye={boundary:s==="clipping-ancestors"?"clippingAncestors":s,padding:Z},be=x.useRef(null),$e=Zr(i),me=Zr(a),te=[wT(gt=>{const mt=PE(gt,r,re),ze=typeof $e.current=="function"?$e.current(mt):$e.current,jn=typeof me.current=="function"?me.current(mt):me.current;return{mainAxis:ze,crossAxis:jn,alignmentAxis:jn}},[typeof i!="function"?i:0,typeof a!="function"?a:0,re,r])],Y=k==="none"&&I!=="shift",j=!Y&&(c||y||I==="shift"),ie=I==="none"?null:ET({...ye,padding:{top:Z.top+ue,right:Z.right+ue,bottom:Z.bottom+ue,left:Z.left+ue},mainAxis:!y&&I==="flip",crossAxis:k==="flip"?"alignment":!1,fallbackAxisSideDirection:B}),Q=Y?null:ST(gt=>{const mt=Zt(gt.elements.floating).documentElement;return{...ye,rootBoundary:y?{x:0,y:0,width:mt.clientWidth,height:mt.clientHeight}:void 0,mainAxis:k!=="none",crossAxis:j,limiter:c||y?void 0:CT(ze=>{if(!be.current)return{};const{width:jn,height:On}=be.current.getBoundingClientRect(),bi=Qr(Rr(ze.placement)),Jt=bi==="y"?jn:On,Sa=bi==="y"?Z.left+Z.right:Z.top+Z.bottom;return{offset:Jt/2+Sa/2}})}},[ye,c,y,Z,k]);I==="shift"||k==="shift"||o==="center"?te.push(Q,ie):te.push(ie,Q),te.push(_T({...ye,apply({elements:{floating:gt},rects:{reference:mt},availableWidth:ze,availableHeight:jn}){const On=gt.style;On.setProperty("--available-width",`${ze}px`),On.setProperty("--available-height",`${jn}px`),On.setProperty("--anchor-width",`${mt.width}px`),On.setProperty("--anchor-height",`${mt.height}px`)}}),x8(()=>({element:be.current||document.createElement("div"),padding:f,offsetParent:"floating"}),[f]),{name:"transformOrigin",fn(gt){const{elements:mt,middlewareData:ze,placement:jn,rects:On,y:bi}=gt,Jt=Rr(jn),Sa=Qr(Jt),Ft=be.current,Bl=ze.arrow?.x||0,rr=ze.arrow?.y||0,yn=Ft?.clientWidth||0,Ca=Ft?.clientHeight||0,No=Bl+yn/2,jr=rr+Ca/2,Cs=Math.abs(ze.shift?.y||0),Lr=On.reference.height/2,mr=typeof i=="function"?i(PE(gt,r,re)):i,Gn=Cs>mr,ot={top:`${No}px calc(100% + ${mr}px)`,bottom:`${No}px ${-mr}px`,left:`calc(100% + ${mr}px) ${jr}px`,right:`${-mr}px ${jr}px`}[Jt],xi=`${No}px ${On.reference.y+Lr-bi}px`;return mt.floating.style.setProperty("--transform-origin",j&&Sa==="y"&&Gn?xi:ot),{}}},w8,S),Ve(()=>{!v&&h&&h.update({referenceElement:null,floatingElement:null,domReferenceElement:null})},[v,h]);const Ae=x.useMemo(()=>({elementResize:!p&&typeof ResizeObserver<"u",layoutShift:!p&&typeof IntersectionObserver<"u"}),[p]),{refs:G,elements:fe,x:ve,y:pe,middlewareData:xe,update:ce,placement:Ce,context:De,isPositioned:nt,floatingStyles:kt}=j6({rootContext:h,placement:ee,middleware:te,strategy:n,whileElementsMounted:g?void 0:(...gt)=>Xy(...gt,Ae),nodeId:w,externalTree:_}),{sideX:Dn,sideY:Ct}=xe.adaptiveOrigin||S8,lt=nt?n:"fixed",Nt=x.useMemo(()=>{const gt=S?{position:lt,[Dn]:ve,[Ct]:pe}:{position:lt,...kt};return nt||(gt.opacity=0),gt},[S,lt,Dn,ve,Ct,pe,kt,nt]),mn=x.useRef(null);Ve(()=>{if(!v)return;const gt=W.current,mt=typeof gt=="function"?gt():gt,jn=(AE(mt)?mt.current:mt)||null||null;jn!==mn.current&&(G.setPositionReference(jn),mn.current=jn)},[v,G,D,W]),x.useEffect(()=>{if(!v)return;const gt=W.current;typeof gt!="function"&&AE(gt)&>.current!==mn.current&&(G.setPositionReference(gt.current),mn.current=gt.current)},[v,G,D,W]),x.useEffect(()=>{if(g&&v&&fe.domReference&&fe.floating)return Xy(fe.domReference,fe.floating,ce,Ae)},[g,v,fe,ce,Ae]);const on=Rr(Ce),_n=YT(r,on,re),Qt=Eo(Ce)||"center",vn=!!xe.hide?.referenceHidden;Ve(()=>{E&&v&&nt&&R(on)},[E,v,nt,on]);const gr=x.useMemo(()=>({position:"absolute",top:xe.arrow?.y,left:xe.arrow?.x}),[xe.arrow]),Un=xe.arrow?.centerOffset!==0;return x.useMemo(()=>({positionerStyles:Nt,arrowStyles:gr,arrowRef:be,arrowUncentered:Un,side:_n,align:Qt,physicalSide:on,anchorHidden:vn,refs:G,context:De,isPositioned:nt,update:ce}),[Nt,gr,be,Un,_n,Qt,on,vn,G,De,nt,ce])}function AE(e){return e!=null&&"current"in e}function XT(e){return e==="starting"?H4:Zn}const ZT=x.forwardRef(function(t,n){const{render:r,className:i,anchor:o,positionMethod:a="absolute",side:s="bottom",align:u="center",sideOffset:c=0,alignOffset:f=0,collisionBoundary:p="clipping-ancestors",collisionPadding:g=5,arrowPadding:h=5,sticky:v=!1,disableAnchorTracking:b=!1,collisionAvoidance:y=G4,...w}=t,S=Mr(),{filteredItems:E}=ma(),_=gh(),P=y8(),R=he(S,ge.modal),I=he(S,ge.open),k=he(S,ge.mounted),B=he(S,ge.openMethod),L=he(S,ge.triggerElement),V=he(S,ge.inputElement),D=he(S,ge.inputInsidePopup),W=he(S,ge.transitionStatus),J=E.length===0,U=C8({anchor:o??(D?L:V),floatingRootContext:_,positionMethod:a,mounted:k,side:s,sideOffset:c,align:u,alignOffset:f,arrowPadding:h,collisionBoundary:p,collisionPadding:g,sticky:v,disableAnchorTracking:b,keepMounted:P,collisionAvoidance:y,lazyFlip:!0});iK(I&&R&&B!=="touch",L);const ee=x.useMemo(()=>{const Ee={...U.positionerStyles};return I||(Ee.pointerEvents="none"),{role:"presentation",hidden:!k,style:Ee}},[I,k,U.positionerStyles]),Z={open:I,side:U.side,align:U.align,anchorHidden:U.anchorHidden,empty:J};Ve(()=>{S.set("popupSide",U.side)},[S,U.side]);const ue=x.useMemo(()=>({side:U.side,align:U.align,arrowRef:U.arrowRef,arrowUncentered:U.arrowUncentered,arrowStyles:U.arrowStyles,anchorHidden:U.anchorHidden,isPositioned:U.isPositioned}),[U.side,U.align,U.arrowRef,U.arrowUncentered,U.arrowStyles,U.anchorHidden,U.isPositioned]),X=Le(Ee=>{S.set("positionerElement",Ee)}),Oe=tr("div",t,{state:Z,ref:[n,X],props:[ee,XT(W),w],stateAttributesMapping:kT});return O.jsxs(Zx.Provider,{value:ue,children:[k&&R&&O.jsx(NT,{inert:Q6(!I),cutout:V??L}),Oe]})});process.env.NODE_ENV!=="production"&&(ZT.displayName="ComboboxPositioner");const E8={...kT,...MI},QT=x.forwardRef(function(t,n){const{render:r,className:i,initialFocus:o,finalFocus:a,...s}=t,u=Mr(),c=Qx(),f=gh(),{filteredItems:p}=ma(),g=he(u,ge.mounted),h=he(u,ge.open),v=he(u,ge.openMethod),b=he(u,ge.transitionStatus),y=he(u,ge.inputInsidePopup),w=he(u,ge.inputElement),S=p.length===0;jx({open:h,ref:u.state.popupRef,onComplete(){h&&u.state.onOpenChangeComplete(!0)}});const E={open:h,side:c.side,align:c.align,anchorHidden:c.anchorHidden,transitionStatus:b,empty:S},_=tr("div",t,{state:E,ref:[n,u.state.popupRef],props:[{role:y?"dialog":"presentation",tabIndex:-1,onFocus(k){const B=ur(k.nativeEvent);v!=="touch"&&(pt(u.state.listElement,B)||B===k.currentTarget)&&u.state.inputRef.current?.focus()}},XT(b),s],stateAttributesMapping:E8}),R=o===void 0?y?k=>k==="touch"?u.state.popupRef.current:w:!1:o;let I;return a!=null?I=a:I=y?void 0:!1,O.jsx(vK,{context:f,disabled:!g,modal:!y,openInteractionType:v,initialFocus:R,returnFocus:I,children:_})});process.env.NODE_ENV!=="production"&&(QT.displayName="ComboboxPopup");const n0=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(n0.displayName="ComboboxGroupContext");function _8(){const e=x.useContext(n0);if(e===void 0)throw new Error(process.env.NODE_ENV!=="production"?"Base UI: ComboboxGroupContext is missing. ComboboxGroup parts must be placed within <Combobox.Group>.":mi(18));return e}const JT=x.forwardRef(function(t,n){const{render:r,className:i,items:o,...a}=t,[s,u]=x.useState(),c=x.useMemo(()=>({labelId:s,setLabelId:u,items:o}),[s,u,o]),f=tr("div",t,{ref:n,props:[{role:"group","aria-labelledby":s},a]}),p=O.jsx(n0.Provider,{value:c,children:f});return o?O.jsx(v8,{items:o,children:p}):p});process.env.NODE_ENV!=="production"&&(JT.displayName="ComboboxGroup");const ek=x.forwardRef(function(t,n){const{render:r,className:i,id:o,...a}=t,{setLabelId:s}=_8(),u=Px(o);return Ve(()=>(s(u),()=>{s(void 0)}),[u,s]),tr("div",t,{ref:n,props:[{id:u},a]})});process.env.NODE_ENV!=="production"&&(ek.displayName="ComboboxGroupLabel");const tk=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(tk.displayName="ComboboxItemContext");const nk=x.createContext(!1);process.env.NODE_ENV!=="production"&&(nk.displayName="ComboboxRowContext");function O8(){return x.useContext(nk)}const rk=x.memo(x.forwardRef(function(t,n){const{render:r,className:i,value:o=null,index:a,disabled:s=!1,nativeButton:u=!1,...c}=t,f=x.useRef(!1),p=x.useRef(null),g=LI({index:a,textRef:p,indexGuessBehavior:jI.GuessFromOrder}),h=Mr(),v=O8(),{flatFilteredItems:b,hasItems:y}=ma(),w=he(h,ge.open),S=he(h,ge.selectionMode),E=he(h,ge.readOnly),_=he(h,ge.virtualized),P=he(h,ge.isItemEqualToValue),R=S!=="none",I=a??(_?Jd(b,o,P):g.index),k=g.index!==-1,B=he(h,ge.id),L=he(h,ge.isActive,I),V=he(h,ge.isSelected,o),D=he(h,ge.getItemProps),W=x.useRef(null),J=B!=null&&k?`${B}-${I}`:void 0,re=V&&R;Ve(()=>{if(!(k&&(_||a!=null)))return;const be=h.state.listRef.current;return be[I]=W.current,()=>{delete be[I]}},[k,_,I,a,h]),Ve(()=>{if(!k||y)return;const ye=h.state.valuesRef.current;return ye[I]=o,S!=="none"&&h.state.allValuesRef.current.push(o),()=>{delete ye[I]}},[k,y,I,o,h,S]),Ve(()=>{if(!w){f.current=!1;return}if(!k||y)return;const ye=h.state.selectedValue,be=Array.isArray(ye)?ye[ye.length-1]:ye;is(o,be,P)&&h.set("selectedIndex",I)},[k,y,w,h,I,o,P]);const U={disabled:s,selected:re,highlighted:L},ee=D({active:L,selected:re});ee.id=void 0,ee.onFocus=void 0;const{getButtonProps:Z,buttonRef:ue}=lh({disabled:s,focusableWhenDisabled:!0,native:u});function X(ye){function be(){h.state.handleSelection(ye,o)}h.state.submitOnItemClick?(Wi.flushSync(be),h.state.requestSubmit()):be()}const Oe={id:J,role:v?"gridcell":"option","aria-selected":R?re:void 0,tabIndex:void 0,onPointerDownCapture(ye){f.current=!0,ye.preventDefault()},onClick(ye){s||E||X(ye.nativeEvent)},onMouseUp(ye){const be=f.current;f.current=!1,!(s||E||ye.button!==0||be||!L)&&X(ye.nativeEvent)}},Ee=tr("div",t,{ref:[ue,n,g.ref,W],state:U,props:[ee,Oe,c,Z]}),Me=x.useMemo(()=>({selected:re,textRef:p}),[re,p]);return O.jsx(tk.Provider,{value:Me,children:Ee})}));process.env.NODE_ENV!=="production"&&(rk.displayName="ComboboxItem");const ik=x.forwardRef(function(t,n){const{render:r,className:i,children:o,...a}=t,{filteredItems:s}=ma(),u=Mr(),c=s.length===0?o:null;return tr("div",t,{ref:[n,u.state.emptyRef],props:[{children:c,role:"status","aria-live":"polite","aria-atomic":!0},a]})});process.env.NODE_ENV!=="production"&&(ik.displayName="ComboboxEmpty");const ok=x.forwardRef(function(t,n){const{className:r,render:i,orientation:o="horizontal",...a}=t;return tr("div",t,{state:{orientation:o},ref:n,props:[{role:"separator","aria-orientation":o},a]})});process.env.NODE_ENV!=="production"&&(ok.displayName="Separator");function P8(e){const{multiple:t=!1,defaultValue:n,value:r,onValueChange:i,autoComplete:o,...a}=e;return O.jsx(p8,{...a,selectionMode:t?"multiple":"single",selectedValue:r,defaultSelectedValue:n,onSelectedValueChange:i,formAutoComplete:o})}function A8(e){const{children:t,placeholder:n}=e,r=Mr(),i=he(r,ge.itemToStringLabel),o=he(r,ge.selectedValue),a=he(r,ge.items),s=he(r,ge.selectionMode)==="multiple",u=he(r,ge.hasSelectedValue),c=!u&&n!=null&&t==null,f=he(r,ge.hasNullItemLabel,c);let p=null;return typeof t=="function"?p=t(o):t!=null?p=t:!u&&n!=null&&!f?p=n:s&&Array.isArray(o)?p=i8(o,a,i):p=MT(o,a,i),O.jsx(x.Fragment,{children:p})}const ak=x.forwardRef(function(t,n){const{render:r,className:i,...o}=t,a=Mr(),s=he(a,ge.open),u=he(a,ge.hasSelectionChips),[c,f]=x.useState(void 0);s&&c!==void 0&&f(void 0);const p=x.useRef([]),g=tr("div",t,{ref:[n,a.state.chipsContainerRef],props:[u?{role:"toolbar"}:Zn,o]}),h=x.useMemo(()=>({highlightedChipIndex:c,setHighlightedChipIndex:f,chipsRef:p}),[c,f,p]);return O.jsx(Xx.Provider,{value:h,children:O.jsx(EI,{elementsRef:p,children:g})})});process.env.NODE_ENV!=="production"&&(ak.displayName="ComboboxChips");const r0=x.createContext(void 0);process.env.NODE_ENV!=="production"&&(r0.displayName="ComboboxChipContext");function R8(){const e=x.useContext(r0);if(!e)throw new Error(process.env.NODE_ENV!=="production"?"useComboboxChipContext must be used within a ComboboxChip":mi(17));return e}const sk=x.forwardRef(function(t,n){const{render:r,className:i,...o}=t,a=Mr(),{setHighlightedChipIndex:s,chipsRef:u}=HT(),c=he(a,ge.disabled),f=he(a,ge.readOnly),p=he(a,ge.selectedValue),{ref:g,index:h}=LI();function v(S){let E=h;if(S.key==="ArrowLeft")S.preventDefault(),h>0?E=h-1:E=void 0;else if(S.key==="ArrowRight")S.preventDefault(),h<p.length-1?E=h+1:E=void 0;else if(S.key==="Backspace"||S.key==="Delete"){const _=h>=p.length-1?p.length-2:h;E=_>=0?_:void 0,Lt(S),a.state.setIndices({activeIndex:null,selectedIndex:null,type:"keyboard"}),a.state.setSelectedValue(p.filter((P,R)=>R!==h),Ze(Xr,S.nativeEvent))}else S.key==="Enter"||S.key===" "?(Lt(S),E=void 0):S.key==="ArrowDown"||S.key==="ArrowUp"?(Lt(S),a.state.setOpen(!0,Ze(ju,S.nativeEvent)),E=void 0):S.key.length===1&&!S.ctrlKey&&!S.metaKey&&!S.altKey&&(E=void 0);return E}const y=tr("div",t,{ref:[n,g],state:{disabled:c},props:[{tabIndex:-1,"aria-disabled":c||void 0,"aria-readonly":f||void 0,onKeyDown(S){if(c||f)return;const E=v(S);Wi.flushSync(()=>{s(E)}),E===void 0?a.state.inputRef.current?.focus():u.current[E]?.focus()},onMouseDown(S){f||(S.preventDefault(),!c&&a.state.inputRef.current?.focus())}},o]}),w=x.useMemo(()=>({index:h}),[h]);return O.jsx(r0.Provider,{value:w,children:y})});process.env.NODE_ENV!=="production"&&(sk.displayName="ComboboxChip");const lk=x.forwardRef(function(t,n){const{render:r,className:i,disabled:o=!1,nativeButton:a=!0,...s}=t,u=Mr(),{index:c}=R8(),f=he(u,ge.disabled),p=he(u,ge.readOnly),g=he(u,ge.selectedValue),h=he(u,ge.isItemEqualToValue),v=f||o,{buttonRef:b,getButtonProps:y}=lh({native:a,disabled:v||p,focusableWhenDisabled:!0}),w={disabled:v};function S(P){const R=u.state.activeIndex;if(R==null)return;const I=Jd(u.state.valuesRef.current,P,h);I!==-1&&R===I&&u.state.setIndices({activeIndex:null,type:u.state.keyboardActiveRef.current?"keyboard":"pointer"})}function E(P){const R=Ze(eq,P.nativeEvent),I=g[c];return S(I),u.state.setSelectedValue(g.filter((k,B)=>B!==c),R),u.state.inputRef.current?.focus(),R}return tr("button",t,{ref:[n,b],state:w,props:[{tabIndex:-1,onClick(P){if(v||p)return;E(P).isPropagationAllowed||P.stopPropagation()},onKeyDown(P){v||p||(P.key==="Enter"||P.key===" ")&&(E(P).isPropagationAllowed||Lt(P))}},s,y]})});process.env.NODE_ENV!=="production"&&(lk.displayName="ComboboxChipRemove");var I8=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],mh=I8.reduce((e,t)=>{const n=rI(`Primitive.${t}`),r=x.forwardRef((i,o)=>{const{asChild:a,...s}=i,u=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),O.jsx(u,{...s,ref:o})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),T8="Label",uk=x.forwardRef((e,t)=>O.jsx(mh.label,{...e,ref:t,onMouseDown:n=>{n.target.closest("button, input, select, textarea")||(e.onMouseDown?.(n),!n.defaultPrevented&&n.detail>1&&n.preventDefault())}}));uk.displayName=T8;var ck=uk;const k8=St(dn("body-sm-regular")),Ku=({className:e,ref:t,...n})=>O.jsx(ck,{ref:t,className:ae(k8(),e),...n});Ku.displayName=ck.displayName;var N8="Separator",RE="horizontal",M8=["horizontal","vertical"],fk=x.forwardRef((e,t)=>{const{decorative:n,orientation:r=RE,...i}=e,o=D8(r)?r:RE,s=n?{role:"none"}:{"aria-orientation":o==="vertical"?o:void 0,role:"separator"};return O.jsx(mh.div,{"data-orientation":o,...s,...i,ref:t})});fk.displayName=N8;function D8(e){return M8.includes(e)}var dk=fk;const i0=({className:e,orientation:t="horizontal",decorative:n=!0,ref:r,...i})=>O.jsx(dk,{ref:r,decorative:n,orientation:t,className:ae("bg-delicate-border shrink-0",t==="horizontal"?"h-px w-full":"h-full w-px",e),...i});i0.displayName=dk.displayName;const j8=St("group/field data-[invalid=true]:text-error-text flex h-full w-full gap-2",{variants:{orientation:{vertical:["flex-col"],horizontal:["flex-row items-center","*:data-[slot=field-label]:flex-auto",`has-[>[data-slot=field-content]]:items-start
|
|
36
|
+
has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px`]}},defaultVariants:{orientation:"vertical"}}),L8="flex flex-col gap-6 has-[>[data-slot=checkbox-group]]:gap-3 has-[>[data-slot=radio-group]]:gap-3",$8="mb-3 font-medium data-[variant=legend]:text-base data-[variant=label]:text-sm",F8="group/field-group @container/field-group flex w-full flex-col gap-7 data-[slot=checkbox-group]:gap-3 *:data-[slot=field-group]:gap-4",V8="group/field-content flex flex-1 flex-col gap-2",B8=[`group/field-label peer/field-label text-primary-text flex w-fit gap-2 text-sm
|
|
37
37
|
leading-[150%] font-normal tracking-normal
|
|
38
38
|
group-data-[disabled=true]/field:opacity-50`,"aria-invalid:text-error-text aria-valid:text-success-text disabled:text-disabled-text",`has-[>[data-slot=field]]:w-full has-[>[data-slot=field]]:flex-col
|
|
39
39
|
has-[>[data-slot=field]]:rounded-md has-[>[data-slot=field]]:border
|
|
40
40
|
*:data-[slot=field]:p-4`,`has-data-[state=checked]:bg-primary/5 has-data-[state=checked]:border-primary
|
|
41
|
-
dark:has-data-[state=checked]:bg-primary/10`].join(" "),
|
|
42
|
-
group-data-[disabled=true]/field:opacity-50`,dn("body-sm-regular")].join(" "),
|
|
41
|
+
dark:has-data-[state=checked]:bg-primary/10`].join(" "),z8=[`text-primary-text flex w-fit items-center gap-2
|
|
42
|
+
group-data-[disabled=true]/field:opacity-50`,dn("body-sm-regular")].join(" "),W8=["text-sub-label-text group-has-data-[orientation=horizontal]/field:text-balance","aria-invalid:text-error-text aria-valid:text-success-text disabled:text-disabled-text",dn("body-xs-regular"),"last:mt-0 nth-last-2:-mt-1 [[data-variant=legend]+&]:-mt-1.5","[&>a:hover]:text-primary-text [&>a]:underline [&>a]:underline-offset-4"].join(" "),H8="relative -my-2 h-5 text-sm group-data-[variant=outline]/field-group:-mb-2",U8="absolute inset-0 top-1/2",G8="bg-background text-muted-foreground relative mx-auto block w-fit px-2",q8="ml-4 flex list-disc flex-col gap-1",K8="text-error-text text-xs leading-[140%] font-normal tracking-normal";function vh({className:e,...t}){return O.jsx("fieldset",{"data-slot":"field-set",className:ae(L8,e,"min-w-0 flex-1 w-full"),...t})}function Y8({className:e,variant:t="legend",...n}){return O.jsx("legend",{"data-slot":"field-legend","data-variant":t,className:ae($8,e),...n})}function hc({className:e,...t}){return O.jsx("div",{"data-slot":"field-group",className:ae(F8,e),...t})}function gc({className:e,orientation:t="vertical",...n}){return O.jsx("div",{role:"group","data-slot":"field","data-orientation":t,className:ae(j8({orientation:t}),e),...n})}function X8({className:e,...t}){return O.jsx("div",{"data-slot":"field-content",className:ae(V8,e),...t})}function Rl({className:e,...t}){return O.jsx(Ku,{"data-slot":"field-label",className:ae(B8,e),...t})}function Z8({className:e,...t}){return O.jsx("div",{"data-slot":"field-label",className:ae(z8,e),...t})}function mc({className:e,...t}){return O.jsx("p",{"data-slot":"field-description",className:ae(W8,e),...t})}function Q8({children:e,className:t,...n}){return O.jsxs("div",{"data-slot":"field-separator","data-content":!!e,className:ae(H8,t),...n,children:[O.jsx(i0,{className:U8}),e&&O.jsx("span",{className:G8,"data-slot":"field-separator-content",children:e})]})}function pk({className:e,children:t,errors:n,...r}){const i=$.useMemo(()=>t||(n?n.length===1&&n[0]?.message?n[0].message:O.jsx("ul",{className:q8,children:n.map(o=>o?.message?O.jsx("li",{children:o.message},o.message):null)}):null),[t,n]);return i?O.jsx("div",{role:"alert","data-slot":"field-error",className:ae(K8,e),...r,children:i}):null}const J8=St(`text-primary-text hover:border-inp-hover-border focus:border-inp-focus-border
|
|
43
43
|
placeholder:text-placeholder-text disabled:border-inp-disabled-border bg-primary-bg
|
|
44
44
|
disabled:bg-disabled-bg disabled:text-disabled-text
|
|
45
45
|
disabled:placeholder:text-disabled-text aria-invalid:border-error-text
|
|
46
46
|
aria-valid:border-success-text w-full rounded-xl border px-3 py-2.5 tracking-normal
|
|
47
47
|
placeholder:text-sm focus:outline-none focus-visible:ring-0
|
|
48
|
-
disabled:pointer-events-none`,{variants:{variant:{primary:"border-inp-default-border"},sizeInput:{lg:"h-12 text-base",md:"h-10 text-sm",sm:"h-8 text-sm",xs:"h-6 text-xs"}},defaultVariants:{variant:"primary",sizeInput:"md"}}),
|
|
48
|
+
disabled:pointer-events-none`,{variants:{variant:{primary:"border-inp-default-border"},sizeInput:{lg:"h-12 text-base",md:"h-10 text-sm",sm:"h-8 text-sm",xs:"h-6 text-xs"}},defaultVariants:{variant:"primary",sizeInput:"md"}}),o0=({className:e,sizeInput:t,type:n,variant:r,...i})=>O.jsx("input",{"data-slot":"input",type:n||"text",className:ae(J8({variant:r,sizeInput:t}),e),...i}),e9=[`border-inp-default-border bg-primary-bg text-primary-text flex h-31 w-full
|
|
49
49
|
resize-none rounded-xl border px-3 py-2.5 text-sm`,"hover:border-inp-hover-border focus:border-inp-focus-border focus:outline-none","placeholder:text-placeholder-text placeholder:text-sm",`disabled:border-inp-disabled-border disabled:bg-disabled-bg
|
|
50
50
|
disabled:text-disabled-text disabled:placeholder:text-disabled-text
|
|
51
|
-
aria-invalid:border-error-text`].join(" "),
|
|
51
|
+
aria-invalid:border-error-text`].join(" "),yh=e=>O.jsx("textarea",{className:ae(e9,e.className),...e});yh.displayName="Textarea";const t9=St(`text-secondary-text group-data-[disabled=true]/input-group:text-disabled-text flex
|
|
52
52
|
h-auto shrink-0 cursor-text items-center justify-center gap-2 py-1.5 text-sm font-medium
|
|
53
53
|
select-none [&>kbd]:rounded-[calc(var(--radius)-5px)]
|
|
54
54
|
[&>svg:not([class*='size-'])]:size-4`,{variants:{align:{"inline-start":"order-first pl-3 has-[>button]:ml-[-0.45rem] has-[>kbd]:ml-[-0.35rem]","inline-end":"order-last pr-3 has-[>button]:mr-[-0.4rem] has-[>kbd]:mr-[-0.35rem]","block-start":`order-first w-full justify-start px-3 pt-3
|
|
55
55
|
group-has-[>input]/input-group:pt-2.5 [.border-b]:pb-3`,"block-end":`order-last w-full justify-start px-3 pb-3
|
|
56
|
-
group-has-[>input]/input-group:pb-2.5 [.border-t]:pt-3`}},defaultVariants:{align:"inline-start"}}),
|
|
57
|
-
[&>svg:not([class*='size-'])]:size-3.5`,sm:"h-8 gap-1.5 rounded-md px-2.5 has-[>svg]:px-2.5","icon-xs":"size-6 rounded-[calc(var(--radius)-5px)] p-0 has-[>svg]:p-0","icon-sm":"size-8 p-0 has-[>svg]:p-0"}},defaultVariants:{size:"xs"}});function
|
|
56
|
+
group-has-[>input]/input-group:pb-2.5 [.border-t]:pt-3`}},defaultVariants:{align:"inline-start"}}),n9=St("flex items-center gap-2 text-sm shadow-none",{variants:{size:{xs:`h-6 gap-1 rounded-[calc(var(--radius)-5px)] px-2 has-[>svg]:px-2
|
|
57
|
+
[&>svg:not([class*='size-'])]:size-3.5`,sm:"h-8 gap-1.5 rounded-md px-2.5 has-[>svg]:px-2.5","icon-xs":"size-6 rounded-[calc(var(--radius)-5px)] p-0 has-[>svg]:p-0","icon-sm":"size-8 p-0 has-[>svg]:p-0"}},defaultVariants:{size:"xs"}});function a0({className:e,...t}){return O.jsx("div",{"data-slot":"input-group",role:"group",className:ae(`group/input-group border-inp-default-border bg-primary-bg relative flex w-full
|
|
58
58
|
items-center rounded-xl border transition-[color,box-shadow] outline-none`,"h-10 has-[>textarea]:h-auto","hover:border-inp-hover-border","has-[>[data-align=inline-start]]:[&>input]:pl-2","has-[>[data-align=inline-end]]:[&>input]:pr-2",`has-[>[data-align=block-start]]:h-auto has-[>[data-align=block-start]]:flex-col
|
|
59
59
|
has-[>[data-align=block-start]]:[&>input]:pb-3`,`has-[>[data-align=block-end]]:h-auto has-[>[data-align=block-end]]:flex-col
|
|
60
60
|
has-[>[data-align=block-end]]:[&>input]:pt-3`,`has-[[data-slot=input-group-control]:focus-visible]:ring-inp-focus-border/20
|
|
61
61
|
has-[[data-slot=input-group-control]:focus-visible]:border-inp-focus-border`,"has-[[data-slot=input-group-control][aria-invalid=true]]:border-error-text","has-[[data-slot=input-group-control][aria-valid=true]]:border-success-text",`has-[[data-slot=input-group-control][disabled]]:border-inp-disabled-border
|
|
62
62
|
has-[[data-slot=input-group-control][disabled]]:bg-disabled-bg
|
|
63
63
|
has-[[data-slot=input-group-control][disabled]]:text-disabled-text
|
|
64
|
-
has-[[data-slot=input-group-control][disabled]]:[&_svg]:text-disabled-text`,e),...t})}function
|
|
65
|
-
[&_svg:not([class*='size-'])]:size-4`,e),...t})}function
|
|
64
|
+
has-[[data-slot=input-group-control][disabled]]:[&_svg]:text-disabled-text`,e),...t})}function s0({className:e,align:t="inline-start",...n}){return O.jsx("div",{role:"group","data-slot":"input-group-addon","data-align":t,className:ae(t9({align:t}),e),onClick:r=>{r.target.closest("button")||r.currentTarget.parentElement?.querySelector("input")?.focus()},...n})}function hk({className:e,type:t="button",variant:n="primary",size:r="xs",...i}){return O.jsx(uo,{type:t,"data-size":r,variant:n,className:ae(n9({size:r}),e),...i})}function r9({className:e,...t}){return O.jsx("span",{className:ae(`text-secondary-text flex items-center gap-2 text-sm [&_svg]:pointer-events-none
|
|
65
|
+
[&_svg:not([class*='size-'])]:size-4`,e),...t})}function l0(e){return O.jsx(o0,{"data-slot":"input-group-control",className:ae(`w-0 min-w-0 flex-1 rounded-none border-0 bg-transparent shadow-none
|
|
66
66
|
focus-visible:ring-0 disabled:border-0 disabled:bg-transparent
|
|
67
|
-
dark:bg-transparent`,e.className),...e})}function
|
|
67
|
+
dark:bg-transparent`,e.className),...e})}function i9({className:e,...t}){return O.jsx(yh,{"data-slot":"input-group-control",className:ae(`flex-1 resize-none rounded-none border-0 bg-transparent py-3 shadow-none
|
|
68
68
|
focus-visible:ring-0 disabled:border-0 disabled:bg-transparent
|
|
69
|
-
dark:bg-transparent`,e),...t})}const
|
|
70
|
-
cursor-pointer focus-visible:border-0 focus-visible:ring-0 focus-visible:outline-none`,
|
|
69
|
+
dark:bg-transparent`,e),...t})}const o9=`absolute top-1/2 right-3 z-10 -translate-y-1/2
|
|
70
|
+
cursor-pointer focus-visible:border-0 focus-visible:ring-0 focus-visible:outline-none`,a9=St("text-primary-text pointer-events-none transition-colors",{variants:{disabled:{true:"text-disabled-text",false:""}},defaultVariants:{disabled:!1}}),gk=`h-full rounded-none border-0 bg-transparent p-0
|
|
71
71
|
pr-1.5 shadow-none hover:bg-transparent hover:shadow-none focus:bg-transparent
|
|
72
|
-
focus:shadow-none`,
|
|
72
|
+
focus:shadow-none`,s9="pointer-events-none",l9=`has-[[data-slot=input-group-control]:focus-visible]:border-inp-focus-border
|
|
73
73
|
has-[[data-slot=combobox-trigger]:focus-visible]:border-inp-focus-border px-0
|
|
74
74
|
has-[[data-slot=combobox-trigger]:focus-visible]:ring-0
|
|
75
75
|
has-[[data-slot=combobox-trigger]:focus-visible]:outline-none
|
|
76
76
|
has-[[data-slot=input-group-control]:focus-visible]:ring-0
|
|
77
|
-
has-[[data-slot=input-group-control]:focus-visible]:outline-none`,
|
|
77
|
+
has-[[data-slot=input-group-control]:focus-visible]:outline-none`,u9="cursor-pointer",c9="isolate z-50",f9=`bg-primary-bg text-primary-text data-open:animate-in
|
|
78
78
|
data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0
|
|
79
79
|
data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2
|
|
80
80
|
data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2
|
|
@@ -84,11 +84,11 @@ border-inp-focus-border absolute max-h-63 w-(--anchor-width) min-w-(--anchor-wid
|
|
|
84
84
|
origin-(--transform-origin) overflow-auto rounded-xl border pl-0
|
|
85
85
|
shadow-[0px_4px_12px_0px_rgba(0,0,0,0.1)] duration-100 *:data-[slot=input-group]:m-1
|
|
86
86
|
*:data-[slot=input-group]:mb-0 *:data-[slot=input-group]:h-8
|
|
87
|
-
*:data-[slot=input-group]:shadow-none`,
|
|
87
|
+
*:data-[slot=input-group]:shadow-none`,d9=`text-primary-text data-disabled:text-disabled-text
|
|
88
88
|
data-highlighted:bg-primary-hover-bg relative flex w-full cursor-pointer items-center gap-2
|
|
89
89
|
text-sm outline-none select-none data-disabled:pointer-events-none
|
|
90
|
-
[&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,
|
|
91
|
-
text-center text-sm group-data-empty/combobox-content:flex`,
|
|
90
|
+
[&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,p9="text-secondary-text px-4 py-2 text-xs",h9=`text-secondary-text hidden w-full justify-center py-2
|
|
91
|
+
text-center text-sm group-data-empty/combobox-content:flex`,g9="bg-delicate-border -mx-1 my-1 h-px",m9=St(`border-inp-default-border bg-primary-bg text-primary-text hover:border-inp-hover-border
|
|
92
92
|
has-aria-invalid:border-error-text has-aria-valid:border-success-text
|
|
93
93
|
has-aria-invalid:ring-error-text/20 focus-within:border-inp-focus-border relative flex
|
|
94
94
|
min-h-10 w-full flex-wrap items-center gap-1 rounded-xl border bg-clip-padding py-1.5
|
|
@@ -96,16 +96,16 @@ text-center text-sm group-data-empty/combobox-content:flex`,u8="bg-delicate-bord
|
|
|
96
96
|
focus-within:outline-none disabled:pointer-events-none
|
|
97
97
|
has-data-[slot=combobox-chip]:pl-1`,{variants:{disabled:{true:`border-inp-disabled-border bg-disabled-bg text-disabled-text
|
|
98
98
|
hover:border-inp-disabled-border [&_input]:text-disabled-text
|
|
99
|
-
[&_input::placeholder]:text-disabled-text [&_svg]:text-disabled-text`,false:""}},defaultVariants:{disabled:!1}}),
|
|
99
|
+
[&_input::placeholder]:text-disabled-text [&_svg]:text-disabled-text`,false:""}},defaultVariants:{disabled:!1}}),v9=`text-primary-text flex items-center justify-center
|
|
100
100
|
px-1.5 text-xs font-medium whitespace-nowrap has-disabled:pointer-events-none
|
|
101
101
|
has-disabled:cursor-not-allowed has-disabled:opacity-50
|
|
102
|
-
has-data-[slot=combobox-chip-remove]:pr-0`,
|
|
103
|
-
disabled:placeholder:text-disabled-text min-w-16 flex-1 outline-none`,{variants:{disabled:{true:"flex-1 p-0",false:""}},defaultVariants:{disabled:!1}}),ch=x.createContext(null);function qT({children:e,...t}){const[n,r]=x.useState(null),i=x.useMemo(()=>({anchorElement:n,setAnchorElement:r}),[n]);return P.jsx(ch,{value:i,children:P.jsx(wK,{...t,children:e})})}function KT({className:e,label:t,description:n,error:r,children:i,...o}){return P.jsxs(sc,{className:e,...o,children:[t&&P.jsx(El,{children:t}),i,n&&P.jsx(lc,{children:n}),r&&P.jsx(HT,{children:r})]})}function Ly({...e}){return P.jsx(CK,{"data-slot":"combobox-value",...e})}function qd({className:e,children:t,...n}){return P.jsxs(xT,{"data-slot":"combobox-trigger",className:ue(JK,e),...n,children:[t,P.jsx(uo,{type:"chevron",className:ue(e8({disabled:n.disabled})),size:"md"})]})}function p8({className:e,...t}){return P.jsx(CT,{"data-slot":"combobox-clear",className:ue(e),...t,render:P.jsx(UT,{variant:"link",size:"icon-xs",className:GT,children:P.jsx(uo,{className:t8,type:"close"})})})}function h8({className:e,children:t,disabled:n=!1,showTrigger:r=!0,showClear:i=!1,...o}){const a=x.use(ch),s=x.useCallback(u=>{a&&a.setAnchorElement(c=>c===u?c:u)},[a]);return P.jsxs(V0,{ref:s,className:ue(n8,e),children:[P.jsx(N0,{render:P.jsx(z0,{disabled:n}),...o}),P.jsxs(B0,{align:"inline-end",className:r8,children:[r&&P.jsx(qd,{}),i&&P.jsx(p8,{disabled:n})]}),t]})}function YT({className:e,side:t="bottom",sideOffset:n=8,align:r="start",alignOffset:i=0,anchor:o,portalContainer:a,...s}){const c=x.use(ch)?.anchorElement??null,d=x.useCallback(()=>{if(typeof document>"u")return null;const b=document.activeElement;return b?b.closest('[data-slot="combobox-chips"]')??b.closest('[data-slot="input-group"]'):null},[]),p=x.useCallback(()=>{const b=c??d();if(typeof Element>"u"||!o)return b;if(o instanceof Element)return o;if(typeof o=="function"){const y=o();return y instanceof Element?y:b}return"current"in o&&o.current instanceof Element?o.current:b},[o,c,d]),g=x.useCallback(()=>{if(typeof document>"u")return;const b=p();if(b instanceof HTMLElement){const w=b.closest('[role="dialog"]');if(w instanceof HTMLElement)return w}const y=document.activeElement?.closest('[role="dialog"]');return y instanceof HTMLElement?y:void 0},[p]),h=o??c??d,v=a??g();return P.jsx(_T,{container:v,children:P.jsx(AT,{side:t,sideOffset:n,align:r,alignOffset:i,anchor:h,className:i8,children:P.jsx(RT,{"data-slot":"combobox-content","data-chips":!!o,className:ue(o8,e),...s})})})}function XT({className:e,...t}){return P.jsx(ET,{"data-slot":"combobox-list",className:ue("flex flex-col gap-1",e),...t})}function ZT({className:e,children:t,...n}){return P.jsx(MT,{"data-slot":"combobox-item",className:ue(a8,e),...n,children:t})}function g8({className:e,...t}){return P.jsx(IT,{"data-slot":"combobox-group",className:ue(e),...t})}function m8({className:e,...t}){return P.jsx(TT,{"data-slot":"combobox-label",className:ue(s8,e),...t})}function v8({...e}){return P.jsx(ST,{"data-slot":"combobox-collection",...e})}function QT({className:e,...t}){return P.jsx(DT,{"data-slot":"combobox-empty",className:ue(l8,e),...t})}function y8({className:e,...t}){return P.jsx(jT,{"data-slot":"combobox-separator",className:ue(u8,e),...t})}function $y({className:e,disabled:t=!1,...n}){const r=x.use(ch),i=x.useCallback(o=>{r&&r.setAnchorElement(a=>a===o?a:o)},[r]);return P.jsx(LT,{ref:i,"data-slot":"combobox-chips",className:ue(c8({disabled:t}),e),...n})}function JT({className:e,children:t,showRemove:n=!0,...r}){return P.jsxs($T,{"data-slot":"combobox-chip",className:ue(f8,e),...r,children:[t,n&&P.jsx(FT,{render:P.jsx(oo,{className:GT,variant:"ghost",children:P.jsx(uo,{className:"text-secondary-text",type:"close"})})})]})}function Fy({className:e,...t}){return P.jsx(N0,{"data-slot":"combobox-chip-input",className:ue(d8({disabled:t.disabled}),e),...t})}var b8=x[" useId ".trim().toString()]||(()=>{}),x8=0;function sl(e){const[t,n]=x.useState(b8());return ia(()=>{n(r=>r??String(x8++))},[e]),t?`radix-${t}`:""}function Ja(e){const t=x.useRef(e);return x.useEffect(()=>{t.current=e}),x.useMemo(()=>(...n)=>t.current?.(...n),[])}function w8(e,t=globalThis?.document){const n=Ja(e);x.useEffect(()=>{const r=i=>{i.key==="Escape"&&n(i)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var C8="DismissableLayer",Vy="dismissableLayer.update",S8="dismissableLayer.pointerDownOutside",E8="dismissableLayer.focusOutside",cE,ek=x.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),W0=x.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:i,onFocusOutside:o,onInteractOutside:a,onDismiss:s,...u}=e,c=x.useContext(ek),[d,p]=x.useState(null),g=d?.ownerDocument??globalThis?.document,[,h]=x.useState({}),v=Zt(t,I=>p(I)),b=Array.from(c.layers),[y]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),w=b.indexOf(y),C=d?b.indexOf(d):-1,E=c.layersWithOutsidePointerEventsDisabled.size>0,_=C>=w,O=P8(I=>{const k=I.target,B=[...c.branches].some(L=>L.contains(k));!_||B||(i?.(I),a?.(I),I.defaultPrevented||s?.())},g),R=A8(I=>{const k=I.target;[...c.branches].some(L=>L.contains(k))||(o?.(I),a?.(I),I.defaultPrevented||s?.())},g);return w8(I=>{C===c.layers.size-1&&(r?.(I),!I.defaultPrevented&&s&&(I.preventDefault(),s()))},g),x.useEffect(()=>{if(d)return n&&(c.layersWithOutsidePointerEventsDisabled.size===0&&(cE=g.body.style.pointerEvents,g.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(d)),c.layers.add(d),fE(),()=>{n&&c.layersWithOutsidePointerEventsDisabled.size===1&&(g.body.style.pointerEvents=cE)}},[d,g,n,c]),x.useEffect(()=>()=>{d&&(c.layers.delete(d),c.layersWithOutsidePointerEventsDisabled.delete(d),fE())},[d,c]),x.useEffect(()=>{const I=()=>h({});return document.addEventListener(Vy,I),()=>document.removeEventListener(Vy,I)},[]),P.jsx(wt.div,{...u,ref:v,style:{pointerEvents:E?_?"auto":"none":void 0,...e.style},onFocusCapture:bt(e.onFocusCapture,R.onFocusCapture),onBlurCapture:bt(e.onBlurCapture,R.onBlurCapture),onPointerDownCapture:bt(e.onPointerDownCapture,O.onPointerDownCapture)})});W0.displayName=C8;var _8="DismissableLayerBranch",O8=x.forwardRef((e,t)=>{const n=x.useContext(ek),r=x.useRef(null),i=Zt(t,r);return x.useEffect(()=>{const o=r.current;if(o)return n.branches.add(o),()=>{n.branches.delete(o)}},[n.branches]),P.jsx(wt.div,{...e,ref:i})});O8.displayName=_8;function P8(e,t=globalThis?.document){const n=Ja(e),r=x.useRef(!1),i=x.useRef(()=>{});return x.useEffect(()=>{const o=s=>{if(s.target&&!r.current){let u=function(){tk(S8,n,c,{discrete:!0})};const c={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",i.current),i.current=u,t.addEventListener("click",i.current,{once:!0})):u()}else t.removeEventListener("click",i.current);r.current=!1},a=window.setTimeout(()=>{t.addEventListener("pointerdown",o)},0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",o),t.removeEventListener("click",i.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function A8(e,t=globalThis?.document){const n=Ja(e),r=x.useRef(!1);return x.useEffect(()=>{const i=o=>{o.target&&!r.current&&tk(E8,n,{originalEvent:o},{discrete:!1})};return t.addEventListener("focusin",i),()=>t.removeEventListener("focusin",i)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function fE(){const e=new CustomEvent(Vy);document.dispatchEvent(e)}function tk(e,t,n,{discrete:r}){const i=n.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?WH(i,o):i.dispatchEvent(o)}var Im="focusScope.autoFocusOnMount",Tm="focusScope.autoFocusOnUnmount",dE={bubbles:!1,cancelable:!0},R8="FocusScope",nk=x.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:o,...a}=e,[s,u]=x.useState(null),c=Ja(i),d=Ja(o),p=x.useRef(null),g=Zt(t,b=>u(b)),h=x.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;x.useEffect(()=>{if(r){let b=function(E){if(h.paused||!s)return;const _=E.target;s.contains(_)?p.current=_:Wo(p.current,{select:!0})},y=function(E){if(h.paused||!s)return;const _=E.relatedTarget;_!==null&&(s.contains(_)||Wo(p.current,{select:!0}))},w=function(E){if(document.activeElement===document.body)for(const O of E)O.removedNodes.length>0&&Wo(s)};document.addEventListener("focusin",b),document.addEventListener("focusout",y);const C=new MutationObserver(w);return s&&C.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",b),document.removeEventListener("focusout",y),C.disconnect()}}},[r,s,h.paused]),x.useEffect(()=>{if(s){hE.add(h);const b=document.activeElement;if(!s.contains(b)){const w=new CustomEvent(Im,dE);s.addEventListener(Im,c),s.dispatchEvent(w),w.defaultPrevented||(I8(D8(rk(s)),{select:!0}),document.activeElement===b&&Wo(s))}return()=>{s.removeEventListener(Im,c),setTimeout(()=>{const w=new CustomEvent(Tm,dE);s.addEventListener(Tm,d),s.dispatchEvent(w),w.defaultPrevented||Wo(b??document.body,{select:!0}),s.removeEventListener(Tm,d),hE.remove(h)},0)}}},[s,c,d,h]);const v=x.useCallback(b=>{if(!n&&!r||h.paused)return;const y=b.key==="Tab"&&!b.altKey&&!b.ctrlKey&&!b.metaKey,w=document.activeElement;if(y&&w){const C=b.currentTarget,[E,_]=T8(C);E&&_?!b.shiftKey&&w===_?(b.preventDefault(),n&&Wo(E,{select:!0})):b.shiftKey&&w===E&&(b.preventDefault(),n&&Wo(_,{select:!0})):w===C&&b.preventDefault()}},[n,r,h.paused]);return P.jsx(wt.div,{tabIndex:-1,...a,ref:g,onKeyDown:v})});nk.displayName=R8;function I8(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Wo(r,{select:t}),document.activeElement!==n)return}function T8(e){const t=rk(e),n=pE(t,e),r=pE(t.reverse(),e);return[n,r]}function rk(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const i=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||i?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function pE(e,t){for(const n of e)if(!k8(n,{upTo:t}))return n}function k8(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 N8(e){return e instanceof HTMLInputElement&&"select"in e}function Wo(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&N8(e)&&t&&e.select()}}var hE=M8();function M8(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=gE(e,t),e.unshift(t)},remove(t){e=gE(e,t),e[0]?.resume()}}}function gE(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function D8(e){return e.filter(t=>t.tagName!=="A")}var j8="Portal",H0=x.forwardRef((e,t)=>{const{container:n,...r}=e,[i,o]=x.useState(!1);ia(()=>o(!0),[]);const a=n||i&&globalThis?.document?.body;return a?Up.createPortal(P.jsx(wt.div,{...r,ref:t}),a):null});H0.displayName=j8;var km=0;function L8(){x.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??mE()),document.body.insertAdjacentElement("beforeend",e[1]??mE()),km++,()=>{km===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),km--}},[])}function mE(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var Pi=function(){return Pi=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},Pi.apply(this,arguments)};function ik(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function $8(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,o;r<i;r++)(o||!(r in t))&&(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}var Ed="right-scroll-bar-position",_d="width-before-scroll-bar",F8="with-scroll-bars-hidden",V8="--removed-body-scroll-bar-size";function Nm(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function B8(e,t){var n=j.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var i=n.value;i!==r&&(n.value=r,n.callback(r,i))}}}})[0];return n.callback=t,n.facade}var z8=typeof window<"u"?x.useLayoutEffect:x.useEffect,vE=new WeakMap;function W8(e,t){var n=B8(null,function(r){return e.forEach(function(i){return Nm(i,r)})});return z8(function(){var r=vE.get(n);if(r){var i=new Set(r),o=new Set(e),a=n.current;i.forEach(function(s){o.has(s)||Nm(s,null)}),o.forEach(function(s){i.has(s)||Nm(s,a)})}vE.set(n,e)},[e]),n}function H8(e){return e}function U8(e,t){t===void 0&&(t=H8);var n=[],r=!1,i={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(o){var a=t(o,r);return n.push(a),function(){n=n.filter(function(s){return s!==a})}},assignSyncMedium:function(o){for(r=!0;n.length;){var a=n;n=[],a.forEach(o)}n={push:function(s){return o(s)},filter:function(){return n}}},assignMedium:function(o){r=!0;var a=[];if(n.length){var s=n;n=[],s.forEach(o),a=n}var u=function(){var d=a;a=[],d.forEach(o)},c=function(){return Promise.resolve().then(u)};c(),n={push:function(d){a.push(d),c()},filter:function(d){return a=a.filter(d),n}}}};return i}function G8(e){e===void 0&&(e={});var t=U8(null);return t.options=Pi({async:!0,ssr:!1},e),t}var ok=function(e){var t=e.sideCar,n=ik(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 x.createElement(r,Pi({},n))};ok.isSideCarExport=!0;function q8(e,t){return e.useMedium(t),ok}var ak=G8(),Mm=function(){},fh=x.forwardRef(function(e,t){var n=x.useRef(null),r=x.useState({onScrollCapture:Mm,onWheelCapture:Mm,onTouchMoveCapture:Mm}),i=r[0],o=r[1],a=e.forwardProps,s=e.children,u=e.className,c=e.removeScrollBar,d=e.enabled,p=e.shards,g=e.sideCar,h=e.noRelative,v=e.noIsolation,b=e.inert,y=e.allowPinchZoom,w=e.as,C=w===void 0?"div":w,E=e.gapMode,_=ik(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),O=g,R=W8([n,t]),I=Pi(Pi({},_),i);return x.createElement(x.Fragment,null,d&&x.createElement(O,{sideCar:ak,removeScrollBar:c,shards:p,noRelative:h,noIsolation:v,inert:b,setCallbacks:o,allowPinchZoom:!!y,lockRef:n,gapMode:E}),a?x.cloneElement(x.Children.only(s),Pi(Pi({},I),{ref:R})):x.createElement(C,Pi({},I,{className:u,ref:R}),s))});fh.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};fh.classNames={fullWidth:_d,zeroRight:Ed};var K8=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function Y8(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=K8();return t&&e.setAttribute("nonce",t),e}function X8(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Z8(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var Q8=function(){var e=0,t=null;return{add:function(n){e==0&&(t=Y8())&&(X8(t,n),Z8(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},J8=function(){var e=Q8();return function(t,n){x.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},sk=function(){var e=J8(),t=function(n){var r=n.styles,i=n.dynamic;return e(r,i),null};return t},e9={left:0,top:0,right:0,gap:0},Dm=function(e){return parseInt(e||"",10)||0},t9=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],i=t[e==="padding"?"paddingRight":"marginRight"];return[Dm(n),Dm(r),Dm(i)]},n9=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return e9;var t=t9(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])}},r9=sk(),ll="data-scroll-locked",i9=function(e,t,n,r){var i=e.left,o=e.top,a=e.right,s=e.gap;return n===void 0&&(n="margin"),`
|
|
104
|
-
.`.concat(
|
|
102
|
+
has-data-[slot=combobox-chip-remove]:pr-0`,y9=St(`text-primary-text placeholder:text-placeholder-text disabled:text-disabled-text
|
|
103
|
+
disabled:placeholder:text-disabled-text min-w-16 flex-1 outline-none`,{variants:{disabled:{true:"flex-1 p-0",false:""}},defaultVariants:{disabled:!1}}),bh=x.createContext(null);function mk({children:e,...t}){const[n,r]=x.useState(null),i=x.useMemo(()=>({anchorElement:n,setAnchorElement:r}),[n]);return O.jsx(bh,{value:i,children:O.jsx(P8,{...t,children:e})})}function vk({className:e,label:t,description:n,error:r,children:i,...o}){return O.jsxs(gc,{className:e,...o,children:[t&&O.jsx(Rl,{children:t}),i,n&&O.jsx(mc,{children:n}),r&&O.jsx(pk,{children:r})]})}function Jy({...e}){return O.jsx(A8,{"data-slot":"combobox-value",...e})}function ep({className:e,children:t,...n}){return O.jsxs(WT,{"data-slot":"combobox-trigger",className:ae(o9,e),...n,children:[t,O.jsx(ji,{type:"chevron",className:ae(a9({disabled:n.disabled})),size:"md"})]})}function b9({className:e,...t}){return O.jsx(UT,{"data-slot":"combobox-clear",className:ae(e),...t,render:O.jsx(hk,{variant:"link",size:"icon-xs",className:gk,children:O.jsx(ji,{className:s9,type:"close"})})})}function x9({className:e,children:t,disabled:n=!1,showTrigger:r=!0,showClear:i=!1,...o}){const a=x.use(bh),s=x.useCallback(u=>{a&&a.setAnchorElement(c=>c===u?c:u)},[a]);return O.jsxs(a0,{ref:s,className:ae(l9,e),children:[O.jsx(Jx,{render:O.jsx(l0,{disabled:n}),...o}),O.jsxs(s0,{align:"inline-end",className:u9,children:[r&&O.jsx(ep,{}),i&&O.jsx(b9,{disabled:n})]}),t]})}function yk({className:e,side:t="bottom",sideOffset:n=8,align:r="start",alignOffset:i=0,anchor:o,portalContainer:a,...s}){const c=x.use(bh)?.anchorElement??null,f=x.useCallback(()=>{if(typeof document>"u")return null;const b=document.activeElement;return b?b.closest('[data-slot="combobox-chips"]')??b.closest('[data-slot="input-group"]'):null},[]),p=x.useCallback(()=>{const b=c??f();if(typeof Element>"u"||!o)return b;if(o instanceof Element)return o;if(typeof o=="function"){const y=o();return y instanceof Element?y:b}return"current"in o&&o.current instanceof Element?o.current:b},[o,c,f]),g=x.useCallback(()=>{if(typeof document>"u")return;const b=p();if(b instanceof HTMLElement){const w=b.closest('[role="dialog"]');if(w instanceof HTMLElement)return w}const y=document.activeElement?.closest('[role="dialog"]');return y instanceof HTMLElement?y:void 0},[p]),h=o??c??f,v=a??g();return O.jsx(KT,{container:v,children:O.jsx(ZT,{side:t,sideOffset:n,align:r,alignOffset:i,anchor:h,className:c9,children:O.jsx(QT,{"data-slot":"combobox-content","data-chips":!!o,className:ae(f9,e),...s})})})}function bk({className:e,...t}){return O.jsx(qT,{"data-slot":"combobox-list",className:ae("flex flex-col gap-1",e),...t})}function xk({className:e,children:t,...n}){return O.jsx(rk,{"data-slot":"combobox-item",className:ae(d9,e),...n,children:t})}function w9({className:e,...t}){return O.jsx(JT,{"data-slot":"combobox-group",className:ae(e),...t})}function S9({className:e,...t}){return O.jsx(ek,{"data-slot":"combobox-label",className:ae(p9,e),...t})}function C9({...e}){return O.jsx(GT,{"data-slot":"combobox-collection",...e})}function wk({className:e,...t}){return O.jsx(ik,{"data-slot":"combobox-empty",className:ae(h9,e),...t})}function E9({className:e,...t}){return O.jsx(ok,{"data-slot":"combobox-separator",className:ae(g9,e),...t})}function eb({className:e,disabled:t=!1,...n}){const r=x.use(bh),i=x.useCallback(o=>{r&&r.setAnchorElement(a=>a===o?a:o)},[r]);return O.jsx(ak,{ref:i,"data-slot":"combobox-chips",className:ae(m9({disabled:t}),e),...n})}function Sk({className:e,children:t,showRemove:n=!0,...r}){return O.jsxs(sk,{"data-slot":"combobox-chip",className:ae(v9,e),...r,children:[t,n&&O.jsx(lk,{render:O.jsx(uo,{className:gk,variant:"ghost",children:O.jsx(ji,{className:"text-secondary-text",type:"close"})})})]})}function tb({className:e,...t}){return O.jsx(Jx,{"data-slot":"combobox-chip-input",className:ae(y9({disabled:t.disabled}),e),...t})}var _9=x[" useId ".trim().toString()]||(()=>{}),O9=0;function fo(e){const[t,n]=x.useState(_9());return Wn(()=>{n(r=>r??String(O9++))},[e]),t?`radix-${t}`:""}function ca(e){const t=x.useRef(e);return x.useEffect(()=>{t.current=e}),x.useMemo(()=>(...n)=>t.current?.(...n),[])}function P9(e,t=globalThis?.document){const n=ca(e);x.useEffect(()=>{const r=i=>{i.key==="Escape"&&n(i)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var A9="DismissableLayer",nb="dismissableLayer.update",R9="dismissableLayer.pointerDownOutside",I9="dismissableLayer.focusOutside",IE,Ck=x.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),xh=x.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:i,onFocusOutside:o,onInteractOutside:a,onDismiss:s,...u}=e,c=x.useContext(Ck),[f,p]=x.useState(null),g=f?.ownerDocument??globalThis?.document,[,h]=x.useState({}),v=bt(t,I=>p(I)),b=Array.from(c.layers),[y]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),w=b.indexOf(y),S=f?b.indexOf(f):-1,E=c.layersWithOutsidePointerEventsDisabled.size>0,_=S>=w,P=N9(I=>{const k=I.target,B=[...c.branches].some(L=>L.contains(k));!_||B||(i?.(I),a?.(I),I.defaultPrevented||s?.())},g),R=M9(I=>{const k=I.target;[...c.branches].some(L=>L.contains(k))||(o?.(I),a?.(I),I.defaultPrevented||s?.())},g);return P9(I=>{S===c.layers.size-1&&(r?.(I),!I.defaultPrevented&&s&&(I.preventDefault(),s()))},g),x.useEffect(()=>{if(f)return n&&(c.layersWithOutsidePointerEventsDisabled.size===0&&(IE=g.body.style.pointerEvents,g.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(f)),c.layers.add(f),TE(),()=>{n&&c.layersWithOutsidePointerEventsDisabled.size===1&&(g.body.style.pointerEvents=IE)}},[f,g,n,c]),x.useEffect(()=>()=>{f&&(c.layers.delete(f),c.layersWithOutsidePointerEventsDisabled.delete(f),TE())},[f,c]),x.useEffect(()=>{const I=()=>h({});return document.addEventListener(nb,I),()=>document.removeEventListener(nb,I)},[]),O.jsx(Qe.div,{...u,ref:v,style:{pointerEvents:E?_?"auto":"none":void 0,...e.style},onFocusCapture:Ke(e.onFocusCapture,R.onFocusCapture),onBlurCapture:Ke(e.onBlurCapture,R.onBlurCapture),onPointerDownCapture:Ke(e.onPointerDownCapture,P.onPointerDownCapture)})});xh.displayName=A9;var T9="DismissableLayerBranch",k9=x.forwardRef((e,t)=>{const n=x.useContext(Ck),r=x.useRef(null),i=bt(t,r);return x.useEffect(()=>{const o=r.current;if(o)return n.branches.add(o),()=>{n.branches.delete(o)}},[n.branches]),O.jsx(Qe.div,{...e,ref:i})});k9.displayName=T9;function N9(e,t=globalThis?.document){const n=ca(e),r=x.useRef(!1),i=x.useRef(()=>{});return x.useEffect(()=>{const o=s=>{if(s.target&&!r.current){let u=function(){Ek(R9,n,c,{discrete:!0})};const c={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",i.current),i.current=u,t.addEventListener("click",i.current,{once:!0})):u()}else t.removeEventListener("click",i.current);r.current=!1},a=window.setTimeout(()=>{t.addEventListener("pointerdown",o)},0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",o),t.removeEventListener("click",i.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function M9(e,t=globalThis?.document){const n=ca(e),r=x.useRef(!1);return x.useEffect(()=>{const i=o=>{o.target&&!r.current&&Ek(I9,n,{originalEvent:o},{discrete:!1})};return t.addEventListener("focusin",i),()=>t.removeEventListener("focusin",i)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function TE(){const e=new CustomEvent(nb);document.dispatchEvent(e)}function Ek(e,t,n,{discrete:r}){const i=n.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?qU(i,o):i.dispatchEvent(o)}var Gm="focusScope.autoFocusOnMount",qm="focusScope.autoFocusOnUnmount",kE={bubbles:!1,cancelable:!0},D9="FocusScope",u0=x.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:o,...a}=e,[s,u]=x.useState(null),c=ca(i),f=ca(o),p=x.useRef(null),g=bt(t,b=>u(b)),h=x.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;x.useEffect(()=>{if(r){let b=function(E){if(h.paused||!s)return;const _=E.target;s.contains(_)?p.current=_:Ko(p.current,{select:!0})},y=function(E){if(h.paused||!s)return;const _=E.relatedTarget;_!==null&&(s.contains(_)||Ko(p.current,{select:!0}))},w=function(E){if(document.activeElement===document.body)for(const P of E)P.removedNodes.length>0&&Ko(s)};document.addEventListener("focusin",b),document.addEventListener("focusout",y);const S=new MutationObserver(w);return s&&S.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",b),document.removeEventListener("focusout",y),S.disconnect()}}},[r,s,h.paused]),x.useEffect(()=>{if(s){ME.add(h);const b=document.activeElement;if(!s.contains(b)){const w=new CustomEvent(Gm,kE);s.addEventListener(Gm,c),s.dispatchEvent(w),w.defaultPrevented||(j9(B9(_k(s)),{select:!0}),document.activeElement===b&&Ko(s))}return()=>{s.removeEventListener(Gm,c),setTimeout(()=>{const w=new CustomEvent(qm,kE);s.addEventListener(qm,f),s.dispatchEvent(w),w.defaultPrevented||Ko(b??document.body,{select:!0}),s.removeEventListener(qm,f),ME.remove(h)},0)}}},[s,c,f,h]);const v=x.useCallback(b=>{if(!n&&!r||h.paused)return;const y=b.key==="Tab"&&!b.altKey&&!b.ctrlKey&&!b.metaKey,w=document.activeElement;if(y&&w){const S=b.currentTarget,[E,_]=L9(S);E&&_?!b.shiftKey&&w===_?(b.preventDefault(),n&&Ko(E,{select:!0})):b.shiftKey&&w===E&&(b.preventDefault(),n&&Ko(_,{select:!0})):w===S&&b.preventDefault()}},[n,r,h.paused]);return O.jsx(Qe.div,{tabIndex:-1,...a,ref:g,onKeyDown:v})});u0.displayName=D9;function j9(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Ko(r,{select:t}),document.activeElement!==n)return}function L9(e){const t=_k(e),n=NE(t,e),r=NE(t.reverse(),e);return[n,r]}function _k(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const i=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||i?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function NE(e,t){for(const n of e)if(!$9(n,{upTo:t}))return n}function $9(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 F9(e){return e instanceof HTMLInputElement&&"select"in e}function Ko(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&F9(e)&&t&&e.select()}}var ME=V9();function V9(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=DE(e,t),e.unshift(t)},remove(t){e=DE(e,t),e[0]?.resume()}}}function DE(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function B9(e){return e.filter(t=>t.tagName!=="A")}var z9="Portal",wh=x.forwardRef((e,t)=>{const{container:n,...r}=e,[i,o]=x.useState(!1);Wn(()=>o(!0),[]);const a=n||i&&globalThis?.document?.body;return a?Jp.createPortal(O.jsx(Qe.div,{...r,ref:t}),a):null});wh.displayName=z9;var Km=0;function Ok(){x.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??jE()),document.body.insertAdjacentElement("beforeend",e[1]??jE()),Km++,()=>{Km===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Km--}},[])}function jE(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var Ii=function(){return Ii=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},Ii.apply(this,arguments)};function Pk(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function W9(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,o;r<i;r++)(o||!(r in t))&&(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}var kd="right-scroll-bar-position",Nd="width-before-scroll-bar",H9="with-scroll-bars-hidden",U9="--removed-body-scroll-bar-size";function Ym(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function G9(e,t){var n=$.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var i=n.value;i!==r&&(n.value=r,n.callback(r,i))}}}})[0];return n.callback=t,n.facade}var q9=typeof window<"u"?x.useLayoutEffect:x.useEffect,LE=new WeakMap;function K9(e,t){var n=G9(null,function(r){return e.forEach(function(i){return Ym(i,r)})});return q9(function(){var r=LE.get(n);if(r){var i=new Set(r),o=new Set(e),a=n.current;i.forEach(function(s){o.has(s)||Ym(s,null)}),o.forEach(function(s){i.has(s)||Ym(s,a)})}LE.set(n,e)},[e]),n}function Y9(e){return e}function X9(e,t){t===void 0&&(t=Y9);var n=[],r=!1,i={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(o){var a=t(o,r);return n.push(a),function(){n=n.filter(function(s){return s!==a})}},assignSyncMedium:function(o){for(r=!0;n.length;){var a=n;n=[],a.forEach(o)}n={push:function(s){return o(s)},filter:function(){return n}}},assignMedium:function(o){r=!0;var a=[];if(n.length){var s=n;n=[],s.forEach(o),a=n}var u=function(){var f=a;a=[],f.forEach(o)},c=function(){return Promise.resolve().then(u)};c(),n={push:function(f){a.push(f),c()},filter:function(f){return a=a.filter(f),n}}}};return i}function Z9(e){e===void 0&&(e={});var t=X9(null);return t.options=Ii({async:!0,ssr:!1},e),t}var Ak=function(e){var t=e.sideCar,n=Pk(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 x.createElement(r,Ii({},n))};Ak.isSideCarExport=!0;function Q9(e,t){return e.useMedium(t),Ak}var Rk=Z9(),Xm=function(){},Sh=x.forwardRef(function(e,t){var n=x.useRef(null),r=x.useState({onScrollCapture:Xm,onWheelCapture:Xm,onTouchMoveCapture:Xm}),i=r[0],o=r[1],a=e.forwardProps,s=e.children,u=e.className,c=e.removeScrollBar,f=e.enabled,p=e.shards,g=e.sideCar,h=e.noRelative,v=e.noIsolation,b=e.inert,y=e.allowPinchZoom,w=e.as,S=w===void 0?"div":w,E=e.gapMode,_=Pk(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),P=g,R=K9([n,t]),I=Ii(Ii({},_),i);return x.createElement(x.Fragment,null,f&&x.createElement(P,{sideCar:Rk,removeScrollBar:c,shards:p,noRelative:h,noIsolation:v,inert:b,setCallbacks:o,allowPinchZoom:!!y,lockRef:n,gapMode:E}),a?x.cloneElement(x.Children.only(s),Ii(Ii({},I),{ref:R})):x.createElement(S,Ii({},I,{className:u,ref:R}),s))});Sh.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};Sh.classNames={fullWidth:Nd,zeroRight:kd};var J9=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function e7(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=J9();return t&&e.setAttribute("nonce",t),e}function t7(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function n7(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var r7=function(){var e=0,t=null;return{add:function(n){e==0&&(t=e7())&&(t7(t,n),n7(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},i7=function(){var e=r7();return function(t,n){x.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Ik=function(){var e=i7(),t=function(n){var r=n.styles,i=n.dynamic;return e(r,i),null};return t},o7={left:0,top:0,right:0,gap:0},Zm=function(e){return parseInt(e||"",10)||0},a7=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],i=t[e==="padding"?"paddingRight":"marginRight"];return[Zm(n),Zm(r),Zm(i)]},s7=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return o7;var t=a7(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])}},l7=Ik(),pl="data-scroll-locked",u7=function(e,t,n,r){var i=e.left,o=e.top,a=e.right,s=e.gap;return n===void 0&&(n="margin"),`
|
|
104
|
+
.`.concat(H9,` {
|
|
105
105
|
overflow: hidden `).concat(r,`;
|
|
106
106
|
padding-right: `).concat(s,"px ").concat(r,`;
|
|
107
107
|
}
|
|
108
|
-
body[`).concat(
|
|
108
|
+
body[`).concat(pl,`] {
|
|
109
109
|
overflow: hidden `).concat(r,`;
|
|
110
110
|
overscroll-behavior: contain;
|
|
111
111
|
`).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
|
|
@@ -118,113 +118,142 @@ has-data-[slot=combobox-chip-remove]:pr-0`,d8=xt(`text-primary-text placeholder:
|
|
|
118
118
|
`),n==="padding"&&"padding-right: ".concat(s,"px ").concat(r,";")].filter(Boolean).join(""),`
|
|
119
119
|
}
|
|
120
120
|
|
|
121
|
-
.`).concat(
|
|
121
|
+
.`).concat(kd,` {
|
|
122
122
|
right: `).concat(s,"px ").concat(r,`;
|
|
123
123
|
}
|
|
124
124
|
|
|
125
|
-
.`).concat(
|
|
125
|
+
.`).concat(Nd,` {
|
|
126
126
|
margin-right: `).concat(s,"px ").concat(r,`;
|
|
127
127
|
}
|
|
128
128
|
|
|
129
|
-
.`).concat(
|
|
129
|
+
.`).concat(kd," .").concat(kd,` {
|
|
130
130
|
right: 0 `).concat(r,`;
|
|
131
131
|
}
|
|
132
132
|
|
|
133
|
-
.`).concat(
|
|
133
|
+
.`).concat(Nd," .").concat(Nd,` {
|
|
134
134
|
margin-right: 0 `).concat(r,`;
|
|
135
135
|
}
|
|
136
136
|
|
|
137
|
-
body[`).concat(
|
|
138
|
-
`).concat(
|
|
137
|
+
body[`).concat(pl,`] {
|
|
138
|
+
`).concat(U9,": ").concat(s,`px;
|
|
139
139
|
}
|
|
140
|
-
`)}
|
|
140
|
+
`)},$E=function(){var e=parseInt(document.body.getAttribute(pl)||"0",10);return isFinite(e)?e:0},c7=function(){x.useEffect(function(){return document.body.setAttribute(pl,($E()+1).toString()),function(){var e=$E()-1;e<=0?document.body.removeAttribute(pl):document.body.setAttribute(pl,e.toString())}},[])},f7=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=r===void 0?"margin":r;c7();var o=x.useMemo(function(){return s7(i)},[i]);return x.createElement(l7,{styles:u7(o,!t,i,n?"":"!important")})},rb=!1;if(typeof window<"u")try{var id=Object.defineProperty({},"passive",{get:function(){return rb=!0,!0}});window.addEventListener("test",id,id),window.removeEventListener("test",id,id)}catch{rb=!1}var Ys=rb?{passive:!1}:!1,d7=function(e){return e.tagName==="TEXTAREA"},Tk=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!d7(e)&&n[t]==="visible")},p7=function(e){return Tk(e,"overflowY")},h7=function(e){return Tk(e,"overflowX")},FE=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var i=kk(e,r);if(i){var o=Nk(e,r),a=o[1],s=o[2];if(a>s)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},g7=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},m7=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},kk=function(e,t){return e==="v"?p7(t):h7(t)},Nk=function(e,t){return e==="v"?g7(t):m7(t)},v7=function(e,t){return e==="h"&&t==="rtl"?-1:1},y7=function(e,t,n,r,i){var o=v7(e,window.getComputedStyle(t).direction),a=o*r,s=n.target,u=t.contains(s),c=!1,f=a>0,p=0,g=0;do{if(!s)break;var h=Nk(e,s),v=h[0],b=h[1],y=h[2],w=b-y-o*v;(v||w)&&kk(e,s)&&(p+=w,g+=v);var S=s.parentNode;s=S&&S.nodeType===Node.DOCUMENT_FRAGMENT_NODE?S.host:S}while(!u&&s!==document.body||u&&(t.contains(s)||t===s));return(f&&Math.abs(p)<1||!f&&Math.abs(g)<1)&&(c=!0),c},od=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},VE=function(e){return[e.deltaX,e.deltaY]},BE=function(e){return e&&"current"in e?e.current:e},b7=function(e,t){return e[0]===t[0]&&e[1]===t[1]},x7=function(e){return`
|
|
141
141
|
.block-interactivity-`.concat(e,` {pointer-events: none;}
|
|
142
142
|
.allow-interactivity-`).concat(e,` {pointer-events: all;}
|
|
143
|
-
`)},
|
|
143
|
+
`)},w7=0,Xs=[];function S7(e){var t=x.useRef([]),n=x.useRef([0,0]),r=x.useRef(),i=x.useState(w7++)[0],o=x.useState(Ik)[0],a=x.useRef(e);x.useEffect(function(){a.current=e},[e]),x.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(i));var b=W9([e.lockRef.current],(e.shards||[]).map(BE),!0).filter(Boolean);return b.forEach(function(y){return y.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),b.forEach(function(y){return y.classList.remove("allow-interactivity-".concat(i))})}}},[e.inert,e.lockRef.current,e.shards]);var s=x.useCallback(function(b,y){if("touches"in b&&b.touches.length===2||b.type==="wheel"&&b.ctrlKey)return!a.current.allowPinchZoom;var w=od(b),S=n.current,E="deltaX"in b?b.deltaX:S[0]-w[0],_="deltaY"in b?b.deltaY:S[1]-w[1],P,R=b.target,I=Math.abs(E)>Math.abs(_)?"h":"v";if("touches"in b&&I==="h"&&R.type==="range")return!1;var k=window.getSelection(),B=k&&k.anchorNode,L=B?B===R||B.contains(R):!1;if(L)return!1;var V=FE(I,R);if(!V)return!0;if(V?P=I:(P=I==="v"?"h":"v",V=FE(I,R)),!V)return!1;if(!r.current&&"changedTouches"in b&&(E||_)&&(r.current=P),!P)return!0;var D=r.current||P;return y7(D,y,b,D==="h"?E:_)},[]),u=x.useCallback(function(b){var y=b;if(!(!Xs.length||Xs[Xs.length-1]!==o)){var w="deltaY"in y?VE(y):od(y),S=t.current.filter(function(P){return P.name===y.type&&(P.target===y.target||y.target===P.shadowParent)&&b7(P.delta,w)})[0];if(S&&S.should){y.cancelable&&y.preventDefault();return}if(!S){var E=(a.current.shards||[]).map(BE).filter(Boolean).filter(function(P){return P.contains(y.target)}),_=E.length>0?s(y,E[0]):!a.current.noIsolation;_&&y.cancelable&&y.preventDefault()}}},[]),c=x.useCallback(function(b,y,w,S){var E={name:b,delta:y,target:w,should:S,shadowParent:C7(w)};t.current.push(E),setTimeout(function(){t.current=t.current.filter(function(_){return _!==E})},1)},[]),f=x.useCallback(function(b){n.current=od(b),r.current=void 0},[]),p=x.useCallback(function(b){c(b.type,VE(b),b.target,s(b,e.lockRef.current))},[]),g=x.useCallback(function(b){c(b.type,od(b),b.target,s(b,e.lockRef.current))},[]);x.useEffect(function(){return Xs.push(o),e.setCallbacks({onScrollCapture:p,onWheelCapture:p,onTouchMoveCapture:g}),document.addEventListener("wheel",u,Ys),document.addEventListener("touchmove",u,Ys),document.addEventListener("touchstart",f,Ys),function(){Xs=Xs.filter(function(b){return b!==o}),document.removeEventListener("wheel",u,Ys),document.removeEventListener("touchmove",u,Ys),document.removeEventListener("touchstart",f,Ys)}},[]);var h=e.removeScrollBar,v=e.inert;return x.createElement(x.Fragment,null,v?x.createElement(o,{styles:x7(i)}):null,h?x.createElement(f7,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function C7(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const E7=Q9(Rk,S7);var c0=x.forwardRef(function(e,t){return x.createElement(Sh,Ii({},e,{ref:t,sideCar:E7}))});c0.classNames=Sh.classNames;var _7=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Zs=new WeakMap,ad=new WeakMap,sd={},Qm=0,Mk=function(e){return e&&(e.host||Mk(e.parentNode))},O7=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=Mk(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})},P7=function(e,t,n,r){var i=O7(t,Array.isArray(e)?e:[e]);sd[n]||(sd[n]=new WeakMap);var o=sd[n],a=[],s=new Set,u=new Set(i),c=function(p){!p||s.has(p)||(s.add(p),c(p.parentNode))};i.forEach(c);var f=function(p){!p||u.has(p)||Array.prototype.forEach.call(p.children,function(g){if(s.has(g))f(g);else try{var h=g.getAttribute(r),v=h!==null&&h!=="false",b=(Zs.get(g)||0)+1,y=(o.get(g)||0)+1;Zs.set(g,b),o.set(g,y),a.push(g),b===1&&v&&ad.set(g,!0),y===1&&g.setAttribute(n,"true"),v||g.setAttribute(r,"true")}catch(w){console.error("aria-hidden: cannot operate on ",g,w)}})};return f(t),s.clear(),Qm++,function(){a.forEach(function(p){var g=Zs.get(p)-1,h=o.get(p)-1;Zs.set(p,g),o.set(p,h),g||(ad.has(p)||p.removeAttribute(r),ad.delete(p)),h||p.removeAttribute(n)}),Qm--,Qm||(Zs=new WeakMap,Zs=new WeakMap,ad=new WeakMap,sd={})}},Dk=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),i=_7(e);return i?(r.push.apply(r,Array.from(i.querySelectorAll("[aria-live], script"))),P7(r,i,n,"aria-hidden")):function(){return null}},Ch="Dialog",[jk]=gi(Ch),[A7,vi]=jk(Ch),Lk=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:o,modal:a=!0}=e,s=x.useRef(null),u=x.useRef(null),[c,f]=go({prop:r,defaultProp:i??!1,onChange:o,caller:Ch});return O.jsx(A7,{scope:t,triggerRef:s,contentRef:u,contentId:fo(),titleId:fo(),descriptionId:fo(),open:c,onOpenChange:f,onOpenToggle:x.useCallback(()=>f(p=>!p),[f]),modal:a,children:n})};Lk.displayName=Ch;var $k="DialogTrigger",Fk=x.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=vi($k,n),o=bt(t,i.triggerRef);return O.jsx(Qe.button,{type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":p0(i.open),...r,ref:o,onClick:Ke(e.onClick,i.onOpenToggle)})});Fk.displayName=$k;var f0="DialogPortal",[R7,Vk]=jk(f0,{forceMount:void 0}),Bk=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:i}=e,o=vi(f0,t);return O.jsx(R7,{scope:t,forceMount:n,children:x.Children.map(r,a=>O.jsx(Co,{present:n||o.open,children:O.jsx(wh,{asChild:!0,container:i,children:a})}))})};Bk.displayName=f0;var tp="DialogOverlay",zk=x.forwardRef((e,t)=>{const n=Vk(tp,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,o=vi(tp,e.__scopeDialog);return o.modal?O.jsx(Co,{present:r||o.open,children:O.jsx(T7,{...i,ref:t})}):null});zk.displayName=tp;var I7=Hu("DialogOverlay.RemoveScroll"),T7=x.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=vi(tp,n);return O.jsx(c0,{as:I7,allowPinchZoom:!0,shards:[i.contentRef],children:O.jsx(Qe.div,{"data-state":p0(i.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),os="DialogContent",Wk=x.forwardRef((e,t)=>{const n=Vk(os,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,o=vi(os,e.__scopeDialog);return O.jsx(Co,{present:r||o.open,children:o.modal?O.jsx(k7,{...i,ref:t}):O.jsx(N7,{...i,ref:t})})});Wk.displayName=os;var k7=x.forwardRef((e,t)=>{const n=vi(os,e.__scopeDialog),r=x.useRef(null),i=bt(t,n.contentRef,r);return x.useEffect(()=>{const o=r.current;if(o)return Dk(o)},[]),O.jsx(Hk,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Ke(e.onCloseAutoFocus,o=>{o.preventDefault(),n.triggerRef.current?.focus()}),onPointerDownOutside:Ke(e.onPointerDownOutside,o=>{const a=o.detail.originalEvent,s=a.button===0&&a.ctrlKey===!0;(a.button===2||s)&&o.preventDefault()}),onFocusOutside:Ke(e.onFocusOutside,o=>o.preventDefault())})}),N7=x.forwardRef((e,t)=>{const n=vi(os,e.__scopeDialog),r=x.useRef(!1),i=x.useRef(!1);return O.jsx(Hk,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:o=>{e.onCloseAutoFocus?.(o),o.defaultPrevented||(r.current||n.triggerRef.current?.focus(),o.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:o=>{e.onInteractOutside?.(o),o.defaultPrevented||(r.current=!0,o.detail.originalEvent.type==="pointerdown"&&(i.current=!0));const a=o.target;n.triggerRef.current?.contains(a)&&o.preventDefault(),o.detail.originalEvent.type==="focusin"&&i.current&&o.preventDefault()}})}),Hk=x.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:o,...a}=e,s=vi(os,n),u=x.useRef(null),c=bt(t,u);return Ok(),O.jsxs(O.Fragment,{children:[O.jsx(u0,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:o,children:O.jsx(xh,{role:"dialog",id:s.contentId,"aria-describedby":s.descriptionId,"aria-labelledby":s.titleId,"data-state":p0(s.open),...a,ref:c,onDismiss:()=>s.onOpenChange(!1)})}),O.jsxs(O.Fragment,{children:[O.jsx(M7,{titleId:s.titleId}),O.jsx(j7,{contentRef:u,descriptionId:s.descriptionId})]})]})}),d0="DialogTitle",Uk=x.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=vi(d0,n);return O.jsx(Qe.h2,{id:i.titleId,...r,ref:t})});Uk.displayName=d0;var Gk="DialogDescription",qk=x.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=vi(Gk,n);return O.jsx(Qe.p,{id:i.descriptionId,...r,ref:t})});qk.displayName=Gk;var Kk="DialogClose",Yk=x.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=vi(Kk,n);return O.jsx(Qe.button,{type:"button",...r,ref:t,onClick:Ke(e.onClick,()=>i.onOpenChange(!1))})});Yk.displayName=Kk;function p0(e){return e?"open":"closed"}var Xk="DialogTitleWarning",[dve,Zk]=NU(Xk,{contentName:os,titleName:d0,docsSlug:"dialog"}),M7=({titleId:e})=>{const t=Zk(Xk),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
|
|
144
144
|
|
|
145
145
|
If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
|
|
146
146
|
|
|
147
|
-
For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return x.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},
|
|
148
|
-
hover:text-primary-inverse-text`,false:"text-secondary-text hover:bg-primary-hover-bg hover:text-primary-text"}},defaultVariants:{collapsed:!1,active:!1}}),
|
|
147
|
+
For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return x.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},D7="DialogDescriptionWarning",j7=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${Zk(D7).contentName}}.`;return x.useEffect(()=>{const i=e.current?.getAttribute("aria-describedby");t&&i&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},L7=Lk,$7=Fk,F7=Bk,Qk=zk,Jk=Wk,eN=Uk,tN=qk,nN=Yk;const V7=["data-open:animate-in data-closed:animate-out data-closed:fade-out-0","data-open:fade-in-0 duration-100","bg-primary-inverse-bg/20 fixed inset-0 isolate z-30"],B7=["fixed left-[50%] top-[50%] z-50 grid translate-x-[-50%]","translate-y-[-50%] gap-8 bg-primary-bg p-6 shadow-[0px_10px_40px_0px_rgba(0,0,0,0.15)] duration-200","rounded-[8px] w-max","[&>[data-base-ui-portal]]:absolute [&>[data-base-ui-portal]]:h-0 [&>[data-base-ui-portal]]:w-0 [&>[data-base-ui-portal]]:overflow-visible","data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0","data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95","data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%]"],z7=["absolute cursor-pointer right-6 top-7 inline-flex size-5 items-center justify-center rounded-sm text-secondary-text","focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-inp-focus-border","disabled:pointer-events-none"],W7=["flex flex-col gap-1.5 pr-10 text-left"],H7=["flex flex-col-reverse sm:flex-row sm:justify-end gap-4 [&>*]:flex-1"],U7=["relative pb-3 tracking-normal text-lg font-medium text-primary-text","after:pointer-events-none after:absolute after:bottom-0 after:h-px after:-left-6 after:-right-16 after:bg-delicate-border"],G7=["tracking-normal text-sm font-normal text-secondary-text"],rN=L7,q7=$7,iN=F7,K7=nN,h0=({className:e,...t})=>O.jsx(Qk,{className:ae(...V7,e),...t});h0.displayName=Qk.displayName;const g0=({className:e,children:t,showCloseButton:n=!0,...r})=>O.jsxs(iN,{children:[O.jsx(h0,{}),O.jsxs(Jk,{className:ae(...B7,e),...r,children:[t,n&&O.jsxs(nN,{className:ae(...z7),children:[O.jsx(ji,{type:"close",viewBox:"3.2 3.2 17.1 17.1"}),O.jsx("span",{className:"sr-only",children:"Close"})]})]})]});g0.displayName=Jk.displayName;const m0=({className:e,...t})=>O.jsx("div",{className:ae(...W7,e),...t});m0.displayName="DialogHeader";const v0=({className:e,...t})=>O.jsx("div",{className:ae(...H7,e),...t});v0.displayName="DialogFooter";const y0=({className:e,...t})=>O.jsx(eN,{className:ae(...U7,e),...t});y0.displayName=eN.displayName;const oN=({className:e,...t})=>O.jsx(tN,{className:ae(...G7,e),...t});oN.displayName=tN.displayName;const Y7=St(["flex h-9 w-full cursor-pointer items-center rounded-xl transition-colors","disabled:pointer-events-none disabled:opacity-50"].join(" "),{variants:{collapsed:{true:"justify-center px-0",false:"justify-start gap-3 px-2"},active:{true:`bg-primary-inverse-bg text-primary-inverse-text hover:bg-primary-inverse-bg
|
|
148
|
+
hover:text-primary-inverse-text`,false:"text-secondary-text hover:bg-primary-hover-bg hover:text-primary-text"}},defaultVariants:{collapsed:!1,active:!1}}),X7=dn("body-sm-medium"),aN=({icon:e,label:t,badge:n,active:r=!1,collapsed:i=!1,disabled:o=!1,onAction:a,className:s,...u})=>{const c=ae(Y7({active:r,collapsed:i}),o&&"pointer-events-none opacity-50",s),f=O.jsxs(O.Fragment,{children:[O.jsx("span",{className:"shrink-0 text-inherit [&_svg]:size-5 [&_svg]:shrink-0",children:e}),!i&&t&&O.jsx("span",{className:X7,children:t}),!i&&n&&O.jsx("span",{className:"ml-auto shrink-0",children:n})]});if("href"in u&&typeof u.href=="string"){const{href:h,rel:v,target:b,...y}=u,w=b==="_blank"?[v,"noopener","noreferrer"].filter(Boolean).join(" "):v;return O.jsx("a",{href:h,target:b,rel:w,"aria-disabled":o||void 0,tabIndex:o?-1:void 0,className:c,onClick:S=>{if(o){S.preventDefault();return}a?.()},...y,children:f})}const{type:p="button",...g}=u;return O.jsx("button",{type:p,disabled:o,className:c,onClick:()=>a?.(),...g,children:f})},Z7=St("px-2.5 py-3",{variants:{divider:{true:"",false:""}},defaultVariants:{divider:!1}}),Q7=[dn("body-xs-medium"),"mb-1 px-2 text-secondary-text uppercase"].join(" "),sN=({title:e,divider:t=!1,collapsed:n=!1,className:r,children:i,...o})=>O.jsxs("section",{className:ae(Z7({divider:t}),r),...o,children:[!n&&e&&O.jsx("p",{className:Q7,children:e}),O.jsx("div",{className:"space-y-1",children:i})]}),b0=({className:e,...t})=>O.jsx("nav",{role:"navigation","aria-label":"pagination",className:ae("mx-auto flex w-full justify-center",e),...t});b0.displayName="Pagination";const x0=({className:e,ref:t,...n})=>O.jsx("ul",{ref:t,className:ae("flex flex-row items-center gap-1",e),...n});x0.displayName="PaginationContent";const sl=({className:e,ref:t,...n})=>O.jsx("li",{ref:t,className:ae("",e),...n});sl.displayName="PaginationItem";const vc=({className:e,isActive:t,size:n=null,...r})=>O.jsx("a",{"aria-current":t?"page":void 0,className:ae(bx({size:n}),e),...r});vc.displayName="PaginationLink";const lN=({className:e,...t})=>O.jsxs(vc,{"aria-label":"Go to previous page",size:"md",className:ae("gap-1 pl-2.5",e),...t,children:[O.jsx(bI,{className:"h-4 w-4"}),O.jsx("span",{children:"Previous"})]});lN.displayName="PaginationPrevious";const uN=({className:e,...t})=>O.jsxs(vc,{"aria-label":"Go to next page",size:"md",className:ae("gap-1 pr-2.5",e),...t,children:[O.jsx("span",{children:"Next"}),O.jsx(xI,{className:"h-4 w-4"})]});uN.displayName="PaginationNext";const cN=({className:e,...t})=>O.jsxs("span",{"aria-hidden":!0,className:ae("flex h-9 w-9 items-center justify-center",e),...t,children:[O.jsx(wI,{className:"h-4 w-4"}),O.jsx("span",{className:"sr-only",children:"More pages"})]});cN.displayName="PaginationEllipsis";function J7(e,t=[]){let n=[];function r(o,a){const s=x.createContext(a);s.displayName=o+"Context";const u=n.length;n=[...n,a];const c=p=>{const{scope:g,children:h,...v}=p,b=g?.[e]?.[u]||s,y=x.useMemo(()=>v,Object.values(v));return O.jsx(b.Provider,{value:y,children:h})};c.displayName=o+"Provider";function f(p,g){const h=g?.[e]?.[u]||s,v=x.useContext(h);if(v)return v;if(a!==void 0)return a;throw new Error(`\`${p}\` must be used within \`${o}\``)}return[c,f]}const i=()=>{const o=n.map(a=>x.createContext(a));return function(s){const u=s?.[e]||o;return x.useMemo(()=>({[`__scope${e}`]:{...s,[e]:u}}),[s,u])}};return i.scopeName=e,[r,eY(i,...t)]}function eY(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(o){const a=r.reduce((s,{useScope:u,scopeName:c})=>{const p=u(o)[`__scope${c}`];return{...s,...p}},{});return x.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}var w0="Progress",S0=100,[tY]=J7(w0),[nY,rY]=tY(w0),fN=x.forwardRef((e,t)=>{const{__scopeProgress:n,value:r=null,max:i,getValueLabel:o=iY,...a}=e;(i||i===0)&&!zE(i)&&console.error(oY(`${i}`,"Progress"));const s=zE(i)?i:S0;r!==null&&!WE(r,s)&&console.error(aY(`${r}`,"Progress"));const u=WE(r,s)?r:null,c=np(u)?o(u,s):void 0;return O.jsx(nY,{scope:n,value:u,max:s,children:O.jsx(mh.div,{"aria-valuemax":s,"aria-valuemin":0,"aria-valuenow":np(u)?u:void 0,"aria-valuetext":c,role:"progressbar","data-state":hN(u,s),"data-value":u??void 0,"data-max":s,...a,ref:t})})});fN.displayName=w0;var dN="ProgressIndicator",pN=x.forwardRef((e,t)=>{const{__scopeProgress:n,...r}=e,i=rY(dN,n);return O.jsx(mh.div,{"data-state":hN(i.value,i.max),"data-value":i.value??void 0,"data-max":i.max,...r,ref:t})});pN.displayName=dN;function iY(e,t){return`${Math.round(e/t*100)}%`}function hN(e,t){return e==null?"indeterminate":e===t?"complete":"loading"}function np(e){return typeof e=="number"}function zE(e){return np(e)&&!isNaN(e)&&e>0}function WE(e,t){return np(e)&&!isNaN(e)&&e<=t&&e>=0}function oY(e,t){return`Invalid prop \`max\` of value \`${e}\` supplied to \`${t}\`. Only numbers greater than 0 are valid max values. Defaulting to \`${S0}\`.`}function aY(e,t){return`Invalid prop \`value\` of value \`${e}\` supplied to \`${t}\`. The \`value\` prop must be:
|
|
149
149
|
- a positive number
|
|
150
|
-
- less than the value passed to \`max\` (or ${
|
|
150
|
+
- less than the value passed to \`max\` (or ${S0} if no \`max\` prop is set)
|
|
151
151
|
- \`null\` or \`undefined\` if the progress is indeterminate.
|
|
152
152
|
|
|
153
|
-
Defaulting to \`null\`.`}var Gk=zk,r7=Hk;const qk=({className:e,value:t=0,max:n=100,ref:r,...i})=>{const o=Math.min(n,Math.max(0,Number(t))),a=o/n*100,s=a>=100,u=`${Math.round(a)}%`;return P.jsxs("div",{className:"flex items-center gap-1",children:[P.jsx(Gk,{ref:r,value:o,max:n,className:ue("bg-primary-inverse-bg/20 relative h-1.5 w-full overflow-hidden rounded-full",e),...i,children:P.jsx(r7,{className:ue("h-full w-full flex-1 rounded-[0.75rem] transition-all",s?"bg-success-text":"bg-primary-inverse-bg"),style:{transform:`translateX(-${n-a}%)`}})}),P.jsx("p",{className:ue("text-center",dn("body-xs-regular"),s?"text-success-text":"text-primary-text"),children:u})]})};qk.displayName=Gk.displayName;function i7(e){const t=e+"CollectionProvider",[n,r]=Fi(t),[i,o]=n(t,{collectionRef:{current:null},itemMap:new Map}),a=b=>{const{scope:y,children:w}=b,C=j.useRef(null),E=j.useRef(new Map).current;return P.jsx(i,{scope:y,itemMap:E,collectionRef:C,children:w})};a.displayName=t;const s=e+"CollectionSlot",u=Nd(s),c=j.forwardRef((b,y)=>{const{scope:w,children:C}=b,E=o(s,w),_=Zt(y,E.collectionRef);return P.jsx(u,{ref:_,children:C})});c.displayName=s;const d=e+"CollectionItemSlot",p="data-radix-collection-item",g=Nd(d),h=j.forwardRef((b,y)=>{const{scope:w,children:C,...E}=b,_=j.useRef(null),O=Zt(y,_),R=o(d,w);return j.useEffect(()=>(R.itemMap.set(_,{ref:_,...E}),()=>{R.itemMap.delete(_)})),P.jsx(g,{[p]:"",ref:O,children:C})});h.displayName=d;function v(b){const y=o(e+"CollectionConsumer",b);return j.useCallback(()=>{const C=y.collectionRef.current;if(!C)return[];const E=Array.from(C.querySelectorAll(`[${p}]`));return Array.from(y.itemMap.values()).sort((R,I)=>E.indexOf(R.ref.current)-E.indexOf(I.ref.current))},[y.collectionRef,y.itemMap])}return[{Provider:a,Slot:c,ItemSlot:h},v,r]}var o7=x.createContext(void 0);function rx(e){const t=x.useContext(o7);return e||t||"ltr"}var Lm="rovingFocusGroup.onEntryFocus",a7={bubbles:!1,cancelable:!0},cc="RovingFocusGroup",[zy,Kk,s7]=i7(cc),[l7,ph]=Fi(cc,[s7]),[u7,c7]=l7(cc),Yk=x.forwardRef((e,t)=>P.jsx(zy.Provider,{scope:e.__scopeRovingFocusGroup,children:P.jsx(zy.Slot,{scope:e.__scopeRovingFocusGroup,children:P.jsx(f7,{...e,ref:t})})}));Yk.displayName=cc;var f7=x.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:i=!1,dir:o,currentTabStopId:a,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:u,onEntryFocus:c,preventScrollOnEntryFocus:d=!1,...p}=e,g=x.useRef(null),h=Zt(t,g),v=rx(o),[b,y]=us({prop:a,defaultProp:s??null,onChange:u,caller:cc}),[w,C]=x.useState(!1),E=Ja(c),_=Kk(n),O=x.useRef(!1),[R,I]=x.useState(0);return x.useEffect(()=>{const k=g.current;if(k)return k.addEventListener(Lm,E),()=>k.removeEventListener(Lm,E)},[E]),P.jsx(u7,{scope:n,orientation:r,dir:v,loop:i,currentTabStopId:b,onItemFocus:x.useCallback(k=>y(k),[y]),onItemShiftTab:x.useCallback(()=>C(!0),[]),onFocusableItemAdd:x.useCallback(()=>I(k=>k+1),[]),onFocusableItemRemove:x.useCallback(()=>I(k=>k-1),[]),children:P.jsx(wt.div,{tabIndex:w||R===0?-1:0,"data-orientation":r,...p,ref:h,style:{outline:"none",...e.style},onMouseDown:bt(e.onMouseDown,()=>{O.current=!0}),onFocus:bt(e.onFocus,k=>{const B=!O.current;if(k.target===k.currentTarget&&B&&!w){const L=new CustomEvent(Lm,a7);if(k.currentTarget.dispatchEvent(L),!L.defaultPrevented){const V=_().filter(G=>G.focusable),D=V.find(G=>G.active),H=V.find(G=>G.id===b),te=[D,H,...V].filter(Boolean).map(G=>G.ref.current);Qk(te,d)}}O.current=!1}),onBlur:bt(e.onBlur,()=>C(!1))})})}),Xk="RovingFocusGroupItem",Zk=x.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:i=!1,tabStopId:o,children:a,...s}=e,u=sl(),c=o||u,d=c7(Xk,n),p=d.currentTabStopId===c,g=Kk(n),{onFocusableItemAdd:h,onFocusableItemRemove:v,currentTabStopId:b}=d;return x.useEffect(()=>{if(r)return h(),()=>v()},[r,h,v]),P.jsx(zy.ItemSlot,{scope:n,id:c,focusable:r,active:i,children:P.jsx(wt.span,{tabIndex:p?0:-1,"data-orientation":d.orientation,...s,ref:t,onMouseDown:bt(e.onMouseDown,y=>{r?d.onItemFocus(c):y.preventDefault()}),onFocus:bt(e.onFocus,()=>d.onItemFocus(c)),onKeyDown:bt(e.onKeyDown,y=>{if(y.key==="Tab"&&y.shiftKey){d.onItemShiftTab();return}if(y.target!==y.currentTarget)return;const w=h7(y,d.orientation,d.dir);if(w!==void 0){if(y.metaKey||y.ctrlKey||y.altKey||y.shiftKey)return;y.preventDefault();let E=g().filter(_=>_.focusable).map(_=>_.ref.current);if(w==="last")E.reverse();else if(w==="prev"||w==="next"){w==="prev"&&E.reverse();const _=E.indexOf(y.currentTarget);E=d.loop?g7(E,_+1):E.slice(_+1)}setTimeout(()=>Qk(E))}}),children:typeof a=="function"?a({isCurrentTabStop:p,hasTabStop:b!=null}):a})})});Zk.displayName=Xk;var d7={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function p7(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function h7(e,t,n){const r=p7(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return d7[r]}function Qk(e,t=!1){const n=document.activeElement;for(const r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function g7(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var Jk=Yk,eN=Zk,ix="Radio",[m7,tN]=Fi(ix),[v7,y7]=m7(ix),nN=x.forwardRef((e,t)=>{const{__scopeRadio:n,name:r,checked:i=!1,required:o,disabled:a,value:s="on",onCheck:u,form:c,...d}=e,[p,g]=x.useState(null),h=Zt(t,y=>g(y)),v=x.useRef(!1),b=p?c||!!p.closest("form"):!0;return P.jsxs(v7,{scope:n,checked:i,disabled:a,children:[P.jsx(wt.button,{type:"button",role:"radio","aria-checked":i,"data-state":aN(i),"data-disabled":a?"":void 0,disabled:a,value:s,...d,ref:h,onClick:bt(e.onClick,y=>{i||u?.(),b&&(v.current=y.isPropagationStopped(),v.current||y.stopPropagation())})}),b&&P.jsx(oN,{control:p,bubbles:!v.current,name:r,value:s,checked:i,required:o,disabled:a,form:c,style:{transform:"translateX(-100%)"}})]})});nN.displayName=ix;var rN="RadioIndicator",iN=x.forwardRef((e,t)=>{const{__scopeRadio:n,forceMount:r,...i}=e,o=y7(rN,n);return P.jsx(yo,{present:r||o.checked,children:P.jsx(wt.span,{"data-state":aN(o.checked),"data-disabled":o.disabled?"":void 0,...i,ref:t})})});iN.displayName=rN;var b7="RadioBubbleInput",oN=x.forwardRef(({__scopeRadio:e,control:t,checked:n,bubbles:r=!0,...i},o)=>{const a=x.useRef(null),s=Zt(a,o),u=Jb(n),c=Gp(t);return x.useEffect(()=>{const d=a.current;if(!d)return;const p=window.HTMLInputElement.prototype,h=Object.getOwnPropertyDescriptor(p,"checked").set;if(u!==n&&h){const v=new Event("click",{bubbles:r});h.call(d,n),d.dispatchEvent(v)}},[u,n,r]),P.jsx(wt.input,{type:"radio","aria-hidden":!0,defaultChecked:n,...i,tabIndex:-1,ref:s,style:{...i.style,...c,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});oN.displayName=b7;function aN(e){return e?"checked":"unchecked"}var x7=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],hh="RadioGroup",[w7]=Fi(hh,[ph,tN]),sN=ph(),lN=tN(),[C7,S7]=w7(hh),uN=x.forwardRef((e,t)=>{const{__scopeRadioGroup:n,name:r,defaultValue:i,value:o,required:a=!1,disabled:s=!1,orientation:u,dir:c,loop:d=!0,onValueChange:p,...g}=e,h=sN(n),v=rx(c),[b,y]=us({prop:o,defaultProp:i??null,onChange:p,caller:hh});return P.jsx(C7,{scope:n,name:r,required:a,disabled:s,value:b,onValueChange:y,children:P.jsx(Jk,{asChild:!0,...h,orientation:u,dir:v,loop:d,children:P.jsx(wt.div,{role:"radiogroup","aria-required":a,"aria-orientation":u,"data-disabled":s?"":void 0,dir:v,...g,ref:t})})})});uN.displayName=hh;var cN="RadioGroupItem",fN=x.forwardRef((e,t)=>{const{__scopeRadioGroup:n,disabled:r,...i}=e,o=S7(cN,n),a=o.disabled||r,s=sN(n),u=lN(n),c=x.useRef(null),d=Zt(t,c),p=o.value===i.value,g=x.useRef(!1);return x.useEffect(()=>{const h=b=>{x7.includes(b.key)&&(g.current=!0)},v=()=>g.current=!1;return document.addEventListener("keydown",h),document.addEventListener("keyup",v),()=>{document.removeEventListener("keydown",h),document.removeEventListener("keyup",v)}},[]),P.jsx(eN,{asChild:!0,...s,focusable:!a,active:p,children:P.jsx(nN,{disabled:a,required:o.required,checked:p,...u,...i,name:o.name,ref:d,onCheck:()=>o.onValueChange(i.value),onKeyDown:bt(h=>{h.key==="Enter"&&h.preventDefault()}),onFocus:bt(i.onFocus,()=>{g.current&&c.current?.click()})})})});fN.displayName=cN;var E7="RadioGroupIndicator",dN=x.forwardRef((e,t)=>{const{__scopeRadioGroup:n,...r}=e,i=lN(n);return P.jsx(iN,{...i,...r,ref:t})});dN.displayName=E7;var pN=uN,hN=fN,_7=dN;const O7=["grid gap-2"],P7=["group size-5 cursor-pointer place-content-center rounded-full border transition-colors duration-200","border-inp-hover-border bg-primary-bg","data-[state=checked]:border-primary-text","enabled:hover:border-inp-hover-border enabled:hover:bg-tertiary-bg","enabled:hover:data-[state=checked]:border-inp-hover-border enabled:hover:data-[state=checked]:bg-tertiary-bg","disabled:cursor-not-allowed disabled:border-disabled-border disabled:bg-disabled-bg","disabled:data-[state=checked]:border-disabled-border disabled:data-[state=checked]:bg-disabled-bg","focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-inp-focus-border"],A7=["flex items-center justify-center"],R7=["size-2.5 rounded-full bg-primary-text transition-colors duration-200","group-hover:bg-secondary-text","group-disabled:bg-disabled-text"],ox=({className:e,ref:t,...n})=>P.jsx(pN,{className:ue(O7,e),...n,ref:t});ox.displayName=pN.displayName;const Xd=({className:e,ref:t,...n})=>P.jsx(hN,{ref:t,className:ue(P7,e),...n,children:P.jsx(_7,{className:ue(A7),children:P.jsx("span",{className:ue(R7)})})});Xd.displayName=hN.displayName;var gh="Switch",[I7]=Fi(gh),[T7,k7]=I7(gh),gN=x.forwardRef((e,t)=>{const{__scopeSwitch:n,name:r,checked:i,defaultChecked:o,required:a,disabled:s,value:u="on",onCheckedChange:c,form:d,...p}=e,[g,h]=x.useState(null),v=Zt(t,E=>h(E)),b=x.useRef(!1),y=g?d||!!g.closest("form"):!0,[w,C]=us({prop:i,defaultProp:o??!1,onChange:c,caller:gh});return P.jsxs(T7,{scope:n,checked:w,disabled:s,children:[P.jsx(wt.button,{type:"button",role:"switch","aria-checked":w,"aria-required":a,"data-state":bN(w),"data-disabled":s?"":void 0,disabled:s,value:u,...p,ref:v,onClick:bt(e.onClick,E=>{C(_=>!_),y&&(b.current=E.isPropagationStopped(),b.current||E.stopPropagation())})}),y&&P.jsx(yN,{control:g,bubbles:!b.current,name:r,value:u,checked:w,required:a,disabled:s,form:d,style:{transform:"translateX(-100%)"}})]})});gN.displayName=gh;var mN="SwitchThumb",vN=x.forwardRef((e,t)=>{const{__scopeSwitch:n,...r}=e,i=k7(mN,n);return P.jsx(wt.span,{"data-state":bN(i.checked),"data-disabled":i.disabled?"":void 0,...r,ref:t})});vN.displayName=mN;var N7="SwitchBubbleInput",yN=x.forwardRef(({__scopeSwitch:e,control:t,checked:n,bubbles:r=!0,...i},o)=>{const a=x.useRef(null),s=Zt(a,o),u=Jb(n),c=Gp(t);return x.useEffect(()=>{const d=a.current;if(!d)return;const p=window.HTMLInputElement.prototype,h=Object.getOwnPropertyDescriptor(p,"checked").set;if(u!==n&&h){const v=new Event("click",{bubbles:r});h.call(d,n),d.dispatchEvent(v)}},[u,n,r]),P.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:n,...i,tabIndex:-1,ref:s,style:{...i.style,...c,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});yN.displayName=N7;function bN(e){return e?"checked":"unchecked"}var xN=gN,M7=vN;const D7=["peer group relative inline-flex h-6 w-12 shrink-0 cursor-pointer items-center rounded-full border p-1 transition-colors","border-inp-default-border bg-primary-bg","enabled:hover:border-inp-hover-border","data-[state=checked]:bg-primary-inverse-bg","data-[state=checked]:border-inp-default-border enabled:hover:data-[state=checked]:border-inp-hover-border","disabled:cursor-not-allowed disabled:border-disabled-border disabled:bg-disabled-bg","disabled:data-[state=checked]:border-disabled-border disabled:data-[state=checked]:bg-disabled-bg","focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-inp-focus-border"],j7=["pointer-events-none block size-4 rounded-full transition-transform","bg-primary-inverse-bg data-[state=checked]:translate-x-6 data-[state=checked]:bg-primary-bg","group-disabled:bg-disabled-text group-disabled:data-[state=checked]:bg-disabled-text"],wN=({className:e,ref:t,...n})=>P.jsx(xN,{className:ue(D7,e),...n,ref:t,children:P.jsx(M7,{className:ue(j7)})});wN.displayName=xN.displayName;const ax=({ref:e,className:t,...n})=>P.jsx("div",{className:"relative w-full overflow-auto",children:P.jsx("table",{ref:e,className:ue("w-full caption-bottom text-sm",t),...n})});ax.displayName="Table";const sx=({ref:e,className:t,...n})=>P.jsx("thead",{ref:e,className:ue("text-primary-text [&_tr]:border-b",t),...n});sx.displayName="TableHeader";const lx=({ref:e,className:t,...n})=>P.jsx("tbody",{ref:e,className:ue(t),...n});lx.displayName="TableBody";const CN=({ref:e,className:t,...n})=>P.jsx("tfoot",{ref:e,className:ue("bg-muted/50 border-t font-medium",t),...n});CN.displayName="TableFooter";const Mu=({ref:e,className:t,...n})=>P.jsx("tr",{ref:e,className:ue(`hover:bg-muted/50 data-[state=selected]:bg-muted border-delicate-border border-b
|
|
154
|
-
transition-colors`,t),...n});
|
|
155
|
-
[&:has([role=checkbox])]:pr-0 *:[[role=checkbox]]:translate-y-0.5`,t),...n});
|
|
156
|
-
*:[[role=checkbox]]:translate-y-0.5`,t),...n});
|
|
157
|
-
focus-visible:ring-offset-2 focus-visible:outline-none`,"data-[orientation=vertical]:flex-1",t),...n});VN.displayName=jN.displayName;var W7="Arrow",BN=x.forwardRef((e,t)=>{const{children:n,width:r=10,height:i=5,...o}=e;return P.jsx(wt.svg,{...o,ref:t,width:r,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:P.jsx("polygon",{points:"0,0 30,0 15,10"})})});BN.displayName=W7;var H7=BN,fx="Popper",[zN,WN]=Fi(fx),[U7,HN]=zN(fx),UN=e=>{const{__scopePopper:t,children:n}=e,[r,i]=x.useState(null);return P.jsx(U7,{scope:t,anchor:r,onAnchorChange:i,children:n})};UN.displayName=fx;var GN="PopperAnchor",qN=x.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...i}=e,o=HN(GN,n),a=x.useRef(null),s=Zt(t,a),u=x.useRef(null);return x.useEffect(()=>{const c=u.current;u.current=r?.current||a.current,c!==u.current&&o.onAnchorChange(u.current)}),r?null:P.jsx(wt.div,{...i,ref:s})});qN.displayName=GN;var dx="PopperContent",[G7,q7]=zN(dx),KN=x.forwardRef((e,t)=>{const{__scopePopper:n,side:r="bottom",sideOffset:i=0,align:o="center",alignOffset:a=0,arrowPadding:s=0,avoidCollisions:u=!0,collisionBoundary:c=[],collisionPadding:d=0,sticky:p="partial",hideWhenDetached:g=!1,updatePositionStrategy:h="optimized",onPlaced:v,...b}=e,y=HN(dx,n),[w,C]=x.useState(null),E=Zt(t,Ke=>C(Ke)),[_,O]=x.useState(null),R=Gp(_),I=R?.width??0,k=R?.height??0,B=r+(o!=="center"?"-"+o:""),L=typeof d=="number"?d:{top:0,right:0,bottom:0,left:0,...d},V=Array.isArray(c)?c:[c],D=V.length>0,H={padding:L,boundary:V.filter(Y7),altBoundary:D},{refs:J,floatingStyles:te,placement:G,isPositioned:ee,middlewareData:Q}=ZI({strategy:"fixed",placement:B,whileElementsMounted:(...Ke)=>My(...Ke,{animationFrame:h==="always"}),elements:{reference:y.anchor},middleware:[QI({mainAxis:i+k,alignmentAxis:a}),u&&JI({mainAxis:!0,crossAxis:!1,limiter:p==="partial"?eT():void 0,...H}),u&&tT({...H}),nT({...H,apply:({elements:Ke,rects:Fe,availableWidth:Y,availableHeight:oe})=>{const{width:ne,height:$}=Fe.reference,ie=Ke.floating.style;ie.setProperty("--radix-popper-available-width",`${Y}px`),ie.setProperty("--radix-popper-available-height",`${oe}px`),ie.setProperty("--radix-popper-anchor-width",`${ne}px`),ie.setProperty("--radix-popper-anchor-height",`${$}px`)}}),_&&Kq({element:_,padding:s}),X7({arrowWidth:I,arrowHeight:k}),g&&rT({strategy:"referenceHidden",...H})]}),[pe,K]=ZN(G),Ae=Ja(v);ia(()=>{ee&&Ae?.()},[ee,Ae]);const Se=Q.arrow?.x,$e=Q.arrow?.y,we=Q.arrow?.centerOffset!==0,[Ce,ze]=x.useState();return ia(()=>{w&&ze(window.getComputedStyle(w).zIndex)},[w]),P.jsx("div",{ref:J.setFloating,"data-radix-popper-content-wrapper":"",style:{...te,transform:ee?te.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Ce,"--radix-popper-transform-origin":[Q.transformOrigin?.x,Q.transformOrigin?.y].join(" "),...Q.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:P.jsx(G7,{scope:n,placedSide:pe,onArrowChange:O,arrowX:Se,arrowY:$e,shouldHideArrow:we,children:P.jsx(wt.div,{"data-side":pe,"data-align":K,...b,ref:E,style:{...b.style,animation:ee?void 0:"none"}})})})});KN.displayName=dx;var YN="PopperArrow",K7={top:"bottom",right:"left",bottom:"top",left:"right"},XN=x.forwardRef(function(t,n){const{__scopePopper:r,...i}=t,o=q7(YN,r),a=K7[o.placedSide];return P.jsx("span",{ref:o.onArrowChange,style:{position:"absolute",left:o.arrowX,top:o.arrowY,[a]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[o.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[o.placedSide],visibility:o.shouldHideArrow?"hidden":void 0},children:P.jsx(H7,{...i,ref:n,style:{...i.style,display:"block"}})})});XN.displayName=YN;function Y7(e){return e!==null}var X7=e=>({name:"transformOrigin",options:e,fn(t){const{placement:n,rects:r,middlewareData:i}=t,a=i.arrow?.centerOffset!==0,s=a?0:e.arrowWidth,u=a?0:e.arrowHeight,[c,d]=ZN(n),p={start:"0%",center:"50%",end:"100%"}[d],g=(i.arrow?.x??0)+s/2,h=(i.arrow?.y??0)+u/2;let v="",b="";return c==="bottom"?(v=a?p:`${g}px`,b=`${-u}px`):c==="top"?(v=a?p:`${g}px`,b=`${r.floating.height+u}px`):c==="right"?(v=`${-u}px`,b=a?p:`${h}px`):c==="left"&&(v=`${r.floating.width+u}px`,b=a?p:`${h}px`),{data:{x:v,y:b}}}});function ZN(e){const[t,n="center"]=e.split("-");return[t,n]}var Z7=UN,Q7=qN,J7=KN,eY=XN,tY=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),nY="VisuallyHidden",QN=x.forwardRef((e,t)=>P.jsx(wt.span,{...e,ref:t,style:{...tY,...e.style}}));QN.displayName=nY;var rY=QN,[vh]=Fi("Tooltip",[WN]),yh=WN(),JN="TooltipProvider",iY=700,Wy="tooltip.open",[oY,px]=vh(JN),eM=e=>{const{__scopeTooltip:t,delayDuration:n=iY,skipDelayDuration:r=300,disableHoverableContent:i=!1,children:o}=e,a=x.useRef(!0),s=x.useRef(!1),u=x.useRef(0);return x.useEffect(()=>{const c=u.current;return()=>window.clearTimeout(c)},[]),P.jsx(oY,{scope:t,isOpenDelayedRef:a,delayDuration:n,onOpen:x.useCallback(()=>{window.clearTimeout(u.current),a.current=!1},[]),onClose:x.useCallback(()=>{window.clearTimeout(u.current),u.current=window.setTimeout(()=>a.current=!0,r)},[r]),isPointerInTransitRef:s,onPointerInTransitChange:x.useCallback(c=>{s.current=c},[]),disableHoverableContent:i,children:o})};eM.displayName=JN;var Bu="Tooltip",[aY,fc]=vh(Bu),tM=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:i,onOpenChange:o,disableHoverableContent:a,delayDuration:s}=e,u=px(Bu,e.__scopeTooltip),c=yh(t),[d,p]=x.useState(null),g=sl(),h=x.useRef(0),v=a??u.disableHoverableContent,b=s??u.delayDuration,y=x.useRef(!1),[w,C]=us({prop:r,defaultProp:i??!1,onChange:I=>{I?(u.onOpen(),document.dispatchEvent(new CustomEvent(Wy))):u.onClose(),o?.(I)},caller:Bu}),E=x.useMemo(()=>w?y.current?"delayed-open":"instant-open":"closed",[w]),_=x.useCallback(()=>{window.clearTimeout(h.current),h.current=0,y.current=!1,C(!0)},[C]),O=x.useCallback(()=>{window.clearTimeout(h.current),h.current=0,C(!1)},[C]),R=x.useCallback(()=>{window.clearTimeout(h.current),h.current=window.setTimeout(()=>{y.current=!0,C(!0),h.current=0},b)},[b,C]);return x.useEffect(()=>()=>{h.current&&(window.clearTimeout(h.current),h.current=0)},[]),P.jsx(Z7,{...c,children:P.jsx(aY,{scope:t,contentId:g,open:w,stateAttribute:E,trigger:d,onTriggerChange:p,onTriggerEnter:x.useCallback(()=>{u.isOpenDelayedRef.current?R():_()},[u.isOpenDelayedRef,R,_]),onTriggerLeave:x.useCallback(()=>{v?O():(window.clearTimeout(h.current),h.current=0)},[O,v]),onOpen:_,onClose:O,disableHoverableContent:v,children:n})})};tM.displayName=Bu;var Hy="TooltipTrigger",nM=x.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,i=fc(Hy,n),o=px(Hy,n),a=yh(n),s=x.useRef(null),u=Zt(t,s,i.onTriggerChange),c=x.useRef(!1),d=x.useRef(!1),p=x.useCallback(()=>c.current=!1,[]);return x.useEffect(()=>()=>document.removeEventListener("pointerup",p),[p]),P.jsx(Q7,{asChild:!0,...a,children:P.jsx(wt.button,{"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute,...r,ref:u,onPointerMove:bt(e.onPointerMove,g=>{g.pointerType!=="touch"&&!d.current&&!o.isPointerInTransitRef.current&&(i.onTriggerEnter(),d.current=!0)}),onPointerLeave:bt(e.onPointerLeave,()=>{i.onTriggerLeave(),d.current=!1}),onPointerDown:bt(e.onPointerDown,()=>{i.open&&i.onClose(),c.current=!0,document.addEventListener("pointerup",p,{once:!0})}),onFocus:bt(e.onFocus,()=>{c.current||i.onOpen()}),onBlur:bt(e.onBlur,i.onClose),onClick:bt(e.onClick,i.onClose)})})});nM.displayName=Hy;var hx="TooltipPortal",[sY,lY]=vh(hx,{forceMount:void 0}),rM=e=>{const{__scopeTooltip:t,forceMount:n,children:r,container:i}=e,o=fc(hx,t);return P.jsx(sY,{scope:t,forceMount:n,children:P.jsx(yo,{present:n||o.open,children:P.jsx(H0,{asChild:!0,container:i,children:r})})})};rM.displayName=hx;var hl="TooltipContent",iM=x.forwardRef((e,t)=>{const n=lY(hl,e.__scopeTooltip),{forceMount:r=n.forceMount,side:i="top",...o}=e,a=fc(hl,e.__scopeTooltip);return P.jsx(yo,{present:r||a.open,children:a.disableHoverableContent?P.jsx(oM,{side:i,...o,ref:t}):P.jsx(uY,{side:i,...o,ref:t})})}),uY=x.forwardRef((e,t)=>{const n=fc(hl,e.__scopeTooltip),r=px(hl,e.__scopeTooltip),i=x.useRef(null),o=Zt(t,i),[a,s]=x.useState(null),{trigger:u,onClose:c}=n,d=i.current,{onPointerInTransitChange:p}=r,g=x.useCallback(()=>{s(null),p(!1)},[p]),h=x.useCallback((v,b)=>{const y=v.currentTarget,w={x:v.clientX,y:v.clientY},C=pY(w,y.getBoundingClientRect()),E=hY(w,C),_=gY(b.getBoundingClientRect()),O=vY([...E,..._]);s(O),p(!0)},[p]);return x.useEffect(()=>()=>g(),[g]),x.useEffect(()=>{if(u&&d){const v=y=>h(y,d),b=y=>h(y,u);return u.addEventListener("pointerleave",v),d.addEventListener("pointerleave",b),()=>{u.removeEventListener("pointerleave",v),d.removeEventListener("pointerleave",b)}}},[u,d,h,g]),x.useEffect(()=>{if(a){const v=b=>{const y=b.target,w={x:b.clientX,y:b.clientY},C=u?.contains(y)||d?.contains(y),E=!mY(w,a);C?g():E&&(g(),c())};return document.addEventListener("pointermove",v),()=>document.removeEventListener("pointermove",v)}},[u,d,a,c,g]),P.jsx(oM,{...e,ref:o})}),[cY,fY]=vh(Bu,{isInside:!1}),dY=$H("TooltipContent"),oM=x.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":i,onEscapeKeyDown:o,onPointerDownOutside:a,...s}=e,u=fc(hl,n),c=yh(n),{onClose:d}=u;return x.useEffect(()=>(document.addEventListener(Wy,d),()=>document.removeEventListener(Wy,d)),[d]),x.useEffect(()=>{if(u.trigger){const p=g=>{g.target?.contains(u.trigger)&&d()};return window.addEventListener("scroll",p,{capture:!0}),()=>window.removeEventListener("scroll",p,{capture:!0})}},[u.trigger,d]),P.jsx(W0,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:o,onPointerDownOutside:a,onFocusOutside:p=>p.preventDefault(),onDismiss:d,children:P.jsxs(J7,{"data-state":u.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)"},children:[P.jsx(dY,{children:r}),P.jsx(cY,{scope:n,isInside:!0,children:P.jsx(rY,{id:u.contentId,role:"tooltip",children:i||r})})]})})});iM.displayName=hl;var aM="TooltipArrow",sM=x.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,i=yh(n);return fY(aM,n).isInside?null:P.jsx(eY,{...i,...r,ref:t})});sM.displayName=aM;function pY(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),i=Math.abs(t.right-e.x),o=Math.abs(t.left-e.x);switch(Math.min(n,r,i,o)){case o:return"left";case i:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function hY(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 gY(e){const{top:t,right:n,bottom:r,left:i}=e;return[{x:i,y:t},{x:n,y:t},{x:n,y:r},{x:i,y:r}]}function mY(e,t){const{x:n,y:r}=e;let i=!1;for(let o=0,a=t.length-1;o<t.length;a=o++){const s=t[o],u=t[a],c=s.x,d=s.y,p=u.x,g=u.y;d>r!=g>r&&n<(p-c)*(r-d)/(g-d)+c&&(i=!i)}return i}function vY(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),yY(t)}function yY(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const i=e[r];for(;t.length>=2;){const o=t[t.length-1],a=t[t.length-2];if((o.x-a.x)*(i.y-a.y)>=(o.y-a.y)*(i.x-a.x))t.pop();else break}t.push(i)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const i=e[r];for(;n.length>=2;){const o=n[n.length-1],a=n[n.length-2];if((o.x-a.x)*(i.y-a.y)>=(o.y-a.y)*(i.x-a.x))n.pop();else break}n.push(i)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var bY=eM,xY=tM,wY=nM,CY=rM,lM=iM,SY=sM;const EY=`bg-primary text-primary-foreground animate-in fade-in-0 zoom-in-95
|
|
153
|
+
Defaulting to \`null\`.`}var gN=fN,sY=pN;const mN=({className:e,value:t=0,max:n=100,ref:r,...i})=>{const o=Math.min(n,Math.max(0,Number(t))),a=o/n*100,s=a>=100,u=`${Math.round(a)}%`;return O.jsxs("div",{className:"flex items-center gap-1",children:[O.jsx(gN,{ref:r,value:o,max:n,className:ae("bg-primary-inverse-bg/20 relative h-1.5 w-full overflow-hidden rounded-full",e),...i,children:O.jsx(sY,{className:ae("h-full w-full flex-1 rounded-[0.75rem] transition-all",s?"bg-success-text":"bg-primary-inverse-bg"),style:{transform:`translateX(-${n-a}%)`}})}),O.jsx("p",{className:ae("text-center",dn("body-xs-regular"),s?"text-success-text":"text-primary-text"),children:u})]})};mN.displayName=gN.displayName;function vN(e){const t=e+"CollectionProvider",[n,r]=gi(t),[i,o]=n(t,{collectionRef:{current:null},itemMap:new Map}),a=b=>{const{scope:y,children:w}=b,S=$.useRef(null),E=$.useRef(new Map).current;return O.jsx(i,{scope:y,itemMap:E,collectionRef:S,children:w})};a.displayName=t;const s=e+"CollectionSlot",u=Hu(s),c=$.forwardRef((b,y)=>{const{scope:w,children:S}=b,E=o(s,w),_=bt(y,E.collectionRef);return O.jsx(u,{ref:_,children:S})});c.displayName=s;const f=e+"CollectionItemSlot",p="data-radix-collection-item",g=Hu(f),h=$.forwardRef((b,y)=>{const{scope:w,children:S,...E}=b,_=$.useRef(null),P=bt(y,_),R=o(f,w);return $.useEffect(()=>(R.itemMap.set(_,{ref:_,...E}),()=>{R.itemMap.delete(_)})),O.jsx(g,{[p]:"",ref:P,children:S})});h.displayName=f;function v(b){const y=o(e+"CollectionConsumer",b);return $.useCallback(()=>{const S=y.collectionRef.current;if(!S)return[];const E=Array.from(S.querySelectorAll(`[${p}]`));return Array.from(y.itemMap.values()).sort((R,I)=>E.indexOf(R.ref.current)-E.indexOf(I.ref.current))},[y.collectionRef,y.itemMap])}return[{Provider:a,Slot:c,ItemSlot:h},v,r]}var lY=x.createContext(void 0);function Eh(e){const t=x.useContext(lY);return e||t||"ltr"}var Jm="rovingFocusGroup.onEntryFocus",uY={bubbles:!1,cancelable:!0},yc="RovingFocusGroup",[ib,yN,cY]=vN(yc),[fY,_h]=gi(yc,[cY]),[dY,pY]=fY(yc),bN=x.forwardRef((e,t)=>O.jsx(ib.Provider,{scope:e.__scopeRovingFocusGroup,children:O.jsx(ib.Slot,{scope:e.__scopeRovingFocusGroup,children:O.jsx(hY,{...e,ref:t})})}));bN.displayName=yc;var hY=x.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:i=!1,dir:o,currentTabStopId:a,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:u,onEntryFocus:c,preventScrollOnEntryFocus:f=!1,...p}=e,g=x.useRef(null),h=bt(t,g),v=Eh(o),[b,y]=go({prop:a,defaultProp:s??null,onChange:u,caller:yc}),[w,S]=x.useState(!1),E=ca(c),_=yN(n),P=x.useRef(!1),[R,I]=x.useState(0);return x.useEffect(()=>{const k=g.current;if(k)return k.addEventListener(Jm,E),()=>k.removeEventListener(Jm,E)},[E]),O.jsx(dY,{scope:n,orientation:r,dir:v,loop:i,currentTabStopId:b,onItemFocus:x.useCallback(k=>y(k),[y]),onItemShiftTab:x.useCallback(()=>S(!0),[]),onFocusableItemAdd:x.useCallback(()=>I(k=>k+1),[]),onFocusableItemRemove:x.useCallback(()=>I(k=>k-1),[]),children:O.jsx(Qe.div,{tabIndex:w||R===0?-1:0,"data-orientation":r,...p,ref:h,style:{outline:"none",...e.style},onMouseDown:Ke(e.onMouseDown,()=>{P.current=!0}),onFocus:Ke(e.onFocus,k=>{const B=!P.current;if(k.target===k.currentTarget&&B&&!w){const L=new CustomEvent(Jm,uY);if(k.currentTarget.dispatchEvent(L),!L.defaultPrevented){const V=_().filter(U=>U.focusable),D=V.find(U=>U.active),W=V.find(U=>U.id===b),re=[D,W,...V].filter(Boolean).map(U=>U.ref.current);SN(re,f)}}P.current=!1}),onBlur:Ke(e.onBlur,()=>S(!1))})})}),xN="RovingFocusGroupItem",wN=x.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:i=!1,tabStopId:o,children:a,...s}=e,u=fo(),c=o||u,f=pY(xN,n),p=f.currentTabStopId===c,g=yN(n),{onFocusableItemAdd:h,onFocusableItemRemove:v,currentTabStopId:b}=f;return x.useEffect(()=>{if(r)return h(),()=>v()},[r,h,v]),O.jsx(ib.ItemSlot,{scope:n,id:c,focusable:r,active:i,children:O.jsx(Qe.span,{tabIndex:p?0:-1,"data-orientation":f.orientation,...s,ref:t,onMouseDown:Ke(e.onMouseDown,y=>{r?f.onItemFocus(c):y.preventDefault()}),onFocus:Ke(e.onFocus,()=>f.onItemFocus(c)),onKeyDown:Ke(e.onKeyDown,y=>{if(y.key==="Tab"&&y.shiftKey){f.onItemShiftTab();return}if(y.target!==y.currentTarget)return;const w=vY(y,f.orientation,f.dir);if(w!==void 0){if(y.metaKey||y.ctrlKey||y.altKey||y.shiftKey)return;y.preventDefault();let E=g().filter(_=>_.focusable).map(_=>_.ref.current);if(w==="last")E.reverse();else if(w==="prev"||w==="next"){w==="prev"&&E.reverse();const _=E.indexOf(y.currentTarget);E=f.loop?yY(E,_+1):E.slice(_+1)}setTimeout(()=>SN(E))}}),children:typeof a=="function"?a({isCurrentTabStop:p,hasTabStop:b!=null}):a})})});wN.displayName=xN;var gY={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function mY(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function vY(e,t,n){const r=mY(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return gY[r]}function SN(e,t=!1){const n=document.activeElement;for(const r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function yY(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var CN=bN,EN=wN,C0="Radio",[bY,_N]=gi(C0),[xY,wY]=bY(C0),ON=x.forwardRef((e,t)=>{const{__scopeRadio:n,name:r,checked:i=!1,required:o,disabled:a,value:s="on",onCheck:u,form:c,...f}=e,[p,g]=x.useState(null),h=bt(t,y=>g(y)),v=x.useRef(!1),b=p?c||!!p.closest("form"):!0;return O.jsxs(xY,{scope:n,checked:i,disabled:a,children:[O.jsx(Qe.button,{type:"button",role:"radio","aria-checked":i,"data-state":IN(i),"data-disabled":a?"":void 0,disabled:a,value:s,...f,ref:h,onClick:Ke(e.onClick,y=>{i||u?.(),b&&(v.current=y.isPropagationStopped(),v.current||y.stopPropagation())})}),b&&O.jsx(RN,{control:p,bubbles:!v.current,name:r,value:s,checked:i,required:o,disabled:a,form:c,style:{transform:"translateX(-100%)"}})]})});ON.displayName=C0;var PN="RadioIndicator",AN=x.forwardRef((e,t)=>{const{__scopeRadio:n,forceMount:r,...i}=e,o=wY(PN,n);return O.jsx(Co,{present:r||o.checked,children:O.jsx(Qe.span,{"data-state":IN(o.checked),"data-disabled":o.disabled?"":void 0,...i,ref:t})})});AN.displayName=PN;var SY="RadioBubbleInput",RN=x.forwardRef(({__scopeRadio:e,control:t,checked:n,bubbles:r=!0,...i},o)=>{const a=x.useRef(null),s=bt(a,o),u=eh(n),c=th(t);return x.useEffect(()=>{const f=a.current;if(!f)return;const p=window.HTMLInputElement.prototype,h=Object.getOwnPropertyDescriptor(p,"checked").set;if(u!==n&&h){const v=new Event("click",{bubbles:r});h.call(f,n),f.dispatchEvent(v)}},[u,n,r]),O.jsx(Qe.input,{type:"radio","aria-hidden":!0,defaultChecked:n,...i,tabIndex:-1,ref:s,style:{...i.style,...c,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});RN.displayName=SY;function IN(e){return e?"checked":"unchecked"}var CY=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],Oh="RadioGroup",[EY]=gi(Oh,[_h,_N]),TN=_h(),kN=_N(),[_Y,OY]=EY(Oh),NN=x.forwardRef((e,t)=>{const{__scopeRadioGroup:n,name:r,defaultValue:i,value:o,required:a=!1,disabled:s=!1,orientation:u,dir:c,loop:f=!0,onValueChange:p,...g}=e,h=TN(n),v=Eh(c),[b,y]=go({prop:o,defaultProp:i??null,onChange:p,caller:Oh});return O.jsx(_Y,{scope:n,name:r,required:a,disabled:s,value:b,onValueChange:y,children:O.jsx(CN,{asChild:!0,...h,orientation:u,dir:v,loop:f,children:O.jsx(Qe.div,{role:"radiogroup","aria-required":a,"aria-orientation":u,"data-disabled":s?"":void 0,dir:v,...g,ref:t})})})});NN.displayName=Oh;var MN="RadioGroupItem",DN=x.forwardRef((e,t)=>{const{__scopeRadioGroup:n,disabled:r,...i}=e,o=OY(MN,n),a=o.disabled||r,s=TN(n),u=kN(n),c=x.useRef(null),f=bt(t,c),p=o.value===i.value,g=x.useRef(!1);return x.useEffect(()=>{const h=b=>{CY.includes(b.key)&&(g.current=!0)},v=()=>g.current=!1;return document.addEventListener("keydown",h),document.addEventListener("keyup",v),()=>{document.removeEventListener("keydown",h),document.removeEventListener("keyup",v)}},[]),O.jsx(EN,{asChild:!0,...s,focusable:!a,active:p,children:O.jsx(ON,{disabled:a,required:o.required,checked:p,...u,...i,name:o.name,ref:f,onCheck:()=>o.onValueChange(i.value),onKeyDown:Ke(h=>{h.key==="Enter"&&h.preventDefault()}),onFocus:Ke(i.onFocus,()=>{g.current&&c.current?.click()})})})});DN.displayName=MN;var PY="RadioGroupIndicator",jN=x.forwardRef((e,t)=>{const{__scopeRadioGroup:n,...r}=e,i=kN(n);return O.jsx(AN,{...i,...r,ref:t})});jN.displayName=PY;var LN=NN,$N=DN,AY=jN;const RY=["grid gap-2"],IY=["group size-5 cursor-pointer place-content-center rounded-full border transition-colors duration-200","border-inp-hover-border bg-primary-bg","data-[state=checked]:border-primary-text","enabled:hover:border-inp-hover-border enabled:hover:bg-tertiary-bg","enabled:hover:data-[state=checked]:border-inp-hover-border enabled:hover:data-[state=checked]:bg-tertiary-bg","disabled:cursor-not-allowed disabled:border-disabled-border disabled:bg-disabled-bg","disabled:data-[state=checked]:border-disabled-border disabled:data-[state=checked]:bg-disabled-bg","focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-inp-focus-border"],TY=["flex items-center justify-center"],kY=["size-2.5 rounded-full bg-primary-text transition-colors duration-200","group-hover:bg-secondary-text","group-disabled:bg-disabled-text"],E0=({className:e,ref:t,...n})=>O.jsx(LN,{className:ae(RY,e),...n,ref:t});E0.displayName=LN.displayName;const rp=({className:e,ref:t,...n})=>O.jsx($N,{ref:t,className:ae(IY,e),...n,children:O.jsx(AY,{className:ae(TY),children:O.jsx("span",{className:ae(kY)})})});rp.displayName=$N.displayName;var Ph="Switch",[NY]=gi(Ph),[MY,DY]=NY(Ph),FN=x.forwardRef((e,t)=>{const{__scopeSwitch:n,name:r,checked:i,defaultChecked:o,required:a,disabled:s,value:u="on",onCheckedChange:c,form:f,...p}=e,[g,h]=x.useState(null),v=bt(t,E=>h(E)),b=x.useRef(!1),y=g?f||!!g.closest("form"):!0,[w,S]=go({prop:i,defaultProp:o??!1,onChange:c,caller:Ph});return O.jsxs(MY,{scope:n,checked:w,disabled:s,children:[O.jsx(Qe.button,{type:"button",role:"switch","aria-checked":w,"aria-required":a,"data-state":WN(w),"data-disabled":s?"":void 0,disabled:s,value:u,...p,ref:v,onClick:Ke(e.onClick,E=>{S(_=>!_),y&&(b.current=E.isPropagationStopped(),b.current||E.stopPropagation())})}),y&&O.jsx(zN,{control:g,bubbles:!b.current,name:r,value:u,checked:w,required:a,disabled:s,form:f,style:{transform:"translateX(-100%)"}})]})});FN.displayName=Ph;var VN="SwitchThumb",BN=x.forwardRef((e,t)=>{const{__scopeSwitch:n,...r}=e,i=DY(VN,n);return O.jsx(Qe.span,{"data-state":WN(i.checked),"data-disabled":i.disabled?"":void 0,...r,ref:t})});BN.displayName=VN;var jY="SwitchBubbleInput",zN=x.forwardRef(({__scopeSwitch:e,control:t,checked:n,bubbles:r=!0,...i},o)=>{const a=x.useRef(null),s=bt(a,o),u=eh(n),c=th(t);return x.useEffect(()=>{const f=a.current;if(!f)return;const p=window.HTMLInputElement.prototype,h=Object.getOwnPropertyDescriptor(p,"checked").set;if(u!==n&&h){const v=new Event("click",{bubbles:r});h.call(f,n),f.dispatchEvent(v)}},[u,n,r]),O.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:n,...i,tabIndex:-1,ref:s,style:{...i.style,...c,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});zN.displayName=jY;function WN(e){return e?"checked":"unchecked"}var HN=FN,LY=BN;const $Y=["peer group relative inline-flex h-6 w-12 shrink-0 cursor-pointer items-center rounded-full border p-1 transition-colors","border-inp-default-border bg-primary-bg","enabled:hover:border-inp-hover-border","data-[state=checked]:bg-primary-inverse-bg","data-[state=checked]:border-inp-default-border enabled:hover:data-[state=checked]:border-inp-hover-border","disabled:cursor-not-allowed disabled:border-disabled-border disabled:bg-disabled-bg","disabled:data-[state=checked]:border-disabled-border disabled:data-[state=checked]:bg-disabled-bg","focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-inp-focus-border"],FY=["pointer-events-none block size-4 rounded-full transition-transform","bg-primary-inverse-bg data-[state=checked]:translate-x-6 data-[state=checked]:bg-primary-bg","group-disabled:bg-disabled-text group-disabled:data-[state=checked]:bg-disabled-text"],UN=({className:e,ref:t,...n})=>O.jsx(HN,{className:ae($Y,e),...n,ref:t,children:O.jsx(LY,{className:ae(FY)})});UN.displayName=HN.displayName;const _0=({ref:e,className:t,...n})=>O.jsx("div",{className:"relative w-full overflow-auto",children:O.jsx("table",{ref:e,className:ae("w-full caption-bottom text-sm",t),...n})});_0.displayName="Table";const O0=({ref:e,className:t,...n})=>O.jsx("thead",{ref:e,className:ae("text-primary-text [&_tr]:border-b",t),...n});O0.displayName="TableHeader";const P0=({ref:e,className:t,...n})=>O.jsx("tbody",{ref:e,className:ae(t),...n});P0.displayName="TableBody";const GN=({ref:e,className:t,...n})=>O.jsx("tfoot",{ref:e,className:ae("bg-muted/50 border-t font-medium",t),...n});GN.displayName="TableFooter";const Bu=({ref:e,className:t,...n})=>O.jsx("tr",{ref:e,className:ae(`hover:bg-muted/50 data-[state=selected]:bg-muted border-delicate-border border-b
|
|
154
|
+
transition-colors`,t),...n});Bu.displayName="TableRow";const A0=({ref:e,className:t,...n})=>O.jsx("th",{ref:e,className:ae(`text-muted-foreground h-10 px-6.25 text-left align-middle font-medium
|
|
155
|
+
[&:has([role=checkbox])]:pr-0 *:[[role=checkbox]]:translate-y-0.5`,t),...n});A0.displayName="TableHead";const ip=({ref:e,className:t,...n})=>O.jsx("td",{ref:e,className:ae(`px-6.25 pt-6 pb-3.5 align-middle [&:has([role=checkbox])]:pr-0
|
|
156
|
+
*:[[role=checkbox]]:translate-y-0.5`,t),...n});ip.displayName="TableCell";const qN=({ref:e,className:t,...n})=>O.jsx("caption",{ref:e,className:ae("text-muted-foreground mt-4 text-sm",t),...n});qN.displayName="TableCaption";var Ah="Tabs",[VY]=gi(Ah,[_h]),KN=_h(),[BY,R0]=VY(Ah),YN=x.forwardRef((e,t)=>{const{__scopeTabs:n,value:r,onValueChange:i,defaultValue:o,orientation:a="horizontal",dir:s,activationMode:u="automatic",...c}=e,f=Eh(s),[p,g]=go({prop:r,onChange:i,defaultProp:o??"",caller:Ah});return O.jsx(BY,{scope:n,baseId:fo(),value:p,onValueChange:g,orientation:a,dir:f,activationMode:u,children:O.jsx(Qe.div,{dir:f,"data-orientation":a,...c,ref:t})})});YN.displayName=Ah;var XN="TabsList",ZN=x.forwardRef((e,t)=>{const{__scopeTabs:n,loop:r=!0,...i}=e,o=R0(XN,n),a=KN(n);return O.jsx(CN,{asChild:!0,...a,orientation:o.orientation,dir:o.dir,loop:r,children:O.jsx(Qe.div,{role:"tablist","aria-orientation":o.orientation,...i,ref:t})})});ZN.displayName=XN;var QN="TabsTrigger",JN=x.forwardRef((e,t)=>{const{__scopeTabs:n,value:r,disabled:i=!1,...o}=e,a=R0(QN,n),s=KN(n),u=nM(a.baseId,r),c=rM(a.baseId,r),f=r===a.value;return O.jsx(EN,{asChild:!0,...s,focusable:!i,active:f,children:O.jsx(Qe.button,{type:"button",role:"tab","aria-selected":f,"aria-controls":c,"data-state":f?"active":"inactive","data-disabled":i?"":void 0,disabled:i,id:u,...o,ref:t,onMouseDown:Ke(e.onMouseDown,p=>{!i&&p.button===0&&p.ctrlKey===!1?a.onValueChange(r):p.preventDefault()}),onKeyDown:Ke(e.onKeyDown,p=>{[" ","Enter"].includes(p.key)&&a.onValueChange(r)}),onFocus:Ke(e.onFocus,()=>{const p=a.activationMode!=="manual";!f&&!i&&p&&a.onValueChange(r)})})})});JN.displayName=QN;var eM="TabsContent",tM=x.forwardRef((e,t)=>{const{__scopeTabs:n,value:r,forceMount:i,children:o,...a}=e,s=R0(eM,n),u=nM(s.baseId,r),c=rM(s.baseId,r),f=r===s.value,p=x.useRef(f);return x.useEffect(()=>{const g=requestAnimationFrame(()=>p.current=!1);return()=>cancelAnimationFrame(g)},[]),O.jsx(Co,{present:i||f,children:({present:g})=>O.jsx(Qe.div,{"data-state":f?"active":"inactive","data-orientation":s.orientation,role:"tabpanel","aria-labelledby":u,hidden:!g,id:c,tabIndex:0,...a,ref:t,style:{...e.style,animationDuration:p.current?"0s":void 0},children:g&&o})})});tM.displayName=eM;function nM(e,t){return`${e}-trigger-${t}`}function rM(e,t){return`${e}-content-${t}`}var zY=YN,iM=ZN,oM=JN,aM=tM;const WY=St(["text-primary-text inline-flex items-stretch","data-[orientation=horizontal]:w-full data-[orientation=horizontal]:gap-1","data-[orientation=vertical]:h-fit data-[orientation=vertical]:w-auto data-[orientation=vertical]:flex-col data-[orientation=vertical]:gap-1"].join(" "),{variants:{variant:{default:["bg-tertiary-bg rounded-lg","data-[orientation=horizontal]:flex-row"].join(" "),line:["border-default-border border-b","data-[orientation=horizontal]:flex-row"].join(" ")}},defaultVariants:{variant:"default"}}),HY=St(["inline-flex items-center justify-center whitespace-nowrap transition-all","focus-visible:ring-ring focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none","cursor-pointer disabled:pointer-events-none disabled:opacity-50","data-[orientation=horizontal]:h-full data-[orientation=horizontal]:w-full data-[orientation=horizontal]:flex-1","data-[orientation=vertical]:h-full data-[orientation=vertical]:w-full"].join(" "),{variants:{variant:{default:[dn("body-sm-medium"),"rounded-xl px-3 py-3","text-primary-text hover:bg-primary-hover-bg hover:text-primary-inverse-bg bg-transparent","data-[state=active]:bg-primary-inverse-bg data-[state=active]:text-primary-bg","active:text-primary-bg active:bg-neutral-500"].join(" "),line:[dn("body-sm-medium"),"-mb-px rounded-none border-b-2 border-transparent px-4 py-3","text-primary-inverse-bg hover:bg-primary-hover-bg hover:text-primary-inverse-bg","data-[state=active]:bg-primary-inverse-bg data-[state=active]:text-primary-bg","active:bg-secondary-inverse-text active:text-primary-bg"].join(" ")}},defaultVariants:{variant:"default"}}),sM=x.createContext("default"),UY=zY,lM=({ref:e,className:t,variant:n="default",...r})=>O.jsx(sM,{value:n,children:O.jsx(iM,{ref:e,className:ae(WY({variant:n}),t),...r})});lM.displayName=iM.displayName;const uM=({ref:e,className:t,variant:n,...r})=>{const i=x.use(sM),o=n??i;return O.jsx(oM,{ref:e,className:ae(HY({variant:o}),t),...r})};uM.displayName=oM.displayName;const cM=({ref:e,className:t,...n})=>O.jsx(aM,{ref:e,className:ae(`text-primary-text focus-visible:ring-ring focus-visible:ring-2
|
|
157
|
+
focus-visible:ring-offset-2 focus-visible:outline-none`,"data-[orientation=vertical]:flex-1",t),...n});cM.displayName=aM.displayName;var GY="Arrow",fM=x.forwardRef((e,t)=>{const{children:n,width:r=10,height:i=5,...o}=e;return O.jsx(Qe.svg,{...o,ref:t,width:r,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:O.jsx("polygon",{points:"0,0 30,0 15,10"})})});fM.displayName=GY;var qY=fM,I0="Popper",[dM,Rh]=gi(I0),[KY,pM]=dM(I0),hM=e=>{const{__scopePopper:t,children:n}=e,[r,i]=x.useState(null);return O.jsx(KY,{scope:t,anchor:r,onAnchorChange:i,children:n})};hM.displayName=I0;var gM="PopperAnchor",mM=x.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...i}=e,o=pM(gM,n),a=x.useRef(null),s=bt(t,a),u=x.useRef(null);return x.useEffect(()=>{const c=u.current;u.current=r?.current||a.current,c!==u.current&&o.onAnchorChange(u.current)}),r?null:O.jsx(Qe.div,{...i,ref:s})});mM.displayName=gM;var T0="PopperContent",[YY,XY]=dM(T0),vM=x.forwardRef((e,t)=>{const{__scopePopper:n,side:r="bottom",sideOffset:i=0,align:o="center",alignOffset:a=0,arrowPadding:s=0,avoidCollisions:u=!0,collisionBoundary:c=[],collisionPadding:f=0,sticky:p="partial",hideWhenDetached:g=!1,updatePositionStrategy:h="optimized",onPlaced:v,...b}=e,y=pM(T0,n),[w,S]=x.useState(null),E=bt(t,me=>S(me)),[_,P]=x.useState(null),R=th(_),I=R?.width??0,k=R?.height??0,B=r+(o!=="center"?"-"+o:""),L=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},V=Array.isArray(c)?c:[c],D=V.length>0,W={padding:L,boundary:V.filter(QY),altBoundary:D},{refs:J,floatingStyles:re,placement:U,isPositioned:ee,middlewareData:Z}=xT({strategy:"fixed",placement:B,whileElementsMounted:(...me)=>Xy(...me,{animationFrame:h==="always"}),elements:{reference:y.anchor},middleware:[wT({mainAxis:i+k,alignmentAxis:a}),u&&ST({mainAxis:!0,crossAxis:!1,limiter:p==="partial"?CT():void 0,...W}),u&&ET({...W}),_T({...W,apply:({elements:me,rects:Se,availableWidth:q,availableHeight:te})=>{const{width:Y,height:j}=Se.reference,ie=me.floating.style;ie.setProperty("--radix-popper-available-width",`${q}px`),ie.setProperty("--radix-popper-available-height",`${te}px`),ie.setProperty("--radix-popper-anchor-width",`${Y}px`),ie.setProperty("--radix-popper-anchor-height",`${j}px`)}}),_&&e6({element:_,padding:s}),JY({arrowWidth:I,arrowHeight:k}),g&&OT({strategy:"referenceHidden",...W})]}),[ue,X]=xM(U),Oe=ca(v);Wn(()=>{ee&&Oe?.()},[ee,Oe]);const Ee=Z.arrow?.x,Me=Z.arrow?.y,ye=Z.arrow?.centerOffset!==0,[be,$e]=x.useState();return Wn(()=>{w&&$e(window.getComputedStyle(w).zIndex)},[w]),O.jsx("div",{ref:J.setFloating,"data-radix-popper-content-wrapper":"",style:{...re,transform:ee?re.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:be,"--radix-popper-transform-origin":[Z.transformOrigin?.x,Z.transformOrigin?.y].join(" "),...Z.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:O.jsx(YY,{scope:n,placedSide:ue,onArrowChange:P,arrowX:Ee,arrowY:Me,shouldHideArrow:ye,children:O.jsx(Qe.div,{"data-side":ue,"data-align":X,...b,ref:E,style:{...b.style,animation:ee?void 0:"none"}})})})});vM.displayName=T0;var yM="PopperArrow",ZY={top:"bottom",right:"left",bottom:"top",left:"right"},bM=x.forwardRef(function(t,n){const{__scopePopper:r,...i}=t,o=XY(yM,r),a=ZY[o.placedSide];return O.jsx("span",{ref:o.onArrowChange,style:{position:"absolute",left:o.arrowX,top:o.arrowY,[a]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[o.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[o.placedSide],visibility:o.shouldHideArrow?"hidden":void 0},children:O.jsx(qY,{...i,ref:n,style:{...i.style,display:"block"}})})});bM.displayName=yM;function QY(e){return e!==null}var JY=e=>({name:"transformOrigin",options:e,fn(t){const{placement:n,rects:r,middlewareData:i}=t,a=i.arrow?.centerOffset!==0,s=a?0:e.arrowWidth,u=a?0:e.arrowHeight,[c,f]=xM(n),p={start:"0%",center:"50%",end:"100%"}[f],g=(i.arrow?.x??0)+s/2,h=(i.arrow?.y??0)+u/2;let v="",b="";return c==="bottom"?(v=a?p:`${g}px`,b=`${-u}px`):c==="top"?(v=a?p:`${g}px`,b=`${r.floating.height+u}px`):c==="right"?(v=`${-u}px`,b=a?p:`${h}px`):c==="left"&&(v=`${r.floating.width+u}px`,b=a?p:`${h}px`),{data:{x:v,y:b}}}});function xM(e){const[t,n="center"]=e.split("-");return[t,n]}var wM=hM,SM=mM,CM=vM,EM=bM,_M=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),eX="VisuallyHidden",OM=x.forwardRef((e,t)=>O.jsx(Qe.span,{...e,ref:t,style:{..._M,...e.style}}));OM.displayName=eX;var tX=OM,[Ih]=gi("Tooltip",[Rh]),Th=Rh(),PM="TooltipProvider",nX=700,ob="tooltip.open",[rX,k0]=Ih(PM),AM=e=>{const{__scopeTooltip:t,delayDuration:n=nX,skipDelayDuration:r=300,disableHoverableContent:i=!1,children:o}=e,a=x.useRef(!0),s=x.useRef(!1),u=x.useRef(0);return x.useEffect(()=>{const c=u.current;return()=>window.clearTimeout(c)},[]),O.jsx(rX,{scope:t,isOpenDelayedRef:a,delayDuration:n,onOpen:x.useCallback(()=>{window.clearTimeout(u.current),a.current=!1},[]),onClose:x.useCallback(()=>{window.clearTimeout(u.current),u.current=window.setTimeout(()=>a.current=!0,r)},[r]),isPointerInTransitRef:s,onPointerInTransitChange:x.useCallback(c=>{s.current=c},[]),disableHoverableContent:i,children:o})};AM.displayName=PM;var Yu="Tooltip",[iX,bc]=Ih(Yu),RM=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:i,onOpenChange:o,disableHoverableContent:a,delayDuration:s}=e,u=k0(Yu,e.__scopeTooltip),c=Th(t),[f,p]=x.useState(null),g=fo(),h=x.useRef(0),v=a??u.disableHoverableContent,b=s??u.delayDuration,y=x.useRef(!1),[w,S]=go({prop:r,defaultProp:i??!1,onChange:I=>{I?(u.onOpen(),document.dispatchEvent(new CustomEvent(ob))):u.onClose(),o?.(I)},caller:Yu}),E=x.useMemo(()=>w?y.current?"delayed-open":"instant-open":"closed",[w]),_=x.useCallback(()=>{window.clearTimeout(h.current),h.current=0,y.current=!1,S(!0)},[S]),P=x.useCallback(()=>{window.clearTimeout(h.current),h.current=0,S(!1)},[S]),R=x.useCallback(()=>{window.clearTimeout(h.current),h.current=window.setTimeout(()=>{y.current=!0,S(!0),h.current=0},b)},[b,S]);return x.useEffect(()=>()=>{h.current&&(window.clearTimeout(h.current),h.current=0)},[]),O.jsx(wM,{...c,children:O.jsx(iX,{scope:t,contentId:g,open:w,stateAttribute:E,trigger:f,onTriggerChange:p,onTriggerEnter:x.useCallback(()=>{u.isOpenDelayedRef.current?R():_()},[u.isOpenDelayedRef,R,_]),onTriggerLeave:x.useCallback(()=>{v?P():(window.clearTimeout(h.current),h.current=0)},[P,v]),onOpen:_,onClose:P,disableHoverableContent:v,children:n})})};RM.displayName=Yu;var ab="TooltipTrigger",IM=x.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,i=bc(ab,n),o=k0(ab,n),a=Th(n),s=x.useRef(null),u=bt(t,s,i.onTriggerChange),c=x.useRef(!1),f=x.useRef(!1),p=x.useCallback(()=>c.current=!1,[]);return x.useEffect(()=>()=>document.removeEventListener("pointerup",p),[p]),O.jsx(SM,{asChild:!0,...a,children:O.jsx(Qe.button,{"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute,...r,ref:u,onPointerMove:Ke(e.onPointerMove,g=>{g.pointerType!=="touch"&&!f.current&&!o.isPointerInTransitRef.current&&(i.onTriggerEnter(),f.current=!0)}),onPointerLeave:Ke(e.onPointerLeave,()=>{i.onTriggerLeave(),f.current=!1}),onPointerDown:Ke(e.onPointerDown,()=>{i.open&&i.onClose(),c.current=!0,document.addEventListener("pointerup",p,{once:!0})}),onFocus:Ke(e.onFocus,()=>{c.current||i.onOpen()}),onBlur:Ke(e.onBlur,i.onClose),onClick:Ke(e.onClick,i.onClose)})})});IM.displayName=ab;var N0="TooltipPortal",[oX,aX]=Ih(N0,{forceMount:void 0}),TM=e=>{const{__scopeTooltip:t,forceMount:n,children:r,container:i}=e,o=bc(N0,t);return O.jsx(oX,{scope:t,forceMount:n,children:O.jsx(Co,{present:n||o.open,children:O.jsx(wh,{asChild:!0,container:i,children:r})})})};TM.displayName=N0;var bl="TooltipContent",kM=x.forwardRef((e,t)=>{const n=aX(bl,e.__scopeTooltip),{forceMount:r=n.forceMount,side:i="top",...o}=e,a=bc(bl,e.__scopeTooltip);return O.jsx(Co,{present:r||a.open,children:a.disableHoverableContent?O.jsx(NM,{side:i,...o,ref:t}):O.jsx(sX,{side:i,...o,ref:t})})}),sX=x.forwardRef((e,t)=>{const n=bc(bl,e.__scopeTooltip),r=k0(bl,e.__scopeTooltip),i=x.useRef(null),o=bt(t,i),[a,s]=x.useState(null),{trigger:u,onClose:c}=n,f=i.current,{onPointerInTransitChange:p}=r,g=x.useCallback(()=>{s(null),p(!1)},[p]),h=x.useCallback((v,b)=>{const y=v.currentTarget,w={x:v.clientX,y:v.clientY},S=fX(w,y.getBoundingClientRect()),E=dX(w,S),_=pX(b.getBoundingClientRect()),P=gX([...E,..._]);s(P),p(!0)},[p]);return x.useEffect(()=>()=>g(),[g]),x.useEffect(()=>{if(u&&f){const v=y=>h(y,f),b=y=>h(y,u);return u.addEventListener("pointerleave",v),f.addEventListener("pointerleave",b),()=>{u.removeEventListener("pointerleave",v),f.removeEventListener("pointerleave",b)}}},[u,f,h,g]),x.useEffect(()=>{if(a){const v=b=>{const y=b.target,w={x:b.clientX,y:b.clientY},S=u?.contains(y)||f?.contains(y),E=!hX(w,a);S?g():E&&(g(),c())};return document.addEventListener("pointermove",v),()=>document.removeEventListener("pointermove",v)}},[u,f,a,c,g]),O.jsx(NM,{...e,ref:o})}),[lX,uX]=Ih(Yu,{isInside:!1}),cX=zU("TooltipContent"),NM=x.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":i,onEscapeKeyDown:o,onPointerDownOutside:a,...s}=e,u=bc(bl,n),c=Th(n),{onClose:f}=u;return x.useEffect(()=>(document.addEventListener(ob,f),()=>document.removeEventListener(ob,f)),[f]),x.useEffect(()=>{if(u.trigger){const p=g=>{g.target?.contains(u.trigger)&&f()};return window.addEventListener("scroll",p,{capture:!0}),()=>window.removeEventListener("scroll",p,{capture:!0})}},[u.trigger,f]),O.jsx(xh,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:o,onPointerDownOutside:a,onFocusOutside:p=>p.preventDefault(),onDismiss:f,children:O.jsxs(CM,{"data-state":u.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)"},children:[O.jsx(cX,{children:r}),O.jsx(lX,{scope:n,isInside:!0,children:O.jsx(tX,{id:u.contentId,role:"tooltip",children:i||r})})]})})});kM.displayName=bl;var MM="TooltipArrow",DM=x.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,i=Th(n);return uX(MM,n).isInside?null:O.jsx(EM,{...i,...r,ref:t})});DM.displayName=MM;function fX(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),i=Math.abs(t.right-e.x),o=Math.abs(t.left-e.x);switch(Math.min(n,r,i,o)){case o:return"left";case i:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function dX(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 pX(e){const{top:t,right:n,bottom:r,left:i}=e;return[{x:i,y:t},{x:n,y:t},{x:n,y:r},{x:i,y:r}]}function hX(e,t){const{x:n,y:r}=e;let i=!1;for(let o=0,a=t.length-1;o<t.length;a=o++){const s=t[o],u=t[a],c=s.x,f=s.y,p=u.x,g=u.y;f>r!=g>r&&n<(p-c)*(r-f)/(g-f)+c&&(i=!i)}return i}function gX(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),mX(t)}function mX(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const i=e[r];for(;t.length>=2;){const o=t[t.length-1],a=t[t.length-2];if((o.x-a.x)*(i.y-a.y)>=(o.y-a.y)*(i.x-a.x))t.pop();else break}t.push(i)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const i=e[r];for(;n.length>=2;){const o=n[n.length-1],a=n[n.length-2];if((o.x-a.x)*(i.y-a.y)>=(o.y-a.y)*(i.x-a.x))n.pop();else break}n.push(i)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var vX=AM,yX=RM,bX=IM,xX=TM,jM=kM,wX=DM;const SX=`bg-primary text-primary-foreground animate-in fade-in-0 zoom-in-95
|
|
158
158
|
data-[state=closed]:animate-out data-[state=closed]:fade-out-0
|
|
159
159
|
data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2
|
|
160
160
|
data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2
|
|
161
161
|
data-[side=top]:slide-in-from-bottom-2 z-50
|
|
162
162
|
origin-[--radix-tooltip-content-transform-origin] overflow-hidden rounded-md px-3
|
|
163
|
-
py-1.5 text-xs`,
|
|
164
|
-
hover:bg-primary-inverse-bg`,false:""}},compoundVariants:[{size:"sm",active:!0,className:"size-7 px-0"},{size:"default",active:!0,className:"size-8 px-0"},{size:"lg",active:!0,className:"size-9 px-0"}],defaultVariants:{size:"default",active:!1}}),
|
|
163
|
+
py-1.5 text-xs`,CX=vX,LM=yX,$M=bX,FM=wX,M0=({className:e,sideOffset:t=4,ref:n,...r})=>O.jsx(xX,{children:O.jsx(jM,{ref:n,sideOffset:t,className:ae(SX,e),...r})});M0.displayName=jM.displayName;const D0=(e=!1)=>{const[t,n]=$.useState(e);return{isOpened:t,openPopup:()=>n(!0),closePopup:()=>n(!1),togglePopup:()=>n(a=>!a)}},EX=(e,t,n)=>{if(n<=e)return Array.from({length:n},(c,f)=>f+1);const r=Math.floor((e-2)/2);let i=Math.max(t-r,2),o=Math.min(t+r,n-1);const a=o-i+1,s=e-2;a<s&&(i===2?o=Math.min(o+(s-a),n-1):o===n-1&&(i=Math.max(i-(s-a),2)));const u=[];u.push(1),i>2&&u.push("ellipsis-start");for(let c=i;c<=o;c++)u.push(c);return o<n-1&&u.push("ellipsis-end"),n>1&&u.push(n),u},_X=St("flex items-center",{variants:{size:{sm:"gap-1",default:"gap-1",lg:"gap-2"}},defaultVariants:{size:"default"}}),HE=St(["bg-tertiary-bg text-primary-text cursor-pointer rounded-[0.25rem] p-0","hover:bg-primary-hover-bg"].join(" "),{variants:{size:{sm:"size-7 [&_svg]:size-3",default:"size-8 [&_svg]:size-3.5",lg:"size-9 [&_svg]:size-4"},side:{prev:"mr-3",next:"ml-3"}},defaultVariants:{size:"default"}}),UE=St(["text-primary-text cursor-pointer rounded-[0.75rem] bg-transparent","hover:bg-tertiary-bg",dn("body-xs-medium")].join(" "),{variants:{size:{sm:"h-7 min-w-7 px-2",default:"h-8 min-w-8 px-3",lg:"h-9 min-w-9 px-3.5"},active:{true:`bg-primary-inverse-bg text-primary-inverse-text
|
|
164
|
+
hover:bg-primary-inverse-bg`,false:""}},compoundVariants:[{size:"sm",active:!0,className:"size-7 px-0"},{size:"default",active:!0,className:"size-8 px-0"},{size:"lg",active:!0,className:"size-9 px-0"}],defaultVariants:{size:"default",active:!1}}),OX=5,PX=5,AX=({currentPage:e,totalPages:t,maxVisiblePages:n=OX,className:r,showNavigation:i=!0,prevLabel:o,nextLabel:a,size:s="default",ellipsisStep:u=PX,onPageChange:c})=>{if(t<=1)return null;const f=EX(n,e,t),p=h=>{h>=1&&h<=t&&c(h)},g=h=>{if(h==="ellipsis-start"){const v=Math.max(1,e-u);p(v)}else{const v=Math.min(t,e+u);p(v)}};return O.jsx(b0,{children:O.jsxs(x0,{className:ae(_X({size:s}),r),children:[i&&O.jsx(sl,{children:O.jsx(uo,{variant:"ghost",disabled:e===1,onClick:()=>p(e-1),className:HE({size:s,side:"prev"}),"aria-label":"Предыдущая страница",children:o||O.jsx(bI,{})})}),f.map(h=>h==="ellipsis-start"||h==="ellipsis-end"?O.jsx(sl,{children:O.jsx(uo,{variant:"ghost",onClick:()=>g(h),className:UE({size:s}),"aria-label":h==="ellipsis-start"?`Перейти на ${u} страниц назад`:`Перейти на ${u} страниц вперед`,title:h==="ellipsis-start"?`Нажать чтобы перейти на ${u} страниц назад`:`Нажать чтобы перейти на ${u} страниц вперед`,children:"..."})},h):O.jsx(sl,{children:O.jsx(vc,{isActive:e===h,onClick:()=>p(h),className:UE({size:s,active:e===h}),"aria-label":`Страница ${h}`,"aria-current":e===h?"page":void 0,children:h})},h)),i&&O.jsx(sl,{children:O.jsx(uo,{variant:"ghost",disabled:e===t,onClick:()=>p(e+1),className:HE({size:s,side:"next"}),"aria-label":"Следующая страница",children:a||O.jsx(xI,{})})})]})})},RX=St(["border-delicate-border bg-secondary-bg flex h-full shrink-0 flex-col border-r","transition-[width] duration-200 ease-out"].join(" "),{variants:{state:{expanded:"w-[15.5rem]",collapsed:"w-16"}},defaultVariants:{state:"expanded"}}),IX=St("border-delicate-border flex h-[4.5rem] items-center border-b",{variants:{state:{expanded:"justify-between px-7",collapsed:"justify-center px-[1.125rem]"}},defaultVariants:{state:"expanded"}}),TX=St("flex items-center gap-3",{variants:{state:{expanded:"opacity-100",collapsed:"hidden opacity-0"}},defaultVariants:{state:"expanded"}}),kX=dn("body-xl-medium"),NX=St(["text-sub-label-text inline-flex size-7 cursor-pointer items-center justify-center rounded-sm","hover:bg-tertiary-bg hover:text-primary-text transition-colors","disabled:text-disabled-text disabled:pointer-events-none"].join(" ")),MX=({groups:e,title:t="CRM",brandMark:n,state:r="expanded",activeItemId:i,showToggle:o=!0,onStateChange:a,onItemSelect:s,className:u,...c})=>{const f=r==="collapsed",p=e.filter(y=>y.placement!=="bottom"),g=e.filter(y=>y.placement==="bottom"),h=f?"expanded":"collapsed",v=()=>{a?.(h)},b=y=>y.map(w=>O.jsx(sN,{title:w.title,collapsed:f,className:ae(w.divider&&"border-delicate-border border-b"),children:w.items.map(S=>{const E=i?i===S.id:!!S.active;return O.jsx(aN,{icon:O.jsx(ji,{type:S.icon}),label:S.label,badge:S.badge,active:E,collapsed:f,disabled:S.disabled,href:S.href,target:S.target,rel:S.rel,onAction:()=>{s?.(S),S.onClick?.(S)},"aria-current":E?"page":void 0},S.id)})},w.id));return O.jsxs("aside",{className:ae(RX({state:r}),u),"aria-label":"Боковая навигация",...c,children:[O.jsxs("header",{className:IX({state:r}),children:[O.jsxs("div",{className:TX({state:r}),children:[n,O.jsx("p",{className:kX,children:t})]}),o&&O.jsx("button",{type:"button",className:NX(),onClick:v,"aria-label":f?"Развернуть боковую навигацию":"Свернуть боковую навигацию",disabled:!a,children:O.jsx(ji,{type:"chevrons",strokeWidth:1.5,className:ae("transition-transform duration-200",f?"-rotate-90":"rotate-90")})})]}),O.jsxs("div",{className:"flex min-h-0 flex-1 flex-col",children:[O.jsx("div",{className:"min-h-0 flex-1 overflow-y-auto",children:b(p)}),g.length>0&&O.jsx("div",{className:"mt-auto",children:b(g)})]})]})},DX=({name:e,orientation:t="horizontal",label:n,disabled:r,classNames:i,isValid:o,...a})=>{const s={"aria-invalid":!!o,"data-invalid":!!o};return O.jsx(hc,{className:i?.classNameGroup,children:O.jsxs(gc,{...s,orientation:t,children:[O.jsx(Sx,{...a,...s,id:e,name:e,disabled:r,className:i?.classNameCheckbox}),n&&O.jsx(Rl,{htmlFor:e,className:ae("text-[14px]",i?.classNameLabel,r&&"cursor-not-allowed"),children:n})]})})},jX=({open:e,onOpenChange:t,title:n,cancelLabel:r="Отмена",confirmLabel:i="Ок",onConfirm:o,children:a,classes:s,footer:u,showCloseButton:c=!1,ariaDescribedby:f=void 0})=>{const p=()=>{t(!1)},g=()=>{o?.(),t(!1)},h=u===void 0?O.jsxs(v0,{className:s?.footer,children:[O.jsx(uo,{variant:"secondary",onClick:p,children:r}),O.jsx(uo,{onClick:g,children:i})]}):u;return O.jsx(rN,{open:e,onOpenChange:t,children:O.jsxs(g0,{"aria-describedby":f,showCloseButton:c,children:[n&&O.jsx(m0,{className:s?.header,children:O.jsx(y0,{className:s?.title,children:n})}),O.jsx("div",{className:s?.body,children:a}),h]})})};function ta(e,t){return typeof e=="function"?e(t):e}function Tr(e,t){return n=>{t.setState(r=>({...r,[e]:ta(n,r[e])}))}}function kh(e){return e instanceof Function}function LX(e){return Array.isArray(e)&&e.every(t=>typeof t=="number")}function $X(e,t){const n=[],r=i=>{i.forEach(o=>{n.push(o);const a=t(o);a!=null&&a.length&&r(a)})};return r(e),n}function Ge(e,t,n){let r=[],i;return o=>{let a;n.key&&n.debug&&(a=Date.now());const s=e(o);if(!(s.length!==r.length||s.some((f,p)=>r[p]!==f)))return i;r=s;let c;if(n.key&&n.debug&&(c=Date.now()),i=t(...s),n==null||n.onChange==null||n.onChange(i),n.key&&n.debug&&n!=null&&n.debug()){const f=Math.round((Date.now()-a)*100)/100,p=Math.round((Date.now()-c)*100)/100,g=p/16,h=(v,b)=>{for(v=String(v);v.length<b;)v=" "+v;return v};console.info(`%c⏱ ${h(p,5)} /${h(f,5)} ms`,`
|
|
165
165
|
font-size: .6rem;
|
|
166
166
|
font-weight: bold;
|
|
167
|
-
color: hsl(${Math.max(0,Math.min(120-120*g,120))}deg 100% 31%);`,n?.key)}return i}}function Ge(e,t,n,r){return{debug:()=>{var i;return(i=e?.debugAll)!=null?i:e[t]},key:process.env.NODE_ENV==="development"&&n,onChange:r}}function BY(e,t,n,r){const i=()=>{var a;return(a=o.getValue())!=null?a:e.options.renderFallbackValue},o={id:`${t.id}_${n.id}`,row:t,column:n,getValue:()=>t.getValue(r),renderValue:i,getContext:Ue(()=>[e,n,t,o],(a,s,u,c)=>({table:a,column:s,row:u,cell:c,getValue:c.getValue,renderValue:c.renderValue}),Ge(e.options,"debugCells","cell.getContext"))};return e._features.forEach(a=>{a.createCell==null||a.createCell(o,n,t,e)},{}),o}function zY(e,t,n,r){var i,o;const s={...e._getDefaultColumnDef(),...t},u=s.accessorKey;let c=(i=(o=s.id)!=null?o:u?typeof String.prototype.replaceAll=="function"?u.replaceAll(".","_"):u.replace(/\./g,"_"):void 0)!=null?i:typeof s.header=="string"?s.header:void 0,d;if(s.accessorFn?d=s.accessorFn:u&&(u.includes(".")?d=g=>{let h=g;for(const b of u.split(".")){var v;h=(v=h)==null?void 0:v[b],process.env.NODE_ENV!=="production"&&h===void 0&&console.warn(`"${b}" in deeply nested key "${u}" returned undefined.`)}return h}:d=g=>g[s.accessorKey]),!c)throw process.env.NODE_ENV!=="production"?new Error(s.accessorFn?"Columns require an id when using an accessorFn":"Columns require an id when using a non-string header"):new Error;let p={id:`${String(c)}`,accessorFn:d,parent:r,depth:n,columnDef:s,columns:[],getFlatColumns:Ue(()=>[!0],()=>{var g;return[p,...(g=p.columns)==null?void 0:g.flatMap(h=>h.getFlatColumns())]},Ge(e.options,"debugColumns","column.getFlatColumns")),getLeafColumns:Ue(()=>[e._getOrderColumnsFn()],g=>{var h;if((h=p.columns)!=null&&h.length){let v=p.columns.flatMap(b=>b.getLeafColumns());return g(v)}return[p]},Ge(e.options,"debugColumns","column.getLeafColumns"))};for(const g of e._features)g.createColumn==null||g.createColumn(p,e);return p}const Fn="debugHeaders";function OE(e,t,n){var r;let o={id:(r=n.id)!=null?r:t.id,column:t,index:n.index,isPlaceholder:!!n.isPlaceholder,placeholderId:n.placeholderId,depth:n.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{const a=[],s=u=>{u.subHeaders&&u.subHeaders.length&&u.subHeaders.map(s),a.push(u)};return s(o),a},getContext:()=>({table:e,header:o,column:t})};return e._features.forEach(a=>{a.createHeader==null||a.createHeader(o,e)}),o}const WY={createTable:e=>{e.getHeaderGroups=Ue(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r,i)=>{var o,a;const s=(o=r?.map(p=>n.find(g=>g.id===p)).filter(Boolean))!=null?o:[],u=(a=i?.map(p=>n.find(g=>g.id===p)).filter(Boolean))!=null?a:[],c=n.filter(p=>!(r!=null&&r.includes(p.id))&&!(i!=null&&i.includes(p.id)));return ed(t,[...s,...c,...u],e)},Ge(e.options,Fn,"getHeaderGroups")),e.getCenterHeaderGroups=Ue(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r,i)=>(n=n.filter(o=>!(r!=null&&r.includes(o.id))&&!(i!=null&&i.includes(o.id))),ed(t,n,e,"center")),Ge(e.options,Fn,"getCenterHeaderGroups")),e.getLeftHeaderGroups=Ue(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left],(t,n,r)=>{var i;const o=(i=r?.map(a=>n.find(s=>s.id===a)).filter(Boolean))!=null?i:[];return ed(t,o,e,"left")},Ge(e.options,Fn,"getLeftHeaderGroups")),e.getRightHeaderGroups=Ue(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.right],(t,n,r)=>{var i;const o=(i=r?.map(a=>n.find(s=>s.id===a)).filter(Boolean))!=null?i:[];return ed(t,o,e,"right")},Ge(e.options,Fn,"getRightHeaderGroups")),e.getFooterGroups=Ue(()=>[e.getHeaderGroups()],t=>[...t].reverse(),Ge(e.options,Fn,"getFooterGroups")),e.getLeftFooterGroups=Ue(()=>[e.getLeftHeaderGroups()],t=>[...t].reverse(),Ge(e.options,Fn,"getLeftFooterGroups")),e.getCenterFooterGroups=Ue(()=>[e.getCenterHeaderGroups()],t=>[...t].reverse(),Ge(e.options,Fn,"getCenterFooterGroups")),e.getRightFooterGroups=Ue(()=>[e.getRightHeaderGroups()],t=>[...t].reverse(),Ge(e.options,Fn,"getRightFooterGroups")),e.getFlatHeaders=Ue(()=>[e.getHeaderGroups()],t=>t.map(n=>n.headers).flat(),Ge(e.options,Fn,"getFlatHeaders")),e.getLeftFlatHeaders=Ue(()=>[e.getLeftHeaderGroups()],t=>t.map(n=>n.headers).flat(),Ge(e.options,Fn,"getLeftFlatHeaders")),e.getCenterFlatHeaders=Ue(()=>[e.getCenterHeaderGroups()],t=>t.map(n=>n.headers).flat(),Ge(e.options,Fn,"getCenterFlatHeaders")),e.getRightFlatHeaders=Ue(()=>[e.getRightHeaderGroups()],t=>t.map(n=>n.headers).flat(),Ge(e.options,Fn,"getRightFlatHeaders")),e.getCenterLeafHeaders=Ue(()=>[e.getCenterFlatHeaders()],t=>t.filter(n=>{var r;return!((r=n.subHeaders)!=null&&r.length)}),Ge(e.options,Fn,"getCenterLeafHeaders")),e.getLeftLeafHeaders=Ue(()=>[e.getLeftFlatHeaders()],t=>t.filter(n=>{var r;return!((r=n.subHeaders)!=null&&r.length)}),Ge(e.options,Fn,"getLeftLeafHeaders")),e.getRightLeafHeaders=Ue(()=>[e.getRightFlatHeaders()],t=>t.filter(n=>{var r;return!((r=n.subHeaders)!=null&&r.length)}),Ge(e.options,Fn,"getRightLeafHeaders")),e.getLeafHeaders=Ue(()=>[e.getLeftHeaderGroups(),e.getCenterHeaderGroups(),e.getRightHeaderGroups()],(t,n,r)=>{var i,o,a,s,u,c;return[...(i=(o=t[0])==null?void 0:o.headers)!=null?i:[],...(a=(s=n[0])==null?void 0:s.headers)!=null?a:[],...(u=(c=r[0])==null?void 0:c.headers)!=null?u:[]].map(d=>d.getLeafHeaders()).flat()},Ge(e.options,Fn,"getLeafHeaders"))}};function ed(e,t,n,r){var i,o;let a=0;const s=function(g,h){h===void 0&&(h=1),a=Math.max(a,h),g.filter(v=>v.getIsVisible()).forEach(v=>{var b;(b=v.columns)!=null&&b.length&&s(v.columns,h+1)},0)};s(e);let u=[];const c=(g,h)=>{const v={depth:h,id:[r,`${h}`].filter(Boolean).join("_"),headers:[]},b=[];g.forEach(y=>{const w=[...b].reverse()[0],C=y.column.depth===v.depth;let E,_=!1;if(C&&y.column.parent?E=y.column.parent:(E=y.column,_=!0),w&&w?.column===E)w.subHeaders.push(y);else{const O=OE(n,E,{id:[r,h,E.id,y?.id].filter(Boolean).join("_"),isPlaceholder:_,placeholderId:_?`${b.filter(R=>R.column===E).length}`:void 0,depth:h,index:b.length});O.subHeaders.push(y),b.push(O)}v.headers.push(y),y.headerGroup=v}),u.push(v),h>0&&c(b,h-1)},d=t.map((g,h)=>OE(n,g,{depth:a,index:h}));c(d,a-1),u.reverse();const p=g=>g.filter(v=>v.column.getIsVisible()).map(v=>{let b=0,y=0,w=[0];v.subHeaders&&v.subHeaders.length?(w=[],p(v.subHeaders).forEach(E=>{let{colSpan:_,rowSpan:O}=E;b+=_,w.push(O)})):b=1;const C=Math.min(...w);return y=y+C,v.colSpan=b,v.rowSpan=y,{colSpan:b,rowSpan:y}});return p((i=(o=u[0])==null?void 0:o.headers)!=null?i:[]),u}const vx=(e,t,n,r,i,o,a)=>{let s={id:t,index:r,original:n,depth:i,parentId:a,_valuesCache:{},_uniqueValuesCache:{},getValue:u=>{if(s._valuesCache.hasOwnProperty(u))return s._valuesCache[u];const c=e.getColumn(u);if(c!=null&&c.accessorFn)return s._valuesCache[u]=c.accessorFn(s.original,r),s._valuesCache[u]},getUniqueValues:u=>{if(s._uniqueValuesCache.hasOwnProperty(u))return s._uniqueValuesCache[u];const c=e.getColumn(u);if(c!=null&&c.accessorFn)return c.columnDef.getUniqueValues?(s._uniqueValuesCache[u]=c.columnDef.getUniqueValues(s.original,r),s._uniqueValuesCache[u]):(s._uniqueValuesCache[u]=[s.getValue(u)],s._uniqueValuesCache[u])},renderValue:u=>{var c;return(c=s.getValue(u))!=null?c:e.options.renderFallbackValue},subRows:[],getLeafRows:()=>VY(s.subRows,u=>u.subRows),getParentRow:()=>s.parentId?e.getRow(s.parentId,!0):void 0,getParentRows:()=>{let u=[],c=s;for(;;){const d=c.getParentRow();if(!d)break;u.push(d),c=d}return u.reverse()},getAllCells:Ue(()=>[e.getAllLeafColumns()],u=>u.map(c=>BY(e,s,c,c.id)),Ge(e.options,"debugRows","getAllCells")),_getAllCellsByColumnId:Ue(()=>[s.getAllCells()],u=>u.reduce((c,d)=>(c[d.column.id]=d,c),{}),Ge(e.options,"debugRows","getAllCellsByColumnId"))};for(let u=0;u<e._features.length;u++){const c=e._features[u];c==null||c.createRow==null||c.createRow(s,e)}return s},HY={createColumn:(e,t)=>{e._getFacetedRowModel=t.options.getFacetedRowModel&&t.options.getFacetedRowModel(t,e.id),e.getFacetedRowModel=()=>e._getFacetedRowModel?e._getFacetedRowModel():t.getPreFilteredRowModel(),e._getFacetedUniqueValues=t.options.getFacetedUniqueValues&&t.options.getFacetedUniqueValues(t,e.id),e.getFacetedUniqueValues=()=>e._getFacetedUniqueValues?e._getFacetedUniqueValues():new Map,e._getFacetedMinMaxValues=t.options.getFacetedMinMaxValues&&t.options.getFacetedMinMaxValues(t,e.id),e.getFacetedMinMaxValues=()=>{if(e._getFacetedMinMaxValues)return e._getFacetedMinMaxValues()}}},dM=(e,t,n)=>{var r,i;const o=n==null||(r=n.toString())==null?void 0:r.toLowerCase();return!!(!((i=e.getValue(t))==null||(i=i.toString())==null||(i=i.toLowerCase())==null)&&i.includes(o))};dM.autoRemove=e=>ci(e);const pM=(e,t,n)=>{var r;return!!(!((r=e.getValue(t))==null||(r=r.toString())==null)&&r.includes(n))};pM.autoRemove=e=>ci(e);const hM=(e,t,n)=>{var r;return((r=e.getValue(t))==null||(r=r.toString())==null?void 0:r.toLowerCase())===n?.toLowerCase()};hM.autoRemove=e=>ci(e);const gM=(e,t,n)=>{var r;return(r=e.getValue(t))==null?void 0:r.includes(n)};gM.autoRemove=e=>ci(e);const mM=(e,t,n)=>!n.some(r=>{var i;return!((i=e.getValue(t))!=null&&i.includes(r))});mM.autoRemove=e=>ci(e)||!(e!=null&&e.length);const vM=(e,t,n)=>n.some(r=>{var i;return(i=e.getValue(t))==null?void 0:i.includes(r)});vM.autoRemove=e=>ci(e)||!(e!=null&&e.length);const yM=(e,t,n)=>e.getValue(t)===n;yM.autoRemove=e=>ci(e);const bM=(e,t,n)=>e.getValue(t)==n;bM.autoRemove=e=>ci(e);const yx=(e,t,n)=>{let[r,i]=n;const o=e.getValue(t);return o>=r&&o<=i};yx.resolveFilterValue=e=>{let[t,n]=e,r=typeof t!="number"?parseFloat(t):t,i=typeof n!="number"?parseFloat(n):n,o=t===null||Number.isNaN(r)?-1/0:r,a=n===null||Number.isNaN(i)?1/0:i;if(o>a){const s=o;o=a,a=s}return[o,a]};yx.autoRemove=e=>ci(e)||ci(e[0])&&ci(e[1]);const Ji={includesString:dM,includesStringSensitive:pM,equalsString:hM,arrIncludes:gM,arrIncludesAll:mM,arrIncludesSome:vM,equals:yM,weakEquals:bM,inNumberRange:yx};function ci(e){return e==null||e===""}const UY={getDefaultColumnDef:()=>({filterFn:"auto"}),getInitialState:e=>({columnFilters:[],...e}),getDefaultOptions:e=>({onColumnFiltersChange:Ir("columnFilters",e),filterFromLeafRows:!1,maxLeafRowFilterDepth:100}),createColumn:(e,t)=>{e.getAutoFilterFn=()=>{const n=t.getCoreRowModel().flatRows[0],r=n?.getValue(e.id);return typeof r=="string"?Ji.includesString:typeof r=="number"?Ji.inNumberRange:typeof r=="boolean"||r!==null&&typeof r=="object"?Ji.equals:Array.isArray(r)?Ji.arrIncludes:Ji.weakEquals},e.getFilterFn=()=>{var n,r;return bh(e.columnDef.filterFn)?e.columnDef.filterFn:e.columnDef.filterFn==="auto"?e.getAutoFilterFn():(n=(r=t.options.filterFns)==null?void 0:r[e.columnDef.filterFn])!=null?n:Ji[e.columnDef.filterFn]},e.getCanFilter=()=>{var n,r,i;return((n=e.columnDef.enableColumnFilter)!=null?n:!0)&&((r=t.options.enableColumnFilters)!=null?r:!0)&&((i=t.options.enableFilters)!=null?i:!0)&&!!e.accessorFn},e.getIsFiltered=()=>e.getFilterIndex()>-1,e.getFilterValue=()=>{var n;return(n=t.getState().columnFilters)==null||(n=n.find(r=>r.id===e.id))==null?void 0:n.value},e.getFilterIndex=()=>{var n,r;return(n=(r=t.getState().columnFilters)==null?void 0:r.findIndex(i=>i.id===e.id))!=null?n:-1},e.setFilterValue=n=>{t.setColumnFilters(r=>{const i=e.getFilterFn(),o=r?.find(d=>d.id===e.id),a=Xo(n,o?o.value:void 0);if(PE(i,a,e)){var s;return(s=r?.filter(d=>d.id!==e.id))!=null?s:[]}const u={id:e.id,value:a};if(o){var c;return(c=r?.map(d=>d.id===e.id?u:d))!=null?c:[]}return r!=null&&r.length?[...r,u]:[u]})}},createRow:(e,t)=>{e.columnFilters={},e.columnFiltersMeta={}},createTable:e=>{e.setColumnFilters=t=>{const n=e.getAllLeafColumns(),r=i=>{var o;return(o=Xo(t,i))==null?void 0:o.filter(a=>{const s=n.find(u=>u.id===a.id);if(s){const u=s.getFilterFn();if(PE(u,a.value,s))return!1}return!0})};e.options.onColumnFiltersChange==null||e.options.onColumnFiltersChange(r)},e.resetColumnFilters=t=>{var n,r;e.setColumnFilters(t?[]:(n=(r=e.initialState)==null?void 0:r.columnFilters)!=null?n:[])},e.getPreFilteredRowModel=()=>e.getCoreRowModel(),e.getFilteredRowModel=()=>(!e._getFilteredRowModel&&e.options.getFilteredRowModel&&(e._getFilteredRowModel=e.options.getFilteredRowModel(e)),e.options.manualFiltering||!e._getFilteredRowModel?e.getPreFilteredRowModel():e._getFilteredRowModel())}};function PE(e,t,n){return(e&&e.autoRemove?e.autoRemove(t,n):!1)||typeof t>"u"||typeof t=="string"&&!t}const GY=(e,t,n)=>n.reduce((r,i)=>{const o=i.getValue(e);return r+(typeof o=="number"?o:0)},0),qY=(e,t,n)=>{let r;return n.forEach(i=>{const o=i.getValue(e);o!=null&&(r>o||r===void 0&&o>=o)&&(r=o)}),r},KY=(e,t,n)=>{let r;return n.forEach(i=>{const o=i.getValue(e);o!=null&&(r<o||r===void 0&&o>=o)&&(r=o)}),r},YY=(e,t,n)=>{let r,i;return n.forEach(o=>{const a=o.getValue(e);a!=null&&(r===void 0?a>=a&&(r=i=a):(r>a&&(r=a),i<a&&(i=a)))}),[r,i]},XY=(e,t)=>{let n=0,r=0;if(t.forEach(i=>{let o=i.getValue(e);o!=null&&(o=+o)>=o&&(++n,r+=o)}),n)return r/n},ZY=(e,t)=>{if(!t.length)return;const n=t.map(o=>o.getValue(e));if(!FY(n))return;if(n.length===1)return n[0];const r=Math.floor(n.length/2),i=n.sort((o,a)=>o-a);return n.length%2!==0?i[r]:(i[r-1]+i[r])/2},QY=(e,t)=>Array.from(new Set(t.map(n=>n.getValue(e))).values()),JY=(e,t)=>new Set(t.map(n=>n.getValue(e))).size,eX=(e,t)=>t.length,$m={sum:GY,min:qY,max:KY,extent:YY,mean:XY,median:ZY,unique:QY,uniqueCount:JY,count:eX},tX={getDefaultColumnDef:()=>({aggregatedCell:e=>{var t,n;return(t=(n=e.getValue())==null||n.toString==null?void 0:n.toString())!=null?t:null},aggregationFn:"auto"}),getInitialState:e=>({grouping:[],...e}),getDefaultOptions:e=>({onGroupingChange:Ir("grouping",e),groupedColumnMode:"reorder"}),createColumn:(e,t)=>{e.toggleGrouping=()=>{t.setGrouping(n=>n!=null&&n.includes(e.id)?n.filter(r=>r!==e.id):[...n??[],e.id])},e.getCanGroup=()=>{var n,r;return((n=e.columnDef.enableGrouping)!=null?n:!0)&&((r=t.options.enableGrouping)!=null?r:!0)&&(!!e.accessorFn||!!e.columnDef.getGroupingValue)},e.getIsGrouped=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.includes(e.id)},e.getGroupedIndex=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.indexOf(e.id)},e.getToggleGroupingHandler=()=>{const n=e.getCanGroup();return()=>{n&&e.toggleGrouping()}},e.getAutoAggregationFn=()=>{const n=t.getCoreRowModel().flatRows[0],r=n?.getValue(e.id);if(typeof r=="number")return $m.sum;if(Object.prototype.toString.call(r)==="[object Date]")return $m.extent},e.getAggregationFn=()=>{var n,r;if(!e)throw new Error;return bh(e.columnDef.aggregationFn)?e.columnDef.aggregationFn:e.columnDef.aggregationFn==="auto"?e.getAutoAggregationFn():(n=(r=t.options.aggregationFns)==null?void 0:r[e.columnDef.aggregationFn])!=null?n:$m[e.columnDef.aggregationFn]}},createTable:e=>{e.setGrouping=t=>e.options.onGroupingChange==null?void 0:e.options.onGroupingChange(t),e.resetGrouping=t=>{var n,r;e.setGrouping(t?[]:(n=(r=e.initialState)==null?void 0:r.grouping)!=null?n:[])},e.getPreGroupedRowModel=()=>e.getFilteredRowModel(),e.getGroupedRowModel=()=>(!e._getGroupedRowModel&&e.options.getGroupedRowModel&&(e._getGroupedRowModel=e.options.getGroupedRowModel(e)),e.options.manualGrouping||!e._getGroupedRowModel?e.getPreGroupedRowModel():e._getGroupedRowModel())},createRow:(e,t)=>{e.getIsGrouped=()=>!!e.groupingColumnId,e.getGroupingValue=n=>{if(e._groupingValuesCache.hasOwnProperty(n))return e._groupingValuesCache[n];const r=t.getColumn(n);return r!=null&&r.columnDef.getGroupingValue?(e._groupingValuesCache[n]=r.columnDef.getGroupingValue(e.original),e._groupingValuesCache[n]):e.getValue(n)},e._groupingValuesCache={}},createCell:(e,t,n,r)=>{e.getIsGrouped=()=>t.getIsGrouped()&&t.id===n.groupingColumnId,e.getIsPlaceholder=()=>!e.getIsGrouped()&&t.getIsGrouped(),e.getIsAggregated=()=>{var i;return!e.getIsGrouped()&&!e.getIsPlaceholder()&&!!((i=n.subRows)!=null&&i.length)}}};function nX(e,t,n){if(!(t!=null&&t.length)||!n)return e;const r=e.filter(o=>!t.includes(o.id));return n==="remove"?r:[...t.map(o=>e.find(a=>a.id===o)).filter(Boolean),...r]}const rX={getInitialState:e=>({columnOrder:[],...e}),getDefaultOptions:e=>({onColumnOrderChange:Ir("columnOrder",e)}),createColumn:(e,t)=>{e.getIndex=Ue(n=>[Du(t,n)],n=>n.findIndex(r=>r.id===e.id),Ge(t.options,"debugColumns","getIndex")),e.getIsFirstColumn=n=>{var r;return((r=Du(t,n)[0])==null?void 0:r.id)===e.id},e.getIsLastColumn=n=>{var r;const i=Du(t,n);return((r=i[i.length-1])==null?void 0:r.id)===e.id}},createTable:e=>{e.setColumnOrder=t=>e.options.onColumnOrderChange==null?void 0:e.options.onColumnOrderChange(t),e.resetColumnOrder=t=>{var n;e.setColumnOrder(t?[]:(n=e.initialState.columnOrder)!=null?n:[])},e._getOrderColumnsFn=Ue(()=>[e.getState().columnOrder,e.getState().grouping,e.options.groupedColumnMode],(t,n,r)=>i=>{let o=[];if(!(t!=null&&t.length))o=i;else{const a=[...t],s=[...i];for(;s.length&&a.length;){const u=a.shift(),c=s.findIndex(d=>d.id===u);c>-1&&o.push(s.splice(c,1)[0])}o=[...o,...s]}return nX(o,n,r)},Ge(e.options,"debugTable","_getOrderColumnsFn"))}},Fm=()=>({left:[],right:[]}),iX={getInitialState:e=>({columnPinning:Fm(),...e}),getDefaultOptions:e=>({onColumnPinningChange:Ir("columnPinning",e)}),createColumn:(e,t)=>{e.pin=n=>{const r=e.getLeafColumns().map(i=>i.id).filter(Boolean);t.setColumnPinning(i=>{var o,a;if(n==="right"){var s,u;return{left:((s=i?.left)!=null?s:[]).filter(p=>!(r!=null&&r.includes(p))),right:[...((u=i?.right)!=null?u:[]).filter(p=>!(r!=null&&r.includes(p))),...r]}}if(n==="left"){var c,d;return{left:[...((c=i?.left)!=null?c:[]).filter(p=>!(r!=null&&r.includes(p))),...r],right:((d=i?.right)!=null?d:[]).filter(p=>!(r!=null&&r.includes(p)))}}return{left:((o=i?.left)!=null?o:[]).filter(p=>!(r!=null&&r.includes(p))),right:((a=i?.right)!=null?a:[]).filter(p=>!(r!=null&&r.includes(p)))}})},e.getCanPin=()=>e.getLeafColumns().some(r=>{var i,o,a;return((i=r.columnDef.enablePinning)!=null?i:!0)&&((o=(a=t.options.enableColumnPinning)!=null?a:t.options.enablePinning)!=null?o:!0)}),e.getIsPinned=()=>{const n=e.getLeafColumns().map(s=>s.id),{left:r,right:i}=t.getState().columnPinning,o=n.some(s=>r?.includes(s)),a=n.some(s=>i?.includes(s));return o?"left":a?"right":!1},e.getPinnedIndex=()=>{var n,r;const i=e.getIsPinned();return i?(n=(r=t.getState().columnPinning)==null||(r=r[i])==null?void 0:r.indexOf(e.id))!=null?n:-1:0}},createRow:(e,t)=>{e.getCenterVisibleCells=Ue(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left,t.getState().columnPinning.right],(n,r,i)=>{const o=[...r??[],...i??[]];return n.filter(a=>!o.includes(a.column.id))},Ge(t.options,"debugRows","getCenterVisibleCells")),e.getLeftVisibleCells=Ue(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left],(n,r)=>(r??[]).map(o=>n.find(a=>a.column.id===o)).filter(Boolean).map(o=>({...o,position:"left"})),Ge(t.options,"debugRows","getLeftVisibleCells")),e.getRightVisibleCells=Ue(()=>[e._getAllVisibleCells(),t.getState().columnPinning.right],(n,r)=>(r??[]).map(o=>n.find(a=>a.column.id===o)).filter(Boolean).map(o=>({...o,position:"right"})),Ge(t.options,"debugRows","getRightVisibleCells"))},createTable:e=>{e.setColumnPinning=t=>e.options.onColumnPinningChange==null?void 0:e.options.onColumnPinningChange(t),e.resetColumnPinning=t=>{var n,r;return e.setColumnPinning(t?Fm():(n=(r=e.initialState)==null?void 0:r.columnPinning)!=null?n:Fm())},e.getIsSomeColumnsPinned=t=>{var n;const r=e.getState().columnPinning;if(!t){var i,o;return!!((i=r.left)!=null&&i.length||(o=r.right)!=null&&o.length)}return!!((n=r[t])!=null&&n.length)},e.getLeftLeafColumns=Ue(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left],(t,n)=>(n??[]).map(r=>t.find(i=>i.id===r)).filter(Boolean),Ge(e.options,"debugColumns","getLeftLeafColumns")),e.getRightLeafColumns=Ue(()=>[e.getAllLeafColumns(),e.getState().columnPinning.right],(t,n)=>(n??[]).map(r=>t.find(i=>i.id===r)).filter(Boolean),Ge(e.options,"debugColumns","getRightLeafColumns")),e.getCenterLeafColumns=Ue(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r)=>{const i=[...n??[],...r??[]];return t.filter(o=>!i.includes(o.id))},Ge(e.options,"debugColumns","getCenterLeafColumns"))}};function oX(e){return e||(typeof document<"u"?document:null)}const td={size:150,minSize:20,maxSize:Number.MAX_SAFE_INTEGER},Vm=()=>({startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]}),aX={getDefaultColumnDef:()=>td,getInitialState:e=>({columnSizing:{},columnSizingInfo:Vm(),...e}),getDefaultOptions:e=>({columnResizeMode:"onEnd",columnResizeDirection:"ltr",onColumnSizingChange:Ir("columnSizing",e),onColumnSizingInfoChange:Ir("columnSizingInfo",e)}),createColumn:(e,t)=>{e.getSize=()=>{var n,r,i;const o=t.getState().columnSizing[e.id];return Math.min(Math.max((n=e.columnDef.minSize)!=null?n:td.minSize,(r=o??e.columnDef.size)!=null?r:td.size),(i=e.columnDef.maxSize)!=null?i:td.maxSize)},e.getStart=Ue(n=>[n,Du(t,n),t.getState().columnSizing],(n,r)=>r.slice(0,e.getIndex(n)).reduce((i,o)=>i+o.getSize(),0),Ge(t.options,"debugColumns","getStart")),e.getAfter=Ue(n=>[n,Du(t,n),t.getState().columnSizing],(n,r)=>r.slice(e.getIndex(n)+1).reduce((i,o)=>i+o.getSize(),0),Ge(t.options,"debugColumns","getAfter")),e.resetSize=()=>{t.setColumnSizing(n=>{let{[e.id]:r,...i}=n;return i})},e.getCanResize=()=>{var n,r;return((n=e.columnDef.enableResizing)!=null?n:!0)&&((r=t.options.enableColumnResizing)!=null?r:!0)},e.getIsResizing=()=>t.getState().columnSizingInfo.isResizingColumn===e.id},createHeader:(e,t)=>{e.getSize=()=>{let n=0;const r=i=>{if(i.subHeaders.length)i.subHeaders.forEach(r);else{var o;n+=(o=i.column.getSize())!=null?o:0}};return r(e),n},e.getStart=()=>{if(e.index>0){const n=e.headerGroup.headers[e.index-1];return n.getStart()+n.getSize()}return 0},e.getResizeHandler=n=>{const r=t.getColumn(e.column.id),i=r?.getCanResize();return o=>{if(!r||!i||(o.persist==null||o.persist(),Bm(o)&&o.touches&&o.touches.length>1))return;const a=e.getSize(),s=e?e.getLeafHeaders().map(w=>[w.column.id,w.column.getSize()]):[[r.id,r.getSize()]],u=Bm(o)?Math.round(o.touches[0].clientX):o.clientX,c={},d=(w,C)=>{typeof C=="number"&&(t.setColumnSizingInfo(E=>{var _,O;const R=t.options.columnResizeDirection==="rtl"?-1:1,I=(C-((_=E?.startOffset)!=null?_:0))*R,k=Math.max(I/((O=E?.startSize)!=null?O:0),-.999999);return E.columnSizingStart.forEach(B=>{let[L,V]=B;c[L]=Math.round(Math.max(V+V*k,0)*100)/100}),{...E,deltaOffset:I,deltaPercentage:k}}),(t.options.columnResizeMode==="onChange"||w==="end")&&t.setColumnSizing(E=>({...E,...c})))},p=w=>d("move",w),g=w=>{d("end",w),t.setColumnSizingInfo(C=>({...C,isResizingColumn:!1,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]}))},h=oX(n),v={moveHandler:w=>p(w.clientX),upHandler:w=>{h?.removeEventListener("mousemove",v.moveHandler),h?.removeEventListener("mouseup",v.upHandler),g(w.clientX)}},b={moveHandler:w=>(w.cancelable&&(w.preventDefault(),w.stopPropagation()),p(w.touches[0].clientX),!1),upHandler:w=>{var C;h?.removeEventListener("touchmove",b.moveHandler),h?.removeEventListener("touchend",b.upHandler),w.cancelable&&(w.preventDefault(),w.stopPropagation()),g((C=w.touches[0])==null?void 0:C.clientX)}},y=sX()?{passive:!1}:!1;Bm(o)?(h?.addEventListener("touchmove",b.moveHandler,y),h?.addEventListener("touchend",b.upHandler,y)):(h?.addEventListener("mousemove",v.moveHandler,y),h?.addEventListener("mouseup",v.upHandler,y)),t.setColumnSizingInfo(w=>({...w,startOffset:u,startSize:a,deltaOffset:0,deltaPercentage:0,columnSizingStart:s,isResizingColumn:r.id}))}}},createTable:e=>{e.setColumnSizing=t=>e.options.onColumnSizingChange==null?void 0:e.options.onColumnSizingChange(t),e.setColumnSizingInfo=t=>e.options.onColumnSizingInfoChange==null?void 0:e.options.onColumnSizingInfoChange(t),e.resetColumnSizing=t=>{var n;e.setColumnSizing(t?{}:(n=e.initialState.columnSizing)!=null?n:{})},e.resetHeaderSizeInfo=t=>{var n;e.setColumnSizingInfo(t?Vm():(n=e.initialState.columnSizingInfo)!=null?n:Vm())},e.getTotalSize=()=>{var t,n;return(t=(n=e.getHeaderGroups()[0])==null?void 0:n.headers.reduce((r,i)=>r+i.getSize(),0))!=null?t:0},e.getLeftTotalSize=()=>{var t,n;return(t=(n=e.getLeftHeaderGroups()[0])==null?void 0:n.headers.reduce((r,i)=>r+i.getSize(),0))!=null?t:0},e.getCenterTotalSize=()=>{var t,n;return(t=(n=e.getCenterHeaderGroups()[0])==null?void 0:n.headers.reduce((r,i)=>r+i.getSize(),0))!=null?t:0},e.getRightTotalSize=()=>{var t,n;return(t=(n=e.getRightHeaderGroups()[0])==null?void 0:n.headers.reduce((r,i)=>r+i.getSize(),0))!=null?t:0}}};let nd=null;function sX(){if(typeof nd=="boolean")return nd;let e=!1;try{const t={get passive(){return e=!0,!1}},n=()=>{};window.addEventListener("test",n,t),window.removeEventListener("test",n)}catch{e=!1}return nd=e,nd}function Bm(e){return e.type==="touchstart"}const lX={getInitialState:e=>({columnVisibility:{},...e}),getDefaultOptions:e=>({onColumnVisibilityChange:Ir("columnVisibility",e)}),createColumn:(e,t)=>{e.toggleVisibility=n=>{e.getCanHide()&&t.setColumnVisibility(r=>({...r,[e.id]:n??!e.getIsVisible()}))},e.getIsVisible=()=>{var n,r;const i=e.columns;return(n=i.length?i.some(o=>o.getIsVisible()):(r=t.getState().columnVisibility)==null?void 0:r[e.id])!=null?n:!0},e.getCanHide=()=>{var n,r;return((n=e.columnDef.enableHiding)!=null?n:!0)&&((r=t.options.enableHiding)!=null?r:!0)},e.getToggleVisibilityHandler=()=>n=>{e.toggleVisibility==null||e.toggleVisibility(n.target.checked)}},createRow:(e,t)=>{e._getAllVisibleCells=Ue(()=>[e.getAllCells(),t.getState().columnVisibility],n=>n.filter(r=>r.column.getIsVisible()),Ge(t.options,"debugRows","_getAllVisibleCells")),e.getVisibleCells=Ue(()=>[e.getLeftVisibleCells(),e.getCenterVisibleCells(),e.getRightVisibleCells()],(n,r,i)=>[...n,...r,...i],Ge(t.options,"debugRows","getVisibleCells"))},createTable:e=>{const t=(n,r)=>Ue(()=>[r(),r().filter(i=>i.getIsVisible()).map(i=>i.id).join("_")],i=>i.filter(o=>o.getIsVisible==null?void 0:o.getIsVisible()),Ge(e.options,"debugColumns",n));e.getVisibleFlatColumns=t("getVisibleFlatColumns",()=>e.getAllFlatColumns()),e.getVisibleLeafColumns=t("getVisibleLeafColumns",()=>e.getAllLeafColumns()),e.getLeftVisibleLeafColumns=t("getLeftVisibleLeafColumns",()=>e.getLeftLeafColumns()),e.getRightVisibleLeafColumns=t("getRightVisibleLeafColumns",()=>e.getRightLeafColumns()),e.getCenterVisibleLeafColumns=t("getCenterVisibleLeafColumns",()=>e.getCenterLeafColumns()),e.setColumnVisibility=n=>e.options.onColumnVisibilityChange==null?void 0:e.options.onColumnVisibilityChange(n),e.resetColumnVisibility=n=>{var r;e.setColumnVisibility(n?{}:(r=e.initialState.columnVisibility)!=null?r:{})},e.toggleAllColumnsVisible=n=>{var r;n=(r=n)!=null?r:!e.getIsAllColumnsVisible(),e.setColumnVisibility(e.getAllLeafColumns().reduce((i,o)=>({...i,[o.id]:n||!(o.getCanHide!=null&&o.getCanHide())}),{}))},e.getIsAllColumnsVisible=()=>!e.getAllLeafColumns().some(n=>!(n.getIsVisible!=null&&n.getIsVisible())),e.getIsSomeColumnsVisible=()=>e.getAllLeafColumns().some(n=>n.getIsVisible==null?void 0:n.getIsVisible()),e.getToggleAllColumnsVisibilityHandler=()=>n=>{var r;e.toggleAllColumnsVisible((r=n.target)==null?void 0:r.checked)}}};function Du(e,t){return t?t==="center"?e.getCenterVisibleLeafColumns():t==="left"?e.getLeftVisibleLeafColumns():e.getRightVisibleLeafColumns():e.getVisibleLeafColumns()}const uX={createTable:e=>{e._getGlobalFacetedRowModel=e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,"__global__"),e.getGlobalFacetedRowModel=()=>e.options.manualFiltering||!e._getGlobalFacetedRowModel?e.getPreFilteredRowModel():e._getGlobalFacetedRowModel(),e._getGlobalFacetedUniqueValues=e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,"__global__"),e.getGlobalFacetedUniqueValues=()=>e._getGlobalFacetedUniqueValues?e._getGlobalFacetedUniqueValues():new Map,e._getGlobalFacetedMinMaxValues=e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,"__global__"),e.getGlobalFacetedMinMaxValues=()=>{if(e._getGlobalFacetedMinMaxValues)return e._getGlobalFacetedMinMaxValues()}}},cX={getInitialState:e=>({globalFilter:void 0,...e}),getDefaultOptions:e=>({onGlobalFilterChange:Ir("globalFilter",e),globalFilterFn:"auto",getColumnCanGlobalFilter:t=>{var n;const r=(n=e.getCoreRowModel().flatRows[0])==null||(n=n._getAllCellsByColumnId()[t.id])==null?void 0:n.getValue();return typeof r=="string"||typeof r=="number"}}),createColumn:(e,t)=>{e.getCanGlobalFilter=()=>{var n,r,i,o;return((n=e.columnDef.enableGlobalFilter)!=null?n:!0)&&((r=t.options.enableGlobalFilter)!=null?r:!0)&&((i=t.options.enableFilters)!=null?i:!0)&&((o=t.options.getColumnCanGlobalFilter==null?void 0:t.options.getColumnCanGlobalFilter(e))!=null?o:!0)&&!!e.accessorFn}},createTable:e=>{e.getGlobalAutoFilterFn=()=>Ji.includesString,e.getGlobalFilterFn=()=>{var t,n;const{globalFilterFn:r}=e.options;return bh(r)?r:r==="auto"?e.getGlobalAutoFilterFn():(t=(n=e.options.filterFns)==null?void 0:n[r])!=null?t:Ji[r]},e.setGlobalFilter=t=>{e.options.onGlobalFilterChange==null||e.options.onGlobalFilterChange(t)},e.resetGlobalFilter=t=>{e.setGlobalFilter(t?void 0:e.initialState.globalFilter)}}},fX={getInitialState:e=>({expanded:{},...e}),getDefaultOptions:e=>({onExpandedChange:Ir("expanded",e),paginateExpandedRows:!0}),createTable:e=>{let t=!1,n=!1;e._autoResetExpanded=()=>{var r,i;if(!t){e._queue(()=>{t=!0});return}if((r=(i=e.options.autoResetAll)!=null?i:e.options.autoResetExpanded)!=null?r:!e.options.manualExpanding){if(n)return;n=!0,e._queue(()=>{e.resetExpanded(),n=!1})}},e.setExpanded=r=>e.options.onExpandedChange==null?void 0:e.options.onExpandedChange(r),e.toggleAllRowsExpanded=r=>{r??!e.getIsAllRowsExpanded()?e.setExpanded(!0):e.setExpanded({})},e.resetExpanded=r=>{var i,o;e.setExpanded(r?{}:(i=(o=e.initialState)==null?void 0:o.expanded)!=null?i:{})},e.getCanSomeRowsExpand=()=>e.getPrePaginationRowModel().flatRows.some(r=>r.getCanExpand()),e.getToggleAllRowsExpandedHandler=()=>r=>{r.persist==null||r.persist(),e.toggleAllRowsExpanded()},e.getIsSomeRowsExpanded=()=>{const r=e.getState().expanded;return r===!0||Object.values(r).some(Boolean)},e.getIsAllRowsExpanded=()=>{const r=e.getState().expanded;return typeof r=="boolean"?r===!0:!(!Object.keys(r).length||e.getRowModel().flatRows.some(i=>!i.getIsExpanded()))},e.getExpandedDepth=()=>{let r=0;return(e.getState().expanded===!0?Object.keys(e.getRowModel().rowsById):Object.keys(e.getState().expanded)).forEach(o=>{const a=o.split(".");r=Math.max(r,a.length)}),r},e.getPreExpandedRowModel=()=>e.getSortedRowModel(),e.getExpandedRowModel=()=>(!e._getExpandedRowModel&&e.options.getExpandedRowModel&&(e._getExpandedRowModel=e.options.getExpandedRowModel(e)),e.options.manualExpanding||!e._getExpandedRowModel?e.getPreExpandedRowModel():e._getExpandedRowModel())},createRow:(e,t)=>{e.toggleExpanded=n=>{t.setExpanded(r=>{var i;const o=r===!0?!0:!!(r!=null&&r[e.id]);let a={};if(r===!0?Object.keys(t.getRowModel().rowsById).forEach(s=>{a[s]=!0}):a=r,n=(i=n)!=null?i:!o,!o&&n)return{...a,[e.id]:!0};if(o&&!n){const{[e.id]:s,...u}=a;return u}return r})},e.getIsExpanded=()=>{var n;const r=t.getState().expanded;return!!((n=t.options.getIsRowExpanded==null?void 0:t.options.getIsRowExpanded(e))!=null?n:r===!0||r?.[e.id])},e.getCanExpand=()=>{var n,r,i;return(n=t.options.getRowCanExpand==null?void 0:t.options.getRowCanExpand(e))!=null?n:((r=t.options.enableExpanding)!=null?r:!0)&&!!((i=e.subRows)!=null&&i.length)},e.getIsAllParentsExpanded=()=>{let n=!0,r=e;for(;n&&r.parentId;)r=t.getRow(r.parentId,!0),n=r.getIsExpanded();return n},e.getToggleExpandedHandler=()=>{const n=e.getCanExpand();return()=>{n&&e.toggleExpanded()}}}},Uy=0,Gy=10,zm=()=>({pageIndex:Uy,pageSize:Gy}),dX={getInitialState:e=>({...e,pagination:{...zm(),...e?.pagination}}),getDefaultOptions:e=>({onPaginationChange:Ir("pagination",e)}),createTable:e=>{let t=!1,n=!1;e._autoResetPageIndex=()=>{var r,i;if(!t){e._queue(()=>{t=!0});return}if((r=(i=e.options.autoResetAll)!=null?i:e.options.autoResetPageIndex)!=null?r:!e.options.manualPagination){if(n)return;n=!0,e._queue(()=>{e.resetPageIndex(),n=!1})}},e.setPagination=r=>{const i=o=>Xo(r,o);return e.options.onPaginationChange==null?void 0:e.options.onPaginationChange(i)},e.resetPagination=r=>{var i;e.setPagination(r?zm():(i=e.initialState.pagination)!=null?i:zm())},e.setPageIndex=r=>{e.setPagination(i=>{let o=Xo(r,i.pageIndex);const a=typeof e.options.pageCount>"u"||e.options.pageCount===-1?Number.MAX_SAFE_INTEGER:e.options.pageCount-1;return o=Math.max(0,Math.min(o,a)),{...i,pageIndex:o}})},e.resetPageIndex=r=>{var i,o;e.setPageIndex(r?Uy:(i=(o=e.initialState)==null||(o=o.pagination)==null?void 0:o.pageIndex)!=null?i:Uy)},e.resetPageSize=r=>{var i,o;e.setPageSize(r?Gy:(i=(o=e.initialState)==null||(o=o.pagination)==null?void 0:o.pageSize)!=null?i:Gy)},e.setPageSize=r=>{e.setPagination(i=>{const o=Math.max(1,Xo(r,i.pageSize)),a=i.pageSize*i.pageIndex,s=Math.floor(a/o);return{...i,pageIndex:s,pageSize:o}})},e.setPageCount=r=>e.setPagination(i=>{var o;let a=Xo(r,(o=e.options.pageCount)!=null?o:-1);return typeof a=="number"&&(a=Math.max(-1,a)),{...i,pageCount:a}}),e.getPageOptions=Ue(()=>[e.getPageCount()],r=>{let i=[];return r&&r>0&&(i=[...new Array(r)].fill(null).map((o,a)=>a)),i},Ge(e.options,"debugTable","getPageOptions")),e.getCanPreviousPage=()=>e.getState().pagination.pageIndex>0,e.getCanNextPage=()=>{const{pageIndex:r}=e.getState().pagination,i=e.getPageCount();return i===-1?!0:i===0?!1:r<i-1},e.previousPage=()=>e.setPageIndex(r=>r-1),e.nextPage=()=>e.setPageIndex(r=>r+1),e.firstPage=()=>e.setPageIndex(0),e.lastPage=()=>e.setPageIndex(e.getPageCount()-1),e.getPrePaginationRowModel=()=>e.getExpandedRowModel(),e.getPaginationRowModel=()=>(!e._getPaginationRowModel&&e.options.getPaginationRowModel&&(e._getPaginationRowModel=e.options.getPaginationRowModel(e)),e.options.manualPagination||!e._getPaginationRowModel?e.getPrePaginationRowModel():e._getPaginationRowModel()),e.getPageCount=()=>{var r;return(r=e.options.pageCount)!=null?r:Math.ceil(e.getRowCount()/e.getState().pagination.pageSize)},e.getRowCount=()=>{var r;return(r=e.options.rowCount)!=null?r:e.getPrePaginationRowModel().rows.length}}},Wm=()=>({top:[],bottom:[]}),pX={getInitialState:e=>({rowPinning:Wm(),...e}),getDefaultOptions:e=>({onRowPinningChange:Ir("rowPinning",e)}),createRow:(e,t)=>{e.pin=(n,r,i)=>{const o=r?e.getLeafRows().map(u=>{let{id:c}=u;return c}):[],a=i?e.getParentRows().map(u=>{let{id:c}=u;return c}):[],s=new Set([...a,e.id,...o]);t.setRowPinning(u=>{var c,d;if(n==="bottom"){var p,g;return{top:((p=u?.top)!=null?p:[]).filter(b=>!(s!=null&&s.has(b))),bottom:[...((g=u?.bottom)!=null?g:[]).filter(b=>!(s!=null&&s.has(b))),...Array.from(s)]}}if(n==="top"){var h,v;return{top:[...((h=u?.top)!=null?h:[]).filter(b=>!(s!=null&&s.has(b))),...Array.from(s)],bottom:((v=u?.bottom)!=null?v:[]).filter(b=>!(s!=null&&s.has(b)))}}return{top:((c=u?.top)!=null?c:[]).filter(b=>!(s!=null&&s.has(b))),bottom:((d=u?.bottom)!=null?d:[]).filter(b=>!(s!=null&&s.has(b)))}})},e.getCanPin=()=>{var n;const{enableRowPinning:r,enablePinning:i}=t.options;return typeof r=="function"?r(e):(n=r??i)!=null?n:!0},e.getIsPinned=()=>{const n=[e.id],{top:r,bottom:i}=t.getState().rowPinning,o=n.some(s=>r?.includes(s)),a=n.some(s=>i?.includes(s));return o?"top":a?"bottom":!1},e.getPinnedIndex=()=>{var n,r;const i=e.getIsPinned();if(!i)return-1;const o=(n=i==="top"?t.getTopRows():t.getBottomRows())==null?void 0:n.map(a=>{let{id:s}=a;return s});return(r=o?.indexOf(e.id))!=null?r:-1}},createTable:e=>{e.setRowPinning=t=>e.options.onRowPinningChange==null?void 0:e.options.onRowPinningChange(t),e.resetRowPinning=t=>{var n,r;return e.setRowPinning(t?Wm():(n=(r=e.initialState)==null?void 0:r.rowPinning)!=null?n:Wm())},e.getIsSomeRowsPinned=t=>{var n;const r=e.getState().rowPinning;if(!t){var i,o;return!!((i=r.top)!=null&&i.length||(o=r.bottom)!=null&&o.length)}return!!((n=r[t])!=null&&n.length)},e._getPinnedRows=(t,n,r)=>{var i;return((i=e.options.keepPinnedRows)==null||i?(n??[]).map(a=>{const s=e.getRow(a,!0);return s.getIsAllParentsExpanded()?s:null}):(n??[]).map(a=>t.find(s=>s.id===a))).filter(Boolean).map(a=>({...a,position:r}))},e.getTopRows=Ue(()=>[e.getRowModel().rows,e.getState().rowPinning.top],(t,n)=>e._getPinnedRows(t,n,"top"),Ge(e.options,"debugRows","getTopRows")),e.getBottomRows=Ue(()=>[e.getRowModel().rows,e.getState().rowPinning.bottom],(t,n)=>e._getPinnedRows(t,n,"bottom"),Ge(e.options,"debugRows","getBottomRows")),e.getCenterRows=Ue(()=>[e.getRowModel().rows,e.getState().rowPinning.top,e.getState().rowPinning.bottom],(t,n,r)=>{const i=new Set([...n??[],...r??[]]);return t.filter(o=>!i.has(o.id))},Ge(e.options,"debugRows","getCenterRows"))}},hX={getInitialState:e=>({rowSelection:{},...e}),getDefaultOptions:e=>({onRowSelectionChange:Ir("rowSelection",e),enableRowSelection:!0,enableMultiRowSelection:!0,enableSubRowSelection:!0}),createTable:e=>{e.setRowSelection=t=>e.options.onRowSelectionChange==null?void 0:e.options.onRowSelectionChange(t),e.resetRowSelection=t=>{var n;return e.setRowSelection(t?{}:(n=e.initialState.rowSelection)!=null?n:{})},e.toggleAllRowsSelected=t=>{e.setRowSelection(n=>{t=typeof t<"u"?t:!e.getIsAllRowsSelected();const r={...n},i=e.getPreGroupedRowModel().flatRows;return t?i.forEach(o=>{o.getCanSelect()&&(r[o.id]=!0)}):i.forEach(o=>{delete r[o.id]}),r})},e.toggleAllPageRowsSelected=t=>e.setRowSelection(n=>{const r=typeof t<"u"?t:!e.getIsAllPageRowsSelected(),i={...n};return e.getRowModel().rows.forEach(o=>{qy(i,o.id,r,!0,e)}),i}),e.getPreSelectedRowModel=()=>e.getCoreRowModel(),e.getSelectedRowModel=Ue(()=>[e.getState().rowSelection,e.getCoreRowModel()],(t,n)=>Object.keys(t).length?Hm(e,n):{rows:[],flatRows:[],rowsById:{}},Ge(e.options,"debugTable","getSelectedRowModel")),e.getFilteredSelectedRowModel=Ue(()=>[e.getState().rowSelection,e.getFilteredRowModel()],(t,n)=>Object.keys(t).length?Hm(e,n):{rows:[],flatRows:[],rowsById:{}},Ge(e.options,"debugTable","getFilteredSelectedRowModel")),e.getGroupedSelectedRowModel=Ue(()=>[e.getState().rowSelection,e.getSortedRowModel()],(t,n)=>Object.keys(t).length?Hm(e,n):{rows:[],flatRows:[],rowsById:{}},Ge(e.options,"debugTable","getGroupedSelectedRowModel")),e.getIsAllRowsSelected=()=>{const t=e.getFilteredRowModel().flatRows,{rowSelection:n}=e.getState();let r=!!(t.length&&Object.keys(n).length);return r&&t.some(i=>i.getCanSelect()&&!n[i.id])&&(r=!1),r},e.getIsAllPageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows.filter(i=>i.getCanSelect()),{rowSelection:n}=e.getState();let r=!!t.length;return r&&t.some(i=>!n[i.id])&&(r=!1),r},e.getIsSomeRowsSelected=()=>{var t;const n=Object.keys((t=e.getState().rowSelection)!=null?t:{}).length;return n>0&&n<e.getFilteredRowModel().flatRows.length},e.getIsSomePageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows;return e.getIsAllPageRowsSelected()?!1:t.filter(n=>n.getCanSelect()).some(n=>n.getIsSelected()||n.getIsSomeSelected())},e.getToggleAllRowsSelectedHandler=()=>t=>{e.toggleAllRowsSelected(t.target.checked)},e.getToggleAllPageRowsSelectedHandler=()=>t=>{e.toggleAllPageRowsSelected(t.target.checked)}},createRow:(e,t)=>{e.toggleSelected=(n,r)=>{const i=e.getIsSelected();t.setRowSelection(o=>{var a;if(n=typeof n<"u"?n:!i,e.getCanSelect()&&i===n)return o;const s={...o};return qy(s,e.id,n,(a=r?.selectChildren)!=null?a:!0,t),s})},e.getIsSelected=()=>{const{rowSelection:n}=t.getState();return bx(e,n)},e.getIsSomeSelected=()=>{const{rowSelection:n}=t.getState();return Ky(e,n)==="some"},e.getIsAllSubRowsSelected=()=>{const{rowSelection:n}=t.getState();return Ky(e,n)==="all"},e.getCanSelect=()=>{var n;return typeof t.options.enableRowSelection=="function"?t.options.enableRowSelection(e):(n=t.options.enableRowSelection)!=null?n:!0},e.getCanSelectSubRows=()=>{var n;return typeof t.options.enableSubRowSelection=="function"?t.options.enableSubRowSelection(e):(n=t.options.enableSubRowSelection)!=null?n:!0},e.getCanMultiSelect=()=>{var n;return typeof t.options.enableMultiRowSelection=="function"?t.options.enableMultiRowSelection(e):(n=t.options.enableMultiRowSelection)!=null?n:!0},e.getToggleSelectedHandler=()=>{const n=e.getCanSelect();return r=>{var i;n&&e.toggleSelected((i=r.target)==null?void 0:i.checked)}}}},qy=(e,t,n,r,i)=>{var o;const a=i.getRow(t,!0);n?(a.getCanMultiSelect()||Object.keys(e).forEach(s=>delete e[s]),a.getCanSelect()&&(e[t]=!0)):delete e[t],r&&(o=a.subRows)!=null&&o.length&&a.getCanSelectSubRows()&&a.subRows.forEach(s=>qy(e,s.id,n,r,i))};function Hm(e,t){const n=e.getState().rowSelection,r=[],i={},o=function(a,s){return a.map(u=>{var c;const d=bx(u,n);if(d&&(r.push(u),i[u.id]=u),(c=u.subRows)!=null&&c.length&&(u={...u,subRows:o(u.subRows)}),d)return u}).filter(Boolean)};return{rows:o(t.rows),flatRows:r,rowsById:i}}function bx(e,t){var n;return(n=t[e.id])!=null?n:!1}function Ky(e,t,n){var r;if(!((r=e.subRows)!=null&&r.length))return!1;let i=!0,o=!1;return e.subRows.forEach(a=>{if(!(o&&!i)&&(a.getCanSelect()&&(bx(a,t)?o=!0:i=!1),a.subRows&&a.subRows.length)){const s=Ky(a,t);s==="all"?o=!0:(s==="some"&&(o=!0),i=!1)}}),i?"all":o?"some":!1}const Yy=/([0-9]+)/gm,gX=(e,t,n)=>xM(aa(e.getValue(n)).toLowerCase(),aa(t.getValue(n)).toLowerCase()),mX=(e,t,n)=>xM(aa(e.getValue(n)),aa(t.getValue(n))),vX=(e,t,n)=>xx(aa(e.getValue(n)).toLowerCase(),aa(t.getValue(n)).toLowerCase()),yX=(e,t,n)=>xx(aa(e.getValue(n)),aa(t.getValue(n))),bX=(e,t,n)=>{const r=e.getValue(n),i=t.getValue(n);return r>i?1:r<i?-1:0},xX=(e,t,n)=>xx(e.getValue(n),t.getValue(n));function xx(e,t){return e===t?0:e>t?1:-1}function aa(e){return typeof e=="number"?isNaN(e)||e===1/0||e===-1/0?"":String(e):typeof e=="string"?e:""}function xM(e,t){const n=e.split(Yy).filter(Boolean),r=t.split(Yy).filter(Boolean);for(;n.length&&r.length;){const i=n.shift(),o=r.shift(),a=parseInt(i,10),s=parseInt(o,10),u=[a,s].sort();if(isNaN(u[0])){if(i>o)return 1;if(o>i)return-1;continue}if(isNaN(u[1]))return isNaN(a)?-1:1;if(a>s)return 1;if(s>a)return-1}return n.length-r.length}const cu={alphanumeric:gX,alphanumericCaseSensitive:mX,text:vX,textCaseSensitive:yX,datetime:bX,basic:xX},wX={getInitialState:e=>({sorting:[],...e}),getDefaultColumnDef:()=>({sortingFn:"auto",sortUndefined:1}),getDefaultOptions:e=>({onSortingChange:Ir("sorting",e),isMultiSortEvent:t=>t.shiftKey}),createColumn:(e,t)=>{e.getAutoSortingFn=()=>{const n=t.getFilteredRowModel().flatRows.slice(10);let r=!1;for(const i of n){const o=i?.getValue(e.id);if(Object.prototype.toString.call(o)==="[object Date]")return cu.datetime;if(typeof o=="string"&&(r=!0,o.split(Yy).length>1))return cu.alphanumeric}return r?cu.text:cu.basic},e.getAutoSortDir=()=>{const n=t.getFilteredRowModel().flatRows[0];return typeof n?.getValue(e.id)=="string"?"asc":"desc"},e.getSortingFn=()=>{var n,r;if(!e)throw new Error;return bh(e.columnDef.sortingFn)?e.columnDef.sortingFn:e.columnDef.sortingFn==="auto"?e.getAutoSortingFn():(n=(r=t.options.sortingFns)==null?void 0:r[e.columnDef.sortingFn])!=null?n:cu[e.columnDef.sortingFn]},e.toggleSorting=(n,r)=>{const i=e.getNextSortingOrder(),o=typeof n<"u"&&n!==null;t.setSorting(a=>{const s=a?.find(h=>h.id===e.id),u=a?.findIndex(h=>h.id===e.id);let c=[],d,p=o?n:i==="desc";if(a!=null&&a.length&&e.getCanMultiSort()&&r?s?d="toggle":d="add":a!=null&&a.length&&u!==a.length-1?d="replace":s?d="toggle":d="replace",d==="toggle"&&(o||i||(d="remove")),d==="add"){var g;c=[...a,{id:e.id,desc:p}],c.splice(0,c.length-((g=t.options.maxMultiSortColCount)!=null?g:Number.MAX_SAFE_INTEGER))}else d==="toggle"?c=a.map(h=>h.id===e.id?{...h,desc:p}:h):d==="remove"?c=a.filter(h=>h.id!==e.id):c=[{id:e.id,desc:p}];return c})},e.getFirstSortDir=()=>{var n,r;return((n=(r=e.columnDef.sortDescFirst)!=null?r:t.options.sortDescFirst)!=null?n:e.getAutoSortDir()==="desc")?"desc":"asc"},e.getNextSortingOrder=n=>{var r,i;const o=e.getFirstSortDir(),a=e.getIsSorted();return a?a!==o&&((r=t.options.enableSortingRemoval)==null||r)&&(!(n&&(i=t.options.enableMultiRemove)!=null)||i)?!1:a==="desc"?"asc":"desc":o},e.getCanSort=()=>{var n,r;return((n=e.columnDef.enableSorting)!=null?n:!0)&&((r=t.options.enableSorting)!=null?r:!0)&&!!e.accessorFn},e.getCanMultiSort=()=>{var n,r;return(n=(r=e.columnDef.enableMultiSort)!=null?r:t.options.enableMultiSort)!=null?n:!!e.accessorFn},e.getIsSorted=()=>{var n;const r=(n=t.getState().sorting)==null?void 0:n.find(i=>i.id===e.id);return r?r.desc?"desc":"asc":!1},e.getSortIndex=()=>{var n,r;return(n=(r=t.getState().sorting)==null?void 0:r.findIndex(i=>i.id===e.id))!=null?n:-1},e.clearSorting=()=>{t.setSorting(n=>n!=null&&n.length?n.filter(r=>r.id!==e.id):[])},e.getToggleSortingHandler=()=>{const n=e.getCanSort();return r=>{n&&(r.persist==null||r.persist(),e.toggleSorting==null||e.toggleSorting(void 0,e.getCanMultiSort()?t.options.isMultiSortEvent==null?void 0:t.options.isMultiSortEvent(r):!1))}}},createTable:e=>{e.setSorting=t=>e.options.onSortingChange==null?void 0:e.options.onSortingChange(t),e.resetSorting=t=>{var n,r;e.setSorting(t?[]:(n=(r=e.initialState)==null?void 0:r.sorting)!=null?n:[])},e.getPreSortedRowModel=()=>e.getGroupedRowModel(),e.getSortedRowModel=()=>(!e._getSortedRowModel&&e.options.getSortedRowModel&&(e._getSortedRowModel=e.options.getSortedRowModel(e)),e.options.manualSorting||!e._getSortedRowModel?e.getPreSortedRowModel():e._getSortedRowModel())}},CX=[WY,lX,rX,iX,HY,UY,uX,cX,wX,tX,fX,dX,pX,hX,aX];function SX(e){var t,n;process.env.NODE_ENV!=="production"&&(e.debugAll||e.debugTable)&&console.info("Creating Table Instance...");const r=[...CX,...(t=e._features)!=null?t:[]];let i={_features:r};const o=i._features.reduce((g,h)=>Object.assign(g,h.getDefaultOptions==null?void 0:h.getDefaultOptions(i)),{}),a=g=>i.options.mergeOptions?i.options.mergeOptions(o,g):{...o,...g};let u={...{},...(n=e.initialState)!=null?n:{}};i._features.forEach(g=>{var h;u=(h=g.getInitialState==null?void 0:g.getInitialState(u))!=null?h:u});const c=[];let d=!1;const p={_features:r,options:{...o,...e},initialState:u,_queue:g=>{c.push(g),d||(d=!0,Promise.resolve().then(()=>{for(;c.length;)c.shift()();d=!1}).catch(h=>setTimeout(()=>{throw h})))},reset:()=>{i.setState(i.initialState)},setOptions:g=>{const h=Xo(g,i.options);i.options=a(h)},getState:()=>i.options.state,setState:g=>{i.options.onStateChange==null||i.options.onStateChange(g)},_getRowId:(g,h,v)=>{var b;return(b=i.options.getRowId==null?void 0:i.options.getRowId(g,h,v))!=null?b:`${v?[v.id,h].join("."):h}`},getCoreRowModel:()=>(i._getCoreRowModel||(i._getCoreRowModel=i.options.getCoreRowModel(i)),i._getCoreRowModel()),getRowModel:()=>i.getPaginationRowModel(),getRow:(g,h)=>{let v=(h?i.getPrePaginationRowModel():i.getRowModel()).rowsById[g];if(!v&&(v=i.getCoreRowModel().rowsById[g],!v))throw process.env.NODE_ENV!=="production"?new Error(`getRow could not find row with ID: ${g}`):new Error;return v},_getDefaultColumnDef:Ue(()=>[i.options.defaultColumn],g=>{var h;return g=(h=g)!=null?h:{},{header:v=>{const b=v.header.column.columnDef;return b.accessorKey?b.accessorKey:b.accessorFn?b.id:null},cell:v=>{var b,y;return(b=(y=v.renderValue())==null||y.toString==null?void 0:y.toString())!=null?b:null},...i._features.reduce((v,b)=>Object.assign(v,b.getDefaultColumnDef==null?void 0:b.getDefaultColumnDef()),{}),...g}},Ge(e,"debugColumns","_getDefaultColumnDef")),_getColumnDefs:()=>i.options.columns,getAllColumns:Ue(()=>[i._getColumnDefs()],g=>{const h=function(v,b,y){return y===void 0&&(y=0),v.map(w=>{const C=zY(i,w,y,b),E=w;return C.columns=E.columns?h(E.columns,C,y+1):[],C})};return h(g)},Ge(e,"debugColumns","getAllColumns")),getAllFlatColumns:Ue(()=>[i.getAllColumns()],g=>g.flatMap(h=>h.getFlatColumns()),Ge(e,"debugColumns","getAllFlatColumns")),_getAllFlatColumnsById:Ue(()=>[i.getAllFlatColumns()],g=>g.reduce((h,v)=>(h[v.id]=v,h),{}),Ge(e,"debugColumns","getAllFlatColumnsById")),getAllLeafColumns:Ue(()=>[i.getAllColumns(),i._getOrderColumnsFn()],(g,h)=>{let v=g.flatMap(b=>b.getLeafColumns());return h(v)},Ge(e,"debugColumns","getAllLeafColumns")),getColumn:g=>{const h=i._getAllFlatColumnsById()[g];return process.env.NODE_ENV!=="production"&&!h&&console.error(`[Table] Column with id '${g}' does not exist.`),h}};Object.assign(i,p);for(let g=0;g<i._features.length;g++){const h=i._features[g];h==null||h.createTable==null||h.createTable(i)}return i}function EX(){return e=>Ue(()=>[e.options.data],t=>{const n={rows:[],flatRows:[],rowsById:{}},r=function(i,o,a){o===void 0&&(o=0);const s=[];for(let c=0;c<i.length;c++){const d=vx(e,e._getRowId(i[c],c,a),i[c],c,o,void 0,a?.id);if(n.flatRows.push(d),n.rowsById[d.id]=d,s.push(d),e.options.getSubRows){var u;d.originalSubRows=e.options.getSubRows(i[c],c),(u=d.originalSubRows)!=null&&u.length&&(d.subRows=r(d.originalSubRows,o+1,d))}}return s};return n.rows=r(t),n},Ge(e.options,"debugTable","getRowModel",()=>e._autoResetPageIndex()))}function _X(e){const t=[],n=r=>{var i;t.push(r),(i=r.subRows)!=null&&i.length&&r.getIsExpanded()&&r.subRows.forEach(n)};return e.rows.forEach(n),{rows:t,flatRows:e.flatRows,rowsById:e.rowsById}}function OX(e,t,n){return n.options.filterFromLeafRows?PX(e,t,n):AX(e,t,n)}function PX(e,t,n){var r;const i=[],o={},a=(r=n.options.maxLeafRowFilterDepth)!=null?r:100,s=function(u,c){c===void 0&&(c=0);const d=[];for(let g=0;g<u.length;g++){var p;let h=u[g];const v=vx(n,h.id,h.original,h.index,h.depth,void 0,h.parentId);if(v.columnFilters=h.columnFilters,(p=h.subRows)!=null&&p.length&&c<a){if(v.subRows=s(h.subRows,c+1),h=v,t(h)&&!v.subRows.length){d.push(h),o[h.id]=h,i.push(h);continue}if(t(h)||v.subRows.length){d.push(h),o[h.id]=h,i.push(h);continue}}else h=v,t(h)&&(d.push(h),o[h.id]=h,i.push(h))}return d};return{rows:s(e),flatRows:i,rowsById:o}}function AX(e,t,n){var r;const i=[],o={},a=(r=n.options.maxLeafRowFilterDepth)!=null?r:100,s=function(u,c){c===void 0&&(c=0);const d=[];for(let g=0;g<u.length;g++){let h=u[g];if(t(h)){var p;if((p=h.subRows)!=null&&p.length&&c<a){const b=vx(n,h.id,h.original,h.index,h.depth,void 0,h.parentId);b.subRows=s(h.subRows,c+1),h=b}d.push(h),i.push(h),o[h.id]=h}}return d};return{rows:s(e),flatRows:i,rowsById:o}}function RX(){return e=>Ue(()=>[e.getPreFilteredRowModel(),e.getState().columnFilters,e.getState().globalFilter],(t,n,r)=>{if(!t.rows.length||!(n!=null&&n.length)&&!r){for(let g=0;g<t.flatRows.length;g++)t.flatRows[g].columnFilters={},t.flatRows[g].columnFiltersMeta={};return t}const i=[],o=[];(n??[]).forEach(g=>{var h;const v=e.getColumn(g.id);if(!v)return;const b=v.getFilterFn();if(!b){process.env.NODE_ENV!=="production"&&console.warn(`Could not find a valid 'column.filterFn' for column with the ID: ${v.id}.`);return}i.push({id:g.id,filterFn:b,resolvedValue:(h=b.resolveFilterValue==null?void 0:b.resolveFilterValue(g.value))!=null?h:g.value})});const a=(n??[]).map(g=>g.id),s=e.getGlobalFilterFn(),u=e.getAllLeafColumns().filter(g=>g.getCanGlobalFilter());r&&s&&u.length&&(a.push("__global__"),u.forEach(g=>{var h;o.push({id:g.id,filterFn:s,resolvedValue:(h=s.resolveFilterValue==null?void 0:s.resolveFilterValue(r))!=null?h:r})}));let c,d;for(let g=0;g<t.flatRows.length;g++){const h=t.flatRows[g];if(h.columnFilters={},i.length)for(let v=0;v<i.length;v++){c=i[v];const b=c.id;h.columnFilters[b]=c.filterFn(h,b,c.resolvedValue,y=>{h.columnFiltersMeta[b]=y})}if(o.length){for(let v=0;v<o.length;v++){d=o[v];const b=d.id;if(d.filterFn(h,b,d.resolvedValue,y=>{h.columnFiltersMeta[b]=y})){h.columnFilters.__global__=!0;break}}h.columnFilters.__global__!==!0&&(h.columnFilters.__global__=!1)}}const p=g=>{for(let h=0;h<a.length;h++)if(g.columnFilters[a[h]]===!1)return!1;return!0};return OX(t.rows,p,e)},Ge(e.options,"debugTable","getFilteredRowModel",()=>e._autoResetPageIndex()))}function IX(e){return t=>Ue(()=>[t.getState().pagination,t.getPrePaginationRowModel(),t.options.paginateExpandedRows?void 0:t.getState().expanded],(n,r)=>{if(!r.rows.length)return r;const{pageSize:i,pageIndex:o}=n;let{rows:a,flatRows:s,rowsById:u}=r;const c=i*o,d=c+i;a=a.slice(c,d);let p;t.options.paginateExpandedRows?p={rows:a,flatRows:s,rowsById:u}:p=_X({rows:a,flatRows:s,rowsById:u}),p.flatRows=[];const g=h=>{p.flatRows.push(h),h.subRows.length&&h.subRows.forEach(g)};return p.rows.forEach(g),p},Ge(t.options,"debugTable","getPaginationRowModel"))}function TX(){return e=>Ue(()=>[e.getState().sorting,e.getPreSortedRowModel()],(t,n)=>{if(!n.rows.length||!(t!=null&&t.length))return n;const r=e.getState().sorting,i=[],o=r.filter(u=>{var c;return(c=e.getColumn(u.id))==null?void 0:c.getCanSort()}),a={};o.forEach(u=>{const c=e.getColumn(u.id);c&&(a[u.id]={sortUndefined:c.columnDef.sortUndefined,invertSorting:c.columnDef.invertSorting,sortingFn:c.getSortingFn()})});const s=u=>{const c=u.map(d=>({...d}));return c.sort((d,p)=>{for(let h=0;h<o.length;h+=1){var g;const v=o[h],b=a[v.id],y=b.sortUndefined,w=(g=v?.desc)!=null?g:!1;let C=0;if(y){const E=d.getValue(v.id),_=p.getValue(v.id),O=E===void 0,R=_===void 0;if(O||R){if(y==="first")return O?-1:1;if(y==="last")return O?1:-1;C=O&&R?0:O?y:-y}}if(C===0&&(C=b.sortingFn(d,p,v.id)),C!==0)return w&&(C*=-1),b.invertSorting&&(C*=-1),C}return d.index-p.index}),c.forEach(d=>{var p;i.push(d),(p=d.subRows)!=null&&p.length&&(d.subRows=s(d.subRows))}),c};return{rows:s(n.rows),flatRows:i,rowsById:n.rowsById}},Ge(e.options,"debugTable","getSortedRowModel",()=>e._autoResetPageIndex()))}function AE(e,t){return e?kX(e)?x.createElement(e,t):e:null}function kX(e){return NX(e)||typeof e=="function"||MX(e)}function NX(e){return typeof e=="function"&&(()=>{const t=Object.getPrototypeOf(e);return t.prototype&&t.prototype.isReactComponent})()}function MX(e){return typeof e=="object"&&typeof e.$$typeof=="symbol"&&["react.memo","react.forward_ref"].includes(e.$$typeof.description)}function DX(e){const t={state:{},onStateChange:()=>{},renderFallbackValue:null,...e},[n]=x.useState(()=>({current:SX(t)})),[r,i]=x.useState(()=>n.current.initialState);return n.current.setOptions(o=>({...o,...e,state:{...r,...e.state},onStateChange:a=>{i(a),e.onStateChange==null||e.onStateChange(a)}})),n.current}function jX({columns:e,data:t,sorting:n,columnFilters:r,pagination:i,onSortingChange:o,onColumnFiltersChange:a,onPaginationChange:s}){const u={};n&&(u.sorting=n),r&&(u.columnFilters=r),i&&(u.pagination=i);const c=DX({data:t,columns:e,state:u,onSortingChange:o,onColumnFiltersChange:a,onPaginationChange:s,getCoreRowModel:EX(),getPaginationRowModel:IX(),getSortedRowModel:TX(),getFilteredRowModel:RX()});return P.jsx("div",{className:"w-full overflow-hidden",children:P.jsxs(ax,{children:[P.jsx(sx,{children:c.getHeaderGroups().map(d=>P.jsx(Mu,{children:d.headers.map(p=>P.jsx(ux,{children:p.isPlaceholder?null:AE(p.column.columnDef.header,p.getContext())},p.id))},d.id))}),P.jsx(lx,{children:c.getRowModel().rows.length?c.getRowModel().rows.map(d=>P.jsx(Mu,{"data-state":d.getIsSelected()&&"selected",children:d.getVisibleCells().map(p=>P.jsx(Zd,{children:AE(p.column.columnDef.cell,p.getContext())},p.id))},d.id)):P.jsx(Mu,{children:P.jsx(Zd,{colSpan:e.length,className:"h-24 text-center",children:"No results."})})})]})})}const LX=({children:e,text:t,place:n="top",arrow:r=!0,classes:i,color:o="dark",tooltipItemsLimit:a=1/0})=>{const{isOpened:s,togglePopup:u}=mx(),c=j.useMemo(()=>({arrow:o==="dark"?"fill-primary-inverse-bg":"fill-primary-bg",content:o==="dark"?"bg-primary-inverse-bg text-primary-inverse-text":"bg-primary-bg text-primary-text"}),[o]),d=j.useMemo(()=>Array.isArray(t)?(t.length-a>0?t.slice(0,a):t).map((h,v)=>P.jsx("p",{className:i?.tooltipTextItem,children:h},v)):t,[i?.tooltipTextItem,t,a]);return P.jsxs(uM,{open:s,onOpenChange:u,children:[P.jsx(cM,{asChild:!0,className:i?.trigger,children:e}),P.jsxs(gx,{side:n,className:c.content,children:[P.jsx("div",{className:ue(i?.tooltip),children:d}),r&&P.jsx(fM,{className:c.arrow})]})]})},wM=({date:e=[],isValid:t,disabled:n=!1,label:r,description:i,classes:o,ref:a,...s})=>{const u={...t===!0&&!n&&{"aria-valid":!0},...t===!1&&!n&&{"aria-invalid":!0},disabled:n};return P.jsx(lh,{className:o?.fieldset,children:P.jsx(ac,{className:o?.fieldgroup,children:P.jsxs(sc,{className:o?.field,children:[r&&P.jsx(El,{...u,children:r}),e.length>0?P.jsxs(V0,{"data-slot":!0,children:[P.jsx(z0,{ref:a,...s,...u,disabled:n}),e.map(c=>P.jsx(B0,{align:c.position,children:c.component},c.id))]}):P.jsx(F0,{ref:a,...s,...u,disabled:n}),i&&P.jsx(lc,{...u,children:i})]})})})},$X=({...e})=>{const{isOpened:t,togglePopup:n}=mx();return P.jsx(wM,{...e,type:t?"text":"password",date:[{id:"0",position:"inline-end",component:P.jsx(uo,{type:t?"eye-off":"eye",onClick:n,className:"cursor-pointer"})}]})};function FX({classNames:e,id:t,value:n,defaultValue:r,label:i,options:o=[],...a}){return P.jsx(ox,{...a,defaultValue:r,className:ue("w-fit",e?.classNameGroup),children:o.length?o.map(s=>P.jsxs("div",{className:ue("flex items-center gap-3",e?.classNameContainerItem),children:[P.jsx(Xd,{value:s.value,id:s.id,className:e?.classNameGroupItem}),s.label&&P.jsx(Vu,{htmlFor:s.id,className:e?.classNameLabel,children:s.label})]},s.id)):P.jsxs("div",{className:ue("flex items-center gap-3",e?.classNameContainerItem),children:[P.jsx(Xd,{value:n,id:t,className:e?.classNameGroupItem}),i&&P.jsx(Vu,{htmlFor:t,className:e?.classNameLabel,children:i})]})})}const Su=e=>typeof e=="object",CM=e=>Su(e)?e.value:e,VX=e=>e.every(t=>typeof t=="string")||e.every(t=>typeof t=="object")?e:e.map(t=>CM(t)),Um=(e,t)=>e===null||t===null||typeof e=="string"||typeof t=="string"?e===t:e.id===t.id,SM=({list:e,label:t,multiple:n,disabled:r=!1,isValid:i,description:o,onChange:a,...s})=>{const[u,c]=j.useState([]),[d,p]=j.useState(null),[g,h]=j.useState(""),v=e,b=r?"opacity-50":"",y={...i===!0&&!r&&{"aria-valid":!0},...i===!1&&!r&&{"aria-invalid":!0},disabled:r},w=L=>{if(n){const V=Array.isArray(L)?L:L?[L]:[],D=V.length>u.length;c(V),a?.(VX(V)),D&&h("")}else{const V=Array.isArray(L)?L[0]??null:L;Um(d,V)?(p(null),a?.(null)):(p(V),a?.(V)),h("")}},C=L=>{h(L.currentTarget.value)},E=()=>{r||(p(null),a?.(null))},_=n?u:d,O=g.trim().toLowerCase(),R=v.filter(L=>CM(L).toLowerCase().includes(O)),I=(L,V)=>P.jsx(JT,{showRemove:V.withRemove,onClick:V.onClick,className:`${Xb({variant:L.variant,kind:L.kind})}
|
|
168
|
-
${b} ${V.className}`,children:P.jsx(by,{variant:L.variant,classNames:{className:"px-2 py-0"},children:L.value})},String(L.id)),k=L=>P.jsxs(P.Fragment,{children:[L.map(V=>Su(V)?I(V,{withRemove:!r,className:"pl-2.5"}):P.jsx("span",{className:b,children:V},V)),P.jsx(Fy,{...s,...y,placeholder:L.length>0?"":s.placeholder,value:g,onChange:C})]}),B=L=>P.jsxs(P.Fragment,{children:[L&&(Su(L)?I(L,{withRemove:!1,className:"ml-1",onClick:E}):P.jsx(yy,{className:b,onClick:E,children:L})),P.jsx(Fy,{...s,placeholder:L?"":s.placeholder,...y,value:g,onChange:C,className:"flex-1 pl-1"})]});return P.jsx(lh,{children:P.jsx(ac,{children:P.jsxs(KT,{children:[P.jsx(El,{...y,children:t}),P.jsxs(qT,{items:v,multiple:n,autoHighlight:n,value:_,onValueChange:r?void 0:w,children:[n?P.jsxs($y,{disabled:r,className:"pr-8",children:[P.jsx(Ly,{children:k}),P.jsx(qd,{className:"-ml-4.5",disabled:r})]}):P.jsxs($y,{disabled:r,className:"pr-8",children:[P.jsx(Ly,{children:B}),P.jsx(qd,{className:"-ml-4.5",disabled:r})]}),P.jsxs(YT,{children:[P.jsx(QT,{children:"No items found."}),P.jsx(XT,{children:R.map((L,V)=>{const D=n?u.some(H=>Um(H,L)):Um(d,L);return P.jsx(ZT,{disabled:r,value:L,className:`${D?"bg-tertiary-bg":""} ${typeof L=="string"?"py-1":"px-2 py-2"}`,children:Su(L)?P.jsx(by,{dotPosition:"left",variant:L.variant,kind:L.kind,classNames:{className:"px-4 py-1.5"},children:L.value}):P.jsx(yy,{className:"px-4 py-1.5",children:L})},Su(L)?String(L.id):`${L}-${V}`)})})]})]}),P.jsx(lc,{...y,children:o})]})})})};SM.displayName="SelectSearch";const BX=({label:e,description:t,isValid:n,...r})=>{const{disabled:i}=r,o={"aria-invalid":!!n},a=[n===!0&&"text-success-text",n===!1&&"text-error-text",i&&"text-disabled-text"].filter(Boolean).join(" ");return P.jsx(lh,{children:P.jsx(ac,{children:P.jsxs(sc,{children:[e&&P.jsx(El,{children:e}),P.jsx(uh,{...r,...o}),t&&P.jsx(lc,{className:ue(i?"text-disabled-text":"",a),children:t})]})})})};var Eu={exports:{}};var zX=Eu.exports,RE;function WX(){return RE||(RE=1,(function(e,t){(function(){var n,r="4.17.23",i=200,o="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",a="Expected a function",s="Invalid `variable` option passed into `_.template`",u="__lodash_hash_undefined__",c=500,d="__lodash_placeholder__",p=1,g=2,h=4,v=1,b=2,y=1,w=2,C=4,E=8,_=16,O=32,R=64,I=128,k=256,B=512,L=30,V="...",D=800,H=16,J=1,te=2,G=3,ee=1/0,Q=9007199254740991,pe=17976931348623157e292,K=NaN,Ae=4294967295,Se=Ae-1,$e=Ae>>>1,we=[["ary",I],["bind",y],["bindKey",w],["curry",E],["curryRight",_],["flip",B],["partial",O],["partialRight",R],["rearg",k]],Ce="[object Arguments]",ze="[object Array]",Ke="[object AsyncFunction]",Fe="[object Boolean]",Y="[object Date]",oe="[object DOMException]",ne="[object Error]",$="[object Function]",ie="[object GeneratorFunction]",Z="[object Map]",Re="[object Number]",U="[object Null]",fe="[object Object]",me="[object Promise]",de="[object Proxy]",ve="[object RegExp]",le="[object Set]",be="[object String]",ke="[object Symbol]",et="[object Undefined]",Tt="[object WeakMap]",Dn="[object WeakSet]",Ct="[object ArrayBuffer]",ot="[object DataView]",kt="[object Float32Array]",mn="[object Float64Array]",on="[object Int8Array]",_n="[object Int16Array]",Qt="[object Int32Array]",vn="[object Uint8Array]",hr="[object Uint8ClampedArray]",Hn="[object Uint16Array]",pt="[object Uint32Array]",ht=/\b__p \+= '';/g,Ve=/\b(__p \+=) '' \+/g,jn=/(__e\(.*?\)|\b__t\)) \+\n'';/g,On=/&(?:amp|lt|gt|quot|#39);/g,mi=/[&<>"']/g,Jt=RegExp(On.source),ma=RegExp(mi.source),$t=/<%-([\s\S]+?)%>/g,Dl=/<%([\s\S]+?)%>/g,nr=/<%=([\s\S]+?)%>/g,yn=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,va=/^\w*$/,Ao=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Dr=/[\\^$.*+?()[\]{}|]/g,vs=RegExp(Dr.source),jr=/^\s+/,gr=/\s/,Un=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,rt=/\{\n\/\* \[wrapped with (.+)\] \*/,vi=/,? & /,og=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,jl=/[()=,{}\[\]\/\s]/,Ll=/\\(\\)?/g,ys=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Nc=/\w*$/,bs=/^[-+]0x[0-9a-f]+$/i,Mc=/^0b[01]+$/i,ya=/^\[object .+?Constructor\]$/,$l=/^0o[0-7]+$/i,mr=/^(?:0|[1-9]\d*)$/,yi=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,xs=/($^)/,Dc=/['\n\r\u2028\u2029\\]/g,ws="\\ud800-\\udfff",Fl="\\u0300-\\u036f",jc="\\ufe20-\\ufe2f",Vl="\\u20d0-\\u20ff",Lc=Fl+jc+Vl,ba="\\u2700-\\u27bf",$c="a-z\\xdf-\\xf6\\xf8-\\xff",vr="\\xac\\xb1\\xd7\\xf7",Lr="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",xa="\\u2000-\\u206f",Cs=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Fc="A-Z\\xc0-\\xd6\\xd8-\\xde",Ss="\\ufe0e\\ufe0f",Es=vr+Lr+xa+Cs,Bl="['’]",_s="["+ws+"]",Os="["+Es+"]",Ro="["+Lc+"]",Vc="\\d+",ag="["+ba+"]",Bc="["+$c+"]",zc="[^"+ws+Es+Vc+ba+$c+Fc+"]",wa="\\ud83c[\\udffb-\\udfff]",zl="(?:"+Ro+"|"+wa+")",Ps="[^"+ws+"]",Wl="(?:\\ud83c[\\udde6-\\uddff]){2}",Hl="[\\ud800-\\udbff][\\udc00-\\udfff]",Io="["+Fc+"]",Wc="\\u200d",As="(?:"+Bc+"|"+zc+")",sg="(?:"+Io+"|"+zc+")",Hc="(?:"+Bl+"(?:d|ll|m|re|s|t|ve))?",xe="(?:"+Bl+"(?:D|LL|M|RE|S|T|VE))?",De=zl+"?",Ze="["+Ss+"]?",Bt="(?:"+Wc+"(?:"+[Ps,Wl,Hl].join("|")+")"+Ze+De+")*",en="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",tn="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",bi=Ze+De+Bt,Bi="(?:"+[ag,Wl,Hl].join("|")+")"+bi,Rs="(?:"+[Ps+Ro+"?",Ro,Wl,Hl,_s].join("|")+")",lg=RegExp(Bl,"g"),Jw=RegExp(Ro,"g"),ug=RegExp(wa+"(?="+wa+")|"+Rs+bi,"g"),N$=RegExp([Io+"?"+Bc+"+"+Hc+"(?="+[Os,Io,"$"].join("|")+")",sg+"+"+xe+"(?="+[Os,Io+As,"$"].join("|")+")",Io+"?"+As+"+"+Hc,Io+"+"+xe,tn,en,Vc,Bi].join("|"),"g"),M$=RegExp("["+Wc+ws+Lc+Ss+"]"),D$=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,j$=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],L$=-1,Nt={};Nt[kt]=Nt[mn]=Nt[on]=Nt[_n]=Nt[Qt]=Nt[vn]=Nt[hr]=Nt[Hn]=Nt[pt]=!0,Nt[Ce]=Nt[ze]=Nt[Ct]=Nt[Fe]=Nt[ot]=Nt[Y]=Nt[ne]=Nt[$]=Nt[Z]=Nt[Re]=Nt[fe]=Nt[ve]=Nt[le]=Nt[be]=Nt[Tt]=!1;var Rt={};Rt[Ce]=Rt[ze]=Rt[Ct]=Rt[ot]=Rt[Fe]=Rt[Y]=Rt[kt]=Rt[mn]=Rt[on]=Rt[_n]=Rt[Qt]=Rt[Z]=Rt[Re]=Rt[fe]=Rt[ve]=Rt[le]=Rt[be]=Rt[ke]=Rt[vn]=Rt[hr]=Rt[Hn]=Rt[pt]=!0,Rt[ne]=Rt[$]=Rt[Tt]=!1;var $$={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},F$={"&":"&","<":"<",">":">",'"':""","'":"'"},V$={"&":"&","<":"<",">":">",""":'"',"'":"'"},B$={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},z$=parseFloat,W$=parseInt,e1=typeof Wf=="object"&&Wf&&Wf.Object===Object&&Wf,H$=typeof self=="object"&&self&&self.Object===Object&&self,Pn=e1||H$||Function("return this")(),cg=t&&!t.nodeType&&t,Ca=cg&&!0&&e&&!e.nodeType&&e,t1=Ca&&Ca.exports===cg,fg=t1&&e1.process,$r=(function(){try{var z=Ca&&Ca.require&&Ca.require("util").types;return z||fg&&fg.binding&&fg.binding("util")}catch{}})(),n1=$r&&$r.isArrayBuffer,r1=$r&&$r.isDate,i1=$r&&$r.isMap,o1=$r&&$r.isRegExp,a1=$r&&$r.isSet,s1=$r&&$r.isTypedArray;function yr(z,re,X){switch(X.length){case 0:return z.call(re);case 1:return z.call(re,X[0]);case 2:return z.call(re,X[0],X[1]);case 3:return z.call(re,X[0],X[1],X[2])}return z.apply(re,X)}function U$(z,re,X,Ee){for(var qe=-1,gt=z==null?0:z.length;++qe<gt;){var an=z[qe];re(Ee,an,X(an),z)}return Ee}function Fr(z,re){for(var X=-1,Ee=z==null?0:z.length;++X<Ee&&re(z[X],X,z)!==!1;);return z}function G$(z,re){for(var X=z==null?0:z.length;X--&&re(z[X],X,z)!==!1;);return z}function l1(z,re){for(var X=-1,Ee=z==null?0:z.length;++X<Ee;)if(!re(z[X],X,z))return!1;return!0}function To(z,re){for(var X=-1,Ee=z==null?0:z.length,qe=0,gt=[];++X<Ee;){var an=z[X];re(an,X,z)&&(gt[qe++]=an)}return gt}function Uc(z,re){var X=z==null?0:z.length;return!!X&&Is(z,re,0)>-1}function dg(z,re,X){for(var Ee=-1,qe=z==null?0:z.length;++Ee<qe;)if(X(re,z[Ee]))return!0;return!1}function Ft(z,re){for(var X=-1,Ee=z==null?0:z.length,qe=Array(Ee);++X<Ee;)qe[X]=re(z[X],X,z);return qe}function ko(z,re){for(var X=-1,Ee=re.length,qe=z.length;++X<Ee;)z[qe+X]=re[X];return z}function pg(z,re,X,Ee){var qe=-1,gt=z==null?0:z.length;for(Ee&>&&(X=z[++qe]);++qe<gt;)X=re(X,z[qe],qe,z);return X}function q$(z,re,X,Ee){var qe=z==null?0:z.length;for(Ee&&qe&&(X=z[--qe]);qe--;)X=re(X,z[qe],qe,z);return X}function hg(z,re){for(var X=-1,Ee=z==null?0:z.length;++X<Ee;)if(re(z[X],X,z))return!0;return!1}var K$=gg("length");function Y$(z){return z.split("")}function X$(z){return z.match(og)||[]}function u1(z,re,X){var Ee;return X(z,function(qe,gt,an){if(re(qe,gt,an))return Ee=gt,!1}),Ee}function Gc(z,re,X,Ee){for(var qe=z.length,gt=X+(Ee?1:-1);Ee?gt--:++gt<qe;)if(re(z[gt],gt,z))return gt;return-1}function Is(z,re,X){return re===re?lF(z,re,X):Gc(z,c1,X)}function Z$(z,re,X,Ee){for(var qe=X-1,gt=z.length;++qe<gt;)if(Ee(z[qe],re))return qe;return-1}function c1(z){return z!==z}function f1(z,re){var X=z==null?0:z.length;return X?vg(z,re)/X:K}function gg(z){return function(re){return re==null?n:re[z]}}function mg(z){return function(re){return z==null?n:z[re]}}function d1(z,re,X,Ee,qe){return qe(z,function(gt,an,_t){X=Ee?(Ee=!1,gt):re(X,gt,an,_t)}),X}function Q$(z,re){var X=z.length;for(z.sort(re);X--;)z[X]=z[X].value;return z}function vg(z,re){for(var X,Ee=-1,qe=z.length;++Ee<qe;){var gt=re(z[Ee]);gt!==n&&(X=X===n?gt:X+gt)}return X}function yg(z,re){for(var X=-1,Ee=Array(z);++X<z;)Ee[X]=re(X);return Ee}function J$(z,re){return Ft(re,function(X){return[X,z[X]]})}function p1(z){return z&&z.slice(0,v1(z)+1).replace(jr,"")}function br(z){return function(re){return z(re)}}function bg(z,re){return Ft(re,function(X){return z[X]})}function Ul(z,re){return z.has(re)}function h1(z,re){for(var X=-1,Ee=z.length;++X<Ee&&Is(re,z[X],0)>-1;);return X}function g1(z,re){for(var X=z.length;X--&&Is(re,z[X],0)>-1;);return X}function eF(z,re){for(var X=z.length,Ee=0;X--;)z[X]===re&&++Ee;return Ee}var tF=mg($$),nF=mg(F$);function rF(z){return"\\"+B$[z]}function iF(z,re){return z==null?n:z[re]}function Ts(z){return M$.test(z)}function oF(z){return D$.test(z)}function aF(z){for(var re,X=[];!(re=z.next()).done;)X.push(re.value);return X}function xg(z){var re=-1,X=Array(z.size);return z.forEach(function(Ee,qe){X[++re]=[qe,Ee]}),X}function m1(z,re){return function(X){return z(re(X))}}function No(z,re){for(var X=-1,Ee=z.length,qe=0,gt=[];++X<Ee;){var an=z[X];(an===re||an===d)&&(z[X]=d,gt[qe++]=X)}return gt}function qc(z){var re=-1,X=Array(z.size);return z.forEach(function(Ee){X[++re]=Ee}),X}function sF(z){var re=-1,X=Array(z.size);return z.forEach(function(Ee){X[++re]=[Ee,Ee]}),X}function lF(z,re,X){for(var Ee=X-1,qe=z.length;++Ee<qe;)if(z[Ee]===re)return Ee;return-1}function uF(z,re,X){for(var Ee=X+1;Ee--;)if(z[Ee]===re)return Ee;return Ee}function ks(z){return Ts(z)?fF(z):K$(z)}function ii(z){return Ts(z)?dF(z):Y$(z)}function v1(z){for(var re=z.length;re--&&gr.test(z.charAt(re)););return re}var cF=mg(V$);function fF(z){for(var re=ug.lastIndex=0;ug.test(z);)++re;return re}function dF(z){return z.match(ug)||[]}function pF(z){return z.match(N$)||[]}var hF=(function z(re){re=re==null?Pn:Ns.defaults(Pn.Object(),re,Ns.pick(Pn,j$));var X=re.Array,Ee=re.Date,qe=re.Error,gt=re.Function,an=re.Math,_t=re.Object,wg=re.RegExp,gF=re.String,Vr=re.TypeError,Kc=X.prototype,mF=gt.prototype,Ms=_t.prototype,Yc=re["__core-js_shared__"],Xc=mF.toString,vt=Ms.hasOwnProperty,vF=0,y1=(function(){var l=/[^.]+$/.exec(Yc&&Yc.keys&&Yc.keys.IE_PROTO||"");return l?"Symbol(src)_1."+l:""})(),Zc=Ms.toString,yF=Xc.call(_t),bF=Pn._,xF=wg("^"+Xc.call(vt).replace(Dr,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Qc=t1?re.Buffer:n,Mo=re.Symbol,Jc=re.Uint8Array,b1=Qc?Qc.allocUnsafe:n,ef=m1(_t.getPrototypeOf,_t),x1=_t.create,w1=Ms.propertyIsEnumerable,tf=Kc.splice,C1=Mo?Mo.isConcatSpreadable:n,Gl=Mo?Mo.iterator:n,Sa=Mo?Mo.toStringTag:n,nf=(function(){try{var l=Aa(_t,"defineProperty");return l({},"",{}),l}catch{}})(),wF=re.clearTimeout!==Pn.clearTimeout&&re.clearTimeout,CF=Ee&&Ee.now!==Pn.Date.now&&Ee.now,SF=re.setTimeout!==Pn.setTimeout&&re.setTimeout,rf=an.ceil,of=an.floor,Cg=_t.getOwnPropertySymbols,EF=Qc?Qc.isBuffer:n,S1=re.isFinite,_F=Kc.join,OF=m1(_t.keys,_t),sn=an.max,Ln=an.min,PF=Ee.now,AF=re.parseInt,E1=an.random,RF=Kc.reverse,Sg=Aa(re,"DataView"),ql=Aa(re,"Map"),Eg=Aa(re,"Promise"),Ds=Aa(re,"Set"),Kl=Aa(re,"WeakMap"),Yl=Aa(_t,"create"),af=Kl&&new Kl,js={},IF=Ra(Sg),TF=Ra(ql),kF=Ra(Eg),NF=Ra(Ds),MF=Ra(Kl),sf=Mo?Mo.prototype:n,Xl=sf?sf.valueOf:n,_1=sf?sf.toString:n;function T(l){if(Ut(l)&&!Ye(l)&&!(l instanceof at)){if(l instanceof Br)return l;if(vt.call(l,"__wrapped__"))return OC(l)}return new Br(l)}var Ls=(function(){function l(){}return function(f){if(!zt(f))return{};if(x1)return x1(f);l.prototype=f;var m=new l;return l.prototype=n,m}})();function lf(){}function Br(l,f){this.__wrapped__=l,this.__actions__=[],this.__chain__=!!f,this.__index__=0,this.__values__=n}T.templateSettings={escape:$t,evaluate:Dl,interpolate:nr,variable:"",imports:{_:T}},T.prototype=lf.prototype,T.prototype.constructor=T,Br.prototype=Ls(lf.prototype),Br.prototype.constructor=Br;function at(l){this.__wrapped__=l,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=Ae,this.__views__=[]}function DF(){var l=new at(this.__wrapped__);return l.__actions__=rr(this.__actions__),l.__dir__=this.__dir__,l.__filtered__=this.__filtered__,l.__iteratees__=rr(this.__iteratees__),l.__takeCount__=this.__takeCount__,l.__views__=rr(this.__views__),l}function jF(){if(this.__filtered__){var l=new at(this);l.__dir__=-1,l.__filtered__=!0}else l=this.clone(),l.__dir__*=-1;return l}function LF(){var l=this.__wrapped__.value(),f=this.__dir__,m=Ye(l),S=f<0,A=m?l.length:0,N=YV(0,A,this.__views__),M=N.start,F=N.end,W=F-M,ae=S?F:M-1,se=this.__iteratees__,ce=se.length,ye=0,Ie=Ln(W,this.__takeCount__);if(!m||!S&&A==W&&Ie==W)return Y1(l,this.__actions__);var We=[];e:for(;W--&&ye<Ie;){ae+=f;for(var Je=-1,He=l[ae];++Je<ce;){var it=se[Je],lt=it.iteratee,Cr=it.type,Kn=lt(He);if(Cr==te)He=Kn;else if(!Kn){if(Cr==J)continue e;break e}}We[ye++]=He}return We}at.prototype=Ls(lf.prototype),at.prototype.constructor=at;function Ea(l){var f=-1,m=l==null?0:l.length;for(this.clear();++f<m;){var S=l[f];this.set(S[0],S[1])}}function $F(){this.__data__=Yl?Yl(null):{},this.size=0}function FF(l){var f=this.has(l)&&delete this.__data__[l];return this.size-=f?1:0,f}function VF(l){var f=this.__data__;if(Yl){var m=f[l];return m===u?n:m}return vt.call(f,l)?f[l]:n}function BF(l){var f=this.__data__;return Yl?f[l]!==n:vt.call(f,l)}function zF(l,f){var m=this.__data__;return this.size+=this.has(l)?0:1,m[l]=Yl&&f===n?u:f,this}Ea.prototype.clear=$F,Ea.prototype.delete=FF,Ea.prototype.get=VF,Ea.prototype.has=BF,Ea.prototype.set=zF;function zi(l){var f=-1,m=l==null?0:l.length;for(this.clear();++f<m;){var S=l[f];this.set(S[0],S[1])}}function WF(){this.__data__=[],this.size=0}function HF(l){var f=this.__data__,m=uf(f,l);if(m<0)return!1;var S=f.length-1;return m==S?f.pop():tf.call(f,m,1),--this.size,!0}function UF(l){var f=this.__data__,m=uf(f,l);return m<0?n:f[m][1]}function GF(l){return uf(this.__data__,l)>-1}function qF(l,f){var m=this.__data__,S=uf(m,l);return S<0?(++this.size,m.push([l,f])):m[S][1]=f,this}zi.prototype.clear=WF,zi.prototype.delete=HF,zi.prototype.get=UF,zi.prototype.has=GF,zi.prototype.set=qF;function Wi(l){var f=-1,m=l==null?0:l.length;for(this.clear();++f<m;){var S=l[f];this.set(S[0],S[1])}}function KF(){this.size=0,this.__data__={hash:new Ea,map:new(ql||zi),string:new Ea}}function YF(l){var f=wf(this,l).delete(l);return this.size-=f?1:0,f}function XF(l){return wf(this,l).get(l)}function ZF(l){return wf(this,l).has(l)}function QF(l,f){var m=wf(this,l),S=m.size;return m.set(l,f),this.size+=m.size==S?0:1,this}Wi.prototype.clear=KF,Wi.prototype.delete=YF,Wi.prototype.get=XF,Wi.prototype.has=ZF,Wi.prototype.set=QF;function _a(l){var f=-1,m=l==null?0:l.length;for(this.__data__=new Wi;++f<m;)this.add(l[f])}function JF(l){return this.__data__.set(l,u),this}function eV(l){return this.__data__.has(l)}_a.prototype.add=_a.prototype.push=JF,_a.prototype.has=eV;function oi(l){var f=this.__data__=new zi(l);this.size=f.size}function tV(){this.__data__=new zi,this.size=0}function nV(l){var f=this.__data__,m=f.delete(l);return this.size=f.size,m}function rV(l){return this.__data__.get(l)}function iV(l){return this.__data__.has(l)}function oV(l,f){var m=this.__data__;if(m instanceof zi){var S=m.__data__;if(!ql||S.length<i-1)return S.push([l,f]),this.size=++m.size,this;m=this.__data__=new Wi(S)}return m.set(l,f),this.size=m.size,this}oi.prototype.clear=tV,oi.prototype.delete=nV,oi.prototype.get=rV,oi.prototype.has=iV,oi.prototype.set=oV;function O1(l,f){var m=Ye(l),S=!m&&Ia(l),A=!m&&!S&&Fo(l),N=!m&&!S&&!A&&Bs(l),M=m||S||A||N,F=M?yg(l.length,gF):[],W=F.length;for(var ae in l)(f||vt.call(l,ae))&&!(M&&(ae=="length"||A&&(ae=="offset"||ae=="parent")||N&&(ae=="buffer"||ae=="byteLength"||ae=="byteOffset")||qi(ae,W)))&&F.push(ae);return F}function P1(l){var f=l.length;return f?l[Dg(0,f-1)]:n}function aV(l,f){return Cf(rr(l),Oa(f,0,l.length))}function sV(l){return Cf(rr(l))}function _g(l,f,m){(m!==n&&!ai(l[f],m)||m===n&&!(f in l))&&Hi(l,f,m)}function Zl(l,f,m){var S=l[f];(!(vt.call(l,f)&&ai(S,m))||m===n&&!(f in l))&&Hi(l,f,m)}function uf(l,f){for(var m=l.length;m--;)if(ai(l[m][0],f))return m;return-1}function lV(l,f,m,S){return Do(l,function(A,N,M){f(S,A,m(A),M)}),S}function A1(l,f){return l&&wi(f,bn(f),l)}function uV(l,f){return l&&wi(f,or(f),l)}function Hi(l,f,m){f=="__proto__"&&nf?nf(l,f,{configurable:!0,enumerable:!0,value:m,writable:!0}):l[f]=m}function Og(l,f){for(var m=-1,S=f.length,A=X(S),N=l==null;++m<S;)A[m]=N?n:am(l,f[m]);return A}function Oa(l,f,m){return l===l&&(m!==n&&(l=l<=m?l:m),f!==n&&(l=l>=f?l:f)),l}function zr(l,f,m,S,A,N){var M,F=f&p,W=f&g,ae=f&h;if(m&&(M=A?m(l,S,A,N):m(l)),M!==n)return M;if(!zt(l))return l;var se=Ye(l);if(se){if(M=ZV(l),!F)return rr(l,M)}else{var ce=$n(l),ye=ce==$||ce==ie;if(Fo(l))return Q1(l,F);if(ce==fe||ce==Ce||ye&&!A){if(M=W||ye?{}:vC(l),!F)return W?VV(l,uV(M,l)):FV(l,A1(M,l))}else{if(!Rt[ce])return A?l:{};M=QV(l,ce,F)}}N||(N=new oi);var Ie=N.get(l);if(Ie)return Ie;N.set(l,M),GC(l)?l.forEach(function(He){M.add(zr(He,f,m,He,l,N))}):HC(l)&&l.forEach(function(He,it){M.set(it,zr(He,f,m,it,l,N))});var We=ae?W?Gg:Ug:W?or:bn,Je=se?n:We(l);return Fr(Je||l,function(He,it){Je&&(it=He,He=l[it]),Zl(M,it,zr(He,f,m,it,l,N))}),M}function cV(l){var f=bn(l);return function(m){return R1(m,l,f)}}function R1(l,f,m){var S=m.length;if(l==null)return!S;for(l=_t(l);S--;){var A=m[S],N=f[A],M=l[A];if(M===n&&!(A in l)||!N(M))return!1}return!0}function I1(l,f,m){if(typeof l!="function")throw new Vr(a);return iu(function(){l.apply(n,m)},f)}function Ql(l,f,m,S){var A=-1,N=Uc,M=!0,F=l.length,W=[],ae=f.length;if(!F)return W;m&&(f=Ft(f,br(m))),S?(N=dg,M=!1):f.length>=i&&(N=Ul,M=!1,f=new _a(f));e:for(;++A<F;){var se=l[A],ce=m==null?se:m(se);if(se=S||se!==0?se:0,M&&ce===ce){for(var ye=ae;ye--;)if(f[ye]===ce)continue e;W.push(se)}else N(f,ce,S)||W.push(se)}return W}var Do=rC(xi),T1=rC(Ag,!0);function fV(l,f){var m=!0;return Do(l,function(S,A,N){return m=!!f(S,A,N),m}),m}function cf(l,f,m){for(var S=-1,A=l.length;++S<A;){var N=l[S],M=f(N);if(M!=null&&(F===n?M===M&&!wr(M):m(M,F)))var F=M,W=N}return W}function dV(l,f,m,S){var A=l.length;for(m=Qe(m),m<0&&(m=-m>A?0:A+m),S=S===n||S>A?A:Qe(S),S<0&&(S+=A),S=m>S?0:KC(S);m<S;)l[m++]=f;return l}function k1(l,f){var m=[];return Do(l,function(S,A,N){f(S,A,N)&&m.push(S)}),m}function An(l,f,m,S,A){var N=-1,M=l.length;for(m||(m=eB),A||(A=[]);++N<M;){var F=l[N];f>0&&m(F)?f>1?An(F,f-1,m,S,A):ko(A,F):S||(A[A.length]=F)}return A}var Pg=iC(),N1=iC(!0);function xi(l,f){return l&&Pg(l,f,bn)}function Ag(l,f){return l&&N1(l,f,bn)}function ff(l,f){return To(f,function(m){return Ki(l[m])})}function Pa(l,f){f=Lo(f,l);for(var m=0,S=f.length;l!=null&&m<S;)l=l[Ci(f[m++])];return m&&m==S?l:n}function M1(l,f,m){var S=f(l);return Ye(l)?S:ko(S,m(l))}function Gn(l){return l==null?l===n?et:U:Sa&&Sa in _t(l)?KV(l):sB(l)}function Rg(l,f){return l>f}function pV(l,f){return l!=null&&vt.call(l,f)}function hV(l,f){return l!=null&&f in _t(l)}function gV(l,f,m){return l>=Ln(f,m)&&l<sn(f,m)}function Ig(l,f,m){for(var S=m?dg:Uc,A=l[0].length,N=l.length,M=N,F=X(N),W=1/0,ae=[];M--;){var se=l[M];M&&f&&(se=Ft(se,br(f))),W=Ln(se.length,W),F[M]=!m&&(f||A>=120&&se.length>=120)?new _a(M&&se):n}se=l[0];var ce=-1,ye=F[0];e:for(;++ce<A&&ae.length<W;){var Ie=se[ce],We=f?f(Ie):Ie;if(Ie=m||Ie!==0?Ie:0,!(ye?Ul(ye,We):S(ae,We,m))){for(M=N;--M;){var Je=F[M];if(!(Je?Ul(Je,We):S(l[M],We,m)))continue e}ye&&ye.push(We),ae.push(Ie)}}return ae}function mV(l,f,m,S){return xi(l,function(A,N,M){f(S,m(A),N,M)}),S}function Jl(l,f,m){f=Lo(f,l),l=wC(l,f);var S=l==null?l:l[Ci(Hr(f))];return S==null?n:yr(S,l,m)}function D1(l){return Ut(l)&&Gn(l)==Ce}function vV(l){return Ut(l)&&Gn(l)==Ct}function yV(l){return Ut(l)&&Gn(l)==Y}function eu(l,f,m,S,A){return l===f?!0:l==null||f==null||!Ut(l)&&!Ut(f)?l!==l&&f!==f:bV(l,f,m,S,eu,A)}function bV(l,f,m,S,A,N){var M=Ye(l),F=Ye(f),W=M?ze:$n(l),ae=F?ze:$n(f);W=W==Ce?fe:W,ae=ae==Ce?fe:ae;var se=W==fe,ce=ae==fe,ye=W==ae;if(ye&&Fo(l)){if(!Fo(f))return!1;M=!0,se=!1}if(ye&&!se)return N||(N=new oi),M||Bs(l)?hC(l,f,m,S,A,N):GV(l,f,W,m,S,A,N);if(!(m&v)){var Ie=se&&vt.call(l,"__wrapped__"),We=ce&&vt.call(f,"__wrapped__");if(Ie||We){var Je=Ie?l.value():l,He=We?f.value():f;return N||(N=new oi),A(Je,He,m,S,N)}}return ye?(N||(N=new oi),qV(l,f,m,S,A,N)):!1}function xV(l){return Ut(l)&&$n(l)==Z}function Tg(l,f,m,S){var A=m.length,N=A,M=!S;if(l==null)return!N;for(l=_t(l);A--;){var F=m[A];if(M&&F[2]?F[1]!==l[F[0]]:!(F[0]in l))return!1}for(;++A<N;){F=m[A];var W=F[0],ae=l[W],se=F[1];if(M&&F[2]){if(ae===n&&!(W in l))return!1}else{var ce=new oi;if(S)var ye=S(ae,se,W,l,f,ce);if(!(ye===n?eu(se,ae,v|b,S,ce):ye))return!1}}return!0}function j1(l){if(!zt(l)||nB(l))return!1;var f=Ki(l)?xF:ya;return f.test(Ra(l))}function wV(l){return Ut(l)&&Gn(l)==ve}function CV(l){return Ut(l)&&$n(l)==le}function SV(l){return Ut(l)&&Af(l.length)&&!!Nt[Gn(l)]}function L1(l){return typeof l=="function"?l:l==null?ar:typeof l=="object"?Ye(l)?V1(l[0],l[1]):F1(l):oS(l)}function kg(l){if(!ru(l))return OF(l);var f=[];for(var m in _t(l))vt.call(l,m)&&m!="constructor"&&f.push(m);return f}function EV(l){if(!zt(l))return aB(l);var f=ru(l),m=[];for(var S in l)S=="constructor"&&(f||!vt.call(l,S))||m.push(S);return m}function Ng(l,f){return l<f}function $1(l,f){var m=-1,S=ir(l)?X(l.length):[];return Do(l,function(A,N,M){S[++m]=f(A,N,M)}),S}function F1(l){var f=Kg(l);return f.length==1&&f[0][2]?bC(f[0][0],f[0][1]):function(m){return m===l||Tg(m,l,f)}}function V1(l,f){return Xg(l)&&yC(f)?bC(Ci(l),f):function(m){var S=am(m,l);return S===n&&S===f?sm(m,l):eu(f,S,v|b)}}function df(l,f,m,S,A){l!==f&&Pg(f,function(N,M){if(A||(A=new oi),zt(N))_V(l,f,M,m,df,S,A);else{var F=S?S(Qg(l,M),N,M+"",l,f,A):n;F===n&&(F=N),_g(l,M,F)}},or)}function _V(l,f,m,S,A,N,M){var F=Qg(l,m),W=Qg(f,m),ae=M.get(W);if(ae){_g(l,m,ae);return}var se=N?N(F,W,m+"",l,f,M):n,ce=se===n;if(ce){var ye=Ye(W),Ie=!ye&&Fo(W),We=!ye&&!Ie&&Bs(W);se=W,ye||Ie||We?Ye(F)?se=F:Kt(F)?se=rr(F):Ie?(ce=!1,se=Q1(W,!0)):We?(ce=!1,se=J1(W,!0)):se=[]:ou(W)||Ia(W)?(se=F,Ia(F)?se=YC(F):(!zt(F)||Ki(F))&&(se=vC(W))):ce=!1}ce&&(M.set(W,se),A(se,W,S,N,M),M.delete(W)),_g(l,m,se)}function B1(l,f){var m=l.length;if(m)return f+=f<0?m:0,qi(f,m)?l[f]:n}function z1(l,f,m){f.length?f=Ft(f,function(N){return Ye(N)?function(M){return Pa(M,N.length===1?N[0]:N)}:N}):f=[ar];var S=-1;f=Ft(f,br(Be()));var A=$1(l,function(N,M,F){var W=Ft(f,function(ae){return ae(N)});return{criteria:W,index:++S,value:N}});return Q$(A,function(N,M){return $V(N,M,m)})}function OV(l,f){return W1(l,f,function(m,S){return sm(l,S)})}function W1(l,f,m){for(var S=-1,A=f.length,N={};++S<A;){var M=f[S],F=Pa(l,M);m(F,M)&&tu(N,Lo(M,l),F)}return N}function PV(l){return function(f){return Pa(f,l)}}function Mg(l,f,m,S){var A=S?Z$:Is,N=-1,M=f.length,F=l;for(l===f&&(f=rr(f)),m&&(F=Ft(l,br(m)));++N<M;)for(var W=0,ae=f[N],se=m?m(ae):ae;(W=A(F,se,W,S))>-1;)F!==l&&tf.call(F,W,1),tf.call(l,W,1);return l}function H1(l,f){for(var m=l?f.length:0,S=m-1;m--;){var A=f[m];if(m==S||A!==N){var N=A;qi(A)?tf.call(l,A,1):$g(l,A)}}return l}function Dg(l,f){return l+of(E1()*(f-l+1))}function AV(l,f,m,S){for(var A=-1,N=sn(rf((f-l)/(m||1)),0),M=X(N);N--;)M[S?N:++A]=l,l+=m;return M}function jg(l,f){var m="";if(!l||f<1||f>Q)return m;do f%2&&(m+=l),f=of(f/2),f&&(l+=l);while(f);return m}function tt(l,f){return Jg(xC(l,f,ar),l+"")}function RV(l){return P1(zs(l))}function IV(l,f){var m=zs(l);return Cf(m,Oa(f,0,m.length))}function tu(l,f,m,S){if(!zt(l))return l;f=Lo(f,l);for(var A=-1,N=f.length,M=N-1,F=l;F!=null&&++A<N;){var W=Ci(f[A]),ae=m;if(W==="__proto__"||W==="constructor"||W==="prototype")return l;if(A!=M){var se=F[W];ae=S?S(se,W,F):n,ae===n&&(ae=zt(se)?se:qi(f[A+1])?[]:{})}Zl(F,W,ae),F=F[W]}return l}var U1=af?function(l,f){return af.set(l,f),l}:ar,TV=nf?function(l,f){return nf(l,"toString",{configurable:!0,enumerable:!1,value:um(f),writable:!0})}:ar;function kV(l){return Cf(zs(l))}function Wr(l,f,m){var S=-1,A=l.length;f<0&&(f=-f>A?0:A+f),m=m>A?A:m,m<0&&(m+=A),A=f>m?0:m-f>>>0,f>>>=0;for(var N=X(A);++S<A;)N[S]=l[S+f];return N}function NV(l,f){var m;return Do(l,function(S,A,N){return m=f(S,A,N),!m}),!!m}function pf(l,f,m){var S=0,A=l==null?S:l.length;if(typeof f=="number"&&f===f&&A<=$e){for(;S<A;){var N=S+A>>>1,M=l[N];M!==null&&!wr(M)&&(m?M<=f:M<f)?S=N+1:A=N}return A}return Lg(l,f,ar,m)}function Lg(l,f,m,S){var A=0,N=l==null?0:l.length;if(N===0)return 0;f=m(f);for(var M=f!==f,F=f===null,W=wr(f),ae=f===n;A<N;){var se=of((A+N)/2),ce=m(l[se]),ye=ce!==n,Ie=ce===null,We=ce===ce,Je=wr(ce);if(M)var He=S||We;else ae?He=We&&(S||ye):F?He=We&&ye&&(S||!Ie):W?He=We&&ye&&!Ie&&(S||!Je):Ie||Je?He=!1:He=S?ce<=f:ce<f;He?A=se+1:N=se}return Ln(N,Se)}function G1(l,f){for(var m=-1,S=l.length,A=0,N=[];++m<S;){var M=l[m],F=f?f(M):M;if(!m||!ai(F,W)){var W=F;N[A++]=M===0?0:M}}return N}function q1(l){return typeof l=="number"?l:wr(l)?K:+l}function xr(l){if(typeof l=="string")return l;if(Ye(l))return Ft(l,xr)+"";if(wr(l))return _1?_1.call(l):"";var f=l+"";return f=="0"&&1/l==-ee?"-0":f}function jo(l,f,m){var S=-1,A=Uc,N=l.length,M=!0,F=[],W=F;if(m)M=!1,A=dg;else if(N>=i){var ae=f?null:HV(l);if(ae)return qc(ae);M=!1,A=Ul,W=new _a}else W=f?[]:F;e:for(;++S<N;){var se=l[S],ce=f?f(se):se;if(se=m||se!==0?se:0,M&&ce===ce){for(var ye=W.length;ye--;)if(W[ye]===ce)continue e;f&&W.push(ce),F.push(se)}else A(W,ce,m)||(W!==F&&W.push(ce),F.push(se))}return F}function $g(l,f){f=Lo(f,l);var m=-1,S=f.length;if(!S)return!0;for(var A=l==null||typeof l!="object"&&typeof l!="function";++m<S;){var N=f[m];if(typeof N=="string"){if(N==="__proto__"&&!vt.call(l,"__proto__"))return!1;if(N==="constructor"&&m+1<S&&typeof f[m+1]=="string"&&f[m+1]==="prototype"){if(A&&m===0)continue;return!1}}}var M=wC(l,f);return M==null||delete M[Ci(Hr(f))]}function K1(l,f,m,S){return tu(l,f,m(Pa(l,f)),S)}function hf(l,f,m,S){for(var A=l.length,N=S?A:-1;(S?N--:++N<A)&&f(l[N],N,l););return m?Wr(l,S?0:N,S?N+1:A):Wr(l,S?N+1:0,S?A:N)}function Y1(l,f){var m=l;return m instanceof at&&(m=m.value()),pg(f,function(S,A){return A.func.apply(A.thisArg,ko([S],A.args))},m)}function Fg(l,f,m){var S=l.length;if(S<2)return S?jo(l[0]):[];for(var A=-1,N=X(S);++A<S;)for(var M=l[A],F=-1;++F<S;)F!=A&&(N[A]=Ql(N[A]||M,l[F],f,m));return jo(An(N,1),f,m)}function X1(l,f,m){for(var S=-1,A=l.length,N=f.length,M={};++S<A;){var F=S<N?f[S]:n;m(M,l[S],F)}return M}function Vg(l){return Kt(l)?l:[]}function Bg(l){return typeof l=="function"?l:ar}function Lo(l,f){return Ye(l)?l:Xg(l,f)?[l]:_C(yt(l))}var MV=tt;function $o(l,f,m){var S=l.length;return m=m===n?S:m,!f&&m>=S?l:Wr(l,f,m)}var Z1=wF||function(l){return Pn.clearTimeout(l)};function Q1(l,f){if(f)return l.slice();var m=l.length,S=b1?b1(m):new l.constructor(m);return l.copy(S),S}function zg(l){var f=new l.constructor(l.byteLength);return new Jc(f).set(new Jc(l)),f}function DV(l,f){var m=f?zg(l.buffer):l.buffer;return new l.constructor(m,l.byteOffset,l.byteLength)}function jV(l){var f=new l.constructor(l.source,Nc.exec(l));return f.lastIndex=l.lastIndex,f}function LV(l){return Xl?_t(Xl.call(l)):{}}function J1(l,f){var m=f?zg(l.buffer):l.buffer;return new l.constructor(m,l.byteOffset,l.length)}function eC(l,f){if(l!==f){var m=l!==n,S=l===null,A=l===l,N=wr(l),M=f!==n,F=f===null,W=f===f,ae=wr(f);if(!F&&!ae&&!N&&l>f||N&&M&&W&&!F&&!ae||S&&M&&W||!m&&W||!A)return 1;if(!S&&!N&&!ae&&l<f||ae&&m&&A&&!S&&!N||F&&m&&A||!M&&A||!W)return-1}return 0}function $V(l,f,m){for(var S=-1,A=l.criteria,N=f.criteria,M=A.length,F=m.length;++S<M;){var W=eC(A[S],N[S]);if(W){if(S>=F)return W;var ae=m[S];return W*(ae=="desc"?-1:1)}}return l.index-f.index}function tC(l,f,m,S){for(var A=-1,N=l.length,M=m.length,F=-1,W=f.length,ae=sn(N-M,0),se=X(W+ae),ce=!S;++F<W;)se[F]=f[F];for(;++A<M;)(ce||A<N)&&(se[m[A]]=l[A]);for(;ae--;)se[F++]=l[A++];return se}function nC(l,f,m,S){for(var A=-1,N=l.length,M=-1,F=m.length,W=-1,ae=f.length,se=sn(N-F,0),ce=X(se+ae),ye=!S;++A<se;)ce[A]=l[A];for(var Ie=A;++W<ae;)ce[Ie+W]=f[W];for(;++M<F;)(ye||A<N)&&(ce[Ie+m[M]]=l[A++]);return ce}function rr(l,f){var m=-1,S=l.length;for(f||(f=X(S));++m<S;)f[m]=l[m];return f}function wi(l,f,m,S){var A=!m;m||(m={});for(var N=-1,M=f.length;++N<M;){var F=f[N],W=S?S(m[F],l[F],F,m,l):n;W===n&&(W=l[F]),A?Hi(m,F,W):Zl(m,F,W)}return m}function FV(l,f){return wi(l,Yg(l),f)}function VV(l,f){return wi(l,gC(l),f)}function gf(l,f){return function(m,S){var A=Ye(m)?U$:lV,N=f?f():{};return A(m,l,Be(S,2),N)}}function $s(l){return tt(function(f,m){var S=-1,A=m.length,N=A>1?m[A-1]:n,M=A>2?m[2]:n;for(N=l.length>3&&typeof N=="function"?(A--,N):n,M&&qn(m[0],m[1],M)&&(N=A<3?n:N,A=1),f=_t(f);++S<A;){var F=m[S];F&&l(f,F,S,N)}return f})}function rC(l,f){return function(m,S){if(m==null)return m;if(!ir(m))return l(m,S);for(var A=m.length,N=f?A:-1,M=_t(m);(f?N--:++N<A)&&S(M[N],N,M)!==!1;);return m}}function iC(l){return function(f,m,S){for(var A=-1,N=_t(f),M=S(f),F=M.length;F--;){var W=M[l?F:++A];if(m(N[W],W,N)===!1)break}return f}}function BV(l,f,m){var S=f&y,A=nu(l);function N(){var M=this&&this!==Pn&&this instanceof N?A:l;return M.apply(S?m:this,arguments)}return N}function oC(l){return function(f){f=yt(f);var m=Ts(f)?ii(f):n,S=m?m[0]:f.charAt(0),A=m?$o(m,1).join(""):f.slice(1);return S[l]()+A}}function Fs(l){return function(f){return pg(rS(nS(f).replace(lg,"")),l,"")}}function nu(l){return function(){var f=arguments;switch(f.length){case 0:return new l;case 1:return new l(f[0]);case 2:return new l(f[0],f[1]);case 3:return new l(f[0],f[1],f[2]);case 4:return new l(f[0],f[1],f[2],f[3]);case 5:return new l(f[0],f[1],f[2],f[3],f[4]);case 6:return new l(f[0],f[1],f[2],f[3],f[4],f[5]);case 7:return new l(f[0],f[1],f[2],f[3],f[4],f[5],f[6])}var m=Ls(l.prototype),S=l.apply(m,f);return zt(S)?S:m}}function zV(l,f,m){var S=nu(l);function A(){for(var N=arguments.length,M=X(N),F=N,W=Vs(A);F--;)M[F]=arguments[F];var ae=N<3&&M[0]!==W&&M[N-1]!==W?[]:No(M,W);if(N-=ae.length,N<m)return cC(l,f,mf,A.placeholder,n,M,ae,n,n,m-N);var se=this&&this!==Pn&&this instanceof A?S:l;return yr(se,this,M)}return A}function aC(l){return function(f,m,S){var A=_t(f);if(!ir(f)){var N=Be(m,3);f=bn(f),m=function(F){return N(A[F],F,A)}}var M=l(f,m,S);return M>-1?A[N?f[M]:M]:n}}function sC(l){return Gi(function(f){var m=f.length,S=m,A=Br.prototype.thru;for(l&&f.reverse();S--;){var N=f[S];if(typeof N!="function")throw new Vr(a);if(A&&!M&&xf(N)=="wrapper")var M=new Br([],!0)}for(S=M?S:m;++S<m;){N=f[S];var F=xf(N),W=F=="wrapper"?qg(N):n;W&&Zg(W[0])&&W[1]==(I|E|O|k)&&!W[4].length&&W[9]==1?M=M[xf(W[0])].apply(M,W[3]):M=N.length==1&&Zg(N)?M[F]():M.thru(N)}return function(){var ae=arguments,se=ae[0];if(M&&ae.length==1&&Ye(se))return M.plant(se).value();for(var ce=0,ye=m?f[ce].apply(this,ae):se;++ce<m;)ye=f[ce].call(this,ye);return ye}})}function mf(l,f,m,S,A,N,M,F,W,ae){var se=f&I,ce=f&y,ye=f&w,Ie=f&(E|_),We=f&B,Je=ye?n:nu(l);function He(){for(var it=arguments.length,lt=X(it),Cr=it;Cr--;)lt[Cr]=arguments[Cr];if(Ie)var Kn=Vs(He),Sr=eF(lt,Kn);if(S&&(lt=tC(lt,S,A,Ie)),N&&(lt=nC(lt,N,M,Ie)),it-=Sr,Ie&&it<ae){var Yt=No(lt,Kn);return cC(l,f,mf,He.placeholder,m,lt,Yt,F,W,ae-it)}var si=ce?m:this,Xi=ye?si[l]:l;return it=lt.length,F?lt=lB(lt,F):We&&it>1&<.reverse(),se&&W<it&&(lt.length=W),this&&this!==Pn&&this instanceof He&&(Xi=Je||nu(Xi)),Xi.apply(si,lt)}return He}function lC(l,f){return function(m,S){return mV(m,l,f(S),{})}}function vf(l,f){return function(m,S){var A;if(m===n&&S===n)return f;if(m!==n&&(A=m),S!==n){if(A===n)return S;typeof m=="string"||typeof S=="string"?(m=xr(m),S=xr(S)):(m=q1(m),S=q1(S)),A=l(m,S)}return A}}function Wg(l){return Gi(function(f){return f=Ft(f,br(Be())),tt(function(m){var S=this;return l(f,function(A){return yr(A,S,m)})})})}function yf(l,f){f=f===n?" ":xr(f);var m=f.length;if(m<2)return m?jg(f,l):f;var S=jg(f,rf(l/ks(f)));return Ts(f)?$o(ii(S),0,l).join(""):S.slice(0,l)}function WV(l,f,m,S){var A=f&y,N=nu(l);function M(){for(var F=-1,W=arguments.length,ae=-1,se=S.length,ce=X(se+W),ye=this&&this!==Pn&&this instanceof M?N:l;++ae<se;)ce[ae]=S[ae];for(;W--;)ce[ae++]=arguments[++F];return yr(ye,A?m:this,ce)}return M}function uC(l){return function(f,m,S){return S&&typeof S!="number"&&qn(f,m,S)&&(m=S=n),f=Yi(f),m===n?(m=f,f=0):m=Yi(m),S=S===n?f<m?1:-1:Yi(S),AV(f,m,S,l)}}function bf(l){return function(f,m){return typeof f=="string"&&typeof m=="string"||(f=Ur(f),m=Ur(m)),l(f,m)}}function cC(l,f,m,S,A,N,M,F,W,ae){var se=f&E,ce=se?M:n,ye=se?n:M,Ie=se?N:n,We=se?n:N;f|=se?O:R,f&=~(se?R:O),f&C||(f&=-4);var Je=[l,f,A,Ie,ce,We,ye,F,W,ae],He=m.apply(n,Je);return Zg(l)&&CC(He,Je),He.placeholder=S,SC(He,l,f)}function Hg(l){var f=an[l];return function(m,S){if(m=Ur(m),S=S==null?0:Ln(Qe(S),292),S&&S1(m)){var A=(yt(m)+"e").split("e"),N=f(A[0]+"e"+(+A[1]+S));return A=(yt(N)+"e").split("e"),+(A[0]+"e"+(+A[1]-S))}return f(m)}}var HV=Ds&&1/qc(new Ds([,-0]))[1]==ee?function(l){return new Ds(l)}:dm;function fC(l){return function(f){var m=$n(f);return m==Z?xg(f):m==le?sF(f):J$(f,l(f))}}function Ui(l,f,m,S,A,N,M,F){var W=f&w;if(!W&&typeof l!="function")throw new Vr(a);var ae=S?S.length:0;if(ae||(f&=-97,S=A=n),M=M===n?M:sn(Qe(M),0),F=F===n?F:Qe(F),ae-=A?A.length:0,f&R){var se=S,ce=A;S=A=n}var ye=W?n:qg(l),Ie=[l,f,m,S,A,se,ce,N,M,F];if(ye&&oB(Ie,ye),l=Ie[0],f=Ie[1],m=Ie[2],S=Ie[3],A=Ie[4],F=Ie[9]=Ie[9]===n?W?0:l.length:sn(Ie[9]-ae,0),!F&&f&(E|_)&&(f&=-25),!f||f==y)var We=BV(l,f,m);else f==E||f==_?We=zV(l,f,F):(f==O||f==(y|O))&&!A.length?We=WV(l,f,m,S):We=mf.apply(n,Ie);var Je=ye?U1:CC;return SC(Je(We,Ie),l,f)}function dC(l,f,m,S){return l===n||ai(l,Ms[m])&&!vt.call(S,m)?f:l}function pC(l,f,m,S,A,N){return zt(l)&&zt(f)&&(N.set(f,l),df(l,f,n,pC,N),N.delete(f)),l}function UV(l){return ou(l)?n:l}function hC(l,f,m,S,A,N){var M=m&v,F=l.length,W=f.length;if(F!=W&&!(M&&W>F))return!1;var ae=N.get(l),se=N.get(f);if(ae&&se)return ae==f&&se==l;var ce=-1,ye=!0,Ie=m&b?new _a:n;for(N.set(l,f),N.set(f,l);++ce<F;){var We=l[ce],Je=f[ce];if(S)var He=M?S(Je,We,ce,f,l,N):S(We,Je,ce,l,f,N);if(He!==n){if(He)continue;ye=!1;break}if(Ie){if(!hg(f,function(it,lt){if(!Ul(Ie,lt)&&(We===it||A(We,it,m,S,N)))return Ie.push(lt)})){ye=!1;break}}else if(!(We===Je||A(We,Je,m,S,N))){ye=!1;break}}return N.delete(l),N.delete(f),ye}function GV(l,f,m,S,A,N,M){switch(m){case ot:if(l.byteLength!=f.byteLength||l.byteOffset!=f.byteOffset)return!1;l=l.buffer,f=f.buffer;case Ct:return!(l.byteLength!=f.byteLength||!N(new Jc(l),new Jc(f)));case Fe:case Y:case Re:return ai(+l,+f);case ne:return l.name==f.name&&l.message==f.message;case ve:case be:return l==f+"";case Z:var F=xg;case le:var W=S&v;if(F||(F=qc),l.size!=f.size&&!W)return!1;var ae=M.get(l);if(ae)return ae==f;S|=b,M.set(l,f);var se=hC(F(l),F(f),S,A,N,M);return M.delete(l),se;case ke:if(Xl)return Xl.call(l)==Xl.call(f)}return!1}function qV(l,f,m,S,A,N){var M=m&v,F=Ug(l),W=F.length,ae=Ug(f),se=ae.length;if(W!=se&&!M)return!1;for(var ce=W;ce--;){var ye=F[ce];if(!(M?ye in f:vt.call(f,ye)))return!1}var Ie=N.get(l),We=N.get(f);if(Ie&&We)return Ie==f&&We==l;var Je=!0;N.set(l,f),N.set(f,l);for(var He=M;++ce<W;){ye=F[ce];var it=l[ye],lt=f[ye];if(S)var Cr=M?S(lt,it,ye,f,l,N):S(it,lt,ye,l,f,N);if(!(Cr===n?it===lt||A(it,lt,m,S,N):Cr)){Je=!1;break}He||(He=ye=="constructor")}if(Je&&!He){var Kn=l.constructor,Sr=f.constructor;Kn!=Sr&&"constructor"in l&&"constructor"in f&&!(typeof Kn=="function"&&Kn instanceof Kn&&typeof Sr=="function"&&Sr instanceof Sr)&&(Je=!1)}return N.delete(l),N.delete(f),Je}function Gi(l){return Jg(xC(l,n,RC),l+"")}function Ug(l){return M1(l,bn,Yg)}function Gg(l){return M1(l,or,gC)}var qg=af?function(l){return af.get(l)}:dm;function xf(l){for(var f=l.name+"",m=js[f],S=vt.call(js,f)?m.length:0;S--;){var A=m[S],N=A.func;if(N==null||N==l)return A.name}return f}function Vs(l){var f=vt.call(T,"placeholder")?T:l;return f.placeholder}function Be(){var l=T.iteratee||cm;return l=l===cm?L1:l,arguments.length?l(arguments[0],arguments[1]):l}function wf(l,f){var m=l.__data__;return tB(f)?m[typeof f=="string"?"string":"hash"]:m.map}function Kg(l){for(var f=bn(l),m=f.length;m--;){var S=f[m],A=l[S];f[m]=[S,A,yC(A)]}return f}function Aa(l,f){var m=iF(l,f);return j1(m)?m:n}function KV(l){var f=vt.call(l,Sa),m=l[Sa];try{l[Sa]=n;var S=!0}catch{}var A=Zc.call(l);return S&&(f?l[Sa]=m:delete l[Sa]),A}var Yg=Cg?function(l){return l==null?[]:(l=_t(l),To(Cg(l),function(f){return w1.call(l,f)}))}:pm,gC=Cg?function(l){for(var f=[];l;)ko(f,Yg(l)),l=ef(l);return f}:pm,$n=Gn;(Sg&&$n(new Sg(new ArrayBuffer(1)))!=ot||ql&&$n(new ql)!=Z||Eg&&$n(Eg.resolve())!=me||Ds&&$n(new Ds)!=le||Kl&&$n(new Kl)!=Tt)&&($n=function(l){var f=Gn(l),m=f==fe?l.constructor:n,S=m?Ra(m):"";if(S)switch(S){case IF:return ot;case TF:return Z;case kF:return me;case NF:return le;case MF:return Tt}return f});function YV(l,f,m){for(var S=-1,A=m.length;++S<A;){var N=m[S],M=N.size;switch(N.type){case"drop":l+=M;break;case"dropRight":f-=M;break;case"take":f=Ln(f,l+M);break;case"takeRight":l=sn(l,f-M);break}}return{start:l,end:f}}function XV(l){var f=l.match(rt);return f?f[1].split(vi):[]}function mC(l,f,m){f=Lo(f,l);for(var S=-1,A=f.length,N=!1;++S<A;){var M=Ci(f[S]);if(!(N=l!=null&&m(l,M)))break;l=l[M]}return N||++S!=A?N:(A=l==null?0:l.length,!!A&&Af(A)&&qi(M,A)&&(Ye(l)||Ia(l)))}function ZV(l){var f=l.length,m=new l.constructor(f);return f&&typeof l[0]=="string"&&vt.call(l,"index")&&(m.index=l.index,m.input=l.input),m}function vC(l){return typeof l.constructor=="function"&&!ru(l)?Ls(ef(l)):{}}function QV(l,f,m){var S=l.constructor;switch(f){case Ct:return zg(l);case Fe:case Y:return new S(+l);case ot:return DV(l,m);case kt:case mn:case on:case _n:case Qt:case vn:case hr:case Hn:case pt:return J1(l,m);case Z:return new S;case Re:case be:return new S(l);case ve:return jV(l);case le:return new S;case ke:return LV(l)}}function JV(l,f){var m=f.length;if(!m)return l;var S=m-1;return f[S]=(m>1?"& ":"")+f[S],f=f.join(m>2?", ":" "),l.replace(Un,`{
|
|
169
|
-
|
|
170
|
-
`)}function eB(l){return Ye(l)||Ia(l)||!!(C1&&l&&l[C1])}function qi(l,f){var m=typeof l;return f=f??Q,!!f&&(m=="number"||m!="symbol"&&mr.test(l))&&l>-1&&l%1==0&&l<f}function qn(l,f,m){if(!zt(m))return!1;var S=typeof f;return(S=="number"?ir(m)&&qi(f,m.length):S=="string"&&f in m)?ai(m[f],l):!1}function Xg(l,f){if(Ye(l))return!1;var m=typeof l;return m=="number"||m=="symbol"||m=="boolean"||l==null||wr(l)?!0:va.test(l)||!yn.test(l)||f!=null&&l in _t(f)}function tB(l){var f=typeof l;return f=="string"||f=="number"||f=="symbol"||f=="boolean"?l!=="__proto__":l===null}function Zg(l){var f=xf(l),m=T[f];if(typeof m!="function"||!(f in at.prototype))return!1;if(l===m)return!0;var S=qg(m);return!!S&&l===S[0]}function nB(l){return!!y1&&y1 in l}var rB=Yc?Ki:hm;function ru(l){var f=l&&l.constructor,m=typeof f=="function"&&f.prototype||Ms;return l===m}function yC(l){return l===l&&!zt(l)}function bC(l,f){return function(m){return m==null?!1:m[l]===f&&(f!==n||l in _t(m))}}function iB(l){var f=Of(l,function(S){return m.size===c&&m.clear(),S}),m=f.cache;return f}function oB(l,f){var m=l[1],S=f[1],A=m|S,N=A<(y|w|I),M=S==I&&m==E||S==I&&m==k&&l[7].length<=f[8]||S==(I|k)&&f[7].length<=f[8]&&m==E;if(!(N||M))return l;S&y&&(l[2]=f[2],A|=m&y?0:C);var F=f[3];if(F){var W=l[3];l[3]=W?tC(W,F,f[4]):F,l[4]=W?No(l[3],d):f[4]}return F=f[5],F&&(W=l[5],l[5]=W?nC(W,F,f[6]):F,l[6]=W?No(l[5],d):f[6]),F=f[7],F&&(l[7]=F),S&I&&(l[8]=l[8]==null?f[8]:Ln(l[8],f[8])),l[9]==null&&(l[9]=f[9]),l[0]=f[0],l[1]=A,l}function aB(l){var f=[];if(l!=null)for(var m in _t(l))f.push(m);return f}function sB(l){return Zc.call(l)}function xC(l,f,m){return f=sn(f===n?l.length-1:f,0),function(){for(var S=arguments,A=-1,N=sn(S.length-f,0),M=X(N);++A<N;)M[A]=S[f+A];A=-1;for(var F=X(f+1);++A<f;)F[A]=S[A];return F[f]=m(M),yr(l,this,F)}}function wC(l,f){return f.length<2?l:Pa(l,Wr(f,0,-1))}function lB(l,f){for(var m=l.length,S=Ln(f.length,m),A=rr(l);S--;){var N=f[S];l[S]=qi(N,m)?A[N]:n}return l}function Qg(l,f){if(!(f==="constructor"&&typeof l[f]=="function")&&f!="__proto__")return l[f]}var CC=EC(U1),iu=SF||function(l,f){return Pn.setTimeout(l,f)},Jg=EC(TV);function SC(l,f,m){var S=f+"";return Jg(l,JV(S,uB(XV(S),m)))}function EC(l){var f=0,m=0;return function(){var S=PF(),A=H-(S-m);if(m=S,A>0){if(++f>=D)return arguments[0]}else f=0;return l.apply(n,arguments)}}function Cf(l,f){var m=-1,S=l.length,A=S-1;for(f=f===n?S:f;++m<f;){var N=Dg(m,A),M=l[N];l[N]=l[m],l[m]=M}return l.length=f,l}var _C=iB(function(l){var f=[];return l.charCodeAt(0)===46&&f.push(""),l.replace(Ao,function(m,S,A,N){f.push(A?N.replace(Ll,"$1"):S||m)}),f});function Ci(l){if(typeof l=="string"||wr(l))return l;var f=l+"";return f=="0"&&1/l==-ee?"-0":f}function Ra(l){if(l!=null){try{return Xc.call(l)}catch{}try{return l+""}catch{}}return""}function uB(l,f){return Fr(we,function(m){var S="_."+m[0];f&m[1]&&!Uc(l,S)&&l.push(S)}),l.sort()}function OC(l){if(l instanceof at)return l.clone();var f=new Br(l.__wrapped__,l.__chain__);return f.__actions__=rr(l.__actions__),f.__index__=l.__index__,f.__values__=l.__values__,f}function cB(l,f,m){(m?qn(l,f,m):f===n)?f=1:f=sn(Qe(f),0);var S=l==null?0:l.length;if(!S||f<1)return[];for(var A=0,N=0,M=X(rf(S/f));A<S;)M[N++]=Wr(l,A,A+=f);return M}function fB(l){for(var f=-1,m=l==null?0:l.length,S=0,A=[];++f<m;){var N=l[f];N&&(A[S++]=N)}return A}function dB(){var l=arguments.length;if(!l)return[];for(var f=X(l-1),m=arguments[0],S=l;S--;)f[S-1]=arguments[S];return ko(Ye(m)?rr(m):[m],An(f,1))}var pB=tt(function(l,f){return Kt(l)?Ql(l,An(f,1,Kt,!0)):[]}),hB=tt(function(l,f){var m=Hr(f);return Kt(m)&&(m=n),Kt(l)?Ql(l,An(f,1,Kt,!0),Be(m,2)):[]}),gB=tt(function(l,f){var m=Hr(f);return Kt(m)&&(m=n),Kt(l)?Ql(l,An(f,1,Kt,!0),n,m):[]});function mB(l,f,m){var S=l==null?0:l.length;return S?(f=m||f===n?1:Qe(f),Wr(l,f<0?0:f,S)):[]}function vB(l,f,m){var S=l==null?0:l.length;return S?(f=m||f===n?1:Qe(f),f=S-f,Wr(l,0,f<0?0:f)):[]}function yB(l,f){return l&&l.length?hf(l,Be(f,3),!0,!0):[]}function bB(l,f){return l&&l.length?hf(l,Be(f,3),!0):[]}function xB(l,f,m,S){var A=l==null?0:l.length;return A?(m&&typeof m!="number"&&qn(l,f,m)&&(m=0,S=A),dV(l,f,m,S)):[]}function PC(l,f,m){var S=l==null?0:l.length;if(!S)return-1;var A=m==null?0:Qe(m);return A<0&&(A=sn(S+A,0)),Gc(l,Be(f,3),A)}function AC(l,f,m){var S=l==null?0:l.length;if(!S)return-1;var A=S-1;return m!==n&&(A=Qe(m),A=m<0?sn(S+A,0):Ln(A,S-1)),Gc(l,Be(f,3),A,!0)}function RC(l){var f=l==null?0:l.length;return f?An(l,1):[]}function wB(l){var f=l==null?0:l.length;return f?An(l,ee):[]}function CB(l,f){var m=l==null?0:l.length;return m?(f=f===n?1:Qe(f),An(l,f)):[]}function SB(l){for(var f=-1,m=l==null?0:l.length,S={};++f<m;){var A=l[f];S[A[0]]=A[1]}return S}function IC(l){return l&&l.length?l[0]:n}function EB(l,f,m){var S=l==null?0:l.length;if(!S)return-1;var A=m==null?0:Qe(m);return A<0&&(A=sn(S+A,0)),Is(l,f,A)}function _B(l){var f=l==null?0:l.length;return f?Wr(l,0,-1):[]}var OB=tt(function(l){var f=Ft(l,Vg);return f.length&&f[0]===l[0]?Ig(f):[]}),PB=tt(function(l){var f=Hr(l),m=Ft(l,Vg);return f===Hr(m)?f=n:m.pop(),m.length&&m[0]===l[0]?Ig(m,Be(f,2)):[]}),AB=tt(function(l){var f=Hr(l),m=Ft(l,Vg);return f=typeof f=="function"?f:n,f&&m.pop(),m.length&&m[0]===l[0]?Ig(m,n,f):[]});function RB(l,f){return l==null?"":_F.call(l,f)}function Hr(l){var f=l==null?0:l.length;return f?l[f-1]:n}function IB(l,f,m){var S=l==null?0:l.length;if(!S)return-1;var A=S;return m!==n&&(A=Qe(m),A=A<0?sn(S+A,0):Ln(A,S-1)),f===f?uF(l,f,A):Gc(l,c1,A,!0)}function TB(l,f){return l&&l.length?B1(l,Qe(f)):n}var kB=tt(TC);function TC(l,f){return l&&l.length&&f&&f.length?Mg(l,f):l}function NB(l,f,m){return l&&l.length&&f&&f.length?Mg(l,f,Be(m,2)):l}function MB(l,f,m){return l&&l.length&&f&&f.length?Mg(l,f,n,m):l}var DB=Gi(function(l,f){var m=l==null?0:l.length,S=Og(l,f);return H1(l,Ft(f,function(A){return qi(A,m)?+A:A}).sort(eC)),S});function jB(l,f){var m=[];if(!(l&&l.length))return m;var S=-1,A=[],N=l.length;for(f=Be(f,3);++S<N;){var M=l[S];f(M,S,l)&&(m.push(M),A.push(S))}return H1(l,A),m}function em(l){return l==null?l:RF.call(l)}function LB(l,f,m){var S=l==null?0:l.length;return S?(m&&typeof m!="number"&&qn(l,f,m)?(f=0,m=S):(f=f==null?0:Qe(f),m=m===n?S:Qe(m)),Wr(l,f,m)):[]}function $B(l,f){return pf(l,f)}function FB(l,f,m){return Lg(l,f,Be(m,2))}function VB(l,f){var m=l==null?0:l.length;if(m){var S=pf(l,f);if(S<m&&ai(l[S],f))return S}return-1}function BB(l,f){return pf(l,f,!0)}function zB(l,f,m){return Lg(l,f,Be(m,2),!0)}function WB(l,f){var m=l==null?0:l.length;if(m){var S=pf(l,f,!0)-1;if(ai(l[S],f))return S}return-1}function HB(l){return l&&l.length?G1(l):[]}function UB(l,f){return l&&l.length?G1(l,Be(f,2)):[]}function GB(l){var f=l==null?0:l.length;return f?Wr(l,1,f):[]}function qB(l,f,m){return l&&l.length?(f=m||f===n?1:Qe(f),Wr(l,0,f<0?0:f)):[]}function KB(l,f,m){var S=l==null?0:l.length;return S?(f=m||f===n?1:Qe(f),f=S-f,Wr(l,f<0?0:f,S)):[]}function YB(l,f){return l&&l.length?hf(l,Be(f,3),!1,!0):[]}function XB(l,f){return l&&l.length?hf(l,Be(f,3)):[]}var ZB=tt(function(l){return jo(An(l,1,Kt,!0))}),QB=tt(function(l){var f=Hr(l);return Kt(f)&&(f=n),jo(An(l,1,Kt,!0),Be(f,2))}),JB=tt(function(l){var f=Hr(l);return f=typeof f=="function"?f:n,jo(An(l,1,Kt,!0),n,f)});function ez(l){return l&&l.length?jo(l):[]}function tz(l,f){return l&&l.length?jo(l,Be(f,2)):[]}function nz(l,f){return f=typeof f=="function"?f:n,l&&l.length?jo(l,n,f):[]}function tm(l){if(!(l&&l.length))return[];var f=0;return l=To(l,function(m){if(Kt(m))return f=sn(m.length,f),!0}),yg(f,function(m){return Ft(l,gg(m))})}function kC(l,f){if(!(l&&l.length))return[];var m=tm(l);return f==null?m:Ft(m,function(S){return yr(f,n,S)})}var rz=tt(function(l,f){return Kt(l)?Ql(l,f):[]}),iz=tt(function(l){return Fg(To(l,Kt))}),oz=tt(function(l){var f=Hr(l);return Kt(f)&&(f=n),Fg(To(l,Kt),Be(f,2))}),az=tt(function(l){var f=Hr(l);return f=typeof f=="function"?f:n,Fg(To(l,Kt),n,f)}),sz=tt(tm);function lz(l,f){return X1(l||[],f||[],Zl)}function uz(l,f){return X1(l||[],f||[],tu)}var cz=tt(function(l){var f=l.length,m=f>1?l[f-1]:n;return m=typeof m=="function"?(l.pop(),m):n,kC(l,m)});function NC(l){var f=T(l);return f.__chain__=!0,f}function fz(l,f){return f(l),l}function Sf(l,f){return f(l)}var dz=Gi(function(l){var f=l.length,m=f?l[0]:0,S=this.__wrapped__,A=function(N){return Og(N,l)};return f>1||this.__actions__.length||!(S instanceof at)||!qi(m)?this.thru(A):(S=S.slice(m,+m+(f?1:0)),S.__actions__.push({func:Sf,args:[A],thisArg:n}),new Br(S,this.__chain__).thru(function(N){return f&&!N.length&&N.push(n),N}))});function pz(){return NC(this)}function hz(){return new Br(this.value(),this.__chain__)}function gz(){this.__values__===n&&(this.__values__=qC(this.value()));var l=this.__index__>=this.__values__.length,f=l?n:this.__values__[this.__index__++];return{done:l,value:f}}function mz(){return this}function vz(l){for(var f,m=this;m instanceof lf;){var S=OC(m);S.__index__=0,S.__values__=n,f?A.__wrapped__=S:f=S;var A=S;m=m.__wrapped__}return A.__wrapped__=l,f}function yz(){var l=this.__wrapped__;if(l instanceof at){var f=l;return this.__actions__.length&&(f=new at(this)),f=f.reverse(),f.__actions__.push({func:Sf,args:[em],thisArg:n}),new Br(f,this.__chain__)}return this.thru(em)}function bz(){return Y1(this.__wrapped__,this.__actions__)}var xz=gf(function(l,f,m){vt.call(l,m)?++l[m]:Hi(l,m,1)});function wz(l,f,m){var S=Ye(l)?l1:fV;return m&&qn(l,f,m)&&(f=n),S(l,Be(f,3))}function Cz(l,f){var m=Ye(l)?To:k1;return m(l,Be(f,3))}var Sz=aC(PC),Ez=aC(AC);function _z(l,f){return An(Ef(l,f),1)}function Oz(l,f){return An(Ef(l,f),ee)}function Pz(l,f,m){return m=m===n?1:Qe(m),An(Ef(l,f),m)}function MC(l,f){var m=Ye(l)?Fr:Do;return m(l,Be(f,3))}function DC(l,f){var m=Ye(l)?G$:T1;return m(l,Be(f,3))}var Az=gf(function(l,f,m){vt.call(l,m)?l[m].push(f):Hi(l,m,[f])});function Rz(l,f,m,S){l=ir(l)?l:zs(l),m=m&&!S?Qe(m):0;var A=l.length;return m<0&&(m=sn(A+m,0)),Rf(l)?m<=A&&l.indexOf(f,m)>-1:!!A&&Is(l,f,m)>-1}var Iz=tt(function(l,f,m){var S=-1,A=typeof f=="function",N=ir(l)?X(l.length):[];return Do(l,function(M){N[++S]=A?yr(f,M,m):Jl(M,f,m)}),N}),Tz=gf(function(l,f,m){Hi(l,m,f)});function Ef(l,f){var m=Ye(l)?Ft:$1;return m(l,Be(f,3))}function kz(l,f,m,S){return l==null?[]:(Ye(f)||(f=f==null?[]:[f]),m=S?n:m,Ye(m)||(m=m==null?[]:[m]),z1(l,f,m))}var Nz=gf(function(l,f,m){l[m?0:1].push(f)},function(){return[[],[]]});function Mz(l,f,m){var S=Ye(l)?pg:d1,A=arguments.length<3;return S(l,Be(f,4),m,A,Do)}function Dz(l,f,m){var S=Ye(l)?q$:d1,A=arguments.length<3;return S(l,Be(f,4),m,A,T1)}function jz(l,f){var m=Ye(l)?To:k1;return m(l,Pf(Be(f,3)))}function Lz(l){var f=Ye(l)?P1:RV;return f(l)}function $z(l,f,m){(m?qn(l,f,m):f===n)?f=1:f=Qe(f);var S=Ye(l)?aV:IV;return S(l,f)}function Fz(l){var f=Ye(l)?sV:kV;return f(l)}function Vz(l){if(l==null)return 0;if(ir(l))return Rf(l)?ks(l):l.length;var f=$n(l);return f==Z||f==le?l.size:kg(l).length}function Bz(l,f,m){var S=Ye(l)?hg:NV;return m&&qn(l,f,m)&&(f=n),S(l,Be(f,3))}var zz=tt(function(l,f){if(l==null)return[];var m=f.length;return m>1&&qn(l,f[0],f[1])?f=[]:m>2&&qn(f[0],f[1],f[2])&&(f=[f[0]]),z1(l,An(f,1),[])}),_f=CF||function(){return Pn.Date.now()};function Wz(l,f){if(typeof f!="function")throw new Vr(a);return l=Qe(l),function(){if(--l<1)return f.apply(this,arguments)}}function jC(l,f,m){return f=m?n:f,f=l&&f==null?l.length:f,Ui(l,I,n,n,n,n,f)}function LC(l,f){var m;if(typeof f!="function")throw new Vr(a);return l=Qe(l),function(){return--l>0&&(m=f.apply(this,arguments)),l<=1&&(f=n),m}}var nm=tt(function(l,f,m){var S=y;if(m.length){var A=No(m,Vs(nm));S|=O}return Ui(l,S,f,m,A)}),$C=tt(function(l,f,m){var S=y|w;if(m.length){var A=No(m,Vs($C));S|=O}return Ui(f,S,l,m,A)});function FC(l,f,m){f=m?n:f;var S=Ui(l,E,n,n,n,n,n,f);return S.placeholder=FC.placeholder,S}function VC(l,f,m){f=m?n:f;var S=Ui(l,_,n,n,n,n,n,f);return S.placeholder=VC.placeholder,S}function BC(l,f,m){var S,A,N,M,F,W,ae=0,se=!1,ce=!1,ye=!0;if(typeof l!="function")throw new Vr(a);f=Ur(f)||0,zt(m)&&(se=!!m.leading,ce="maxWait"in m,N=ce?sn(Ur(m.maxWait)||0,f):N,ye="trailing"in m?!!m.trailing:ye);function Ie(Yt){var si=S,Xi=A;return S=A=n,ae=Yt,M=l.apply(Xi,si),M}function We(Yt){return ae=Yt,F=iu(it,f),se?Ie(Yt):M}function Je(Yt){var si=Yt-W,Xi=Yt-ae,aS=f-si;return ce?Ln(aS,N-Xi):aS}function He(Yt){var si=Yt-W,Xi=Yt-ae;return W===n||si>=f||si<0||ce&&Xi>=N}function it(){var Yt=_f();if(He(Yt))return lt(Yt);F=iu(it,Je(Yt))}function lt(Yt){return F=n,ye&&S?Ie(Yt):(S=A=n,M)}function Cr(){F!==n&&Z1(F),ae=0,S=W=A=F=n}function Kn(){return F===n?M:lt(_f())}function Sr(){var Yt=_f(),si=He(Yt);if(S=arguments,A=this,W=Yt,si){if(F===n)return We(W);if(ce)return Z1(F),F=iu(it,f),Ie(W)}return F===n&&(F=iu(it,f)),M}return Sr.cancel=Cr,Sr.flush=Kn,Sr}var Hz=tt(function(l,f){return I1(l,1,f)}),Uz=tt(function(l,f,m){return I1(l,Ur(f)||0,m)});function Gz(l){return Ui(l,B)}function Of(l,f){if(typeof l!="function"||f!=null&&typeof f!="function")throw new Vr(a);var m=function(){var S=arguments,A=f?f.apply(this,S):S[0],N=m.cache;if(N.has(A))return N.get(A);var M=l.apply(this,S);return m.cache=N.set(A,M)||N,M};return m.cache=new(Of.Cache||Wi),m}Of.Cache=Wi;function Pf(l){if(typeof l!="function")throw new Vr(a);return function(){var f=arguments;switch(f.length){case 0:return!l.call(this);case 1:return!l.call(this,f[0]);case 2:return!l.call(this,f[0],f[1]);case 3:return!l.call(this,f[0],f[1],f[2])}return!l.apply(this,f)}}function qz(l){return LC(2,l)}var Kz=MV(function(l,f){f=f.length==1&&Ye(f[0])?Ft(f[0],br(Be())):Ft(An(f,1),br(Be()));var m=f.length;return tt(function(S){for(var A=-1,N=Ln(S.length,m);++A<N;)S[A]=f[A].call(this,S[A]);return yr(l,this,S)})}),rm=tt(function(l,f){var m=No(f,Vs(rm));return Ui(l,O,n,f,m)}),zC=tt(function(l,f){var m=No(f,Vs(zC));return Ui(l,R,n,f,m)}),Yz=Gi(function(l,f){return Ui(l,k,n,n,n,f)});function Xz(l,f){if(typeof l!="function")throw new Vr(a);return f=f===n?f:Qe(f),tt(l,f)}function Zz(l,f){if(typeof l!="function")throw new Vr(a);return f=f==null?0:sn(Qe(f),0),tt(function(m){var S=m[f],A=$o(m,0,f);return S&&ko(A,S),yr(l,this,A)})}function Qz(l,f,m){var S=!0,A=!0;if(typeof l!="function")throw new Vr(a);return zt(m)&&(S="leading"in m?!!m.leading:S,A="trailing"in m?!!m.trailing:A),BC(l,f,{leading:S,maxWait:f,trailing:A})}function Jz(l){return jC(l,1)}function e3(l,f){return rm(Bg(f),l)}function t3(){if(!arguments.length)return[];var l=arguments[0];return Ye(l)?l:[l]}function n3(l){return zr(l,h)}function r3(l,f){return f=typeof f=="function"?f:n,zr(l,h,f)}function i3(l){return zr(l,p|h)}function o3(l,f){return f=typeof f=="function"?f:n,zr(l,p|h,f)}function a3(l,f){return f==null||R1(l,f,bn(f))}function ai(l,f){return l===f||l!==l&&f!==f}var s3=bf(Rg),l3=bf(function(l,f){return l>=f}),Ia=D1((function(){return arguments})())?D1:function(l){return Ut(l)&&vt.call(l,"callee")&&!w1.call(l,"callee")},Ye=X.isArray,u3=n1?br(n1):vV;function ir(l){return l!=null&&Af(l.length)&&!Ki(l)}function Kt(l){return Ut(l)&&ir(l)}function c3(l){return l===!0||l===!1||Ut(l)&&Gn(l)==Fe}var Fo=EF||hm,f3=r1?br(r1):yV;function d3(l){return Ut(l)&&l.nodeType===1&&!ou(l)}function p3(l){if(l==null)return!0;if(ir(l)&&(Ye(l)||typeof l=="string"||typeof l.splice=="function"||Fo(l)||Bs(l)||Ia(l)))return!l.length;var f=$n(l);if(f==Z||f==le)return!l.size;if(ru(l))return!kg(l).length;for(var m in l)if(vt.call(l,m))return!1;return!0}function h3(l,f){return eu(l,f)}function g3(l,f,m){m=typeof m=="function"?m:n;var S=m?m(l,f):n;return S===n?eu(l,f,n,m):!!S}function im(l){if(!Ut(l))return!1;var f=Gn(l);return f==ne||f==oe||typeof l.message=="string"&&typeof l.name=="string"&&!ou(l)}function m3(l){return typeof l=="number"&&S1(l)}function Ki(l){if(!zt(l))return!1;var f=Gn(l);return f==$||f==ie||f==Ke||f==de}function WC(l){return typeof l=="number"&&l==Qe(l)}function Af(l){return typeof l=="number"&&l>-1&&l%1==0&&l<=Q}function zt(l){var f=typeof l;return l!=null&&(f=="object"||f=="function")}function Ut(l){return l!=null&&typeof l=="object"}var HC=i1?br(i1):xV;function v3(l,f){return l===f||Tg(l,f,Kg(f))}function y3(l,f,m){return m=typeof m=="function"?m:n,Tg(l,f,Kg(f),m)}function b3(l){return UC(l)&&l!=+l}function x3(l){if(rB(l))throw new qe(o);return j1(l)}function w3(l){return l===null}function C3(l){return l==null}function UC(l){return typeof l=="number"||Ut(l)&&Gn(l)==Re}function ou(l){if(!Ut(l)||Gn(l)!=fe)return!1;var f=ef(l);if(f===null)return!0;var m=vt.call(f,"constructor")&&f.constructor;return typeof m=="function"&&m instanceof m&&Xc.call(m)==yF}var om=o1?br(o1):wV;function S3(l){return WC(l)&&l>=-Q&&l<=Q}var GC=a1?br(a1):CV;function Rf(l){return typeof l=="string"||!Ye(l)&&Ut(l)&&Gn(l)==be}function wr(l){return typeof l=="symbol"||Ut(l)&&Gn(l)==ke}var Bs=s1?br(s1):SV;function E3(l){return l===n}function _3(l){return Ut(l)&&$n(l)==Tt}function O3(l){return Ut(l)&&Gn(l)==Dn}var P3=bf(Ng),A3=bf(function(l,f){return l<=f});function qC(l){if(!l)return[];if(ir(l))return Rf(l)?ii(l):rr(l);if(Gl&&l[Gl])return aF(l[Gl]());var f=$n(l),m=f==Z?xg:f==le?qc:zs;return m(l)}function Yi(l){if(!l)return l===0?l:0;if(l=Ur(l),l===ee||l===-ee){var f=l<0?-1:1;return f*pe}return l===l?l:0}function Qe(l){var f=Yi(l),m=f%1;return f===f?m?f-m:f:0}function KC(l){return l?Oa(Qe(l),0,Ae):0}function Ur(l){if(typeof l=="number")return l;if(wr(l))return K;if(zt(l)){var f=typeof l.valueOf=="function"?l.valueOf():l;l=zt(f)?f+"":f}if(typeof l!="string")return l===0?l:+l;l=p1(l);var m=Mc.test(l);return m||$l.test(l)?W$(l.slice(2),m?2:8):bs.test(l)?K:+l}function YC(l){return wi(l,or(l))}function R3(l){return l?Oa(Qe(l),-Q,Q):l===0?l:0}function yt(l){return l==null?"":xr(l)}var I3=$s(function(l,f){if(ru(f)||ir(f)){wi(f,bn(f),l);return}for(var m in f)vt.call(f,m)&&Zl(l,m,f[m])}),XC=$s(function(l,f){wi(f,or(f),l)}),If=$s(function(l,f,m,S){wi(f,or(f),l,S)}),T3=$s(function(l,f,m,S){wi(f,bn(f),l,S)}),k3=Gi(Og);function N3(l,f){var m=Ls(l);return f==null?m:A1(m,f)}var M3=tt(function(l,f){l=_t(l);var m=-1,S=f.length,A=S>2?f[2]:n;for(A&&qn(f[0],f[1],A)&&(S=1);++m<S;)for(var N=f[m],M=or(N),F=-1,W=M.length;++F<W;){var ae=M[F],se=l[ae];(se===n||ai(se,Ms[ae])&&!vt.call(l,ae))&&(l[ae]=N[ae])}return l}),D3=tt(function(l){return l.push(n,pC),yr(ZC,n,l)});function j3(l,f){return u1(l,Be(f,3),xi)}function L3(l,f){return u1(l,Be(f,3),Ag)}function $3(l,f){return l==null?l:Pg(l,Be(f,3),or)}function F3(l,f){return l==null?l:N1(l,Be(f,3),or)}function V3(l,f){return l&&xi(l,Be(f,3))}function B3(l,f){return l&&Ag(l,Be(f,3))}function z3(l){return l==null?[]:ff(l,bn(l))}function W3(l){return l==null?[]:ff(l,or(l))}function am(l,f,m){var S=l==null?n:Pa(l,f);return S===n?m:S}function H3(l,f){return l!=null&&mC(l,f,pV)}function sm(l,f){return l!=null&&mC(l,f,hV)}var U3=lC(function(l,f,m){f!=null&&typeof f.toString!="function"&&(f=Zc.call(f)),l[f]=m},um(ar)),G3=lC(function(l,f,m){f!=null&&typeof f.toString!="function"&&(f=Zc.call(f)),vt.call(l,f)?l[f].push(m):l[f]=[m]},Be),q3=tt(Jl);function bn(l){return ir(l)?O1(l):kg(l)}function or(l){return ir(l)?O1(l,!0):EV(l)}function K3(l,f){var m={};return f=Be(f,3),xi(l,function(S,A,N){Hi(m,f(S,A,N),S)}),m}function Y3(l,f){var m={};return f=Be(f,3),xi(l,function(S,A,N){Hi(m,A,f(S,A,N))}),m}var X3=$s(function(l,f,m){df(l,f,m)}),ZC=$s(function(l,f,m,S){df(l,f,m,S)}),Z3=Gi(function(l,f){var m={};if(l==null)return m;var S=!1;f=Ft(f,function(N){return N=Lo(N,l),S||(S=N.length>1),N}),wi(l,Gg(l),m),S&&(m=zr(m,p|g|h,UV));for(var A=f.length;A--;)$g(m,f[A]);return m});function Q3(l,f){return QC(l,Pf(Be(f)))}var J3=Gi(function(l,f){return l==null?{}:OV(l,f)});function QC(l,f){if(l==null)return{};var m=Ft(Gg(l),function(S){return[S]});return f=Be(f),W1(l,m,function(S,A){return f(S,A[0])})}function e5(l,f,m){f=Lo(f,l);var S=-1,A=f.length;for(A||(A=1,l=n);++S<A;){var N=l==null?n:l[Ci(f[S])];N===n&&(S=A,N=m),l=Ki(N)?N.call(l):N}return l}function t5(l,f,m){return l==null?l:tu(l,f,m)}function n5(l,f,m,S){return S=typeof S=="function"?S:n,l==null?l:tu(l,f,m,S)}var JC=fC(bn),eS=fC(or);function r5(l,f,m){var S=Ye(l),A=S||Fo(l)||Bs(l);if(f=Be(f,4),m==null){var N=l&&l.constructor;A?m=S?new N:[]:zt(l)?m=Ki(N)?Ls(ef(l)):{}:m={}}return(A?Fr:xi)(l,function(M,F,W){return f(m,M,F,W)}),m}function i5(l,f){return l==null?!0:$g(l,f)}function o5(l,f,m){return l==null?l:K1(l,f,Bg(m))}function a5(l,f,m,S){return S=typeof S=="function"?S:n,l==null?l:K1(l,f,Bg(m),S)}function zs(l){return l==null?[]:bg(l,bn(l))}function s5(l){return l==null?[]:bg(l,or(l))}function l5(l,f,m){return m===n&&(m=f,f=n),m!==n&&(m=Ur(m),m=m===m?m:0),f!==n&&(f=Ur(f),f=f===f?f:0),Oa(Ur(l),f,m)}function u5(l,f,m){return f=Yi(f),m===n?(m=f,f=0):m=Yi(m),l=Ur(l),gV(l,f,m)}function c5(l,f,m){if(m&&typeof m!="boolean"&&qn(l,f,m)&&(f=m=n),m===n&&(typeof f=="boolean"?(m=f,f=n):typeof l=="boolean"&&(m=l,l=n)),l===n&&f===n?(l=0,f=1):(l=Yi(l),f===n?(f=l,l=0):f=Yi(f)),l>f){var S=l;l=f,f=S}if(m||l%1||f%1){var A=E1();return Ln(l+A*(f-l+z$("1e-"+((A+"").length-1))),f)}return Dg(l,f)}var f5=Fs(function(l,f,m){return f=f.toLowerCase(),l+(m?tS(f):f)});function tS(l){return lm(yt(l).toLowerCase())}function nS(l){return l=yt(l),l&&l.replace(yi,tF).replace(Jw,"")}function d5(l,f,m){l=yt(l),f=xr(f);var S=l.length;m=m===n?S:Oa(Qe(m),0,S);var A=m;return m-=f.length,m>=0&&l.slice(m,A)==f}function p5(l){return l=yt(l),l&&ma.test(l)?l.replace(mi,nF):l}function h5(l){return l=yt(l),l&&vs.test(l)?l.replace(Dr,"\\$&"):l}var g5=Fs(function(l,f,m){return l+(m?"-":"")+f.toLowerCase()}),m5=Fs(function(l,f,m){return l+(m?" ":"")+f.toLowerCase()}),v5=oC("toLowerCase");function y5(l,f,m){l=yt(l),f=Qe(f);var S=f?ks(l):0;if(!f||S>=f)return l;var A=(f-S)/2;return yf(of(A),m)+l+yf(rf(A),m)}function b5(l,f,m){l=yt(l),f=Qe(f);var S=f?ks(l):0;return f&&S<f?l+yf(f-S,m):l}function x5(l,f,m){l=yt(l),f=Qe(f);var S=f?ks(l):0;return f&&S<f?yf(f-S,m)+l:l}function w5(l,f,m){return m||f==null?f=0:f&&(f=+f),AF(yt(l).replace(jr,""),f||0)}function C5(l,f,m){return(m?qn(l,f,m):f===n)?f=1:f=Qe(f),jg(yt(l),f)}function S5(){var l=arguments,f=yt(l[0]);return l.length<3?f:f.replace(l[1],l[2])}var E5=Fs(function(l,f,m){return l+(m?"_":"")+f.toLowerCase()});function _5(l,f,m){return m&&typeof m!="number"&&qn(l,f,m)&&(f=m=n),m=m===n?Ae:m>>>0,m?(l=yt(l),l&&(typeof f=="string"||f!=null&&!om(f))&&(f=xr(f),!f&&Ts(l))?$o(ii(l),0,m):l.split(f,m)):[]}var O5=Fs(function(l,f,m){return l+(m?" ":"")+lm(f)});function P5(l,f,m){return l=yt(l),m=m==null?0:Oa(Qe(m),0,l.length),f=xr(f),l.slice(m,m+f.length)==f}function A5(l,f,m){var S=T.templateSettings;m&&qn(l,f,m)&&(f=n),l=yt(l),f=If({},f,S,dC);var A=If({},f.imports,S.imports,dC),N=bn(A),M=bg(A,N),F,W,ae=0,se=f.interpolate||xs,ce="__p += '",ye=wg((f.escape||xs).source+"|"+se.source+"|"+(se===nr?ys:xs).source+"|"+(f.evaluate||xs).source+"|$","g"),Ie="//# sourceURL="+(vt.call(f,"sourceURL")?(f.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++L$+"]")+`
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
167
|
+
color: hsl(${Math.max(0,Math.min(120-120*g,120))}deg 100% 31%);`,n?.key)}return i}}function qe(e,t,n,r){return{debug:()=>{var i;return(i=e?.debugAll)!=null?i:e[t]},key:process.env.NODE_ENV==="development"&&n,onChange:r}}function FX(e,t,n,r){const i=()=>{var a;return(a=o.getValue())!=null?a:e.options.renderFallbackValue},o={id:`${t.id}_${n.id}`,row:t,column:n,getValue:()=>t.getValue(r),renderValue:i,getContext:Ge(()=>[e,n,t,o],(a,s,u,c)=>({table:a,column:s,row:u,cell:c,getValue:c.getValue,renderValue:c.renderValue}),qe(e.options,"debugCells","cell.getContext"))};return e._features.forEach(a=>{a.createCell==null||a.createCell(o,n,t,e)},{}),o}function VX(e,t,n,r){var i,o;const s={...e._getDefaultColumnDef(),...t},u=s.accessorKey;let c=(i=(o=s.id)!=null?o:u?typeof String.prototype.replaceAll=="function"?u.replaceAll(".","_"):u.replace(/\./g,"_"):void 0)!=null?i:typeof s.header=="string"?s.header:void 0,f;if(s.accessorFn?f=s.accessorFn:u&&(u.includes(".")?f=g=>{let h=g;for(const b of u.split(".")){var v;h=(v=h)==null?void 0:v[b],process.env.NODE_ENV!=="production"&&h===void 0&&console.warn(`"${b}" in deeply nested key "${u}" returned undefined.`)}return h}:f=g=>g[s.accessorKey]),!c)throw process.env.NODE_ENV!=="production"?new Error(s.accessorFn?"Columns require an id when using an accessorFn":"Columns require an id when using a non-string header"):new Error;let p={id:`${String(c)}`,accessorFn:f,parent:r,depth:n,columnDef:s,columns:[],getFlatColumns:Ge(()=>[!0],()=>{var g;return[p,...(g=p.columns)==null?void 0:g.flatMap(h=>h.getFlatColumns())]},qe(e.options,"debugColumns","column.getFlatColumns")),getLeafColumns:Ge(()=>[e._getOrderColumnsFn()],g=>{var h;if((h=p.columns)!=null&&h.length){let v=p.columns.flatMap(b=>b.getLeafColumns());return g(v)}return[p]},qe(e.options,"debugColumns","column.getLeafColumns"))};for(const g of e._features)g.createColumn==null||g.createColumn(p,e);return p}const Fn="debugHeaders";function GE(e,t,n){var r;let o={id:(r=n.id)!=null?r:t.id,column:t,index:n.index,isPlaceholder:!!n.isPlaceholder,placeholderId:n.placeholderId,depth:n.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{const a=[],s=u=>{u.subHeaders&&u.subHeaders.length&&u.subHeaders.map(s),a.push(u)};return s(o),a},getContext:()=>({table:e,header:o,column:t})};return e._features.forEach(a=>{a.createHeader==null||a.createHeader(o,e)}),o}const BX={createTable:e=>{e.getHeaderGroups=Ge(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r,i)=>{var o,a;const s=(o=r?.map(p=>n.find(g=>g.id===p)).filter(Boolean))!=null?o:[],u=(a=i?.map(p=>n.find(g=>g.id===p)).filter(Boolean))!=null?a:[],c=n.filter(p=>!(r!=null&&r.includes(p.id))&&!(i!=null&&i.includes(p.id)));return ld(t,[...s,...c,...u],e)},qe(e.options,Fn,"getHeaderGroups")),e.getCenterHeaderGroups=Ge(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r,i)=>(n=n.filter(o=>!(r!=null&&r.includes(o.id))&&!(i!=null&&i.includes(o.id))),ld(t,n,e,"center")),qe(e.options,Fn,"getCenterHeaderGroups")),e.getLeftHeaderGroups=Ge(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left],(t,n,r)=>{var i;const o=(i=r?.map(a=>n.find(s=>s.id===a)).filter(Boolean))!=null?i:[];return ld(t,o,e,"left")},qe(e.options,Fn,"getLeftHeaderGroups")),e.getRightHeaderGroups=Ge(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.right],(t,n,r)=>{var i;const o=(i=r?.map(a=>n.find(s=>s.id===a)).filter(Boolean))!=null?i:[];return ld(t,o,e,"right")},qe(e.options,Fn,"getRightHeaderGroups")),e.getFooterGroups=Ge(()=>[e.getHeaderGroups()],t=>[...t].reverse(),qe(e.options,Fn,"getFooterGroups")),e.getLeftFooterGroups=Ge(()=>[e.getLeftHeaderGroups()],t=>[...t].reverse(),qe(e.options,Fn,"getLeftFooterGroups")),e.getCenterFooterGroups=Ge(()=>[e.getCenterHeaderGroups()],t=>[...t].reverse(),qe(e.options,Fn,"getCenterFooterGroups")),e.getRightFooterGroups=Ge(()=>[e.getRightHeaderGroups()],t=>[...t].reverse(),qe(e.options,Fn,"getRightFooterGroups")),e.getFlatHeaders=Ge(()=>[e.getHeaderGroups()],t=>t.map(n=>n.headers).flat(),qe(e.options,Fn,"getFlatHeaders")),e.getLeftFlatHeaders=Ge(()=>[e.getLeftHeaderGroups()],t=>t.map(n=>n.headers).flat(),qe(e.options,Fn,"getLeftFlatHeaders")),e.getCenterFlatHeaders=Ge(()=>[e.getCenterHeaderGroups()],t=>t.map(n=>n.headers).flat(),qe(e.options,Fn,"getCenterFlatHeaders")),e.getRightFlatHeaders=Ge(()=>[e.getRightHeaderGroups()],t=>t.map(n=>n.headers).flat(),qe(e.options,Fn,"getRightFlatHeaders")),e.getCenterLeafHeaders=Ge(()=>[e.getCenterFlatHeaders()],t=>t.filter(n=>{var r;return!((r=n.subHeaders)!=null&&r.length)}),qe(e.options,Fn,"getCenterLeafHeaders")),e.getLeftLeafHeaders=Ge(()=>[e.getLeftFlatHeaders()],t=>t.filter(n=>{var r;return!((r=n.subHeaders)!=null&&r.length)}),qe(e.options,Fn,"getLeftLeafHeaders")),e.getRightLeafHeaders=Ge(()=>[e.getRightFlatHeaders()],t=>t.filter(n=>{var r;return!((r=n.subHeaders)!=null&&r.length)}),qe(e.options,Fn,"getRightLeafHeaders")),e.getLeafHeaders=Ge(()=>[e.getLeftHeaderGroups(),e.getCenterHeaderGroups(),e.getRightHeaderGroups()],(t,n,r)=>{var i,o,a,s,u,c;return[...(i=(o=t[0])==null?void 0:o.headers)!=null?i:[],...(a=(s=n[0])==null?void 0:s.headers)!=null?a:[],...(u=(c=r[0])==null?void 0:c.headers)!=null?u:[]].map(f=>f.getLeafHeaders()).flat()},qe(e.options,Fn,"getLeafHeaders"))}};function ld(e,t,n,r){var i,o;let a=0;const s=function(g,h){h===void 0&&(h=1),a=Math.max(a,h),g.filter(v=>v.getIsVisible()).forEach(v=>{var b;(b=v.columns)!=null&&b.length&&s(v.columns,h+1)},0)};s(e);let u=[];const c=(g,h)=>{const v={depth:h,id:[r,`${h}`].filter(Boolean).join("_"),headers:[]},b=[];g.forEach(y=>{const w=[...b].reverse()[0],S=y.column.depth===v.depth;let E,_=!1;if(S&&y.column.parent?E=y.column.parent:(E=y.column,_=!0),w&&w?.column===E)w.subHeaders.push(y);else{const P=GE(n,E,{id:[r,h,E.id,y?.id].filter(Boolean).join("_"),isPlaceholder:_,placeholderId:_?`${b.filter(R=>R.column===E).length}`:void 0,depth:h,index:b.length});P.subHeaders.push(y),b.push(P)}v.headers.push(y),y.headerGroup=v}),u.push(v),h>0&&c(b,h-1)},f=t.map((g,h)=>GE(n,g,{depth:a,index:h}));c(f,a-1),u.reverse();const p=g=>g.filter(v=>v.column.getIsVisible()).map(v=>{let b=0,y=0,w=[0];v.subHeaders&&v.subHeaders.length?(w=[],p(v.subHeaders).forEach(E=>{let{colSpan:_,rowSpan:P}=E;b+=_,w.push(P)})):b=1;const S=Math.min(...w);return y=y+S,v.colSpan=b,v.rowSpan=y,{colSpan:b,rowSpan:y}});return p((i=(o=u[0])==null?void 0:o.headers)!=null?i:[]),u}const j0=(e,t,n,r,i,o,a)=>{let s={id:t,index:r,original:n,depth:i,parentId:a,_valuesCache:{},_uniqueValuesCache:{},getValue:u=>{if(s._valuesCache.hasOwnProperty(u))return s._valuesCache[u];const c=e.getColumn(u);if(c!=null&&c.accessorFn)return s._valuesCache[u]=c.accessorFn(s.original,r),s._valuesCache[u]},getUniqueValues:u=>{if(s._uniqueValuesCache.hasOwnProperty(u))return s._uniqueValuesCache[u];const c=e.getColumn(u);if(c!=null&&c.accessorFn)return c.columnDef.getUniqueValues?(s._uniqueValuesCache[u]=c.columnDef.getUniqueValues(s.original,r),s._uniqueValuesCache[u]):(s._uniqueValuesCache[u]=[s.getValue(u)],s._uniqueValuesCache[u])},renderValue:u=>{var c;return(c=s.getValue(u))!=null?c:e.options.renderFallbackValue},subRows:[],getLeafRows:()=>$X(s.subRows,u=>u.subRows),getParentRow:()=>s.parentId?e.getRow(s.parentId,!0):void 0,getParentRows:()=>{let u=[],c=s;for(;;){const f=c.getParentRow();if(!f)break;u.push(f),c=f}return u.reverse()},getAllCells:Ge(()=>[e.getAllLeafColumns()],u=>u.map(c=>FX(e,s,c,c.id)),qe(e.options,"debugRows","getAllCells")),_getAllCellsByColumnId:Ge(()=>[s.getAllCells()],u=>u.reduce((c,f)=>(c[f.column.id]=f,c),{}),qe(e.options,"debugRows","getAllCellsByColumnId"))};for(let u=0;u<e._features.length;u++){const c=e._features[u];c==null||c.createRow==null||c.createRow(s,e)}return s},zX={createColumn:(e,t)=>{e._getFacetedRowModel=t.options.getFacetedRowModel&&t.options.getFacetedRowModel(t,e.id),e.getFacetedRowModel=()=>e._getFacetedRowModel?e._getFacetedRowModel():t.getPreFilteredRowModel(),e._getFacetedUniqueValues=t.options.getFacetedUniqueValues&&t.options.getFacetedUniqueValues(t,e.id),e.getFacetedUniqueValues=()=>e._getFacetedUniqueValues?e._getFacetedUniqueValues():new Map,e._getFacetedMinMaxValues=t.options.getFacetedMinMaxValues&&t.options.getFacetedMinMaxValues(t,e.id),e.getFacetedMinMaxValues=()=>{if(e._getFacetedMinMaxValues)return e._getFacetedMinMaxValues()}}},VM=(e,t,n)=>{var r,i;const o=n==null||(r=n.toString())==null?void 0:r.toLowerCase();return!!(!((i=e.getValue(t))==null||(i=i.toString())==null||(i=i.toLowerCase())==null)&&i.includes(o))};VM.autoRemove=e=>di(e);const BM=(e,t,n)=>{var r;return!!(!((r=e.getValue(t))==null||(r=r.toString())==null)&&r.includes(n))};BM.autoRemove=e=>di(e);const zM=(e,t,n)=>{var r;return((r=e.getValue(t))==null||(r=r.toString())==null?void 0:r.toLowerCase())===n?.toLowerCase()};zM.autoRemove=e=>di(e);const WM=(e,t,n)=>{var r;return(r=e.getValue(t))==null?void 0:r.includes(n)};WM.autoRemove=e=>di(e);const HM=(e,t,n)=>!n.some(r=>{var i;return!((i=e.getValue(t))!=null&&i.includes(r))});HM.autoRemove=e=>di(e)||!(e!=null&&e.length);const UM=(e,t,n)=>n.some(r=>{var i;return(i=e.getValue(t))==null?void 0:i.includes(r)});UM.autoRemove=e=>di(e)||!(e!=null&&e.length);const GM=(e,t,n)=>e.getValue(t)===n;GM.autoRemove=e=>di(e);const qM=(e,t,n)=>e.getValue(t)==n;qM.autoRemove=e=>di(e);const L0=(e,t,n)=>{let[r,i]=n;const o=e.getValue(t);return o>=r&&o<=i};L0.resolveFilterValue=e=>{let[t,n]=e,r=typeof t!="number"?parseFloat(t):t,i=typeof n!="number"?parseFloat(n):n,o=t===null||Number.isNaN(r)?-1/0:r,a=n===null||Number.isNaN(i)?1/0:i;if(o>a){const s=o;o=a,a=s}return[o,a]};L0.autoRemove=e=>di(e)||di(e[0])&&di(e[1]);const ro={includesString:VM,includesStringSensitive:BM,equalsString:zM,arrIncludes:WM,arrIncludesAll:HM,arrIncludesSome:UM,equals:GM,weakEquals:qM,inNumberRange:L0};function di(e){return e==null||e===""}const WX={getDefaultColumnDef:()=>({filterFn:"auto"}),getInitialState:e=>({columnFilters:[],...e}),getDefaultOptions:e=>({onColumnFiltersChange:Tr("columnFilters",e),filterFromLeafRows:!1,maxLeafRowFilterDepth:100}),createColumn:(e,t)=>{e.getAutoFilterFn=()=>{const n=t.getCoreRowModel().flatRows[0],r=n?.getValue(e.id);return typeof r=="string"?ro.includesString:typeof r=="number"?ro.inNumberRange:typeof r=="boolean"||r!==null&&typeof r=="object"?ro.equals:Array.isArray(r)?ro.arrIncludes:ro.weakEquals},e.getFilterFn=()=>{var n,r;return kh(e.columnDef.filterFn)?e.columnDef.filterFn:e.columnDef.filterFn==="auto"?e.getAutoFilterFn():(n=(r=t.options.filterFns)==null?void 0:r[e.columnDef.filterFn])!=null?n:ro[e.columnDef.filterFn]},e.getCanFilter=()=>{var n,r,i;return((n=e.columnDef.enableColumnFilter)!=null?n:!0)&&((r=t.options.enableColumnFilters)!=null?r:!0)&&((i=t.options.enableFilters)!=null?i:!0)&&!!e.accessorFn},e.getIsFiltered=()=>e.getFilterIndex()>-1,e.getFilterValue=()=>{var n;return(n=t.getState().columnFilters)==null||(n=n.find(r=>r.id===e.id))==null?void 0:n.value},e.getFilterIndex=()=>{var n,r;return(n=(r=t.getState().columnFilters)==null?void 0:r.findIndex(i=>i.id===e.id))!=null?n:-1},e.setFilterValue=n=>{t.setColumnFilters(r=>{const i=e.getFilterFn(),o=r?.find(f=>f.id===e.id),a=ta(n,o?o.value:void 0);if(qE(i,a,e)){var s;return(s=r?.filter(f=>f.id!==e.id))!=null?s:[]}const u={id:e.id,value:a};if(o){var c;return(c=r?.map(f=>f.id===e.id?u:f))!=null?c:[]}return r!=null&&r.length?[...r,u]:[u]})}},createRow:(e,t)=>{e.columnFilters={},e.columnFiltersMeta={}},createTable:e=>{e.setColumnFilters=t=>{const n=e.getAllLeafColumns(),r=i=>{var o;return(o=ta(t,i))==null?void 0:o.filter(a=>{const s=n.find(u=>u.id===a.id);if(s){const u=s.getFilterFn();if(qE(u,a.value,s))return!1}return!0})};e.options.onColumnFiltersChange==null||e.options.onColumnFiltersChange(r)},e.resetColumnFilters=t=>{var n,r;e.setColumnFilters(t?[]:(n=(r=e.initialState)==null?void 0:r.columnFilters)!=null?n:[])},e.getPreFilteredRowModel=()=>e.getCoreRowModel(),e.getFilteredRowModel=()=>(!e._getFilteredRowModel&&e.options.getFilteredRowModel&&(e._getFilteredRowModel=e.options.getFilteredRowModel(e)),e.options.manualFiltering||!e._getFilteredRowModel?e.getPreFilteredRowModel():e._getFilteredRowModel())}};function qE(e,t,n){return(e&&e.autoRemove?e.autoRemove(t,n):!1)||typeof t>"u"||typeof t=="string"&&!t}const HX=(e,t,n)=>n.reduce((r,i)=>{const o=i.getValue(e);return r+(typeof o=="number"?o:0)},0),UX=(e,t,n)=>{let r;return n.forEach(i=>{const o=i.getValue(e);o!=null&&(r>o||r===void 0&&o>=o)&&(r=o)}),r},GX=(e,t,n)=>{let r;return n.forEach(i=>{const o=i.getValue(e);o!=null&&(r<o||r===void 0&&o>=o)&&(r=o)}),r},qX=(e,t,n)=>{let r,i;return n.forEach(o=>{const a=o.getValue(e);a!=null&&(r===void 0?a>=a&&(r=i=a):(r>a&&(r=a),i<a&&(i=a)))}),[r,i]},KX=(e,t)=>{let n=0,r=0;if(t.forEach(i=>{let o=i.getValue(e);o!=null&&(o=+o)>=o&&(++n,r+=o)}),n)return r/n},YX=(e,t)=>{if(!t.length)return;const n=t.map(o=>o.getValue(e));if(!LX(n))return;if(n.length===1)return n[0];const r=Math.floor(n.length/2),i=n.sort((o,a)=>o-a);return n.length%2!==0?i[r]:(i[r-1]+i[r])/2},XX=(e,t)=>Array.from(new Set(t.map(n=>n.getValue(e))).values()),ZX=(e,t)=>new Set(t.map(n=>n.getValue(e))).size,QX=(e,t)=>t.length,ev={sum:HX,min:UX,max:GX,extent:qX,mean:KX,median:YX,unique:XX,uniqueCount:ZX,count:QX},JX={getDefaultColumnDef:()=>({aggregatedCell:e=>{var t,n;return(t=(n=e.getValue())==null||n.toString==null?void 0:n.toString())!=null?t:null},aggregationFn:"auto"}),getInitialState:e=>({grouping:[],...e}),getDefaultOptions:e=>({onGroupingChange:Tr("grouping",e),groupedColumnMode:"reorder"}),createColumn:(e,t)=>{e.toggleGrouping=()=>{t.setGrouping(n=>n!=null&&n.includes(e.id)?n.filter(r=>r!==e.id):[...n??[],e.id])},e.getCanGroup=()=>{var n,r;return((n=e.columnDef.enableGrouping)!=null?n:!0)&&((r=t.options.enableGrouping)!=null?r:!0)&&(!!e.accessorFn||!!e.columnDef.getGroupingValue)},e.getIsGrouped=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.includes(e.id)},e.getGroupedIndex=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.indexOf(e.id)},e.getToggleGroupingHandler=()=>{const n=e.getCanGroup();return()=>{n&&e.toggleGrouping()}},e.getAutoAggregationFn=()=>{const n=t.getCoreRowModel().flatRows[0],r=n?.getValue(e.id);if(typeof r=="number")return ev.sum;if(Object.prototype.toString.call(r)==="[object Date]")return ev.extent},e.getAggregationFn=()=>{var n,r;if(!e)throw new Error;return kh(e.columnDef.aggregationFn)?e.columnDef.aggregationFn:e.columnDef.aggregationFn==="auto"?e.getAutoAggregationFn():(n=(r=t.options.aggregationFns)==null?void 0:r[e.columnDef.aggregationFn])!=null?n:ev[e.columnDef.aggregationFn]}},createTable:e=>{e.setGrouping=t=>e.options.onGroupingChange==null?void 0:e.options.onGroupingChange(t),e.resetGrouping=t=>{var n,r;e.setGrouping(t?[]:(n=(r=e.initialState)==null?void 0:r.grouping)!=null?n:[])},e.getPreGroupedRowModel=()=>e.getFilteredRowModel(),e.getGroupedRowModel=()=>(!e._getGroupedRowModel&&e.options.getGroupedRowModel&&(e._getGroupedRowModel=e.options.getGroupedRowModel(e)),e.options.manualGrouping||!e._getGroupedRowModel?e.getPreGroupedRowModel():e._getGroupedRowModel())},createRow:(e,t)=>{e.getIsGrouped=()=>!!e.groupingColumnId,e.getGroupingValue=n=>{if(e._groupingValuesCache.hasOwnProperty(n))return e._groupingValuesCache[n];const r=t.getColumn(n);return r!=null&&r.columnDef.getGroupingValue?(e._groupingValuesCache[n]=r.columnDef.getGroupingValue(e.original),e._groupingValuesCache[n]):e.getValue(n)},e._groupingValuesCache={}},createCell:(e,t,n,r)=>{e.getIsGrouped=()=>t.getIsGrouped()&&t.id===n.groupingColumnId,e.getIsPlaceholder=()=>!e.getIsGrouped()&&t.getIsGrouped(),e.getIsAggregated=()=>{var i;return!e.getIsGrouped()&&!e.getIsPlaceholder()&&!!((i=n.subRows)!=null&&i.length)}}};function eZ(e,t,n){if(!(t!=null&&t.length)||!n)return e;const r=e.filter(o=>!t.includes(o.id));return n==="remove"?r:[...t.map(o=>e.find(a=>a.id===o)).filter(Boolean),...r]}const tZ={getInitialState:e=>({columnOrder:[],...e}),getDefaultOptions:e=>({onColumnOrderChange:Tr("columnOrder",e)}),createColumn:(e,t)=>{e.getIndex=Ge(n=>[zu(t,n)],n=>n.findIndex(r=>r.id===e.id),qe(t.options,"debugColumns","getIndex")),e.getIsFirstColumn=n=>{var r;return((r=zu(t,n)[0])==null?void 0:r.id)===e.id},e.getIsLastColumn=n=>{var r;const i=zu(t,n);return((r=i[i.length-1])==null?void 0:r.id)===e.id}},createTable:e=>{e.setColumnOrder=t=>e.options.onColumnOrderChange==null?void 0:e.options.onColumnOrderChange(t),e.resetColumnOrder=t=>{var n;e.setColumnOrder(t?[]:(n=e.initialState.columnOrder)!=null?n:[])},e._getOrderColumnsFn=Ge(()=>[e.getState().columnOrder,e.getState().grouping,e.options.groupedColumnMode],(t,n,r)=>i=>{let o=[];if(!(t!=null&&t.length))o=i;else{const a=[...t],s=[...i];for(;s.length&&a.length;){const u=a.shift(),c=s.findIndex(f=>f.id===u);c>-1&&o.push(s.splice(c,1)[0])}o=[...o,...s]}return eZ(o,n,r)},qe(e.options,"debugTable","_getOrderColumnsFn"))}},tv=()=>({left:[],right:[]}),nZ={getInitialState:e=>({columnPinning:tv(),...e}),getDefaultOptions:e=>({onColumnPinningChange:Tr("columnPinning",e)}),createColumn:(e,t)=>{e.pin=n=>{const r=e.getLeafColumns().map(i=>i.id).filter(Boolean);t.setColumnPinning(i=>{var o,a;if(n==="right"){var s,u;return{left:((s=i?.left)!=null?s:[]).filter(p=>!(r!=null&&r.includes(p))),right:[...((u=i?.right)!=null?u:[]).filter(p=>!(r!=null&&r.includes(p))),...r]}}if(n==="left"){var c,f;return{left:[...((c=i?.left)!=null?c:[]).filter(p=>!(r!=null&&r.includes(p))),...r],right:((f=i?.right)!=null?f:[]).filter(p=>!(r!=null&&r.includes(p)))}}return{left:((o=i?.left)!=null?o:[]).filter(p=>!(r!=null&&r.includes(p))),right:((a=i?.right)!=null?a:[]).filter(p=>!(r!=null&&r.includes(p)))}})},e.getCanPin=()=>e.getLeafColumns().some(r=>{var i,o,a;return((i=r.columnDef.enablePinning)!=null?i:!0)&&((o=(a=t.options.enableColumnPinning)!=null?a:t.options.enablePinning)!=null?o:!0)}),e.getIsPinned=()=>{const n=e.getLeafColumns().map(s=>s.id),{left:r,right:i}=t.getState().columnPinning,o=n.some(s=>r?.includes(s)),a=n.some(s=>i?.includes(s));return o?"left":a?"right":!1},e.getPinnedIndex=()=>{var n,r;const i=e.getIsPinned();return i?(n=(r=t.getState().columnPinning)==null||(r=r[i])==null?void 0:r.indexOf(e.id))!=null?n:-1:0}},createRow:(e,t)=>{e.getCenterVisibleCells=Ge(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left,t.getState().columnPinning.right],(n,r,i)=>{const o=[...r??[],...i??[]];return n.filter(a=>!o.includes(a.column.id))},qe(t.options,"debugRows","getCenterVisibleCells")),e.getLeftVisibleCells=Ge(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left],(n,r)=>(r??[]).map(o=>n.find(a=>a.column.id===o)).filter(Boolean).map(o=>({...o,position:"left"})),qe(t.options,"debugRows","getLeftVisibleCells")),e.getRightVisibleCells=Ge(()=>[e._getAllVisibleCells(),t.getState().columnPinning.right],(n,r)=>(r??[]).map(o=>n.find(a=>a.column.id===o)).filter(Boolean).map(o=>({...o,position:"right"})),qe(t.options,"debugRows","getRightVisibleCells"))},createTable:e=>{e.setColumnPinning=t=>e.options.onColumnPinningChange==null?void 0:e.options.onColumnPinningChange(t),e.resetColumnPinning=t=>{var n,r;return e.setColumnPinning(t?tv():(n=(r=e.initialState)==null?void 0:r.columnPinning)!=null?n:tv())},e.getIsSomeColumnsPinned=t=>{var n;const r=e.getState().columnPinning;if(!t){var i,o;return!!((i=r.left)!=null&&i.length||(o=r.right)!=null&&o.length)}return!!((n=r[t])!=null&&n.length)},e.getLeftLeafColumns=Ge(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left],(t,n)=>(n??[]).map(r=>t.find(i=>i.id===r)).filter(Boolean),qe(e.options,"debugColumns","getLeftLeafColumns")),e.getRightLeafColumns=Ge(()=>[e.getAllLeafColumns(),e.getState().columnPinning.right],(t,n)=>(n??[]).map(r=>t.find(i=>i.id===r)).filter(Boolean),qe(e.options,"debugColumns","getRightLeafColumns")),e.getCenterLeafColumns=Ge(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,r)=>{const i=[...n??[],...r??[]];return t.filter(o=>!i.includes(o.id))},qe(e.options,"debugColumns","getCenterLeafColumns"))}};function rZ(e){return e||(typeof document<"u"?document:null)}const ud={size:150,minSize:20,maxSize:Number.MAX_SAFE_INTEGER},nv=()=>({startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]}),iZ={getDefaultColumnDef:()=>ud,getInitialState:e=>({columnSizing:{},columnSizingInfo:nv(),...e}),getDefaultOptions:e=>({columnResizeMode:"onEnd",columnResizeDirection:"ltr",onColumnSizingChange:Tr("columnSizing",e),onColumnSizingInfoChange:Tr("columnSizingInfo",e)}),createColumn:(e,t)=>{e.getSize=()=>{var n,r,i;const o=t.getState().columnSizing[e.id];return Math.min(Math.max((n=e.columnDef.minSize)!=null?n:ud.minSize,(r=o??e.columnDef.size)!=null?r:ud.size),(i=e.columnDef.maxSize)!=null?i:ud.maxSize)},e.getStart=Ge(n=>[n,zu(t,n),t.getState().columnSizing],(n,r)=>r.slice(0,e.getIndex(n)).reduce((i,o)=>i+o.getSize(),0),qe(t.options,"debugColumns","getStart")),e.getAfter=Ge(n=>[n,zu(t,n),t.getState().columnSizing],(n,r)=>r.slice(e.getIndex(n)+1).reduce((i,o)=>i+o.getSize(),0),qe(t.options,"debugColumns","getAfter")),e.resetSize=()=>{t.setColumnSizing(n=>{let{[e.id]:r,...i}=n;return i})},e.getCanResize=()=>{var n,r;return((n=e.columnDef.enableResizing)!=null?n:!0)&&((r=t.options.enableColumnResizing)!=null?r:!0)},e.getIsResizing=()=>t.getState().columnSizingInfo.isResizingColumn===e.id},createHeader:(e,t)=>{e.getSize=()=>{let n=0;const r=i=>{if(i.subHeaders.length)i.subHeaders.forEach(r);else{var o;n+=(o=i.column.getSize())!=null?o:0}};return r(e),n},e.getStart=()=>{if(e.index>0){const n=e.headerGroup.headers[e.index-1];return n.getStart()+n.getSize()}return 0},e.getResizeHandler=n=>{const r=t.getColumn(e.column.id),i=r?.getCanResize();return o=>{if(!r||!i||(o.persist==null||o.persist(),rv(o)&&o.touches&&o.touches.length>1))return;const a=e.getSize(),s=e?e.getLeafHeaders().map(w=>[w.column.id,w.column.getSize()]):[[r.id,r.getSize()]],u=rv(o)?Math.round(o.touches[0].clientX):o.clientX,c={},f=(w,S)=>{typeof S=="number"&&(t.setColumnSizingInfo(E=>{var _,P;const R=t.options.columnResizeDirection==="rtl"?-1:1,I=(S-((_=E?.startOffset)!=null?_:0))*R,k=Math.max(I/((P=E?.startSize)!=null?P:0),-.999999);return E.columnSizingStart.forEach(B=>{let[L,V]=B;c[L]=Math.round(Math.max(V+V*k,0)*100)/100}),{...E,deltaOffset:I,deltaPercentage:k}}),(t.options.columnResizeMode==="onChange"||w==="end")&&t.setColumnSizing(E=>({...E,...c})))},p=w=>f("move",w),g=w=>{f("end",w),t.setColumnSizingInfo(S=>({...S,isResizingColumn:!1,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]}))},h=rZ(n),v={moveHandler:w=>p(w.clientX),upHandler:w=>{h?.removeEventListener("mousemove",v.moveHandler),h?.removeEventListener("mouseup",v.upHandler),g(w.clientX)}},b={moveHandler:w=>(w.cancelable&&(w.preventDefault(),w.stopPropagation()),p(w.touches[0].clientX),!1),upHandler:w=>{var S;h?.removeEventListener("touchmove",b.moveHandler),h?.removeEventListener("touchend",b.upHandler),w.cancelable&&(w.preventDefault(),w.stopPropagation()),g((S=w.touches[0])==null?void 0:S.clientX)}},y=oZ()?{passive:!1}:!1;rv(o)?(h?.addEventListener("touchmove",b.moveHandler,y),h?.addEventListener("touchend",b.upHandler,y)):(h?.addEventListener("mousemove",v.moveHandler,y),h?.addEventListener("mouseup",v.upHandler,y)),t.setColumnSizingInfo(w=>({...w,startOffset:u,startSize:a,deltaOffset:0,deltaPercentage:0,columnSizingStart:s,isResizingColumn:r.id}))}}},createTable:e=>{e.setColumnSizing=t=>e.options.onColumnSizingChange==null?void 0:e.options.onColumnSizingChange(t),e.setColumnSizingInfo=t=>e.options.onColumnSizingInfoChange==null?void 0:e.options.onColumnSizingInfoChange(t),e.resetColumnSizing=t=>{var n;e.setColumnSizing(t?{}:(n=e.initialState.columnSizing)!=null?n:{})},e.resetHeaderSizeInfo=t=>{var n;e.setColumnSizingInfo(t?nv():(n=e.initialState.columnSizingInfo)!=null?n:nv())},e.getTotalSize=()=>{var t,n;return(t=(n=e.getHeaderGroups()[0])==null?void 0:n.headers.reduce((r,i)=>r+i.getSize(),0))!=null?t:0},e.getLeftTotalSize=()=>{var t,n;return(t=(n=e.getLeftHeaderGroups()[0])==null?void 0:n.headers.reduce((r,i)=>r+i.getSize(),0))!=null?t:0},e.getCenterTotalSize=()=>{var t,n;return(t=(n=e.getCenterHeaderGroups()[0])==null?void 0:n.headers.reduce((r,i)=>r+i.getSize(),0))!=null?t:0},e.getRightTotalSize=()=>{var t,n;return(t=(n=e.getRightHeaderGroups()[0])==null?void 0:n.headers.reduce((r,i)=>r+i.getSize(),0))!=null?t:0}}};let cd=null;function oZ(){if(typeof cd=="boolean")return cd;let e=!1;try{const t={get passive(){return e=!0,!1}},n=()=>{};window.addEventListener("test",n,t),window.removeEventListener("test",n)}catch{e=!1}return cd=e,cd}function rv(e){return e.type==="touchstart"}const aZ={getInitialState:e=>({columnVisibility:{},...e}),getDefaultOptions:e=>({onColumnVisibilityChange:Tr("columnVisibility",e)}),createColumn:(e,t)=>{e.toggleVisibility=n=>{e.getCanHide()&&t.setColumnVisibility(r=>({...r,[e.id]:n??!e.getIsVisible()}))},e.getIsVisible=()=>{var n,r;const i=e.columns;return(n=i.length?i.some(o=>o.getIsVisible()):(r=t.getState().columnVisibility)==null?void 0:r[e.id])!=null?n:!0},e.getCanHide=()=>{var n,r;return((n=e.columnDef.enableHiding)!=null?n:!0)&&((r=t.options.enableHiding)!=null?r:!0)},e.getToggleVisibilityHandler=()=>n=>{e.toggleVisibility==null||e.toggleVisibility(n.target.checked)}},createRow:(e,t)=>{e._getAllVisibleCells=Ge(()=>[e.getAllCells(),t.getState().columnVisibility],n=>n.filter(r=>r.column.getIsVisible()),qe(t.options,"debugRows","_getAllVisibleCells")),e.getVisibleCells=Ge(()=>[e.getLeftVisibleCells(),e.getCenterVisibleCells(),e.getRightVisibleCells()],(n,r,i)=>[...n,...r,...i],qe(t.options,"debugRows","getVisibleCells"))},createTable:e=>{const t=(n,r)=>Ge(()=>[r(),r().filter(i=>i.getIsVisible()).map(i=>i.id).join("_")],i=>i.filter(o=>o.getIsVisible==null?void 0:o.getIsVisible()),qe(e.options,"debugColumns",n));e.getVisibleFlatColumns=t("getVisibleFlatColumns",()=>e.getAllFlatColumns()),e.getVisibleLeafColumns=t("getVisibleLeafColumns",()=>e.getAllLeafColumns()),e.getLeftVisibleLeafColumns=t("getLeftVisibleLeafColumns",()=>e.getLeftLeafColumns()),e.getRightVisibleLeafColumns=t("getRightVisibleLeafColumns",()=>e.getRightLeafColumns()),e.getCenterVisibleLeafColumns=t("getCenterVisibleLeafColumns",()=>e.getCenterLeafColumns()),e.setColumnVisibility=n=>e.options.onColumnVisibilityChange==null?void 0:e.options.onColumnVisibilityChange(n),e.resetColumnVisibility=n=>{var r;e.setColumnVisibility(n?{}:(r=e.initialState.columnVisibility)!=null?r:{})},e.toggleAllColumnsVisible=n=>{var r;n=(r=n)!=null?r:!e.getIsAllColumnsVisible(),e.setColumnVisibility(e.getAllLeafColumns().reduce((i,o)=>({...i,[o.id]:n||!(o.getCanHide!=null&&o.getCanHide())}),{}))},e.getIsAllColumnsVisible=()=>!e.getAllLeafColumns().some(n=>!(n.getIsVisible!=null&&n.getIsVisible())),e.getIsSomeColumnsVisible=()=>e.getAllLeafColumns().some(n=>n.getIsVisible==null?void 0:n.getIsVisible()),e.getToggleAllColumnsVisibilityHandler=()=>n=>{var r;e.toggleAllColumnsVisible((r=n.target)==null?void 0:r.checked)}}};function zu(e,t){return t?t==="center"?e.getCenterVisibleLeafColumns():t==="left"?e.getLeftVisibleLeafColumns():e.getRightVisibleLeafColumns():e.getVisibleLeafColumns()}const sZ={createTable:e=>{e._getGlobalFacetedRowModel=e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,"__global__"),e.getGlobalFacetedRowModel=()=>e.options.manualFiltering||!e._getGlobalFacetedRowModel?e.getPreFilteredRowModel():e._getGlobalFacetedRowModel(),e._getGlobalFacetedUniqueValues=e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,"__global__"),e.getGlobalFacetedUniqueValues=()=>e._getGlobalFacetedUniqueValues?e._getGlobalFacetedUniqueValues():new Map,e._getGlobalFacetedMinMaxValues=e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,"__global__"),e.getGlobalFacetedMinMaxValues=()=>{if(e._getGlobalFacetedMinMaxValues)return e._getGlobalFacetedMinMaxValues()}}},lZ={getInitialState:e=>({globalFilter:void 0,...e}),getDefaultOptions:e=>({onGlobalFilterChange:Tr("globalFilter",e),globalFilterFn:"auto",getColumnCanGlobalFilter:t=>{var n;const r=(n=e.getCoreRowModel().flatRows[0])==null||(n=n._getAllCellsByColumnId()[t.id])==null?void 0:n.getValue();return typeof r=="string"||typeof r=="number"}}),createColumn:(e,t)=>{e.getCanGlobalFilter=()=>{var n,r,i,o;return((n=e.columnDef.enableGlobalFilter)!=null?n:!0)&&((r=t.options.enableGlobalFilter)!=null?r:!0)&&((i=t.options.enableFilters)!=null?i:!0)&&((o=t.options.getColumnCanGlobalFilter==null?void 0:t.options.getColumnCanGlobalFilter(e))!=null?o:!0)&&!!e.accessorFn}},createTable:e=>{e.getGlobalAutoFilterFn=()=>ro.includesString,e.getGlobalFilterFn=()=>{var t,n;const{globalFilterFn:r}=e.options;return kh(r)?r:r==="auto"?e.getGlobalAutoFilterFn():(t=(n=e.options.filterFns)==null?void 0:n[r])!=null?t:ro[r]},e.setGlobalFilter=t=>{e.options.onGlobalFilterChange==null||e.options.onGlobalFilterChange(t)},e.resetGlobalFilter=t=>{e.setGlobalFilter(t?void 0:e.initialState.globalFilter)}}},uZ={getInitialState:e=>({expanded:{},...e}),getDefaultOptions:e=>({onExpandedChange:Tr("expanded",e),paginateExpandedRows:!0}),createTable:e=>{let t=!1,n=!1;e._autoResetExpanded=()=>{var r,i;if(!t){e._queue(()=>{t=!0});return}if((r=(i=e.options.autoResetAll)!=null?i:e.options.autoResetExpanded)!=null?r:!e.options.manualExpanding){if(n)return;n=!0,e._queue(()=>{e.resetExpanded(),n=!1})}},e.setExpanded=r=>e.options.onExpandedChange==null?void 0:e.options.onExpandedChange(r),e.toggleAllRowsExpanded=r=>{r??!e.getIsAllRowsExpanded()?e.setExpanded(!0):e.setExpanded({})},e.resetExpanded=r=>{var i,o;e.setExpanded(r?{}:(i=(o=e.initialState)==null?void 0:o.expanded)!=null?i:{})},e.getCanSomeRowsExpand=()=>e.getPrePaginationRowModel().flatRows.some(r=>r.getCanExpand()),e.getToggleAllRowsExpandedHandler=()=>r=>{r.persist==null||r.persist(),e.toggleAllRowsExpanded()},e.getIsSomeRowsExpanded=()=>{const r=e.getState().expanded;return r===!0||Object.values(r).some(Boolean)},e.getIsAllRowsExpanded=()=>{const r=e.getState().expanded;return typeof r=="boolean"?r===!0:!(!Object.keys(r).length||e.getRowModel().flatRows.some(i=>!i.getIsExpanded()))},e.getExpandedDepth=()=>{let r=0;return(e.getState().expanded===!0?Object.keys(e.getRowModel().rowsById):Object.keys(e.getState().expanded)).forEach(o=>{const a=o.split(".");r=Math.max(r,a.length)}),r},e.getPreExpandedRowModel=()=>e.getSortedRowModel(),e.getExpandedRowModel=()=>(!e._getExpandedRowModel&&e.options.getExpandedRowModel&&(e._getExpandedRowModel=e.options.getExpandedRowModel(e)),e.options.manualExpanding||!e._getExpandedRowModel?e.getPreExpandedRowModel():e._getExpandedRowModel())},createRow:(e,t)=>{e.toggleExpanded=n=>{t.setExpanded(r=>{var i;const o=r===!0?!0:!!(r!=null&&r[e.id]);let a={};if(r===!0?Object.keys(t.getRowModel().rowsById).forEach(s=>{a[s]=!0}):a=r,n=(i=n)!=null?i:!o,!o&&n)return{...a,[e.id]:!0};if(o&&!n){const{[e.id]:s,...u}=a;return u}return r})},e.getIsExpanded=()=>{var n;const r=t.getState().expanded;return!!((n=t.options.getIsRowExpanded==null?void 0:t.options.getIsRowExpanded(e))!=null?n:r===!0||r?.[e.id])},e.getCanExpand=()=>{var n,r,i;return(n=t.options.getRowCanExpand==null?void 0:t.options.getRowCanExpand(e))!=null?n:((r=t.options.enableExpanding)!=null?r:!0)&&!!((i=e.subRows)!=null&&i.length)},e.getIsAllParentsExpanded=()=>{let n=!0,r=e;for(;n&&r.parentId;)r=t.getRow(r.parentId,!0),n=r.getIsExpanded();return n},e.getToggleExpandedHandler=()=>{const n=e.getCanExpand();return()=>{n&&e.toggleExpanded()}}}},sb=0,lb=10,iv=()=>({pageIndex:sb,pageSize:lb}),cZ={getInitialState:e=>({...e,pagination:{...iv(),...e?.pagination}}),getDefaultOptions:e=>({onPaginationChange:Tr("pagination",e)}),createTable:e=>{let t=!1,n=!1;e._autoResetPageIndex=()=>{var r,i;if(!t){e._queue(()=>{t=!0});return}if((r=(i=e.options.autoResetAll)!=null?i:e.options.autoResetPageIndex)!=null?r:!e.options.manualPagination){if(n)return;n=!0,e._queue(()=>{e.resetPageIndex(),n=!1})}},e.setPagination=r=>{const i=o=>ta(r,o);return e.options.onPaginationChange==null?void 0:e.options.onPaginationChange(i)},e.resetPagination=r=>{var i;e.setPagination(r?iv():(i=e.initialState.pagination)!=null?i:iv())},e.setPageIndex=r=>{e.setPagination(i=>{let o=ta(r,i.pageIndex);const a=typeof e.options.pageCount>"u"||e.options.pageCount===-1?Number.MAX_SAFE_INTEGER:e.options.pageCount-1;return o=Math.max(0,Math.min(o,a)),{...i,pageIndex:o}})},e.resetPageIndex=r=>{var i,o;e.setPageIndex(r?sb:(i=(o=e.initialState)==null||(o=o.pagination)==null?void 0:o.pageIndex)!=null?i:sb)},e.resetPageSize=r=>{var i,o;e.setPageSize(r?lb:(i=(o=e.initialState)==null||(o=o.pagination)==null?void 0:o.pageSize)!=null?i:lb)},e.setPageSize=r=>{e.setPagination(i=>{const o=Math.max(1,ta(r,i.pageSize)),a=i.pageSize*i.pageIndex,s=Math.floor(a/o);return{...i,pageIndex:s,pageSize:o}})},e.setPageCount=r=>e.setPagination(i=>{var o;let a=ta(r,(o=e.options.pageCount)!=null?o:-1);return typeof a=="number"&&(a=Math.max(-1,a)),{...i,pageCount:a}}),e.getPageOptions=Ge(()=>[e.getPageCount()],r=>{let i=[];return r&&r>0&&(i=[...new Array(r)].fill(null).map((o,a)=>a)),i},qe(e.options,"debugTable","getPageOptions")),e.getCanPreviousPage=()=>e.getState().pagination.pageIndex>0,e.getCanNextPage=()=>{const{pageIndex:r}=e.getState().pagination,i=e.getPageCount();return i===-1?!0:i===0?!1:r<i-1},e.previousPage=()=>e.setPageIndex(r=>r-1),e.nextPage=()=>e.setPageIndex(r=>r+1),e.firstPage=()=>e.setPageIndex(0),e.lastPage=()=>e.setPageIndex(e.getPageCount()-1),e.getPrePaginationRowModel=()=>e.getExpandedRowModel(),e.getPaginationRowModel=()=>(!e._getPaginationRowModel&&e.options.getPaginationRowModel&&(e._getPaginationRowModel=e.options.getPaginationRowModel(e)),e.options.manualPagination||!e._getPaginationRowModel?e.getPrePaginationRowModel():e._getPaginationRowModel()),e.getPageCount=()=>{var r;return(r=e.options.pageCount)!=null?r:Math.ceil(e.getRowCount()/e.getState().pagination.pageSize)},e.getRowCount=()=>{var r;return(r=e.options.rowCount)!=null?r:e.getPrePaginationRowModel().rows.length}}},ov=()=>({top:[],bottom:[]}),fZ={getInitialState:e=>({rowPinning:ov(),...e}),getDefaultOptions:e=>({onRowPinningChange:Tr("rowPinning",e)}),createRow:(e,t)=>{e.pin=(n,r,i)=>{const o=r?e.getLeafRows().map(u=>{let{id:c}=u;return c}):[],a=i?e.getParentRows().map(u=>{let{id:c}=u;return c}):[],s=new Set([...a,e.id,...o]);t.setRowPinning(u=>{var c,f;if(n==="bottom"){var p,g;return{top:((p=u?.top)!=null?p:[]).filter(b=>!(s!=null&&s.has(b))),bottom:[...((g=u?.bottom)!=null?g:[]).filter(b=>!(s!=null&&s.has(b))),...Array.from(s)]}}if(n==="top"){var h,v;return{top:[...((h=u?.top)!=null?h:[]).filter(b=>!(s!=null&&s.has(b))),...Array.from(s)],bottom:((v=u?.bottom)!=null?v:[]).filter(b=>!(s!=null&&s.has(b)))}}return{top:((c=u?.top)!=null?c:[]).filter(b=>!(s!=null&&s.has(b))),bottom:((f=u?.bottom)!=null?f:[]).filter(b=>!(s!=null&&s.has(b)))}})},e.getCanPin=()=>{var n;const{enableRowPinning:r,enablePinning:i}=t.options;return typeof r=="function"?r(e):(n=r??i)!=null?n:!0},e.getIsPinned=()=>{const n=[e.id],{top:r,bottom:i}=t.getState().rowPinning,o=n.some(s=>r?.includes(s)),a=n.some(s=>i?.includes(s));return o?"top":a?"bottom":!1},e.getPinnedIndex=()=>{var n,r;const i=e.getIsPinned();if(!i)return-1;const o=(n=i==="top"?t.getTopRows():t.getBottomRows())==null?void 0:n.map(a=>{let{id:s}=a;return s});return(r=o?.indexOf(e.id))!=null?r:-1}},createTable:e=>{e.setRowPinning=t=>e.options.onRowPinningChange==null?void 0:e.options.onRowPinningChange(t),e.resetRowPinning=t=>{var n,r;return e.setRowPinning(t?ov():(n=(r=e.initialState)==null?void 0:r.rowPinning)!=null?n:ov())},e.getIsSomeRowsPinned=t=>{var n;const r=e.getState().rowPinning;if(!t){var i,o;return!!((i=r.top)!=null&&i.length||(o=r.bottom)!=null&&o.length)}return!!((n=r[t])!=null&&n.length)},e._getPinnedRows=(t,n,r)=>{var i;return((i=e.options.keepPinnedRows)==null||i?(n??[]).map(a=>{const s=e.getRow(a,!0);return s.getIsAllParentsExpanded()?s:null}):(n??[]).map(a=>t.find(s=>s.id===a))).filter(Boolean).map(a=>({...a,position:r}))},e.getTopRows=Ge(()=>[e.getRowModel().rows,e.getState().rowPinning.top],(t,n)=>e._getPinnedRows(t,n,"top"),qe(e.options,"debugRows","getTopRows")),e.getBottomRows=Ge(()=>[e.getRowModel().rows,e.getState().rowPinning.bottom],(t,n)=>e._getPinnedRows(t,n,"bottom"),qe(e.options,"debugRows","getBottomRows")),e.getCenterRows=Ge(()=>[e.getRowModel().rows,e.getState().rowPinning.top,e.getState().rowPinning.bottom],(t,n,r)=>{const i=new Set([...n??[],...r??[]]);return t.filter(o=>!i.has(o.id))},qe(e.options,"debugRows","getCenterRows"))}},dZ={getInitialState:e=>({rowSelection:{},...e}),getDefaultOptions:e=>({onRowSelectionChange:Tr("rowSelection",e),enableRowSelection:!0,enableMultiRowSelection:!0,enableSubRowSelection:!0}),createTable:e=>{e.setRowSelection=t=>e.options.onRowSelectionChange==null?void 0:e.options.onRowSelectionChange(t),e.resetRowSelection=t=>{var n;return e.setRowSelection(t?{}:(n=e.initialState.rowSelection)!=null?n:{})},e.toggleAllRowsSelected=t=>{e.setRowSelection(n=>{t=typeof t<"u"?t:!e.getIsAllRowsSelected();const r={...n},i=e.getPreGroupedRowModel().flatRows;return t?i.forEach(o=>{o.getCanSelect()&&(r[o.id]=!0)}):i.forEach(o=>{delete r[o.id]}),r})},e.toggleAllPageRowsSelected=t=>e.setRowSelection(n=>{const r=typeof t<"u"?t:!e.getIsAllPageRowsSelected(),i={...n};return e.getRowModel().rows.forEach(o=>{ub(i,o.id,r,!0,e)}),i}),e.getPreSelectedRowModel=()=>e.getCoreRowModel(),e.getSelectedRowModel=Ge(()=>[e.getState().rowSelection,e.getCoreRowModel()],(t,n)=>Object.keys(t).length?av(e,n):{rows:[],flatRows:[],rowsById:{}},qe(e.options,"debugTable","getSelectedRowModel")),e.getFilteredSelectedRowModel=Ge(()=>[e.getState().rowSelection,e.getFilteredRowModel()],(t,n)=>Object.keys(t).length?av(e,n):{rows:[],flatRows:[],rowsById:{}},qe(e.options,"debugTable","getFilteredSelectedRowModel")),e.getGroupedSelectedRowModel=Ge(()=>[e.getState().rowSelection,e.getSortedRowModel()],(t,n)=>Object.keys(t).length?av(e,n):{rows:[],flatRows:[],rowsById:{}},qe(e.options,"debugTable","getGroupedSelectedRowModel")),e.getIsAllRowsSelected=()=>{const t=e.getFilteredRowModel().flatRows,{rowSelection:n}=e.getState();let r=!!(t.length&&Object.keys(n).length);return r&&t.some(i=>i.getCanSelect()&&!n[i.id])&&(r=!1),r},e.getIsAllPageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows.filter(i=>i.getCanSelect()),{rowSelection:n}=e.getState();let r=!!t.length;return r&&t.some(i=>!n[i.id])&&(r=!1),r},e.getIsSomeRowsSelected=()=>{var t;const n=Object.keys((t=e.getState().rowSelection)!=null?t:{}).length;return n>0&&n<e.getFilteredRowModel().flatRows.length},e.getIsSomePageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows;return e.getIsAllPageRowsSelected()?!1:t.filter(n=>n.getCanSelect()).some(n=>n.getIsSelected()||n.getIsSomeSelected())},e.getToggleAllRowsSelectedHandler=()=>t=>{e.toggleAllRowsSelected(t.target.checked)},e.getToggleAllPageRowsSelectedHandler=()=>t=>{e.toggleAllPageRowsSelected(t.target.checked)}},createRow:(e,t)=>{e.toggleSelected=(n,r)=>{const i=e.getIsSelected();t.setRowSelection(o=>{var a;if(n=typeof n<"u"?n:!i,e.getCanSelect()&&i===n)return o;const s={...o};return ub(s,e.id,n,(a=r?.selectChildren)!=null?a:!0,t),s})},e.getIsSelected=()=>{const{rowSelection:n}=t.getState();return $0(e,n)},e.getIsSomeSelected=()=>{const{rowSelection:n}=t.getState();return cb(e,n)==="some"},e.getIsAllSubRowsSelected=()=>{const{rowSelection:n}=t.getState();return cb(e,n)==="all"},e.getCanSelect=()=>{var n;return typeof t.options.enableRowSelection=="function"?t.options.enableRowSelection(e):(n=t.options.enableRowSelection)!=null?n:!0},e.getCanSelectSubRows=()=>{var n;return typeof t.options.enableSubRowSelection=="function"?t.options.enableSubRowSelection(e):(n=t.options.enableSubRowSelection)!=null?n:!0},e.getCanMultiSelect=()=>{var n;return typeof t.options.enableMultiRowSelection=="function"?t.options.enableMultiRowSelection(e):(n=t.options.enableMultiRowSelection)!=null?n:!0},e.getToggleSelectedHandler=()=>{const n=e.getCanSelect();return r=>{var i;n&&e.toggleSelected((i=r.target)==null?void 0:i.checked)}}}},ub=(e,t,n,r,i)=>{var o;const a=i.getRow(t,!0);n?(a.getCanMultiSelect()||Object.keys(e).forEach(s=>delete e[s]),a.getCanSelect()&&(e[t]=!0)):delete e[t],r&&(o=a.subRows)!=null&&o.length&&a.getCanSelectSubRows()&&a.subRows.forEach(s=>ub(e,s.id,n,r,i))};function av(e,t){const n=e.getState().rowSelection,r=[],i={},o=function(a,s){return a.map(u=>{var c;const f=$0(u,n);if(f&&(r.push(u),i[u.id]=u),(c=u.subRows)!=null&&c.length&&(u={...u,subRows:o(u.subRows)}),f)return u}).filter(Boolean)};return{rows:o(t.rows),flatRows:r,rowsById:i}}function $0(e,t){var n;return(n=t[e.id])!=null?n:!1}function cb(e,t,n){var r;if(!((r=e.subRows)!=null&&r.length))return!1;let i=!0,o=!1;return e.subRows.forEach(a=>{if(!(o&&!i)&&(a.getCanSelect()&&($0(a,t)?o=!0:i=!1),a.subRows&&a.subRows.length)){const s=cb(a,t);s==="all"?o=!0:(s==="some"&&(o=!0),i=!1)}}),i?"all":o?"some":!1}const fb=/([0-9]+)/gm,pZ=(e,t,n)=>KM(fa(e.getValue(n)).toLowerCase(),fa(t.getValue(n)).toLowerCase()),hZ=(e,t,n)=>KM(fa(e.getValue(n)),fa(t.getValue(n))),gZ=(e,t,n)=>F0(fa(e.getValue(n)).toLowerCase(),fa(t.getValue(n)).toLowerCase()),mZ=(e,t,n)=>F0(fa(e.getValue(n)),fa(t.getValue(n))),vZ=(e,t,n)=>{const r=e.getValue(n),i=t.getValue(n);return r>i?1:r<i?-1:0},yZ=(e,t,n)=>F0(e.getValue(n),t.getValue(n));function F0(e,t){return e===t?0:e>t?1:-1}function fa(e){return typeof e=="number"?isNaN(e)||e===1/0||e===-1/0?"":String(e):typeof e=="string"?e:""}function KM(e,t){const n=e.split(fb).filter(Boolean),r=t.split(fb).filter(Boolean);for(;n.length&&r.length;){const i=n.shift(),o=r.shift(),a=parseInt(i,10),s=parseInt(o,10),u=[a,s].sort();if(isNaN(u[0])){if(i>o)return 1;if(o>i)return-1;continue}if(isNaN(u[1]))return isNaN(a)?-1:1;if(a>s)return 1;if(s>a)return-1}return n.length-r.length}const mu={alphanumeric:pZ,alphanumericCaseSensitive:hZ,text:gZ,textCaseSensitive:mZ,datetime:vZ,basic:yZ},bZ={getInitialState:e=>({sorting:[],...e}),getDefaultColumnDef:()=>({sortingFn:"auto",sortUndefined:1}),getDefaultOptions:e=>({onSortingChange:Tr("sorting",e),isMultiSortEvent:t=>t.shiftKey}),createColumn:(e,t)=>{e.getAutoSortingFn=()=>{const n=t.getFilteredRowModel().flatRows.slice(10);let r=!1;for(const i of n){const o=i?.getValue(e.id);if(Object.prototype.toString.call(o)==="[object Date]")return mu.datetime;if(typeof o=="string"&&(r=!0,o.split(fb).length>1))return mu.alphanumeric}return r?mu.text:mu.basic},e.getAutoSortDir=()=>{const n=t.getFilteredRowModel().flatRows[0];return typeof n?.getValue(e.id)=="string"?"asc":"desc"},e.getSortingFn=()=>{var n,r;if(!e)throw new Error;return kh(e.columnDef.sortingFn)?e.columnDef.sortingFn:e.columnDef.sortingFn==="auto"?e.getAutoSortingFn():(n=(r=t.options.sortingFns)==null?void 0:r[e.columnDef.sortingFn])!=null?n:mu[e.columnDef.sortingFn]},e.toggleSorting=(n,r)=>{const i=e.getNextSortingOrder(),o=typeof n<"u"&&n!==null;t.setSorting(a=>{const s=a?.find(h=>h.id===e.id),u=a?.findIndex(h=>h.id===e.id);let c=[],f,p=o?n:i==="desc";if(a!=null&&a.length&&e.getCanMultiSort()&&r?s?f="toggle":f="add":a!=null&&a.length&&u!==a.length-1?f="replace":s?f="toggle":f="replace",f==="toggle"&&(o||i||(f="remove")),f==="add"){var g;c=[...a,{id:e.id,desc:p}],c.splice(0,c.length-((g=t.options.maxMultiSortColCount)!=null?g:Number.MAX_SAFE_INTEGER))}else f==="toggle"?c=a.map(h=>h.id===e.id?{...h,desc:p}:h):f==="remove"?c=a.filter(h=>h.id!==e.id):c=[{id:e.id,desc:p}];return c})},e.getFirstSortDir=()=>{var n,r;return((n=(r=e.columnDef.sortDescFirst)!=null?r:t.options.sortDescFirst)!=null?n:e.getAutoSortDir()==="desc")?"desc":"asc"},e.getNextSortingOrder=n=>{var r,i;const o=e.getFirstSortDir(),a=e.getIsSorted();return a?a!==o&&((r=t.options.enableSortingRemoval)==null||r)&&(!(n&&(i=t.options.enableMultiRemove)!=null)||i)?!1:a==="desc"?"asc":"desc":o},e.getCanSort=()=>{var n,r;return((n=e.columnDef.enableSorting)!=null?n:!0)&&((r=t.options.enableSorting)!=null?r:!0)&&!!e.accessorFn},e.getCanMultiSort=()=>{var n,r;return(n=(r=e.columnDef.enableMultiSort)!=null?r:t.options.enableMultiSort)!=null?n:!!e.accessorFn},e.getIsSorted=()=>{var n;const r=(n=t.getState().sorting)==null?void 0:n.find(i=>i.id===e.id);return r?r.desc?"desc":"asc":!1},e.getSortIndex=()=>{var n,r;return(n=(r=t.getState().sorting)==null?void 0:r.findIndex(i=>i.id===e.id))!=null?n:-1},e.clearSorting=()=>{t.setSorting(n=>n!=null&&n.length?n.filter(r=>r.id!==e.id):[])},e.getToggleSortingHandler=()=>{const n=e.getCanSort();return r=>{n&&(r.persist==null||r.persist(),e.toggleSorting==null||e.toggleSorting(void 0,e.getCanMultiSort()?t.options.isMultiSortEvent==null?void 0:t.options.isMultiSortEvent(r):!1))}}},createTable:e=>{e.setSorting=t=>e.options.onSortingChange==null?void 0:e.options.onSortingChange(t),e.resetSorting=t=>{var n,r;e.setSorting(t?[]:(n=(r=e.initialState)==null?void 0:r.sorting)!=null?n:[])},e.getPreSortedRowModel=()=>e.getGroupedRowModel(),e.getSortedRowModel=()=>(!e._getSortedRowModel&&e.options.getSortedRowModel&&(e._getSortedRowModel=e.options.getSortedRowModel(e)),e.options.manualSorting||!e._getSortedRowModel?e.getPreSortedRowModel():e._getSortedRowModel())}},xZ=[BX,aZ,tZ,nZ,zX,WX,sZ,lZ,bZ,JX,uZ,cZ,fZ,dZ,iZ];function wZ(e){var t,n;process.env.NODE_ENV!=="production"&&(e.debugAll||e.debugTable)&&console.info("Creating Table Instance...");const r=[...xZ,...(t=e._features)!=null?t:[]];let i={_features:r};const o=i._features.reduce((g,h)=>Object.assign(g,h.getDefaultOptions==null?void 0:h.getDefaultOptions(i)),{}),a=g=>i.options.mergeOptions?i.options.mergeOptions(o,g):{...o,...g};let u={...{},...(n=e.initialState)!=null?n:{}};i._features.forEach(g=>{var h;u=(h=g.getInitialState==null?void 0:g.getInitialState(u))!=null?h:u});const c=[];let f=!1;const p={_features:r,options:{...o,...e},initialState:u,_queue:g=>{c.push(g),f||(f=!0,Promise.resolve().then(()=>{for(;c.length;)c.shift()();f=!1}).catch(h=>setTimeout(()=>{throw h})))},reset:()=>{i.setState(i.initialState)},setOptions:g=>{const h=ta(g,i.options);i.options=a(h)},getState:()=>i.options.state,setState:g=>{i.options.onStateChange==null||i.options.onStateChange(g)},_getRowId:(g,h,v)=>{var b;return(b=i.options.getRowId==null?void 0:i.options.getRowId(g,h,v))!=null?b:`${v?[v.id,h].join("."):h}`},getCoreRowModel:()=>(i._getCoreRowModel||(i._getCoreRowModel=i.options.getCoreRowModel(i)),i._getCoreRowModel()),getRowModel:()=>i.getPaginationRowModel(),getRow:(g,h)=>{let v=(h?i.getPrePaginationRowModel():i.getRowModel()).rowsById[g];if(!v&&(v=i.getCoreRowModel().rowsById[g],!v))throw process.env.NODE_ENV!=="production"?new Error(`getRow could not find row with ID: ${g}`):new Error;return v},_getDefaultColumnDef:Ge(()=>[i.options.defaultColumn],g=>{var h;return g=(h=g)!=null?h:{},{header:v=>{const b=v.header.column.columnDef;return b.accessorKey?b.accessorKey:b.accessorFn?b.id:null},cell:v=>{var b,y;return(b=(y=v.renderValue())==null||y.toString==null?void 0:y.toString())!=null?b:null},...i._features.reduce((v,b)=>Object.assign(v,b.getDefaultColumnDef==null?void 0:b.getDefaultColumnDef()),{}),...g}},qe(e,"debugColumns","_getDefaultColumnDef")),_getColumnDefs:()=>i.options.columns,getAllColumns:Ge(()=>[i._getColumnDefs()],g=>{const h=function(v,b,y){return y===void 0&&(y=0),v.map(w=>{const S=VX(i,w,y,b),E=w;return S.columns=E.columns?h(E.columns,S,y+1):[],S})};return h(g)},qe(e,"debugColumns","getAllColumns")),getAllFlatColumns:Ge(()=>[i.getAllColumns()],g=>g.flatMap(h=>h.getFlatColumns()),qe(e,"debugColumns","getAllFlatColumns")),_getAllFlatColumnsById:Ge(()=>[i.getAllFlatColumns()],g=>g.reduce((h,v)=>(h[v.id]=v,h),{}),qe(e,"debugColumns","getAllFlatColumnsById")),getAllLeafColumns:Ge(()=>[i.getAllColumns(),i._getOrderColumnsFn()],(g,h)=>{let v=g.flatMap(b=>b.getLeafColumns());return h(v)},qe(e,"debugColumns","getAllLeafColumns")),getColumn:g=>{const h=i._getAllFlatColumnsById()[g];return process.env.NODE_ENV!=="production"&&!h&&console.error(`[Table] Column with id '${g}' does not exist.`),h}};Object.assign(i,p);for(let g=0;g<i._features.length;g++){const h=i._features[g];h==null||h.createTable==null||h.createTable(i)}return i}function SZ(){return e=>Ge(()=>[e.options.data],t=>{const n={rows:[],flatRows:[],rowsById:{}},r=function(i,o,a){o===void 0&&(o=0);const s=[];for(let c=0;c<i.length;c++){const f=j0(e,e._getRowId(i[c],c,a),i[c],c,o,void 0,a?.id);if(n.flatRows.push(f),n.rowsById[f.id]=f,s.push(f),e.options.getSubRows){var u;f.originalSubRows=e.options.getSubRows(i[c],c),(u=f.originalSubRows)!=null&&u.length&&(f.subRows=r(f.originalSubRows,o+1,f))}}return s};return n.rows=r(t),n},qe(e.options,"debugTable","getRowModel",()=>e._autoResetPageIndex()))}function CZ(e){const t=[],n=r=>{var i;t.push(r),(i=r.subRows)!=null&&i.length&&r.getIsExpanded()&&r.subRows.forEach(n)};return e.rows.forEach(n),{rows:t,flatRows:e.flatRows,rowsById:e.rowsById}}function EZ(e,t,n){return n.options.filterFromLeafRows?_Z(e,t,n):OZ(e,t,n)}function _Z(e,t,n){var r;const i=[],o={},a=(r=n.options.maxLeafRowFilterDepth)!=null?r:100,s=function(u,c){c===void 0&&(c=0);const f=[];for(let g=0;g<u.length;g++){var p;let h=u[g];const v=j0(n,h.id,h.original,h.index,h.depth,void 0,h.parentId);if(v.columnFilters=h.columnFilters,(p=h.subRows)!=null&&p.length&&c<a){if(v.subRows=s(h.subRows,c+1),h=v,t(h)&&!v.subRows.length){f.push(h),o[h.id]=h,i.push(h);continue}if(t(h)||v.subRows.length){f.push(h),o[h.id]=h,i.push(h);continue}}else h=v,t(h)&&(f.push(h),o[h.id]=h,i.push(h))}return f};return{rows:s(e),flatRows:i,rowsById:o}}function OZ(e,t,n){var r;const i=[],o={},a=(r=n.options.maxLeafRowFilterDepth)!=null?r:100,s=function(u,c){c===void 0&&(c=0);const f=[];for(let g=0;g<u.length;g++){let h=u[g];if(t(h)){var p;if((p=h.subRows)!=null&&p.length&&c<a){const b=j0(n,h.id,h.original,h.index,h.depth,void 0,h.parentId);b.subRows=s(h.subRows,c+1),h=b}f.push(h),i.push(h),o[h.id]=h}}return f};return{rows:s(e),flatRows:i,rowsById:o}}function PZ(){return e=>Ge(()=>[e.getPreFilteredRowModel(),e.getState().columnFilters,e.getState().globalFilter],(t,n,r)=>{if(!t.rows.length||!(n!=null&&n.length)&&!r){for(let g=0;g<t.flatRows.length;g++)t.flatRows[g].columnFilters={},t.flatRows[g].columnFiltersMeta={};return t}const i=[],o=[];(n??[]).forEach(g=>{var h;const v=e.getColumn(g.id);if(!v)return;const b=v.getFilterFn();if(!b){process.env.NODE_ENV!=="production"&&console.warn(`Could not find a valid 'column.filterFn' for column with the ID: ${v.id}.`);return}i.push({id:g.id,filterFn:b,resolvedValue:(h=b.resolveFilterValue==null?void 0:b.resolveFilterValue(g.value))!=null?h:g.value})});const a=(n??[]).map(g=>g.id),s=e.getGlobalFilterFn(),u=e.getAllLeafColumns().filter(g=>g.getCanGlobalFilter());r&&s&&u.length&&(a.push("__global__"),u.forEach(g=>{var h;o.push({id:g.id,filterFn:s,resolvedValue:(h=s.resolveFilterValue==null?void 0:s.resolveFilterValue(r))!=null?h:r})}));let c,f;for(let g=0;g<t.flatRows.length;g++){const h=t.flatRows[g];if(h.columnFilters={},i.length)for(let v=0;v<i.length;v++){c=i[v];const b=c.id;h.columnFilters[b]=c.filterFn(h,b,c.resolvedValue,y=>{h.columnFiltersMeta[b]=y})}if(o.length){for(let v=0;v<o.length;v++){f=o[v];const b=f.id;if(f.filterFn(h,b,f.resolvedValue,y=>{h.columnFiltersMeta[b]=y})){h.columnFilters.__global__=!0;break}}h.columnFilters.__global__!==!0&&(h.columnFilters.__global__=!1)}}const p=g=>{for(let h=0;h<a.length;h++)if(g.columnFilters[a[h]]===!1)return!1;return!0};return EZ(t.rows,p,e)},qe(e.options,"debugTable","getFilteredRowModel",()=>e._autoResetPageIndex()))}function AZ(e){return t=>Ge(()=>[t.getState().pagination,t.getPrePaginationRowModel(),t.options.paginateExpandedRows?void 0:t.getState().expanded],(n,r)=>{if(!r.rows.length)return r;const{pageSize:i,pageIndex:o}=n;let{rows:a,flatRows:s,rowsById:u}=r;const c=i*o,f=c+i;a=a.slice(c,f);let p;t.options.paginateExpandedRows?p={rows:a,flatRows:s,rowsById:u}:p=CZ({rows:a,flatRows:s,rowsById:u}),p.flatRows=[];const g=h=>{p.flatRows.push(h),h.subRows.length&&h.subRows.forEach(g)};return p.rows.forEach(g),p},qe(t.options,"debugTable","getPaginationRowModel"))}function RZ(){return e=>Ge(()=>[e.getState().sorting,e.getPreSortedRowModel()],(t,n)=>{if(!n.rows.length||!(t!=null&&t.length))return n;const r=e.getState().sorting,i=[],o=r.filter(u=>{var c;return(c=e.getColumn(u.id))==null?void 0:c.getCanSort()}),a={};o.forEach(u=>{const c=e.getColumn(u.id);c&&(a[u.id]={sortUndefined:c.columnDef.sortUndefined,invertSorting:c.columnDef.invertSorting,sortingFn:c.getSortingFn()})});const s=u=>{const c=u.map(f=>({...f}));return c.sort((f,p)=>{for(let h=0;h<o.length;h+=1){var g;const v=o[h],b=a[v.id],y=b.sortUndefined,w=(g=v?.desc)!=null?g:!1;let S=0;if(y){const E=f.getValue(v.id),_=p.getValue(v.id),P=E===void 0,R=_===void 0;if(P||R){if(y==="first")return P?-1:1;if(y==="last")return P?1:-1;S=P&&R?0:P?y:-y}}if(S===0&&(S=b.sortingFn(f,p,v.id)),S!==0)return w&&(S*=-1),b.invertSorting&&(S*=-1),S}return f.index-p.index}),c.forEach(f=>{var p;i.push(f),(p=f.subRows)!=null&&p.length&&(f.subRows=s(f.subRows))}),c};return{rows:s(n.rows),flatRows:i,rowsById:n.rowsById}},qe(e.options,"debugTable","getSortedRowModel",()=>e._autoResetPageIndex()))}function KE(e,t){return e?IZ(e)?x.createElement(e,t):e:null}function IZ(e){return TZ(e)||typeof e=="function"||kZ(e)}function TZ(e){return typeof e=="function"&&(()=>{const t=Object.getPrototypeOf(e);return t.prototype&&t.prototype.isReactComponent})()}function kZ(e){return typeof e=="object"&&typeof e.$$typeof=="symbol"&&["react.memo","react.forward_ref"].includes(e.$$typeof.description)}function NZ(e){const t={state:{},onStateChange:()=>{},renderFallbackValue:null,...e},[n]=x.useState(()=>({current:wZ(t)})),[r,i]=x.useState(()=>n.current.initialState);return n.current.setOptions(o=>({...o,...e,state:{...r,...e.state},onStateChange:a=>{i(a),e.onStateChange==null||e.onStateChange(a)}})),n.current}function MZ({columns:e,data:t,sorting:n,columnFilters:r,pagination:i,onSortingChange:o,onColumnFiltersChange:a,onPaginationChange:s}){const u={};n&&(u.sorting=n),r&&(u.columnFilters=r),i&&(u.pagination=i);const c=NZ({data:t,columns:e,state:u,onSortingChange:o,onColumnFiltersChange:a,onPaginationChange:s,getCoreRowModel:SZ(),getPaginationRowModel:AZ(),getSortedRowModel:RZ(),getFilteredRowModel:PZ()});return O.jsx("div",{className:"w-full overflow-hidden",children:O.jsxs(_0,{children:[O.jsx(O0,{children:c.getHeaderGroups().map(f=>O.jsx(Bu,{children:f.headers.map(p=>O.jsx(A0,{children:p.isPlaceholder?null:KE(p.column.columnDef.header,p.getContext())},p.id))},f.id))}),O.jsx(P0,{children:c.getRowModel().rows.length?c.getRowModel().rows.map(f=>O.jsx(Bu,{"data-state":f.getIsSelected()&&"selected",children:f.getVisibleCells().map(p=>O.jsx(ip,{children:KE(p.column.columnDef.cell,p.getContext())},p.id))},f.id)):O.jsx(Bu,{children:O.jsx(ip,{colSpan:e.length,className:"h-24 text-center",children:"No results."})})})]})})}const DZ=({children:e,text:t,place:n="top",arrow:r=!0,classes:i,color:o="dark",tooltipItemsLimit:a=1/0})=>{const{isOpened:s,togglePopup:u}=D0(),c=$.useMemo(()=>({arrow:o==="dark"?"fill-primary-inverse-bg":"fill-primary-bg",content:o==="dark"?"bg-primary-inverse-bg text-primary-inverse-text":"bg-primary-bg text-primary-text"}),[o]),f=$.useMemo(()=>Array.isArray(t)?(t.length-a>0?t.slice(0,a):t).map((h,v)=>O.jsx("p",{className:i?.tooltipTextItem,children:h},v)):t,[i?.tooltipTextItem,t,a]);return O.jsxs(LM,{open:s,onOpenChange:u,children:[O.jsx($M,{asChild:!0,className:i?.trigger,children:e}),O.jsxs(M0,{side:n,className:c.content,children:[O.jsx("div",{className:ae(i?.tooltip),children:f}),r&&O.jsx(FM,{className:c.arrow})]})]})},YM=({date:e=[],isValid:t,disabled:n=!1,label:r,description:i,classes:o,ref:a,...s})=>{const u={...t===!0&&!n&&{"aria-valid":!0},...t===!1&&!n&&{"aria-invalid":!0},disabled:n};return O.jsx(vh,{className:o?.fieldset,children:O.jsx(hc,{className:o?.fieldgroup,children:O.jsxs(gc,{className:o?.field,children:[r&&O.jsx(Rl,{...u,children:r}),e.length>0?O.jsxs(a0,{"data-slot":!0,children:[O.jsx(l0,{ref:a,...s,...u,disabled:n}),e.map(c=>O.jsx(s0,{align:c.position,children:c.component},c.id))]}):O.jsx(o0,{ref:a,...s,...u,disabled:n}),i&&O.jsx(mc,{...u,children:i})]})})})},jZ=({...e})=>{const{isOpened:t,togglePopup:n}=D0();return O.jsx(YM,{...e,type:t?"text":"password",date:[{id:"0",position:"inline-end",component:O.jsx(ji,{type:t?"eye-off":"eye",onClick:n,className:"cursor-pointer"})}]})};function LZ({classNames:e,id:t,value:n,defaultValue:r,label:i,options:o=[],...a}){return O.jsx(E0,{...a,defaultValue:r,className:ae("w-fit",e?.classNameGroup),children:o.length?o.map(s=>O.jsxs("div",{className:ae("flex items-center gap-3",e?.classNameContainerItem),children:[O.jsx(rp,{value:s.value,id:s.id,className:e?.classNameGroupItem}),s.label&&O.jsx(Ku,{htmlFor:s.id,className:e?.classNameLabel,children:s.label})]},s.id)):O.jsxs("div",{className:ae("flex items-center gap-3",e?.classNameContainerItem),children:[O.jsx(rp,{value:n,id:t,className:e?.classNameGroupItem}),i&&O.jsx(Ku,{htmlFor:t,className:e?.classNameLabel,children:i})]})})}const Ru=e=>typeof e=="object",XM=e=>Ru(e)?e.value:e,$Z=e=>e.every(t=>typeof t=="string")||e.every(t=>typeof t=="object")?e:e.map(t=>XM(t)),sv=(e,t)=>e===null||t===null||typeof e=="string"||typeof t=="string"?e===t:e.id===t.id,ZM=({list:e,label:t,multiple:n,disabled:r=!1,isValid:i,description:o,onChange:a,...s})=>{const[u,c]=$.useState([]),[f,p]=$.useState(null),[g,h]=$.useState(""),v=e,b=r?"opacity-50":"",y={...i===!0&&!r&&{"aria-valid":!0},...i===!1&&!r&&{"aria-invalid":!0},disabled:r},w=L=>{if(n){const V=Array.isArray(L)?L:L?[L]:[],D=V.length>u.length;c(V),a?.($Z(V)),D&&h("")}else{const V=Array.isArray(L)?L[0]??null:L;sv(f,V)?(p(null),a?.(null)):(p(V),a?.(V)),h("")}},S=L=>{h(L.currentTarget.value)},E=()=>{r||(p(null),a?.(null))},_=n?u:f,P=g.trim().toLowerCase(),R=v.filter(L=>XM(L).toLowerCase().includes(P)),I=(L,V)=>O.jsx(Sk,{showRemove:V.withRemove,onClick:V.onClick,className:`${vx({variant:L.variant,kind:L.kind})}
|
|
168
|
+
${b} ${V.className}`,children:O.jsx(Dy,{variant:L.variant,classNames:{className:"px-2 py-0"},children:L.value})},String(L.id)),k=L=>O.jsxs(O.Fragment,{children:[L.map(V=>Ru(V)?I(V,{withRemove:!r,className:"pl-2.5"}):O.jsx("span",{className:b,children:V},V)),O.jsx(tb,{...s,...y,placeholder:L.length>0?"":s.placeholder,value:g,onChange:S})]}),B=L=>O.jsxs(O.Fragment,{children:[L&&(Ru(L)?I(L,{withRemove:!1,className:"ml-1",onClick:E}):O.jsx(My,{className:b,onClick:E,children:L})),O.jsx(tb,{...s,placeholder:L?"":s.placeholder,...y,value:g,onChange:S,className:"flex-1 pl-1"})]});return O.jsx(vh,{children:O.jsx(hc,{children:O.jsxs(vk,{children:[O.jsx(Rl,{...y,children:t}),O.jsxs(mk,{items:v,multiple:n,autoHighlight:n,value:_,onValueChange:r?void 0:w,children:[n?O.jsxs(eb,{disabled:r,className:"pr-8",children:[O.jsx(Jy,{children:k}),O.jsx(ep,{className:"-ml-4.5",disabled:r})]}):O.jsxs(eb,{disabled:r,className:"pr-8",children:[O.jsx(Jy,{children:B}),O.jsx(ep,{className:"-ml-4.5",disabled:r})]}),O.jsxs(yk,{children:[O.jsx(wk,{children:"No items found."}),O.jsx(bk,{children:R.map((L,V)=>{const D=n?u.some(W=>sv(W,L)):sv(f,L);return O.jsx(xk,{disabled:r,value:L,className:`${D?"bg-tertiary-bg":""} ${typeof L=="string"?"py-1":"px-2 py-2"}`,children:Ru(L)?O.jsx(Dy,{dotPosition:"left",variant:L.variant,kind:L.kind,classNames:{className:"px-4 py-1.5"},children:L.value}):O.jsx(My,{className:"px-4 py-1.5",children:L})},Ru(L)?String(L.id):`${L}-${V}`)})})]})]}),O.jsx(mc,{...y,children:o})]})})})};ZM.displayName="SelectSearch";function YE(e,[t,n]){return Math.min(n,Math.max(t,e))}var FZ=[" ","Enter","ArrowUp","ArrowDown"],VZ=[" ","Enter"],as="Select",[Nh,Mh,BZ]=vN(as),[Il]=gi(as,[BZ,Rh]),Dh=Rh(),[zZ,va]=Il(as),[WZ,HZ]=Il(as),QM=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:i,onOpenChange:o,value:a,defaultValue:s,onValueChange:u,dir:c,name:f,autoComplete:p,disabled:g,required:h,form:v}=e,b=Dh(t),[y,w]=x.useState(null),[S,E]=x.useState(null),[_,P]=x.useState(!1),R=Eh(c),[I,k]=go({prop:r,defaultProp:i??!1,onChange:o,caller:as}),[B,L]=go({prop:a,defaultProp:s,onChange:u,caller:as}),V=x.useRef(null),D=y?v||!!y.closest("form"):!0,[W,J]=x.useState(new Set),re=Array.from(W).map(U=>U.props.value).join(";");return O.jsx(wM,{...b,children:O.jsxs(zZ,{required:h,scope:t,trigger:y,onTriggerChange:w,valueNode:S,onValueNodeChange:E,valueNodeHasChildren:_,onValueNodeHasChildrenChange:P,contentId:fo(),value:B,onValueChange:L,open:I,onOpenChange:k,dir:R,triggerPointerDownPosRef:V,disabled:g,children:[O.jsx(Nh.Provider,{scope:t,children:O.jsx(WZ,{scope:e.__scopeSelect,onNativeOptionAdd:x.useCallback(U=>{J(ee=>new Set(ee).add(U))},[]),onNativeOptionRemove:x.useCallback(U=>{J(ee=>{const Z=new Set(ee);return Z.delete(U),Z})},[]),children:n})}),D?O.jsxs(CD,{"aria-hidden":!0,required:h,tabIndex:-1,name:f,autoComplete:p,value:B,onChange:U=>L(U.target.value),disabled:g,form:v,children:[B===void 0?O.jsx("option",{value:""}):null,Array.from(W)]},re):null]})})};QM.displayName=as;var JM="SelectTrigger",eD=x.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...i}=e,o=Dh(n),a=va(JM,n),s=a.disabled||r,u=bt(t,a.onTriggerChange),c=Mh(n),f=x.useRef("touch"),[p,g,h]=_D(b=>{const y=c().filter(E=>!E.disabled),w=y.find(E=>E.value===a.value),S=OD(y,b,w);S!==void 0&&a.onValueChange(S.value)}),v=b=>{s||(a.onOpenChange(!0),h()),b&&(a.triggerPointerDownPosRef.current={x:Math.round(b.pageX),y:Math.round(b.pageY)})};return O.jsx(SM,{asChild:!0,...o,children:O.jsx(Qe.button,{type:"button",role:"combobox","aria-controls":a.contentId,"aria-expanded":a.open,"aria-required":a.required,"aria-autocomplete":"none",dir:a.dir,"data-state":a.open?"open":"closed",disabled:s,"data-disabled":s?"":void 0,"data-placeholder":ED(a.value)?"":void 0,...i,ref:u,onClick:Ke(i.onClick,b=>{b.currentTarget.focus(),f.current!=="mouse"&&v(b)}),onPointerDown:Ke(i.onPointerDown,b=>{f.current=b.pointerType;const y=b.target;y.hasPointerCapture(b.pointerId)&&y.releasePointerCapture(b.pointerId),b.button===0&&b.ctrlKey===!1&&b.pointerType==="mouse"&&(v(b),b.preventDefault())}),onKeyDown:Ke(i.onKeyDown,b=>{const y=p.current!=="";!(b.ctrlKey||b.altKey||b.metaKey)&&b.key.length===1&&g(b.key),!(y&&b.key===" ")&&FZ.includes(b.key)&&(v(),b.preventDefault())})})})});eD.displayName=JM;var tD="SelectValue",nD=x.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:i,children:o,placeholder:a="",...s}=e,u=va(tD,n),{onValueNodeHasChildrenChange:c}=u,f=o!==void 0,p=bt(t,u.onValueNodeChange);return Wn(()=>{c(f)},[c,f]),O.jsx(Qe.span,{...s,ref:p,style:{pointerEvents:"none"},children:ED(u.value)?O.jsx(O.Fragment,{children:a}):o})});nD.displayName=tD;var UZ="SelectIcon",rD=x.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...i}=e;return O.jsx(Qe.span,{"aria-hidden":!0,...i,ref:t,children:r||"▼"})});rD.displayName=UZ;var GZ="SelectPortal",iD=e=>O.jsx(wh,{asChild:!0,...e});iD.displayName=GZ;var ss="SelectContent",oD=x.forwardRef((e,t)=>{const n=va(ss,e.__scopeSelect),[r,i]=x.useState();if(Wn(()=>{i(new DocumentFragment)},[]),!n.open){const o=r;return o?Wi.createPortal(O.jsx(aD,{scope:e.__scopeSelect,children:O.jsx(Nh.Slot,{scope:e.__scopeSelect,children:O.jsx("div",{children:e.children})})}),o):null}return O.jsx(sD,{...e,ref:t})});oD.displayName=ss;var ci=10,[aD,ya]=Il(ss),qZ="SelectContentImpl",KZ=Hu("SelectContent.RemoveScroll"),sD=x.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:i,onEscapeKeyDown:o,onPointerDownOutside:a,side:s,sideOffset:u,align:c,alignOffset:f,arrowPadding:p,collisionBoundary:g,collisionPadding:h,sticky:v,hideWhenDetached:b,avoidCollisions:y,...w}=e,S=va(ss,n),[E,_]=x.useState(null),[P,R]=x.useState(null),I=bt(t,me=>_(me)),[k,B]=x.useState(null),[L,V]=x.useState(null),D=Mh(n),[W,J]=x.useState(!1),re=x.useRef(!1);x.useEffect(()=>{if(E)return Dk(E)},[E]),Ok();const U=x.useCallback(me=>{const[Se,...q]=D().map(j=>j.ref.current),[te]=q.slice(-1),Y=document.activeElement;for(const j of me)if(j===Y||(j?.scrollIntoView({block:"nearest"}),j===Se&&P&&(P.scrollTop=0),j===te&&P&&(P.scrollTop=P.scrollHeight),j?.focus(),document.activeElement!==Y))return},[D,P]),ee=x.useCallback(()=>U([k,E]),[U,k,E]);x.useEffect(()=>{W&&ee()},[W,ee]);const{onOpenChange:Z,triggerPointerDownPosRef:ue}=S;x.useEffect(()=>{if(E){let me={x:0,y:0};const Se=te=>{me={x:Math.abs(Math.round(te.pageX)-(ue.current?.x??0)),y:Math.abs(Math.round(te.pageY)-(ue.current?.y??0))}},q=te=>{me.x<=10&&me.y<=10?te.preventDefault():E.contains(te.target)||Z(!1),document.removeEventListener("pointermove",Se),ue.current=null};return ue.current!==null&&(document.addEventListener("pointermove",Se),document.addEventListener("pointerup",q,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",Se),document.removeEventListener("pointerup",q,{capture:!0})}}},[E,Z,ue]),x.useEffect(()=>{const me=()=>Z(!1);return window.addEventListener("blur",me),window.addEventListener("resize",me),()=>{window.removeEventListener("blur",me),window.removeEventListener("resize",me)}},[Z]);const[X,Oe]=_D(me=>{const Se=D().filter(Y=>!Y.disabled),q=Se.find(Y=>Y.ref.current===document.activeElement),te=OD(Se,me,q);te&&setTimeout(()=>te.ref.current.focus())}),Ee=x.useCallback((me,Se,q)=>{const te=!re.current&&!q;(S.value!==void 0&&S.value===Se||te)&&(B(me),te&&(re.current=!0))},[S.value]),Me=x.useCallback(()=>E?.focus(),[E]),ye=x.useCallback((me,Se,q)=>{const te=!re.current&&!q;(S.value!==void 0&&S.value===Se||te)&&V(me)},[S.value]),be=r==="popper"?db:lD,$e=be===db?{side:s,sideOffset:u,align:c,alignOffset:f,arrowPadding:p,collisionBoundary:g,collisionPadding:h,sticky:v,hideWhenDetached:b,avoidCollisions:y}:{};return O.jsx(aD,{scope:n,content:E,viewport:P,onViewportChange:R,itemRefCallback:Ee,selectedItem:k,onItemLeave:Me,itemTextRefCallback:ye,focusSelectedItem:ee,selectedItemText:L,position:r,isPositioned:W,searchRef:X,children:O.jsx(c0,{as:KZ,allowPinchZoom:!0,children:O.jsx(u0,{asChild:!0,trapped:S.open,onMountAutoFocus:me=>{me.preventDefault()},onUnmountAutoFocus:Ke(i,me=>{S.trigger?.focus({preventScroll:!0}),me.preventDefault()}),children:O.jsx(xh,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:o,onPointerDownOutside:a,onFocusOutside:me=>me.preventDefault(),onDismiss:()=>S.onOpenChange(!1),children:O.jsx(be,{role:"listbox",id:S.contentId,"data-state":S.open?"open":"closed",dir:S.dir,onContextMenu:me=>me.preventDefault(),...w,...$e,onPlaced:()=>J(!0),ref:I,style:{display:"flex",flexDirection:"column",outline:"none",...w.style},onKeyDown:Ke(w.onKeyDown,me=>{const Se=me.ctrlKey||me.altKey||me.metaKey;if(me.key==="Tab"&&me.preventDefault(),!Se&&me.key.length===1&&Oe(me.key),["ArrowUp","ArrowDown","Home","End"].includes(me.key)){let te=D().filter(Y=>!Y.disabled).map(Y=>Y.ref.current);if(["ArrowUp","End"].includes(me.key)&&(te=te.slice().reverse()),["ArrowUp","ArrowDown"].includes(me.key)){const Y=me.target,j=te.indexOf(Y);te=te.slice(j+1)}setTimeout(()=>U(te)),me.preventDefault()}})})})})})})});sD.displayName=qZ;var YZ="SelectItemAlignedPosition",lD=x.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...i}=e,o=va(ss,n),a=ya(ss,n),[s,u]=x.useState(null),[c,f]=x.useState(null),p=bt(t,I=>f(I)),g=Mh(n),h=x.useRef(!1),v=x.useRef(!0),{viewport:b,selectedItem:y,selectedItemText:w,focusSelectedItem:S}=a,E=x.useCallback(()=>{if(o.trigger&&o.valueNode&&s&&c&&b&&y&&w){const I=o.trigger.getBoundingClientRect(),k=c.getBoundingClientRect(),B=o.valueNode.getBoundingClientRect(),L=w.getBoundingClientRect();if(o.dir!=="rtl"){const Y=L.left-k.left,j=B.left-Y,ie=I.left-j,Q=I.width+ie,Ae=Math.max(Q,k.width),G=window.innerWidth-ci,fe=YE(j,[ci,Math.max(ci,G-Ae)]);s.style.minWidth=Q+"px",s.style.left=fe+"px"}else{const Y=k.right-L.right,j=window.innerWidth-B.right-Y,ie=window.innerWidth-I.right-j,Q=I.width+ie,Ae=Math.max(Q,k.width),G=window.innerWidth-ci,fe=YE(j,[ci,Math.max(ci,G-Ae)]);s.style.minWidth=Q+"px",s.style.right=fe+"px"}const V=g(),D=window.innerHeight-ci*2,W=b.scrollHeight,J=window.getComputedStyle(c),re=parseInt(J.borderTopWidth,10),U=parseInt(J.paddingTop,10),ee=parseInt(J.borderBottomWidth,10),Z=parseInt(J.paddingBottom,10),ue=re+U+W+Z+ee,X=Math.min(y.offsetHeight*5,ue),Oe=window.getComputedStyle(b),Ee=parseInt(Oe.paddingTop,10),Me=parseInt(Oe.paddingBottom,10),ye=I.top+I.height/2-ci,be=D-ye,$e=y.offsetHeight/2,me=y.offsetTop+$e,Se=re+U+me,q=ue-Se;if(Se<=ye){const Y=V.length>0&&y===V[V.length-1].ref.current;s.style.bottom="0px";const j=c.clientHeight-b.offsetTop-b.offsetHeight,ie=Math.max(be,$e+(Y?Me:0)+j+ee),Q=Se+ie;s.style.height=Q+"px"}else{const Y=V.length>0&&y===V[0].ref.current;s.style.top="0px";const ie=Math.max(ye,re+b.offsetTop+(Y?Ee:0)+$e)+q;s.style.height=ie+"px",b.scrollTop=Se-ye+b.offsetTop}s.style.margin=`${ci}px 0`,s.style.minHeight=X+"px",s.style.maxHeight=D+"px",r?.(),requestAnimationFrame(()=>h.current=!0)}},[g,o.trigger,o.valueNode,s,c,b,y,w,o.dir,r]);Wn(()=>E(),[E]);const[_,P]=x.useState();Wn(()=>{c&&P(window.getComputedStyle(c).zIndex)},[c]);const R=x.useCallback(I=>{I&&v.current===!0&&(E(),S?.(),v.current=!1)},[E,S]);return O.jsx(ZZ,{scope:n,contentWrapper:s,shouldExpandOnScrollRef:h,onScrollButtonChange:R,children:O.jsx("div",{ref:u,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:_},children:O.jsx(Qe.div,{...i,ref:p,style:{boxSizing:"border-box",maxHeight:"100%",...i.style}})})})});lD.displayName=YZ;var XZ="SelectPopperPosition",db=x.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:i=ci,...o}=e,a=Dh(n);return O.jsx(CM,{...a,...o,ref:t,align:r,collisionPadding:i,style:{boxSizing:"border-box",...o.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)"}})});db.displayName=XZ;var[ZZ,V0]=Il(ss,{}),pb="SelectViewport",uD=x.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:r,...i}=e,o=ya(pb,n),a=V0(pb,n),s=bt(t,o.onViewportChange),u=x.useRef(0);return O.jsxs(O.Fragment,{children:[O.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:r}),O.jsx(Nh.Slot,{scope:n,children:O.jsx(Qe.div,{"data-radix-select-viewport":"",role:"presentation",...i,ref:s,style:{position:"relative",flex:1,overflow:"hidden auto",...i.style},onScroll:Ke(i.onScroll,c=>{const f=c.currentTarget,{contentWrapper:p,shouldExpandOnScrollRef:g}=a;if(g?.current&&p){const h=Math.abs(u.current-f.scrollTop);if(h>0){const v=window.innerHeight-ci*2,b=parseFloat(p.style.minHeight),y=parseFloat(p.style.height),w=Math.max(b,y);if(w<v){const S=w+h,E=Math.min(v,S),_=S-E;p.style.height=E+"px",p.style.bottom==="0px"&&(f.scrollTop=_>0?_:0,p.style.justifyContent="flex-end")}}}u.current=f.scrollTop})})})]})});uD.displayName=pb;var cD="SelectGroup",[QZ,JZ]=Il(cD),fD=x.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,i=fo();return O.jsx(QZ,{scope:n,id:i,children:O.jsx(Qe.div,{role:"group","aria-labelledby":i,...r,ref:t})})});fD.displayName=cD;var dD="SelectLabel",pD=x.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,i=JZ(dD,n);return O.jsx(Qe.div,{id:i.id,...r,ref:t})});pD.displayName=dD;var op="SelectItem",[eQ,hD]=Il(op),gD=x.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:i=!1,textValue:o,...a}=e,s=va(op,n),u=ya(op,n),c=s.value===r,[f,p]=x.useState(o??""),[g,h]=x.useState(!1),v=bt(t,S=>u.itemRefCallback?.(S,r,i)),b=fo(),y=x.useRef("touch"),w=()=>{i||(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 O.jsx(eQ,{scope:n,value:r,disabled:i,textId:b,isSelected:c,onItemTextChange:x.useCallback(S=>{p(E=>E||(S?.textContent??"").trim())},[]),children:O.jsx(Nh.ItemSlot,{scope:n,value:r,disabled:i,textValue:f,children:O.jsx(Qe.div,{role:"option","aria-labelledby":b,"data-highlighted":g?"":void 0,"aria-selected":c&&g,"data-state":c?"checked":"unchecked","aria-disabled":i||void 0,"data-disabled":i?"":void 0,tabIndex:i?void 0:-1,...a,ref:v,onFocus:Ke(a.onFocus,()=>h(!0)),onBlur:Ke(a.onBlur,()=>h(!1)),onClick:Ke(a.onClick,()=>{y.current!=="mouse"&&w()}),onPointerUp:Ke(a.onPointerUp,()=>{y.current==="mouse"&&w()}),onPointerDown:Ke(a.onPointerDown,S=>{y.current=S.pointerType}),onPointerMove:Ke(a.onPointerMove,S=>{y.current=S.pointerType,i?u.onItemLeave?.():y.current==="mouse"&&S.currentTarget.focus({preventScroll:!0})}),onPointerLeave:Ke(a.onPointerLeave,S=>{S.currentTarget===document.activeElement&&u.onItemLeave?.()}),onKeyDown:Ke(a.onKeyDown,S=>{u.searchRef?.current!==""&&S.key===" "||(VZ.includes(S.key)&&w(),S.key===" "&&S.preventDefault())})})})})});gD.displayName=op;var Iu="SelectItemText",mD=x.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:i,...o}=e,a=va(Iu,n),s=ya(Iu,n),u=hD(Iu,n),c=HZ(Iu,n),[f,p]=x.useState(null),g=bt(t,w=>p(w),u.onItemTextChange,w=>s.itemTextRefCallback?.(w,u.value,u.disabled)),h=f?.textContent,v=x.useMemo(()=>O.jsx("option",{value:u.value,disabled:u.disabled,children:h},u.value),[u.disabled,u.value,h]),{onNativeOptionAdd:b,onNativeOptionRemove:y}=c;return Wn(()=>(b(v),()=>y(v)),[b,y,v]),O.jsxs(O.Fragment,{children:[O.jsx(Qe.span,{id:u.textId,...o,ref:g}),u.isSelected&&a.valueNode&&!a.valueNodeHasChildren?Wi.createPortal(o.children,a.valueNode):null]})});mD.displayName=Iu;var vD="SelectItemIndicator",yD=x.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return hD(vD,n).isSelected?O.jsx(Qe.span,{"aria-hidden":!0,...r,ref:t}):null});yD.displayName=vD;var hb="SelectScrollUpButton",bD=x.forwardRef((e,t)=>{const n=ya(hb,e.__scopeSelect),r=V0(hb,e.__scopeSelect),[i,o]=x.useState(!1),a=bt(t,r.onScrollButtonChange);return Wn(()=>{if(n.viewport&&n.isPositioned){let s=function(){const c=u.scrollTop>0;o(c)};const u=n.viewport;return s(),u.addEventListener("scroll",s),()=>u.removeEventListener("scroll",s)}},[n.viewport,n.isPositioned]),i?O.jsx(wD,{...e,ref:a,onAutoScroll:()=>{const{viewport:s,selectedItem:u}=n;s&&u&&(s.scrollTop=s.scrollTop-u.offsetHeight)}}):null});bD.displayName=hb;var gb="SelectScrollDownButton",xD=x.forwardRef((e,t)=>{const n=ya(gb,e.__scopeSelect),r=V0(gb,e.__scopeSelect),[i,o]=x.useState(!1),a=bt(t,r.onScrollButtonChange);return Wn(()=>{if(n.viewport&&n.isPositioned){let s=function(){const c=u.scrollHeight-u.clientHeight,f=Math.ceil(u.scrollTop)<c;o(f)};const u=n.viewport;return s(),u.addEventListener("scroll",s),()=>u.removeEventListener("scroll",s)}},[n.viewport,n.isPositioned]),i?O.jsx(wD,{...e,ref:a,onAutoScroll:()=>{const{viewport:s,selectedItem:u}=n;s&&u&&(s.scrollTop=s.scrollTop+u.offsetHeight)}}):null});xD.displayName=gb;var wD=x.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...i}=e,o=ya("SelectScrollButton",n),a=x.useRef(null),s=Mh(n),u=x.useCallback(()=>{a.current!==null&&(window.clearInterval(a.current),a.current=null)},[]);return x.useEffect(()=>()=>u(),[u]),Wn(()=>{s().find(f=>f.ref.current===document.activeElement)?.ref.current?.scrollIntoView({block:"nearest"})},[s]),O.jsx(Qe.div,{"aria-hidden":!0,...i,ref:t,style:{flexShrink:0,...i.style},onPointerDown:Ke(i.onPointerDown,()=>{a.current===null&&(a.current=window.setInterval(r,50))}),onPointerMove:Ke(i.onPointerMove,()=>{o.onItemLeave?.(),a.current===null&&(a.current=window.setInterval(r,50))}),onPointerLeave:Ke(i.onPointerLeave,()=>{u()})})}),tQ="SelectSeparator",SD=x.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return O.jsx(Qe.div,{"aria-hidden":!0,...r,ref:t})});SD.displayName=tQ;var mb="SelectArrow",nQ=x.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,i=Dh(n),o=va(mb,n),a=ya(mb,n);return o.open&&a.position==="popper"?O.jsx(EM,{...i,...r,ref:t}):null});nQ.displayName=mb;var rQ="SelectBubbleInput",CD=x.forwardRef(({__scopeSelect:e,value:t,...n},r)=>{const i=x.useRef(null),o=bt(r,i),a=eh(t);return x.useEffect(()=>{const s=i.current;if(!s)return;const u=window.HTMLSelectElement.prototype,f=Object.getOwnPropertyDescriptor(u,"value").set;if(a!==t&&f){const p=new Event("change",{bubbles:!0});f.call(s,t),s.dispatchEvent(p)}},[a,t]),O.jsx(Qe.select,{...n,style:{..._M,...n.style},ref:o,defaultValue:t})});CD.displayName=rQ;function ED(e){return e===""||e===void 0}function _D(e){const t=ca(e),n=x.useRef(""),r=x.useRef(0),i=x.useCallback(a=>{const s=n.current+a;t(s),(function u(c){n.current=c,window.clearTimeout(r.current),c!==""&&(r.current=window.setTimeout(()=>u(""),1e3))})(s)},[t]),o=x.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return x.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,i,o]}function OD(e,t,n){const i=t.length>1&&Array.from(t).every(c=>c===t[0])?t[0]:t,o=n?e.indexOf(n):-1;let a=iQ(e,Math.max(o,0));i.length===1&&(a=a.filter(c=>c!==n));const u=a.find(c=>c.textValue.toLowerCase().startsWith(i.toLowerCase()));return u!==n?u:void 0}function iQ(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var oQ=QM,aQ=eD,sQ=nD,lQ=rD,uQ=iD,cQ=oD,fQ=uD,dQ=fD,pQ=pD,hQ=gD,gQ=mD,mQ=yD,vQ=bD,yQ=xD,bQ=SD;const xQ="flex flex-col gap-1",wQ=`border-inp-default-border bg-primary-bg text-primary-text
|
|
169
|
+
hover:border-inp-hover-border focus-visible:border-inp-focus-border
|
|
170
|
+
data-placeholder:text-placeholder-text aria-invalid:border-error-text
|
|
171
|
+
aria-valid:border-success-text disabled:border-inp-disabled-border
|
|
172
|
+
disabled:bg-disabled-bg disabled:text-disabled-text
|
|
173
|
+
[&[data-disabled]_svg]:text-disabled-text relative flex w-full items-center
|
|
174
|
+
justify-between gap-2 rounded-xl border px-3 py-2.5 text-sm whitespace-nowrap
|
|
175
|
+
transition-colors outline-none select-none focus-visible:ring-0
|
|
176
|
+
disabled:pointer-events-none data-[size=default]:h-10 data-[size=sm]:h-8
|
|
177
|
+
*:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex
|
|
178
|
+
*:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-1.5
|
|
179
|
+
[&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,SQ="text-primary-text pointer-events-none size-4",CQ=`border-inp-focus-border bg-primary-bg text-primary-text
|
|
180
|
+
data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2
|
|
181
|
+
data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2
|
|
182
|
+
data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95
|
|
183
|
+
data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95 relative
|
|
184
|
+
z-50 max-h-63 w-(--radix-select-trigger-width)
|
|
185
|
+
min-w-(--radix-select-trigger-width)
|
|
186
|
+
origin-(--radix-select-content-transform-origin) overflow-x-hidden
|
|
187
|
+
overflow-y-auto rounded-xl border shadow-[0px_4px_12px_0px_rgba(0,0,0,0.1)]
|
|
188
|
+
duration-100 data-[align-trigger=true]:animate-none`,EQ=`data-[position=popper]:h-(--radix-select-trigger-height)
|
|
189
|
+
data-[position=popper]:w-full
|
|
190
|
+
data-[position=popper]:min-w-(--radix-select-trigger-width)`,_Q="text-secondary-text px-4 py-2 text-xs",OQ=`text-primary-text data-highlighted:bg-primary-hover-bg
|
|
191
|
+
data-[state=checked]:bg-primary-hover-bg data-disabled:text-disabled-text relative
|
|
192
|
+
flex w-full cursor-pointer items-center gap-2 px-4 py-2 pr-9 text-sm
|
|
193
|
+
outline-none select-none data-disabled:pointer-events-none
|
|
194
|
+
[&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,PQ=`pointer-events-none absolute right-3 flex size-4
|
|
195
|
+
items-center justify-center`,AQ="bg-delicate-border pointer-events-none my-1 h-px",PD=`text-secondary-text bg-primary-bg z-10 flex
|
|
196
|
+
cursor-default items-center justify-center py-1
|
|
197
|
+
[&_svg:not([class*='size-'])]:size-4`;function RQ({...e}){return O.jsx(oQ,{"data-slot":"select",...e})}function XE({className:e,...t}){return O.jsx(dQ,{"data-slot":"select-group",className:ae(xQ,e),...t})}function IQ({...e}){return O.jsx(sQ,{"data-slot":"select-value",...e})}function TQ({className:e,size:t="default",children:n,...r}){return O.jsxs(aQ,{"data-slot":"select-trigger","data-size":t,className:ae(wQ,e),...r,children:[n,O.jsx(lQ,{asChild:!0,children:O.jsx(ji,{className:SQ,type:"chevron"})})]})}function kQ({className:e,children:t,position:n="popper",align:r="center",sideOffset:i=10,...o}){return O.jsx(uQ,{children:O.jsxs(cQ,{"data-slot":"select-content","data-align-trigger":n==="item-aligned",className:ae(CQ,n==="popper"&&"",e),position:n,align:r,sideOffset:i,...o,children:[O.jsx(DQ,{}),O.jsx(fQ,{"data-position":n,className:ae(EQ,n==="popper"&&""),children:t}),O.jsx(jQ,{})]})})}function NQ({className:e,...t}){return O.jsx(pQ,{"data-slot":"select-label",className:ae(_Q,e),...t})}function ZE({className:e,children:t,...n}){return O.jsxs(hQ,{"data-slot":"select-item",className:ae(OQ,e),...n,children:[O.jsx("span",{className:PQ,children:O.jsx(mQ,{})}),O.jsx(gQ,{children:t})]})}function MQ({className:e,...t}){return O.jsx(bQ,{"data-slot":"select-separator",className:ae(AQ,e),...t})}function DQ({className:e,...t}){return O.jsx(vQ,{"data-slot":"select-scroll-up-button",className:ae(PD,e),...t})}function jQ({className:e,...t}){return O.jsx(yQ,{"data-slot":"select-scroll-down-button",className:ae(PD,e),...t})}const LQ=({groups:e=[],placeholder:t="Выберите значение",value:n,defaultValue:r,onChange:i,showSeparators:o=!0,classNames:a,...s})=>{const[u,c]=$.useState(r),f=typeof n=="string",p=f?n:u,g=e.some(v=>v.items.length>0),h=v=>{f||c(v),i?.(v)};return O.jsxs(RQ,{value:p,onValueChange:h,...s,children:[O.jsx(TQ,{className:ae("w-full",a?.trigger),children:O.jsx(IQ,{placeholder:t})}),O.jsx(kQ,{className:a?.content,children:g?e.map((v,b)=>O.jsxs($.Fragment,{children:[O.jsxs(XE,{className:a?.group,children:[v.label?O.jsx(NQ,{className:a?.label,children:v.label}):null,v.items.map(y=>O.jsx(ZE,{value:y,className:a?.item,children:y},y))]}),o&&b<e.length-1?O.jsx(MQ,{className:a?.separator}):null]},v.label)):O.jsx(XE,{className:a?.group,children:O.jsx(ZE,{value:"",disabled:!0,className:a?.item,children:"Нет доступных элементов"})})})]})},$Q=({label:e,description:t,isValid:n,...r})=>{const{disabled:i}=r,o={"aria-invalid":!!n},a=[n===!0&&"text-success-text",n===!1&&"text-error-text",i&&"text-disabled-text"].filter(Boolean).join(" ");return O.jsx(vh,{children:O.jsx(hc,{children:O.jsxs(gc,{children:[e&&O.jsx(Rl,{children:e}),O.jsx(yh,{...r,...o}),t&&O.jsx(mc,{className:ae(i?"text-disabled-text":"",a),children:t})]})})})};var Tu={exports:{}};var FQ=Tu.exports,QE;function VQ(){return QE||(QE=1,(function(e,t){(function(){var n,r="4.17.23",i=200,o="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",a="Expected a function",s="Invalid `variable` option passed into `_.template`",u="__lodash_hash_undefined__",c=500,f="__lodash_placeholder__",p=1,g=2,h=4,v=1,b=2,y=1,w=2,S=4,E=8,_=16,P=32,R=64,I=128,k=256,B=512,L=30,V="...",D=800,W=16,J=1,re=2,U=3,ee=1/0,Z=9007199254740991,ue=17976931348623157e292,X=NaN,Oe=4294967295,Ee=Oe-1,Me=Oe>>>1,ye=[["ary",I],["bind",y],["bindKey",w],["curry",E],["curryRight",_],["flip",B],["partial",P],["partialRight",R],["rearg",k]],be="[object Arguments]",$e="[object Array]",me="[object AsyncFunction]",Se="[object Boolean]",q="[object Date]",te="[object DOMException]",Y="[object Error]",j="[object Function]",ie="[object GeneratorFunction]",Q="[object Map]",Ae="[object Number]",G="[object Null]",fe="[object Object]",ve="[object Promise]",pe="[object Proxy]",xe="[object RegExp]",ce="[object Set]",Ce="[object String]",De="[object Symbol]",nt="[object Undefined]",kt="[object WeakMap]",Dn="[object WeakSet]",Ct="[object ArrayBuffer]",lt="[object DataView]",Nt="[object Float32Array]",mn="[object Float64Array]",on="[object Int8Array]",_n="[object Int16Array]",Qt="[object Int32Array]",vn="[object Uint8Array]",gr="[object Uint8ClampedArray]",Un="[object Uint16Array]",gt="[object Uint32Array]",mt=/\b__p \+= '';/g,ze=/\b(__p \+=) '' \+/g,jn=/(__e\(.*?\)|\b__t\)) \+\n'';/g,On=/&(?:amp|lt|gt|quot|#39);/g,bi=/[&<>"']/g,Jt=RegExp(On.source),Sa=RegExp(bi.source),Ft=/<%-([\s\S]+?)%>/g,Bl=/<%([\s\S]+?)%>/g,rr=/<%=([\s\S]+?)%>/g,yn=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Ca=/^\w*$/,No=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,jr=/[\\^$.*+?()[\]{}|]/g,Cs=RegExp(jr.source),Lr=/^\s+/,mr=/\s/,Gn=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,ot=/\{\n\/\* \[wrapped with (.+)\] \*/,xi=/,? & /,wg=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,zl=/[()=,{}\[\]\/\s]/,Wl=/\\(\\)?/g,Es=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Bc=/\w*$/,_s=/^[-+]0x[0-9a-f]+$/i,zc=/^0b[01]+$/i,Ea=/^\[object .+?Constructor\]$/,Hl=/^0o[0-7]+$/i,vr=/^(?:0|[1-9]\d*)$/,wi=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Os=/($^)/,Wc=/['\n\r\u2028\u2029\\]/g,Ps="\\ud800-\\udfff",Ul="\\u0300-\\u036f",Hc="\\ufe20-\\ufe2f",Gl="\\u20d0-\\u20ff",Uc=Ul+Hc+Gl,_a="\\u2700-\\u27bf",Gc="a-z\\xdf-\\xf6\\xf8-\\xff",yr="\\xac\\xb1\\xd7\\xf7",$r="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",Oa="\\u2000-\\u206f",As=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",qc="A-Z\\xc0-\\xd6\\xd8-\\xde",Rs="\\ufe0e\\ufe0f",Is=yr+$r+Oa+As,ql="['’]",Ts="["+Ps+"]",ks="["+Is+"]",Mo="["+Uc+"]",Kc="\\d+",Sg="["+_a+"]",Yc="["+Gc+"]",Xc="[^"+Ps+Is+Kc+_a+Gc+qc+"]",Pa="\\ud83c[\\udffb-\\udfff]",Kl="(?:"+Mo+"|"+Pa+")",Ns="[^"+Ps+"]",Yl="(?:\\ud83c[\\udde6-\\uddff]){2}",Xl="[\\ud800-\\udbff][\\udc00-\\udfff]",Do="["+qc+"]",Zc="\\u200d",Ms="(?:"+Yc+"|"+Xc+")",Cg="(?:"+Do+"|"+Xc+")",Qc="(?:"+ql+"(?:d|ll|m|re|s|t|ve))?",_e="(?:"+ql+"(?:D|LL|M|RE|S|T|VE))?",Fe=Kl+"?",Je="["+Rs+"]?",zt="(?:"+Zc+"(?:"+[Ns,Yl,Xl].join("|")+")"+Je+Fe+")*",en="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",tn="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Si=Je+Fe+zt,Ui="(?:"+[Sg,Yl,Xl].join("|")+")"+Si,Ds="(?:"+[Ns+Mo+"?",Mo,Yl,Xl,Ts].join("|")+")",Eg=RegExp(ql,"g"),bS=RegExp(Mo,"g"),_g=RegExp(Pa+"(?="+Pa+")|"+Ds+Si,"g"),LF=RegExp([Do+"?"+Yc+"+"+Qc+"(?="+[ks,Do,"$"].join("|")+")",Cg+"+"+_e+"(?="+[ks,Do+Ms,"$"].join("|")+")",Do+"?"+Ms+"+"+Qc,Do+"+"+_e,tn,en,Kc,Ui].join("|"),"g"),$F=RegExp("["+Zc+Ps+Uc+Rs+"]"),FF=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,VF=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],BF=-1,Mt={};Mt[Nt]=Mt[mn]=Mt[on]=Mt[_n]=Mt[Qt]=Mt[vn]=Mt[gr]=Mt[Un]=Mt[gt]=!0,Mt[be]=Mt[$e]=Mt[Ct]=Mt[Se]=Mt[lt]=Mt[q]=Mt[Y]=Mt[j]=Mt[Q]=Mt[Ae]=Mt[fe]=Mt[xe]=Mt[ce]=Mt[Ce]=Mt[kt]=!1;var It={};It[be]=It[$e]=It[Ct]=It[lt]=It[Se]=It[q]=It[Nt]=It[mn]=It[on]=It[_n]=It[Qt]=It[Q]=It[Ae]=It[fe]=It[xe]=It[ce]=It[Ce]=It[De]=It[vn]=It[gr]=It[Un]=It[gt]=!0,It[Y]=It[j]=It[kt]=!1;var zF={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},WF={"&":"&","<":"<",">":">",'"':""","'":"'"},HF={"&":"&","<":"<",">":">",""":'"',"'":"'"},UF={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},GF=parseFloat,qF=parseInt,xS=typeof Zf=="object"&&Zf&&Zf.Object===Object&&Zf,KF=typeof self=="object"&&self&&self.Object===Object&&self,Pn=xS||KF||Function("return this")(),Og=t&&!t.nodeType&&t,Aa=Og&&!0&&e&&!e.nodeType&&e,wS=Aa&&Aa.exports===Og,Pg=wS&&xS.process,Fr=(function(){try{var z=Aa&&Aa.require&&Aa.require("util").types;return z||Pg&&Pg.binding&&Pg.binding("util")}catch{}})(),SS=Fr&&Fr.isArrayBuffer,CS=Fr&&Fr.isDate,ES=Fr&&Fr.isMap,_S=Fr&&Fr.isRegExp,OS=Fr&&Fr.isSet,PS=Fr&&Fr.isTypedArray;function br(z,oe,ne){switch(ne.length){case 0:return z.call(oe);case 1:return z.call(oe,ne[0]);case 2:return z.call(oe,ne[0],ne[1]);case 3:return z.call(oe,ne[0],ne[1],ne[2])}return z.apply(oe,ne)}function YF(z,oe,ne,Pe){for(var Ye=-1,vt=z==null?0:z.length;++Ye<vt;){var an=z[Ye];oe(Pe,an,ne(an),z)}return Pe}function Vr(z,oe){for(var ne=-1,Pe=z==null?0:z.length;++ne<Pe&&oe(z[ne],ne,z)!==!1;);return z}function XF(z,oe){for(var ne=z==null?0:z.length;ne--&&oe(z[ne],ne,z)!==!1;);return z}function AS(z,oe){for(var ne=-1,Pe=z==null?0:z.length;++ne<Pe;)if(!oe(z[ne],ne,z))return!1;return!0}function jo(z,oe){for(var ne=-1,Pe=z==null?0:z.length,Ye=0,vt=[];++ne<Pe;){var an=z[ne];oe(an,ne,z)&&(vt[Ye++]=an)}return vt}function Jc(z,oe){var ne=z==null?0:z.length;return!!ne&&js(z,oe,0)>-1}function Ag(z,oe,ne){for(var Pe=-1,Ye=z==null?0:z.length;++Pe<Ye;)if(ne(oe,z[Pe]))return!0;return!1}function Vt(z,oe){for(var ne=-1,Pe=z==null?0:z.length,Ye=Array(Pe);++ne<Pe;)Ye[ne]=oe(z[ne],ne,z);return Ye}function Lo(z,oe){for(var ne=-1,Pe=oe.length,Ye=z.length;++ne<Pe;)z[Ye+ne]=oe[ne];return z}function Rg(z,oe,ne,Pe){var Ye=-1,vt=z==null?0:z.length;for(Pe&&vt&&(ne=z[++Ye]);++Ye<vt;)ne=oe(ne,z[Ye],Ye,z);return ne}function ZF(z,oe,ne,Pe){var Ye=z==null?0:z.length;for(Pe&&Ye&&(ne=z[--Ye]);Ye--;)ne=oe(ne,z[Ye],Ye,z);return ne}function Ig(z,oe){for(var ne=-1,Pe=z==null?0:z.length;++ne<Pe;)if(oe(z[ne],ne,z))return!0;return!1}var QF=Tg("length");function JF(z){return z.split("")}function eV(z){return z.match(wg)||[]}function RS(z,oe,ne){var Pe;return ne(z,function(Ye,vt,an){if(oe(Ye,vt,an))return Pe=vt,!1}),Pe}function ef(z,oe,ne,Pe){for(var Ye=z.length,vt=ne+(Pe?1:-1);Pe?vt--:++vt<Ye;)if(oe(z[vt],vt,z))return vt;return-1}function js(z,oe,ne){return oe===oe?dV(z,oe,ne):ef(z,IS,ne)}function tV(z,oe,ne,Pe){for(var Ye=ne-1,vt=z.length;++Ye<vt;)if(Pe(z[Ye],oe))return Ye;return-1}function IS(z){return z!==z}function TS(z,oe){var ne=z==null?0:z.length;return ne?Ng(z,oe)/ne:X}function Tg(z){return function(oe){return oe==null?n:oe[z]}}function kg(z){return function(oe){return z==null?n:z[oe]}}function kS(z,oe,ne,Pe,Ye){return Ye(z,function(vt,an,Ot){ne=Pe?(Pe=!1,vt):oe(ne,vt,an,Ot)}),ne}function nV(z,oe){var ne=z.length;for(z.sort(oe);ne--;)z[ne]=z[ne].value;return z}function Ng(z,oe){for(var ne,Pe=-1,Ye=z.length;++Pe<Ye;){var vt=oe(z[Pe]);vt!==n&&(ne=ne===n?vt:ne+vt)}return ne}function Mg(z,oe){for(var ne=-1,Pe=Array(z);++ne<z;)Pe[ne]=oe(ne);return Pe}function rV(z,oe){return Vt(oe,function(ne){return[ne,z[ne]]})}function NS(z){return z&&z.slice(0,LS(z)+1).replace(Lr,"")}function xr(z){return function(oe){return z(oe)}}function Dg(z,oe){return Vt(oe,function(ne){return z[ne]})}function Zl(z,oe){return z.has(oe)}function MS(z,oe){for(var ne=-1,Pe=z.length;++ne<Pe&&js(oe,z[ne],0)>-1;);return ne}function DS(z,oe){for(var ne=z.length;ne--&&js(oe,z[ne],0)>-1;);return ne}function iV(z,oe){for(var ne=z.length,Pe=0;ne--;)z[ne]===oe&&++Pe;return Pe}var oV=kg(zF),aV=kg(WF);function sV(z){return"\\"+UF[z]}function lV(z,oe){return z==null?n:z[oe]}function Ls(z){return $F.test(z)}function uV(z){return FF.test(z)}function cV(z){for(var oe,ne=[];!(oe=z.next()).done;)ne.push(oe.value);return ne}function jg(z){var oe=-1,ne=Array(z.size);return z.forEach(function(Pe,Ye){ne[++oe]=[Ye,Pe]}),ne}function jS(z,oe){return function(ne){return z(oe(ne))}}function $o(z,oe){for(var ne=-1,Pe=z.length,Ye=0,vt=[];++ne<Pe;){var an=z[ne];(an===oe||an===f)&&(z[ne]=f,vt[Ye++]=ne)}return vt}function tf(z){var oe=-1,ne=Array(z.size);return z.forEach(function(Pe){ne[++oe]=Pe}),ne}function fV(z){var oe=-1,ne=Array(z.size);return z.forEach(function(Pe){ne[++oe]=[Pe,Pe]}),ne}function dV(z,oe,ne){for(var Pe=ne-1,Ye=z.length;++Pe<Ye;)if(z[Pe]===oe)return Pe;return-1}function pV(z,oe,ne){for(var Pe=ne+1;Pe--;)if(z[Pe]===oe)return Pe;return Pe}function $s(z){return Ls(z)?gV(z):QF(z)}function oi(z){return Ls(z)?mV(z):JF(z)}function LS(z){for(var oe=z.length;oe--&&mr.test(z.charAt(oe)););return oe}var hV=kg(HF);function gV(z){for(var oe=_g.lastIndex=0;_g.test(z);)++oe;return oe}function mV(z){return z.match(_g)||[]}function vV(z){return z.match(LF)||[]}var yV=(function z(oe){oe=oe==null?Pn:Fs.defaults(Pn.Object(),oe,Fs.pick(Pn,VF));var ne=oe.Array,Pe=oe.Date,Ye=oe.Error,vt=oe.Function,an=oe.Math,Ot=oe.Object,Lg=oe.RegExp,bV=oe.String,Br=oe.TypeError,nf=ne.prototype,xV=vt.prototype,Vs=Ot.prototype,rf=oe["__core-js_shared__"],of=xV.toString,xt=Vs.hasOwnProperty,wV=0,$S=(function(){var l=/[^.]+$/.exec(rf&&rf.keys&&rf.keys.IE_PROTO||"");return l?"Symbol(src)_1."+l:""})(),af=Vs.toString,SV=of.call(Ot),CV=Pn._,EV=Lg("^"+of.call(xt).replace(jr,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),sf=wS?oe.Buffer:n,Fo=oe.Symbol,lf=oe.Uint8Array,FS=sf?sf.allocUnsafe:n,uf=jS(Ot.getPrototypeOf,Ot),VS=Ot.create,BS=Vs.propertyIsEnumerable,cf=nf.splice,zS=Fo?Fo.isConcatSpreadable:n,Ql=Fo?Fo.iterator:n,Ra=Fo?Fo.toStringTag:n,ff=(function(){try{var l=Ma(Ot,"defineProperty");return l({},"",{}),l}catch{}})(),_V=oe.clearTimeout!==Pn.clearTimeout&&oe.clearTimeout,OV=Pe&&Pe.now!==Pn.Date.now&&Pe.now,PV=oe.setTimeout!==Pn.setTimeout&&oe.setTimeout,df=an.ceil,pf=an.floor,$g=Ot.getOwnPropertySymbols,AV=sf?sf.isBuffer:n,WS=oe.isFinite,RV=nf.join,IV=jS(Ot.keys,Ot),sn=an.max,Ln=an.min,TV=Pe.now,kV=oe.parseInt,HS=an.random,NV=nf.reverse,Fg=Ma(oe,"DataView"),Jl=Ma(oe,"Map"),Vg=Ma(oe,"Promise"),Bs=Ma(oe,"Set"),eu=Ma(oe,"WeakMap"),tu=Ma(Ot,"create"),hf=eu&&new eu,zs={},MV=Da(Fg),DV=Da(Jl),jV=Da(Vg),LV=Da(Bs),$V=Da(eu),gf=Fo?Fo.prototype:n,nu=gf?gf.valueOf:n,US=gf?gf.toString:n;function T(l){if(Gt(l)&&!Xe(l)&&!(l instanceof ut)){if(l instanceof zr)return l;if(xt.call(l,"__wrapped__"))return G1(l)}return new zr(l)}var Ws=(function(){function l(){}return function(d){if(!Wt(d))return{};if(VS)return VS(d);l.prototype=d;var m=new l;return l.prototype=n,m}})();function mf(){}function zr(l,d){this.__wrapped__=l,this.__actions__=[],this.__chain__=!!d,this.__index__=0,this.__values__=n}T.templateSettings={escape:Ft,evaluate:Bl,interpolate:rr,variable:"",imports:{_:T}},T.prototype=mf.prototype,T.prototype.constructor=T,zr.prototype=Ws(mf.prototype),zr.prototype.constructor=zr;function ut(l){this.__wrapped__=l,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=Oe,this.__views__=[]}function FV(){var l=new ut(this.__wrapped__);return l.__actions__=ir(this.__actions__),l.__dir__=this.__dir__,l.__filtered__=this.__filtered__,l.__iteratees__=ir(this.__iteratees__),l.__takeCount__=this.__takeCount__,l.__views__=ir(this.__views__),l}function VV(){if(this.__filtered__){var l=new ut(this);l.__dir__=-1,l.__filtered__=!0}else l=this.clone(),l.__dir__*=-1;return l}function BV(){var l=this.__wrapped__.value(),d=this.__dir__,m=Xe(l),C=d<0,A=m?l.length:0,N=JB(0,A,this.__views__),M=N.start,F=N.end,H=F-M,se=C?F:M-1,le=this.__iteratees__,de=le.length,we=0,ke=Ln(H,this.__takeCount__);if(!m||!C&&A==H&&ke==H)return g1(l,this.__actions__);var He=[];e:for(;H--&&we<ke;){se+=d;for(var tt=-1,Ue=l[se];++tt<de;){var at=le[tt],ct=at.iteratee,Cr=at.type,Yn=ct(Ue);if(Cr==re)Ue=Yn;else if(!Yn){if(Cr==J)continue e;break e}}He[we++]=Ue}return He}ut.prototype=Ws(mf.prototype),ut.prototype.constructor=ut;function Ia(l){var d=-1,m=l==null?0:l.length;for(this.clear();++d<m;){var C=l[d];this.set(C[0],C[1])}}function zV(){this.__data__=tu?tu(null):{},this.size=0}function WV(l){var d=this.has(l)&&delete this.__data__[l];return this.size-=d?1:0,d}function HV(l){var d=this.__data__;if(tu){var m=d[l];return m===u?n:m}return xt.call(d,l)?d[l]:n}function UV(l){var d=this.__data__;return tu?d[l]!==n:xt.call(d,l)}function GV(l,d){var m=this.__data__;return this.size+=this.has(l)?0:1,m[l]=tu&&d===n?u:d,this}Ia.prototype.clear=zV,Ia.prototype.delete=WV,Ia.prototype.get=HV,Ia.prototype.has=UV,Ia.prototype.set=GV;function Gi(l){var d=-1,m=l==null?0:l.length;for(this.clear();++d<m;){var C=l[d];this.set(C[0],C[1])}}function qV(){this.__data__=[],this.size=0}function KV(l){var d=this.__data__,m=vf(d,l);if(m<0)return!1;var C=d.length-1;return m==C?d.pop():cf.call(d,m,1),--this.size,!0}function YV(l){var d=this.__data__,m=vf(d,l);return m<0?n:d[m][1]}function XV(l){return vf(this.__data__,l)>-1}function ZV(l,d){var m=this.__data__,C=vf(m,l);return C<0?(++this.size,m.push([l,d])):m[C][1]=d,this}Gi.prototype.clear=qV,Gi.prototype.delete=KV,Gi.prototype.get=YV,Gi.prototype.has=XV,Gi.prototype.set=ZV;function qi(l){var d=-1,m=l==null?0:l.length;for(this.clear();++d<m;){var C=l[d];this.set(C[0],C[1])}}function QV(){this.size=0,this.__data__={hash:new Ia,map:new(Jl||Gi),string:new Ia}}function JV(l){var d=Rf(this,l).delete(l);return this.size-=d?1:0,d}function eB(l){return Rf(this,l).get(l)}function tB(l){return Rf(this,l).has(l)}function nB(l,d){var m=Rf(this,l),C=m.size;return m.set(l,d),this.size+=m.size==C?0:1,this}qi.prototype.clear=QV,qi.prototype.delete=JV,qi.prototype.get=eB,qi.prototype.has=tB,qi.prototype.set=nB;function Ta(l){var d=-1,m=l==null?0:l.length;for(this.__data__=new qi;++d<m;)this.add(l[d])}function rB(l){return this.__data__.set(l,u),this}function iB(l){return this.__data__.has(l)}Ta.prototype.add=Ta.prototype.push=rB,Ta.prototype.has=iB;function ai(l){var d=this.__data__=new Gi(l);this.size=d.size}function oB(){this.__data__=new Gi,this.size=0}function aB(l){var d=this.__data__,m=d.delete(l);return this.size=d.size,m}function sB(l){return this.__data__.get(l)}function lB(l){return this.__data__.has(l)}function uB(l,d){var m=this.__data__;if(m instanceof Gi){var C=m.__data__;if(!Jl||C.length<i-1)return C.push([l,d]),this.size=++m.size,this;m=this.__data__=new qi(C)}return m.set(l,d),this.size=m.size,this}ai.prototype.clear=oB,ai.prototype.delete=aB,ai.prototype.get=sB,ai.prototype.has=lB,ai.prototype.set=uB;function GS(l,d){var m=Xe(l),C=!m&&ja(l),A=!m&&!C&&Ho(l),N=!m&&!C&&!A&&qs(l),M=m||C||A||N,F=M?Mg(l.length,bV):[],H=F.length;for(var se in l)(d||xt.call(l,se))&&!(M&&(se=="length"||A&&(se=="offset"||se=="parent")||N&&(se=="buffer"||se=="byteLength"||se=="byteOffset")||Zi(se,H)))&&F.push(se);return F}function qS(l){var d=l.length;return d?l[Zg(0,d-1)]:n}function cB(l,d){return If(ir(l),ka(d,0,l.length))}function fB(l){return If(ir(l))}function Bg(l,d,m){(m!==n&&!si(l[d],m)||m===n&&!(d in l))&&Ki(l,d,m)}function ru(l,d,m){var C=l[d];(!(xt.call(l,d)&&si(C,m))||m===n&&!(d in l))&&Ki(l,d,m)}function vf(l,d){for(var m=l.length;m--;)if(si(l[m][0],d))return m;return-1}function dB(l,d,m,C){return Vo(l,function(A,N,M){d(C,A,m(A),M)}),C}function KS(l,d){return l&&Ei(d,bn(d),l)}function pB(l,d){return l&&Ei(d,ar(d),l)}function Ki(l,d,m){d=="__proto__"&&ff?ff(l,d,{configurable:!0,enumerable:!0,value:m,writable:!0}):l[d]=m}function zg(l,d){for(var m=-1,C=d.length,A=ne(C),N=l==null;++m<C;)A[m]=N?n:Sm(l,d[m]);return A}function ka(l,d,m){return l===l&&(m!==n&&(l=l<=m?l:m),d!==n&&(l=l>=d?l:d)),l}function Wr(l,d,m,C,A,N){var M,F=d&p,H=d&g,se=d&h;if(m&&(M=A?m(l,C,A,N):m(l)),M!==n)return M;if(!Wt(l))return l;var le=Xe(l);if(le){if(M=tz(l),!F)return ir(l,M)}else{var de=$n(l),we=de==j||de==ie;if(Ho(l))return y1(l,F);if(de==fe||de==be||we&&!A){if(M=H||we?{}:L1(l),!F)return H?HB(l,pB(M,l)):WB(l,KS(M,l))}else{if(!It[de])return A?l:{};M=nz(l,de,F)}}N||(N=new ai);var ke=N.get(l);if(ke)return ke;N.set(l,M),dC(l)?l.forEach(function(Ue){M.add(Wr(Ue,d,m,Ue,l,N))}):cC(l)&&l.forEach(function(Ue,at){M.set(at,Wr(Ue,d,m,at,l,N))});var He=se?H?lm:sm:H?ar:bn,tt=le?n:He(l);return Vr(tt||l,function(Ue,at){tt&&(at=Ue,Ue=l[at]),ru(M,at,Wr(Ue,d,m,at,l,N))}),M}function hB(l){var d=bn(l);return function(m){return YS(m,l,d)}}function YS(l,d,m){var C=m.length;if(l==null)return!C;for(l=Ot(l);C--;){var A=m[C],N=d[A],M=l[A];if(M===n&&!(A in l)||!N(M))return!1}return!0}function XS(l,d,m){if(typeof l!="function")throw new Br(a);return cu(function(){l.apply(n,m)},d)}function iu(l,d,m,C){var A=-1,N=Jc,M=!0,F=l.length,H=[],se=d.length;if(!F)return H;m&&(d=Vt(d,xr(m))),C?(N=Ag,M=!1):d.length>=i&&(N=Zl,M=!1,d=new Ta(d));e:for(;++A<F;){var le=l[A],de=m==null?le:m(le);if(le=C||le!==0?le:0,M&&de===de){for(var we=se;we--;)if(d[we]===de)continue e;H.push(le)}else N(d,de,C)||H.push(le)}return H}var Vo=C1(Ci),ZS=C1(Hg,!0);function gB(l,d){var m=!0;return Vo(l,function(C,A,N){return m=!!d(C,A,N),m}),m}function yf(l,d,m){for(var C=-1,A=l.length;++C<A;){var N=l[C],M=d(N);if(M!=null&&(F===n?M===M&&!Sr(M):m(M,F)))var F=M,H=N}return H}function mB(l,d,m,C){var A=l.length;for(m=et(m),m<0&&(m=-m>A?0:A+m),C=C===n||C>A?A:et(C),C<0&&(C+=A),C=m>C?0:hC(C);m<C;)l[m++]=d;return l}function QS(l,d){var m=[];return Vo(l,function(C,A,N){d(C,A,N)&&m.push(C)}),m}function An(l,d,m,C,A){var N=-1,M=l.length;for(m||(m=iz),A||(A=[]);++N<M;){var F=l[N];d>0&&m(F)?d>1?An(F,d-1,m,C,A):Lo(A,F):C||(A[A.length]=F)}return A}var Wg=E1(),JS=E1(!0);function Ci(l,d){return l&&Wg(l,d,bn)}function Hg(l,d){return l&&JS(l,d,bn)}function bf(l,d){return jo(d,function(m){return Qi(l[m])})}function Na(l,d){d=zo(d,l);for(var m=0,C=d.length;l!=null&&m<C;)l=l[_i(d[m++])];return m&&m==C?l:n}function e1(l,d,m){var C=d(l);return Xe(l)?C:Lo(C,m(l))}function qn(l){return l==null?l===n?nt:G:Ra&&Ra in Ot(l)?QB(l):fz(l)}function Ug(l,d){return l>d}function vB(l,d){return l!=null&&xt.call(l,d)}function yB(l,d){return l!=null&&d in Ot(l)}function bB(l,d,m){return l>=Ln(d,m)&&l<sn(d,m)}function Gg(l,d,m){for(var C=m?Ag:Jc,A=l[0].length,N=l.length,M=N,F=ne(N),H=1/0,se=[];M--;){var le=l[M];M&&d&&(le=Vt(le,xr(d))),H=Ln(le.length,H),F[M]=!m&&(d||A>=120&&le.length>=120)?new Ta(M&&le):n}le=l[0];var de=-1,we=F[0];e:for(;++de<A&&se.length<H;){var ke=le[de],He=d?d(ke):ke;if(ke=m||ke!==0?ke:0,!(we?Zl(we,He):C(se,He,m))){for(M=N;--M;){var tt=F[M];if(!(tt?Zl(tt,He):C(l[M],He,m)))continue e}we&&we.push(He),se.push(ke)}}return se}function xB(l,d,m,C){return Ci(l,function(A,N,M){d(C,m(A),N,M)}),C}function ou(l,d,m){d=zo(d,l),l=B1(l,d);var C=l==null?l:l[_i(Ur(d))];return C==null?n:br(C,l,m)}function t1(l){return Gt(l)&&qn(l)==be}function wB(l){return Gt(l)&&qn(l)==Ct}function SB(l){return Gt(l)&&qn(l)==q}function au(l,d,m,C,A){return l===d?!0:l==null||d==null||!Gt(l)&&!Gt(d)?l!==l&&d!==d:CB(l,d,m,C,au,A)}function CB(l,d,m,C,A,N){var M=Xe(l),F=Xe(d),H=M?$e:$n(l),se=F?$e:$n(d);H=H==be?fe:H,se=se==be?fe:se;var le=H==fe,de=se==fe,we=H==se;if(we&&Ho(l)){if(!Ho(d))return!1;M=!0,le=!1}if(we&&!le)return N||(N=new ai),M||qs(l)?M1(l,d,m,C,A,N):XB(l,d,H,m,C,A,N);if(!(m&v)){var ke=le&&xt.call(l,"__wrapped__"),He=de&&xt.call(d,"__wrapped__");if(ke||He){var tt=ke?l.value():l,Ue=He?d.value():d;return N||(N=new ai),A(tt,Ue,m,C,N)}}return we?(N||(N=new ai),ZB(l,d,m,C,A,N)):!1}function EB(l){return Gt(l)&&$n(l)==Q}function qg(l,d,m,C){var A=m.length,N=A,M=!C;if(l==null)return!N;for(l=Ot(l);A--;){var F=m[A];if(M&&F[2]?F[1]!==l[F[0]]:!(F[0]in l))return!1}for(;++A<N;){F=m[A];var H=F[0],se=l[H],le=F[1];if(M&&F[2]){if(se===n&&!(H in l))return!1}else{var de=new ai;if(C)var we=C(se,le,H,l,d,de);if(!(we===n?au(le,se,v|b,C,de):we))return!1}}return!0}function n1(l){if(!Wt(l)||az(l))return!1;var d=Qi(l)?EV:Ea;return d.test(Da(l))}function _B(l){return Gt(l)&&qn(l)==xe}function OB(l){return Gt(l)&&$n(l)==ce}function PB(l){return Gt(l)&&jf(l.length)&&!!Mt[qn(l)]}function r1(l){return typeof l=="function"?l:l==null?sr:typeof l=="object"?Xe(l)?a1(l[0],l[1]):o1(l):_C(l)}function Kg(l){if(!uu(l))return IV(l);var d=[];for(var m in Ot(l))xt.call(l,m)&&m!="constructor"&&d.push(m);return d}function AB(l){if(!Wt(l))return cz(l);var d=uu(l),m=[];for(var C in l)C=="constructor"&&(d||!xt.call(l,C))||m.push(C);return m}function Yg(l,d){return l<d}function i1(l,d){var m=-1,C=or(l)?ne(l.length):[];return Vo(l,function(A,N,M){C[++m]=d(A,N,M)}),C}function o1(l){var d=cm(l);return d.length==1&&d[0][2]?F1(d[0][0],d[0][1]):function(m){return m===l||qg(m,l,d)}}function a1(l,d){return dm(l)&&$1(d)?F1(_i(l),d):function(m){var C=Sm(m,l);return C===n&&C===d?Cm(m,l):au(d,C,v|b)}}function xf(l,d,m,C,A){l!==d&&Wg(d,function(N,M){if(A||(A=new ai),Wt(N))RB(l,d,M,m,xf,C,A);else{var F=C?C(hm(l,M),N,M+"",l,d,A):n;F===n&&(F=N),Bg(l,M,F)}},ar)}function RB(l,d,m,C,A,N,M){var F=hm(l,m),H=hm(d,m),se=M.get(H);if(se){Bg(l,m,se);return}var le=N?N(F,H,m+"",l,d,M):n,de=le===n;if(de){var we=Xe(H),ke=!we&&Ho(H),He=!we&&!ke&&qs(H);le=H,we||ke||He?Xe(F)?le=F:Yt(F)?le=ir(F):ke?(de=!1,le=y1(H,!0)):He?(de=!1,le=b1(H,!0)):le=[]:fu(H)||ja(H)?(le=F,ja(F)?le=gC(F):(!Wt(F)||Qi(F))&&(le=L1(H))):de=!1}de&&(M.set(H,le),A(le,H,C,N,M),M.delete(H)),Bg(l,m,le)}function s1(l,d){var m=l.length;if(m)return d+=d<0?m:0,Zi(d,m)?l[d]:n}function l1(l,d,m){d.length?d=Vt(d,function(N){return Xe(N)?function(M){return Na(M,N.length===1?N[0]:N)}:N}):d=[sr];var C=-1;d=Vt(d,xr(We()));var A=i1(l,function(N,M,F){var H=Vt(d,function(se){return se(N)});return{criteria:H,index:++C,value:N}});return nV(A,function(N,M){return zB(N,M,m)})}function IB(l,d){return u1(l,d,function(m,C){return Cm(l,C)})}function u1(l,d,m){for(var C=-1,A=d.length,N={};++C<A;){var M=d[C],F=Na(l,M);m(F,M)&&su(N,zo(M,l),F)}return N}function TB(l){return function(d){return Na(d,l)}}function Xg(l,d,m,C){var A=C?tV:js,N=-1,M=d.length,F=l;for(l===d&&(d=ir(d)),m&&(F=Vt(l,xr(m)));++N<M;)for(var H=0,se=d[N],le=m?m(se):se;(H=A(F,le,H,C))>-1;)F!==l&&cf.call(F,H,1),cf.call(l,H,1);return l}function c1(l,d){for(var m=l?d.length:0,C=m-1;m--;){var A=d[m];if(m==C||A!==N){var N=A;Zi(A)?cf.call(l,A,1):em(l,A)}}return l}function Zg(l,d){return l+pf(HS()*(d-l+1))}function kB(l,d,m,C){for(var A=-1,N=sn(df((d-l)/(m||1)),0),M=ne(N);N--;)M[C?N:++A]=l,l+=m;return M}function Qg(l,d){var m="";if(!l||d<1||d>Z)return m;do d%2&&(m+=l),d=pf(d/2),d&&(l+=l);while(d);return m}function rt(l,d){return gm(V1(l,d,sr),l+"")}function NB(l){return qS(Ks(l))}function MB(l,d){var m=Ks(l);return If(m,ka(d,0,m.length))}function su(l,d,m,C){if(!Wt(l))return l;d=zo(d,l);for(var A=-1,N=d.length,M=N-1,F=l;F!=null&&++A<N;){var H=_i(d[A]),se=m;if(H==="__proto__"||H==="constructor"||H==="prototype")return l;if(A!=M){var le=F[H];se=C?C(le,H,F):n,se===n&&(se=Wt(le)?le:Zi(d[A+1])?[]:{})}ru(F,H,se),F=F[H]}return l}var f1=hf?function(l,d){return hf.set(l,d),l}:sr,DB=ff?function(l,d){return ff(l,"toString",{configurable:!0,enumerable:!1,value:_m(d),writable:!0})}:sr;function jB(l){return If(Ks(l))}function Hr(l,d,m){var C=-1,A=l.length;d<0&&(d=-d>A?0:A+d),m=m>A?A:m,m<0&&(m+=A),A=d>m?0:m-d>>>0,d>>>=0;for(var N=ne(A);++C<A;)N[C]=l[C+d];return N}function LB(l,d){var m;return Vo(l,function(C,A,N){return m=d(C,A,N),!m}),!!m}function wf(l,d,m){var C=0,A=l==null?C:l.length;if(typeof d=="number"&&d===d&&A<=Me){for(;C<A;){var N=C+A>>>1,M=l[N];M!==null&&!Sr(M)&&(m?M<=d:M<d)?C=N+1:A=N}return A}return Jg(l,d,sr,m)}function Jg(l,d,m,C){var A=0,N=l==null?0:l.length;if(N===0)return 0;d=m(d);for(var M=d!==d,F=d===null,H=Sr(d),se=d===n;A<N;){var le=pf((A+N)/2),de=m(l[le]),we=de!==n,ke=de===null,He=de===de,tt=Sr(de);if(M)var Ue=C||He;else se?Ue=He&&(C||we):F?Ue=He&&we&&(C||!ke):H?Ue=He&&we&&!ke&&(C||!tt):ke||tt?Ue=!1:Ue=C?de<=d:de<d;Ue?A=le+1:N=le}return Ln(N,Ee)}function d1(l,d){for(var m=-1,C=l.length,A=0,N=[];++m<C;){var M=l[m],F=d?d(M):M;if(!m||!si(F,H)){var H=F;N[A++]=M===0?0:M}}return N}function p1(l){return typeof l=="number"?l:Sr(l)?X:+l}function wr(l){if(typeof l=="string")return l;if(Xe(l))return Vt(l,wr)+"";if(Sr(l))return US?US.call(l):"";var d=l+"";return d=="0"&&1/l==-ee?"-0":d}function Bo(l,d,m){var C=-1,A=Jc,N=l.length,M=!0,F=[],H=F;if(m)M=!1,A=Ag;else if(N>=i){var se=d?null:KB(l);if(se)return tf(se);M=!1,A=Zl,H=new Ta}else H=d?[]:F;e:for(;++C<N;){var le=l[C],de=d?d(le):le;if(le=m||le!==0?le:0,M&&de===de){for(var we=H.length;we--;)if(H[we]===de)continue e;d&&H.push(de),F.push(le)}else A(H,de,m)||(H!==F&&H.push(de),F.push(le))}return F}function em(l,d){d=zo(d,l);var m=-1,C=d.length;if(!C)return!0;for(var A=l==null||typeof l!="object"&&typeof l!="function";++m<C;){var N=d[m];if(typeof N=="string"){if(N==="__proto__"&&!xt.call(l,"__proto__"))return!1;if(N==="constructor"&&m+1<C&&typeof d[m+1]=="string"&&d[m+1]==="prototype"){if(A&&m===0)continue;return!1}}}var M=B1(l,d);return M==null||delete M[_i(Ur(d))]}function h1(l,d,m,C){return su(l,d,m(Na(l,d)),C)}function Sf(l,d,m,C){for(var A=l.length,N=C?A:-1;(C?N--:++N<A)&&d(l[N],N,l););return m?Hr(l,C?0:N,C?N+1:A):Hr(l,C?N+1:0,C?A:N)}function g1(l,d){var m=l;return m instanceof ut&&(m=m.value()),Rg(d,function(C,A){return A.func.apply(A.thisArg,Lo([C],A.args))},m)}function tm(l,d,m){var C=l.length;if(C<2)return C?Bo(l[0]):[];for(var A=-1,N=ne(C);++A<C;)for(var M=l[A],F=-1;++F<C;)F!=A&&(N[A]=iu(N[A]||M,l[F],d,m));return Bo(An(N,1),d,m)}function m1(l,d,m){for(var C=-1,A=l.length,N=d.length,M={};++C<A;){var F=C<N?d[C]:n;m(M,l[C],F)}return M}function nm(l){return Yt(l)?l:[]}function rm(l){return typeof l=="function"?l:sr}function zo(l,d){return Xe(l)?l:dm(l,d)?[l]:U1(wt(l))}var $B=rt;function Wo(l,d,m){var C=l.length;return m=m===n?C:m,!d&&m>=C?l:Hr(l,d,m)}var v1=_V||function(l){return Pn.clearTimeout(l)};function y1(l,d){if(d)return l.slice();var m=l.length,C=FS?FS(m):new l.constructor(m);return l.copy(C),C}function im(l){var d=new l.constructor(l.byteLength);return new lf(d).set(new lf(l)),d}function FB(l,d){var m=d?im(l.buffer):l.buffer;return new l.constructor(m,l.byteOffset,l.byteLength)}function VB(l){var d=new l.constructor(l.source,Bc.exec(l));return d.lastIndex=l.lastIndex,d}function BB(l){return nu?Ot(nu.call(l)):{}}function b1(l,d){var m=d?im(l.buffer):l.buffer;return new l.constructor(m,l.byteOffset,l.length)}function x1(l,d){if(l!==d){var m=l!==n,C=l===null,A=l===l,N=Sr(l),M=d!==n,F=d===null,H=d===d,se=Sr(d);if(!F&&!se&&!N&&l>d||N&&M&&H&&!F&&!se||C&&M&&H||!m&&H||!A)return 1;if(!C&&!N&&!se&&l<d||se&&m&&A&&!C&&!N||F&&m&&A||!M&&A||!H)return-1}return 0}function zB(l,d,m){for(var C=-1,A=l.criteria,N=d.criteria,M=A.length,F=m.length;++C<M;){var H=x1(A[C],N[C]);if(H){if(C>=F)return H;var se=m[C];return H*(se=="desc"?-1:1)}}return l.index-d.index}function w1(l,d,m,C){for(var A=-1,N=l.length,M=m.length,F=-1,H=d.length,se=sn(N-M,0),le=ne(H+se),de=!C;++F<H;)le[F]=d[F];for(;++A<M;)(de||A<N)&&(le[m[A]]=l[A]);for(;se--;)le[F++]=l[A++];return le}function S1(l,d,m,C){for(var A=-1,N=l.length,M=-1,F=m.length,H=-1,se=d.length,le=sn(N-F,0),de=ne(le+se),we=!C;++A<le;)de[A]=l[A];for(var ke=A;++H<se;)de[ke+H]=d[H];for(;++M<F;)(we||A<N)&&(de[ke+m[M]]=l[A++]);return de}function ir(l,d){var m=-1,C=l.length;for(d||(d=ne(C));++m<C;)d[m]=l[m];return d}function Ei(l,d,m,C){var A=!m;m||(m={});for(var N=-1,M=d.length;++N<M;){var F=d[N],H=C?C(m[F],l[F],F,m,l):n;H===n&&(H=l[F]),A?Ki(m,F,H):ru(m,F,H)}return m}function WB(l,d){return Ei(l,fm(l),d)}function HB(l,d){return Ei(l,D1(l),d)}function Cf(l,d){return function(m,C){var A=Xe(m)?YF:dB,N=d?d():{};return A(m,l,We(C,2),N)}}function Hs(l){return rt(function(d,m){var C=-1,A=m.length,N=A>1?m[A-1]:n,M=A>2?m[2]:n;for(N=l.length>3&&typeof N=="function"?(A--,N):n,M&&Kn(m[0],m[1],M)&&(N=A<3?n:N,A=1),d=Ot(d);++C<A;){var F=m[C];F&&l(d,F,C,N)}return d})}function C1(l,d){return function(m,C){if(m==null)return m;if(!or(m))return l(m,C);for(var A=m.length,N=d?A:-1,M=Ot(m);(d?N--:++N<A)&&C(M[N],N,M)!==!1;);return m}}function E1(l){return function(d,m,C){for(var A=-1,N=Ot(d),M=C(d),F=M.length;F--;){var H=M[l?F:++A];if(m(N[H],H,N)===!1)break}return d}}function UB(l,d,m){var C=d&y,A=lu(l);function N(){var M=this&&this!==Pn&&this instanceof N?A:l;return M.apply(C?m:this,arguments)}return N}function _1(l){return function(d){d=wt(d);var m=Ls(d)?oi(d):n,C=m?m[0]:d.charAt(0),A=m?Wo(m,1).join(""):d.slice(1);return C[l]()+A}}function Us(l){return function(d){return Rg(CC(SC(d).replace(Eg,"")),l,"")}}function lu(l){return function(){var d=arguments;switch(d.length){case 0:return new l;case 1:return new l(d[0]);case 2:return new l(d[0],d[1]);case 3:return new l(d[0],d[1],d[2]);case 4:return new l(d[0],d[1],d[2],d[3]);case 5:return new l(d[0],d[1],d[2],d[3],d[4]);case 6:return new l(d[0],d[1],d[2],d[3],d[4],d[5]);case 7:return new l(d[0],d[1],d[2],d[3],d[4],d[5],d[6])}var m=Ws(l.prototype),C=l.apply(m,d);return Wt(C)?C:m}}function GB(l,d,m){var C=lu(l);function A(){for(var N=arguments.length,M=ne(N),F=N,H=Gs(A);F--;)M[F]=arguments[F];var se=N<3&&M[0]!==H&&M[N-1]!==H?[]:$o(M,H);if(N-=se.length,N<m)return I1(l,d,Ef,A.placeholder,n,M,se,n,n,m-N);var le=this&&this!==Pn&&this instanceof A?C:l;return br(le,this,M)}return A}function O1(l){return function(d,m,C){var A=Ot(d);if(!or(d)){var N=We(m,3);d=bn(d),m=function(F){return N(A[F],F,A)}}var M=l(d,m,C);return M>-1?A[N?d[M]:M]:n}}function P1(l){return Xi(function(d){var m=d.length,C=m,A=zr.prototype.thru;for(l&&d.reverse();C--;){var N=d[C];if(typeof N!="function")throw new Br(a);if(A&&!M&&Af(N)=="wrapper")var M=new zr([],!0)}for(C=M?C:m;++C<m;){N=d[C];var F=Af(N),H=F=="wrapper"?um(N):n;H&&pm(H[0])&&H[1]==(I|E|P|k)&&!H[4].length&&H[9]==1?M=M[Af(H[0])].apply(M,H[3]):M=N.length==1&&pm(N)?M[F]():M.thru(N)}return function(){var se=arguments,le=se[0];if(M&&se.length==1&&Xe(le))return M.plant(le).value();for(var de=0,we=m?d[de].apply(this,se):le;++de<m;)we=d[de].call(this,we);return we}})}function Ef(l,d,m,C,A,N,M,F,H,se){var le=d&I,de=d&y,we=d&w,ke=d&(E|_),He=d&B,tt=we?n:lu(l);function Ue(){for(var at=arguments.length,ct=ne(at),Cr=at;Cr--;)ct[Cr]=arguments[Cr];if(ke)var Yn=Gs(Ue),Er=iV(ct,Yn);if(C&&(ct=w1(ct,C,A,ke)),N&&(ct=S1(ct,N,M,ke)),at-=Er,ke&&at<se){var Xt=$o(ct,Yn);return I1(l,d,Ef,Ue.placeholder,m,ct,Xt,F,H,se-at)}var li=de?m:this,eo=we?li[l]:l;return at=ct.length,F?ct=dz(ct,F):He&&at>1&&ct.reverse(),le&&H<at&&(ct.length=H),this&&this!==Pn&&this instanceof Ue&&(eo=tt||lu(eo)),eo.apply(li,ct)}return Ue}function A1(l,d){return function(m,C){return xB(m,l,d(C),{})}}function _f(l,d){return function(m,C){var A;if(m===n&&C===n)return d;if(m!==n&&(A=m),C!==n){if(A===n)return C;typeof m=="string"||typeof C=="string"?(m=wr(m),C=wr(C)):(m=p1(m),C=p1(C)),A=l(m,C)}return A}}function om(l){return Xi(function(d){return d=Vt(d,xr(We())),rt(function(m){var C=this;return l(d,function(A){return br(A,C,m)})})})}function Of(l,d){d=d===n?" ":wr(d);var m=d.length;if(m<2)return m?Qg(d,l):d;var C=Qg(d,df(l/$s(d)));return Ls(d)?Wo(oi(C),0,l).join(""):C.slice(0,l)}function qB(l,d,m,C){var A=d&y,N=lu(l);function M(){for(var F=-1,H=arguments.length,se=-1,le=C.length,de=ne(le+H),we=this&&this!==Pn&&this instanceof M?N:l;++se<le;)de[se]=C[se];for(;H--;)de[se++]=arguments[++F];return br(we,A?m:this,de)}return M}function R1(l){return function(d,m,C){return C&&typeof C!="number"&&Kn(d,m,C)&&(m=C=n),d=Ji(d),m===n?(m=d,d=0):m=Ji(m),C=C===n?d<m?1:-1:Ji(C),kB(d,m,C,l)}}function Pf(l){return function(d,m){return typeof d=="string"&&typeof m=="string"||(d=Gr(d),m=Gr(m)),l(d,m)}}function I1(l,d,m,C,A,N,M,F,H,se){var le=d&E,de=le?M:n,we=le?n:M,ke=le?N:n,He=le?n:N;d|=le?P:R,d&=~(le?R:P),d&S||(d&=-4);var tt=[l,d,A,ke,de,He,we,F,H,se],Ue=m.apply(n,tt);return pm(l)&&z1(Ue,tt),Ue.placeholder=C,W1(Ue,l,d)}function am(l){var d=an[l];return function(m,C){if(m=Gr(m),C=C==null?0:Ln(et(C),292),C&&WS(m)){var A=(wt(m)+"e").split("e"),N=d(A[0]+"e"+(+A[1]+C));return A=(wt(N)+"e").split("e"),+(A[0]+"e"+(+A[1]-C))}return d(m)}}var KB=Bs&&1/tf(new Bs([,-0]))[1]==ee?function(l){return new Bs(l)}:Am;function T1(l){return function(d){var m=$n(d);return m==Q?jg(d):m==ce?fV(d):rV(d,l(d))}}function Yi(l,d,m,C,A,N,M,F){var H=d&w;if(!H&&typeof l!="function")throw new Br(a);var se=C?C.length:0;if(se||(d&=-97,C=A=n),M=M===n?M:sn(et(M),0),F=F===n?F:et(F),se-=A?A.length:0,d&R){var le=C,de=A;C=A=n}var we=H?n:um(l),ke=[l,d,m,C,A,le,de,N,M,F];if(we&&uz(ke,we),l=ke[0],d=ke[1],m=ke[2],C=ke[3],A=ke[4],F=ke[9]=ke[9]===n?H?0:l.length:sn(ke[9]-se,0),!F&&d&(E|_)&&(d&=-25),!d||d==y)var He=UB(l,d,m);else d==E||d==_?He=GB(l,d,F):(d==P||d==(y|P))&&!A.length?He=qB(l,d,m,C):He=Ef.apply(n,ke);var tt=we?f1:z1;return W1(tt(He,ke),l,d)}function k1(l,d,m,C){return l===n||si(l,Vs[m])&&!xt.call(C,m)?d:l}function N1(l,d,m,C,A,N){return Wt(l)&&Wt(d)&&(N.set(d,l),xf(l,d,n,N1,N),N.delete(d)),l}function YB(l){return fu(l)?n:l}function M1(l,d,m,C,A,N){var M=m&v,F=l.length,H=d.length;if(F!=H&&!(M&&H>F))return!1;var se=N.get(l),le=N.get(d);if(se&&le)return se==d&&le==l;var de=-1,we=!0,ke=m&b?new Ta:n;for(N.set(l,d),N.set(d,l);++de<F;){var He=l[de],tt=d[de];if(C)var Ue=M?C(tt,He,de,d,l,N):C(He,tt,de,l,d,N);if(Ue!==n){if(Ue)continue;we=!1;break}if(ke){if(!Ig(d,function(at,ct){if(!Zl(ke,ct)&&(He===at||A(He,at,m,C,N)))return ke.push(ct)})){we=!1;break}}else if(!(He===tt||A(He,tt,m,C,N))){we=!1;break}}return N.delete(l),N.delete(d),we}function XB(l,d,m,C,A,N,M){switch(m){case lt:if(l.byteLength!=d.byteLength||l.byteOffset!=d.byteOffset)return!1;l=l.buffer,d=d.buffer;case Ct:return!(l.byteLength!=d.byteLength||!N(new lf(l),new lf(d)));case Se:case q:case Ae:return si(+l,+d);case Y:return l.name==d.name&&l.message==d.message;case xe:case Ce:return l==d+"";case Q:var F=jg;case ce:var H=C&v;if(F||(F=tf),l.size!=d.size&&!H)return!1;var se=M.get(l);if(se)return se==d;C|=b,M.set(l,d);var le=M1(F(l),F(d),C,A,N,M);return M.delete(l),le;case De:if(nu)return nu.call(l)==nu.call(d)}return!1}function ZB(l,d,m,C,A,N){var M=m&v,F=sm(l),H=F.length,se=sm(d),le=se.length;if(H!=le&&!M)return!1;for(var de=H;de--;){var we=F[de];if(!(M?we in d:xt.call(d,we)))return!1}var ke=N.get(l),He=N.get(d);if(ke&&He)return ke==d&&He==l;var tt=!0;N.set(l,d),N.set(d,l);for(var Ue=M;++de<H;){we=F[de];var at=l[we],ct=d[we];if(C)var Cr=M?C(ct,at,we,d,l,N):C(at,ct,we,l,d,N);if(!(Cr===n?at===ct||A(at,ct,m,C,N):Cr)){tt=!1;break}Ue||(Ue=we=="constructor")}if(tt&&!Ue){var Yn=l.constructor,Er=d.constructor;Yn!=Er&&"constructor"in l&&"constructor"in d&&!(typeof Yn=="function"&&Yn instanceof Yn&&typeof Er=="function"&&Er instanceof Er)&&(tt=!1)}return N.delete(l),N.delete(d),tt}function Xi(l){return gm(V1(l,n,Y1),l+"")}function sm(l){return e1(l,bn,fm)}function lm(l){return e1(l,ar,D1)}var um=hf?function(l){return hf.get(l)}:Am;function Af(l){for(var d=l.name+"",m=zs[d],C=xt.call(zs,d)?m.length:0;C--;){var A=m[C],N=A.func;if(N==null||N==l)return A.name}return d}function Gs(l){var d=xt.call(T,"placeholder")?T:l;return d.placeholder}function We(){var l=T.iteratee||Om;return l=l===Om?r1:l,arguments.length?l(arguments[0],arguments[1]):l}function Rf(l,d){var m=l.__data__;return oz(d)?m[typeof d=="string"?"string":"hash"]:m.map}function cm(l){for(var d=bn(l),m=d.length;m--;){var C=d[m],A=l[C];d[m]=[C,A,$1(A)]}return d}function Ma(l,d){var m=lV(l,d);return n1(m)?m:n}function QB(l){var d=xt.call(l,Ra),m=l[Ra];try{l[Ra]=n;var C=!0}catch{}var A=af.call(l);return C&&(d?l[Ra]=m:delete l[Ra]),A}var fm=$g?function(l){return l==null?[]:(l=Ot(l),jo($g(l),function(d){return BS.call(l,d)}))}:Rm,D1=$g?function(l){for(var d=[];l;)Lo(d,fm(l)),l=uf(l);return d}:Rm,$n=qn;(Fg&&$n(new Fg(new ArrayBuffer(1)))!=lt||Jl&&$n(new Jl)!=Q||Vg&&$n(Vg.resolve())!=ve||Bs&&$n(new Bs)!=ce||eu&&$n(new eu)!=kt)&&($n=function(l){var d=qn(l),m=d==fe?l.constructor:n,C=m?Da(m):"";if(C)switch(C){case MV:return lt;case DV:return Q;case jV:return ve;case LV:return ce;case $V:return kt}return d});function JB(l,d,m){for(var C=-1,A=m.length;++C<A;){var N=m[C],M=N.size;switch(N.type){case"drop":l+=M;break;case"dropRight":d-=M;break;case"take":d=Ln(d,l+M);break;case"takeRight":l=sn(l,d-M);break}}return{start:l,end:d}}function ez(l){var d=l.match(ot);return d?d[1].split(xi):[]}function j1(l,d,m){d=zo(d,l);for(var C=-1,A=d.length,N=!1;++C<A;){var M=_i(d[C]);if(!(N=l!=null&&m(l,M)))break;l=l[M]}return N||++C!=A?N:(A=l==null?0:l.length,!!A&&jf(A)&&Zi(M,A)&&(Xe(l)||ja(l)))}function tz(l){var d=l.length,m=new l.constructor(d);return d&&typeof l[0]=="string"&&xt.call(l,"index")&&(m.index=l.index,m.input=l.input),m}function L1(l){return typeof l.constructor=="function"&&!uu(l)?Ws(uf(l)):{}}function nz(l,d,m){var C=l.constructor;switch(d){case Ct:return im(l);case Se:case q:return new C(+l);case lt:return FB(l,m);case Nt:case mn:case on:case _n:case Qt:case vn:case gr:case Un:case gt:return b1(l,m);case Q:return new C;case Ae:case Ce:return new C(l);case xe:return VB(l);case ce:return new C;case De:return BB(l)}}function rz(l,d){var m=d.length;if(!m)return l;var C=m-1;return d[C]=(m>1?"& ":"")+d[C],d=d.join(m>2?", ":" "),l.replace(Gn,`{
|
|
198
|
+
/* [wrapped with `+d+`] */
|
|
199
|
+
`)}function iz(l){return Xe(l)||ja(l)||!!(zS&&l&&l[zS])}function Zi(l,d){var m=typeof l;return d=d??Z,!!d&&(m=="number"||m!="symbol"&&vr.test(l))&&l>-1&&l%1==0&&l<d}function Kn(l,d,m){if(!Wt(m))return!1;var C=typeof d;return(C=="number"?or(m)&&Zi(d,m.length):C=="string"&&d in m)?si(m[d],l):!1}function dm(l,d){if(Xe(l))return!1;var m=typeof l;return m=="number"||m=="symbol"||m=="boolean"||l==null||Sr(l)?!0:Ca.test(l)||!yn.test(l)||d!=null&&l in Ot(d)}function oz(l){var d=typeof l;return d=="string"||d=="number"||d=="symbol"||d=="boolean"?l!=="__proto__":l===null}function pm(l){var d=Af(l),m=T[d];if(typeof m!="function"||!(d in ut.prototype))return!1;if(l===m)return!0;var C=um(m);return!!C&&l===C[0]}function az(l){return!!$S&&$S in l}var sz=rf?Qi:Im;function uu(l){var d=l&&l.constructor,m=typeof d=="function"&&d.prototype||Vs;return l===m}function $1(l){return l===l&&!Wt(l)}function F1(l,d){return function(m){return m==null?!1:m[l]===d&&(d!==n||l in Ot(m))}}function lz(l){var d=Mf(l,function(C){return m.size===c&&m.clear(),C}),m=d.cache;return d}function uz(l,d){var m=l[1],C=d[1],A=m|C,N=A<(y|w|I),M=C==I&&m==E||C==I&&m==k&&l[7].length<=d[8]||C==(I|k)&&d[7].length<=d[8]&&m==E;if(!(N||M))return l;C&y&&(l[2]=d[2],A|=m&y?0:S);var F=d[3];if(F){var H=l[3];l[3]=H?w1(H,F,d[4]):F,l[4]=H?$o(l[3],f):d[4]}return F=d[5],F&&(H=l[5],l[5]=H?S1(H,F,d[6]):F,l[6]=H?$o(l[5],f):d[6]),F=d[7],F&&(l[7]=F),C&I&&(l[8]=l[8]==null?d[8]:Ln(l[8],d[8])),l[9]==null&&(l[9]=d[9]),l[0]=d[0],l[1]=A,l}function cz(l){var d=[];if(l!=null)for(var m in Ot(l))d.push(m);return d}function fz(l){return af.call(l)}function V1(l,d,m){return d=sn(d===n?l.length-1:d,0),function(){for(var C=arguments,A=-1,N=sn(C.length-d,0),M=ne(N);++A<N;)M[A]=C[d+A];A=-1;for(var F=ne(d+1);++A<d;)F[A]=C[A];return F[d]=m(M),br(l,this,F)}}function B1(l,d){return d.length<2?l:Na(l,Hr(d,0,-1))}function dz(l,d){for(var m=l.length,C=Ln(d.length,m),A=ir(l);C--;){var N=d[C];l[C]=Zi(N,m)?A[N]:n}return l}function hm(l,d){if(!(d==="constructor"&&typeof l[d]=="function")&&d!="__proto__")return l[d]}var z1=H1(f1),cu=PV||function(l,d){return Pn.setTimeout(l,d)},gm=H1(DB);function W1(l,d,m){var C=d+"";return gm(l,rz(C,pz(ez(C),m)))}function H1(l){var d=0,m=0;return function(){var C=TV(),A=W-(C-m);if(m=C,A>0){if(++d>=D)return arguments[0]}else d=0;return l.apply(n,arguments)}}function If(l,d){var m=-1,C=l.length,A=C-1;for(d=d===n?C:d;++m<d;){var N=Zg(m,A),M=l[N];l[N]=l[m],l[m]=M}return l.length=d,l}var U1=lz(function(l){var d=[];return l.charCodeAt(0)===46&&d.push(""),l.replace(No,function(m,C,A,N){d.push(A?N.replace(Wl,"$1"):C||m)}),d});function _i(l){if(typeof l=="string"||Sr(l))return l;var d=l+"";return d=="0"&&1/l==-ee?"-0":d}function Da(l){if(l!=null){try{return of.call(l)}catch{}try{return l+""}catch{}}return""}function pz(l,d){return Vr(ye,function(m){var C="_."+m[0];d&m[1]&&!Jc(l,C)&&l.push(C)}),l.sort()}function G1(l){if(l instanceof ut)return l.clone();var d=new zr(l.__wrapped__,l.__chain__);return d.__actions__=ir(l.__actions__),d.__index__=l.__index__,d.__values__=l.__values__,d}function hz(l,d,m){(m?Kn(l,d,m):d===n)?d=1:d=sn(et(d),0);var C=l==null?0:l.length;if(!C||d<1)return[];for(var A=0,N=0,M=ne(df(C/d));A<C;)M[N++]=Hr(l,A,A+=d);return M}function gz(l){for(var d=-1,m=l==null?0:l.length,C=0,A=[];++d<m;){var N=l[d];N&&(A[C++]=N)}return A}function mz(){var l=arguments.length;if(!l)return[];for(var d=ne(l-1),m=arguments[0],C=l;C--;)d[C-1]=arguments[C];return Lo(Xe(m)?ir(m):[m],An(d,1))}var vz=rt(function(l,d){return Yt(l)?iu(l,An(d,1,Yt,!0)):[]}),yz=rt(function(l,d){var m=Ur(d);return Yt(m)&&(m=n),Yt(l)?iu(l,An(d,1,Yt,!0),We(m,2)):[]}),bz=rt(function(l,d){var m=Ur(d);return Yt(m)&&(m=n),Yt(l)?iu(l,An(d,1,Yt,!0),n,m):[]});function xz(l,d,m){var C=l==null?0:l.length;return C?(d=m||d===n?1:et(d),Hr(l,d<0?0:d,C)):[]}function wz(l,d,m){var C=l==null?0:l.length;return C?(d=m||d===n?1:et(d),d=C-d,Hr(l,0,d<0?0:d)):[]}function Sz(l,d){return l&&l.length?Sf(l,We(d,3),!0,!0):[]}function Cz(l,d){return l&&l.length?Sf(l,We(d,3),!0):[]}function Ez(l,d,m,C){var A=l==null?0:l.length;return A?(m&&typeof m!="number"&&Kn(l,d,m)&&(m=0,C=A),mB(l,d,m,C)):[]}function q1(l,d,m){var C=l==null?0:l.length;if(!C)return-1;var A=m==null?0:et(m);return A<0&&(A=sn(C+A,0)),ef(l,We(d,3),A)}function K1(l,d,m){var C=l==null?0:l.length;if(!C)return-1;var A=C-1;return m!==n&&(A=et(m),A=m<0?sn(C+A,0):Ln(A,C-1)),ef(l,We(d,3),A,!0)}function Y1(l){var d=l==null?0:l.length;return d?An(l,1):[]}function _z(l){var d=l==null?0:l.length;return d?An(l,ee):[]}function Oz(l,d){var m=l==null?0:l.length;return m?(d=d===n?1:et(d),An(l,d)):[]}function Pz(l){for(var d=-1,m=l==null?0:l.length,C={};++d<m;){var A=l[d];C[A[0]]=A[1]}return C}function X1(l){return l&&l.length?l[0]:n}function Az(l,d,m){var C=l==null?0:l.length;if(!C)return-1;var A=m==null?0:et(m);return A<0&&(A=sn(C+A,0)),js(l,d,A)}function Rz(l){var d=l==null?0:l.length;return d?Hr(l,0,-1):[]}var Iz=rt(function(l){var d=Vt(l,nm);return d.length&&d[0]===l[0]?Gg(d):[]}),Tz=rt(function(l){var d=Ur(l),m=Vt(l,nm);return d===Ur(m)?d=n:m.pop(),m.length&&m[0]===l[0]?Gg(m,We(d,2)):[]}),kz=rt(function(l){var d=Ur(l),m=Vt(l,nm);return d=typeof d=="function"?d:n,d&&m.pop(),m.length&&m[0]===l[0]?Gg(m,n,d):[]});function Nz(l,d){return l==null?"":RV.call(l,d)}function Ur(l){var d=l==null?0:l.length;return d?l[d-1]:n}function Mz(l,d,m){var C=l==null?0:l.length;if(!C)return-1;var A=C;return m!==n&&(A=et(m),A=A<0?sn(C+A,0):Ln(A,C-1)),d===d?pV(l,d,A):ef(l,IS,A,!0)}function Dz(l,d){return l&&l.length?s1(l,et(d)):n}var jz=rt(Z1);function Z1(l,d){return l&&l.length&&d&&d.length?Xg(l,d):l}function Lz(l,d,m){return l&&l.length&&d&&d.length?Xg(l,d,We(m,2)):l}function $z(l,d,m){return l&&l.length&&d&&d.length?Xg(l,d,n,m):l}var Fz=Xi(function(l,d){var m=l==null?0:l.length,C=zg(l,d);return c1(l,Vt(d,function(A){return Zi(A,m)?+A:A}).sort(x1)),C});function Vz(l,d){var m=[];if(!(l&&l.length))return m;var C=-1,A=[],N=l.length;for(d=We(d,3);++C<N;){var M=l[C];d(M,C,l)&&(m.push(M),A.push(C))}return c1(l,A),m}function mm(l){return l==null?l:NV.call(l)}function Bz(l,d,m){var C=l==null?0:l.length;return C?(m&&typeof m!="number"&&Kn(l,d,m)?(d=0,m=C):(d=d==null?0:et(d),m=m===n?C:et(m)),Hr(l,d,m)):[]}function zz(l,d){return wf(l,d)}function Wz(l,d,m){return Jg(l,d,We(m,2))}function Hz(l,d){var m=l==null?0:l.length;if(m){var C=wf(l,d);if(C<m&&si(l[C],d))return C}return-1}function Uz(l,d){return wf(l,d,!0)}function Gz(l,d,m){return Jg(l,d,We(m,2),!0)}function qz(l,d){var m=l==null?0:l.length;if(m){var C=wf(l,d,!0)-1;if(si(l[C],d))return C}return-1}function Kz(l){return l&&l.length?d1(l):[]}function Yz(l,d){return l&&l.length?d1(l,We(d,2)):[]}function Xz(l){var d=l==null?0:l.length;return d?Hr(l,1,d):[]}function Zz(l,d,m){return l&&l.length?(d=m||d===n?1:et(d),Hr(l,0,d<0?0:d)):[]}function Qz(l,d,m){var C=l==null?0:l.length;return C?(d=m||d===n?1:et(d),d=C-d,Hr(l,d<0?0:d,C)):[]}function Jz(l,d){return l&&l.length?Sf(l,We(d,3),!1,!0):[]}function e3(l,d){return l&&l.length?Sf(l,We(d,3)):[]}var t3=rt(function(l){return Bo(An(l,1,Yt,!0))}),n3=rt(function(l){var d=Ur(l);return Yt(d)&&(d=n),Bo(An(l,1,Yt,!0),We(d,2))}),r3=rt(function(l){var d=Ur(l);return d=typeof d=="function"?d:n,Bo(An(l,1,Yt,!0),n,d)});function i3(l){return l&&l.length?Bo(l):[]}function o3(l,d){return l&&l.length?Bo(l,We(d,2)):[]}function a3(l,d){return d=typeof d=="function"?d:n,l&&l.length?Bo(l,n,d):[]}function vm(l){if(!(l&&l.length))return[];var d=0;return l=jo(l,function(m){if(Yt(m))return d=sn(m.length,d),!0}),Mg(d,function(m){return Vt(l,Tg(m))})}function Q1(l,d){if(!(l&&l.length))return[];var m=vm(l);return d==null?m:Vt(m,function(C){return br(d,n,C)})}var s3=rt(function(l,d){return Yt(l)?iu(l,d):[]}),l3=rt(function(l){return tm(jo(l,Yt))}),u3=rt(function(l){var d=Ur(l);return Yt(d)&&(d=n),tm(jo(l,Yt),We(d,2))}),c3=rt(function(l){var d=Ur(l);return d=typeof d=="function"?d:n,tm(jo(l,Yt),n,d)}),f3=rt(vm);function d3(l,d){return m1(l||[],d||[],ru)}function p3(l,d){return m1(l||[],d||[],su)}var h3=rt(function(l){var d=l.length,m=d>1?l[d-1]:n;return m=typeof m=="function"?(l.pop(),m):n,Q1(l,m)});function J1(l){var d=T(l);return d.__chain__=!0,d}function g3(l,d){return d(l),l}function Tf(l,d){return d(l)}var m3=Xi(function(l){var d=l.length,m=d?l[0]:0,C=this.__wrapped__,A=function(N){return zg(N,l)};return d>1||this.__actions__.length||!(C instanceof ut)||!Zi(m)?this.thru(A):(C=C.slice(m,+m+(d?1:0)),C.__actions__.push({func:Tf,args:[A],thisArg:n}),new zr(C,this.__chain__).thru(function(N){return d&&!N.length&&N.push(n),N}))});function v3(){return J1(this)}function y3(){return new zr(this.value(),this.__chain__)}function b3(){this.__values__===n&&(this.__values__=pC(this.value()));var l=this.__index__>=this.__values__.length,d=l?n:this.__values__[this.__index__++];return{done:l,value:d}}function x3(){return this}function w3(l){for(var d,m=this;m instanceof mf;){var C=G1(m);C.__index__=0,C.__values__=n,d?A.__wrapped__=C:d=C;var A=C;m=m.__wrapped__}return A.__wrapped__=l,d}function S3(){var l=this.__wrapped__;if(l instanceof ut){var d=l;return this.__actions__.length&&(d=new ut(this)),d=d.reverse(),d.__actions__.push({func:Tf,args:[mm],thisArg:n}),new zr(d,this.__chain__)}return this.thru(mm)}function C3(){return g1(this.__wrapped__,this.__actions__)}var E3=Cf(function(l,d,m){xt.call(l,m)?++l[m]:Ki(l,m,1)});function _3(l,d,m){var C=Xe(l)?AS:gB;return m&&Kn(l,d,m)&&(d=n),C(l,We(d,3))}function O3(l,d){var m=Xe(l)?jo:QS;return m(l,We(d,3))}var P3=O1(q1),A3=O1(K1);function R3(l,d){return An(kf(l,d),1)}function I3(l,d){return An(kf(l,d),ee)}function T3(l,d,m){return m=m===n?1:et(m),An(kf(l,d),m)}function eC(l,d){var m=Xe(l)?Vr:Vo;return m(l,We(d,3))}function tC(l,d){var m=Xe(l)?XF:ZS;return m(l,We(d,3))}var k3=Cf(function(l,d,m){xt.call(l,m)?l[m].push(d):Ki(l,m,[d])});function N3(l,d,m,C){l=or(l)?l:Ks(l),m=m&&!C?et(m):0;var A=l.length;return m<0&&(m=sn(A+m,0)),Lf(l)?m<=A&&l.indexOf(d,m)>-1:!!A&&js(l,d,m)>-1}var M3=rt(function(l,d,m){var C=-1,A=typeof d=="function",N=or(l)?ne(l.length):[];return Vo(l,function(M){N[++C]=A?br(d,M,m):ou(M,d,m)}),N}),D3=Cf(function(l,d,m){Ki(l,m,d)});function kf(l,d){var m=Xe(l)?Vt:i1;return m(l,We(d,3))}function j3(l,d,m,C){return l==null?[]:(Xe(d)||(d=d==null?[]:[d]),m=C?n:m,Xe(m)||(m=m==null?[]:[m]),l1(l,d,m))}var L3=Cf(function(l,d,m){l[m?0:1].push(d)},function(){return[[],[]]});function $3(l,d,m){var C=Xe(l)?Rg:kS,A=arguments.length<3;return C(l,We(d,4),m,A,Vo)}function F3(l,d,m){var C=Xe(l)?ZF:kS,A=arguments.length<3;return C(l,We(d,4),m,A,ZS)}function V3(l,d){var m=Xe(l)?jo:QS;return m(l,Df(We(d,3)))}function B3(l){var d=Xe(l)?qS:NB;return d(l)}function z3(l,d,m){(m?Kn(l,d,m):d===n)?d=1:d=et(d);var C=Xe(l)?cB:MB;return C(l,d)}function W3(l){var d=Xe(l)?fB:jB;return d(l)}function H3(l){if(l==null)return 0;if(or(l))return Lf(l)?$s(l):l.length;var d=$n(l);return d==Q||d==ce?l.size:Kg(l).length}function U3(l,d,m){var C=Xe(l)?Ig:LB;return m&&Kn(l,d,m)&&(d=n),C(l,We(d,3))}var G3=rt(function(l,d){if(l==null)return[];var m=d.length;return m>1&&Kn(l,d[0],d[1])?d=[]:m>2&&Kn(d[0],d[1],d[2])&&(d=[d[0]]),l1(l,An(d,1),[])}),Nf=OV||function(){return Pn.Date.now()};function q3(l,d){if(typeof d!="function")throw new Br(a);return l=et(l),function(){if(--l<1)return d.apply(this,arguments)}}function nC(l,d,m){return d=m?n:d,d=l&&d==null?l.length:d,Yi(l,I,n,n,n,n,d)}function rC(l,d){var m;if(typeof d!="function")throw new Br(a);return l=et(l),function(){return--l>0&&(m=d.apply(this,arguments)),l<=1&&(d=n),m}}var ym=rt(function(l,d,m){var C=y;if(m.length){var A=$o(m,Gs(ym));C|=P}return Yi(l,C,d,m,A)}),iC=rt(function(l,d,m){var C=y|w;if(m.length){var A=$o(m,Gs(iC));C|=P}return Yi(d,C,l,m,A)});function oC(l,d,m){d=m?n:d;var C=Yi(l,E,n,n,n,n,n,d);return C.placeholder=oC.placeholder,C}function aC(l,d,m){d=m?n:d;var C=Yi(l,_,n,n,n,n,n,d);return C.placeholder=aC.placeholder,C}function sC(l,d,m){var C,A,N,M,F,H,se=0,le=!1,de=!1,we=!0;if(typeof l!="function")throw new Br(a);d=Gr(d)||0,Wt(m)&&(le=!!m.leading,de="maxWait"in m,N=de?sn(Gr(m.maxWait)||0,d):N,we="trailing"in m?!!m.trailing:we);function ke(Xt){var li=C,eo=A;return C=A=n,se=Xt,M=l.apply(eo,li),M}function He(Xt){return se=Xt,F=cu(at,d),le?ke(Xt):M}function tt(Xt){var li=Xt-H,eo=Xt-se,OC=d-li;return de?Ln(OC,N-eo):OC}function Ue(Xt){var li=Xt-H,eo=Xt-se;return H===n||li>=d||li<0||de&&eo>=N}function at(){var Xt=Nf();if(Ue(Xt))return ct(Xt);F=cu(at,tt(Xt))}function ct(Xt){return F=n,we&&C?ke(Xt):(C=A=n,M)}function Cr(){F!==n&&v1(F),se=0,C=H=A=F=n}function Yn(){return F===n?M:ct(Nf())}function Er(){var Xt=Nf(),li=Ue(Xt);if(C=arguments,A=this,H=Xt,li){if(F===n)return He(H);if(de)return v1(F),F=cu(at,d),ke(H)}return F===n&&(F=cu(at,d)),M}return Er.cancel=Cr,Er.flush=Yn,Er}var K3=rt(function(l,d){return XS(l,1,d)}),Y3=rt(function(l,d,m){return XS(l,Gr(d)||0,m)});function X3(l){return Yi(l,B)}function Mf(l,d){if(typeof l!="function"||d!=null&&typeof d!="function")throw new Br(a);var m=function(){var C=arguments,A=d?d.apply(this,C):C[0],N=m.cache;if(N.has(A))return N.get(A);var M=l.apply(this,C);return m.cache=N.set(A,M)||N,M};return m.cache=new(Mf.Cache||qi),m}Mf.Cache=qi;function Df(l){if(typeof l!="function")throw new Br(a);return function(){var d=arguments;switch(d.length){case 0:return!l.call(this);case 1:return!l.call(this,d[0]);case 2:return!l.call(this,d[0],d[1]);case 3:return!l.call(this,d[0],d[1],d[2])}return!l.apply(this,d)}}function Z3(l){return rC(2,l)}var Q3=$B(function(l,d){d=d.length==1&&Xe(d[0])?Vt(d[0],xr(We())):Vt(An(d,1),xr(We()));var m=d.length;return rt(function(C){for(var A=-1,N=Ln(C.length,m);++A<N;)C[A]=d[A].call(this,C[A]);return br(l,this,C)})}),bm=rt(function(l,d){var m=$o(d,Gs(bm));return Yi(l,P,n,d,m)}),lC=rt(function(l,d){var m=$o(d,Gs(lC));return Yi(l,R,n,d,m)}),J3=Xi(function(l,d){return Yi(l,k,n,n,n,d)});function eW(l,d){if(typeof l!="function")throw new Br(a);return d=d===n?d:et(d),rt(l,d)}function tW(l,d){if(typeof l!="function")throw new Br(a);return d=d==null?0:sn(et(d),0),rt(function(m){var C=m[d],A=Wo(m,0,d);return C&&Lo(A,C),br(l,this,A)})}function nW(l,d,m){var C=!0,A=!0;if(typeof l!="function")throw new Br(a);return Wt(m)&&(C="leading"in m?!!m.leading:C,A="trailing"in m?!!m.trailing:A),sC(l,d,{leading:C,maxWait:d,trailing:A})}function rW(l){return nC(l,1)}function iW(l,d){return bm(rm(d),l)}function oW(){if(!arguments.length)return[];var l=arguments[0];return Xe(l)?l:[l]}function aW(l){return Wr(l,h)}function sW(l,d){return d=typeof d=="function"?d:n,Wr(l,h,d)}function lW(l){return Wr(l,p|h)}function uW(l,d){return d=typeof d=="function"?d:n,Wr(l,p|h,d)}function cW(l,d){return d==null||YS(l,d,bn(d))}function si(l,d){return l===d||l!==l&&d!==d}var fW=Pf(Ug),dW=Pf(function(l,d){return l>=d}),ja=t1((function(){return arguments})())?t1:function(l){return Gt(l)&&xt.call(l,"callee")&&!BS.call(l,"callee")},Xe=ne.isArray,pW=SS?xr(SS):wB;function or(l){return l!=null&&jf(l.length)&&!Qi(l)}function Yt(l){return Gt(l)&&or(l)}function hW(l){return l===!0||l===!1||Gt(l)&&qn(l)==Se}var Ho=AV||Im,gW=CS?xr(CS):SB;function mW(l){return Gt(l)&&l.nodeType===1&&!fu(l)}function vW(l){if(l==null)return!0;if(or(l)&&(Xe(l)||typeof l=="string"||typeof l.splice=="function"||Ho(l)||qs(l)||ja(l)))return!l.length;var d=$n(l);if(d==Q||d==ce)return!l.size;if(uu(l))return!Kg(l).length;for(var m in l)if(xt.call(l,m))return!1;return!0}function yW(l,d){return au(l,d)}function bW(l,d,m){m=typeof m=="function"?m:n;var C=m?m(l,d):n;return C===n?au(l,d,n,m):!!C}function xm(l){if(!Gt(l))return!1;var d=qn(l);return d==Y||d==te||typeof l.message=="string"&&typeof l.name=="string"&&!fu(l)}function xW(l){return typeof l=="number"&&WS(l)}function Qi(l){if(!Wt(l))return!1;var d=qn(l);return d==j||d==ie||d==me||d==pe}function uC(l){return typeof l=="number"&&l==et(l)}function jf(l){return typeof l=="number"&&l>-1&&l%1==0&&l<=Z}function Wt(l){var d=typeof l;return l!=null&&(d=="object"||d=="function")}function Gt(l){return l!=null&&typeof l=="object"}var cC=ES?xr(ES):EB;function wW(l,d){return l===d||qg(l,d,cm(d))}function SW(l,d,m){return m=typeof m=="function"?m:n,qg(l,d,cm(d),m)}function CW(l){return fC(l)&&l!=+l}function EW(l){if(sz(l))throw new Ye(o);return n1(l)}function _W(l){return l===null}function OW(l){return l==null}function fC(l){return typeof l=="number"||Gt(l)&&qn(l)==Ae}function fu(l){if(!Gt(l)||qn(l)!=fe)return!1;var d=uf(l);if(d===null)return!0;var m=xt.call(d,"constructor")&&d.constructor;return typeof m=="function"&&m instanceof m&&of.call(m)==SV}var wm=_S?xr(_S):_B;function PW(l){return uC(l)&&l>=-Z&&l<=Z}var dC=OS?xr(OS):OB;function Lf(l){return typeof l=="string"||!Xe(l)&&Gt(l)&&qn(l)==Ce}function Sr(l){return typeof l=="symbol"||Gt(l)&&qn(l)==De}var qs=PS?xr(PS):PB;function AW(l){return l===n}function RW(l){return Gt(l)&&$n(l)==kt}function IW(l){return Gt(l)&&qn(l)==Dn}var TW=Pf(Yg),kW=Pf(function(l,d){return l<=d});function pC(l){if(!l)return[];if(or(l))return Lf(l)?oi(l):ir(l);if(Ql&&l[Ql])return cV(l[Ql]());var d=$n(l),m=d==Q?jg:d==ce?tf:Ks;return m(l)}function Ji(l){if(!l)return l===0?l:0;if(l=Gr(l),l===ee||l===-ee){var d=l<0?-1:1;return d*ue}return l===l?l:0}function et(l){var d=Ji(l),m=d%1;return d===d?m?d-m:d:0}function hC(l){return l?ka(et(l),0,Oe):0}function Gr(l){if(typeof l=="number")return l;if(Sr(l))return X;if(Wt(l)){var d=typeof l.valueOf=="function"?l.valueOf():l;l=Wt(d)?d+"":d}if(typeof l!="string")return l===0?l:+l;l=NS(l);var m=zc.test(l);return m||Hl.test(l)?qF(l.slice(2),m?2:8):_s.test(l)?X:+l}function gC(l){return Ei(l,ar(l))}function NW(l){return l?ka(et(l),-Z,Z):l===0?l:0}function wt(l){return l==null?"":wr(l)}var MW=Hs(function(l,d){if(uu(d)||or(d)){Ei(d,bn(d),l);return}for(var m in d)xt.call(d,m)&&ru(l,m,d[m])}),mC=Hs(function(l,d){Ei(d,ar(d),l)}),$f=Hs(function(l,d,m,C){Ei(d,ar(d),l,C)}),DW=Hs(function(l,d,m,C){Ei(d,bn(d),l,C)}),jW=Xi(zg);function LW(l,d){var m=Ws(l);return d==null?m:KS(m,d)}var $W=rt(function(l,d){l=Ot(l);var m=-1,C=d.length,A=C>2?d[2]:n;for(A&&Kn(d[0],d[1],A)&&(C=1);++m<C;)for(var N=d[m],M=ar(N),F=-1,H=M.length;++F<H;){var se=M[F],le=l[se];(le===n||si(le,Vs[se])&&!xt.call(l,se))&&(l[se]=N[se])}return l}),FW=rt(function(l){return l.push(n,N1),br(vC,n,l)});function VW(l,d){return RS(l,We(d,3),Ci)}function BW(l,d){return RS(l,We(d,3),Hg)}function zW(l,d){return l==null?l:Wg(l,We(d,3),ar)}function WW(l,d){return l==null?l:JS(l,We(d,3),ar)}function HW(l,d){return l&&Ci(l,We(d,3))}function UW(l,d){return l&&Hg(l,We(d,3))}function GW(l){return l==null?[]:bf(l,bn(l))}function qW(l){return l==null?[]:bf(l,ar(l))}function Sm(l,d,m){var C=l==null?n:Na(l,d);return C===n?m:C}function KW(l,d){return l!=null&&j1(l,d,vB)}function Cm(l,d){return l!=null&&j1(l,d,yB)}var YW=A1(function(l,d,m){d!=null&&typeof d.toString!="function"&&(d=af.call(d)),l[d]=m},_m(sr)),XW=A1(function(l,d,m){d!=null&&typeof d.toString!="function"&&(d=af.call(d)),xt.call(l,d)?l[d].push(m):l[d]=[m]},We),ZW=rt(ou);function bn(l){return or(l)?GS(l):Kg(l)}function ar(l){return or(l)?GS(l,!0):AB(l)}function QW(l,d){var m={};return d=We(d,3),Ci(l,function(C,A,N){Ki(m,d(C,A,N),C)}),m}function JW(l,d){var m={};return d=We(d,3),Ci(l,function(C,A,N){Ki(m,A,d(C,A,N))}),m}var e5=Hs(function(l,d,m){xf(l,d,m)}),vC=Hs(function(l,d,m,C){xf(l,d,m,C)}),t5=Xi(function(l,d){var m={};if(l==null)return m;var C=!1;d=Vt(d,function(N){return N=zo(N,l),C||(C=N.length>1),N}),Ei(l,lm(l),m),C&&(m=Wr(m,p|g|h,YB));for(var A=d.length;A--;)em(m,d[A]);return m});function n5(l,d){return yC(l,Df(We(d)))}var r5=Xi(function(l,d){return l==null?{}:IB(l,d)});function yC(l,d){if(l==null)return{};var m=Vt(lm(l),function(C){return[C]});return d=We(d),u1(l,m,function(C,A){return d(C,A[0])})}function i5(l,d,m){d=zo(d,l);var C=-1,A=d.length;for(A||(A=1,l=n);++C<A;){var N=l==null?n:l[_i(d[C])];N===n&&(C=A,N=m),l=Qi(N)?N.call(l):N}return l}function o5(l,d,m){return l==null?l:su(l,d,m)}function a5(l,d,m,C){return C=typeof C=="function"?C:n,l==null?l:su(l,d,m,C)}var bC=T1(bn),xC=T1(ar);function s5(l,d,m){var C=Xe(l),A=C||Ho(l)||qs(l);if(d=We(d,4),m==null){var N=l&&l.constructor;A?m=C?new N:[]:Wt(l)?m=Qi(N)?Ws(uf(l)):{}:m={}}return(A?Vr:Ci)(l,function(M,F,H){return d(m,M,F,H)}),m}function l5(l,d){return l==null?!0:em(l,d)}function u5(l,d,m){return l==null?l:h1(l,d,rm(m))}function c5(l,d,m,C){return C=typeof C=="function"?C:n,l==null?l:h1(l,d,rm(m),C)}function Ks(l){return l==null?[]:Dg(l,bn(l))}function f5(l){return l==null?[]:Dg(l,ar(l))}function d5(l,d,m){return m===n&&(m=d,d=n),m!==n&&(m=Gr(m),m=m===m?m:0),d!==n&&(d=Gr(d),d=d===d?d:0),ka(Gr(l),d,m)}function p5(l,d,m){return d=Ji(d),m===n?(m=d,d=0):m=Ji(m),l=Gr(l),bB(l,d,m)}function h5(l,d,m){if(m&&typeof m!="boolean"&&Kn(l,d,m)&&(d=m=n),m===n&&(typeof d=="boolean"?(m=d,d=n):typeof l=="boolean"&&(m=l,l=n)),l===n&&d===n?(l=0,d=1):(l=Ji(l),d===n?(d=l,l=0):d=Ji(d)),l>d){var C=l;l=d,d=C}if(m||l%1||d%1){var A=HS();return Ln(l+A*(d-l+GF("1e-"+((A+"").length-1))),d)}return Zg(l,d)}var g5=Us(function(l,d,m){return d=d.toLowerCase(),l+(m?wC(d):d)});function wC(l){return Em(wt(l).toLowerCase())}function SC(l){return l=wt(l),l&&l.replace(wi,oV).replace(bS,"")}function m5(l,d,m){l=wt(l),d=wr(d);var C=l.length;m=m===n?C:ka(et(m),0,C);var A=m;return m-=d.length,m>=0&&l.slice(m,A)==d}function v5(l){return l=wt(l),l&&Sa.test(l)?l.replace(bi,aV):l}function y5(l){return l=wt(l),l&&Cs.test(l)?l.replace(jr,"\\$&"):l}var b5=Us(function(l,d,m){return l+(m?"-":"")+d.toLowerCase()}),x5=Us(function(l,d,m){return l+(m?" ":"")+d.toLowerCase()}),w5=_1("toLowerCase");function S5(l,d,m){l=wt(l),d=et(d);var C=d?$s(l):0;if(!d||C>=d)return l;var A=(d-C)/2;return Of(pf(A),m)+l+Of(df(A),m)}function C5(l,d,m){l=wt(l),d=et(d);var C=d?$s(l):0;return d&&C<d?l+Of(d-C,m):l}function E5(l,d,m){l=wt(l),d=et(d);var C=d?$s(l):0;return d&&C<d?Of(d-C,m)+l:l}function _5(l,d,m){return m||d==null?d=0:d&&(d=+d),kV(wt(l).replace(Lr,""),d||0)}function O5(l,d,m){return(m?Kn(l,d,m):d===n)?d=1:d=et(d),Qg(wt(l),d)}function P5(){var l=arguments,d=wt(l[0]);return l.length<3?d:d.replace(l[1],l[2])}var A5=Us(function(l,d,m){return l+(m?"_":"")+d.toLowerCase()});function R5(l,d,m){return m&&typeof m!="number"&&Kn(l,d,m)&&(d=m=n),m=m===n?Oe:m>>>0,m?(l=wt(l),l&&(typeof d=="string"||d!=null&&!wm(d))&&(d=wr(d),!d&&Ls(l))?Wo(oi(l),0,m):l.split(d,m)):[]}var I5=Us(function(l,d,m){return l+(m?" ":"")+Em(d)});function T5(l,d,m){return l=wt(l),m=m==null?0:ka(et(m),0,l.length),d=wr(d),l.slice(m,m+d.length)==d}function k5(l,d,m){var C=T.templateSettings;m&&Kn(l,d,m)&&(d=n),l=wt(l),d=$f({},d,C,k1);var A=$f({},d.imports,C.imports,k1),N=bn(A),M=Dg(A,N),F,H,se=0,le=d.interpolate||Os,de="__p += '",we=Lg((d.escape||Os).source+"|"+le.source+"|"+(le===rr?Es:Os).source+"|"+(d.evaluate||Os).source+"|$","g"),ke="//# sourceURL="+(xt.call(d,"sourceURL")?(d.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++BF+"]")+`
|
|
200
|
+
`;l.replace(we,function(Ue,at,ct,Cr,Yn,Er){return ct||(ct=Cr),de+=l.slice(se,Er).replace(Wc,sV),at&&(F=!0,de+=`' +
|
|
201
|
+
__e(`+at+`) +
|
|
202
|
+
'`),Yn&&(H=!0,de+=`';
|
|
203
|
+
`+Yn+`;
|
|
204
|
+
__p += '`),ct&&(de+=`' +
|
|
205
|
+
((__t = (`+ct+`)) == null ? '' : __t) +
|
|
206
|
+
'`),se=Er+Ue.length,Ue}),de+=`';
|
|
207
|
+
`;var He=xt.call(d,"variable")&&d.variable;if(!He)de=`with (obj) {
|
|
208
|
+
`+de+`
|
|
180
209
|
}
|
|
181
|
-
`;else if(
|
|
182
|
-
`+(
|
|
183
|
-
`)+"var __t, __p = ''"+(F?", __e = _.escape":"")+(
|
|
210
|
+
`;else if(zl.test(He))throw new Ye(s);de=(H?de.replace(mt,""):de).replace(ze,"$1").replace(jn,"$1;"),de="function("+(He||"obj")+`) {
|
|
211
|
+
`+(He?"":`obj || (obj = {});
|
|
212
|
+
`)+"var __t, __p = ''"+(F?", __e = _.escape":"")+(H?`, __j = Array.prototype.join;
|
|
184
213
|
function print() { __p += __j.call(arguments, '') }
|
|
185
214
|
`:`;
|
|
186
|
-
`)+
|
|
187
|
-
}`;var Je=iS(function(){return gt(N,Ie+"return "+ce).apply(n,M)});if(Je.source=ce,im(Je))throw Je;return Je}function R5(l){return yt(l).toLowerCase()}function I5(l){return yt(l).toUpperCase()}function T5(l,f,m){if(l=yt(l),l&&(m||f===n))return p1(l);if(!l||!(f=xr(f)))return l;var S=ii(l),A=ii(f),N=h1(S,A),M=g1(S,A)+1;return $o(S,N,M).join("")}function k5(l,f,m){if(l=yt(l),l&&(m||f===n))return l.slice(0,v1(l)+1);if(!l||!(f=xr(f)))return l;var S=ii(l),A=g1(S,ii(f))+1;return $o(S,0,A).join("")}function N5(l,f,m){if(l=yt(l),l&&(m||f===n))return l.replace(jr,"");if(!l||!(f=xr(f)))return l;var S=ii(l),A=h1(S,ii(f));return $o(S,A).join("")}function M5(l,f){var m=L,S=V;if(zt(f)){var A="separator"in f?f.separator:A;m="length"in f?Qe(f.length):m,S="omission"in f?xr(f.omission):S}l=yt(l);var N=l.length;if(Ts(l)){var M=ii(l);N=M.length}if(m>=N)return l;var F=m-ks(S);if(F<1)return S;var W=M?$o(M,0,F).join(""):l.slice(0,F);if(A===n)return W+S;if(M&&(F+=W.length-F),om(A)){if(l.slice(F).search(A)){var ae,se=W;for(A.global||(A=wg(A.source,yt(Nc.exec(A))+"g")),A.lastIndex=0;ae=A.exec(se);)var ce=ae.index;W=W.slice(0,ce===n?F:ce)}}else if(l.indexOf(xr(A),F)!=F){var ye=W.lastIndexOf(A);ye>-1&&(W=W.slice(0,ye))}return W+S}function D5(l){return l=yt(l),l&&Jt.test(l)?l.replace(On,cF):l}var j5=Fs(function(l,f,m){return l+(m?" ":"")+f.toUpperCase()}),lm=oC("toUpperCase");function rS(l,f,m){return l=yt(l),f=m?n:f,f===n?oF(l)?pF(l):X$(l):l.match(f)||[]}var iS=tt(function(l,f){try{return yr(l,n,f)}catch(m){return im(m)?m:new qe(m)}}),L5=Gi(function(l,f){return Fr(f,function(m){m=Ci(m),Hi(l,m,nm(l[m],l))}),l});function $5(l){var f=l==null?0:l.length,m=Be();return l=f?Ft(l,function(S){if(typeof S[1]!="function")throw new Vr(a);return[m(S[0]),S[1]]}):[],tt(function(S){for(var A=-1;++A<f;){var N=l[A];if(yr(N[0],this,S))return yr(N[1],this,S)}})}function F5(l){return cV(zr(l,p))}function um(l){return function(){return l}}function V5(l,f){return l==null||l!==l?f:l}var B5=sC(),z5=sC(!0);function ar(l){return l}function cm(l){return L1(typeof l=="function"?l:zr(l,p))}function W5(l){return F1(zr(l,p))}function H5(l,f){return V1(l,zr(f,p))}var U5=tt(function(l,f){return function(m){return Jl(m,l,f)}}),G5=tt(function(l,f){return function(m){return Jl(l,m,f)}});function fm(l,f,m){var S=bn(f),A=ff(f,S);m==null&&!(zt(f)&&(A.length||!S.length))&&(m=f,f=l,l=this,A=ff(f,bn(f)));var N=!(zt(m)&&"chain"in m)||!!m.chain,M=Ki(l);return Fr(A,function(F){var W=f[F];l[F]=W,M&&(l.prototype[F]=function(){var ae=this.__chain__;if(N||ae){var se=l(this.__wrapped__),ce=se.__actions__=rr(this.__actions__);return ce.push({func:W,args:arguments,thisArg:l}),se.__chain__=ae,se}return W.apply(l,ko([this.value()],arguments))})}),l}function q5(){return Pn._===this&&(Pn._=bF),this}function dm(){}function K5(l){return l=Qe(l),tt(function(f){return B1(f,l)})}var Y5=Wg(Ft),X5=Wg(l1),Z5=Wg(hg);function oS(l){return Xg(l)?gg(Ci(l)):PV(l)}function Q5(l){return function(f){return l==null?n:Pa(l,f)}}var J5=uC(),eW=uC(!0);function pm(){return[]}function hm(){return!1}function tW(){return{}}function nW(){return""}function rW(){return!0}function iW(l,f){if(l=Qe(l),l<1||l>Q)return[];var m=Ae,S=Ln(l,Ae);f=Be(f),l-=Ae;for(var A=yg(S,f);++m<l;)f(m);return A}function oW(l){return Ye(l)?Ft(l,Ci):wr(l)?[l]:rr(_C(yt(l)))}function aW(l){var f=++vF;return yt(l)+f}var sW=vf(function(l,f){return l+f},0),lW=Hg("ceil"),uW=vf(function(l,f){return l/f},1),cW=Hg("floor");function fW(l){return l&&l.length?cf(l,ar,Rg):n}function dW(l,f){return l&&l.length?cf(l,Be(f,2),Rg):n}function pW(l){return f1(l,ar)}function hW(l,f){return f1(l,Be(f,2))}function gW(l){return l&&l.length?cf(l,ar,Ng):n}function mW(l,f){return l&&l.length?cf(l,Be(f,2),Ng):n}var vW=vf(function(l,f){return l*f},1),yW=Hg("round"),bW=vf(function(l,f){return l-f},0);function xW(l){return l&&l.length?vg(l,ar):0}function wW(l,f){return l&&l.length?vg(l,Be(f,2)):0}return T.after=Wz,T.ary=jC,T.assign=I3,T.assignIn=XC,T.assignInWith=If,T.assignWith=T3,T.at=k3,T.before=LC,T.bind=nm,T.bindAll=L5,T.bindKey=$C,T.castArray=t3,T.chain=NC,T.chunk=cB,T.compact=fB,T.concat=dB,T.cond=$5,T.conforms=F5,T.constant=um,T.countBy=xz,T.create=N3,T.curry=FC,T.curryRight=VC,T.debounce=BC,T.defaults=M3,T.defaultsDeep=D3,T.defer=Hz,T.delay=Uz,T.difference=pB,T.differenceBy=hB,T.differenceWith=gB,T.drop=mB,T.dropRight=vB,T.dropRightWhile=yB,T.dropWhile=bB,T.fill=xB,T.filter=Cz,T.flatMap=_z,T.flatMapDeep=Oz,T.flatMapDepth=Pz,T.flatten=RC,T.flattenDeep=wB,T.flattenDepth=CB,T.flip=Gz,T.flow=B5,T.flowRight=z5,T.fromPairs=SB,T.functions=z3,T.functionsIn=W3,T.groupBy=Az,T.initial=_B,T.intersection=OB,T.intersectionBy=PB,T.intersectionWith=AB,T.invert=U3,T.invertBy=G3,T.invokeMap=Iz,T.iteratee=cm,T.keyBy=Tz,T.keys=bn,T.keysIn=or,T.map=Ef,T.mapKeys=K3,T.mapValues=Y3,T.matches=W5,T.matchesProperty=H5,T.memoize=Of,T.merge=X3,T.mergeWith=ZC,T.method=U5,T.methodOf=G5,T.mixin=fm,T.negate=Pf,T.nthArg=K5,T.omit=Z3,T.omitBy=Q3,T.once=qz,T.orderBy=kz,T.over=Y5,T.overArgs=Kz,T.overEvery=X5,T.overSome=Z5,T.partial=rm,T.partialRight=zC,T.partition=Nz,T.pick=J3,T.pickBy=QC,T.property=oS,T.propertyOf=Q5,T.pull=kB,T.pullAll=TC,T.pullAllBy=NB,T.pullAllWith=MB,T.pullAt=DB,T.range=J5,T.rangeRight=eW,T.rearg=Yz,T.reject=jz,T.remove=jB,T.rest=Xz,T.reverse=em,T.sampleSize=$z,T.set=t5,T.setWith=n5,T.shuffle=Fz,T.slice=LB,T.sortBy=zz,T.sortedUniq=HB,T.sortedUniqBy=UB,T.split=_5,T.spread=Zz,T.tail=GB,T.take=qB,T.takeRight=KB,T.takeRightWhile=YB,T.takeWhile=XB,T.tap=fz,T.throttle=Qz,T.thru=Sf,T.toArray=qC,T.toPairs=JC,T.toPairsIn=eS,T.toPath=oW,T.toPlainObject=YC,T.transform=r5,T.unary=Jz,T.union=ZB,T.unionBy=QB,T.unionWith=JB,T.uniq=ez,T.uniqBy=tz,T.uniqWith=nz,T.unset=i5,T.unzip=tm,T.unzipWith=kC,T.update=o5,T.updateWith=a5,T.values=zs,T.valuesIn=s5,T.without=rz,T.words=rS,T.wrap=e3,T.xor=iz,T.xorBy=oz,T.xorWith=az,T.zip=sz,T.zipObject=lz,T.zipObjectDeep=uz,T.zipWith=cz,T.entries=JC,T.entriesIn=eS,T.extend=XC,T.extendWith=If,fm(T,T),T.add=sW,T.attempt=iS,T.camelCase=f5,T.capitalize=tS,T.ceil=lW,T.clamp=l5,T.clone=n3,T.cloneDeep=i3,T.cloneDeepWith=o3,T.cloneWith=r3,T.conformsTo=a3,T.deburr=nS,T.defaultTo=V5,T.divide=uW,T.endsWith=d5,T.eq=ai,T.escape=p5,T.escapeRegExp=h5,T.every=wz,T.find=Sz,T.findIndex=PC,T.findKey=j3,T.findLast=Ez,T.findLastIndex=AC,T.findLastKey=L3,T.floor=cW,T.forEach=MC,T.forEachRight=DC,T.forIn=$3,T.forInRight=F3,T.forOwn=V3,T.forOwnRight=B3,T.get=am,T.gt=s3,T.gte=l3,T.has=H3,T.hasIn=sm,T.head=IC,T.identity=ar,T.includes=Rz,T.indexOf=EB,T.inRange=u5,T.invoke=q3,T.isArguments=Ia,T.isArray=Ye,T.isArrayBuffer=u3,T.isArrayLike=ir,T.isArrayLikeObject=Kt,T.isBoolean=c3,T.isBuffer=Fo,T.isDate=f3,T.isElement=d3,T.isEmpty=p3,T.isEqual=h3,T.isEqualWith=g3,T.isError=im,T.isFinite=m3,T.isFunction=Ki,T.isInteger=WC,T.isLength=Af,T.isMap=HC,T.isMatch=v3,T.isMatchWith=y3,T.isNaN=b3,T.isNative=x3,T.isNil=C3,T.isNull=w3,T.isNumber=UC,T.isObject=zt,T.isObjectLike=Ut,T.isPlainObject=ou,T.isRegExp=om,T.isSafeInteger=S3,T.isSet=GC,T.isString=Rf,T.isSymbol=wr,T.isTypedArray=Bs,T.isUndefined=E3,T.isWeakMap=_3,T.isWeakSet=O3,T.join=RB,T.kebabCase=g5,T.last=Hr,T.lastIndexOf=IB,T.lowerCase=m5,T.lowerFirst=v5,T.lt=P3,T.lte=A3,T.max=fW,T.maxBy=dW,T.mean=pW,T.meanBy=hW,T.min=gW,T.minBy=mW,T.stubArray=pm,T.stubFalse=hm,T.stubObject=tW,T.stubString=nW,T.stubTrue=rW,T.multiply=vW,T.nth=TB,T.noConflict=q5,T.noop=dm,T.now=_f,T.pad=y5,T.padEnd=b5,T.padStart=x5,T.parseInt=w5,T.random=c5,T.reduce=Mz,T.reduceRight=Dz,T.repeat=C5,T.replace=S5,T.result=e5,T.round=yW,T.runInContext=z,T.sample=Lz,T.size=Vz,T.snakeCase=E5,T.some=Bz,T.sortedIndex=$B,T.sortedIndexBy=FB,T.sortedIndexOf=VB,T.sortedLastIndex=BB,T.sortedLastIndexBy=zB,T.sortedLastIndexOf=WB,T.startCase=O5,T.startsWith=P5,T.subtract=bW,T.sum=xW,T.sumBy=wW,T.template=A5,T.times=iW,T.toFinite=Yi,T.toInteger=Qe,T.toLength=KC,T.toLower=R5,T.toNumber=Ur,T.toSafeInteger=R3,T.toString=yt,T.toUpper=I5,T.trim=T5,T.trimEnd=k5,T.trimStart=N5,T.truncate=M5,T.unescape=D5,T.uniqueId=aW,T.upperCase=j5,T.upperFirst=lm,T.each=MC,T.eachRight=DC,T.first=IC,fm(T,(function(){var l={};return xi(T,function(f,m){vt.call(T.prototype,m)||(l[m]=f)}),l})(),{chain:!1}),T.VERSION=r,Fr(["bind","bindKey","curry","curryRight","partial","partialRight"],function(l){T[l].placeholder=T}),Fr(["drop","take"],function(l,f){at.prototype[l]=function(m){m=m===n?1:sn(Qe(m),0);var S=this.__filtered__&&!f?new at(this):this.clone();return S.__filtered__?S.__takeCount__=Ln(m,S.__takeCount__):S.__views__.push({size:Ln(m,Ae),type:l+(S.__dir__<0?"Right":"")}),S},at.prototype[l+"Right"]=function(m){return this.reverse()[l](m).reverse()}}),Fr(["filter","map","takeWhile"],function(l,f){var m=f+1,S=m==J||m==G;at.prototype[l]=function(A){var N=this.clone();return N.__iteratees__.push({iteratee:Be(A,3),type:m}),N.__filtered__=N.__filtered__||S,N}}),Fr(["head","last"],function(l,f){var m="take"+(f?"Right":"");at.prototype[l]=function(){return this[m](1).value()[0]}}),Fr(["initial","tail"],function(l,f){var m="drop"+(f?"":"Right");at.prototype[l]=function(){return this.__filtered__?new at(this):this[m](1)}}),at.prototype.compact=function(){return this.filter(ar)},at.prototype.find=function(l){return this.filter(l).head()},at.prototype.findLast=function(l){return this.reverse().find(l)},at.prototype.invokeMap=tt(function(l,f){return typeof l=="function"?new at(this):this.map(function(m){return Jl(m,l,f)})}),at.prototype.reject=function(l){return this.filter(Pf(Be(l)))},at.prototype.slice=function(l,f){l=Qe(l);var m=this;return m.__filtered__&&(l>0||f<0)?new at(m):(l<0?m=m.takeRight(-l):l&&(m=m.drop(l)),f!==n&&(f=Qe(f),m=f<0?m.dropRight(-f):m.take(f-l)),m)},at.prototype.takeRightWhile=function(l){return this.reverse().takeWhile(l).reverse()},at.prototype.toArray=function(){return this.take(Ae)},xi(at.prototype,function(l,f){var m=/^(?:filter|find|map|reject)|While$/.test(f),S=/^(?:head|last)$/.test(f),A=T[S?"take"+(f=="last"?"Right":""):f],N=S||/^find/.test(f);A&&(T.prototype[f]=function(){var M=this.__wrapped__,F=S?[1]:arguments,W=M instanceof at,ae=F[0],se=W||Ye(M),ce=function(it){var lt=A.apply(T,ko([it],F));return S&&ye?lt[0]:lt};se&&m&&typeof ae=="function"&&ae.length!=1&&(W=se=!1);var ye=this.__chain__,Ie=!!this.__actions__.length,We=N&&!ye,Je=W&&!Ie;if(!N&&se){M=Je?M:new at(this);var He=l.apply(M,F);return He.__actions__.push({func:Sf,args:[ce],thisArg:n}),new Br(He,ye)}return We&&Je?l.apply(this,F):(He=this.thru(ce),We?S?He.value()[0]:He.value():He)})}),Fr(["pop","push","shift","sort","splice","unshift"],function(l){var f=Kc[l],m=/^(?:push|sort|unshift)$/.test(l)?"tap":"thru",S=/^(?:pop|shift)$/.test(l);T.prototype[l]=function(){var A=arguments;if(S&&!this.__chain__){var N=this.value();return f.apply(Ye(N)?N:[],A)}return this[m](function(M){return f.apply(Ye(M)?M:[],A)})}}),xi(at.prototype,function(l,f){var m=T[f];if(m){var S=m.name+"";vt.call(js,S)||(js[S]=[]),js[S].push({name:f,func:m})}}),js[mf(n,w).name]=[{name:"wrapper",func:n}],at.prototype.clone=DF,at.prototype.reverse=jF,at.prototype.value=LF,T.prototype.at=dz,T.prototype.chain=pz,T.prototype.commit=hz,T.prototype.next=gz,T.prototype.plant=vz,T.prototype.reverse=yz,T.prototype.toJSON=T.prototype.valueOf=T.prototype.value=bz,T.prototype.first=T.prototype.head,Gl&&(T.prototype[Gl]=mz),T}),Ns=hF();Ca?((Ca.exports=Ns)._=Ns,cg._=Ns):Pn._=Ns}).call(zX)})(Eu,Eu.exports)),Eu.exports}var HX=WX(),UX=["dangerouslySetInnerHTML","onCopy","onCopyCapture","onCut","onCutCapture","onPaste","onPasteCapture","onCompositionEnd","onCompositionEndCapture","onCompositionStart","onCompositionStartCapture","onCompositionUpdate","onCompositionUpdateCapture","onFocus","onFocusCapture","onBlur","onBlurCapture","onChange","onChangeCapture","onBeforeInput","onBeforeInputCapture","onInput","onInputCapture","onReset","onResetCapture","onSubmit","onSubmitCapture","onInvalid","onInvalidCapture","onLoad","onLoadCapture","onError","onErrorCapture","onKeyDown","onKeyDownCapture","onKeyPress","onKeyPressCapture","onKeyUp","onKeyUpCapture","onAbort","onAbortCapture","onCanPlay","onCanPlayCapture","onCanPlayThrough","onCanPlayThroughCapture","onDurationChange","onDurationChangeCapture","onEmptied","onEmptiedCapture","onEncrypted","onEncryptedCapture","onEnded","onEndedCapture","onLoadedData","onLoadedDataCapture","onLoadedMetadata","onLoadedMetadataCapture","onLoadStart","onLoadStartCapture","onPause","onPauseCapture","onPlay","onPlayCapture","onPlaying","onPlayingCapture","onProgress","onProgressCapture","onRateChange","onRateChangeCapture","onSeeked","onSeekedCapture","onSeeking","onSeekingCapture","onStalled","onStalledCapture","onSuspend","onSuspendCapture","onTimeUpdate","onTimeUpdateCapture","onVolumeChange","onVolumeChangeCapture","onWaiting","onWaitingCapture","onAuxClick","onAuxClickCapture","onClick","onClickCapture","onContextMenu","onContextMenuCapture","onDoubleClick","onDoubleClickCapture","onDrag","onDragCapture","onDragEnd","onDragEndCapture","onDragEnter","onDragEnterCapture","onDragExit","onDragExitCapture","onDragLeave","onDragLeaveCapture","onDragOver","onDragOverCapture","onDragStart","onDragStartCapture","onDrop","onDropCapture","onMouseDown","onMouseDownCapture","onMouseEnter","onMouseLeave","onMouseMove","onMouseMoveCapture","onMouseOut","onMouseOutCapture","onMouseOver","onMouseOverCapture","onMouseUp","onMouseUpCapture","onSelect","onSelectCapture","onTouchCancel","onTouchCancelCapture","onTouchEnd","onTouchEndCapture","onTouchMove","onTouchMoveCapture","onTouchStart","onTouchStartCapture","onPointerDown","onPointerDownCapture","onPointerMove","onPointerMoveCapture","onPointerUp","onPointerUpCapture","onPointerCancel","onPointerCancelCapture","onPointerEnter","onPointerEnterCapture","onPointerLeave","onPointerLeaveCapture","onPointerOver","onPointerOverCapture","onPointerOut","onPointerOutCapture","onGotPointerCapture","onGotPointerCaptureCapture","onLostPointerCapture","onLostPointerCaptureCapture","onScroll","onScrollCapture","onWheel","onWheelCapture","onAnimationStart","onAnimationStartCapture","onAnimationEnd","onAnimationEndCapture","onAnimationIteration","onAnimationIterationCapture","onTransitionEnd","onTransitionEndCapture"];function wx(e){if(typeof e!="string")return!1;var t=UX;return t.includes(e)}var GX=["aria-activedescendant","aria-atomic","aria-autocomplete","aria-busy","aria-checked","aria-colcount","aria-colindex","aria-colspan","aria-controls","aria-current","aria-describedby","aria-details","aria-disabled","aria-errormessage","aria-expanded","aria-flowto","aria-haspopup","aria-hidden","aria-invalid","aria-keyshortcuts","aria-label","aria-labelledby","aria-level","aria-live","aria-modal","aria-multiline","aria-multiselectable","aria-orientation","aria-owns","aria-placeholder","aria-posinset","aria-pressed","aria-readonly","aria-relevant","aria-required","aria-roledescription","aria-rowcount","aria-rowindex","aria-rowspan","aria-selected","aria-setsize","aria-sort","aria-valuemax","aria-valuemin","aria-valuenow","aria-valuetext","className","color","height","id","lang","max","media","method","min","name","style","target","width","role","tabIndex","accentHeight","accumulate","additive","alignmentBaseline","allowReorder","alphabetic","amplitude","arabicForm","ascent","attributeName","attributeType","autoReverse","azimuth","baseFrequency","baselineShift","baseProfile","bbox","begin","bias","by","calcMode","capHeight","clip","clipPath","clipPathUnits","clipRule","colorInterpolation","colorInterpolationFilters","colorProfile","colorRendering","contentScriptType","contentStyleType","cursor","cx","cy","d","decelerate","descent","diffuseConstant","direction","display","divisor","dominantBaseline","dur","dx","dy","edgeMode","elevation","enableBackground","end","exponent","externalResourcesRequired","fill","fillOpacity","fillRule","filter","filterRes","filterUnits","floodColor","floodOpacity","focusable","fontFamily","fontSize","fontSizeAdjust","fontStretch","fontStyle","fontVariant","fontWeight","format","from","fx","fy","g1","g2","glyphName","glyphOrientationHorizontal","glyphOrientationVertical","glyphRef","gradientTransform","gradientUnits","hanging","horizAdvX","horizOriginX","href","ideographic","imageRendering","in2","in","intercept","k1","k2","k3","k4","k","kernelMatrix","kernelUnitLength","kerning","keyPoints","keySplines","keyTimes","lengthAdjust","letterSpacing","lightingColor","limitingConeAngle","local","markerEnd","markerHeight","markerMid","markerStart","markerUnits","markerWidth","mask","maskContentUnits","maskUnits","mathematical","mode","numOctaves","offset","opacity","operator","order","orient","orientation","origin","overflow","overlinePosition","overlineThickness","paintOrder","panose1","pathLength","patternContentUnits","patternTransform","patternUnits","pointerEvents","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","r","radius","refX","refY","renderingIntent","repeatCount","repeatDur","requiredExtensions","requiredFeatures","restart","result","rotate","rx","ry","seed","shapeRendering","slope","spacing","specularConstant","specularExponent","speed","spreadMethod","startOffset","stdDeviation","stemh","stemv","stitchTiles","stopColor","stopOpacity","strikethroughPosition","strikethroughThickness","string","stroke","strokeDasharray","strokeDashoffset","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity","strokeWidth","surfaceScale","systemLanguage","tableValues","targetX","targetY","textAnchor","textDecoration","textLength","textRendering","to","transform","u1","u2","underlinePosition","underlineThickness","unicode","unicodeBidi","unicodeRange","unitsPerEm","vAlphabetic","values","vectorEffect","version","vertAdvY","vertOriginX","vertOriginY","vHanging","vIdeographic","viewTarget","visibility","vMathematical","widths","wordSpacing","writingMode","x1","x2","x","xChannelSelector","xHeight","xlinkActuate","xlinkArcrole","xlinkHref","xlinkRole","xlinkShow","xlinkTitle","xlinkType","xmlBase","xmlLang","xmlns","xmlnsXlink","xmlSpace","y1","y2","y","yChannelSelector","z","zoomAndPan","ref","key","angle"],qX=new Set(GX);function EM(e){return typeof e!="string"?!1:qX.has(e)}function _M(e){return typeof e=="string"&&e.startsWith("data-")}function fo(e){if(typeof e!="object"||e===null)return{};var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(EM(n)||_M(n))&&(t[n]=e[n]);return t}function Cx(e){if(e==null)return null;if(j.isValidElement(e)&&typeof e.props=="object"&&e.props!==null){var t=e.props;return fo(t)}return typeof e=="object"&&!Array.isArray(e)?fo(e):null}function ti(e){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(EM(n)||_M(n)||wx(n))&&(t[n]=e[n]);return t}var KX=["children","width","height","viewBox","className","style","title","desc"];function Xy(){return Xy=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Xy.apply(null,arguments)}function YX(e,t){if(e==null)return{};var n,r,i=XX(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function XX(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var OM=j.forwardRef((e,t)=>{var{children:n,width:r,height:i,viewBox:o,className:a,style:s,title:u,desc:c}=e,d=YX(e,KX),p=o||{width:r,height:i,x:0,y:0},g=Pt("recharts-surface",a);return x.createElement("svg",Xy({},ti(d),{className:g,width:r,height:i,style:s,viewBox:"".concat(p.x," ").concat(p.y," ").concat(p.width," ").concat(p.height),ref:t}),x.createElement("title",null,u),x.createElement("desc",null,c),n)}),ZX=["children","className"];function Zy(){return Zy=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Zy.apply(null,arguments)}function QX(e,t){if(e==null)return{};var n,r,i=JX(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function JX(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var Mi=x.forwardRef((e,t)=>{var{children:n,className:r}=e,i=QX(e,ZX),o=Pt("recharts-layer",r);return x.createElement("g",Zy({className:o},ti(i),{ref:t}),n)}),eZ=j.createContext(null);function It(e){return function(){return e}}const PM=Math.cos,Qd=Math.sin,gi=Math.sqrt,Jd=Math.PI,xh=2*Jd,Qy=Math.PI,Jy=2*Qy,$a=1e-6,tZ=Jy-$a;function AM(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function nZ(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return AM;const n=10**t;return function(r){this._+=r[0];for(let i=1,o=r.length;i<o;++i)this._+=Math.round(arguments[i]*n)/n+r[i]}}class rZ{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?AM:nZ(t)}moveTo(t,n){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,n){this._append`L${this._x1=+t},${this._y1=+n}`}quadraticCurveTo(t,n,r,i){this._append`Q${+t},${+n},${this._x1=+r},${this._y1=+i}`}bezierCurveTo(t,n,r,i,o,a){this._append`C${+t},${+n},${+r},${+i},${this._x1=+o},${this._y1=+a}`}arcTo(t,n,r,i,o){if(t=+t,n=+n,r=+r,i=+i,o=+o,o<0)throw new Error(`negative radius: ${o}`);let a=this._x1,s=this._y1,u=r-t,c=i-n,d=a-t,p=s-n,g=d*d+p*p;if(this._x1===null)this._append`M${this._x1=t},${this._y1=n}`;else if(g>$a)if(!(Math.abs(p*u-c*d)>$a)||!o)this._append`L${this._x1=t},${this._y1=n}`;else{let h=r-a,v=i-s,b=u*u+c*c,y=h*h+v*v,w=Math.sqrt(b),C=Math.sqrt(g),E=o*Math.tan((Qy-Math.acos((b+g-y)/(2*w*C)))/2),_=E/C,O=E/w;Math.abs(_-1)>$a&&this._append`L${t+_*d},${n+_*p}`,this._append`A${o},${o},0,0,${+(p*h>d*v)},${this._x1=t+O*u},${this._y1=n+O*c}`}}arc(t,n,r,i,o,a){if(t=+t,n=+n,r=+r,a=!!a,r<0)throw new Error(`negative radius: ${r}`);let s=r*Math.cos(i),u=r*Math.sin(i),c=t+s,d=n+u,p=1^a,g=a?i-o:o-i;this._x1===null?this._append`M${c},${d}`:(Math.abs(this._x1-c)>$a||Math.abs(this._y1-d)>$a)&&this._append`L${c},${d}`,r&&(g<0&&(g=g%Jy+Jy),g>tZ?this._append`A${r},${r},0,1,${p},${t-s},${n-u}A${r},${r},0,1,${p},${this._x1=c},${this._y1=d}`:g>$a&&this._append`A${r},${r},0,${+(g>=Qy)},${p},${this._x1=t+r*Math.cos(o)},${this._y1=n+r*Math.sin(o)}`)}rect(t,n,r,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${r=+r}v${+i}h${-r}Z`}toString(){return this._}}function Sx(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{const r=Math.floor(n);if(!(r>=0))throw new RangeError(`invalid digits: ${n}`);t=r}return e},()=>new rZ(t)}function Ex(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function RM(e){this._context=e}RM.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 wh(e){return new RM(e)}function IM(e){return e[0]}function TM(e){return e[1]}function kM(e,t){var n=It(!0),r=null,i=wh,o=null,a=Sx(s);e=typeof e=="function"?e:e===void 0?IM:It(e),t=typeof t=="function"?t:t===void 0?TM:It(t);function s(u){var c,d=(u=Ex(u)).length,p,g=!1,h;for(r==null&&(o=i(h=a())),c=0;c<=d;++c)!(c<d&&n(p=u[c],c,u))===g&&((g=!g)?o.lineStart():o.lineEnd()),g&&o.point(+e(p,c,u),+t(p,c,u));if(h)return o=null,h+""||null}return s.x=function(u){return arguments.length?(e=typeof u=="function"?u:It(+u),s):e},s.y=function(u){return arguments.length?(t=typeof u=="function"?u:It(+u),s):t},s.defined=function(u){return arguments.length?(n=typeof u=="function"?u:It(!!u),s):n},s.curve=function(u){return arguments.length?(i=u,r!=null&&(o=i(r)),s):i},s.context=function(u){return arguments.length?(u==null?r=o=null:o=i(r=u),s):r},s}function rd(e,t,n){var r=null,i=It(!0),o=null,a=wh,s=null,u=Sx(c);e=typeof e=="function"?e:e===void 0?IM:It(+e),t=typeof t=="function"?t:It(t===void 0?0:+t),n=typeof n=="function"?n:n===void 0?TM:It(+n);function c(p){var g,h,v,b=(p=Ex(p)).length,y,w=!1,C,E=new Array(b),_=new Array(b);for(o==null&&(s=a(C=u())),g=0;g<=b;++g){if(!(g<b&&i(y=p[g],g,p))===w)if(w=!w)h=g,s.areaStart(),s.lineStart();else{for(s.lineEnd(),s.lineStart(),v=g-1;v>=h;--v)s.point(E[v],_[v]);s.lineEnd(),s.areaEnd()}w&&(E[g]=+e(y,g,p),_[g]=+t(y,g,p),s.point(r?+r(y,g,p):E[g],n?+n(y,g,p):_[g]))}if(C)return s=null,C+""||null}function d(){return kM().defined(i).curve(a).context(o)}return c.x=function(p){return arguments.length?(e=typeof p=="function"?p:It(+p),r=null,c):e},c.x0=function(p){return arguments.length?(e=typeof p=="function"?p:It(+p),c):e},c.x1=function(p){return arguments.length?(r=p==null?null:typeof p=="function"?p:It(+p),c):r},c.y=function(p){return arguments.length?(t=typeof p=="function"?p:It(+p),n=null,c):t},c.y0=function(p){return arguments.length?(t=typeof p=="function"?p:It(+p),c):t},c.y1=function(p){return arguments.length?(n=p==null?null:typeof p=="function"?p:It(+p),c):n},c.lineX0=c.lineY0=function(){return d().x(e).y(t)},c.lineY1=function(){return d().x(e).y(n)},c.lineX1=function(){return d().x(r).y(t)},c.defined=function(p){return arguments.length?(i=typeof p=="function"?p:It(!!p),c):i},c.curve=function(p){return arguments.length?(a=p,o!=null&&(s=a(o)),c):a},c.context=function(p){return arguments.length?(p==null?o=s=null:s=a(o=p),c):o},c}class NM{constructor(t,n){this._context=t,this._x=n}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(t,n){switch(t=+t,n=+n,this._point){case 0:{this._point=1,this._line?this._context.lineTo(t,n):this._context.moveTo(t,n);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,n,t,n):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+n)/2,t,this._y0,t,n);break}}this._x0=t,this._y0=n}}function iZ(e){return new NM(e,!0)}function oZ(e){return new NM(e,!1)}const _x={draw(e,t){const n=gi(t/Jd);e.moveTo(n,0),e.arc(0,0,n,0,xh)}},aZ={draw(e,t){const n=gi(t/5)/2;e.moveTo(-3*n,-n),e.lineTo(-n,-n),e.lineTo(-n,-3*n),e.lineTo(n,-3*n),e.lineTo(n,-n),e.lineTo(3*n,-n),e.lineTo(3*n,n),e.lineTo(n,n),e.lineTo(n,3*n),e.lineTo(-n,3*n),e.lineTo(-n,n),e.lineTo(-3*n,n),e.closePath()}},MM=gi(1/3),sZ=MM*2,lZ={draw(e,t){const n=gi(t/sZ),r=n*MM;e.moveTo(0,-n),e.lineTo(r,0),e.lineTo(0,n),e.lineTo(-r,0),e.closePath()}},uZ={draw(e,t){const n=gi(t),r=-n/2;e.rect(r,r,n,n)}},cZ=.8908130915292852,DM=Qd(Jd/10)/Qd(7*Jd/10),fZ=Qd(xh/10)*DM,dZ=-PM(xh/10)*DM,pZ={draw(e,t){const n=gi(t*cZ),r=fZ*n,i=dZ*n;e.moveTo(0,-n),e.lineTo(r,i);for(let o=1;o<5;++o){const a=xh*o/5,s=PM(a),u=Qd(a);e.lineTo(u*n,-s*n),e.lineTo(s*r-u*i,u*r+s*i)}e.closePath()}},Gm=gi(3),hZ={draw(e,t){const n=-gi(t/(Gm*3));e.moveTo(0,n*2),e.lineTo(-Gm*n,-n),e.lineTo(Gm*n,-n),e.closePath()}},Gr=-.5,qr=gi(3)/2,eb=1/gi(12),gZ=(eb/2+1)*3,mZ={draw(e,t){const n=gi(t/gZ),r=n/2,i=n*eb,o=r,a=n*eb+n,s=-o,u=a;e.moveTo(r,i),e.lineTo(o,a),e.lineTo(s,u),e.lineTo(Gr*r-qr*i,qr*r+Gr*i),e.lineTo(Gr*o-qr*a,qr*o+Gr*a),e.lineTo(Gr*s-qr*u,qr*s+Gr*u),e.lineTo(Gr*r+qr*i,Gr*i-qr*r),e.lineTo(Gr*o+qr*a,Gr*a-qr*o),e.lineTo(Gr*s+qr*u,Gr*u-qr*s),e.closePath()}};function vZ(e,t){let n=null,r=Sx(i);e=typeof e=="function"?e:It(e||_x),t=typeof t=="function"?t:It(t===void 0?64:+t);function i(){let o;if(n||(n=o=r()),e.apply(this,arguments).draw(n,+t.apply(this,arguments)),o)return n=null,o+""||null}return i.type=function(o){return arguments.length?(e=typeof o=="function"?o:It(o),i):e},i.size=function(o){return arguments.length?(t=typeof o=="function"?o:It(+o),i):t},i.context=function(o){return arguments.length?(n=o??null,i):n},i}function ep(){}function tp(e,t,n){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+n)/6)}function jM(e){this._context=e}jM.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:tp(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(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;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:tp(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function yZ(e){return new jM(e)}function LM(e){this._context=e}LM.prototype={areaStart:ep,areaEnd:ep,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:tp(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function bZ(e){return new LM(e)}function $M(e){this._context=e}$M.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:tp(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function xZ(e){return new $M(e)}function FM(e){this._context=e}FM.prototype={areaStart:ep,areaEnd:ep,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function wZ(e){return new FM(e)}function IE(e){return e<0?-1:1}function TE(e,t,n){var r=e._x1-e._x0,i=t-e._x1,o=(e._y1-e._y0)/(r||i<0&&-0),a=(n-e._y1)/(i||r<0&&-0),s=(o*i+a*r)/(r+i);return(IE(o)+IE(a))*Math.min(Math.abs(o),Math.abs(a),.5*Math.abs(s))||0}function kE(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function qm(e,t,n){var r=e._x0,i=e._y0,o=e._x1,a=e._y1,s=(o-r)/3;e._context.bezierCurveTo(r+s,i+s*t,o-s,a-s*n,o,a)}function np(e){this._context=e}np.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:qm(this,this._t0,kE(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var n=NaN;if(e=+e,t=+t,!(e===this._x1&&t===this._y1)){switch(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;break;case 2:this._point=3,qm(this,kE(this,n=TE(this,e,t)),n);break;default:qm(this,this._t0,n=TE(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function VM(e){this._context=new BM(e)}(VM.prototype=Object.create(np.prototype)).point=function(e,t){np.prototype.point.call(this,t,e)};function BM(e){this._context=e}BM.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,n,r,i,o){this._context.bezierCurveTo(t,e,r,n,o,i)}};function CZ(e){return new np(e)}function SZ(e){return new VM(e)}function zM(e){this._context=e}zM.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,n=e.length;if(n)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),n===2)this._context.lineTo(e[1],t[1]);else for(var r=NE(e),i=NE(t),o=0,a=1;a<n;++o,++a)this._context.bezierCurveTo(r[0][o],i[0][o],r[1][o],i[1][o],e[a],t[a]);(this._line||this._line!==0&&n===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}};function NE(e){var t,n=e.length-1,r,i=new Array(n),o=new Array(n),a=new Array(n);for(i[0]=0,o[0]=2,a[0]=e[0]+2*e[1],t=1;t<n-1;++t)i[t]=1,o[t]=4,a[t]=4*e[t]+2*e[t+1];for(i[n-1]=2,o[n-1]=7,a[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)r=i[t]/o[t-1],o[t]-=r,a[t]-=r*a[t-1];for(i[n-1]=a[n-1]/o[n-1],t=n-2;t>=0;--t)i[t]=(a[t]-i[t+1])/o[t];for(o[n-1]=(e[n]+i[n-1])/2,t=0;t<n-1;++t)o[t]=2*e[t+1]-i[t+1];return[i,o]}function EZ(e){return new zM(e)}function Ch(e,t){this._context=e,this._t=t}Ch.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,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:{if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}break}}this._x=e,this._y=t}};function _Z(e){return new Ch(e,.5)}function OZ(e){return new Ch(e,0)}function PZ(e){return new Ch(e,1)}function ts(e,t){if((a=e.length)>1)for(var n=1,r,i,o=e[t[0]],a,s=o.length;n<a;++n)for(i=o,o=e[t[n]],r=0;r<s;++r)o[r][1]+=o[r][0]=isNaN(i[r][1])?i[r][0]:i[r][1]}function tb(e){for(var t=e.length,n=new Array(t);--t>=0;)n[t]=t;return n}function AZ(e,t){return e[t]}function RZ(e){const t=[];return t.key=e,t}function IZ(){var e=It([]),t=tb,n=ts,r=AZ;function i(o){var a=Array.from(e.apply(this,arguments),RZ),s,u=a.length,c=-1,d;for(const p of o)for(s=0,++c;s<u;++s)(a[s][c]=[0,+r(p,a[s].key,c,o)]).data=p;for(s=0,d=Ex(t(a));s<u;++s)a[d[s]].index=s;return n(a,d),a}return i.keys=function(o){return arguments.length?(e=typeof o=="function"?o:It(Array.from(o)),i):e},i.value=function(o){return arguments.length?(r=typeof o=="function"?o:It(+o),i):r},i.order=function(o){return arguments.length?(t=o==null?tb:typeof o=="function"?o:It(Array.from(o)),i):t},i.offset=function(o){return arguments.length?(n=o??ts,i):n},i}function TZ(e,t){if((r=e.length)>0){for(var n,r,i=0,o=e[0].length,a;i<o;++i){for(a=n=0;n<r;++n)a+=e[n][i][1]||0;if(a)for(n=0;n<r;++n)e[n][i][1]/=a}ts(e,t)}}function kZ(e,t){if((i=e.length)>0){for(var n=0,r=e[t[0]],i,o=r.length;n<o;++n){for(var a=0,s=0;a<i;++a)s+=e[a][n][1]||0;r[n][1]+=r[n][0]=-s/2}ts(e,t)}}function NZ(e,t){if(!(!((a=e.length)>0)||!((o=(i=e[t[0]]).length)>0))){for(var n=0,r=1,i,o,a;r<o;++r){for(var s=0,u=0,c=0;s<a;++s){for(var d=e[t[s]],p=d[r][1]||0,g=d[r-1][1]||0,h=(p-g)/2,v=0;v<s;++v){var b=e[t[v]],y=b[r][1]||0,w=b[r-1][1]||0;h+=y-w}u+=p,c+=h*p}i[r-1][1]+=i[r-1][0]=n,u&&(n-=c/u)}i[r-1][1]+=i[r-1][0]=n,ts(e,t)}}var Km={},Ym={},ME;function MZ(){return ME||(ME=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return n==="__proto__"}e.isUnsafeProperty=t})(Ym)),Ym}var Xm={},DE;function WM(){return DE||(DE=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){switch(typeof n){case"number":case"symbol":return!1;case"string":return n.includes(".")||n.includes("[")||n.includes("]")}}e.isDeepKey=t})(Xm)),Xm}var Zm={},jE;function Ox(){return jE||(jE=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return typeof n=="string"||typeof n=="symbol"?n:Object.is(n?.valueOf?.(),-0)?"-0":String(n)}e.toKey=t})(Zm)),Zm}var Qm={},Jm={},LE;function DZ(){return LE||(LE=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){if(n==null)return"";if(typeof n=="string")return n;if(Array.isArray(n))return n.map(t).join(",");const r=String(n);return r==="0"&&Object.is(Number(n),-0)?"-0":r}e.toString=t})(Jm)),Jm}var $E;function Px(){return $E||($E=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=DZ(),n=Ox();function r(i){if(Array.isArray(i))return i.map(n.toKey);if(typeof i=="symbol")return[i];i=t.toString(i);const o=[],a=i.length;if(a===0)return o;let s=0,u="",c="",d=!1;for(i.charCodeAt(0)===46&&(o.push(""),s++);s<a;){const p=i[s];c?p==="\\"&&s+1<a?(s++,u+=i[s]):p===c?c="":u+=p:d?p==='"'||p==="'"?c=p:p==="]"?(d=!1,o.push(u),u=""):u+=p:p==="["?(d=!0,u&&(o.push(u),u="")):p==="."?u&&(o.push(u),u=""):u+=p,s++}return u&&o.push(u),o}e.toPath=r})(Qm)),Qm}var FE;function Ax(){return FE||(FE=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=MZ(),n=WM(),r=Ox(),i=Px();function o(s,u,c){if(s==null)return c;switch(typeof u){case"string":{if(t.isUnsafeProperty(u))return c;const d=s[u];return d===void 0?n.isDeepKey(u)?o(s,i.toPath(u),c):c:d}case"number":case"symbol":{typeof u=="number"&&(u=r.toKey(u));const d=s[u];return d===void 0?c:d}default:{if(Array.isArray(u))return a(s,u,c);if(Object.is(u?.valueOf(),-0)?u="-0":u=String(u),t.isUnsafeProperty(u))return c;const d=s[u];return d===void 0?c:d}}}function a(s,u,c){if(u.length===0)return c;let d=s;for(let p=0;p<u.length;p++){if(d==null||t.isUnsafeProperty(u[p]))return c;d=d[u[p]]}return d===void 0?c:d}e.get=o})(Km)),Km}var ev,VE;function jZ(){return VE||(VE=1,ev=Ax().get),ev}var LZ=jZ();const gl=fs(LZ);var $Z=4;function Zo(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:$Z,n=10**t,r=Math.round(e*n)/n;return Object.is(r,-0)?0:r}function qt(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return e.reduce((i,o,a)=>{var s=n[a-1];return typeof s=="string"?i+s+o:s!==void 0?i+Zo(s)+o:i+o},"")}var cr=e=>e===0?0:e>0?1:-1,Di=e=>typeof e=="number"&&e!=+e,ns=e=>typeof e=="string"&&e.indexOf("%")===e.length-1,Te=e=>(typeof e=="number"||e instanceof Number)&&!Di(e),ji=e=>Te(e)||typeof e=="string",FZ=0,zu=e=>{var t=++FZ;return"".concat(e||"").concat(t)},fi=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(!Te(t)&&typeof t!="string")return r;var o;if(ns(t)){if(n==null)return r;var a=t.indexOf("%");o=n*parseFloat(t.slice(0,a))/100}else o=+t;return Di(o)&&(o=r),i&&n!=null&&o>n&&(o=n),o},HM=e=>{if(!Array.isArray(e))return!1;for(var t=e.length,n={},r=0;r<t;r++)if(!n[String(e[r])])n[String(e[r])]=!0;else return!0;return!1};function Tn(e,t,n){return Te(e)&&Te(t)?Zo(e+n*(t-e)):t}function VZ(e,t,n){if(!(!e||!e.length))return e.find(r=>r&&(typeof t=="function"?t(r):gl(r,t))===n)}var pn=e=>e===null||typeof e>"u",dc=e=>pn(e)?e:"".concat(e.charAt(0).toUpperCase()).concat(e.slice(1));function fr(e){return e!=null}function ds(){}var BZ=["type","size","sizeType"];function nb(){return nb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},nb.apply(null,arguments)}function BE(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function zE(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?BE(Object(n),!0).forEach(function(r){zZ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):BE(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function zZ(e,t,n){return(t=WZ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function WZ(e){var t=HZ(e,"string");return typeof t=="symbol"?t:t+""}function HZ(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function UZ(e,t){if(e==null)return{};var n,r,i=GZ(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function GZ(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var UM={symbolCircle:_x,symbolCross:aZ,symbolDiamond:lZ,symbolSquare:uZ,symbolStar:pZ,symbolTriangle:hZ,symbolWye:mZ},qZ=Math.PI/180,KZ=e=>{var t="symbol".concat(dc(e));return UM[t]||_x},YZ=(e,t,n)=>{if(t==="area")return e;switch(n){case"cross":return 5*e*e/9;case"diamond":return .5*e*e/Math.sqrt(3);case"square":return e*e;case"star":{var r=18*qZ;return 1.25*e*e*(Math.tan(r)-Math.tan(r*2)*Math.tan(r)**2)}case"triangle":return Math.sqrt(3)*e*e/4;case"wye":return(21-10*Math.sqrt(3))*e*e/8;default:return Math.PI*e*e/4}},XZ=(e,t)=>{UM["symbol".concat(dc(e))]=t},GM=e=>{var{type:t="circle",size:n=64,sizeType:r="area"}=e,i=UZ(e,BZ),o=zE(zE({},i),{},{type:t,size:n,sizeType:r}),a="circle";typeof t=="string"&&(a=t);var s=()=>{var g=KZ(a),h=vZ().type(g).size(YZ(n,r,a)),v=h();if(v!==null)return v},{className:u,cx:c,cy:d}=o,p=ti(o);return Te(c)&&Te(d)&&Te(n)?x.createElement("path",nb({},p,{className:Pt("recharts-symbols",u),transform:"translate(".concat(c,", ").concat(d,")"),d:s()})):null};GM.registerSymbol=XZ;var qM=e=>"radius"in e&&"startAngle"in e&&"endAngle"in e,ZZ=(e,t)=>{if(!e||typeof e=="function"||typeof e=="boolean")return null;var n=e;if(j.isValidElement(e)&&(n=e.props),typeof n!="object"&&typeof n!="function")return null;var r={};return Object.keys(n).forEach(i=>{wx(i)&&typeof n[i]=="function"&&(r[i]=(o=>n[i](n,o)))}),r},QZ=(e,t,n)=>r=>(e(t,n,r),null),Rx=(e,t,n)=>{if(e===null||typeof e!="object"&&typeof e!="function")return null;var r=null;return Object.keys(e).forEach(i=>{var o=e[i];wx(i)&&typeof o=="function"&&(r||(r={}),r[i]=QZ(o,t,n))}),r};function WE(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function JZ(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?WE(Object(n),!0).forEach(function(r){eQ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):WE(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function eQ(e,t,n){return(t=tQ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function tQ(e){var t=nQ(e,"string");return typeof t=="symbol"?t:t+""}function nQ(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Mr(e,t){var n=JZ({},e),r=t,i=Object.keys(t),o=i.reduce((a,s)=>(a[s]===void 0&&r[s]!==void 0&&(a[s]=r[s]),a),n);return o}var tv={},nv={},HE;function rQ(){return HE||(HE=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r){const i=new Map;for(let o=0;o<n.length;o++){const a=n[o],s=r(a,o,n);i.has(s)||i.set(s,a)}return Array.from(i.values())}e.uniqBy=t})(nv)),nv}var rv={},UE;function iQ(){return UE||(UE=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r){return function(...i){return n.apply(this,i.slice(0,r))}}e.ary=t})(rv)),rv}var iv={},GE;function KM(){return GE||(GE=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return n}e.identity=t})(iv)),iv}var ov={},av={},sv={},qE;function oQ(){return qE||(qE=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return Number.isSafeInteger(n)&&n>=0}e.isLength=t})(sv)),sv}var KE;function YM(){return KE||(KE=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=oQ();function n(r){return r!=null&&typeof r!="function"&&t.isLength(r.length)}e.isArrayLike=n})(av)),av}var lv={},YE;function aQ(){return YE||(YE=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return typeof n=="object"&&n!==null}e.isObjectLike=t})(lv)),lv}var XE;function sQ(){return XE||(XE=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=YM(),n=aQ();function r(i){return n.isObjectLike(i)&&t.isArrayLike(i)}e.isArrayLikeObject=r})(ov)),ov}var uv={},cv={},ZE;function lQ(){return ZE||(ZE=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Ax();function n(r){return function(i){return t.get(i,r)}}e.property=n})(cv)),cv}var fv={},dv={},pv={},hv={},QE;function XM(){return QE||(QE=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return n!==null&&(typeof n=="object"||typeof n=="function")}e.isObject=t})(hv)),hv}var gv={},JE;function ZM(){return JE||(JE=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return n==null||typeof n!="object"&&typeof n!="function"}e.isPrimitive=t})(gv)),gv}var mv={},e_;function QM(){return e_||(e_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r){return n===r||Number.isNaN(n)&&Number.isNaN(r)}e.isEqualsSameValueZero=t})(mv)),mv}var t_;function uQ(){return t_||(t_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=XM(),n=ZM(),r=QM();function i(d,p,g){return typeof g!="function"?i(d,p,()=>{}):o(d,p,function h(v,b,y,w,C,E){const _=g(v,b,y,w,C,E);return _!==void 0?!!_:o(v,b,h,E)},new Map)}function o(d,p,g,h){if(p===d)return!0;switch(typeof p){case"object":return a(d,p,g,h);case"function":return Object.keys(p).length>0?o(d,{...p},g,h):r.isEqualsSameValueZero(d,p);default:return t.isObject(d)?typeof p=="string"?p==="":!0:r.isEqualsSameValueZero(d,p)}}function a(d,p,g,h){if(p==null)return!0;if(Array.isArray(p))return u(d,p,g,h);if(p instanceof Map)return s(d,p,g,h);if(p instanceof Set)return c(d,p,g,h);const v=Object.keys(p);if(d==null||n.isPrimitive(d))return v.length===0;if(v.length===0)return!0;if(h?.has(p))return h.get(p)===d;h?.set(p,d);try{for(let b=0;b<v.length;b++){const y=v[b];if(!n.isPrimitive(d)&&!(y in d)||p[y]===void 0&&d[y]!==void 0||p[y]===null&&d[y]!==null||!g(d[y],p[y],y,d,p,h))return!1}return!0}finally{h?.delete(p)}}function s(d,p,g,h){if(p.size===0)return!0;if(!(d instanceof Map))return!1;for(const[v,b]of p.entries()){const y=d.get(v);if(g(y,b,v,d,p,h)===!1)return!1}return!0}function u(d,p,g,h){if(p.length===0)return!0;if(!Array.isArray(d))return!1;const v=new Set;for(let b=0;b<p.length;b++){const y=p[b];let w=!1;for(let C=0;C<d.length;C++){if(v.has(C))continue;const E=d[C];let _=!1;if(g(E,y,b,d,p,h)&&(_=!0),_){v.add(C),w=!0;break}}if(!w)return!1}return!0}function c(d,p,g,h){return p.size===0?!0:d instanceof Set?u([...d],[...p],g,h):!1}e.isMatchWith=i,e.isSetMatch=c})(pv)),pv}var n_;function JM(){return n_||(n_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=uQ();function n(r,i){return t.isMatchWith(r,i,()=>{})}e.isMatch=n})(dv)),dv}var vv={},yv={},bv={},r_;function cQ(){return r_||(r_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return Object.getOwnPropertySymbols(n).filter(r=>Object.prototype.propertyIsEnumerable.call(n,r))}e.getSymbols=t})(bv)),bv}var xv={},i_;function Ix(){return i_||(i_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return n==null?n===void 0?"[object Undefined]":"[object Null]":Object.prototype.toString.call(n)}e.getTag=t})(xv)),xv}var wv={},o_;function eD(){return o_||(o_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t="[object RegExp]",n="[object String]",r="[object Number]",i="[object Boolean]",o="[object Arguments]",a="[object Symbol]",s="[object Date]",u="[object Map]",c="[object Set]",d="[object Array]",p="[object Function]",g="[object ArrayBuffer]",h="[object Object]",v="[object Error]",b="[object DataView]",y="[object Uint8Array]",w="[object Uint8ClampedArray]",C="[object Uint16Array]",E="[object Uint32Array]",_="[object BigUint64Array]",O="[object Int8Array]",R="[object Int16Array]",I="[object Int32Array]",k="[object BigInt64Array]",B="[object Float32Array]",L="[object Float64Array]";e.argumentsTag=o,e.arrayBufferTag=g,e.arrayTag=d,e.bigInt64ArrayTag=k,e.bigUint64ArrayTag=_,e.booleanTag=i,e.dataViewTag=b,e.dateTag=s,e.errorTag=v,e.float32ArrayTag=B,e.float64ArrayTag=L,e.functionTag=p,e.int16ArrayTag=R,e.int32ArrayTag=I,e.int8ArrayTag=O,e.mapTag=u,e.numberTag=r,e.objectTag=h,e.regexpTag=t,e.setTag=c,e.stringTag=n,e.symbolTag=a,e.uint16ArrayTag=C,e.uint32ArrayTag=E,e.uint8ArrayTag=y,e.uint8ClampedArrayTag=w})(wv)),wv}var Cv={},a_;function fQ(){return a_||(a_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return ArrayBuffer.isView(n)&&!(n instanceof DataView)}e.isTypedArray=t})(Cv)),Cv}var s_;function tD(){return s_||(s_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=cQ(),n=Ix(),r=eD(),i=ZM(),o=fQ();function a(d,p){return s(d,void 0,d,new Map,p)}function s(d,p,g,h=new Map,v=void 0){const b=v?.(d,p,g,h);if(b!==void 0)return b;if(i.isPrimitive(d))return d;if(h.has(d))return h.get(d);if(Array.isArray(d)){const y=new Array(d.length);h.set(d,y);for(let w=0;w<d.length;w++)y[w]=s(d[w],w,g,h,v);return Object.hasOwn(d,"index")&&(y.index=d.index),Object.hasOwn(d,"input")&&(y.input=d.input),y}if(d instanceof Date)return new Date(d.getTime());if(d instanceof RegExp){const y=new RegExp(d.source,d.flags);return y.lastIndex=d.lastIndex,y}if(d instanceof Map){const y=new Map;h.set(d,y);for(const[w,C]of d)y.set(w,s(C,w,g,h,v));return y}if(d instanceof Set){const y=new Set;h.set(d,y);for(const w of d)y.add(s(w,void 0,g,h,v));return y}if(typeof Buffer<"u"&&Buffer.isBuffer(d))return d.subarray();if(o.isTypedArray(d)){const y=new(Object.getPrototypeOf(d)).constructor(d.length);h.set(d,y);for(let w=0;w<d.length;w++)y[w]=s(d[w],w,g,h,v);return y}if(d instanceof ArrayBuffer||typeof SharedArrayBuffer<"u"&&d instanceof SharedArrayBuffer)return d.slice(0);if(d instanceof DataView){const y=new DataView(d.buffer.slice(0),d.byteOffset,d.byteLength);return h.set(d,y),u(y,d,g,h,v),y}if(typeof File<"u"&&d instanceof File){const y=new File([d],d.name,{type:d.type});return h.set(d,y),u(y,d,g,h,v),y}if(typeof Blob<"u"&&d instanceof Blob){const y=new Blob([d],{type:d.type});return h.set(d,y),u(y,d,g,h,v),y}if(d instanceof Error){const y=structuredClone(d);return h.set(d,y),y.message=d.message,y.name=d.name,y.stack=d.stack,y.cause=d.cause,y.constructor=d.constructor,u(y,d,g,h,v),y}if(d instanceof Boolean){const y=new Boolean(d.valueOf());return h.set(d,y),u(y,d,g,h,v),y}if(d instanceof Number){const y=new Number(d.valueOf());return h.set(d,y),u(y,d,g,h,v),y}if(d instanceof String){const y=new String(d.valueOf());return h.set(d,y),u(y,d,g,h,v),y}if(typeof d=="object"&&c(d)){const y=Object.create(Object.getPrototypeOf(d));return h.set(d,y),u(y,d,g,h,v),y}return d}function u(d,p,g=d,h,v){const b=[...Object.keys(p),...t.getSymbols(p)];for(let y=0;y<b.length;y++){const w=b[y],C=Object.getOwnPropertyDescriptor(d,w);(C==null||C.writable)&&(d[w]=s(p[w],w,g,h,v))}}function c(d){switch(n.getTag(d)){case r.argumentsTag:case r.arrayTag:case r.arrayBufferTag:case r.dataViewTag:case r.booleanTag:case r.dateTag:case r.float32ArrayTag:case r.float64ArrayTag:case r.int8ArrayTag:case r.int16ArrayTag:case r.int32ArrayTag:case r.mapTag:case r.numberTag:case r.objectTag:case r.regexpTag:case r.setTag:case r.stringTag:case r.symbolTag:case r.uint8ArrayTag:case r.uint8ClampedArrayTag:case r.uint16ArrayTag:case r.uint32ArrayTag:return!0;default:return!1}}e.cloneDeepWith=a,e.cloneDeepWithImpl=s,e.copyProperties=u})(yv)),yv}var l_;function dQ(){return l_||(l_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=tD();function n(r){return t.cloneDeepWithImpl(r,void 0,r,new Map,void 0)}e.cloneDeep=n})(vv)),vv}var u_;function pQ(){return u_||(u_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=JM(),n=dQ();function r(i){return i=n.cloneDeep(i),o=>t.isMatch(o,i)}e.matches=r})(fv)),fv}var Sv={},Ev={},_v={},c_;function hQ(){return c_||(c_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=tD(),n=Ix(),r=eD();function i(o,a){return t.cloneDeepWith(o,(s,u,c,d)=>{const p=a?.(s,u,c,d);if(p!==void 0)return p;if(typeof o=="object"){if(n.getTag(o)===r.objectTag&&typeof o.constructor!="function"){const g={};return d.set(o,g),t.copyProperties(g,o,c,d),g}switch(Object.prototype.toString.call(o)){case r.numberTag:case r.stringTag:case r.booleanTag:{const g=new o.constructor(o?.valueOf());return t.copyProperties(g,o),g}case r.argumentsTag:{const g={};return t.copyProperties(g,o),g.length=o.length,g[Symbol.iterator]=o[Symbol.iterator],g}default:return}}})}e.cloneDeepWith=i})(_v)),_v}var f_;function gQ(){return f_||(f_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=hQ();function n(r){return t.cloneDeepWith(r)}e.cloneDeep=n})(Ev)),Ev}var Ov={},Pv={},d_;function nD(){return d_||(d_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=/^(?:0|[1-9]\d*)$/;function n(r,i=Number.MAX_SAFE_INTEGER){switch(typeof r){case"number":return Number.isInteger(r)&&r>=0&&r<i;case"symbol":return!1;case"string":return t.test(r)}}e.isIndex=n})(Pv)),Pv}var Av={},p_;function mQ(){return p_||(p_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Ix();function n(r){return r!==null&&typeof r=="object"&&t.getTag(r)==="[object Arguments]"}e.isArguments=n})(Av)),Av}var h_;function vQ(){return h_||(h_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=WM(),n=nD(),r=mQ(),i=Px();function o(a,s){let u;if(Array.isArray(s)?u=s:typeof s=="string"&&t.isDeepKey(s)&&a?.[s]==null?u=i.toPath(s):u=[s],u.length===0)return!1;let c=a;for(let d=0;d<u.length;d++){const p=u[d];if((c==null||!Object.hasOwn(c,p))&&!((Array.isArray(c)||r.isArguments(c))&&n.isIndex(p)&&p<c.length))return!1;c=c[p]}return!0}e.has=o})(Ov)),Ov}var g_;function yQ(){return g_||(g_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=JM(),n=Ox(),r=gQ(),i=Ax(),o=vQ();function a(s,u){switch(typeof s){case"object":{Object.is(s?.valueOf(),-0)&&(s="-0");break}case"number":{s=n.toKey(s);break}}return u=r.cloneDeep(u),function(c){const d=i.get(c,s);return d===void 0?o.has(c,s):u===void 0?d===void 0:t.isMatch(d,u)}}e.matchesProperty=a})(Sv)),Sv}var m_;function bQ(){return m_||(m_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=KM(),n=lQ(),r=pQ(),i=yQ();function o(a){if(a==null)return t.identity;switch(typeof a){case"function":return a;case"object":return Array.isArray(a)&&a.length===2?i.matchesProperty(a[0],a[1]):r.matches(a);case"string":case"symbol":case"number":return n.property(a)}}e.iteratee=o})(uv)),uv}var v_;function xQ(){return v_||(v_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=rQ(),n=iQ(),r=KM(),i=sQ(),o=bQ();function a(s,u=r.identity){return i.isArrayLikeObject(s)?t.uniqBy(Array.from(s),n.ary(o.iteratee(u),1)):[]}e.uniqBy=a})(tv)),tv}var Rv,y_;function wQ(){return y_||(y_=1,Rv=xQ().uniqBy),Rv}var CQ=wQ();const b_=fs(CQ);function SQ(e,t,n){return t===!0?b_(e,n):typeof t=="function"?b_(e,t):e}var Tx=j.createContext(null),EQ=e=>e,Ht=()=>{var e=j.useContext(Tx);return e?e.store.dispatch:EQ},Od=()=>{},_Q=()=>Od,OQ=(e,t)=>e===t;function Le(e){var t=j.useContext(Tx),n=j.useMemo(()=>t?r=>{if(r!=null)return e(r)}:Od,[t,e]);return aT.useSyncExternalStoreWithSelector(t?t.subscription.addNestedSub:_Q,t?t.store.getState:Od,t?t.store.getState:Od,n,OQ)}var Iv={},Tv={},kv={},x_;function PQ(){return x_||(x_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(r){return typeof r=="symbol"?1:r===null?2:r===void 0?3:r!==r?4:0}const n=(r,i,o)=>{if(r!==i){const a=t(r),s=t(i);if(a===s&&a===0){if(r<i)return o==="desc"?1:-1;if(r>i)return o==="desc"?-1:1}return o==="desc"?s-a:a-s}return 0};e.compareValues=n})(kv)),kv}var Nv={},Mv={},w_;function rD(){return w_||(w_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return typeof n=="symbol"||n instanceof Symbol}e.isSymbol=t})(Mv)),Mv}var C_;function AQ(){return C_||(C_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=rD(),n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,r=/^\w*$/;function i(o,a){return Array.isArray(o)?!1:typeof o=="number"||typeof o=="boolean"||o==null||t.isSymbol(o)?!0:typeof o=="string"&&(r.test(o)||!n.test(o))||a!=null&&Object.hasOwn(a,o)}e.isKey=i})(Nv)),Nv}var S_;function RQ(){return S_||(S_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=PQ(),n=AQ(),r=Px();function i(o,a,s,u){if(o==null)return[];s=u?void 0:s,Array.isArray(o)||(o=Object.values(o)),Array.isArray(a)||(a=a==null?[null]:[a]),a.length===0&&(a=[null]),Array.isArray(s)||(s=s==null?[]:[s]),s=s.map(h=>String(h));const c=(h,v)=>{let b=h;for(let y=0;y<v.length&&b!=null;++y)b=b[v[y]];return b},d=(h,v)=>v==null||h==null?v:typeof h=="object"&&"key"in h?Object.hasOwn(v,h.key)?v[h.key]:c(v,h.path):typeof h=="function"?h(v):Array.isArray(h)?c(v,h):typeof v=="object"?v[h]:v,p=a.map(h=>(Array.isArray(h)&&h.length===1&&(h=h[0]),h==null||typeof h=="function"||Array.isArray(h)||n.isKey(h)?h:{key:h,path:r.toPath(h)}));return o.map(h=>({original:h,criteria:p.map(v=>d(v,h))})).slice().sort((h,v)=>{for(let b=0;b<p.length;b++){const y=t.compareValues(h.criteria[b],v.criteria[b],s[b]);if(y!==0)return y}return 0}).map(h=>h.original)}e.orderBy=i})(Tv)),Tv}var Dv={},E_;function IQ(){return E_||(E_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r=1){const i=[],o=Math.floor(r),a=(s,u)=>{for(let c=0;c<s.length;c++){const d=s[c];Array.isArray(d)&&u<o?a(d,u+1):i.push(d)}};return a(n,0),i}e.flatten=t})(Dv)),Dv}var jv={},__;function iD(){return __||(__=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=nD(),n=YM(),r=XM(),i=QM();function o(a,s,u){return r.isObject(u)&&(typeof s=="number"&&n.isArrayLike(u)&&t.isIndex(s)&&s<u.length||typeof s=="string"&&s in u)?i.isEqualsSameValueZero(u[s],a):!1}e.isIterateeCall=o})(jv)),jv}var O_;function TQ(){return O_||(O_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=RQ(),n=IQ(),r=iD();function i(o,...a){const s=a.length;return s>1&&r.isIterateeCall(o,a[0],a[1])?a=[]:s>2&&r.isIterateeCall(a[0],a[1],a[2])&&(a=[a[0]]),t.orderBy(o,n.flatten(a),["asc"])}e.sortBy=i})(Iv)),Iv}var Lv,P_;function kQ(){return P_||(P_=1,Lv=TQ().sortBy),Lv}var NQ=kQ();const Sh=fs(NQ);var oD=e=>e.legend.settings,MQ=e=>e.legend.size,DQ=e=>e.legend.payload;q([DQ,oD],(e,t)=>{var{itemSorter:n}=t,r=e.flat(1);return n?Sh(r,n):r});var id=1;function jQ(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],[t,n]=j.useState({height:0,left:0,top:0,width:0}),r=j.useCallback(i=>{if(i!=null){var o=i.getBoundingClientRect(),a={height:o.height,left:o.left,top:o.top,width:o.width};(Math.abs(a.height-t.height)>id||Math.abs(a.left-t.left)>id||Math.abs(a.top-t.top)>id||Math.abs(a.width-t.width)>id)&&n({height:a.height,left:a.left,top:a.top,width:a.width})}},[t.width,t.height,t.top,t.left,...e]);return[t,r]}function Rn(e){return`Minified Redux error #${e}; visit https://redux.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}var LQ=typeof Symbol=="function"&&Symbol.observable||"@@observable",A_=LQ,$v=()=>Math.random().toString(36).substring(7).split("").join("."),$Q={INIT:`@@redux/INIT${$v()}`,REPLACE:`@@redux/REPLACE${$v()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${$v()}`},Ga=$Q;function pc(e){if(typeof e!="object"||e===null)return!1;let t=e;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t||Object.getPrototypeOf(e)===null}function FQ(e){if(e===void 0)return"undefined";if(e===null)return"null";const t=typeof e;switch(t){case"boolean":case"string":case"number":case"symbol":case"function":return t}if(Array.isArray(e))return"array";if(zQ(e))return"date";if(BQ(e))return"error";const n=VQ(e);switch(n){case"Symbol":case"Promise":case"WeakMap":case"WeakSet":case"Map":case"Set":return n}return Object.prototype.toString.call(e).slice(8,-1).toLowerCase().replace(/\s/g,"")}function VQ(e){return typeof e.constructor=="function"?e.constructor.name:null}function BQ(e){return e instanceof Error||typeof e.message=="string"&&e.constructor&&typeof e.constructor.stackTraceLimit=="number"}function zQ(e){return e instanceof Date?!0:typeof e.toDateString=="function"&&typeof e.getDate=="function"&&typeof e.setDate=="function"}function Ho(e){let t=typeof e;return process.env.NODE_ENV!=="production"&&(t=FQ(e)),t}function aD(e,t,n){if(typeof e!="function")throw new Error(process.env.NODE_ENV==="production"?Rn(2):`Expected the root reducer to be a function. Instead, received: '${Ho(e)}'`);if(typeof t=="function"&&typeof n=="function"||typeof n=="function"&&typeof arguments[3]=="function")throw new Error(process.env.NODE_ENV==="production"?Rn(0):"It looks like you are passing several store enhancers to createStore(). This is not supported. Instead, compose them together to a single function. See https://redux.js.org/tutorials/fundamentals/part-4-store#creating-a-store-with-enhancers for an example.");if(typeof t=="function"&&typeof n>"u"&&(n=t,t=void 0),typeof n<"u"){if(typeof n!="function")throw new Error(process.env.NODE_ENV==="production"?Rn(1):`Expected the enhancer to be a function. Instead, received: '${Ho(n)}'`);return n(aD)(e,t)}let r=e,i=t,o=new Map,a=o,s=0,u=!1;function c(){a===o&&(a=new Map,o.forEach((y,w)=>{a.set(w,y)}))}function d(){if(u)throw new Error(process.env.NODE_ENV==="production"?Rn(3):"You may not call store.getState() while the reducer is executing. The reducer has already received the state as an argument. Pass it down from the top reducer instead of reading it from the store.");return i}function p(y){if(typeof y!="function")throw new Error(process.env.NODE_ENV==="production"?Rn(4):`Expected the listener to be a function. Instead, received: '${Ho(y)}'`);if(u)throw new Error(process.env.NODE_ENV==="production"?Rn(5):"You may not call store.subscribe() while the reducer is executing. If you would like to be notified after the store has been updated, subscribe from a component and invoke store.getState() in the callback to access the latest state. See https://redux.js.org/api/store#subscribelistener for more details.");let w=!0;c();const C=s++;return a.set(C,y),function(){if(w){if(u)throw new Error(process.env.NODE_ENV==="production"?Rn(6):"You may not unsubscribe from a store listener while the reducer is executing. See https://redux.js.org/api/store#subscribelistener for more details.");w=!1,c(),a.delete(C),o=null}}}function g(y){if(!pc(y))throw new Error(process.env.NODE_ENV==="production"?Rn(7):`Actions must be plain objects. Instead, the actual type was: '${Ho(y)}'. You may need to add middleware to your store setup to handle dispatching other values, such as 'redux-thunk' to handle dispatching functions. See https://redux.js.org/tutorials/fundamentals/part-4-store#middleware and https://redux.js.org/tutorials/fundamentals/part-6-async-logic#using-the-redux-thunk-middleware for examples.`);if(typeof y.type>"u")throw new Error(process.env.NODE_ENV==="production"?Rn(8):'Actions may not have an undefined "type" property. You may have misspelled an action type string constant.');if(typeof y.type!="string")throw new Error(process.env.NODE_ENV==="production"?Rn(17):`Action "type" property must be a string. Instead, the actual type was: '${Ho(y.type)}'. Value was: '${y.type}' (stringified)`);if(u)throw new Error(process.env.NODE_ENV==="production"?Rn(9):"Reducers may not dispatch actions.");try{u=!0,i=r(i,y)}finally{u=!1}return(o=a).forEach(C=>{C()}),y}function h(y){if(typeof y!="function")throw new Error(process.env.NODE_ENV==="production"?Rn(10):`Expected the nextReducer to be a function. Instead, received: '${Ho(y)}`);r=y,g({type:Ga.REPLACE})}function v(){const y=p;return{subscribe(w){if(typeof w!="object"||w===null)throw new Error(process.env.NODE_ENV==="production"?Rn(11):`Expected the observer to be an object. Instead, received: '${Ho(w)}'`);function C(){const _=w;_.next&&_.next(d())}return C(),{unsubscribe:y(C)}},[A_](){return this}}}return g({type:Ga.INIT}),{dispatch:g,subscribe:p,getState:d,replaceReducer:h,[A_]:v}}function R_(e){typeof console<"u"&&typeof console.error=="function"&&console.error(e);try{throw new Error(e)}catch{}}function WQ(e,t,n,r){const i=Object.keys(t),o=n&&n.type===Ga.INIT?"preloadedState argument passed to createStore":"previous state received by the reducer";if(i.length===0)return"Store does not have a valid reducer. Make sure the argument passed to combineReducers is an object whose values are reducers.";if(!pc(e))return`The ${o} has unexpected type of "${Ho(e)}". Expected argument to be an object with the following keys: "${i.join('", "')}"`;const a=Object.keys(e).filter(s=>!t.hasOwnProperty(s)&&!r[s]);if(a.forEach(s=>{r[s]=!0}),!(n&&n.type===Ga.REPLACE)&&a.length>0)return`Unexpected ${a.length>1?"keys":"key"} "${a.join('", "')}" found in ${o}. Expected to find one of the known reducer keys instead: "${i.join('", "')}". Unexpected keys will be ignored.`}function HQ(e){Object.keys(e).forEach(t=>{const n=e[t];if(typeof n(void 0,{type:Ga.INIT})>"u")throw new Error(process.env.NODE_ENV==="production"?Rn(12):`The slice reducer for key "${t}" returned undefined during initialization. If the state passed to the reducer is undefined, you must explicitly return the initial state. The initial state may not be undefined. If you don't want to set a value for this reducer, you can use null instead of undefined.`);if(typeof n(void 0,{type:Ga.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(process.env.NODE_ENV==="production"?Rn(13):`The slice reducer for key "${t}" returned undefined when probed with a random type. Don't try to handle '${Ga.INIT}' or other actions in "redux/*" namespace. They are considered private. Instead, you must return the current state for any unknown actions, unless it is undefined, in which case you must return the initial state, regardless of the action type. The initial state may not be undefined, but can be null.`)})}function sD(e){const t=Object.keys(e),n={};for(let a=0;a<t.length;a++){const s=t[a];process.env.NODE_ENV!=="production"&&typeof e[s]>"u"&&R_(`No reducer provided for key "${s}"`),typeof e[s]=="function"&&(n[s]=e[s])}const r=Object.keys(n);let i;process.env.NODE_ENV!=="production"&&(i={});let o;try{HQ(n)}catch(a){o=a}return function(s={},u){if(o)throw o;if(process.env.NODE_ENV!=="production"){const p=WQ(s,n,u,i);p&&R_(p)}let c=!1;const d={};for(let p=0;p<r.length;p++){const g=r[p],h=n[g],v=s[g],b=h(v,u);if(typeof b>"u"){const y=u&&u.type;throw new Error(process.env.NODE_ENV==="production"?Rn(14):`When called with an action of type ${y?`"${String(y)}"`:"(unknown type)"}, the slice reducer for key "${g}" returned undefined. To ignore an action, you must explicitly return the previous state. If you want this reducer to hold no value, you can return null instead of undefined.`)}d[g]=b,c=c||b!==v}return c=c||r.length!==Object.keys(s).length,c?d:s}}function rp(...e){return e.length===0?t=>t:e.length===1?e[0]:e.reduce((t,n)=>(...r)=>t(n(...r)))}function UQ(...e){return t=>(n,r)=>{const i=t(n,r);let o=()=>{throw new Error(process.env.NODE_ENV==="production"?Rn(15):"Dispatching while constructing your middleware is not allowed. Other middleware would not be applied to this dispatch.")};const a={getState:i.getState,dispatch:(u,...c)=>o(u,...c)},s=e.map(u=>u(a));return o=rp(...s)(i.dispatch),{...i,dispatch:o}}}function kx(e){return pc(e)&&"type"in e&&typeof e.type=="string"}var lD=Symbol.for("immer-nothing"),I_=Symbol.for("immer-draftable"),Jn=Symbol.for("immer-state"),GQ=process.env.NODE_ENV!=="production"?[function(e){return`The plugin for '${e}' has not been loaded into Immer. To enable the plugin, import and call \`enable${e}()\` when initializing your application.`},function(e){return`produce can only be called on things that are draftable: plain objects, arrays, Map, Set or classes that are marked with '[immerable]: true'. Got '${e}'`},"This object has been frozen and should not be mutated",function(e){return"Cannot use a proxy that has been revoked. Did you pass an object from inside an immer function to an async process? "+e},"An immer producer returned a new value *and* modified its draft. Either return a new value *or* modify the draft.","Immer forbids circular references","The first or second argument to `produce` must be a function","The third argument to `produce` must be a function or undefined","First argument to `createDraft` must be a plain object, an array, or an immerable object","First argument to `finishDraft` must be a draft returned by `createDraft`",function(e){return`'current' expects a draft, got: ${e}`},"Object.defineProperty() cannot be used on an Immer draft","Object.setPrototypeOf() cannot be used on an Immer draft","Immer only supports deleting array indices","Immer only supports setting array indices and the 'length' property",function(e){return`'original' expects a draft, got: ${e}`}]:[];function _r(e,...t){if(process.env.NODE_ENV!=="production"){const n=GQ[e],r=Ba(n)?n.apply(null,t):n;throw new Error(`[Immer] ${r}`)}throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var Pr=Object,ml=Pr.getPrototypeOf,ip="constructor",Eh="prototype",rb="configurable",op="enumerable",Pd="writable",Wu="value",po=e=>!!e&&!!e[Jn];function di(e){return e?uD(e)||Oh(e)||!!e[I_]||!!e[ip]?.[I_]||Ph(e)||Ah(e):!1}var qQ=Pr[Eh][ip].toString(),T_=new WeakMap;function uD(e){if(!e||!Nx(e))return!1;const t=ml(e);if(t===null||t===Pr[Eh])return!0;const n=Pr.hasOwnProperty.call(t,ip)&&t[ip];if(n===Object)return!0;if(!Ba(n))return!1;let r=T_.get(n);return r===void 0&&(r=Function.toString.call(n),T_.set(n,r)),r===qQ}function _h(e,t,n=!0){hc(e)===0?(n?Reflect.ownKeys(e):Pr.keys(e)).forEach(i=>{t(i,e[i],e)}):e.forEach((r,i)=>t(i,r,e))}function hc(e){const t=e[Jn];return t?t.type_:Oh(e)?1:Ph(e)?2:Ah(e)?3:0}var k_=(e,t,n=hc(e))=>n===2?e.has(t):Pr[Eh].hasOwnProperty.call(e,t),ib=(e,t,n=hc(e))=>n===2?e.get(t):e[t],ap=(e,t,n,r=hc(e))=>{r===2?e.set(t,n):r===3?e.add(n):e[t]=n};function KQ(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}var Oh=Array.isArray,Ph=e=>e instanceof Map,Ah=e=>e instanceof Set,Nx=e=>typeof e=="object",Ba=e=>typeof e=="function",Fv=e=>typeof e=="boolean";function YQ(e){const t=+e;return Number.isInteger(t)&&String(t)===e}var to=e=>e.copy_||e.base_,Mx=e=>e.modified_?e.copy_:e.base_;function ob(e,t){if(Ph(e))return new Map(e);if(Ah(e))return new Set(e);if(Oh(e))return Array[Eh].slice.call(e);const n=uD(e);if(t===!0||t==="class_only"&&!n){const r=Pr.getOwnPropertyDescriptors(e);delete r[Jn];let i=Reflect.ownKeys(r);for(let o=0;o<i.length;o++){const a=i[o],s=r[a];s[Pd]===!1&&(s[Pd]=!0,s[rb]=!0),(s.get||s.set)&&(r[a]={[rb]:!0,[Pd]:!0,[op]:s[op],[Wu]:e[a]})}return Pr.create(ml(e),r)}else{const r=ml(e);if(r!==null&&n)return{...e};const i=Pr.create(r);return Pr.assign(i,e)}}function Dx(e,t=!1){return Rh(e)||po(e)||!di(e)||(hc(e)>1&&Pr.defineProperties(e,{set:od,add:od,clear:od,delete:od}),Pr.freeze(e),t&&_h(e,(n,r)=>{Dx(r,!0)},!1)),e}function XQ(){_r(2)}var od={[Wu]:XQ};function Rh(e){return e===null||!Nx(e)?!0:Pr.isFrozen(e)}var sp="MapSet",ab="Patches",N_="ArrayMethods",cD={};function rs(e){const t=cD[e];return t||_r(0,e),t}var M_=e=>!!cD[e],Hu,fD=()=>Hu,ZQ=(e,t)=>({drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0,handledSet_:new Set,processedForPatches_:new Set,mapSetPlugin_:M_(sp)?rs(sp):void 0,arrayMethodsPlugin_:M_(N_)?rs(N_):void 0});function D_(e,t){t&&(e.patchPlugin_=rs(ab),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function sb(e){lb(e),e.drafts_.forEach(QQ),e.drafts_=null}function lb(e){e===Hu&&(Hu=e.parent_)}var j_=e=>Hu=ZQ(Hu,e);function QQ(e){const t=e[Jn];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function L_(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];if(e!==void 0&&e!==n){n[Jn].modified_&&(sb(t),_r(4)),di(e)&&(e=$_(t,e));const{patchPlugin_:i}=t;i&&i.generateReplacementPatches_(n[Jn].base_,e,t)}else e=$_(t,n);return JQ(t,e,!0),sb(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==lD?e:void 0}function $_(e,t){if(Rh(t))return t;const n=t[Jn];if(!n)return lp(t,e.handledSet_,e);if(!Ih(n,e))return t;if(!n.modified_)return n.base_;if(!n.finalized_){const{callbacks_:r}=n;if(r)for(;r.length>0;)r.pop()(e);hD(n,e)}return n.copy_}function JQ(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&Dx(t,n)}function dD(e){e.finalized_=!0,e.scope_.unfinalizedDrafts_--}var Ih=(e,t)=>e.scope_===t,eJ=[];function pD(e,t,n,r){const i=to(e),o=e.type_;if(r!==void 0&&ib(i,r,o)===t){ap(i,r,n,o);return}if(!e.draftLocations_){const s=e.draftLocations_=new Map;_h(i,(u,c)=>{if(po(c)){const d=s.get(c)||[];d.push(u),s.set(c,d)}})}const a=e.draftLocations_.get(t)??eJ;for(const s of a)ap(i,s,n,o)}function tJ(e,t,n){e.callbacks_.push(function(i){const o=t;if(!o||!Ih(o,i))return;i.mapSetPlugin_?.fixSetContents(o);const a=Mx(o);pD(e,o.draft_??o,a,n),hD(o,i)})}function hD(e,t){if(e.modified_&&!e.finalized_&&(e.type_===3||e.type_===1&&e.allIndicesReassigned_||(e.assigned_?.size??0)>0)){const{patchPlugin_:r}=t;if(r){const i=r.getPath(e);i&&r.generatePatches_(e,i,t)}dD(e)}}function nJ(e,t,n){const{scope_:r}=e;if(po(n)){const i=n[Jn];Ih(i,r)&&i.callbacks_.push(function(){Ad(e);const a=Mx(i);pD(e,n,a,t)})}else di(n)&&e.callbacks_.push(function(){const o=to(e);e.type_===3?o.has(n)&&lp(n,r.handledSet_,r):ib(o,t,e.type_)===n&&r.drafts_.length>1&&(e.assigned_.get(t)??!1)===!0&&e.copy_&&lp(ib(e.copy_,t,e.type_),r.handledSet_,r)})}function lp(e,t,n){return!n.immer_.autoFreeze_&&n.unfinalizedDrafts_<1||po(e)||t.has(e)||!di(e)||Rh(e)||(t.add(e),_h(e,(r,i)=>{if(po(i)){const o=i[Jn];if(Ih(o,n)){const a=Mx(o);ap(e,r,a,e.type_),dD(o)}}else di(i)&&lp(i,t,n)})),e}function rJ(e,t){const n=Oh(e),r={type_:n?1:0,scope_:t?t.scope_:fD(),modified_:!1,finalized_:!1,assigned_:void 0,parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1,callbacks_:void 0};let i=r,o=up;n&&(i=[r],o=Uu);const{revoke:a,proxy:s}=Proxy.revocable(i,o);return r.draft_=s,r.revoke_=a,[s,r]}var up={get(e,t){if(t===Jn)return e;let n=e.scope_.arrayMethodsPlugin_;const r=e.type_===1&&typeof t=="string";if(r&&n?.isArrayOperationMethod(t))return n.createMethodInterceptor(e,t);const i=to(e);if(!k_(i,t,e.type_))return iJ(e,i,t);const o=i[t];if(e.finalized_||!di(o)||r&&e.operationMethod&&n?.isMutatingArrayMethod(e.operationMethod)&&YQ(t))return o;if(o===Vv(e.base_,t)){Ad(e);const a=e.type_===1?+t:t,s=cb(e.scope_,o,e,a);return e.copy_[a]=s}return o},has(e,t){return t in to(e)},ownKeys(e){return Reflect.ownKeys(to(e))},set(e,t,n){const r=gD(to(e),t);if(r?.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){const i=Vv(to(e),t),o=i?.[Jn];if(o&&o.base_===n)return e.copy_[t]=n,e.assigned_.set(t,!1),!0;if(KQ(n,i)&&(n!==void 0||k_(e.base_,t,e.type_)))return!0;Ad(e),ub(e)}return e.copy_[t]===n&&(n!==void 0||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_.set(t,!0),nJ(e,t,n)),!0},deleteProperty(e,t){return Ad(e),Vv(e.base_,t)!==void 0||t in e.base_?(e.assigned_.set(t,!1),ub(e)):e.assigned_.delete(t),e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const n=to(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{[Pd]:!0,[rb]:e.type_!==1||t!=="length",[op]:r[op],[Wu]:n[t]}},defineProperty(){_r(11)},getPrototypeOf(e){return ml(e.base_)},setPrototypeOf(){_r(12)}},Uu={};for(let e in up){let t=up[e];Uu[e]=function(){const n=arguments;return n[0]=n[0][0],t.apply(this,n)}}Uu.deleteProperty=function(e,t){return process.env.NODE_ENV!=="production"&&isNaN(parseInt(t))&&_r(13),Uu.set.call(this,e,t,void 0)};Uu.set=function(e,t,n){return process.env.NODE_ENV!=="production"&&t!=="length"&&isNaN(parseInt(t))&&_r(14),up.set.call(this,e[0],t,n,e[0])};function Vv(e,t){const n=e[Jn];return(n?to(n):e)[t]}function iJ(e,t,n){const r=gD(t,n);return r?Wu in r?r[Wu]:r.get?.call(e.draft_):void 0}function gD(e,t){if(!(t in e))return;let n=ml(e);for(;n;){const r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=ml(n)}}function ub(e){e.modified_||(e.modified_=!0,e.parent_&&ub(e.parent_))}function Ad(e){e.copy_||(e.assigned_=new Map,e.copy_=ob(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var oJ=class{constructor(t){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.useStrictIteration_=!1,this.produce=(n,r,i)=>{if(Ba(n)&&!Ba(r)){const a=r;r=n;const s=this;return function(c=a,...d){return s.produce(c,p=>r.call(this,p,...d))}}Ba(r)||_r(6),i!==void 0&&!Ba(i)&&_r(7);let o;if(di(n)){const a=j_(this),s=cb(a,n,void 0);let u=!0;try{o=r(s),u=!1}finally{u?sb(a):lb(a)}return D_(a,i),L_(o,a)}else if(!n||!Nx(n)){if(o=r(n),o===void 0&&(o=n),o===lD&&(o=void 0),this.autoFreeze_&&Dx(o,!0),i){const a=[],s=[];rs(ab).generateReplacementPatches_(n,o,{patches_:a,inversePatches_:s}),i(a,s)}return o}else _r(1,n)},this.produceWithPatches=(n,r)=>{if(Ba(n))return(s,...u)=>this.produceWithPatches(s,c=>n(c,...u));let i,o;return[this.produce(n,r,(s,u)=>{i=s,o=u}),i,o]},Fv(t?.autoFreeze)&&this.setAutoFreeze(t.autoFreeze),Fv(t?.useStrictShallowCopy)&&this.setUseStrictShallowCopy(t.useStrictShallowCopy),Fv(t?.useStrictIteration)&&this.setUseStrictIteration(t.useStrictIteration)}createDraft(t){di(t)||_r(8),po(t)&&(t=Qr(t));const n=j_(this),r=cb(n,t,void 0);return r[Jn].isManual_=!0,lb(n),r}finishDraft(t,n){const r=t&&t[Jn];(!r||!r.isManual_)&&_r(9);const{scope_:i}=r;return D_(i,n),L_(void 0,i)}setAutoFreeze(t){this.autoFreeze_=t}setUseStrictShallowCopy(t){this.useStrictShallowCopy_=t}setUseStrictIteration(t){this.useStrictIteration_=t}shouldUseStrictIteration(){return this.useStrictIteration_}applyPatches(t,n){let r;for(r=n.length-1;r>=0;r--){const o=n[r];if(o.path.length===0&&o.op==="replace"){t=o.value;break}}r>-1&&(n=n.slice(r+1));const i=rs(ab).applyPatches_;return po(t)?i(t,n):this.produce(t,o=>i(o,n))}};function cb(e,t,n,r){const[i,o]=Ph(t)?rs(sp).proxyMap_(t,n):Ah(t)?rs(sp).proxySet_(t,n):rJ(t,n);return(n?.scope_??fD()).drafts_.push(i),o.callbacks_=n?.callbacks_??[],o.key_=r,n&&r!==void 0?tJ(n,o,r):o.callbacks_.push(function(u){u.mapSetPlugin_?.fixSetContents(o);const{patchPlugin_:c}=u;o.modified_&&c&&c.generatePatches_(o,[],u)}),i}function Qr(e){return po(e)||_r(10,e),mD(e)}function mD(e){if(!di(e)||Rh(e))return e;const t=e[Jn];let n,r=!0;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=ob(e,t.scope_.immer_.useStrictShallowCopy_),r=t.scope_.immer_.shouldUseStrictIteration()}else n=ob(e,!0);return _h(n,(i,o)=>{ap(n,i,mD(o))},r),t&&(t.finalized_=!1),n}var aJ=new oJ,vD=aJ.produce;function yD(e){return({dispatch:n,getState:r})=>i=>o=>typeof o=="function"?o(n,r,e):i(o)}var sJ=yD(),lJ=yD,uJ=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?rp:rp.apply(null,arguments)},cJ=e=>e&&typeof e.match=="function";function Tr(e,t){function n(...r){if(t){let i=t(...r);if(!i)throw new Error(process.env.NODE_ENV==="production"?mt(0):"prepareAction did not return an object");return{type:e,payload:i.payload,..."meta"in i&&{meta:i.meta},..."error"in i&&{error:i.error}}}return{type:e,payload:r[0]}}return n.toString=()=>`${e}`,n.type=e,n.match=r=>kx(r)&&r.type===e,n}function fJ(e){return typeof e=="function"&&"type"in e&&cJ(e)}function dJ(e){const t=e?`${e}`.split("/"):[],n=t[t.length-1]||"actionCreator";return`Detected an action creator with type "${e||"unknown"}" being dispatched.
|
|
188
|
-
Make sure you're calling the action creator before dispatching, i.e. \`dispatch(${n}())\` instead of \`dispatch(${n})\`. This is necessary even if the action has no payload.`}function
|
|
215
|
+
`)+de+`return __p
|
|
216
|
+
}`;var tt=EC(function(){return vt(N,ke+"return "+de).apply(n,M)});if(tt.source=de,xm(tt))throw tt;return tt}function N5(l){return wt(l).toLowerCase()}function M5(l){return wt(l).toUpperCase()}function D5(l,d,m){if(l=wt(l),l&&(m||d===n))return NS(l);if(!l||!(d=wr(d)))return l;var C=oi(l),A=oi(d),N=MS(C,A),M=DS(C,A)+1;return Wo(C,N,M).join("")}function j5(l,d,m){if(l=wt(l),l&&(m||d===n))return l.slice(0,LS(l)+1);if(!l||!(d=wr(d)))return l;var C=oi(l),A=DS(C,oi(d))+1;return Wo(C,0,A).join("")}function L5(l,d,m){if(l=wt(l),l&&(m||d===n))return l.replace(Lr,"");if(!l||!(d=wr(d)))return l;var C=oi(l),A=MS(C,oi(d));return Wo(C,A).join("")}function $5(l,d){var m=L,C=V;if(Wt(d)){var A="separator"in d?d.separator:A;m="length"in d?et(d.length):m,C="omission"in d?wr(d.omission):C}l=wt(l);var N=l.length;if(Ls(l)){var M=oi(l);N=M.length}if(m>=N)return l;var F=m-$s(C);if(F<1)return C;var H=M?Wo(M,0,F).join(""):l.slice(0,F);if(A===n)return H+C;if(M&&(F+=H.length-F),wm(A)){if(l.slice(F).search(A)){var se,le=H;for(A.global||(A=Lg(A.source,wt(Bc.exec(A))+"g")),A.lastIndex=0;se=A.exec(le);)var de=se.index;H=H.slice(0,de===n?F:de)}}else if(l.indexOf(wr(A),F)!=F){var we=H.lastIndexOf(A);we>-1&&(H=H.slice(0,we))}return H+C}function F5(l){return l=wt(l),l&&Jt.test(l)?l.replace(On,hV):l}var V5=Us(function(l,d,m){return l+(m?" ":"")+d.toUpperCase()}),Em=_1("toUpperCase");function CC(l,d,m){return l=wt(l),d=m?n:d,d===n?uV(l)?vV(l):eV(l):l.match(d)||[]}var EC=rt(function(l,d){try{return br(l,n,d)}catch(m){return xm(m)?m:new Ye(m)}}),B5=Xi(function(l,d){return Vr(d,function(m){m=_i(m),Ki(l,m,ym(l[m],l))}),l});function z5(l){var d=l==null?0:l.length,m=We();return l=d?Vt(l,function(C){if(typeof C[1]!="function")throw new Br(a);return[m(C[0]),C[1]]}):[],rt(function(C){for(var A=-1;++A<d;){var N=l[A];if(br(N[0],this,C))return br(N[1],this,C)}})}function W5(l){return hB(Wr(l,p))}function _m(l){return function(){return l}}function H5(l,d){return l==null||l!==l?d:l}var U5=P1(),G5=P1(!0);function sr(l){return l}function Om(l){return r1(typeof l=="function"?l:Wr(l,p))}function q5(l){return o1(Wr(l,p))}function K5(l,d){return a1(l,Wr(d,p))}var Y5=rt(function(l,d){return function(m){return ou(m,l,d)}}),X5=rt(function(l,d){return function(m){return ou(l,m,d)}});function Pm(l,d,m){var C=bn(d),A=bf(d,C);m==null&&!(Wt(d)&&(A.length||!C.length))&&(m=d,d=l,l=this,A=bf(d,bn(d)));var N=!(Wt(m)&&"chain"in m)||!!m.chain,M=Qi(l);return Vr(A,function(F){var H=d[F];l[F]=H,M&&(l.prototype[F]=function(){var se=this.__chain__;if(N||se){var le=l(this.__wrapped__),de=le.__actions__=ir(this.__actions__);return de.push({func:H,args:arguments,thisArg:l}),le.__chain__=se,le}return H.apply(l,Lo([this.value()],arguments))})}),l}function Z5(){return Pn._===this&&(Pn._=CV),this}function Am(){}function Q5(l){return l=et(l),rt(function(d){return s1(d,l)})}var J5=om(Vt),eH=om(AS),tH=om(Ig);function _C(l){return dm(l)?Tg(_i(l)):TB(l)}function nH(l){return function(d){return l==null?n:Na(l,d)}}var rH=R1(),iH=R1(!0);function Rm(){return[]}function Im(){return!1}function oH(){return{}}function aH(){return""}function sH(){return!0}function lH(l,d){if(l=et(l),l<1||l>Z)return[];var m=Oe,C=Ln(l,Oe);d=We(d),l-=Oe;for(var A=Mg(C,d);++m<l;)d(m);return A}function uH(l){return Xe(l)?Vt(l,_i):Sr(l)?[l]:ir(U1(wt(l)))}function cH(l){var d=++wV;return wt(l)+d}var fH=_f(function(l,d){return l+d},0),dH=am("ceil"),pH=_f(function(l,d){return l/d},1),hH=am("floor");function gH(l){return l&&l.length?yf(l,sr,Ug):n}function mH(l,d){return l&&l.length?yf(l,We(d,2),Ug):n}function vH(l){return TS(l,sr)}function yH(l,d){return TS(l,We(d,2))}function bH(l){return l&&l.length?yf(l,sr,Yg):n}function xH(l,d){return l&&l.length?yf(l,We(d,2),Yg):n}var wH=_f(function(l,d){return l*d},1),SH=am("round"),CH=_f(function(l,d){return l-d},0);function EH(l){return l&&l.length?Ng(l,sr):0}function _H(l,d){return l&&l.length?Ng(l,We(d,2)):0}return T.after=q3,T.ary=nC,T.assign=MW,T.assignIn=mC,T.assignInWith=$f,T.assignWith=DW,T.at=jW,T.before=rC,T.bind=ym,T.bindAll=B5,T.bindKey=iC,T.castArray=oW,T.chain=J1,T.chunk=hz,T.compact=gz,T.concat=mz,T.cond=z5,T.conforms=W5,T.constant=_m,T.countBy=E3,T.create=LW,T.curry=oC,T.curryRight=aC,T.debounce=sC,T.defaults=$W,T.defaultsDeep=FW,T.defer=K3,T.delay=Y3,T.difference=vz,T.differenceBy=yz,T.differenceWith=bz,T.drop=xz,T.dropRight=wz,T.dropRightWhile=Sz,T.dropWhile=Cz,T.fill=Ez,T.filter=O3,T.flatMap=R3,T.flatMapDeep=I3,T.flatMapDepth=T3,T.flatten=Y1,T.flattenDeep=_z,T.flattenDepth=Oz,T.flip=X3,T.flow=U5,T.flowRight=G5,T.fromPairs=Pz,T.functions=GW,T.functionsIn=qW,T.groupBy=k3,T.initial=Rz,T.intersection=Iz,T.intersectionBy=Tz,T.intersectionWith=kz,T.invert=YW,T.invertBy=XW,T.invokeMap=M3,T.iteratee=Om,T.keyBy=D3,T.keys=bn,T.keysIn=ar,T.map=kf,T.mapKeys=QW,T.mapValues=JW,T.matches=q5,T.matchesProperty=K5,T.memoize=Mf,T.merge=e5,T.mergeWith=vC,T.method=Y5,T.methodOf=X5,T.mixin=Pm,T.negate=Df,T.nthArg=Q5,T.omit=t5,T.omitBy=n5,T.once=Z3,T.orderBy=j3,T.over=J5,T.overArgs=Q3,T.overEvery=eH,T.overSome=tH,T.partial=bm,T.partialRight=lC,T.partition=L3,T.pick=r5,T.pickBy=yC,T.property=_C,T.propertyOf=nH,T.pull=jz,T.pullAll=Z1,T.pullAllBy=Lz,T.pullAllWith=$z,T.pullAt=Fz,T.range=rH,T.rangeRight=iH,T.rearg=J3,T.reject=V3,T.remove=Vz,T.rest=eW,T.reverse=mm,T.sampleSize=z3,T.set=o5,T.setWith=a5,T.shuffle=W3,T.slice=Bz,T.sortBy=G3,T.sortedUniq=Kz,T.sortedUniqBy=Yz,T.split=R5,T.spread=tW,T.tail=Xz,T.take=Zz,T.takeRight=Qz,T.takeRightWhile=Jz,T.takeWhile=e3,T.tap=g3,T.throttle=nW,T.thru=Tf,T.toArray=pC,T.toPairs=bC,T.toPairsIn=xC,T.toPath=uH,T.toPlainObject=gC,T.transform=s5,T.unary=rW,T.union=t3,T.unionBy=n3,T.unionWith=r3,T.uniq=i3,T.uniqBy=o3,T.uniqWith=a3,T.unset=l5,T.unzip=vm,T.unzipWith=Q1,T.update=u5,T.updateWith=c5,T.values=Ks,T.valuesIn=f5,T.without=s3,T.words=CC,T.wrap=iW,T.xor=l3,T.xorBy=u3,T.xorWith=c3,T.zip=f3,T.zipObject=d3,T.zipObjectDeep=p3,T.zipWith=h3,T.entries=bC,T.entriesIn=xC,T.extend=mC,T.extendWith=$f,Pm(T,T),T.add=fH,T.attempt=EC,T.camelCase=g5,T.capitalize=wC,T.ceil=dH,T.clamp=d5,T.clone=aW,T.cloneDeep=lW,T.cloneDeepWith=uW,T.cloneWith=sW,T.conformsTo=cW,T.deburr=SC,T.defaultTo=H5,T.divide=pH,T.endsWith=m5,T.eq=si,T.escape=v5,T.escapeRegExp=y5,T.every=_3,T.find=P3,T.findIndex=q1,T.findKey=VW,T.findLast=A3,T.findLastIndex=K1,T.findLastKey=BW,T.floor=hH,T.forEach=eC,T.forEachRight=tC,T.forIn=zW,T.forInRight=WW,T.forOwn=HW,T.forOwnRight=UW,T.get=Sm,T.gt=fW,T.gte=dW,T.has=KW,T.hasIn=Cm,T.head=X1,T.identity=sr,T.includes=N3,T.indexOf=Az,T.inRange=p5,T.invoke=ZW,T.isArguments=ja,T.isArray=Xe,T.isArrayBuffer=pW,T.isArrayLike=or,T.isArrayLikeObject=Yt,T.isBoolean=hW,T.isBuffer=Ho,T.isDate=gW,T.isElement=mW,T.isEmpty=vW,T.isEqual=yW,T.isEqualWith=bW,T.isError=xm,T.isFinite=xW,T.isFunction=Qi,T.isInteger=uC,T.isLength=jf,T.isMap=cC,T.isMatch=wW,T.isMatchWith=SW,T.isNaN=CW,T.isNative=EW,T.isNil=OW,T.isNull=_W,T.isNumber=fC,T.isObject=Wt,T.isObjectLike=Gt,T.isPlainObject=fu,T.isRegExp=wm,T.isSafeInteger=PW,T.isSet=dC,T.isString=Lf,T.isSymbol=Sr,T.isTypedArray=qs,T.isUndefined=AW,T.isWeakMap=RW,T.isWeakSet=IW,T.join=Nz,T.kebabCase=b5,T.last=Ur,T.lastIndexOf=Mz,T.lowerCase=x5,T.lowerFirst=w5,T.lt=TW,T.lte=kW,T.max=gH,T.maxBy=mH,T.mean=vH,T.meanBy=yH,T.min=bH,T.minBy=xH,T.stubArray=Rm,T.stubFalse=Im,T.stubObject=oH,T.stubString=aH,T.stubTrue=sH,T.multiply=wH,T.nth=Dz,T.noConflict=Z5,T.noop=Am,T.now=Nf,T.pad=S5,T.padEnd=C5,T.padStart=E5,T.parseInt=_5,T.random=h5,T.reduce=$3,T.reduceRight=F3,T.repeat=O5,T.replace=P5,T.result=i5,T.round=SH,T.runInContext=z,T.sample=B3,T.size=H3,T.snakeCase=A5,T.some=U3,T.sortedIndex=zz,T.sortedIndexBy=Wz,T.sortedIndexOf=Hz,T.sortedLastIndex=Uz,T.sortedLastIndexBy=Gz,T.sortedLastIndexOf=qz,T.startCase=I5,T.startsWith=T5,T.subtract=CH,T.sum=EH,T.sumBy=_H,T.template=k5,T.times=lH,T.toFinite=Ji,T.toInteger=et,T.toLength=hC,T.toLower=N5,T.toNumber=Gr,T.toSafeInteger=NW,T.toString=wt,T.toUpper=M5,T.trim=D5,T.trimEnd=j5,T.trimStart=L5,T.truncate=$5,T.unescape=F5,T.uniqueId=cH,T.upperCase=V5,T.upperFirst=Em,T.each=eC,T.eachRight=tC,T.first=X1,Pm(T,(function(){var l={};return Ci(T,function(d,m){xt.call(T.prototype,m)||(l[m]=d)}),l})(),{chain:!1}),T.VERSION=r,Vr(["bind","bindKey","curry","curryRight","partial","partialRight"],function(l){T[l].placeholder=T}),Vr(["drop","take"],function(l,d){ut.prototype[l]=function(m){m=m===n?1:sn(et(m),0);var C=this.__filtered__&&!d?new ut(this):this.clone();return C.__filtered__?C.__takeCount__=Ln(m,C.__takeCount__):C.__views__.push({size:Ln(m,Oe),type:l+(C.__dir__<0?"Right":"")}),C},ut.prototype[l+"Right"]=function(m){return this.reverse()[l](m).reverse()}}),Vr(["filter","map","takeWhile"],function(l,d){var m=d+1,C=m==J||m==U;ut.prototype[l]=function(A){var N=this.clone();return N.__iteratees__.push({iteratee:We(A,3),type:m}),N.__filtered__=N.__filtered__||C,N}}),Vr(["head","last"],function(l,d){var m="take"+(d?"Right":"");ut.prototype[l]=function(){return this[m](1).value()[0]}}),Vr(["initial","tail"],function(l,d){var m="drop"+(d?"":"Right");ut.prototype[l]=function(){return this.__filtered__?new ut(this):this[m](1)}}),ut.prototype.compact=function(){return this.filter(sr)},ut.prototype.find=function(l){return this.filter(l).head()},ut.prototype.findLast=function(l){return this.reverse().find(l)},ut.prototype.invokeMap=rt(function(l,d){return typeof l=="function"?new ut(this):this.map(function(m){return ou(m,l,d)})}),ut.prototype.reject=function(l){return this.filter(Df(We(l)))},ut.prototype.slice=function(l,d){l=et(l);var m=this;return m.__filtered__&&(l>0||d<0)?new ut(m):(l<0?m=m.takeRight(-l):l&&(m=m.drop(l)),d!==n&&(d=et(d),m=d<0?m.dropRight(-d):m.take(d-l)),m)},ut.prototype.takeRightWhile=function(l){return this.reverse().takeWhile(l).reverse()},ut.prototype.toArray=function(){return this.take(Oe)},Ci(ut.prototype,function(l,d){var m=/^(?:filter|find|map|reject)|While$/.test(d),C=/^(?:head|last)$/.test(d),A=T[C?"take"+(d=="last"?"Right":""):d],N=C||/^find/.test(d);A&&(T.prototype[d]=function(){var M=this.__wrapped__,F=C?[1]:arguments,H=M instanceof ut,se=F[0],le=H||Xe(M),de=function(at){var ct=A.apply(T,Lo([at],F));return C&&we?ct[0]:ct};le&&m&&typeof se=="function"&&se.length!=1&&(H=le=!1);var we=this.__chain__,ke=!!this.__actions__.length,He=N&&!we,tt=H&&!ke;if(!N&&le){M=tt?M:new ut(this);var Ue=l.apply(M,F);return Ue.__actions__.push({func:Tf,args:[de],thisArg:n}),new zr(Ue,we)}return He&&tt?l.apply(this,F):(Ue=this.thru(de),He?C?Ue.value()[0]:Ue.value():Ue)})}),Vr(["pop","push","shift","sort","splice","unshift"],function(l){var d=nf[l],m=/^(?:push|sort|unshift)$/.test(l)?"tap":"thru",C=/^(?:pop|shift)$/.test(l);T.prototype[l]=function(){var A=arguments;if(C&&!this.__chain__){var N=this.value();return d.apply(Xe(N)?N:[],A)}return this[m](function(M){return d.apply(Xe(M)?M:[],A)})}}),Ci(ut.prototype,function(l,d){var m=T[d];if(m){var C=m.name+"";xt.call(zs,C)||(zs[C]=[]),zs[C].push({name:d,func:m})}}),zs[Ef(n,w).name]=[{name:"wrapper",func:n}],ut.prototype.clone=FV,ut.prototype.reverse=VV,ut.prototype.value=BV,T.prototype.at=m3,T.prototype.chain=v3,T.prototype.commit=y3,T.prototype.next=b3,T.prototype.plant=w3,T.prototype.reverse=S3,T.prototype.toJSON=T.prototype.valueOf=T.prototype.value=C3,T.prototype.first=T.prototype.head,Ql&&(T.prototype[Ql]=x3),T}),Fs=yV();Aa?((Aa.exports=Fs)._=Fs,Og._=Fs):Pn._=Fs}).call(FQ)})(Tu,Tu.exports)),Tu.exports}var BQ=VQ(),zQ=["dangerouslySetInnerHTML","onCopy","onCopyCapture","onCut","onCutCapture","onPaste","onPasteCapture","onCompositionEnd","onCompositionEndCapture","onCompositionStart","onCompositionStartCapture","onCompositionUpdate","onCompositionUpdateCapture","onFocus","onFocusCapture","onBlur","onBlurCapture","onChange","onChangeCapture","onBeforeInput","onBeforeInputCapture","onInput","onInputCapture","onReset","onResetCapture","onSubmit","onSubmitCapture","onInvalid","onInvalidCapture","onLoad","onLoadCapture","onError","onErrorCapture","onKeyDown","onKeyDownCapture","onKeyPress","onKeyPressCapture","onKeyUp","onKeyUpCapture","onAbort","onAbortCapture","onCanPlay","onCanPlayCapture","onCanPlayThrough","onCanPlayThroughCapture","onDurationChange","onDurationChangeCapture","onEmptied","onEmptiedCapture","onEncrypted","onEncryptedCapture","onEnded","onEndedCapture","onLoadedData","onLoadedDataCapture","onLoadedMetadata","onLoadedMetadataCapture","onLoadStart","onLoadStartCapture","onPause","onPauseCapture","onPlay","onPlayCapture","onPlaying","onPlayingCapture","onProgress","onProgressCapture","onRateChange","onRateChangeCapture","onSeeked","onSeekedCapture","onSeeking","onSeekingCapture","onStalled","onStalledCapture","onSuspend","onSuspendCapture","onTimeUpdate","onTimeUpdateCapture","onVolumeChange","onVolumeChangeCapture","onWaiting","onWaitingCapture","onAuxClick","onAuxClickCapture","onClick","onClickCapture","onContextMenu","onContextMenuCapture","onDoubleClick","onDoubleClickCapture","onDrag","onDragCapture","onDragEnd","onDragEndCapture","onDragEnter","onDragEnterCapture","onDragExit","onDragExitCapture","onDragLeave","onDragLeaveCapture","onDragOver","onDragOverCapture","onDragStart","onDragStartCapture","onDrop","onDropCapture","onMouseDown","onMouseDownCapture","onMouseEnter","onMouseLeave","onMouseMove","onMouseMoveCapture","onMouseOut","onMouseOutCapture","onMouseOver","onMouseOverCapture","onMouseUp","onMouseUpCapture","onSelect","onSelectCapture","onTouchCancel","onTouchCancelCapture","onTouchEnd","onTouchEndCapture","onTouchMove","onTouchMoveCapture","onTouchStart","onTouchStartCapture","onPointerDown","onPointerDownCapture","onPointerMove","onPointerMoveCapture","onPointerUp","onPointerUpCapture","onPointerCancel","onPointerCancelCapture","onPointerEnter","onPointerEnterCapture","onPointerLeave","onPointerLeaveCapture","onPointerOver","onPointerOverCapture","onPointerOut","onPointerOutCapture","onGotPointerCapture","onGotPointerCaptureCapture","onLostPointerCapture","onLostPointerCaptureCapture","onScroll","onScrollCapture","onWheel","onWheelCapture","onAnimationStart","onAnimationStartCapture","onAnimationEnd","onAnimationEndCapture","onAnimationIteration","onAnimationIterationCapture","onTransitionEnd","onTransitionEndCapture"];function B0(e){if(typeof e!="string")return!1;var t=zQ;return t.includes(e)}var WQ=["aria-activedescendant","aria-atomic","aria-autocomplete","aria-busy","aria-checked","aria-colcount","aria-colindex","aria-colspan","aria-controls","aria-current","aria-describedby","aria-details","aria-disabled","aria-errormessage","aria-expanded","aria-flowto","aria-haspopup","aria-hidden","aria-invalid","aria-keyshortcuts","aria-label","aria-labelledby","aria-level","aria-live","aria-modal","aria-multiline","aria-multiselectable","aria-orientation","aria-owns","aria-placeholder","aria-posinset","aria-pressed","aria-readonly","aria-relevant","aria-required","aria-roledescription","aria-rowcount","aria-rowindex","aria-rowspan","aria-selected","aria-setsize","aria-sort","aria-valuemax","aria-valuemin","aria-valuenow","aria-valuetext","className","color","height","id","lang","max","media","method","min","name","style","target","width","role","tabIndex","accentHeight","accumulate","additive","alignmentBaseline","allowReorder","alphabetic","amplitude","arabicForm","ascent","attributeName","attributeType","autoReverse","azimuth","baseFrequency","baselineShift","baseProfile","bbox","begin","bias","by","calcMode","capHeight","clip","clipPath","clipPathUnits","clipRule","colorInterpolation","colorInterpolationFilters","colorProfile","colorRendering","contentScriptType","contentStyleType","cursor","cx","cy","d","decelerate","descent","diffuseConstant","direction","display","divisor","dominantBaseline","dur","dx","dy","edgeMode","elevation","enableBackground","end","exponent","externalResourcesRequired","fill","fillOpacity","fillRule","filter","filterRes","filterUnits","floodColor","floodOpacity","focusable","fontFamily","fontSize","fontSizeAdjust","fontStretch","fontStyle","fontVariant","fontWeight","format","from","fx","fy","g1","g2","glyphName","glyphOrientationHorizontal","glyphOrientationVertical","glyphRef","gradientTransform","gradientUnits","hanging","horizAdvX","horizOriginX","href","ideographic","imageRendering","in2","in","intercept","k1","k2","k3","k4","k","kernelMatrix","kernelUnitLength","kerning","keyPoints","keySplines","keyTimes","lengthAdjust","letterSpacing","lightingColor","limitingConeAngle","local","markerEnd","markerHeight","markerMid","markerStart","markerUnits","markerWidth","mask","maskContentUnits","maskUnits","mathematical","mode","numOctaves","offset","opacity","operator","order","orient","orientation","origin","overflow","overlinePosition","overlineThickness","paintOrder","panose1","pathLength","patternContentUnits","patternTransform","patternUnits","pointerEvents","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","r","radius","refX","refY","renderingIntent","repeatCount","repeatDur","requiredExtensions","requiredFeatures","restart","result","rotate","rx","ry","seed","shapeRendering","slope","spacing","specularConstant","specularExponent","speed","spreadMethod","startOffset","stdDeviation","stemh","stemv","stitchTiles","stopColor","stopOpacity","strikethroughPosition","strikethroughThickness","string","stroke","strokeDasharray","strokeDashoffset","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity","strokeWidth","surfaceScale","systemLanguage","tableValues","targetX","targetY","textAnchor","textDecoration","textLength","textRendering","to","transform","u1","u2","underlinePosition","underlineThickness","unicode","unicodeBidi","unicodeRange","unitsPerEm","vAlphabetic","values","vectorEffect","version","vertAdvY","vertOriginX","vertOriginY","vHanging","vIdeographic","viewTarget","visibility","vMathematical","widths","wordSpacing","writingMode","x1","x2","x","xChannelSelector","xHeight","xlinkActuate","xlinkArcrole","xlinkHref","xlinkRole","xlinkShow","xlinkTitle","xlinkType","xmlBase","xmlLang","xmlns","xmlnsXlink","xmlSpace","y1","y2","y","yChannelSelector","z","zoomAndPan","ref","key","angle"],HQ=new Set(WQ);function AD(e){return typeof e!="string"?!1:HQ.has(e)}function RD(e){return typeof e=="string"&&e.startsWith("data-")}function vo(e){if(typeof e!="object"||e===null)return{};var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(AD(n)||RD(n))&&(t[n]=e[n]);return t}function z0(e){if(e==null)return null;if($.isValidElement(e)&&typeof e.props=="object"&&e.props!==null){var t=e.props;return vo(t)}return typeof e=="object"&&!Array.isArray(e)?vo(e):null}function ni(e){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(AD(n)||RD(n)||B0(n))&&(t[n]=e[n]);return t}var UQ=["children","width","height","viewBox","className","style","title","desc"];function vb(){return vb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},vb.apply(null,arguments)}function GQ(e,t){if(e==null)return{};var n,r,i=qQ(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function qQ(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var ID=$.forwardRef((e,t)=>{var{children:n,width:r,height:i,viewBox:o,className:a,style:s,title:u,desc:c}=e,f=GQ(e,UQ),p=o||{width:r,height:i,x:0,y:0},g=At("recharts-surface",a);return x.createElement("svg",vb({},ni(f),{className:g,width:r,height:i,style:s,viewBox:"".concat(p.x," ").concat(p.y," ").concat(p.width," ").concat(p.height),ref:t}),x.createElement("title",null,u),x.createElement("desc",null,c),n)}),KQ=["children","className"];function yb(){return yb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},yb.apply(null,arguments)}function YQ(e,t){if(e==null)return{};var n,r,i=XQ(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function XQ(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var $i=x.forwardRef((e,t)=>{var{children:n,className:r}=e,i=YQ(e,KQ),o=At("recharts-layer",r);return x.createElement("g",yb({className:o},ni(i),{ref:t}),n)}),ZQ=$.createContext(null);function Tt(e){return function(){return e}}const TD=Math.cos,ap=Math.sin,yi=Math.sqrt,sp=Math.PI,jh=2*sp,bb=Math.PI,xb=2*bb,Ha=1e-6,QQ=xb-Ha;function kD(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function JQ(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return kD;const n=10**t;return function(r){this._+=r[0];for(let i=1,o=r.length;i<o;++i)this._+=Math.round(arguments[i]*n)/n+r[i]}}class eJ{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?kD:JQ(t)}moveTo(t,n){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,n){this._append`L${this._x1=+t},${this._y1=+n}`}quadraticCurveTo(t,n,r,i){this._append`Q${+t},${+n},${this._x1=+r},${this._y1=+i}`}bezierCurveTo(t,n,r,i,o,a){this._append`C${+t},${+n},${+r},${+i},${this._x1=+o},${this._y1=+a}`}arcTo(t,n,r,i,o){if(t=+t,n=+n,r=+r,i=+i,o=+o,o<0)throw new Error(`negative radius: ${o}`);let a=this._x1,s=this._y1,u=r-t,c=i-n,f=a-t,p=s-n,g=f*f+p*p;if(this._x1===null)this._append`M${this._x1=t},${this._y1=n}`;else if(g>Ha)if(!(Math.abs(p*u-c*f)>Ha)||!o)this._append`L${this._x1=t},${this._y1=n}`;else{let h=r-a,v=i-s,b=u*u+c*c,y=h*h+v*v,w=Math.sqrt(b),S=Math.sqrt(g),E=o*Math.tan((bb-Math.acos((b+g-y)/(2*w*S)))/2),_=E/S,P=E/w;Math.abs(_-1)>Ha&&this._append`L${t+_*f},${n+_*p}`,this._append`A${o},${o},0,0,${+(p*h>f*v)},${this._x1=t+P*u},${this._y1=n+P*c}`}}arc(t,n,r,i,o,a){if(t=+t,n=+n,r=+r,a=!!a,r<0)throw new Error(`negative radius: ${r}`);let s=r*Math.cos(i),u=r*Math.sin(i),c=t+s,f=n+u,p=1^a,g=a?i-o:o-i;this._x1===null?this._append`M${c},${f}`:(Math.abs(this._x1-c)>Ha||Math.abs(this._y1-f)>Ha)&&this._append`L${c},${f}`,r&&(g<0&&(g=g%xb+xb),g>QQ?this._append`A${r},${r},0,1,${p},${t-s},${n-u}A${r},${r},0,1,${p},${this._x1=c},${this._y1=f}`:g>Ha&&this._append`A${r},${r},0,${+(g>=bb)},${p},${this._x1=t+r*Math.cos(o)},${this._y1=n+r*Math.sin(o)}`)}rect(t,n,r,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${r=+r}v${+i}h${-r}Z`}toString(){return this._}}function W0(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{const r=Math.floor(n);if(!(r>=0))throw new RangeError(`invalid digits: ${n}`);t=r}return e},()=>new eJ(t)}function H0(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function ND(e){this._context=e}ND.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 Lh(e){return new ND(e)}function MD(e){return e[0]}function DD(e){return e[1]}function jD(e,t){var n=Tt(!0),r=null,i=Lh,o=null,a=W0(s);e=typeof e=="function"?e:e===void 0?MD:Tt(e),t=typeof t=="function"?t:t===void 0?DD:Tt(t);function s(u){var c,f=(u=H0(u)).length,p,g=!1,h;for(r==null&&(o=i(h=a())),c=0;c<=f;++c)!(c<f&&n(p=u[c],c,u))===g&&((g=!g)?o.lineStart():o.lineEnd()),g&&o.point(+e(p,c,u),+t(p,c,u));if(h)return o=null,h+""||null}return s.x=function(u){return arguments.length?(e=typeof u=="function"?u:Tt(+u),s):e},s.y=function(u){return arguments.length?(t=typeof u=="function"?u:Tt(+u),s):t},s.defined=function(u){return arguments.length?(n=typeof u=="function"?u:Tt(!!u),s):n},s.curve=function(u){return arguments.length?(i=u,r!=null&&(o=i(r)),s):i},s.context=function(u){return arguments.length?(u==null?r=o=null:o=i(r=u),s):r},s}function fd(e,t,n){var r=null,i=Tt(!0),o=null,a=Lh,s=null,u=W0(c);e=typeof e=="function"?e:e===void 0?MD:Tt(+e),t=typeof t=="function"?t:Tt(t===void 0?0:+t),n=typeof n=="function"?n:n===void 0?DD:Tt(+n);function c(p){var g,h,v,b=(p=H0(p)).length,y,w=!1,S,E=new Array(b),_=new Array(b);for(o==null&&(s=a(S=u())),g=0;g<=b;++g){if(!(g<b&&i(y=p[g],g,p))===w)if(w=!w)h=g,s.areaStart(),s.lineStart();else{for(s.lineEnd(),s.lineStart(),v=g-1;v>=h;--v)s.point(E[v],_[v]);s.lineEnd(),s.areaEnd()}w&&(E[g]=+e(y,g,p),_[g]=+t(y,g,p),s.point(r?+r(y,g,p):E[g],n?+n(y,g,p):_[g]))}if(S)return s=null,S+""||null}function f(){return jD().defined(i).curve(a).context(o)}return c.x=function(p){return arguments.length?(e=typeof p=="function"?p:Tt(+p),r=null,c):e},c.x0=function(p){return arguments.length?(e=typeof p=="function"?p:Tt(+p),c):e},c.x1=function(p){return arguments.length?(r=p==null?null:typeof p=="function"?p:Tt(+p),c):r},c.y=function(p){return arguments.length?(t=typeof p=="function"?p:Tt(+p),n=null,c):t},c.y0=function(p){return arguments.length?(t=typeof p=="function"?p:Tt(+p),c):t},c.y1=function(p){return arguments.length?(n=p==null?null:typeof p=="function"?p:Tt(+p),c):n},c.lineX0=c.lineY0=function(){return f().x(e).y(t)},c.lineY1=function(){return f().x(e).y(n)},c.lineX1=function(){return f().x(r).y(t)},c.defined=function(p){return arguments.length?(i=typeof p=="function"?p:Tt(!!p),c):i},c.curve=function(p){return arguments.length?(a=p,o!=null&&(s=a(o)),c):a},c.context=function(p){return arguments.length?(p==null?o=s=null:s=a(o=p),c):o},c}class LD{constructor(t,n){this._context=t,this._x=n}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(t,n){switch(t=+t,n=+n,this._point){case 0:{this._point=1,this._line?this._context.lineTo(t,n):this._context.moveTo(t,n);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,n,t,n):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+n)/2,t,this._y0,t,n);break}}this._x0=t,this._y0=n}}function tJ(e){return new LD(e,!0)}function nJ(e){return new LD(e,!1)}const U0={draw(e,t){const n=yi(t/sp);e.moveTo(n,0),e.arc(0,0,n,0,jh)}},rJ={draw(e,t){const n=yi(t/5)/2;e.moveTo(-3*n,-n),e.lineTo(-n,-n),e.lineTo(-n,-3*n),e.lineTo(n,-3*n),e.lineTo(n,-n),e.lineTo(3*n,-n),e.lineTo(3*n,n),e.lineTo(n,n),e.lineTo(n,3*n),e.lineTo(-n,3*n),e.lineTo(-n,n),e.lineTo(-3*n,n),e.closePath()}},$D=yi(1/3),iJ=$D*2,oJ={draw(e,t){const n=yi(t/iJ),r=n*$D;e.moveTo(0,-n),e.lineTo(r,0),e.lineTo(0,n),e.lineTo(-r,0),e.closePath()}},aJ={draw(e,t){const n=yi(t),r=-n/2;e.rect(r,r,n,n)}},sJ=.8908130915292852,FD=ap(sp/10)/ap(7*sp/10),lJ=ap(jh/10)*FD,uJ=-TD(jh/10)*FD,cJ={draw(e,t){const n=yi(t*sJ),r=lJ*n,i=uJ*n;e.moveTo(0,-n),e.lineTo(r,i);for(let o=1;o<5;++o){const a=jh*o/5,s=TD(a),u=ap(a);e.lineTo(u*n,-s*n),e.lineTo(s*r-u*i,u*r+s*i)}e.closePath()}},lv=yi(3),fJ={draw(e,t){const n=-yi(t/(lv*3));e.moveTo(0,n*2),e.lineTo(-lv*n,-n),e.lineTo(lv*n,-n),e.closePath()}},qr=-.5,Kr=yi(3)/2,wb=1/yi(12),dJ=(wb/2+1)*3,pJ={draw(e,t){const n=yi(t/dJ),r=n/2,i=n*wb,o=r,a=n*wb+n,s=-o,u=a;e.moveTo(r,i),e.lineTo(o,a),e.lineTo(s,u),e.lineTo(qr*r-Kr*i,Kr*r+qr*i),e.lineTo(qr*o-Kr*a,Kr*o+qr*a),e.lineTo(qr*s-Kr*u,Kr*s+qr*u),e.lineTo(qr*r+Kr*i,qr*i-Kr*r),e.lineTo(qr*o+Kr*a,qr*a-Kr*o),e.lineTo(qr*s+Kr*u,qr*u-Kr*s),e.closePath()}};function hJ(e,t){let n=null,r=W0(i);e=typeof e=="function"?e:Tt(e||U0),t=typeof t=="function"?t:Tt(t===void 0?64:+t);function i(){let o;if(n||(n=o=r()),e.apply(this,arguments).draw(n,+t.apply(this,arguments)),o)return n=null,o+""||null}return i.type=function(o){return arguments.length?(e=typeof o=="function"?o:Tt(o),i):e},i.size=function(o){return arguments.length?(t=typeof o=="function"?o:Tt(+o),i):t},i.context=function(o){return arguments.length?(n=o??null,i):n},i}function lp(){}function up(e,t,n){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+n)/6)}function VD(e){this._context=e}VD.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:up(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(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;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:up(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function gJ(e){return new VD(e)}function BD(e){this._context=e}BD.prototype={areaStart:lp,areaEnd:lp,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:up(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function mJ(e){return new BD(e)}function zD(e){this._context=e}zD.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:up(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function vJ(e){return new zD(e)}function WD(e){this._context=e}WD.prototype={areaStart:lp,areaEnd:lp,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function yJ(e){return new WD(e)}function JE(e){return e<0?-1:1}function e_(e,t,n){var r=e._x1-e._x0,i=t-e._x1,o=(e._y1-e._y0)/(r||i<0&&-0),a=(n-e._y1)/(i||r<0&&-0),s=(o*i+a*r)/(r+i);return(JE(o)+JE(a))*Math.min(Math.abs(o),Math.abs(a),.5*Math.abs(s))||0}function t_(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function uv(e,t,n){var r=e._x0,i=e._y0,o=e._x1,a=e._y1,s=(o-r)/3;e._context.bezierCurveTo(r+s,i+s*t,o-s,a-s*n,o,a)}function cp(e){this._context=e}cp.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:uv(this,this._t0,t_(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var n=NaN;if(e=+e,t=+t,!(e===this._x1&&t===this._y1)){switch(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;break;case 2:this._point=3,uv(this,t_(this,n=e_(this,e,t)),n);break;default:uv(this,this._t0,n=e_(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function HD(e){this._context=new UD(e)}(HD.prototype=Object.create(cp.prototype)).point=function(e,t){cp.prototype.point.call(this,t,e)};function UD(e){this._context=e}UD.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,n,r,i,o){this._context.bezierCurveTo(t,e,r,n,o,i)}};function bJ(e){return new cp(e)}function xJ(e){return new HD(e)}function GD(e){this._context=e}GD.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,n=e.length;if(n)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),n===2)this._context.lineTo(e[1],t[1]);else for(var r=n_(e),i=n_(t),o=0,a=1;a<n;++o,++a)this._context.bezierCurveTo(r[0][o],i[0][o],r[1][o],i[1][o],e[a],t[a]);(this._line||this._line!==0&&n===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}};function n_(e){var t,n=e.length-1,r,i=new Array(n),o=new Array(n),a=new Array(n);for(i[0]=0,o[0]=2,a[0]=e[0]+2*e[1],t=1;t<n-1;++t)i[t]=1,o[t]=4,a[t]=4*e[t]+2*e[t+1];for(i[n-1]=2,o[n-1]=7,a[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)r=i[t]/o[t-1],o[t]-=r,a[t]-=r*a[t-1];for(i[n-1]=a[n-1]/o[n-1],t=n-2;t>=0;--t)i[t]=(a[t]-i[t+1])/o[t];for(o[n-1]=(e[n]+i[n-1])/2,t=0;t<n-1;++t)o[t]=2*e[t+1]-i[t+1];return[i,o]}function wJ(e){return new GD(e)}function $h(e,t){this._context=e,this._t=t}$h.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,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:{if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}break}}this._x=e,this._y=t}};function SJ(e){return new $h(e,.5)}function CJ(e){return new $h(e,0)}function EJ(e){return new $h(e,1)}function ls(e,t){if((a=e.length)>1)for(var n=1,r,i,o=e[t[0]],a,s=o.length;n<a;++n)for(i=o,o=e[t[n]],r=0;r<s;++r)o[r][1]+=o[r][0]=isNaN(i[r][1])?i[r][0]:i[r][1]}function Sb(e){for(var t=e.length,n=new Array(t);--t>=0;)n[t]=t;return n}function _J(e,t){return e[t]}function OJ(e){const t=[];return t.key=e,t}function PJ(){var e=Tt([]),t=Sb,n=ls,r=_J;function i(o){var a=Array.from(e.apply(this,arguments),OJ),s,u=a.length,c=-1,f;for(const p of o)for(s=0,++c;s<u;++s)(a[s][c]=[0,+r(p,a[s].key,c,o)]).data=p;for(s=0,f=H0(t(a));s<u;++s)a[f[s]].index=s;return n(a,f),a}return i.keys=function(o){return arguments.length?(e=typeof o=="function"?o:Tt(Array.from(o)),i):e},i.value=function(o){return arguments.length?(r=typeof o=="function"?o:Tt(+o),i):r},i.order=function(o){return arguments.length?(t=o==null?Sb:typeof o=="function"?o:Tt(Array.from(o)),i):t},i.offset=function(o){return arguments.length?(n=o??ls,i):n},i}function AJ(e,t){if((r=e.length)>0){for(var n,r,i=0,o=e[0].length,a;i<o;++i){for(a=n=0;n<r;++n)a+=e[n][i][1]||0;if(a)for(n=0;n<r;++n)e[n][i][1]/=a}ls(e,t)}}function RJ(e,t){if((i=e.length)>0){for(var n=0,r=e[t[0]],i,o=r.length;n<o;++n){for(var a=0,s=0;a<i;++a)s+=e[a][n][1]||0;r[n][1]+=r[n][0]=-s/2}ls(e,t)}}function IJ(e,t){if(!(!((a=e.length)>0)||!((o=(i=e[t[0]]).length)>0))){for(var n=0,r=1,i,o,a;r<o;++r){for(var s=0,u=0,c=0;s<a;++s){for(var f=e[t[s]],p=f[r][1]||0,g=f[r-1][1]||0,h=(p-g)/2,v=0;v<s;++v){var b=e[t[v]],y=b[r][1]||0,w=b[r-1][1]||0;h+=y-w}u+=p,c+=h*p}i[r-1][1]+=i[r-1][0]=n,u&&(n-=c/u)}i[r-1][1]+=i[r-1][0]=n,ls(e,t)}}var cv={},fv={},r_;function TJ(){return r_||(r_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return n==="__proto__"}e.isUnsafeProperty=t})(fv)),fv}var dv={},i_;function qD(){return i_||(i_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){switch(typeof n){case"number":case"symbol":return!1;case"string":return n.includes(".")||n.includes("[")||n.includes("]")}}e.isDeepKey=t})(dv)),dv}var pv={},o_;function G0(){return o_||(o_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return typeof n=="string"||typeof n=="symbol"?n:Object.is(n?.valueOf?.(),-0)?"-0":String(n)}e.toKey=t})(pv)),pv}var hv={},gv={},a_;function kJ(){return a_||(a_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){if(n==null)return"";if(typeof n=="string")return n;if(Array.isArray(n))return n.map(t).join(",");const r=String(n);return r==="0"&&Object.is(Number(n),-0)?"-0":r}e.toString=t})(gv)),gv}var s_;function q0(){return s_||(s_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=kJ(),n=G0();function r(i){if(Array.isArray(i))return i.map(n.toKey);if(typeof i=="symbol")return[i];i=t.toString(i);const o=[],a=i.length;if(a===0)return o;let s=0,u="",c="",f=!1;for(i.charCodeAt(0)===46&&(o.push(""),s++);s<a;){const p=i[s];c?p==="\\"&&s+1<a?(s++,u+=i[s]):p===c?c="":u+=p:f?p==='"'||p==="'"?c=p:p==="]"?(f=!1,o.push(u),u=""):u+=p:p==="["?(f=!0,u&&(o.push(u),u="")):p==="."?u&&(o.push(u),u=""):u+=p,s++}return u&&o.push(u),o}e.toPath=r})(hv)),hv}var l_;function K0(){return l_||(l_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=TJ(),n=qD(),r=G0(),i=q0();function o(s,u,c){if(s==null)return c;switch(typeof u){case"string":{if(t.isUnsafeProperty(u))return c;const f=s[u];return f===void 0?n.isDeepKey(u)?o(s,i.toPath(u),c):c:f}case"number":case"symbol":{typeof u=="number"&&(u=r.toKey(u));const f=s[u];return f===void 0?c:f}default:{if(Array.isArray(u))return a(s,u,c);if(Object.is(u?.valueOf(),-0)?u="-0":u=String(u),t.isUnsafeProperty(u))return c;const f=s[u];return f===void 0?c:f}}}function a(s,u,c){if(u.length===0)return c;let f=s;for(let p=0;p<u.length;p++){if(f==null||t.isUnsafeProperty(u[p]))return c;f=f[u[p]]}return f===void 0?c:f}e.get=o})(cv)),cv}var mv,u_;function NJ(){return u_||(u_=1,mv=K0().get),mv}var MJ=NJ();const xl=vs(MJ);var DJ=4;function na(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:DJ,n=10**t,r=Math.round(e*n)/n;return Object.is(r,-0)?0:r}function Kt(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return e.reduce((i,o,a)=>{var s=n[a-1];return typeof s=="string"?i+s+o:s!==void 0?i+na(s)+o:i+o},"")}var fr=e=>e===0?0:e>0?1:-1,Fi=e=>typeof e=="number"&&e!=+e,us=e=>typeof e=="string"&&e.indexOf("%")===e.length-1,Ne=e=>(typeof e=="number"||e instanceof Number)&&!Fi(e),Vi=e=>Ne(e)||typeof e=="string",jJ=0,Xu=e=>{var t=++jJ;return"".concat(e||"").concat(t)},pi=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(!Ne(t)&&typeof t!="string")return r;var o;if(us(t)){if(n==null)return r;var a=t.indexOf("%");o=n*parseFloat(t.slice(0,a))/100}else o=+t;return Fi(o)&&(o=r),i&&n!=null&&o>n&&(o=n),o},KD=e=>{if(!Array.isArray(e))return!1;for(var t=e.length,n={},r=0;r<t;r++)if(!n[String(e[r])])n[String(e[r])]=!0;else return!0;return!1};function Tn(e,t,n){return Ne(e)&&Ne(t)?na(e+n*(t-e)):t}function LJ(e,t,n){if(!(!e||!e.length))return e.find(r=>r&&(typeof t=="function"?t(r):xl(r,t))===n)}var pn=e=>e===null||typeof e>"u",xc=e=>pn(e)?e:"".concat(e.charAt(0).toUpperCase()).concat(e.slice(1));function dr(e){return e!=null}function ys(){}var $J=["type","size","sizeType"];function Cb(){return Cb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Cb.apply(null,arguments)}function c_(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function f_(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?c_(Object(n),!0).forEach(function(r){FJ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):c_(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function FJ(e,t,n){return(t=VJ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function VJ(e){var t=BJ(e,"string");return typeof t=="symbol"?t:t+""}function BJ(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function zJ(e,t){if(e==null)return{};var n,r,i=WJ(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function WJ(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var YD={symbolCircle:U0,symbolCross:rJ,symbolDiamond:oJ,symbolSquare:aJ,symbolStar:cJ,symbolTriangle:fJ,symbolWye:pJ},HJ=Math.PI/180,UJ=e=>{var t="symbol".concat(xc(e));return YD[t]||U0},GJ=(e,t,n)=>{if(t==="area")return e;switch(n){case"cross":return 5*e*e/9;case"diamond":return .5*e*e/Math.sqrt(3);case"square":return e*e;case"star":{var r=18*HJ;return 1.25*e*e*(Math.tan(r)-Math.tan(r*2)*Math.tan(r)**2)}case"triangle":return Math.sqrt(3)*e*e/4;case"wye":return(21-10*Math.sqrt(3))*e*e/8;default:return Math.PI*e*e/4}},qJ=(e,t)=>{YD["symbol".concat(xc(e))]=t},XD=e=>{var{type:t="circle",size:n=64,sizeType:r="area"}=e,i=zJ(e,$J),o=f_(f_({},i),{},{type:t,size:n,sizeType:r}),a="circle";typeof t=="string"&&(a=t);var s=()=>{var g=UJ(a),h=hJ().type(g).size(GJ(n,r,a)),v=h();if(v!==null)return v},{className:u,cx:c,cy:f}=o,p=ni(o);return Ne(c)&&Ne(f)&&Ne(n)?x.createElement("path",Cb({},p,{className:At("recharts-symbols",u),transform:"translate(".concat(c,", ").concat(f,")"),d:s()})):null};XD.registerSymbol=qJ;var ZD=e=>"radius"in e&&"startAngle"in e&&"endAngle"in e,KJ=(e,t)=>{if(!e||typeof e=="function"||typeof e=="boolean")return null;var n=e;if($.isValidElement(e)&&(n=e.props),typeof n!="object"&&typeof n!="function")return null;var r={};return Object.keys(n).forEach(i=>{B0(i)&&typeof n[i]=="function"&&(r[i]=(o=>n[i](n,o)))}),r},YJ=(e,t,n)=>r=>(e(t,n,r),null),Y0=(e,t,n)=>{if(e===null||typeof e!="object"&&typeof e!="function")return null;var r=null;return Object.keys(e).forEach(i=>{var o=e[i];B0(i)&&typeof o=="function"&&(r||(r={}),r[i]=YJ(o,t,n))}),r};function d_(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function XJ(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?d_(Object(n),!0).forEach(function(r){ZJ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):d_(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ZJ(e,t,n){return(t=QJ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function QJ(e){var t=JJ(e,"string");return typeof t=="symbol"?t:t+""}function JJ(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Dr(e,t){var n=XJ({},e),r=t,i=Object.keys(t),o=i.reduce((a,s)=>(a[s]===void 0&&r[s]!==void 0&&(a[s]=r[s]),a),n);return o}var vv={},yv={},p_;function eee(){return p_||(p_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r){const i=new Map;for(let o=0;o<n.length;o++){const a=n[o],s=r(a,o,n);i.has(s)||i.set(s,a)}return Array.from(i.values())}e.uniqBy=t})(yv)),yv}var bv={},h_;function tee(){return h_||(h_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r){return function(...i){return n.apply(this,i.slice(0,r))}}e.ary=t})(bv)),bv}var xv={},g_;function QD(){return g_||(g_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return n}e.identity=t})(xv)),xv}var wv={},Sv={},Cv={},m_;function nee(){return m_||(m_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return Number.isSafeInteger(n)&&n>=0}e.isLength=t})(Cv)),Cv}var v_;function JD(){return v_||(v_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=nee();function n(r){return r!=null&&typeof r!="function"&&t.isLength(r.length)}e.isArrayLike=n})(Sv)),Sv}var Ev={},y_;function ree(){return y_||(y_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return typeof n=="object"&&n!==null}e.isObjectLike=t})(Ev)),Ev}var b_;function iee(){return b_||(b_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=JD(),n=ree();function r(i){return n.isObjectLike(i)&&t.isArrayLike(i)}e.isArrayLikeObject=r})(wv)),wv}var _v={},Ov={},x_;function oee(){return x_||(x_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=K0();function n(r){return function(i){return t.get(i,r)}}e.property=n})(Ov)),Ov}var Pv={},Av={},Rv={},Iv={},w_;function ej(){return w_||(w_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return n!==null&&(typeof n=="object"||typeof n=="function")}e.isObject=t})(Iv)),Iv}var Tv={},S_;function tj(){return S_||(S_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return n==null||typeof n!="object"&&typeof n!="function"}e.isPrimitive=t})(Tv)),Tv}var kv={},C_;function nj(){return C_||(C_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r){return n===r||Number.isNaN(n)&&Number.isNaN(r)}e.isEqualsSameValueZero=t})(kv)),kv}var E_;function aee(){return E_||(E_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=ej(),n=tj(),r=nj();function i(f,p,g){return typeof g!="function"?i(f,p,()=>{}):o(f,p,function h(v,b,y,w,S,E){const _=g(v,b,y,w,S,E);return _!==void 0?!!_:o(v,b,h,E)},new Map)}function o(f,p,g,h){if(p===f)return!0;switch(typeof p){case"object":return a(f,p,g,h);case"function":return Object.keys(p).length>0?o(f,{...p},g,h):r.isEqualsSameValueZero(f,p);default:return t.isObject(f)?typeof p=="string"?p==="":!0:r.isEqualsSameValueZero(f,p)}}function a(f,p,g,h){if(p==null)return!0;if(Array.isArray(p))return u(f,p,g,h);if(p instanceof Map)return s(f,p,g,h);if(p instanceof Set)return c(f,p,g,h);const v=Object.keys(p);if(f==null||n.isPrimitive(f))return v.length===0;if(v.length===0)return!0;if(h?.has(p))return h.get(p)===f;h?.set(p,f);try{for(let b=0;b<v.length;b++){const y=v[b];if(!n.isPrimitive(f)&&!(y in f)||p[y]===void 0&&f[y]!==void 0||p[y]===null&&f[y]!==null||!g(f[y],p[y],y,f,p,h))return!1}return!0}finally{h?.delete(p)}}function s(f,p,g,h){if(p.size===0)return!0;if(!(f instanceof Map))return!1;for(const[v,b]of p.entries()){const y=f.get(v);if(g(y,b,v,f,p,h)===!1)return!1}return!0}function u(f,p,g,h){if(p.length===0)return!0;if(!Array.isArray(f))return!1;const v=new Set;for(let b=0;b<p.length;b++){const y=p[b];let w=!1;for(let S=0;S<f.length;S++){if(v.has(S))continue;const E=f[S];let _=!1;if(g(E,y,b,f,p,h)&&(_=!0),_){v.add(S),w=!0;break}}if(!w)return!1}return!0}function c(f,p,g,h){return p.size===0?!0:f instanceof Set?u([...f],[...p],g,h):!1}e.isMatchWith=i,e.isSetMatch=c})(Rv)),Rv}var __;function rj(){return __||(__=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=aee();function n(r,i){return t.isMatchWith(r,i,()=>{})}e.isMatch=n})(Av)),Av}var Nv={},Mv={},Dv={},O_;function see(){return O_||(O_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return Object.getOwnPropertySymbols(n).filter(r=>Object.prototype.propertyIsEnumerable.call(n,r))}e.getSymbols=t})(Dv)),Dv}var jv={},P_;function X0(){return P_||(P_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return n==null?n===void 0?"[object Undefined]":"[object Null]":Object.prototype.toString.call(n)}e.getTag=t})(jv)),jv}var Lv={},A_;function ij(){return A_||(A_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t="[object RegExp]",n="[object String]",r="[object Number]",i="[object Boolean]",o="[object Arguments]",a="[object Symbol]",s="[object Date]",u="[object Map]",c="[object Set]",f="[object Array]",p="[object Function]",g="[object ArrayBuffer]",h="[object Object]",v="[object Error]",b="[object DataView]",y="[object Uint8Array]",w="[object Uint8ClampedArray]",S="[object Uint16Array]",E="[object Uint32Array]",_="[object BigUint64Array]",P="[object Int8Array]",R="[object Int16Array]",I="[object Int32Array]",k="[object BigInt64Array]",B="[object Float32Array]",L="[object Float64Array]";e.argumentsTag=o,e.arrayBufferTag=g,e.arrayTag=f,e.bigInt64ArrayTag=k,e.bigUint64ArrayTag=_,e.booleanTag=i,e.dataViewTag=b,e.dateTag=s,e.errorTag=v,e.float32ArrayTag=B,e.float64ArrayTag=L,e.functionTag=p,e.int16ArrayTag=R,e.int32ArrayTag=I,e.int8ArrayTag=P,e.mapTag=u,e.numberTag=r,e.objectTag=h,e.regexpTag=t,e.setTag=c,e.stringTag=n,e.symbolTag=a,e.uint16ArrayTag=S,e.uint32ArrayTag=E,e.uint8ArrayTag=y,e.uint8ClampedArrayTag=w})(Lv)),Lv}var $v={},R_;function lee(){return R_||(R_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return ArrayBuffer.isView(n)&&!(n instanceof DataView)}e.isTypedArray=t})($v)),$v}var I_;function oj(){return I_||(I_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=see(),n=X0(),r=ij(),i=tj(),o=lee();function a(f,p){return s(f,void 0,f,new Map,p)}function s(f,p,g,h=new Map,v=void 0){const b=v?.(f,p,g,h);if(b!==void 0)return b;if(i.isPrimitive(f))return f;if(h.has(f))return h.get(f);if(Array.isArray(f)){const y=new Array(f.length);h.set(f,y);for(let w=0;w<f.length;w++)y[w]=s(f[w],w,g,h,v);return Object.hasOwn(f,"index")&&(y.index=f.index),Object.hasOwn(f,"input")&&(y.input=f.input),y}if(f instanceof Date)return new Date(f.getTime());if(f instanceof RegExp){const y=new RegExp(f.source,f.flags);return y.lastIndex=f.lastIndex,y}if(f instanceof Map){const y=new Map;h.set(f,y);for(const[w,S]of f)y.set(w,s(S,w,g,h,v));return y}if(f instanceof Set){const y=new Set;h.set(f,y);for(const w of f)y.add(s(w,void 0,g,h,v));return y}if(typeof Buffer<"u"&&Buffer.isBuffer(f))return f.subarray();if(o.isTypedArray(f)){const y=new(Object.getPrototypeOf(f)).constructor(f.length);h.set(f,y);for(let w=0;w<f.length;w++)y[w]=s(f[w],w,g,h,v);return y}if(f instanceof ArrayBuffer||typeof SharedArrayBuffer<"u"&&f instanceof SharedArrayBuffer)return f.slice(0);if(f instanceof DataView){const y=new DataView(f.buffer.slice(0),f.byteOffset,f.byteLength);return h.set(f,y),u(y,f,g,h,v),y}if(typeof File<"u"&&f instanceof File){const y=new File([f],f.name,{type:f.type});return h.set(f,y),u(y,f,g,h,v),y}if(typeof Blob<"u"&&f instanceof Blob){const y=new Blob([f],{type:f.type});return h.set(f,y),u(y,f,g,h,v),y}if(f instanceof Error){const y=structuredClone(f);return h.set(f,y),y.message=f.message,y.name=f.name,y.stack=f.stack,y.cause=f.cause,y.constructor=f.constructor,u(y,f,g,h,v),y}if(f instanceof Boolean){const y=new Boolean(f.valueOf());return h.set(f,y),u(y,f,g,h,v),y}if(f instanceof Number){const y=new Number(f.valueOf());return h.set(f,y),u(y,f,g,h,v),y}if(f instanceof String){const y=new String(f.valueOf());return h.set(f,y),u(y,f,g,h,v),y}if(typeof f=="object"&&c(f)){const y=Object.create(Object.getPrototypeOf(f));return h.set(f,y),u(y,f,g,h,v),y}return f}function u(f,p,g=f,h,v){const b=[...Object.keys(p),...t.getSymbols(p)];for(let y=0;y<b.length;y++){const w=b[y],S=Object.getOwnPropertyDescriptor(f,w);(S==null||S.writable)&&(f[w]=s(p[w],w,g,h,v))}}function c(f){switch(n.getTag(f)){case r.argumentsTag:case r.arrayTag:case r.arrayBufferTag:case r.dataViewTag:case r.booleanTag:case r.dateTag:case r.float32ArrayTag:case r.float64ArrayTag:case r.int8ArrayTag:case r.int16ArrayTag:case r.int32ArrayTag:case r.mapTag:case r.numberTag:case r.objectTag:case r.regexpTag:case r.setTag:case r.stringTag:case r.symbolTag:case r.uint8ArrayTag:case r.uint8ClampedArrayTag:case r.uint16ArrayTag:case r.uint32ArrayTag:return!0;default:return!1}}e.cloneDeepWith=a,e.cloneDeepWithImpl=s,e.copyProperties=u})(Mv)),Mv}var T_;function uee(){return T_||(T_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=oj();function n(r){return t.cloneDeepWithImpl(r,void 0,r,new Map,void 0)}e.cloneDeep=n})(Nv)),Nv}var k_;function cee(){return k_||(k_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=rj(),n=uee();function r(i){return i=n.cloneDeep(i),o=>t.isMatch(o,i)}e.matches=r})(Pv)),Pv}var Fv={},Vv={},Bv={},N_;function fee(){return N_||(N_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=oj(),n=X0(),r=ij();function i(o,a){return t.cloneDeepWith(o,(s,u,c,f)=>{const p=a?.(s,u,c,f);if(p!==void 0)return p;if(typeof o=="object"){if(n.getTag(o)===r.objectTag&&typeof o.constructor!="function"){const g={};return f.set(o,g),t.copyProperties(g,o,c,f),g}switch(Object.prototype.toString.call(o)){case r.numberTag:case r.stringTag:case r.booleanTag:{const g=new o.constructor(o?.valueOf());return t.copyProperties(g,o),g}case r.argumentsTag:{const g={};return t.copyProperties(g,o),g.length=o.length,g[Symbol.iterator]=o[Symbol.iterator],g}default:return}}})}e.cloneDeepWith=i})(Bv)),Bv}var M_;function dee(){return M_||(M_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=fee();function n(r){return t.cloneDeepWith(r)}e.cloneDeep=n})(Vv)),Vv}var zv={},Wv={},D_;function aj(){return D_||(D_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=/^(?:0|[1-9]\d*)$/;function n(r,i=Number.MAX_SAFE_INTEGER){switch(typeof r){case"number":return Number.isInteger(r)&&r>=0&&r<i;case"symbol":return!1;case"string":return t.test(r)}}e.isIndex=n})(Wv)),Wv}var Hv={},j_;function pee(){return j_||(j_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=X0();function n(r){return r!==null&&typeof r=="object"&&t.getTag(r)==="[object Arguments]"}e.isArguments=n})(Hv)),Hv}var L_;function hee(){return L_||(L_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=qD(),n=aj(),r=pee(),i=q0();function o(a,s){let u;if(Array.isArray(s)?u=s:typeof s=="string"&&t.isDeepKey(s)&&a?.[s]==null?u=i.toPath(s):u=[s],u.length===0)return!1;let c=a;for(let f=0;f<u.length;f++){const p=u[f];if((c==null||!Object.hasOwn(c,p))&&!((Array.isArray(c)||r.isArguments(c))&&n.isIndex(p)&&p<c.length))return!1;c=c[p]}return!0}e.has=o})(zv)),zv}var $_;function gee(){return $_||($_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=rj(),n=G0(),r=dee(),i=K0(),o=hee();function a(s,u){switch(typeof s){case"object":{Object.is(s?.valueOf(),-0)&&(s="-0");break}case"number":{s=n.toKey(s);break}}return u=r.cloneDeep(u),function(c){const f=i.get(c,s);return f===void 0?o.has(c,s):u===void 0?f===void 0:t.isMatch(f,u)}}e.matchesProperty=a})(Fv)),Fv}var F_;function mee(){return F_||(F_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=QD(),n=oee(),r=cee(),i=gee();function o(a){if(a==null)return t.identity;switch(typeof a){case"function":return a;case"object":return Array.isArray(a)&&a.length===2?i.matchesProperty(a[0],a[1]):r.matches(a);case"string":case"symbol":case"number":return n.property(a)}}e.iteratee=o})(_v)),_v}var V_;function vee(){return V_||(V_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=eee(),n=tee(),r=QD(),i=iee(),o=mee();function a(s,u=r.identity){return i.isArrayLikeObject(s)?t.uniqBy(Array.from(s),n.ary(o.iteratee(u),1)):[]}e.uniqBy=a})(vv)),vv}var Uv,B_;function yee(){return B_||(B_=1,Uv=vee().uniqBy),Uv}var bee=yee();const z_=vs(bee);function xee(e,t,n){return t===!0?z_(e,n):typeof t=="function"?z_(e,t):e}var Z0=$.createContext(null),wee=e=>e,Ut=()=>{var e=$.useContext(Z0);return e?e.store.dispatch:wee},Md=()=>{},See=()=>Md,Cee=(e,t)=>e===t;function Be(e){var t=$.useContext(Z0),n=$.useMemo(()=>t?r=>{if(r!=null)return e(r)}:Md,[t,e]);return RT.useSyncExternalStoreWithSelector(t?t.subscription.addNestedSub:See,t?t.store.getState:Md,t?t.store.getState:Md,n,Cee)}var Gv={},qv={},Kv={},W_;function Eee(){return W_||(W_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(r){return typeof r=="symbol"?1:r===null?2:r===void 0?3:r!==r?4:0}const n=(r,i,o)=>{if(r!==i){const a=t(r),s=t(i);if(a===s&&a===0){if(r<i)return o==="desc"?1:-1;if(r>i)return o==="desc"?-1:1}return o==="desc"?s-a:a-s}return 0};e.compareValues=n})(Kv)),Kv}var Yv={},Xv={},H_;function sj(){return H_||(H_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){return typeof n=="symbol"||n instanceof Symbol}e.isSymbol=t})(Xv)),Xv}var U_;function _ee(){return U_||(U_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=sj(),n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,r=/^\w*$/;function i(o,a){return Array.isArray(o)?!1:typeof o=="number"||typeof o=="boolean"||o==null||t.isSymbol(o)?!0:typeof o=="string"&&(r.test(o)||!n.test(o))||a!=null&&Object.hasOwn(a,o)}e.isKey=i})(Yv)),Yv}var G_;function Oee(){return G_||(G_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Eee(),n=_ee(),r=q0();function i(o,a,s,u){if(o==null)return[];s=u?void 0:s,Array.isArray(o)||(o=Object.values(o)),Array.isArray(a)||(a=a==null?[null]:[a]),a.length===0&&(a=[null]),Array.isArray(s)||(s=s==null?[]:[s]),s=s.map(h=>String(h));const c=(h,v)=>{let b=h;for(let y=0;y<v.length&&b!=null;++y)b=b[v[y]];return b},f=(h,v)=>v==null||h==null?v:typeof h=="object"&&"key"in h?Object.hasOwn(v,h.key)?v[h.key]:c(v,h.path):typeof h=="function"?h(v):Array.isArray(h)?c(v,h):typeof v=="object"?v[h]:v,p=a.map(h=>(Array.isArray(h)&&h.length===1&&(h=h[0]),h==null||typeof h=="function"||Array.isArray(h)||n.isKey(h)?h:{key:h,path:r.toPath(h)}));return o.map(h=>({original:h,criteria:p.map(v=>f(v,h))})).slice().sort((h,v)=>{for(let b=0;b<p.length;b++){const y=t.compareValues(h.criteria[b],v.criteria[b],s[b]);if(y!==0)return y}return 0}).map(h=>h.original)}e.orderBy=i})(qv)),qv}var Zv={},q_;function Pee(){return q_||(q_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r=1){const i=[],o=Math.floor(r),a=(s,u)=>{for(let c=0;c<s.length;c++){const f=s[c];Array.isArray(f)&&u<o?a(f,u+1):i.push(f)}};return a(n,0),i}e.flatten=t})(Zv)),Zv}var Qv={},K_;function lj(){return K_||(K_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=aj(),n=JD(),r=ej(),i=nj();function o(a,s,u){return r.isObject(u)&&(typeof s=="number"&&n.isArrayLike(u)&&t.isIndex(s)&&s<u.length||typeof s=="string"&&s in u)?i.isEqualsSameValueZero(u[s],a):!1}e.isIterateeCall=o})(Qv)),Qv}var Y_;function Aee(){return Y_||(Y_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Oee(),n=Pee(),r=lj();function i(o,...a){const s=a.length;return s>1&&r.isIterateeCall(o,a[0],a[1])?a=[]:s>2&&r.isIterateeCall(a[0],a[1],a[2])&&(a=[a[0]]),t.orderBy(o,n.flatten(a),["asc"])}e.sortBy=i})(Gv)),Gv}var Jv,X_;function Ree(){return X_||(X_=1,Jv=Aee().sortBy),Jv}var Iee=Ree();const Fh=vs(Iee);var uj=e=>e.legend.settings,Tee=e=>e.legend.size,kee=e=>e.legend.payload;K([kee,uj],(e,t)=>{var{itemSorter:n}=t,r=e.flat(1);return n?Fh(r,n):r});var dd=1;function Nee(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],[t,n]=$.useState({height:0,left:0,top:0,width:0}),r=$.useCallback(i=>{if(i!=null){var o=i.getBoundingClientRect(),a={height:o.height,left:o.left,top:o.top,width:o.width};(Math.abs(a.height-t.height)>dd||Math.abs(a.left-t.left)>dd||Math.abs(a.top-t.top)>dd||Math.abs(a.width-t.width)>dd)&&n({height:a.height,left:a.left,top:a.top,width:a.width})}},[t.width,t.height,t.top,t.left,...e]);return[t,r]}function Rn(e){return`Minified Redux error #${e}; visit https://redux.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}var Mee=typeof Symbol=="function"&&Symbol.observable||"@@observable",Z_=Mee,ey=()=>Math.random().toString(36).substring(7).split("").join("."),Dee={INIT:`@@redux/INIT${ey()}`,REPLACE:`@@redux/REPLACE${ey()}`,PROBE_UNKNOWN_ACTION:()=>`@@redux/PROBE_UNKNOWN_ACTION${ey()}`},Qa=Dee;function wc(e){if(typeof e!="object"||e===null)return!1;let t=e;for(;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t||Object.getPrototypeOf(e)===null}function jee(e){if(e===void 0)return"undefined";if(e===null)return"null";const t=typeof e;switch(t){case"boolean":case"string":case"number":case"symbol":case"function":return t}if(Array.isArray(e))return"array";if(Fee(e))return"date";if($ee(e))return"error";const n=Lee(e);switch(n){case"Symbol":case"Promise":case"WeakMap":case"WeakSet":case"Map":case"Set":return n}return Object.prototype.toString.call(e).slice(8,-1).toLowerCase().replace(/\s/g,"")}function Lee(e){return typeof e.constructor=="function"?e.constructor.name:null}function $ee(e){return e instanceof Error||typeof e.message=="string"&&e.constructor&&typeof e.constructor.stackTraceLimit=="number"}function Fee(e){return e instanceof Date?!0:typeof e.toDateString=="function"&&typeof e.getDate=="function"&&typeof e.setDate=="function"}function Yo(e){let t=typeof e;return process.env.NODE_ENV!=="production"&&(t=jee(e)),t}function cj(e,t,n){if(typeof e!="function")throw new Error(process.env.NODE_ENV==="production"?Rn(2):`Expected the root reducer to be a function. Instead, received: '${Yo(e)}'`);if(typeof t=="function"&&typeof n=="function"||typeof n=="function"&&typeof arguments[3]=="function")throw new Error(process.env.NODE_ENV==="production"?Rn(0):"It looks like you are passing several store enhancers to createStore(). This is not supported. Instead, compose them together to a single function. See https://redux.js.org/tutorials/fundamentals/part-4-store#creating-a-store-with-enhancers for an example.");if(typeof t=="function"&&typeof n>"u"&&(n=t,t=void 0),typeof n<"u"){if(typeof n!="function")throw new Error(process.env.NODE_ENV==="production"?Rn(1):`Expected the enhancer to be a function. Instead, received: '${Yo(n)}'`);return n(cj)(e,t)}let r=e,i=t,o=new Map,a=o,s=0,u=!1;function c(){a===o&&(a=new Map,o.forEach((y,w)=>{a.set(w,y)}))}function f(){if(u)throw new Error(process.env.NODE_ENV==="production"?Rn(3):"You may not call store.getState() while the reducer is executing. The reducer has already received the state as an argument. Pass it down from the top reducer instead of reading it from the store.");return i}function p(y){if(typeof y!="function")throw new Error(process.env.NODE_ENV==="production"?Rn(4):`Expected the listener to be a function. Instead, received: '${Yo(y)}'`);if(u)throw new Error(process.env.NODE_ENV==="production"?Rn(5):"You may not call store.subscribe() while the reducer is executing. If you would like to be notified after the store has been updated, subscribe from a component and invoke store.getState() in the callback to access the latest state. See https://redux.js.org/api/store#subscribelistener for more details.");let w=!0;c();const S=s++;return a.set(S,y),function(){if(w){if(u)throw new Error(process.env.NODE_ENV==="production"?Rn(6):"You may not unsubscribe from a store listener while the reducer is executing. See https://redux.js.org/api/store#subscribelistener for more details.");w=!1,c(),a.delete(S),o=null}}}function g(y){if(!wc(y))throw new Error(process.env.NODE_ENV==="production"?Rn(7):`Actions must be plain objects. Instead, the actual type was: '${Yo(y)}'. You may need to add middleware to your store setup to handle dispatching other values, such as 'redux-thunk' to handle dispatching functions. See https://redux.js.org/tutorials/fundamentals/part-4-store#middleware and https://redux.js.org/tutorials/fundamentals/part-6-async-logic#using-the-redux-thunk-middleware for examples.`);if(typeof y.type>"u")throw new Error(process.env.NODE_ENV==="production"?Rn(8):'Actions may not have an undefined "type" property. You may have misspelled an action type string constant.');if(typeof y.type!="string")throw new Error(process.env.NODE_ENV==="production"?Rn(17):`Action "type" property must be a string. Instead, the actual type was: '${Yo(y.type)}'. Value was: '${y.type}' (stringified)`);if(u)throw new Error(process.env.NODE_ENV==="production"?Rn(9):"Reducers may not dispatch actions.");try{u=!0,i=r(i,y)}finally{u=!1}return(o=a).forEach(S=>{S()}),y}function h(y){if(typeof y!="function")throw new Error(process.env.NODE_ENV==="production"?Rn(10):`Expected the nextReducer to be a function. Instead, received: '${Yo(y)}`);r=y,g({type:Qa.REPLACE})}function v(){const y=p;return{subscribe(w){if(typeof w!="object"||w===null)throw new Error(process.env.NODE_ENV==="production"?Rn(11):`Expected the observer to be an object. Instead, received: '${Yo(w)}'`);function S(){const _=w;_.next&&_.next(f())}return S(),{unsubscribe:y(S)}},[Z_](){return this}}}return g({type:Qa.INIT}),{dispatch:g,subscribe:p,getState:f,replaceReducer:h,[Z_]:v}}function Q_(e){typeof console<"u"&&typeof console.error=="function"&&console.error(e);try{throw new Error(e)}catch{}}function Vee(e,t,n,r){const i=Object.keys(t),o=n&&n.type===Qa.INIT?"preloadedState argument passed to createStore":"previous state received by the reducer";if(i.length===0)return"Store does not have a valid reducer. Make sure the argument passed to combineReducers is an object whose values are reducers.";if(!wc(e))return`The ${o} has unexpected type of "${Yo(e)}". Expected argument to be an object with the following keys: "${i.join('", "')}"`;const a=Object.keys(e).filter(s=>!t.hasOwnProperty(s)&&!r[s]);if(a.forEach(s=>{r[s]=!0}),!(n&&n.type===Qa.REPLACE)&&a.length>0)return`Unexpected ${a.length>1?"keys":"key"} "${a.join('", "')}" found in ${o}. Expected to find one of the known reducer keys instead: "${i.join('", "')}". Unexpected keys will be ignored.`}function Bee(e){Object.keys(e).forEach(t=>{const n=e[t];if(typeof n(void 0,{type:Qa.INIT})>"u")throw new Error(process.env.NODE_ENV==="production"?Rn(12):`The slice reducer for key "${t}" returned undefined during initialization. If the state passed to the reducer is undefined, you must explicitly return the initial state. The initial state may not be undefined. If you don't want to set a value for this reducer, you can use null instead of undefined.`);if(typeof n(void 0,{type:Qa.PROBE_UNKNOWN_ACTION()})>"u")throw new Error(process.env.NODE_ENV==="production"?Rn(13):`The slice reducer for key "${t}" returned undefined when probed with a random type. Don't try to handle '${Qa.INIT}' or other actions in "redux/*" namespace. They are considered private. Instead, you must return the current state for any unknown actions, unless it is undefined, in which case you must return the initial state, regardless of the action type. The initial state may not be undefined, but can be null.`)})}function fj(e){const t=Object.keys(e),n={};for(let a=0;a<t.length;a++){const s=t[a];process.env.NODE_ENV!=="production"&&typeof e[s]>"u"&&Q_(`No reducer provided for key "${s}"`),typeof e[s]=="function"&&(n[s]=e[s])}const r=Object.keys(n);let i;process.env.NODE_ENV!=="production"&&(i={});let o;try{Bee(n)}catch(a){o=a}return function(s={},u){if(o)throw o;if(process.env.NODE_ENV!=="production"){const p=Vee(s,n,u,i);p&&Q_(p)}let c=!1;const f={};for(let p=0;p<r.length;p++){const g=r[p],h=n[g],v=s[g],b=h(v,u);if(typeof b>"u"){const y=u&&u.type;throw new Error(process.env.NODE_ENV==="production"?Rn(14):`When called with an action of type ${y?`"${String(y)}"`:"(unknown type)"}, the slice reducer for key "${g}" returned undefined. To ignore an action, you must explicitly return the previous state. If you want this reducer to hold no value, you can return null instead of undefined.`)}f[g]=b,c=c||b!==v}return c=c||r.length!==Object.keys(s).length,c?f:s}}function fp(...e){return e.length===0?t=>t:e.length===1?e[0]:e.reduce((t,n)=>(...r)=>t(n(...r)))}function zee(...e){return t=>(n,r)=>{const i=t(n,r);let o=()=>{throw new Error(process.env.NODE_ENV==="production"?Rn(15):"Dispatching while constructing your middleware is not allowed. Other middleware would not be applied to this dispatch.")};const a={getState:i.getState,dispatch:(u,...c)=>o(u,...c)},s=e.map(u=>u(a));return o=fp(...s)(i.dispatch),{...i,dispatch:o}}}function Q0(e){return wc(e)&&"type"in e&&typeof e.type=="string"}var dj=Symbol.for("immer-nothing"),J_=Symbol.for("immer-draftable"),er=Symbol.for("immer-state"),Wee=process.env.NODE_ENV!=="production"?[function(e){return`The plugin for '${e}' has not been loaded into Immer. To enable the plugin, import and call \`enable${e}()\` when initializing your application.`},function(e){return`produce can only be called on things that are draftable: plain objects, arrays, Map, Set or classes that are marked with '[immerable]: true'. Got '${e}'`},"This object has been frozen and should not be mutated",function(e){return"Cannot use a proxy that has been revoked. Did you pass an object from inside an immer function to an async process? "+e},"An immer producer returned a new value *and* modified its draft. Either return a new value *or* modify the draft.","Immer forbids circular references","The first or second argument to `produce` must be a function","The third argument to `produce` must be a function or undefined","First argument to `createDraft` must be a plain object, an array, or an immerable object","First argument to `finishDraft` must be a draft returned by `createDraft`",function(e){return`'current' expects a draft, got: ${e}`},"Object.defineProperty() cannot be used on an Immer draft","Object.setPrototypeOf() cannot be used on an Immer draft","Immer only supports deleting array indices","Immer only supports setting array indices and the 'length' property",function(e){return`'original' expects a draft, got: ${e}`}]:[];function Or(e,...t){if(process.env.NODE_ENV!=="production"){const n=Wee[e],r=qa(n)?n.apply(null,t):n;throw new Error(`[Immer] ${r}`)}throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var Ar=Object,wl=Ar.getPrototypeOf,dp="constructor",Vh="prototype",Eb="configurable",pp="enumerable",Dd="writable",Zu="value",yo=e=>!!e&&!!e[er];function hi(e){return e?pj(e)||zh(e)||!!e[J_]||!!e[dp]?.[J_]||Wh(e)||Hh(e):!1}var Hee=Ar[Vh][dp].toString(),eO=new WeakMap;function pj(e){if(!e||!J0(e))return!1;const t=wl(e);if(t===null||t===Ar[Vh])return!0;const n=Ar.hasOwnProperty.call(t,dp)&&t[dp];if(n===Object)return!0;if(!qa(n))return!1;let r=eO.get(n);return r===void 0&&(r=Function.toString.call(n),eO.set(n,r)),r===Hee}function Bh(e,t,n=!0){Sc(e)===0?(n?Reflect.ownKeys(e):Ar.keys(e)).forEach(i=>{t(i,e[i],e)}):e.forEach((r,i)=>t(i,r,e))}function Sc(e){const t=e[er];return t?t.type_:zh(e)?1:Wh(e)?2:Hh(e)?3:0}var tO=(e,t,n=Sc(e))=>n===2?e.has(t):Ar[Vh].hasOwnProperty.call(e,t),_b=(e,t,n=Sc(e))=>n===2?e.get(t):e[t],hp=(e,t,n,r=Sc(e))=>{r===2?e.set(t,n):r===3?e.add(n):e[t]=n};function Uee(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}var zh=Array.isArray,Wh=e=>e instanceof Map,Hh=e=>e instanceof Set,J0=e=>typeof e=="object",qa=e=>typeof e=="function",ty=e=>typeof e=="boolean";function Gee(e){const t=+e;return Number.isInteger(t)&&String(t)===e}var oo=e=>e.copy_||e.base_,ew=e=>e.modified_?e.copy_:e.base_;function Ob(e,t){if(Wh(e))return new Map(e);if(Hh(e))return new Set(e);if(zh(e))return Array[Vh].slice.call(e);const n=pj(e);if(t===!0||t==="class_only"&&!n){const r=Ar.getOwnPropertyDescriptors(e);delete r[er];let i=Reflect.ownKeys(r);for(let o=0;o<i.length;o++){const a=i[o],s=r[a];s[Dd]===!1&&(s[Dd]=!0,s[Eb]=!0),(s.get||s.set)&&(r[a]={[Eb]:!0,[Dd]:!0,[pp]:s[pp],[Zu]:e[a]})}return Ar.create(wl(e),r)}else{const r=wl(e);if(r!==null&&n)return{...e};const i=Ar.create(r);return Ar.assign(i,e)}}function tw(e,t=!1){return Uh(e)||yo(e)||!hi(e)||(Sc(e)>1&&Ar.defineProperties(e,{set:pd,add:pd,clear:pd,delete:pd}),Ar.freeze(e),t&&Bh(e,(n,r)=>{tw(r,!0)},!1)),e}function qee(){Or(2)}var pd={[Zu]:qee};function Uh(e){return e===null||!J0(e)?!0:Ar.isFrozen(e)}var gp="MapSet",Pb="Patches",nO="ArrayMethods",hj={};function cs(e){const t=hj[e];return t||Or(0,e),t}var rO=e=>!!hj[e],Qu,gj=()=>Qu,Kee=(e,t)=>({drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0,handledSet_:new Set,processedForPatches_:new Set,mapSetPlugin_:rO(gp)?cs(gp):void 0,arrayMethodsPlugin_:rO(nO)?cs(nO):void 0});function iO(e,t){t&&(e.patchPlugin_=cs(Pb),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function Ab(e){Rb(e),e.drafts_.forEach(Yee),e.drafts_=null}function Rb(e){e===Qu&&(Qu=e.parent_)}var oO=e=>Qu=Kee(Qu,e);function Yee(e){const t=e[er];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function aO(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];if(e!==void 0&&e!==n){n[er].modified_&&(Ab(t),Or(4)),hi(e)&&(e=sO(t,e));const{patchPlugin_:i}=t;i&&i.generateReplacementPatches_(n[er].base_,e,t)}else e=sO(t,n);return Xee(t,e,!0),Ab(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==dj?e:void 0}function sO(e,t){if(Uh(t))return t;const n=t[er];if(!n)return mp(t,e.handledSet_,e);if(!Gh(n,e))return t;if(!n.modified_)return n.base_;if(!n.finalized_){const{callbacks_:r}=n;if(r)for(;r.length>0;)r.pop()(e);yj(n,e)}return n.copy_}function Xee(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&tw(t,n)}function mj(e){e.finalized_=!0,e.scope_.unfinalizedDrafts_--}var Gh=(e,t)=>e.scope_===t,Zee=[];function vj(e,t,n,r){const i=oo(e),o=e.type_;if(r!==void 0&&_b(i,r,o)===t){hp(i,r,n,o);return}if(!e.draftLocations_){const s=e.draftLocations_=new Map;Bh(i,(u,c)=>{if(yo(c)){const f=s.get(c)||[];f.push(u),s.set(c,f)}})}const a=e.draftLocations_.get(t)??Zee;for(const s of a)hp(i,s,n,o)}function Qee(e,t,n){e.callbacks_.push(function(i){const o=t;if(!o||!Gh(o,i))return;i.mapSetPlugin_?.fixSetContents(o);const a=ew(o);vj(e,o.draft_??o,a,n),yj(o,i)})}function yj(e,t){if(e.modified_&&!e.finalized_&&(e.type_===3||e.type_===1&&e.allIndicesReassigned_||(e.assigned_?.size??0)>0)){const{patchPlugin_:r}=t;if(r){const i=r.getPath(e);i&&r.generatePatches_(e,i,t)}mj(e)}}function Jee(e,t,n){const{scope_:r}=e;if(yo(n)){const i=n[er];Gh(i,r)&&i.callbacks_.push(function(){jd(e);const a=ew(i);vj(e,n,a,t)})}else hi(n)&&e.callbacks_.push(function(){const o=oo(e);e.type_===3?o.has(n)&&mp(n,r.handledSet_,r):_b(o,t,e.type_)===n&&r.drafts_.length>1&&(e.assigned_.get(t)??!1)===!0&&e.copy_&&mp(_b(e.copy_,t,e.type_),r.handledSet_,r)})}function mp(e,t,n){return!n.immer_.autoFreeze_&&n.unfinalizedDrafts_<1||yo(e)||t.has(e)||!hi(e)||Uh(e)||(t.add(e),Bh(e,(r,i)=>{if(yo(i)){const o=i[er];if(Gh(o,n)){const a=ew(o);hp(e,r,a,e.type_),mj(o)}}else hi(i)&&mp(i,t,n)})),e}function ete(e,t){const n=zh(e),r={type_:n?1:0,scope_:t?t.scope_:gj(),modified_:!1,finalized_:!1,assigned_:void 0,parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1,callbacks_:void 0};let i=r,o=vp;n&&(i=[r],o=Ju);const{revoke:a,proxy:s}=Proxy.revocable(i,o);return r.draft_=s,r.revoke_=a,[s,r]}var vp={get(e,t){if(t===er)return e;let n=e.scope_.arrayMethodsPlugin_;const r=e.type_===1&&typeof t=="string";if(r&&n?.isArrayOperationMethod(t))return n.createMethodInterceptor(e,t);const i=oo(e);if(!tO(i,t,e.type_))return tte(e,i,t);const o=i[t];if(e.finalized_||!hi(o)||r&&e.operationMethod&&n?.isMutatingArrayMethod(e.operationMethod)&&Gee(t))return o;if(o===ny(e.base_,t)){jd(e);const a=e.type_===1?+t:t,s=Tb(e.scope_,o,e,a);return e.copy_[a]=s}return o},has(e,t){return t in oo(e)},ownKeys(e){return Reflect.ownKeys(oo(e))},set(e,t,n){const r=bj(oo(e),t);if(r?.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){const i=ny(oo(e),t),o=i?.[er];if(o&&o.base_===n)return e.copy_[t]=n,e.assigned_.set(t,!1),!0;if(Uee(n,i)&&(n!==void 0||tO(e.base_,t,e.type_)))return!0;jd(e),Ib(e)}return e.copy_[t]===n&&(n!==void 0||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_.set(t,!0),Jee(e,t,n)),!0},deleteProperty(e,t){return jd(e),ny(e.base_,t)!==void 0||t in e.base_?(e.assigned_.set(t,!1),Ib(e)):e.assigned_.delete(t),e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const n=oo(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{[Dd]:!0,[Eb]:e.type_!==1||t!=="length",[pp]:r[pp],[Zu]:n[t]}},defineProperty(){Or(11)},getPrototypeOf(e){return wl(e.base_)},setPrototypeOf(){Or(12)}},Ju={};for(let e in vp){let t=vp[e];Ju[e]=function(){const n=arguments;return n[0]=n[0][0],t.apply(this,n)}}Ju.deleteProperty=function(e,t){return process.env.NODE_ENV!=="production"&&isNaN(parseInt(t))&&Or(13),Ju.set.call(this,e,t,void 0)};Ju.set=function(e,t,n){return process.env.NODE_ENV!=="production"&&t!=="length"&&isNaN(parseInt(t))&&Or(14),vp.set.call(this,e[0],t,n,e[0])};function ny(e,t){const n=e[er];return(n?oo(n):e)[t]}function tte(e,t,n){const r=bj(t,n);return r?Zu in r?r[Zu]:r.get?.call(e.draft_):void 0}function bj(e,t){if(!(t in e))return;let n=wl(e);for(;n;){const r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=wl(n)}}function Ib(e){e.modified_||(e.modified_=!0,e.parent_&&Ib(e.parent_))}function jd(e){e.copy_||(e.assigned_=new Map,e.copy_=Ob(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var nte=class{constructor(t){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.useStrictIteration_=!1,this.produce=(n,r,i)=>{if(qa(n)&&!qa(r)){const a=r;r=n;const s=this;return function(c=a,...f){return s.produce(c,p=>r.call(this,p,...f))}}qa(r)||Or(6),i!==void 0&&!qa(i)&&Or(7);let o;if(hi(n)){const a=oO(this),s=Tb(a,n,void 0);let u=!0;try{o=r(s),u=!1}finally{u?Ab(a):Rb(a)}return iO(a,i),aO(o,a)}else if(!n||!J0(n)){if(o=r(n),o===void 0&&(o=n),o===dj&&(o=void 0),this.autoFreeze_&&tw(o,!0),i){const a=[],s=[];cs(Pb).generateReplacementPatches_(n,o,{patches_:a,inversePatches_:s}),i(a,s)}return o}else Or(1,n)},this.produceWithPatches=(n,r)=>{if(qa(n))return(s,...u)=>this.produceWithPatches(s,c=>n(c,...u));let i,o;return[this.produce(n,r,(s,u)=>{i=s,o=u}),i,o]},ty(t?.autoFreeze)&&this.setAutoFreeze(t.autoFreeze),ty(t?.useStrictShallowCopy)&&this.setUseStrictShallowCopy(t.useStrictShallowCopy),ty(t?.useStrictIteration)&&this.setUseStrictIteration(t.useStrictIteration)}createDraft(t){hi(t)||Or(8),yo(t)&&(t=Jr(t));const n=oO(this),r=Tb(n,t,void 0);return r[er].isManual_=!0,Rb(n),r}finishDraft(t,n){const r=t&&t[er];(!r||!r.isManual_)&&Or(9);const{scope_:i}=r;return iO(i,n),aO(void 0,i)}setAutoFreeze(t){this.autoFreeze_=t}setUseStrictShallowCopy(t){this.useStrictShallowCopy_=t}setUseStrictIteration(t){this.useStrictIteration_=t}shouldUseStrictIteration(){return this.useStrictIteration_}applyPatches(t,n){let r;for(r=n.length-1;r>=0;r--){const o=n[r];if(o.path.length===0&&o.op==="replace"){t=o.value;break}}r>-1&&(n=n.slice(r+1));const i=cs(Pb).applyPatches_;return yo(t)?i(t,n):this.produce(t,o=>i(o,n))}};function Tb(e,t,n,r){const[i,o]=Wh(t)?cs(gp).proxyMap_(t,n):Hh(t)?cs(gp).proxySet_(t,n):ete(t,n);return(n?.scope_??gj()).drafts_.push(i),o.callbacks_=n?.callbacks_??[],o.key_=r,n&&r!==void 0?Qee(n,o,r):o.callbacks_.push(function(u){u.mapSetPlugin_?.fixSetContents(o);const{patchPlugin_:c}=u;o.modified_&&c&&c.generatePatches_(o,[],u)}),i}function Jr(e){return yo(e)||Or(10,e),xj(e)}function xj(e){if(!hi(e)||Uh(e))return e;const t=e[er];let n,r=!0;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=Ob(e,t.scope_.immer_.useStrictShallowCopy_),r=t.scope_.immer_.shouldUseStrictIteration()}else n=Ob(e,!0);return Bh(n,(i,o)=>{hp(n,i,xj(o))},r),t&&(t.finalized_=!1),n}var rte=new nte,wj=rte.produce;function Sj(e){return({dispatch:n,getState:r})=>i=>o=>typeof o=="function"?o(n,r,e):i(o)}var ite=Sj(),ote=Sj,ate=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?fp:fp.apply(null,arguments)},ste=e=>e&&typeof e.match=="function";function kr(e,t){function n(...r){if(t){let i=t(...r);if(!i)throw new Error(process.env.NODE_ENV==="production"?yt(0):"prepareAction did not return an object");return{type:e,payload:i.payload,..."meta"in i&&{meta:i.meta},..."error"in i&&{error:i.error}}}return{type:e,payload:r[0]}}return n.toString=()=>`${e}`,n.type=e,n.match=r=>Q0(r)&&r.type===e,n}function lte(e){return typeof e=="function"&&"type"in e&&ste(e)}function ute(e){const t=e?`${e}`.split("/"):[],n=t[t.length-1]||"actionCreator";return`Detected an action creator with type "${e||"unknown"}" being dispatched.
|
|
217
|
+
Make sure you're calling the action creator before dispatching, i.e. \`dispatch(${n}())\` instead of \`dispatch(${n})\`. This is necessary even if the action has no payload.`}function cte(e={}){if(process.env.NODE_ENV==="production")return()=>n=>r=>n(r);const{isActionCreator:t=lte}=e;return()=>n=>r=>(t(r)&&console.warn(ute(r.type)),n(r))}function Cj(e,t){let n=0;return{measureTime(r){const i=Date.now();try{return r()}finally{const o=Date.now();n+=o-i}},warnIfExceeded(){n>e&&console.warn(`${t} took ${n}ms, which is more than the warning threshold of ${e}ms.
|
|
189
218
|
If your state or actions are very large, you may want to disable the middleware as it might cause too much of a slowdown in development mode. See https://redux-toolkit.js.org/api/getDefaultMiddleware for instructions.
|
|
190
|
-
It is disabled in production builds, so you don't need to worry about that.`)}}}var
|
|
219
|
+
It is disabled in production builds, so you don't need to worry about that.`)}}}var Ej=class ku extends Array{constructor(...t){super(...t),Object.setPrototypeOf(this,ku.prototype)}static get[Symbol.species](){return ku}concat(...t){return super.concat.apply(this,t)}prepend(...t){return t.length===1&&Array.isArray(t[0])?new ku(...t[0].concat(this)):new ku(...t.concat(this))}};function lO(e){return hi(e)?wj(e,()=>{}):e}function hd(e,t,n){return e.has(t)?e.get(t):e.set(t,n(t)).get(t)}function fte(e){return typeof e!="object"||e==null||Object.isFrozen(e)}function dte(e,t,n){const r=_j(e,t,n);return{detectMutations(){return Oj(e,t,r,n)}}}function _j(e,t=[],n,r="",i=new Set){const o={value:n};if(!e(n)&&!i.has(n)){i.add(n),o.children={};const a=t.length>0;for(const s in n){const u=r?r+"."+s:s;a&&t.some(f=>f instanceof RegExp?f.test(u):u===f)||(o.children[s]=_j(e,t,n[s],u))}}return o}function Oj(e,t=[],n,r,i=!1,o=""){const a=n?n.value:void 0,s=a===r;if(i&&!s&&!Number.isNaN(r))return{wasMutated:!0,path:o};if(e(a)||e(r))return{wasMutated:!1};const u={};for(let f in n.children)u[f]=!0;for(let f in r)u[f]=!0;const c=t.length>0;for(let f in u){const p=o?o+"."+f:f;if(c&&t.some(v=>v instanceof RegExp?v.test(p):p===v))continue;const g=Oj(e,t,n.children[f],r[f],s,p);if(g.wasMutated)return g}return{wasMutated:!1}}function pte(e={}){if(process.env.NODE_ENV==="production")return()=>t=>n=>t(n);{let t=function(s,u,c,f){return JSON.stringify(s,n(u,f),c)},n=function(s,u){let c=[],f=[];return u||(u=function(p,g){return c[0]===g?"[Circular ~]":"[Circular ~."+f.slice(0,c.indexOf(g)).join(".")+"]"}),function(p,g){if(c.length>0){var h=c.indexOf(this);~h?c.splice(h+1):c.push(this),~h?f.splice(h,1/0,p):f.push(p),~c.indexOf(g)&&(g=u.call(this,p,g))}else c.push(g);return s==null?g:s.call(this,p,g)}},{isImmutable:r=fte,ignoredPaths:i,warnAfter:o=32}=e;const a=dte.bind(null,r,i);return({getState:s})=>{let u=s(),c=a(u),f;return p=>g=>{const h=Cj(o,"ImmutableStateInvariantMiddleware");h.measureTime(()=>{if(u=s(),f=c.detectMutations(),c=a(u),f.wasMutated)throw new Error(process.env.NODE_ENV==="production"?yt(19):`A state mutation was detected between dispatches, in the path '${f.path||""}'. This may cause incorrect behavior. (https://redux.js.org/style-guide/style-guide#do-not-mutate-state)`)});const v=p(g);return h.measureTime(()=>{if(u=s(),f=c.detectMutations(),c=a(u),f.wasMutated)throw new Error(process.env.NODE_ENV==="production"?yt(20):`A state mutation was detected inside a dispatch, in the path: ${f.path||""}. Take a look at the reducer(s) handling the action ${t(g)}. (https://redux.js.org/style-guide/style-guide#do-not-mutate-state)`)}),h.warnIfExceeded(),v}}}}function Pj(e){const t=typeof e;return e==null||t==="string"||t==="boolean"||t==="number"||Array.isArray(e)||wc(e)}function kb(e,t="",n=Pj,r,i=[],o){let a;if(!n(e))return{keyPath:t||"<root>",value:e};if(typeof e!="object"||e===null||o?.has(e))return!1;const s=r!=null?r(e):Object.entries(e),u=i.length>0;for(const[c,f]of s){const p=t?t+"."+c:c;if(!(u&&i.some(h=>h instanceof RegExp?h.test(p):p===h))){if(!n(f))return{keyPath:p,value:f};if(typeof f=="object"&&(a=kb(f,p,n,r,i,o),a))return a}}return o&&Aj(e)&&o.add(e),!1}function Aj(e){if(!Object.isFrozen(e))return!1;for(const t of Object.values(e))if(!(typeof t!="object"||t===null)&&!Aj(t))return!1;return!0}function hte(e={}){if(process.env.NODE_ENV==="production")return()=>t=>n=>t(n);{const{isSerializable:t=Pj,getEntries:n,ignoredActions:r=[],ignoredActionPaths:i=["meta.arg","meta.baseQueryMeta"],ignoredPaths:o=[],warnAfter:a=32,ignoreState:s=!1,ignoreActions:u=!1,disableCache:c=!1}=e,f=!c&&WeakSet?new WeakSet:void 0;return p=>g=>h=>{if(!Q0(h))return g(h);const v=g(h),b=Cj(a,"SerializableStateInvariantMiddleware");return!u&&!(r.length&&r.indexOf(h.type)!==-1)&&b.measureTime(()=>{const y=kb(h,"",t,n,i,f);if(y){const{keyPath:w,value:S}=y;console.error(`A non-serializable value was detected in an action, in the path: \`${w}\`. Value:`,S,`
|
|
191
220
|
Take a look at the logic that dispatched this action: `,h,`
|
|
192
221
|
(See https://redux.js.org/faq/actions#why-should-type-be-a-string-or-at-least-serializable-why-should-my-action-types-be-constants)`,`
|
|
193
|
-
(To allow non-serializable values see: https://redux-toolkit.js.org/usage/usage-guide#working-with-non-serializable-data)`)}}),s||(b.measureTime(()=>{const y=p.getState(),w=
|
|
222
|
+
(To allow non-serializable values see: https://redux-toolkit.js.org/usage/usage-guide#working-with-non-serializable-data)`)}}),s||(b.measureTime(()=>{const y=p.getState(),w=kb(y,"",t,n,o,f);if(w){const{keyPath:S,value:E}=w;console.error(`A non-serializable value was detected in the state, in the path: \`${S}\`. Value:`,E,`
|
|
194
223
|
Take a look at the reducer(s) handling this action type: ${h.type}.
|
|
195
|
-
(See https://redux.js.org/faq/organizing-state#can-i-put-functions-promises-or-other-non-serializable-items-in-my-store-state)`)}}),b.warnIfExceeded()),v}}}function sd(e){return typeof e=="boolean"}var yJ=()=>function(t){const{thunk:n=!0,immutableCheck:r=!0,serializableCheck:i=!0,actionCreatorCheck:o=!0}=t??{};let a=new xD;if(n&&(sd(n)?a.push(sJ):a.push(lJ(n.extraArgument))),process.env.NODE_ENV!=="production"){if(r){let s={};sd(r)||(s=r),a.unshift(mJ(s))}if(i){let s={};sd(i)||(s=i),a.push(vJ(s))}if(o){let s={};sd(o)||(s=o),a.unshift(pJ(s))}}return a},_D="RTK_autoBatch",Mt=()=>e=>({payload:e,meta:{[_D]:!0}}),V_=e=>t=>{setTimeout(t,e)},OD=(e={type:"raf"})=>t=>(...n)=>{const r=t(...n);let i=!0,o=!1,a=!1;const s=new Set,u=e.type==="tick"?queueMicrotask:e.type==="raf"?typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:V_(10):e.type==="callback"?e.queueNotification:V_(e.timeout),c=()=>{a=!1,o&&(o=!1,s.forEach(d=>d()))};return Object.assign({},r,{subscribe(d){const p=()=>i&&d(),g=r.subscribe(p);return s.add(d),()=>{g(),s.delete(d)}},dispatch(d){try{return i=!d?.meta?.[_D],o=!i,o&&(a||(a=!0,u(c))),r.dispatch(d)}finally{i=!0}}})},bJ=e=>function(n){const{autoBatch:r=!0}=n??{};let i=new xD(e);return r&&i.push(OD(typeof r=="object"?r:void 0)),i};function xJ(e){const t=yJ(),{reducer:n=void 0,middleware:r,devTools:i=!0,duplicateMiddlewareCheck:o=!0,preloadedState:a=void 0,enhancers:s=void 0}=e||{};let u;if(typeof n=="function")u=n;else if(pc(n))u=sD(n);else throw new Error(process.env.NODE_ENV==="production"?mt(1):"`reducer` is a required argument, and must be a function or an object of functions that can be passed to combineReducers");if(process.env.NODE_ENV!=="production"&&r&&typeof r!="function")throw new Error(process.env.NODE_ENV==="production"?mt(2):"`middleware` field must be a callback");let c;if(typeof r=="function"){if(c=r(t),process.env.NODE_ENV!=="production"&&!Array.isArray(c))throw new Error(process.env.NODE_ENV==="production"?mt(3):"when using a middleware builder function, an array of middleware must be returned")}else c=t();if(process.env.NODE_ENV!=="production"&&c.some(b=>typeof b!="function"))throw new Error(process.env.NODE_ENV==="production"?mt(4):"each middleware provided to configureStore must be a function");if(process.env.NODE_ENV!=="production"&&o){let b=new Set;c.forEach(y=>{if(b.has(y))throw new Error(process.env.NODE_ENV==="production"?mt(42):"Duplicate middleware references found when creating the store. Ensure that each middleware is only included once.");b.add(y)})}let d=rp;i&&(d=uJ({trace:process.env.NODE_ENV!=="production",...typeof i=="object"&&i}));const p=UQ(...c),g=bJ(p);if(process.env.NODE_ENV!=="production"&&s&&typeof s!="function")throw new Error(process.env.NODE_ENV==="production"?mt(5):"`enhancers` field must be a callback");let h=typeof s=="function"?s(g):g();if(process.env.NODE_ENV!=="production"&&!Array.isArray(h))throw new Error(process.env.NODE_ENV==="production"?mt(6):"`enhancers` callback must return an array");if(process.env.NODE_ENV!=="production"&&h.some(b=>typeof b!="function"))throw new Error(process.env.NODE_ENV==="production"?mt(7):"each enhancer provided to configureStore must be a function");process.env.NODE_ENV!=="production"&&c.length&&!h.includes(p)&&console.error("middlewares were provided, but middleware enhancer was not included in final enhancers - make sure to call `getDefaultEnhancers`");const v=d(...h);return aD(u,a,v)}function PD(e){const t={},n=[];let r;const i={addCase(o,a){if(process.env.NODE_ENV!=="production"){if(n.length>0)throw new Error(process.env.NODE_ENV==="production"?mt(26):"`builder.addCase` should only be called before calling `builder.addMatcher`");if(r)throw new Error(process.env.NODE_ENV==="production"?mt(27):"`builder.addCase` should only be called before calling `builder.addDefaultCase`")}const s=typeof o=="string"?o:o.type;if(!s)throw new Error(process.env.NODE_ENV==="production"?mt(28):"`builder.addCase` cannot be called with an empty action type");if(s in t)throw new Error(process.env.NODE_ENV==="production"?mt(29):`\`builder.addCase\` cannot be called with two reducers for the same action type '${s}'`);return t[s]=a,i},addAsyncThunk(o,a){if(process.env.NODE_ENV!=="production"&&r)throw new Error(process.env.NODE_ENV==="production"?mt(43):"`builder.addAsyncThunk` should only be called before calling `builder.addDefaultCase`");return a.pending&&(t[o.pending.type]=a.pending),a.rejected&&(t[o.rejected.type]=a.rejected),a.fulfilled&&(t[o.fulfilled.type]=a.fulfilled),a.settled&&n.push({matcher:o.settled,reducer:a.settled}),i},addMatcher(o,a){if(process.env.NODE_ENV!=="production"&&r)throw new Error(process.env.NODE_ENV==="production"?mt(30):"`builder.addMatcher` should only be called before calling `builder.addDefaultCase`");return n.push({matcher:o,reducer:a}),i},addDefaultCase(o){if(process.env.NODE_ENV!=="production"&&r)throw new Error(process.env.NODE_ENV==="production"?mt(31):"`builder.addDefaultCase` can only be called once");return r=o,i}};return e(i),[t,n,r]}function wJ(e){return typeof e=="function"}function CJ(e,t){if(process.env.NODE_ENV!=="production"&&typeof t=="object")throw new Error(process.env.NODE_ENV==="production"?mt(8):"The object notation for `createReducer` has been removed. Please use the 'builder callback' notation instead: https://redux-toolkit.js.org/api/createReducer");let[n,r,i]=PD(t),o;if(wJ(e))o=()=>F_(e());else{const s=F_(e);o=()=>s}function a(s=o(),u){let c=[n[u.type],...r.filter(({matcher:d})=>d(u)).map(({reducer:d})=>d)];return c.filter(d=>!!d).length===0&&(c=[i]),c.reduce((d,p)=>{if(p)if(po(d)){const h=p(d,u);return h===void 0?d:h}else{if(di(d))return vD(d,g=>p(g,u));{const g=p(d,u);if(g===void 0){if(d===null)return d;throw Error("A case reducer on a non-draftable value must not return undefined")}return g}}return d},s)}return a.getInitialState=o,a}var SJ="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",EJ=(e=21)=>{let t="",n=e;for(;n--;)t+=SJ[Math.random()*64|0];return t},_J=Symbol.for("rtk-slice-createasyncthunk");function OJ(e,t){return`${e}/${t}`}function PJ({creators:e}={}){const t=e?.asyncThunk?.[_J];return function(r){const{name:i,reducerPath:o=i}=r;if(!i)throw new Error(process.env.NODE_ENV==="production"?mt(11):"`name` is a required option for createSlice");typeof process<"u"&&process.env.NODE_ENV==="development"&&r.initialState===void 0&&console.error("You must provide an `initialState` value that is not `undefined`. You may have misspelled `initialState`");const a=(typeof r.reducers=="function"?r.reducers(RJ()):r.reducers)||{},s=Object.keys(a),u={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},c={addCase(E,_){const O=typeof E=="string"?E:E.type;if(!O)throw new Error(process.env.NODE_ENV==="production"?mt(12):"`context.addCase` cannot be called with an empty action type");if(O in u.sliceCaseReducersByType)throw new Error(process.env.NODE_ENV==="production"?mt(13):"`context.addCase` cannot be called with two reducers for the same action type: "+O);return u.sliceCaseReducersByType[O]=_,c},addMatcher(E,_){return u.sliceMatchers.push({matcher:E,reducer:_}),c},exposeAction(E,_){return u.actionCreators[E]=_,c},exposeCaseReducer(E,_){return u.sliceCaseReducersByName[E]=_,c}};s.forEach(E=>{const _=a[E],O={reducerName:E,type:OJ(i,E),createNotation:typeof r.reducers=="function"};TJ(_)?NJ(O,_,c,t):IJ(O,_,c)});function d(){if(process.env.NODE_ENV!=="production"&&typeof r.extraReducers=="object")throw new Error(process.env.NODE_ENV==="production"?mt(14):"The object notation for `createSlice.extraReducers` has been removed. Please use the 'builder callback' notation instead: https://redux-toolkit.js.org/api/createSlice");const[E={},_=[],O=void 0]=typeof r.extraReducers=="function"?PD(r.extraReducers):[r.extraReducers],R={...E,...u.sliceCaseReducersByType};return CJ(r.initialState,I=>{for(let k in R)I.addCase(k,R[k]);for(let k of u.sliceMatchers)I.addMatcher(k.matcher,k.reducer);for(let k of _)I.addMatcher(k.matcher,k.reducer);O&&I.addDefaultCase(O)})}const p=E=>E,g=new Map,h=new WeakMap;let v;function b(E,_){return v||(v=d()),v(E,_)}function y(){return v||(v=d()),v.getInitialState()}function w(E,_=!1){function O(I){let k=I[E];if(typeof k>"u"){if(_)k=ad(h,O,y);else if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV==="production"?mt(15):"selectSlice returned undefined for an uninjected slice reducer")}return k}function R(I=p){const k=ad(g,_,()=>new WeakMap);return ad(k,I,()=>{const B={};for(const[L,V]of Object.entries(r.selectors??{}))B[L]=AJ(V,I,()=>ad(h,I,y),_);return B})}return{reducerPath:E,getSelectors:R,get selectors(){return R(O)},selectSlice:O}}const C={name:i,reducer:b,actions:u.actionCreators,caseReducers:u.sliceCaseReducersByName,getInitialState:y,...w(o),injectInto(E,{reducerPath:_,...O}={}){const R=_??o;return E.inject({reducerPath:R,reducer:b},O),{...C,...w(R,!0)}}};return C}}function AJ(e,t,n,r){function i(o,...a){let s=t(o);if(typeof s>"u"){if(r)s=n();else if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV==="production"?mt(16):"selectState returned undefined for an uninjected slice reducer")}return e(s,...a)}return i.unwrapped=e,i}var Wn=PJ();function RJ(){function e(t,n){return{_reducerDefinitionType:"asyncThunk",payloadCreator:t,...n}}return e.withTypes=()=>e,{reducer(t){return Object.assign({[t.name](...n){return t(...n)}}[t.name],{_reducerDefinitionType:"reducer"})},preparedReducer(t,n){return{_reducerDefinitionType:"reducerWithPrepare",prepare:t,reducer:n}},asyncThunk:e}}function IJ({type:e,reducerName:t,createNotation:n},r,i){let o,a;if("reducer"in r){if(n&&!kJ(r))throw new Error(process.env.NODE_ENV==="production"?mt(17):"Please use the `create.preparedReducer` notation for prepared action creators with the `create` notation.");o=r.reducer,a=r.prepare}else o=r;i.addCase(e,o).exposeCaseReducer(t,o).exposeAction(t,a?Tr(e,a):Tr(e))}function TJ(e){return e._reducerDefinitionType==="asyncThunk"}function kJ(e){return e._reducerDefinitionType==="reducerWithPrepare"}function NJ({type:e,reducerName:t},n,r,i){if(!i)throw new Error(process.env.NODE_ENV==="production"?mt(18):"Cannot use `create.asyncThunk` in the built-in `createSlice`. Use `buildCreateSlice({ creators: { asyncThunk: asyncThunkCreator } })` to create a customised version of `createSlice`.");const{payloadCreator:o,fulfilled:a,pending:s,rejected:u,settled:c,options:d}=n,p=i(e,o,d);r.exposeAction(t,p),a&&r.addCase(p.fulfilled,a),s&&r.addCase(p.pending,s),u&&r.addCase(p.rejected,u),c&&r.addMatcher(p.settled,c),r.exposeCaseReducer(t,{fulfilled:a||ld,pending:s||ld,rejected:u||ld,settled:c||ld})}function ld(){}var MJ="task",AD="listener",RD="completed",jx="cancelled",DJ=`task-${jx}`,jJ=`task-${RD}`,db=`${AD}-${jx}`,LJ=`${AD}-${RD}`,Th=class{constructor(e){this.code=e,this.message=`${MJ} ${jx} (reason: ${e})`}name="TaskAbortError";message},Lx=(e,t)=>{if(typeof e!="function")throw new TypeError(process.env.NODE_ENV==="production"?mt(32):`${t} is not a function`)},cp=()=>{},ID=(e,t=cp)=>(e.catch(t),e),TD=(e,t)=>(e.addEventListener("abort",t,{once:!0}),()=>e.removeEventListener("abort",t)),qa=e=>{if(e.aborted)throw new Th(e.reason)};function kD(e,t){let n=cp;return new Promise((r,i)=>{const o=()=>i(new Th(e.reason));if(e.aborted){o();return}n=TD(e,o),t.finally(()=>n()).then(r,i)}).finally(()=>{n=cp})}var $J=async(e,t)=>{try{return await Promise.resolve(),{status:"ok",value:await e()}}catch(n){return{status:n instanceof Th?"cancelled":"rejected",error:n}}finally{t?.()}},fp=e=>t=>ID(kD(e,t).then(n=>(qa(e),n))),ND=e=>{const t=fp(e);return n=>t(new Promise(r=>setTimeout(r,n)))},{assign:ul}=Object,B_={},gc="listenerMiddleware",FJ=(e,t)=>{const n=r=>TD(e,()=>r.abort(e.reason));return(r,i)=>{Lx(r,"taskExecutor");const o=new AbortController;n(o);const a=$J(async()=>{qa(e),qa(o.signal);const s=await r({pause:fp(o.signal),delay:ND(o.signal),signal:o.signal});return qa(o.signal),s},()=>o.abort(jJ));return i?.autoJoin&&t.push(a.catch(cp)),{result:fp(e)(a),cancel(){o.abort(DJ)}}}},VJ=(e,t)=>{const n=async(r,i)=>{qa(t);let o=()=>{};const s=[new Promise((u,c)=>{let d=e({predicate:r,effect:(p,g)=>{g.unsubscribe(),u([p,g.getState(),g.getOriginalState()])}});o=()=>{d(),c()}})];i!=null&&s.push(new Promise(u=>setTimeout(u,i,null)));try{const u=await kD(t,Promise.race(s));return qa(t),u}finally{o()}};return(r,i)=>ID(n(r,i))},MD=e=>{let{type:t,actionCreator:n,matcher:r,predicate:i,effect:o}=e;if(t)i=Tr(t).match;else if(n)t=n.type,i=n.match;else if(r)i=r;else if(!i)throw new Error(process.env.NODE_ENV==="production"?mt(21):"Creating or removing a listener requires one of the known fields for matching an action");return Lx(o,"options.listener"),{predicate:i,type:t,effect:o}},DD=ul(e=>{const{type:t,predicate:n,effect:r}=MD(e);return{id:EJ(),effect:r,type:t,predicate:n,pending:new Set,unsubscribe:()=>{throw new Error(process.env.NODE_ENV==="production"?mt(22):"Unsubscribe not initialized")}}},{withTypes:()=>DD}),z_=(e,t)=>{const{type:n,effect:r,predicate:i}=MD(t);return Array.from(e.values()).find(o=>(typeof n=="string"?o.type===n:o.predicate===i)&&o.effect===r)},pb=e=>{e.pending.forEach(t=>{t.abort(db)})},BJ=(e,t)=>()=>{for(const n of t.keys())pb(n);e.clear()},W_=(e,t,n)=>{try{e(t,n)}catch(r){setTimeout(()=>{throw r},0)}},jD=ul(Tr(`${gc}/add`),{withTypes:()=>jD}),zJ=Tr(`${gc}/removeAll`),LD=ul(Tr(`${gc}/remove`),{withTypes:()=>LD}),WJ=(...e)=>{console.error(`${gc}/error`,...e)},mc=(e={})=>{const t=new Map,n=new Map,r=h=>{const v=n.get(h)??0;n.set(h,v+1)},i=h=>{const v=n.get(h)??1;v===1?n.delete(h):n.set(h,v-1)},{extra:o,onError:a=WJ}=e;Lx(a,"onError");const s=h=>(h.unsubscribe=()=>t.delete(h.id),t.set(h.id,h),v=>{h.unsubscribe(),v?.cancelActive&&pb(h)}),u=h=>{const v=z_(t,h)??DD(h);return s(v)};ul(u,{withTypes:()=>u});const c=h=>{const v=z_(t,h);return v&&(v.unsubscribe(),h.cancelActive&&pb(v)),!!v};ul(c,{withTypes:()=>c});const d=async(h,v,b,y)=>{const w=new AbortController,C=VJ(u,w.signal),E=[];try{h.pending.add(w),r(h),await Promise.resolve(h.effect(v,ul({},b,{getOriginalState:y,condition:(_,O)=>C(_,O).then(Boolean),take:C,delay:ND(w.signal),pause:fp(w.signal),extra:o,signal:w.signal,fork:FJ(w.signal,E),unsubscribe:h.unsubscribe,subscribe:()=>{t.set(h.id,h)},cancelActiveListeners:()=>{h.pending.forEach((_,O,R)=>{_!==w&&(_.abort(db),R.delete(_))})},cancel:()=>{w.abort(db),h.pending.delete(w)},throwIfCancelled:()=>{qa(w.signal)}})))}catch(_){_ instanceof Th||W_(a,_,{raisedBy:"effect"})}finally{await Promise.all(E),w.abort(LJ),i(h),h.pending.delete(w)}},p=BJ(t,n);return{middleware:h=>v=>b=>{if(!kx(b))return v(b);if(jD.match(b))return u(b.payload);if(zJ.match(b)){p();return}if(LD.match(b))return c(b.payload);let y=h.getState();const w=()=>{if(y===B_)throw new Error(process.env.NODE_ENV==="production"?mt(23):`${gc}: getOriginalState can only be called synchronously`);return y};let C;try{if(C=v(b),t.size>0){const E=h.getState(),_=Array.from(t.values());for(const O of _){let R=!1;try{R=O.predicate(b,E,y)}catch(I){R=!1,W_(a,I,{raisedBy:"predicate"})}R&&d(O,b,h,w)}}}finally{y=B_}return C},startListening:u,stopListening:c,clearListeners:p}};function mt(e){return`Minified Redux Toolkit error #${e}; visit https://redux-toolkit.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}var HJ={layoutType:"horizontal",width:0,height:0,margin:{top:5,right:5,bottom:5,left:5},scale:1},$D=Wn({name:"chartLayout",initialState:HJ,reducers:{setLayout(e,t){e.layoutType=t.payload},setChartSize(e,t){e.width=t.payload.width,e.height=t.payload.height},setMargin(e,t){var n,r,i,o;e.margin.top=(n=t.payload.top)!==null&&n!==void 0?n:0,e.margin.right=(r=t.payload.right)!==null&&r!==void 0?r:0,e.margin.bottom=(i=t.payload.bottom)!==null&&i!==void 0?i:0,e.margin.left=(o=t.payload.left)!==null&&o!==void 0?o:0},setScale(e,t){e.scale=t.payload}}}),{setMargin:UJ,setLayout:GJ,setChartSize:qJ,setScale:KJ}=$D.actions,YJ=$D.reducer;function FD(e,t,n){return Array.isArray(e)&&e&&t+n!==0?e.slice(t,n+1):e}function ct(e){return Number.isFinite(e)}function Li(e){return typeof e=="number"&&e>0&&Number.isFinite(e)}function H_(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function nl(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?H_(Object(n),!0).forEach(function(r){XJ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):H_(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function XJ(e,t,n){return(t=ZJ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ZJ(e){var t=QJ(e,"string");return typeof t=="symbol"?t:t+""}function QJ(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Mn(e,t,n){return pn(e)||pn(t)?n:ji(t)?gl(e,t,n):typeof t=="function"?t(e):n}var JJ=(e,t,n)=>{if(t&&n){var{width:r,height:i}=n,{align:o,verticalAlign:a,layout:s}=t;if((s==="vertical"||s==="horizontal"&&a==="middle")&&o!=="center"&&Te(e[o]))return nl(nl({},e),{},{[o]:e[o]+(r||0)});if((s==="horizontal"||s==="vertical"&&o==="center")&&a!=="middle"&&Te(e[a]))return nl(nl({},e),{},{[a]:e[a]+(i||0)})}return e},pa=(e,t)=>e==="horizontal"&&t==="xAxis"||e==="vertical"&&t==="yAxis"||e==="centric"&&t==="angleAxis"||e==="radial"&&t==="radiusAxis",VD=(e,t,n,r)=>{if(r)return e.map(s=>s.coordinate);var i,o,a=e.map(s=>(s.coordinate===t&&(i=!0),s.coordinate===n&&(o=!0),s.coordinate));return i||a.push(t),o||a.push(n),a},BD=(e,t,n)=>{if(!e)return null;var{duplicateDomain:r,type:i,range:o,scale:a,realScaleType:s,isCategorical:u,categoricalDomain:c,tickCount:d,ticks:p,niceTicks:g,axisType:h}=e;if(!a)return null;var v=s==="scaleBand"&&a.bandwidth?a.bandwidth()/2:2,b=i==="category"&&a.bandwidth?a.bandwidth()/v:0;if(b=h==="angleAxis"&&o&&o.length>=2?cr(o[0]-o[1])*2*b:b,p||g){var y=(p||g||[]).map((w,C)=>{var E=r?r.indexOf(w):w,_=a.map(E);return ct(_)?{coordinate:_+b,value:w,offset:b,index:C}:null}).filter(fr);return y}return u&&c?c.map((w,C)=>{var E=a.map(w);return ct(E)?{coordinate:E+b,value:w,index:C,offset:b}:null}).filter(fr):a.ticks&&d!=null?a.ticks(d).map((w,C)=>{var E=a.map(w);return ct(E)?{coordinate:E+b,value:w,index:C,offset:b}:null}).filter(fr):a.domain().map((w,C)=>{var E=a.map(w);return ct(E)?{coordinate:E+b,value:r?r[w]:w,index:C,offset:b}:null}).filter(fr)},eee=(e,t)=>{if(!t||t.length!==2||!Te(t[0])||!Te(t[1]))return e;var n=Math.min(t[0],t[1]),r=Math.max(t[0],t[1]),i=[e[0],e[1]];return(!Te(e[0])||e[0]<n)&&(i[0]=n),(!Te(e[1])||e[1]>r)&&(i[1]=r),i[0]>r&&(i[0]=r),i[1]<n&&(i[1]=n),i},tee=e=>{var t,n=e.length;if(!(n<=0)){var r=(t=e[0])===null||t===void 0?void 0:t.length;if(!(r==null||r<=0))for(var i=0;i<r;++i)for(var o=0,a=0,s=0;s<n;++s){var u=e[s],c=u?.[i];if(c!=null){var d=c[1],p=c[0],g=Di(d)?p:d;g>=0?(c[0]=o,o+=g,c[1]=o):(c[0]=a,a+=g,c[1]=a)}}}},nee=e=>{var t,n=e.length;if(!(n<=0)){var r=(t=e[0])===null||t===void 0?void 0:t.length;if(!(r==null||r<=0))for(var i=0;i<r;++i)for(var o=0,a=0;a<n;++a){var s=e[a],u=s?.[i];if(u!=null){var c=Di(u[1])?u[0]:u[1];c>=0?(u[0]=o,o+=c,u[1]=o):(u[0]=0,u[1]=0)}}}},ree={sign:tee,expand:TZ,none:ts,silhouette:kZ,wiggle:NZ,positive:nee},iee=(e,t,n)=>{var r,i=(r=ree[n])!==null&&r!==void 0?r:ts,o=IZ().keys(t).value((s,u)=>Number(Mn(s,u,0))).order(tb).offset(i),a=o(e);return a.forEach((s,u)=>{s.forEach((c,d)=>{var p=Mn(e[d],t[u],0);Array.isArray(p)&&p.length===2&&Te(p[0])&&Te(p[1])&&(c[0]=p[0],c[1]=p[1])})}),a};function oee(e){return e==null?void 0:String(e)}var U_=e=>{var{axis:t,ticks:n,offset:r,bandSize:i,entry:o,index:a}=e;if(t.type==="category")return n[a]?n[a].coordinate+r:null;var s=Mn(o,t.dataKey,t.scale.domain()[a]);if(pn(s))return null;var u=t.scale.map(s);return Te(u)?u-i/2+r:null},aee=e=>{var{numericAxis:t}=e,n=t.scale.domain();if(t.type==="number"){var r=Math.min(n[0],n[1]),i=Math.max(n[0],n[1]);return r<=0&&i>=0?0:i<0?i:r}return n[0]},see=e=>{var t=e.flat(2).filter(Te);return[Math.min(...t),Math.max(...t)]},lee=e=>[e[0]===1/0?0:e[0],e[1]===-1/0?0:e[1]],uee=(e,t,n)=>{if(e!=null)return lee(Object.keys(e).reduce((r,i)=>{var o=e[i];if(!o)return r;var{stackedData:a}=o,s=a.reduce((u,c)=>{var d=FD(c,t,n),p=see(d);return!ct(p[0])||!ct(p[1])?u:[Math.min(u[0],p[0]),Math.max(u[1],p[1])]},[1/0,-1/0]);return[Math.min(s[0],r[0]),Math.max(s[1],r[1])]},[1/0,-1/0]))},G_=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,q_=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,dp=(e,t,n)=>{if(e&&e.scale&&e.scale.bandwidth){var r=e.scale.bandwidth();if(!n||r>0)return r}if(e&&t&&t.length>=2){for(var i=Sh(t,d=>d.coordinate),o=1/0,a=1,s=i.length;a<s;a++){var u=i[a],c=i[a-1];o=Math.min((u?.coordinate||0)-(c?.coordinate||0),o)}return o===1/0?0:o}return n?void 0:0};function K_(e){var{tooltipEntrySettings:t,dataKey:n,payload:r,value:i,name:o}=e;return nl(nl({},t),{},{dataKey:n,payload:r,value:i,name:o})}function zD(e,t){if(e)return String(e);if(typeof t=="string")return t}var cee=(e,t)=>{if(t==="horizontal")return e.relativeX;if(t==="vertical")return e.relativeY},fee=(e,t)=>t==="centric"?e.angle:e.radius,xo=e=>e.layout.width,wo=e=>e.layout.height,dee=e=>e.layout.scale,WD=e=>e.layout.margin,kh=q(e=>e.cartesianAxis.xAxis,e=>Object.values(e)),Nh=q(e=>e.cartesianAxis.yAxis,e=>Object.values(e)),pee="data-recharts-item-index",hee="data-recharts-item-id",vc=60;function Y_(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function ud(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Y_(Object(n),!0).forEach(function(r){gee(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Y_(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function gee(e,t,n){return(t=mee(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function mee(e){var t=vee(e,"string");return typeof t=="symbol"?t:t+""}function vee(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var yee=e=>e.brush.height;function bee(e){var t=Nh(e);return t.reduce((n,r)=>{if(r.orientation==="left"&&!r.mirror&&!r.hide){var i=typeof r.width=="number"?r.width:vc;return n+i}return n},0)}function xee(e){var t=Nh(e);return t.reduce((n,r)=>{if(r.orientation==="right"&&!r.mirror&&!r.hide){var i=typeof r.width=="number"?r.width:vc;return n+i}return n},0)}function wee(e){var t=kh(e);return t.reduce((n,r)=>r.orientation==="top"&&!r.mirror&&!r.hide?n+r.height:n,0)}function Cee(e){var t=kh(e);return t.reduce((n,r)=>r.orientation==="bottom"&&!r.mirror&&!r.hide?n+r.height:n,0)}var wn=q([xo,wo,WD,yee,bee,xee,wee,Cee,oD,MQ],(e,t,n,r,i,o,a,s,u,c)=>{var d={left:(n.left||0)+i,right:(n.right||0)+o},p={top:(n.top||0)+a,bottom:(n.bottom||0)+s},g=ud(ud({},p),d),h=g.bottom;g.bottom+=r,g=JJ(g,u,c);var v=e-g.left-g.right,b=t-g.top-g.bottom;return ud(ud({brushBottom:h},g),{},{width:Math.max(v,0),height:Math.max(b,0)})}),See=q(wn,e=>({x:e.left,y:e.top,width:e.width,height:e.height})),$x=q(xo,wo,(e,t)=>({x:0,y:0,width:e,height:t})),Eee=j.createContext(null),pr=()=>j.useContext(Eee)!=null,Mh=e=>e.brush,Dh=q([Mh,wn,WD],(e,t,n)=>({height:e.height,x:Te(e.x)?e.x:t.left,y:Te(e.y)?e.y:t.top+t.height+t.brushBottom-(n?.bottom||0),width:Te(e.width)?e.width:t.width})),Bv={},zv={},Wv={},X_;function _ee(){return X_||(X_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r,{signal:i,edges:o}={}){let a,s=null;const u=o!=null&&o.includes("leading"),c=o==null||o.includes("trailing"),d=()=>{s!==null&&(n.apply(a,s),a=void 0,s=null)},p=()=>{c&&d(),b()};let g=null;const h=()=>{g!=null&&clearTimeout(g),g=setTimeout(()=>{g=null,p()},r)},v=()=>{g!==null&&(clearTimeout(g),g=null)},b=()=>{v(),a=void 0,s=null},y=()=>{d()},w=function(...C){if(i?.aborted)return;a=this,s=C;const E=g==null;h(),u&&E&&d()};return w.schedule=h,w.cancel=b,w.flush=y,i?.addEventListener("abort",b,{once:!0}),w}e.debounce=t})(Wv)),Wv}var Z_;function Oee(){return Z_||(Z_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=_ee();function n(r,i=0,o={}){typeof o!="object"&&(o={});const{leading:a=!1,trailing:s=!0,maxWait:u}=o,c=Array(2);a&&(c[0]="leading"),s&&(c[1]="trailing");let d,p=null;const g=t.debounce(function(...b){d=r.apply(this,b),p=null},i,{edges:c}),h=function(...b){return u!=null&&(p===null&&(p=Date.now()),Date.now()-p>=u)?(d=r.apply(this,b),p=Date.now(),g.cancel(),g.schedule(),d):(g.apply(this,b),d)},v=()=>(g.flush(),d);return h.cancel=g.cancel,h.flush=v,h}e.debounce=n})(zv)),zv}var Q_;function Pee(){return Q_||(Q_=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Oee();function n(r,i=0,o={}){const{leading:a=!0,trailing:s=!0}=o;return t.debounce(r,i,{leading:a,maxWait:i,trailing:s})}e.throttle=n})(Bv)),Bv}var Hv,J_;function Aee(){return J_||(J_=1,Hv=Pee().throttle),Hv}var Ree=Aee();const Iee=fs(Ree);var pp=function(t,n){for(var r=arguments.length,i=new Array(r>2?r-2:0),o=2;o<r;o++)i[o-2]=arguments[o];if(typeof console<"u"&&console.warn&&(n===void 0&&console.warn("LogUtils requires an error message argument"),!t))if(n===void 0)console.warn("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var a=0;console.warn(n.replace(/%s/g,()=>i[a++]))}},Ai={width:"100%",height:"100%",debounce:0,minWidth:0,initialDimension:{width:-1,height:-1}},HD=(e,t,n)=>{var{width:r=Ai.width,height:i=Ai.height,aspect:o,maxHeight:a}=n,s=ns(r)?e:Number(r),u=ns(i)?t:Number(i);return o&&o>0&&(s?u=s/o:u&&(s=u*o),a&&u!=null&&u>a&&(u=a)),{calculatedWidth:s,calculatedHeight:u}},Tee={width:0,height:0,overflow:"visible"},kee={width:0,overflowX:"visible"},Nee={height:0,overflowY:"visible"},Mee={},Dee=e=>{var{width:t,height:n}=e,r=ns(t),i=ns(n);return r&&i?Tee:r?kee:i?Nee:Mee};function jee(e){var{width:t,height:n,aspect:r}=e,i=t,o=n;return i===void 0&&o===void 0?(i=Ai.width,o=Ai.height):i===void 0?i=r&&r>0?void 0:Ai.width:o===void 0&&(o=r&&r>0?void 0:Ai.height),{width:i,height:o}}function hb(){return hb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},hb.apply(null,arguments)}function eO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function tO(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?eO(Object(n),!0).forEach(function(r){Lee(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):eO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Lee(e,t,n){return(t=$ee(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function $ee(e){var t=Fee(e,"string");return typeof t=="symbol"?t:t+""}function Fee(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var UD=j.createContext(Ai.initialDimension);function Vee(e){return Li(e.width)&&Li(e.height)}function GD(e){var{children:t,width:n,height:r}=e,i=j.useMemo(()=>({width:n,height:r}),[n,r]);return Vee(i)?x.createElement(UD.Provider,{value:i},t):null}var Fx=()=>j.useContext(UD),Bee=j.forwardRef((e,t)=>{var{aspect:n,initialDimension:r=Ai.initialDimension,width:i,height:o,minWidth:a=Ai.minWidth,minHeight:s,maxHeight:u,children:c,debounce:d=Ai.debounce,id:p,className:g,onResize:h,style:v={}}=e,b=j.useRef(null),y=j.useRef();y.current=h,j.useImperativeHandle(t,()=>b.current);var[w,C]=j.useState({containerWidth:r.width,containerHeight:r.height}),E=j.useCallback((k,B)=>{C(L=>{var V=Math.round(k),D=Math.round(B);return L.containerWidth===V&&L.containerHeight===D?L:{containerWidth:V,containerHeight:D}})},[]);j.useEffect(()=>{if(b.current==null||typeof ResizeObserver>"u")return ds;var k=D=>{var H,J=D[0];if(J!=null){var{width:te,height:G}=J.contentRect;E(te,G),(H=y.current)===null||H===void 0||H.call(y,te,G)}};d>0&&(k=Iee(k,d,{trailing:!0,leading:!1}));var B=new ResizeObserver(k),{width:L,height:V}=b.current.getBoundingClientRect();return E(L,V),B.observe(b.current),()=>{B.disconnect()}},[E,d]);var{containerWidth:_,containerHeight:O}=w;pp(!n||n>0,"The aspect(%s) must be greater than zero.",n);var{calculatedWidth:R,calculatedHeight:I}=HD(_,O,{width:i,height:o,aspect:n,maxHeight:u});return pp(R!=null&&R>0||I!=null&&I>0,`The width(%s) and height(%s) of chart should be greater than 0,
|
|
224
|
+
(See https://redux.js.org/faq/organizing-state#can-i-put-functions-promises-or-other-non-serializable-items-in-my-store-state)`)}}),b.warnIfExceeded()),v}}}function gd(e){return typeof e=="boolean"}var gte=()=>function(t){const{thunk:n=!0,immutableCheck:r=!0,serializableCheck:i=!0,actionCreatorCheck:o=!0}=t??{};let a=new Ej;if(n&&(gd(n)?a.push(ite):a.push(ote(n.extraArgument))),process.env.NODE_ENV!=="production"){if(r){let s={};gd(r)||(s=r),a.unshift(pte(s))}if(i){let s={};gd(i)||(s=i),a.push(hte(s))}if(o){let s={};gd(o)||(s=o),a.unshift(cte(s))}}return a},Rj="RTK_autoBatch",Dt=()=>e=>({payload:e,meta:{[Rj]:!0}}),uO=e=>t=>{setTimeout(t,e)},Ij=(e={type:"raf"})=>t=>(...n)=>{const r=t(...n);let i=!0,o=!1,a=!1;const s=new Set,u=e.type==="tick"?queueMicrotask:e.type==="raf"?typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame:uO(10):e.type==="callback"?e.queueNotification:uO(e.timeout),c=()=>{a=!1,o&&(o=!1,s.forEach(f=>f()))};return Object.assign({},r,{subscribe(f){const p=()=>i&&f(),g=r.subscribe(p);return s.add(f),()=>{g(),s.delete(f)}},dispatch(f){try{return i=!f?.meta?.[Rj],o=!i,o&&(a||(a=!0,u(c))),r.dispatch(f)}finally{i=!0}}})},mte=e=>function(n){const{autoBatch:r=!0}=n??{};let i=new Ej(e);return r&&i.push(Ij(typeof r=="object"?r:void 0)),i};function vte(e){const t=gte(),{reducer:n=void 0,middleware:r,devTools:i=!0,duplicateMiddlewareCheck:o=!0,preloadedState:a=void 0,enhancers:s=void 0}=e||{};let u;if(typeof n=="function")u=n;else if(wc(n))u=fj(n);else throw new Error(process.env.NODE_ENV==="production"?yt(1):"`reducer` is a required argument, and must be a function or an object of functions that can be passed to combineReducers");if(process.env.NODE_ENV!=="production"&&r&&typeof r!="function")throw new Error(process.env.NODE_ENV==="production"?yt(2):"`middleware` field must be a callback");let c;if(typeof r=="function"){if(c=r(t),process.env.NODE_ENV!=="production"&&!Array.isArray(c))throw new Error(process.env.NODE_ENV==="production"?yt(3):"when using a middleware builder function, an array of middleware must be returned")}else c=t();if(process.env.NODE_ENV!=="production"&&c.some(b=>typeof b!="function"))throw new Error(process.env.NODE_ENV==="production"?yt(4):"each middleware provided to configureStore must be a function");if(process.env.NODE_ENV!=="production"&&o){let b=new Set;c.forEach(y=>{if(b.has(y))throw new Error(process.env.NODE_ENV==="production"?yt(42):"Duplicate middleware references found when creating the store. Ensure that each middleware is only included once.");b.add(y)})}let f=fp;i&&(f=ate({trace:process.env.NODE_ENV!=="production",...typeof i=="object"&&i}));const p=zee(...c),g=mte(p);if(process.env.NODE_ENV!=="production"&&s&&typeof s!="function")throw new Error(process.env.NODE_ENV==="production"?yt(5):"`enhancers` field must be a callback");let h=typeof s=="function"?s(g):g();if(process.env.NODE_ENV!=="production"&&!Array.isArray(h))throw new Error(process.env.NODE_ENV==="production"?yt(6):"`enhancers` callback must return an array");if(process.env.NODE_ENV!=="production"&&h.some(b=>typeof b!="function"))throw new Error(process.env.NODE_ENV==="production"?yt(7):"each enhancer provided to configureStore must be a function");process.env.NODE_ENV!=="production"&&c.length&&!h.includes(p)&&console.error("middlewares were provided, but middleware enhancer was not included in final enhancers - make sure to call `getDefaultEnhancers`");const v=f(...h);return cj(u,a,v)}function Tj(e){const t={},n=[];let r;const i={addCase(o,a){if(process.env.NODE_ENV!=="production"){if(n.length>0)throw new Error(process.env.NODE_ENV==="production"?yt(26):"`builder.addCase` should only be called before calling `builder.addMatcher`");if(r)throw new Error(process.env.NODE_ENV==="production"?yt(27):"`builder.addCase` should only be called before calling `builder.addDefaultCase`")}const s=typeof o=="string"?o:o.type;if(!s)throw new Error(process.env.NODE_ENV==="production"?yt(28):"`builder.addCase` cannot be called with an empty action type");if(s in t)throw new Error(process.env.NODE_ENV==="production"?yt(29):`\`builder.addCase\` cannot be called with two reducers for the same action type '${s}'`);return t[s]=a,i},addAsyncThunk(o,a){if(process.env.NODE_ENV!=="production"&&r)throw new Error(process.env.NODE_ENV==="production"?yt(43):"`builder.addAsyncThunk` should only be called before calling `builder.addDefaultCase`");return a.pending&&(t[o.pending.type]=a.pending),a.rejected&&(t[o.rejected.type]=a.rejected),a.fulfilled&&(t[o.fulfilled.type]=a.fulfilled),a.settled&&n.push({matcher:o.settled,reducer:a.settled}),i},addMatcher(o,a){if(process.env.NODE_ENV!=="production"&&r)throw new Error(process.env.NODE_ENV==="production"?yt(30):"`builder.addMatcher` should only be called before calling `builder.addDefaultCase`");return n.push({matcher:o,reducer:a}),i},addDefaultCase(o){if(process.env.NODE_ENV!=="production"&&r)throw new Error(process.env.NODE_ENV==="production"?yt(31):"`builder.addDefaultCase` can only be called once");return r=o,i}};return e(i),[t,n,r]}function yte(e){return typeof e=="function"}function bte(e,t){if(process.env.NODE_ENV!=="production"&&typeof t=="object")throw new Error(process.env.NODE_ENV==="production"?yt(8):"The object notation for `createReducer` has been removed. Please use the 'builder callback' notation instead: https://redux-toolkit.js.org/api/createReducer");let[n,r,i]=Tj(t),o;if(yte(e))o=()=>lO(e());else{const s=lO(e);o=()=>s}function a(s=o(),u){let c=[n[u.type],...r.filter(({matcher:f})=>f(u)).map(({reducer:f})=>f)];return c.filter(f=>!!f).length===0&&(c=[i]),c.reduce((f,p)=>{if(p)if(yo(f)){const h=p(f,u);return h===void 0?f:h}else{if(hi(f))return wj(f,g=>p(g,u));{const g=p(f,u);if(g===void 0){if(f===null)return f;throw Error("A case reducer on a non-draftable value must not return undefined")}return g}}return f},s)}return a.getInitialState=o,a}var xte="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",wte=(e=21)=>{let t="",n=e;for(;n--;)t+=xte[Math.random()*64|0];return t},Ste=Symbol.for("rtk-slice-createasyncthunk");function Cte(e,t){return`${e}/${t}`}function Ete({creators:e}={}){const t=e?.asyncThunk?.[Ste];return function(r){const{name:i,reducerPath:o=i}=r;if(!i)throw new Error(process.env.NODE_ENV==="production"?yt(11):"`name` is a required option for createSlice");typeof process<"u"&&process.env.NODE_ENV==="development"&&r.initialState===void 0&&console.error("You must provide an `initialState` value that is not `undefined`. You may have misspelled `initialState`");const a=(typeof r.reducers=="function"?r.reducers(Ote()):r.reducers)||{},s=Object.keys(a),u={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},c={addCase(E,_){const P=typeof E=="string"?E:E.type;if(!P)throw new Error(process.env.NODE_ENV==="production"?yt(12):"`context.addCase` cannot be called with an empty action type");if(P in u.sliceCaseReducersByType)throw new Error(process.env.NODE_ENV==="production"?yt(13):"`context.addCase` cannot be called with two reducers for the same action type: "+P);return u.sliceCaseReducersByType[P]=_,c},addMatcher(E,_){return u.sliceMatchers.push({matcher:E,reducer:_}),c},exposeAction(E,_){return u.actionCreators[E]=_,c},exposeCaseReducer(E,_){return u.sliceCaseReducersByName[E]=_,c}};s.forEach(E=>{const _=a[E],P={reducerName:E,type:Cte(i,E),createNotation:typeof r.reducers=="function"};Ate(_)?Ite(P,_,c,t):Pte(P,_,c)});function f(){if(process.env.NODE_ENV!=="production"&&typeof r.extraReducers=="object")throw new Error(process.env.NODE_ENV==="production"?yt(14):"The object notation for `createSlice.extraReducers` has been removed. Please use the 'builder callback' notation instead: https://redux-toolkit.js.org/api/createSlice");const[E={},_=[],P=void 0]=typeof r.extraReducers=="function"?Tj(r.extraReducers):[r.extraReducers],R={...E,...u.sliceCaseReducersByType};return bte(r.initialState,I=>{for(let k in R)I.addCase(k,R[k]);for(let k of u.sliceMatchers)I.addMatcher(k.matcher,k.reducer);for(let k of _)I.addMatcher(k.matcher,k.reducer);P&&I.addDefaultCase(P)})}const p=E=>E,g=new Map,h=new WeakMap;let v;function b(E,_){return v||(v=f()),v(E,_)}function y(){return v||(v=f()),v.getInitialState()}function w(E,_=!1){function P(I){let k=I[E];if(typeof k>"u"){if(_)k=hd(h,P,y);else if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV==="production"?yt(15):"selectSlice returned undefined for an uninjected slice reducer")}return k}function R(I=p){const k=hd(g,_,()=>new WeakMap);return hd(k,I,()=>{const B={};for(const[L,V]of Object.entries(r.selectors??{}))B[L]=_te(V,I,()=>hd(h,I,y),_);return B})}return{reducerPath:E,getSelectors:R,get selectors(){return R(P)},selectSlice:P}}const S={name:i,reducer:b,actions:u.actionCreators,caseReducers:u.sliceCaseReducersByName,getInitialState:y,...w(o),injectInto(E,{reducerPath:_,...P}={}){const R=_??o;return E.inject({reducerPath:R,reducer:b},P),{...S,...w(R,!0)}}};return S}}function _te(e,t,n,r){function i(o,...a){let s=t(o);if(typeof s>"u"){if(r)s=n();else if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV==="production"?yt(16):"selectState returned undefined for an uninjected slice reducer")}return e(s,...a)}return i.unwrapped=e,i}var Hn=Ete();function Ote(){function e(t,n){return{_reducerDefinitionType:"asyncThunk",payloadCreator:t,...n}}return e.withTypes=()=>e,{reducer(t){return Object.assign({[t.name](...n){return t(...n)}}[t.name],{_reducerDefinitionType:"reducer"})},preparedReducer(t,n){return{_reducerDefinitionType:"reducerWithPrepare",prepare:t,reducer:n}},asyncThunk:e}}function Pte({type:e,reducerName:t,createNotation:n},r,i){let o,a;if("reducer"in r){if(n&&!Rte(r))throw new Error(process.env.NODE_ENV==="production"?yt(17):"Please use the `create.preparedReducer` notation for prepared action creators with the `create` notation.");o=r.reducer,a=r.prepare}else o=r;i.addCase(e,o).exposeCaseReducer(t,o).exposeAction(t,a?kr(e,a):kr(e))}function Ate(e){return e._reducerDefinitionType==="asyncThunk"}function Rte(e){return e._reducerDefinitionType==="reducerWithPrepare"}function Ite({type:e,reducerName:t},n,r,i){if(!i)throw new Error(process.env.NODE_ENV==="production"?yt(18):"Cannot use `create.asyncThunk` in the built-in `createSlice`. Use `buildCreateSlice({ creators: { asyncThunk: asyncThunkCreator } })` to create a customised version of `createSlice`.");const{payloadCreator:o,fulfilled:a,pending:s,rejected:u,settled:c,options:f}=n,p=i(e,o,f);r.exposeAction(t,p),a&&r.addCase(p.fulfilled,a),s&&r.addCase(p.pending,s),u&&r.addCase(p.rejected,u),c&&r.addMatcher(p.settled,c),r.exposeCaseReducer(t,{fulfilled:a||md,pending:s||md,rejected:u||md,settled:c||md})}function md(){}var Tte="task",kj="listener",Nj="completed",nw="cancelled",kte=`task-${nw}`,Nte=`task-${Nj}`,Nb=`${kj}-${nw}`,Mte=`${kj}-${Nj}`,qh=class{constructor(e){this.code=e,this.message=`${Tte} ${nw} (reason: ${e})`}name="TaskAbortError";message},rw=(e,t)=>{if(typeof e!="function")throw new TypeError(process.env.NODE_ENV==="production"?yt(32):`${t} is not a function`)},yp=()=>{},Mj=(e,t=yp)=>(e.catch(t),e),Dj=(e,t)=>(e.addEventListener("abort",t,{once:!0}),()=>e.removeEventListener("abort",t)),Ja=e=>{if(e.aborted)throw new qh(e.reason)};function jj(e,t){let n=yp;return new Promise((r,i)=>{const o=()=>i(new qh(e.reason));if(e.aborted){o();return}n=Dj(e,o),t.finally(()=>n()).then(r,i)}).finally(()=>{n=yp})}var Dte=async(e,t)=>{try{return await Promise.resolve(),{status:"ok",value:await e()}}catch(n){return{status:n instanceof qh?"cancelled":"rejected",error:n}}finally{t?.()}},bp=e=>t=>Mj(jj(e,t).then(n=>(Ja(e),n))),Lj=e=>{const t=bp(e);return n=>t(new Promise(r=>setTimeout(r,n)))},{assign:hl}=Object,cO={},Cc="listenerMiddleware",jte=(e,t)=>{const n=r=>Dj(e,()=>r.abort(e.reason));return(r,i)=>{rw(r,"taskExecutor");const o=new AbortController;n(o);const a=Dte(async()=>{Ja(e),Ja(o.signal);const s=await r({pause:bp(o.signal),delay:Lj(o.signal),signal:o.signal});return Ja(o.signal),s},()=>o.abort(Nte));return i?.autoJoin&&t.push(a.catch(yp)),{result:bp(e)(a),cancel(){o.abort(kte)}}}},Lte=(e,t)=>{const n=async(r,i)=>{Ja(t);let o=()=>{};const s=[new Promise((u,c)=>{let f=e({predicate:r,effect:(p,g)=>{g.unsubscribe(),u([p,g.getState(),g.getOriginalState()])}});o=()=>{f(),c()}})];i!=null&&s.push(new Promise(u=>setTimeout(u,i,null)));try{const u=await jj(t,Promise.race(s));return Ja(t),u}finally{o()}};return(r,i)=>Mj(n(r,i))},$j=e=>{let{type:t,actionCreator:n,matcher:r,predicate:i,effect:o}=e;if(t)i=kr(t).match;else if(n)t=n.type,i=n.match;else if(r)i=r;else if(!i)throw new Error(process.env.NODE_ENV==="production"?yt(21):"Creating or removing a listener requires one of the known fields for matching an action");return rw(o,"options.listener"),{predicate:i,type:t,effect:o}},Fj=hl(e=>{const{type:t,predicate:n,effect:r}=$j(e);return{id:wte(),effect:r,type:t,predicate:n,pending:new Set,unsubscribe:()=>{throw new Error(process.env.NODE_ENV==="production"?yt(22):"Unsubscribe not initialized")}}},{withTypes:()=>Fj}),fO=(e,t)=>{const{type:n,effect:r,predicate:i}=$j(t);return Array.from(e.values()).find(o=>(typeof n=="string"?o.type===n:o.predicate===i)&&o.effect===r)},Mb=e=>{e.pending.forEach(t=>{t.abort(Nb)})},$te=(e,t)=>()=>{for(const n of t.keys())Mb(n);e.clear()},dO=(e,t,n)=>{try{e(t,n)}catch(r){setTimeout(()=>{throw r},0)}},Vj=hl(kr(`${Cc}/add`),{withTypes:()=>Vj}),Fte=kr(`${Cc}/removeAll`),Bj=hl(kr(`${Cc}/remove`),{withTypes:()=>Bj}),Vte=(...e)=>{console.error(`${Cc}/error`,...e)},Ec=(e={})=>{const t=new Map,n=new Map,r=h=>{const v=n.get(h)??0;n.set(h,v+1)},i=h=>{const v=n.get(h)??1;v===1?n.delete(h):n.set(h,v-1)},{extra:o,onError:a=Vte}=e;rw(a,"onError");const s=h=>(h.unsubscribe=()=>t.delete(h.id),t.set(h.id,h),v=>{h.unsubscribe(),v?.cancelActive&&Mb(h)}),u=h=>{const v=fO(t,h)??Fj(h);return s(v)};hl(u,{withTypes:()=>u});const c=h=>{const v=fO(t,h);return v&&(v.unsubscribe(),h.cancelActive&&Mb(v)),!!v};hl(c,{withTypes:()=>c});const f=async(h,v,b,y)=>{const w=new AbortController,S=Lte(u,w.signal),E=[];try{h.pending.add(w),r(h),await Promise.resolve(h.effect(v,hl({},b,{getOriginalState:y,condition:(_,P)=>S(_,P).then(Boolean),take:S,delay:Lj(w.signal),pause:bp(w.signal),extra:o,signal:w.signal,fork:jte(w.signal,E),unsubscribe:h.unsubscribe,subscribe:()=>{t.set(h.id,h)},cancelActiveListeners:()=>{h.pending.forEach((_,P,R)=>{_!==w&&(_.abort(Nb),R.delete(_))})},cancel:()=>{w.abort(Nb),h.pending.delete(w)},throwIfCancelled:()=>{Ja(w.signal)}})))}catch(_){_ instanceof qh||dO(a,_,{raisedBy:"effect"})}finally{await Promise.all(E),w.abort(Mte),i(h),h.pending.delete(w)}},p=$te(t,n);return{middleware:h=>v=>b=>{if(!Q0(b))return v(b);if(Vj.match(b))return u(b.payload);if(Fte.match(b)){p();return}if(Bj.match(b))return c(b.payload);let y=h.getState();const w=()=>{if(y===cO)throw new Error(process.env.NODE_ENV==="production"?yt(23):`${Cc}: getOriginalState can only be called synchronously`);return y};let S;try{if(S=v(b),t.size>0){const E=h.getState(),_=Array.from(t.values());for(const P of _){let R=!1;try{R=P.predicate(b,E,y)}catch(I){R=!1,dO(a,I,{raisedBy:"predicate"})}R&&f(P,b,h,w)}}}finally{y=cO}return S},startListening:u,stopListening:c,clearListeners:p}};function yt(e){return`Minified Redux Toolkit error #${e}; visit https://redux-toolkit.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}var Bte={layoutType:"horizontal",width:0,height:0,margin:{top:5,right:5,bottom:5,left:5},scale:1},zj=Hn({name:"chartLayout",initialState:Bte,reducers:{setLayout(e,t){e.layoutType=t.payload},setChartSize(e,t){e.width=t.payload.width,e.height=t.payload.height},setMargin(e,t){var n,r,i,o;e.margin.top=(n=t.payload.top)!==null&&n!==void 0?n:0,e.margin.right=(r=t.payload.right)!==null&&r!==void 0?r:0,e.margin.bottom=(i=t.payload.bottom)!==null&&i!==void 0?i:0,e.margin.left=(o=t.payload.left)!==null&&o!==void 0?o:0},setScale(e,t){e.scale=t.payload}}}),{setMargin:zte,setLayout:Wte,setChartSize:Hte,setScale:Ute}=zj.actions,Gte=zj.reducer;function Wj(e,t,n){return Array.isArray(e)&&e&&t+n!==0?e.slice(t,n+1):e}function dt(e){return Number.isFinite(e)}function Bi(e){return typeof e=="number"&&e>0&&Number.isFinite(e)}function pO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function ll(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?pO(Object(n),!0).forEach(function(r){qte(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function qte(e,t,n){return(t=Kte(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Kte(e){var t=Yte(e,"string");return typeof t=="symbol"?t:t+""}function Yte(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Mn(e,t,n){return pn(e)||pn(t)?n:Vi(t)?xl(e,t,n):typeof t=="function"?t(e):n}var Xte=(e,t,n)=>{if(t&&n){var{width:r,height:i}=n,{align:o,verticalAlign:a,layout:s}=t;if((s==="vertical"||s==="horizontal"&&a==="middle")&&o!=="center"&&Ne(e[o]))return ll(ll({},e),{},{[o]:e[o]+(r||0)});if((s==="horizontal"||s==="vertical"&&o==="center")&&a!=="middle"&&Ne(e[a]))return ll(ll({},e),{},{[a]:e[a]+(i||0)})}return e},ba=(e,t)=>e==="horizontal"&&t==="xAxis"||e==="vertical"&&t==="yAxis"||e==="centric"&&t==="angleAxis"||e==="radial"&&t==="radiusAxis",Hj=(e,t,n,r)=>{if(r)return e.map(s=>s.coordinate);var i,o,a=e.map(s=>(s.coordinate===t&&(i=!0),s.coordinate===n&&(o=!0),s.coordinate));return i||a.push(t),o||a.push(n),a},Uj=(e,t,n)=>{if(!e)return null;var{duplicateDomain:r,type:i,range:o,scale:a,realScaleType:s,isCategorical:u,categoricalDomain:c,tickCount:f,ticks:p,niceTicks:g,axisType:h}=e;if(!a)return null;var v=s==="scaleBand"&&a.bandwidth?a.bandwidth()/2:2,b=i==="category"&&a.bandwidth?a.bandwidth()/v:0;if(b=h==="angleAxis"&&o&&o.length>=2?fr(o[0]-o[1])*2*b:b,p||g){var y=(p||g||[]).map((w,S)=>{var E=r?r.indexOf(w):w,_=a.map(E);return dt(_)?{coordinate:_+b,value:w,offset:b,index:S}:null}).filter(dr);return y}return u&&c?c.map((w,S)=>{var E=a.map(w);return dt(E)?{coordinate:E+b,value:w,index:S,offset:b}:null}).filter(dr):a.ticks&&f!=null?a.ticks(f).map((w,S)=>{var E=a.map(w);return dt(E)?{coordinate:E+b,value:w,index:S,offset:b}:null}).filter(dr):a.domain().map((w,S)=>{var E=a.map(w);return dt(E)?{coordinate:E+b,value:r?r[w]:w,index:S,offset:b}:null}).filter(dr)},Zte=(e,t)=>{if(!t||t.length!==2||!Ne(t[0])||!Ne(t[1]))return e;var n=Math.min(t[0],t[1]),r=Math.max(t[0],t[1]),i=[e[0],e[1]];return(!Ne(e[0])||e[0]<n)&&(i[0]=n),(!Ne(e[1])||e[1]>r)&&(i[1]=r),i[0]>r&&(i[0]=r),i[1]<n&&(i[1]=n),i},Qte=e=>{var t,n=e.length;if(!(n<=0)){var r=(t=e[0])===null||t===void 0?void 0:t.length;if(!(r==null||r<=0))for(var i=0;i<r;++i)for(var o=0,a=0,s=0;s<n;++s){var u=e[s],c=u?.[i];if(c!=null){var f=c[1],p=c[0],g=Fi(f)?p:f;g>=0?(c[0]=o,o+=g,c[1]=o):(c[0]=a,a+=g,c[1]=a)}}}},Jte=e=>{var t,n=e.length;if(!(n<=0)){var r=(t=e[0])===null||t===void 0?void 0:t.length;if(!(r==null||r<=0))for(var i=0;i<r;++i)for(var o=0,a=0;a<n;++a){var s=e[a],u=s?.[i];if(u!=null){var c=Fi(u[1])?u[0]:u[1];c>=0?(u[0]=o,o+=c,u[1]=o):(u[0]=0,u[1]=0)}}}},ene={sign:Qte,expand:AJ,none:ls,silhouette:RJ,wiggle:IJ,positive:Jte},tne=(e,t,n)=>{var r,i=(r=ene[n])!==null&&r!==void 0?r:ls,o=PJ().keys(t).value((s,u)=>Number(Mn(s,u,0))).order(Sb).offset(i),a=o(e);return a.forEach((s,u)=>{s.forEach((c,f)=>{var p=Mn(e[f],t[u],0);Array.isArray(p)&&p.length===2&&Ne(p[0])&&Ne(p[1])&&(c[0]=p[0],c[1]=p[1])})}),a};function nne(e){return e==null?void 0:String(e)}var hO=e=>{var{axis:t,ticks:n,offset:r,bandSize:i,entry:o,index:a}=e;if(t.type==="category")return n[a]?n[a].coordinate+r:null;var s=Mn(o,t.dataKey,t.scale.domain()[a]);if(pn(s))return null;var u=t.scale.map(s);return Ne(u)?u-i/2+r:null},rne=e=>{var{numericAxis:t}=e,n=t.scale.domain();if(t.type==="number"){var r=Math.min(n[0],n[1]),i=Math.max(n[0],n[1]);return r<=0&&i>=0?0:i<0?i:r}return n[0]},ine=e=>{var t=e.flat(2).filter(Ne);return[Math.min(...t),Math.max(...t)]},one=e=>[e[0]===1/0?0:e[0],e[1]===-1/0?0:e[1]],ane=(e,t,n)=>{if(e!=null)return one(Object.keys(e).reduce((r,i)=>{var o=e[i];if(!o)return r;var{stackedData:a}=o,s=a.reduce((u,c)=>{var f=Wj(c,t,n),p=ine(f);return!dt(p[0])||!dt(p[1])?u:[Math.min(u[0],p[0]),Math.max(u[1],p[1])]},[1/0,-1/0]);return[Math.min(s[0],r[0]),Math.max(s[1],r[1])]},[1/0,-1/0]))},gO=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,mO=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,xp=(e,t,n)=>{if(e&&e.scale&&e.scale.bandwidth){var r=e.scale.bandwidth();if(!n||r>0)return r}if(e&&t&&t.length>=2){for(var i=Fh(t,f=>f.coordinate),o=1/0,a=1,s=i.length;a<s;a++){var u=i[a],c=i[a-1];o=Math.min((u?.coordinate||0)-(c?.coordinate||0),o)}return o===1/0?0:o}return n?void 0:0};function vO(e){var{tooltipEntrySettings:t,dataKey:n,payload:r,value:i,name:o}=e;return ll(ll({},t),{},{dataKey:n,payload:r,value:i,name:o})}function Gj(e,t){if(e)return String(e);if(typeof t=="string")return t}var sne=(e,t)=>{if(t==="horizontal")return e.relativeX;if(t==="vertical")return e.relativeY},lne=(e,t)=>t==="centric"?e.angle:e.radius,_o=e=>e.layout.width,Oo=e=>e.layout.height,une=e=>e.layout.scale,qj=e=>e.layout.margin,Kh=K(e=>e.cartesianAxis.xAxis,e=>Object.values(e)),Yh=K(e=>e.cartesianAxis.yAxis,e=>Object.values(e)),cne="data-recharts-item-index",fne="data-recharts-item-id",_c=60;function yO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function vd(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?yO(Object(n),!0).forEach(function(r){dne(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):yO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function dne(e,t,n){return(t=pne(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pne(e){var t=hne(e,"string");return typeof t=="symbol"?t:t+""}function hne(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var gne=e=>e.brush.height;function mne(e){var t=Yh(e);return t.reduce((n,r)=>{if(r.orientation==="left"&&!r.mirror&&!r.hide){var i=typeof r.width=="number"?r.width:_c;return n+i}return n},0)}function vne(e){var t=Yh(e);return t.reduce((n,r)=>{if(r.orientation==="right"&&!r.mirror&&!r.hide){var i=typeof r.width=="number"?r.width:_c;return n+i}return n},0)}function yne(e){var t=Kh(e);return t.reduce((n,r)=>r.orientation==="top"&&!r.mirror&&!r.hide?n+r.height:n,0)}function bne(e){var t=Kh(e);return t.reduce((n,r)=>r.orientation==="bottom"&&!r.mirror&&!r.hide?n+r.height:n,0)}var wn=K([_o,Oo,qj,gne,mne,vne,yne,bne,uj,Tee],(e,t,n,r,i,o,a,s,u,c)=>{var f={left:(n.left||0)+i,right:(n.right||0)+o},p={top:(n.top||0)+a,bottom:(n.bottom||0)+s},g=vd(vd({},p),f),h=g.bottom;g.bottom+=r,g=Xte(g,u,c);var v=e-g.left-g.right,b=t-g.top-g.bottom;return vd(vd({brushBottom:h},g),{},{width:Math.max(v,0),height:Math.max(b,0)})}),xne=K(wn,e=>({x:e.left,y:e.top,width:e.width,height:e.height})),iw=K(_o,Oo,(e,t)=>({x:0,y:0,width:e,height:t})),wne=$.createContext(null),hr=()=>$.useContext(wne)!=null,Xh=e=>e.brush,Zh=K([Xh,wn,qj],(e,t,n)=>({height:e.height,x:Ne(e.x)?e.x:t.left,y:Ne(e.y)?e.y:t.top+t.height+t.brushBottom-(n?.bottom||0),width:Ne(e.width)?e.width:t.width})),ry={},iy={},oy={},bO;function Sne(){return bO||(bO=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r,{signal:i,edges:o}={}){let a,s=null;const u=o!=null&&o.includes("leading"),c=o==null||o.includes("trailing"),f=()=>{s!==null&&(n.apply(a,s),a=void 0,s=null)},p=()=>{c&&f(),b()};let g=null;const h=()=>{g!=null&&clearTimeout(g),g=setTimeout(()=>{g=null,p()},r)},v=()=>{g!==null&&(clearTimeout(g),g=null)},b=()=>{v(),a=void 0,s=null},y=()=>{f()},w=function(...S){if(i?.aborted)return;a=this,s=S;const E=g==null;h(),u&&E&&f()};return w.schedule=h,w.cancel=b,w.flush=y,i?.addEventListener("abort",b,{once:!0}),w}e.debounce=t})(oy)),oy}var xO;function Cne(){return xO||(xO=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Sne();function n(r,i=0,o={}){typeof o!="object"&&(o={});const{leading:a=!1,trailing:s=!0,maxWait:u}=o,c=Array(2);a&&(c[0]="leading"),s&&(c[1]="trailing");let f,p=null;const g=t.debounce(function(...b){f=r.apply(this,b),p=null},i,{edges:c}),h=function(...b){return u!=null&&(p===null&&(p=Date.now()),Date.now()-p>=u)?(f=r.apply(this,b),p=Date.now(),g.cancel(),g.schedule(),f):(g.apply(this,b),f)},v=()=>(g.flush(),f);return h.cancel=g.cancel,h.flush=v,h}e.debounce=n})(iy)),iy}var wO;function Ene(){return wO||(wO=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Cne();function n(r,i=0,o={}){const{leading:a=!0,trailing:s=!0}=o;return t.debounce(r,i,{leading:a,maxWait:i,trailing:s})}e.throttle=n})(ry)),ry}var ay,SO;function _ne(){return SO||(SO=1,ay=Ene().throttle),ay}var One=_ne();const Pne=vs(One);var wp=function(t,n){for(var r=arguments.length,i=new Array(r>2?r-2:0),o=2;o<r;o++)i[o-2]=arguments[o];if(typeof console<"u"&&console.warn&&(n===void 0&&console.warn("LogUtils requires an error message argument"),!t))if(n===void 0)console.warn("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var a=0;console.warn(n.replace(/%s/g,()=>i[a++]))}},Ti={width:"100%",height:"100%",debounce:0,minWidth:0,initialDimension:{width:-1,height:-1}},Kj=(e,t,n)=>{var{width:r=Ti.width,height:i=Ti.height,aspect:o,maxHeight:a}=n,s=us(r)?e:Number(r),u=us(i)?t:Number(i);return o&&o>0&&(s?u=s/o:u&&(s=u*o),a&&u!=null&&u>a&&(u=a)),{calculatedWidth:s,calculatedHeight:u}},Ane={width:0,height:0,overflow:"visible"},Rne={width:0,overflowX:"visible"},Ine={height:0,overflowY:"visible"},Tne={},kne=e=>{var{width:t,height:n}=e,r=us(t),i=us(n);return r&&i?Ane:r?Rne:i?Ine:Tne};function Nne(e){var{width:t,height:n,aspect:r}=e,i=t,o=n;return i===void 0&&o===void 0?(i=Ti.width,o=Ti.height):i===void 0?i=r&&r>0?void 0:Ti.width:o===void 0&&(o=r&&r>0?void 0:Ti.height),{width:i,height:o}}function Db(){return Db=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Db.apply(null,arguments)}function CO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function EO(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?CO(Object(n),!0).forEach(function(r){Mne(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):CO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Mne(e,t,n){return(t=Dne(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Dne(e){var t=jne(e,"string");return typeof t=="symbol"?t:t+""}function jne(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Yj=$.createContext(Ti.initialDimension);function Lne(e){return Bi(e.width)&&Bi(e.height)}function Xj(e){var{children:t,width:n,height:r}=e,i=$.useMemo(()=>({width:n,height:r}),[n,r]);return Lne(i)?x.createElement(Yj.Provider,{value:i},t):null}var ow=()=>$.useContext(Yj),$ne=$.forwardRef((e,t)=>{var{aspect:n,initialDimension:r=Ti.initialDimension,width:i,height:o,minWidth:a=Ti.minWidth,minHeight:s,maxHeight:u,children:c,debounce:f=Ti.debounce,id:p,className:g,onResize:h,style:v={}}=e,b=$.useRef(null),y=$.useRef();y.current=h,$.useImperativeHandle(t,()=>b.current);var[w,S]=$.useState({containerWidth:r.width,containerHeight:r.height}),E=$.useCallback((k,B)=>{S(L=>{var V=Math.round(k),D=Math.round(B);return L.containerWidth===V&&L.containerHeight===D?L:{containerWidth:V,containerHeight:D}})},[]);$.useEffect(()=>{if(b.current==null||typeof ResizeObserver>"u")return ys;var k=D=>{var W,J=D[0];if(J!=null){var{width:re,height:U}=J.contentRect;E(re,U),(W=y.current)===null||W===void 0||W.call(y,re,U)}};f>0&&(k=Pne(k,f,{trailing:!0,leading:!1}));var B=new ResizeObserver(k),{width:L,height:V}=b.current.getBoundingClientRect();return E(L,V),B.observe(b.current),()=>{B.disconnect()}},[E,f]);var{containerWidth:_,containerHeight:P}=w;wp(!n||n>0,"The aspect(%s) must be greater than zero.",n);var{calculatedWidth:R,calculatedHeight:I}=Kj(_,P,{width:i,height:o,aspect:n,maxHeight:u});return wp(R!=null&&R>0||I!=null&&I>0,`The width(%s) and height(%s) of chart should be greater than 0,
|
|
196
225
|
please check the style of container, or the props width(%s) and height(%s),
|
|
197
226
|
or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the
|
|
198
|
-
height and width.`,R,I,i,o,a,s,n),x.createElement("div",{id:p?"".concat(p):void 0,className:Pt("recharts-responsive-container",g),style:tO(tO({},v),{},{width:i,height:o,minWidth:a,minHeight:s,maxHeight:u}),ref:b},x.createElement("div",{style:Dee({width:i,height:o})},x.createElement(GD,{width:R,height:I},c)))}),zee=j.forwardRef((e,t)=>{var n=Fx();if(Li(n.width)&&Li(n.height))return e.children;var{width:r,height:i}=jee({width:e.width,height:e.height,aspect:e.aspect}),{calculatedWidth:o,calculatedHeight:a}=HD(void 0,void 0,{width:r,height:i,aspect:e.aspect,maxHeight:e.maxHeight});return Te(o)&&Te(a)?x.createElement(GD,{width:o,height:a},e.children):x.createElement(Bee,hb({},e,{width:r,height:i,ref:t}))});function Vx(e){if(e)return{x:e.x,y:e.y,upperWidth:"upperWidth"in e?e.upperWidth:e.width,lowerWidth:"lowerWidth"in e?e.lowerWidth:e.width,width:e.width,height:e.height}}var jh=()=>{var e,t=pr(),n=Le(See),r=Le(Dh),i=(e=Le(Mh))===null||e===void 0?void 0:e.padding;return!t||!r||!i?n:{width:r.width-i.left-i.right,height:r.height-i.top-i.bottom,x:i.left,y:i.top}},Wee={top:0,bottom:0,left:0,right:0,width:0,height:0,brushBottom:0},qD=()=>{var e;return(e=Le(wn))!==null&&e!==void 0?e:Wee},KD=()=>Le(xo),YD=()=>Le(wo),At=e=>e.layout.layoutType,_l=()=>Le(At),XD=()=>{var e=_l();if(e==="horizontal"||e==="vertical")return e},ZD=e=>{var t=e.layout.layoutType;if(t==="centric"||t==="radial")return t},Hee=()=>{var e=_l();return e!==void 0},yc=e=>{var t=Ht(),n=pr(),{width:r,height:i}=e,o=Fx(),a=r,s=i;return o&&(a=o.width>0?o.width:r,s=o.height>0?o.height:i),j.useEffect(()=>{!n&&Li(a)&&Li(s)&&t(qJ({width:a,height:s}))},[t,n,a,s]),null},QD=Symbol.for("immer-nothing"),nO=Symbol.for("immer-draftable"),kr=Symbol.for("immer-state"),Uee=process.env.NODE_ENV!=="production"?[function(e){return`The plugin for '${e}' has not been loaded into Immer. To enable the plugin, import and call \`enable${e}()\` when initializing your application.`},function(e){return`produce can only be called on things that are draftable: plain objects, arrays, Map, Set or classes that are marked with '[immerable]: true'. Got '${e}'`},"This object has been frozen and should not be mutated",function(e){return"Cannot use a proxy that has been revoked. Did you pass an object from inside an immer function to an async process? "+e},"An immer producer returned a new value *and* modified its draft. Either return a new value *or* modify the draft.","Immer forbids circular references","The first or second argument to `produce` must be a function","The third argument to `produce` must be a function or undefined","First argument to `createDraft` must be a plain object, an array, or an immerable object","First argument to `finishDraft` must be a draft returned by `createDraft`",function(e){return`'current' expects a draft, got: ${e}`},"Object.defineProperty() cannot be used on an Immer draft","Object.setPrototypeOf() cannot be used on an Immer draft","Immer only supports deleting array indices","Immer only supports setting array indices and the 'length' property",function(e){return`'original' expects a draft, got: ${e}`}]:[];function ur(e,...t){if(process.env.NODE_ENV!=="production"){const n=Uee[e],r=typeof n=="function"?n.apply(null,t):n;throw new Error(`[Immer] ${r}`)}throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var Gu=Object.getPrototypeOf;function vl(e){return!!e&&!!e[kr]}function is(e){return e?JD(e)||Array.isArray(e)||!!e[nO]||!!e.constructor?.[nO]||bc(e)||$h(e):!1}var Gee=Object.prototype.constructor.toString(),rO=new WeakMap;function JD(e){if(!e||typeof e!="object")return!1;const t=Object.getPrototypeOf(e);if(t===null||t===Object.prototype)return!0;const n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;if(n===Object)return!0;if(typeof n!="function")return!1;let r=rO.get(n);return r===void 0&&(r=Function.toString.call(n),rO.set(n,r)),r===Gee}function hp(e,t,n=!0){Lh(e)===0?(n?Reflect.ownKeys(e):Object.keys(e)).forEach(i=>{t(i,e[i],e)}):e.forEach((r,i)=>t(i,r,e))}function Lh(e){const t=e[kr];return t?t.type_:Array.isArray(e)?1:bc(e)?2:$h(e)?3:0}function gb(e,t){return Lh(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function ej(e,t,n){const r=Lh(e);r===2?e.set(t,n):r===3?e.add(n):e[t]=n}function qee(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function bc(e){return e instanceof Map}function $h(e){return e instanceof Set}function Fa(e){return e.copy_||e.base_}function mb(e,t){if(bc(e))return new Map(e);if($h(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);const n=JD(e);if(t===!0||t==="class_only"&&!n){const r=Object.getOwnPropertyDescriptors(e);delete r[kr];let i=Reflect.ownKeys(r);for(let o=0;o<i.length;o++){const a=i[o],s=r[a];s.writable===!1&&(s.writable=!0,s.configurable=!0),(s.get||s.set)&&(r[a]={configurable:!0,writable:!0,enumerable:s.enumerable,value:e[a]})}return Object.create(Gu(e),r)}else{const r=Gu(e);if(r!==null&&n)return{...e};const i=Object.create(r);return Object.assign(i,e)}}function Bx(e,t=!1){return Fh(e)||vl(e)||!is(e)||(Lh(e)>1&&Object.defineProperties(e,{set:cd,add:cd,clear:cd,delete:cd}),Object.freeze(e),t&&Object.values(e).forEach(n=>Bx(n,!0))),e}function Kee(){ur(2)}var cd={value:Kee};function Fh(e){return e===null||typeof e!="object"?!0:Object.isFrozen(e)}var Yee={};function os(e){const t=Yee[e];return t||ur(0,e),t}var qu;function tj(){return qu}function Xee(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function iO(e,t){t&&(os("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function vb(e){yb(e),e.drafts_.forEach(Zee),e.drafts_=null}function yb(e){e===qu&&(qu=e.parent_)}function oO(e){return qu=Xee(qu,e)}function Zee(e){const t=e[kr];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function aO(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];return e!==void 0&&e!==n?(n[kr].modified_&&(vb(t),ur(4)),is(e)&&(e=gp(t,e),t.parent_||mp(t,e)),t.patches_&&os("Patches").generateReplacementPatches_(n[kr].base_,e,t.patches_,t.inversePatches_)):e=gp(t,n,[]),vb(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==QD?e:void 0}function gp(e,t,n){if(Fh(t))return t;const r=e.immer_.shouldUseStrictIteration(),i=t[kr];if(!i)return hp(t,(o,a)=>sO(e,i,t,o,a,n),r),t;if(i.scope_!==e)return t;if(!i.modified_)return mp(e,i.base_,!0),i.base_;if(!i.finalized_){i.finalized_=!0,i.scope_.unfinalizedDrafts_--;const o=i.copy_;let a=o,s=!1;i.type_===3&&(a=new Set(o),o.clear(),s=!0),hp(a,(u,c)=>sO(e,i,o,u,c,n,s),r),mp(e,o,!1),n&&e.patches_&&os("Patches").generatePatches_(i,n,e.patches_,e.inversePatches_)}return i.copy_}function sO(e,t,n,r,i,o,a){if(i==null||typeof i!="object"&&!a)return;const s=Fh(i);if(!(s&&!a)){if(process.env.NODE_ENV!=="production"&&i===n&&ur(5),vl(i)){const u=o&&t&&t.type_!==3&&!gb(t.assigned_,r)?o.concat(r):void 0,c=gp(e,i,u);if(ej(n,r,c),vl(c))e.canAutoFreeze_=!1;else return}else a&&n.add(i);if(is(i)&&!s){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1||t&&t.base_&&t.base_[r]===i&&s)return;gp(e,i),(!t||!t.scope_.parent_)&&typeof r!="symbol"&&(bc(n)?n.has(r):Object.prototype.propertyIsEnumerable.call(n,r))&&mp(e,i)}}}function mp(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&Bx(t,n)}function Qee(e,t){const n=Array.isArray(e),r={type_:n?1:0,scope_:t?t.scope_:tj(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let i=r,o=zx;n&&(i=[r],o=Ku);const{revoke:a,proxy:s}=Proxy.revocable(i,o);return r.draft_=s,r.revoke_=a,s}var zx={get(e,t){if(t===kr)return e;const n=Fa(e);if(!gb(n,t))return Jee(e,n,t);const r=n[t];return e.finalized_||!is(r)?r:r===Uv(e.base_,t)?(Gv(e),e.copy_[t]=xb(r,e)):r},has(e,t){return t in Fa(e)},ownKeys(e){return Reflect.ownKeys(Fa(e))},set(e,t,n){const r=nj(Fa(e),t);if(r?.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){const i=Uv(Fa(e),t),o=i?.[kr];if(o&&o.base_===n)return e.copy_[t]=n,e.assigned_[t]=!1,!0;if(qee(n,i)&&(n!==void 0||gb(e.base_,t)))return!0;Gv(e),bb(e)}return e.copy_[t]===n&&(n!==void 0||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_[t]=!0),!0},deleteProperty(e,t){return Uv(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,Gv(e),bb(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const n=Fa(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:r.enumerable,value:n[t]}},defineProperty(){ur(11)},getPrototypeOf(e){return Gu(e.base_)},setPrototypeOf(){ur(12)}},Ku={};hp(zx,(e,t)=>{Ku[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}});Ku.deleteProperty=function(e,t){return process.env.NODE_ENV!=="production"&&isNaN(parseInt(t))&&ur(13),Ku.set.call(this,e,t,void 0)};Ku.set=function(e,t,n){return process.env.NODE_ENV!=="production"&&t!=="length"&&isNaN(parseInt(t))&&ur(14),zx.set.call(this,e[0],t,n,e[0])};function Uv(e,t){const n=e[kr];return(n?Fa(n):e)[t]}function Jee(e,t,n){const r=nj(t,n);return r?"value"in r?r.value:r.get?.call(e.draft_):void 0}function nj(e,t){if(!(t in e))return;let n=Gu(e);for(;n;){const r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=Gu(n)}}function bb(e){e.modified_||(e.modified_=!0,e.parent_&&bb(e.parent_))}function Gv(e){e.copy_||(e.copy_=mb(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var ete=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.useStrictIteration_=!0,this.produce=(t,n,r)=>{if(typeof t=="function"&&typeof n!="function"){const o=n;n=t;const a=this;return function(u=o,...c){return a.produce(u,d=>n.call(this,d,...c))}}typeof n!="function"&&ur(6),r!==void 0&&typeof r!="function"&&ur(7);let i;if(is(t)){const o=oO(this),a=xb(t,void 0);let s=!0;try{i=n(a),s=!1}finally{s?vb(o):yb(o)}return iO(o,r),aO(i,o)}else if(!t||typeof t!="object"){if(i=n(t),i===void 0&&(i=t),i===QD&&(i=void 0),this.autoFreeze_&&Bx(i,!0),r){const o=[],a=[];os("Patches").generateReplacementPatches_(t,i,o,a),r(o,a)}return i}else ur(1,t)},this.produceWithPatches=(t,n)=>{if(typeof t=="function")return(a,...s)=>this.produceWithPatches(a,u=>t(u,...s));let r,i;return[this.produce(t,n,(a,s)=>{r=a,i=s}),r,i]},typeof e?.autoFreeze=="boolean"&&this.setAutoFreeze(e.autoFreeze),typeof e?.useStrictShallowCopy=="boolean"&&this.setUseStrictShallowCopy(e.useStrictShallowCopy),typeof e?.useStrictIteration=="boolean"&&this.setUseStrictIteration(e.useStrictIteration)}createDraft(e){is(e)||ur(8),vl(e)&&(e=tte(e));const t=oO(this),n=xb(e,void 0);return n[kr].isManual_=!0,yb(t),n}finishDraft(e,t){const n=e&&e[kr];(!n||!n.isManual_)&&ur(9);const{scope_:r}=n;return iO(r,t),aO(void 0,r)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}setUseStrictIteration(e){this.useStrictIteration_=e}shouldUseStrictIteration(){return this.useStrictIteration_}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){const i=t[n];if(i.path.length===0&&i.op==="replace"){e=i.value;break}}n>-1&&(t=t.slice(n+1));const r=os("Patches").applyPatches_;return vl(e)?r(e,t):this.produce(e,i=>r(i,t))}};function xb(e,t){const n=bc(e)?os("MapSet").proxyMap_(e,t):$h(e)?os("MapSet").proxySet_(e,t):Qee(e,t);return(t?t.scope_:tj()).drafts_.push(n),n}function tte(e){return vl(e)||ur(10,e),rj(e)}function rj(e){if(!is(e)||Fh(e))return e;const t=e[kr];let n,r=!0;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=mb(e,t.scope_.immer_.useStrictShallowCopy_),r=t.scope_.immer_.shouldUseStrictIteration()}else n=mb(e,!0);return hp(n,(i,o)=>{ej(n,i,rj(o))},r),t&&(t.finalized_=!1),n}var nte=new ete;nte.produce;var rte={settings:{layout:"horizontal",align:"center",verticalAlign:"middle",itemSorter:"value"},size:{width:0,height:0},payload:[]},ij=Wn({name:"legend",initialState:rte,reducers:{setLegendSize(e,t){e.size.width=t.payload.width,e.size.height=t.payload.height},setLegendSettings(e,t){e.settings.align=t.payload.align,e.settings.layout=t.payload.layout,e.settings.verticalAlign=t.payload.verticalAlign,e.settings.itemSorter=t.payload.itemSorter},addLegendPayload:{reducer(e,t){e.payload.push(t.payload)},prepare:Mt()},replaceLegendPayload:{reducer(e,t){var{prev:n,next:r}=t.payload,i=Qr(e).payload.indexOf(n);i>-1&&(e.payload[i]=r)},prepare:Mt()},removeLegendPayload:{reducer(e,t){var n=Qr(e).payload.indexOf(t.payload);n>-1&&e.payload.splice(n,1)},prepare:Mt()}}}),{setLegendSize:vge,setLegendSettings:yge,addLegendPayload:ite,replaceLegendPayload:ote,removeLegendPayload:ate}=ij.actions,ste=ij.reducer,fd={exports:{}},qv={};var lO;function lte(){if(lO)return qv;lO=1;var e=j;function t(u,c){return u===c&&(u!==0||1/u===1/c)||u!==u&&c!==c}var n=typeof Object.is=="function"?Object.is:t,r=e.useSyncExternalStore,i=e.useRef,o=e.useEffect,a=e.useMemo,s=e.useDebugValue;return qv.useSyncExternalStoreWithSelector=function(u,c,d,p,g){var h=i(null);if(h.current===null){var v={hasValue:!1,value:null};h.current=v}else v=h.current;h=a(function(){function y(O){if(!w){if(w=!0,C=O,O=p(O),g!==void 0&&v.hasValue){var R=v.value;if(g(R,O))return E=R}return E=O}if(R=E,n(C,O))return R;var I=p(O);return g!==void 0&&g(R,I)?(C=O,R):(C=O,E=I)}var w=!1,C,E,_=d===void 0?null:d;return[function(){return y(c())},_===null?void 0:function(){return y(_())}]},[c,d,p,g]);var b=r(u,h[0],h[1]);return o(function(){v.hasValue=!0,v.value=b},[b]),s(b),b},qv}var Kv={};var uO;function ute(){return uO||(uO=1,process.env.NODE_ENV!=="production"&&(function(){function e(u,c){return u===c&&(u!==0||1/u===1/c)||u!==u&&c!==c}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var t=j,n=typeof Object.is=="function"?Object.is:e,r=t.useSyncExternalStore,i=t.useRef,o=t.useEffect,a=t.useMemo,s=t.useDebugValue;Kv.useSyncExternalStoreWithSelector=function(u,c,d,p,g){var h=i(null);if(h.current===null){var v={hasValue:!1,value:null};h.current=v}else v=h.current;h=a(function(){function y(O){if(!w){if(w=!0,C=O,O=p(O),g!==void 0&&v.hasValue){var R=v.value;if(g(R,O))return E=R}return E=O}if(R=E,n(C,O))return R;var I=p(O);return g!==void 0&&g(R,I)?(C=O,R):(C=O,E=I)}var w=!1,C,E,_=d===void 0?null:d;return[function(){return y(c())},_===null?void 0:function(){return y(_())}]},[c,d,p,g]);var b=r(u,h[0],h[1]);return o(function(){v.hasValue=!0,v.value=b},[b]),s(b),b},typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()),Kv}var cO;function cte(){return cO||(cO=1,process.env.NODE_ENV==="production"?fd.exports=lte():fd.exports=ute()),fd.exports}cte();function fte(e){e()}function dte(){let e=null,t=null;return{clear(){e=null,t=null},notify(){fte(()=>{let n=e;for(;n;)n.callback(),n=n.next})},get(){const n=[];let r=e;for(;r;)n.push(r),r=r.next;return n},subscribe(n){let r=!0;const i=t={callback:n,next:null,prev:t};return i.prev?i.prev.next=i:e=i,function(){!r||e===null||(r=!1,i.next?i.next.prev=i.prev:t=i.prev,i.prev?i.prev.next=i.next:e=i.next)}}}}var fO={notify(){},get:()=>[]};function pte(e,t){let n,r=fO,i=0,o=!1;function a(b){d();const y=r.subscribe(b);let w=!1;return()=>{w||(w=!0,y(),p())}}function s(){r.notify()}function u(){v.onStateChange&&v.onStateChange()}function c(){return o}function d(){i++,n||(n=e.subscribe(u),r=dte())}function p(){i--,n&&i===0&&(n(),n=void 0,r.clear(),r=fO)}function g(){o||(o=!0,d())}function h(){o&&(o=!1,p())}const v={addNestedSub:a,notifyNestedSubs:s,handleChangeWrapper:u,isSubscribed:c,trySubscribe:g,tryUnsubscribe:h,getListeners:()=>r};return v}var hte=()=>typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",gte=hte(),mte=()=>typeof navigator<"u"&&navigator.product==="ReactNative",vte=mte(),yte=()=>gte||vte?x.useLayoutEffect:x.useEffect,bte=yte();function dO(e,t){return e===t?e!==0||t!==0||1/e===1/t:e!==e&&t!==t}function xte(e,t){if(dO(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;const n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(let i=0;i<n.length;i++)if(!Object.prototype.hasOwnProperty.call(t,n[i])||!dO(e[n[i]],t[n[i]]))return!1;return!0}var wte=Symbol.for("react-redux-context"),Cte=typeof globalThis<"u"?globalThis:{};function Ste(){if(!x.createContext)return{};const e=Cte[wte]??=new Map;let t=e.get(x.createContext);return t||(t=x.createContext(null),process.env.NODE_ENV!=="production"&&(t.displayName="ReactRedux"),e.set(x.createContext,t)),t}var Ete=Ste();function _te(e){const{children:t,context:n,serverState:r,store:i}=e,o=x.useMemo(()=>{const u=pte(i),c={store:i,subscription:u,getServerState:r?()=>r:void 0};if(process.env.NODE_ENV==="production")return c;{const{identityFunctionCheck:d="once",stabilityCheck:p="once"}=e;return Object.assign(c,{stabilityCheck:p,identityFunctionCheck:d})}},[i,r]),a=x.useMemo(()=>i.getState(),[i]);bte(()=>{const{subscription:u}=o;return u.onStateChange=u.notifyNestedSubs,u.trySubscribe(),a!==i.getState()&&u.notifyNestedSubs(),()=>{u.tryUnsubscribe(),u.onStateChange=void 0}},[o,a]);const s=n||Ete;return x.createElement(s.Provider,{value:o},t)}var Ote=_te,Pte=new Set(["axisLine","tickLine","activeBar","activeDot","activeLabel","activeShape","allowEscapeViewBox","background","cursor","dot","label","line","margin","padding","position","shape","style","tick","wrapperStyle","radius","throttledEvents"]);function Ate(e,t){return e==null&&t==null?!0:typeof e=="number"&&typeof t=="number"?e===t||e!==e&&t!==t:e===t}function Vh(e,t){var n=new Set([...Object.keys(e),...Object.keys(t)]);for(var r of n)if(Pte.has(r)){if(e[r]==null&&t[r]==null)continue;if(!xte(e[r],t[r]))return!1}else if(!Ate(e[r],t[r]))return!1;return!0}function wb(){return wb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},wb.apply(null,arguments)}function pO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function fu(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?pO(Object(n),!0).forEach(function(r){Rte(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Rte(e,t,n){return(t=Ite(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ite(e){var t=Tte(e,"string");return typeof t=="symbol"?t:t+""}function Tte(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function kte(e){return Array.isArray(e)&&ji(e[0])&&ji(e[1])?e.join(" ~ "):e}var Gs={separator:" : ",contentStyle:{margin:0,padding:10,backgroundColor:"#fff",border:"1px solid #ccc",whiteSpace:"nowrap"},itemStyle:{display:"block",paddingTop:4,paddingBottom:4,color:"#000"},labelStyle:{},accessibilityLayer:!1};function Nte(e,t){return t==null?e:Sh(e,t)}var Mte=e=>{var{separator:t=Gs.separator,contentStyle:n,itemStyle:r,labelStyle:i=Gs.labelStyle,payload:o,formatter:a,itemSorter:s,wrapperClassName:u,labelClassName:c,label:d,labelFormatter:p,accessibilityLayer:g=Gs.accessibilityLayer}=e,h=()=>{if(o&&o.length){var O={padding:0,margin:0},R=Nte(o,s),I=R.map((k,B)=>{if(k.type==="none")return null;var L=k.formatter||a||kte,{value:V,name:D}=k,H=V,J=D;if(L){var te=L(V,D,k,B,o);if(Array.isArray(te))[H,J]=te;else if(te!=null)H=te;else return null}var G=fu(fu({},Gs.itemStyle),{},{color:k.color||Gs.itemStyle.color},r);return x.createElement("li",{className:"recharts-tooltip-item",key:"tooltip-item-".concat(B),style:G},ji(J)?x.createElement("span",{className:"recharts-tooltip-item-name"},J):null,ji(J)?x.createElement("span",{className:"recharts-tooltip-item-separator"},t):null,x.createElement("span",{className:"recharts-tooltip-item-value"},H),x.createElement("span",{className:"recharts-tooltip-item-unit"},k.unit||""))});return x.createElement("ul",{className:"recharts-tooltip-item-list",style:O},I)}return null},v=fu(fu({},Gs.contentStyle),n),b=fu({margin:0},i),y=!pn(d),w=y?d:"",C=Pt("recharts-default-tooltip",u),E=Pt("recharts-tooltip-label",c);y&&p&&o!==void 0&&o!==null&&(w=p(d,o));var _=g?{role:"status","aria-live":"assertive"}:{};return x.createElement("div",wb({className:C,style:v},_),x.createElement("p",{className:E,style:b},x.isValidElement(w)?w:"".concat(w)),h())},du="recharts-tooltip-wrapper",Dte={visibility:"hidden"};function jte(e){var{coordinate:t,translateX:n,translateY:r}=e;return Pt(du,{["".concat(du,"-right")]:Te(n)&&t&&Te(t.x)&&n>=t.x,["".concat(du,"-left")]:Te(n)&&t&&Te(t.x)&&n<t.x,["".concat(du,"-bottom")]:Te(r)&&t&&Te(t.y)&&r>=t.y,["".concat(du,"-top")]:Te(r)&&t&&Te(t.y)&&r<t.y})}function hO(e){var{allowEscapeViewBox:t,coordinate:n,key:r,offset:i,position:o,reverseDirection:a,tooltipDimension:s,viewBox:u,viewBoxDimension:c}=e;if(o&&Te(o[r]))return o[r];var d=n[r]-s-(i>0?i:0),p=n[r]+i;if(t[r])return a[r]?d:p;var g=u[r];if(g==null)return 0;if(a[r]){var h=d,v=g;return h<v?Math.max(p,g):Math.max(d,g)}if(c==null)return 0;var b=p+s,y=g+c;return b>y?Math.max(d,g):Math.max(p,g)}function Lte(e){var{translateX:t,translateY:n,useTranslate3d:r}=e;return{transform:r?"translate3d(".concat(t,"px, ").concat(n,"px, 0)"):"translate(".concat(t,"px, ").concat(n,"px)")}}function $te(e){var{allowEscapeViewBox:t,coordinate:n,offsetTop:r,offsetLeft:i,position:o,reverseDirection:a,tooltipBox:s,useTranslate3d:u,viewBox:c}=e,d,p,g;return s.height>0&&s.width>0&&n?(p=hO({allowEscapeViewBox:t,coordinate:n,key:"x",offset:i,position:o,reverseDirection:a,tooltipDimension:s.width,viewBox:c,viewBoxDimension:c.width}),g=hO({allowEscapeViewBox:t,coordinate:n,key:"y",offset:r,position:o,reverseDirection:a,tooltipDimension:s.height,viewBox:c,viewBoxDimension:c.height}),d=Lte({translateX:p,translateY:g,useTranslate3d:u})):d=Dte,{cssProperties:d,cssClasses:jte({translateX:p,translateY:g,coordinate:n})}}var Fte=()=>!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout),xc={isSsr:Fte()};function oj(){var[e,t]=j.useState(()=>xc.isSsr||!window.matchMedia?!1:window.matchMedia("(prefers-reduced-motion: reduce)").matches);return j.useEffect(()=>{if(window.matchMedia){var n=window.matchMedia("(prefers-reduced-motion: reduce)"),r=()=>{t(n.matches)};return n.addEventListener("change",r),()=>{n.removeEventListener("change",r)}}},[]),e}function gO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function qs(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?gO(Object(n),!0).forEach(function(r){Vte(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):gO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Vte(e,t,n){return(t=Bte(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Bte(e){var t=zte(e,"string");return typeof t=="symbol"?t:t+""}function zte(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Wte(e){if(!(e.prefersReducedMotion&&e.isAnimationActive==="auto")&&e.isAnimationActive&&e.active)return"transform ".concat(e.animationDuration,"ms ").concat(e.animationEasing)}function Hte(e){var t,n,r,i,o,a,s=oj(),[u,c]=x.useState(()=>({dismissed:!1,dismissedAtCoordinate:{x:0,y:0}}));x.useEffect(()=>{var v=b=>{if(b.key==="Escape"){var y,w,C,E;c({dismissed:!0,dismissedAtCoordinate:{x:(y=(w=e.coordinate)===null||w===void 0?void 0:w.x)!==null&&y!==void 0?y:0,y:(C=(E=e.coordinate)===null||E===void 0?void 0:E.y)!==null&&C!==void 0?C:0}})}};return document.addEventListener("keydown",v),()=>{document.removeEventListener("keydown",v)}},[(t=e.coordinate)===null||t===void 0?void 0:t.x,(n=e.coordinate)===null||n===void 0?void 0:n.y]),u.dismissed&&(((r=(i=e.coordinate)===null||i===void 0?void 0:i.x)!==null&&r!==void 0?r:0)!==u.dismissedAtCoordinate.x||((o=(a=e.coordinate)===null||a===void 0?void 0:a.y)!==null&&o!==void 0?o:0)!==u.dismissedAtCoordinate.y)&&c(qs(qs({},u),{},{dismissed:!1}));var{cssClasses:d,cssProperties:p}=$te({allowEscapeViewBox:e.allowEscapeViewBox,coordinate:e.coordinate,offsetLeft:typeof e.offset=="number"?e.offset:e.offset.x,offsetTop:typeof e.offset=="number"?e.offset:e.offset.y,position:e.position,reverseDirection:e.reverseDirection,tooltipBox:{height:e.lastBoundingBox.height,width:e.lastBoundingBox.width},useTranslate3d:e.useTranslate3d,viewBox:e.viewBox}),g=e.hasPortalFromProps?{}:qs(qs({transition:Wte({prefersReducedMotion:s,isAnimationActive:e.isAnimationActive,active:e.active,animationDuration:e.animationDuration,animationEasing:e.animationEasing})},p),{},{pointerEvents:"none",position:"absolute",top:0,left:0}),h=qs(qs({},g),{},{visibility:!u.dismissed&&e.active&&e.hasPayload?"visible":"hidden"},e.wrapperStyle);return x.createElement("div",{xmlns:"http://www.w3.org/1999/xhtml",tabIndex:-1,className:d,style:h,ref:e.innerRef},e.children)}var Ute=x.memo(Hte),aj=()=>{var e;return(e=Le(t=>t.rootProps.accessibilityLayer))!==null&&e!==void 0?e:!0};function Cb(){return Cb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Cb.apply(null,arguments)}function mO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function vO(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?mO(Object(n),!0).forEach(function(r){Gte(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):mO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Gte(e,t,n){return(t=qte(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function qte(e){var t=Kte(e,"string");return typeof t=="symbol"?t:t+""}function Kte(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var yO={curveBasisClosed:bZ,curveBasisOpen:xZ,curveBasis:yZ,curveBumpX:iZ,curveBumpY:oZ,curveLinearClosed:wZ,curveLinear:wh,curveMonotoneX:CZ,curveMonotoneY:SZ,curveNatural:EZ,curveStep:_Z,curveStepAfter:PZ,curveStepBefore:OZ},vp=e=>ct(e.x)&&ct(e.y),bO=e=>e.base!=null&&vp(e.base)&&vp(e),pu=e=>e.x,hu=e=>e.y,Yte=(e,t)=>{if(typeof e=="function")return e;var n="curve".concat(dc(e));if((n==="curveMonotone"||n==="curveBump")&&t){var r=yO["".concat(n).concat(t==="vertical"?"Y":"X")];if(r)return r}return yO[n]||wh},xO={connectNulls:!1,type:"linear"},Xte=e=>{var{type:t=xO.type,points:n=[],baseLine:r,layout:i,connectNulls:o=xO.connectNulls}=e,a=Yte(t,i),s=o?n.filter(vp):n;if(Array.isArray(r)){var u,c=n.map((v,b)=>vO(vO({},v),{},{base:r[b]}));i==="vertical"?u=rd().y(hu).x1(pu).x0(v=>v.base.x):u=rd().x(pu).y1(hu).y0(v=>v.base.y);var d=u.defined(bO).curve(a),p=o?c.filter(bO):c;return d(p)}var g;i==="vertical"&&Te(r)?g=rd().y(hu).x1(pu).x0(r):Te(r)?g=rd().x(pu).y1(hu).y0(r):g=kM().x(pu).y(hu);var h=g.defined(vp).curve(a);return h(s)},sj=e=>{var{className:t,points:n,path:r,pathRef:i}=e,o=_l();if((!n||!n.length)&&!r)return null;var a={type:e.type,points:e.points,baseLine:e.baseLine,layout:e.layout||o,connectNulls:e.connectNulls},s=n&&n.length?Xte(a):r;return x.createElement("path",Cb({},fo(e),ZZ(e),{className:Pt("recharts-curve",t),d:s===null?void 0:s,ref:i}))},Zte=["x","y","top","left","width","height","className"];function Sb(){return Sb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Sb.apply(null,arguments)}function wO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Qte(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?wO(Object(n),!0).forEach(function(r){Jte(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Jte(e,t,n){return(t=ene(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ene(e){var t=tne(e,"string");return typeof t=="symbol"?t:t+""}function tne(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function nne(e,t){if(e==null)return{};var n,r,i=rne(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function rne(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var ine=(e,t,n,r,i,o)=>"M".concat(e,",").concat(i,"v").concat(r,"M").concat(o,",").concat(t,"h").concat(n),one=e=>{var{x:t=0,y:n=0,top:r=0,left:i=0,width:o=0,height:a=0,className:s}=e,u=nne(e,Zte),c=Qte({x:t,y:n,top:r,left:i,width:o,height:a},u);return!Te(t)||!Te(n)||!Te(o)||!Te(a)||!Te(r)||!Te(i)?null:x.createElement("path",Sb({},ti(c),{className:Pt("recharts-cross",s),d:ine(t,n,o,a,r,i)}))};function ane(e,t,n,r){var i=r/2;return{stroke:"none",fill:"#ccc",x:e==="horizontal"?t.x-i:n.left+.5,y:e==="horizontal"?n.top+.5:t.y-i,width:e==="horizontal"?r:n.width-1,height:e==="horizontal"?n.height-1:r}}function CO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function SO(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?CO(Object(n),!0).forEach(function(r){sne(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):CO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function sne(e,t,n){return(t=lne(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function lne(e){var t=une(e,"string");return typeof t=="symbol"?t:t+""}function une(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var cne=e=>e.replace(/([A-Z])/g,t=>"-".concat(t.toLowerCase())),lj=(e,t,n)=>e.map(r=>"".concat(cne(r)," ").concat(t,"ms ").concat(n)).join(","),fne=(e,t)=>[Object.keys(e),Object.keys(t)].reduce((n,r)=>n.filter(i=>r.includes(i))),Yu=(e,t)=>Object.keys(t).reduce((n,r)=>SO(SO({},n),{},{[r]:e(r,t[r])}),{});function EO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function fn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?EO(Object(n),!0).forEach(function(r){dne(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):EO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function dne(e,t,n){return(t=pne(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pne(e){var t=hne(e,"string");return typeof t=="symbol"?t:t+""}function hne(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var yp=(e,t,n)=>e+(t-e)*n,Eb=e=>{var{from:t,to:n}=e;return t!==n},uj=(e,t,n)=>{var r=Yu((i,o)=>{if(Eb(o)){var[a,s]=e(o.from,o.to,o.velocity);return fn(fn({},o),{},{from:a,velocity:s})}return o},t);return n<1?Yu((i,o)=>Eb(o)&&r[i]!=null?fn(fn({},o),{},{velocity:yp(o.velocity,r[i].velocity,n),from:yp(o.from,r[i].from,n)}):o,t):uj(e,r,n-1)};function gne(e,t,n,r,i,o){var a,s=r.reduce((g,h)=>fn(fn({},g),{},{[h]:{from:e[h],velocity:0,to:t[h]}}),{}),u=()=>Yu((g,h)=>h.from,s),c=()=>!Object.values(s).filter(Eb).length,d=null,p=g=>{a||(a=g);var h=g-a,v=h/n.dt;s=uj(n,s,v),i(fn(fn(fn({},e),t),u())),a=g,c()||(d=o.setTimeout(p))};return()=>(d=o.setTimeout(p),()=>{var g;(g=d)===null||g===void 0||g()})}function mne(e,t,n,r,i,o,a){var s=null,u=i.reduce((p,g)=>{var h=e[g],v=t[g];return h==null||v==null?p:fn(fn({},p),{},{[g]:[h,v]})},{}),c,d=p=>{c||(c=p);var g=(p-c)/r,h=Yu((b,y)=>yp(...y,n(g)),u);if(o(fn(fn(fn({},e),t),h)),g<1)s=a.setTimeout(d);else{var v=Yu((b,y)=>yp(...y,n(1)),u);o(fn(fn(fn({},e),t),v))}};return()=>(s=a.setTimeout(d),()=>{var p;(p=s)===null||p===void 0||p()})}const vne=(e,t,n,r,i,o)=>{var a=fne(e,t);return n==null?()=>(i(fn(fn({},e),t)),()=>{}):n.isStepper===!0?gne(e,t,n,a,i,o):mne(e,t,n,r,a,i,o)};var bp=1e-4,cj=(e,t)=>[0,3*e,3*t-6*e,3*e-3*t+1],fj=(e,t)=>e.map((n,r)=>n*t**r).reduce((n,r)=>n+r),_O=(e,t)=>n=>{var r=cj(e,t);return fj(r,n)},yne=(e,t)=>n=>{var r=cj(e,t),i=[...r.map((o,a)=>o*a).slice(1),0];return fj(i,n)},bne=e=>{var t,n=e.split("(");if(n.length!==2||n[0]!=="cubic-bezier")return null;var r=(t=n[1])===null||t===void 0||(t=t.split(")")[0])===null||t===void 0?void 0:t.split(",");if(r==null||r.length!==4)return null;var i=r.map(o=>parseFloat(o));return[i[0],i[1],i[2],i[3]]},xne=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];if(n.length===1)switch(n[0]){case"linear":return[0,0,1,1];case"ease":return[.25,.1,.25,1];case"ease-in":return[.42,0,1,1];case"ease-out":return[.42,0,.58,1];case"ease-in-out":return[0,0,.58,1];default:{var i=bne(n[0]);if(i)return i}}return n.length===4?n:[0,0,1,1]},wne=(e,t,n,r)=>{var i=_O(e,n),o=_O(t,r),a=yne(e,n),s=c=>c>1?1:c<0?0:c,u=c=>{for(var d=c>1?1:c,p=d,g=0;g<8;++g){var h=i(p)-d,v=a(p);if(Math.abs(h-d)<bp||v<bp)return o(p);p=s(p-h/v)}return o(p)};return u.isStepper=!1,u},OO=function(){return wne(...xne(...arguments))},Cne=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},{stiff:n=100,damping:r=8,dt:i=17}=t,o=(a,s,u)=>{var c=-(a-s)*n,d=u*r,p=u+(c-d)*i/1e3,g=u*i/1e3+a;return Math.abs(g-s)<bp&&Math.abs(p)<bp?[s,0]:[g,p]};return o.isStepper=!0,o.dt=i,o},Sne=e=>{if(typeof e=="string")switch(e){case"ease":case"ease-in-out":case"ease-out":case"ease-in":case"linear":return OO(e);case"spring":return Cne();default:if(e.split("(")[0]==="cubic-bezier")return OO(e)}return typeof e=="function"?e:null};function Ene(e){var t,n=()=>null,r=!1,i=null,o=a=>{if(!r){if(Array.isArray(a)){if(!a.length)return;var s=a,[u,...c]=s;if(typeof u=="number"){i=e.setTimeout(o.bind(null,c),u);return}o(u),i=e.setTimeout(o.bind(null,c));return}typeof a=="string"&&(t=a,n(t)),typeof a=="object"&&(t=a,n(t)),typeof a=="function"&&a()}};return{stop:()=>{r=!0},start:a=>{r=!1,i&&(i(),i=null),o(a)},subscribe:a=>(n=a,()=>{n=()=>null}),getTimeoutController:()=>e}}class _ne{setTimeout(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,r=performance.now(),i=null,o=a=>{a-r>=n?t(a):typeof requestAnimationFrame=="function"&&(i=requestAnimationFrame(o))};return i=requestAnimationFrame(o),()=>{i!=null&&cancelAnimationFrame(i)}}}function One(){return Ene(new _ne)}var Pne=j.createContext(One);function Ane(e,t){var n=j.useContext(Pne);return j.useMemo(()=>t??n(e),[e,t,n])}var Rne={begin:0,duration:1e3,easing:"ease",isActive:!0,canBegin:!0,onAnimationEnd:()=>{},onAnimationStart:()=>{}},PO={t:0},Yv={t:1};function Wx(e){var t=Mr(e,Rne),{isActive:n,canBegin:r,duration:i,easing:o,begin:a,onAnimationEnd:s,onAnimationStart:u,children:c}=t,d=oj(),p=n==="auto"?!xc.isSsr&&!d:n,g=Ane(t.animationId,t.animationManager),[h,v]=j.useState(p?PO:Yv),b=j.useRef(null);return j.useEffect(()=>{p||v(Yv)},[p]),j.useEffect(()=>{if(!p||!r)return ds;var y=vne(PO,Yv,Sne(o),i,v,g.getTimeoutController()),w=()=>{b.current=y()};return g.start([u,a,w,i,s]),()=>{g.stop(),b.current&&b.current(),s()}},[p,r,i,o,a,u,s,g]),c(h.t)}function Hx(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"animation-",n=j.useRef(zu(t)),r=j.useRef(e);return r.current!==e&&(n.current=zu(t),r.current=e),n.current}var Ine=["radius"],Tne=["radius"],AO,RO,IO,TO,kO,NO,MO,DO,jO,LO;function $O(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function FO(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?$O(Object(n),!0).forEach(function(r){kne(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$O(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function kne(e,t,n){return(t=Nne(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Nne(e){var t=Mne(e,"string");return typeof t=="symbol"?t:t+""}function Mne(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function xp(){return xp=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},xp.apply(null,arguments)}function VO(e,t){if(e==null)return{};var n,r,i=Dne(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Dne(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function Si(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}var BO=(e,t,n,r,i)=>{var o=Zo(n),a=Zo(r),s=Math.min(Math.abs(o)/2,Math.abs(a)/2),u=a>=0?1:-1,c=o>=0?1:-1,d=a>=0&&o>=0||a<0&&o<0?1:0,p;if(s>0&&Array.isArray(i)){for(var g=[0,0,0,0],h=0,v=4;h<v;h++){var b,y=(b=i[h])!==null&&b!==void 0?b:0;g[h]=y>s?s:y}p=qt(AO||(AO=Si(["M",",",""])),e,t+u*g[0]),g[0]>0&&(p+=qt(RO||(RO=Si(["A ",",",",0,0,",",",",",""])),g[0],g[0],d,e+c*g[0],t)),p+=qt(IO||(IO=Si(["L ",",",""])),e+n-c*g[1],t),g[1]>0&&(p+=qt(TO||(TO=Si(["A ",",",",0,0,",`,
|
|
199
|
-
`,",",""])),g[1],g[1],
|
|
200
|
-
`,",",""])),g[2],g[2],
|
|
201
|
-
`,",",""])),g[3],g[3],
|
|
227
|
+
height and width.`,R,I,i,o,a,s,n),x.createElement("div",{id:p?"".concat(p):void 0,className:At("recharts-responsive-container",g),style:EO(EO({},v),{},{width:i,height:o,minWidth:a,minHeight:s,maxHeight:u}),ref:b},x.createElement("div",{style:kne({width:i,height:o})},x.createElement(Xj,{width:R,height:I},c)))}),Fne=$.forwardRef((e,t)=>{var n=ow();if(Bi(n.width)&&Bi(n.height))return e.children;var{width:r,height:i}=Nne({width:e.width,height:e.height,aspect:e.aspect}),{calculatedWidth:o,calculatedHeight:a}=Kj(void 0,void 0,{width:r,height:i,aspect:e.aspect,maxHeight:e.maxHeight});return Ne(o)&&Ne(a)?x.createElement(Xj,{width:o,height:a},e.children):x.createElement($ne,Db({},e,{width:r,height:i,ref:t}))});function aw(e){if(e)return{x:e.x,y:e.y,upperWidth:"upperWidth"in e?e.upperWidth:e.width,lowerWidth:"lowerWidth"in e?e.lowerWidth:e.width,width:e.width,height:e.height}}var Qh=()=>{var e,t=hr(),n=Be(xne),r=Be(Zh),i=(e=Be(Xh))===null||e===void 0?void 0:e.padding;return!t||!r||!i?n:{width:r.width-i.left-i.right,height:r.height-i.top-i.bottom,x:i.left,y:i.top}},Vne={top:0,bottom:0,left:0,right:0,width:0,height:0,brushBottom:0},Zj=()=>{var e;return(e=Be(wn))!==null&&e!==void 0?e:Vne},Qj=()=>Be(_o),Jj=()=>Be(Oo),Rt=e=>e.layout.layoutType,Tl=()=>Be(Rt),e2=()=>{var e=Tl();if(e==="horizontal"||e==="vertical")return e},t2=e=>{var t=e.layout.layoutType;if(t==="centric"||t==="radial")return t},Bne=()=>{var e=Tl();return e!==void 0},Oc=e=>{var t=Ut(),n=hr(),{width:r,height:i}=e,o=ow(),a=r,s=i;return o&&(a=o.width>0?o.width:r,s=o.height>0?o.height:i),$.useEffect(()=>{!n&&Bi(a)&&Bi(s)&&t(Hte({width:a,height:s}))},[t,n,a,s]),null},n2=Symbol.for("immer-nothing"),_O=Symbol.for("immer-draftable"),Nr=Symbol.for("immer-state"),zne=process.env.NODE_ENV!=="production"?[function(e){return`The plugin for '${e}' has not been loaded into Immer. To enable the plugin, import and call \`enable${e}()\` when initializing your application.`},function(e){return`produce can only be called on things that are draftable: plain objects, arrays, Map, Set or classes that are marked with '[immerable]: true'. Got '${e}'`},"This object has been frozen and should not be mutated",function(e){return"Cannot use a proxy that has been revoked. Did you pass an object from inside an immer function to an async process? "+e},"An immer producer returned a new value *and* modified its draft. Either return a new value *or* modify the draft.","Immer forbids circular references","The first or second argument to `produce` must be a function","The third argument to `produce` must be a function or undefined","First argument to `createDraft` must be a plain object, an array, or an immerable object","First argument to `finishDraft` must be a draft returned by `createDraft`",function(e){return`'current' expects a draft, got: ${e}`},"Object.defineProperty() cannot be used on an Immer draft","Object.setPrototypeOf() cannot be used on an Immer draft","Immer only supports deleting array indices","Immer only supports setting array indices and the 'length' property",function(e){return`'original' expects a draft, got: ${e}`}]:[];function cr(e,...t){if(process.env.NODE_ENV!=="production"){const n=zne[e],r=typeof n=="function"?n.apply(null,t):n;throw new Error(`[Immer] ${r}`)}throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var ec=Object.getPrototypeOf;function Sl(e){return!!e&&!!e[Nr]}function fs(e){return e?r2(e)||Array.isArray(e)||!!e[_O]||!!e.constructor?.[_O]||Pc(e)||eg(e):!1}var Wne=Object.prototype.constructor.toString(),OO=new WeakMap;function r2(e){if(!e||typeof e!="object")return!1;const t=Object.getPrototypeOf(e);if(t===null||t===Object.prototype)return!0;const n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;if(n===Object)return!0;if(typeof n!="function")return!1;let r=OO.get(n);return r===void 0&&(r=Function.toString.call(n),OO.set(n,r)),r===Wne}function Sp(e,t,n=!0){Jh(e)===0?(n?Reflect.ownKeys(e):Object.keys(e)).forEach(i=>{t(i,e[i],e)}):e.forEach((r,i)=>t(i,r,e))}function Jh(e){const t=e[Nr];return t?t.type_:Array.isArray(e)?1:Pc(e)?2:eg(e)?3:0}function jb(e,t){return Jh(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function i2(e,t,n){const r=Jh(e);r===2?e.set(t,n):r===3?e.add(n):e[t]=n}function Hne(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function Pc(e){return e instanceof Map}function eg(e){return e instanceof Set}function Ua(e){return e.copy_||e.base_}function Lb(e,t){if(Pc(e))return new Map(e);if(eg(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);const n=r2(e);if(t===!0||t==="class_only"&&!n){const r=Object.getOwnPropertyDescriptors(e);delete r[Nr];let i=Reflect.ownKeys(r);for(let o=0;o<i.length;o++){const a=i[o],s=r[a];s.writable===!1&&(s.writable=!0,s.configurable=!0),(s.get||s.set)&&(r[a]={configurable:!0,writable:!0,enumerable:s.enumerable,value:e[a]})}return Object.create(ec(e),r)}else{const r=ec(e);if(r!==null&&n)return{...e};const i=Object.create(r);return Object.assign(i,e)}}function sw(e,t=!1){return tg(e)||Sl(e)||!fs(e)||(Jh(e)>1&&Object.defineProperties(e,{set:yd,add:yd,clear:yd,delete:yd}),Object.freeze(e),t&&Object.values(e).forEach(n=>sw(n,!0))),e}function Une(){cr(2)}var yd={value:Une};function tg(e){return e===null||typeof e!="object"?!0:Object.isFrozen(e)}var Gne={};function ds(e){const t=Gne[e];return t||cr(0,e),t}var tc;function o2(){return tc}function qne(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function PO(e,t){t&&(ds("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function $b(e){Fb(e),e.drafts_.forEach(Kne),e.drafts_=null}function Fb(e){e===tc&&(tc=e.parent_)}function AO(e){return tc=qne(tc,e)}function Kne(e){const t=e[Nr];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function RO(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];return e!==void 0&&e!==n?(n[Nr].modified_&&($b(t),cr(4)),fs(e)&&(e=Cp(t,e),t.parent_||Ep(t,e)),t.patches_&&ds("Patches").generateReplacementPatches_(n[Nr].base_,e,t.patches_,t.inversePatches_)):e=Cp(t,n,[]),$b(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==n2?e:void 0}function Cp(e,t,n){if(tg(t))return t;const r=e.immer_.shouldUseStrictIteration(),i=t[Nr];if(!i)return Sp(t,(o,a)=>IO(e,i,t,o,a,n),r),t;if(i.scope_!==e)return t;if(!i.modified_)return Ep(e,i.base_,!0),i.base_;if(!i.finalized_){i.finalized_=!0,i.scope_.unfinalizedDrafts_--;const o=i.copy_;let a=o,s=!1;i.type_===3&&(a=new Set(o),o.clear(),s=!0),Sp(a,(u,c)=>IO(e,i,o,u,c,n,s),r),Ep(e,o,!1),n&&e.patches_&&ds("Patches").generatePatches_(i,n,e.patches_,e.inversePatches_)}return i.copy_}function IO(e,t,n,r,i,o,a){if(i==null||typeof i!="object"&&!a)return;const s=tg(i);if(!(s&&!a)){if(process.env.NODE_ENV!=="production"&&i===n&&cr(5),Sl(i)){const u=o&&t&&t.type_!==3&&!jb(t.assigned_,r)?o.concat(r):void 0,c=Cp(e,i,u);if(i2(n,r,c),Sl(c))e.canAutoFreeze_=!1;else return}else a&&n.add(i);if(fs(i)&&!s){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1||t&&t.base_&&t.base_[r]===i&&s)return;Cp(e,i),(!t||!t.scope_.parent_)&&typeof r!="symbol"&&(Pc(n)?n.has(r):Object.prototype.propertyIsEnumerable.call(n,r))&&Ep(e,i)}}}function Ep(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&sw(t,n)}function Yne(e,t){const n=Array.isArray(e),r={type_:n?1:0,scope_:t?t.scope_:o2(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let i=r,o=lw;n&&(i=[r],o=nc);const{revoke:a,proxy:s}=Proxy.revocable(i,o);return r.draft_=s,r.revoke_=a,s}var lw={get(e,t){if(t===Nr)return e;const n=Ua(e);if(!jb(n,t))return Xne(e,n,t);const r=n[t];return e.finalized_||!fs(r)?r:r===sy(e.base_,t)?(ly(e),e.copy_[t]=Bb(r,e)):r},has(e,t){return t in Ua(e)},ownKeys(e){return Reflect.ownKeys(Ua(e))},set(e,t,n){const r=a2(Ua(e),t);if(r?.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){const i=sy(Ua(e),t),o=i?.[Nr];if(o&&o.base_===n)return e.copy_[t]=n,e.assigned_[t]=!1,!0;if(Hne(n,i)&&(n!==void 0||jb(e.base_,t)))return!0;ly(e),Vb(e)}return e.copy_[t]===n&&(n!==void 0||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_[t]=!0),!0},deleteProperty(e,t){return sy(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,ly(e),Vb(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const n=Ua(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:r.enumerable,value:n[t]}},defineProperty(){cr(11)},getPrototypeOf(e){return ec(e.base_)},setPrototypeOf(){cr(12)}},nc={};Sp(lw,(e,t)=>{nc[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}});nc.deleteProperty=function(e,t){return process.env.NODE_ENV!=="production"&&isNaN(parseInt(t))&&cr(13),nc.set.call(this,e,t,void 0)};nc.set=function(e,t,n){return process.env.NODE_ENV!=="production"&&t!=="length"&&isNaN(parseInt(t))&&cr(14),lw.set.call(this,e[0],t,n,e[0])};function sy(e,t){const n=e[Nr];return(n?Ua(n):e)[t]}function Xne(e,t,n){const r=a2(t,n);return r?"value"in r?r.value:r.get?.call(e.draft_):void 0}function a2(e,t){if(!(t in e))return;let n=ec(e);for(;n;){const r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=ec(n)}}function Vb(e){e.modified_||(e.modified_=!0,e.parent_&&Vb(e.parent_))}function ly(e){e.copy_||(e.copy_=Lb(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var Zne=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.useStrictIteration_=!0,this.produce=(t,n,r)=>{if(typeof t=="function"&&typeof n!="function"){const o=n;n=t;const a=this;return function(u=o,...c){return a.produce(u,f=>n.call(this,f,...c))}}typeof n!="function"&&cr(6),r!==void 0&&typeof r!="function"&&cr(7);let i;if(fs(t)){const o=AO(this),a=Bb(t,void 0);let s=!0;try{i=n(a),s=!1}finally{s?$b(o):Fb(o)}return PO(o,r),RO(i,o)}else if(!t||typeof t!="object"){if(i=n(t),i===void 0&&(i=t),i===n2&&(i=void 0),this.autoFreeze_&&sw(i,!0),r){const o=[],a=[];ds("Patches").generateReplacementPatches_(t,i,o,a),r(o,a)}return i}else cr(1,t)},this.produceWithPatches=(t,n)=>{if(typeof t=="function")return(a,...s)=>this.produceWithPatches(a,u=>t(u,...s));let r,i;return[this.produce(t,n,(a,s)=>{r=a,i=s}),r,i]},typeof e?.autoFreeze=="boolean"&&this.setAutoFreeze(e.autoFreeze),typeof e?.useStrictShallowCopy=="boolean"&&this.setUseStrictShallowCopy(e.useStrictShallowCopy),typeof e?.useStrictIteration=="boolean"&&this.setUseStrictIteration(e.useStrictIteration)}createDraft(e){fs(e)||cr(8),Sl(e)&&(e=Qne(e));const t=AO(this),n=Bb(e,void 0);return n[Nr].isManual_=!0,Fb(t),n}finishDraft(e,t){const n=e&&e[Nr];(!n||!n.isManual_)&&cr(9);const{scope_:r}=n;return PO(r,t),RO(void 0,r)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}setUseStrictIteration(e){this.useStrictIteration_=e}shouldUseStrictIteration(){return this.useStrictIteration_}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){const i=t[n];if(i.path.length===0&&i.op==="replace"){e=i.value;break}}n>-1&&(t=t.slice(n+1));const r=ds("Patches").applyPatches_;return Sl(e)?r(e,t):this.produce(e,i=>r(i,t))}};function Bb(e,t){const n=Pc(e)?ds("MapSet").proxyMap_(e,t):eg(e)?ds("MapSet").proxySet_(e,t):Yne(e,t);return(t?t.scope_:o2()).drafts_.push(n),n}function Qne(e){return Sl(e)||cr(10,e),s2(e)}function s2(e){if(!fs(e)||tg(e))return e;const t=e[Nr];let n,r=!0;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=Lb(e,t.scope_.immer_.useStrictShallowCopy_),r=t.scope_.immer_.shouldUseStrictIteration()}else n=Lb(e,!0);return Sp(n,(i,o)=>{i2(n,i,s2(o))},r),t&&(t.finalized_=!1),n}var Jne=new Zne;Jne.produce;var ere={settings:{layout:"horizontal",align:"center",verticalAlign:"middle",itemSorter:"value"},size:{width:0,height:0},payload:[]},l2=Hn({name:"legend",initialState:ere,reducers:{setLegendSize(e,t){e.size.width=t.payload.width,e.size.height=t.payload.height},setLegendSettings(e,t){e.settings.align=t.payload.align,e.settings.layout=t.payload.layout,e.settings.verticalAlign=t.payload.verticalAlign,e.settings.itemSorter=t.payload.itemSorter},addLegendPayload:{reducer(e,t){e.payload.push(t.payload)},prepare:Dt()},replaceLegendPayload:{reducer(e,t){var{prev:n,next:r}=t.payload,i=Jr(e).payload.indexOf(n);i>-1&&(e.payload[i]=r)},prepare:Dt()},removeLegendPayload:{reducer(e,t){var n=Jr(e).payload.indexOf(t.payload);n>-1&&e.payload.splice(n,1)},prepare:Dt()}}}),{setLegendSize:hve,setLegendSettings:gve,addLegendPayload:tre,replaceLegendPayload:nre,removeLegendPayload:rre}=l2.actions,ire=l2.reducer,bd={exports:{}},uy={};var TO;function ore(){if(TO)return uy;TO=1;var e=$;function t(u,c){return u===c&&(u!==0||1/u===1/c)||u!==u&&c!==c}var n=typeof Object.is=="function"?Object.is:t,r=e.useSyncExternalStore,i=e.useRef,o=e.useEffect,a=e.useMemo,s=e.useDebugValue;return uy.useSyncExternalStoreWithSelector=function(u,c,f,p,g){var h=i(null);if(h.current===null){var v={hasValue:!1,value:null};h.current=v}else v=h.current;h=a(function(){function y(P){if(!w){if(w=!0,S=P,P=p(P),g!==void 0&&v.hasValue){var R=v.value;if(g(R,P))return E=R}return E=P}if(R=E,n(S,P))return R;var I=p(P);return g!==void 0&&g(R,I)?(S=P,R):(S=P,E=I)}var w=!1,S,E,_=f===void 0?null:f;return[function(){return y(c())},_===null?void 0:function(){return y(_())}]},[c,f,p,g]);var b=r(u,h[0],h[1]);return o(function(){v.hasValue=!0,v.value=b},[b]),s(b),b},uy}var cy={};var kO;function are(){return kO||(kO=1,process.env.NODE_ENV!=="production"&&(function(){function e(u,c){return u===c&&(u!==0||1/u===1/c)||u!==u&&c!==c}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var t=$,n=typeof Object.is=="function"?Object.is:e,r=t.useSyncExternalStore,i=t.useRef,o=t.useEffect,a=t.useMemo,s=t.useDebugValue;cy.useSyncExternalStoreWithSelector=function(u,c,f,p,g){var h=i(null);if(h.current===null){var v={hasValue:!1,value:null};h.current=v}else v=h.current;h=a(function(){function y(P){if(!w){if(w=!0,S=P,P=p(P),g!==void 0&&v.hasValue){var R=v.value;if(g(R,P))return E=R}return E=P}if(R=E,n(S,P))return R;var I=p(P);return g!==void 0&&g(R,I)?(S=P,R):(S=P,E=I)}var w=!1,S,E,_=f===void 0?null:f;return[function(){return y(c())},_===null?void 0:function(){return y(_())}]},[c,f,p,g]);var b=r(u,h[0],h[1]);return o(function(){v.hasValue=!0,v.value=b},[b]),s(b),b},typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()),cy}var NO;function sre(){return NO||(NO=1,process.env.NODE_ENV==="production"?bd.exports=ore():bd.exports=are()),bd.exports}sre();function lre(e){e()}function ure(){let e=null,t=null;return{clear(){e=null,t=null},notify(){lre(()=>{let n=e;for(;n;)n.callback(),n=n.next})},get(){const n=[];let r=e;for(;r;)n.push(r),r=r.next;return n},subscribe(n){let r=!0;const i=t={callback:n,next:null,prev:t};return i.prev?i.prev.next=i:e=i,function(){!r||e===null||(r=!1,i.next?i.next.prev=i.prev:t=i.prev,i.prev?i.prev.next=i.next:e=i.next)}}}}var MO={notify(){},get:()=>[]};function cre(e,t){let n,r=MO,i=0,o=!1;function a(b){f();const y=r.subscribe(b);let w=!1;return()=>{w||(w=!0,y(),p())}}function s(){r.notify()}function u(){v.onStateChange&&v.onStateChange()}function c(){return o}function f(){i++,n||(n=e.subscribe(u),r=ure())}function p(){i--,n&&i===0&&(n(),n=void 0,r.clear(),r=MO)}function g(){o||(o=!0,f())}function h(){o&&(o=!1,p())}const v={addNestedSub:a,notifyNestedSubs:s,handleChangeWrapper:u,isSubscribed:c,trySubscribe:g,tryUnsubscribe:h,getListeners:()=>r};return v}var fre=()=>typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",dre=fre(),pre=()=>typeof navigator<"u"&&navigator.product==="ReactNative",hre=pre(),gre=()=>dre||hre?x.useLayoutEffect:x.useEffect,mre=gre();function DO(e,t){return e===t?e!==0||t!==0||1/e===1/t:e!==e&&t!==t}function vre(e,t){if(DO(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;const n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(let i=0;i<n.length;i++)if(!Object.prototype.hasOwnProperty.call(t,n[i])||!DO(e[n[i]],t[n[i]]))return!1;return!0}var yre=Symbol.for("react-redux-context"),bre=typeof globalThis<"u"?globalThis:{};function xre(){if(!x.createContext)return{};const e=bre[yre]??=new Map;let t=e.get(x.createContext);return t||(t=x.createContext(null),process.env.NODE_ENV!=="production"&&(t.displayName="ReactRedux"),e.set(x.createContext,t)),t}var wre=xre();function Sre(e){const{children:t,context:n,serverState:r,store:i}=e,o=x.useMemo(()=>{const u=cre(i),c={store:i,subscription:u,getServerState:r?()=>r:void 0};if(process.env.NODE_ENV==="production")return c;{const{identityFunctionCheck:f="once",stabilityCheck:p="once"}=e;return Object.assign(c,{stabilityCheck:p,identityFunctionCheck:f})}},[i,r]),a=x.useMemo(()=>i.getState(),[i]);mre(()=>{const{subscription:u}=o;return u.onStateChange=u.notifyNestedSubs,u.trySubscribe(),a!==i.getState()&&u.notifyNestedSubs(),()=>{u.tryUnsubscribe(),u.onStateChange=void 0}},[o,a]);const s=n||wre;return x.createElement(s.Provider,{value:o},t)}var Cre=Sre,Ere=new Set(["axisLine","tickLine","activeBar","activeDot","activeLabel","activeShape","allowEscapeViewBox","background","cursor","dot","label","line","margin","padding","position","shape","style","tick","wrapperStyle","radius","throttledEvents"]);function _re(e,t){return e==null&&t==null?!0:typeof e=="number"&&typeof t=="number"?e===t||e!==e&&t!==t:e===t}function ng(e,t){var n=new Set([...Object.keys(e),...Object.keys(t)]);for(var r of n)if(Ere.has(r)){if(e[r]==null&&t[r]==null)continue;if(!vre(e[r],t[r]))return!1}else if(!_re(e[r],t[r]))return!1;return!0}function zb(){return zb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},zb.apply(null,arguments)}function jO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function vu(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?jO(Object(n),!0).forEach(function(r){Ore(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):jO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Ore(e,t,n){return(t=Pre(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Pre(e){var t=Are(e,"string");return typeof t=="symbol"?t:t+""}function Are(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Rre(e){return Array.isArray(e)&&Vi(e[0])&&Vi(e[1])?e.join(" ~ "):e}var Qs={separator:" : ",contentStyle:{margin:0,padding:10,backgroundColor:"#fff",border:"1px solid #ccc",whiteSpace:"nowrap"},itemStyle:{display:"block",paddingTop:4,paddingBottom:4,color:"#000"},labelStyle:{},accessibilityLayer:!1};function Ire(e,t){return t==null?e:Fh(e,t)}var Tre=e=>{var{separator:t=Qs.separator,contentStyle:n,itemStyle:r,labelStyle:i=Qs.labelStyle,payload:o,formatter:a,itemSorter:s,wrapperClassName:u,labelClassName:c,label:f,labelFormatter:p,accessibilityLayer:g=Qs.accessibilityLayer}=e,h=()=>{if(o&&o.length){var P={padding:0,margin:0},R=Ire(o,s),I=R.map((k,B)=>{if(k.type==="none")return null;var L=k.formatter||a||Rre,{value:V,name:D}=k,W=V,J=D;if(L){var re=L(V,D,k,B,o);if(Array.isArray(re))[W,J]=re;else if(re!=null)W=re;else return null}var U=vu(vu({},Qs.itemStyle),{},{color:k.color||Qs.itemStyle.color},r);return x.createElement("li",{className:"recharts-tooltip-item",key:"tooltip-item-".concat(B),style:U},Vi(J)?x.createElement("span",{className:"recharts-tooltip-item-name"},J):null,Vi(J)?x.createElement("span",{className:"recharts-tooltip-item-separator"},t):null,x.createElement("span",{className:"recharts-tooltip-item-value"},W),x.createElement("span",{className:"recharts-tooltip-item-unit"},k.unit||""))});return x.createElement("ul",{className:"recharts-tooltip-item-list",style:P},I)}return null},v=vu(vu({},Qs.contentStyle),n),b=vu({margin:0},i),y=!pn(f),w=y?f:"",S=At("recharts-default-tooltip",u),E=At("recharts-tooltip-label",c);y&&p&&o!==void 0&&o!==null&&(w=p(f,o));var _=g?{role:"status","aria-live":"assertive"}:{};return x.createElement("div",zb({className:S,style:v},_),x.createElement("p",{className:E,style:b},x.isValidElement(w)?w:"".concat(w)),h())},yu="recharts-tooltip-wrapper",kre={visibility:"hidden"};function Nre(e){var{coordinate:t,translateX:n,translateY:r}=e;return At(yu,{["".concat(yu,"-right")]:Ne(n)&&t&&Ne(t.x)&&n>=t.x,["".concat(yu,"-left")]:Ne(n)&&t&&Ne(t.x)&&n<t.x,["".concat(yu,"-bottom")]:Ne(r)&&t&&Ne(t.y)&&r>=t.y,["".concat(yu,"-top")]:Ne(r)&&t&&Ne(t.y)&&r<t.y})}function LO(e){var{allowEscapeViewBox:t,coordinate:n,key:r,offset:i,position:o,reverseDirection:a,tooltipDimension:s,viewBox:u,viewBoxDimension:c}=e;if(o&&Ne(o[r]))return o[r];var f=n[r]-s-(i>0?i:0),p=n[r]+i;if(t[r])return a[r]?f:p;var g=u[r];if(g==null)return 0;if(a[r]){var h=f,v=g;return h<v?Math.max(p,g):Math.max(f,g)}if(c==null)return 0;var b=p+s,y=g+c;return b>y?Math.max(f,g):Math.max(p,g)}function Mre(e){var{translateX:t,translateY:n,useTranslate3d:r}=e;return{transform:r?"translate3d(".concat(t,"px, ").concat(n,"px, 0)"):"translate(".concat(t,"px, ").concat(n,"px)")}}function Dre(e){var{allowEscapeViewBox:t,coordinate:n,offsetTop:r,offsetLeft:i,position:o,reverseDirection:a,tooltipBox:s,useTranslate3d:u,viewBox:c}=e,f,p,g;return s.height>0&&s.width>0&&n?(p=LO({allowEscapeViewBox:t,coordinate:n,key:"x",offset:i,position:o,reverseDirection:a,tooltipDimension:s.width,viewBox:c,viewBoxDimension:c.width}),g=LO({allowEscapeViewBox:t,coordinate:n,key:"y",offset:r,position:o,reverseDirection:a,tooltipDimension:s.height,viewBox:c,viewBoxDimension:c.height}),f=Mre({translateX:p,translateY:g,useTranslate3d:u})):f=kre,{cssProperties:f,cssClasses:Nre({translateX:p,translateY:g,coordinate:n})}}var jre=()=>!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout),Ac={isSsr:jre()};function u2(){var[e,t]=$.useState(()=>Ac.isSsr||!window.matchMedia?!1:window.matchMedia("(prefers-reduced-motion: reduce)").matches);return $.useEffect(()=>{if(window.matchMedia){var n=window.matchMedia("(prefers-reduced-motion: reduce)"),r=()=>{t(n.matches)};return n.addEventListener("change",r),()=>{n.removeEventListener("change",r)}}},[]),e}function $O(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Js(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?$O(Object(n),!0).forEach(function(r){Lre(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$O(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Lre(e,t,n){return(t=$re(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function $re(e){var t=Fre(e,"string");return typeof t=="symbol"?t:t+""}function Fre(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Vre(e){if(!(e.prefersReducedMotion&&e.isAnimationActive==="auto")&&e.isAnimationActive&&e.active)return"transform ".concat(e.animationDuration,"ms ").concat(e.animationEasing)}function Bre(e){var t,n,r,i,o,a,s=u2(),[u,c]=x.useState(()=>({dismissed:!1,dismissedAtCoordinate:{x:0,y:0}}));x.useEffect(()=>{var v=b=>{if(b.key==="Escape"){var y,w,S,E;c({dismissed:!0,dismissedAtCoordinate:{x:(y=(w=e.coordinate)===null||w===void 0?void 0:w.x)!==null&&y!==void 0?y:0,y:(S=(E=e.coordinate)===null||E===void 0?void 0:E.y)!==null&&S!==void 0?S:0}})}};return document.addEventListener("keydown",v),()=>{document.removeEventListener("keydown",v)}},[(t=e.coordinate)===null||t===void 0?void 0:t.x,(n=e.coordinate)===null||n===void 0?void 0:n.y]),u.dismissed&&(((r=(i=e.coordinate)===null||i===void 0?void 0:i.x)!==null&&r!==void 0?r:0)!==u.dismissedAtCoordinate.x||((o=(a=e.coordinate)===null||a===void 0?void 0:a.y)!==null&&o!==void 0?o:0)!==u.dismissedAtCoordinate.y)&&c(Js(Js({},u),{},{dismissed:!1}));var{cssClasses:f,cssProperties:p}=Dre({allowEscapeViewBox:e.allowEscapeViewBox,coordinate:e.coordinate,offsetLeft:typeof e.offset=="number"?e.offset:e.offset.x,offsetTop:typeof e.offset=="number"?e.offset:e.offset.y,position:e.position,reverseDirection:e.reverseDirection,tooltipBox:{height:e.lastBoundingBox.height,width:e.lastBoundingBox.width},useTranslate3d:e.useTranslate3d,viewBox:e.viewBox}),g=e.hasPortalFromProps?{}:Js(Js({transition:Vre({prefersReducedMotion:s,isAnimationActive:e.isAnimationActive,active:e.active,animationDuration:e.animationDuration,animationEasing:e.animationEasing})},p),{},{pointerEvents:"none",position:"absolute",top:0,left:0}),h=Js(Js({},g),{},{visibility:!u.dismissed&&e.active&&e.hasPayload?"visible":"hidden"},e.wrapperStyle);return x.createElement("div",{xmlns:"http://www.w3.org/1999/xhtml",tabIndex:-1,className:f,style:h,ref:e.innerRef},e.children)}var zre=x.memo(Bre),c2=()=>{var e;return(e=Be(t=>t.rootProps.accessibilityLayer))!==null&&e!==void 0?e:!0};function Wb(){return Wb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Wb.apply(null,arguments)}function FO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function VO(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?FO(Object(n),!0).forEach(function(r){Wre(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):FO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Wre(e,t,n){return(t=Hre(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Hre(e){var t=Ure(e,"string");return typeof t=="symbol"?t:t+""}function Ure(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var BO={curveBasisClosed:mJ,curveBasisOpen:vJ,curveBasis:gJ,curveBumpX:tJ,curveBumpY:nJ,curveLinearClosed:yJ,curveLinear:Lh,curveMonotoneX:bJ,curveMonotoneY:xJ,curveNatural:wJ,curveStep:SJ,curveStepAfter:EJ,curveStepBefore:CJ},_p=e=>dt(e.x)&&dt(e.y),zO=e=>e.base!=null&&_p(e.base)&&_p(e),bu=e=>e.x,xu=e=>e.y,Gre=(e,t)=>{if(typeof e=="function")return e;var n="curve".concat(xc(e));if((n==="curveMonotone"||n==="curveBump")&&t){var r=BO["".concat(n).concat(t==="vertical"?"Y":"X")];if(r)return r}return BO[n]||Lh},WO={connectNulls:!1,type:"linear"},qre=e=>{var{type:t=WO.type,points:n=[],baseLine:r,layout:i,connectNulls:o=WO.connectNulls}=e,a=Gre(t,i),s=o?n.filter(_p):n;if(Array.isArray(r)){var u,c=n.map((v,b)=>VO(VO({},v),{},{base:r[b]}));i==="vertical"?u=fd().y(xu).x1(bu).x0(v=>v.base.x):u=fd().x(bu).y1(xu).y0(v=>v.base.y);var f=u.defined(zO).curve(a),p=o?c.filter(zO):c;return f(p)}var g;i==="vertical"&&Ne(r)?g=fd().y(xu).x1(bu).x0(r):Ne(r)?g=fd().x(bu).y1(xu).y0(r):g=jD().x(bu).y(xu);var h=g.defined(_p).curve(a);return h(s)},f2=e=>{var{className:t,points:n,path:r,pathRef:i}=e,o=Tl();if((!n||!n.length)&&!r)return null;var a={type:e.type,points:e.points,baseLine:e.baseLine,layout:e.layout||o,connectNulls:e.connectNulls},s=n&&n.length?qre(a):r;return x.createElement("path",Wb({},vo(e),KJ(e),{className:At("recharts-curve",t),d:s===null?void 0:s,ref:i}))},Kre=["x","y","top","left","width","height","className"];function Hb(){return Hb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Hb.apply(null,arguments)}function HO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Yre(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?HO(Object(n),!0).forEach(function(r){Xre(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):HO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Xre(e,t,n){return(t=Zre(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Zre(e){var t=Qre(e,"string");return typeof t=="symbol"?t:t+""}function Qre(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Jre(e,t){if(e==null)return{};var n,r,i=eie(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function eie(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var tie=(e,t,n,r,i,o)=>"M".concat(e,",").concat(i,"v").concat(r,"M").concat(o,",").concat(t,"h").concat(n),nie=e=>{var{x:t=0,y:n=0,top:r=0,left:i=0,width:o=0,height:a=0,className:s}=e,u=Jre(e,Kre),c=Yre({x:t,y:n,top:r,left:i,width:o,height:a},u);return!Ne(t)||!Ne(n)||!Ne(o)||!Ne(a)||!Ne(r)||!Ne(i)?null:x.createElement("path",Hb({},ni(c),{className:At("recharts-cross",s),d:tie(t,n,o,a,r,i)}))};function rie(e,t,n,r){var i=r/2;return{stroke:"none",fill:"#ccc",x:e==="horizontal"?t.x-i:n.left+.5,y:e==="horizontal"?n.top+.5:t.y-i,width:e==="horizontal"?r:n.width-1,height:e==="horizontal"?n.height-1:r}}function UO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function GO(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?UO(Object(n),!0).forEach(function(r){iie(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):UO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function iie(e,t,n){return(t=oie(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function oie(e){var t=aie(e,"string");return typeof t=="symbol"?t:t+""}function aie(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var sie=e=>e.replace(/([A-Z])/g,t=>"-".concat(t.toLowerCase())),d2=(e,t,n)=>e.map(r=>"".concat(sie(r)," ").concat(t,"ms ").concat(n)).join(","),lie=(e,t)=>[Object.keys(e),Object.keys(t)].reduce((n,r)=>n.filter(i=>r.includes(i))),rc=(e,t)=>Object.keys(t).reduce((n,r)=>GO(GO({},n),{},{[r]:e(r,t[r])}),{});function qO(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function fn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?qO(Object(n),!0).forEach(function(r){uie(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):qO(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function uie(e,t,n){return(t=cie(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cie(e){var t=fie(e,"string");return typeof t=="symbol"?t:t+""}function fie(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Op=(e,t,n)=>e+(t-e)*n,Ub=e=>{var{from:t,to:n}=e;return t!==n},p2=(e,t,n)=>{var r=rc((i,o)=>{if(Ub(o)){var[a,s]=e(o.from,o.to,o.velocity);return fn(fn({},o),{},{from:a,velocity:s})}return o},t);return n<1?rc((i,o)=>Ub(o)&&r[i]!=null?fn(fn({},o),{},{velocity:Op(o.velocity,r[i].velocity,n),from:Op(o.from,r[i].from,n)}):o,t):p2(e,r,n-1)};function die(e,t,n,r,i,o){var a,s=r.reduce((g,h)=>fn(fn({},g),{},{[h]:{from:e[h],velocity:0,to:t[h]}}),{}),u=()=>rc((g,h)=>h.from,s),c=()=>!Object.values(s).filter(Ub).length,f=null,p=g=>{a||(a=g);var h=g-a,v=h/n.dt;s=p2(n,s,v),i(fn(fn(fn({},e),t),u())),a=g,c()||(f=o.setTimeout(p))};return()=>(f=o.setTimeout(p),()=>{var g;(g=f)===null||g===void 0||g()})}function pie(e,t,n,r,i,o,a){var s=null,u=i.reduce((p,g)=>{var h=e[g],v=t[g];return h==null||v==null?p:fn(fn({},p),{},{[g]:[h,v]})},{}),c,f=p=>{c||(c=p);var g=(p-c)/r,h=rc((b,y)=>Op(...y,n(g)),u);if(o(fn(fn(fn({},e),t),h)),g<1)s=a.setTimeout(f);else{var v=rc((b,y)=>Op(...y,n(1)),u);o(fn(fn(fn({},e),t),v))}};return()=>(s=a.setTimeout(f),()=>{var p;(p=s)===null||p===void 0||p()})}const hie=(e,t,n,r,i,o)=>{var a=lie(e,t);return n==null?()=>(i(fn(fn({},e),t)),()=>{}):n.isStepper===!0?die(e,t,n,a,i,o):pie(e,t,n,r,a,i,o)};var Pp=1e-4,h2=(e,t)=>[0,3*e,3*t-6*e,3*e-3*t+1],g2=(e,t)=>e.map((n,r)=>n*t**r).reduce((n,r)=>n+r),KO=(e,t)=>n=>{var r=h2(e,t);return g2(r,n)},gie=(e,t)=>n=>{var r=h2(e,t),i=[...r.map((o,a)=>o*a).slice(1),0];return g2(i,n)},mie=e=>{var t,n=e.split("(");if(n.length!==2||n[0]!=="cubic-bezier")return null;var r=(t=n[1])===null||t===void 0||(t=t.split(")")[0])===null||t===void 0?void 0:t.split(",");if(r==null||r.length!==4)return null;var i=r.map(o=>parseFloat(o));return[i[0],i[1],i[2],i[3]]},vie=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];if(n.length===1)switch(n[0]){case"linear":return[0,0,1,1];case"ease":return[.25,.1,.25,1];case"ease-in":return[.42,0,1,1];case"ease-out":return[.42,0,.58,1];case"ease-in-out":return[0,0,.58,1];default:{var i=mie(n[0]);if(i)return i}}return n.length===4?n:[0,0,1,1]},yie=(e,t,n,r)=>{var i=KO(e,n),o=KO(t,r),a=gie(e,n),s=c=>c>1?1:c<0?0:c,u=c=>{for(var f=c>1?1:c,p=f,g=0;g<8;++g){var h=i(p)-f,v=a(p);if(Math.abs(h-f)<Pp||v<Pp)return o(p);p=s(p-h/v)}return o(p)};return u.isStepper=!1,u},YO=function(){return yie(...vie(...arguments))},bie=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},{stiff:n=100,damping:r=8,dt:i=17}=t,o=(a,s,u)=>{var c=-(a-s)*n,f=u*r,p=u+(c-f)*i/1e3,g=u*i/1e3+a;return Math.abs(g-s)<Pp&&Math.abs(p)<Pp?[s,0]:[g,p]};return o.isStepper=!0,o.dt=i,o},xie=e=>{if(typeof e=="string")switch(e){case"ease":case"ease-in-out":case"ease-out":case"ease-in":case"linear":return YO(e);case"spring":return bie();default:if(e.split("(")[0]==="cubic-bezier")return YO(e)}return typeof e=="function"?e:null};function wie(e){var t,n=()=>null,r=!1,i=null,o=a=>{if(!r){if(Array.isArray(a)){if(!a.length)return;var s=a,[u,...c]=s;if(typeof u=="number"){i=e.setTimeout(o.bind(null,c),u);return}o(u),i=e.setTimeout(o.bind(null,c));return}typeof a=="string"&&(t=a,n(t)),typeof a=="object"&&(t=a,n(t)),typeof a=="function"&&a()}};return{stop:()=>{r=!0},start:a=>{r=!1,i&&(i(),i=null),o(a)},subscribe:a=>(n=a,()=>{n=()=>null}),getTimeoutController:()=>e}}class Sie{setTimeout(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,r=performance.now(),i=null,o=a=>{a-r>=n?t(a):typeof requestAnimationFrame=="function"&&(i=requestAnimationFrame(o))};return i=requestAnimationFrame(o),()=>{i!=null&&cancelAnimationFrame(i)}}}function Cie(){return wie(new Sie)}var Eie=$.createContext(Cie);function _ie(e,t){var n=$.useContext(Eie);return $.useMemo(()=>t??n(e),[e,t,n])}var Oie={begin:0,duration:1e3,easing:"ease",isActive:!0,canBegin:!0,onAnimationEnd:()=>{},onAnimationStart:()=>{}},XO={t:0},fy={t:1};function uw(e){var t=Dr(e,Oie),{isActive:n,canBegin:r,duration:i,easing:o,begin:a,onAnimationEnd:s,onAnimationStart:u,children:c}=t,f=u2(),p=n==="auto"?!Ac.isSsr&&!f:n,g=_ie(t.animationId,t.animationManager),[h,v]=$.useState(p?XO:fy),b=$.useRef(null);return $.useEffect(()=>{p||v(fy)},[p]),$.useEffect(()=>{if(!p||!r)return ys;var y=hie(XO,fy,xie(o),i,v,g.getTimeoutController()),w=()=>{b.current=y()};return g.start([u,a,w,i,s]),()=>{g.stop(),b.current&&b.current(),s()}},[p,r,i,o,a,u,s,g]),c(h.t)}function cw(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"animation-",n=$.useRef(Xu(t)),r=$.useRef(e);return r.current!==e&&(n.current=Xu(t),r.current=e),n.current}var Pie=["radius"],Aie=["radius"],ZO,QO,JO,eP,tP,nP,rP,iP,oP,aP;function sP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function lP(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?sP(Object(n),!0).forEach(function(r){Rie(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Rie(e,t,n){return(t=Iie(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Iie(e){var t=Tie(e,"string");return typeof t=="symbol"?t:t+""}function Tie(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Ap(){return Ap=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ap.apply(null,arguments)}function uP(e,t){if(e==null)return{};var n,r,i=kie(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function kie(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function Oi(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}var cP=(e,t,n,r,i)=>{var o=na(n),a=na(r),s=Math.min(Math.abs(o)/2,Math.abs(a)/2),u=a>=0?1:-1,c=o>=0?1:-1,f=a>=0&&o>=0||a<0&&o<0?1:0,p;if(s>0&&Array.isArray(i)){for(var g=[0,0,0,0],h=0,v=4;h<v;h++){var b,y=(b=i[h])!==null&&b!==void 0?b:0;g[h]=y>s?s:y}p=Kt(ZO||(ZO=Oi(["M",",",""])),e,t+u*g[0]),g[0]>0&&(p+=Kt(QO||(QO=Oi(["A ",",",",0,0,",",",",",""])),g[0],g[0],f,e+c*g[0],t)),p+=Kt(JO||(JO=Oi(["L ",",",""])),e+n-c*g[1],t),g[1]>0&&(p+=Kt(eP||(eP=Oi(["A ",",",",0,0,",`,
|
|
228
|
+
`,",",""])),g[1],g[1],f,e+n,t+u*g[1])),p+=Kt(tP||(tP=Oi(["L ",",",""])),e+n,t+r-u*g[2]),g[2]>0&&(p+=Kt(nP||(nP=Oi(["A ",",",",0,0,",`,
|
|
229
|
+
`,",",""])),g[2],g[2],f,e+n-c*g[2],t+r)),p+=Kt(rP||(rP=Oi(["L ",",",""])),e+c*g[3],t+r),g[3]>0&&(p+=Kt(iP||(iP=Oi(["A ",",",",0,0,",`,
|
|
230
|
+
`,",",""])),g[3],g[3],f,e,t+r-u*g[3])),p+="Z"}else if(s>0&&i===+i&&i>0){var w=Math.min(s,i);p=Kt(oP||(oP=Oi(["M ",",",`
|
|
202
231
|
A `,",",",0,0,",",",",",`
|
|
203
232
|
L `,",",`
|
|
204
233
|
A `,",",",0,0,",",",",",`
|
|
205
234
|
L `,",",`
|
|
206
235
|
A `,",",",0,0,",",",",",`
|
|
207
236
|
L `,",",`
|
|
208
|
-
A `,",",",0,0,",",",","," Z"])),e,t+u*w,w,w,
|
|
237
|
+
A `,",",",0,0,",",",","," Z"])),e,t+u*w,w,w,f,e+c*w,t,e+n-c*w,t,w,w,f,e+n,t+u*w,e+n,t+r-u*w,w,w,f,e+n-c*w,t+r,e+c*w,t+r,w,w,f,e,t+r-u*w)}else p=Kt(aP||(aP=Oi(["M ",","," h "," v "," h "," Z"])),e,t,n,r,-n);return p},fP={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},m2=e=>{var t=Dr(e,fP),n=$.useRef(null),[r,i]=$.useState(-1);$.useEffect(()=>{if(n.current&&n.current.getTotalLength)try{var ee=n.current.getTotalLength();ee&&i(ee)}catch{}},[]);var{x:o,y:a,width:s,height:u,radius:c,className:f}=t,{animationEasing:p,animationDuration:g,animationBegin:h,isAnimationActive:v,isUpdateAnimationActive:b}=t,y=$.useRef(s),w=$.useRef(u),S=$.useRef(o),E=$.useRef(a),_=$.useMemo(()=>({x:o,y:a,width:s,height:u,radius:c}),[o,a,s,u,c]),P=cw(_,"rectangle-");if(o!==+o||a!==+a||s!==+s||u!==+u||s===0||u===0)return null;var R=At("recharts-rectangle",f);if(!b){var I=ni(t),{radius:k}=I,B=uP(I,Pie);return x.createElement("path",Ap({},B,{x:na(o),y:na(a),width:na(s),height:na(u),radius:typeof c=="number"?c:void 0,className:R,d:cP(o,a,s,u,c)}))}var L=y.current,V=w.current,D=S.current,W=E.current,J="0px ".concat(r===-1?1:r,"px"),re="".concat(r,"px ").concat(r,"px"),U=d2(["strokeDasharray"],g,typeof p=="string"?p:fP.animationEasing);return x.createElement(uw,{animationId:P,key:P,canBegin:r>0,duration:g,easing:p,isActive:b,begin:h},ee=>{var Z=Tn(L,s,ee),ue=Tn(V,u,ee),X=Tn(D,o,ee),Oe=Tn(W,a,ee);n.current&&(y.current=Z,w.current=ue,S.current=X,E.current=Oe);var Ee;v?ee>0?Ee={transition:U,strokeDasharray:re}:Ee={strokeDasharray:J}:Ee={strokeDasharray:re};var Me=ni(t),{radius:ye}=Me,be=uP(Me,Aie);return x.createElement("path",Ap({},be,{radius:typeof c=="number"?c:void 0,className:R,d:cP(X,Oe,Z,ue,c),ref:n,style:lP(lP({},Ee),t.style)}))})};function dP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function pP(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?dP(Object(n),!0).forEach(function(r){Nie(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):dP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Nie(e,t,n){return(t=Mie(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Mie(e){var t=Die(e,"string");return typeof t=="symbol"?t:t+""}function Die(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Rp=Math.PI/180,jie=e=>e*180/Math.PI,kn=(e,t,n,r)=>({x:e+Math.cos(-Rp*r)*n,y:t+Math.sin(-Rp*r)*n}),Lie=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{top:0,right:0,bottom:0,left:0};return Math.min(Math.abs(t-(r.left||0)-(r.right||0)),Math.abs(n-(r.top||0)-(r.bottom||0)))/2},$ie=(e,t)=>{var{x:n,y:r}=e,{x:i,y:o}=t;return Math.sqrt((n-i)**2+(r-o)**2)},Fie=(e,t)=>{var{x:n,y:r}=e,{cx:i,cy:o}=t,a=$ie({x:n,y:r},{x:i,y:o});if(a<=0)return{radius:a,angle:0};var s=(n-i)/a,u=Math.acos(s);return r>o&&(u=2*Math.PI-u),{radius:a,angle:jie(u),angleInRadian:u}},Vie=e=>{var{startAngle:t,endAngle:n}=e,r=Math.floor(t/360),i=Math.floor(n/360),o=Math.min(r,i);return{startAngle:t-o*360,endAngle:n-o*360}},Bie=(e,t)=>{var{startAngle:n,endAngle:r}=t,i=Math.floor(n/360),o=Math.floor(r/360),a=Math.min(i,o);return e+a*360},zie=(e,t)=>{var{relativeX:n,relativeY:r}=e,{radius:i,angle:o}=Fie({x:n,y:r},t),{innerRadius:a,outerRadius:s}=t;if(i<a||i>s||i===0)return null;var{startAngle:u,endAngle:c}=Vie(t),f=o,p;if(u<=c){for(;f>c;)f-=360;for(;f<u;)f+=360;p=f>=u&&f<=c}else{for(;f>u;)f-=360;for(;f<c;)f+=360;p=f>=c&&f<=u}return p?pP(pP({},t),{},{radius:i,angle:Bie(f,t)}):null};function v2(e){var{cx:t,cy:n,radius:r,startAngle:i,endAngle:o}=e,a=kn(t,n,r,i),s=kn(t,n,r,o);return{points:[a,s],cx:t,cy:n,radius:r,startAngle:i,endAngle:o}}var hP,gP,mP,vP,yP,bP,xP;function Gb(){return Gb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Gb.apply(null,arguments)}function Ka(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}var Wie=(e,t)=>{var n=fr(t-e),r=Math.min(Math.abs(t-e),359.999);return n*r},xd=e=>{var{cx:t,cy:n,radius:r,angle:i,sign:o,isExternal:a,cornerRadius:s,cornerIsExternal:u}=e,c=s*(a?1:-1)+r,f=Math.asin(s/c)/Rp,p=u?i:i+o*f,g=kn(t,n,c,p),h=kn(t,n,r,p),v=u?i-o*f:i,b=kn(t,n,c*Math.cos(f*Rp),v);return{center:g,circleTangency:h,lineTangency:b,theta:f}},y2=e=>{var{cx:t,cy:n,innerRadius:r,outerRadius:i,startAngle:o,endAngle:a}=e,s=Wie(o,a),u=o+s,c=kn(t,n,i,o),f=kn(t,n,i,u),p=Kt(hP||(hP=Ka(["M ",",",`
|
|
209
238
|
A `,",",`,0,
|
|
210
239
|
`,",",`,
|
|
211
240
|
`,",",`
|
|
212
|
-
`])),c.x,c.y,i,i,+(Math.abs(s)>180),+(o>u),
|
|
241
|
+
`])),c.x,c.y,i,i,+(Math.abs(s)>180),+(o>u),f.x,f.y);if(r>0){var g=kn(t,n,r,o),h=kn(t,n,r,u);p+=Kt(gP||(gP=Ka(["L ",",",`
|
|
213
242
|
A `,",",`,0,
|
|
214
243
|
`,",",`,
|
|
215
|
-
`,","," Z"])),h.x,h.y,r,r,+(Math.abs(s)>180),+(o<=u),g.x,g.y)}else p+=
|
|
244
|
+
`,","," Z"])),h.x,h.y,r,r,+(Math.abs(s)>180),+(o<=u),g.x,g.y)}else p+=Kt(mP||(mP=Ka(["L ",","," Z"])),t,n);return p},Hie=e=>{var{cx:t,cy:n,innerRadius:r,outerRadius:i,cornerRadius:o,forceCornerRadius:a,cornerIsExternal:s,startAngle:u,endAngle:c}=e,f=fr(c-u),{circleTangency:p,lineTangency:g,theta:h}=xd({cx:t,cy:n,radius:i,angle:u,sign:f,cornerRadius:o,cornerIsExternal:s}),{circleTangency:v,lineTangency:b,theta:y}=xd({cx:t,cy:n,radius:i,angle:c,sign:-f,cornerRadius:o,cornerIsExternal:s}),w=s?Math.abs(u-c):Math.abs(u-c)-h-y;if(w<0)return a?Kt(vP||(vP=Ka(["M ",",",`
|
|
216
245
|
a`,",",",0,0,1,",`,0
|
|
217
246
|
a`,",",",0,0,1,",`,0
|
|
218
|
-
`])),g.x,g.y,o,o,o*2,o,o,-o*2):
|
|
247
|
+
`])),g.x,g.y,o,o,o*2,o,o,-o*2):y2({cx:t,cy:n,innerRadius:r,outerRadius:i,startAngle:u,endAngle:c});var S=Kt(yP||(yP=Ka(["M ",",",`
|
|
219
248
|
A`,",",",0,0,",",",",",`
|
|
220
249
|
A`,",",",0,",",",",",",",`
|
|
221
250
|
A`,",",",0,0,",",",",",`
|
|
222
|
-
`])),g.x,g.y,o,o,+(
|
|
251
|
+
`])),g.x,g.y,o,o,+(f<0),p.x,p.y,i,i,+(w>180),+(f<0),v.x,v.y,o,o,+(f<0),b.x,b.y);if(r>0){var{circleTangency:E,lineTangency:_,theta:P}=xd({cx:t,cy:n,radius:r,angle:u,sign:f,isExternal:!0,cornerRadius:o,cornerIsExternal:s}),{circleTangency:R,lineTangency:I,theta:k}=xd({cx:t,cy:n,radius:r,angle:c,sign:-f,isExternal:!0,cornerRadius:o,cornerIsExternal:s}),B=s?Math.abs(u-c):Math.abs(u-c)-P-k;if(B<0&&o===0)return"".concat(S,"L").concat(t,",").concat(n,"Z");S+=Kt(bP||(bP=Ka(["L",",",`
|
|
223
252
|
A`,",",",0,0,",",",",",`
|
|
224
253
|
A`,",",",0,",",",",",",",`
|
|
225
|
-
A`,",",",0,0,",",",",","Z"])),I.x,I.y,o,o,+(d<0),R.x,R.y,r,r,+(B>180),+(d>0),E.x,E.y,o,o,+(d<0),_.x,_.y)}else C+=qt(ZO||(ZO=za(["L",",","Z"])),t,n);return C},Kne={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},gj=e=>{var t=Mr(e,Kne),{cx:n,cy:r,innerRadius:i,outerRadius:o,cornerRadius:a,forceCornerRadius:s,cornerIsExternal:u,startAngle:c,endAngle:d,className:p}=t;if(o<i||c===d)return null;var g=Pt("recharts-sector",p),h=o-i,v=fi(a,h,0,!0),b;return v>0&&Math.abs(c-d)<360?b=qne({cx:n,cy:r,innerRadius:i,outerRadius:o,cornerRadius:Math.min(v,h/2),forceCornerRadius:s,cornerIsExternal:u,startAngle:c,endAngle:d}):b=hj({cx:n,cy:r,innerRadius:i,outerRadius:o,startAngle:c,endAngle:d}),x.createElement("path",_b({},ti(t),{className:g,d:b}))};function Yne(e,t,n){if(e==="horizontal")return[{x:t.x,y:n.top},{x:t.x,y:n.top+n.height}];if(e==="vertical")return[{x:n.left,y:t.y},{x:n.left+n.width,y:t.y}];if(qM(t)){if(e==="centric"){var{cx:r,cy:i,innerRadius:o,outerRadius:a,angle:s}=t,u=kn(r,i,o,s),c=kn(r,i,a,s);return[{x:u.x,y:u.y},{x:c.x,y:c.y}]}return pj(t)}}var Xv={},Zv={},Qv={},QO;function Xne(){return QO||(QO=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=rD();function n(r){return t.isSymbol(r)?NaN:Number(r)}e.toNumber=n})(Qv)),Qv}var JO;function Zne(){return JO||(JO=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=Xne();function n(r){return r?(r=t.toNumber(r),r===1/0||r===-1/0?(r<0?-1:1)*Number.MAX_VALUE:r===r?r:0):r===0?r:0}e.toFinite=n})(Zv)),Zv}var eP;function Qne(){return eP||(eP=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=iD(),n=Zne();function r(i,o,a){a&&typeof a!="number"&&t.isIterateeCall(i,o,a)&&(o=a=void 0),i=n.toFinite(i),o===void 0?(o=i,i=0):o=n.toFinite(o),a=a===void 0?i<o?1:-1:n.toFinite(a);const s=Math.max(Math.ceil((o-i)/(a||1)),0),u=new Array(s);for(let c=0;c<s;c++)u[c]=i,i+=a;return u}e.range=r})(Xv)),Xv}var Jv,tP;function Jne(){return tP||(tP=1,Jv=Qne().range),Jv}var ere=Jne();const mj=fs(ere);var Co=e=>e.chartData,vj=q([Co],e=>{var t=e.chartData!=null?e.chartData.length-1:0;return{chartData:e.chartData,computedData:e.computedData,dataEndIndex:t,dataStartIndex:0}}),yj=(e,t,n,r)=>r?vj(e):Co(e),tre=(e,t,n)=>n?vj(e):Co(e);function Ti(e){if(Array.isArray(e)&&e.length===2){var[t,n]=e;if(ct(t)&&ct(n))return!0}return!1}function nP(e,t,n){return n?e:[Math.min(e[0],t[0]),Math.max(e[1],t[1])]}function bj(e,t){if(t&&typeof e!="function"&&Array.isArray(e)&&e.length===2){var[n,r]=e,i,o;if(ct(n))i=n;else if(typeof n=="function")return;if(ct(r))o=r;else if(typeof r=="function")return;var a=[i,o];if(Ti(a))return a}}function nre(e,t,n){if(!(!n&&t==null)){if(typeof e=="function"&&t!=null)try{var r=e(t,n);if(Ti(r))return nP(r,t,n)}catch{}if(Array.isArray(e)&&e.length===2){var[i,o]=e,a,s;if(i==="auto")t!=null&&(a=Math.min(...t));else if(Te(i))a=i;else if(typeof i=="function")try{t!=null&&(a=i(t?.[0]))}catch{}else if(typeof i=="string"&&G_.test(i)){var u=G_.exec(i);if(u==null||u[1]==null||t==null)a=void 0;else{var c=+u[1];a=t[0]-c}}else a=t?.[0];if(o==="auto")t!=null&&(s=Math.max(...t));else if(Te(o))s=o;else if(typeof o=="function")try{t!=null&&(s=o(t?.[1]))}catch{}else if(typeof o=="string"&&q_.test(o)){var d=q_.exec(o);if(d==null||d[1]==null||t==null)s=void 0;else{var p=+d[1];s=t[1]+p}}else s=t?.[1];var g=[a,s];if(Ti(g))return t==null?g:nP(g,t,n)}}}var Ol=1e9,rre={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},Gx,Vt=!0,ni="[DecimalError] ",Ka=ni+"Invalid argument: ",Ux=ni+"Exponent out of range: ",Pl=Math.floor,Va=Math.pow,ire=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,Or,xn=1e7,Dt=7,xj=9007199254740991,Cp=Pl(xj/Dt),_e={};_e.absoluteValue=_e.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e};_e.comparedTo=_e.cmp=function(e){var t,n,r,i,o=this;if(e=new o.constructor(e),o.s!==e.s)return o.s||-e.s;if(o.e!==e.e)return o.e>e.e^o.s<0?1:-1;for(r=o.d.length,i=e.d.length,t=0,n=r<i?r:i;t<n;++t)if(o.d[t]!==e.d[t])return o.d[t]>e.d[t]^o.s<0?1:-1;return r===i?0:r>i^o.s<0?1:-1};_e.decimalPlaces=_e.dp=function(){var e=this,t=e.d.length-1,n=(t-e.e)*Dt;if(t=e.d[t],t)for(;t%10==0;t/=10)n--;return n<0?0:n};_e.dividedBy=_e.div=function(e){return so(this,new this.constructor(e))};_e.dividedToIntegerBy=_e.idiv=function(e){var t=this,n=t.constructor;return Ot(so(t,new n(e),0,1),n.precision)};_e.equals=_e.eq=function(e){return!this.cmp(e)};_e.exponent=function(){return rn(this)};_e.greaterThan=_e.gt=function(e){return this.cmp(e)>0};_e.greaterThanOrEqualTo=_e.gte=function(e){return this.cmp(e)>=0};_e.isInteger=_e.isint=function(){return this.e>this.d.length-2};_e.isNegative=_e.isneg=function(){return this.s<0};_e.isPositive=_e.ispos=function(){return this.s>0};_e.isZero=function(){return this.s===0};_e.lessThan=_e.lt=function(e){return this.cmp(e)<0};_e.lessThanOrEqualTo=_e.lte=function(e){return this.cmp(e)<1};_e.logarithm=_e.log=function(e){var t,n=this,r=n.constructor,i=r.precision,o=i+5;if(e===void 0)e=new r(10);else if(e=new r(e),e.s<1||e.eq(Or))throw Error(ni+"NaN");if(n.s<1)throw Error(ni+(n.s?"NaN":"-Infinity"));return n.eq(Or)?new r(0):(Vt=!1,t=so(Xu(n,o),Xu(e,o),o),Vt=!0,Ot(t,i))};_e.minus=_e.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?Sj(t,e):wj(t,(e.s=-e.s,e))};_e.modulo=_e.mod=function(e){var t,n=this,r=n.constructor,i=r.precision;if(e=new r(e),!e.s)throw Error(ni+"NaN");return n.s?(Vt=!1,t=so(n,e,0,1).times(e),Vt=!0,n.minus(t)):Ot(new r(n),i)};_e.naturalExponential=_e.exp=function(){return Cj(this)};_e.naturalLogarithm=_e.ln=function(){return Xu(this)};_e.negated=_e.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};_e.plus=_e.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?wj(t,e):Sj(t,(e.s=-e.s,e))};_e.precision=_e.sd=function(e){var t,n,r,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(Ka+e);if(t=rn(i)+1,r=i.d.length-1,n=r*Dt+1,r=i.d[r],r){for(;r%10==0;r/=10)n--;for(r=i.d[0];r>=10;r/=10)n++}return e&&t>n?t:n};_e.squareRoot=_e.sqrt=function(){var e,t,n,r,i,o,a,s=this,u=s.constructor;if(s.s<1){if(!s.s)return new u(0);throw Error(ni+"NaN")}for(e=rn(s),Vt=!1,i=Math.sqrt(+s),i==0||i==1/0?(t=Ri(s.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=Pl((e+1)/2)-(e<0||e%2),i==1/0?t="5e"+e:(t=i.toExponential(),t=t.slice(0,t.indexOf("e")+1)+e),r=new u(t)):r=new u(i.toString()),n=u.precision,i=a=n+3;;)if(o=r,r=o.plus(so(s,o,a+2)).times(.5),Ri(o.d).slice(0,a)===(t=Ri(r.d)).slice(0,a)){if(t=t.slice(a-3,a+1),i==a&&t=="4999"){if(Ot(o,n+1,0),o.times(o).eq(s)){r=o;break}}else if(t!="9999")break;a+=4}return Vt=!0,Ot(r,n)};_e.times=_e.mul=function(e){var t,n,r,i,o,a,s,u,c,d=this,p=d.constructor,g=d.d,h=(e=new p(e)).d;if(!d.s||!e.s)return new p(0);for(e.s*=d.s,n=d.e+e.e,u=g.length,c=h.length,u<c&&(o=g,g=h,h=o,a=u,u=c,c=a),o=[],a=u+c,r=a;r--;)o.push(0);for(r=c;--r>=0;){for(t=0,i=u+r;i>r;)s=o[i]+h[r]*g[i-r-1]+t,o[i--]=s%xn|0,t=s/xn|0;o[i]=(o[i]+t)%xn|0}for(;!o[--a];)o.pop();return t?++n:o.shift(),e.d=o,e.e=n,Vt?Ot(e,p.precision):e};_e.toDecimalPlaces=_e.todp=function(e,t){var n=this,r=n.constructor;return n=new r(n),e===void 0?n:($i(e,0,Ol),t===void 0?t=r.rounding:$i(t,0,8),Ot(n,e+rn(n)+1,t))};_e.toExponential=function(e,t){var n,r=this,i=r.constructor;return e===void 0?n=as(r,!0):($i(e,0,Ol),t===void 0?t=i.rounding:$i(t,0,8),r=Ot(new i(r),e+1,t),n=as(r,!0,e+1)),n};_e.toFixed=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?as(i):($i(e,0,Ol),t===void 0?t=o.rounding:$i(t,0,8),r=Ot(new o(i),e+rn(i)+1,t),n=as(r.abs(),!1,e+rn(r)+1),i.isneg()&&!i.isZero()?"-"+n:n)};_e.toInteger=_e.toint=function(){var e=this,t=e.constructor;return Ot(new t(e),rn(e)+1,t.rounding)};_e.toNumber=function(){return+this};_e.toPower=_e.pow=function(e){var t,n,r,i,o,a,s=this,u=s.constructor,c=12,d=+(e=new u(e));if(!e.s)return new u(Or);if(s=new u(s),!s.s){if(e.s<1)throw Error(ni+"Infinity");return s}if(s.eq(Or))return s;if(r=u.precision,e.eq(Or))return Ot(s,r);if(t=e.e,n=e.d.length-1,a=t>=n,o=s.s,a){if((n=d<0?-d:d)<=xj){for(i=new u(Or),t=Math.ceil(r/Dt+4),Vt=!1;n%2&&(i=i.times(s),iP(i.d,t)),n=Pl(n/2),n!==0;)s=s.times(s),iP(s.d,t);return Vt=!0,e.s<0?new u(Or).div(i):Ot(i,r)}}else if(o<0)throw Error(ni+"NaN");return o=o<0&&e.d[Math.max(t,n)]&1?-1:1,s.s=1,Vt=!1,i=e.times(Xu(s,r+c)),Vt=!0,i=Cj(i),i.s=o,i};_e.toPrecision=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?(n=rn(i),r=as(i,n<=o.toExpNeg||n>=o.toExpPos)):($i(e,1,Ol),t===void 0?t=o.rounding:$i(t,0,8),i=Ot(new o(i),e,t),n=rn(i),r=as(i,e<=n||n<=o.toExpNeg,e)),r};_e.toSignificantDigits=_e.tosd=function(e,t){var n=this,r=n.constructor;return e===void 0?(e=r.precision,t=r.rounding):($i(e,1,Ol),t===void 0?t=r.rounding:$i(t,0,8)),Ot(new r(n),e,t)};_e.toString=_e.valueOf=_e.val=_e.toJSON=_e[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=rn(e),n=e.constructor;return as(e,t<=n.toExpNeg||t>=n.toExpPos)};function wj(e,t){var n,r,i,o,a,s,u,c,d=e.constructor,p=d.precision;if(!e.s||!t.s)return t.s||(t=new d(e)),Vt?Ot(t,p):t;if(u=e.d,c=t.d,a=e.e,i=t.e,u=u.slice(),o=a-i,o){for(o<0?(r=u,o=-o,s=c.length):(r=c,i=a,s=u.length),a=Math.ceil(p/Dt),s=a>s?a+1:s+1,o>s&&(o=s,r.length=1),r.reverse();o--;)r.push(0);r.reverse()}for(s=u.length,o=c.length,s-o<0&&(o=s,r=c,c=u,u=r),n=0;o;)n=(u[--o]=u[o]+c[o]+n)/xn|0,u[o]%=xn;for(n&&(u.unshift(n),++i),s=u.length;u[--s]==0;)u.pop();return t.d=u,t.e=i,Vt?Ot(t,p):t}function $i(e,t,n){if(e!==~~e||e<t||e>n)throw Error(Ka+e)}function Ri(e){var t,n,r,i=e.length-1,o="",a=e[0];if(i>0){for(o+=a,t=1;t<i;t++)r=e[t]+"",n=Dt-r.length,n&&(o+=Go(n)),o+=r;a=e[t],r=a+"",n=Dt-r.length,n&&(o+=Go(n))}else if(a===0)return"0";for(;a%10===0;)a/=10;return o+a}var so=(function(){function e(r,i){var o,a=0,s=r.length;for(r=r.slice();s--;)o=r[s]*i+a,r[s]=o%xn|0,a=o/xn|0;return a&&r.unshift(a),r}function t(r,i,o,a){var s,u;if(o!=a)u=o>a?1:-1;else for(s=u=0;s<o;s++)if(r[s]!=i[s]){u=r[s]>i[s]?1:-1;break}return u}function n(r,i,o){for(var a=0;o--;)r[o]-=a,a=r[o]<i[o]?1:0,r[o]=a*xn+r[o]-i[o];for(;!r[0]&&r.length>1;)r.shift()}return function(r,i,o,a){var s,u,c,d,p,g,h,v,b,y,w,C,E,_,O,R,I,k,B=r.constructor,L=r.s==i.s?1:-1,V=r.d,D=i.d;if(!r.s)return new B(r);if(!i.s)throw Error(ni+"Division by zero");for(u=r.e-i.e,I=D.length,O=V.length,h=new B(L),v=h.d=[],c=0;D[c]==(V[c]||0);)++c;if(D[c]>(V[c]||0)&&--u,o==null?C=o=B.precision:a?C=o+(rn(r)-rn(i))+1:C=o,C<0)return new B(0);if(C=C/Dt+2|0,c=0,I==1)for(d=0,D=D[0],C++;(c<O||d)&&C--;c++)E=d*xn+(V[c]||0),v[c]=E/D|0,d=E%D|0;else{for(d=xn/(D[0]+1)|0,d>1&&(D=e(D,d),V=e(V,d),I=D.length,O=V.length),_=I,b=V.slice(0,I),y=b.length;y<I;)b[y++]=0;k=D.slice(),k.unshift(0),R=D[0],D[1]>=xn/2&&++R;do d=0,s=t(D,b,I,y),s<0?(w=b[0],I!=y&&(w=w*xn+(b[1]||0)),d=w/R|0,d>1?(d>=xn&&(d=xn-1),p=e(D,d),g=p.length,y=b.length,s=t(p,b,g,y),s==1&&(d--,n(p,I<g?k:D,g))):(d==0&&(s=d=1),p=D.slice()),g=p.length,g<y&&p.unshift(0),n(b,p,y),s==-1&&(y=b.length,s=t(D,b,I,y),s<1&&(d++,n(b,I<y?k:D,y))),y=b.length):s===0&&(d++,b=[0]),v[c++]=d,s&&b[0]?b[y++]=V[_]||0:(b=[V[_]],y=1);while((_++<O||b[0]!==void 0)&&C--)}return v[0]||v.shift(),h.e=u,Ot(h,a?o+rn(h)+1:o)}})();function Cj(e,t){var n,r,i,o,a,s,u=0,c=0,d=e.constructor,p=d.precision;if(rn(e)>16)throw Error(Ux+rn(e));if(!e.s)return new d(Or);for(Vt=!1,s=p,a=new d(.03125);e.abs().gte(.1);)e=e.times(a),c+=5;for(r=Math.log(Va(2,c))/Math.LN10*2+5|0,s+=r,n=i=o=new d(Or),d.precision=s;;){if(i=Ot(i.times(e),s),n=n.times(++u),a=o.plus(so(i,n,s)),Ri(a.d).slice(0,s)===Ri(o.d).slice(0,s)){for(;c--;)o=Ot(o.times(o),s);return d.precision=p,t==null?(Vt=!0,Ot(o,p)):o}o=a}}function rn(e){for(var t=e.e*Dt,n=e.d[0];n>=10;n/=10)t++;return t}function ey(e,t,n){if(t>e.LN10.sd())throw Vt=!0,n&&(e.precision=n),Error(ni+"LN10 precision limit exceeded");return Ot(new e(e.LN10),t)}function Go(e){for(var t="";e--;)t+="0";return t}function Xu(e,t){var n,r,i,o,a,s,u,c,d,p=1,g=10,h=e,v=h.d,b=h.constructor,y=b.precision;if(h.s<1)throw Error(ni+(h.s?"NaN":"-Infinity"));if(h.eq(Or))return new b(0);if(t==null?(Vt=!1,c=y):c=t,h.eq(10))return t==null&&(Vt=!0),ey(b,c);if(c+=g,b.precision=c,n=Ri(v),r=n.charAt(0),o=rn(h),Math.abs(o)<15e14){for(;r<7&&r!=1||r==1&&n.charAt(1)>3;)h=h.times(e),n=Ri(h.d),r=n.charAt(0),p++;o=rn(h),r>1?(h=new b("0."+n),o++):h=new b(r+"."+n.slice(1))}else return u=ey(b,c+2,y).times(o+""),h=Xu(new b(r+"."+n.slice(1)),c-g).plus(u),b.precision=y,t==null?(Vt=!0,Ot(h,y)):h;for(s=a=h=so(h.minus(Or),h.plus(Or),c),d=Ot(h.times(h),c),i=3;;){if(a=Ot(a.times(d),c),u=s.plus(so(a,new b(i),c)),Ri(u.d).slice(0,c)===Ri(s.d).slice(0,c))return s=s.times(2),o!==0&&(s=s.plus(ey(b,c+2,y).times(o+""))),s=so(s,new b(p),c),b.precision=y,t==null?(Vt=!0,Ot(s,y)):s;s=u,i+=2}}function rP(e,t){var n,r,i;for((n=t.indexOf("."))>-1&&(t=t.replace(".","")),(r=t.search(/e/i))>0?(n<0&&(n=r),n+=+t.slice(r+1),t=t.substring(0,r)):n<0&&(n=t.length),r=0;t.charCodeAt(r)===48;)++r;for(i=t.length;t.charCodeAt(i-1)===48;)--i;if(t=t.slice(r,i),t){if(i-=r,n=n-r-1,e.e=Pl(n/Dt),e.d=[],r=(n+1)%Dt,n<0&&(r+=Dt),r<i){for(r&&e.d.push(+t.slice(0,r)),i-=Dt;r<i;)e.d.push(+t.slice(r,r+=Dt));t=t.slice(r),r=Dt-t.length}else r-=i;for(;r--;)t+="0";if(e.d.push(+t),Vt&&(e.e>Cp||e.e<-Cp))throw Error(Ux+n)}else e.s=0,e.e=0,e.d=[0];return e}function Ot(e,t,n){var r,i,o,a,s,u,c,d,p=e.d;for(a=1,o=p[0];o>=10;o/=10)a++;if(r=t-a,r<0)r+=Dt,i=t,c=p[d=0];else{if(d=Math.ceil((r+1)/Dt),o=p.length,d>=o)return e;for(c=o=p[d],a=1;o>=10;o/=10)a++;r%=Dt,i=r-Dt+a}if(n!==void 0&&(o=Va(10,a-i-1),s=c/o%10|0,u=t<0||p[d+1]!==void 0||c%o,u=n<4?(s||u)&&(n==0||n==(e.s<0?3:2)):s>5||s==5&&(n==4||u||n==6&&(r>0?i>0?c/Va(10,a-i):0:p[d-1])%10&1||n==(e.s<0?8:7))),t<1||!p[0])return u?(o=rn(e),p.length=1,t=t-o-1,p[0]=Va(10,(Dt-t%Dt)%Dt),e.e=Pl(-t/Dt)||0):(p.length=1,p[0]=e.e=e.s=0),e;if(r==0?(p.length=d,o=1,d--):(p.length=d+1,o=Va(10,Dt-r),p[d]=i>0?(c/Va(10,a-i)%Va(10,i)|0)*o:0),u)for(;;)if(d==0){(p[0]+=o)==xn&&(p[0]=1,++e.e);break}else{if(p[d]+=o,p[d]!=xn)break;p[d--]=0,o=1}for(r=p.length;p[--r]===0;)p.pop();if(Vt&&(e.e>Cp||e.e<-Cp))throw Error(Ux+rn(e));return e}function Sj(e,t){var n,r,i,o,a,s,u,c,d,p,g=e.constructor,h=g.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new g(e),Vt?Ot(t,h):t;if(u=e.d,p=t.d,r=t.e,c=e.e,u=u.slice(),a=c-r,a){for(d=a<0,d?(n=u,a=-a,s=p.length):(n=p,r=c,s=u.length),i=Math.max(Math.ceil(h/Dt),s)+2,a>i&&(a=i,n.length=1),n.reverse(),i=a;i--;)n.push(0);n.reverse()}else{for(i=u.length,s=p.length,d=i<s,d&&(s=i),i=0;i<s;i++)if(u[i]!=p[i]){d=u[i]<p[i];break}a=0}for(d&&(n=u,u=p,p=n,t.s=-t.s),s=u.length,i=p.length-s;i>0;--i)u[s++]=0;for(i=p.length;i>a;){if(u[--i]<p[i]){for(o=i;o&&u[--o]===0;)u[o]=xn-1;--u[o],u[i]+=xn}u[i]-=p[i]}for(;u[--s]===0;)u.pop();for(;u[0]===0;u.shift())--r;return u[0]?(t.d=u,t.e=r,Vt?Ot(t,h):t):new g(0)}function as(e,t,n){var r,i=rn(e),o=Ri(e.d),a=o.length;return t?(n&&(r=n-a)>0?o=o.charAt(0)+"."+o.slice(1)+Go(r):a>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(i<0?"e":"e+")+i):i<0?(o="0."+Go(-i-1)+o,n&&(r=n-a)>0&&(o+=Go(r))):i>=a?(o+=Go(i+1-a),n&&(r=n-i-1)>0&&(o=o+"."+Go(r))):((r=i+1)<a&&(o=o.slice(0,r)+"."+o.slice(r)),n&&(r=n-a)>0&&(i+1===a&&(o+="."),o+=Go(r))),e.s<0?"-"+o:o}function iP(e,t){if(e.length>t)return e.length=t,!0}function Ej(e){var t,n,r;function i(o){var a=this;if(!(a instanceof i))return new i(o);if(a.constructor=i,o instanceof i){a.s=o.s,a.e=o.e,a.d=(o=o.d)?o.slice():o;return}if(typeof o=="number"){if(o*0!==0)throw Error(Ka+o);if(o>0)a.s=1;else if(o<0)o=-o,a.s=-1;else{a.s=0,a.e=0,a.d=[0];return}if(o===~~o&&o<1e7){a.e=0,a.d=[o];return}return rP(a,o.toString())}else if(typeof o!="string")throw Error(Ka+o);if(o.charCodeAt(0)===45?(o=o.slice(1),a.s=-1):a.s=1,ire.test(o))rP(a,o);else throw Error(Ka+o)}if(i.prototype=_e,i.ROUND_UP=0,i.ROUND_DOWN=1,i.ROUND_CEIL=2,i.ROUND_FLOOR=3,i.ROUND_HALF_UP=4,i.ROUND_HALF_DOWN=5,i.ROUND_HALF_EVEN=6,i.ROUND_HALF_CEIL=7,i.ROUND_HALF_FLOOR=8,i.clone=Ej,i.config=i.set=ore,e===void 0&&(e={}),e)for(r=["precision","rounding","toExpNeg","toExpPos","LN10"],t=0;t<r.length;)e.hasOwnProperty(n=r[t++])||(e[n]=this[n]);return i.config(e),i}function ore(e){if(!e||typeof e!="object")throw Error(ni+"Object expected");var t,n,r,i=["precision",1,Ol,"rounding",0,8,"toExpNeg",-1/0,0,"toExpPos",0,1/0];for(t=0;t<i.length;t+=3)if((r=e[n=i[t]])!==void 0)if(Pl(r)===r&&r>=i[t+1]&&r<=i[t+2])this[n]=r;else throw Error(Ka+n+": "+r);if((r=e[n="LN10"])!==void 0)if(r==Math.LN10)this[n]=new this(r);else throw Error(Ka+n+": "+r);return this}var Gx=Ej(rre);Or=new Gx(1);const ut=Gx;function _j(e){var t;return e===0?t=1:t=Math.floor(new ut(e).abs().log(10).toNumber())+1,t}function Oj(e,t,n){for(var r=new ut(e),i=0,o=[];r.lt(t)&&i<1e5;)o.push(r.toNumber()),r=r.add(n),i++;return o}var Pj=e=>{var[t,n]=e,[r,i]=[t,n];return t>n&&([r,i]=[n,t]),[r,i]},qx=(e,t,n)=>{if(e.lte(0))return new ut(0);var r=_j(e.toNumber()),i=new ut(10).pow(r),o=e.div(i),a=r!==1?.05:.1,s=new ut(Math.ceil(o.div(a).toNumber())).add(n).mul(a),u=s.mul(i);return t?new ut(u.toNumber()):new ut(Math.ceil(u.toNumber()))},Aj=(e,t,n)=>{var r;if(e.lte(0))return new ut(0);var i=[1,2,2.5,5],o=e.toNumber(),a=Math.floor(new ut(o).abs().log(10).toNumber()),s=new ut(10).pow(a),u=e.div(s).toNumber(),c=i.findIndex(h=>h>=u-1e-10);if(c===-1&&(s=s.mul(10),c=0),c+=n,c>=i.length){var d=Math.floor(c/i.length);c%=i.length,s=s.mul(new ut(10).pow(d))}var p=(r=i[c])!==null&&r!==void 0?r:1,g=new ut(p).mul(s);return t?g:new ut(Math.ceil(g.toNumber()))},are=(e,t,n)=>{var r=new ut(1),i=new ut(e);if(!i.isint()&&n){var o=Math.abs(e);o<1?(r=new ut(10).pow(_j(e)-1),i=new ut(Math.floor(i.div(r).toNumber())).mul(r)):o>1&&(i=new ut(Math.floor(e)))}else e===0?i=new ut(Math.floor((t-1)/2)):n||(i=new ut(Math.floor(e)));for(var a=Math.floor((t-1)/2),s=[],u=0;u<t;u++)s.push(i.add(new ut(u-a).mul(r)).toNumber());return s},Rj=function(t,n,r,i){var o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0,a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:qx;if(!Number.isFinite((n-t)/(r-1)))return{step:new ut(0),tickMin:new ut(0),tickMax:new ut(0)};var s=a(new ut(n).sub(t).div(r-1),i,o),u;t<=0&&n>=0?u=new ut(0):(u=new ut(t).add(n).div(2),u=u.sub(new ut(u).mod(s)));var c=Math.ceil(u.sub(t).div(s).toNumber()),d=Math.ceil(new ut(n).sub(u).div(s).toNumber()),p=c+d+1;return p>r?Rj(t,n,r,i,o+1,a):(p<r&&(d=n>0?d+(r-p):d,c=n>0?c:c+(r-p)),{step:s,tickMin:u.sub(new ut(c).mul(s)),tickMax:u.add(new ut(d).mul(s))})},oP=function(t){var[n,r]=t,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"auto",s=Math.max(i,2),[u,c]=Pj([n,r]);if(u===-1/0||c===1/0){var d=c===1/0?[u,...Array(i-1).fill(1/0)]:[...Array(i-1).fill(-1/0),c];return n>r?d.reverse():d}if(u===c)return are(u,i,o);var p=a==="snap125"?Aj:qx,{step:g,tickMin:h,tickMax:v}=Rj(u,c,s,o,0,p),b=Oj(h,v.add(new ut(.1).mul(g)),g);return n>r?b.reverse():b},aP=function(t,n){var[r,i]=t,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"auto",[s,u]=Pj([r,i]);if(s===-1/0||u===1/0)return[r,i];if(s===u)return[s];var c=a==="snap125"?Aj:qx,d=Math.max(n,2),p=c(new ut(u).sub(s).div(d-1),o,0),g=[...Oj(new ut(s),new ut(u),p),u];return o===!1&&(g=g.map(h=>Math.round(h))),r>i?g.reverse():g},Ij=e=>e.rootProps.maxBarSize,sre=e=>e.rootProps.barGap,Tj=e=>e.rootProps.barCategoryGap,lre=e=>e.rootProps.barSize,Bh=e=>e.rootProps.stackOffset,kj=e=>e.rootProps.reverseStackOrder,Kx=e=>e.options.chartName,Yx=e=>e.rootProps.syncId,Nj=e=>e.rootProps.syncMethod,Xx=e=>e.options.eventEmitter,Zn={grid:-100,barBackground:-50,area:100,cursorRectangle:200,bar:300,line:400,axis:500,scatter:600,activeBar:1e3,cursorLine:1100,activeDot:1200,label:2e3},Ma={allowDecimals:!1,allowDataOverflow:!1,angleAxisId:0,reversed:!1,scale:"auto",tick:!0,type:"auto"},Ei={allowDataOverflow:!1,allowDecimals:!1,allowDuplicatedCategory:!0,includeHidden:!1,radiusAxisId:0,reversed:!1,scale:"auto",tick:!0,tickCount:5,type:"auto"},zh=(e,t)=>{if(!(!e||!t))return e!=null&&e.reversed?[t[1],t[0]]:t};function Wh(e,t,n){if(n!=="auto")return n;if(e!=null)return pa(e,t)?"category":"number"}function sP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Sp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?sP(Object(n),!0).forEach(function(r){ure(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ure(e,t,n){return(t=cre(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cre(e){var t=fre(e,"string");return typeof t=="symbol"?t:t+""}function fre(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var lP={allowDataOverflow:Ma.allowDataOverflow,allowDecimals:Ma.allowDecimals,allowDuplicatedCategory:!1,dataKey:void 0,domain:void 0,id:Ma.angleAxisId,includeHidden:!1,name:void 0,reversed:Ma.reversed,scale:Ma.scale,tick:Ma.tick,tickCount:void 0,ticks:void 0,type:Ma.type,unit:void 0,niceTicks:"auto"},uP={allowDataOverflow:Ei.allowDataOverflow,allowDecimals:Ei.allowDecimals,allowDuplicatedCategory:Ei.allowDuplicatedCategory,dataKey:void 0,domain:void 0,id:Ei.radiusAxisId,includeHidden:Ei.includeHidden,name:void 0,reversed:Ei.reversed,scale:Ei.scale,tick:Ei.tick,tickCount:Ei.tickCount,ticks:void 0,type:Ei.type,unit:void 0,niceTicks:"auto"},dre=(e,t)=>{if(t!=null)return e.polarAxis.angleAxis[t]},Zx=q([dre,ZD],(e,t)=>{var n;if(e!=null)return e;var r=(n=Wh(t,"angleAxis",lP.type))!==null&&n!==void 0?n:"category";return Sp(Sp({},lP),{},{type:r})}),pre=(e,t)=>e.polarAxis.radiusAxis[t],Qx=q([pre,ZD],(e,t)=>{var n;if(e!=null)return e;var r=(n=Wh(t,"radiusAxis",uP.type))!==null&&n!==void 0?n:"category";return Sp(Sp({},uP),{},{type:r})}),Hh=e=>e.polarOptions,Jx=q([xo,wo,wn],Vne),Mj=q([Hh,Jx],(e,t)=>{if(e!=null)return fi(e.innerRadius,t,0)}),Dj=q([Hh,Jx],(e,t)=>{if(e!=null)return fi(e.outerRadius,t,t*.8)}),hre=e=>{if(e==null)return[0,0];var{startAngle:t,endAngle:n}=e;return[t,n]},jj=q([Hh],hre);q([Zx,jj],zh);var Lj=q([Jx,Mj,Dj],(e,t,n)=>{if(!(e==null||t==null||n==null))return[t,n]});q([Qx,Lj],zh);var $j=q([At,Hh,Mj,Dj,xo,wo],(e,t,n,r,i,o)=>{if(!(e!=="centric"&&e!=="radial"||t==null||n==null||r==null)){var{cx:a,cy:s,startAngle:u,endAngle:c}=t;return{cx:fi(a,i,i/2),cy:fi(s,o,o/2),innerRadius:n,outerRadius:r,startAngle:u,endAngle:c,clockWise:!1}}}),Cn=(e,t)=>t,Uh=(e,t,n)=>n;function ew(e){return e?.id}function Fj(e,t,n){var{chartData:r=[]}=t,{allowDuplicatedCategory:i,dataKey:o}=n,a=new Map;return e.forEach(s=>{var u,c=(u=s.data)!==null&&u!==void 0?u:r;if(!(c==null||c.length===0)){var d=ew(s);c.forEach((p,g)=>{var h=o==null||i?g:String(Mn(p,o,null)),v=Mn(p,s.dataKey,0),b;a.has(h)?b=a.get(h):b={},Object.assign(b,{[d]:v}),a.set(h,b)})}}),Array.from(a.values())}function Gh(e){return"stackId"in e&&e.stackId!=null&&e.dataKey!=null}var qh=(e,t)=>e===t?!0:e==null||t==null?!1:e[0]===t[0]&&e[1]===t[1];function Kh(e,t){return Array.isArray(e)&&Array.isArray(t)&&e.length===0&&t.length===0?!0:e===t}function gre(e,t){if(e.length===t.length){for(var n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}return!1}var Sn=e=>{var t=At(e);return t==="horizontal"?"xAxis":t==="vertical"?"yAxis":t==="centric"?"angleAxis":"radiusAxis"},Al=e=>e.tooltip.settings.axisId;function tw(e){if(e!=null){var t=e.ticks,n=e.bandwidth,r=e.range(),i=[Math.min(...r),Math.max(...r)];return{domain:()=>e.domain(),range:(function(o){function a(){return o.apply(this,arguments)}return a.toString=function(){return o.toString()},a})(()=>i),rangeMin:()=>i[0],rangeMax:()=>i[1],isInRange(o){var a=i[0],s=i[1];return a<=s?o>=a&&o<=s:o>=s&&o<=a},bandwidth:n?()=>n.call(e):void 0,ticks:t?o=>t.call(e,o):void 0,map:(o,a)=>{var s=e(o);if(s!=null){if(e.bandwidth&&a!==null&&a!==void 0&&a.position){var u=e.bandwidth();switch(a.position){case"middle":s+=u/2;break;case"end":s+=u;break}}return s}}}}}var mre=(e,t)=>{if(t!=null)switch(e){case"linear":{if(!Ti(t)){for(var n,r,i=0;i<t.length;i++){var o=t[i];ct(o)&&((n===void 0||o<n)&&(n=o),(r===void 0||o>r)&&(r=o))}return n!==void 0&&r!==void 0?[n,r]:void 0}return t}default:return t}};function na(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function vre(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function nw(e){let t,n,r;e.length!==2?(t=na,n=(s,u)=>na(e(s),u),r=(s,u)=>e(s)-u):(t=e===na||e===vre?e:yre,n=e,r=e);function i(s,u,c=0,d=s.length){if(c<d){if(t(u,u)!==0)return d;do{const p=c+d>>>1;n(s[p],u)<0?c=p+1:d=p}while(c<d)}return c}function o(s,u,c=0,d=s.length){if(c<d){if(t(u,u)!==0)return d;do{const p=c+d>>>1;n(s[p],u)<=0?c=p+1:d=p}while(c<d)}return c}function a(s,u,c=0,d=s.length){const p=i(s,u,c,d-1);return p>c&&r(s[p-1],u)>-r(s[p],u)?p-1:p}return{left:i,center:a,right:o}}function yre(){return 0}function Vj(e){return e===null?NaN:+e}function*bre(e,t){for(let n of e)n!=null&&(n=+n)>=n&&(yield n)}const xre=nw(na),wc=xre.right;nw(Vj).center;class cP extends Map{constructor(t,n=Sre){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[r,i]of t)this.set(r,i)}get(t){return super.get(fP(this,t))}has(t){return super.has(fP(this,t))}set(t,n){return super.set(wre(this,t),n)}delete(t){return super.delete(Cre(this,t))}}function fP({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function wre({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function Cre({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function Sre(e){return e!==null&&typeof e=="object"?e.valueOf():e}function Ere(e=na){if(e===na)return Bj;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 Bj(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}const _re=Math.sqrt(50),Ore=Math.sqrt(10),Pre=Math.sqrt(2);function Ep(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),a=o>=_re?10:o>=Ore?5:o>=Pre?2:1;let s,u,c;return i<0?(c=Math.pow(10,-i)/a,s=Math.round(e*c),u=Math.round(t*c),s/c<e&&++s,u/c>t&&--u,c=-c):(c=Math.pow(10,i)*a,s=Math.round(e/c),u=Math.round(t/c),s*c<e&&++s,u*c>t&&--u),u<s&&.5<=n&&n<2?Ep(e,t,n*2):[s,u,c]}function Ob(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[i,o,a]=r?Ep(t,e,n):Ep(e,t,n);if(!(o>=i))return[];const s=o-i+1,u=new Array(s);if(r)if(a<0)for(let c=0;c<s;++c)u[c]=(o-c)/-a;else for(let c=0;c<s;++c)u[c]=(o-c)*a;else if(a<0)for(let c=0;c<s;++c)u[c]=(i+c)/-a;else for(let c=0;c<s;++c)u[c]=(i+c)*a;return u}function Pb(e,t,n){return t=+t,e=+e,n=+n,Ep(e,t,n)[2]}function Ab(e,t,n){t=+t,e=+e,n=+n;const r=t<e,i=r?Pb(t,e,n):Pb(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}function dP(e,t){let n;for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);return n}function pP(e,t){let n;for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);return n}function zj(e,t,n=0,r=1/0,i){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(i=i===void 0?Bj:Ere(i);r>n;){if(r-n>600){const u=r-n+1,c=t-n+1,d=Math.log(u),p=.5*Math.exp(2*d/3),g=.5*Math.sqrt(d*p*(u-p)/u)*(c-u/2<0?-1:1),h=Math.max(n,Math.floor(t-c*p/u+g)),v=Math.min(r,Math.floor(t+(u-c)*p/u+g));zj(e,t,h,v,i)}const o=e[t];let a=n,s=r;for(gu(e,n,t),i(e[r],o)>0&&gu(e,n,r);a<s;){for(gu(e,a,s),++a,--s;i(e[a],o)<0;)++a;for(;i(e[s],o)>0;)--s}i(e[n],o)===0?gu(e,n,s):(++s,gu(e,s,r)),s<=t&&(n=s+1),t<=s&&(r=s-1)}return e}function gu(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function Are(e,t,n){if(e=Float64Array.from(bre(e)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return pP(e);if(t>=1)return dP(e);var r,i=(r-1)*t,o=Math.floor(i),a=dP(zj(e,o).subarray(0,o+1)),s=pP(e.subarray(o+1));return a+(s-a)*(i-o)}}function Rre(e,t,n=Vj){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,i=(r-1)*t,o=Math.floor(i),a=+n(e[o],o,e),s=+n(e[o+1],o+1,e);return a+(s-a)*(i-o)}}function Ire(e,t,n){e=+e,t=+t,n=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+n;for(var r=-1,i=Math.max(0,Math.ceil((t-e)/n))|0,o=new Array(i);++r<i;)o[r]=e+r*n;return o}function ri(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function So(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 Rb=Symbol("implicit");function rw(){var e=new cP,t=[],n=[],r=Rb;function i(o){let a=e.get(o);if(a===void 0){if(r!==Rb)return r;e.set(o,a=t.push(o)-1)}return n[a%n.length]}return i.domain=function(o){if(!arguments.length)return t.slice();t=[],e=new cP;for(const a of o)e.has(a)||e.set(a,t.push(a)-1);return i},i.range=function(o){return arguments.length?(n=Array.from(o),i):n.slice()},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return rw(t,n).unknown(r)},ri.apply(i,arguments),i}function iw(){var e=rw().unknown(void 0),t=e.domain,n=e.range,r=0,i=1,o,a,s=!1,u=0,c=0,d=.5;delete e.unknown;function p(){var g=t().length,h=i<r,v=h?i:r,b=h?r:i;o=(b-v)/Math.max(1,g-u+c*2),s&&(o=Math.floor(o)),v+=(b-v-o*(g-u))*d,a=o*(1-u),s&&(v=Math.round(v),a=Math.round(a));var y=Ire(g).map(function(w){return v+o*w});return n(h?y.reverse():y)}return e.domain=function(g){return arguments.length?(t(g),p()):t()},e.range=function(g){return arguments.length?([r,i]=g,r=+r,i=+i,p()):[r,i]},e.rangeRound=function(g){return[r,i]=g,r=+r,i=+i,s=!0,p()},e.bandwidth=function(){return a},e.step=function(){return o},e.round=function(g){return arguments.length?(s=!!g,p()):s},e.padding=function(g){return arguments.length?(u=Math.min(1,c=+g),p()):u},e.paddingInner=function(g){return arguments.length?(u=Math.min(1,g),p()):u},e.paddingOuter=function(g){return arguments.length?(c=+g,p()):c},e.align=function(g){return arguments.length?(d=Math.max(0,Math.min(1,g)),p()):d},e.copy=function(){return iw(t(),[r,i]).round(s).paddingInner(u).paddingOuter(c).align(d)},ri.apply(p(),arguments)}function Wj(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return Wj(t())},e}function Tre(){return Wj(iw.apply(null,arguments).paddingInner(1))}function ow(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function Hj(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function Cc(){}var Zu=.7,_p=1/Zu,cl="\\s*([+-]?\\d+)\\s*",Qu="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",ki="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",kre=/^#([0-9a-f]{3,8})$/,Nre=new RegExp(`^rgb\\(${cl},${cl},${cl}\\)$`),Mre=new RegExp(`^rgb\\(${ki},${ki},${ki}\\)$`),Dre=new RegExp(`^rgba\\(${cl},${cl},${cl},${Qu}\\)$`),jre=new RegExp(`^rgba\\(${ki},${ki},${ki},${Qu}\\)$`),Lre=new RegExp(`^hsl\\(${Qu},${ki},${ki}\\)$`),$re=new RegExp(`^hsla\\(${Qu},${ki},${ki},${Qu}\\)$`),hP={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};ow(Cc,Ju,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:gP,formatHex:gP,formatHex8:Fre,formatHsl:Vre,formatRgb:mP,toString:mP});function gP(){return this.rgb().formatHex()}function Fre(){return this.rgb().formatHex8()}function Vre(){return Uj(this).formatHsl()}function mP(){return this.rgb().formatRgb()}function Ju(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=kre.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?vP(t):n===3?new dr(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?pd(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?pd(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=Nre.exec(e))?new dr(t[1],t[2],t[3],1):(t=Mre.exec(e))?new dr(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=Dre.exec(e))?pd(t[1],t[2],t[3],t[4]):(t=jre.exec(e))?pd(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=Lre.exec(e))?xP(t[1],t[2]/100,t[3]/100,1):(t=$re.exec(e))?xP(t[1],t[2]/100,t[3]/100,t[4]):hP.hasOwnProperty(e)?vP(hP[e]):e==="transparent"?new dr(NaN,NaN,NaN,0):null}function vP(e){return new dr(e>>16&255,e>>8&255,e&255,1)}function pd(e,t,n,r){return r<=0&&(e=t=n=NaN),new dr(e,t,n,r)}function Bre(e){return e instanceof Cc||(e=Ju(e)),e?(e=e.rgb(),new dr(e.r,e.g,e.b,e.opacity)):new dr}function Ib(e,t,n,r){return arguments.length===1?Bre(e):new dr(e,t,n,r??1)}function dr(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}ow(dr,Ib,Hj(Cc,{brighter(e){return e=e==null?_p:Math.pow(_p,e),new dr(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Zu:Math.pow(Zu,e),new dr(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new dr(Ya(this.r),Ya(this.g),Ya(this.b),Op(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:yP,formatHex:yP,formatHex8:zre,formatRgb:bP,toString:bP}));function yP(){return`#${Wa(this.r)}${Wa(this.g)}${Wa(this.b)}`}function zre(){return`#${Wa(this.r)}${Wa(this.g)}${Wa(this.b)}${Wa((isNaN(this.opacity)?1:this.opacity)*255)}`}function bP(){const e=Op(this.opacity);return`${e===1?"rgb(":"rgba("}${Ya(this.r)}, ${Ya(this.g)}, ${Ya(this.b)}${e===1?")":`, ${e})`}`}function Op(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Ya(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Wa(e){return e=Ya(e),(e<16?"0":"")+e.toString(16)}function xP(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new ui(e,t,n,r)}function Uj(e){if(e instanceof ui)return new ui(e.h,e.s,e.l,e.opacity);if(e instanceof Cc||(e=Ju(e)),!e)return new ui;if(e instanceof ui)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),o=Math.max(t,n,r),a=NaN,s=o-i,u=(o+i)/2;return s?(t===o?a=(n-r)/s+(n<r)*6:n===o?a=(r-t)/s+2:a=(t-n)/s+4,s/=u<.5?o+i:2-o-i,a*=60):s=u>0&&u<1?0:a,new ui(a,s,u,e.opacity)}function Wre(e,t,n,r){return arguments.length===1?Uj(e):new ui(e,t,n,r??1)}function ui(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}ow(ui,Wre,Hj(Cc,{brighter(e){return e=e==null?_p:Math.pow(_p,e),new ui(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Zu:Math.pow(Zu,e),new ui(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,i=2*n-r;return new dr(ty(e>=240?e-240:e+120,i,r),ty(e,i,r),ty(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new ui(wP(this.h),hd(this.s),hd(this.l),Op(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=Op(this.opacity);return`${e===1?"hsl(":"hsla("}${wP(this.h)}, ${hd(this.s)*100}%, ${hd(this.l)*100}%${e===1?")":`, ${e})`}`}}));function wP(e){return e=(e||0)%360,e<0?e+360:e}function hd(e){return Math.max(0,Math.min(1,e||0))}function ty(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 aw=e=>()=>e;function Hre(e,t){return function(n){return e+n*t}}function Ure(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 Gre(e){return(e=+e)==1?Gj:function(t,n){return n-t?Ure(t,n,e):aw(isNaN(t)?n:t)}}function Gj(e,t){var n=t-e;return n?Hre(e,n):aw(isNaN(e)?t:e)}const CP=(function e(t){var n=Gre(t);function r(i,o){var a=n((i=Ib(i)).r,(o=Ib(o)).r),s=n(i.g,o.g),u=n(i.b,o.b),c=Gj(i.opacity,o.opacity);return function(d){return i.r=a(d),i.g=s(d),i.b=u(d),i.opacity=c(d),i+""}}return r.gamma=e,r})(1);function qre(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(o){for(i=0;i<n;++i)r[i]=e[i]*(1-o)+t[i]*o;return r}}function Kre(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function Yre(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=new Array(r),o=new Array(n),a;for(a=0;a<r;++a)i[a]=Rl(e[a],t[a]);for(;a<n;++a)o[a]=t[a];return function(s){for(a=0;a<r;++a)o[a]=i[a](s);return o}}function Xre(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function Pp(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function Zre(e,t){var n={},r={},i;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(i in t)i in e?n[i]=Rl(e[i],t[i]):r[i]=t[i];return function(o){for(i in n)r[i]=n[i](o);return r}}var Tb=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,ny=new RegExp(Tb.source,"g");function Qre(e){return function(){return e}}function Jre(e){return function(t){return e(t)+""}}function eie(e,t){var n=Tb.lastIndex=ny.lastIndex=0,r,i,o,a=-1,s=[],u=[];for(e=e+"",t=t+"";(r=Tb.exec(e))&&(i=ny.exec(t));)(o=i.index)>n&&(o=t.slice(n,o),s[a]?s[a]+=o:s[++a]=o),(r=r[0])===(i=i[0])?s[a]?s[a]+=i:s[++a]=i:(s[++a]=null,u.push({i:a,x:Pp(r,i)})),n=ny.lastIndex;return n<t.length&&(o=t.slice(n),s[a]?s[a]+=o:s[++a]=o),s.length<2?u[0]?Jre(u[0].x):Qre(t):(t=u.length,function(c){for(var d=0,p;d<t;++d)s[(p=u[d]).i]=p.x(c);return s.join("")})}function Rl(e,t){var n=typeof t,r;return t==null||n==="boolean"?aw(t):(n==="number"?Pp:n==="string"?(r=Ju(t))?(t=r,CP):eie:t instanceof Ju?CP:t instanceof Date?Xre:Kre(t)?qre:Array.isArray(t)?Yre:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?Zre:Pp)(e,t)}function sw(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}function tie(e,t){t===void 0&&(t=e,e=Rl);for(var n=0,r=t.length-1,i=t[0],o=new Array(r<0?0:r);n<r;)o[n]=e(i,i=t[++n]);return function(a){var s=Math.max(0,Math.min(r-1,Math.floor(a*=r)));return o[s](a-s)}}function nie(e){return function(){return e}}function Ap(e){return+e}var SP=[0,1];function Qn(e){return e}function kb(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:nie(isNaN(t)?NaN:.5)}function rie(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function iie(e,t,n){var r=e[0],i=e[1],o=t[0],a=t[1];return i<r?(r=kb(i,r),o=n(a,o)):(r=kb(r,i),o=n(o,a)),function(s){return o(r(s))}}function oie(e,t,n){var r=Math.min(e.length,t.length)-1,i=new Array(r),o=new Array(r),a=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++a<r;)i[a]=kb(e[a],e[a+1]),o[a]=n(t[a],t[a+1]);return function(s){var u=wc(e,s,1,r)-1;return o[u](i[u](s))}}function Sc(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Yh(){var e=SP,t=SP,n=Rl,r,i,o,a=Qn,s,u,c;function d(){var g=Math.min(e.length,t.length);return a!==Qn&&(a=rie(e[0],e[g-1])),s=g>2?oie:iie,u=c=null,p}function p(g){return g==null||isNaN(g=+g)?o:(u||(u=s(e.map(r),t,n)))(r(a(g)))}return p.invert=function(g){return a(i((c||(c=s(t,e.map(r),Pp)))(g)))},p.domain=function(g){return arguments.length?(e=Array.from(g,Ap),d()):e.slice()},p.range=function(g){return arguments.length?(t=Array.from(g),d()):t.slice()},p.rangeRound=function(g){return t=Array.from(g),n=sw,d()},p.clamp=function(g){return arguments.length?(a=g?!0:Qn,d()):a!==Qn},p.interpolate=function(g){return arguments.length?(n=g,d()):n},p.unknown=function(g){return arguments.length?(o=g,p):o},function(g,h){return r=g,i=h,d()}}function lw(){return Yh()(Qn,Qn)}function aie(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Rp(e,t){if(!isFinite(e)||e===0)return null;var n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"),r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function yl(e){return e=Rp(Math.abs(e)),e?e[1]:NaN}function sie(e,t){return function(n,r){for(var i=n.length,o=[],a=0,s=e[0],u=0;i>0&&s>0&&(u+s+1>r&&(s=Math.max(1,r-u)),o.push(n.substring(i-=s,i+s)),!((u+=s+1)>r));)s=e[a=(a+1)%e.length];return o.reverse().join(t)}}function lie(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var uie=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function ec(e){if(!(t=uie.exec(e)))throw new Error("invalid format: "+e);var t;return new uw({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]})}ec.prototype=uw.prototype;function uw(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+""}uw.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 cie(e){e:for(var t=e.length,n=1,r=-1,i;n<t;++n)switch(e[n]){case".":r=i=n;break;case"0":r===0&&(r=n),i=n;break;default:if(!+e[n])break e;r>0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(i+1):e}var Ip;function fie(e,t){var n=Rp(e,t);if(!n)return Ip=void 0,e.toPrecision(t);var r=n[0],i=n[1],o=i-(Ip=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+Rp(e,Math.max(0,t+o-1))[0]}function EP(e,t){var n=Rp(e,t);if(!n)return e+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}const _P={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:aie,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)=>EP(e*100,t),r:EP,s:fie,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function OP(e){return e}var PP=Array.prototype.map,AP=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function die(e){var t=e.grouping===void 0||e.thousands===void 0?OP:sie(PP.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?OP:lie(PP.call(e.numerals,String)),a=e.percent===void 0?"%":e.percent+"",s=e.minus===void 0?"−":e.minus+"",u=e.nan===void 0?"NaN":e.nan+"";function c(p,g){p=ec(p);var h=p.fill,v=p.align,b=p.sign,y=p.symbol,w=p.zero,C=p.width,E=p.comma,_=p.precision,O=p.trim,R=p.type;R==="n"?(E=!0,R="g"):_P[R]||(_===void 0&&(_=12),O=!0,R="g"),(w||h==="0"&&v==="=")&&(w=!0,h="0",v="=");var I=(g&&g.prefix!==void 0?g.prefix:"")+(y==="$"?n:y==="#"&&/[boxX]/.test(R)?"0"+R.toLowerCase():""),k=(y==="$"?r:/[%p]/.test(R)?a:"")+(g&&g.suffix!==void 0?g.suffix:""),B=_P[R],L=/[defgprs%]/.test(R);_=_===void 0?6:/[gprs]/.test(R)?Math.max(1,Math.min(21,_)):Math.max(0,Math.min(20,_));function V(D){var H=I,J=k,te,G,ee;if(R==="c")J=B(D)+J,D="";else{D=+D;var Q=D<0||1/D<0;if(D=isNaN(D)?u:B(Math.abs(D),_),O&&(D=cie(D)),Q&&+D==0&&b!=="+"&&(Q=!1),H=(Q?b==="("?b:s:b==="-"||b==="("?"":b)+H,J=(R==="s"&&!isNaN(D)&&Ip!==void 0?AP[8+Ip/3]:"")+J+(Q&&b==="("?")":""),L){for(te=-1,G=D.length;++te<G;)if(ee=D.charCodeAt(te),48>ee||ee>57){J=(ee===46?i+D.slice(te+1):D.slice(te))+J,D=D.slice(0,te);break}}}E&&!w&&(D=t(D,1/0));var pe=H.length+D.length+J.length,K=pe<C?new Array(C-pe+1).join(h):"";switch(E&&w&&(D=t(K+D,K.length?C-J.length:1/0),K=""),v){case"<":D=H+D+J+K;break;case"=":D=H+K+D+J;break;case"^":D=K.slice(0,pe=K.length>>1)+H+D+J+K.slice(pe);break;default:D=K+H+D+J;break}return o(D)}return V.toString=function(){return p+""},V}function d(p,g){var h=Math.max(-8,Math.min(8,Math.floor(yl(g)/3)))*3,v=Math.pow(10,-h),b=c((p=ec(p),p.type="f",p),{suffix:AP[8+h/3]});return function(y){return b(v*y)}}return{format:c,formatPrefix:d}}var gd,cw,qj;pie({thousands:",",grouping:[3],currency:["$",""]});function pie(e){return gd=die(e),cw=gd.format,qj=gd.formatPrefix,gd}function hie(e){return Math.max(0,-yl(Math.abs(e)))}function gie(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(yl(t)/3)))*3-yl(Math.abs(e)))}function mie(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,yl(t)-yl(e))+1}function Kj(e,t,n,r){var i=Ab(e,t,n),o;switch(r=ec(r??",f"),r.type){case"s":{var a=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(o=gie(i,a))&&(r.precision=o),qj(r,a)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(o=mie(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=o-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(o=hie(i))&&(r.precision=o-(r.type==="%")*2);break}}return cw(r)}function ha(e){var t=e.domain;return e.ticks=function(n){var r=t();return Ob(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var i=t();return Kj(i[0],i[i.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),i=0,o=r.length-1,a=r[i],s=r[o],u,c,d=10;for(s<a&&(c=a,a=s,s=c,c=i,i=o,o=c);d-- >0;){if(c=Pb(a,s,n),c===u)return r[i]=a,r[o]=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;u=c}return e},e}function Yj(){var e=lw();return e.copy=function(){return Sc(e,Yj())},ri.apply(e,arguments),ha(e)}function Xj(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,Ap),n):e.slice()},n.unknown=function(r){return arguments.length?(t=r,n):t},n.copy=function(){return Xj(e).unknown(t)},e=arguments.length?Array.from(e,Ap):[0,1],ha(n)}function Zj(e,t){e=e.slice();var n=0,r=e.length-1,i=e[n],o=e[r],a;return o<i&&(a=n,n=r,r=a,a=i,i=o,o=a),e[n]=t.floor(i),e[r]=t.ceil(o),e}function RP(e){return Math.log(e)}function IP(e){return Math.exp(e)}function vie(e){return-Math.log(-e)}function yie(e){return-Math.exp(-e)}function bie(e){return isFinite(e)?+("1e"+e):e<0?0:e}function xie(e){return e===10?bie:e===Math.E?Math.exp:t=>Math.pow(e,t)}function wie(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 TP(e){return(t,n)=>-e(-t,n)}function fw(e){const t=e(RP,IP),n=t.domain;let r=10,i,o;function a(){return i=wie(r),o=xie(r),n()[0]<0?(i=TP(i),o=TP(o),e(vie,yie)):e(RP,IP),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 u=n();let c=u[0],d=u[u.length-1];const p=d<c;p&&([c,d]=[d,c]);let g=i(c),h=i(d),v,b;const y=s==null?10:+s;let w=[];if(!(r%1)&&h-g<y){if(g=Math.floor(g),h=Math.ceil(h),c>0){for(;g<=h;++g)for(v=1;v<r;++v)if(b=g<0?v/o(-g):v*o(g),!(b<c)){if(b>d)break;w.push(b)}}else for(;g<=h;++g)for(v=r-1;v>=1;--v)if(b=g>0?v/o(-g):v*o(g),!(b<c)){if(b>d)break;w.push(b)}w.length*2<y&&(w=Ob(c,d,y))}else w=Ob(g,h,Math.min(h-g,y)).map(o);return p?w.reverse():w},t.tickFormat=(s,u)=>{if(s==null&&(s=10),u==null&&(u=r===10?"s":","),typeof u!="function"&&(!(r%1)&&(u=ec(u)).precision==null&&(u.trim=!0),u=cw(u)),s===1/0)return u;const c=Math.max(1,r*s/t.ticks().length);return d=>{let p=d/o(Math.round(i(d)));return p*r<r-.5&&(p*=r),p<=c?u(d):""}},t.nice=()=>n(Zj(n(),{floor:s=>o(Math.floor(i(s))),ceil:s=>o(Math.ceil(i(s)))})),t}function Qj(){const e=fw(Yh()).domain([1,10]);return e.copy=()=>Sc(e,Qj()).base(e.base()),ri.apply(e,arguments),e}function kP(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function NP(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function dw(e){var t=1,n=e(kP(t),NP(t));return n.constant=function(r){return arguments.length?e(kP(t=+r),NP(t)):t},ha(n)}function Jj(){var e=dw(Yh());return e.copy=function(){return Sc(e,Jj()).constant(e.constant())},ri.apply(e,arguments)}function MP(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function Cie(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function Sie(e){return e<0?-e*e:e*e}function pw(e){var t=e(Qn,Qn),n=1;function r(){return n===1?e(Qn,Qn):n===.5?e(Cie,Sie):e(MP(n),MP(1/n))}return t.exponent=function(i){return arguments.length?(n=+i,r()):n},ha(t)}function hw(){var e=pw(Yh());return e.copy=function(){return Sc(e,hw()).exponent(e.exponent())},ri.apply(e,arguments),e}function Eie(){return hw.apply(null,arguments).exponent(.5)}function DP(e){return Math.sign(e)*e*e}function _ie(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function e2(){var e=lw(),t=[0,1],n=!1,r;function i(o){var a=_ie(e(o));return isNaN(a)?r:n?Math.round(a):a}return i.invert=function(o){return e.invert(DP(o))},i.domain=function(o){return arguments.length?(e.domain(o),i):e.domain()},i.range=function(o){return arguments.length?(e.range((t=Array.from(o,Ap)).map(DP)),i):t.slice()},i.rangeRound=function(o){return i.range(o).round(!0)},i.round=function(o){return arguments.length?(n=!!o,i):n},i.clamp=function(o){return arguments.length?(e.clamp(o),i):e.clamp()},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return e2(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},ri.apply(i,arguments),ha(i)}function t2(){var e=[],t=[],n=[],r;function i(){var a=0,s=Math.max(1,t.length);for(n=new Array(s-1);++a<s;)n[a-1]=Rre(e,a/s);return o}function o(a){return a==null||isNaN(a=+a)?r:t[wc(n,a)]}return o.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]]},o.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(na),i()},o.range=function(a){return arguments.length?(t=Array.from(a),i()):t.slice()},o.unknown=function(a){return arguments.length?(r=a,o):r},o.quantiles=function(){return n.slice()},o.copy=function(){return t2().domain(e).range(t).unknown(r)},ri.apply(o,arguments)}function n2(){var e=0,t=1,n=1,r=[.5],i=[0,1],o;function a(u){return u!=null&&u<=u?i[wc(r,u,0,n)]:o}function s(){var u=-1;for(r=new Array(n);++u<n;)r[u]=((u+1)*t-(u-n)*e)/(n+1);return a}return a.domain=function(u){return arguments.length?([e,t]=u,e=+e,t=+t,s()):[e,t]},a.range=function(u){return arguments.length?(n=(i=Array.from(u)).length-1,s()):i.slice()},a.invertExtent=function(u){var c=i.indexOf(u);return c<0?[NaN,NaN]:c<1?[e,r[0]]:c>=n?[r[n-1],t]:[r[c-1],r[c]]},a.unknown=function(u){return arguments.length&&(o=u),a},a.thresholds=function(){return r.slice()},a.copy=function(){return n2().domain([e,t]).range(i).unknown(o)},ri.apply(ha(a),arguments)}function r2(){var e=[.5],t=[0,1],n,r=1;function i(o){return o!=null&&o<=o?t[wc(e,o,0,r)]:n}return i.domain=function(o){return arguments.length?(e=Array.from(o),r=Math.min(e.length,t.length-1),i):e.slice()},i.range=function(o){return arguments.length?(t=Array.from(o),r=Math.min(e.length,t.length-1),i):t.slice()},i.invertExtent=function(o){var a=t.indexOf(o);return[e[a-1],e[a]]},i.unknown=function(o){return arguments.length?(n=o,i):n},i.copy=function(){return r2().domain(e).range(t).unknown(n)},ri.apply(i,arguments)}const ry=new Date,iy=new Date;function hn(e,t,n,r){function i(o){return e(o=arguments.length===0?new Date:new Date(+o)),o}return i.floor=o=>(e(o=new Date(+o)),o),i.ceil=o=>(e(o=new Date(o-1)),t(o,1),e(o),o),i.round=o=>{const a=i(o),s=i.ceil(o);return o-a<s-o?a:s},i.offset=(o,a)=>(t(o=new Date(+o),a==null?1:Math.floor(a)),o),i.range=(o,a,s)=>{const u=[];if(o=i.ceil(o),s=s==null?1:Math.floor(s),!(o<a)||!(s>0))return u;let c;do u.push(c=new Date(+o)),t(o,s),e(o);while(c<o&&o<a);return u},i.filter=o=>hn(a=>{if(a>=a)for(;e(a),!o(a);)a.setTime(a-1)},(a,s)=>{if(a>=a)if(s<0)for(;++s<=0;)for(;t(a,-1),!o(a););else for(;--s>=0;)for(;t(a,1),!o(a););}),n&&(i.count=(o,a)=>(ry.setTime(+o),iy.setTime(+a),e(ry),e(iy),Math.floor(n(ry,iy))),i.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?i.filter(r?a=>r(a)%o===0:a=>i.count(0,a)%o===0):i)),i}const Tp=hn(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Tp.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?hn(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):Tp);Tp.range;const ro=1e3,Jr=ro*60,io=Jr*60,ho=io*24,gw=ho*7,jP=ho*30,oy=ho*365,Ha=hn(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*ro)},(e,t)=>(t-e)/ro,e=>e.getUTCSeconds());Ha.range;const mw=hn(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*ro)},(e,t)=>{e.setTime(+e+t*Jr)},(e,t)=>(t-e)/Jr,e=>e.getMinutes());mw.range;const vw=hn(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Jr)},(e,t)=>(t-e)/Jr,e=>e.getUTCMinutes());vw.range;const yw=hn(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*ro-e.getMinutes()*Jr)},(e,t)=>{e.setTime(+e+t*io)},(e,t)=>(t-e)/io,e=>e.getHours());yw.range;const bw=hn(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*io)},(e,t)=>(t-e)/io,e=>e.getUTCHours());bw.range;const Ec=hn(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Jr)/ho,e=>e.getDate()-1);Ec.range;const Xh=hn(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/ho,e=>e.getUTCDate()-1);Xh.range;const i2=hn(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/ho,e=>Math.floor(e/ho));i2.range;function ps(e){return hn(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())*Jr)/gw)}const Zh=ps(0),kp=ps(1),Oie=ps(2),Pie=ps(3),bl=ps(4),Aie=ps(5),Rie=ps(6);Zh.range;kp.range;Oie.range;Pie.range;bl.range;Aie.range;Rie.range;function hs(e){return hn(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)/gw)}const Qh=hs(0),Np=hs(1),Iie=hs(2),Tie=hs(3),xl=hs(4),kie=hs(5),Nie=hs(6);Qh.range;Np.range;Iie.range;Tie.range;xl.range;kie.range;Nie.range;const xw=hn(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());xw.range;const ww=hn(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());ww.range;const go=hn(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());go.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:hn(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)});go.range;const mo=hn(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());mo.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:hn(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)});mo.range;function o2(e,t,n,r,i,o){const a=[[Ha,1,ro],[Ha,5,5*ro],[Ha,15,15*ro],[Ha,30,30*ro],[o,1,Jr],[o,5,5*Jr],[o,15,15*Jr],[o,30,30*Jr],[i,1,io],[i,3,3*io],[i,6,6*io],[i,12,12*io],[r,1,ho],[r,2,2*ho],[n,1,gw],[t,1,jP],[t,3,3*jP],[e,1,oy]];function s(c,d,p){const g=d<c;g&&([c,d]=[d,c]);const h=p&&typeof p.range=="function"?p:u(c,d,p),v=h?h.range(c,+d+1):[];return g?v.reverse():v}function u(c,d,p){const g=Math.abs(d-c)/p,h=nw(([,,y])=>y).right(a,g);if(h===a.length)return e.every(Ab(c/oy,d/oy,p));if(h===0)return Tp.every(Math.max(Ab(c,d,p),1));const[v,b]=a[g/a[h-1][2]<a[h][2]/g?h-1:h];return v.every(b)}return[s,u]}const[Mie,Die]=o2(mo,ww,Qh,i2,bw,vw),[jie,Lie]=o2(go,xw,Zh,Ec,yw,mw);function ay(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 sy(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 mu(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function $ie(e){var t=e.dateTime,n=e.date,r=e.time,i=e.periods,o=e.days,a=e.shortDays,s=e.months,u=e.shortMonths,c=vu(i),d=yu(i),p=vu(o),g=yu(o),h=vu(a),v=yu(a),b=vu(s),y=yu(s),w=vu(u),C=yu(u),E={a:ee,A:Q,b:pe,B:K,c:null,d:zP,e:zP,f:soe,g:voe,G:boe,H:ioe,I:ooe,j:aoe,L:a2,m:loe,M:uoe,p:Ae,q:Se,Q:UP,s:GP,S:coe,u:foe,U:doe,V:poe,w:hoe,W:goe,x:null,X:null,y:moe,Y:yoe,Z:xoe,"%":HP},_={a:$e,A:we,b:Ce,B:ze,c:null,d:WP,e:WP,f:Eoe,g:Moe,G:joe,H:woe,I:Coe,j:Soe,L:l2,m:_oe,M:Ooe,p:Ke,q:Fe,Q:UP,s:GP,S:Poe,u:Aoe,U:Roe,V:Ioe,w:Toe,W:koe,x:null,X:null,y:Noe,Y:Doe,Z:Loe,"%":HP},O={a:L,A:V,b:D,B:H,c:J,d:VP,e:VP,f:eoe,g:FP,G:$P,H:BP,I:BP,j:Xie,L:Jie,m:Yie,M:Zie,p:B,q:Kie,Q:noe,s:roe,S:Qie,u:Wie,U:Hie,V:Uie,w:zie,W:Gie,x:te,X:G,y:FP,Y:$P,Z:qie,"%":toe};E.x=R(n,E),E.X=R(r,E),E.c=R(t,E),_.x=R(n,_),_.X=R(r,_),_.c=R(t,_);function R(Y,oe){return function(ne){var $=[],ie=-1,Z=0,Re=Y.length,U,fe,me;for(ne instanceof Date||(ne=new Date(+ne));++ie<Re;)Y.charCodeAt(ie)===37&&($.push(Y.slice(Z,ie)),(fe=LP[U=Y.charAt(++ie)])!=null?U=Y.charAt(++ie):fe=U==="e"?" ":"0",(me=oe[U])&&(U=me(ne,fe)),$.push(U),Z=ie+1);return $.push(Y.slice(Z,ie)),$.join("")}}function I(Y,oe){return function(ne){var $=mu(1900,void 0,1),ie=k($,Y,ne+="",0),Z,Re;if(ie!=ne.length)return null;if("Q"in $)return new Date($.Q);if("s"in $)return new Date($.s*1e3+("L"in $?$.L:0));if(oe&&!("Z"in $)&&($.Z=0),"p"in $&&($.H=$.H%12+$.p*12),$.m===void 0&&($.m="q"in $?$.q:0),"V"in $){if($.V<1||$.V>53)return null;"w"in $||($.w=1),"Z"in $?(Z=sy(mu($.y,0,1)),Re=Z.getUTCDay(),Z=Re>4||Re===0?Np.ceil(Z):Np(Z),Z=Xh.offset(Z,($.V-1)*7),$.y=Z.getUTCFullYear(),$.m=Z.getUTCMonth(),$.d=Z.getUTCDate()+($.w+6)%7):(Z=ay(mu($.y,0,1)),Re=Z.getDay(),Z=Re>4||Re===0?kp.ceil(Z):kp(Z),Z=Ec.offset(Z,($.V-1)*7),$.y=Z.getFullYear(),$.m=Z.getMonth(),$.d=Z.getDate()+($.w+6)%7)}else("W"in $||"U"in $)&&("w"in $||($.w="u"in $?$.u%7:"W"in $?1:0),Re="Z"in $?sy(mu($.y,0,1)).getUTCDay():ay(mu($.y,0,1)).getDay(),$.m=0,$.d="W"in $?($.w+6)%7+$.W*7-(Re+5)%7:$.w+$.U*7-(Re+6)%7);return"Z"in $?($.H+=$.Z/100|0,$.M+=$.Z%100,sy($)):ay($)}}function k(Y,oe,ne,$){for(var ie=0,Z=oe.length,Re=ne.length,U,fe;ie<Z;){if($>=Re)return-1;if(U=oe.charCodeAt(ie++),U===37){if(U=oe.charAt(ie++),fe=O[U in LP?oe.charAt(ie++):U],!fe||($=fe(Y,ne,$))<0)return-1}else if(U!=ne.charCodeAt($++))return-1}return $}function B(Y,oe,ne){var $=c.exec(oe.slice(ne));return $?(Y.p=d.get($[0].toLowerCase()),ne+$[0].length):-1}function L(Y,oe,ne){var $=h.exec(oe.slice(ne));return $?(Y.w=v.get($[0].toLowerCase()),ne+$[0].length):-1}function V(Y,oe,ne){var $=p.exec(oe.slice(ne));return $?(Y.w=g.get($[0].toLowerCase()),ne+$[0].length):-1}function D(Y,oe,ne){var $=w.exec(oe.slice(ne));return $?(Y.m=C.get($[0].toLowerCase()),ne+$[0].length):-1}function H(Y,oe,ne){var $=b.exec(oe.slice(ne));return $?(Y.m=y.get($[0].toLowerCase()),ne+$[0].length):-1}function J(Y,oe,ne){return k(Y,t,oe,ne)}function te(Y,oe,ne){return k(Y,n,oe,ne)}function G(Y,oe,ne){return k(Y,r,oe,ne)}function ee(Y){return a[Y.getDay()]}function Q(Y){return o[Y.getDay()]}function pe(Y){return u[Y.getMonth()]}function K(Y){return s[Y.getMonth()]}function Ae(Y){return i[+(Y.getHours()>=12)]}function Se(Y){return 1+~~(Y.getMonth()/3)}function $e(Y){return a[Y.getUTCDay()]}function we(Y){return o[Y.getUTCDay()]}function Ce(Y){return u[Y.getUTCMonth()]}function ze(Y){return s[Y.getUTCMonth()]}function Ke(Y){return i[+(Y.getUTCHours()>=12)]}function Fe(Y){return 1+~~(Y.getUTCMonth()/3)}return{format:function(Y){var oe=R(Y+="",E);return oe.toString=function(){return Y},oe},parse:function(Y){var oe=I(Y+="",!1);return oe.toString=function(){return Y},oe},utcFormat:function(Y){var oe=R(Y+="",_);return oe.toString=function(){return Y},oe},utcParse:function(Y){var oe=I(Y+="",!0);return oe.toString=function(){return Y},oe}}}var LP={"-":"",_:" ",0:"0"},En=/^\s*\d+/,Fie=/^%/,Vie=/[\\^$*+?|[\]().{}]/g;function dt(e,t,n){var r=e<0?"-":"",i=(r?-e:e)+"",o=i.length;return r+(o<n?new Array(n-o+1).join(t)+i:i)}function Bie(e){return e.replace(Vie,"\\$&")}function vu(e){return new RegExp("^(?:"+e.map(Bie).join("|")+")","i")}function yu(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function zie(e,t,n){var r=En.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function Wie(e,t,n){var r=En.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function Hie(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function Uie(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function Gie(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function $P(e,t,n){var r=En.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function FP(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function qie(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 Kie(e,t,n){var r=En.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function Yie(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function VP(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function Xie(e,t,n){var r=En.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function BP(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function Zie(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function Qie(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function Jie(e,t,n){var r=En.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function eoe(e,t,n){var r=En.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function toe(e,t,n){var r=Fie.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function noe(e,t,n){var r=En.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function roe(e,t,n){var r=En.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function zP(e,t){return dt(e.getDate(),t,2)}function ioe(e,t){return dt(e.getHours(),t,2)}function ooe(e,t){return dt(e.getHours()%12||12,t,2)}function aoe(e,t){return dt(1+Ec.count(go(e),e),t,3)}function a2(e,t){return dt(e.getMilliseconds(),t,3)}function soe(e,t){return a2(e,t)+"000"}function loe(e,t){return dt(e.getMonth()+1,t,2)}function uoe(e,t){return dt(e.getMinutes(),t,2)}function coe(e,t){return dt(e.getSeconds(),t,2)}function foe(e){var t=e.getDay();return t===0?7:t}function doe(e,t){return dt(Zh.count(go(e)-1,e),t,2)}function s2(e){var t=e.getDay();return t>=4||t===0?bl(e):bl.ceil(e)}function poe(e,t){return e=s2(e),dt(bl.count(go(e),e)+(go(e).getDay()===4),t,2)}function hoe(e){return e.getDay()}function goe(e,t){return dt(kp.count(go(e)-1,e),t,2)}function moe(e,t){return dt(e.getFullYear()%100,t,2)}function voe(e,t){return e=s2(e),dt(e.getFullYear()%100,t,2)}function yoe(e,t){return dt(e.getFullYear()%1e4,t,4)}function boe(e,t){var n=e.getDay();return e=n>=4||n===0?bl(e):bl.ceil(e),dt(e.getFullYear()%1e4,t,4)}function xoe(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+dt(t/60|0,"0",2)+dt(t%60,"0",2)}function WP(e,t){return dt(e.getUTCDate(),t,2)}function woe(e,t){return dt(e.getUTCHours(),t,2)}function Coe(e,t){return dt(e.getUTCHours()%12||12,t,2)}function Soe(e,t){return dt(1+Xh.count(mo(e),e),t,3)}function l2(e,t){return dt(e.getUTCMilliseconds(),t,3)}function Eoe(e,t){return l2(e,t)+"000"}function _oe(e,t){return dt(e.getUTCMonth()+1,t,2)}function Ooe(e,t){return dt(e.getUTCMinutes(),t,2)}function Poe(e,t){return dt(e.getUTCSeconds(),t,2)}function Aoe(e){var t=e.getUTCDay();return t===0?7:t}function Roe(e,t){return dt(Qh.count(mo(e)-1,e),t,2)}function u2(e){var t=e.getUTCDay();return t>=4||t===0?xl(e):xl.ceil(e)}function Ioe(e,t){return e=u2(e),dt(xl.count(mo(e),e)+(mo(e).getUTCDay()===4),t,2)}function Toe(e){return e.getUTCDay()}function koe(e,t){return dt(Np.count(mo(e)-1,e),t,2)}function Noe(e,t){return dt(e.getUTCFullYear()%100,t,2)}function Moe(e,t){return e=u2(e),dt(e.getUTCFullYear()%100,t,2)}function Doe(e,t){return dt(e.getUTCFullYear()%1e4,t,4)}function joe(e,t){var n=e.getUTCDay();return e=n>=4||n===0?xl(e):xl.ceil(e),dt(e.getUTCFullYear()%1e4,t,4)}function Loe(){return"+0000"}function HP(){return"%"}function UP(e){return+e}function GP(e){return Math.floor(+e/1e3)}var Ks,c2,f2;$oe({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 $oe(e){return Ks=$ie(e),c2=Ks.format,Ks.parse,f2=Ks.utcFormat,Ks.utcParse,Ks}function Foe(e){return new Date(e)}function Voe(e){return e instanceof Date?+e:+new Date(+e)}function Cw(e,t,n,r,i,o,a,s,u,c){var d=lw(),p=d.invert,g=d.domain,h=c(".%L"),v=c(":%S"),b=c("%I:%M"),y=c("%I %p"),w=c("%a %d"),C=c("%b %d"),E=c("%B"),_=c("%Y");function O(R){return(u(R)<R?h:s(R)<R?v:a(R)<R?b:o(R)<R?y:r(R)<R?i(R)<R?w:C:n(R)<R?E:_)(R)}return d.invert=function(R){return new Date(p(R))},d.domain=function(R){return arguments.length?g(Array.from(R,Voe)):g().map(Foe)},d.ticks=function(R){var I=g();return e(I[0],I[I.length-1],R??10)},d.tickFormat=function(R,I){return I==null?O:c(I)},d.nice=function(R){var I=g();return(!R||typeof R.range!="function")&&(R=t(I[0],I[I.length-1],R??10)),R?g(Zj(I,R)):d},d.copy=function(){return Sc(d,Cw(e,t,n,r,i,o,a,s,u,c))},d}function Boe(){return ri.apply(Cw(jie,Lie,go,xw,Zh,Ec,yw,mw,Ha,c2).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function zoe(){return ri.apply(Cw(Mie,Die,mo,ww,Qh,Xh,bw,vw,Ha,f2).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function Jh(){var e=0,t=1,n,r,i,o,a=Qn,s=!1,u;function c(p){return p==null||isNaN(p=+p)?u:a(i===0?.5:(p=(o(p)-n)*i,s?Math.max(0,Math.min(1,p)):p))}c.domain=function(p){return arguments.length?([e,t]=p,n=o(e=+e),r=o(t=+t),i=n===r?0:1/(r-n),c):[e,t]},c.clamp=function(p){return arguments.length?(s=!!p,c):s},c.interpolator=function(p){return arguments.length?(a=p,c):a};function d(p){return function(g){var h,v;return arguments.length?([h,v]=g,a=p(h,v),c):[a(0),a(1)]}}return c.range=d(Rl),c.rangeRound=d(sw),c.unknown=function(p){return arguments.length?(u=p,c):u},function(p){return o=p,n=p(e),r=p(t),i=n===r?0:1/(r-n),c}}function ga(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function d2(){var e=ha(Jh()(Qn));return e.copy=function(){return ga(e,d2())},So.apply(e,arguments)}function p2(){var e=fw(Jh()).domain([1,10]);return e.copy=function(){return ga(e,p2()).base(e.base())},So.apply(e,arguments)}function h2(){var e=dw(Jh());return e.copy=function(){return ga(e,h2()).constant(e.constant())},So.apply(e,arguments)}function Sw(){var e=pw(Jh());return e.copy=function(){return ga(e,Sw()).exponent(e.exponent())},So.apply(e,arguments)}function Woe(){return Sw.apply(null,arguments).exponent(.5)}function g2(){var e=[],t=Qn;function n(r){if(r!=null&&!isNaN(r=+r))return t((wc(e,r,1)-1)/(e.length-1))}return n.domain=function(r){if(!arguments.length)return e.slice();e=[];for(let i of r)i!=null&&!isNaN(i=+i)&&e.push(i);return e.sort(na),n},n.interpolator=function(r){return arguments.length?(t=r,n):t},n.range=function(){return e.map((r,i)=>t(i/(e.length-1)))},n.quantiles=function(r){return Array.from({length:r+1},(i,o)=>Are(e,o/r))},n.copy=function(){return g2(t).domain(e)},So.apply(n,arguments)}function eg(){var e=0,t=.5,n=1,r=1,i,o,a,s,u,c=Qn,d,p=!1,g;function h(b){return isNaN(b=+b)?g:(b=.5+((b=+d(b))-o)*(r*b<r*o?s:u),c(p?Math.max(0,Math.min(1,b)):b))}h.domain=function(b){return arguments.length?([e,t,n]=b,i=d(e=+e),o=d(t=+t),a=d(n=+n),s=i===o?0:.5/(o-i),u=o===a?0:.5/(a-o),r=o<i?-1:1,h):[e,t,n]},h.clamp=function(b){return arguments.length?(p=!!b,h):p},h.interpolator=function(b){return arguments.length?(c=b,h):c};function v(b){return function(y){var w,C,E;return arguments.length?([w,C,E]=y,c=tie(b,[w,C,E]),h):[c(0),c(.5),c(1)]}}return h.range=v(Rl),h.rangeRound=v(sw),h.unknown=function(b){return arguments.length?(g=b,h):g},function(b){return d=b,i=b(e),o=b(t),a=b(n),s=i===o?0:.5/(o-i),u=o===a?0:.5/(a-o),r=o<i?-1:1,h}}function m2(){var e=ha(eg()(Qn));return e.copy=function(){return ga(e,m2())},So.apply(e,arguments)}function v2(){var e=fw(eg()).domain([.1,1,10]);return e.copy=function(){return ga(e,v2()).base(e.base())},So.apply(e,arguments)}function y2(){var e=dw(eg());return e.copy=function(){return ga(e,y2()).constant(e.constant())},So.apply(e,arguments)}function Ew(){var e=pw(eg());return e.copy=function(){return ga(e,Ew()).exponent(e.exponent())},So.apply(e,arguments)}function Hoe(){return Ew.apply(null,arguments).exponent(.5)}const Ou=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:iw,scaleDiverging:m2,scaleDivergingLog:v2,scaleDivergingPow:Ew,scaleDivergingSqrt:Hoe,scaleDivergingSymlog:y2,scaleIdentity:Xj,scaleImplicit:Rb,scaleLinear:Yj,scaleLog:Qj,scaleOrdinal:rw,scalePoint:Tre,scalePow:hw,scaleQuantile:t2,scaleQuantize:n2,scaleRadial:e2,scaleSequential:d2,scaleSequentialLog:p2,scaleSequentialPow:Sw,scaleSequentialQuantile:g2,scaleSequentialSqrt:Woe,scaleSequentialSymlog:h2,scaleSqrt:Eie,scaleSymlog:Jj,scaleThreshold:r2,scaleTime:Boe,scaleUtc:zoe,tickFormat:Kj},Symbol.toStringTag,{value:"Module"}));function Uoe(e){if(e in Ou)return Ou[e]();var t="scale".concat(dc(e));if(t in Ou)return Ou[t]()}function qP(e,t,n){if(typeof e=="function")return e.copy().domain(t).range(n);if(e!=null){var r=Uoe(e);if(r!=null)return r.domain(t).range(n),r}}function _w(e,t,n,r){if(!(n==null||r==null))return typeof e.scale=="function"?qP(e.scale,n,r):qP(t,n,r)}function Goe(e){return"scale".concat(dc(e))}function qoe(e){return Goe(e)in Ou}var b2=(e,t,n)=>{if(e!=null){var{scale:r,type:i}=e;if(r==="auto")return i==="category"&&n&&(n.indexOf("LineChart")>=0||n.indexOf("AreaChart")>=0||n.indexOf("ComposedChart")>=0&&!t)?"point":i==="category"?"band":"linear";if(typeof r=="string")return qoe(r)?r:"point"}};function Koe(e,t){for(var n=0,r=e.length,i=e[0]<e[e.length-1];n<r;){var o=Math.floor((n+r)/2);(i?e[o]<t:e[o]>t)?n=o+1:r=o}return n}function x2(e,t){if(e){var n=t??e.domain(),r=n.map(o=>{var a;return(a=e(o))!==null&&a!==void 0?a:0}),i=e.range();if(!(n.length===0||i.length<2))return o=>{var a,s,u=Koe(r,o);if(u<=0)return n[0];if(u>=n.length)return n[n.length-1];var c=(a=r[u-1])!==null&&a!==void 0?a:0,d=(s=r[u])!==null&&s!==void 0?s:0;return Math.abs(o-c)<=Math.abs(o-d)?n[u-1]:n[u]}}}function Yoe(e){if(e!=null)return"invert"in e&&typeof e.invert=="function"?e.invert.bind(e):x2(e,void 0)}function KP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Mp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?KP(Object(n),!0).forEach(function(r){Xoe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):KP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Xoe(e,t,n){return(t=Zoe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Zoe(e){var t=Qoe(e,"string");return typeof t=="symbol"?t:t+""}function Qoe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Nb=[0,"auto"],un={allowDataOverflow:!1,allowDecimals:!0,allowDuplicatedCategory:!0,angle:0,dataKey:void 0,domain:void 0,height:30,hide:!0,id:0,includeHidden:!1,interval:"preserveEnd",minTickGap:5,mirror:!1,name:void 0,orientation:"bottom",padding:{left:0,right:0},reversed:!1,scale:"auto",tick:!0,tickCount:5,tickFormatter:void 0,ticks:void 0,type:"category",unit:void 0,niceTicks:"auto"},w2=(e,t)=>e.cartesianAxis.xAxis[t],Eo=(e,t)=>{var n=w2(e,t);return n??un},cn={allowDataOverflow:!1,allowDecimals:!0,allowDuplicatedCategory:!0,angle:0,dataKey:void 0,domain:Nb,hide:!0,id:0,includeHidden:!1,interval:"preserveEnd",minTickGap:5,mirror:!1,name:void 0,orientation:"left",padding:{top:0,bottom:0},reversed:!1,scale:"auto",tick:!0,tickCount:5,tickFormatter:void 0,ticks:void 0,type:"number",unit:void 0,niceTicks:"auto",width:vc},C2=(e,t)=>e.cartesianAxis.yAxis[t],_o=(e,t)=>{var n=C2(e,t);return n??cn},Joe={domain:[0,"auto"],includeHidden:!1,reversed:!1,allowDataOverflow:!1,allowDuplicatedCategory:!1,dataKey:void 0,id:0,name:"",range:[64,64],scale:"auto",type:"number",unit:""},Ow=(e,t)=>{var n=e.cartesianAxis.zAxis[t];return n??Joe},tr=(e,t,n)=>{switch(t){case"xAxis":return Eo(e,n);case"yAxis":return _o(e,n);case"zAxis":return Ow(e,n);case"angleAxis":return Zx(e,n);case"radiusAxis":return Qx(e,n);default:throw new Error("Unexpected axis type: ".concat(t))}},eae=(e,t,n)=>{switch(t){case"xAxis":return Eo(e,n);case"yAxis":return _o(e,n);default:throw new Error("Unexpected axis type: ".concat(t))}},_c=(e,t,n)=>{switch(t){case"xAxis":return Eo(e,n);case"yAxis":return _o(e,n);case"angleAxis":return Zx(e,n);case"radiusAxis":return Qx(e,n);default:throw new Error("Unexpected axis type: ".concat(t))}},S2=e=>e.graphicalItems.cartesianItems.some(t=>t.type==="bar")||e.graphicalItems.polarItems.some(t=>t.type==="radialBar");function E2(e,t){return n=>{switch(e){case"xAxis":return"xAxisId"in n&&n.xAxisId===t;case"yAxis":return"yAxisId"in n&&n.yAxisId===t;case"zAxis":return"zAxisId"in n&&n.zAxisId===t;case"angleAxis":return"angleAxisId"in n&&n.angleAxisId===t;case"radiusAxis":return"radiusAxisId"in n&&n.radiusAxisId===t;default:return!1}}}var Pw=e=>e.graphicalItems.cartesianItems,tae=q([Cn,Uh],E2),_2=(e,t,n)=>e.filter(n).filter(r=>t?.includeHidden===!0?!0:!r.hide),Oc=q([Pw,tr,tae],_2,{memoizeOptions:{resultEqualityCheck:Kh}}),O2=q([Oc],e=>e.filter(t=>t.type==="area"||t.type==="bar").filter(Gh)),P2=e=>e.filter(t=>!("stackId"in t)||t.stackId===void 0),nae=q([Oc],P2),A2=e=>e.map(t=>t.data).filter(Boolean).flat(1),rae=q([Oc],A2,{memoizeOptions:{resultEqualityCheck:Kh}}),R2=(e,t)=>{var{chartData:n=[],dataStartIndex:r,dataEndIndex:i}=t;return e.length>0?e:n.slice(r,i+1)},Aw=q([rae,yj],R2),I2=(e,t,n)=>t?.dataKey!=null?e.map(r=>({value:Mn(r,t.dataKey)})):n.length>0?n.map(r=>r.dataKey).flatMap(r=>e.map(i=>({value:Mn(i,r)}))):e.map(r=>({value:r})),Pc=q([Aw,tr,Oc],I2);function fl(e){if(ji(e)||e instanceof Date){var t=Number(e);if(ct(t))return t}}function YP(e){if(Array.isArray(e)){var t=[fl(e[0]),fl(e[1])];return Ti(t)?t:void 0}var n=fl(e);if(n!=null)return[n,n]}function vo(e){return e.map(fl).filter(fr)}function iae(e,t){var n=fl(e),r=fl(t);return n==null&&r==null?0:n==null?-1:r==null?1:n-r}var oae=q([Pc],e=>e?.map(t=>t.value).sort(iae));function T2(e,t){switch(e){case"xAxis":return t.direction==="x";case"yAxis":return t.direction==="y";default:return!1}}function aae(e,t,n){return!n||typeof t!="number"||Di(t)?[]:n.length?vo(n.flatMap(r=>{var i=Mn(e,r.dataKey),o,a;if(Array.isArray(i)?[o,a]=i:o=a=i,!(!ct(o)||!ct(a)))return[t-o,t+a]})):[]}var gn=e=>{var t=Sn(e),n=Al(e);return _c(e,t,n)},Ac=q([gn],e=>e?.dataKey),sae=q([O2,yj,gn],Fj),k2=(e,t,n,r)=>{var i={},o=t.reduce((a,s)=>{if(s.stackId==null)return a;var u=a[s.stackId];return u==null&&(u=[]),u.push(s),a[s.stackId]=u,a},i);return Object.fromEntries(Object.entries(o).map(a=>{var[s,u]=a,c=r?[...u].reverse():u,d=c.map(ew);return[s,{stackedData:iee(e,d,n),graphicalItems:c}]}))},Mb=q([sae,O2,Bh,kj],k2),N2=(e,t,n,r)=>{var{dataStartIndex:i,dataEndIndex:o}=t;if(r==null&&n!=="zAxis"){var a=uee(e,i,o);if(!(a!=null&&a[0]===0&&a[1]===0))return a}},lae=q([tr],e=>e.allowDataOverflow),Rw=e=>{var t;if(e==null||!("domain"in e))return Nb;if(e.domain!=null)return e.domain;if("ticks"in e&&e.ticks!=null){if(e.type==="number"){var n=vo(e.ticks);return[Math.min(...n),Math.max(...n)]}if(e.type==="category")return e.ticks.map(String)}return(t=e?.domain)!==null&&t!==void 0?t:Nb},M2=q([tr],Rw),D2=q([M2,lae],bj),uae=q([Mb,Co,Cn,D2],N2,{memoizeOptions:{resultEqualityCheck:qh}}),Iw=e=>e.errorBars,cae=(e,t,n)=>e.flatMap(r=>t[r.id]).filter(Boolean).filter(r=>T2(n,r)),Dp=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=n.filter(Boolean);if(i.length!==0){var o=i.flat(),a=Math.min(...o),s=Math.max(...o);return[a,s]}},j2=(e,t,n,r,i)=>{var o,a;if(n.length>0&&e.forEach(s=>{n.forEach(u=>{var c,d,p=(c=r[u.id])===null||c===void 0?void 0:c.filter(w=>T2(i,w)),g=Mn(s,(d=t.dataKey)!==null&&d!==void 0?d:u.dataKey),h=aae(s,g,p);if(h.length>=2){var v=Math.min(...h),b=Math.max(...h);(o==null||v<o)&&(o=v),(a==null||b>a)&&(a=b)}var y=YP(g);y!=null&&(o=o==null?y[0]:Math.min(o,y[0]),a=a==null?y[1]:Math.max(a,y[1]))})}),t?.dataKey!=null&&e.forEach(s=>{var u=YP(Mn(s,t.dataKey));u!=null&&(o=o==null?u[0]:Math.min(o,u[0]),a=a==null?u[1]:Math.max(a,u[1]))}),ct(o)&&ct(a))return[o,a]},fae=q([Aw,tr,nae,Iw,Cn],j2,{memoizeOptions:{resultEqualityCheck:qh}});function dae(e){var{value:t}=e;if(ji(t)||t instanceof Date)return t}var pae=(e,t,n)=>{var r=e.map(dae).filter(i=>i!=null);return n&&(t.dataKey==null||t.allowDuplicatedCategory&&HM(r))?mj(0,e.length):t.allowDuplicatedCategory?r:Array.from(new Set(r))},L2=e=>e.referenceElements.dots,Il=(e,t,n)=>e.filter(r=>r.ifOverflow==="extendDomain").filter(r=>t==="xAxis"?r.xAxisId===n:r.yAxisId===n),hae=q([L2,Cn,Uh],Il),$2=e=>e.referenceElements.areas,gae=q([$2,Cn,Uh],Il),F2=e=>e.referenceElements.lines,mae=q([F2,Cn,Uh],Il),V2=(e,t)=>{if(e!=null){var n=vo(e.map(r=>t==="xAxis"?r.x:r.y));if(n.length!==0)return[Math.min(...n),Math.max(...n)]}},vae=q(hae,Cn,V2),B2=(e,t)=>{if(e!=null){var n=vo(e.flatMap(r=>[t==="xAxis"?r.x1:r.y1,t==="xAxis"?r.x2:r.y2]));if(n.length!==0)return[Math.min(...n),Math.max(...n)]}},yae=q([gae,Cn],B2);function bae(e){var t;if(e.x!=null)return vo([e.x]);var n=(t=e.segment)===null||t===void 0?void 0:t.map(r=>r.x);return n==null||n.length===0?[]:vo(n)}function xae(e){var t;if(e.y!=null)return vo([e.y]);var n=(t=e.segment)===null||t===void 0?void 0:t.map(r=>r.y);return n==null||n.length===0?[]:vo(n)}var z2=(e,t)=>{if(e!=null){var n=e.flatMap(r=>t==="xAxis"?bae(r):xae(r));if(n.length!==0)return[Math.min(...n),Math.max(...n)]}},wae=q([mae,Cn],z2),Cae=q(vae,wae,yae,(e,t,n)=>Dp(e,n,t)),W2=(e,t,n,r,i,o,a,s)=>{if(n!=null)return n;var u=a==="vertical"&&s==="xAxis"||a==="horizontal"&&s==="yAxis",c=u?Dp(r,o,i):Dp(o,i);return nre(t,c,e.allowDataOverflow)},Sae=q([tr,M2,D2,uae,fae,Cae,At,Cn],W2,{memoizeOptions:{resultEqualityCheck:qh}}),Eae=[0,1],H2=(e,t,n,r,i,o,a)=>{if(!((e==null||n==null||n.length===0)&&a===void 0)){var{dataKey:s,type:u}=e,c=pa(t,o);if(c&&s==null){var d;return mj(0,(d=n?.length)!==null&&d!==void 0?d:0)}return u==="category"?pae(r,e,c):i==="expand"?Eae:a}},Tw=q([tr,At,Aw,Pc,Bh,Cn,Sae],H2),Tl=q([tr,S2,Kx],b2),U2=(e,t,n)=>{var{niceTicks:r}=t;if(r!=="none"){var i=Rw(t),o=Array.isArray(i)&&(i[0]==="auto"||i[1]==="auto");if((r==="snap125"||r==="adaptive")&&t!=null&&t.tickCount&&Ti(e)){if(o)return oP(e,t.tickCount,t.allowDecimals,r);if(t.type==="number")return aP(e,t.tickCount,t.allowDecimals,r)}if(r==="auto"&&n==="linear"&&t!=null&&t.tickCount){if(o&&Ti(e))return oP(e,t.tickCount,t.allowDecimals,"adaptive");if(t.type==="number"&&Ti(e))return aP(e,t.tickCount,t.allowDecimals,"adaptive")}}},kw=q([Tw,_c,Tl],U2),G2=(e,t,n,r)=>{if(r!=="angleAxis"&&e?.type==="number"&&Ti(t)&&Array.isArray(n)&&n.length>0){var i,o,a=t[0],s=(i=n[0])!==null&&i!==void 0?i:0,u=t[1],c=(o=n[n.length-1])!==null&&o!==void 0?o:0;return[Math.min(a,s),Math.max(u,c)]}return t},_ae=q([tr,Tw,kw,Cn],G2),Oae=q(Pc,tr,(e,t)=>{if(!(!t||t.type!=="number")){var n=1/0,r=Array.from(vo(e.map(p=>p.value))).sort((p,g)=>p-g),i=r[0],o=r[r.length-1];if(i==null||o==null)return 1/0;var a=o-i;if(a===0)return 1/0;for(var s=0;s<r.length-1;s++){var u=r[s],c=r[s+1];if(!(u==null||c==null)){var d=c-u;n=Math.min(n,d)}}return n/a}}),q2=q(Oae,At,Tj,wn,(e,t,n,r,i)=>i,(e,t,n,r,i)=>{if(!ct(e))return 0;var o=t==="vertical"?r.height:r.width;if(i==="gap")return e*o/2;if(i==="no-gap"){var a=fi(n,e*o),s=e*o/2;return s-a-(s-a)/o*a}return 0}),Pae=(e,t,n)=>{var r=Eo(e,t);return r==null||typeof r.padding!="string"?0:q2(e,"xAxis",t,n,r.padding)},Aae=(e,t,n)=>{var r=_o(e,t);return r==null||typeof r.padding!="string"?0:q2(e,"yAxis",t,n,r.padding)},Rae=q(Eo,Pae,(e,t)=>{var n,r;if(e==null)return{left:0,right:0};var{padding:i}=e;return typeof i=="string"?{left:t,right:t}:{left:((n=i.left)!==null&&n!==void 0?n:0)+t,right:((r=i.right)!==null&&r!==void 0?r:0)+t}}),Iae=q(_o,Aae,(e,t)=>{var n,r;if(e==null)return{top:0,bottom:0};var{padding:i}=e;return typeof i=="string"?{top:t,bottom:t}:{top:((n=i.top)!==null&&n!==void 0?n:0)+t,bottom:((r=i.bottom)!==null&&r!==void 0?r:0)+t}}),Tae=q([wn,Rae,Dh,Mh,(e,t,n)=>n],(e,t,n,r,i)=>{var{padding:o}=r;return i?[o.left,n.width-o.right]:[e.left+t.left,e.left+e.width-t.right]}),kae=q([wn,At,Iae,Dh,Mh,(e,t,n)=>n],(e,t,n,r,i,o)=>{var{padding:a}=i;return o?[r.height-a.bottom,a.top]:t==="horizontal"?[e.top+e.height-n.bottom,e.top+n.top]:[e.top+n.top,e.top+e.height-n.bottom]}),Rc=(e,t,n,r)=>{var i;switch(t){case"xAxis":return Tae(e,n,r);case"yAxis":return kae(e,n,r);case"zAxis":return(i=Ow(e,n))===null||i===void 0?void 0:i.range;case"angleAxis":return jj(e);case"radiusAxis":return Lj(e,n);default:return}},K2=q([tr,Rc],zh),Nae=q([Tl,_ae],mre),Nw=q([tr,Tl,Nae,K2],_w),Y2=(e,t,n,r)=>{if(!(n==null||n.dataKey==null)){var{type:i,scale:o}=n,a=pa(e,r);if(a&&(i==="number"||o!=="auto"))return t.map(s=>s.value)}},Mw=q([At,Pc,_c,Cn],Y2),tg=q([Nw],tw);q([Nw],Yoe);q([Nw,oae],x2);q([Oc,Iw,Cn],cae);function X2(e,t){return e.id<t.id?-1:e.id>t.id?1:0}var ng=(e,t)=>t,rg=(e,t,n)=>n,Mae=q(kh,ng,rg,(e,t,n)=>e.filter(r=>r.orientation===t).filter(r=>r.mirror===n).sort(X2)),Dae=q(Nh,ng,rg,(e,t,n)=>e.filter(r=>r.orientation===t).filter(r=>r.mirror===n).sort(X2)),Z2=(e,t)=>({width:e.width,height:t.height}),jae=(e,t)=>{var n=typeof t.width=="number"?t.width:vc;return{width:n,height:e.height}},Q2=q(wn,Eo,Z2),Lae=(e,t,n)=>{switch(t){case"top":return e.top;case"bottom":return n-e.bottom;default:return 0}},$ae=(e,t,n)=>{switch(t){case"left":return e.left;case"right":return n-e.right;default:return 0}},Fae=q(wo,wn,Mae,ng,rg,(e,t,n,r,i)=>{var o={},a;return n.forEach(s=>{var u=Z2(t,s);a==null&&(a=Lae(t,r,e));var c=r==="top"&&!i||r==="bottom"&&i;o[s.id]=a-Number(c)*u.height,a+=(c?-1:1)*u.height}),o}),Vae=q(xo,wn,Dae,ng,rg,(e,t,n,r,i)=>{var o={},a;return n.forEach(s=>{var u=jae(t,s);a==null&&(a=$ae(t,r,e));var c=r==="left"&&!i||r==="right"&&i;o[s.id]=a-Number(c)*u.width,a+=(c?-1:1)*u.width}),o}),Bae=(e,t)=>{var n=Eo(e,t);if(n!=null)return Fae(e,n.orientation,n.mirror)},zae=q([wn,Eo,Bae,(e,t)=>t],(e,t,n,r)=>{if(t!=null){var i=n?.[r];return i==null?{x:e.left,y:0}:{x:e.left,y:i}}}),Wae=(e,t)=>{var n=_o(e,t);if(n!=null)return Vae(e,n.orientation,n.mirror)},Hae=q([wn,_o,Wae,(e,t)=>t],(e,t,n,r)=>{if(t!=null){var i=n?.[r];return i==null?{x:0,y:e.top}:{x:i,y:e.top}}}),J2=q(wn,_o,(e,t)=>{var n=typeof t.width=="number"?t.width:vc;return{width:n,height:e.height}}),XP=(e,t,n)=>{switch(t){case"xAxis":return Q2(e,n).width;case"yAxis":return J2(e,n).height;default:return}},eL=(e,t,n,r)=>{if(n!=null){var{allowDuplicatedCategory:i,type:o,dataKey:a}=n,s=pa(e,r),u=t.map(c=>c.value);if(a&&s&&o==="category"&&i&&HM(u))return u}},Dw=q([At,Pc,tr,Cn],eL),ZP=q([At,eae,Tl,tg,Dw,Mw,Rc,kw,Cn],(e,t,n,r,i,o,a,s,u)=>{if(t!=null){var c=pa(e,u);return{angle:t.angle,interval:t.interval,minTickGap:t.minTickGap,orientation:t.orientation,tick:t.tick,tickCount:t.tickCount,tickFormatter:t.tickFormatter,ticks:t.ticks,type:t.type,unit:t.unit,axisType:u,categoricalDomain:o,duplicateDomain:i,isCategorical:c,niceTicks:s,range:a,realScaleType:n,scale:r}}}),Uae=(e,t,n,r,i,o,a,s,u)=>{if(!(t==null||r==null)){var c=pa(e,u),{type:d,ticks:p,tickCount:g}=t,h=n==="scaleBand"&&typeof r.bandwidth=="function"?r.bandwidth()/2:2,v=d==="category"&&r.bandwidth?r.bandwidth()/h:0;v=u==="angleAxis"&&o!=null&&o.length>=2?cr(o[0]-o[1])*2*v:v;var b=p||i;return b?b.map((y,w)=>{var C=a?a.indexOf(y):y,E=r.map(C);return ct(E)?{index:w,coordinate:E+v,value:y,offset:v}:null}).filter(fr):c&&s?s.map((y,w)=>{var C=r.map(y);return ct(C)?{coordinate:C+v,value:y,index:w,offset:v}:null}).filter(fr):r.ticks?r.ticks(g).map((y,w)=>{var C=r.map(y);return ct(C)?{coordinate:C+v,value:y,index:w,offset:v}:null}).filter(fr):r.domain().map((y,w)=>{var C=r.map(y);return ct(C)?{coordinate:C+v,value:a?a[y]:y,index:w,offset:v}:null}).filter(fr)}},tL=q([At,_c,Tl,tg,kw,Rc,Dw,Mw,Cn],Uae),Gae=(e,t,n,r,i,o,a)=>{if(!(t==null||n==null||r==null||r[0]===r[1])){var s=pa(e,a),{tickCount:u}=t,c=0;return c=a==="angleAxis"&&r?.length>=2?cr(r[0]-r[1])*2*c:c,s&&o?o.map((d,p)=>{var g=n.map(d);return ct(g)?{coordinate:g+c,value:d,index:p,offset:c}:null}).filter(fr):n.ticks?n.ticks(u).map((d,p)=>{var g=n.map(d);return ct(g)?{coordinate:g+c,value:d,index:p,offset:c}:null}).filter(fr):n.domain().map((d,p)=>{var g=n.map(d);return ct(g)?{coordinate:g+c,value:i?i[d]:d,index:p,offset:c}:null}).filter(fr)}},wl=q([At,_c,tg,Rc,Dw,Mw,Cn],Gae),Cl=q(tr,tg,(e,t)=>{if(!(e==null||t==null))return Mp(Mp({},e),{},{scale:t})}),qae=q([tr,Tl,Tw,K2],_w),Kae=q([qae],tw);q((e,t,n)=>Ow(e,n),Kae,(e,t)=>{if(!(e==null||t==null))return Mp(Mp({},e),{},{scale:t})});var Yae=q([At,kh,Nh],(e,t,n)=>{switch(e){case"horizontal":return t.some(r=>r.reversed)?"right-to-left":"left-to-right";case"vertical":return n.some(r=>r.reversed)?"bottom-to-top":"top-to-bottom";case"centric":case"radial":return"left-to-right";default:return}}),Xae=(e,t,n)=>{var r;return(r=e.renderedTicks[t])===null||r===void 0?void 0:r[n]};q([Xae],e=>{if(!(!e||e.length===0))return t=>{var n,r=1/0,i=e[0];for(var o of e){var a=Math.abs(o.coordinate-t);a<r&&(r=a,i=o)}return(n=i)===null||n===void 0?void 0:n.value}});var nL=e=>e.options.defaultTooltipEventType,rL=e=>e.options.validateTooltipEventTypes;function iL(e,t,n){if(e==null)return t;var r=e?"axis":"item";return n==null?t:n.includes(r)?r:t}function jw(e,t){var n=nL(e),r=rL(e);return iL(t,n,r)}function Zae(e){return Le(t=>jw(t,e))}var oL=(e,t)=>{var n,r=Number(t);if(!(Di(r)||t==null))return r>=0?e==null||(n=e[r])===null||n===void 0?void 0:n.value:void 0},Qae=e=>e.tooltip.settings,Ko={active:!1,index:null,dataKey:void 0,graphicalItemId:void 0,coordinate:void 0},Jae={itemInteraction:{click:Ko,hover:Ko},axisInteraction:{click:Ko,hover:Ko},keyboardInteraction:Ko,syncInteraction:{active:!1,index:null,dataKey:void 0,label:void 0,coordinate:void 0,sourceViewBox:void 0,graphicalItemId:void 0},tooltipItemPayloads:[],settings:{shared:void 0,trigger:"hover",axisId:0,active:!1,defaultIndex:void 0}},aL=Wn({name:"tooltip",initialState:Jae,reducers:{addTooltipEntrySettings:{reducer(e,t){e.tooltipItemPayloads.push(t.payload)},prepare:Mt()},replaceTooltipEntrySettings:{reducer(e,t){var{prev:n,next:r}=t.payload,i=Qr(e).tooltipItemPayloads.indexOf(n);i>-1&&(e.tooltipItemPayloads[i]=r)},prepare:Mt()},removeTooltipEntrySettings:{reducer(e,t){var n=Qr(e).tooltipItemPayloads.indexOf(t.payload);n>-1&&e.tooltipItemPayloads.splice(n,1)},prepare:Mt()},setTooltipSettingsState(e,t){e.settings=t.payload},setActiveMouseOverItemIndex(e,t){e.syncInteraction.active=!1,e.keyboardInteraction.active=!1,e.itemInteraction.hover.active=!0,e.itemInteraction.hover.index=t.payload.activeIndex,e.itemInteraction.hover.dataKey=t.payload.activeDataKey,e.itemInteraction.hover.graphicalItemId=t.payload.activeGraphicalItemId,e.itemInteraction.hover.coordinate=t.payload.activeCoordinate},mouseLeaveChart(e){e.itemInteraction.hover.active=!1,e.axisInteraction.hover.active=!1},mouseLeaveItem(e){e.itemInteraction.hover.active=!1},setActiveClickItemIndex(e,t){e.syncInteraction.active=!1,e.itemInteraction.click.active=!0,e.keyboardInteraction.active=!1,e.itemInteraction.click.index=t.payload.activeIndex,e.itemInteraction.click.dataKey=t.payload.activeDataKey,e.itemInteraction.click.graphicalItemId=t.payload.activeGraphicalItemId,e.itemInteraction.click.coordinate=t.payload.activeCoordinate},setMouseOverAxisIndex(e,t){e.syncInteraction.active=!1,e.axisInteraction.hover.active=!0,e.keyboardInteraction.active=!1,e.axisInteraction.hover.index=t.payload.activeIndex,e.axisInteraction.hover.dataKey=t.payload.activeDataKey,e.axisInteraction.hover.coordinate=t.payload.activeCoordinate},setMouseClickAxisIndex(e,t){e.syncInteraction.active=!1,e.keyboardInteraction.active=!1,e.axisInteraction.click.active=!0,e.axisInteraction.click.index=t.payload.activeIndex,e.axisInteraction.click.dataKey=t.payload.activeDataKey,e.axisInteraction.click.coordinate=t.payload.activeCoordinate},setSyncInteraction(e,t){e.syncInteraction=t.payload},setKeyboardInteraction(e,t){e.keyboardInteraction.active=t.payload.active,e.keyboardInteraction.index=t.payload.activeIndex,e.keyboardInteraction.coordinate=t.payload.activeCoordinate}}}),{addTooltipEntrySettings:ese,replaceTooltipEntrySettings:tse,removeTooltipEntrySettings:nse,setTooltipSettingsState:rse,setActiveMouseOverItemIndex:sL,mouseLeaveItem:ise,mouseLeaveChart:lL,setActiveClickItemIndex:ose,setMouseOverAxisIndex:uL,setMouseClickAxisIndex:ase,setSyncInteraction:Db,setKeyboardInteraction:jp}=aL.actions,sse=aL.reducer;function QP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function md(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?QP(Object(n),!0).forEach(function(r){lse(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):QP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function lse(e,t,n){return(t=use(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function use(e){var t=cse(e,"string");return typeof t=="symbol"?t:t+""}function cse(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function fse(e,t,n){return t==="axis"?n==="click"?e.axisInteraction.click:e.axisInteraction.hover:n==="click"?e.itemInteraction.click:e.itemInteraction.hover}function dse(e){return e.index!=null}var cL=(e,t,n,r)=>{if(t==null)return Ko;var i=fse(e,t,n);if(i==null)return Ko;if(i.active)return i;if(e.keyboardInteraction.active)return e.keyboardInteraction;if(e.syncInteraction.active&&e.syncInteraction.index!=null)return e.syncInteraction;var o=e.settings.active===!0;if(dse(i)){if(o)return md(md({},i),{},{active:!0})}else if(r!=null)return{active:!0,coordinate:void 0,dataKey:void 0,index:r,graphicalItemId:void 0};return md(md({},Ko),{},{coordinate:i.coordinate})};function pse(e){if(typeof e=="number")return Number.isFinite(e)?e:void 0;if(e instanceof Date){var t=e.valueOf();return Number.isFinite(t)?t:void 0}var n=Number(e);return Number.isFinite(n)?n:void 0}function hse(e,t){var n=pse(e),r=t[0],i=t[1];if(n===void 0)return!1;var o=Math.min(r,i),a=Math.max(r,i);return n>=o&&n<=a}function gse(e,t,n){if(n==null||t==null)return!0;var r=Mn(e,t);return r==null||!Ti(n)?!0:hse(r,n)}var Lw=(e,t,n,r)=>{var i=e?.index;if(i==null)return null;var o=Number(i);if(!ct(o))return i;var a=0,s=1/0;t.length>0&&(s=t.length-1);var u=Math.max(a,Math.min(o,s)),c=t[u];return c==null||gse(c,n,r)?String(u):null},fL=(e,t,n,r,i,o,a)=>{if(o!=null){var s=a[0],u=s?.getPosition(o);if(u!=null)return u;var c=i?.[Number(o)];if(c)return n==="horizontal"?{x:c.coordinate,y:(r.top+t)/2}:{x:(r.left+e)/2,y:c.coordinate}}},dL=(e,t,n,r)=>{if(t==="axis")return e.tooltipItemPayloads;if(e.tooltipItemPayloads.length===0)return[];var i;if(n==="hover"?i=e.itemInteraction.hover.graphicalItemId:i=e.itemInteraction.click.graphicalItemId,e.syncInteraction.active&&i==null)return e.tooltipItemPayloads;if(i==null&&r!=null){var o=e.tooltipItemPayloads[0];return o!=null?[o]:[]}return e.tooltipItemPayloads.filter(a=>{var s;return((s=a.settings)===null||s===void 0?void 0:s.graphicalItemId)===i})},pL=e=>e.options.tooltipPayloadSearcher,kl=e=>e.tooltip;function JP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function eA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?JP(Object(n),!0).forEach(function(r){mse(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):JP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function mse(e,t,n){return(t=vse(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function vse(e){var t=yse(e,"string");return typeof t=="symbol"?t:t+""}function yse(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function bse(e){if(typeof e=="string"||typeof e=="number")return e}function xse(e){if(typeof e=="string"||typeof e=="number"||typeof e=="boolean")return e}function wse(e){if(typeof e=="string"||typeof e=="number")return e;if(typeof e=="function")return t=>e(t)}function tA(e){if(typeof e=="string")return e}function Cse(e){if(!(e==null||typeof e!="object")){var t="name"in e?bse(e.name):void 0,n="unit"in e?xse(e.unit):void 0,r="dataKey"in e?wse(e.dataKey):void 0,i="payload"in e?e.payload:void 0,o="color"in e?tA(e.color):void 0,a="fill"in e?tA(e.fill):void 0;return{name:t,unit:n,dataKey:r,payload:i,color:o,fill:a}}}function Sse(e,t){return e??t}var hL=(e,t,n,r,i,o,a)=>{if(!(t==null||o==null)){var{chartData:s,computedData:u,dataStartIndex:c,dataEndIndex:d}=n,p=[];return e.reduce((g,h)=>{var v,{dataDefinedOnItem:b,settings:y}=h,w=Sse(b,s),C=Array.isArray(w)?FD(w,c,d):w,E=(v=y?.dataKey)!==null&&v!==void 0?v:r,_=y?.nameKey,O;if(r&&Array.isArray(C)&&!Array.isArray(C[0])&&a==="axis"?O=VZ(C,r,i):O=o(C,t,u,_),Array.isArray(O))O.forEach(I=>{var k,B,L=Cse(I),V=L?.name,D=L?.dataKey,H=L?.payload,J=eA(eA({},y),{},{name:V,unit:L?.unit,color:(k=L?.color)!==null&&k!==void 0?k:y?.color,fill:(B=L?.fill)!==null&&B!==void 0?B:y?.fill});g.push(K_({tooltipEntrySettings:J,dataKey:D,payload:H,value:Mn(H,D),name:V==null?void 0:String(V)}))});else{var R;g.push(K_({tooltipEntrySettings:y,dataKey:E,payload:O,value:Mn(O,E),name:(R=Mn(O,_))!==null&&R!==void 0?R:y?.name}))}return g},p)}},$w=q([gn,S2,Kx],b2),Ese=q([e=>e.graphicalItems.cartesianItems,e=>e.graphicalItems.polarItems],(e,t)=>[...e,...t]),_se=q([Sn,Al],E2),Nl=q([Ese,gn,_se],_2,{memoizeOptions:{resultEqualityCheck:Kh}}),Ose=q([Nl],e=>e.filter(Gh)),Pse=q([Nl],A2,{memoizeOptions:{resultEqualityCheck:Kh}}),Ml=q([Pse,Co],R2),Ase=q([Ose,Co,gn],Fj),Fw=q([Ml,gn,Nl],I2),gL=q([gn],Rw),Rse=q([gn],e=>e.allowDataOverflow),mL=q([gL,Rse],bj),Ise=q([Nl],e=>e.filter(Gh)),Tse=q([Ase,Ise,Bh,kj],k2),kse=q([Tse,Co,Sn,mL],N2),Nse=q([Nl],P2),Mse=q([Ml,gn,Nse,Iw,Sn],j2,{memoizeOptions:{resultEqualityCheck:qh}}),Dse=q([L2,Sn,Al],Il),jse=q([Dse,Sn],V2),Lse=q([$2,Sn,Al],Il),$se=q([Lse,Sn],B2),Fse=q([F2,Sn,Al],Il),Vse=q([Fse,Sn],z2),Bse=q([jse,Vse,$se],Dp),zse=q([gn,gL,mL,kse,Mse,Bse,At,Sn],W2),Ic=q([gn,At,Ml,Fw,Bh,Sn,zse],H2),Wse=q([Ic,gn,$w],U2),Hse=q([gn,Ic,Wse,Sn],G2),vL=e=>{var t=Sn(e),n=Al(e),r=!1;return Rc(e,t,n,r)},yL=q([gn,vL],zh),Use=q([gn,$w,Hse,yL],_w),bL=q([Use],tw),Gse=q([At,Fw,gn,Sn],eL),qse=q([At,Fw,gn,Sn],Y2),Kse=(e,t,n,r,i,o,a,s)=>{if(t){var{type:u}=t,c=pa(e,s);if(r){var d=n==="scaleBand"&&r.bandwidth?r.bandwidth()/2:2,p=u==="category"&&r.bandwidth?r.bandwidth()/d:0;return p=s==="angleAxis"&&i!=null&&i?.length>=2?cr(i[0]-i[1])*2*p:p,c&&a?a.map((g,h)=>{var v=r.map(g);return ct(v)?{coordinate:v+p,value:g,index:h,offset:p}:null}).filter(fr):r.domain().map((g,h)=>{var v=r.map(g);return ct(v)?{coordinate:v+p,value:o?o[g]:g,index:h,offset:p}:null}).filter(fr)}}},Oo=q([At,gn,$w,bL,vL,Gse,qse,Sn],Kse),Vw=q([nL,rL,Qae],(e,t,n)=>iL(n.shared,e,t)),xL=e=>e.tooltip.settings.trigger,Bw=e=>e.tooltip.settings.defaultIndex,Tc=q([kl,Vw,xL,Bw],cL),Sl=q([Tc,Ml,Ac,Ic],Lw),wL=q([Oo,Sl],oL),CL=q([Tc],e=>{if(e)return e.dataKey}),Yse=q([Tc],e=>{if(e)return e.graphicalItemId}),SL=q([kl,Vw,xL,Bw],dL),Xse=q([xo,wo,At,wn,Oo,Bw,SL],fL),Zse=q([Tc,Xse],(e,t)=>e!=null&&e.coordinate?e.coordinate:t),Qse=q([Tc],e=>{var t;return(t=e?.active)!==null&&t!==void 0?t:!1}),Jse=q([SL,Sl,Co,Ac,wL,pL,Vw],hL);q([Jse],e=>{if(e!=null){var t=e.map(n=>n.payload).filter(n=>n!=null);return Array.from(new Set(t))}});function nA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function rA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?nA(Object(n),!0).forEach(function(r){ele(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):nA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ele(e,t,n){return(t=tle(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function tle(e){var t=nle(e,"string");return typeof t=="symbol"?t:t+""}function nle(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var rle=()=>Le(gn),ile=()=>{var e=rle(),t=Le(Oo),n=Le(bL);return dp(!e||!n?void 0:rA(rA({},e),{},{scale:n}),t)};function iA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ys(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?iA(Object(n),!0).forEach(function(r){ole(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):iA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ole(e,t,n){return(t=ale(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ale(e){var t=sle(e,"string");return typeof t=="symbol"?t:t+""}function sle(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var lle=(e,t,n,r)=>{var i=t.find(o=>o&&o.index===n);if(i){if(e==="horizontal")return{x:i.coordinate,y:r.relativeY};if(e==="vertical")return{x:r.relativeX,y:i.coordinate}}return{x:0,y:0}},ule=(e,t,n,r)=>{var i=t.find(c=>c&&c.index===n);if(i){if(e==="centric"){var o=i.coordinate,{radius:a}=r;return Ys(Ys(Ys({},r),kn(r.cx,r.cy,a,o)),{},{angle:o,radius:a})}var s=i.coordinate,{angle:u}=r;return Ys(Ys(Ys({},r),kn(r.cx,r.cy,s,u)),{},{angle:u,radius:s})}return{angle:0,clockWise:!1,cx:0,cy:0,endAngle:0,innerRadius:0,outerRadius:0,radius:0,startAngle:0,x:0,y:0}};function cle(e,t){var{relativeX:n,relativeY:r}=e;return n>=t.left&&n<=t.left+t.width&&r>=t.top&&r<=t.top+t.height}var EL=(e,t,n,r,i)=>{var o,a=(o=t?.length)!==null&&o!==void 0?o:0;if(a<=1||e==null)return 0;if(r==="angleAxis"&&i!=null&&Math.abs(Math.abs(i[1]-i[0])-360)<=1e-6)for(var s=0;s<a;s++){var u,c,d,p,g,h=s>0?(u=n[s-1])===null||u===void 0?void 0:u.coordinate:(c=n[a-1])===null||c===void 0?void 0:c.coordinate,v=(d=n[s])===null||d===void 0?void 0:d.coordinate,b=s>=a-1?(p=n[0])===null||p===void 0?void 0:p.coordinate:(g=n[s+1])===null||g===void 0?void 0:g.coordinate,y=void 0;if(!(h==null||v==null||b==null))if(cr(v-h)!==cr(b-v)){var w=[];if(cr(b-v)===cr(i[1]-i[0])){y=b;var C=v+i[1]-i[0];w[0]=Math.min(C,(C+h)/2),w[1]=Math.max(C,(C+h)/2)}else{y=h;var E=b+i[1]-i[0];w[0]=Math.min(v,(E+v)/2),w[1]=Math.max(v,(E+v)/2)}var _=[Math.min(v,(y+v)/2),Math.max(v,(y+v)/2)];if(e>_[0]&&e<=_[1]||e>=w[0]&&e<=w[1]){var O;return(O=n[s])===null||O===void 0?void 0:O.index}}else{var R=Math.min(h,b),I=Math.max(h,b);if(e>(R+v)/2&&e<=(I+v)/2){var k;return(k=n[s])===null||k===void 0?void 0:k.index}}}else if(t)for(var B=0;B<a;B++){var L=t[B];if(L!=null){var V=t[B+1],D=t[B-1];if(B===0&&V!=null&&e<=(L.coordinate+V.coordinate)/2||B===a-1&&D!=null&&e>(L.coordinate+D.coordinate)/2||B>0&&B<a-1&&D!=null&&V!=null&&e>(L.coordinate+D.coordinate)/2&&e<=(L.coordinate+V.coordinate)/2)return L.index}}return-1},fle=()=>Le(Kx),zw=(e,t)=>t,_L=(e,t,n)=>n,Ww=(e,t,n,r)=>r,dle=q(Oo,e=>Sh(e,t=>t.coordinate)),Hw=q([kl,zw,_L,Ww],cL),Uw=q([Hw,Ml,Ac,Ic],Lw),ple=(e,t,n)=>{if(t!=null){var r=kl(e);return t==="axis"?n==="hover"?r.axisInteraction.hover.dataKey:r.axisInteraction.click.dataKey:n==="hover"?r.itemInteraction.hover.dataKey:r.itemInteraction.click.dataKey}},OL=q([kl,zw,_L,Ww],dL),Lp=q([xo,wo,At,wn,Oo,Ww,OL],fL),hle=q([Hw,Lp],(e,t)=>{var n;return(n=e.coordinate)!==null&&n!==void 0?n:t}),PL=q([Oo,Uw],oL),gle=q([OL,Uw,Co,Ac,PL,pL,zw],hL),mle=q([Hw,Uw],(e,t)=>({isActive:e.active&&t!=null,activeIndex:t})),vle=(e,t,n,r,i,o,a)=>{if(!(!e||!n||!r||!i)&&cle(e,a)){var s=cee(e,t),u=EL(s,o,i,n,r),c=lle(t,i,u,e);return{activeIndex:String(u),activeCoordinate:c}}},yle=(e,t,n,r,i,o,a)=>{if(!(!e||!r||!i||!o||!n)){var s=Une(e,n);if(s){var u=fee(s,t),c=EL(u,a,o,r,i),d=ule(t,o,c,s);return{activeIndex:String(c),activeCoordinate:d}}}},ble=(e,t,n,r,i,o,a,s)=>{if(!(!e||!t||!r||!i||!o))return t==="horizontal"||t==="vertical"?vle(e,t,r,i,o,a,s):yle(e,t,n,r,i,o,a)},xle=q(e=>e.zIndex.zIndexMap,(e,t)=>t,(e,t,n)=>n,(e,t,n)=>{if(t!=null){var r=e[t];if(r!=null)return n?r.panoramaElement:r.element}}),wle=q(e=>e.zIndex.zIndexMap,e=>{var t=Object.keys(e).map(r=>parseInt(r,10)).concat(Object.values(Zn)),n=Array.from(new Set(t));return n.sort((r,i)=>r-i)},{memoizeOptions:{resultEqualityCheck:gre}});function oA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function aA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?oA(Object(n),!0).forEach(function(r){Cle(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):oA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Cle(e,t,n){return(t=Sle(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Sle(e){var t=Ele(e,"string");return typeof t=="symbol"?t:t+""}function Ele(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var _le={},Ole={zIndexMap:Object.values(Zn).reduce((e,t)=>aA(aA({},e),{},{[t]:{element:void 0,panoramaElement:void 0,consumers:0}}),_le)},Ple=new Set(Object.values(Zn));function Ale(e){return Ple.has(e)}var AL=Wn({name:"zIndex",initialState:Ole,reducers:{registerZIndexPortal:{reducer:(e,t)=>{var{zIndex:n}=t.payload;e.zIndexMap[n]?e.zIndexMap[n].consumers+=1:e.zIndexMap[n]={consumers:1,element:void 0,panoramaElement:void 0}},prepare:Mt()},unregisterZIndexPortal:{reducer:(e,t)=>{var{zIndex:n}=t.payload;e.zIndexMap[n]&&(e.zIndexMap[n].consumers-=1,e.zIndexMap[n].consumers<=0&&!Ale(n)&&delete e.zIndexMap[n])},prepare:Mt()},registerZIndexPortalElement:{reducer:(e,t)=>{var{zIndex:n,element:r,isPanorama:i}=t.payload;e.zIndexMap[n]?i?e.zIndexMap[n].panoramaElement=r:e.zIndexMap[n].element=r:e.zIndexMap[n]={consumers:0,element:i?void 0:r,panoramaElement:i?r:void 0}},prepare:Mt()},unregisterZIndexPortalElement:{reducer:(e,t)=>{var{zIndex:n}=t.payload;e.zIndexMap[n]&&(t.payload.isPanorama?e.zIndexMap[n].panoramaElement=void 0:e.zIndexMap[n].element=void 0)},prepare:Mt()}}}),{registerZIndexPortal:Rle,unregisterZIndexPortal:Ile,registerZIndexPortalElement:Tle,unregisterZIndexPortalElement:kle}=AL.actions,Nle=AL.reducer;function Po(e){var{zIndex:t,children:n}=e,r=Hee(),i=r&&t!==void 0&&t!==0,o=pr(),a=Ht();j.useLayoutEffect(()=>i?(a(Rle({zIndex:t})),()=>{a(Ile({zIndex:t}))}):ds,[a,t,i]);var s=Le(u=>xle(u,t,o));return i?s?Up.createPortal(n,s):null:n}function jb(){return jb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},jb.apply(null,arguments)}function sA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function vd(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?sA(Object(n),!0).forEach(function(r){Mle(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Mle(e,t,n){return(t=Dle(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Dle(e){var t=jle(e,"string");return typeof t=="symbol"?t:t+""}function jle(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Lle(e){var{cursor:t,cursorComp:n,cursorProps:r}=e;return j.isValidElement(t)?j.cloneElement(t,r):j.createElement(n,r)}function $le(e){var t,{coordinate:n,payload:r,index:i,offset:o,tooltipAxisBandSize:a,layout:s,cursor:u,tooltipEventType:c,chartName:d}=e,p=n,g=r,h=i;if(!u||!p||d!=="ScatterChart"&&c!=="axis")return null;var v,b,y;if(d==="ScatterChart")v=p,b=one,y=Zn.cursorLine;else if(d==="BarChart")v=ane(s,p,o,a),b=dj,y=Zn.cursorRectangle;else if(s==="radial"&&qM(p)){var{cx:w,cy:C,radius:E,startAngle:_,endAngle:O}=pj(p);v={cx:w,cy:C,startAngle:_,endAngle:O,innerRadius:E,outerRadius:E},b=gj,y=Zn.cursorLine}else v={points:Yne(s,p,o)},b=sj,y=Zn.cursorLine;var R=typeof u=="object"&&"className"in u?u.className:void 0,I=vd(vd(vd(vd({stroke:"#ccc",pointerEvents:"none"},o),v),Cx(u)),{},{payload:g,payloadIndex:h,className:Pt("recharts-tooltip-cursor",R)});return x.createElement(Po,{zIndex:(t=e.zIndex)!==null&&t!==void 0?t:y},x.createElement(Lle,{cursor:u,cursorComp:b,cursorProps:I}))}function Fle(e){var t=ile(),n=qD(),r=_l(),i=fle();return t==null||n==null||r==null||i==null?null:x.createElement($le,jb({},e,{offset:n,layout:r,tooltipAxisBandSize:t,chartName:i}))}var RL=j.createContext(null),Vle=()=>j.useContext(RL),ly={exports:{}},lA;function Ble(){return lA||(lA=1,(function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}Object.create&&(r.prototype=Object.create(null),new r().__proto__||(n=!1));function i(u,c,d){this.fn=u,this.context=c,this.once=d||!1}function o(u,c,d,p,g){if(typeof d!="function")throw new TypeError("The listener must be a function");var h=new i(d,p||u,g),v=n?n+c:c;return u._events[v]?u._events[v].fn?u._events[v]=[u._events[v],h]:u._events[v].push(h):(u._events[v]=h,u._eventsCount++),u}function a(u,c){--u._eventsCount===0?u._events=new r:delete u._events[c]}function s(){this._events=new r,this._eventsCount=0}s.prototype.eventNames=function(){var c=[],d,p;if(this._eventsCount===0)return c;for(p in d=this._events)t.call(d,p)&&c.push(n?p.slice(1):p);return Object.getOwnPropertySymbols?c.concat(Object.getOwnPropertySymbols(d)):c},s.prototype.listeners=function(c){var d=n?n+c:c,p=this._events[d];if(!p)return[];if(p.fn)return[p.fn];for(var g=0,h=p.length,v=new Array(h);g<h;g++)v[g]=p[g].fn;return v},s.prototype.listenerCount=function(c){var d=n?n+c:c,p=this._events[d];return p?p.fn?1:p.length:0},s.prototype.emit=function(c,d,p,g,h,v){var b=n?n+c:c;if(!this._events[b])return!1;var y=this._events[b],w=arguments.length,C,E;if(y.fn){switch(y.once&&this.removeListener(c,y.fn,void 0,!0),w){case 1:return y.fn.call(y.context),!0;case 2:return y.fn.call(y.context,d),!0;case 3:return y.fn.call(y.context,d,p),!0;case 4:return y.fn.call(y.context,d,p,g),!0;case 5:return y.fn.call(y.context,d,p,g,h),!0;case 6:return y.fn.call(y.context,d,p,g,h,v),!0}for(E=1,C=new Array(w-1);E<w;E++)C[E-1]=arguments[E];y.fn.apply(y.context,C)}else{var _=y.length,O;for(E=0;E<_;E++)switch(y[E].once&&this.removeListener(c,y[E].fn,void 0,!0),w){case 1:y[E].fn.call(y[E].context);break;case 2:y[E].fn.call(y[E].context,d);break;case 3:y[E].fn.call(y[E].context,d,p);break;case 4:y[E].fn.call(y[E].context,d,p,g);break;default:if(!C)for(O=1,C=new Array(w-1);O<w;O++)C[O-1]=arguments[O];y[E].fn.apply(y[E].context,C)}}return!0},s.prototype.on=function(c,d,p){return o(this,c,d,p,!1)},s.prototype.once=function(c,d,p){return o(this,c,d,p,!0)},s.prototype.removeListener=function(c,d,p,g){var h=n?n+c:c;if(!this._events[h])return this;if(!d)return a(this,h),this;var v=this._events[h];if(v.fn)v.fn===d&&(!g||v.once)&&(!p||v.context===p)&&a(this,h);else{for(var b=0,y=[],w=v.length;b<w;b++)(v[b].fn!==d||g&&!v[b].once||p&&v[b].context!==p)&&y.push(v[b]);y.length?this._events[h]=y.length===1?y[0]:y:a(this,h)}return this},s.prototype.removeAllListeners=function(c){var d;return c?(d=n?n+c:c,this._events[d]&&a(this,d)):(this._events=new r,this._eventsCount=0),this},s.prototype.off=s.prototype.removeListener,s.prototype.addListener=s.prototype.on,s.prefixed=n,s.EventEmitter=s,e.exports=s})(ly)),ly.exports}var zle=Ble();const Wle=fs(zle);var tc=new Wle,Lb="recharts.syncEvent.tooltip",uA="recharts.syncEvent.brush",Hle=(e,t)=>{if(t&&Array.isArray(e)){var n=Number.parseInt(t,10);if(!Di(n))return e[n]}},Ule={chartName:"",tooltipPayloadSearcher:()=>{},eventEmitter:void 0,defaultTooltipEventType:"axis"},IL=Wn({name:"options",initialState:Ule,reducers:{createEventEmitter:e=>{e.eventEmitter==null&&(e.eventEmitter=Symbol("rechartsEventEmitter"))}}}),Gle=IL.reducer,{createEventEmitter:qle}=IL.actions;function Kle(e){return e.tooltip.syncInteraction}var Yle={chartData:void 0,computedData:void 0,dataStartIndex:0,dataEndIndex:0},TL=Wn({name:"chartData",initialState:Yle,reducers:{setChartData(e,t){if(e.chartData=t.payload,t.payload==null){e.dataStartIndex=0,e.dataEndIndex=0;return}t.payload.length>0&&e.dataEndIndex!==t.payload.length-1&&(e.dataEndIndex=t.payload.length-1)},setComputedData(e,t){e.computedData=t.payload},setDataStartEndIndexes(e,t){var{startIndex:n,endIndex:r}=t.payload;n!=null&&(e.dataStartIndex=n),r!=null&&(e.dataEndIndex=r)}}}),{setChartData:cA,setDataStartEndIndexes:Xle,setComputedData:bge}=TL.actions,Zle=TL.reducer,Qle=["x","y"];function fA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Xs(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?fA(Object(n),!0).forEach(function(r){Jle(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Jle(e,t,n){return(t=eue(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function eue(e){var t=tue(e,"string");return typeof t=="symbol"?t:t+""}function tue(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function nue(e,t){if(e==null)return{};var n,r,i=rue(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function rue(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function iue(){var e=Le(Yx),t=Le(Xx),n=Ht(),r=Le(Nj),i=Le(Oo),o=_l(),a=jh(),s=Le(u=>u.rootProps.className);j.useEffect(()=>{if(e==null)return ds;var u=(c,d,p)=>{if(t!==p&&e===c){if(r==="index"){var g;if(a&&d!==null&&d!==void 0&&(g=d.payload)!==null&&g!==void 0&&g.coordinate&&d.payload.sourceViewBox){var h=d.payload.coordinate,{x:v,y:b}=h,y=nue(h,Qle),{x:w,y:C,width:E,height:_}=d.payload.sourceViewBox,O=Xs(Xs({},y),{},{x:a.x+(E?(v-w)/E:0)*a.width,y:a.y+(_?(b-C)/_:0)*a.height});n(Xs(Xs({},d),{},{payload:Xs(Xs({},d.payload),{},{coordinate:O})}))}else n(d);return}if(i!=null){var R;if(typeof r=="function"){var I={activeTooltipIndex:d.payload.index==null?void 0:Number(d.payload.index),isTooltipActive:d.payload.active,activeIndex:d.payload.index==null?void 0:Number(d.payload.index),activeLabel:d.payload.label,activeDataKey:d.payload.dataKey,activeCoordinate:d.payload.coordinate},k=r(i,I);R=i[k]}else r==="value"&&(R=i.find(G=>String(G.value)===d.payload.label));var{coordinate:B}=d.payload;if(R==null||d.payload.active===!1||B==null||a==null){n(Db({active:!1,coordinate:void 0,dataKey:void 0,index:null,label:void 0,sourceViewBox:void 0,graphicalItemId:void 0}));return}var{x:L,y:V}=B,D=Math.min(L,a.x+a.width),H=Math.min(V,a.y+a.height),J={x:o==="horizontal"?R.coordinate:D,y:o==="horizontal"?H:R.coordinate},te=Db({active:d.payload.active,coordinate:J,dataKey:d.payload.dataKey,index:String(R.index),label:d.payload.label,sourceViewBox:d.payload.sourceViewBox,graphicalItemId:d.payload.graphicalItemId});n(te)}}};return tc.on(Lb,u),()=>{tc.off(Lb,u)}},[s,n,t,e,r,i,o,a])}function oue(){var e=Le(Yx),t=Le(Xx),n=Ht();j.useEffect(()=>{if(e==null)return ds;var r=(i,o,a)=>{t!==a&&e===i&&n(Xle(o))};return tc.on(uA,r),()=>{tc.off(uA,r)}},[n,t,e])}function aue(){var e=Ht();j.useEffect(()=>{e(qle())},[e]),iue(),oue()}function sue(e,t,n,r,i,o){var a=Le(v=>ple(v,e,t)),s=Le(Yse),u=Le(Xx),c=Le(Yx),d=Le(Nj),p=Le(Kle),g=p?.active,h=jh();j.useEffect(()=>{if(!g&&c!=null&&u!=null){var v=Db({active:o,coordinate:n,dataKey:a,index:i,label:typeof r=="number"?String(r):r,sourceViewBox:h,graphicalItemId:s});tc.emit(Lb,c,v,u)}},[g,n,a,s,i,r,u,c,d,o,h])}function dA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function pA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?dA(Object(n),!0).forEach(function(r){lue(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):dA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function lue(e,t,n){return(t=uue(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function uue(e){var t=cue(e,"string");return typeof t=="symbol"?t:t+""}function cue(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function fue(e){return e.dataKey}function due(e,t){return x.isValidElement(e)?x.cloneElement(e,t):typeof e=="function"?x.createElement(e,t):x.createElement(Mte,t)}var hA=[],pue={allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",axisId:0,contentStyle:{},cursor:!0,filterNull:!0,includeHidden:!1,isAnimationActive:"auto",itemSorter:"name",itemStyle:{},labelStyle:{},offset:10,reverseDirection:{x:!1,y:!1},separator:" : ",trigger:"hover",useTranslate3d:!1,wrapperStyle:{}};function hue(e){var t,n,r=Mr(e,pue),{active:i,allowEscapeViewBox:o,animationDuration:a,animationEasing:s,content:u,filterNull:c,isAnimationActive:d,offset:p,payloadUniqBy:g,position:h,reverseDirection:v,useTranslate3d:b,wrapperStyle:y,cursor:w,shared:C,trigger:E,defaultIndex:_,portal:O,axisId:R}=r,I=Ht(),k=typeof _=="number"?String(_):_;j.useEffect(()=>{I(rse({shared:C,trigger:E,axisId:R,active:i,defaultIndex:k}))},[I,C,E,R,i,k]);var B=jh(),L=aj(),V=Zae(C),{activeIndex:D,isActive:H}=(t=Le(Fe=>mle(Fe,V,E,k)))!==null&&t!==void 0?t:{},J=Le(Fe=>gle(Fe,V,E,k)),te=Le(Fe=>PL(Fe,V,E,k)),G=Le(Fe=>hle(Fe,V,E,k)),ee=J,Q=Vle(),pe=(n=i??H)!==null&&n!==void 0?n:!1,[K,Ae]=jQ([ee,pe]),Se=V==="axis"?te:void 0;sue(V,E,G,Se,D,pe);var $e=O??Q;if($e==null||B==null||V==null)return null;var we=ee??hA;pe||(we=hA),c&&we.length&&(we=SQ(we.filter(Fe=>Fe.value!=null&&(Fe.hide!==!0||r.includeHidden)),g,fue));var Ce=we.length>0,ze=pA(pA({},r),{},{payload:we,label:Se,active:pe,activeIndex:D,coordinate:G,accessibilityLayer:L}),Ke=x.createElement(Ute,{allowEscapeViewBox:o,animationDuration:a,animationEasing:s,isAnimationActive:d,active:pe,coordinate:G,hasPayload:Ce,offset:p,position:h,reverseDirection:v,useTranslate3d:b,viewBox:B,wrapperStyle:y,lastBoundingBox:K,innerRef:Ae,hasPortalFromProps:!!O},due(u,ze));return x.createElement(x.Fragment,null,Up.createPortal(Ke,$e),pe&&x.createElement(Fle,{cursor:w,tooltipEventType:V,coordinate:G,payload:we,index:D}))}var kL=e=>null;kL.displayName="Cell";function gue(e,t,n){return(t=mue(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function mue(e){var t=vue(e,"string");return typeof t=="symbol"?t:t+""}function vue(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}class yue{constructor(t){gue(this,"cache",new Map),this.maxSize=t}get(t){var n=this.cache.get(t);return n!==void 0&&(this.cache.delete(t),this.cache.set(t,n)),n}set(t,n){if(this.cache.has(t))this.cache.delete(t);else if(this.cache.size>=this.maxSize){var r=this.cache.keys().next().value;r!=null&&this.cache.delete(r)}this.cache.set(t,n)}clear(){this.cache.clear()}size(){return this.cache.size}}function gA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function bue(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?gA(Object(n),!0).forEach(function(r){xue(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):gA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function xue(e,t,n){return(t=wue(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function wue(e){var t=Cue(e,"string");return typeof t=="symbol"?t:t+""}function Cue(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Sue={cacheSize:2e3,enableCache:!0},NL=bue({},Sue),mA=new yue(NL.cacheSize),Eue={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},vA="recharts_measurement_span";function _ue(e,t){var n=t.fontSize||"",r=t.fontFamily||"",i=t.fontWeight||"",o=t.fontStyle||"",a=t.letterSpacing||"",s=t.textTransform||"";return"".concat(e,"|").concat(n,"|").concat(r,"|").concat(i,"|").concat(o,"|").concat(a,"|").concat(s)}var yA=(e,t)=>{try{var n=document.getElementById(vA);n||(n=document.createElement("span"),n.setAttribute("id",vA),n.setAttribute("aria-hidden","true"),document.body.appendChild(n)),Object.assign(n.style,Eue,t),n.textContent="".concat(e);var r=n.getBoundingClientRect();return{width:r.width,height:r.height}}catch{return{width:0,height:0}}},ju=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(t==null||xc.isSsr)return{width:0,height:0};if(!NL.enableCache)return yA(t,n);var r=_ue(t,n),i=mA.get(r);if(i)return i;var o=yA(t,n);return mA.set(r,o),o},ML;function Oue(e,t,n){return(t=Pue(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Pue(e){var t=Aue(e,"string");return typeof t=="symbol"?t:t+""}function Aue(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var bA=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,xA=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,Rue=/^(px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q)$/,Iue=/(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/,Tue={cm:96/2.54,mm:96/25.4,pt:96/72,pc:96/6,in:96,Q:96/(2.54*40),px:1},kue=["cm","mm","pt","pc","in","Q","px"];function Nue(e){return kue.includes(e)}var rl="NaN";function Mue(e,t){return e*Tue[t]}class In{static parse(t){var n,[,r,i]=(n=Iue.exec(t))!==null&&n!==void 0?n:[];return r==null?In.NaN:new In(parseFloat(r),i??"")}constructor(t,n){this.num=t,this.unit=n,this.num=t,this.unit=n,Di(t)&&(this.unit=""),n!==""&&!Rue.test(n)&&(this.num=NaN,this.unit=""),Nue(n)&&(this.num=Mue(t,n),this.unit="px")}add(t){return this.unit!==t.unit?new In(NaN,""):new In(this.num+t.num,this.unit)}subtract(t){return this.unit!==t.unit?new In(NaN,""):new In(this.num-t.num,this.unit)}multiply(t){return this.unit!==""&&t.unit!==""&&this.unit!==t.unit?new In(NaN,""):new In(this.num*t.num,this.unit||t.unit)}divide(t){return this.unit!==""&&t.unit!==""&&this.unit!==t.unit?new In(NaN,""):new In(this.num/t.num,this.unit||t.unit)}toString(){return"".concat(this.num).concat(this.unit)}isNaN(){return Di(this.num)}}ML=In;Oue(In,"NaN",new ML(NaN,""));function DL(e){if(e==null||e.includes(rl))return rl;for(var t=e;t.includes("*")||t.includes("/");){var n,[,r,i,o]=(n=bA.exec(t))!==null&&n!==void 0?n:[],a=In.parse(r??""),s=In.parse(o??""),u=i==="*"?a.multiply(s):a.divide(s);if(u.isNaN())return rl;t=t.replace(bA,u.toString())}for(;t.includes("+")||/.-\d+(?:\.\d+)?/.test(t);){var c,[,d,p,g]=(c=xA.exec(t))!==null&&c!==void 0?c:[],h=In.parse(d??""),v=In.parse(g??""),b=p==="+"?h.add(v):h.subtract(v);if(b.isNaN())return rl;t=t.replace(xA,b.toString())}return t}var wA=/\(([^()]*)\)/;function Due(e){for(var t=e,n;(n=wA.exec(t))!=null;){var[,r]=n;t=t.replace(wA,DL(r))}return t}function jue(e){var t=e.replace(/\s+/g,"");return t=Due(t),t=DL(t),t}function Lue(e){try{return jue(e)}catch{return rl}}function uy(e){var t=Lue(e.slice(5,-1));return t===rl?"":t}var $ue=["x","y","lineHeight","capHeight","fill","scaleToFit","textAnchor","verticalAnchor"],Fue=["dx","dy","angle","className","breakAll"];function $b(){return $b=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},$b.apply(null,arguments)}function CA(e,t){if(e==null)return{};var n,r,i=Vue(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Vue(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var jL=/[ \f\n\r\t\v\u2028\u2029]+/,LL=e=>{var{children:t,breakAll:n,style:r}=e;try{var i=[];pn(t)||(n?i=t.toString().split(""):i=t.toString().split(jL));var o=i.map(s=>({word:s,width:ju(s,r).width})),a=n?0:ju(" ",r).width;return{wordsWithComputedWidth:o,spaceWidth:a}}catch{return null}};function $L(e){return e==="start"||e==="middle"||e==="end"||e==="inherit"}function Bue(e){return pn(e)||typeof e=="string"||typeof e=="number"||typeof e=="boolean"}var FL=(e,t,n,r)=>e.reduce((i,o)=>{var{word:a,width:s}=o,u=i[i.length-1];if(u&&s!=null&&(t==null||r||u.width+s+n<Number(t)))u.words.push(a),u.width+=s+n;else{var c={words:[a],width:s};i.push(c)}return i},[]),VL=e=>e.reduce((t,n)=>t.width>n.width?t:n),zue="…",SA=(e,t,n,r,i,o,a,s)=>{var u=e.slice(0,t),c=LL({breakAll:n,style:r,children:u+zue});if(!c)return[!1,[]];var d=FL(c.wordsWithComputedWidth,o,a,s),p=d.length>i||VL(d).width>Number(o);return[p,d]},Wue=(e,t,n,r,i)=>{var{maxLines:o,children:a,style:s,breakAll:u}=e,c=Te(o),d=String(a),p=FL(t,r,n,i);if(!c||i)return p;var g=p.length>o||VL(p).width>Number(r);if(!g)return p;for(var h=0,v=d.length-1,b=0,y;h<=v&&b<=d.length-1;){var w=Math.floor((h+v)/2),C=w-1,[E,_]=SA(d,C,u,s,o,r,n,i),[O]=SA(d,w,u,s,o,r,n,i);if(!E&&!O&&(h=w+1),E&&O&&(v=w-1),!E&&O){y=_;break}b++}return y||p},EA=e=>{var t=pn(e)?[]:e.toString().split(jL);return[{words:t,width:void 0}]},Hue=e=>{var{width:t,scaleToFit:n,children:r,style:i,breakAll:o,maxLines:a}=e;if((t||n)&&!xc.isSsr){var s,u,c=LL({breakAll:o,children:r,style:i});if(c){var{wordsWithComputedWidth:d,spaceWidth:p}=c;s=d,u=p}else return EA(r);return Wue({breakAll:o,children:r,maxLines:a,style:i},s,u,t,!!n)}return EA(r)},BL="#808080",Uue={angle:0,breakAll:!1,capHeight:"0.71em",fill:BL,lineHeight:"1em",scaleToFit:!1,textAnchor:"start",verticalAnchor:"end",x:0,y:0},Gw=j.forwardRef((e,t)=>{var n=Mr(e,Uue),{x:r,y:i,lineHeight:o,capHeight:a,fill:s,scaleToFit:u,textAnchor:c,verticalAnchor:d}=n,p=CA(n,$ue),g=j.useMemo(()=>Hue({breakAll:p.breakAll,children:p.children,maxLines:p.maxLines,scaleToFit:u,style:p.style,width:p.width}),[p.breakAll,p.children,p.maxLines,u,p.style,p.width]),{dx:h,dy:v,angle:b,className:y,breakAll:w}=p,C=CA(p,Fue);if(!ji(r)||!ji(i)||g.length===0)return null;var E=Number(r)+(Te(h)?h:0),_=Number(i)+(Te(v)?v:0);if(!ct(E)||!ct(_))return null;var O;switch(d){case"start":O=uy("calc(".concat(a,")"));break;case"middle":O=uy("calc(".concat((g.length-1)/2," * -").concat(o," + (").concat(a," / 2))"));break;default:O=uy("calc(".concat(g.length-1," * -").concat(o,")"));break}var R=[],I=g[0];if(u&&I!=null){var k=I.width,{width:B}=p;R.push("scale(".concat(Te(B)&&Te(k)?B/k:1,")"))}return b&&R.push("rotate(".concat(b,", ").concat(E,", ").concat(_,")")),R.length&&(C.transform=R.join(" ")),x.createElement("text",$b({},ti(C),{ref:t,x:E,y:_,className:Pt("recharts-text",y),textAnchor:c,fill:s.includes("url")?BL:s}),g.map((L,V)=>{var D=L.words.join(w?"":" ");return x.createElement("tspan",{x:E,dy:V===0?O:o,key:"".concat(D,"-").concat(V)},D)}))});Gw.displayName="Text";function _A(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function _i(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?_A(Object(n),!0).forEach(function(r){Gue(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_A(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Gue(e,t,n){return(t=que(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function que(e){var t=Kue(e,"string");return typeof t=="symbol"?t:t+""}function Kue(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Yue=e=>{var{viewBox:t,position:n,offset:r=0,parentViewBox:i}=e,{x:o,y:a,height:s,upperWidth:u,lowerWidth:c}=Vx(t),d=o,p=o+(u-c)/2,g=(d+p)/2,h=(u+c)/2,v=d+u/2,b=s>=0?1:-1,y=b*r,w=b>0?"end":"start",C=b>0?"start":"end",E=u>=0?1:-1,_=E*r,O=E>0?"end":"start",R=E>0?"start":"end",I=i;if(n==="top"){var k={x:d+u/2,y:a-y,horizontalAnchor:"middle",verticalAnchor:w};return I&&(k.height=Math.max(a-I.y,0),k.width=u),k}if(n==="bottom"){var B={x:p+c/2,y:a+s+y,horizontalAnchor:"middle",verticalAnchor:C};return I&&(B.height=Math.max(I.y+I.height-(a+s),0),B.width=c),B}if(n==="left"){var L={x:g-_,y:a+s/2,horizontalAnchor:O,verticalAnchor:"middle"};return I&&(L.width=Math.max(L.x-I.x,0),L.height=s),L}if(n==="right"){var V={x:g+h+_,y:a+s/2,horizontalAnchor:R,verticalAnchor:"middle"};return I&&(V.width=Math.max(I.x+I.width-V.x,0),V.height=s),V}var D=I?{width:h,height:s}:{};return n==="insideLeft"?_i({x:g+_,y:a+s/2,horizontalAnchor:R,verticalAnchor:"middle"},D):n==="insideRight"?_i({x:g+h-_,y:a+s/2,horizontalAnchor:O,verticalAnchor:"middle"},D):n==="insideTop"?_i({x:d+u/2,y:a+y,horizontalAnchor:"middle",verticalAnchor:C},D):n==="insideBottom"?_i({x:p+c/2,y:a+s-y,horizontalAnchor:"middle",verticalAnchor:w},D):n==="insideTopLeft"?_i({x:d+_,y:a+y,horizontalAnchor:R,verticalAnchor:C},D):n==="insideTopRight"?_i({x:d+u-_,y:a+y,horizontalAnchor:O,verticalAnchor:C},D):n==="insideBottomLeft"?_i({x:p+_,y:a+s-y,horizontalAnchor:R,verticalAnchor:w},D):n==="insideBottomRight"?_i({x:p+c-_,y:a+s-y,horizontalAnchor:O,verticalAnchor:w},D):n&&typeof n=="object"&&(Te(n.x)||ns(n.x))&&(Te(n.y)||ns(n.y))?_i({x:o+fi(n.x,h),y:a+fi(n.y,s),horizontalAnchor:"end",verticalAnchor:"end"},D):_i({x:v,y:a+s/2,horizontalAnchor:"middle",verticalAnchor:"middle"},D)},Xue=["labelRef"],Zue=["content"];function OA(e,t){if(e==null)return{};var n,r,i=Que(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Que(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function PA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Pu(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?PA(Object(n),!0).forEach(function(r){Jue(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):PA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Jue(e,t,n){return(t=ece(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ece(e){var t=tce(e,"string");return typeof t=="symbol"?t:t+""}function tce(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function no(){return no=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},no.apply(null,arguments)}var zL=j.createContext(null),nce=e=>{var{x:t,y:n,upperWidth:r,lowerWidth:i,width:o,height:a,children:s}=e,u=j.useMemo(()=>({x:t,y:n,upperWidth:r,lowerWidth:i,width:o,height:a}),[t,n,r,i,o,a]);return x.createElement(zL.Provider,{value:u},s)},WL=()=>{var e=j.useContext(zL),t=jh();return e||(t?Vx(t):void 0)},rce=j.createContext(null),ice=()=>{var e=j.useContext(rce),t=Le($j);return e||t},oce=e=>{var{value:t,formatter:n}=e,r=pn(e.children)?t:e.children;return typeof n=="function"?n(r):r},qw=e=>e!=null&&typeof e=="function",ace=(e,t)=>{var n=cr(t-e),r=Math.min(Math.abs(t-e),360);return n*r},sce=(e,t,n,r,i)=>{var{offset:o,className:a}=e,{cx:s,cy:u,innerRadius:c,outerRadius:d,startAngle:p,endAngle:g,clockWise:h}=i,v=(c+d)/2,b=ace(p,g),y=b>=0?1:-1,w,C;switch(t){case"insideStart":w=p+y*o,C=h;break;case"insideEnd":w=g-y*o,C=!h;break;case"end":w=g+y*o,C=h;break;default:throw new Error("Unsupported position ".concat(t))}C=b<=0?C:!C;var E=kn(s,u,v,w),_=kn(s,u,v,w+(C?1:-1)*359),O="M".concat(E.x,",").concat(E.y,`
|
|
226
|
-
A`).concat(v,",").concat(v,",0,1,").concat(
|
|
227
|
-
`).concat(_.x,",").concat(_.y),R=pn(e.id)?zu("recharts-radial-line-"):e.id;return x.createElement("text",no({},r,{dominantBaseline:"central",className:Pt("recharts-radial-bar-label",a)}),x.createElement("defs",null,x.createElement("path",{id:R,d:O})),x.createElement("textPath",{xlinkHref:"#".concat(R)},n))},lce=(e,t,n)=>{var{cx:r,cy:i,innerRadius:o,outerRadius:a,startAngle:s,endAngle:u}=e,c=(s+u)/2;if(n==="outside"){var{x:d,y:p}=kn(r,i,a+t,c);return{x:d,y:p,textAnchor:d>=r?"start":"end",verticalAnchor:"middle"}}if(n==="center")return{x:r,y:i,textAnchor:"middle",verticalAnchor:"middle"};if(n==="centerTop")return{x:r,y:i,textAnchor:"middle",verticalAnchor:"start"};if(n==="centerBottom")return{x:r,y:i,textAnchor:"middle",verticalAnchor:"end"};var g=(o+a)/2,{x:h,y:v}=kn(r,i,g,c);return{x:h,y:v,textAnchor:"middle",verticalAnchor:"middle"}},Rd=e=>e!=null&&"cx"in e&&Te(e.cx),uce={angle:0,offset:5,zIndex:Zn.label,position:"middle",textBreakAll:!1};function cce(e){if(!Rd(e))return e;var{cx:t,cy:n,outerRadius:r}=e,i=r*2;return{x:t-r,y:n-r,width:i,upperWidth:i,lowerWidth:i,height:i}}function qo(e){var t=Mr(e,uce),{viewBox:n,parentViewBox:r,position:i,value:o,children:a,content:s,className:u="",textBreakAll:c,labelRef:d}=t,p=ice(),g=WL(),h=i==="center"?g:p??g,v,b,y;n==null?v=h:Rd(n)?v=n:v=Vx(n);var w=cce(v);if(!v||pn(o)&&pn(a)&&!j.isValidElement(s)&&typeof s!="function")return null;var C=Pu(Pu({},t),{},{viewBox:v});if(j.isValidElement(s)){var{labelRef:E}=C,_=OA(C,Xue);return j.cloneElement(s,_)}if(typeof s=="function"){var{content:O}=C,R=OA(C,Zue);if(b=j.createElement(s,R),j.isValidElement(b))return b}else b=oce(t);var I=ti(t);if(Rd(v)){if(i==="insideStart"||i==="insideEnd"||i==="end")return sce(t,i,b,I,v);y=lce(v,t.offset,t.position)}else{if(!w)return null;var k=Yue({viewBox:w,position:i,offset:t.offset,parentViewBox:Rd(r)?void 0:r});y=Pu(Pu({x:k.x,y:k.y,textAnchor:k.horizontalAnchor,verticalAnchor:k.verticalAnchor},k.width!==void 0?{width:k.width}:{}),k.height!==void 0?{height:k.height}:{})}return x.createElement(Po,{zIndex:t.zIndex},x.createElement(Gw,no({ref:d,className:Pt("recharts-label",u)},I,y,{textAnchor:$L(I.textAnchor)?I.textAnchor:y.textAnchor,breakAll:c}),b))}qo.displayName="Label";var fce=(e,t,n)=>{if(!e)return null;var r={viewBox:t,labelRef:n};return e===!0?x.createElement(qo,no({key:"label-implicit"},r)):ji(e)?x.createElement(qo,no({key:"label-implicit",value:e},r)):j.isValidElement(e)?e.type===qo?j.cloneElement(e,Pu({key:"label-implicit"},r)):x.createElement(qo,no({key:"label-implicit",content:e},r)):qw(e)?x.createElement(qo,no({key:"label-implicit",content:e},r)):e&&typeof e=="object"?x.createElement(qo,no({},e,{key:"label-implicit"},r)):null};function dce(e){var{label:t,labelRef:n}=e,r=WL();return fce(t,r,n)||null}var pce=["valueAccessor"],hce=["dataKey","clockWise","id","textBreakAll","zIndex"];function $p(){return $p=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},$p.apply(null,arguments)}function AA(e,t){if(e==null)return{};var n,r,i=gce(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function gce(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var mce=e=>{var t=Array.isArray(e.value)?e.value[e.value.length-1]:e.value;if(Bue(t))return t},HL=j.createContext(void 0),vce=HL.Provider,UL=j.createContext(void 0);UL.Provider;function yce(){return j.useContext(HL)}function bce(){return j.useContext(UL)}function Id(e){var{valueAccessor:t=mce}=e,n=AA(e,pce),{dataKey:r,clockWise:i,id:o,textBreakAll:a,zIndex:s}=n,u=AA(n,hce),c=yce(),d=bce(),p=c||d;return!p||!p.length?null:x.createElement(Po,{zIndex:s??Zn.label},x.createElement(Mi,{className:"recharts-label-list"},p.map((g,h)=>{var v,b=pn(r)?t(g,h):Mn(g.payload,r),y=pn(o)?{}:{id:"".concat(o,"-").concat(h)};return x.createElement(qo,$p({key:"label-".concat(h)},ti(g),u,y,{fill:(v=n.fill)!==null&&v!==void 0?v:g.fill,parentViewBox:g.parentViewBox,value:b,textBreakAll:a,viewBox:g.viewBox,index:h,zIndex:0}))})))}Id.displayName="LabelList";function xce(e){var{label:t}=e;return t?t===!0?x.createElement(Id,{key:"labelList-implicit"}):x.isValidElement(t)||qw(t)?x.createElement(Id,{key:"labelList-implicit",content:t}):typeof t=="object"?x.createElement(Id,$p({key:"labelList-implicit"},t,{type:String(t.type)})):null:null}var wce={radiusAxis:{},angleAxis:{}},GL=Wn({name:"polarAxis",initialState:wce,reducers:{addRadiusAxis(e,t){e.radiusAxis[t.payload.id]=t.payload},removeRadiusAxis(e,t){delete e.radiusAxis[t.payload.id]},addAngleAxis(e,t){e.angleAxis[t.payload.id]=t.payload},removeAngleAxis(e,t){delete e.angleAxis[t.payload.id]}}}),{addRadiusAxis:xge,removeRadiusAxis:wge,addAngleAxis:Cge,removeAngleAxis:Sge}=GL.actions,Cce=GL.reducer;function Sce(e){return e&&typeof e=="object"&&"className"in e&&typeof e.className=="string"?e.className:""}var yd={exports:{}},St={};var RA;function Ece(){if(RA)return St;RA=1;var e=60103,t=60106,n=60107,r=60108,i=60114,o=60109,a=60110,s=60112,u=60113,c=60120,d=60115,p=60116,g=60121,h=60122,v=60117,b=60129,y=60131;if(typeof Symbol=="function"&&Symbol.for){var w=Symbol.for;e=w("react.element"),t=w("react.portal"),n=w("react.fragment"),r=w("react.strict_mode"),i=w("react.profiler"),o=w("react.provider"),a=w("react.context"),s=w("react.forward_ref"),u=w("react.suspense"),c=w("react.suspense_list"),d=w("react.memo"),p=w("react.lazy"),g=w("react.block"),h=w("react.server.block"),v=w("react.fundamental"),b=w("react.debug_trace_mode"),y=w("react.legacy_hidden")}function C(H){if(typeof H=="object"&&H!==null){var J=H.$$typeof;switch(J){case e:switch(H=H.type,H){case n:case i:case r:case u:case c:return H;default:switch(H=H&&H.$$typeof,H){case a:case s:case p:case d:case o:return H;default:return J}}case t:return J}}}var E=o,_=e,O=s,R=n,I=p,k=d,B=t,L=i,V=r,D=u;return St.ContextConsumer=a,St.ContextProvider=E,St.Element=_,St.ForwardRef=O,St.Fragment=R,St.Lazy=I,St.Memo=k,St.Portal=B,St.Profiler=L,St.StrictMode=V,St.Suspense=D,St.isAsyncMode=function(){return!1},St.isConcurrentMode=function(){return!1},St.isContextConsumer=function(H){return C(H)===a},St.isContextProvider=function(H){return C(H)===o},St.isElement=function(H){return typeof H=="object"&&H!==null&&H.$$typeof===e},St.isForwardRef=function(H){return C(H)===s},St.isFragment=function(H){return C(H)===n},St.isLazy=function(H){return C(H)===p},St.isMemo=function(H){return C(H)===d},St.isPortal=function(H){return C(H)===t},St.isProfiler=function(H){return C(H)===i},St.isStrictMode=function(H){return C(H)===r},St.isSuspense=function(H){return C(H)===u},St.isValidElementType=function(H){return typeof H=="string"||typeof H=="function"||H===n||H===i||H===b||H===r||H===u||H===c||H===y||typeof H=="object"&&H!==null&&(H.$$typeof===p||H.$$typeof===d||H.$$typeof===o||H.$$typeof===a||H.$$typeof===s||H.$$typeof===v||H.$$typeof===g||H[0]===h)},St.typeOf=C,St}var Et={};var IA;function _ce(){return IA||(IA=1,process.env.NODE_ENV!=="production"&&(function(){var e=60103,t=60106,n=60107,r=60108,i=60114,o=60109,a=60110,s=60112,u=60113,c=60120,d=60115,p=60116,g=60121,h=60122,v=60117,b=60129,y=60131;if(typeof Symbol=="function"&&Symbol.for){var w=Symbol.for;e=w("react.element"),t=w("react.portal"),n=w("react.fragment"),r=w("react.strict_mode"),i=w("react.profiler"),o=w("react.provider"),a=w("react.context"),s=w("react.forward_ref"),u=w("react.suspense"),c=w("react.suspense_list"),d=w("react.memo"),p=w("react.lazy"),g=w("react.block"),h=w("react.server.block"),v=w("react.fundamental"),w("react.scope"),w("react.opaque.id"),b=w("react.debug_trace_mode"),w("react.offscreen"),y=w("react.legacy_hidden")}var C=!1;function E(ne){return!!(typeof ne=="string"||typeof ne=="function"||ne===n||ne===i||ne===b||ne===r||ne===u||ne===c||ne===y||C||typeof ne=="object"&&ne!==null&&(ne.$$typeof===p||ne.$$typeof===d||ne.$$typeof===o||ne.$$typeof===a||ne.$$typeof===s||ne.$$typeof===v||ne.$$typeof===g||ne[0]===h))}function _(ne){if(typeof ne=="object"&&ne!==null){var $=ne.$$typeof;switch($){case e:var ie=ne.type;switch(ie){case n:case i:case r:case u:case c:return ie;default:var Z=ie&&ie.$$typeof;switch(Z){case a:case s:case p:case d:case o:return Z;default:return $}}case t:return $}}}var O=a,R=o,I=e,k=s,B=n,L=p,V=d,D=t,H=i,J=r,te=u,G=!1,ee=!1;function Q(ne){return G||(G=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function pe(ne){return ee||(ee=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function K(ne){return _(ne)===a}function Ae(ne){return _(ne)===o}function Se(ne){return typeof ne=="object"&&ne!==null&&ne.$$typeof===e}function $e(ne){return _(ne)===s}function we(ne){return _(ne)===n}function Ce(ne){return _(ne)===p}function ze(ne){return _(ne)===d}function Ke(ne){return _(ne)===t}function Fe(ne){return _(ne)===i}function Y(ne){return _(ne)===r}function oe(ne){return _(ne)===u}Et.ContextConsumer=O,Et.ContextProvider=R,Et.Element=I,Et.ForwardRef=k,Et.Fragment=B,Et.Lazy=L,Et.Memo=V,Et.Portal=D,Et.Profiler=H,Et.StrictMode=J,Et.Suspense=te,Et.isAsyncMode=Q,Et.isConcurrentMode=pe,Et.isContextConsumer=K,Et.isContextProvider=Ae,Et.isElement=Se,Et.isForwardRef=$e,Et.isFragment=we,Et.isLazy=Ce,Et.isMemo=ze,Et.isPortal=Ke,Et.isProfiler=Fe,Et.isStrictMode=Y,Et.isSuspense=oe,Et.isValidElementType=E,Et.typeOf=_})()),Et}var TA;function Oce(){return TA||(TA=1,process.env.NODE_ENV==="production"?yd.exports=Ece():yd.exports=_ce()),yd.exports}var Pce=Oce(),kA=e=>typeof e=="string"?e:e?e.displayName||e.name||"Component":"",NA=null,cy=null,qL=e=>{if(e===NA&&Array.isArray(cy))return cy;var t=[];return j.Children.forEach(e,n=>{pn(n)||(Pce.isFragment(n)?t=t.concat(qL(n.props.children)):t.push(n))}),cy=t,NA=e,t};function Ace(e,t){var n=[],r=[];return Array.isArray(t)?r=t.map(i=>kA(i)):r=[kA(t)],qL(e).forEach(i=>{var o=gl(i,"type.displayName")||gl(i,"type.name");o&&r.indexOf(o)!==-1&&n.push(i)}),n}var fy={},MA;function Rce(){return MA||(MA=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){if(typeof n!="object"||n==null)return!1;if(Object.getPrototypeOf(n)===null)return!0;if(Object.prototype.toString.call(n)!=="[object Object]"){const i=n[Symbol.toStringTag];return i==null||!Object.getOwnPropertyDescriptor(n,Symbol.toStringTag)?.writable?!1:n.toString()===`[object ${i}]`}let r=n;for(;Object.getPrototypeOf(r)!==null;)r=Object.getPrototypeOf(r);return Object.getPrototypeOf(n)===r}e.isPlainObject=t})(fy)),fy}var dy,DA;function Ice(){return DA||(DA=1,dy=Rce().isPlainObject),dy}var Tce=Ice();const kce=fs(Tce);var jA,LA,$A,FA,VA;function BA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function zA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?BA(Object(n),!0).forEach(function(r){Nce(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):BA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Nce(e,t,n){return(t=Mce(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Mce(e){var t=Dce(e,"string");return typeof t=="symbol"?t:t+""}function Dce(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Fp(){return Fp=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Fp.apply(null,arguments)}function bu(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}var WA=(e,t,n,r,i)=>{var o=n-r,a;return a=qt(jA||(jA=bu(["M ",",",""])),e,t),a+=qt(LA||(LA=bu(["L ",",",""])),e+n,t),a+=qt($A||($A=bu(["L ",",",""])),e+n-o/2,t+i),a+=qt(FA||(FA=bu(["L ",",",""])),e+n-o/2-r,t+i),a+=qt(VA||(VA=bu(["L ",","," Z"])),e,t),a},jce={x:0,y:0,upperWidth:0,lowerWidth:0,height:0,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},Lce=e=>{var t=Mr(e,jce),{x:n,y:r,upperWidth:i,lowerWidth:o,height:a,className:s}=t,{animationEasing:u,animationDuration:c,animationBegin:d,isUpdateAnimationActive:p}=t,g=j.useRef(null),[h,v]=j.useState(-1),b=j.useRef(i),y=j.useRef(o),w=j.useRef(a),C=j.useRef(n),E=j.useRef(r),_=Hx(e,"trapezoid-");if(j.useEffect(()=>{if(g.current&&g.current.getTotalLength)try{var J=g.current.getTotalLength();J&&v(J)}catch{}},[]),n!==+n||r!==+r||i!==+i||o!==+o||a!==+a||i===0&&o===0||a===0)return null;var O=Pt("recharts-trapezoid",s);if(!p)return x.createElement("g",null,x.createElement("path",Fp({},ti(t),{className:O,d:WA(n,r,i,o,a)})));var R=b.current,I=y.current,k=w.current,B=C.current,L=E.current,V="0px ".concat(h===-1?1:h,"px"),D="".concat(h,"px ").concat(h,"px"),H=lj(["strokeDasharray"],c,u);return x.createElement(Wx,{animationId:_,key:_,canBegin:h>0,duration:c,easing:u,isActive:p,begin:d},J=>{var te=Tn(R,i,J),G=Tn(I,o,J),ee=Tn(k,a,J),Q=Tn(B,n,J),pe=Tn(L,r,J);g.current&&(b.current=te,y.current=G,w.current=ee,C.current=Q,E.current=pe);var K=J>0?{transition:H,strokeDasharray:D}:{strokeDasharray:V};return x.createElement("path",Fp({},ti(t),{className:O,d:WA(Q,pe,te,G,ee),ref:g,style:zA(zA({},K),t.style)}))})},$ce=["option","shapeType","activeClassName","inActiveClassName"];function Fce(e,t){if(e==null)return{};var n,r,i=Vce(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Vce(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function HA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Vp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?HA(Object(n),!0).forEach(function(r){Bce(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):HA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Bce(e,t,n){return(t=zce(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zce(e){var t=Wce(e,"string");return typeof t=="symbol"?t:t+""}function Wce(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Hce(e,t){return Vp(Vp({},t),e)}function Uce(e,t){return e==="symbols"}function UA(e){var{shapeType:t,elementProps:n}=e;switch(t){case"rectangle":return x.createElement(dj,n);case"trapezoid":return x.createElement(Lce,n);case"sector":return x.createElement(gj,n);case"symbols":if(Uce(t))return x.createElement(GM,n);break;case"curve":return x.createElement(sj,n);default:return null}}function Gce(e){return j.isValidElement(e)?e.props:e}function qce(e){var{option:t,shapeType:n,activeClassName:r="recharts-active-shape",inActiveClassName:i="recharts-shape"}=e,o=Fce(e,$ce),a;if(j.isValidElement(t))a=j.cloneElement(t,Vp(Vp({},o),Gce(t)));else if(typeof t=="function")a=t(o,o.index);else if(kce(t)&&typeof t!="boolean"){var s=Hce(t,o);a=x.createElement(UA,{shapeType:n,elementProps:s})}else{var u=o;a=x.createElement(UA,{shapeType:n,elementProps:u})}return o.isActive?x.createElement(Mi,{className:r},a):x.createElement(Mi,{className:i},a)}var KL=(e,t,n)=>{var r=Ht();return(i,o)=>a=>{e?.(i,o,a),r(sL({activeIndex:String(o),activeDataKey:t,activeCoordinate:i.tooltipPosition,activeGraphicalItemId:n}))}},YL=e=>{var t=Ht();return(n,r)=>i=>{e?.(n,r,i),t(ise())}},XL=(e,t,n)=>{var r=Ht();return(i,o)=>a=>{e?.(i,o,a),r(ose({activeIndex:String(o),activeDataKey:t,activeCoordinate:i.tooltipPosition,activeGraphicalItemId:n}))}};function Kce(e){var{tooltipEntrySettings:t}=e,n=Ht(),r=pr(),i=j.useRef(null);return j.useLayoutEffect(()=>{r||(i.current===null?n(ese(t)):i.current!==t&&n(tse({prev:i.current,next:t})),i.current=t)},[t,n,r]),j.useLayoutEffect(()=>()=>{i.current&&(n(nse(i.current)),i.current=null)},[n]),null}function Yce(e){var{legendPayload:t}=e,n=Ht(),r=pr(),i=j.useRef(null);return j.useLayoutEffect(()=>{r||(i.current===null?n(ite(t)):i.current!==t&&n(ote({prev:i.current,next:t})),i.current=t)},[n,r,t]),j.useLayoutEffect(()=>()=>{i.current&&(n(ate(i.current)),i.current=null)},[n]),null}var py,Xce=()=>{var[e]=x.useState(()=>zu("uid-"));return e},Zce=(py=x.useId)!==null&&py!==void 0?py:Xce;function Qce(e,t){var n=Zce();return t||(e?"".concat(e,"-").concat(n):n)}var Jce=j.createContext(void 0),efe=e=>{var{id:t,type:n,children:r}=e,i=Qce("recharts-".concat(n),t);return x.createElement(Jce.Provider,{value:i},r(i))},tfe={cartesianItems:[],polarItems:[]},ZL=Wn({name:"graphicalItems",initialState:tfe,reducers:{addCartesianGraphicalItem:{reducer(e,t){e.cartesianItems.push(t.payload)},prepare:Mt()},replaceCartesianGraphicalItem:{reducer(e,t){var{prev:n,next:r}=t.payload,i=Qr(e).cartesianItems.indexOf(n);i>-1&&(e.cartesianItems[i]=r)},prepare:Mt()},removeCartesianGraphicalItem:{reducer(e,t){var n=Qr(e).cartesianItems.indexOf(t.payload);n>-1&&e.cartesianItems.splice(n,1)},prepare:Mt()},addPolarGraphicalItem:{reducer(e,t){e.polarItems.push(t.payload)},prepare:Mt()},removePolarGraphicalItem:{reducer(e,t){var n=Qr(e).polarItems.indexOf(t.payload);n>-1&&e.polarItems.splice(n,1)},prepare:Mt()},replacePolarGraphicalItem:{reducer(e,t){var{prev:n,next:r}=t.payload,i=Qr(e).polarItems.indexOf(n);i>-1&&(e.polarItems[i]=r)},prepare:Mt()}}}),{addCartesianGraphicalItem:nfe,replaceCartesianGraphicalItem:rfe,removeCartesianGraphicalItem:ife,addPolarGraphicalItem:Ege,removePolarGraphicalItem:_ge,replacePolarGraphicalItem:Oge}=ZL.actions,ofe=ZL.reducer,afe=e=>{var t=Ht(),n=j.useRef(null);return j.useLayoutEffect(()=>{n.current===null?t(nfe(e)):n.current!==e&&t(rfe({prev:n.current,next:e})),n.current=e},[t,e]),j.useLayoutEffect(()=>()=>{n.current&&(t(ife(n.current)),n.current=null)},[t]),null},sfe=j.memo(afe);function GA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function qA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?GA(Object(n),!0).forEach(function(r){lfe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):GA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function lfe(e,t,n){return(t=ufe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ufe(e){var t=cfe(e,"string");return typeof t=="symbol"?t:t+""}function cfe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var QL=0,ffe={xAxis:{},yAxis:{},zAxis:{}},JL=Wn({name:"cartesianAxis",initialState:ffe,reducers:{addXAxis:{reducer(e,t){e.xAxis[t.payload.id]=t.payload},prepare:Mt()},replaceXAxis:{reducer(e,t){var{prev:n,next:r}=t.payload;e.xAxis[n.id]!==void 0&&(n.id!==r.id&&delete e.xAxis[n.id],e.xAxis[r.id]=r)},prepare:Mt()},removeXAxis:{reducer(e,t){delete e.xAxis[t.payload.id]},prepare:Mt()},addYAxis:{reducer(e,t){e.yAxis[t.payload.id]=t.payload},prepare:Mt()},replaceYAxis:{reducer(e,t){var{prev:n,next:r}=t.payload;e.yAxis[n.id]!==void 0&&(n.id!==r.id&&delete e.yAxis[n.id],e.yAxis[r.id]=r)},prepare:Mt()},removeYAxis:{reducer(e,t){delete e.yAxis[t.payload.id]},prepare:Mt()},addZAxis:{reducer(e,t){e.zAxis[t.payload.id]=t.payload},prepare:Mt()},replaceZAxis:{reducer(e,t){var{prev:n,next:r}=t.payload;e.zAxis[n.id]!==void 0&&(n.id!==r.id&&delete e.zAxis[n.id],e.zAxis[r.id]=r)},prepare:Mt()},removeZAxis:{reducer(e,t){delete e.zAxis[t.payload.id]},prepare:Mt()},updateYAxisWidth(e,t){var{id:n,width:r}=t.payload,i=e.yAxis[n];if(i){var o,a=i.widthHistory||[];if(a.length===3&&a[0]===a[2]&&r===a[1]&&r!==i.width&&Math.abs(r-((o=a[0])!==null&&o!==void 0?o:0))<=1)return;var s=[...a,r].slice(-3);e.yAxis[n]=qA(qA({},i),{},{width:r,widthHistory:s})}}}}),{addXAxis:dfe,replaceXAxis:pfe,removeXAxis:hfe,addYAxis:gfe,replaceYAxis:mfe,removeYAxis:vfe,addZAxis:Pge,replaceZAxis:Age,removeZAxis:Rge,updateYAxisWidth:yfe}=JL.actions,bfe=JL.reducer,xfe=q([wn],e=>({top:e.top,bottom:e.bottom,left:e.left,right:e.right})),wfe=q([xfe,xo,wo],(e,t,n)=>{if(!(!e||t==null||n==null))return{x:e.left,y:e.top,width:Math.max(0,t-e.left-e.right),height:Math.max(0,n-e.top-e.bottom)}}),e$=()=>Le(wfe),KA=(e,t,n)=>{var r=n??e;if(!pn(r))return fi(r,t,0)},Cfe=(e,t,n)=>{var r={},i=e.filter(Gh),o=e.filter(c=>c.stackId==null),a=i.reduce((c,d)=>{var p=c[d.stackId];return p==null&&(p=[]),p.push(d),c[d.stackId]=p,c},r),s=Object.entries(a).map(c=>{var d,[p,g]=c,h=g.map(b=>b.dataKey),v=KA(t,n,(d=g[0])===null||d===void 0?void 0:d.barSize);return{stackId:p,dataKeys:h,barSize:v}}),u=o.map(c=>{var d=[c.dataKey].filter(g=>g!=null),p=KA(t,n,c.barSize);return{stackId:void 0,dataKeys:d,barSize:p}});return[...s,...u]};function YA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function bd(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?YA(Object(n),!0).forEach(function(r){Sfe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):YA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Sfe(e,t,n){return(t=Efe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Efe(e){var t=_fe(e,"string");return typeof t=="symbol"?t:t+""}function _fe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Ofe(e,t,n,r,i){var o,a=r.length;if(!(a<1)){var s=fi(e,n,0,!0),u,c=[];if(ct((o=r[0])===null||o===void 0?void 0:o.barSize)){var d=!1,p=n/a,g=r.reduce((C,E)=>C+(E.barSize||0),0);g+=(a-1)*s,g>=n&&(g-=(a-1)*s,s=0),g>=n&&p>0&&(d=!0,p*=.9,g=a*p);var h=(n-g)/2>>0,v={offset:h-s,size:0};u=r.reduce((C,E)=>{var _,O={stackId:E.stackId,dataKeys:E.dataKeys,position:{offset:v.offset+v.size+s,size:d?p:(_=E.barSize)!==null&&_!==void 0?_:0}},R=[...C,O];return v=O.position,R},c)}else{var b=fi(t,n,0,!0);n-2*b-(a-1)*s<=0&&(s=0);var y=(n-2*b-(a-1)*s)/a;y>1&&(y>>=0);var w=ct(i)?Math.min(y,i):y;u=r.reduce((C,E,_)=>[...C,{stackId:E.stackId,dataKeys:E.dataKeys,position:{offset:b+(y+s)*_+(y-w)/2,size:w}}],c)}return u}}var Pfe=(e,t,n,r,i,o,a)=>{var s=pn(a)?t:a,u=Ofe(n,r,i!==o?i:o,e,s);return i!==o&&u!=null&&(u=u.map(c=>bd(bd({},c),{},{position:bd(bd({},c.position),{},{offset:c.position.offset-i/2})}))),u},Afe=(e,t)=>{var n=ew(t);if(!(!e||n==null||t==null)){var{stackId:r}=t;if(r!=null){var i=e[r];if(i){var{stackedData:o}=i;if(o)return o.find(a=>a.key===n)}}}},Rfe=(e,t)=>{if(!(e==null||t==null)){var n=e.find(r=>r.stackId===t.stackId&&t.dataKey!=null&&r.dataKeys.includes(t.dataKey));if(n!=null)return n.position}};function Ife(e,t){return e&&typeof e=="object"&&"zIndex"in e&&typeof e.zIndex=="number"&&ct(e.zIndex)?e.zIndex:t}var Tfe=e=>{var{chartData:t}=e,n=Ht(),r=pr();return j.useEffect(()=>r?()=>{}:(n(cA(t)),()=>{n(cA(void 0))}),[t,n,r]),null},XA={x:0,y:0,width:0,height:0,padding:{top:0,right:0,bottom:0,left:0}},t$=Wn({name:"brush",initialState:XA,reducers:{setBrushSettings(e,t){return t.payload==null?XA:t.payload}}}),{setBrushSettings:Ige}=t$.actions,kfe=t$.reducer;function Nfe(e){return(e%180+180)%180}var Mfe=function(t){var{width:n,height:r}=t,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,o=Nfe(i),a=o*Math.PI/180,s=Math.atan(r/n),u=a>s&&a<Math.PI-s?r/Math.sin(a):n/Math.cos(a);return Math.abs(u)},Dfe={dots:[],areas:[],lines:[]},n$=Wn({name:"referenceElements",initialState:Dfe,reducers:{addDot:(e,t)=>{e.dots.push(t.payload)},removeDot:(e,t)=>{var n=Qr(e).dots.findIndex(r=>r===t.payload);n!==-1&&e.dots.splice(n,1)},addArea:(e,t)=>{e.areas.push(t.payload)},removeArea:(e,t)=>{var n=Qr(e).areas.findIndex(r=>r===t.payload);n!==-1&&e.areas.splice(n,1)},addLine:(e,t)=>{e.lines.push(t.payload)},removeLine:(e,t)=>{var n=Qr(e).lines.findIndex(r=>r===t.payload);n!==-1&&e.lines.splice(n,1)}}}),{addDot:Tge,removeDot:kge,addArea:Nge,removeArea:Mge,addLine:Dge,removeLine:jge}=n$.actions,jfe=n$.reducer,Lfe=j.createContext(void 0),$fe=e=>{var{children:t}=e,[n]=j.useState("".concat(zu("recharts"),"-clip")),r=e$();if(r==null)return null;var{x:i,y:o,width:a,height:s}=r;return x.createElement(Lfe.Provider,{value:n},x.createElement("defs",null,x.createElement("clipPath",{id:n},x.createElement("rect",{x:i,y:o,height:s,width:a}))),t)};function r$(e,t){if(t<1)return[];if(t===1)return e;for(var n=[],r=0;r<e.length;r+=t){var i=e[r];i!==void 0&&n.push(i)}return n}function Ffe(e,t,n){var r={width:e.width+t.width,height:e.height+t.height};return Mfe(r,n)}function Vfe(e,t,n){var r=n==="width",{x:i,y:o,width:a,height:s}=e;return t===1?{start:r?i:o,end:r?i+a:o+s}:{start:r?i+a:o+s,end:r?i:o}}function nc(e,t,n,r,i){if(e*t<e*r||e*t>e*i)return!1;var o=n();return e*(t-e*o/2-r)>=0&&e*(t+e*o/2-i)<=0}function Bfe(e,t){return r$(e,t+1)}function zfe(e,t,n,r,i){for(var o=(r||[]).slice(),{start:a,end:s}=t,u=0,c=1,d=a,p=function(){var v=r?.[u];if(v===void 0)return{v:r$(r,c)};var b=u,y,w=()=>(y===void 0&&(y=n(v,b)),y),C=v.coordinate,E=u===0||nc(e,C,w,d,s);E||(u=0,d=a,c+=1),E&&(d=C+e*(w()/2+i),u+=c)},g;c<=o.length;)if(g=p(),g)return g.v;return[]}function Wfe(e,t,n,r,i){var o=(r||[]).slice(),a=o.length;if(a===0)return[];for(var{start:s,end:u}=t,c=1;c<=a;c++){for(var d=(a-1)%c,p=s,g=!0,h=function(){var _=r[b];if(_==null)return 0;var O=b,R,I=()=>(R===void 0&&(R=n(_,O)),R),k=_.coordinate,B=b===d||nc(e,k,I,p,u);if(!B)return g=!1,1;B&&(p=k+e*(I()/2+i))},v,b=d;b<a&&(v=h(),!(v!==0&&v===1));b+=c);if(g){for(var y=[],w=d;w<a;w+=c){var C=r[w];C!=null&&y.push(C)}return y}}return[]}function ZA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Bn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ZA(Object(n),!0).forEach(function(r){Hfe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ZA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Hfe(e,t,n){return(t=Ufe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ufe(e){var t=Gfe(e,"string");return typeof t=="symbol"?t:t+""}function Gfe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function qfe(e,t,n,r,i){for(var o=(r||[]).slice(),a=o.length,{start:s}=t,{end:u}=t,c=function(g){var h=o[g];if(h==null)return 1;var v=h,b,y=()=>(b===void 0&&(b=n(h,g)),b);if(g===a-1){var w=e*(v.coordinate+e*y()/2-u);o[g]=v=Bn(Bn({},v),{},{tickCoord:w>0?v.coordinate-w*e:v.coordinate})}else o[g]=v=Bn(Bn({},v),{},{tickCoord:v.coordinate});if(v.tickCoord!=null){var C=nc(e,v.tickCoord,y,s,u);C&&(u=v.tickCoord-e*(y()/2+i),o[g]=Bn(Bn({},v),{},{isShow:!0}))}},d=a-1;d>=0;d--)c(d);return o}function Kfe(e,t,n,r,i,o){var a=(r||[]).slice(),s=a.length,{start:u,end:c}=t;if(o){var d=r[s-1];if(d!=null){var p=n(d,s-1),g=e*(d.coordinate+e*p/2-c);if(a[s-1]=d=Bn(Bn({},d),{},{tickCoord:g>0?d.coordinate-g*e:d.coordinate}),d.tickCoord!=null){var h=nc(e,d.tickCoord,()=>p,u,c);h&&(c=d.tickCoord-e*(p/2+i),a[s-1]=Bn(Bn({},d),{},{isShow:!0}))}}}for(var v=o?s-1:s,b=function(C){var E=a[C];if(E==null)return 1;var _=E,O,R=()=>(O===void 0&&(O=n(E,C)),O);if(C===0){var I=e*(_.coordinate-e*R()/2-u);a[C]=_=Bn(Bn({},_),{},{tickCoord:I<0?_.coordinate-I*e:_.coordinate})}else a[C]=_=Bn(Bn({},_),{},{tickCoord:_.coordinate});if(_.tickCoord!=null){var k=nc(e,_.tickCoord,R,u,c);k&&(u=_.tickCoord+e*(R()/2+i),a[C]=Bn(Bn({},_),{},{isShow:!0}))}},y=0;y<v;y++)b(y);return a}function Kw(e,t,n){var{tick:r,ticks:i,viewBox:o,minTickGap:a,orientation:s,interval:u,tickFormatter:c,unit:d,angle:p}=e;if(!i||!i.length||!r)return[];if(Te(u)||xc.isSsr){var g;return(g=Bfe(i,Te(u)?u:0))!==null&&g!==void 0?g:[]}var h=[],v=s==="top"||s==="bottom"?"width":"height",b=d&&v==="width"?ju(d,{fontSize:t,letterSpacing:n}):{width:0,height:0},y=(O,R)=>{var I=typeof c=="function"?c(O.value,R):O.value;return v==="width"?Ffe(ju(I,{fontSize:t,letterSpacing:n}),b,p):ju(I,{fontSize:t,letterSpacing:n})[v]},w=i[0],C=i[1],E=i.length>=2&&w!=null&&C!=null?cr(C.coordinate-w.coordinate):1,_=Vfe(o,E,v);return u==="equidistantPreserveStart"?zfe(E,_,y,i,a):u==="equidistantPreserveEnd"?Wfe(E,_,y,i,a):(u==="preserveStart"||u==="preserveStartEnd"?h=Kfe(E,_,y,i,a,u==="preserveStartEnd"):h=qfe(E,_,y,i,a),h.filter(O=>O.isShow))}var Yfe=e=>{var{ticks:t,label:n,labelGapWithTick:r=5,tickSize:i=0,tickMargin:o=0}=e,a=0;if(t){Array.from(t).forEach(d=>{if(d){var p=d.getBoundingClientRect();p.width>a&&(a=p.width)}});var s=n?n.getBoundingClientRect().width:0,u=i+o,c=a+u+s+(n?r:0);return Math.round(c)}return 0},Xfe={xAxis:{},yAxis:{}},i$=Wn({name:"renderedTicks",initialState:Xfe,reducers:{setRenderedTicks:(e,t)=>{var{axisType:n,axisId:r,ticks:i}=t.payload;e[n][r]=i},removeRenderedTicks:(e,t)=>{var{axisType:n,axisId:r}=t.payload;delete e[n][r]}}}),{setRenderedTicks:Zfe,removeRenderedTicks:Qfe}=i$.actions,Jfe=i$.reducer,ede=["axisLine","width","height","className","hide","ticks","axisType","axisId"];function tde(e,t){if(e==null)return{};var n,r,i=nde(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function nde(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function ss(){return ss=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ss.apply(null,arguments)}function QA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Gt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?QA(Object(n),!0).forEach(function(r){rde(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):QA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function rde(e,t,n){return(t=ide(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ide(e){var t=ode(e,"string");return typeof t=="symbol"?t:t+""}function ode(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var lo={x:0,y:0,width:0,height:0,viewBox:{x:0,y:0,width:0,height:0},orientation:"bottom",ticks:[],stroke:"#666",tickLine:!0,axisLine:!0,tick:!0,mirror:!1,minTickGap:5,tickSize:6,tickMargin:2,interval:"preserveEnd",zIndex:Zn.axis};function ade(e){var{x:t,y:n,width:r,height:i,orientation:o,mirror:a,axisLine:s,otherSvgProps:u}=e;if(!s)return null;var c=Gt(Gt(Gt({},u),fo(s)),{},{fill:"none"});if(o==="top"||o==="bottom"){var d=+(o==="top"&&!a||o==="bottom"&&a);c=Gt(Gt({},c),{},{x1:t,y1:n+d*i,x2:t+r,y2:n+d*i})}else{var p=+(o==="left"&&!a||o==="right"&&a);c=Gt(Gt({},c),{},{x1:t+p*r,y1:n,x2:t+p*r,y2:n+i})}return x.createElement("line",ss({},c,{className:Pt("recharts-cartesian-axis-line",gl(s,"className"))}))}function sde(e,t,n,r,i,o,a,s,u){var c,d,p,g,h,v,b=s?-1:1,y=e.tickSize||a,w=Te(e.tickCoord)?e.tickCoord:e.coordinate;switch(o){case"top":c=d=e.coordinate,g=n+ +!s*i,p=g-b*y,v=p-b*u,h=w;break;case"left":p=g=e.coordinate,d=t+ +!s*r,c=d-b*y,h=c-b*u,v=w;break;case"right":p=g=e.coordinate,d=t+ +s*r,c=d+b*y,h=c+b*u,v=w;break;default:c=d=e.coordinate,g=n+ +s*i,p=g+b*y,v=p+b*u,h=w;break}return{line:{x1:c,y1:p,x2:d,y2:g},tick:{x:h,y:v}}}function lde(e,t){switch(e){case"left":return t?"start":"end";case"right":return t?"end":"start";default:return"middle"}}function ude(e,t){switch(e){case"left":case"right":return"middle";case"top":return t?"start":"end";default:return t?"end":"start"}}function cde(e){var{option:t,tickProps:n,value:r}=e,i,o=Pt(n.className,"recharts-cartesian-axis-tick-value");if(x.isValidElement(t))i=x.cloneElement(t,Gt(Gt({},n),{},{className:o}));else if(typeof t=="function")i=t(Gt(Gt({},n),{},{className:o}));else{var a="recharts-cartesian-axis-tick-value";typeof t!="boolean"&&(a=Pt(a,Sce(t))),i=x.createElement(Gw,ss({},n,{className:a}),r)}return i}function fde(e){var{ticks:t,axisType:n,axisId:r}=e,i=Ht();return j.useEffect(()=>{if(r==null||n==null)return ds;var o=t.map(a=>({value:a.value,coordinate:a.coordinate,offset:a.offset,index:a.index}));return i(Zfe({ticks:o,axisId:r,axisType:n})),()=>{i(Qfe({axisId:r,axisType:n}))}},[i,t,r,n]),null}var dde=j.forwardRef((e,t)=>{var{ticks:n=[],tick:r,tickLine:i,stroke:o,tickFormatter:a,unit:s,padding:u,tickTextProps:c,orientation:d,mirror:p,x:g,y:h,width:v,height:b,tickSize:y,tickMargin:w,fontSize:C,letterSpacing:E,getTicksConfig:_,events:O,axisType:R,axisId:I}=e,k=Kw(Gt(Gt({},_),{},{ticks:n}),C,E),B=fo(_),L=Cx(r),V=$L(B.textAnchor)?B.textAnchor:lde(d,p),D=ude(d,p),H={};typeof i=="object"&&(H=i);var J=Gt(Gt({},B),{},{fill:"none"},H),te=k.map(Q=>Gt({entry:Q},sde(Q,g,h,v,b,d,y,p,w))),G=te.map(Q=>{var{entry:pe,line:K}=Q;return x.createElement(Mi,{className:"recharts-cartesian-axis-tick",key:"tick-".concat(pe.value,"-").concat(pe.coordinate,"-").concat(pe.tickCoord)},i&&x.createElement("line",ss({},J,K,{className:Pt("recharts-cartesian-axis-tick-line",gl(i,"className"))})))}),ee=te.map((Q,pe)=>{var K,Ae,{entry:Se,tick:$e}=Q,we=Gt(Gt(Gt(Gt({verticalAnchor:D},B),{},{textAnchor:V,stroke:"none",fill:o},$e),{},{index:pe,payload:Se,visibleTicksCount:k.length,tickFormatter:a,padding:u},c),{},{angle:(K=(Ae=c?.angle)!==null&&Ae!==void 0?Ae:B.angle)!==null&&K!==void 0?K:0}),Ce=Gt(Gt({},we),L);return x.createElement(Mi,ss({className:"recharts-cartesian-axis-tick-label",key:"tick-label-".concat(Se.value,"-").concat(Se.coordinate,"-").concat(Se.tickCoord)},Rx(O,Se,pe)),r&&x.createElement(cde,{option:r,tickProps:Ce,value:"".concat(typeof a=="function"?a(Se.value,pe):Se.value).concat(s||"")}))});return x.createElement("g",{className:"recharts-cartesian-axis-ticks recharts-".concat(R,"-ticks")},x.createElement(fde,{ticks:k,axisId:I,axisType:R}),ee.length>0&&x.createElement(Po,{zIndex:Zn.label},x.createElement("g",{className:"recharts-cartesian-axis-tick-labels recharts-".concat(R,"-tick-labels"),ref:t},ee)),G.length>0&&x.createElement("g",{className:"recharts-cartesian-axis-tick-lines recharts-".concat(R,"-tick-lines")},G))}),pde=j.forwardRef((e,t)=>{var{axisLine:n,width:r,height:i,className:o,hide:a,ticks:s,axisType:u,axisId:c}=e,d=tde(e,ede),[p,g]=j.useState(""),[h,v]=j.useState(""),b=j.useRef(null);j.useImperativeHandle(t,()=>({getCalculatedWidth:()=>{var w;return Yfe({ticks:b.current,label:(w=e.labelRef)===null||w===void 0?void 0:w.current,labelGapWithTick:5,tickSize:e.tickSize,tickMargin:e.tickMargin})}}));var y=j.useCallback(w=>{if(w){var C=w.getElementsByClassName("recharts-cartesian-axis-tick-value");b.current=C;var E=C[0];if(E){var _=window.getComputedStyle(E),O=_.fontSize,R=_.letterSpacing;(O!==p||R!==h)&&(g(O),v(R))}}},[p,h]);return a||r!=null&&r<=0||i!=null&&i<=0?null:x.createElement(Po,{zIndex:e.zIndex},x.createElement(Mi,{className:Pt("recharts-cartesian-axis",o)},x.createElement(ade,{x:e.x,y:e.y,width:r,height:i,orientation:e.orientation,mirror:e.mirror,axisLine:n,otherSvgProps:fo(e)}),x.createElement(dde,{ref:y,axisType:u,events:d,fontSize:p,getTicksConfig:e,height:e.height,letterSpacing:h,mirror:e.mirror,orientation:e.orientation,padding:e.padding,stroke:e.stroke,tick:e.tick,tickFormatter:e.tickFormatter,tickLine:e.tickLine,tickMargin:e.tickMargin,tickSize:e.tickSize,tickTextProps:e.tickTextProps,ticks:s,unit:e.unit,width:e.width,x:e.x,y:e.y,axisId:c}),x.createElement(nce,{x:e.x,y:e.y,width:e.width,height:e.height,lowerWidth:e.width,upperWidth:e.width},x.createElement(dce,{label:e.label,labelRef:e.labelRef}),e.children)))}),Yw=x.forwardRef((e,t)=>{var n=Mr(e,lo);return x.createElement(pde,ss({},n,{ref:t}))});Yw.displayName="CartesianAxis";var hde=["x1","y1","x2","y2","key"],gde=["offset"],mde=["xAxisId","yAxisId"],vde=["xAxisId","yAxisId"];function JA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function zn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?JA(Object(n),!0).forEach(function(r){yde(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):JA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function yde(e,t,n){return(t=bde(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function bde(e){var t=xde(e,"string");return typeof t=="symbol"?t:t+""}function xde(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Ua(){return Ua=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ua.apply(null,arguments)}function Bp(e,t){if(e==null)return{};var n,r,i=wde(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function wde(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var Cde=e=>{var{fill:t}=e;if(!t||t==="none")return null;var{fillOpacity:n,x:r,y:i,width:o,height:a,ry:s}=e;return x.createElement("rect",{x:r,y:i,ry:s,width:o,height:a,stroke:"none",fill:t,fillOpacity:n,className:"recharts-cartesian-grid-bg"})};function o$(e){var{option:t,lineItemProps:n}=e,r;if(x.isValidElement(t))r=x.cloneElement(t,n);else if(typeof t=="function")r=t(n);else{var i,{x1:o,y1:a,x2:s,y2:u,key:c}=n,d=Bp(n,hde),p=(i=fo(d))!==null&&i!==void 0?i:{},{offset:g}=p,h=Bp(p,gde);r=x.createElement("line",Ua({},h,{x1:o,y1:a,x2:s,y2:u,fill:"none",key:c}))}return r}function Sde(e){var{x:t,width:n,horizontal:r=!0,horizontalPoints:i}=e;if(!r||!i||!i.length)return null;var{xAxisId:o,yAxisId:a}=e,s=Bp(e,mde),u=i.map((c,d)=>{var p=zn(zn({},s),{},{x1:t,y1:c,x2:t+n,y2:c,key:"line-".concat(d),index:d});return x.createElement(o$,{key:"line-".concat(d),option:r,lineItemProps:p})});return x.createElement("g",{className:"recharts-cartesian-grid-horizontal"},u)}function Ede(e){var{y:t,height:n,vertical:r=!0,verticalPoints:i}=e;if(!r||!i||!i.length)return null;var{xAxisId:o,yAxisId:a}=e,s=Bp(e,vde),u=i.map((c,d)=>{var p=zn(zn({},s),{},{x1:c,y1:t,x2:c,y2:t+n,key:"line-".concat(d),index:d});return x.createElement(o$,{option:r,lineItemProps:p,key:"line-".concat(d)})});return x.createElement("g",{className:"recharts-cartesian-grid-vertical"},u)}function _de(e){var{horizontalFill:t,fillOpacity:n,x:r,y:i,width:o,height:a,horizontalPoints:s,horizontal:u=!0}=e;if(!u||!t||!t.length||s==null)return null;var c=s.map(p=>Math.round(p+i-i)).sort((p,g)=>p-g);i!==c[0]&&c.unshift(0);var d=c.map((p,g)=>{var h=c[g+1],v=h==null,b=v?i+a-p:h-p;if(b<=0)return null;var y=g%t.length;return x.createElement("rect",{key:"react-".concat(g),y:p,x:r,height:b,width:o,stroke:"none",fill:t[y],fillOpacity:n,className:"recharts-cartesian-grid-bg"})});return x.createElement("g",{className:"recharts-cartesian-gridstripes-horizontal"},d)}function Ode(e){var{vertical:t=!0,verticalFill:n,fillOpacity:r,x:i,y:o,width:a,height:s,verticalPoints:u}=e;if(!t||!n||!n.length)return null;var c=u.map(p=>Math.round(p+i-i)).sort((p,g)=>p-g);i!==c[0]&&c.unshift(0);var d=c.map((p,g)=>{var h=c[g+1],v=h==null,b=v?i+a-p:h-p;if(b<=0)return null;var y=g%n.length;return x.createElement("rect",{key:"react-".concat(g),x:p,y:o,width:b,height:s,stroke:"none",fill:n[y],fillOpacity:r,className:"recharts-cartesian-grid-bg"})});return x.createElement("g",{className:"recharts-cartesian-gridstripes-vertical"},d)}var Pde=(e,t)=>{var{xAxis:n,width:r,height:i,offset:o}=e;return VD(Kw(zn(zn(zn({},lo),n),{},{ticks:BD(n),viewBox:{x:0,y:0,width:r,height:i}})),o.left,o.left+o.width,t)},Ade=(e,t)=>{var{yAxis:n,width:r,height:i,offset:o}=e;return VD(Kw(zn(zn(zn({},lo),n),{},{ticks:BD(n),viewBox:{x:0,y:0,width:r,height:i}})),o.top,o.top+o.height,t)},Rde={horizontal:!0,vertical:!0,horizontalPoints:[],verticalPoints:[],stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[],xAxisId:0,yAxisId:0,syncWithTicks:!1,zIndex:Zn.grid};function a$(e){var t=KD(),n=YD(),r=qD(),i=zn(zn({},Mr(e,Rde)),{},{x:Te(e.x)?e.x:r.left,y:Te(e.y)?e.y:r.top,width:Te(e.width)?e.width:r.width,height:Te(e.height)?e.height:r.height}),{xAxisId:o,yAxisId:a,x:s,y:u,width:c,height:d,syncWithTicks:p,horizontalValues:g,verticalValues:h}=i,v=pr(),b=Le(B=>ZP(B,"xAxis",o,v)),y=Le(B=>ZP(B,"yAxis",a,v));if(!Li(c)||!Li(d)||!Te(s)||!Te(u))return null;var w=i.verticalCoordinatesGenerator||Pde,C=i.horizontalCoordinatesGenerator||Ade,{horizontalPoints:E,verticalPoints:_}=i;if((!E||!E.length)&&typeof C=="function"){var O=g&&g.length,R=C({yAxis:y?zn(zn({},y),{},{ticks:O?g:y.ticks}):void 0,width:t??c,height:n??d,offset:r},O?!0:p);pp(Array.isArray(R),"horizontalCoordinatesGenerator should return Array but instead it returned [".concat(typeof R,"]")),Array.isArray(R)&&(E=R)}if((!_||!_.length)&&typeof w=="function"){var I=h&&h.length,k=w({xAxis:b?zn(zn({},b),{},{ticks:I?h:b.ticks}):void 0,width:t??c,height:n??d,offset:r},I?!0:p);pp(Array.isArray(k),"verticalCoordinatesGenerator should return Array but instead it returned [".concat(typeof k,"]")),Array.isArray(k)&&(_=k)}return x.createElement(Po,{zIndex:i.zIndex},x.createElement("g",{className:"recharts-cartesian-grid"},x.createElement(Cde,{fill:i.fill,fillOpacity:i.fillOpacity,x:i.x,y:i.y,width:i.width,height:i.height,ry:i.ry}),x.createElement(_de,Ua({},i,{horizontalPoints:E})),x.createElement(Ode,Ua({},i,{verticalPoints:_})),x.createElement(Sde,Ua({},i,{offset:r,horizontalPoints:E,xAxis:b,yAxis:y})),x.createElement(Ede,Ua({},i,{offset:r,verticalPoints:_,xAxis:b,yAxis:y}))))}a$.displayName="CartesianGrid";var Ide={},s$=Wn({name:"errorBars",initialState:Ide,reducers:{addErrorBar:(e,t)=>{var{itemId:n,errorBar:r}=t.payload;e[n]||(e[n]=[]),e[n].push(r)},replaceErrorBar:(e,t)=>{var{itemId:n,prev:r,next:i}=t.payload;e[n]&&(e[n]=e[n].map(o=>o.dataKey===r.dataKey&&o.direction===r.direction?i:o))},removeErrorBar:(e,t)=>{var{itemId:n,errorBar:r}=t.payload;e[n]&&(e[n]=e[n].filter(i=>i.dataKey!==r.dataKey||i.direction!==r.direction))}}}),{addErrorBar:Lge,replaceErrorBar:$ge,removeErrorBar:Fge}=s$.actions,Tde=s$.reducer,kde=["children"];function Nde(e,t){if(e==null)return{};var n,r,i=Mde(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Mde(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var Dde={data:[],xAxisId:"xAxis-0",yAxisId:"yAxis-0",dataPointFormatter:()=>({x:0,y:0,value:0}),errorBarOffset:0},jde=j.createContext(Dde);function Lde(e){var{children:t}=e,n=Nde(e,kde);return x.createElement(jde.Provider,{value:n},t)}function l$(e,t){var n,r,i=Le(c=>Eo(c,e)),o=Le(c=>_o(c,t)),a=(n=i?.allowDataOverflow)!==null&&n!==void 0?n:un.allowDataOverflow,s=(r=o?.allowDataOverflow)!==null&&r!==void 0?r:cn.allowDataOverflow,u=a||s;return{needClip:u,needClipX:a,needClipY:s}}function $de(e){var{xAxisId:t,yAxisId:n,clipPathId:r}=e,i=e$(),{needClipX:o,needClipY:a,needClip:s}=l$(t,n);if(!s||!i)return null;var{x:u,y:c,width:d,height:p}=i;return x.createElement("clipPath",{id:"clipPath-".concat(r)},x.createElement("rect",{x:o?u:u-d/2,y:a?c:c-p/2,width:o?d:d*2,height:a?p:p*2}))}function gs(e,t){var n,r;return(n=(r=e.graphicalItems.cartesianItems.find(i=>i.id===t))===null||r===void 0?void 0:r.xAxisId)!==null&&n!==void 0?n:QL}function ms(e,t){var n,r;return(n=(r=e.graphicalItems.cartesianItems.find(i=>i.id===t))===null||r===void 0?void 0:r.yAxisId)!==null&&n!==void 0?n:QL}var Fde=process.env.NODE_ENV==="production",hy="Invariant failed";function Vde(e,t){if(Fde)throw new Error(hy);var n=typeof t=="function"?t():t,r=n?"".concat(hy,": ").concat(n):hy;throw new Error(r)}function Fb(){return Fb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Fb.apply(null,arguments)}function Xw(e){return x.createElement(qce,Fb({shapeType:"rectangle",activeClassName:"recharts-active-bar",inActiveClassName:"recharts-inactive-bar"},e))}var Bde=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return(r,i)=>{if(Te(t))return t;var o=Te(r)||pn(r);return o?t(r,i):(o||Vde(!1,"minPointSize callback function received a value with type of ".concat(typeof r,". Currently only numbers or null/undefined are supported.")),n)}},zde=(e,t,n)=>n,Wde=(e,t)=>t,kc=q([Pw,Wde],(e,t)=>e.filter(n=>n.type==="bar").find(n=>n.id===t)),Hde=q([kc],e=>e?.maxBarSize),Ude=(e,t,n,r)=>r,Gde=q([At,Pw,gs,ms,zde],(e,t,n,r,i)=>t.filter(o=>e==="horizontal"?o.xAxisId===n:o.yAxisId===r).filter(o=>o.isPanorama===i).filter(o=>o.hide===!1).filter(o=>o.type==="bar")),qde=(e,t,n)=>{var r=At(e),i=gs(e,t),o=ms(e,t);if(!(i==null||o==null))return r==="horizontal"?Mb(e,"yAxis",o,n):Mb(e,"xAxis",i,n)},Kde=(e,t)=>{var n=At(e),r=gs(e,t),i=ms(e,t);if(!(r==null||i==null))return n==="horizontal"?XP(e,"xAxis",r):XP(e,"yAxis",i)},Yde=q([Gde,lre,Kde],Cfe),Xde=(e,t,n)=>{var r,i,o=kc(e,t);if(o==null)return 0;var a=gs(e,t),s=ms(e,t);if(a==null||s==null)return 0;var u=At(e),c=Ij(e),{maxBarSize:d}=o,p=pn(d)?c:d,g,h;return u==="horizontal"?(g=Cl(e,"xAxis",a,n),h=wl(e,"xAxis",a,n)):(g=Cl(e,"yAxis",s,n),h=wl(e,"yAxis",s,n)),(r=(i=dp(g,h,!0))!==null&&i!==void 0?i:p)!==null&&r!==void 0?r:0},u$=(e,t,n)=>{var r=At(e),i=gs(e,t),o=ms(e,t);if(!(i==null||o==null)){var a,s;return r==="horizontal"?(a=Cl(e,"xAxis",i,n),s=wl(e,"xAxis",i,n)):(a=Cl(e,"yAxis",o,n),s=wl(e,"yAxis",o,n)),dp(a,s)}},Zde=q([Yde,Ij,sre,Tj,Xde,u$,Hde],Pfe),Qde=(e,t,n)=>{var r=gs(e,t);if(r!=null)return Cl(e,"xAxis",r,n)},Jde=(e,t,n)=>{var r=ms(e,t);if(r!=null)return Cl(e,"yAxis",r,n)},epe=(e,t,n)=>{var r=gs(e,t);if(r!=null)return wl(e,"xAxis",r,n)},tpe=(e,t,n)=>{var r=ms(e,t);if(r!=null)return wl(e,"yAxis",r,n)},npe=q([Zde,kc],Rfe),rpe=q([qde,kc],Afe),ipe=q([wn,$x,Qde,Jde,epe,tpe,npe,At,tre,u$,rpe,kc,Ude],(e,t,n,r,i,o,a,s,u,c,d,p,g)=>{var{chartData:h,dataStartIndex:v,dataEndIndex:b}=u;if(!(p==null||a==null||t==null||s!=="horizontal"&&s!=="vertical"||n==null||r==null||i==null||o==null||c==null)){var{data:y}=p,w;if(y!=null&&y.length>0?w=y:w=h?.slice(v,b+1),w!=null)return kpe({layout:s,barSettings:p,pos:a,parentViewBox:t,bandSize:c,xAxis:n,yAxis:r,xAxisTicks:i,yAxisTicks:o,stackedData:d,displayedData:w,offset:e,cells:g,dataStartIndex:v})}}),ope=["index"];function Vb(){return Vb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Vb.apply(null,arguments)}function ape(e,t){if(e==null)return{};var n,r,i=spe(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function spe(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var c$=j.createContext(void 0),lpe=e=>{var t=j.useContext(c$);if(t!=null)return t.stackId;if(e!=null)return oee(e)},upe=(e,t)=>"recharts-bar-stack-clip-path-".concat(e,"-").concat(t),cpe=e=>{var t=j.useContext(c$);if(t!=null){var{stackId:n}=t;return"url(#".concat(upe(n,e),")")}},f$=e=>{var{index:t}=e,n=ape(e,ope),r=cpe(t);return x.createElement(Mi,Vb({className:"recharts-bar-stack-layer",clipPath:r},n))},fpe=["onMouseEnter","onMouseLeave","onClick"],dpe=["value","background","tooltipPosition"],ppe=["id"],hpe=["onMouseEnter","onClick","onMouseLeave"];function sa(){return sa=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},sa.apply(null,arguments)}function eR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Yn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?eR(Object(n),!0).forEach(function(r){gpe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):eR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function gpe(e,t,n){return(t=mpe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function mpe(e){var t=vpe(e,"string");return typeof t=="symbol"?t:t+""}function vpe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function zp(e,t){if(e==null)return{};var n,r,i=ype(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function ype(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var bpe=e=>{var{dataKey:t,name:n,fill:r,legendType:i,hide:o}=e;return[{inactive:o,dataKey:t,type:i,color:r,value:zD(n,t),payload:e}]},xpe=x.memo(e=>{var{dataKey:t,stroke:n,strokeWidth:r,fill:i,name:o,hide:a,unit:s,tooltipType:u,id:c}=e,d={dataDefinedOnItem:void 0,getPosition:ds,settings:{stroke:n,strokeWidth:r,fill:i,dataKey:t,nameKey:void 0,name:zD(o,t),hide:a,type:u,color:i,unit:s,graphicalItemId:c}};return x.createElement(Kce,{tooltipEntrySettings:d})});function wpe(e){var t=Le(Sl),{data:n,dataKey:r,background:i,allOtherBarProps:o}=e,{onMouseEnter:a,onMouseLeave:s,onClick:u}=o,c=zp(o,fpe),d=KL(a,r,o.id),p=YL(s),g=XL(u,r,o.id);if(!i||n==null)return null;var h=Cx(i);return x.createElement(Po,{zIndex:Ife(i,Zn.barBackground)},n.map((v,b)=>{var{value:y,background:w,tooltipPosition:C}=v,E=zp(v,dpe);if(!w)return null;var _=d(v,b),O=p(v,b),R=g(v,b),I=Yn(Yn(Yn(Yn(Yn({option:i,isActive:String(b)===t},E),{},{fill:"#eee"},w),h),Rx(c,v,b)),{},{onMouseEnter:_,onMouseLeave:O,onClick:R,dataKey:r,index:b,className:"recharts-bar-background-rectangle"});return x.createElement(Xw,sa({key:"background-bar-".concat(b)},I))}))}function Cpe(e){var{showLabels:t,children:n,rects:r}=e,i=r?.map(o=>{var a={x:o.x,y:o.y,width:o.width,lowerWidth:o.width,upperWidth:o.width,height:o.height};return Yn(Yn({},a),{},{value:o.value,payload:o.payload,parentViewBox:o.parentViewBox,viewBox:a,fill:o.fill})});return x.createElement(vce,{value:t?i:void 0},n)}function Spe(e){var{shape:t,activeBar:n,baseProps:r,entry:i,index:o,dataKey:a}=e,s=Le(Sl),u=Le(CL),c=n&&String(i.originalDataIndex)===s&&(u==null||a===u),[d,p]=j.useState(!1),[g,h]=j.useState(!1);j.useEffect(()=>{var E;return c?(p(!0),E=requestAnimationFrame(()=>{h(!0)})):h(!1),()=>{cancelAnimationFrame(E)}},[c]);var v=j.useCallback(()=>{c||p(!1)},[c]),b=c&&g,y=c||d,w;c?n===!0?w=t:w=n:w=t;var C=x.createElement(Xw,sa({},r,{name:String(r.name)},i,{isActive:b,option:w,index:o,dataKey:a,onTransitionEnd:v}));return y?x.createElement(Po,{zIndex:Zn.activeBar},x.createElement(f$,{index:i.originalDataIndex},C)):C}function Epe(e){var{shape:t,baseProps:n,entry:r,index:i,dataKey:o}=e;return x.createElement(Xw,sa({},n,{name:String(n.name)},r,{isActive:!1,option:t,index:i,dataKey:o}))}function _pe(e){var t,{data:n,props:r}=e,i=(t=fo(r))!==null&&t!==void 0?t:{},{id:o}=i,a=zp(i,ppe),{shape:s,dataKey:u,activeBar:c}=r,{onMouseEnter:d,onClick:p,onMouseLeave:g}=r,h=zp(r,hpe),v=KL(d,u,o),b=YL(g),y=XL(p,u,o);return n?x.createElement(x.Fragment,null,n.map((w,C)=>x.createElement(f$,sa({index:w.originalDataIndex,key:"rectangle-".concat(w?.x,"-").concat(w?.y,"-").concat(w?.value,"-").concat(C),className:"recharts-bar-rectangle"},Rx(h,w,C),{onMouseEnter:v(w,C),onMouseLeave:b(w,C),onClick:y(w,C)}),c?x.createElement(Spe,{shape:s,activeBar:c,baseProps:a,entry:w,index:C,dataKey:u}):x.createElement(Epe,{shape:s,baseProps:a,entry:w,index:C,dataKey:u})))):null}function Ope(e){var{props:t,previousRectanglesRef:n}=e,{data:r,layout:i,isAnimationActive:o,animationBegin:a,animationDuration:s,animationEasing:u,onAnimationEnd:c,onAnimationStart:d}=t,p=n.current,g=Hx(t,"recharts-bar-"),[h,v]=j.useState(!1),b=!h,y=j.useCallback(()=>{typeof c=="function"&&c(),v(!1)},[c]),w=j.useCallback(()=>{typeof d=="function"&&d(),v(!0)},[d]);return x.createElement(Cpe,{showLabels:b,rects:r},x.createElement(Wx,{animationId:g,begin:a,duration:s,isActive:o,easing:u,onAnimationEnd:y,onAnimationStart:w,key:g},C=>{var E=C===1?r:r?.map((_,O)=>{var R=p&&p[O];if(R)return Yn(Yn({},_),{},{x:Tn(R.x,_.x,C),y:Tn(R.y,_.y,C),width:Tn(R.width,_.width,C),height:Tn(R.height,_.height,C)});if(i==="horizontal"){var I=Tn(0,_.height,C),k=Tn(_.stackedBarStart,_.y,C);return Yn(Yn({},_),{},{y:k,height:I})}var B=Tn(0,_.width,C),L=Tn(_.stackedBarStart,_.x,C);return Yn(Yn({},_),{},{width:B,x:L})});return C>0&&(n.current=E??null),E==null?null:x.createElement(Mi,null,x.createElement(_pe,{props:t,data:E}))}),x.createElement(xce,{label:t.label}),t.children)}function Ppe(e){var t=j.useRef(null);return x.createElement(Ope,{previousRectanglesRef:t,props:e})}var d$=0,Ape=(e,t)=>{var n=Array.isArray(e.value)?e.value[1]:e.value;return{x:e.x,y:e.y,value:n,errorVal:Mn(e,t)}};class Rpe extends j.PureComponent{render(){var{hide:t,data:n,dataKey:r,className:i,xAxisId:o,yAxisId:a,needClip:s,background:u,id:c}=this.props;if(t||n==null)return null;var d=Pt("recharts-bar",i),p=c;return x.createElement(Mi,{className:d,id:c},s&&x.createElement("defs",null,x.createElement($de,{clipPathId:p,xAxisId:o,yAxisId:a})),x.createElement(Mi,{className:"recharts-bar-rectangles",clipPath:s?"url(#clipPath-".concat(p,")"):void 0},x.createElement(wpe,{data:n,dataKey:r,background:u,allOtherBarProps:this.props}),x.createElement(Ppe,this.props)))}}var Ipe={activeBar:!1,animationBegin:0,animationDuration:400,animationEasing:"ease",background:!1,hide:!1,isAnimationActive:"auto",label:!1,legendType:"rect",minPointSize:d$,xAxisId:0,yAxisId:0,zIndex:Zn.bar};function Tpe(e){var{xAxisId:t,yAxisId:n,hide:r,legendType:i,minPointSize:o,activeBar:a,animationBegin:s,animationDuration:u,animationEasing:c,isAnimationActive:d}=e,{needClip:p}=l$(t,n),g=_l(),h=pr(),v=Ace(e.children,kL),b=Le(C=>ipe(C,e.id,h,v));if(g!=="vertical"&&g!=="horizontal")return null;var y,w=b?.[0];return w==null||w.height==null||w.width==null?y=0:y=g==="vertical"?w.height/2:w.width/2,x.createElement(Lde,{xAxisId:t,yAxisId:n,data:b,dataPointFormatter:Ape,errorBarOffset:y},x.createElement(Rpe,sa({},e,{layout:g,needClip:p,data:b,xAxisId:t,yAxisId:n,hide:r,legendType:i,minPointSize:o,activeBar:a,animationBegin:s,animationDuration:u,animationEasing:c,isAnimationActive:d})))}function kpe(e){var{layout:t,barSettings:{dataKey:n,minPointSize:r,hasCustomShape:i},pos:o,bandSize:a,xAxis:s,yAxis:u,xAxisTicks:c,yAxisTicks:d,stackedData:p,displayedData:g,offset:h,cells:v,parentViewBox:b,dataStartIndex:y}=e,w=t==="horizontal"?u:s,C=p?w.scale.domain():null,E=aee({numericAxis:w}),_=w.scale.map(E);return g.map((O,R)=>{var I,k,B,L,V,D;if(p){var H=p[R+y];if(H==null)return null;I=eee(H,C)}else I=Mn(O,n),Array.isArray(I)||(I=[E,I]);var J=Bde(r,d$)(I[1],R);if(t==="horizontal"){var te,G=u.scale.map(I[0]),ee=u.scale.map(I[1]);if(G==null||ee==null)return null;k=U_({axis:s,ticks:c,bandSize:a,offset:o.offset,entry:O,index:R}),B=(te=ee??G)!==null&&te!==void 0?te:void 0,L=o.size;var Q=G-ee;if(V=Di(Q)?0:Q,D={x:k,y:h.top,width:L,height:h.height},Math.abs(J)>0&&Math.abs(V)<Math.abs(J)){var pe=cr(V||J)*(Math.abs(J)-Math.abs(V));B-=pe,V+=pe}}else{var K=s.scale.map(I[0]),Ae=s.scale.map(I[1]);if(K==null||Ae==null)return null;if(k=K,B=U_({axis:u,ticks:d,bandSize:a,offset:o.offset,entry:O,index:R}),L=Ae-K,V=o.size,D={x:h.left,y:B,width:h.width,height:V},Math.abs(J)>0&&Math.abs(L)<Math.abs(J)){var Se=cr(L||J)*(Math.abs(J)-Math.abs(L));L+=Se}}if(k==null||B==null||L==null||V==null||!i&&(L===0||V===0))return null;var $e=Yn(Yn({},O),{},{stackedBarStart:_,x:k,y:B,width:L,height:V,value:p?I:I[1],payload:O,background:D,tooltipPosition:{x:k+L/2,y:B+V/2},parentViewBox:b,originalDataIndex:R},v&&v[R]&&v[R].props);return $e}).filter(Boolean)}function Npe(e){var t=Mr(e,Ipe),n=lpe(t.stackId),r=pr();return x.createElement(efe,{id:t.id,type:"bar"},i=>x.createElement(x.Fragment,null,x.createElement(Yce,{legendPayload:bpe(t)}),x.createElement(xpe,{dataKey:t.dataKey,stroke:t.stroke,strokeWidth:t.strokeWidth,fill:t.fill,name:t.name,hide:t.hide,unit:t.unit,tooltipType:t.tooltipType,id:i}),x.createElement(sfe,{type:"bar",id:i,data:void 0,xAxisId:t.xAxisId,yAxisId:t.yAxisId,zAxisId:0,dataKey:t.dataKey,stackId:n,hide:t.hide,barSize:t.barSize,minPointSize:t.minPointSize,maxBarSize:t.maxBarSize,isPanorama:r,hasCustomShape:t.shape!=null}),x.createElement(Po,{zIndex:t.zIndex},x.createElement(Tpe,sa({},t,{id:i})))))}var p$=x.memo(Npe,Vh);p$.displayName="Bar";var Mpe=["domain","range"],Dpe=["domain","range"];function tR(e,t){if(e==null)return{};var n,r,i=jpe(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function jpe(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function nR(e,t){return e===t?!0:Array.isArray(e)&&e.length===2&&Array.isArray(t)&&t.length===2?e[0]===t[0]&&e[1]===t[1]:!1}function h$(e,t){if(e===t)return!0;var{domain:n,range:r}=e,i=tR(e,Mpe),{domain:o,range:a}=t,s=tR(t,Dpe);return!nR(n,o)||!nR(r,a)?!1:Vh(i,s)}var Lpe=["type"],$pe=["dangerouslySetInnerHTML","ticks","scale"],Fpe=["id","scale"];function Bb(){return Bb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Bb.apply(null,arguments)}function rR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function iR(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?rR(Object(n),!0).forEach(function(r){Vpe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):rR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Vpe(e,t,n){return(t=Bpe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Bpe(e){var t=zpe(e,"string");return typeof t=="symbol"?t:t+""}function zpe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function zb(e,t){if(e==null)return{};var n,r,i=Wpe(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Wpe(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function Hpe(e){var t=Ht(),n=j.useRef(null),r=XD(),{type:i}=e,o=zb(e,Lpe),a=Wh(r,"xAxis",i),s=j.useMemo(()=>{if(a!=null)return iR(iR({},o),{},{type:a})},[o,a]);return j.useLayoutEffect(()=>{s!=null&&(n.current===null?t(dfe(s)):n.current!==s&&t(pfe({prev:n.current,next:s})),n.current=s)},[s,t]),j.useLayoutEffect(()=>()=>{n.current&&(t(hfe(n.current)),n.current=null)},[t]),null}var Upe=e=>{var{xAxisId:t,className:n}=e,r=Le($x),i=pr(),o="xAxis",a=Le(w=>tL(w,o,t,i)),s=Le(w=>Q2(w,t)),u=Le(w=>zae(w,t)),c=Le(w=>w2(w,t));if(s==null||u==null||c==null)return null;var{dangerouslySetInnerHTML:d,ticks:p,scale:g}=e,h=zb(e,$pe),{id:v,scale:b}=c,y=zb(c,Fpe);return x.createElement(Yw,Bb({},h,y,{x:u.x,y:u.y,width:s.width,height:s.height,className:Pt("recharts-".concat(o," ").concat(o),n),viewBox:r,ticks:a,axisType:o,axisId:t}))},Gpe={allowDataOverflow:un.allowDataOverflow,allowDecimals:un.allowDecimals,allowDuplicatedCategory:un.allowDuplicatedCategory,angle:un.angle,axisLine:lo.axisLine,height:un.height,hide:!1,includeHidden:un.includeHidden,interval:un.interval,label:!1,minTickGap:un.minTickGap,mirror:un.mirror,orientation:un.orientation,padding:un.padding,reversed:un.reversed,scale:un.scale,tick:un.tick,tickCount:un.tickCount,tickLine:lo.tickLine,tickSize:lo.tickSize,type:un.type,niceTicks:un.niceTicks,xAxisId:0},qpe=e=>{var t=Mr(e,Gpe);return x.createElement(x.Fragment,null,x.createElement(Hpe,{allowDataOverflow:t.allowDataOverflow,allowDecimals:t.allowDecimals,allowDuplicatedCategory:t.allowDuplicatedCategory,angle:t.angle,dataKey:t.dataKey,domain:t.domain,height:t.height,hide:t.hide,id:t.xAxisId,includeHidden:t.includeHidden,interval:t.interval,minTickGap:t.minTickGap,mirror:t.mirror,name:t.name,orientation:t.orientation,padding:t.padding,reversed:t.reversed,scale:t.scale,tick:t.tick,tickCount:t.tickCount,tickFormatter:t.tickFormatter,ticks:t.ticks,type:t.type,unit:t.unit,niceTicks:t.niceTicks}),x.createElement(Upe,t))},g$=x.memo(qpe,h$);g$.displayName="XAxis";var Kpe=["type"],Ype=["dangerouslySetInnerHTML","ticks","scale"],Xpe=["id","scale"];function Wb(){return Wb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Wb.apply(null,arguments)}function oR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function aR(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?oR(Object(n),!0).forEach(function(r){Zpe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):oR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Zpe(e,t,n){return(t=Qpe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Qpe(e){var t=Jpe(e,"string");return typeof t=="symbol"?t:t+""}function Jpe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Hb(e,t){if(e==null)return{};var n,r,i=ehe(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function ehe(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function the(e){var t=Ht(),n=j.useRef(null),r=XD(),{type:i}=e,o=Hb(e,Kpe),a=Wh(r,"yAxis",i),s=j.useMemo(()=>{if(a!=null)return aR(aR({},o),{},{type:a})},[a,o]);return j.useLayoutEffect(()=>{s!=null&&(n.current===null?t(gfe(s)):n.current!==s&&t(mfe({prev:n.current,next:s})),n.current=s)},[s,t]),j.useLayoutEffect(()=>()=>{n.current&&(t(vfe(n.current)),n.current=null)},[t]),null}function nhe(e){var{yAxisId:t,className:n,width:r,label:i}=e,o=j.useRef(null),a=j.useRef(null),s=Le($x),u=pr(),c=Ht(),d="yAxis",p=Le(R=>J2(R,t)),g=Le(R=>Hae(R,t)),h=Le(R=>tL(R,d,t,u)),v=Le(R=>C2(R,t));if(j.useLayoutEffect(()=>{if(!(r!=="auto"||!p||qw(i)||j.isValidElement(i)||v==null)){var R=o.current;if(R){var I=R.getCalculatedWidth();Math.round(p.width)!==Math.round(I)&&c(yfe({id:t,width:I}))}}},[h,p,c,i,t,r,v]),p==null||g==null||v==null)return null;var{dangerouslySetInnerHTML:b,ticks:y,scale:w}=e,C=Hb(e,Ype),{id:E,scale:_}=v,O=Hb(v,Xpe);return x.createElement(Yw,Wb({},C,O,{ref:o,labelRef:a,x:g.x,y:g.y,tickTextProps:r==="auto"?{width:void 0}:{width:r},width:p.width,height:p.height,className:Pt("recharts-".concat(d," ").concat(d),n),viewBox:s,ticks:h,axisType:d,axisId:t}))}var rhe={allowDataOverflow:cn.allowDataOverflow,allowDecimals:cn.allowDecimals,allowDuplicatedCategory:cn.allowDuplicatedCategory,angle:cn.angle,axisLine:lo.axisLine,hide:!1,includeHidden:cn.includeHidden,interval:cn.interval,label:!1,minTickGap:cn.minTickGap,mirror:cn.mirror,orientation:cn.orientation,padding:cn.padding,reversed:cn.reversed,scale:cn.scale,tick:cn.tick,tickCount:cn.tickCount,tickLine:lo.tickLine,tickSize:lo.tickSize,type:cn.type,niceTicks:cn.niceTicks,width:cn.width,yAxisId:0},ihe=e=>{var t=Mr(e,rhe);return x.createElement(x.Fragment,null,x.createElement(the,{interval:t.interval,id:t.yAxisId,scale:t.scale,type:t.type,domain:t.domain,allowDataOverflow:t.allowDataOverflow,dataKey:t.dataKey,allowDuplicatedCategory:t.allowDuplicatedCategory,allowDecimals:t.allowDecimals,tickCount:t.tickCount,padding:t.padding,includeHidden:t.includeHidden,reversed:t.reversed,ticks:t.ticks,width:t.width,orientation:t.orientation,mirror:t.mirror,hide:t.hide,unit:t.unit,name:t.name,angle:t.angle,minTickGap:t.minTickGap,tick:t.tick,tickFormatter:t.tickFormatter,niceTicks:t.niceTicks}),x.createElement(nhe,t))},m$=x.memo(ihe,h$);m$.displayName="YAxis";var ohe=(e,t)=>t,Zw=q([ohe,At,$j,Sn,yL,Oo,dle,wn],ble);function ahe(e){return"getBBox"in e.currentTarget&&typeof e.currentTarget.getBBox=="function"}function Qw(e){var t=e.currentTarget.getBoundingClientRect(),n,r;if(ahe(e)){var i=e.currentTarget.getBBox();n=i.width>0?t.width/i.width:1,r=i.height>0?t.height/i.height:1}else{var o=e.currentTarget;n=o.offsetWidth>0?t.width/o.offsetWidth:1,r=o.offsetHeight>0?t.height/o.offsetHeight:1}var a=(s,u)=>({relativeX:Math.round((s-t.left)/n),relativeY:Math.round((u-t.top)/r)});return"touches"in e?Array.from(e.touches).map(s=>a(s.clientX,s.clientY)):a(e.clientX,e.clientY)}var v$=Tr("mouseClick"),y$=mc();y$.startListening({actionCreator:v$,effect:(e,t)=>{var n=e.payload,r=Zw(t.getState(),Qw(n));r?.activeIndex!=null&&t.dispatch(ase({activeIndex:r.activeIndex,activeDataKey:void 0,activeCoordinate:r.activeCoordinate}))}});var Ub=Tr("mouseMove"),b$=mc(),Zs=null,Da=null,gy=null;b$.startListening({actionCreator:Ub,effect:(e,t)=>{var n=e.payload,r=t.getState(),{throttleDelay:i,throttledEvents:o}=r.eventSettings,a=o==="all"||o?.includes("mousemove");Zs!==null&&(cancelAnimationFrame(Zs),Zs=null),Da!==null&&(typeof i!="number"||!a)&&(clearTimeout(Da),Da=null),gy=Qw(n);var s=()=>{var u=t.getState(),c=jw(u,u.tooltip.settings.shared);if(!gy){Zs=null,Da=null;return}if(c==="axis"){var d=Zw(u,gy);d?.activeIndex!=null?t.dispatch(uL({activeIndex:d.activeIndex,activeDataKey:void 0,activeCoordinate:d.activeCoordinate})):t.dispatch(lL())}Zs=null,Da=null};if(!a){s();return}i==="raf"?Zs=requestAnimationFrame(s):typeof i=="number"&&Da===null&&(Da=setTimeout(s,i))}});function she(e,t){return t instanceof HTMLElement?"HTMLElement <".concat(t.tagName,' class="').concat(t.className,'">'):t===window?"global.window":e==="children"&&typeof t=="object"&&t!==null?"<<CHILDREN>>":t}var sR={accessibilityLayer:!0,barCategoryGap:"10%",barGap:4,barSize:void 0,className:void 0,maxBarSize:void 0,stackOffset:"none",syncId:void 0,syncMethod:"index",baseValue:void 0,reverseStackOrder:!1},x$=Wn({name:"rootProps",initialState:sR,reducers:{updateOptions:(e,t)=>{var n;e.accessibilityLayer=t.payload.accessibilityLayer,e.barCategoryGap=t.payload.barCategoryGap,e.barGap=(n=t.payload.barGap)!==null&&n!==void 0?n:sR.barGap,e.barSize=t.payload.barSize,e.maxBarSize=t.payload.maxBarSize,e.stackOffset=t.payload.stackOffset,e.syncId=t.payload.syncId,e.syncMethod=t.payload.syncMethod,e.className=t.payload.className,e.baseValue=t.payload.baseValue,e.reverseStackOrder=t.payload.reverseStackOrder}}}),lhe=x$.reducer,{updateOptions:uhe}=x$.actions,che=null,fhe={updatePolarOptions:(e,t)=>e===null?t.payload:(e.startAngle=t.payload.startAngle,e.endAngle=t.payload.endAngle,e.cx=t.payload.cx,e.cy=t.payload.cy,e.innerRadius=t.payload.innerRadius,e.outerRadius=t.payload.outerRadius,e)},w$=Wn({name:"polarOptions",initialState:che,reducers:fhe}),{updatePolarOptions:Vge}=w$.actions,dhe=w$.reducer,C$=Tr("keyDown"),S$=Tr("focus"),E$=Tr("blur"),ig=mc(),Qs=null,ja=null,xd=null;ig.startListening({actionCreator:C$,effect:(e,t)=>{xd=e.payload,Qs!==null&&(cancelAnimationFrame(Qs),Qs=null);var n=t.getState(),{throttleDelay:r,throttledEvents:i}=n.eventSettings,o=i==="all"||i.includes("keydown");ja!==null&&(typeof r!="number"||!o)&&(clearTimeout(ja),ja=null);var a=()=>{try{var s=t.getState(),u=s.rootProps.accessibilityLayer!==!1;if(!u)return;var{keyboardInteraction:c}=s.tooltip,d=xd;if(d!=="ArrowRight"&&d!=="ArrowLeft"&&d!=="Enter")return;var p=Lw(c,Ml(s),Ac(s),Ic(s)),g=p==null?-1:Number(p);if(!Number.isFinite(g)||g<0)return;var h=Oo(s);if(d==="Enter"){var v=Lp(s,"axis","hover",String(c.index));t.dispatch(jp({active:!c.active,activeIndex:c.index,activeCoordinate:v}));return}var b=Yae(s),y=b==="left-to-right"?1:-1,w=d==="ArrowRight"?1:-1,C=g+w*y;if(h==null||C>=h.length||C<0)return;var E=Lp(s,"axis","hover",String(C));t.dispatch(jp({active:!0,activeIndex:C.toString(),activeCoordinate:E}))}finally{Qs=null,ja=null}};if(!o){a();return}r==="raf"?Qs=requestAnimationFrame(a):typeof r=="number"&&ja===null&&(a(),xd=null,ja=setTimeout(()=>{xd?a():(ja=null,Qs=null)},r))}});ig.startListening({actionCreator:S$,effect:(e,t)=>{var n=t.getState(),r=n.rootProps.accessibilityLayer!==!1;if(r){var{keyboardInteraction:i}=n.tooltip;if(!i.active&&i.index==null){var o="0",a=Lp(n,"axis","hover",String(o));t.dispatch(jp({active:!0,activeIndex:o,activeCoordinate:a}))}}}});ig.startListening({actionCreator:E$,effect:(e,t)=>{var n=t.getState(),r=n.rootProps.accessibilityLayer!==!1;if(r){var{keyboardInteraction:i}=n.tooltip;i.active&&t.dispatch(jp({active:!1,activeIndex:i.index,activeCoordinate:i.coordinate}))}}});function _$(e){e.persist();var{currentTarget:t}=e;return new Proxy(e,{get:(n,r)=>{if(r==="currentTarget")return t;var i=Reflect.get(n,r);return typeof i=="function"?i.bind(n):i}})}var Kr=Tr("externalEvent"),O$=mc(),wd=new Map,xu=new Map,my=new Map;O$.startListening({actionCreator:Kr,effect:(e,t)=>{var{handler:n,reactEvent:r}=e.payload;if(n!=null){var i=r.type,o=_$(r);my.set(i,{handler:n,reactEvent:o});var a=wd.get(i);a!==void 0&&(cancelAnimationFrame(a),wd.delete(i));var s=t.getState(),{throttleDelay:u,throttledEvents:c}=s.eventSettings,d=c,p=d==="all"||d?.includes(i),g=xu.get(i);g!==void 0&&(typeof u!="number"||!p)&&(clearTimeout(g),xu.delete(i));var h=()=>{var y=my.get(i);try{if(!y)return;var{handler:w,reactEvent:C}=y,E=t.getState(),_={activeCoordinate:Zse(E),activeDataKey:CL(E),activeIndex:Sl(E),activeLabel:wL(E),activeTooltipIndex:Sl(E),isTooltipActive:Qse(E)};w&&w(_,C)}finally{wd.delete(i),xu.delete(i),my.delete(i)}};if(!p){h();return}if(u==="raf"){var v=requestAnimationFrame(h);wd.set(i,v)}else if(typeof u=="number"){if(!xu.has(i)){h();var b=setTimeout(h,u);xu.set(i,b)}}else h()}}});var phe=q([kl],e=>e.tooltipItemPayloads),hhe=q([phe,(e,t)=>t,(e,t,n)=>n],(e,t,n)=>{if(t!=null){var r=e.find(o=>o.settings.graphicalItemId===n);if(r!=null){var{getPosition:i}=r;if(i!=null)return i(t)}}}),P$=Tr("touchMove"),A$=mc(),La=null,zo=null,lR=null,wu=null;A$.startListening({actionCreator:P$,effect:(e,t)=>{var n=e.payload;if(!(n.touches==null||n.touches.length===0)){wu=_$(n);var r=t.getState(),{throttleDelay:i,throttledEvents:o}=r.eventSettings,a=o==="all"||o.includes("touchmove");La!==null&&(cancelAnimationFrame(La),La=null),zo!==null&&(typeof i!="number"||!a)&&(clearTimeout(zo),zo=null),lR=Array.from(n.touches).map(u=>Qw({clientX:u.clientX,clientY:u.clientY,currentTarget:n.currentTarget}));var s=()=>{if(wu!=null){var u=t.getState(),c=jw(u,u.tooltip.settings.shared);if(c==="axis"){var d,p=(d=lR)===null||d===void 0?void 0:d[0];if(p==null){La=null,zo=null;return}var g=Zw(u,p);g?.activeIndex!=null&&t.dispatch(uL({activeIndex:g.activeIndex,activeDataKey:void 0,activeCoordinate:g.activeCoordinate}))}else if(c==="item"){var h,v=wu.touches[0];if(document.elementFromPoint==null||v==null)return;var b=document.elementFromPoint(v.clientX,v.clientY);if(!b||!b.getAttribute)return;var y=b.getAttribute(pee),w=(h=b.getAttribute(hee))!==null&&h!==void 0?h:void 0,C=Nl(u).find(O=>O.id===w);if(y==null||C==null||w==null)return;var{dataKey:E}=C,_=hhe(u,y,w);t.dispatch(sL({activeDataKey:E,activeIndex:y,activeCoordinate:_,activeGraphicalItemId:w}))}La=null,zo=null}};if(!a){s();return}i==="raf"?La=requestAnimationFrame(s):typeof i=="number"&&zo===null&&(s(),wu=null,zo=setTimeout(()=>{wu?s():(zo=null,La=null)},i))}}});var R$={throttleDelay:"raf",throttledEvents:["mousemove","touchmove","pointermove","scroll","wheel"]},I$=Wn({name:"eventSettings",initialState:R$,reducers:{setEventSettings:(e,t)=>{t.payload.throttleDelay!=null&&(e.throttleDelay=t.payload.throttleDelay),t.payload.throttledEvents!=null&&(e.throttledEvents=t.payload.throttledEvents)}}}),{setEventSettings:ghe}=I$.actions,mhe=I$.reducer,vhe=sD({brush:kfe,cartesianAxis:bfe,chartData:Zle,errorBars:Tde,eventSettings:mhe,graphicalItems:ofe,layout:YJ,legend:ste,options:Gle,polarAxis:Cce,polarOptions:dhe,referenceElements:jfe,renderedTicks:Jfe,rootProps:lhe,tooltip:sse,zIndex:Nle}),yhe=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"Chart";return xJ({reducer:vhe,preloadedState:t,middleware:r=>{var i;return r({serializableCheck:!1,immutableCheck:!["commonjs","es6","production"].includes((i="es6")!==null&&i!==void 0?i:"")}).concat([y$.middleware,b$.middleware,ig.middleware,O$.middleware,A$.middleware])},enhancers:r=>{var i=r;return typeof r=="function"&&(i=r()),i.concat(OD({type:"raf"}))},devTools:{serialize:{replacer:she},name:"recharts-".concat(n)}})};function bhe(e){var{preloadedState:t,children:n,reduxStoreName:r}=e,i=pr(),o=j.useRef(null);if(i)return n;o.current==null&&(o.current=yhe(t,r));var a=Tx;return x.createElement(Ote,{context:a,store:o.current},n)}function xhe(e){var{layout:t,margin:n}=e,r=Ht(),i=pr();return j.useEffect(()=>{i||(r(GJ(t)),r(UJ(n)))},[r,i,t,n]),null}var whe=j.memo(xhe,Vh);function Che(e){var t=Ht();return j.useEffect(()=>{t(uhe(e))},[t,e]),null}var She=e=>{var t=Ht();return j.useEffect(()=>{t(ghe(e))},[t,e]),null},Ehe=j.memo(She,Vh);function uR(e){var{zIndex:t,isPanorama:n}=e,r=j.useRef(null),i=Ht();return j.useLayoutEffect(()=>(r.current&&i(Tle({zIndex:t,element:r.current,isPanorama:n})),()=>{i(kle({zIndex:t,isPanorama:n}))}),[i,t,n]),x.createElement("g",{tabIndex:-1,ref:r,className:"recharts-zIndex-layer_".concat(t)})}function cR(e){var{children:t,isPanorama:n}=e,r=Le(wle);if(!r||r.length===0)return t;var i=r.filter(a=>a<0),o=r.filter(a=>a>0);return x.createElement(x.Fragment,null,i.map(a=>x.createElement(uR,{key:a,zIndex:a,isPanorama:n})),t,o.map(a=>x.createElement(uR,{key:a,zIndex:a,isPanorama:n})))}var _he=["children"];function Ohe(e,t){if(e==null)return{};var n,r,i=Phe(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Phe(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function Wp(){return Wp=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Wp.apply(null,arguments)}var Ahe={width:"100%",height:"100%",display:"block"},Rhe=j.forwardRef((e,t)=>{var n=KD(),r=YD(),i=aj();if(!Li(n)||!Li(r))return null;var{children:o,otherAttributes:a,title:s,desc:u}=e,c,d;return a!=null&&(typeof a.tabIndex=="number"?c=a.tabIndex:c=i?0:void 0,typeof a.role=="string"?d=a.role:d=i?"application":void 0),x.createElement(OM,Wp({},a,{title:s,desc:u,role:d,tabIndex:c,width:n,height:r,style:Ahe,ref:t}),o)}),Ihe=e=>{var{children:t}=e,n=Le(Dh);if(!n)return null;var{width:r,height:i,y:o,x:a}=n;return x.createElement(OM,{width:r,height:i,x:a,y:o},t)},fR=j.forwardRef((e,t)=>{var{children:n}=e,r=Ohe(e,_he),i=pr();return i?x.createElement(Ihe,null,x.createElement(cR,{isPanorama:!0},n)):x.createElement(Rhe,Wp({ref:t},r),x.createElement(cR,{isPanorama:!1},n))});function The(){var e=Ht(),[t,n]=j.useState(null),r=Le(dee);return j.useEffect(()=>{if(t!=null){var i=t.getBoundingClientRect(),o=i.width/t.offsetWidth;ct(o)&&o!==r&&e(KJ(o))}},[t,e,r]),n}function dR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function khe(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?dR(Object(n),!0).forEach(function(r){Nhe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):dR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Nhe(e,t,n){return(t=Mhe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Mhe(e){var t=Dhe(e,"string");return typeof t=="symbol"?t:t+""}function Dhe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ra(){return ra=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ra.apply(null,arguments)}var jhe=()=>(aue(),null);function Hp(e){if(typeof e=="number")return e;if(typeof e=="string"){var t=parseFloat(e);if(!Number.isNaN(t))return t}return 0}var Lhe=j.forwardRef((e,t)=>{var n,r,i=j.useRef(null),[o,a]=j.useState({containerWidth:Hp((n=e.style)===null||n===void 0?void 0:n.width),containerHeight:Hp((r=e.style)===null||r===void 0?void 0:r.height)}),s=j.useCallback((c,d)=>{a(p=>{var g=Math.round(c),h=Math.round(d);return p.containerWidth===g&&p.containerHeight===h?p:{containerWidth:g,containerHeight:h}})},[]),u=j.useCallback(c=>{if(typeof t=="function"&&t(c),c!=null&&typeof ResizeObserver<"u"){var{width:d,height:p}=c.getBoundingClientRect();s(d,p);var g=v=>{var b=v[0];if(b!=null){var{width:y,height:w}=b.contentRect;s(y,w)}},h=new ResizeObserver(g);h.observe(c),i.current=h}},[t,s]);return j.useEffect(()=>()=>{var c=i.current;c?.disconnect()},[s]),x.createElement(x.Fragment,null,x.createElement(yc,{width:o.containerWidth,height:o.containerHeight}),x.createElement("div",ra({ref:u},e)))}),$he=j.forwardRef((e,t)=>{var{width:n,height:r}=e,[i,o]=j.useState({containerWidth:Hp(n),containerHeight:Hp(r)}),a=j.useCallback((u,c)=>{o(d=>{var p=Math.round(u),g=Math.round(c);return d.containerWidth===p&&d.containerHeight===g?d:{containerWidth:p,containerHeight:g}})},[]),s=j.useCallback(u=>{if(typeof t=="function"&&t(u),u!=null){var{width:c,height:d}=u.getBoundingClientRect();a(c,d)}},[t,a]);return x.createElement(x.Fragment,null,x.createElement(yc,{width:i.containerWidth,height:i.containerHeight}),x.createElement("div",ra({ref:s},e)))}),Fhe=j.forwardRef((e,t)=>{var{width:n,height:r}=e;return x.createElement(x.Fragment,null,x.createElement(yc,{width:n,height:r}),x.createElement("div",ra({ref:t},e)))}),Vhe=j.forwardRef((e,t)=>{var{width:n,height:r}=e;return typeof n=="string"||typeof r=="string"?x.createElement($he,ra({},e,{ref:t})):typeof n=="number"&&typeof r=="number"?x.createElement(Fhe,ra({},e,{width:n,height:r,ref:t})):x.createElement(x.Fragment,null,x.createElement(yc,{width:n,height:r}),x.createElement("div",ra({ref:t},e)))});function Bhe(e){return e?Lhe:Vhe}var zhe=j.forwardRef((e,t)=>{var{children:n,className:r,height:i,onClick:o,onContextMenu:a,onDoubleClick:s,onMouseDown:u,onMouseEnter:c,onMouseLeave:d,onMouseMove:p,onMouseUp:g,onTouchEnd:h,onTouchMove:v,onTouchStart:b,style:y,width:w,responsive:C,dispatchTouchEvents:E=!0}=e,_=j.useRef(null),O=Ht(),[R,I]=j.useState(null),[k,B]=j.useState(null),L=The(),V=Fx(),D=V?.width>0?V.width:w,H=V?.height>0?V.height:i,J=j.useCallback(oe=>{L(oe),typeof t=="function"&&t(oe),I(oe),B(oe),oe!=null&&(_.current=oe)},[L,t,I,B]),te=j.useCallback(oe=>{O(v$(oe)),O(Kr({handler:o,reactEvent:oe}))},[O,o]),G=j.useCallback(oe=>{O(Ub(oe)),O(Kr({handler:c,reactEvent:oe}))},[O,c]),ee=j.useCallback(oe=>{O(lL()),O(Kr({handler:d,reactEvent:oe}))},[O,d]),Q=j.useCallback(oe=>{O(Ub(oe)),O(Kr({handler:p,reactEvent:oe}))},[O,p]),pe=j.useCallback(()=>{O(S$())},[O]),K=j.useCallback(()=>{O(E$())},[O]),Ae=j.useCallback(oe=>{O(C$(oe.key))},[O]),Se=j.useCallback(oe=>{O(Kr({handler:a,reactEvent:oe}))},[O,a]),$e=j.useCallback(oe=>{O(Kr({handler:s,reactEvent:oe}))},[O,s]),we=j.useCallback(oe=>{O(Kr({handler:u,reactEvent:oe}))},[O,u]),Ce=j.useCallback(oe=>{O(Kr({handler:g,reactEvent:oe}))},[O,g]),ze=j.useCallback(oe=>{O(Kr({handler:b,reactEvent:oe}))},[O,b]),Ke=j.useCallback(oe=>{E&&O(P$(oe)),O(Kr({handler:v,reactEvent:oe}))},[O,E,v]),Fe=j.useCallback(oe=>{O(Kr({handler:h,reactEvent:oe}))},[O,h]),Y=Bhe(C);return x.createElement(RL.Provider,{value:R},x.createElement(eZ.Provider,{value:k},x.createElement(Y,{width:D??y?.width,height:H??y?.height,className:Pt("recharts-wrapper",r),style:khe({position:"relative",cursor:"default",width:D,height:H},y),onClick:te,onContextMenu:Se,onDoubleClick:$e,onFocus:pe,onBlur:K,onKeyDown:Ae,onMouseDown:we,onMouseEnter:G,onMouseLeave:ee,onMouseMove:Q,onMouseUp:Ce,onTouchEnd:Fe,onTouchMove:Ke,onTouchStart:ze,ref:J},x.createElement(jhe,null),n)))}),Whe=["width","height","responsive","children","className","style","compact","title","desc"];function Hhe(e,t){if(e==null)return{};var n,r,i=Uhe(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Uhe(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var Ghe=j.forwardRef((e,t)=>{var{width:n,height:r,responsive:i,children:o,className:a,style:s,compact:u,title:c,desc:d}=e,p=Hhe(e,Whe),g=fo(p);return u?x.createElement(x.Fragment,null,x.createElement(yc,{width:n,height:r}),x.createElement(fR,{otherAttributes:g,title:c,desc:d},o)):x.createElement(zhe,{className:a,style:s,width:n,height:r,responsive:i??!1,onClick:e.onClick,onMouseLeave:e.onMouseLeave,onMouseEnter:e.onMouseEnter,onMouseMove:e.onMouseMove,onMouseDown:e.onMouseDown,onMouseUp:e.onMouseUp,onContextMenu:e.onContextMenu,onDoubleClick:e.onDoubleClick,onTouchStart:e.onTouchStart,onTouchMove:e.onTouchMove,onTouchEnd:e.onTouchEnd},x.createElement(fR,{otherAttributes:g,title:c,desc:d,ref:t},x.createElement($fe,null,o)))});function Gb(){return Gb=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Gb.apply(null,arguments)}function pR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function qhe(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?pR(Object(n),!0).forEach(function(r){Khe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Khe(e,t,n){return(t=Yhe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Yhe(e){var t=Xhe(e,"string");return typeof t=="symbol"?t:t+""}function Xhe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Zhe={top:5,right:5,bottom:5,left:5},Qhe=qhe({accessibilityLayer:!0,barCategoryGap:"10%",barGap:4,layout:"horizontal",margin:Zhe,responsive:!1,reverseStackOrder:!1,stackOffset:"none",syncMethod:"index"},R$),Jhe=j.forwardRef(function(t,n){var r,i=Mr(t.categoricalChartProps,Qhe),{chartName:o,defaultTooltipEventType:a,validateTooltipEventTypes:s,tooltipPayloadSearcher:u,categoricalChartProps:c}=t,d={chartName:o,defaultTooltipEventType:a,validateTooltipEventTypes:s,tooltipPayloadSearcher:u,eventEmitter:void 0};return x.createElement(bhe,{preloadedState:{options:d},reduxStoreName:(r=c.id)!==null&&r!==void 0?r:o},x.createElement(Tfe,{chartData:c.data}),x.createElement(whe,{layout:i.layout,margin:i.margin}),x.createElement(Ehe,{throttleDelay:i.throttleDelay,throttledEvents:i.throttledEvents}),x.createElement(Che,{baseValue:i.baseValue,accessibilityLayer:i.accessibilityLayer,barCategoryGap:i.barCategoryGap,maxBarSize:i.maxBarSize,stackOffset:i.stackOffset,barGap:i.barGap,barSize:i.barSize,syncId:i.syncId,syncMethod:i.syncMethod,className:i.className,reverseStackOrder:i.reverseStackOrder}),x.createElement(Ghe,Gb({},i,{ref:n})))}),ege=["axis","item"],tge=j.forwardRef((e,t)=>x.createElement(Jhe,{chartName:"BarChart",defaultTooltipEventType:"axis",validateTooltipEventTypes:ege,tooltipPayloadSearcher:Hle,categoricalChartProps:e,ref:t}));const nge={light:"",dark:".dark"},T$=x.createContext(null);function rge(){const e=x.useContext(T$);if(!e)throw new Error("useChart must be used within a <ChartContainer />");return e}function ige({id:e,className:t,children:n,config:r,...i}){const o=x.useId(),a=`chart-${e||o.replace(/:/g,"")}`;return P.jsx(T$.Provider,{value:{config:r},children:P.jsxs("div",{"data-slot":"chart","data-chart":a,className:ue(`[&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground
|
|
254
|
+
A`,",",",0,0,",",",",","Z"])),I.x,I.y,o,o,+(f<0),R.x,R.y,r,r,+(B>180),+(f>0),E.x,E.y,o,o,+(f<0),_.x,_.y)}else S+=Kt(xP||(xP=Ka(["L",",","Z"])),t,n);return S},Uie={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},b2=e=>{var t=Dr(e,Uie),{cx:n,cy:r,innerRadius:i,outerRadius:o,cornerRadius:a,forceCornerRadius:s,cornerIsExternal:u,startAngle:c,endAngle:f,className:p}=t;if(o<i||c===f)return null;var g=At("recharts-sector",p),h=o-i,v=pi(a,h,0,!0),b;return v>0&&Math.abs(c-f)<360?b=Hie({cx:n,cy:r,innerRadius:i,outerRadius:o,cornerRadius:Math.min(v,h/2),forceCornerRadius:s,cornerIsExternal:u,startAngle:c,endAngle:f}):b=y2({cx:n,cy:r,innerRadius:i,outerRadius:o,startAngle:c,endAngle:f}),x.createElement("path",Gb({},ni(t),{className:g,d:b}))};function Gie(e,t,n){if(e==="horizontal")return[{x:t.x,y:n.top},{x:t.x,y:n.top+n.height}];if(e==="vertical")return[{x:n.left,y:t.y},{x:n.left+n.width,y:t.y}];if(ZD(t)){if(e==="centric"){var{cx:r,cy:i,innerRadius:o,outerRadius:a,angle:s}=t,u=kn(r,i,o,s),c=kn(r,i,a,s);return[{x:u.x,y:u.y},{x:c.x,y:c.y}]}return v2(t)}}var dy={},py={},hy={},wP;function qie(){return wP||(wP=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=sj();function n(r){return t.isSymbol(r)?NaN:Number(r)}e.toNumber=n})(hy)),hy}var SP;function Kie(){return SP||(SP=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=qie();function n(r){return r?(r=t.toNumber(r),r===1/0||r===-1/0?(r<0?-1:1)*Number.MAX_VALUE:r===r?r:0):r===0?r:0}e.toFinite=n})(py)),py}var CP;function Yie(){return CP||(CP=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=lj(),n=Kie();function r(i,o,a){a&&typeof a!="number"&&t.isIterateeCall(i,o,a)&&(o=a=void 0),i=n.toFinite(i),o===void 0?(o=i,i=0):o=n.toFinite(o),a=a===void 0?i<o?1:-1:n.toFinite(a);const s=Math.max(Math.ceil((o-i)/(a||1)),0),u=new Array(s);for(let c=0;c<s;c++)u[c]=i,i+=a;return u}e.range=r})(dy)),dy}var gy,EP;function Xie(){return EP||(EP=1,gy=Yie().range),gy}var Zie=Xie();const x2=vs(Zie);var Po=e=>e.chartData,w2=K([Po],e=>{var t=e.chartData!=null?e.chartData.length-1:0;return{chartData:e.chartData,computedData:e.computedData,dataEndIndex:t,dataStartIndex:0}}),S2=(e,t,n,r)=>r?w2(e):Po(e),Qie=(e,t,n)=>n?w2(e):Po(e);function Mi(e){if(Array.isArray(e)&&e.length===2){var[t,n]=e;if(dt(t)&&dt(n))return!0}return!1}function _P(e,t,n){return n?e:[Math.min(e[0],t[0]),Math.max(e[1],t[1])]}function C2(e,t){if(t&&typeof e!="function"&&Array.isArray(e)&&e.length===2){var[n,r]=e,i,o;if(dt(n))i=n;else if(typeof n=="function")return;if(dt(r))o=r;else if(typeof r=="function")return;var a=[i,o];if(Mi(a))return a}}function Jie(e,t,n){if(!(!n&&t==null)){if(typeof e=="function"&&t!=null)try{var r=e(t,n);if(Mi(r))return _P(r,t,n)}catch{}if(Array.isArray(e)&&e.length===2){var[i,o]=e,a,s;if(i==="auto")t!=null&&(a=Math.min(...t));else if(Ne(i))a=i;else if(typeof i=="function")try{t!=null&&(a=i(t?.[0]))}catch{}else if(typeof i=="string"&&gO.test(i)){var u=gO.exec(i);if(u==null||u[1]==null||t==null)a=void 0;else{var c=+u[1];a=t[0]-c}}else a=t?.[0];if(o==="auto")t!=null&&(s=Math.max(...t));else if(Ne(o))s=o;else if(typeof o=="function")try{t!=null&&(s=o(t?.[1]))}catch{}else if(typeof o=="string"&&mO.test(o)){var f=mO.exec(o);if(f==null||f[1]==null||t==null)s=void 0;else{var p=+f[1];s=t[1]+p}}else s=t?.[1];var g=[a,s];if(Mi(g))return t==null?g:_P(g,t,n)}}}var kl=1e9,eoe={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},dw,Bt=!0,ri="[DecimalError] ",es=ri+"Invalid argument: ",fw=ri+"Exponent out of range: ",Nl=Math.floor,Ga=Math.pow,toe=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,Pr,xn=1e7,jt=7,E2=9007199254740991,Ip=Nl(E2/jt),Re={};Re.absoluteValue=Re.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e};Re.comparedTo=Re.cmp=function(e){var t,n,r,i,o=this;if(e=new o.constructor(e),o.s!==e.s)return o.s||-e.s;if(o.e!==e.e)return o.e>e.e^o.s<0?1:-1;for(r=o.d.length,i=e.d.length,t=0,n=r<i?r:i;t<n;++t)if(o.d[t]!==e.d[t])return o.d[t]>e.d[t]^o.s<0?1:-1;return r===i?0:r>i^o.s<0?1:-1};Re.decimalPlaces=Re.dp=function(){var e=this,t=e.d.length-1,n=(t-e.e)*jt;if(t=e.d[t],t)for(;t%10==0;t/=10)n--;return n<0?0:n};Re.dividedBy=Re.div=function(e){return po(this,new this.constructor(e))};Re.dividedToIntegerBy=Re.idiv=function(e){var t=this,n=t.constructor;return Pt(po(t,new n(e),0,1),n.precision)};Re.equals=Re.eq=function(e){return!this.cmp(e)};Re.exponent=function(){return rn(this)};Re.greaterThan=Re.gt=function(e){return this.cmp(e)>0};Re.greaterThanOrEqualTo=Re.gte=function(e){return this.cmp(e)>=0};Re.isInteger=Re.isint=function(){return this.e>this.d.length-2};Re.isNegative=Re.isneg=function(){return this.s<0};Re.isPositive=Re.ispos=function(){return this.s>0};Re.isZero=function(){return this.s===0};Re.lessThan=Re.lt=function(e){return this.cmp(e)<0};Re.lessThanOrEqualTo=Re.lte=function(e){return this.cmp(e)<1};Re.logarithm=Re.log=function(e){var t,n=this,r=n.constructor,i=r.precision,o=i+5;if(e===void 0)e=new r(10);else if(e=new r(e),e.s<1||e.eq(Pr))throw Error(ri+"NaN");if(n.s<1)throw Error(ri+(n.s?"NaN":"-Infinity"));return n.eq(Pr)?new r(0):(Bt=!1,t=po(ic(n,o),ic(e,o),o),Bt=!0,Pt(t,i))};Re.minus=Re.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?P2(t,e):_2(t,(e.s=-e.s,e))};Re.modulo=Re.mod=function(e){var t,n=this,r=n.constructor,i=r.precision;if(e=new r(e),!e.s)throw Error(ri+"NaN");return n.s?(Bt=!1,t=po(n,e,0,1).times(e),Bt=!0,n.minus(t)):Pt(new r(n),i)};Re.naturalExponential=Re.exp=function(){return O2(this)};Re.naturalLogarithm=Re.ln=function(){return ic(this)};Re.negated=Re.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};Re.plus=Re.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?_2(t,e):P2(t,(e.s=-e.s,e))};Re.precision=Re.sd=function(e){var t,n,r,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(es+e);if(t=rn(i)+1,r=i.d.length-1,n=r*jt+1,r=i.d[r],r){for(;r%10==0;r/=10)n--;for(r=i.d[0];r>=10;r/=10)n++}return e&&t>n?t:n};Re.squareRoot=Re.sqrt=function(){var e,t,n,r,i,o,a,s=this,u=s.constructor;if(s.s<1){if(!s.s)return new u(0);throw Error(ri+"NaN")}for(e=rn(s),Bt=!1,i=Math.sqrt(+s),i==0||i==1/0?(t=ki(s.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=Nl((e+1)/2)-(e<0||e%2),i==1/0?t="5e"+e:(t=i.toExponential(),t=t.slice(0,t.indexOf("e")+1)+e),r=new u(t)):r=new u(i.toString()),n=u.precision,i=a=n+3;;)if(o=r,r=o.plus(po(s,o,a+2)).times(.5),ki(o.d).slice(0,a)===(t=ki(r.d)).slice(0,a)){if(t=t.slice(a-3,a+1),i==a&&t=="4999"){if(Pt(o,n+1,0),o.times(o).eq(s)){r=o;break}}else if(t!="9999")break;a+=4}return Bt=!0,Pt(r,n)};Re.times=Re.mul=function(e){var t,n,r,i,o,a,s,u,c,f=this,p=f.constructor,g=f.d,h=(e=new p(e)).d;if(!f.s||!e.s)return new p(0);for(e.s*=f.s,n=f.e+e.e,u=g.length,c=h.length,u<c&&(o=g,g=h,h=o,a=u,u=c,c=a),o=[],a=u+c,r=a;r--;)o.push(0);for(r=c;--r>=0;){for(t=0,i=u+r;i>r;)s=o[i]+h[r]*g[i-r-1]+t,o[i--]=s%xn|0,t=s/xn|0;o[i]=(o[i]+t)%xn|0}for(;!o[--a];)o.pop();return t?++n:o.shift(),e.d=o,e.e=n,Bt?Pt(e,p.precision):e};Re.toDecimalPlaces=Re.todp=function(e,t){var n=this,r=n.constructor;return n=new r(n),e===void 0?n:(zi(e,0,kl),t===void 0?t=r.rounding:zi(t,0,8),Pt(n,e+rn(n)+1,t))};Re.toExponential=function(e,t){var n,r=this,i=r.constructor;return e===void 0?n=ps(r,!0):(zi(e,0,kl),t===void 0?t=i.rounding:zi(t,0,8),r=Pt(new i(r),e+1,t),n=ps(r,!0,e+1)),n};Re.toFixed=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?ps(i):(zi(e,0,kl),t===void 0?t=o.rounding:zi(t,0,8),r=Pt(new o(i),e+rn(i)+1,t),n=ps(r.abs(),!1,e+rn(r)+1),i.isneg()&&!i.isZero()?"-"+n:n)};Re.toInteger=Re.toint=function(){var e=this,t=e.constructor;return Pt(new t(e),rn(e)+1,t.rounding)};Re.toNumber=function(){return+this};Re.toPower=Re.pow=function(e){var t,n,r,i,o,a,s=this,u=s.constructor,c=12,f=+(e=new u(e));if(!e.s)return new u(Pr);if(s=new u(s),!s.s){if(e.s<1)throw Error(ri+"Infinity");return s}if(s.eq(Pr))return s;if(r=u.precision,e.eq(Pr))return Pt(s,r);if(t=e.e,n=e.d.length-1,a=t>=n,o=s.s,a){if((n=f<0?-f:f)<=E2){for(i=new u(Pr),t=Math.ceil(r/jt+4),Bt=!1;n%2&&(i=i.times(s),PP(i.d,t)),n=Nl(n/2),n!==0;)s=s.times(s),PP(s.d,t);return Bt=!0,e.s<0?new u(Pr).div(i):Pt(i,r)}}else if(o<0)throw Error(ri+"NaN");return o=o<0&&e.d[Math.max(t,n)]&1?-1:1,s.s=1,Bt=!1,i=e.times(ic(s,r+c)),Bt=!0,i=O2(i),i.s=o,i};Re.toPrecision=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?(n=rn(i),r=ps(i,n<=o.toExpNeg||n>=o.toExpPos)):(zi(e,1,kl),t===void 0?t=o.rounding:zi(t,0,8),i=Pt(new o(i),e,t),n=rn(i),r=ps(i,e<=n||n<=o.toExpNeg,e)),r};Re.toSignificantDigits=Re.tosd=function(e,t){var n=this,r=n.constructor;return e===void 0?(e=r.precision,t=r.rounding):(zi(e,1,kl),t===void 0?t=r.rounding:zi(t,0,8)),Pt(new r(n),e,t)};Re.toString=Re.valueOf=Re.val=Re.toJSON=Re[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=rn(e),n=e.constructor;return ps(e,t<=n.toExpNeg||t>=n.toExpPos)};function _2(e,t){var n,r,i,o,a,s,u,c,f=e.constructor,p=f.precision;if(!e.s||!t.s)return t.s||(t=new f(e)),Bt?Pt(t,p):t;if(u=e.d,c=t.d,a=e.e,i=t.e,u=u.slice(),o=a-i,o){for(o<0?(r=u,o=-o,s=c.length):(r=c,i=a,s=u.length),a=Math.ceil(p/jt),s=a>s?a+1:s+1,o>s&&(o=s,r.length=1),r.reverse();o--;)r.push(0);r.reverse()}for(s=u.length,o=c.length,s-o<0&&(o=s,r=c,c=u,u=r),n=0;o;)n=(u[--o]=u[o]+c[o]+n)/xn|0,u[o]%=xn;for(n&&(u.unshift(n),++i),s=u.length;u[--s]==0;)u.pop();return t.d=u,t.e=i,Bt?Pt(t,p):t}function zi(e,t,n){if(e!==~~e||e<t||e>n)throw Error(es+e)}function ki(e){var t,n,r,i=e.length-1,o="",a=e[0];if(i>0){for(o+=a,t=1;t<i;t++)r=e[t]+"",n=jt-r.length,n&&(o+=Zo(n)),o+=r;a=e[t],r=a+"",n=jt-r.length,n&&(o+=Zo(n))}else if(a===0)return"0";for(;a%10===0;)a/=10;return o+a}var po=(function(){function e(r,i){var o,a=0,s=r.length;for(r=r.slice();s--;)o=r[s]*i+a,r[s]=o%xn|0,a=o/xn|0;return a&&r.unshift(a),r}function t(r,i,o,a){var s,u;if(o!=a)u=o>a?1:-1;else for(s=u=0;s<o;s++)if(r[s]!=i[s]){u=r[s]>i[s]?1:-1;break}return u}function n(r,i,o){for(var a=0;o--;)r[o]-=a,a=r[o]<i[o]?1:0,r[o]=a*xn+r[o]-i[o];for(;!r[0]&&r.length>1;)r.shift()}return function(r,i,o,a){var s,u,c,f,p,g,h,v,b,y,w,S,E,_,P,R,I,k,B=r.constructor,L=r.s==i.s?1:-1,V=r.d,D=i.d;if(!r.s)return new B(r);if(!i.s)throw Error(ri+"Division by zero");for(u=r.e-i.e,I=D.length,P=V.length,h=new B(L),v=h.d=[],c=0;D[c]==(V[c]||0);)++c;if(D[c]>(V[c]||0)&&--u,o==null?S=o=B.precision:a?S=o+(rn(r)-rn(i))+1:S=o,S<0)return new B(0);if(S=S/jt+2|0,c=0,I==1)for(f=0,D=D[0],S++;(c<P||f)&&S--;c++)E=f*xn+(V[c]||0),v[c]=E/D|0,f=E%D|0;else{for(f=xn/(D[0]+1)|0,f>1&&(D=e(D,f),V=e(V,f),I=D.length,P=V.length),_=I,b=V.slice(0,I),y=b.length;y<I;)b[y++]=0;k=D.slice(),k.unshift(0),R=D[0],D[1]>=xn/2&&++R;do f=0,s=t(D,b,I,y),s<0?(w=b[0],I!=y&&(w=w*xn+(b[1]||0)),f=w/R|0,f>1?(f>=xn&&(f=xn-1),p=e(D,f),g=p.length,y=b.length,s=t(p,b,g,y),s==1&&(f--,n(p,I<g?k:D,g))):(f==0&&(s=f=1),p=D.slice()),g=p.length,g<y&&p.unshift(0),n(b,p,y),s==-1&&(y=b.length,s=t(D,b,I,y),s<1&&(f++,n(b,I<y?k:D,y))),y=b.length):s===0&&(f++,b=[0]),v[c++]=f,s&&b[0]?b[y++]=V[_]||0:(b=[V[_]],y=1);while((_++<P||b[0]!==void 0)&&S--)}return v[0]||v.shift(),h.e=u,Pt(h,a?o+rn(h)+1:o)}})();function O2(e,t){var n,r,i,o,a,s,u=0,c=0,f=e.constructor,p=f.precision;if(rn(e)>16)throw Error(fw+rn(e));if(!e.s)return new f(Pr);for(Bt=!1,s=p,a=new f(.03125);e.abs().gte(.1);)e=e.times(a),c+=5;for(r=Math.log(Ga(2,c))/Math.LN10*2+5|0,s+=r,n=i=o=new f(Pr),f.precision=s;;){if(i=Pt(i.times(e),s),n=n.times(++u),a=o.plus(po(i,n,s)),ki(a.d).slice(0,s)===ki(o.d).slice(0,s)){for(;c--;)o=Pt(o.times(o),s);return f.precision=p,t==null?(Bt=!0,Pt(o,p)):o}o=a}}function rn(e){for(var t=e.e*jt,n=e.d[0];n>=10;n/=10)t++;return t}function my(e,t,n){if(t>e.LN10.sd())throw Bt=!0,n&&(e.precision=n),Error(ri+"LN10 precision limit exceeded");return Pt(new e(e.LN10),t)}function Zo(e){for(var t="";e--;)t+="0";return t}function ic(e,t){var n,r,i,o,a,s,u,c,f,p=1,g=10,h=e,v=h.d,b=h.constructor,y=b.precision;if(h.s<1)throw Error(ri+(h.s?"NaN":"-Infinity"));if(h.eq(Pr))return new b(0);if(t==null?(Bt=!1,c=y):c=t,h.eq(10))return t==null&&(Bt=!0),my(b,c);if(c+=g,b.precision=c,n=ki(v),r=n.charAt(0),o=rn(h),Math.abs(o)<15e14){for(;r<7&&r!=1||r==1&&n.charAt(1)>3;)h=h.times(e),n=ki(h.d),r=n.charAt(0),p++;o=rn(h),r>1?(h=new b("0."+n),o++):h=new b(r+"."+n.slice(1))}else return u=my(b,c+2,y).times(o+""),h=ic(new b(r+"."+n.slice(1)),c-g).plus(u),b.precision=y,t==null?(Bt=!0,Pt(h,y)):h;for(s=a=h=po(h.minus(Pr),h.plus(Pr),c),f=Pt(h.times(h),c),i=3;;){if(a=Pt(a.times(f),c),u=s.plus(po(a,new b(i),c)),ki(u.d).slice(0,c)===ki(s.d).slice(0,c))return s=s.times(2),o!==0&&(s=s.plus(my(b,c+2,y).times(o+""))),s=po(s,new b(p),c),b.precision=y,t==null?(Bt=!0,Pt(s,y)):s;s=u,i+=2}}function OP(e,t){var n,r,i;for((n=t.indexOf("."))>-1&&(t=t.replace(".","")),(r=t.search(/e/i))>0?(n<0&&(n=r),n+=+t.slice(r+1),t=t.substring(0,r)):n<0&&(n=t.length),r=0;t.charCodeAt(r)===48;)++r;for(i=t.length;t.charCodeAt(i-1)===48;)--i;if(t=t.slice(r,i),t){if(i-=r,n=n-r-1,e.e=Nl(n/jt),e.d=[],r=(n+1)%jt,n<0&&(r+=jt),r<i){for(r&&e.d.push(+t.slice(0,r)),i-=jt;r<i;)e.d.push(+t.slice(r,r+=jt));t=t.slice(r),r=jt-t.length}else r-=i;for(;r--;)t+="0";if(e.d.push(+t),Bt&&(e.e>Ip||e.e<-Ip))throw Error(fw+n)}else e.s=0,e.e=0,e.d=[0];return e}function Pt(e,t,n){var r,i,o,a,s,u,c,f,p=e.d;for(a=1,o=p[0];o>=10;o/=10)a++;if(r=t-a,r<0)r+=jt,i=t,c=p[f=0];else{if(f=Math.ceil((r+1)/jt),o=p.length,f>=o)return e;for(c=o=p[f],a=1;o>=10;o/=10)a++;r%=jt,i=r-jt+a}if(n!==void 0&&(o=Ga(10,a-i-1),s=c/o%10|0,u=t<0||p[f+1]!==void 0||c%o,u=n<4?(s||u)&&(n==0||n==(e.s<0?3:2)):s>5||s==5&&(n==4||u||n==6&&(r>0?i>0?c/Ga(10,a-i):0:p[f-1])%10&1||n==(e.s<0?8:7))),t<1||!p[0])return u?(o=rn(e),p.length=1,t=t-o-1,p[0]=Ga(10,(jt-t%jt)%jt),e.e=Nl(-t/jt)||0):(p.length=1,p[0]=e.e=e.s=0),e;if(r==0?(p.length=f,o=1,f--):(p.length=f+1,o=Ga(10,jt-r),p[f]=i>0?(c/Ga(10,a-i)%Ga(10,i)|0)*o:0),u)for(;;)if(f==0){(p[0]+=o)==xn&&(p[0]=1,++e.e);break}else{if(p[f]+=o,p[f]!=xn)break;p[f--]=0,o=1}for(r=p.length;p[--r]===0;)p.pop();if(Bt&&(e.e>Ip||e.e<-Ip))throw Error(fw+rn(e));return e}function P2(e,t){var n,r,i,o,a,s,u,c,f,p,g=e.constructor,h=g.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new g(e),Bt?Pt(t,h):t;if(u=e.d,p=t.d,r=t.e,c=e.e,u=u.slice(),a=c-r,a){for(f=a<0,f?(n=u,a=-a,s=p.length):(n=p,r=c,s=u.length),i=Math.max(Math.ceil(h/jt),s)+2,a>i&&(a=i,n.length=1),n.reverse(),i=a;i--;)n.push(0);n.reverse()}else{for(i=u.length,s=p.length,f=i<s,f&&(s=i),i=0;i<s;i++)if(u[i]!=p[i]){f=u[i]<p[i];break}a=0}for(f&&(n=u,u=p,p=n,t.s=-t.s),s=u.length,i=p.length-s;i>0;--i)u[s++]=0;for(i=p.length;i>a;){if(u[--i]<p[i]){for(o=i;o&&u[--o]===0;)u[o]=xn-1;--u[o],u[i]+=xn}u[i]-=p[i]}for(;u[--s]===0;)u.pop();for(;u[0]===0;u.shift())--r;return u[0]?(t.d=u,t.e=r,Bt?Pt(t,h):t):new g(0)}function ps(e,t,n){var r,i=rn(e),o=ki(e.d),a=o.length;return t?(n&&(r=n-a)>0?o=o.charAt(0)+"."+o.slice(1)+Zo(r):a>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(i<0?"e":"e+")+i):i<0?(o="0."+Zo(-i-1)+o,n&&(r=n-a)>0&&(o+=Zo(r))):i>=a?(o+=Zo(i+1-a),n&&(r=n-i-1)>0&&(o=o+"."+Zo(r))):((r=i+1)<a&&(o=o.slice(0,r)+"."+o.slice(r)),n&&(r=n-a)>0&&(i+1===a&&(o+="."),o+=Zo(r))),e.s<0?"-"+o:o}function PP(e,t){if(e.length>t)return e.length=t,!0}function A2(e){var t,n,r;function i(o){var a=this;if(!(a instanceof i))return new i(o);if(a.constructor=i,o instanceof i){a.s=o.s,a.e=o.e,a.d=(o=o.d)?o.slice():o;return}if(typeof o=="number"){if(o*0!==0)throw Error(es+o);if(o>0)a.s=1;else if(o<0)o=-o,a.s=-1;else{a.s=0,a.e=0,a.d=[0];return}if(o===~~o&&o<1e7){a.e=0,a.d=[o];return}return OP(a,o.toString())}else if(typeof o!="string")throw Error(es+o);if(o.charCodeAt(0)===45?(o=o.slice(1),a.s=-1):a.s=1,toe.test(o))OP(a,o);else throw Error(es+o)}if(i.prototype=Re,i.ROUND_UP=0,i.ROUND_DOWN=1,i.ROUND_CEIL=2,i.ROUND_FLOOR=3,i.ROUND_HALF_UP=4,i.ROUND_HALF_DOWN=5,i.ROUND_HALF_EVEN=6,i.ROUND_HALF_CEIL=7,i.ROUND_HALF_FLOOR=8,i.clone=A2,i.config=i.set=noe,e===void 0&&(e={}),e)for(r=["precision","rounding","toExpNeg","toExpPos","LN10"],t=0;t<r.length;)e.hasOwnProperty(n=r[t++])||(e[n]=this[n]);return i.config(e),i}function noe(e){if(!e||typeof e!="object")throw Error(ri+"Object expected");var t,n,r,i=["precision",1,kl,"rounding",0,8,"toExpNeg",-1/0,0,"toExpPos",0,1/0];for(t=0;t<i.length;t+=3)if((r=e[n=i[t]])!==void 0)if(Nl(r)===r&&r>=i[t+1]&&r<=i[t+2])this[n]=r;else throw Error(es+n+": "+r);if((r=e[n="LN10"])!==void 0)if(r==Math.LN10)this[n]=new this(r);else throw Error(es+n+": "+r);return this}var dw=A2(eoe);Pr=new dw(1);const ft=dw;function R2(e){var t;return e===0?t=1:t=Math.floor(new ft(e).abs().log(10).toNumber())+1,t}function I2(e,t,n){for(var r=new ft(e),i=0,o=[];r.lt(t)&&i<1e5;)o.push(r.toNumber()),r=r.add(n),i++;return o}var T2=e=>{var[t,n]=e,[r,i]=[t,n];return t>n&&([r,i]=[n,t]),[r,i]},pw=(e,t,n)=>{if(e.lte(0))return new ft(0);var r=R2(e.toNumber()),i=new ft(10).pow(r),o=e.div(i),a=r!==1?.05:.1,s=new ft(Math.ceil(o.div(a).toNumber())).add(n).mul(a),u=s.mul(i);return t?new ft(u.toNumber()):new ft(Math.ceil(u.toNumber()))},k2=(e,t,n)=>{var r;if(e.lte(0))return new ft(0);var i=[1,2,2.5,5],o=e.toNumber(),a=Math.floor(new ft(o).abs().log(10).toNumber()),s=new ft(10).pow(a),u=e.div(s).toNumber(),c=i.findIndex(h=>h>=u-1e-10);if(c===-1&&(s=s.mul(10),c=0),c+=n,c>=i.length){var f=Math.floor(c/i.length);c%=i.length,s=s.mul(new ft(10).pow(f))}var p=(r=i[c])!==null&&r!==void 0?r:1,g=new ft(p).mul(s);return t?g:new ft(Math.ceil(g.toNumber()))},roe=(e,t,n)=>{var r=new ft(1),i=new ft(e);if(!i.isint()&&n){var o=Math.abs(e);o<1?(r=new ft(10).pow(R2(e)-1),i=new ft(Math.floor(i.div(r).toNumber())).mul(r)):o>1&&(i=new ft(Math.floor(e)))}else e===0?i=new ft(Math.floor((t-1)/2)):n||(i=new ft(Math.floor(e)));for(var a=Math.floor((t-1)/2),s=[],u=0;u<t;u++)s.push(i.add(new ft(u-a).mul(r)).toNumber());return s},N2=function(t,n,r,i){var o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0,a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:pw;if(!Number.isFinite((n-t)/(r-1)))return{step:new ft(0),tickMin:new ft(0),tickMax:new ft(0)};var s=a(new ft(n).sub(t).div(r-1),i,o),u;t<=0&&n>=0?u=new ft(0):(u=new ft(t).add(n).div(2),u=u.sub(new ft(u).mod(s)));var c=Math.ceil(u.sub(t).div(s).toNumber()),f=Math.ceil(new ft(n).sub(u).div(s).toNumber()),p=c+f+1;return p>r?N2(t,n,r,i,o+1,a):(p<r&&(f=n>0?f+(r-p):f,c=n>0?c:c+(r-p)),{step:s,tickMin:u.sub(new ft(c).mul(s)),tickMax:u.add(new ft(f).mul(s))})},AP=function(t){var[n,r]=t,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"auto",s=Math.max(i,2),[u,c]=T2([n,r]);if(u===-1/0||c===1/0){var f=c===1/0?[u,...Array(i-1).fill(1/0)]:[...Array(i-1).fill(-1/0),c];return n>r?f.reverse():f}if(u===c)return roe(u,i,o);var p=a==="snap125"?k2:pw,{step:g,tickMin:h,tickMax:v}=N2(u,c,s,o,0,p),b=I2(h,v.add(new ft(.1).mul(g)),g);return n>r?b.reverse():b},RP=function(t,n){var[r,i]=t,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"auto",[s,u]=T2([r,i]);if(s===-1/0||u===1/0)return[r,i];if(s===u)return[s];var c=a==="snap125"?k2:pw,f=Math.max(n,2),p=c(new ft(u).sub(s).div(f-1),o,0),g=[...I2(new ft(s),new ft(u),p),u];return o===!1&&(g=g.map(h=>Math.round(h))),r>i?g.reverse():g},M2=e=>e.rootProps.maxBarSize,ioe=e=>e.rootProps.barGap,D2=e=>e.rootProps.barCategoryGap,ooe=e=>e.rootProps.barSize,rg=e=>e.rootProps.stackOffset,j2=e=>e.rootProps.reverseStackOrder,hw=e=>e.options.chartName,gw=e=>e.rootProps.syncId,L2=e=>e.rootProps.syncMethod,mw=e=>e.options.eventEmitter,Qn={grid:-100,barBackground:-50,area:100,cursorRectangle:200,bar:300,line:400,axis:500,scatter:600,activeBar:1e3,cursorLine:1100,activeDot:1200,label:2e3},Va={allowDecimals:!1,allowDataOverflow:!1,angleAxisId:0,reversed:!1,scale:"auto",tick:!0,type:"auto"},Pi={allowDataOverflow:!1,allowDecimals:!1,allowDuplicatedCategory:!0,includeHidden:!1,radiusAxisId:0,reversed:!1,scale:"auto",tick:!0,tickCount:5,type:"auto"},ig=(e,t)=>{if(!(!e||!t))return e!=null&&e.reversed?[t[1],t[0]]:t};function og(e,t,n){if(n!=="auto")return n;if(e!=null)return ba(e,t)?"category":"number"}function IP(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Tp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?IP(Object(n),!0).forEach(function(r){aoe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):IP(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function aoe(e,t,n){return(t=soe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function soe(e){var t=loe(e,"string");return typeof t=="symbol"?t:t+""}function loe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var TP={allowDataOverflow:Va.allowDataOverflow,allowDecimals:Va.allowDecimals,allowDuplicatedCategory:!1,dataKey:void 0,domain:void 0,id:Va.angleAxisId,includeHidden:!1,name:void 0,reversed:Va.reversed,scale:Va.scale,tick:Va.tick,tickCount:void 0,ticks:void 0,type:Va.type,unit:void 0,niceTicks:"auto"},kP={allowDataOverflow:Pi.allowDataOverflow,allowDecimals:Pi.allowDecimals,allowDuplicatedCategory:Pi.allowDuplicatedCategory,dataKey:void 0,domain:void 0,id:Pi.radiusAxisId,includeHidden:Pi.includeHidden,name:void 0,reversed:Pi.reversed,scale:Pi.scale,tick:Pi.tick,tickCount:Pi.tickCount,ticks:void 0,type:Pi.type,unit:void 0,niceTicks:"auto"},uoe=(e,t)=>{if(t!=null)return e.polarAxis.angleAxis[t]},vw=K([uoe,t2],(e,t)=>{var n;if(e!=null)return e;var r=(n=og(t,"angleAxis",TP.type))!==null&&n!==void 0?n:"category";return Tp(Tp({},TP),{},{type:r})}),coe=(e,t)=>e.polarAxis.radiusAxis[t],yw=K([coe,t2],(e,t)=>{var n;if(e!=null)return e;var r=(n=og(t,"radiusAxis",kP.type))!==null&&n!==void 0?n:"category";return Tp(Tp({},kP),{},{type:r})}),ag=e=>e.polarOptions,bw=K([_o,Oo,wn],Lie),$2=K([ag,bw],(e,t)=>{if(e!=null)return pi(e.innerRadius,t,0)}),F2=K([ag,bw],(e,t)=>{if(e!=null)return pi(e.outerRadius,t,t*.8)}),foe=e=>{if(e==null)return[0,0];var{startAngle:t,endAngle:n}=e;return[t,n]},V2=K([ag],foe);K([vw,V2],ig);var B2=K([bw,$2,F2],(e,t,n)=>{if(!(e==null||t==null||n==null))return[t,n]});K([yw,B2],ig);var z2=K([Rt,ag,$2,F2,_o,Oo],(e,t,n,r,i,o)=>{if(!(e!=="centric"&&e!=="radial"||t==null||n==null||r==null)){var{cx:a,cy:s,startAngle:u,endAngle:c}=t;return{cx:pi(a,i,i/2),cy:pi(s,o,o/2),innerRadius:n,outerRadius:r,startAngle:u,endAngle:c,clockWise:!1}}}),Sn=(e,t)=>t,sg=(e,t,n)=>n;function xw(e){return e?.id}function W2(e,t,n){var{chartData:r=[]}=t,{allowDuplicatedCategory:i,dataKey:o}=n,a=new Map;return e.forEach(s=>{var u,c=(u=s.data)!==null&&u!==void 0?u:r;if(!(c==null||c.length===0)){var f=xw(s);c.forEach((p,g)=>{var h=o==null||i?g:String(Mn(p,o,null)),v=Mn(p,s.dataKey,0),b;a.has(h)?b=a.get(h):b={},Object.assign(b,{[f]:v}),a.set(h,b)})}}),Array.from(a.values())}function lg(e){return"stackId"in e&&e.stackId!=null&&e.dataKey!=null}var ug=(e,t)=>e===t?!0:e==null||t==null?!1:e[0]===t[0]&&e[1]===t[1];function cg(e,t){return Array.isArray(e)&&Array.isArray(t)&&e.length===0&&t.length===0?!0:e===t}function doe(e,t){if(e.length===t.length){for(var n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}return!1}var Cn=e=>{var t=Rt(e);return t==="horizontal"?"xAxis":t==="vertical"?"yAxis":t==="centric"?"angleAxis":"radiusAxis"},Ml=e=>e.tooltip.settings.axisId;function ww(e){if(e!=null){var t=e.ticks,n=e.bandwidth,r=e.range(),i=[Math.min(...r),Math.max(...r)];return{domain:()=>e.domain(),range:(function(o){function a(){return o.apply(this,arguments)}return a.toString=function(){return o.toString()},a})(()=>i),rangeMin:()=>i[0],rangeMax:()=>i[1],isInRange(o){var a=i[0],s=i[1];return a<=s?o>=a&&o<=s:o>=s&&o<=a},bandwidth:n?()=>n.call(e):void 0,ticks:t?o=>t.call(e,o):void 0,map:(o,a)=>{var s=e(o);if(s!=null){if(e.bandwidth&&a!==null&&a!==void 0&&a.position){var u=e.bandwidth();switch(a.position){case"middle":s+=u/2;break;case"end":s+=u;break}}return s}}}}}var poe=(e,t)=>{if(t!=null)switch(e){case"linear":{if(!Mi(t)){for(var n,r,i=0;i<t.length;i++){var o=t[i];dt(o)&&((n===void 0||o<n)&&(n=o),(r===void 0||o>r)&&(r=o))}return n!==void 0&&r!==void 0?[n,r]:void 0}return t}default:return t}};function sa(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function hoe(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function Sw(e){let t,n,r;e.length!==2?(t=sa,n=(s,u)=>sa(e(s),u),r=(s,u)=>e(s)-u):(t=e===sa||e===hoe?e:goe,n=e,r=e);function i(s,u,c=0,f=s.length){if(c<f){if(t(u,u)!==0)return f;do{const p=c+f>>>1;n(s[p],u)<0?c=p+1:f=p}while(c<f)}return c}function o(s,u,c=0,f=s.length){if(c<f){if(t(u,u)!==0)return f;do{const p=c+f>>>1;n(s[p],u)<=0?c=p+1:f=p}while(c<f)}return c}function a(s,u,c=0,f=s.length){const p=i(s,u,c,f-1);return p>c&&r(s[p-1],u)>-r(s[p],u)?p-1:p}return{left:i,center:a,right:o}}function goe(){return 0}function H2(e){return e===null?NaN:+e}function*moe(e,t){for(let n of e)n!=null&&(n=+n)>=n&&(yield n)}const voe=Sw(sa),Rc=voe.right;Sw(H2).center;class NP extends Map{constructor(t,n=xoe){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[r,i]of t)this.set(r,i)}get(t){return super.get(MP(this,t))}has(t){return super.has(MP(this,t))}set(t,n){return super.set(yoe(this,t),n)}delete(t){return super.delete(boe(this,t))}}function MP({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function yoe({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function boe({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function xoe(e){return e!==null&&typeof e=="object"?e.valueOf():e}function woe(e=sa){if(e===sa)return U2;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 U2(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}const Soe=Math.sqrt(50),Coe=Math.sqrt(10),Eoe=Math.sqrt(2);function kp(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),a=o>=Soe?10:o>=Coe?5:o>=Eoe?2:1;let s,u,c;return i<0?(c=Math.pow(10,-i)/a,s=Math.round(e*c),u=Math.round(t*c),s/c<e&&++s,u/c>t&&--u,c=-c):(c=Math.pow(10,i)*a,s=Math.round(e/c),u=Math.round(t/c),s*c<e&&++s,u*c>t&&--u),u<s&&.5<=n&&n<2?kp(e,t,n*2):[s,u,c]}function qb(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[i,o,a]=r?kp(t,e,n):kp(e,t,n);if(!(o>=i))return[];const s=o-i+1,u=new Array(s);if(r)if(a<0)for(let c=0;c<s;++c)u[c]=(o-c)/-a;else for(let c=0;c<s;++c)u[c]=(o-c)*a;else if(a<0)for(let c=0;c<s;++c)u[c]=(i+c)/-a;else for(let c=0;c<s;++c)u[c]=(i+c)*a;return u}function Kb(e,t,n){return t=+t,e=+e,n=+n,kp(e,t,n)[2]}function Yb(e,t,n){t=+t,e=+e,n=+n;const r=t<e,i=r?Kb(t,e,n):Kb(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}function DP(e,t){let n;for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);return n}function jP(e,t){let n;for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);return n}function G2(e,t,n=0,r=1/0,i){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(i=i===void 0?U2:woe(i);r>n;){if(r-n>600){const u=r-n+1,c=t-n+1,f=Math.log(u),p=.5*Math.exp(2*f/3),g=.5*Math.sqrt(f*p*(u-p)/u)*(c-u/2<0?-1:1),h=Math.max(n,Math.floor(t-c*p/u+g)),v=Math.min(r,Math.floor(t+(u-c)*p/u+g));G2(e,t,h,v,i)}const o=e[t];let a=n,s=r;for(wu(e,n,t),i(e[r],o)>0&&wu(e,n,r);a<s;){for(wu(e,a,s),++a,--s;i(e[a],o)<0;)++a;for(;i(e[s],o)>0;)--s}i(e[n],o)===0?wu(e,n,s):(++s,wu(e,s,r)),s<=t&&(n=s+1),t<=s&&(r=s-1)}return e}function wu(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function _oe(e,t,n){if(e=Float64Array.from(moe(e)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return jP(e);if(t>=1)return DP(e);var r,i=(r-1)*t,o=Math.floor(i),a=DP(G2(e,o).subarray(0,o+1)),s=jP(e.subarray(o+1));return a+(s-a)*(i-o)}}function Ooe(e,t,n=H2){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,i=(r-1)*t,o=Math.floor(i),a=+n(e[o],o,e),s=+n(e[o+1],o+1,e);return a+(s-a)*(i-o)}}function Poe(e,t,n){e=+e,t=+t,n=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+n;for(var r=-1,i=Math.max(0,Math.ceil((t-e)/n))|0,o=new Array(i);++r<i;)o[r]=e+r*n;return o}function ii(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function Ao(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 Xb=Symbol("implicit");function Cw(){var e=new NP,t=[],n=[],r=Xb;function i(o){let a=e.get(o);if(a===void 0){if(r!==Xb)return r;e.set(o,a=t.push(o)-1)}return n[a%n.length]}return i.domain=function(o){if(!arguments.length)return t.slice();t=[],e=new NP;for(const a of o)e.has(a)||e.set(a,t.push(a)-1);return i},i.range=function(o){return arguments.length?(n=Array.from(o),i):n.slice()},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return Cw(t,n).unknown(r)},ii.apply(i,arguments),i}function Ew(){var e=Cw().unknown(void 0),t=e.domain,n=e.range,r=0,i=1,o,a,s=!1,u=0,c=0,f=.5;delete e.unknown;function p(){var g=t().length,h=i<r,v=h?i:r,b=h?r:i;o=(b-v)/Math.max(1,g-u+c*2),s&&(o=Math.floor(o)),v+=(b-v-o*(g-u))*f,a=o*(1-u),s&&(v=Math.round(v),a=Math.round(a));var y=Poe(g).map(function(w){return v+o*w});return n(h?y.reverse():y)}return e.domain=function(g){return arguments.length?(t(g),p()):t()},e.range=function(g){return arguments.length?([r,i]=g,r=+r,i=+i,p()):[r,i]},e.rangeRound=function(g){return[r,i]=g,r=+r,i=+i,s=!0,p()},e.bandwidth=function(){return a},e.step=function(){return o},e.round=function(g){return arguments.length?(s=!!g,p()):s},e.padding=function(g){return arguments.length?(u=Math.min(1,c=+g),p()):u},e.paddingInner=function(g){return arguments.length?(u=Math.min(1,g),p()):u},e.paddingOuter=function(g){return arguments.length?(c=+g,p()):c},e.align=function(g){return arguments.length?(f=Math.max(0,Math.min(1,g)),p()):f},e.copy=function(){return Ew(t(),[r,i]).round(s).paddingInner(u).paddingOuter(c).align(f)},ii.apply(p(),arguments)}function q2(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return q2(t())},e}function Aoe(){return q2(Ew.apply(null,arguments).paddingInner(1))}function _w(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function K2(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function Ic(){}var oc=.7,Np=1/oc,gl="\\s*([+-]?\\d+)\\s*",ac="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Di="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Roe=/^#([0-9a-f]{3,8})$/,Ioe=new RegExp(`^rgb\\(${gl},${gl},${gl}\\)$`),Toe=new RegExp(`^rgb\\(${Di},${Di},${Di}\\)$`),koe=new RegExp(`^rgba\\(${gl},${gl},${gl},${ac}\\)$`),Noe=new RegExp(`^rgba\\(${Di},${Di},${Di},${ac}\\)$`),Moe=new RegExp(`^hsl\\(${ac},${Di},${Di}\\)$`),Doe=new RegExp(`^hsla\\(${ac},${Di},${Di},${ac}\\)$`),LP={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};_w(Ic,sc,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:$P,formatHex:$P,formatHex8:joe,formatHsl:Loe,formatRgb:FP,toString:FP});function $P(){return this.rgb().formatHex()}function joe(){return this.rgb().formatHex8()}function Loe(){return Y2(this).formatHsl()}function FP(){return this.rgb().formatRgb()}function sc(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=Roe.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?VP(t):n===3?new pr(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?wd(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?wd(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=Ioe.exec(e))?new pr(t[1],t[2],t[3],1):(t=Toe.exec(e))?new pr(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=koe.exec(e))?wd(t[1],t[2],t[3],t[4]):(t=Noe.exec(e))?wd(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=Moe.exec(e))?WP(t[1],t[2]/100,t[3]/100,1):(t=Doe.exec(e))?WP(t[1],t[2]/100,t[3]/100,t[4]):LP.hasOwnProperty(e)?VP(LP[e]):e==="transparent"?new pr(NaN,NaN,NaN,0):null}function VP(e){return new pr(e>>16&255,e>>8&255,e&255,1)}function wd(e,t,n,r){return r<=0&&(e=t=n=NaN),new pr(e,t,n,r)}function $oe(e){return e instanceof Ic||(e=sc(e)),e?(e=e.rgb(),new pr(e.r,e.g,e.b,e.opacity)):new pr}function Zb(e,t,n,r){return arguments.length===1?$oe(e):new pr(e,t,n,r??1)}function pr(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}_w(pr,Zb,K2(Ic,{brighter(e){return e=e==null?Np:Math.pow(Np,e),new pr(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?oc:Math.pow(oc,e),new pr(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new pr(ts(this.r),ts(this.g),ts(this.b),Mp(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:BP,formatHex:BP,formatHex8:Foe,formatRgb:zP,toString:zP}));function BP(){return`#${Ya(this.r)}${Ya(this.g)}${Ya(this.b)}`}function Foe(){return`#${Ya(this.r)}${Ya(this.g)}${Ya(this.b)}${Ya((isNaN(this.opacity)?1:this.opacity)*255)}`}function zP(){const e=Mp(this.opacity);return`${e===1?"rgb(":"rgba("}${ts(this.r)}, ${ts(this.g)}, ${ts(this.b)}${e===1?")":`, ${e})`}`}function Mp(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function ts(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Ya(e){return e=ts(e),(e<16?"0":"")+e.toString(16)}function WP(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new fi(e,t,n,r)}function Y2(e){if(e instanceof fi)return new fi(e.h,e.s,e.l,e.opacity);if(e instanceof Ic||(e=sc(e)),!e)return new fi;if(e instanceof fi)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),o=Math.max(t,n,r),a=NaN,s=o-i,u=(o+i)/2;return s?(t===o?a=(n-r)/s+(n<r)*6:n===o?a=(r-t)/s+2:a=(t-n)/s+4,s/=u<.5?o+i:2-o-i,a*=60):s=u>0&&u<1?0:a,new fi(a,s,u,e.opacity)}function Voe(e,t,n,r){return arguments.length===1?Y2(e):new fi(e,t,n,r??1)}function fi(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}_w(fi,Voe,K2(Ic,{brighter(e){return e=e==null?Np:Math.pow(Np,e),new fi(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?oc:Math.pow(oc,e),new fi(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,i=2*n-r;return new pr(vy(e>=240?e-240:e+120,i,r),vy(e,i,r),vy(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new fi(HP(this.h),Sd(this.s),Sd(this.l),Mp(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=Mp(this.opacity);return`${e===1?"hsl(":"hsla("}${HP(this.h)}, ${Sd(this.s)*100}%, ${Sd(this.l)*100}%${e===1?")":`, ${e})`}`}}));function HP(e){return e=(e||0)%360,e<0?e+360:e}function Sd(e){return Math.max(0,Math.min(1,e||0))}function vy(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 Ow=e=>()=>e;function Boe(e,t){return function(n){return e+n*t}}function zoe(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 Woe(e){return(e=+e)==1?X2:function(t,n){return n-t?zoe(t,n,e):Ow(isNaN(t)?n:t)}}function X2(e,t){var n=t-e;return n?Boe(e,n):Ow(isNaN(e)?t:e)}const UP=(function e(t){var n=Woe(t);function r(i,o){var a=n((i=Zb(i)).r,(o=Zb(o)).r),s=n(i.g,o.g),u=n(i.b,o.b),c=X2(i.opacity,o.opacity);return function(f){return i.r=a(f),i.g=s(f),i.b=u(f),i.opacity=c(f),i+""}}return r.gamma=e,r})(1);function Hoe(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(o){for(i=0;i<n;++i)r[i]=e[i]*(1-o)+t[i]*o;return r}}function Uoe(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function Goe(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=new Array(r),o=new Array(n),a;for(a=0;a<r;++a)i[a]=Dl(e[a],t[a]);for(;a<n;++a)o[a]=t[a];return function(s){for(a=0;a<r;++a)o[a]=i[a](s);return o}}function qoe(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function Dp(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function Koe(e,t){var n={},r={},i;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(i in t)i in e?n[i]=Dl(e[i],t[i]):r[i]=t[i];return function(o){for(i in n)r[i]=n[i](o);return r}}var Qb=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,yy=new RegExp(Qb.source,"g");function Yoe(e){return function(){return e}}function Xoe(e){return function(t){return e(t)+""}}function Zoe(e,t){var n=Qb.lastIndex=yy.lastIndex=0,r,i,o,a=-1,s=[],u=[];for(e=e+"",t=t+"";(r=Qb.exec(e))&&(i=yy.exec(t));)(o=i.index)>n&&(o=t.slice(n,o),s[a]?s[a]+=o:s[++a]=o),(r=r[0])===(i=i[0])?s[a]?s[a]+=i:s[++a]=i:(s[++a]=null,u.push({i:a,x:Dp(r,i)})),n=yy.lastIndex;return n<t.length&&(o=t.slice(n),s[a]?s[a]+=o:s[++a]=o),s.length<2?u[0]?Xoe(u[0].x):Yoe(t):(t=u.length,function(c){for(var f=0,p;f<t;++f)s[(p=u[f]).i]=p.x(c);return s.join("")})}function Dl(e,t){var n=typeof t,r;return t==null||n==="boolean"?Ow(t):(n==="number"?Dp:n==="string"?(r=sc(t))?(t=r,UP):Zoe:t instanceof sc?UP:t instanceof Date?qoe:Uoe(t)?Hoe:Array.isArray(t)?Goe:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?Koe:Dp)(e,t)}function Pw(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}function Qoe(e,t){t===void 0&&(t=e,e=Dl);for(var n=0,r=t.length-1,i=t[0],o=new Array(r<0?0:r);n<r;)o[n]=e(i,i=t[++n]);return function(a){var s=Math.max(0,Math.min(r-1,Math.floor(a*=r)));return o[s](a-s)}}function Joe(e){return function(){return e}}function jp(e){return+e}var GP=[0,1];function Jn(e){return e}function Jb(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:Joe(isNaN(t)?NaN:.5)}function eae(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function tae(e,t,n){var r=e[0],i=e[1],o=t[0],a=t[1];return i<r?(r=Jb(i,r),o=n(a,o)):(r=Jb(r,i),o=n(o,a)),function(s){return o(r(s))}}function nae(e,t,n){var r=Math.min(e.length,t.length)-1,i=new Array(r),o=new Array(r),a=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++a<r;)i[a]=Jb(e[a],e[a+1]),o[a]=n(t[a],t[a+1]);return function(s){var u=Rc(e,s,1,r)-1;return o[u](i[u](s))}}function Tc(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function fg(){var e=GP,t=GP,n=Dl,r,i,o,a=Jn,s,u,c;function f(){var g=Math.min(e.length,t.length);return a!==Jn&&(a=eae(e[0],e[g-1])),s=g>2?nae:tae,u=c=null,p}function p(g){return g==null||isNaN(g=+g)?o:(u||(u=s(e.map(r),t,n)))(r(a(g)))}return p.invert=function(g){return a(i((c||(c=s(t,e.map(r),Dp)))(g)))},p.domain=function(g){return arguments.length?(e=Array.from(g,jp),f()):e.slice()},p.range=function(g){return arguments.length?(t=Array.from(g),f()):t.slice()},p.rangeRound=function(g){return t=Array.from(g),n=Pw,f()},p.clamp=function(g){return arguments.length?(a=g?!0:Jn,f()):a!==Jn},p.interpolate=function(g){return arguments.length?(n=g,f()):n},p.unknown=function(g){return arguments.length?(o=g,p):o},function(g,h){return r=g,i=h,f()}}function Aw(){return fg()(Jn,Jn)}function rae(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Lp(e,t){if(!isFinite(e)||e===0)return null;var n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"),r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function Cl(e){return e=Lp(Math.abs(e)),e?e[1]:NaN}function iae(e,t){return function(n,r){for(var i=n.length,o=[],a=0,s=e[0],u=0;i>0&&s>0&&(u+s+1>r&&(s=Math.max(1,r-u)),o.push(n.substring(i-=s,i+s)),!((u+=s+1)>r));)s=e[a=(a+1)%e.length];return o.reverse().join(t)}}function oae(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var aae=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function lc(e){if(!(t=aae.exec(e)))throw new Error("invalid format: "+e);var t;return new Rw({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]})}lc.prototype=Rw.prototype;function Rw(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+""}Rw.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 sae(e){e:for(var t=e.length,n=1,r=-1,i;n<t;++n)switch(e[n]){case".":r=i=n;break;case"0":r===0&&(r=n),i=n;break;default:if(!+e[n])break e;r>0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(i+1):e}var $p;function lae(e,t){var n=Lp(e,t);if(!n)return $p=void 0,e.toPrecision(t);var r=n[0],i=n[1],o=i-($p=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+Lp(e,Math.max(0,t+o-1))[0]}function qP(e,t){var n=Lp(e,t);if(!n)return e+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}const KP={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:rae,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)=>qP(e*100,t),r:qP,s:lae,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function YP(e){return e}var XP=Array.prototype.map,ZP=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function uae(e){var t=e.grouping===void 0||e.thousands===void 0?YP:iae(XP.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?YP:oae(XP.call(e.numerals,String)),a=e.percent===void 0?"%":e.percent+"",s=e.minus===void 0?"−":e.minus+"",u=e.nan===void 0?"NaN":e.nan+"";function c(p,g){p=lc(p);var h=p.fill,v=p.align,b=p.sign,y=p.symbol,w=p.zero,S=p.width,E=p.comma,_=p.precision,P=p.trim,R=p.type;R==="n"?(E=!0,R="g"):KP[R]||(_===void 0&&(_=12),P=!0,R="g"),(w||h==="0"&&v==="=")&&(w=!0,h="0",v="=");var I=(g&&g.prefix!==void 0?g.prefix:"")+(y==="$"?n:y==="#"&&/[boxX]/.test(R)?"0"+R.toLowerCase():""),k=(y==="$"?r:/[%p]/.test(R)?a:"")+(g&&g.suffix!==void 0?g.suffix:""),B=KP[R],L=/[defgprs%]/.test(R);_=_===void 0?6:/[gprs]/.test(R)?Math.max(1,Math.min(21,_)):Math.max(0,Math.min(20,_));function V(D){var W=I,J=k,re,U,ee;if(R==="c")J=B(D)+J,D="";else{D=+D;var Z=D<0||1/D<0;if(D=isNaN(D)?u:B(Math.abs(D),_),P&&(D=sae(D)),Z&&+D==0&&b!=="+"&&(Z=!1),W=(Z?b==="("?b:s:b==="-"||b==="("?"":b)+W,J=(R==="s"&&!isNaN(D)&&$p!==void 0?ZP[8+$p/3]:"")+J+(Z&&b==="("?")":""),L){for(re=-1,U=D.length;++re<U;)if(ee=D.charCodeAt(re),48>ee||ee>57){J=(ee===46?i+D.slice(re+1):D.slice(re))+J,D=D.slice(0,re);break}}}E&&!w&&(D=t(D,1/0));var ue=W.length+D.length+J.length,X=ue<S?new Array(S-ue+1).join(h):"";switch(E&&w&&(D=t(X+D,X.length?S-J.length:1/0),X=""),v){case"<":D=W+D+J+X;break;case"=":D=W+X+D+J;break;case"^":D=X.slice(0,ue=X.length>>1)+W+D+J+X.slice(ue);break;default:D=X+W+D+J;break}return o(D)}return V.toString=function(){return p+""},V}function f(p,g){var h=Math.max(-8,Math.min(8,Math.floor(Cl(g)/3)))*3,v=Math.pow(10,-h),b=c((p=lc(p),p.type="f",p),{suffix:ZP[8+h/3]});return function(y){return b(v*y)}}return{format:c,formatPrefix:f}}var Cd,Iw,Z2;cae({thousands:",",grouping:[3],currency:["$",""]});function cae(e){return Cd=uae(e),Iw=Cd.format,Z2=Cd.formatPrefix,Cd}function fae(e){return Math.max(0,-Cl(Math.abs(e)))}function dae(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Cl(t)/3)))*3-Cl(Math.abs(e)))}function pae(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Cl(t)-Cl(e))+1}function Q2(e,t,n,r){var i=Yb(e,t,n),o;switch(r=lc(r??",f"),r.type){case"s":{var a=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(o=dae(i,a))&&(r.precision=o),Z2(r,a)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(o=pae(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=o-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(o=fae(i))&&(r.precision=o-(r.type==="%")*2);break}}return Iw(r)}function xa(e){var t=e.domain;return e.ticks=function(n){var r=t();return qb(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var i=t();return Q2(i[0],i[i.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),i=0,o=r.length-1,a=r[i],s=r[o],u,c,f=10;for(s<a&&(c=a,a=s,s=c,c=i,i=o,o=c);f-- >0;){if(c=Kb(a,s,n),c===u)return r[i]=a,r[o]=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;u=c}return e},e}function J2(){var e=Aw();return e.copy=function(){return Tc(e,J2())},ii.apply(e,arguments),xa(e)}function eL(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,jp),n):e.slice()},n.unknown=function(r){return arguments.length?(t=r,n):t},n.copy=function(){return eL(e).unknown(t)},e=arguments.length?Array.from(e,jp):[0,1],xa(n)}function tL(e,t){e=e.slice();var n=0,r=e.length-1,i=e[n],o=e[r],a;return o<i&&(a=n,n=r,r=a,a=i,i=o,o=a),e[n]=t.floor(i),e[r]=t.ceil(o),e}function QP(e){return Math.log(e)}function JP(e){return Math.exp(e)}function hae(e){return-Math.log(-e)}function gae(e){return-Math.exp(-e)}function mae(e){return isFinite(e)?+("1e"+e):e<0?0:e}function vae(e){return e===10?mae:e===Math.E?Math.exp:t=>Math.pow(e,t)}function yae(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 eA(e){return(t,n)=>-e(-t,n)}function Tw(e){const t=e(QP,JP),n=t.domain;let r=10,i,o;function a(){return i=yae(r),o=vae(r),n()[0]<0?(i=eA(i),o=eA(o),e(hae,gae)):e(QP,JP),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 u=n();let c=u[0],f=u[u.length-1];const p=f<c;p&&([c,f]=[f,c]);let g=i(c),h=i(f),v,b;const y=s==null?10:+s;let w=[];if(!(r%1)&&h-g<y){if(g=Math.floor(g),h=Math.ceil(h),c>0){for(;g<=h;++g)for(v=1;v<r;++v)if(b=g<0?v/o(-g):v*o(g),!(b<c)){if(b>f)break;w.push(b)}}else for(;g<=h;++g)for(v=r-1;v>=1;--v)if(b=g>0?v/o(-g):v*o(g),!(b<c)){if(b>f)break;w.push(b)}w.length*2<y&&(w=qb(c,f,y))}else w=qb(g,h,Math.min(h-g,y)).map(o);return p?w.reverse():w},t.tickFormat=(s,u)=>{if(s==null&&(s=10),u==null&&(u=r===10?"s":","),typeof u!="function"&&(!(r%1)&&(u=lc(u)).precision==null&&(u.trim=!0),u=Iw(u)),s===1/0)return u;const c=Math.max(1,r*s/t.ticks().length);return f=>{let p=f/o(Math.round(i(f)));return p*r<r-.5&&(p*=r),p<=c?u(f):""}},t.nice=()=>n(tL(n(),{floor:s=>o(Math.floor(i(s))),ceil:s=>o(Math.ceil(i(s)))})),t}function nL(){const e=Tw(fg()).domain([1,10]);return e.copy=()=>Tc(e,nL()).base(e.base()),ii.apply(e,arguments),e}function tA(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function nA(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function kw(e){var t=1,n=e(tA(t),nA(t));return n.constant=function(r){return arguments.length?e(tA(t=+r),nA(t)):t},xa(n)}function rL(){var e=kw(fg());return e.copy=function(){return Tc(e,rL()).constant(e.constant())},ii.apply(e,arguments)}function rA(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function bae(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function xae(e){return e<0?-e*e:e*e}function Nw(e){var t=e(Jn,Jn),n=1;function r(){return n===1?e(Jn,Jn):n===.5?e(bae,xae):e(rA(n),rA(1/n))}return t.exponent=function(i){return arguments.length?(n=+i,r()):n},xa(t)}function Mw(){var e=Nw(fg());return e.copy=function(){return Tc(e,Mw()).exponent(e.exponent())},ii.apply(e,arguments),e}function wae(){return Mw.apply(null,arguments).exponent(.5)}function iA(e){return Math.sign(e)*e*e}function Sae(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function iL(){var e=Aw(),t=[0,1],n=!1,r;function i(o){var a=Sae(e(o));return isNaN(a)?r:n?Math.round(a):a}return i.invert=function(o){return e.invert(iA(o))},i.domain=function(o){return arguments.length?(e.domain(o),i):e.domain()},i.range=function(o){return arguments.length?(e.range((t=Array.from(o,jp)).map(iA)),i):t.slice()},i.rangeRound=function(o){return i.range(o).round(!0)},i.round=function(o){return arguments.length?(n=!!o,i):n},i.clamp=function(o){return arguments.length?(e.clamp(o),i):e.clamp()},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return iL(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},ii.apply(i,arguments),xa(i)}function oL(){var e=[],t=[],n=[],r;function i(){var a=0,s=Math.max(1,t.length);for(n=new Array(s-1);++a<s;)n[a-1]=Ooe(e,a/s);return o}function o(a){return a==null||isNaN(a=+a)?r:t[Rc(n,a)]}return o.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]]},o.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(sa),i()},o.range=function(a){return arguments.length?(t=Array.from(a),i()):t.slice()},o.unknown=function(a){return arguments.length?(r=a,o):r},o.quantiles=function(){return n.slice()},o.copy=function(){return oL().domain(e).range(t).unknown(r)},ii.apply(o,arguments)}function aL(){var e=0,t=1,n=1,r=[.5],i=[0,1],o;function a(u){return u!=null&&u<=u?i[Rc(r,u,0,n)]:o}function s(){var u=-1;for(r=new Array(n);++u<n;)r[u]=((u+1)*t-(u-n)*e)/(n+1);return a}return a.domain=function(u){return arguments.length?([e,t]=u,e=+e,t=+t,s()):[e,t]},a.range=function(u){return arguments.length?(n=(i=Array.from(u)).length-1,s()):i.slice()},a.invertExtent=function(u){var c=i.indexOf(u);return c<0?[NaN,NaN]:c<1?[e,r[0]]:c>=n?[r[n-1],t]:[r[c-1],r[c]]},a.unknown=function(u){return arguments.length&&(o=u),a},a.thresholds=function(){return r.slice()},a.copy=function(){return aL().domain([e,t]).range(i).unknown(o)},ii.apply(xa(a),arguments)}function sL(){var e=[.5],t=[0,1],n,r=1;function i(o){return o!=null&&o<=o?t[Rc(e,o,0,r)]:n}return i.domain=function(o){return arguments.length?(e=Array.from(o),r=Math.min(e.length,t.length-1),i):e.slice()},i.range=function(o){return arguments.length?(t=Array.from(o),r=Math.min(e.length,t.length-1),i):t.slice()},i.invertExtent=function(o){var a=t.indexOf(o);return[e[a-1],e[a]]},i.unknown=function(o){return arguments.length?(n=o,i):n},i.copy=function(){return sL().domain(e).range(t).unknown(n)},ii.apply(i,arguments)}const by=new Date,xy=new Date;function hn(e,t,n,r){function i(o){return e(o=arguments.length===0?new Date:new Date(+o)),o}return i.floor=o=>(e(o=new Date(+o)),o),i.ceil=o=>(e(o=new Date(o-1)),t(o,1),e(o),o),i.round=o=>{const a=i(o),s=i.ceil(o);return o-a<s-o?a:s},i.offset=(o,a)=>(t(o=new Date(+o),a==null?1:Math.floor(a)),o),i.range=(o,a,s)=>{const u=[];if(o=i.ceil(o),s=s==null?1:Math.floor(s),!(o<a)||!(s>0))return u;let c;do u.push(c=new Date(+o)),t(o,s),e(o);while(c<o&&o<a);return u},i.filter=o=>hn(a=>{if(a>=a)for(;e(a),!o(a);)a.setTime(a-1)},(a,s)=>{if(a>=a)if(s<0)for(;++s<=0;)for(;t(a,-1),!o(a););else for(;--s>=0;)for(;t(a,1),!o(a););}),n&&(i.count=(o,a)=>(by.setTime(+o),xy.setTime(+a),e(by),e(xy),Math.floor(n(by,xy))),i.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?i.filter(r?a=>r(a)%o===0:a=>i.count(0,a)%o===0):i)),i}const Fp=hn(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Fp.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?hn(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):Fp);Fp.range;const so=1e3,ei=so*60,lo=ei*60,bo=lo*24,Dw=bo*7,oA=bo*30,wy=bo*365,Xa=hn(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*so)},(e,t)=>(t-e)/so,e=>e.getUTCSeconds());Xa.range;const jw=hn(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*so)},(e,t)=>{e.setTime(+e+t*ei)},(e,t)=>(t-e)/ei,e=>e.getMinutes());jw.range;const Lw=hn(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*ei)},(e,t)=>(t-e)/ei,e=>e.getUTCMinutes());Lw.range;const $w=hn(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*so-e.getMinutes()*ei)},(e,t)=>{e.setTime(+e+t*lo)},(e,t)=>(t-e)/lo,e=>e.getHours());$w.range;const Fw=hn(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*lo)},(e,t)=>(t-e)/lo,e=>e.getUTCHours());Fw.range;const kc=hn(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*ei)/bo,e=>e.getDate()-1);kc.range;const dg=hn(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/bo,e=>e.getUTCDate()-1);dg.range;const lL=hn(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/bo,e=>Math.floor(e/bo));lL.range;function bs(e){return hn(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())*ei)/Dw)}const pg=bs(0),Vp=bs(1),Cae=bs(2),Eae=bs(3),El=bs(4),_ae=bs(5),Oae=bs(6);pg.range;Vp.range;Cae.range;Eae.range;El.range;_ae.range;Oae.range;function xs(e){return hn(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)/Dw)}const hg=xs(0),Bp=xs(1),Pae=xs(2),Aae=xs(3),_l=xs(4),Rae=xs(5),Iae=xs(6);hg.range;Bp.range;Pae.range;Aae.range;_l.range;Rae.range;Iae.range;const Vw=hn(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());Vw.range;const Bw=hn(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());Bw.range;const xo=hn(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());xo.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:hn(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)});xo.range;const wo=hn(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());wo.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:hn(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)});wo.range;function uL(e,t,n,r,i,o){const a=[[Xa,1,so],[Xa,5,5*so],[Xa,15,15*so],[Xa,30,30*so],[o,1,ei],[o,5,5*ei],[o,15,15*ei],[o,30,30*ei],[i,1,lo],[i,3,3*lo],[i,6,6*lo],[i,12,12*lo],[r,1,bo],[r,2,2*bo],[n,1,Dw],[t,1,oA],[t,3,3*oA],[e,1,wy]];function s(c,f,p){const g=f<c;g&&([c,f]=[f,c]);const h=p&&typeof p.range=="function"?p:u(c,f,p),v=h?h.range(c,+f+1):[];return g?v.reverse():v}function u(c,f,p){const g=Math.abs(f-c)/p,h=Sw(([,,y])=>y).right(a,g);if(h===a.length)return e.every(Yb(c/wy,f/wy,p));if(h===0)return Fp.every(Math.max(Yb(c,f,p),1));const[v,b]=a[g/a[h-1][2]<a[h][2]/g?h-1:h];return v.every(b)}return[s,u]}const[Tae,kae]=uL(wo,Bw,hg,lL,Fw,Lw),[Nae,Mae]=uL(xo,Vw,pg,kc,$w,jw);function Sy(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 Cy(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 Su(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function Dae(e){var t=e.dateTime,n=e.date,r=e.time,i=e.periods,o=e.days,a=e.shortDays,s=e.months,u=e.shortMonths,c=Cu(i),f=Eu(i),p=Cu(o),g=Eu(o),h=Cu(a),v=Eu(a),b=Cu(s),y=Eu(s),w=Cu(u),S=Eu(u),E={a:ee,A:Z,b:ue,B:X,c:null,d:fA,e:fA,f:ise,g:hse,G:mse,H:tse,I:nse,j:rse,L:cL,m:ose,M:ase,p:Oe,q:Ee,Q:hA,s:gA,S:sse,u:lse,U:use,V:cse,w:fse,W:dse,x:null,X:null,y:pse,Y:gse,Z:vse,"%":pA},_={a:Me,A:ye,b:be,B:$e,c:null,d:dA,e:dA,f:wse,g:Tse,G:Nse,H:yse,I:bse,j:xse,L:dL,m:Sse,M:Cse,p:me,q:Se,Q:hA,s:gA,S:Ese,u:_se,U:Ose,V:Pse,w:Ase,W:Rse,x:null,X:null,y:Ise,Y:kse,Z:Mse,"%":pA},P={a:L,A:V,b:D,B:W,c:J,d:uA,e:uA,f:Zae,g:lA,G:sA,H:cA,I:cA,j:qae,L:Xae,m:Gae,M:Kae,p:B,q:Uae,Q:Jae,s:ese,S:Yae,u:Vae,U:Bae,V:zae,w:Fae,W:Wae,x:re,X:U,y:lA,Y:sA,Z:Hae,"%":Qae};E.x=R(n,E),E.X=R(r,E),E.c=R(t,E),_.x=R(n,_),_.X=R(r,_),_.c=R(t,_);function R(q,te){return function(Y){var j=[],ie=-1,Q=0,Ae=q.length,G,fe,ve;for(Y instanceof Date||(Y=new Date(+Y));++ie<Ae;)q.charCodeAt(ie)===37&&(j.push(q.slice(Q,ie)),(fe=aA[G=q.charAt(++ie)])!=null?G=q.charAt(++ie):fe=G==="e"?" ":"0",(ve=te[G])&&(G=ve(Y,fe)),j.push(G),Q=ie+1);return j.push(q.slice(Q,ie)),j.join("")}}function I(q,te){return function(Y){var j=Su(1900,void 0,1),ie=k(j,q,Y+="",0),Q,Ae;if(ie!=Y.length)return null;if("Q"in j)return new Date(j.Q);if("s"in j)return new Date(j.s*1e3+("L"in j?j.L:0));if(te&&!("Z"in j)&&(j.Z=0),"p"in j&&(j.H=j.H%12+j.p*12),j.m===void 0&&(j.m="q"in j?j.q:0),"V"in j){if(j.V<1||j.V>53)return null;"w"in j||(j.w=1),"Z"in j?(Q=Cy(Su(j.y,0,1)),Ae=Q.getUTCDay(),Q=Ae>4||Ae===0?Bp.ceil(Q):Bp(Q),Q=dg.offset(Q,(j.V-1)*7),j.y=Q.getUTCFullYear(),j.m=Q.getUTCMonth(),j.d=Q.getUTCDate()+(j.w+6)%7):(Q=Sy(Su(j.y,0,1)),Ae=Q.getDay(),Q=Ae>4||Ae===0?Vp.ceil(Q):Vp(Q),Q=kc.offset(Q,(j.V-1)*7),j.y=Q.getFullYear(),j.m=Q.getMonth(),j.d=Q.getDate()+(j.w+6)%7)}else("W"in j||"U"in j)&&("w"in j||(j.w="u"in j?j.u%7:"W"in j?1:0),Ae="Z"in j?Cy(Su(j.y,0,1)).getUTCDay():Sy(Su(j.y,0,1)).getDay(),j.m=0,j.d="W"in j?(j.w+6)%7+j.W*7-(Ae+5)%7:j.w+j.U*7-(Ae+6)%7);return"Z"in j?(j.H+=j.Z/100|0,j.M+=j.Z%100,Cy(j)):Sy(j)}}function k(q,te,Y,j){for(var ie=0,Q=te.length,Ae=Y.length,G,fe;ie<Q;){if(j>=Ae)return-1;if(G=te.charCodeAt(ie++),G===37){if(G=te.charAt(ie++),fe=P[G in aA?te.charAt(ie++):G],!fe||(j=fe(q,Y,j))<0)return-1}else if(G!=Y.charCodeAt(j++))return-1}return j}function B(q,te,Y){var j=c.exec(te.slice(Y));return j?(q.p=f.get(j[0].toLowerCase()),Y+j[0].length):-1}function L(q,te,Y){var j=h.exec(te.slice(Y));return j?(q.w=v.get(j[0].toLowerCase()),Y+j[0].length):-1}function V(q,te,Y){var j=p.exec(te.slice(Y));return j?(q.w=g.get(j[0].toLowerCase()),Y+j[0].length):-1}function D(q,te,Y){var j=w.exec(te.slice(Y));return j?(q.m=S.get(j[0].toLowerCase()),Y+j[0].length):-1}function W(q,te,Y){var j=b.exec(te.slice(Y));return j?(q.m=y.get(j[0].toLowerCase()),Y+j[0].length):-1}function J(q,te,Y){return k(q,t,te,Y)}function re(q,te,Y){return k(q,n,te,Y)}function U(q,te,Y){return k(q,r,te,Y)}function ee(q){return a[q.getDay()]}function Z(q){return o[q.getDay()]}function ue(q){return u[q.getMonth()]}function X(q){return s[q.getMonth()]}function Oe(q){return i[+(q.getHours()>=12)]}function Ee(q){return 1+~~(q.getMonth()/3)}function Me(q){return a[q.getUTCDay()]}function ye(q){return o[q.getUTCDay()]}function be(q){return u[q.getUTCMonth()]}function $e(q){return s[q.getUTCMonth()]}function me(q){return i[+(q.getUTCHours()>=12)]}function Se(q){return 1+~~(q.getUTCMonth()/3)}return{format:function(q){var te=R(q+="",E);return te.toString=function(){return q},te},parse:function(q){var te=I(q+="",!1);return te.toString=function(){return q},te},utcFormat:function(q){var te=R(q+="",_);return te.toString=function(){return q},te},utcParse:function(q){var te=I(q+="",!0);return te.toString=function(){return q},te}}}var aA={"-":"",_:" ",0:"0"},En=/^\s*\d+/,jae=/^%/,Lae=/[\\^$*+?|[\]().{}]/g;function ht(e,t,n){var r=e<0?"-":"",i=(r?-e:e)+"",o=i.length;return r+(o<n?new Array(n-o+1).join(t)+i:i)}function $ae(e){return e.replace(Lae,"\\$&")}function Cu(e){return new RegExp("^(?:"+e.map($ae).join("|")+")","i")}function Eu(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function Fae(e,t,n){var r=En.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function Vae(e,t,n){var r=En.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function Bae(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function zae(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function Wae(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function sA(e,t,n){var r=En.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function lA(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function Hae(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 Uae(e,t,n){var r=En.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function Gae(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function uA(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function qae(e,t,n){var r=En.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function cA(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function Kae(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function Yae(e,t,n){var r=En.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function Xae(e,t,n){var r=En.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function Zae(e,t,n){var r=En.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function Qae(e,t,n){var r=jae.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function Jae(e,t,n){var r=En.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function ese(e,t,n){var r=En.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function fA(e,t){return ht(e.getDate(),t,2)}function tse(e,t){return ht(e.getHours(),t,2)}function nse(e,t){return ht(e.getHours()%12||12,t,2)}function rse(e,t){return ht(1+kc.count(xo(e),e),t,3)}function cL(e,t){return ht(e.getMilliseconds(),t,3)}function ise(e,t){return cL(e,t)+"000"}function ose(e,t){return ht(e.getMonth()+1,t,2)}function ase(e,t){return ht(e.getMinutes(),t,2)}function sse(e,t){return ht(e.getSeconds(),t,2)}function lse(e){var t=e.getDay();return t===0?7:t}function use(e,t){return ht(pg.count(xo(e)-1,e),t,2)}function fL(e){var t=e.getDay();return t>=4||t===0?El(e):El.ceil(e)}function cse(e,t){return e=fL(e),ht(El.count(xo(e),e)+(xo(e).getDay()===4),t,2)}function fse(e){return e.getDay()}function dse(e,t){return ht(Vp.count(xo(e)-1,e),t,2)}function pse(e,t){return ht(e.getFullYear()%100,t,2)}function hse(e,t){return e=fL(e),ht(e.getFullYear()%100,t,2)}function gse(e,t){return ht(e.getFullYear()%1e4,t,4)}function mse(e,t){var n=e.getDay();return e=n>=4||n===0?El(e):El.ceil(e),ht(e.getFullYear()%1e4,t,4)}function vse(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+ht(t/60|0,"0",2)+ht(t%60,"0",2)}function dA(e,t){return ht(e.getUTCDate(),t,2)}function yse(e,t){return ht(e.getUTCHours(),t,2)}function bse(e,t){return ht(e.getUTCHours()%12||12,t,2)}function xse(e,t){return ht(1+dg.count(wo(e),e),t,3)}function dL(e,t){return ht(e.getUTCMilliseconds(),t,3)}function wse(e,t){return dL(e,t)+"000"}function Sse(e,t){return ht(e.getUTCMonth()+1,t,2)}function Cse(e,t){return ht(e.getUTCMinutes(),t,2)}function Ese(e,t){return ht(e.getUTCSeconds(),t,2)}function _se(e){var t=e.getUTCDay();return t===0?7:t}function Ose(e,t){return ht(hg.count(wo(e)-1,e),t,2)}function pL(e){var t=e.getUTCDay();return t>=4||t===0?_l(e):_l.ceil(e)}function Pse(e,t){return e=pL(e),ht(_l.count(wo(e),e)+(wo(e).getUTCDay()===4),t,2)}function Ase(e){return e.getUTCDay()}function Rse(e,t){return ht(Bp.count(wo(e)-1,e),t,2)}function Ise(e,t){return ht(e.getUTCFullYear()%100,t,2)}function Tse(e,t){return e=pL(e),ht(e.getUTCFullYear()%100,t,2)}function kse(e,t){return ht(e.getUTCFullYear()%1e4,t,4)}function Nse(e,t){var n=e.getUTCDay();return e=n>=4||n===0?_l(e):_l.ceil(e),ht(e.getUTCFullYear()%1e4,t,4)}function Mse(){return"+0000"}function pA(){return"%"}function hA(e){return+e}function gA(e){return Math.floor(+e/1e3)}var el,hL,gL;Dse({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 Dse(e){return el=Dae(e),hL=el.format,el.parse,gL=el.utcFormat,el.utcParse,el}function jse(e){return new Date(e)}function Lse(e){return e instanceof Date?+e:+new Date(+e)}function zw(e,t,n,r,i,o,a,s,u,c){var f=Aw(),p=f.invert,g=f.domain,h=c(".%L"),v=c(":%S"),b=c("%I:%M"),y=c("%I %p"),w=c("%a %d"),S=c("%b %d"),E=c("%B"),_=c("%Y");function P(R){return(u(R)<R?h:s(R)<R?v:a(R)<R?b:o(R)<R?y:r(R)<R?i(R)<R?w:S:n(R)<R?E:_)(R)}return f.invert=function(R){return new Date(p(R))},f.domain=function(R){return arguments.length?g(Array.from(R,Lse)):g().map(jse)},f.ticks=function(R){var I=g();return e(I[0],I[I.length-1],R??10)},f.tickFormat=function(R,I){return I==null?P:c(I)},f.nice=function(R){var I=g();return(!R||typeof R.range!="function")&&(R=t(I[0],I[I.length-1],R??10)),R?g(tL(I,R)):f},f.copy=function(){return Tc(f,zw(e,t,n,r,i,o,a,s,u,c))},f}function $se(){return ii.apply(zw(Nae,Mae,xo,Vw,pg,kc,$w,jw,Xa,hL).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function Fse(){return ii.apply(zw(Tae,kae,wo,Bw,hg,dg,Fw,Lw,Xa,gL).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function gg(){var e=0,t=1,n,r,i,o,a=Jn,s=!1,u;function c(p){return p==null||isNaN(p=+p)?u:a(i===0?.5:(p=(o(p)-n)*i,s?Math.max(0,Math.min(1,p)):p))}c.domain=function(p){return arguments.length?([e,t]=p,n=o(e=+e),r=o(t=+t),i=n===r?0:1/(r-n),c):[e,t]},c.clamp=function(p){return arguments.length?(s=!!p,c):s},c.interpolator=function(p){return arguments.length?(a=p,c):a};function f(p){return function(g){var h,v;return arguments.length?([h,v]=g,a=p(h,v),c):[a(0),a(1)]}}return c.range=f(Dl),c.rangeRound=f(Pw),c.unknown=function(p){return arguments.length?(u=p,c):u},function(p){return o=p,n=p(e),r=p(t),i=n===r?0:1/(r-n),c}}function wa(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function mL(){var e=xa(gg()(Jn));return e.copy=function(){return wa(e,mL())},Ao.apply(e,arguments)}function vL(){var e=Tw(gg()).domain([1,10]);return e.copy=function(){return wa(e,vL()).base(e.base())},Ao.apply(e,arguments)}function yL(){var e=kw(gg());return e.copy=function(){return wa(e,yL()).constant(e.constant())},Ao.apply(e,arguments)}function Ww(){var e=Nw(gg());return e.copy=function(){return wa(e,Ww()).exponent(e.exponent())},Ao.apply(e,arguments)}function Vse(){return Ww.apply(null,arguments).exponent(.5)}function bL(){var e=[],t=Jn;function n(r){if(r!=null&&!isNaN(r=+r))return t((Rc(e,r,1)-1)/(e.length-1))}return n.domain=function(r){if(!arguments.length)return e.slice();e=[];for(let i of r)i!=null&&!isNaN(i=+i)&&e.push(i);return e.sort(sa),n},n.interpolator=function(r){return arguments.length?(t=r,n):t},n.range=function(){return e.map((r,i)=>t(i/(e.length-1)))},n.quantiles=function(r){return Array.from({length:r+1},(i,o)=>_oe(e,o/r))},n.copy=function(){return bL(t).domain(e)},Ao.apply(n,arguments)}function mg(){var e=0,t=.5,n=1,r=1,i,o,a,s,u,c=Jn,f,p=!1,g;function h(b){return isNaN(b=+b)?g:(b=.5+((b=+f(b))-o)*(r*b<r*o?s:u),c(p?Math.max(0,Math.min(1,b)):b))}h.domain=function(b){return arguments.length?([e,t,n]=b,i=f(e=+e),o=f(t=+t),a=f(n=+n),s=i===o?0:.5/(o-i),u=o===a?0:.5/(a-o),r=o<i?-1:1,h):[e,t,n]},h.clamp=function(b){return arguments.length?(p=!!b,h):p},h.interpolator=function(b){return arguments.length?(c=b,h):c};function v(b){return function(y){var w,S,E;return arguments.length?([w,S,E]=y,c=Qoe(b,[w,S,E]),h):[c(0),c(.5),c(1)]}}return h.range=v(Dl),h.rangeRound=v(Pw),h.unknown=function(b){return arguments.length?(g=b,h):g},function(b){return f=b,i=b(e),o=b(t),a=b(n),s=i===o?0:.5/(o-i),u=o===a?0:.5/(a-o),r=o<i?-1:1,h}}function xL(){var e=xa(mg()(Jn));return e.copy=function(){return wa(e,xL())},Ao.apply(e,arguments)}function wL(){var e=Tw(mg()).domain([.1,1,10]);return e.copy=function(){return wa(e,wL()).base(e.base())},Ao.apply(e,arguments)}function SL(){var e=kw(mg());return e.copy=function(){return wa(e,SL()).constant(e.constant())},Ao.apply(e,arguments)}function Hw(){var e=Nw(mg());return e.copy=function(){return wa(e,Hw()).exponent(e.exponent())},Ao.apply(e,arguments)}function Bse(){return Hw.apply(null,arguments).exponent(.5)}const Nu=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:Ew,scaleDiverging:xL,scaleDivergingLog:wL,scaleDivergingPow:Hw,scaleDivergingSqrt:Bse,scaleDivergingSymlog:SL,scaleIdentity:eL,scaleImplicit:Xb,scaleLinear:J2,scaleLog:nL,scaleOrdinal:Cw,scalePoint:Aoe,scalePow:Mw,scaleQuantile:oL,scaleQuantize:aL,scaleRadial:iL,scaleSequential:mL,scaleSequentialLog:vL,scaleSequentialPow:Ww,scaleSequentialQuantile:bL,scaleSequentialSqrt:Vse,scaleSequentialSymlog:yL,scaleSqrt:wae,scaleSymlog:rL,scaleThreshold:sL,scaleTime:$se,scaleUtc:Fse,tickFormat:Q2},Symbol.toStringTag,{value:"Module"}));function zse(e){if(e in Nu)return Nu[e]();var t="scale".concat(xc(e));if(t in Nu)return Nu[t]()}function mA(e,t,n){if(typeof e=="function")return e.copy().domain(t).range(n);if(e!=null){var r=zse(e);if(r!=null)return r.domain(t).range(n),r}}function Uw(e,t,n,r){if(!(n==null||r==null))return typeof e.scale=="function"?mA(e.scale,n,r):mA(t,n,r)}function Wse(e){return"scale".concat(xc(e))}function Hse(e){return Wse(e)in Nu}var CL=(e,t,n)=>{if(e!=null){var{scale:r,type:i}=e;if(r==="auto")return i==="category"&&n&&(n.indexOf("LineChart")>=0||n.indexOf("AreaChart")>=0||n.indexOf("ComposedChart")>=0&&!t)?"point":i==="category"?"band":"linear";if(typeof r=="string")return Hse(r)?r:"point"}};function Use(e,t){for(var n=0,r=e.length,i=e[0]<e[e.length-1];n<r;){var o=Math.floor((n+r)/2);(i?e[o]<t:e[o]>t)?n=o+1:r=o}return n}function EL(e,t){if(e){var n=t??e.domain(),r=n.map(o=>{var a;return(a=e(o))!==null&&a!==void 0?a:0}),i=e.range();if(!(n.length===0||i.length<2))return o=>{var a,s,u=Use(r,o);if(u<=0)return n[0];if(u>=n.length)return n[n.length-1];var c=(a=r[u-1])!==null&&a!==void 0?a:0,f=(s=r[u])!==null&&s!==void 0?s:0;return Math.abs(o-c)<=Math.abs(o-f)?n[u-1]:n[u]}}}function Gse(e){if(e!=null)return"invert"in e&&typeof e.invert=="function"?e.invert.bind(e):EL(e,void 0)}function vA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function zp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?vA(Object(n),!0).forEach(function(r){qse(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):vA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function qse(e,t,n){return(t=Kse(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Kse(e){var t=Yse(e,"string");return typeof t=="symbol"?t:t+""}function Yse(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var ex=[0,"auto"],un={allowDataOverflow:!1,allowDecimals:!0,allowDuplicatedCategory:!0,angle:0,dataKey:void 0,domain:void 0,height:30,hide:!0,id:0,includeHidden:!1,interval:"preserveEnd",minTickGap:5,mirror:!1,name:void 0,orientation:"bottom",padding:{left:0,right:0},reversed:!1,scale:"auto",tick:!0,tickCount:5,tickFormatter:void 0,ticks:void 0,type:"category",unit:void 0,niceTicks:"auto"},_L=(e,t)=>e.cartesianAxis.xAxis[t],Ro=(e,t)=>{var n=_L(e,t);return n??un},cn={allowDataOverflow:!1,allowDecimals:!0,allowDuplicatedCategory:!0,angle:0,dataKey:void 0,domain:ex,hide:!0,id:0,includeHidden:!1,interval:"preserveEnd",minTickGap:5,mirror:!1,name:void 0,orientation:"left",padding:{top:0,bottom:0},reversed:!1,scale:"auto",tick:!0,tickCount:5,tickFormatter:void 0,ticks:void 0,type:"number",unit:void 0,niceTicks:"auto",width:_c},OL=(e,t)=>e.cartesianAxis.yAxis[t],Io=(e,t)=>{var n=OL(e,t);return n??cn},Xse={domain:[0,"auto"],includeHidden:!1,reversed:!1,allowDataOverflow:!1,allowDuplicatedCategory:!1,dataKey:void 0,id:0,name:"",range:[64,64],scale:"auto",type:"number",unit:""},Gw=(e,t)=>{var n=e.cartesianAxis.zAxis[t];return n??Xse},nr=(e,t,n)=>{switch(t){case"xAxis":return Ro(e,n);case"yAxis":return Io(e,n);case"zAxis":return Gw(e,n);case"angleAxis":return vw(e,n);case"radiusAxis":return yw(e,n);default:throw new Error("Unexpected axis type: ".concat(t))}},Zse=(e,t,n)=>{switch(t){case"xAxis":return Ro(e,n);case"yAxis":return Io(e,n);default:throw new Error("Unexpected axis type: ".concat(t))}},Nc=(e,t,n)=>{switch(t){case"xAxis":return Ro(e,n);case"yAxis":return Io(e,n);case"angleAxis":return vw(e,n);case"radiusAxis":return yw(e,n);default:throw new Error("Unexpected axis type: ".concat(t))}},PL=e=>e.graphicalItems.cartesianItems.some(t=>t.type==="bar")||e.graphicalItems.polarItems.some(t=>t.type==="radialBar");function AL(e,t){return n=>{switch(e){case"xAxis":return"xAxisId"in n&&n.xAxisId===t;case"yAxis":return"yAxisId"in n&&n.yAxisId===t;case"zAxis":return"zAxisId"in n&&n.zAxisId===t;case"angleAxis":return"angleAxisId"in n&&n.angleAxisId===t;case"radiusAxis":return"radiusAxisId"in n&&n.radiusAxisId===t;default:return!1}}}var qw=e=>e.graphicalItems.cartesianItems,Qse=K([Sn,sg],AL),RL=(e,t,n)=>e.filter(n).filter(r=>t?.includeHidden===!0?!0:!r.hide),Mc=K([qw,nr,Qse],RL,{memoizeOptions:{resultEqualityCheck:cg}}),IL=K([Mc],e=>e.filter(t=>t.type==="area"||t.type==="bar").filter(lg)),TL=e=>e.filter(t=>!("stackId"in t)||t.stackId===void 0),Jse=K([Mc],TL),kL=e=>e.map(t=>t.data).filter(Boolean).flat(1),ele=K([Mc],kL,{memoizeOptions:{resultEqualityCheck:cg}}),NL=(e,t)=>{var{chartData:n=[],dataStartIndex:r,dataEndIndex:i}=t;return e.length>0?e:n.slice(r,i+1)},Kw=K([ele,S2],NL),ML=(e,t,n)=>t?.dataKey!=null?e.map(r=>({value:Mn(r,t.dataKey)})):n.length>0?n.map(r=>r.dataKey).flatMap(r=>e.map(i=>({value:Mn(i,r)}))):e.map(r=>({value:r})),Dc=K([Kw,nr,Mc],ML);function ml(e){if(Vi(e)||e instanceof Date){var t=Number(e);if(dt(t))return t}}function yA(e){if(Array.isArray(e)){var t=[ml(e[0]),ml(e[1])];return Mi(t)?t:void 0}var n=ml(e);if(n!=null)return[n,n]}function So(e){return e.map(ml).filter(dr)}function tle(e,t){var n=ml(e),r=ml(t);return n==null&&r==null?0:n==null?-1:r==null?1:n-r}var nle=K([Dc],e=>e?.map(t=>t.value).sort(tle));function DL(e,t){switch(e){case"xAxis":return t.direction==="x";case"yAxis":return t.direction==="y";default:return!1}}function rle(e,t,n){return!n||typeof t!="number"||Fi(t)?[]:n.length?So(n.flatMap(r=>{var i=Mn(e,r.dataKey),o,a;if(Array.isArray(i)?[o,a]=i:o=a=i,!(!dt(o)||!dt(a)))return[t-o,t+a]})):[]}var gn=e=>{var t=Cn(e),n=Ml(e);return Nc(e,t,n)},jc=K([gn],e=>e?.dataKey),ile=K([IL,S2,gn],W2),jL=(e,t,n,r)=>{var i={},o=t.reduce((a,s)=>{if(s.stackId==null)return a;var u=a[s.stackId];return u==null&&(u=[]),u.push(s),a[s.stackId]=u,a},i);return Object.fromEntries(Object.entries(o).map(a=>{var[s,u]=a,c=r?[...u].reverse():u,f=c.map(xw);return[s,{stackedData:tne(e,f,n),graphicalItems:c}]}))},tx=K([ile,IL,rg,j2],jL),LL=(e,t,n,r)=>{var{dataStartIndex:i,dataEndIndex:o}=t;if(r==null&&n!=="zAxis"){var a=ane(e,i,o);if(!(a!=null&&a[0]===0&&a[1]===0))return a}},ole=K([nr],e=>e.allowDataOverflow),Yw=e=>{var t;if(e==null||!("domain"in e))return ex;if(e.domain!=null)return e.domain;if("ticks"in e&&e.ticks!=null){if(e.type==="number"){var n=So(e.ticks);return[Math.min(...n),Math.max(...n)]}if(e.type==="category")return e.ticks.map(String)}return(t=e?.domain)!==null&&t!==void 0?t:ex},$L=K([nr],Yw),FL=K([$L,ole],C2),ale=K([tx,Po,Sn,FL],LL,{memoizeOptions:{resultEqualityCheck:ug}}),Xw=e=>e.errorBars,sle=(e,t,n)=>e.flatMap(r=>t[r.id]).filter(Boolean).filter(r=>DL(n,r)),Wp=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=n.filter(Boolean);if(i.length!==0){var o=i.flat(),a=Math.min(...o),s=Math.max(...o);return[a,s]}},VL=(e,t,n,r,i)=>{var o,a;if(n.length>0&&e.forEach(s=>{n.forEach(u=>{var c,f,p=(c=r[u.id])===null||c===void 0?void 0:c.filter(w=>DL(i,w)),g=Mn(s,(f=t.dataKey)!==null&&f!==void 0?f:u.dataKey),h=rle(s,g,p);if(h.length>=2){var v=Math.min(...h),b=Math.max(...h);(o==null||v<o)&&(o=v),(a==null||b>a)&&(a=b)}var y=yA(g);y!=null&&(o=o==null?y[0]:Math.min(o,y[0]),a=a==null?y[1]:Math.max(a,y[1]))})}),t?.dataKey!=null&&e.forEach(s=>{var u=yA(Mn(s,t.dataKey));u!=null&&(o=o==null?u[0]:Math.min(o,u[0]),a=a==null?u[1]:Math.max(a,u[1]))}),dt(o)&&dt(a))return[o,a]},lle=K([Kw,nr,Jse,Xw,Sn],VL,{memoizeOptions:{resultEqualityCheck:ug}});function ule(e){var{value:t}=e;if(Vi(t)||t instanceof Date)return t}var cle=(e,t,n)=>{var r=e.map(ule).filter(i=>i!=null);return n&&(t.dataKey==null||t.allowDuplicatedCategory&&KD(r))?x2(0,e.length):t.allowDuplicatedCategory?r:Array.from(new Set(r))},BL=e=>e.referenceElements.dots,jl=(e,t,n)=>e.filter(r=>r.ifOverflow==="extendDomain").filter(r=>t==="xAxis"?r.xAxisId===n:r.yAxisId===n),fle=K([BL,Sn,sg],jl),zL=e=>e.referenceElements.areas,dle=K([zL,Sn,sg],jl),WL=e=>e.referenceElements.lines,ple=K([WL,Sn,sg],jl),HL=(e,t)=>{if(e!=null){var n=So(e.map(r=>t==="xAxis"?r.x:r.y));if(n.length!==0)return[Math.min(...n),Math.max(...n)]}},hle=K(fle,Sn,HL),UL=(e,t)=>{if(e!=null){var n=So(e.flatMap(r=>[t==="xAxis"?r.x1:r.y1,t==="xAxis"?r.x2:r.y2]));if(n.length!==0)return[Math.min(...n),Math.max(...n)]}},gle=K([dle,Sn],UL);function mle(e){var t;if(e.x!=null)return So([e.x]);var n=(t=e.segment)===null||t===void 0?void 0:t.map(r=>r.x);return n==null||n.length===0?[]:So(n)}function vle(e){var t;if(e.y!=null)return So([e.y]);var n=(t=e.segment)===null||t===void 0?void 0:t.map(r=>r.y);return n==null||n.length===0?[]:So(n)}var GL=(e,t)=>{if(e!=null){var n=e.flatMap(r=>t==="xAxis"?mle(r):vle(r));if(n.length!==0)return[Math.min(...n),Math.max(...n)]}},yle=K([ple,Sn],GL),ble=K(hle,yle,gle,(e,t,n)=>Wp(e,n,t)),qL=(e,t,n,r,i,o,a,s)=>{if(n!=null)return n;var u=a==="vertical"&&s==="xAxis"||a==="horizontal"&&s==="yAxis",c=u?Wp(r,o,i):Wp(o,i);return Jie(t,c,e.allowDataOverflow)},xle=K([nr,$L,FL,ale,lle,ble,Rt,Sn],qL,{memoizeOptions:{resultEqualityCheck:ug}}),wle=[0,1],KL=(e,t,n,r,i,o,a)=>{if(!((e==null||n==null||n.length===0)&&a===void 0)){var{dataKey:s,type:u}=e,c=ba(t,o);if(c&&s==null){var f;return x2(0,(f=n?.length)!==null&&f!==void 0?f:0)}return u==="category"?cle(r,e,c):i==="expand"?wle:a}},Zw=K([nr,Rt,Kw,Dc,rg,Sn,xle],KL),Ll=K([nr,PL,hw],CL),YL=(e,t,n)=>{var{niceTicks:r}=t;if(r!=="none"){var i=Yw(t),o=Array.isArray(i)&&(i[0]==="auto"||i[1]==="auto");if((r==="snap125"||r==="adaptive")&&t!=null&&t.tickCount&&Mi(e)){if(o)return AP(e,t.tickCount,t.allowDecimals,r);if(t.type==="number")return RP(e,t.tickCount,t.allowDecimals,r)}if(r==="auto"&&n==="linear"&&t!=null&&t.tickCount){if(o&&Mi(e))return AP(e,t.tickCount,t.allowDecimals,"adaptive");if(t.type==="number"&&Mi(e))return RP(e,t.tickCount,t.allowDecimals,"adaptive")}}},Qw=K([Zw,Nc,Ll],YL),XL=(e,t,n,r)=>{if(r!=="angleAxis"&&e?.type==="number"&&Mi(t)&&Array.isArray(n)&&n.length>0){var i,o,a=t[0],s=(i=n[0])!==null&&i!==void 0?i:0,u=t[1],c=(o=n[n.length-1])!==null&&o!==void 0?o:0;return[Math.min(a,s),Math.max(u,c)]}return t},Sle=K([nr,Zw,Qw,Sn],XL),Cle=K(Dc,nr,(e,t)=>{if(!(!t||t.type!=="number")){var n=1/0,r=Array.from(So(e.map(p=>p.value))).sort((p,g)=>p-g),i=r[0],o=r[r.length-1];if(i==null||o==null)return 1/0;var a=o-i;if(a===0)return 1/0;for(var s=0;s<r.length-1;s++){var u=r[s],c=r[s+1];if(!(u==null||c==null)){var f=c-u;n=Math.min(n,f)}}return n/a}}),ZL=K(Cle,Rt,D2,wn,(e,t,n,r,i)=>i,(e,t,n,r,i)=>{if(!dt(e))return 0;var o=t==="vertical"?r.height:r.width;if(i==="gap")return e*o/2;if(i==="no-gap"){var a=pi(n,e*o),s=e*o/2;return s-a-(s-a)/o*a}return 0}),Ele=(e,t,n)=>{var r=Ro(e,t);return r==null||typeof r.padding!="string"?0:ZL(e,"xAxis",t,n,r.padding)},_le=(e,t,n)=>{var r=Io(e,t);return r==null||typeof r.padding!="string"?0:ZL(e,"yAxis",t,n,r.padding)},Ole=K(Ro,Ele,(e,t)=>{var n,r;if(e==null)return{left:0,right:0};var{padding:i}=e;return typeof i=="string"?{left:t,right:t}:{left:((n=i.left)!==null&&n!==void 0?n:0)+t,right:((r=i.right)!==null&&r!==void 0?r:0)+t}}),Ple=K(Io,_le,(e,t)=>{var n,r;if(e==null)return{top:0,bottom:0};var{padding:i}=e;return typeof i=="string"?{top:t,bottom:t}:{top:((n=i.top)!==null&&n!==void 0?n:0)+t,bottom:((r=i.bottom)!==null&&r!==void 0?r:0)+t}}),Ale=K([wn,Ole,Zh,Xh,(e,t,n)=>n],(e,t,n,r,i)=>{var{padding:o}=r;return i?[o.left,n.width-o.right]:[e.left+t.left,e.left+e.width-t.right]}),Rle=K([wn,Rt,Ple,Zh,Xh,(e,t,n)=>n],(e,t,n,r,i,o)=>{var{padding:a}=i;return o?[r.height-a.bottom,a.top]:t==="horizontal"?[e.top+e.height-n.bottom,e.top+n.top]:[e.top+n.top,e.top+e.height-n.bottom]}),Lc=(e,t,n,r)=>{var i;switch(t){case"xAxis":return Ale(e,n,r);case"yAxis":return Rle(e,n,r);case"zAxis":return(i=Gw(e,n))===null||i===void 0?void 0:i.range;case"angleAxis":return V2(e);case"radiusAxis":return B2(e,n);default:return}},QL=K([nr,Lc],ig),Ile=K([Ll,Sle],poe),Jw=K([nr,Ll,Ile,QL],Uw),JL=(e,t,n,r)=>{if(!(n==null||n.dataKey==null)){var{type:i,scale:o}=n,a=ba(e,r);if(a&&(i==="number"||o!=="auto"))return t.map(s=>s.value)}},eS=K([Rt,Dc,Nc,Sn],JL),vg=K([Jw],ww);K([Jw],Gse);K([Jw,nle],EL);K([Mc,Xw,Sn],sle);function e$(e,t){return e.id<t.id?-1:e.id>t.id?1:0}var yg=(e,t)=>t,bg=(e,t,n)=>n,Tle=K(Kh,yg,bg,(e,t,n)=>e.filter(r=>r.orientation===t).filter(r=>r.mirror===n).sort(e$)),kle=K(Yh,yg,bg,(e,t,n)=>e.filter(r=>r.orientation===t).filter(r=>r.mirror===n).sort(e$)),t$=(e,t)=>({width:e.width,height:t.height}),Nle=(e,t)=>{var n=typeof t.width=="number"?t.width:_c;return{width:n,height:e.height}},n$=K(wn,Ro,t$),Mle=(e,t,n)=>{switch(t){case"top":return e.top;case"bottom":return n-e.bottom;default:return 0}},Dle=(e,t,n)=>{switch(t){case"left":return e.left;case"right":return n-e.right;default:return 0}},jle=K(Oo,wn,Tle,yg,bg,(e,t,n,r,i)=>{var o={},a;return n.forEach(s=>{var u=t$(t,s);a==null&&(a=Mle(t,r,e));var c=r==="top"&&!i||r==="bottom"&&i;o[s.id]=a-Number(c)*u.height,a+=(c?-1:1)*u.height}),o}),Lle=K(_o,wn,kle,yg,bg,(e,t,n,r,i)=>{var o={},a;return n.forEach(s=>{var u=Nle(t,s);a==null&&(a=Dle(t,r,e));var c=r==="left"&&!i||r==="right"&&i;o[s.id]=a-Number(c)*u.width,a+=(c?-1:1)*u.width}),o}),$le=(e,t)=>{var n=Ro(e,t);if(n!=null)return jle(e,n.orientation,n.mirror)},Fle=K([wn,Ro,$le,(e,t)=>t],(e,t,n,r)=>{if(t!=null){var i=n?.[r];return i==null?{x:e.left,y:0}:{x:e.left,y:i}}}),Vle=(e,t)=>{var n=Io(e,t);if(n!=null)return Lle(e,n.orientation,n.mirror)},Ble=K([wn,Io,Vle,(e,t)=>t],(e,t,n,r)=>{if(t!=null){var i=n?.[r];return i==null?{x:0,y:e.top}:{x:i,y:e.top}}}),r$=K(wn,Io,(e,t)=>{var n=typeof t.width=="number"?t.width:_c;return{width:n,height:e.height}}),bA=(e,t,n)=>{switch(t){case"xAxis":return n$(e,n).width;case"yAxis":return r$(e,n).height;default:return}},i$=(e,t,n,r)=>{if(n!=null){var{allowDuplicatedCategory:i,type:o,dataKey:a}=n,s=ba(e,r),u=t.map(c=>c.value);if(a&&s&&o==="category"&&i&&KD(u))return u}},tS=K([Rt,Dc,nr,Sn],i$),xA=K([Rt,Zse,Ll,vg,tS,eS,Lc,Qw,Sn],(e,t,n,r,i,o,a,s,u)=>{if(t!=null){var c=ba(e,u);return{angle:t.angle,interval:t.interval,minTickGap:t.minTickGap,orientation:t.orientation,tick:t.tick,tickCount:t.tickCount,tickFormatter:t.tickFormatter,ticks:t.ticks,type:t.type,unit:t.unit,axisType:u,categoricalDomain:o,duplicateDomain:i,isCategorical:c,niceTicks:s,range:a,realScaleType:n,scale:r}}}),zle=(e,t,n,r,i,o,a,s,u)=>{if(!(t==null||r==null)){var c=ba(e,u),{type:f,ticks:p,tickCount:g}=t,h=n==="scaleBand"&&typeof r.bandwidth=="function"?r.bandwidth()/2:2,v=f==="category"&&r.bandwidth?r.bandwidth()/h:0;v=u==="angleAxis"&&o!=null&&o.length>=2?fr(o[0]-o[1])*2*v:v;var b=p||i;return b?b.map((y,w)=>{var S=a?a.indexOf(y):y,E=r.map(S);return dt(E)?{index:w,coordinate:E+v,value:y,offset:v}:null}).filter(dr):c&&s?s.map((y,w)=>{var S=r.map(y);return dt(S)?{coordinate:S+v,value:y,index:w,offset:v}:null}).filter(dr):r.ticks?r.ticks(g).map((y,w)=>{var S=r.map(y);return dt(S)?{coordinate:S+v,value:y,index:w,offset:v}:null}).filter(dr):r.domain().map((y,w)=>{var S=r.map(y);return dt(S)?{coordinate:S+v,value:a?a[y]:y,index:w,offset:v}:null}).filter(dr)}},o$=K([Rt,Nc,Ll,vg,Qw,Lc,tS,eS,Sn],zle),Wle=(e,t,n,r,i,o,a)=>{if(!(t==null||n==null||r==null||r[0]===r[1])){var s=ba(e,a),{tickCount:u}=t,c=0;return c=a==="angleAxis"&&r?.length>=2?fr(r[0]-r[1])*2*c:c,s&&o?o.map((f,p)=>{var g=n.map(f);return dt(g)?{coordinate:g+c,value:f,index:p,offset:c}:null}).filter(dr):n.ticks?n.ticks(u).map((f,p)=>{var g=n.map(f);return dt(g)?{coordinate:g+c,value:f,index:p,offset:c}:null}).filter(dr):n.domain().map((f,p)=>{var g=n.map(f);return dt(g)?{coordinate:g+c,value:i?i[f]:f,index:p,offset:c}:null}).filter(dr)}},Ol=K([Rt,Nc,vg,Lc,tS,eS,Sn],Wle),Pl=K(nr,vg,(e,t)=>{if(!(e==null||t==null))return zp(zp({},e),{},{scale:t})}),Hle=K([nr,Ll,Zw,QL],Uw),Ule=K([Hle],ww);K((e,t,n)=>Gw(e,n),Ule,(e,t)=>{if(!(e==null||t==null))return zp(zp({},e),{},{scale:t})});var Gle=K([Rt,Kh,Yh],(e,t,n)=>{switch(e){case"horizontal":return t.some(r=>r.reversed)?"right-to-left":"left-to-right";case"vertical":return n.some(r=>r.reversed)?"bottom-to-top":"top-to-bottom";case"centric":case"radial":return"left-to-right";default:return}}),qle=(e,t,n)=>{var r;return(r=e.renderedTicks[t])===null||r===void 0?void 0:r[n]};K([qle],e=>{if(!(!e||e.length===0))return t=>{var n,r=1/0,i=e[0];for(var o of e){var a=Math.abs(o.coordinate-t);a<r&&(r=a,i=o)}return(n=i)===null||n===void 0?void 0:n.value}});var a$=e=>e.options.defaultTooltipEventType,s$=e=>e.options.validateTooltipEventTypes;function l$(e,t,n){if(e==null)return t;var r=e?"axis":"item";return n==null?t:n.includes(r)?r:t}function nS(e,t){var n=a$(e),r=s$(e);return l$(t,n,r)}function Kle(e){return Be(t=>nS(t,e))}var u$=(e,t)=>{var n,r=Number(t);if(!(Fi(r)||t==null))return r>=0?e==null||(n=e[r])===null||n===void 0?void 0:n.value:void 0},Yle=e=>e.tooltip.settings,Jo={active:!1,index:null,dataKey:void 0,graphicalItemId:void 0,coordinate:void 0},Xle={itemInteraction:{click:Jo,hover:Jo},axisInteraction:{click:Jo,hover:Jo},keyboardInteraction:Jo,syncInteraction:{active:!1,index:null,dataKey:void 0,label:void 0,coordinate:void 0,sourceViewBox:void 0,graphicalItemId:void 0},tooltipItemPayloads:[],settings:{shared:void 0,trigger:"hover",axisId:0,active:!1,defaultIndex:void 0}},c$=Hn({name:"tooltip",initialState:Xle,reducers:{addTooltipEntrySettings:{reducer(e,t){e.tooltipItemPayloads.push(t.payload)},prepare:Dt()},replaceTooltipEntrySettings:{reducer(e,t){var{prev:n,next:r}=t.payload,i=Jr(e).tooltipItemPayloads.indexOf(n);i>-1&&(e.tooltipItemPayloads[i]=r)},prepare:Dt()},removeTooltipEntrySettings:{reducer(e,t){var n=Jr(e).tooltipItemPayloads.indexOf(t.payload);n>-1&&e.tooltipItemPayloads.splice(n,1)},prepare:Dt()},setTooltipSettingsState(e,t){e.settings=t.payload},setActiveMouseOverItemIndex(e,t){e.syncInteraction.active=!1,e.keyboardInteraction.active=!1,e.itemInteraction.hover.active=!0,e.itemInteraction.hover.index=t.payload.activeIndex,e.itemInteraction.hover.dataKey=t.payload.activeDataKey,e.itemInteraction.hover.graphicalItemId=t.payload.activeGraphicalItemId,e.itemInteraction.hover.coordinate=t.payload.activeCoordinate},mouseLeaveChart(e){e.itemInteraction.hover.active=!1,e.axisInteraction.hover.active=!1},mouseLeaveItem(e){e.itemInteraction.hover.active=!1},setActiveClickItemIndex(e,t){e.syncInteraction.active=!1,e.itemInteraction.click.active=!0,e.keyboardInteraction.active=!1,e.itemInteraction.click.index=t.payload.activeIndex,e.itemInteraction.click.dataKey=t.payload.activeDataKey,e.itemInteraction.click.graphicalItemId=t.payload.activeGraphicalItemId,e.itemInteraction.click.coordinate=t.payload.activeCoordinate},setMouseOverAxisIndex(e,t){e.syncInteraction.active=!1,e.axisInteraction.hover.active=!0,e.keyboardInteraction.active=!1,e.axisInteraction.hover.index=t.payload.activeIndex,e.axisInteraction.hover.dataKey=t.payload.activeDataKey,e.axisInteraction.hover.coordinate=t.payload.activeCoordinate},setMouseClickAxisIndex(e,t){e.syncInteraction.active=!1,e.keyboardInteraction.active=!1,e.axisInteraction.click.active=!0,e.axisInteraction.click.index=t.payload.activeIndex,e.axisInteraction.click.dataKey=t.payload.activeDataKey,e.axisInteraction.click.coordinate=t.payload.activeCoordinate},setSyncInteraction(e,t){e.syncInteraction=t.payload},setKeyboardInteraction(e,t){e.keyboardInteraction.active=t.payload.active,e.keyboardInteraction.index=t.payload.activeIndex,e.keyboardInteraction.coordinate=t.payload.activeCoordinate}}}),{addTooltipEntrySettings:Zle,replaceTooltipEntrySettings:Qle,removeTooltipEntrySettings:Jle,setTooltipSettingsState:eue,setActiveMouseOverItemIndex:f$,mouseLeaveItem:tue,mouseLeaveChart:d$,setActiveClickItemIndex:nue,setMouseOverAxisIndex:p$,setMouseClickAxisIndex:rue,setSyncInteraction:nx,setKeyboardInteraction:Hp}=c$.actions,iue=c$.reducer;function wA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ed(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?wA(Object(n),!0).forEach(function(r){oue(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function oue(e,t,n){return(t=aue(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function aue(e){var t=sue(e,"string");return typeof t=="symbol"?t:t+""}function sue(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function lue(e,t,n){return t==="axis"?n==="click"?e.axisInteraction.click:e.axisInteraction.hover:n==="click"?e.itemInteraction.click:e.itemInteraction.hover}function uue(e){return e.index!=null}var h$=(e,t,n,r)=>{if(t==null)return Jo;var i=lue(e,t,n);if(i==null)return Jo;if(i.active)return i;if(e.keyboardInteraction.active)return e.keyboardInteraction;if(e.syncInteraction.active&&e.syncInteraction.index!=null)return e.syncInteraction;var o=e.settings.active===!0;if(uue(i)){if(o)return Ed(Ed({},i),{},{active:!0})}else if(r!=null)return{active:!0,coordinate:void 0,dataKey:void 0,index:r,graphicalItemId:void 0};return Ed(Ed({},Jo),{},{coordinate:i.coordinate})};function cue(e){if(typeof e=="number")return Number.isFinite(e)?e:void 0;if(e instanceof Date){var t=e.valueOf();return Number.isFinite(t)?t:void 0}var n=Number(e);return Number.isFinite(n)?n:void 0}function fue(e,t){var n=cue(e),r=t[0],i=t[1];if(n===void 0)return!1;var o=Math.min(r,i),a=Math.max(r,i);return n>=o&&n<=a}function due(e,t,n){if(n==null||t==null)return!0;var r=Mn(e,t);return r==null||!Mi(n)?!0:fue(r,n)}var rS=(e,t,n,r)=>{var i=e?.index;if(i==null)return null;var o=Number(i);if(!dt(o))return i;var a=0,s=1/0;t.length>0&&(s=t.length-1);var u=Math.max(a,Math.min(o,s)),c=t[u];return c==null||due(c,n,r)?String(u):null},g$=(e,t,n,r,i,o,a)=>{if(o!=null){var s=a[0],u=s?.getPosition(o);if(u!=null)return u;var c=i?.[Number(o)];if(c)return n==="horizontal"?{x:c.coordinate,y:(r.top+t)/2}:{x:(r.left+e)/2,y:c.coordinate}}},m$=(e,t,n,r)=>{if(t==="axis")return e.tooltipItemPayloads;if(e.tooltipItemPayloads.length===0)return[];var i;if(n==="hover"?i=e.itemInteraction.hover.graphicalItemId:i=e.itemInteraction.click.graphicalItemId,e.syncInteraction.active&&i==null)return e.tooltipItemPayloads;if(i==null&&r!=null){var o=e.tooltipItemPayloads[0];return o!=null?[o]:[]}return e.tooltipItemPayloads.filter(a=>{var s;return((s=a.settings)===null||s===void 0?void 0:s.graphicalItemId)===i})},v$=e=>e.options.tooltipPayloadSearcher,$l=e=>e.tooltip;function SA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function CA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?SA(Object(n),!0).forEach(function(r){pue(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):SA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function pue(e,t,n){return(t=hue(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function hue(e){var t=gue(e,"string");return typeof t=="symbol"?t:t+""}function gue(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function mue(e){if(typeof e=="string"||typeof e=="number")return e}function vue(e){if(typeof e=="string"||typeof e=="number"||typeof e=="boolean")return e}function yue(e){if(typeof e=="string"||typeof e=="number")return e;if(typeof e=="function")return t=>e(t)}function EA(e){if(typeof e=="string")return e}function bue(e){if(!(e==null||typeof e!="object")){var t="name"in e?mue(e.name):void 0,n="unit"in e?vue(e.unit):void 0,r="dataKey"in e?yue(e.dataKey):void 0,i="payload"in e?e.payload:void 0,o="color"in e?EA(e.color):void 0,a="fill"in e?EA(e.fill):void 0;return{name:t,unit:n,dataKey:r,payload:i,color:o,fill:a}}}function xue(e,t){return e??t}var y$=(e,t,n,r,i,o,a)=>{if(!(t==null||o==null)){var{chartData:s,computedData:u,dataStartIndex:c,dataEndIndex:f}=n,p=[];return e.reduce((g,h)=>{var v,{dataDefinedOnItem:b,settings:y}=h,w=xue(b,s),S=Array.isArray(w)?Wj(w,c,f):w,E=(v=y?.dataKey)!==null&&v!==void 0?v:r,_=y?.nameKey,P;if(r&&Array.isArray(S)&&!Array.isArray(S[0])&&a==="axis"?P=LJ(S,r,i):P=o(S,t,u,_),Array.isArray(P))P.forEach(I=>{var k,B,L=bue(I),V=L?.name,D=L?.dataKey,W=L?.payload,J=CA(CA({},y),{},{name:V,unit:L?.unit,color:(k=L?.color)!==null&&k!==void 0?k:y?.color,fill:(B=L?.fill)!==null&&B!==void 0?B:y?.fill});g.push(vO({tooltipEntrySettings:J,dataKey:D,payload:W,value:Mn(W,D),name:V==null?void 0:String(V)}))});else{var R;g.push(vO({tooltipEntrySettings:y,dataKey:E,payload:P,value:Mn(P,E),name:(R=Mn(P,_))!==null&&R!==void 0?R:y?.name}))}return g},p)}},iS=K([gn,PL,hw],CL),wue=K([e=>e.graphicalItems.cartesianItems,e=>e.graphicalItems.polarItems],(e,t)=>[...e,...t]),Sue=K([Cn,Ml],AL),Fl=K([wue,gn,Sue],RL,{memoizeOptions:{resultEqualityCheck:cg}}),Cue=K([Fl],e=>e.filter(lg)),Eue=K([Fl],kL,{memoizeOptions:{resultEqualityCheck:cg}}),Vl=K([Eue,Po],NL),_ue=K([Cue,Po,gn],W2),oS=K([Vl,gn,Fl],ML),b$=K([gn],Yw),Oue=K([gn],e=>e.allowDataOverflow),x$=K([b$,Oue],C2),Pue=K([Fl],e=>e.filter(lg)),Aue=K([_ue,Pue,rg,j2],jL),Rue=K([Aue,Po,Cn,x$],LL),Iue=K([Fl],TL),Tue=K([Vl,gn,Iue,Xw,Cn],VL,{memoizeOptions:{resultEqualityCheck:ug}}),kue=K([BL,Cn,Ml],jl),Nue=K([kue,Cn],HL),Mue=K([zL,Cn,Ml],jl),Due=K([Mue,Cn],UL),jue=K([WL,Cn,Ml],jl),Lue=K([jue,Cn],GL),$ue=K([Nue,Lue,Due],Wp),Fue=K([gn,b$,x$,Rue,Tue,$ue,Rt,Cn],qL),$c=K([gn,Rt,Vl,oS,rg,Cn,Fue],KL),Vue=K([$c,gn,iS],YL),Bue=K([gn,$c,Vue,Cn],XL),w$=e=>{var t=Cn(e),n=Ml(e),r=!1;return Lc(e,t,n,r)},S$=K([gn,w$],ig),zue=K([gn,iS,Bue,S$],Uw),C$=K([zue],ww),Wue=K([Rt,oS,gn,Cn],i$),Hue=K([Rt,oS,gn,Cn],JL),Uue=(e,t,n,r,i,o,a,s)=>{if(t){var{type:u}=t,c=ba(e,s);if(r){var f=n==="scaleBand"&&r.bandwidth?r.bandwidth()/2:2,p=u==="category"&&r.bandwidth?r.bandwidth()/f:0;return p=s==="angleAxis"&&i!=null&&i?.length>=2?fr(i[0]-i[1])*2*p:p,c&&a?a.map((g,h)=>{var v=r.map(g);return dt(v)?{coordinate:v+p,value:g,index:h,offset:p}:null}).filter(dr):r.domain().map((g,h)=>{var v=r.map(g);return dt(v)?{coordinate:v+p,value:o?o[g]:g,index:h,offset:p}:null}).filter(dr)}}},To=K([Rt,gn,iS,C$,w$,Wue,Hue,Cn],Uue),aS=K([a$,s$,Yle],(e,t,n)=>l$(n.shared,e,t)),E$=e=>e.tooltip.settings.trigger,sS=e=>e.tooltip.settings.defaultIndex,Fc=K([$l,aS,E$,sS],h$),Al=K([Fc,Vl,jc,$c],rS),_$=K([To,Al],u$),O$=K([Fc],e=>{if(e)return e.dataKey}),Gue=K([Fc],e=>{if(e)return e.graphicalItemId}),P$=K([$l,aS,E$,sS],m$),que=K([_o,Oo,Rt,wn,To,sS,P$],g$),Kue=K([Fc,que],(e,t)=>e!=null&&e.coordinate?e.coordinate:t),Yue=K([Fc],e=>{var t;return(t=e?.active)!==null&&t!==void 0?t:!1}),Xue=K([P$,Al,Po,jc,_$,v$,aS],y$);K([Xue],e=>{if(e!=null){var t=e.map(n=>n.payload).filter(n=>n!=null);return Array.from(new Set(t))}});function _A(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function OA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?_A(Object(n),!0).forEach(function(r){Zue(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_A(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Zue(e,t,n){return(t=Que(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Que(e){var t=Jue(e,"string");return typeof t=="symbol"?t:t+""}function Jue(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var ece=()=>Be(gn),tce=()=>{var e=ece(),t=Be(To),n=Be(C$);return xp(!e||!n?void 0:OA(OA({},e),{},{scale:n}),t)};function PA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function tl(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?PA(Object(n),!0).forEach(function(r){nce(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):PA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function nce(e,t,n){return(t=rce(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function rce(e){var t=ice(e,"string");return typeof t=="symbol"?t:t+""}function ice(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var oce=(e,t,n,r)=>{var i=t.find(o=>o&&o.index===n);if(i){if(e==="horizontal")return{x:i.coordinate,y:r.relativeY};if(e==="vertical")return{x:r.relativeX,y:i.coordinate}}return{x:0,y:0}},ace=(e,t,n,r)=>{var i=t.find(c=>c&&c.index===n);if(i){if(e==="centric"){var o=i.coordinate,{radius:a}=r;return tl(tl(tl({},r),kn(r.cx,r.cy,a,o)),{},{angle:o,radius:a})}var s=i.coordinate,{angle:u}=r;return tl(tl(tl({},r),kn(r.cx,r.cy,s,u)),{},{angle:u,radius:s})}return{angle:0,clockWise:!1,cx:0,cy:0,endAngle:0,innerRadius:0,outerRadius:0,radius:0,startAngle:0,x:0,y:0}};function sce(e,t){var{relativeX:n,relativeY:r}=e;return n>=t.left&&n<=t.left+t.width&&r>=t.top&&r<=t.top+t.height}var A$=(e,t,n,r,i)=>{var o,a=(o=t?.length)!==null&&o!==void 0?o:0;if(a<=1||e==null)return 0;if(r==="angleAxis"&&i!=null&&Math.abs(Math.abs(i[1]-i[0])-360)<=1e-6)for(var s=0;s<a;s++){var u,c,f,p,g,h=s>0?(u=n[s-1])===null||u===void 0?void 0:u.coordinate:(c=n[a-1])===null||c===void 0?void 0:c.coordinate,v=(f=n[s])===null||f===void 0?void 0:f.coordinate,b=s>=a-1?(p=n[0])===null||p===void 0?void 0:p.coordinate:(g=n[s+1])===null||g===void 0?void 0:g.coordinate,y=void 0;if(!(h==null||v==null||b==null))if(fr(v-h)!==fr(b-v)){var w=[];if(fr(b-v)===fr(i[1]-i[0])){y=b;var S=v+i[1]-i[0];w[0]=Math.min(S,(S+h)/2),w[1]=Math.max(S,(S+h)/2)}else{y=h;var E=b+i[1]-i[0];w[0]=Math.min(v,(E+v)/2),w[1]=Math.max(v,(E+v)/2)}var _=[Math.min(v,(y+v)/2),Math.max(v,(y+v)/2)];if(e>_[0]&&e<=_[1]||e>=w[0]&&e<=w[1]){var P;return(P=n[s])===null||P===void 0?void 0:P.index}}else{var R=Math.min(h,b),I=Math.max(h,b);if(e>(R+v)/2&&e<=(I+v)/2){var k;return(k=n[s])===null||k===void 0?void 0:k.index}}}else if(t)for(var B=0;B<a;B++){var L=t[B];if(L!=null){var V=t[B+1],D=t[B-1];if(B===0&&V!=null&&e<=(L.coordinate+V.coordinate)/2||B===a-1&&D!=null&&e>(L.coordinate+D.coordinate)/2||B>0&&B<a-1&&D!=null&&V!=null&&e>(L.coordinate+D.coordinate)/2&&e<=(L.coordinate+V.coordinate)/2)return L.index}}return-1},lce=()=>Be(hw),lS=(e,t)=>t,R$=(e,t,n)=>n,uS=(e,t,n,r)=>r,uce=K(To,e=>Fh(e,t=>t.coordinate)),cS=K([$l,lS,R$,uS],h$),fS=K([cS,Vl,jc,$c],rS),cce=(e,t,n)=>{if(t!=null){var r=$l(e);return t==="axis"?n==="hover"?r.axisInteraction.hover.dataKey:r.axisInteraction.click.dataKey:n==="hover"?r.itemInteraction.hover.dataKey:r.itemInteraction.click.dataKey}},I$=K([$l,lS,R$,uS],m$),Up=K([_o,Oo,Rt,wn,To,uS,I$],g$),fce=K([cS,Up],(e,t)=>{var n;return(n=e.coordinate)!==null&&n!==void 0?n:t}),T$=K([To,fS],u$),dce=K([I$,fS,Po,jc,T$,v$,lS],y$),pce=K([cS,fS],(e,t)=>({isActive:e.active&&t!=null,activeIndex:t})),hce=(e,t,n,r,i,o,a)=>{if(!(!e||!n||!r||!i)&&sce(e,a)){var s=sne(e,t),u=A$(s,o,i,n,r),c=oce(t,i,u,e);return{activeIndex:String(u),activeCoordinate:c}}},gce=(e,t,n,r,i,o,a)=>{if(!(!e||!r||!i||!o||!n)){var s=zie(e,n);if(s){var u=lne(s,t),c=A$(u,a,o,r,i),f=ace(t,o,c,s);return{activeIndex:String(c),activeCoordinate:f}}}},mce=(e,t,n,r,i,o,a,s)=>{if(!(!e||!t||!r||!i||!o))return t==="horizontal"||t==="vertical"?hce(e,t,r,i,o,a,s):gce(e,t,n,r,i,o,a)},vce=K(e=>e.zIndex.zIndexMap,(e,t)=>t,(e,t,n)=>n,(e,t,n)=>{if(t!=null){var r=e[t];if(r!=null)return n?r.panoramaElement:r.element}}),yce=K(e=>e.zIndex.zIndexMap,e=>{var t=Object.keys(e).map(r=>parseInt(r,10)).concat(Object.values(Qn)),n=Array.from(new Set(t));return n.sort((r,i)=>r-i)},{memoizeOptions:{resultEqualityCheck:doe}});function AA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function RA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?AA(Object(n),!0).forEach(function(r){bce(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):AA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function bce(e,t,n){return(t=xce(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function xce(e){var t=wce(e,"string");return typeof t=="symbol"?t:t+""}function wce(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Sce={},Cce={zIndexMap:Object.values(Qn).reduce((e,t)=>RA(RA({},e),{},{[t]:{element:void 0,panoramaElement:void 0,consumers:0}}),Sce)},Ece=new Set(Object.values(Qn));function _ce(e){return Ece.has(e)}var k$=Hn({name:"zIndex",initialState:Cce,reducers:{registerZIndexPortal:{reducer:(e,t)=>{var{zIndex:n}=t.payload;e.zIndexMap[n]?e.zIndexMap[n].consumers+=1:e.zIndexMap[n]={consumers:1,element:void 0,panoramaElement:void 0}},prepare:Dt()},unregisterZIndexPortal:{reducer:(e,t)=>{var{zIndex:n}=t.payload;e.zIndexMap[n]&&(e.zIndexMap[n].consumers-=1,e.zIndexMap[n].consumers<=0&&!_ce(n)&&delete e.zIndexMap[n])},prepare:Dt()},registerZIndexPortalElement:{reducer:(e,t)=>{var{zIndex:n,element:r,isPanorama:i}=t.payload;e.zIndexMap[n]?i?e.zIndexMap[n].panoramaElement=r:e.zIndexMap[n].element=r:e.zIndexMap[n]={consumers:0,element:i?void 0:r,panoramaElement:i?r:void 0}},prepare:Dt()},unregisterZIndexPortalElement:{reducer:(e,t)=>{var{zIndex:n}=t.payload;e.zIndexMap[n]&&(t.payload.isPanorama?e.zIndexMap[n].panoramaElement=void 0:e.zIndexMap[n].element=void 0)},prepare:Dt()}}}),{registerZIndexPortal:Oce,unregisterZIndexPortal:Pce,registerZIndexPortalElement:Ace,unregisterZIndexPortalElement:Rce}=k$.actions,Ice=k$.reducer;function ko(e){var{zIndex:t,children:n}=e,r=Bne(),i=r&&t!==void 0&&t!==0,o=hr(),a=Ut();$.useLayoutEffect(()=>i?(a(Oce({zIndex:t})),()=>{a(Pce({zIndex:t}))}):ys,[a,t,i]);var s=Be(u=>vce(u,t,o));return i?s?Jp.createPortal(n,s):null:n}function rx(){return rx=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},rx.apply(null,arguments)}function IA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function _d(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?IA(Object(n),!0).forEach(function(r){Tce(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):IA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Tce(e,t,n){return(t=kce(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function kce(e){var t=Nce(e,"string");return typeof t=="symbol"?t:t+""}function Nce(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Mce(e){var{cursor:t,cursorComp:n,cursorProps:r}=e;return $.isValidElement(t)?$.cloneElement(t,r):$.createElement(n,r)}function Dce(e){var t,{coordinate:n,payload:r,index:i,offset:o,tooltipAxisBandSize:a,layout:s,cursor:u,tooltipEventType:c,chartName:f}=e,p=n,g=r,h=i;if(!u||!p||f!=="ScatterChart"&&c!=="axis")return null;var v,b,y;if(f==="ScatterChart")v=p,b=nie,y=Qn.cursorLine;else if(f==="BarChart")v=rie(s,p,o,a),b=m2,y=Qn.cursorRectangle;else if(s==="radial"&&ZD(p)){var{cx:w,cy:S,radius:E,startAngle:_,endAngle:P}=v2(p);v={cx:w,cy:S,startAngle:_,endAngle:P,innerRadius:E,outerRadius:E},b=b2,y=Qn.cursorLine}else v={points:Gie(s,p,o)},b=f2,y=Qn.cursorLine;var R=typeof u=="object"&&"className"in u?u.className:void 0,I=_d(_d(_d(_d({stroke:"#ccc",pointerEvents:"none"},o),v),z0(u)),{},{payload:g,payloadIndex:h,className:At("recharts-tooltip-cursor",R)});return x.createElement(ko,{zIndex:(t=e.zIndex)!==null&&t!==void 0?t:y},x.createElement(Mce,{cursor:u,cursorComp:b,cursorProps:I}))}function jce(e){var t=tce(),n=Zj(),r=Tl(),i=lce();return t==null||n==null||r==null||i==null?null:x.createElement(Dce,rx({},e,{offset:n,layout:r,tooltipAxisBandSize:t,chartName:i}))}var N$=$.createContext(null),Lce=()=>$.useContext(N$),Ey={exports:{}},TA;function $ce(){return TA||(TA=1,(function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}Object.create&&(r.prototype=Object.create(null),new r().__proto__||(n=!1));function i(u,c,f){this.fn=u,this.context=c,this.once=f||!1}function o(u,c,f,p,g){if(typeof f!="function")throw new TypeError("The listener must be a function");var h=new i(f,p||u,g),v=n?n+c:c;return u._events[v]?u._events[v].fn?u._events[v]=[u._events[v],h]:u._events[v].push(h):(u._events[v]=h,u._eventsCount++),u}function a(u,c){--u._eventsCount===0?u._events=new r:delete u._events[c]}function s(){this._events=new r,this._eventsCount=0}s.prototype.eventNames=function(){var c=[],f,p;if(this._eventsCount===0)return c;for(p in f=this._events)t.call(f,p)&&c.push(n?p.slice(1):p);return Object.getOwnPropertySymbols?c.concat(Object.getOwnPropertySymbols(f)):c},s.prototype.listeners=function(c){var f=n?n+c:c,p=this._events[f];if(!p)return[];if(p.fn)return[p.fn];for(var g=0,h=p.length,v=new Array(h);g<h;g++)v[g]=p[g].fn;return v},s.prototype.listenerCount=function(c){var f=n?n+c:c,p=this._events[f];return p?p.fn?1:p.length:0},s.prototype.emit=function(c,f,p,g,h,v){var b=n?n+c:c;if(!this._events[b])return!1;var y=this._events[b],w=arguments.length,S,E;if(y.fn){switch(y.once&&this.removeListener(c,y.fn,void 0,!0),w){case 1:return y.fn.call(y.context),!0;case 2:return y.fn.call(y.context,f),!0;case 3:return y.fn.call(y.context,f,p),!0;case 4:return y.fn.call(y.context,f,p,g),!0;case 5:return y.fn.call(y.context,f,p,g,h),!0;case 6:return y.fn.call(y.context,f,p,g,h,v),!0}for(E=1,S=new Array(w-1);E<w;E++)S[E-1]=arguments[E];y.fn.apply(y.context,S)}else{var _=y.length,P;for(E=0;E<_;E++)switch(y[E].once&&this.removeListener(c,y[E].fn,void 0,!0),w){case 1:y[E].fn.call(y[E].context);break;case 2:y[E].fn.call(y[E].context,f);break;case 3:y[E].fn.call(y[E].context,f,p);break;case 4:y[E].fn.call(y[E].context,f,p,g);break;default:if(!S)for(P=1,S=new Array(w-1);P<w;P++)S[P-1]=arguments[P];y[E].fn.apply(y[E].context,S)}}return!0},s.prototype.on=function(c,f,p){return o(this,c,f,p,!1)},s.prototype.once=function(c,f,p){return o(this,c,f,p,!0)},s.prototype.removeListener=function(c,f,p,g){var h=n?n+c:c;if(!this._events[h])return this;if(!f)return a(this,h),this;var v=this._events[h];if(v.fn)v.fn===f&&(!g||v.once)&&(!p||v.context===p)&&a(this,h);else{for(var b=0,y=[],w=v.length;b<w;b++)(v[b].fn!==f||g&&!v[b].once||p&&v[b].context!==p)&&y.push(v[b]);y.length?this._events[h]=y.length===1?y[0]:y:a(this,h)}return this},s.prototype.removeAllListeners=function(c){var f;return c?(f=n?n+c:c,this._events[f]&&a(this,f)):(this._events=new r,this._eventsCount=0),this},s.prototype.off=s.prototype.removeListener,s.prototype.addListener=s.prototype.on,s.prefixed=n,s.EventEmitter=s,e.exports=s})(Ey)),Ey.exports}var Fce=$ce();const Vce=vs(Fce);var uc=new Vce,ix="recharts.syncEvent.tooltip",kA="recharts.syncEvent.brush",Bce=(e,t)=>{if(t&&Array.isArray(e)){var n=Number.parseInt(t,10);if(!Fi(n))return e[n]}},zce={chartName:"",tooltipPayloadSearcher:()=>{},eventEmitter:void 0,defaultTooltipEventType:"axis"},M$=Hn({name:"options",initialState:zce,reducers:{createEventEmitter:e=>{e.eventEmitter==null&&(e.eventEmitter=Symbol("rechartsEventEmitter"))}}}),Wce=M$.reducer,{createEventEmitter:Hce}=M$.actions;function Uce(e){return e.tooltip.syncInteraction}var Gce={chartData:void 0,computedData:void 0,dataStartIndex:0,dataEndIndex:0},D$=Hn({name:"chartData",initialState:Gce,reducers:{setChartData(e,t){if(e.chartData=t.payload,t.payload==null){e.dataStartIndex=0,e.dataEndIndex=0;return}t.payload.length>0&&e.dataEndIndex!==t.payload.length-1&&(e.dataEndIndex=t.payload.length-1)},setComputedData(e,t){e.computedData=t.payload},setDataStartEndIndexes(e,t){var{startIndex:n,endIndex:r}=t.payload;n!=null&&(e.dataStartIndex=n),r!=null&&(e.dataEndIndex=r)}}}),{setChartData:NA,setDataStartEndIndexes:qce,setComputedData:mve}=D$.actions,Kce=D$.reducer,Yce=["x","y"];function MA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function nl(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?MA(Object(n),!0).forEach(function(r){Xce(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):MA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Xce(e,t,n){return(t=Zce(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Zce(e){var t=Qce(e,"string");return typeof t=="symbol"?t:t+""}function Qce(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Jce(e,t){if(e==null)return{};var n,r,i=efe(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function efe(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function tfe(){var e=Be(gw),t=Be(mw),n=Ut(),r=Be(L2),i=Be(To),o=Tl(),a=Qh(),s=Be(u=>u.rootProps.className);$.useEffect(()=>{if(e==null)return ys;var u=(c,f,p)=>{if(t!==p&&e===c){if(r==="index"){var g;if(a&&f!==null&&f!==void 0&&(g=f.payload)!==null&&g!==void 0&&g.coordinate&&f.payload.sourceViewBox){var h=f.payload.coordinate,{x:v,y:b}=h,y=Jce(h,Yce),{x:w,y:S,width:E,height:_}=f.payload.sourceViewBox,P=nl(nl({},y),{},{x:a.x+(E?(v-w)/E:0)*a.width,y:a.y+(_?(b-S)/_:0)*a.height});n(nl(nl({},f),{},{payload:nl(nl({},f.payload),{},{coordinate:P})}))}else n(f);return}if(i!=null){var R;if(typeof r=="function"){var I={activeTooltipIndex:f.payload.index==null?void 0:Number(f.payload.index),isTooltipActive:f.payload.active,activeIndex:f.payload.index==null?void 0:Number(f.payload.index),activeLabel:f.payload.label,activeDataKey:f.payload.dataKey,activeCoordinate:f.payload.coordinate},k=r(i,I);R=i[k]}else r==="value"&&(R=i.find(U=>String(U.value)===f.payload.label));var{coordinate:B}=f.payload;if(R==null||f.payload.active===!1||B==null||a==null){n(nx({active:!1,coordinate:void 0,dataKey:void 0,index:null,label:void 0,sourceViewBox:void 0,graphicalItemId:void 0}));return}var{x:L,y:V}=B,D=Math.min(L,a.x+a.width),W=Math.min(V,a.y+a.height),J={x:o==="horizontal"?R.coordinate:D,y:o==="horizontal"?W:R.coordinate},re=nx({active:f.payload.active,coordinate:J,dataKey:f.payload.dataKey,index:String(R.index),label:f.payload.label,sourceViewBox:f.payload.sourceViewBox,graphicalItemId:f.payload.graphicalItemId});n(re)}}};return uc.on(ix,u),()=>{uc.off(ix,u)}},[s,n,t,e,r,i,o,a])}function nfe(){var e=Be(gw),t=Be(mw),n=Ut();$.useEffect(()=>{if(e==null)return ys;var r=(i,o,a)=>{t!==a&&e===i&&n(qce(o))};return uc.on(kA,r),()=>{uc.off(kA,r)}},[n,t,e])}function rfe(){var e=Ut();$.useEffect(()=>{e(Hce())},[e]),tfe(),nfe()}function ife(e,t,n,r,i,o){var a=Be(v=>cce(v,e,t)),s=Be(Gue),u=Be(mw),c=Be(gw),f=Be(L2),p=Be(Uce),g=p?.active,h=Qh();$.useEffect(()=>{if(!g&&c!=null&&u!=null){var v=nx({active:o,coordinate:n,dataKey:a,index:i,label:typeof r=="number"?String(r):r,sourceViewBox:h,graphicalItemId:s});uc.emit(ix,c,v,u)}},[g,n,a,s,i,r,u,c,f,o,h])}function DA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function jA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?DA(Object(n),!0).forEach(function(r){ofe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):DA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ofe(e,t,n){return(t=afe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function afe(e){var t=sfe(e,"string");return typeof t=="symbol"?t:t+""}function sfe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function lfe(e){return e.dataKey}function ufe(e,t){return x.isValidElement(e)?x.cloneElement(e,t):typeof e=="function"?x.createElement(e,t):x.createElement(Tre,t)}var LA=[],cfe={allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",axisId:0,contentStyle:{},cursor:!0,filterNull:!0,includeHidden:!1,isAnimationActive:"auto",itemSorter:"name",itemStyle:{},labelStyle:{},offset:10,reverseDirection:{x:!1,y:!1},separator:" : ",trigger:"hover",useTranslate3d:!1,wrapperStyle:{}};function ffe(e){var t,n,r=Dr(e,cfe),{active:i,allowEscapeViewBox:o,animationDuration:a,animationEasing:s,content:u,filterNull:c,isAnimationActive:f,offset:p,payloadUniqBy:g,position:h,reverseDirection:v,useTranslate3d:b,wrapperStyle:y,cursor:w,shared:S,trigger:E,defaultIndex:_,portal:P,axisId:R}=r,I=Ut(),k=typeof _=="number"?String(_):_;$.useEffect(()=>{I(eue({shared:S,trigger:E,axisId:R,active:i,defaultIndex:k}))},[I,S,E,R,i,k]);var B=Qh(),L=c2(),V=Kle(S),{activeIndex:D,isActive:W}=(t=Be(Se=>pce(Se,V,E,k)))!==null&&t!==void 0?t:{},J=Be(Se=>dce(Se,V,E,k)),re=Be(Se=>T$(Se,V,E,k)),U=Be(Se=>fce(Se,V,E,k)),ee=J,Z=Lce(),ue=(n=i??W)!==null&&n!==void 0?n:!1,[X,Oe]=Nee([ee,ue]),Ee=V==="axis"?re:void 0;ife(V,E,U,Ee,D,ue);var Me=P??Z;if(Me==null||B==null||V==null)return null;var ye=ee??LA;ue||(ye=LA),c&&ye.length&&(ye=xee(ye.filter(Se=>Se.value!=null&&(Se.hide!==!0||r.includeHidden)),g,lfe));var be=ye.length>0,$e=jA(jA({},r),{},{payload:ye,label:Ee,active:ue,activeIndex:D,coordinate:U,accessibilityLayer:L}),me=x.createElement(zre,{allowEscapeViewBox:o,animationDuration:a,animationEasing:s,isAnimationActive:f,active:ue,coordinate:U,hasPayload:be,offset:p,position:h,reverseDirection:v,useTranslate3d:b,viewBox:B,wrapperStyle:y,lastBoundingBox:X,innerRef:Oe,hasPortalFromProps:!!P},ufe(u,$e));return x.createElement(x.Fragment,null,Jp.createPortal(me,Me),ue&&x.createElement(jce,{cursor:w,tooltipEventType:V,coordinate:U,payload:ye,index:D}))}var j$=e=>null;j$.displayName="Cell";function dfe(e,t,n){return(t=pfe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pfe(e){var t=hfe(e,"string");return typeof t=="symbol"?t:t+""}function hfe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}class gfe{constructor(t){dfe(this,"cache",new Map),this.maxSize=t}get(t){var n=this.cache.get(t);return n!==void 0&&(this.cache.delete(t),this.cache.set(t,n)),n}set(t,n){if(this.cache.has(t))this.cache.delete(t);else if(this.cache.size>=this.maxSize){var r=this.cache.keys().next().value;r!=null&&this.cache.delete(r)}this.cache.set(t,n)}clear(){this.cache.clear()}size(){return this.cache.size}}function $A(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function mfe(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?$A(Object(n),!0).forEach(function(r){vfe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$A(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function vfe(e,t,n){return(t=yfe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function yfe(e){var t=bfe(e,"string");return typeof t=="symbol"?t:t+""}function bfe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var xfe={cacheSize:2e3,enableCache:!0},L$=mfe({},xfe),FA=new gfe(L$.cacheSize),wfe={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},VA="recharts_measurement_span";function Sfe(e,t){var n=t.fontSize||"",r=t.fontFamily||"",i=t.fontWeight||"",o=t.fontStyle||"",a=t.letterSpacing||"",s=t.textTransform||"";return"".concat(e,"|").concat(n,"|").concat(r,"|").concat(i,"|").concat(o,"|").concat(a,"|").concat(s)}var BA=(e,t)=>{try{var n=document.getElementById(VA);n||(n=document.createElement("span"),n.setAttribute("id",VA),n.setAttribute("aria-hidden","true"),document.body.appendChild(n)),Object.assign(n.style,wfe,t),n.textContent="".concat(e);var r=n.getBoundingClientRect();return{width:r.width,height:r.height}}catch{return{width:0,height:0}}},Wu=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(t==null||Ac.isSsr)return{width:0,height:0};if(!L$.enableCache)return BA(t,n);var r=Sfe(t,n),i=FA.get(r);if(i)return i;var o=BA(t,n);return FA.set(r,o),o},$$;function Cfe(e,t,n){return(t=Efe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Efe(e){var t=_fe(e,"string");return typeof t=="symbol"?t:t+""}function _fe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var zA=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,WA=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,Ofe=/^(px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q)$/,Pfe=/(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/,Afe={cm:96/2.54,mm:96/25.4,pt:96/72,pc:96/6,in:96,Q:96/(2.54*40),px:1},Rfe=["cm","mm","pt","pc","in","Q","px"];function Ife(e){return Rfe.includes(e)}var ul="NaN";function Tfe(e,t){return e*Afe[t]}class In{static parse(t){var n,[,r,i]=(n=Pfe.exec(t))!==null&&n!==void 0?n:[];return r==null?In.NaN:new In(parseFloat(r),i??"")}constructor(t,n){this.num=t,this.unit=n,this.num=t,this.unit=n,Fi(t)&&(this.unit=""),n!==""&&!Ofe.test(n)&&(this.num=NaN,this.unit=""),Ife(n)&&(this.num=Tfe(t,n),this.unit="px")}add(t){return this.unit!==t.unit?new In(NaN,""):new In(this.num+t.num,this.unit)}subtract(t){return this.unit!==t.unit?new In(NaN,""):new In(this.num-t.num,this.unit)}multiply(t){return this.unit!==""&&t.unit!==""&&this.unit!==t.unit?new In(NaN,""):new In(this.num*t.num,this.unit||t.unit)}divide(t){return this.unit!==""&&t.unit!==""&&this.unit!==t.unit?new In(NaN,""):new In(this.num/t.num,this.unit||t.unit)}toString(){return"".concat(this.num).concat(this.unit)}isNaN(){return Fi(this.num)}}$$=In;Cfe(In,"NaN",new $$(NaN,""));function F$(e){if(e==null||e.includes(ul))return ul;for(var t=e;t.includes("*")||t.includes("/");){var n,[,r,i,o]=(n=zA.exec(t))!==null&&n!==void 0?n:[],a=In.parse(r??""),s=In.parse(o??""),u=i==="*"?a.multiply(s):a.divide(s);if(u.isNaN())return ul;t=t.replace(zA,u.toString())}for(;t.includes("+")||/.-\d+(?:\.\d+)?/.test(t);){var c,[,f,p,g]=(c=WA.exec(t))!==null&&c!==void 0?c:[],h=In.parse(f??""),v=In.parse(g??""),b=p==="+"?h.add(v):h.subtract(v);if(b.isNaN())return ul;t=t.replace(WA,b.toString())}return t}var HA=/\(([^()]*)\)/;function kfe(e){for(var t=e,n;(n=HA.exec(t))!=null;){var[,r]=n;t=t.replace(HA,F$(r))}return t}function Nfe(e){var t=e.replace(/\s+/g,"");return t=kfe(t),t=F$(t),t}function Mfe(e){try{return Nfe(e)}catch{return ul}}function _y(e){var t=Mfe(e.slice(5,-1));return t===ul?"":t}var Dfe=["x","y","lineHeight","capHeight","fill","scaleToFit","textAnchor","verticalAnchor"],jfe=["dx","dy","angle","className","breakAll"];function ox(){return ox=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ox.apply(null,arguments)}function UA(e,t){if(e==null)return{};var n,r,i=Lfe(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Lfe(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var V$=/[ \f\n\r\t\v\u2028\u2029]+/,B$=e=>{var{children:t,breakAll:n,style:r}=e;try{var i=[];pn(t)||(n?i=t.toString().split(""):i=t.toString().split(V$));var o=i.map(s=>({word:s,width:Wu(s,r).width})),a=n?0:Wu(" ",r).width;return{wordsWithComputedWidth:o,spaceWidth:a}}catch{return null}};function z$(e){return e==="start"||e==="middle"||e==="end"||e==="inherit"}function $fe(e){return pn(e)||typeof e=="string"||typeof e=="number"||typeof e=="boolean"}var W$=(e,t,n,r)=>e.reduce((i,o)=>{var{word:a,width:s}=o,u=i[i.length-1];if(u&&s!=null&&(t==null||r||u.width+s+n<Number(t)))u.words.push(a),u.width+=s+n;else{var c={words:[a],width:s};i.push(c)}return i},[]),H$=e=>e.reduce((t,n)=>t.width>n.width?t:n),Ffe="…",GA=(e,t,n,r,i,o,a,s)=>{var u=e.slice(0,t),c=B$({breakAll:n,style:r,children:u+Ffe});if(!c)return[!1,[]];var f=W$(c.wordsWithComputedWidth,o,a,s),p=f.length>i||H$(f).width>Number(o);return[p,f]},Vfe=(e,t,n,r,i)=>{var{maxLines:o,children:a,style:s,breakAll:u}=e,c=Ne(o),f=String(a),p=W$(t,r,n,i);if(!c||i)return p;var g=p.length>o||H$(p).width>Number(r);if(!g)return p;for(var h=0,v=f.length-1,b=0,y;h<=v&&b<=f.length-1;){var w=Math.floor((h+v)/2),S=w-1,[E,_]=GA(f,S,u,s,o,r,n,i),[P]=GA(f,w,u,s,o,r,n,i);if(!E&&!P&&(h=w+1),E&&P&&(v=w-1),!E&&P){y=_;break}b++}return y||p},qA=e=>{var t=pn(e)?[]:e.toString().split(V$);return[{words:t,width:void 0}]},Bfe=e=>{var{width:t,scaleToFit:n,children:r,style:i,breakAll:o,maxLines:a}=e;if((t||n)&&!Ac.isSsr){var s,u,c=B$({breakAll:o,children:r,style:i});if(c){var{wordsWithComputedWidth:f,spaceWidth:p}=c;s=f,u=p}else return qA(r);return Vfe({breakAll:o,children:r,maxLines:a,style:i},s,u,t,!!n)}return qA(r)},U$="#808080",zfe={angle:0,breakAll:!1,capHeight:"0.71em",fill:U$,lineHeight:"1em",scaleToFit:!1,textAnchor:"start",verticalAnchor:"end",x:0,y:0},dS=$.forwardRef((e,t)=>{var n=Dr(e,zfe),{x:r,y:i,lineHeight:o,capHeight:a,fill:s,scaleToFit:u,textAnchor:c,verticalAnchor:f}=n,p=UA(n,Dfe),g=$.useMemo(()=>Bfe({breakAll:p.breakAll,children:p.children,maxLines:p.maxLines,scaleToFit:u,style:p.style,width:p.width}),[p.breakAll,p.children,p.maxLines,u,p.style,p.width]),{dx:h,dy:v,angle:b,className:y,breakAll:w}=p,S=UA(p,jfe);if(!Vi(r)||!Vi(i)||g.length===0)return null;var E=Number(r)+(Ne(h)?h:0),_=Number(i)+(Ne(v)?v:0);if(!dt(E)||!dt(_))return null;var P;switch(f){case"start":P=_y("calc(".concat(a,")"));break;case"middle":P=_y("calc(".concat((g.length-1)/2," * -").concat(o," + (").concat(a," / 2))"));break;default:P=_y("calc(".concat(g.length-1," * -").concat(o,")"));break}var R=[],I=g[0];if(u&&I!=null){var k=I.width,{width:B}=p;R.push("scale(".concat(Ne(B)&&Ne(k)?B/k:1,")"))}return b&&R.push("rotate(".concat(b,", ").concat(E,", ").concat(_,")")),R.length&&(S.transform=R.join(" ")),x.createElement("text",ox({},ni(S),{ref:t,x:E,y:_,className:At("recharts-text",y),textAnchor:c,fill:s.includes("url")?U$:s}),g.map((L,V)=>{var D=L.words.join(w?"":" ");return x.createElement("tspan",{x:E,dy:V===0?P:o,key:"".concat(D,"-").concat(V)},D)}))});dS.displayName="Text";function KA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ai(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?KA(Object(n),!0).forEach(function(r){Wfe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):KA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Wfe(e,t,n){return(t=Hfe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Hfe(e){var t=Ufe(e,"string");return typeof t=="symbol"?t:t+""}function Ufe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Gfe=e=>{var{viewBox:t,position:n,offset:r=0,parentViewBox:i}=e,{x:o,y:a,height:s,upperWidth:u,lowerWidth:c}=aw(t),f=o,p=o+(u-c)/2,g=(f+p)/2,h=(u+c)/2,v=f+u/2,b=s>=0?1:-1,y=b*r,w=b>0?"end":"start",S=b>0?"start":"end",E=u>=0?1:-1,_=E*r,P=E>0?"end":"start",R=E>0?"start":"end",I=i;if(n==="top"){var k={x:f+u/2,y:a-y,horizontalAnchor:"middle",verticalAnchor:w};return I&&(k.height=Math.max(a-I.y,0),k.width=u),k}if(n==="bottom"){var B={x:p+c/2,y:a+s+y,horizontalAnchor:"middle",verticalAnchor:S};return I&&(B.height=Math.max(I.y+I.height-(a+s),0),B.width=c),B}if(n==="left"){var L={x:g-_,y:a+s/2,horizontalAnchor:P,verticalAnchor:"middle"};return I&&(L.width=Math.max(L.x-I.x,0),L.height=s),L}if(n==="right"){var V={x:g+h+_,y:a+s/2,horizontalAnchor:R,verticalAnchor:"middle"};return I&&(V.width=Math.max(I.x+I.width-V.x,0),V.height=s),V}var D=I?{width:h,height:s}:{};return n==="insideLeft"?Ai({x:g+_,y:a+s/2,horizontalAnchor:R,verticalAnchor:"middle"},D):n==="insideRight"?Ai({x:g+h-_,y:a+s/2,horizontalAnchor:P,verticalAnchor:"middle"},D):n==="insideTop"?Ai({x:f+u/2,y:a+y,horizontalAnchor:"middle",verticalAnchor:S},D):n==="insideBottom"?Ai({x:p+c/2,y:a+s-y,horizontalAnchor:"middle",verticalAnchor:w},D):n==="insideTopLeft"?Ai({x:f+_,y:a+y,horizontalAnchor:R,verticalAnchor:S},D):n==="insideTopRight"?Ai({x:f+u-_,y:a+y,horizontalAnchor:P,verticalAnchor:S},D):n==="insideBottomLeft"?Ai({x:p+_,y:a+s-y,horizontalAnchor:R,verticalAnchor:w},D):n==="insideBottomRight"?Ai({x:p+c-_,y:a+s-y,horizontalAnchor:P,verticalAnchor:w},D):n&&typeof n=="object"&&(Ne(n.x)||us(n.x))&&(Ne(n.y)||us(n.y))?Ai({x:o+pi(n.x,h),y:a+pi(n.y,s),horizontalAnchor:"end",verticalAnchor:"end"},D):Ai({x:v,y:a+s/2,horizontalAnchor:"middle",verticalAnchor:"middle"},D)},qfe=["labelRef"],Kfe=["content"];function YA(e,t){if(e==null)return{};var n,r,i=Yfe(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Yfe(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function XA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Mu(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?XA(Object(n),!0).forEach(function(r){Xfe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):XA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Xfe(e,t,n){return(t=Zfe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Zfe(e){var t=Qfe(e,"string");return typeof t=="symbol"?t:t+""}function Qfe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ao(){return ao=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ao.apply(null,arguments)}var G$=$.createContext(null),Jfe=e=>{var{x:t,y:n,upperWidth:r,lowerWidth:i,width:o,height:a,children:s}=e,u=$.useMemo(()=>({x:t,y:n,upperWidth:r,lowerWidth:i,width:o,height:a}),[t,n,r,i,o,a]);return x.createElement(G$.Provider,{value:u},s)},q$=()=>{var e=$.useContext(G$),t=Qh();return e||(t?aw(t):void 0)},ede=$.createContext(null),tde=()=>{var e=$.useContext(ede),t=Be(z2);return e||t},nde=e=>{var{value:t,formatter:n}=e,r=pn(e.children)?t:e.children;return typeof n=="function"?n(r):r},pS=e=>e!=null&&typeof e=="function",rde=(e,t)=>{var n=fr(t-e),r=Math.min(Math.abs(t-e),360);return n*r},ide=(e,t,n,r,i)=>{var{offset:o,className:a}=e,{cx:s,cy:u,innerRadius:c,outerRadius:f,startAngle:p,endAngle:g,clockWise:h}=i,v=(c+f)/2,b=rde(p,g),y=b>=0?1:-1,w,S;switch(t){case"insideStart":w=p+y*o,S=h;break;case"insideEnd":w=g-y*o,S=!h;break;case"end":w=g+y*o,S=h;break;default:throw new Error("Unsupported position ".concat(t))}S=b<=0?S:!S;var E=kn(s,u,v,w),_=kn(s,u,v,w+(S?1:-1)*359),P="M".concat(E.x,",").concat(E.y,`
|
|
255
|
+
A`).concat(v,",").concat(v,",0,1,").concat(S?0:1,`,
|
|
256
|
+
`).concat(_.x,",").concat(_.y),R=pn(e.id)?Xu("recharts-radial-line-"):e.id;return x.createElement("text",ao({},r,{dominantBaseline:"central",className:At("recharts-radial-bar-label",a)}),x.createElement("defs",null,x.createElement("path",{id:R,d:P})),x.createElement("textPath",{xlinkHref:"#".concat(R)},n))},ode=(e,t,n)=>{var{cx:r,cy:i,innerRadius:o,outerRadius:a,startAngle:s,endAngle:u}=e,c=(s+u)/2;if(n==="outside"){var{x:f,y:p}=kn(r,i,a+t,c);return{x:f,y:p,textAnchor:f>=r?"start":"end",verticalAnchor:"middle"}}if(n==="center")return{x:r,y:i,textAnchor:"middle",verticalAnchor:"middle"};if(n==="centerTop")return{x:r,y:i,textAnchor:"middle",verticalAnchor:"start"};if(n==="centerBottom")return{x:r,y:i,textAnchor:"middle",verticalAnchor:"end"};var g=(o+a)/2,{x:h,y:v}=kn(r,i,g,c);return{x:h,y:v,textAnchor:"middle",verticalAnchor:"middle"}},Ld=e=>e!=null&&"cx"in e&&Ne(e.cx),ade={angle:0,offset:5,zIndex:Qn.label,position:"middle",textBreakAll:!1};function sde(e){if(!Ld(e))return e;var{cx:t,cy:n,outerRadius:r}=e,i=r*2;return{x:t-r,y:n-r,width:i,upperWidth:i,lowerWidth:i,height:i}}function Qo(e){var t=Dr(e,ade),{viewBox:n,parentViewBox:r,position:i,value:o,children:a,content:s,className:u="",textBreakAll:c,labelRef:f}=t,p=tde(),g=q$(),h=i==="center"?g:p??g,v,b,y;n==null?v=h:Ld(n)?v=n:v=aw(n);var w=sde(v);if(!v||pn(o)&&pn(a)&&!$.isValidElement(s)&&typeof s!="function")return null;var S=Mu(Mu({},t),{},{viewBox:v});if($.isValidElement(s)){var{labelRef:E}=S,_=YA(S,qfe);return $.cloneElement(s,_)}if(typeof s=="function"){var{content:P}=S,R=YA(S,Kfe);if(b=$.createElement(s,R),$.isValidElement(b))return b}else b=nde(t);var I=ni(t);if(Ld(v)){if(i==="insideStart"||i==="insideEnd"||i==="end")return ide(t,i,b,I,v);y=ode(v,t.offset,t.position)}else{if(!w)return null;var k=Gfe({viewBox:w,position:i,offset:t.offset,parentViewBox:Ld(r)?void 0:r});y=Mu(Mu({x:k.x,y:k.y,textAnchor:k.horizontalAnchor,verticalAnchor:k.verticalAnchor},k.width!==void 0?{width:k.width}:{}),k.height!==void 0?{height:k.height}:{})}return x.createElement(ko,{zIndex:t.zIndex},x.createElement(dS,ao({ref:f,className:At("recharts-label",u)},I,y,{textAnchor:z$(I.textAnchor)?I.textAnchor:y.textAnchor,breakAll:c}),b))}Qo.displayName="Label";var lde=(e,t,n)=>{if(!e)return null;var r={viewBox:t,labelRef:n};return e===!0?x.createElement(Qo,ao({key:"label-implicit"},r)):Vi(e)?x.createElement(Qo,ao({key:"label-implicit",value:e},r)):$.isValidElement(e)?e.type===Qo?$.cloneElement(e,Mu({key:"label-implicit"},r)):x.createElement(Qo,ao({key:"label-implicit",content:e},r)):pS(e)?x.createElement(Qo,ao({key:"label-implicit",content:e},r)):e&&typeof e=="object"?x.createElement(Qo,ao({},e,{key:"label-implicit"},r)):null};function ude(e){var{label:t,labelRef:n}=e,r=q$();return lde(t,r,n)||null}var cde=["valueAccessor"],fde=["dataKey","clockWise","id","textBreakAll","zIndex"];function Gp(){return Gp=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Gp.apply(null,arguments)}function ZA(e,t){if(e==null)return{};var n,r,i=dde(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function dde(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var pde=e=>{var t=Array.isArray(e.value)?e.value[e.value.length-1]:e.value;if($fe(t))return t},K$=$.createContext(void 0),hde=K$.Provider,Y$=$.createContext(void 0);Y$.Provider;function gde(){return $.useContext(K$)}function mde(){return $.useContext(Y$)}function $d(e){var{valueAccessor:t=pde}=e,n=ZA(e,cde),{dataKey:r,clockWise:i,id:o,textBreakAll:a,zIndex:s}=n,u=ZA(n,fde),c=gde(),f=mde(),p=c||f;return!p||!p.length?null:x.createElement(ko,{zIndex:s??Qn.label},x.createElement($i,{className:"recharts-label-list"},p.map((g,h)=>{var v,b=pn(r)?t(g,h):Mn(g.payload,r),y=pn(o)?{}:{id:"".concat(o,"-").concat(h)};return x.createElement(Qo,Gp({key:"label-".concat(h)},ni(g),u,y,{fill:(v=n.fill)!==null&&v!==void 0?v:g.fill,parentViewBox:g.parentViewBox,value:b,textBreakAll:a,viewBox:g.viewBox,index:h,zIndex:0}))})))}$d.displayName="LabelList";function vde(e){var{label:t}=e;return t?t===!0?x.createElement($d,{key:"labelList-implicit"}):x.isValidElement(t)||pS(t)?x.createElement($d,{key:"labelList-implicit",content:t}):typeof t=="object"?x.createElement($d,Gp({key:"labelList-implicit"},t,{type:String(t.type)})):null:null}var yde={radiusAxis:{},angleAxis:{}},X$=Hn({name:"polarAxis",initialState:yde,reducers:{addRadiusAxis(e,t){e.radiusAxis[t.payload.id]=t.payload},removeRadiusAxis(e,t){delete e.radiusAxis[t.payload.id]},addAngleAxis(e,t){e.angleAxis[t.payload.id]=t.payload},removeAngleAxis(e,t){delete e.angleAxis[t.payload.id]}}}),{addRadiusAxis:vve,removeRadiusAxis:yve,addAngleAxis:bve,removeAngleAxis:xve}=X$.actions,bde=X$.reducer;function xde(e){return e&&typeof e=="object"&&"className"in e&&typeof e.className=="string"?e.className:""}var Od={exports:{}},Et={};var QA;function wde(){if(QA)return Et;QA=1;var e=60103,t=60106,n=60107,r=60108,i=60114,o=60109,a=60110,s=60112,u=60113,c=60120,f=60115,p=60116,g=60121,h=60122,v=60117,b=60129,y=60131;if(typeof Symbol=="function"&&Symbol.for){var w=Symbol.for;e=w("react.element"),t=w("react.portal"),n=w("react.fragment"),r=w("react.strict_mode"),i=w("react.profiler"),o=w("react.provider"),a=w("react.context"),s=w("react.forward_ref"),u=w("react.suspense"),c=w("react.suspense_list"),f=w("react.memo"),p=w("react.lazy"),g=w("react.block"),h=w("react.server.block"),v=w("react.fundamental"),b=w("react.debug_trace_mode"),y=w("react.legacy_hidden")}function S(W){if(typeof W=="object"&&W!==null){var J=W.$$typeof;switch(J){case e:switch(W=W.type,W){case n:case i:case r:case u:case c:return W;default:switch(W=W&&W.$$typeof,W){case a:case s:case p:case f:case o:return W;default:return J}}case t:return J}}}var E=o,_=e,P=s,R=n,I=p,k=f,B=t,L=i,V=r,D=u;return Et.ContextConsumer=a,Et.ContextProvider=E,Et.Element=_,Et.ForwardRef=P,Et.Fragment=R,Et.Lazy=I,Et.Memo=k,Et.Portal=B,Et.Profiler=L,Et.StrictMode=V,Et.Suspense=D,Et.isAsyncMode=function(){return!1},Et.isConcurrentMode=function(){return!1},Et.isContextConsumer=function(W){return S(W)===a},Et.isContextProvider=function(W){return S(W)===o},Et.isElement=function(W){return typeof W=="object"&&W!==null&&W.$$typeof===e},Et.isForwardRef=function(W){return S(W)===s},Et.isFragment=function(W){return S(W)===n},Et.isLazy=function(W){return S(W)===p},Et.isMemo=function(W){return S(W)===f},Et.isPortal=function(W){return S(W)===t},Et.isProfiler=function(W){return S(W)===i},Et.isStrictMode=function(W){return S(W)===r},Et.isSuspense=function(W){return S(W)===u},Et.isValidElementType=function(W){return typeof W=="string"||typeof W=="function"||W===n||W===i||W===b||W===r||W===u||W===c||W===y||typeof W=="object"&&W!==null&&(W.$$typeof===p||W.$$typeof===f||W.$$typeof===o||W.$$typeof===a||W.$$typeof===s||W.$$typeof===v||W.$$typeof===g||W[0]===h)},Et.typeOf=S,Et}var _t={};var JA;function Sde(){return JA||(JA=1,process.env.NODE_ENV!=="production"&&(function(){var e=60103,t=60106,n=60107,r=60108,i=60114,o=60109,a=60110,s=60112,u=60113,c=60120,f=60115,p=60116,g=60121,h=60122,v=60117,b=60129,y=60131;if(typeof Symbol=="function"&&Symbol.for){var w=Symbol.for;e=w("react.element"),t=w("react.portal"),n=w("react.fragment"),r=w("react.strict_mode"),i=w("react.profiler"),o=w("react.provider"),a=w("react.context"),s=w("react.forward_ref"),u=w("react.suspense"),c=w("react.suspense_list"),f=w("react.memo"),p=w("react.lazy"),g=w("react.block"),h=w("react.server.block"),v=w("react.fundamental"),w("react.scope"),w("react.opaque.id"),b=w("react.debug_trace_mode"),w("react.offscreen"),y=w("react.legacy_hidden")}var S=!1;function E(Y){return!!(typeof Y=="string"||typeof Y=="function"||Y===n||Y===i||Y===b||Y===r||Y===u||Y===c||Y===y||S||typeof Y=="object"&&Y!==null&&(Y.$$typeof===p||Y.$$typeof===f||Y.$$typeof===o||Y.$$typeof===a||Y.$$typeof===s||Y.$$typeof===v||Y.$$typeof===g||Y[0]===h))}function _(Y){if(typeof Y=="object"&&Y!==null){var j=Y.$$typeof;switch(j){case e:var ie=Y.type;switch(ie){case n:case i:case r:case u:case c:return ie;default:var Q=ie&&ie.$$typeof;switch(Q){case a:case s:case p:case f:case o:return Q;default:return j}}case t:return j}}}var P=a,R=o,I=e,k=s,B=n,L=p,V=f,D=t,W=i,J=r,re=u,U=!1,ee=!1;function Z(Y){return U||(U=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function ue(Y){return ee||(ee=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function X(Y){return _(Y)===a}function Oe(Y){return _(Y)===o}function Ee(Y){return typeof Y=="object"&&Y!==null&&Y.$$typeof===e}function Me(Y){return _(Y)===s}function ye(Y){return _(Y)===n}function be(Y){return _(Y)===p}function $e(Y){return _(Y)===f}function me(Y){return _(Y)===t}function Se(Y){return _(Y)===i}function q(Y){return _(Y)===r}function te(Y){return _(Y)===u}_t.ContextConsumer=P,_t.ContextProvider=R,_t.Element=I,_t.ForwardRef=k,_t.Fragment=B,_t.Lazy=L,_t.Memo=V,_t.Portal=D,_t.Profiler=W,_t.StrictMode=J,_t.Suspense=re,_t.isAsyncMode=Z,_t.isConcurrentMode=ue,_t.isContextConsumer=X,_t.isContextProvider=Oe,_t.isElement=Ee,_t.isForwardRef=Me,_t.isFragment=ye,_t.isLazy=be,_t.isMemo=$e,_t.isPortal=me,_t.isProfiler=Se,_t.isStrictMode=q,_t.isSuspense=te,_t.isValidElementType=E,_t.typeOf=_})()),_t}var eR;function Cde(){return eR||(eR=1,process.env.NODE_ENV==="production"?Od.exports=wde():Od.exports=Sde()),Od.exports}var Ede=Cde(),tR=e=>typeof e=="string"?e:e?e.displayName||e.name||"Component":"",nR=null,Oy=null,Z$=e=>{if(e===nR&&Array.isArray(Oy))return Oy;var t=[];return $.Children.forEach(e,n=>{pn(n)||(Ede.isFragment(n)?t=t.concat(Z$(n.props.children)):t.push(n))}),Oy=t,nR=e,t};function _de(e,t){var n=[],r=[];return Array.isArray(t)?r=t.map(i=>tR(i)):r=[tR(t)],Z$(e).forEach(i=>{var o=xl(i,"type.displayName")||xl(i,"type.name");o&&r.indexOf(o)!==-1&&n.push(i)}),n}var Py={},rR;function Ode(){return rR||(rR=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n){if(typeof n!="object"||n==null)return!1;if(Object.getPrototypeOf(n)===null)return!0;if(Object.prototype.toString.call(n)!=="[object Object]"){const i=n[Symbol.toStringTag];return i==null||!Object.getOwnPropertyDescriptor(n,Symbol.toStringTag)?.writable?!1:n.toString()===`[object ${i}]`}let r=n;for(;Object.getPrototypeOf(r)!==null;)r=Object.getPrototypeOf(r);return Object.getPrototypeOf(n)===r}e.isPlainObject=t})(Py)),Py}var Ay,iR;function Pde(){return iR||(iR=1,Ay=Ode().isPlainObject),Ay}var Ade=Pde();const Rde=vs(Ade);var oR,aR,sR,lR,uR;function cR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function fR(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?cR(Object(n),!0).forEach(function(r){Ide(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):cR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Ide(e,t,n){return(t=Tde(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Tde(e){var t=kde(e,"string");return typeof t=="symbol"?t:t+""}function kde(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function qp(){return qp=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},qp.apply(null,arguments)}function _u(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}var dR=(e,t,n,r,i)=>{var o=n-r,a;return a=Kt(oR||(oR=_u(["M ",",",""])),e,t),a+=Kt(aR||(aR=_u(["L ",",",""])),e+n,t),a+=Kt(sR||(sR=_u(["L ",",",""])),e+n-o/2,t+i),a+=Kt(lR||(lR=_u(["L ",",",""])),e+n-o/2-r,t+i),a+=Kt(uR||(uR=_u(["L ",","," Z"])),e,t),a},Nde={x:0,y:0,upperWidth:0,lowerWidth:0,height:0,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},Mde=e=>{var t=Dr(e,Nde),{x:n,y:r,upperWidth:i,lowerWidth:o,height:a,className:s}=t,{animationEasing:u,animationDuration:c,animationBegin:f,isUpdateAnimationActive:p}=t,g=$.useRef(null),[h,v]=$.useState(-1),b=$.useRef(i),y=$.useRef(o),w=$.useRef(a),S=$.useRef(n),E=$.useRef(r),_=cw(e,"trapezoid-");if($.useEffect(()=>{if(g.current&&g.current.getTotalLength)try{var J=g.current.getTotalLength();J&&v(J)}catch{}},[]),n!==+n||r!==+r||i!==+i||o!==+o||a!==+a||i===0&&o===0||a===0)return null;var P=At("recharts-trapezoid",s);if(!p)return x.createElement("g",null,x.createElement("path",qp({},ni(t),{className:P,d:dR(n,r,i,o,a)})));var R=b.current,I=y.current,k=w.current,B=S.current,L=E.current,V="0px ".concat(h===-1?1:h,"px"),D="".concat(h,"px ").concat(h,"px"),W=d2(["strokeDasharray"],c,u);return x.createElement(uw,{animationId:_,key:_,canBegin:h>0,duration:c,easing:u,isActive:p,begin:f},J=>{var re=Tn(R,i,J),U=Tn(I,o,J),ee=Tn(k,a,J),Z=Tn(B,n,J),ue=Tn(L,r,J);g.current&&(b.current=re,y.current=U,w.current=ee,S.current=Z,E.current=ue);var X=J>0?{transition:W,strokeDasharray:D}:{strokeDasharray:V};return x.createElement("path",qp({},ni(t),{className:P,d:dR(Z,ue,re,U,ee),ref:g,style:fR(fR({},X),t.style)}))})},Dde=["option","shapeType","activeClassName","inActiveClassName"];function jde(e,t){if(e==null)return{};var n,r,i=Lde(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Lde(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function pR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Kp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?pR(Object(n),!0).forEach(function(r){$de(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function $de(e,t,n){return(t=Fde(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Fde(e){var t=Vde(e,"string");return typeof t=="symbol"?t:t+""}function Vde(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Bde(e,t){return Kp(Kp({},t),e)}function zde(e,t){return e==="symbols"}function hR(e){var{shapeType:t,elementProps:n}=e;switch(t){case"rectangle":return x.createElement(m2,n);case"trapezoid":return x.createElement(Mde,n);case"sector":return x.createElement(b2,n);case"symbols":if(zde(t))return x.createElement(XD,n);break;case"curve":return x.createElement(f2,n);default:return null}}function Wde(e){return $.isValidElement(e)?e.props:e}function Hde(e){var{option:t,shapeType:n,activeClassName:r="recharts-active-shape",inActiveClassName:i="recharts-shape"}=e,o=jde(e,Dde),a;if($.isValidElement(t))a=$.cloneElement(t,Kp(Kp({},o),Wde(t)));else if(typeof t=="function")a=t(o,o.index);else if(Rde(t)&&typeof t!="boolean"){var s=Bde(t,o);a=x.createElement(hR,{shapeType:n,elementProps:s})}else{var u=o;a=x.createElement(hR,{shapeType:n,elementProps:u})}return o.isActive?x.createElement($i,{className:r},a):x.createElement($i,{className:i},a)}var Q$=(e,t,n)=>{var r=Ut();return(i,o)=>a=>{e?.(i,o,a),r(f$({activeIndex:String(o),activeDataKey:t,activeCoordinate:i.tooltipPosition,activeGraphicalItemId:n}))}},J$=e=>{var t=Ut();return(n,r)=>i=>{e?.(n,r,i),t(tue())}},eF=(e,t,n)=>{var r=Ut();return(i,o)=>a=>{e?.(i,o,a),r(nue({activeIndex:String(o),activeDataKey:t,activeCoordinate:i.tooltipPosition,activeGraphicalItemId:n}))}};function Ude(e){var{tooltipEntrySettings:t}=e,n=Ut(),r=hr(),i=$.useRef(null);return $.useLayoutEffect(()=>{r||(i.current===null?n(Zle(t)):i.current!==t&&n(Qle({prev:i.current,next:t})),i.current=t)},[t,n,r]),$.useLayoutEffect(()=>()=>{i.current&&(n(Jle(i.current)),i.current=null)},[n]),null}function Gde(e){var{legendPayload:t}=e,n=Ut(),r=hr(),i=$.useRef(null);return $.useLayoutEffect(()=>{r||(i.current===null?n(tre(t)):i.current!==t&&n(nre({prev:i.current,next:t})),i.current=t)},[n,r,t]),$.useLayoutEffect(()=>()=>{i.current&&(n(rre(i.current)),i.current=null)},[n]),null}var Ry,qde=()=>{var[e]=x.useState(()=>Xu("uid-"));return e},Kde=(Ry=x.useId)!==null&&Ry!==void 0?Ry:qde;function Yde(e,t){var n=Kde();return t||(e?"".concat(e,"-").concat(n):n)}var Xde=$.createContext(void 0),Zde=e=>{var{id:t,type:n,children:r}=e,i=Yde("recharts-".concat(n),t);return x.createElement(Xde.Provider,{value:i},r(i))},Qde={cartesianItems:[],polarItems:[]},tF=Hn({name:"graphicalItems",initialState:Qde,reducers:{addCartesianGraphicalItem:{reducer(e,t){e.cartesianItems.push(t.payload)},prepare:Dt()},replaceCartesianGraphicalItem:{reducer(e,t){var{prev:n,next:r}=t.payload,i=Jr(e).cartesianItems.indexOf(n);i>-1&&(e.cartesianItems[i]=r)},prepare:Dt()},removeCartesianGraphicalItem:{reducer(e,t){var n=Jr(e).cartesianItems.indexOf(t.payload);n>-1&&e.cartesianItems.splice(n,1)},prepare:Dt()},addPolarGraphicalItem:{reducer(e,t){e.polarItems.push(t.payload)},prepare:Dt()},removePolarGraphicalItem:{reducer(e,t){var n=Jr(e).polarItems.indexOf(t.payload);n>-1&&e.polarItems.splice(n,1)},prepare:Dt()},replacePolarGraphicalItem:{reducer(e,t){var{prev:n,next:r}=t.payload,i=Jr(e).polarItems.indexOf(n);i>-1&&(e.polarItems[i]=r)},prepare:Dt()}}}),{addCartesianGraphicalItem:Jde,replaceCartesianGraphicalItem:epe,removeCartesianGraphicalItem:tpe,addPolarGraphicalItem:wve,removePolarGraphicalItem:Sve,replacePolarGraphicalItem:Cve}=tF.actions,npe=tF.reducer,rpe=e=>{var t=Ut(),n=$.useRef(null);return $.useLayoutEffect(()=>{n.current===null?t(Jde(e)):n.current!==e&&t(epe({prev:n.current,next:e})),n.current=e},[t,e]),$.useLayoutEffect(()=>()=>{n.current&&(t(tpe(n.current)),n.current=null)},[t]),null},ipe=$.memo(rpe);function gR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function mR(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?gR(Object(n),!0).forEach(function(r){ope(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):gR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ope(e,t,n){return(t=ape(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ape(e){var t=spe(e,"string");return typeof t=="symbol"?t:t+""}function spe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var nF=0,lpe={xAxis:{},yAxis:{},zAxis:{}},rF=Hn({name:"cartesianAxis",initialState:lpe,reducers:{addXAxis:{reducer(e,t){e.xAxis[t.payload.id]=t.payload},prepare:Dt()},replaceXAxis:{reducer(e,t){var{prev:n,next:r}=t.payload;e.xAxis[n.id]!==void 0&&(n.id!==r.id&&delete e.xAxis[n.id],e.xAxis[r.id]=r)},prepare:Dt()},removeXAxis:{reducer(e,t){delete e.xAxis[t.payload.id]},prepare:Dt()},addYAxis:{reducer(e,t){e.yAxis[t.payload.id]=t.payload},prepare:Dt()},replaceYAxis:{reducer(e,t){var{prev:n,next:r}=t.payload;e.yAxis[n.id]!==void 0&&(n.id!==r.id&&delete e.yAxis[n.id],e.yAxis[r.id]=r)},prepare:Dt()},removeYAxis:{reducer(e,t){delete e.yAxis[t.payload.id]},prepare:Dt()},addZAxis:{reducer(e,t){e.zAxis[t.payload.id]=t.payload},prepare:Dt()},replaceZAxis:{reducer(e,t){var{prev:n,next:r}=t.payload;e.zAxis[n.id]!==void 0&&(n.id!==r.id&&delete e.zAxis[n.id],e.zAxis[r.id]=r)},prepare:Dt()},removeZAxis:{reducer(e,t){delete e.zAxis[t.payload.id]},prepare:Dt()},updateYAxisWidth(e,t){var{id:n,width:r}=t.payload,i=e.yAxis[n];if(i){var o,a=i.widthHistory||[];if(a.length===3&&a[0]===a[2]&&r===a[1]&&r!==i.width&&Math.abs(r-((o=a[0])!==null&&o!==void 0?o:0))<=1)return;var s=[...a,r].slice(-3);e.yAxis[n]=mR(mR({},i),{},{width:r,widthHistory:s})}}}}),{addXAxis:upe,replaceXAxis:cpe,removeXAxis:fpe,addYAxis:dpe,replaceYAxis:ppe,removeYAxis:hpe,addZAxis:Eve,replaceZAxis:_ve,removeZAxis:Ove,updateYAxisWidth:gpe}=rF.actions,mpe=rF.reducer,vpe=K([wn],e=>({top:e.top,bottom:e.bottom,left:e.left,right:e.right})),ype=K([vpe,_o,Oo],(e,t,n)=>{if(!(!e||t==null||n==null))return{x:e.left,y:e.top,width:Math.max(0,t-e.left-e.right),height:Math.max(0,n-e.top-e.bottom)}}),iF=()=>Be(ype),vR=(e,t,n)=>{var r=n??e;if(!pn(r))return pi(r,t,0)},bpe=(e,t,n)=>{var r={},i=e.filter(lg),o=e.filter(c=>c.stackId==null),a=i.reduce((c,f)=>{var p=c[f.stackId];return p==null&&(p=[]),p.push(f),c[f.stackId]=p,c},r),s=Object.entries(a).map(c=>{var f,[p,g]=c,h=g.map(b=>b.dataKey),v=vR(t,n,(f=g[0])===null||f===void 0?void 0:f.barSize);return{stackId:p,dataKeys:h,barSize:v}}),u=o.map(c=>{var f=[c.dataKey].filter(g=>g!=null),p=vR(t,n,c.barSize);return{stackId:void 0,dataKeys:f,barSize:p}});return[...s,...u]};function yR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Pd(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?yR(Object(n),!0).forEach(function(r){xpe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):yR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function xpe(e,t,n){return(t=wpe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function wpe(e){var t=Spe(e,"string");return typeof t=="symbol"?t:t+""}function Spe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Cpe(e,t,n,r,i){var o,a=r.length;if(!(a<1)){var s=pi(e,n,0,!0),u,c=[];if(dt((o=r[0])===null||o===void 0?void 0:o.barSize)){var f=!1,p=n/a,g=r.reduce((S,E)=>S+(E.barSize||0),0);g+=(a-1)*s,g>=n&&(g-=(a-1)*s,s=0),g>=n&&p>0&&(f=!0,p*=.9,g=a*p);var h=(n-g)/2>>0,v={offset:h-s,size:0};u=r.reduce((S,E)=>{var _,P={stackId:E.stackId,dataKeys:E.dataKeys,position:{offset:v.offset+v.size+s,size:f?p:(_=E.barSize)!==null&&_!==void 0?_:0}},R=[...S,P];return v=P.position,R},c)}else{var b=pi(t,n,0,!0);n-2*b-(a-1)*s<=0&&(s=0);var y=(n-2*b-(a-1)*s)/a;y>1&&(y>>=0);var w=dt(i)?Math.min(y,i):y;u=r.reduce((S,E,_)=>[...S,{stackId:E.stackId,dataKeys:E.dataKeys,position:{offset:b+(y+s)*_+(y-w)/2,size:w}}],c)}return u}}var Epe=(e,t,n,r,i,o,a)=>{var s=pn(a)?t:a,u=Cpe(n,r,i!==o?i:o,e,s);return i!==o&&u!=null&&(u=u.map(c=>Pd(Pd({},c),{},{position:Pd(Pd({},c.position),{},{offset:c.position.offset-i/2})}))),u},_pe=(e,t)=>{var n=xw(t);if(!(!e||n==null||t==null)){var{stackId:r}=t;if(r!=null){var i=e[r];if(i){var{stackedData:o}=i;if(o)return o.find(a=>a.key===n)}}}},Ope=(e,t)=>{if(!(e==null||t==null)){var n=e.find(r=>r.stackId===t.stackId&&t.dataKey!=null&&r.dataKeys.includes(t.dataKey));if(n!=null)return n.position}};function Ppe(e,t){return e&&typeof e=="object"&&"zIndex"in e&&typeof e.zIndex=="number"&&dt(e.zIndex)?e.zIndex:t}var Ape=e=>{var{chartData:t}=e,n=Ut(),r=hr();return $.useEffect(()=>r?()=>{}:(n(NA(t)),()=>{n(NA(void 0))}),[t,n,r]),null},bR={x:0,y:0,width:0,height:0,padding:{top:0,right:0,bottom:0,left:0}},oF=Hn({name:"brush",initialState:bR,reducers:{setBrushSettings(e,t){return t.payload==null?bR:t.payload}}}),{setBrushSettings:Pve}=oF.actions,Rpe=oF.reducer;function Ipe(e){return(e%180+180)%180}var Tpe=function(t){var{width:n,height:r}=t,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,o=Ipe(i),a=o*Math.PI/180,s=Math.atan(r/n),u=a>s&&a<Math.PI-s?r/Math.sin(a):n/Math.cos(a);return Math.abs(u)},kpe={dots:[],areas:[],lines:[]},aF=Hn({name:"referenceElements",initialState:kpe,reducers:{addDot:(e,t)=>{e.dots.push(t.payload)},removeDot:(e,t)=>{var n=Jr(e).dots.findIndex(r=>r===t.payload);n!==-1&&e.dots.splice(n,1)},addArea:(e,t)=>{e.areas.push(t.payload)},removeArea:(e,t)=>{var n=Jr(e).areas.findIndex(r=>r===t.payload);n!==-1&&e.areas.splice(n,1)},addLine:(e,t)=>{e.lines.push(t.payload)},removeLine:(e,t)=>{var n=Jr(e).lines.findIndex(r=>r===t.payload);n!==-1&&e.lines.splice(n,1)}}}),{addDot:Ave,removeDot:Rve,addArea:Ive,removeArea:Tve,addLine:kve,removeLine:Nve}=aF.actions,Npe=aF.reducer,Mpe=$.createContext(void 0),Dpe=e=>{var{children:t}=e,[n]=$.useState("".concat(Xu("recharts"),"-clip")),r=iF();if(r==null)return null;var{x:i,y:o,width:a,height:s}=r;return x.createElement(Mpe.Provider,{value:n},x.createElement("defs",null,x.createElement("clipPath",{id:n},x.createElement("rect",{x:i,y:o,height:s,width:a}))),t)};function sF(e,t){if(t<1)return[];if(t===1)return e;for(var n=[],r=0;r<e.length;r+=t){var i=e[r];i!==void 0&&n.push(i)}return n}function jpe(e,t,n){var r={width:e.width+t.width,height:e.height+t.height};return Tpe(r,n)}function Lpe(e,t,n){var r=n==="width",{x:i,y:o,width:a,height:s}=e;return t===1?{start:r?i:o,end:r?i+a:o+s}:{start:r?i+a:o+s,end:r?i:o}}function cc(e,t,n,r,i){if(e*t<e*r||e*t>e*i)return!1;var o=n();return e*(t-e*o/2-r)>=0&&e*(t+e*o/2-i)<=0}function $pe(e,t){return sF(e,t+1)}function Fpe(e,t,n,r,i){for(var o=(r||[]).slice(),{start:a,end:s}=t,u=0,c=1,f=a,p=function(){var v=r?.[u];if(v===void 0)return{v:sF(r,c)};var b=u,y,w=()=>(y===void 0&&(y=n(v,b)),y),S=v.coordinate,E=u===0||cc(e,S,w,f,s);E||(u=0,f=a,c+=1),E&&(f=S+e*(w()/2+i),u+=c)},g;c<=o.length;)if(g=p(),g)return g.v;return[]}function Vpe(e,t,n,r,i){var o=(r||[]).slice(),a=o.length;if(a===0)return[];for(var{start:s,end:u}=t,c=1;c<=a;c++){for(var f=(a-1)%c,p=s,g=!0,h=function(){var _=r[b];if(_==null)return 0;var P=b,R,I=()=>(R===void 0&&(R=n(_,P)),R),k=_.coordinate,B=b===f||cc(e,k,I,p,u);if(!B)return g=!1,1;B&&(p=k+e*(I()/2+i))},v,b=f;b<a&&(v=h(),!(v!==0&&v===1));b+=c);if(g){for(var y=[],w=f;w<a;w+=c){var S=r[w];S!=null&&y.push(S)}return y}}return[]}function xR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Bn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?xR(Object(n),!0).forEach(function(r){Bpe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):xR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Bpe(e,t,n){return(t=zpe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zpe(e){var t=Wpe(e,"string");return typeof t=="symbol"?t:t+""}function Wpe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Hpe(e,t,n,r,i){for(var o=(r||[]).slice(),a=o.length,{start:s}=t,{end:u}=t,c=function(g){var h=o[g];if(h==null)return 1;var v=h,b,y=()=>(b===void 0&&(b=n(h,g)),b);if(g===a-1){var w=e*(v.coordinate+e*y()/2-u);o[g]=v=Bn(Bn({},v),{},{tickCoord:w>0?v.coordinate-w*e:v.coordinate})}else o[g]=v=Bn(Bn({},v),{},{tickCoord:v.coordinate});if(v.tickCoord!=null){var S=cc(e,v.tickCoord,y,s,u);S&&(u=v.tickCoord-e*(y()/2+i),o[g]=Bn(Bn({},v),{},{isShow:!0}))}},f=a-1;f>=0;f--)c(f);return o}function Upe(e,t,n,r,i,o){var a=(r||[]).slice(),s=a.length,{start:u,end:c}=t;if(o){var f=r[s-1];if(f!=null){var p=n(f,s-1),g=e*(f.coordinate+e*p/2-c);if(a[s-1]=f=Bn(Bn({},f),{},{tickCoord:g>0?f.coordinate-g*e:f.coordinate}),f.tickCoord!=null){var h=cc(e,f.tickCoord,()=>p,u,c);h&&(c=f.tickCoord-e*(p/2+i),a[s-1]=Bn(Bn({},f),{},{isShow:!0}))}}}for(var v=o?s-1:s,b=function(S){var E=a[S];if(E==null)return 1;var _=E,P,R=()=>(P===void 0&&(P=n(E,S)),P);if(S===0){var I=e*(_.coordinate-e*R()/2-u);a[S]=_=Bn(Bn({},_),{},{tickCoord:I<0?_.coordinate-I*e:_.coordinate})}else a[S]=_=Bn(Bn({},_),{},{tickCoord:_.coordinate});if(_.tickCoord!=null){var k=cc(e,_.tickCoord,R,u,c);k&&(u=_.tickCoord+e*(R()/2+i),a[S]=Bn(Bn({},_),{},{isShow:!0}))}},y=0;y<v;y++)b(y);return a}function hS(e,t,n){var{tick:r,ticks:i,viewBox:o,minTickGap:a,orientation:s,interval:u,tickFormatter:c,unit:f,angle:p}=e;if(!i||!i.length||!r)return[];if(Ne(u)||Ac.isSsr){var g;return(g=$pe(i,Ne(u)?u:0))!==null&&g!==void 0?g:[]}var h=[],v=s==="top"||s==="bottom"?"width":"height",b=f&&v==="width"?Wu(f,{fontSize:t,letterSpacing:n}):{width:0,height:0},y=(P,R)=>{var I=typeof c=="function"?c(P.value,R):P.value;return v==="width"?jpe(Wu(I,{fontSize:t,letterSpacing:n}),b,p):Wu(I,{fontSize:t,letterSpacing:n})[v]},w=i[0],S=i[1],E=i.length>=2&&w!=null&&S!=null?fr(S.coordinate-w.coordinate):1,_=Lpe(o,E,v);return u==="equidistantPreserveStart"?Fpe(E,_,y,i,a):u==="equidistantPreserveEnd"?Vpe(E,_,y,i,a):(u==="preserveStart"||u==="preserveStartEnd"?h=Upe(E,_,y,i,a,u==="preserveStartEnd"):h=Hpe(E,_,y,i,a),h.filter(P=>P.isShow))}var Gpe=e=>{var{ticks:t,label:n,labelGapWithTick:r=5,tickSize:i=0,tickMargin:o=0}=e,a=0;if(t){Array.from(t).forEach(f=>{if(f){var p=f.getBoundingClientRect();p.width>a&&(a=p.width)}});var s=n?n.getBoundingClientRect().width:0,u=i+o,c=a+u+s+(n?r:0);return Math.round(c)}return 0},qpe={xAxis:{},yAxis:{}},lF=Hn({name:"renderedTicks",initialState:qpe,reducers:{setRenderedTicks:(e,t)=>{var{axisType:n,axisId:r,ticks:i}=t.payload;e[n][r]=i},removeRenderedTicks:(e,t)=>{var{axisType:n,axisId:r}=t.payload;delete e[n][r]}}}),{setRenderedTicks:Kpe,removeRenderedTicks:Ype}=lF.actions,Xpe=lF.reducer,Zpe=["axisLine","width","height","className","hide","ticks","axisType","axisId"];function Qpe(e,t){if(e==null)return{};var n,r,i=Jpe(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Jpe(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function hs(){return hs=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},hs.apply(null,arguments)}function wR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function qt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?wR(Object(n),!0).forEach(function(r){ehe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ehe(e,t,n){return(t=the(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function the(e){var t=nhe(e,"string");return typeof t=="symbol"?t:t+""}function nhe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var ho={x:0,y:0,width:0,height:0,viewBox:{x:0,y:0,width:0,height:0},orientation:"bottom",ticks:[],stroke:"#666",tickLine:!0,axisLine:!0,tick:!0,mirror:!1,minTickGap:5,tickSize:6,tickMargin:2,interval:"preserveEnd",zIndex:Qn.axis};function rhe(e){var{x:t,y:n,width:r,height:i,orientation:o,mirror:a,axisLine:s,otherSvgProps:u}=e;if(!s)return null;var c=qt(qt(qt({},u),vo(s)),{},{fill:"none"});if(o==="top"||o==="bottom"){var f=+(o==="top"&&!a||o==="bottom"&&a);c=qt(qt({},c),{},{x1:t,y1:n+f*i,x2:t+r,y2:n+f*i})}else{var p=+(o==="left"&&!a||o==="right"&&a);c=qt(qt({},c),{},{x1:t+p*r,y1:n,x2:t+p*r,y2:n+i})}return x.createElement("line",hs({},c,{className:At("recharts-cartesian-axis-line",xl(s,"className"))}))}function ihe(e,t,n,r,i,o,a,s,u){var c,f,p,g,h,v,b=s?-1:1,y=e.tickSize||a,w=Ne(e.tickCoord)?e.tickCoord:e.coordinate;switch(o){case"top":c=f=e.coordinate,g=n+ +!s*i,p=g-b*y,v=p-b*u,h=w;break;case"left":p=g=e.coordinate,f=t+ +!s*r,c=f-b*y,h=c-b*u,v=w;break;case"right":p=g=e.coordinate,f=t+ +s*r,c=f+b*y,h=c+b*u,v=w;break;default:c=f=e.coordinate,g=n+ +s*i,p=g+b*y,v=p+b*u,h=w;break}return{line:{x1:c,y1:p,x2:f,y2:g},tick:{x:h,y:v}}}function ohe(e,t){switch(e){case"left":return t?"start":"end";case"right":return t?"end":"start";default:return"middle"}}function ahe(e,t){switch(e){case"left":case"right":return"middle";case"top":return t?"start":"end";default:return t?"end":"start"}}function she(e){var{option:t,tickProps:n,value:r}=e,i,o=At(n.className,"recharts-cartesian-axis-tick-value");if(x.isValidElement(t))i=x.cloneElement(t,qt(qt({},n),{},{className:o}));else if(typeof t=="function")i=t(qt(qt({},n),{},{className:o}));else{var a="recharts-cartesian-axis-tick-value";typeof t!="boolean"&&(a=At(a,xde(t))),i=x.createElement(dS,hs({},n,{className:a}),r)}return i}function lhe(e){var{ticks:t,axisType:n,axisId:r}=e,i=Ut();return $.useEffect(()=>{if(r==null||n==null)return ys;var o=t.map(a=>({value:a.value,coordinate:a.coordinate,offset:a.offset,index:a.index}));return i(Kpe({ticks:o,axisId:r,axisType:n})),()=>{i(Ype({axisId:r,axisType:n}))}},[i,t,r,n]),null}var uhe=$.forwardRef((e,t)=>{var{ticks:n=[],tick:r,tickLine:i,stroke:o,tickFormatter:a,unit:s,padding:u,tickTextProps:c,orientation:f,mirror:p,x:g,y:h,width:v,height:b,tickSize:y,tickMargin:w,fontSize:S,letterSpacing:E,getTicksConfig:_,events:P,axisType:R,axisId:I}=e,k=hS(qt(qt({},_),{},{ticks:n}),S,E),B=vo(_),L=z0(r),V=z$(B.textAnchor)?B.textAnchor:ohe(f,p),D=ahe(f,p),W={};typeof i=="object"&&(W=i);var J=qt(qt({},B),{},{fill:"none"},W),re=k.map(Z=>qt({entry:Z},ihe(Z,g,h,v,b,f,y,p,w))),U=re.map(Z=>{var{entry:ue,line:X}=Z;return x.createElement($i,{className:"recharts-cartesian-axis-tick",key:"tick-".concat(ue.value,"-").concat(ue.coordinate,"-").concat(ue.tickCoord)},i&&x.createElement("line",hs({},J,X,{className:At("recharts-cartesian-axis-tick-line",xl(i,"className"))})))}),ee=re.map((Z,ue)=>{var X,Oe,{entry:Ee,tick:Me}=Z,ye=qt(qt(qt(qt({verticalAnchor:D},B),{},{textAnchor:V,stroke:"none",fill:o},Me),{},{index:ue,payload:Ee,visibleTicksCount:k.length,tickFormatter:a,padding:u},c),{},{angle:(X=(Oe=c?.angle)!==null&&Oe!==void 0?Oe:B.angle)!==null&&X!==void 0?X:0}),be=qt(qt({},ye),L);return x.createElement($i,hs({className:"recharts-cartesian-axis-tick-label",key:"tick-label-".concat(Ee.value,"-").concat(Ee.coordinate,"-").concat(Ee.tickCoord)},Y0(P,Ee,ue)),r&&x.createElement(she,{option:r,tickProps:be,value:"".concat(typeof a=="function"?a(Ee.value,ue):Ee.value).concat(s||"")}))});return x.createElement("g",{className:"recharts-cartesian-axis-ticks recharts-".concat(R,"-ticks")},x.createElement(lhe,{ticks:k,axisId:I,axisType:R}),ee.length>0&&x.createElement(ko,{zIndex:Qn.label},x.createElement("g",{className:"recharts-cartesian-axis-tick-labels recharts-".concat(R,"-tick-labels"),ref:t},ee)),U.length>0&&x.createElement("g",{className:"recharts-cartesian-axis-tick-lines recharts-".concat(R,"-tick-lines")},U))}),che=$.forwardRef((e,t)=>{var{axisLine:n,width:r,height:i,className:o,hide:a,ticks:s,axisType:u,axisId:c}=e,f=Qpe(e,Zpe),[p,g]=$.useState(""),[h,v]=$.useState(""),b=$.useRef(null);$.useImperativeHandle(t,()=>({getCalculatedWidth:()=>{var w;return Gpe({ticks:b.current,label:(w=e.labelRef)===null||w===void 0?void 0:w.current,labelGapWithTick:5,tickSize:e.tickSize,tickMargin:e.tickMargin})}}));var y=$.useCallback(w=>{if(w){var S=w.getElementsByClassName("recharts-cartesian-axis-tick-value");b.current=S;var E=S[0];if(E){var _=window.getComputedStyle(E),P=_.fontSize,R=_.letterSpacing;(P!==p||R!==h)&&(g(P),v(R))}}},[p,h]);return a||r!=null&&r<=0||i!=null&&i<=0?null:x.createElement(ko,{zIndex:e.zIndex},x.createElement($i,{className:At("recharts-cartesian-axis",o)},x.createElement(rhe,{x:e.x,y:e.y,width:r,height:i,orientation:e.orientation,mirror:e.mirror,axisLine:n,otherSvgProps:vo(e)}),x.createElement(uhe,{ref:y,axisType:u,events:f,fontSize:p,getTicksConfig:e,height:e.height,letterSpacing:h,mirror:e.mirror,orientation:e.orientation,padding:e.padding,stroke:e.stroke,tick:e.tick,tickFormatter:e.tickFormatter,tickLine:e.tickLine,tickMargin:e.tickMargin,tickSize:e.tickSize,tickTextProps:e.tickTextProps,ticks:s,unit:e.unit,width:e.width,x:e.x,y:e.y,axisId:c}),x.createElement(Jfe,{x:e.x,y:e.y,width:e.width,height:e.height,lowerWidth:e.width,upperWidth:e.width},x.createElement(ude,{label:e.label,labelRef:e.labelRef}),e.children)))}),gS=x.forwardRef((e,t)=>{var n=Dr(e,ho);return x.createElement(che,hs({},n,{ref:t}))});gS.displayName="CartesianAxis";var fhe=["x1","y1","x2","y2","key"],dhe=["offset"],phe=["xAxisId","yAxisId"],hhe=["xAxisId","yAxisId"];function SR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function zn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?SR(Object(n),!0).forEach(function(r){ghe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):SR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ghe(e,t,n){return(t=mhe(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function mhe(e){var t=vhe(e,"string");return typeof t=="symbol"?t:t+""}function vhe(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Za(){return Za=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Za.apply(null,arguments)}function Yp(e,t){if(e==null)return{};var n,r,i=yhe(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function yhe(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var bhe=e=>{var{fill:t}=e;if(!t||t==="none")return null;var{fillOpacity:n,x:r,y:i,width:o,height:a,ry:s}=e;return x.createElement("rect",{x:r,y:i,ry:s,width:o,height:a,stroke:"none",fill:t,fillOpacity:n,className:"recharts-cartesian-grid-bg"})};function uF(e){var{option:t,lineItemProps:n}=e,r;if(x.isValidElement(t))r=x.cloneElement(t,n);else if(typeof t=="function")r=t(n);else{var i,{x1:o,y1:a,x2:s,y2:u,key:c}=n,f=Yp(n,fhe),p=(i=vo(f))!==null&&i!==void 0?i:{},{offset:g}=p,h=Yp(p,dhe);r=x.createElement("line",Za({},h,{x1:o,y1:a,x2:s,y2:u,fill:"none",key:c}))}return r}function xhe(e){var{x:t,width:n,horizontal:r=!0,horizontalPoints:i}=e;if(!r||!i||!i.length)return null;var{xAxisId:o,yAxisId:a}=e,s=Yp(e,phe),u=i.map((c,f)=>{var p=zn(zn({},s),{},{x1:t,y1:c,x2:t+n,y2:c,key:"line-".concat(f),index:f});return x.createElement(uF,{key:"line-".concat(f),option:r,lineItemProps:p})});return x.createElement("g",{className:"recharts-cartesian-grid-horizontal"},u)}function whe(e){var{y:t,height:n,vertical:r=!0,verticalPoints:i}=e;if(!r||!i||!i.length)return null;var{xAxisId:o,yAxisId:a}=e,s=Yp(e,hhe),u=i.map((c,f)=>{var p=zn(zn({},s),{},{x1:c,y1:t,x2:c,y2:t+n,key:"line-".concat(f),index:f});return x.createElement(uF,{option:r,lineItemProps:p,key:"line-".concat(f)})});return x.createElement("g",{className:"recharts-cartesian-grid-vertical"},u)}function She(e){var{horizontalFill:t,fillOpacity:n,x:r,y:i,width:o,height:a,horizontalPoints:s,horizontal:u=!0}=e;if(!u||!t||!t.length||s==null)return null;var c=s.map(p=>Math.round(p+i-i)).sort((p,g)=>p-g);i!==c[0]&&c.unshift(0);var f=c.map((p,g)=>{var h=c[g+1],v=h==null,b=v?i+a-p:h-p;if(b<=0)return null;var y=g%t.length;return x.createElement("rect",{key:"react-".concat(g),y:p,x:r,height:b,width:o,stroke:"none",fill:t[y],fillOpacity:n,className:"recharts-cartesian-grid-bg"})});return x.createElement("g",{className:"recharts-cartesian-gridstripes-horizontal"},f)}function Che(e){var{vertical:t=!0,verticalFill:n,fillOpacity:r,x:i,y:o,width:a,height:s,verticalPoints:u}=e;if(!t||!n||!n.length)return null;var c=u.map(p=>Math.round(p+i-i)).sort((p,g)=>p-g);i!==c[0]&&c.unshift(0);var f=c.map((p,g)=>{var h=c[g+1],v=h==null,b=v?i+a-p:h-p;if(b<=0)return null;var y=g%n.length;return x.createElement("rect",{key:"react-".concat(g),x:p,y:o,width:b,height:s,stroke:"none",fill:n[y],fillOpacity:r,className:"recharts-cartesian-grid-bg"})});return x.createElement("g",{className:"recharts-cartesian-gridstripes-vertical"},f)}var Ehe=(e,t)=>{var{xAxis:n,width:r,height:i,offset:o}=e;return Hj(hS(zn(zn(zn({},ho),n),{},{ticks:Uj(n),viewBox:{x:0,y:0,width:r,height:i}})),o.left,o.left+o.width,t)},_he=(e,t)=>{var{yAxis:n,width:r,height:i,offset:o}=e;return Hj(hS(zn(zn(zn({},ho),n),{},{ticks:Uj(n),viewBox:{x:0,y:0,width:r,height:i}})),o.top,o.top+o.height,t)},Ohe={horizontal:!0,vertical:!0,horizontalPoints:[],verticalPoints:[],stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[],xAxisId:0,yAxisId:0,syncWithTicks:!1,zIndex:Qn.grid};function cF(e){var t=Qj(),n=Jj(),r=Zj(),i=zn(zn({},Dr(e,Ohe)),{},{x:Ne(e.x)?e.x:r.left,y:Ne(e.y)?e.y:r.top,width:Ne(e.width)?e.width:r.width,height:Ne(e.height)?e.height:r.height}),{xAxisId:o,yAxisId:a,x:s,y:u,width:c,height:f,syncWithTicks:p,horizontalValues:g,verticalValues:h}=i,v=hr(),b=Be(B=>xA(B,"xAxis",o,v)),y=Be(B=>xA(B,"yAxis",a,v));if(!Bi(c)||!Bi(f)||!Ne(s)||!Ne(u))return null;var w=i.verticalCoordinatesGenerator||Ehe,S=i.horizontalCoordinatesGenerator||_he,{horizontalPoints:E,verticalPoints:_}=i;if((!E||!E.length)&&typeof S=="function"){var P=g&&g.length,R=S({yAxis:y?zn(zn({},y),{},{ticks:P?g:y.ticks}):void 0,width:t??c,height:n??f,offset:r},P?!0:p);wp(Array.isArray(R),"horizontalCoordinatesGenerator should return Array but instead it returned [".concat(typeof R,"]")),Array.isArray(R)&&(E=R)}if((!_||!_.length)&&typeof w=="function"){var I=h&&h.length,k=w({xAxis:b?zn(zn({},b),{},{ticks:I?h:b.ticks}):void 0,width:t??c,height:n??f,offset:r},I?!0:p);wp(Array.isArray(k),"verticalCoordinatesGenerator should return Array but instead it returned [".concat(typeof k,"]")),Array.isArray(k)&&(_=k)}return x.createElement(ko,{zIndex:i.zIndex},x.createElement("g",{className:"recharts-cartesian-grid"},x.createElement(bhe,{fill:i.fill,fillOpacity:i.fillOpacity,x:i.x,y:i.y,width:i.width,height:i.height,ry:i.ry}),x.createElement(She,Za({},i,{horizontalPoints:E})),x.createElement(Che,Za({},i,{verticalPoints:_})),x.createElement(xhe,Za({},i,{offset:r,horizontalPoints:E,xAxis:b,yAxis:y})),x.createElement(whe,Za({},i,{offset:r,verticalPoints:_,xAxis:b,yAxis:y}))))}cF.displayName="CartesianGrid";var Phe={},fF=Hn({name:"errorBars",initialState:Phe,reducers:{addErrorBar:(e,t)=>{var{itemId:n,errorBar:r}=t.payload;e[n]||(e[n]=[]),e[n].push(r)},replaceErrorBar:(e,t)=>{var{itemId:n,prev:r,next:i}=t.payload;e[n]&&(e[n]=e[n].map(o=>o.dataKey===r.dataKey&&o.direction===r.direction?i:o))},removeErrorBar:(e,t)=>{var{itemId:n,errorBar:r}=t.payload;e[n]&&(e[n]=e[n].filter(i=>i.dataKey!==r.dataKey||i.direction!==r.direction))}}}),{addErrorBar:Mve,replaceErrorBar:Dve,removeErrorBar:jve}=fF.actions,Ahe=fF.reducer,Rhe=["children"];function Ihe(e,t){if(e==null)return{};var n,r,i=The(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function The(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var khe={data:[],xAxisId:"xAxis-0",yAxisId:"yAxis-0",dataPointFormatter:()=>({x:0,y:0,value:0}),errorBarOffset:0},Nhe=$.createContext(khe);function Mhe(e){var{children:t}=e,n=Ihe(e,Rhe);return x.createElement(Nhe.Provider,{value:n},t)}function dF(e,t){var n,r,i=Be(c=>Ro(c,e)),o=Be(c=>Io(c,t)),a=(n=i?.allowDataOverflow)!==null&&n!==void 0?n:un.allowDataOverflow,s=(r=o?.allowDataOverflow)!==null&&r!==void 0?r:cn.allowDataOverflow,u=a||s;return{needClip:u,needClipX:a,needClipY:s}}function Dhe(e){var{xAxisId:t,yAxisId:n,clipPathId:r}=e,i=iF(),{needClipX:o,needClipY:a,needClip:s}=dF(t,n);if(!s||!i)return null;var{x:u,y:c,width:f,height:p}=i;return x.createElement("clipPath",{id:"clipPath-".concat(r)},x.createElement("rect",{x:o?u:u-f/2,y:a?c:c-p/2,width:o?f:f*2,height:a?p:p*2}))}function ws(e,t){var n,r;return(n=(r=e.graphicalItems.cartesianItems.find(i=>i.id===t))===null||r===void 0?void 0:r.xAxisId)!==null&&n!==void 0?n:nF}function Ss(e,t){var n,r;return(n=(r=e.graphicalItems.cartesianItems.find(i=>i.id===t))===null||r===void 0?void 0:r.yAxisId)!==null&&n!==void 0?n:nF}var jhe=process.env.NODE_ENV==="production",Iy="Invariant failed";function Lhe(e,t){if(jhe)throw new Error(Iy);var n=typeof t=="function"?t():t,r=n?"".concat(Iy,": ").concat(n):Iy;throw new Error(r)}function ax(){return ax=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ax.apply(null,arguments)}function mS(e){return x.createElement(Hde,ax({shapeType:"rectangle",activeClassName:"recharts-active-bar",inActiveClassName:"recharts-inactive-bar"},e))}var $he=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return(r,i)=>{if(Ne(t))return t;var o=Ne(r)||pn(r);return o?t(r,i):(o||Lhe(!1,"minPointSize callback function received a value with type of ".concat(typeof r,". Currently only numbers or null/undefined are supported.")),n)}},Fhe=(e,t,n)=>n,Vhe=(e,t)=>t,Vc=K([qw,Vhe],(e,t)=>e.filter(n=>n.type==="bar").find(n=>n.id===t)),Bhe=K([Vc],e=>e?.maxBarSize),zhe=(e,t,n,r)=>r,Whe=K([Rt,qw,ws,Ss,Fhe],(e,t,n,r,i)=>t.filter(o=>e==="horizontal"?o.xAxisId===n:o.yAxisId===r).filter(o=>o.isPanorama===i).filter(o=>o.hide===!1).filter(o=>o.type==="bar")),Hhe=(e,t,n)=>{var r=Rt(e),i=ws(e,t),o=Ss(e,t);if(!(i==null||o==null))return r==="horizontal"?tx(e,"yAxis",o,n):tx(e,"xAxis",i,n)},Uhe=(e,t)=>{var n=Rt(e),r=ws(e,t),i=Ss(e,t);if(!(r==null||i==null))return n==="horizontal"?bA(e,"xAxis",r):bA(e,"yAxis",i)},Ghe=K([Whe,ooe,Uhe],bpe),qhe=(e,t,n)=>{var r,i,o=Vc(e,t);if(o==null)return 0;var a=ws(e,t),s=Ss(e,t);if(a==null||s==null)return 0;var u=Rt(e),c=M2(e),{maxBarSize:f}=o,p=pn(f)?c:f,g,h;return u==="horizontal"?(g=Pl(e,"xAxis",a,n),h=Ol(e,"xAxis",a,n)):(g=Pl(e,"yAxis",s,n),h=Ol(e,"yAxis",s,n)),(r=(i=xp(g,h,!0))!==null&&i!==void 0?i:p)!==null&&r!==void 0?r:0},pF=(e,t,n)=>{var r=Rt(e),i=ws(e,t),o=Ss(e,t);if(!(i==null||o==null)){var a,s;return r==="horizontal"?(a=Pl(e,"xAxis",i,n),s=Ol(e,"xAxis",i,n)):(a=Pl(e,"yAxis",o,n),s=Ol(e,"yAxis",o,n)),xp(a,s)}},Khe=K([Ghe,M2,ioe,D2,qhe,pF,Bhe],Epe),Yhe=(e,t,n)=>{var r=ws(e,t);if(r!=null)return Pl(e,"xAxis",r,n)},Xhe=(e,t,n)=>{var r=Ss(e,t);if(r!=null)return Pl(e,"yAxis",r,n)},Zhe=(e,t,n)=>{var r=ws(e,t);if(r!=null)return Ol(e,"xAxis",r,n)},Qhe=(e,t,n)=>{var r=Ss(e,t);if(r!=null)return Ol(e,"yAxis",r,n)},Jhe=K([Khe,Vc],Ope),ege=K([Hhe,Vc],_pe),tge=K([wn,iw,Yhe,Xhe,Zhe,Qhe,Jhe,Rt,Qie,pF,ege,Vc,zhe],(e,t,n,r,i,o,a,s,u,c,f,p,g)=>{var{chartData:h,dataStartIndex:v,dataEndIndex:b}=u;if(!(p==null||a==null||t==null||s!=="horizontal"&&s!=="vertical"||n==null||r==null||i==null||o==null||c==null)){var{data:y}=p,w;if(y!=null&&y.length>0?w=y:w=h?.slice(v,b+1),w!=null)return Rge({layout:s,barSettings:p,pos:a,parentViewBox:t,bandSize:c,xAxis:n,yAxis:r,xAxisTicks:i,yAxisTicks:o,stackedData:f,displayedData:w,offset:e,cells:g,dataStartIndex:v})}}),nge=["index"];function sx(){return sx=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},sx.apply(null,arguments)}function rge(e,t){if(e==null)return{};var n,r,i=ige(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function ige(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var hF=$.createContext(void 0),oge=e=>{var t=$.useContext(hF);if(t!=null)return t.stackId;if(e!=null)return nne(e)},age=(e,t)=>"recharts-bar-stack-clip-path-".concat(e,"-").concat(t),sge=e=>{var t=$.useContext(hF);if(t!=null){var{stackId:n}=t;return"url(#".concat(age(n,e),")")}},gF=e=>{var{index:t}=e,n=rge(e,nge),r=sge(t);return x.createElement($i,sx({className:"recharts-bar-stack-layer",clipPath:r},n))},lge=["onMouseEnter","onMouseLeave","onClick"],uge=["value","background","tooltipPosition"],cge=["id"],fge=["onMouseEnter","onClick","onMouseLeave"];function da(){return da=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},da.apply(null,arguments)}function CR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Xn(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?CR(Object(n),!0).forEach(function(r){dge(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):CR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function dge(e,t,n){return(t=pge(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pge(e){var t=hge(e,"string");return typeof t=="symbol"?t:t+""}function hge(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Xp(e,t){if(e==null)return{};var n,r,i=gge(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function gge(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var mge=e=>{var{dataKey:t,name:n,fill:r,legendType:i,hide:o}=e;return[{inactive:o,dataKey:t,type:i,color:r,value:Gj(n,t),payload:e}]},vge=x.memo(e=>{var{dataKey:t,stroke:n,strokeWidth:r,fill:i,name:o,hide:a,unit:s,tooltipType:u,id:c}=e,f={dataDefinedOnItem:void 0,getPosition:ys,settings:{stroke:n,strokeWidth:r,fill:i,dataKey:t,nameKey:void 0,name:Gj(o,t),hide:a,type:u,color:i,unit:s,graphicalItemId:c}};return x.createElement(Ude,{tooltipEntrySettings:f})});function yge(e){var t=Be(Al),{data:n,dataKey:r,background:i,allOtherBarProps:o}=e,{onMouseEnter:a,onMouseLeave:s,onClick:u}=o,c=Xp(o,lge),f=Q$(a,r,o.id),p=J$(s),g=eF(u,r,o.id);if(!i||n==null)return null;var h=z0(i);return x.createElement(ko,{zIndex:Ppe(i,Qn.barBackground)},n.map((v,b)=>{var{value:y,background:w,tooltipPosition:S}=v,E=Xp(v,uge);if(!w)return null;var _=f(v,b),P=p(v,b),R=g(v,b),I=Xn(Xn(Xn(Xn(Xn({option:i,isActive:String(b)===t},E),{},{fill:"#eee"},w),h),Y0(c,v,b)),{},{onMouseEnter:_,onMouseLeave:P,onClick:R,dataKey:r,index:b,className:"recharts-bar-background-rectangle"});return x.createElement(mS,da({key:"background-bar-".concat(b)},I))}))}function bge(e){var{showLabels:t,children:n,rects:r}=e,i=r?.map(o=>{var a={x:o.x,y:o.y,width:o.width,lowerWidth:o.width,upperWidth:o.width,height:o.height};return Xn(Xn({},a),{},{value:o.value,payload:o.payload,parentViewBox:o.parentViewBox,viewBox:a,fill:o.fill})});return x.createElement(hde,{value:t?i:void 0},n)}function xge(e){var{shape:t,activeBar:n,baseProps:r,entry:i,index:o,dataKey:a}=e,s=Be(Al),u=Be(O$),c=n&&String(i.originalDataIndex)===s&&(u==null||a===u),[f,p]=$.useState(!1),[g,h]=$.useState(!1);$.useEffect(()=>{var E;return c?(p(!0),E=requestAnimationFrame(()=>{h(!0)})):h(!1),()=>{cancelAnimationFrame(E)}},[c]);var v=$.useCallback(()=>{c||p(!1)},[c]),b=c&&g,y=c||f,w;c?n===!0?w=t:w=n:w=t;var S=x.createElement(mS,da({},r,{name:String(r.name)},i,{isActive:b,option:w,index:o,dataKey:a,onTransitionEnd:v}));return y?x.createElement(ko,{zIndex:Qn.activeBar},x.createElement(gF,{index:i.originalDataIndex},S)):S}function wge(e){var{shape:t,baseProps:n,entry:r,index:i,dataKey:o}=e;return x.createElement(mS,da({},n,{name:String(n.name)},r,{isActive:!1,option:t,index:i,dataKey:o}))}function Sge(e){var t,{data:n,props:r}=e,i=(t=vo(r))!==null&&t!==void 0?t:{},{id:o}=i,a=Xp(i,cge),{shape:s,dataKey:u,activeBar:c}=r,{onMouseEnter:f,onClick:p,onMouseLeave:g}=r,h=Xp(r,fge),v=Q$(f,u,o),b=J$(g),y=eF(p,u,o);return n?x.createElement(x.Fragment,null,n.map((w,S)=>x.createElement(gF,da({index:w.originalDataIndex,key:"rectangle-".concat(w?.x,"-").concat(w?.y,"-").concat(w?.value,"-").concat(S),className:"recharts-bar-rectangle"},Y0(h,w,S),{onMouseEnter:v(w,S),onMouseLeave:b(w,S),onClick:y(w,S)}),c?x.createElement(xge,{shape:s,activeBar:c,baseProps:a,entry:w,index:S,dataKey:u}):x.createElement(wge,{shape:s,baseProps:a,entry:w,index:S,dataKey:u})))):null}function Cge(e){var{props:t,previousRectanglesRef:n}=e,{data:r,layout:i,isAnimationActive:o,animationBegin:a,animationDuration:s,animationEasing:u,onAnimationEnd:c,onAnimationStart:f}=t,p=n.current,g=cw(t,"recharts-bar-"),[h,v]=$.useState(!1),b=!h,y=$.useCallback(()=>{typeof c=="function"&&c(),v(!1)},[c]),w=$.useCallback(()=>{typeof f=="function"&&f(),v(!0)},[f]);return x.createElement(bge,{showLabels:b,rects:r},x.createElement(uw,{animationId:g,begin:a,duration:s,isActive:o,easing:u,onAnimationEnd:y,onAnimationStart:w,key:g},S=>{var E=S===1?r:r?.map((_,P)=>{var R=p&&p[P];if(R)return Xn(Xn({},_),{},{x:Tn(R.x,_.x,S),y:Tn(R.y,_.y,S),width:Tn(R.width,_.width,S),height:Tn(R.height,_.height,S)});if(i==="horizontal"){var I=Tn(0,_.height,S),k=Tn(_.stackedBarStart,_.y,S);return Xn(Xn({},_),{},{y:k,height:I})}var B=Tn(0,_.width,S),L=Tn(_.stackedBarStart,_.x,S);return Xn(Xn({},_),{},{width:B,x:L})});return S>0&&(n.current=E??null),E==null?null:x.createElement($i,null,x.createElement(Sge,{props:t,data:E}))}),x.createElement(vde,{label:t.label}),t.children)}function Ege(e){var t=$.useRef(null);return x.createElement(Cge,{previousRectanglesRef:t,props:e})}var mF=0,_ge=(e,t)=>{var n=Array.isArray(e.value)?e.value[1]:e.value;return{x:e.x,y:e.y,value:n,errorVal:Mn(e,t)}};class Oge extends $.PureComponent{render(){var{hide:t,data:n,dataKey:r,className:i,xAxisId:o,yAxisId:a,needClip:s,background:u,id:c}=this.props;if(t||n==null)return null;var f=At("recharts-bar",i),p=c;return x.createElement($i,{className:f,id:c},s&&x.createElement("defs",null,x.createElement(Dhe,{clipPathId:p,xAxisId:o,yAxisId:a})),x.createElement($i,{className:"recharts-bar-rectangles",clipPath:s?"url(#clipPath-".concat(p,")"):void 0},x.createElement(yge,{data:n,dataKey:r,background:u,allOtherBarProps:this.props}),x.createElement(Ege,this.props)))}}var Pge={activeBar:!1,animationBegin:0,animationDuration:400,animationEasing:"ease",background:!1,hide:!1,isAnimationActive:"auto",label:!1,legendType:"rect",minPointSize:mF,xAxisId:0,yAxisId:0,zIndex:Qn.bar};function Age(e){var{xAxisId:t,yAxisId:n,hide:r,legendType:i,minPointSize:o,activeBar:a,animationBegin:s,animationDuration:u,animationEasing:c,isAnimationActive:f}=e,{needClip:p}=dF(t,n),g=Tl(),h=hr(),v=_de(e.children,j$),b=Be(S=>tge(S,e.id,h,v));if(g!=="vertical"&&g!=="horizontal")return null;var y,w=b?.[0];return w==null||w.height==null||w.width==null?y=0:y=g==="vertical"?w.height/2:w.width/2,x.createElement(Mhe,{xAxisId:t,yAxisId:n,data:b,dataPointFormatter:_ge,errorBarOffset:y},x.createElement(Oge,da({},e,{layout:g,needClip:p,data:b,xAxisId:t,yAxisId:n,hide:r,legendType:i,minPointSize:o,activeBar:a,animationBegin:s,animationDuration:u,animationEasing:c,isAnimationActive:f})))}function Rge(e){var{layout:t,barSettings:{dataKey:n,minPointSize:r,hasCustomShape:i},pos:o,bandSize:a,xAxis:s,yAxis:u,xAxisTicks:c,yAxisTicks:f,stackedData:p,displayedData:g,offset:h,cells:v,parentViewBox:b,dataStartIndex:y}=e,w=t==="horizontal"?u:s,S=p?w.scale.domain():null,E=rne({numericAxis:w}),_=w.scale.map(E);return g.map((P,R)=>{var I,k,B,L,V,D;if(p){var W=p[R+y];if(W==null)return null;I=Zte(W,S)}else I=Mn(P,n),Array.isArray(I)||(I=[E,I]);var J=$he(r,mF)(I[1],R);if(t==="horizontal"){var re,U=u.scale.map(I[0]),ee=u.scale.map(I[1]);if(U==null||ee==null)return null;k=hO({axis:s,ticks:c,bandSize:a,offset:o.offset,entry:P,index:R}),B=(re=ee??U)!==null&&re!==void 0?re:void 0,L=o.size;var Z=U-ee;if(V=Fi(Z)?0:Z,D={x:k,y:h.top,width:L,height:h.height},Math.abs(J)>0&&Math.abs(V)<Math.abs(J)){var ue=fr(V||J)*(Math.abs(J)-Math.abs(V));B-=ue,V+=ue}}else{var X=s.scale.map(I[0]),Oe=s.scale.map(I[1]);if(X==null||Oe==null)return null;if(k=X,B=hO({axis:u,ticks:f,bandSize:a,offset:o.offset,entry:P,index:R}),L=Oe-X,V=o.size,D={x:h.left,y:B,width:h.width,height:V},Math.abs(J)>0&&Math.abs(L)<Math.abs(J)){var Ee=fr(L||J)*(Math.abs(J)-Math.abs(L));L+=Ee}}if(k==null||B==null||L==null||V==null||!i&&(L===0||V===0))return null;var Me=Xn(Xn({},P),{},{stackedBarStart:_,x:k,y:B,width:L,height:V,value:p?I:I[1],payload:P,background:D,tooltipPosition:{x:k+L/2,y:B+V/2},parentViewBox:b,originalDataIndex:R},v&&v[R]&&v[R].props);return Me}).filter(Boolean)}function Ige(e){var t=Dr(e,Pge),n=oge(t.stackId),r=hr();return x.createElement(Zde,{id:t.id,type:"bar"},i=>x.createElement(x.Fragment,null,x.createElement(Gde,{legendPayload:mge(t)}),x.createElement(vge,{dataKey:t.dataKey,stroke:t.stroke,strokeWidth:t.strokeWidth,fill:t.fill,name:t.name,hide:t.hide,unit:t.unit,tooltipType:t.tooltipType,id:i}),x.createElement(ipe,{type:"bar",id:i,data:void 0,xAxisId:t.xAxisId,yAxisId:t.yAxisId,zAxisId:0,dataKey:t.dataKey,stackId:n,hide:t.hide,barSize:t.barSize,minPointSize:t.minPointSize,maxBarSize:t.maxBarSize,isPanorama:r,hasCustomShape:t.shape!=null}),x.createElement(ko,{zIndex:t.zIndex},x.createElement(Age,da({},t,{id:i})))))}var vF=x.memo(Ige,ng);vF.displayName="Bar";var Tge=["domain","range"],kge=["domain","range"];function ER(e,t){if(e==null)return{};var n,r,i=Nge(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Nge(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function _R(e,t){return e===t?!0:Array.isArray(e)&&e.length===2&&Array.isArray(t)&&t.length===2?e[0]===t[0]&&e[1]===t[1]:!1}function yF(e,t){if(e===t)return!0;var{domain:n,range:r}=e,i=ER(e,Tge),{domain:o,range:a}=t,s=ER(t,kge);return!_R(n,o)||!_R(r,a)?!1:ng(i,s)}var Mge=["type"],Dge=["dangerouslySetInnerHTML","ticks","scale"],jge=["id","scale"];function lx(){return lx=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},lx.apply(null,arguments)}function OR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function PR(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?OR(Object(n),!0).forEach(function(r){Lge(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):OR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Lge(e,t,n){return(t=$ge(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function $ge(e){var t=Fge(e,"string");return typeof t=="symbol"?t:t+""}function Fge(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ux(e,t){if(e==null)return{};var n,r,i=Vge(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Vge(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function Bge(e){var t=Ut(),n=$.useRef(null),r=e2(),{type:i}=e,o=ux(e,Mge),a=og(r,"xAxis",i),s=$.useMemo(()=>{if(a!=null)return PR(PR({},o),{},{type:a})},[o,a]);return $.useLayoutEffect(()=>{s!=null&&(n.current===null?t(upe(s)):n.current!==s&&t(cpe({prev:n.current,next:s})),n.current=s)},[s,t]),$.useLayoutEffect(()=>()=>{n.current&&(t(fpe(n.current)),n.current=null)},[t]),null}var zge=e=>{var{xAxisId:t,className:n}=e,r=Be(iw),i=hr(),o="xAxis",a=Be(w=>o$(w,o,t,i)),s=Be(w=>n$(w,t)),u=Be(w=>Fle(w,t)),c=Be(w=>_L(w,t));if(s==null||u==null||c==null)return null;var{dangerouslySetInnerHTML:f,ticks:p,scale:g}=e,h=ux(e,Dge),{id:v,scale:b}=c,y=ux(c,jge);return x.createElement(gS,lx({},h,y,{x:u.x,y:u.y,width:s.width,height:s.height,className:At("recharts-".concat(o," ").concat(o),n),viewBox:r,ticks:a,axisType:o,axisId:t}))},Wge={allowDataOverflow:un.allowDataOverflow,allowDecimals:un.allowDecimals,allowDuplicatedCategory:un.allowDuplicatedCategory,angle:un.angle,axisLine:ho.axisLine,height:un.height,hide:!1,includeHidden:un.includeHidden,interval:un.interval,label:!1,minTickGap:un.minTickGap,mirror:un.mirror,orientation:un.orientation,padding:un.padding,reversed:un.reversed,scale:un.scale,tick:un.tick,tickCount:un.tickCount,tickLine:ho.tickLine,tickSize:ho.tickSize,type:un.type,niceTicks:un.niceTicks,xAxisId:0},Hge=e=>{var t=Dr(e,Wge);return x.createElement(x.Fragment,null,x.createElement(Bge,{allowDataOverflow:t.allowDataOverflow,allowDecimals:t.allowDecimals,allowDuplicatedCategory:t.allowDuplicatedCategory,angle:t.angle,dataKey:t.dataKey,domain:t.domain,height:t.height,hide:t.hide,id:t.xAxisId,includeHidden:t.includeHidden,interval:t.interval,minTickGap:t.minTickGap,mirror:t.mirror,name:t.name,orientation:t.orientation,padding:t.padding,reversed:t.reversed,scale:t.scale,tick:t.tick,tickCount:t.tickCount,tickFormatter:t.tickFormatter,ticks:t.ticks,type:t.type,unit:t.unit,niceTicks:t.niceTicks}),x.createElement(zge,t))},bF=x.memo(Hge,yF);bF.displayName="XAxis";var Uge=["type"],Gge=["dangerouslySetInnerHTML","ticks","scale"],qge=["id","scale"];function cx(){return cx=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},cx.apply(null,arguments)}function AR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function RR(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?AR(Object(n),!0).forEach(function(r){Kge(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):AR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Kge(e,t,n){return(t=Yge(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Yge(e){var t=Xge(e,"string");return typeof t=="symbol"?t:t+""}function Xge(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function fx(e,t){if(e==null)return{};var n,r,i=Zge(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Zge(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function Qge(e){var t=Ut(),n=$.useRef(null),r=e2(),{type:i}=e,o=fx(e,Uge),a=og(r,"yAxis",i),s=$.useMemo(()=>{if(a!=null)return RR(RR({},o),{},{type:a})},[a,o]);return $.useLayoutEffect(()=>{s!=null&&(n.current===null?t(dpe(s)):n.current!==s&&t(ppe({prev:n.current,next:s})),n.current=s)},[s,t]),$.useLayoutEffect(()=>()=>{n.current&&(t(hpe(n.current)),n.current=null)},[t]),null}function Jge(e){var{yAxisId:t,className:n,width:r,label:i}=e,o=$.useRef(null),a=$.useRef(null),s=Be(iw),u=hr(),c=Ut(),f="yAxis",p=Be(R=>r$(R,t)),g=Be(R=>Ble(R,t)),h=Be(R=>o$(R,f,t,u)),v=Be(R=>OL(R,t));if($.useLayoutEffect(()=>{if(!(r!=="auto"||!p||pS(i)||$.isValidElement(i)||v==null)){var R=o.current;if(R){var I=R.getCalculatedWidth();Math.round(p.width)!==Math.round(I)&&c(gpe({id:t,width:I}))}}},[h,p,c,i,t,r,v]),p==null||g==null||v==null)return null;var{dangerouslySetInnerHTML:b,ticks:y,scale:w}=e,S=fx(e,Gge),{id:E,scale:_}=v,P=fx(v,qge);return x.createElement(gS,cx({},S,P,{ref:o,labelRef:a,x:g.x,y:g.y,tickTextProps:r==="auto"?{width:void 0}:{width:r},width:p.width,height:p.height,className:At("recharts-".concat(f," ").concat(f),n),viewBox:s,ticks:h,axisType:f,axisId:t}))}var eme={allowDataOverflow:cn.allowDataOverflow,allowDecimals:cn.allowDecimals,allowDuplicatedCategory:cn.allowDuplicatedCategory,angle:cn.angle,axisLine:ho.axisLine,hide:!1,includeHidden:cn.includeHidden,interval:cn.interval,label:!1,minTickGap:cn.minTickGap,mirror:cn.mirror,orientation:cn.orientation,padding:cn.padding,reversed:cn.reversed,scale:cn.scale,tick:cn.tick,tickCount:cn.tickCount,tickLine:ho.tickLine,tickSize:ho.tickSize,type:cn.type,niceTicks:cn.niceTicks,width:cn.width,yAxisId:0},tme=e=>{var t=Dr(e,eme);return x.createElement(x.Fragment,null,x.createElement(Qge,{interval:t.interval,id:t.yAxisId,scale:t.scale,type:t.type,domain:t.domain,allowDataOverflow:t.allowDataOverflow,dataKey:t.dataKey,allowDuplicatedCategory:t.allowDuplicatedCategory,allowDecimals:t.allowDecimals,tickCount:t.tickCount,padding:t.padding,includeHidden:t.includeHidden,reversed:t.reversed,ticks:t.ticks,width:t.width,orientation:t.orientation,mirror:t.mirror,hide:t.hide,unit:t.unit,name:t.name,angle:t.angle,minTickGap:t.minTickGap,tick:t.tick,tickFormatter:t.tickFormatter,niceTicks:t.niceTicks}),x.createElement(Jge,t))},xF=x.memo(tme,yF);xF.displayName="YAxis";var nme=(e,t)=>t,vS=K([nme,Rt,z2,Cn,S$,To,uce,wn],mce);function rme(e){return"getBBox"in e.currentTarget&&typeof e.currentTarget.getBBox=="function"}function yS(e){var t=e.currentTarget.getBoundingClientRect(),n,r;if(rme(e)){var i=e.currentTarget.getBBox();n=i.width>0?t.width/i.width:1,r=i.height>0?t.height/i.height:1}else{var o=e.currentTarget;n=o.offsetWidth>0?t.width/o.offsetWidth:1,r=o.offsetHeight>0?t.height/o.offsetHeight:1}var a=(s,u)=>({relativeX:Math.round((s-t.left)/n),relativeY:Math.round((u-t.top)/r)});return"touches"in e?Array.from(e.touches).map(s=>a(s.clientX,s.clientY)):a(e.clientX,e.clientY)}var wF=kr("mouseClick"),SF=Ec();SF.startListening({actionCreator:wF,effect:(e,t)=>{var n=e.payload,r=vS(t.getState(),yS(n));r?.activeIndex!=null&&t.dispatch(rue({activeIndex:r.activeIndex,activeDataKey:void 0,activeCoordinate:r.activeCoordinate}))}});var dx=kr("mouseMove"),CF=Ec(),rl=null,Ba=null,Ty=null;CF.startListening({actionCreator:dx,effect:(e,t)=>{var n=e.payload,r=t.getState(),{throttleDelay:i,throttledEvents:o}=r.eventSettings,a=o==="all"||o?.includes("mousemove");rl!==null&&(cancelAnimationFrame(rl),rl=null),Ba!==null&&(typeof i!="number"||!a)&&(clearTimeout(Ba),Ba=null),Ty=yS(n);var s=()=>{var u=t.getState(),c=nS(u,u.tooltip.settings.shared);if(!Ty){rl=null,Ba=null;return}if(c==="axis"){var f=vS(u,Ty);f?.activeIndex!=null?t.dispatch(p$({activeIndex:f.activeIndex,activeDataKey:void 0,activeCoordinate:f.activeCoordinate})):t.dispatch(d$())}rl=null,Ba=null};if(!a){s();return}i==="raf"?rl=requestAnimationFrame(s):typeof i=="number"&&Ba===null&&(Ba=setTimeout(s,i))}});function ime(e,t){return t instanceof HTMLElement?"HTMLElement <".concat(t.tagName,' class="').concat(t.className,'">'):t===window?"global.window":e==="children"&&typeof t=="object"&&t!==null?"<<CHILDREN>>":t}var IR={accessibilityLayer:!0,barCategoryGap:"10%",barGap:4,barSize:void 0,className:void 0,maxBarSize:void 0,stackOffset:"none",syncId:void 0,syncMethod:"index",baseValue:void 0,reverseStackOrder:!1},EF=Hn({name:"rootProps",initialState:IR,reducers:{updateOptions:(e,t)=>{var n;e.accessibilityLayer=t.payload.accessibilityLayer,e.barCategoryGap=t.payload.barCategoryGap,e.barGap=(n=t.payload.barGap)!==null&&n!==void 0?n:IR.barGap,e.barSize=t.payload.barSize,e.maxBarSize=t.payload.maxBarSize,e.stackOffset=t.payload.stackOffset,e.syncId=t.payload.syncId,e.syncMethod=t.payload.syncMethod,e.className=t.payload.className,e.baseValue=t.payload.baseValue,e.reverseStackOrder=t.payload.reverseStackOrder}}}),ome=EF.reducer,{updateOptions:ame}=EF.actions,sme=null,lme={updatePolarOptions:(e,t)=>e===null?t.payload:(e.startAngle=t.payload.startAngle,e.endAngle=t.payload.endAngle,e.cx=t.payload.cx,e.cy=t.payload.cy,e.innerRadius=t.payload.innerRadius,e.outerRadius=t.payload.outerRadius,e)},_F=Hn({name:"polarOptions",initialState:sme,reducers:lme}),{updatePolarOptions:Lve}=_F.actions,ume=_F.reducer,OF=kr("keyDown"),PF=kr("focus"),AF=kr("blur"),xg=Ec(),il=null,za=null,Ad=null;xg.startListening({actionCreator:OF,effect:(e,t)=>{Ad=e.payload,il!==null&&(cancelAnimationFrame(il),il=null);var n=t.getState(),{throttleDelay:r,throttledEvents:i}=n.eventSettings,o=i==="all"||i.includes("keydown");za!==null&&(typeof r!="number"||!o)&&(clearTimeout(za),za=null);var a=()=>{try{var s=t.getState(),u=s.rootProps.accessibilityLayer!==!1;if(!u)return;var{keyboardInteraction:c}=s.tooltip,f=Ad;if(f!=="ArrowRight"&&f!=="ArrowLeft"&&f!=="Enter")return;var p=rS(c,Vl(s),jc(s),$c(s)),g=p==null?-1:Number(p);if(!Number.isFinite(g)||g<0)return;var h=To(s);if(f==="Enter"){var v=Up(s,"axis","hover",String(c.index));t.dispatch(Hp({active:!c.active,activeIndex:c.index,activeCoordinate:v}));return}var b=Gle(s),y=b==="left-to-right"?1:-1,w=f==="ArrowRight"?1:-1,S=g+w*y;if(h==null||S>=h.length||S<0)return;var E=Up(s,"axis","hover",String(S));t.dispatch(Hp({active:!0,activeIndex:S.toString(),activeCoordinate:E}))}finally{il=null,za=null}};if(!o){a();return}r==="raf"?il=requestAnimationFrame(a):typeof r=="number"&&za===null&&(a(),Ad=null,za=setTimeout(()=>{Ad?a():(za=null,il=null)},r))}});xg.startListening({actionCreator:PF,effect:(e,t)=>{var n=t.getState(),r=n.rootProps.accessibilityLayer!==!1;if(r){var{keyboardInteraction:i}=n.tooltip;if(!i.active&&i.index==null){var o="0",a=Up(n,"axis","hover",String(o));t.dispatch(Hp({active:!0,activeIndex:o,activeCoordinate:a}))}}}});xg.startListening({actionCreator:AF,effect:(e,t)=>{var n=t.getState(),r=n.rootProps.accessibilityLayer!==!1;if(r){var{keyboardInteraction:i}=n.tooltip;i.active&&t.dispatch(Hp({active:!1,activeIndex:i.index,activeCoordinate:i.coordinate}))}}});function RF(e){e.persist();var{currentTarget:t}=e;return new Proxy(e,{get:(n,r)=>{if(r==="currentTarget")return t;var i=Reflect.get(n,r);return typeof i=="function"?i.bind(n):i}})}var Yr=kr("externalEvent"),IF=Ec(),Rd=new Map,Ou=new Map,ky=new Map;IF.startListening({actionCreator:Yr,effect:(e,t)=>{var{handler:n,reactEvent:r}=e.payload;if(n!=null){var i=r.type,o=RF(r);ky.set(i,{handler:n,reactEvent:o});var a=Rd.get(i);a!==void 0&&(cancelAnimationFrame(a),Rd.delete(i));var s=t.getState(),{throttleDelay:u,throttledEvents:c}=s.eventSettings,f=c,p=f==="all"||f?.includes(i),g=Ou.get(i);g!==void 0&&(typeof u!="number"||!p)&&(clearTimeout(g),Ou.delete(i));var h=()=>{var y=ky.get(i);try{if(!y)return;var{handler:w,reactEvent:S}=y,E=t.getState(),_={activeCoordinate:Kue(E),activeDataKey:O$(E),activeIndex:Al(E),activeLabel:_$(E),activeTooltipIndex:Al(E),isTooltipActive:Yue(E)};w&&w(_,S)}finally{Rd.delete(i),Ou.delete(i),ky.delete(i)}};if(!p){h();return}if(u==="raf"){var v=requestAnimationFrame(h);Rd.set(i,v)}else if(typeof u=="number"){if(!Ou.has(i)){h();var b=setTimeout(h,u);Ou.set(i,b)}}else h()}}});var cme=K([$l],e=>e.tooltipItemPayloads),fme=K([cme,(e,t)=>t,(e,t,n)=>n],(e,t,n)=>{if(t!=null){var r=e.find(o=>o.settings.graphicalItemId===n);if(r!=null){var{getPosition:i}=r;if(i!=null)return i(t)}}}),TF=kr("touchMove"),kF=Ec(),Wa=null,qo=null,TR=null,Pu=null;kF.startListening({actionCreator:TF,effect:(e,t)=>{var n=e.payload;if(!(n.touches==null||n.touches.length===0)){Pu=RF(n);var r=t.getState(),{throttleDelay:i,throttledEvents:o}=r.eventSettings,a=o==="all"||o.includes("touchmove");Wa!==null&&(cancelAnimationFrame(Wa),Wa=null),qo!==null&&(typeof i!="number"||!a)&&(clearTimeout(qo),qo=null),TR=Array.from(n.touches).map(u=>yS({clientX:u.clientX,clientY:u.clientY,currentTarget:n.currentTarget}));var s=()=>{if(Pu!=null){var u=t.getState(),c=nS(u,u.tooltip.settings.shared);if(c==="axis"){var f,p=(f=TR)===null||f===void 0?void 0:f[0];if(p==null){Wa=null,qo=null;return}var g=vS(u,p);g?.activeIndex!=null&&t.dispatch(p$({activeIndex:g.activeIndex,activeDataKey:void 0,activeCoordinate:g.activeCoordinate}))}else if(c==="item"){var h,v=Pu.touches[0];if(document.elementFromPoint==null||v==null)return;var b=document.elementFromPoint(v.clientX,v.clientY);if(!b||!b.getAttribute)return;var y=b.getAttribute(cne),w=(h=b.getAttribute(fne))!==null&&h!==void 0?h:void 0,S=Fl(u).find(P=>P.id===w);if(y==null||S==null||w==null)return;var{dataKey:E}=S,_=fme(u,y,w);t.dispatch(f$({activeDataKey:E,activeIndex:y,activeCoordinate:_,activeGraphicalItemId:w}))}Wa=null,qo=null}};if(!a){s();return}i==="raf"?Wa=requestAnimationFrame(s):typeof i=="number"&&qo===null&&(s(),Pu=null,qo=setTimeout(()=>{Pu?s():(qo=null,Wa=null)},i))}}});var NF={throttleDelay:"raf",throttledEvents:["mousemove","touchmove","pointermove","scroll","wheel"]},MF=Hn({name:"eventSettings",initialState:NF,reducers:{setEventSettings:(e,t)=>{t.payload.throttleDelay!=null&&(e.throttleDelay=t.payload.throttleDelay),t.payload.throttledEvents!=null&&(e.throttledEvents=t.payload.throttledEvents)}}}),{setEventSettings:dme}=MF.actions,pme=MF.reducer,hme=fj({brush:Rpe,cartesianAxis:mpe,chartData:Kce,errorBars:Ahe,eventSettings:pme,graphicalItems:npe,layout:Gte,legend:ire,options:Wce,polarAxis:bde,polarOptions:ume,referenceElements:Npe,renderedTicks:Xpe,rootProps:ome,tooltip:iue,zIndex:Ice}),gme=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"Chart";return vte({reducer:hme,preloadedState:t,middleware:r=>{var i;return r({serializableCheck:!1,immutableCheck:!["commonjs","es6","production"].includes((i="es6")!==null&&i!==void 0?i:"")}).concat([SF.middleware,CF.middleware,xg.middleware,IF.middleware,kF.middleware])},enhancers:r=>{var i=r;return typeof r=="function"&&(i=r()),i.concat(Ij({type:"raf"}))},devTools:{serialize:{replacer:ime},name:"recharts-".concat(n)}})};function mme(e){var{preloadedState:t,children:n,reduxStoreName:r}=e,i=hr(),o=$.useRef(null);if(i)return n;o.current==null&&(o.current=gme(t,r));var a=Z0;return x.createElement(Cre,{context:a,store:o.current},n)}function vme(e){var{layout:t,margin:n}=e,r=Ut(),i=hr();return $.useEffect(()=>{i||(r(Wte(t)),r(zte(n)))},[r,i,t,n]),null}var yme=$.memo(vme,ng);function bme(e){var t=Ut();return $.useEffect(()=>{t(ame(e))},[t,e]),null}var xme=e=>{var t=Ut();return $.useEffect(()=>{t(dme(e))},[t,e]),null},wme=$.memo(xme,ng);function kR(e){var{zIndex:t,isPanorama:n}=e,r=$.useRef(null),i=Ut();return $.useLayoutEffect(()=>(r.current&&i(Ace({zIndex:t,element:r.current,isPanorama:n})),()=>{i(Rce({zIndex:t,isPanorama:n}))}),[i,t,n]),x.createElement("g",{tabIndex:-1,ref:r,className:"recharts-zIndex-layer_".concat(t)})}function NR(e){var{children:t,isPanorama:n}=e,r=Be(yce);if(!r||r.length===0)return t;var i=r.filter(a=>a<0),o=r.filter(a=>a>0);return x.createElement(x.Fragment,null,i.map(a=>x.createElement(kR,{key:a,zIndex:a,isPanorama:n})),t,o.map(a=>x.createElement(kR,{key:a,zIndex:a,isPanorama:n})))}var Sme=["children"];function Cme(e,t){if(e==null)return{};var n,r,i=Eme(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Eme(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function Zp(){return Zp=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Zp.apply(null,arguments)}var _me={width:"100%",height:"100%",display:"block"},Ome=$.forwardRef((e,t)=>{var n=Qj(),r=Jj(),i=c2();if(!Bi(n)||!Bi(r))return null;var{children:o,otherAttributes:a,title:s,desc:u}=e,c,f;return a!=null&&(typeof a.tabIndex=="number"?c=a.tabIndex:c=i?0:void 0,typeof a.role=="string"?f=a.role:f=i?"application":void 0),x.createElement(ID,Zp({},a,{title:s,desc:u,role:f,tabIndex:c,width:n,height:r,style:_me,ref:t}),o)}),Pme=e=>{var{children:t}=e,n=Be(Zh);if(!n)return null;var{width:r,height:i,y:o,x:a}=n;return x.createElement(ID,{width:r,height:i,x:a,y:o},t)},MR=$.forwardRef((e,t)=>{var{children:n}=e,r=Cme(e,Sme),i=hr();return i?x.createElement(Pme,null,x.createElement(NR,{isPanorama:!0},n)):x.createElement(Ome,Zp({ref:t},r),x.createElement(NR,{isPanorama:!1},n))});function Ame(){var e=Ut(),[t,n]=$.useState(null),r=Be(une);return $.useEffect(()=>{if(t!=null){var i=t.getBoundingClientRect(),o=i.width/t.offsetWidth;dt(o)&&o!==r&&e(Ute(o))}},[t,e,r]),n}function DR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Rme(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?DR(Object(n),!0).forEach(function(r){Ime(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):DR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Ime(e,t,n){return(t=Tme(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Tme(e){var t=kme(e,"string");return typeof t=="symbol"?t:t+""}function kme(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function la(){return la=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},la.apply(null,arguments)}var Nme=()=>(rfe(),null);function Qp(e){if(typeof e=="number")return e;if(typeof e=="string"){var t=parseFloat(e);if(!Number.isNaN(t))return t}return 0}var Mme=$.forwardRef((e,t)=>{var n,r,i=$.useRef(null),[o,a]=$.useState({containerWidth:Qp((n=e.style)===null||n===void 0?void 0:n.width),containerHeight:Qp((r=e.style)===null||r===void 0?void 0:r.height)}),s=$.useCallback((c,f)=>{a(p=>{var g=Math.round(c),h=Math.round(f);return p.containerWidth===g&&p.containerHeight===h?p:{containerWidth:g,containerHeight:h}})},[]),u=$.useCallback(c=>{if(typeof t=="function"&&t(c),c!=null&&typeof ResizeObserver<"u"){var{width:f,height:p}=c.getBoundingClientRect();s(f,p);var g=v=>{var b=v[0];if(b!=null){var{width:y,height:w}=b.contentRect;s(y,w)}},h=new ResizeObserver(g);h.observe(c),i.current=h}},[t,s]);return $.useEffect(()=>()=>{var c=i.current;c?.disconnect()},[s]),x.createElement(x.Fragment,null,x.createElement(Oc,{width:o.containerWidth,height:o.containerHeight}),x.createElement("div",la({ref:u},e)))}),Dme=$.forwardRef((e,t)=>{var{width:n,height:r}=e,[i,o]=$.useState({containerWidth:Qp(n),containerHeight:Qp(r)}),a=$.useCallback((u,c)=>{o(f=>{var p=Math.round(u),g=Math.round(c);return f.containerWidth===p&&f.containerHeight===g?f:{containerWidth:p,containerHeight:g}})},[]),s=$.useCallback(u=>{if(typeof t=="function"&&t(u),u!=null){var{width:c,height:f}=u.getBoundingClientRect();a(c,f)}},[t,a]);return x.createElement(x.Fragment,null,x.createElement(Oc,{width:i.containerWidth,height:i.containerHeight}),x.createElement("div",la({ref:s},e)))}),jme=$.forwardRef((e,t)=>{var{width:n,height:r}=e;return x.createElement(x.Fragment,null,x.createElement(Oc,{width:n,height:r}),x.createElement("div",la({ref:t},e)))}),Lme=$.forwardRef((e,t)=>{var{width:n,height:r}=e;return typeof n=="string"||typeof r=="string"?x.createElement(Dme,la({},e,{ref:t})):typeof n=="number"&&typeof r=="number"?x.createElement(jme,la({},e,{width:n,height:r,ref:t})):x.createElement(x.Fragment,null,x.createElement(Oc,{width:n,height:r}),x.createElement("div",la({ref:t},e)))});function $me(e){return e?Mme:Lme}var Fme=$.forwardRef((e,t)=>{var{children:n,className:r,height:i,onClick:o,onContextMenu:a,onDoubleClick:s,onMouseDown:u,onMouseEnter:c,onMouseLeave:f,onMouseMove:p,onMouseUp:g,onTouchEnd:h,onTouchMove:v,onTouchStart:b,style:y,width:w,responsive:S,dispatchTouchEvents:E=!0}=e,_=$.useRef(null),P=Ut(),[R,I]=$.useState(null),[k,B]=$.useState(null),L=Ame(),V=ow(),D=V?.width>0?V.width:w,W=V?.height>0?V.height:i,J=$.useCallback(te=>{L(te),typeof t=="function"&&t(te),I(te),B(te),te!=null&&(_.current=te)},[L,t,I,B]),re=$.useCallback(te=>{P(wF(te)),P(Yr({handler:o,reactEvent:te}))},[P,o]),U=$.useCallback(te=>{P(dx(te)),P(Yr({handler:c,reactEvent:te}))},[P,c]),ee=$.useCallback(te=>{P(d$()),P(Yr({handler:f,reactEvent:te}))},[P,f]),Z=$.useCallback(te=>{P(dx(te)),P(Yr({handler:p,reactEvent:te}))},[P,p]),ue=$.useCallback(()=>{P(PF())},[P]),X=$.useCallback(()=>{P(AF())},[P]),Oe=$.useCallback(te=>{P(OF(te.key))},[P]),Ee=$.useCallback(te=>{P(Yr({handler:a,reactEvent:te}))},[P,a]),Me=$.useCallback(te=>{P(Yr({handler:s,reactEvent:te}))},[P,s]),ye=$.useCallback(te=>{P(Yr({handler:u,reactEvent:te}))},[P,u]),be=$.useCallback(te=>{P(Yr({handler:g,reactEvent:te}))},[P,g]),$e=$.useCallback(te=>{P(Yr({handler:b,reactEvent:te}))},[P,b]),me=$.useCallback(te=>{E&&P(TF(te)),P(Yr({handler:v,reactEvent:te}))},[P,E,v]),Se=$.useCallback(te=>{P(Yr({handler:h,reactEvent:te}))},[P,h]),q=$me(S);return x.createElement(N$.Provider,{value:R},x.createElement(ZQ.Provider,{value:k},x.createElement(q,{width:D??y?.width,height:W??y?.height,className:At("recharts-wrapper",r),style:Rme({position:"relative",cursor:"default",width:D,height:W},y),onClick:re,onContextMenu:Ee,onDoubleClick:Me,onFocus:ue,onBlur:X,onKeyDown:Oe,onMouseDown:ye,onMouseEnter:U,onMouseLeave:ee,onMouseMove:Z,onMouseUp:be,onTouchEnd:Se,onTouchMove:me,onTouchStart:$e,ref:J},x.createElement(Nme,null),n)))}),Vme=["width","height","responsive","children","className","style","compact","title","desc"];function Bme(e,t){if(e==null)return{};var n,r,i=zme(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function zme(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var Wme=$.forwardRef((e,t)=>{var{width:n,height:r,responsive:i,children:o,className:a,style:s,compact:u,title:c,desc:f}=e,p=Bme(e,Vme),g=vo(p);return u?x.createElement(x.Fragment,null,x.createElement(Oc,{width:n,height:r}),x.createElement(MR,{otherAttributes:g,title:c,desc:f},o)):x.createElement(Fme,{className:a,style:s,width:n,height:r,responsive:i??!1,onClick:e.onClick,onMouseLeave:e.onMouseLeave,onMouseEnter:e.onMouseEnter,onMouseMove:e.onMouseMove,onMouseDown:e.onMouseDown,onMouseUp:e.onMouseUp,onContextMenu:e.onContextMenu,onDoubleClick:e.onDoubleClick,onTouchStart:e.onTouchStart,onTouchMove:e.onTouchMove,onTouchEnd:e.onTouchEnd},x.createElement(MR,{otherAttributes:g,title:c,desc:f,ref:t},x.createElement(Dpe,null,o)))});function px(){return px=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},px.apply(null,arguments)}function jR(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Hme(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?jR(Object(n),!0).forEach(function(r){Ume(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):jR(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Ume(e,t,n){return(t=Gme(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Gme(e){var t=qme(e,"string");return typeof t=="symbol"?t:t+""}function qme(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Kme={top:5,right:5,bottom:5,left:5},Yme=Hme({accessibilityLayer:!0,barCategoryGap:"10%",barGap:4,layout:"horizontal",margin:Kme,responsive:!1,reverseStackOrder:!1,stackOffset:"none",syncMethod:"index"},NF),Xme=$.forwardRef(function(t,n){var r,i=Dr(t.categoricalChartProps,Yme),{chartName:o,defaultTooltipEventType:a,validateTooltipEventTypes:s,tooltipPayloadSearcher:u,categoricalChartProps:c}=t,f={chartName:o,defaultTooltipEventType:a,validateTooltipEventTypes:s,tooltipPayloadSearcher:u,eventEmitter:void 0};return x.createElement(mme,{preloadedState:{options:f},reduxStoreName:(r=c.id)!==null&&r!==void 0?r:o},x.createElement(Ape,{chartData:c.data}),x.createElement(yme,{layout:i.layout,margin:i.margin}),x.createElement(wme,{throttleDelay:i.throttleDelay,throttledEvents:i.throttledEvents}),x.createElement(bme,{baseValue:i.baseValue,accessibilityLayer:i.accessibilityLayer,barCategoryGap:i.barCategoryGap,maxBarSize:i.maxBarSize,stackOffset:i.stackOffset,barGap:i.barGap,barSize:i.barSize,syncId:i.syncId,syncMethod:i.syncMethod,className:i.className,reverseStackOrder:i.reverseStackOrder}),x.createElement(Wme,px({},i,{ref:n})))}),Zme=["axis","item"],Qme=$.forwardRef((e,t)=>x.createElement(Xme,{chartName:"BarChart",defaultTooltipEventType:"axis",validateTooltipEventTypes:Zme,tooltipPayloadSearcher:Bce,categoricalChartProps:e,ref:t}));const Jme={light:"",dark:".dark"},DF=x.createContext(null);function eve(){const e=x.useContext(DF);if(!e)throw new Error("useChart must be used within a <ChartContainer />");return e}function tve({id:e,className:t,children:n,config:r,...i}){const o=x.useId(),a=`chart-${e||o.replace(/:/g,"")}`;return O.jsx(DF.Provider,{value:{config:r},children:O.jsxs("div",{"data-slot":"chart","data-chart":a,className:ae(`[&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground
|
|
228
257
|
[&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50
|
|
229
258
|
[&_.recharts-curve.recharts-tooltip-cursor]:stroke-border
|
|
230
259
|
[&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border
|
|
@@ -234,14 +263,14 @@ Take a look at the reducer(s) handling this action type: ${h.type}.
|
|
|
234
263
|
justify-center text-xs [&_.recharts-dot[stroke='#fff']]:stroke-transparent
|
|
235
264
|
[&_.recharts-layer]:outline-hidden [&_.recharts-sector]:outline-hidden
|
|
236
265
|
[&_.recharts-sector[stroke='#fff']]:stroke-transparent
|
|
237
|
-
[&_.recharts-surface]:outline-hidden`,t),...i,children:[
|
|
266
|
+
[&_.recharts-surface]:outline-hidden`,t),...i,children:[O.jsx(nve,{id:a,config:r}),O.jsx(Fne,{children:n})]})})}const nve=({id:e,config:t})=>{const n=Object.entries(t).filter(([,r])=>r.theme||r.color);return n.length?O.jsx("style",{dangerouslySetInnerHTML:{__html:Object.entries(Jme).map(([r,i])=>`
|
|
238
267
|
${i} [data-chart=${e}] {
|
|
239
268
|
${n.map(([o,a])=>{const s=a.theme?.[r]||a.color;return s?` --color-${o}: ${s};`:null}).filter(Boolean).join(`
|
|
240
269
|
`)}
|
|
241
270
|
}
|
|
242
271
|
`).join(`
|
|
243
|
-
`)}}):null},
|
|
244
|
-
border px-2.5 py-1.5 text-xs shadow-xl`,n),children:[b?null:v,
|
|
245
|
-
[&>svg]:h-2.5 [&>svg]:w-2.5`,r==="dot"&&"items-center"),children:c&&y?.value!==void 0&&y.name?c(y.value,y.name,y,w,y.payload):
|
|
246
|
-
bg-(--color-bg)`,{"h-2.5 w-2.5":r==="dot","w-1":r==="line","w-0 border-[1.5px] border-dashed bg-transparent":r==="dashed","my-0.5":b&&r==="dashed"}),style:{"--color-bg":_,"--color-border":_}}),
|
|
272
|
+
`)}}):null},rve=ffe;function ive({active:e,payload:t,className:n,indicator:r="dot",hideLabel:i=!1,hideIndicator:o=!1,label:a,labelFormatter:s,labelClassName:u,formatter:c,color:f,nameKey:p,labelKey:g}){const{config:h}=eve(),v=x.useMemo(()=>{if(i||!t?.length)return null;const[y]=t,w=`${g||y?.dataKey||y?.name||"value"}`,S=LR(h,y,w),E=!g&&typeof a=="string"?h[a]?.label||a:S?.label;return s?O.jsx("div",{className:ae("font-medium",u),children:s(E,t)}):E?O.jsx("div",{className:ae("font-medium",u),children:E}):null},[a,s,t,i,u,h,g]);if(!e||!t?.length)return null;const b=t.length===1&&r!=="dot";return O.jsxs("div",{className:ae(`border-border/50 bg-background grid min-w-32 items-start gap-1.5 rounded-lg
|
|
273
|
+
border px-2.5 py-1.5 text-xs shadow-xl`,n),children:[b?null:v,O.jsx("div",{className:"grid gap-1.5",children:t.filter(y=>y.type!=="none").map((y,w)=>{const S=`${p||y.name||y.dataKey||"value"}`,E=LR(h,y,S),_=f||y.payload?.fill||y.color;return O.jsx("div",{className:ae(`[&>svg]:text-muted-foreground flex w-full flex-wrap items-stretch gap-2
|
|
274
|
+
[&>svg]:h-2.5 [&>svg]:w-2.5`,r==="dot"&&"items-center"),children:c&&y?.value!==void 0&&y.name?c(y.value,y.name,y,w,y.payload):O.jsxs(O.Fragment,{children:[E?.icon?O.jsx(E.icon,{}):!o&&O.jsx("div",{className:ae(`shrink-0 rounded-[2px] border-(--color-border)
|
|
275
|
+
bg-(--color-bg)`,{"h-2.5 w-2.5":r==="dot","w-1":r==="line","w-0 border-[1.5px] border-dashed bg-transparent":r==="dashed","my-0.5":b&&r==="dashed"}),style:{"--color-bg":_,"--color-border":_}}),O.jsxs("div",{className:ae("flex flex-1 justify-between leading-none",b?"items-end":"items-center"),children:[O.jsxs("div",{className:"grid gap-1.5",children:[b?v:null,O.jsx("span",{className:"text-muted-foreground",children:E?.label||y.name})]}),y.value&&O.jsx("span",{className:"text-foreground font-mono font-medium tabular-nums",children:y.value.toLocaleString()})]})]})},y.dataKey)})})]})}function LR(e,t,n){if(typeof t!="object"||t===null)return;const r="payload"in t&&typeof t.payload=="object"&&t.payload!==null?t.payload:void 0;let i=n;return n in t&&typeof t[n]=="string"?i=t[n]:r&&n in r&&typeof r[n]=="string"&&(i=r[n]),i in e?e[i]:e[n]}const ove=14.52,$R=10,ave=4,jF="#3B82F6",sve=400,lve=200,uve=150,cve={desktop:{label:"default",color:jF}},fve=({chartContainer:e,barChart:t,cartesianGrid:n,axis:r,hasTooltip:i=!0,tooltip:o,bar:a,chartTooltipContent:s,fillContainer:u=!1,minHeight:c=lve,smoothResize:f=!0,resizeDebounceMs:p=uve,mobileBreakpoint:g=sve})=>{const h=e?.config??cve,[v,b]=$.useState(null),[y,w]=$.useState({width:0,height:0}),[S,E]=$.useState(!1);$.useEffect(()=>{if(!f||!v)return;let P;const R=BQ.debounce(L=>{E(!0);for(const V of L){const{width:D,height:W}=V.contentRect;w({width:D,height:W})}clearTimeout(P),P=setTimeout(()=>{E(!1)},100)},p),I=new ResizeObserver(R);I.observe(v);const{width:k,height:B}=v.getBoundingClientRect();return w({width:k,height:B}),()=>{I.disconnect(),R.cancel(),clearTimeout(P)}},[v,f,p]);const _=y.width<g;return O.jsx("div",{ref:b,className:ae("w-full transition-opacity duration-200 will-change-transform",S?"opacity-60":"opacity-100",u?"h-full":"min-h-[200px]"),style:{minHeight:u?void 0:c,transform:"translateZ(0)",backfaceVisibility:"hidden"},children:O.jsx(tve,{...e,config:e?.config??h,className:ae(!u&&"aspect-video","transition-[width,height] duration-200 ease-in-out",e?.className),children:O.jsxs(Qme,{barSize:a?.barSize??t?.barSize??ove,...t,margin:t?.margin||{top:10,right:_?5:10,bottom:_?30:20,left:_?0:10},className:"transition-all duration-200",children:[O.jsx(cF,{vertical:n?.vertical??!1,horizontal:n?.horizontal??!0,strokeDasharray:n?.strokeDasharray??"3 3",...n}),O.jsx(xF,{tickLine:r?.y?.tickLine??!1,axisLine:r?.y?.axisLine??!1,tickMargin:r?.y?.tickMargin??$R,width:r?.y?.width??(_?30:35),...r?.y,hide:r?.y?.hide??_,tick:r?.y?.tick??{fontSize:_?10:12,...typeof r?.y?.tick=="object"?r?.y?.tick:{}}}),O.jsx(bF,{tickLine:r?.x?.tickLine??!1,axisLine:r?.x?.axisLine??!1,tickMargin:r?.x?.tickMargin??$R,interval:r?.x?.interval??(_?0:"preserveStart"),...r?.x,angle:r?.x?.angle??(_?-45:0),textAnchor:r?.x?.textAnchor??(_?"end":"middle"),height:r?.x?.height??(_?60:30),tick:r?.x?.tick??{fontSize:_?10:12,...typeof r?.x?.tick=="object"?r?.x?.tick:{}}}),i&&O.jsx(rve,{cursor:o?.cursor??!0,content:O.jsx(ive,{...s,className:ae("transition-all duration-200",_&&"origin-top-left scale-90 text-xs")}),...o}),O.jsx(vF,{fill:a?.fill??jF,radius:typeof a?.radius=="number"?Math.min(a.radius,_?3:a.radius):_?3:ave,...a})]})})})};exports.AppPagination=AX;exports.AppSidebar=MX;exports.Badge=Dy;exports.BasicChart=fve;exports.BasicCheckbox=DX;exports.BasicModal=jX;exports.BasicTable=MZ;exports.BasicTooltip=DZ;exports.Button=uo;exports.Card=iI;exports.CardContent=lI;exports.CardDescription=sI;exports.CardFooter=uI;exports.CardHeader=oI;exports.CardTitle=aI;exports.Checkbox=Sx;exports.Combobox=mk;exports.ComboboxChip=Sk;exports.ComboboxChips=eb;exports.ComboboxChipsInput=tb;exports.ComboboxCollection=C9;exports.ComboboxContent=yk;exports.ComboboxEmpty=wk;exports.ComboboxField=vk;exports.ComboboxGroup=w9;exports.ComboboxInput=x9;exports.ComboboxItem=xk;exports.ComboboxLabel=S9;exports.ComboboxList=bk;exports.ComboboxSeparator=E9;exports.ComboboxTrigger=ep;exports.ComboboxValue=Jy;exports.Dialog=rN;exports.DialogClose=K7;exports.DialogContent=g0;exports.DialogDescription=oN;exports.DialogFooter=v0;exports.DialogHeader=m0;exports.DialogOverlay=h0;exports.DialogPortal=iN;exports.DialogTitle=y0;exports.DialogTrigger=q7;exports.Field=gc;exports.FieldContent=X8;exports.FieldDescription=mc;exports.FieldError=pk;exports.FieldGroup=hc;exports.FieldLabel=Rl;exports.FieldLegend=Y8;exports.FieldSeparator=Q8;exports.FieldSet=vh;exports.FieldTitle=Z8;exports.Icon=ji;exports.Input=o0;exports.InputField=YM;exports.InputGroup=a0;exports.InputGroupAddon=s0;exports.InputGroupButton=hk;exports.InputGroupInput=l0;exports.InputGroupText=r9;exports.InputGroupTextarea=i9;exports.InputPassword=jZ;exports.Label=Ku;exports.NavigationItem=aN;exports.NavigationMenu=sN;exports.Pagination=b0;exports.PaginationContent=x0;exports.PaginationEllipsis=cN;exports.PaginationItem=sl;exports.PaginationLink=vc;exports.PaginationNext=uN;exports.PaginationPrevious=lN;exports.Progress=mN;exports.RadioButton=LZ;exports.RadioGroup=E0;exports.RadioGroupItem=rp;exports.SelectField=ZM;exports.SelectGroups=LQ;exports.Separator=i0;exports.Switch=UN;exports.Table=_0;exports.TableBody=P0;exports.TableCaption=qN;exports.TableCell=ip;exports.TableFooter=GN;exports.TableHead=A0;exports.TableHeader=O0;exports.TableRow=Bu;exports.Tabs=UY;exports.TabsContent=cM;exports.TabsList=lM;exports.TabsTrigger=uM;exports.Textarea=yh;exports.TextareaField=$Q;exports.Tooltip=LM;exports.TooltipArrow=FM;exports.TooltipContent=M0;exports.TooltipProvider=CX;exports.TooltipTrigger=$M;exports.Typography=My;exports.badgeVariants=vx;exports.buttonVariants=bx;exports.cn=ae;exports.getTypographyClassName=dn;exports.typographyClassNames=mx;exports.typographyVariantOptions=gU;exports.usePopupControls=D0;
|
|
247
276
|
//# sourceMappingURL=index.cjs.map
|