@dudousxd/nestjs-catalog-dashboard 0.34.2 → 0.35.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2829,11 +2829,11 @@ export default function transform({ record, context }) {
2829
2829
  { "tag": "AF00D00169", "risk": "12", "kind": "sedan" }
2830
2830
  ]`;function uvt({result:e,error:t}){return y.jsxs("div",{className:"max-h-64 overflow-auto p-3",children:[t?y.jsx("p",{className:"font-mono text-[11px] leading-relaxed text-red-600",children:t instanceof Error?t.message:"It failed."}):null,e&&y.jsxs(y.Fragment,{children:[e.logs.length>0&&y.jsx("pre",{className:X("mb-2 whitespace-pre-wrap font-mono text-[10px]",Bu),children:e.logs.join(`
2831
2831
  `)}),e.rows.length===0?y.jsx("p",{className:"text-[11px] text-amber-600",children:"It ran and returned no rows. A connector using this would commit an empty snapshot."}):y.jsx("pre",{className:"whitespace-pre-wrap font-mono text-[11px]",children:JSON.stringify(e.rows,null,2)}),y.jsxs("p",{className:X("mt-2 font-mono text-[10px]",Bu),children:[e.rows.length," rows · ",e.elapsedMs,"ms"]})]}),!e&&!t&&y.jsx("p",{className:X("py-4 text-center text-[11px]",Bu),children:"Run it to see what it produces."})]})}function cvt({language:e,code:t,mode:n}){if(e==="python")return null;const i=Ke.transformShape(t)==="module",o=n==="record"?"{ record, context }":"{ records, context }";return y.jsx(kt,{content:i?`A top-level \`export\`, so this is imported as a module and its default export (or an export named \`transform\`) is called with one object: ${o}. Fields can be added to that object later without changing this signature.`:"No top-level `export`, so this runs as the body of a function that already has `records` and `context` in scope. Supported and unchanged — `export default function transform({ records, context })` is the shape that can gain fields later.",children:y.jsx("span",{className:X("cursor-default rounded border px-1.5 py-0.5 font-mono text-[10px] uppercase tracking-[0.14em]",rm,Bu),children:i?"function":"bare body"})})}function dvt({transform:e,nameIsEmpty:t,refused:n,pending:r,error:i,onSave:o}){return y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx("button",{type:"button",onClick:o,disabled:r||t||n,className:X("rounded-md border px-3 py-1.5 text-xs disabled:opacity-40",rm,"hover:bg-zinc-50 dark:hover:bg-zinc-800"),children:r?"Saving…":e?"Save changes":"Save transform"}),e&&y.jsxs("span",{className:X("font-mono text-[10px]",Bu),children:["saving new code makes this v",e.version+1]}),i?y.jsx("span",{className:"text-[11px] text-red-600",children:i instanceof Error?i.message:"Could not save."}):null]})}function AOe({transform:e,languages:t,pythonPackages:n=[],onClose:r,onSaved:i}){const o=Sr(),[s,a]=A.useState((e==null?void 0:e.name)??""),[l,u]=A.useState((e==null?void 0:e.description)??""),[c,d]=A.useState((e==null?void 0:e.language)??t[0]??"javascript"),[h,m]=A.useState(e?Ke.transformMode(e):"batch"),[g,b]=A.useState((e==null?void 0:e.code)??x8((e==null?void 0:e.language)??"javascript","batch")),[v,w]=A.useState(lvt),[S,C]=A.useState(!1),E=Jn({mutationFn:()=>{let N;try{const I=JSON.parse(v);N=Array.isArray(I)?I:[I]}catch{throw new Error("The sample is not valid JSON.")}return o.tryTransform({language:c,code:g,records:N,mode:h})}}),T=Jn({mutationFn:()=>o.saveTransform({id:e==null?void 0:e.id,name:s.trim(),language:c,code:g,mode:h,description:l.trim()||void 0}),onSuccess:i}),O=Ke.recordModeRefusal({language:c,code:g,mode:h});function M(N){(N.metaKey||N.ctrlKey)&&N.key==="Enter"&&(N.preventDefault(),E.mutate())}return y.jsxs("div",{className:"mt-6 space-y-3",children:[y.jsxs("button",{type:"button",onClick:r,className:X("flex items-center gap-1.5 font-mono text-[11px] uppercase tracking-[0.14em]",Bu,"hover:text-zinc-950 dark:hover:text-zinc-50"),children:[y.jsx(wq,{size:12}),"Transforms"]}),y.jsxs("div",{className:"grid gap-3 sm:grid-cols-3",children:[y.jsx(Xt,{label:"Name",value:s,onChange:a,placeholder:"Fleet rows"}),y.jsx(Xt,{label:"Description",value:l,onChange:u,placeholder:"What it does (optional)"}),y.jsx(pr,{label:"Language",ariaLabel:"Language",value:c,onValueChange:N=>{Ke.isTransformLanguage(N)&&(d(N),Rle(g)&&b(x8(N,h)))},options:t.map(N=>({value:N,label:N}))})]}),y.jsxs("div",{className:"grid gap-3 sm:grid-cols-3",children:[y.jsx(pr,{label:"Called",ariaLabel:"Called",value:h,onValueChange:N=>{Ke.isTransformMode(N)&&(m(N),Rle(g)&&b(x8(c,N)))},options:[{value:"batch",label:"once with the whole batch"},{value:"record",label:"once per record (streams)"}]}),y.jsx("p",{className:X("sm:col-span-2 self-center text-xs leading-relaxed",Bu),children:h==="record"?"Each record is mapped on its own and the rows are written as they are produced, so nothing holds the whole read. Return one object, an array of them, or null to drop the record. Aggregating, deduplicating and sorting need the whole batch and cannot be written this way.":"The code is called once with every record, which is what aggregating, deduplicating, sorting and joining need. The whole read is held in memory while it runs."})]}),O?y.jsx("p",{className:"rounded-lg border border-amber-300 bg-amber-50 px-3 py-2 text-xs leading-relaxed text-amber-900 dark:border-amber-900/60 dark:bg-amber-950/40 dark:text-amber-200",children:O}):null,y.jsxs("div",{className:"grid gap-3 lg:grid-cols-2",children:[y.jsxs("div",{className:X("overflow-hidden rounded-lg border",rm,v8),children:[y.jsxs("div",{className:X("flex items-center justify-between border-b px-3 py-1.5",rm),children:[y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx("span",{className:X("font-mono text-[10px] uppercase tracking-[0.14em]",Bu),children:"Code"}),y.jsx(cvt,{language:c,code:g,mode:h})]}),y.jsx("span",{className:X("font-mono text-[10px]",Bu),children:c==="python"&&n.length>0?`imports: ${n.join(", ")}`:"⌘↵ to try"})]}),y.jsx(qU,{value:g,onChange:b,onKeyDown:M,language:avt[c],label:"Transform code",className:"h-72"})]}),y.jsxs("div",{className:"space-y-3",children:[y.jsxs("div",{className:X("overflow-hidden rounded-lg border",rm,v8),children:[y.jsx("div",{className:X("border-b px-3 py-1.5",rm),children:y.jsx("span",{className:X("font-mono text-[10px] uppercase tracking-[0.14em]",Bu),children:"Sample records"})}),y.jsx(qU,{value:v,onChange:w,language:"json",label:"Sample records",className:"h-32"})]}),y.jsxs("button",{type:"button",onClick:()=>E.mutate(),disabled:E.isPending,className:"flex items-center gap-1.5 rounded-md bg-zinc-950 px-3 py-1.5 text-xs text-zinc-50 disabled:opacity-40 dark:bg-zinc-100 dark:text-zinc-950",children:[y.jsx(fP,{size:12}),E.isPending?"Running…":"Try it"]}),y.jsxs("div",{className:X("overflow-hidden rounded-lg border",rm,v8),children:[y.jsx("div",{className:X("border-b px-3 py-1.5",rm),children:y.jsx("span",{className:X("font-mono text-[10px] uppercase tracking-[0.14em]",Bu),children:"Output"})}),y.jsx(uvt,{result:E.data,error:E.error})]})]})]}),y.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[y.jsx(dvt,{refused:O!==void 0,transform:e,nameIsEmpty:s.trim().length===0,pending:T.isPending,error:T.error,onSave:()=>T.mutate()}),e&&y.jsx(pbt,{className:"ml-auto",onClick:()=>C(!0)})]}),e&&y.jsx(xY,{open:S,onOpenChange:C,subject:{kind:"transform",id:e.id,name:e.name},current:{version:e.version,body:e.code}})]})}const OOe=A.createContext(void 0);function SY(){const e=A.useContext(OOe);if(e===void 0)throw new Error(Br(64));return e}const fvt="data-activation-direction",jj={tabActivationDirection:e=>({[fvt]:e})},hvt=A.forwardRef(function(t,n){const{className:r,defaultValue:i=0,onValueChange:o,orientation:s="horizontal",render:a,value:l,style:u,...c}=t,d=t.defaultValue!==void 0,h=A.useRef([]),[m,g]=A.useState(()=>new Map),[b,v]=$y({controlled:l,default:i,name:"Tabs",state:"value"}),w=l!==void 0,[S,C]=A.useState(()=>new Map),E=A.useRef(void 0),T=A.useCallback(ae=>KU(S,ae),[S]),[O,M]=A.useState(()=>({previousValue:b,tabActivationDirection:"none"})),{previousValue:N,tabActivationDirection:I}=O;let D=I,P=!1;N!==b&&(D=Mle(N,b,s,S),P=N!=null&&b!=null&&T(b)==null);const F=P?N:b,z=N!==F||I!==D;et(()=>{z&&M({previousValue:F,tabActivationDirection:D})},[F,z,D]);const $=at((ae,ie)=>{const he=Mle(b,ae,s,S);ie.activationDirection=he,o==null||o(ae,ie),!ie.isCanceled&&v(()=>ae)}),B=at((ae,ie)=>{o==null||o(ae,Et(ie,void 0,void 0,{activationDirection:"none"}))}),H=at((ae,ie)=>(g(he=>{const fe=new Map(he);return fe.set(ae,ie),fe}),()=>{g(he=>{if(he.get(ae)!==ie)return he;const fe=new Map(he);return fe.delete(ae),fe})})),U=A.useCallback(ae=>m.get(ae),[m]),W=A.useCallback(ae=>{for(const ie of S.values())if(ae===ie.value)return ie.id},[S]),q=A.useMemo(()=>({getTabElementBySelectedValue:T,getTabIdByPanelValue:W,getTabPanelIdByValue:U,onValueChange:$,orientation:s,registerMountedTabPanel:H,setTabMap:C,tabActivationDirection:D,value:b}),[T,W,U,$,s,H,C,D,b]),Y=A.useMemo(()=>{for(const ae of S.values())if(ae.value===b)return ae},[S,b]),Q=A.useMemo(()=>{for(const ae of S.values())if(!ae.disabled)return ae.value},[S]),G=A.useRef(!d),le=A.useRef(i),K=A.useRef(d),te=A.useRef(!1);et(()=>{var se;if(w)return;function ae(Se,pe){v(()=>Se),M({previousValue:Se,tabActivationDirection:"none"}),B(Se,pe),G.current=!1}if(S.size===0){te.current&&b!==null&&!((se=E.current)!=null&&se.isConnected)&&ae(null,Fne);return}te.current=!0,E.current=S.keys().next().value;const ie=Y==null?void 0:Y.disabled,he=Y==null&&b!==null;if(!ie&&b===le.current&&(K.current=!1),K.current&&ie&&b===le.current)return;const fe=G.current;if(ie||he){const Se=Q??null;if(b===Se){G.current=!1;return}let pe=Fne;fe?pe=Bne:ie&&(pe=zve),ae(Se,pe);return}fe&&Y!=null&&(B(b,Bne),G.current=!1)},[Q,w,B,Y,v,S,b]);const ue=$n("div",t,{state:{orientation:s,tabActivationDirection:D},ref:n,props:c,stateAttributesMapping:jj});return y.jsx(OOe.Provider,{value:q,children:y.jsx(_2,{elementsRef:h,children:ue})})});function KU(e,t){for(const[n,r]of e.entries())if(t===r.value)return n;return null}function Mle(e,t,n,r){if(e==null||t==null)return"none";const[i,o,s]=n==="horizontal"?["left","left","right"]:["top","up","down"],a=KU(r,e),l=KU(r,t);if(a==null||l==null)return a!==l&&(typeof e=="number"||typeof e=="string")&&typeof e==typeof t?t>e?s:o:"none";const u=a.getBoundingClientRect()[i],c=l.getBoundingClientRect()[i];return c<u?o:c>u?s:"none"}const kY="data-composite-item-active";function ROe(e={}){const{highlightItemOnHover:t,highlightedIndex:n,onHighlightedIndexChange:r}=DP(),{ref:i,index:o}=L2(e),s=n===o,a=A.useRef(null),l=uu(i,a);return{compositeProps:{tabIndex:s?0:-1,onFocus(){r(o)},onMouseMove(){const c=a.current;if(!t||!c)return;const d=c.hasAttribute("disabled")||c.ariaDisabled==="true";!s&&!d&&c.focus()}},compositeRef:l,index:o}}const MOe=A.createContext(void 0);function pvt(){const e=A.useContext(MOe);if(e===void 0)throw new Error(Br(65));return e}const mvt=A.forwardRef(function(t,n){const{className:r,disabled:i=!1,render:o,value:s,id:a,nativeButton:l=!0,style:u,...c}=t,{value:d,getTabPanelIdByValue:h,onValueChange:m,orientation:g,tabActivationDirection:b}=SY(),{activateOnFocus:v,registerTabResizeObserverElement:w,tabsListElement:S}=pvt(),{highlightedIndex:C,onHighlightedIndexChange:E}=DP(),T=Ca(a),O=A.useMemo(()=>({disabled:i,id:T,value:s}),[i,T,s]),{compositeProps:M,compositeRef:N,index:I}=ROe({metadata:O}),D=s===d,P=A.useRef(!1),F=A.useRef(null),z=at(te=>{var de;(de=F.current)==null||de.call(F),F.current=te?w(te):null});et(()=>{if(P.current){P.current=!1;return}if(!(D&&I>-1&&C!==I))return;const te=S;if(te!=null){const de=Ss(Dn(te));if(de&&Rt(te,de))return}i||E(I)},[D,I,C,E,i,S]);const{getButtonProps:$,buttonRef:B}=Kh({disabled:i,native:l,focusableWhenDisabled:!0}),H=h(s),U=A.useRef(!1),W=A.useRef(!1);function q(te){m(s,Et(ki,te.nativeEvent,void 0,{activationDirection:"none"}))}function Y(te){D||i||q(te)}function Q(te){D||i||v&&(!U.current||W.current)&&q(te)}function G(te){if(D||i)return;U.current=!0,W.current=te.button===0;const de=Dn(te.currentTarget);function ue(){U.current=!1,W.current=!1,de.removeEventListener("pointerup",ue),de.removeEventListener("pointercancel",ue)}de.addEventListener("pointerup",ue),de.addEventListener("pointercancel",ue)}return $n("button",t,{state:{disabled:i,active:D,orientation:g,tabActivationDirection:b},ref:[n,B,N,z],props:[M,{role:"tab","aria-controls":H,"aria-selected":D,id:T,onClick:Y,onFocus:Q,onPointerDown:G,[kY]:D?"":void 0,onKeyDownCapture(){P.current=!0}},c,$],stateAttributesMapping:jj})}),gvt="data-index",yvt={...jj,...Bw},bvt=A.forwardRef(function(t,n){const{className:r,value:i,render:o,keepMounted:s=!1,style:a,...l}=t,{value:u,getTabIdByPanelValue:c,orientation:d,tabActivationDirection:h,registerMountedTabPanel:m}=SY(),g=Ca(),{ref:b,index:v}=L2(),w=i===u,{mounted:S,transitionStatus:C,setMounted:E}=lG(w),T=!S,O=c(i),M={hidden:T,orientation:d,tabActivationDirection:h,transitionStatus:C},N=A.useRef(null),I=$n("div",t,{state:M,ref:[n,b,N],props:[{"aria-labelledby":O,hidden:T,id:g,role:"tabpanel",tabIndex:w?0:-1,inert:M2(!w),[gvt]:v},l],stateAttributesMapping:yvt});return Ig({open:w,ref:N,onComplete(){w||E(!1)}}),et(()=>{if(!(g==null||T&&!s))return m(i,g)},[T,s,i,g,m]),s||S?I:null});function vvt(e){const{loopFocus:t=!0,orientation:n="both",grid:r,onLoop:i,direction:o,highlightedIndex:s,onHighlightedIndexChange:a,rootRef:l,enableHomeAndEndKeys:u=!1,stopEventPropagation:c,disabledIndices:d,modifierKeys:h=Ws}=e,[m,g]=A.useState(0),b=r!=null,v=A.useRef(null),w=uu(v,l),S=A.useRef([]),C=A.useRef(!1),E=A.useRef(null),T=s??m,O=at((P,F=!1)=>{if(E.current=S.current[P]??null,(a??g)(P),F){const z=S.current[P];Cre(v.current,z,o,n)}}),M=at(P=>{var B;if(P.size===0)return;if(C.current){const H=S.current,U=H.indexOf(E.current);if(U===-1){const W=H[T];!W||tg(H,T,d)?O(xvt(H,d)):E.current=W}else U!==T&&O(U);return}C.current=!0;const F=Array.from(P.keys()),z=F.find(H=>H==null?void 0:H.hasAttribute(kY))??null,$=z?((B=P.get(z))==null?void 0:B.index)??-1:-1;if($!==-1)O($);else if(tg(F,T,d)){const H=Hs(F,{disabledIndices:d});wh(F,H)||O(H)}Cre(v.current,z,o,n)});et(()=>{if(d==null||s!=null||!C.current)return;const P=S.current;if(tg(P,T,d)){const F=Hs(P,{disabledIndices:d});wh(P,F)||O(F)}},[d,s,T,S,O]);const N=at((P,F,z)=>i?i(P,F,z,S):z),I=at(P=>{const F=P.key===J7||P.key===e9;if(!HP.has(P.key)||!u&&F||wvt(P,h)||!v.current)return;const $=o==="rtl",B=$?Q7:Z7,H=$?Z7:Q7,U=n==="vertical"?X7:B,W=n==="vertical"?Y7:H,q=ji(P.nativeEvent);if(q!=null&&kre(q)&&!Sve(q)){const te=q.selectionStart,de=q.selectionEnd,ue=q.value;if(te==null||P.shiftKey||te!==de||P.key!==W&&te<ue.length||P.key!==U&&te>0)return}let Y=T;const Q=RM(S,d),G=V7(S,d);r!=null&&(Y=r({disabledIndices:d,elementsRef:S,event:P,highlightedIndex:T,loopFocus:t,maxIndex:G,minIndex:Q,onLoop:N,orientation:n,rtl:$}));const le=n!=="vertical"&&P.key===B||n!=="horizontal"&&P.key===X7,K=n!=="vertical"&&P.key===H||n!=="horizontal"&&P.key===Y7;u&&(P.key===J7?Y=Q:P.key===e9&&(Y=G)),Y===T&&(le||K)&&(t&&Y===G&&le?(Y=Q,i&&(Y=i(P,T,Y,S))):t&&Y===Q&&K?(Y=G,i&&(Y=i(P,T,Y,S))):Y=Hs(S.current,{startingIndex:Y,decrement:K,disabledIndices:d})),Y!==T&&!wh(S.current,Y)&&(c&&P.stopPropagation(),(b||F||le||K)&&P.preventDefault(),O(Y,!0),queueMicrotask(()=>{var te;(te=S.current[Y])==null||te.focus()}))});return{props:{ref:w,onFocus(P){const F=v.current,z=ji(P.nativeEvent);!F||z==null||!kre(z)||z.setSelectionRange(0,z.value.length)},onKeyDown:I},highlightedIndex:T,onHighlightedIndexChange:O,elementsRef:S,onMapChange:M,relayKeyboardEvent:I}}function xvt(e,t){let n=-1;for(let r=0;r<e.length;r+=1){const i=e[r];if(!(!i||tg(e,r,t))){if(i.hasAttribute(kY))return r;n===-1&&(n=r)}}return Math.max(n,0)}function wvt(e,t){for(const n of xUe)if(!t.includes(n)&&e.getModifierState(n))return!0;return!1}function Svt(e){const{render:t,className:n,style:r,refs:i=Ws,props:o=Ws,state:s=Un,stateAttributesMapping:a,highlightedIndex:l,onHighlightedIndexChange:u,orientation:c,grid:d,loopFocus:h,onLoop:m,enableHomeAndEndKeys:g,onMapChange:b,stopEventPropagation:v=!0,rootRef:w,disabledIndices:S,modifierKeys:C,highlightItemOnHover:E=!1,tag:T="div",...O}=e,M=Ww(),{props:N,highlightedIndex:I,onHighlightedIndexChange:D,elementsRef:P,onMapChange:F,relayKeyboardEvent:z}=vvt({grid:d,loopFocus:h,onLoop:m,orientation:c,highlightedIndex:l,onHighlightedIndexChange:u,rootRef:w,stopEventPropagation:v,enableHomeAndEndKeys:g,direction:M,disabledIndices:S,modifierKeys:C}),$=$n(T,e,{state:s,ref:i,props:[N,...o,O],stateAttributesMapping:a}),B=A.useMemo(()=>({highlightedIndex:I,onHighlightedIndexChange:D,highlightItemOnHover:E,relayKeyboardEvent:z}),[I,D,E,z]);return y.jsx(G1e.Provider,{value:B,children:y.jsx(_2,{elementsRef:P,onMapChange:H=>{b==null||b(H),F(H)},children:$})})}const kvt=A.forwardRef(function(t,n){const{activateOnFocus:r=!1,className:i,loopFocus:o=!0,render:s,style:a,...l}=t,{orientation:u,setTabMap:c,tabActivationDirection:d}=SY(),[h,m]=A.useState(0),[g,b]=A.useState(null),v=A.useRef(new Set),w=A.useRef(new Set),S=A.useRef(null);et(()=>{if(typeof ResizeObserver>"u")return;const N=new ResizeObserver(()=>{v.current.forEach(I=>{I()})});return S.current=N,g&&N.observe(g),w.current.forEach(I=>{N.observe(I)}),()=>{N.disconnect(),S.current=null}},[g]);const C=at(N=>(v.current.add(N),()=>{v.current.delete(N)})),E=at(N=>{var I;return w.current.add(N),(I=S.current)==null||I.observe(N),()=>{var D;w.current.delete(N),(D=S.current)==null||D.unobserve(N)}}),T={orientation:u,tabActivationDirection:d},O={"aria-orientation":u==="vertical"?"vertical":void 0,role:"tablist"},M=A.useMemo(()=>({activateOnFocus:r,registerIndicatorUpdateListener:C,registerTabResizeObserverElement:E,tabsListElement:g}),[r,C,E,g]);return y.jsx(MOe.Provider,{value:M,children:y.jsx(Svt,{render:s,className:i,style:a,state:T,refs:[n,b],props:[O,l],stateAttributesMapping:jj,highlightedIndex:h,enableHomeAndEndKeys:!0,loopFocus:o,orientation:u,onHighlightedIndexChange:m,onMapChange:c,disabledIndices:Ws})})});function _Oe({value:e,onValueChange:t,children:n,className:r}){return y.jsx(hvt,{value:e,onValueChange:i=>{typeof i=="string"&&t(i)},className:r,children:n})}function NOe({children:e,className:t,ref:n}){return y.jsx(kvt,{ref:n,className:X("flex gap-1 border-b border-zinc-200 dark:border-zinc-800",t),children:e})}function YU({value:e,children:t,className:n,ref:r}){return y.jsx(mvt,{ref:r,value:e,className:X("flex items-center gap-1.5 border-b-2 px-3 py-2 text-sm transition-colors outline-none","border-transparent text-zinc-500","hover:text-zinc-950 dark:hover:text-zinc-50","focus-visible:ring-2 focus-visible:ring-sky-500/30","data-[selected]:border-sky-600 data-[selected]:text-zinc-950","dark:data-[selected]:text-zinc-50",n),children:t})}function Il({value:e,children:t,className:n}){return y.jsx(bvt,{value:e,className:X("outline-none",n),children:t})}const q0="text-zinc-400 dark:text-zinc-500",w8="border-zinc-200 dark:border-zinc-800",Cvt="bg-white dark:bg-zinc-900";function Evt({title:e="Connections & transforms",eyebrow:t="Ingestion",intro:n=`The two things a ${bn.singular} borrows: the addresses it reads through and the code it runs. Both are shared, so both outlive any one of them — which is why they are managed here rather than on the canvas where they are used.`,canEdit:r=!0}){var l;const i=Sr(),[o,s]=A.useState("connections"),{data:a}=Cn({queryKey:rn.capabilities,queryFn:()=>i.pipelineCapabilities(),staleTime:Number.POSITIVE_INFINITY});return y.jsx(Qh,{children:y.jsx("div",{className:"h-full overflow-y-auto",children:y.jsxs("div",{className:"mx-auto max-w-5xl px-8 py-8",children:[y.jsx("p",{className:X("font-mono text-[11px] uppercase tracking-[0.18em]",q0),children:t}),y.jsx("h1",{className:"mt-1 text-2xl font-semibold tracking-tight",children:e}),y.jsx("p",{className:"mt-1 max-w-2xl text-sm text-zinc-500 dark:text-zinc-400",children:n}),y.jsxs(_Oe,{value:o,onValueChange:s,className:"mt-6",children:[y.jsxs(NOe,{children:[y.jsxs(YU,{value:"connections",children:[y.jsx($w,{size:13}),"Connections"]}),y.jsxs(YU,{value:"transforms",children:[y.jsx(b2,{size:13}),"Transforms"]}),y.jsx(kt,{content:(l=a==null?void 0:a.pythonPackages)!=null&&l.length?`Python transforms may import ${a.pythonPackages.join(", ")} — provisioned by the image, not by this service.`:"Which languages this deployment can actually execute.",children:y.jsx("span",{className:X("ml-auto cursor-help self-center font-mono text-[10px]",q0),children:a?`runs ${a.languages.join(" · ")}`:"checking…"})})]}),y.jsx(Il,{value:"connections",children:y.jsx(Ybt,{canEdit:r})}),y.jsx(Il,{value:"transforms",children:y.jsx(Tvt,{canEdit:r,languages:(a==null?void 0:a.languages)??["javascript"],pythonPackages:(a==null?void 0:a.pythonPackages)??[]})})]})]})})})}function Tvt({canEdit:e,languages:t,pythonPackages:n}){var d,h;const r=Sr(),i=ra(),[o,s]=A.useState(null),[a,l]=A.useState(null),u=Cn({queryKey:rn.transforms,queryFn:()=>r.listTransforms()}),c=Jn({mutationFn:m=>r.deleteTransform(m),onSuccess:()=>{l(null),i.invalidateQueries({queryKey:rn.transforms})}});return o?y.jsx(AOe,{transform:o==="new"?void 0:o,languages:t,pythonPackages:n,onClose:()=>s(null),onSaved:()=>{s(null),i.invalidateQueries({queryKey:rn.transforms})}}):y.jsxs("div",{className:"mt-6 space-y-3",children:[e&&y.jsxs(Kt,{variant:"outline",size:"sm",onClick:()=>s("new"),children:[y.jsx(Rg,{size:12}),"New transform"]}),u.isPending&&y.jsx("p",{className:X("rounded-lg border border-dashed px-4 py-12 text-center text-sm",w8,q0),children:"Reading transforms…"}),u.isError&&y.jsxs("div",{className:"rounded-lg border border-red-200 bg-red-50 px-4 py-6 text-center dark:border-red-900 dark:bg-red-950/40",children:[y.jsx("p",{className:"text-sm text-red-700 dark:text-red-300",children:u.error instanceof Error?u.error.message:"Could not read the transforms."}),y.jsx(Kt,{variant:"outline",size:"sm",className:"mt-2 border-red-300 text-red-700 dark:border-red-800 dark:text-red-300",onClick:()=>u.refetch(),children:"Try again"})]}),((d=u.data)==null?void 0:d.length)===0&&y.jsxs("p",{className:X("rounded-lg border border-dashed px-4 py-12 text-center text-sm",w8,q0),children:["No transforms yet. Without one, a ",bn.singular," stores records exactly as they arrive — and a transform node on the canvas can write its first one for you."]}),(h=u.data)==null?void 0:h.map(m=>y.jsxs("div",{className:X("flex items-start gap-3 rounded-lg border p-4",w8,Cvt),children:[y.jsx(b2,{size:14,className:X("mt-0.5 shrink-0",q0)}),y.jsxs("button",{type:"button",onClick:()=>s(m),className:"min-w-0 flex-1 text-left",children:[y.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[y.jsx("span",{className:"text-sm font-medium",children:m.name}),y.jsx("span",{className:"rounded-sm bg-zinc-100 px-1.5 py-0.5 font-mono text-[10px] dark:bg-zinc-800",children:m.language}),y.jsx(kt,{content:"Bumped only when the code changed, so it stays useful for tracing a surprising load back to what ran.",children:y.jsxs("span",{className:X("cursor-help font-mono text-[10px]",q0),children:["v",m.version]})})]}),m.description&&y.jsx("p",{className:X("mt-0.5 text-[11px]",q0),children:m.description})]}),e&&y.jsx(kt,{content:`Delete ${m.name}`,children:y.jsx(Kt,{variant:"ghost",size:"icon",onClick:()=>l(m),"aria-label":`Delete ${m.name}`,className:"hover:text-red-600",children:y.jsx(jd,{size:12})})})]},m.id)),y.jsx(nS,{open:a!==null,onOpenChange:m=>{m||l(null)},title:a?`Delete ${a.name}?`:"",description:`Any ${bn.singular} with a transform node pointing at it stops validating — the node names code that no longer exists, and the graph cannot be published until somebody chooses another. Every past version goes with it, so a surprising load can no longer be traced to the code that ran.`,confirmLabel:c.isPending?"Deleting…":"Delete",pending:c.isPending,onConfirm:()=>{a&&c.mutate(a.id)},error:c.error?c.error instanceof Error?c.error.message:"Could not delete it.":void 0})]})}const Zl="text-zinc-400 dark:text-zinc-500",FL="border-zinc-200 dark:border-zinc-800";function Avt(e){if(!e||typeof e!="object"||!Array.isArray(Reflect.get(e,"columns")))throw new Error("The server answered the discovery request with something this console does not recognise. It is most likely running a version of @dudousxd/nestjs-catalog-pipeline older than this console expects.");return Object.assign(Object.create(null),e)}const _le=["string","number","boolean","date","uuid","json","unknown"];function Ovt(e){return e.map(t=>({include:t.type!==null,type:t.type??""}))}function Rvt(e,t){const n=e.columns.map((l,u)=>({column:l,choice:t[u]??{include:!1,type:""}})).filter(l=>l.choice.include),r=[],i=n.filter(l=>l.choice.type==="");i.length>0&&r.push(`Choose a type for ${i.map(l=>`"${l.column.name}"`).join(", ")}, or leave ${i.length===1?"it":"them"} out.`);const o=new Map;for(const l of n)o.set(l.column.name,(o.get(l.column.name)??0)+1);const s=[...o].filter(([,l])=>l>1).map(([l])=>`"${l}"`);s.length>0&&r.push(`${s.join(", ")} appears more than once. A record is an object, so only one of them can survive — leave the others out.`);const a=[];for(const l of n)l.choice.type!==""&&a.push({name:l.column.name,columnName:l.column.name,type:l.choice.type,nullable:l.column.nullable??!0});return a.length===0&&r.push("Nothing is selected, and a type with no properties is refused."),{draft:{name:e.targetType,properties:a},problems:r}}function Mvt({workflowId:e,nodeId:t,bridge:n,disabledReason:r,onSave:i,saving:o=!1,onDiscovered:s}){const[a,l]=A.useState(),u=Jn({mutationFn:()=>n.discover(e,t),onSuccess:c=>{l(d=>({run:((d==null?void 0:d.run)??0)+1,value:c})),s==null||s(t,c)}});return y.jsxs("div",{className:X("rounded-md border border-dashed p-3",FL),children:[y.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[y.jsxs(Kt,{variant:"outline",size:"sm",onClick:()=>u.mutate(),disabled:u.isPending||r!==void 0,children:[u.isPending?y.jsx(Js,{size:12,className:"animate-spin"}):y.jsx(q8e,{size:12}),u.isPending?"Reading the source…":"Discover schema"]}),y.jsx("span",{className:X("text-[11px]",Zl),children:r??"Reads the source and reports its columns. Creates nothing on its own, and works on a draft — the type has to exist before a sink can commit into it."}),r!==void 0&&i&&y.jsxs(Kt,{variant:"secondary",size:"sm",onClick:i,disabled:o,children:[o?y.jsx(Js,{size:12,className:"animate-spin"}):y.jsx(vbe,{size:12}),o?"Saving…":"Save now"]})]}),r!==void 0&&i&&y.jsx("p",{className:X("mt-1.5 text-[11px]",Zl),children:"Saving stores the graph as a draft. It does not publish it, and nothing runs because of it."}),u.error?y.jsx("p",{className:"mt-2 text-[11px] text-red-600",children:u.error instanceof Error?u.error.message:"Could not read the source."}):null,a&&y.jsx(_vt,{discovery:a.value,createType:n.createType},a.run)]})}function _vt({discovery:e,createType:t}){const[n,r]=A.useState(()=>Ovt(e.columns)),{draft:i,problems:o}=Rvt(e,n),s=(a,l)=>r(u=>u.map((c,d)=>d===a?{...c,...l}:c));return y.jsxs("div",{className:"mt-3 space-y-3",children:[y.jsx("p",{className:X("text-[11px]",Zl),children:e.caveat}),e.targetType?y.jsx(Ivt,{drift:e.drift,targetType:e.targetType}):y.jsx("p",{className:X("text-[11px]",Zl),children:"This graph has no sink naming an object type yet, so there is nothing to compare these columns against. Draw one and choose a type, and this becomes the way to create it."}),e.columns.length===0?y.jsx("p",{className:X("text-[11px]",Zl),children:"No columns came back."}):y.jsxs("table",{className:"w-full text-left text-[11px]",children:[y.jsx("thead",{className:X("font-mono uppercase tracking-[0.14em]",Zl),children:y.jsxs("tr",{children:[y.jsx("th",{className:"w-6 pb-1 font-normal",children:y.jsx("span",{className:"sr-only",children:"Include"})}),y.jsx("th",{className:"pb-1 font-normal",children:"Column"}),y.jsx("th",{className:"pb-1 font-normal",children:"Type"}),y.jsx("th",{className:"pb-1 font-normal",children:"Null"}),y.jsx("th",{className:"pb-1 font-normal",children:"Source"})]})}),y.jsx("tbody",{children:e.columns.map((a,l)=>y.jsx(Lvt,{column:a,choice:n[l]??{include:!1,type:""},onChange:u=>s(l,u)},`${a.name}-${l}`))})]}),o.map(a=>y.jsxs("p",{className:"flex items-start gap-1.5 text-[11px] text-amber-600",children:[y.jsx(Mg,{size:11,className:"mt-0.5 shrink-0","aria-hidden":!0}),a]},a)),e.targetType?y.jsx(Nvt,{discovery:e,draft:i,problems:o,createType:t}):null]})}function Nvt({discovery:e,draft:t,problems:n,createType:r}){const[i,o]=A.useState(!1),s=Jn({mutationFn:()=>r?r(t):Promise.reject(new Error("This console cannot create types.")),onSuccess:()=>o(!0)});return r?i?y.jsxs("p",{className:"flex items-center gap-1.5 text-[11px] text-emerald-600",children:[y.jsx(Wh,{size:11,"aria-hidden":!0}),e.targetType," now exists with ",t.properties.length," properties. Running this workflow will load into it."]}):y.jsxs("div",{className:"space-y-1",children:[y.jsx(Kt,{onClick:()=>s.mutate(),disabled:n.length>0||s.isPending,size:"sm",children:s.isPending?"Creating…":e.typeExists?`Update ${e.targetType}`:`Create ${e.targetType}`}),y.jsx("p",{className:X("text-[11px]",Zl),children:e.typeExists?"Adds and retypes properties. Display names, descriptions and classifications somebody wrote are kept.":"This is the act that creates the type. Nothing has been created up to here."}),s.error?y.jsx("p",{className:"text-[11px] text-red-600",children:s.error instanceof Error?s.error.message:"Could not create it."}):null]}):y.jsx(Pvt,{draft:t})}function Lvt({column:e,choice:t,onChange:n}){return y.jsxs(y.Fragment,{children:[y.jsxs("tr",{className:X("border-t",FL),children:[y.jsx("td",{className:"py-1 align-top",children:y.jsx("input",{type:"checkbox",checked:t.include,"aria-label":`Include ${e.name}`,onChange:r=>n({include:r.target.checked})})}),y.jsx("td",{className:"py-1 align-top font-mono",children:e.name}),y.jsxs("td",{className:"py-1 align-top",children:[y.jsxs("select",{value:t.type,"aria-label":`Type for ${e.name}`,onChange:r=>{const i=_le.find(o=>o===r.target.value);n({type:i??""})},className:X("rounded-sm border bg-transparent px-1 py-0.5 font-mono text-[11px]",FL,"text-zinc-900 dark:bg-zinc-900 dark:text-zinc-100",t.type===""&&"text-amber-600 dark:text-amber-500"),children:[y.jsx("option",{value:"",children:"not typed"}),_le.map(r=>y.jsx("option",{value:r,children:r},r))]}),e.confidence==="inferred"&&y.jsx("span",{className:X("ml-1.5 font-mono text-[10px]",Zl),children:"inferred"})]}),y.jsx("td",{className:X("py-1 align-top font-mono",Zl),children:e.nullable===null?"not stated":e.nullable?"nullable":"not null"}),y.jsx("td",{className:X("py-1 align-top font-mono",Zl),children:e.sourceType})]}),e.note&&y.jsxs("tr",{children:[y.jsx("td",{}),y.jsx("td",{colSpan:4,className:"pb-1.5 text-[11px] text-amber-600",children:e.note})]})]})}function Ivt({drift:e,targetType:t}){return e?e.added.length===0&&e.removed.length===0&&e.retyped.length===0?y.jsxs("p",{className:"flex items-center gap-1.5 text-[11px] text-emerald-600",children:[y.jsx(Wh,{size:11,"aria-hidden":!0}),"The source still matches ",t,"."]}):y.jsxs("div",{className:"space-y-1 rounded-md border border-amber-300 bg-amber-50 p-2 dark:border-amber-900 dark:bg-amber-950/30",children:[y.jsxs("p",{className:"font-mono text-[10px] uppercase tracking-[0.14em] text-amber-700 dark:text-amber-400",children:["Drift since ",t," was written down"]}),e.added.length>0&&y.jsxs("p",{className:"text-[11px] text-amber-700 dark:text-amber-300",children:["New in the source, and dropped by every load until the type has them:"," ",y.jsx("span",{className:"font-mono",children:e.added.join(", ")})]}),e.removed.length>0&&y.jsxs("p",{className:"text-[11px] text-amber-700 dark:text-amber-300",children:["On the type, absent from the source, so they load as null:"," ",y.jsx("span",{className:"font-mono",children:e.removed.join(", ")})]}),e.retyped.map(r=>y.jsxs("p",{className:"text-[11px] text-amber-700 dark:text-amber-300",children:[y.jsx("span",{className:"font-mono",children:r.property})," is ",r.now," in the source and"," ",r.was," here — every load coerces it, and a value that will not convert becomes null."]},r.property))]}):y.jsxs("p",{className:X("text-[11px]",Zl),children:[t," does not exist yet, so there is nothing to compare against."]})}function Pvt({draft:e}){return y.jsxs("div",{className:"space-y-1",children:[y.jsx("p",{className:X("text-[11px]",Zl),children:"This console cannot create types — nothing is wired to the publish route. What was confirmed above is this request:"}),y.jsx("pre",{className:X("overflow-x-auto rounded-md border p-2 font-mono text-[10px]",FL,"bg-zinc-50 dark:bg-zinc-950"),children:`PUT /publish/${e.name}/schema
2832
- ${JSON.stringify(e,null,2)}`})]})}const As="text-zinc-400 dark:text-zinc-500",Cg="border-zinc-200 dark:border-zinc-800",sA="bg-white dark:bg-zinc-900";function jvt({value:e,onChange:t}){return y.jsxs("label",{className:"mt-3 block",children:[y.jsx("span",{className:"sr-only",children:"Search people"}),y.jsx("input",{type:"search",value:e,onChange:n=>t(n.target.value),placeholder:"Search by name or email",className:X("w-full rounded-md border px-3 py-1.5 text-sm",Cg,sA,"placeholder:text-zinc-400 dark:placeholder:text-zinc-600")})]})}function Dvt({page:e,onOffset:t,busy:n}){const r=e.people.length,i=e.total===0?0:e.offset+1,o=e.offset+r,s=o<e.total;return y.jsxs("div",{className:X("mt-3 flex items-center justify-between text-xs",As),children:[y.jsx("span",{children:e.total===0?"No people":`Showing ${i}–${o} of ${e.total.toLocaleString()}`}),(e.offset>0||s)&&y.jsxs("span",{className:"flex gap-2",children:[y.jsx("button",{type:"button",disabled:e.offset===0||n,onClick:()=>t(Math.max(0,e.offset-e.limit)),className:"disabled:opacity-40",children:"Previous"}),y.jsx("button",{type:"button",disabled:!s||n,onClick:()=>t(e.offset+e.limit),className:"disabled:opacity-40",children:"Next"})]})]})}function $vt({identity:e,onSignOut:t,signOutPending:n,canAddPeople:r,title:i="Access",eyebrow:o="Governance",intro:s="Two kinds of caller reach this catalog. Applications hold keys and act on their own behalf. People sign in and act through an application, and can never do more than both of them may."}){var b,v,w,S;const a=Sr(),l=Cn({queryKey:rn.principals,queryFn:()=>a.listPrincipals(),staleTime:3e4}),[u,c]=A.useState(""),[d,h]=A.useState(0),m=Cn({queryKey:[...rn.people,{search:u,offset:d}],queryFn:()=>a.listPeople({...u?{search:u}:{},offset:d}),staleTime:3e4,placeholderData:C=>C}),g=r??(e==null?void 0:e.scopes.includes("catalog:admin"))??!1;return y.jsx(Qh,{children:y.jsxs("div",{className:"mx-auto max-w-5xl px-8 py-8",children:[y.jsx("p",{className:X("font-mono text-[11px] uppercase tracking-[0.18em]",As),children:o}),y.jsx("h1",{className:"mt-1 text-2xl font-semibold tracking-tight",children:i}),y.jsx("p",{className:"mt-1 max-w-2xl text-sm text-zinc-500 dark:text-zinc-400",children:s}),e&&y.jsx(zvt,{identity:e,onSignOut:t,signOutPending:n}),y.jsxs(Nle,{title:"People",note:"Sign in to the console. Capped by the application they sign in through.",children:[y.jsx(jvt,{value:u,onChange:C=>{c(C),h(0)}}),g&&y.jsx(Uvt,{}),m.isPending&&y.jsx(xk,{children:"Reading people…"}),m.isError&&y.jsx(Lle,{message:m.error instanceof Error?m.error.message:"Could not read the people list.",onRetry:()=>m.refetch()}),(b=m.data)==null?void 0:b.people.map(C=>y.jsx(Fvt,{person:C},C.email)),((v=m.data)==null?void 0:v.people.length)===0&&(u?y.jsxs(xk,{children:["Nobody matches “",u,"”."]}):y.jsx(xk,{children:"Nobody can sign in yet. Seed the first administrator from the environment before anybody can reach this console as a person."})),m.data&&y.jsx(Dvt,{page:m.data,onOffset:h,busy:m.isFetching})]}),y.jsxs(Nle,{title:"Applications",note:"Provisioned by an operator — a console that could hand grants out is one that stops leaving a trail.",children:[l.isPending&&y.jsx(xk,{children:"Reading applications…"}),l.isError&&y.jsx(Lle,{message:l.error instanceof Error?l.error.message:"Could not read the application list.",onRetry:()=>l.refetch()}),(w=l.data)==null?void 0:w.map(C=>y.jsx(Wvt,{principal:C},C.id)),((S=l.data)==null?void 0:S.length)===0&&y.jsx(xk,{children:"No applications are provisioned."})]})]})})}function zvt({identity:e,onSignOut:t,signOutPending:n}){const r=e.actor===null;return y.jsxs("div",{className:X("mt-6 rounded-lg border p-4",sA,r?"border-amber-500/40":Cg),children:[y.jsxs("div",{className:"flex flex-wrap items-start justify-between gap-3",children:[y.jsxs("div",{className:"min-w-0",children:[y.jsx("div",{className:X("font-mono text-[10px] uppercase tracking-[0.14em]",As),children:r?"Acting as an application":"Signed in"}),y.jsxs("div",{className:"mt-1 flex items-center gap-2 text-sm font-medium",children:[r?y.jsx(cP,{size:14}):y.jsx(v$e,{size:14}),e.displayName]}),y.jsxs("div",{className:X("mt-1 font-mono text-[11px]",As),children:["recorded as ",e.principalId]}),r&&y.jsx("p",{className:"mt-2 max-w-md text-xs text-amber-600",children:"Nothing you do here will name you. This is the application-key path, kept for local development — sign in to be attributable."})]}),y.jsxs("div",{className:"flex items-center gap-4",children:[e.session&&y.jsxs("span",{className:X("font-mono text-[11px]",As),children:["expires ",new Date(e.session.expiresAt).toLocaleTimeString()," · idle"," ",e.session.idleMinutes,"m"]}),!r&&t&&y.jsxs("button",{type:"button",onClick:t,disabled:n,className:X("flex items-center gap-1.5 rounded-md border px-3 py-1.5 text-xs disabled:opacity-40",Cg,"hover:bg-zinc-50 dark:hover:bg-zinc-800"),children:[y.jsx(M8e,{size:13}),n?"Signing out…":"Sign out"]})]})]}),y.jsxs("div",{className:"mt-4 grid gap-3 sm:grid-cols-2 lg:grid-cols-4",children:[y.jsx(ol,{label:"Effective scopes",values:e.scopes,tone:"neutral"}),y.jsx(ol,{label:"May write",values:e.writeTypes,tone:"write",emptyNote:"nothing"}),y.jsx(ol,{label:"May read",values:e.readTypes??["every type"],tone:"neutral"}),y.jsx(ol,{label:"May see",values:e.classifications,tone:"classified",emptyNote:"nothing classified"})]})]})}function Fvt({person:e}){return y.jsxs("div",{className:X("rounded-lg border p-4",Cg,sA),children:[y.jsxs("div",{className:"flex flex-wrap items-start justify-between gap-3",children:[y.jsxs("div",{className:"min-w-0",children:[y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx("span",{className:"text-sm font-medium",children:e.displayName}),y.jsx("span",{className:"rounded-sm bg-zinc-100 px-1.5 py-0.5 font-mono text-[10px] uppercase text-zinc-500 dark:bg-zinc-800",children:e.role}),!e.active&&y.jsx("span",{className:"rounded-sm bg-red-100 px-1.5 py-0.5 font-mono text-[10px] uppercase text-red-600 dark:bg-red-950",children:"disabled"})]}),y.jsx("div",{className:X("mt-0.5 font-mono text-[11px]",As),children:e.principalId})]}),y.jsxs("div",{className:X("flex items-center gap-4 font-mono text-[11px]",As),children:[y.jsx(kt,{content:"Sessions currently alive — not expired, not idled out, not revoked.",children:y.jsxs("span",{className:"cursor-help",children:[e.liveSessions," live"]})}),y.jsx("span",{children:e.lastLoginAt?`last in ${new Date(e.lastLoginAt).toLocaleString()}`:"never signed in"})]})]}),y.jsxs("div",{className:"mt-4 grid gap-3 sm:grid-cols-2 lg:grid-cols-4",children:[y.jsx(ol,{label:"Effective scopes",values:e.effective.scopes,tone:"neutral",emptyNote:"nothing"}),y.jsx(ol,{label:"May write",values:e.effective.writeTypes,tone:"write",emptyNote:"nothing"}),y.jsx(ol,{label:"May read",values:e.effective.readTypes??["every type"],tone:"neutral"}),y.jsx(ol,{label:"May see",values:e.effective.classifications,tone:"classified",emptyNote:"nothing classified"})]})]})}const Bvt=[{value:"viewer",label:"viewer",hint:"read"},{value:"curator",label:"curator",hint:"read, curate"},{value:"admin",label:"admin",hint:"read, curate, administer"}];function Hvt(e){return e==="curator"||e==="admin"?e:"viewer"}function Uvt(){const e=Sr(),t=ra(),[n,r]=A.useState(!1),[i,o]=A.useState(""),[s,a]=A.useState(""),[l,u]=A.useState("viewer"),[c,d]=A.useState(""),h=Jn({mutationFn:()=>e.upsertPerson({email:i.trim(),displayName:s.trim()||i.trim(),role:l,password:c}),onSuccess:()=>{o(""),a(""),d(""),r(!1),t.invalidateQueries({queryKey:rn.people})}});return n?y.jsxs("form",{className:X("rounded-lg border p-4",Cg,sA),onSubmit:m=>{m.preventDefault(),h.mutate()},children:[y.jsxs("div",{className:"grid gap-3 sm:grid-cols-2",children:[y.jsx(Xt,{label:"Email",type:"email",value:i,onChange:o,placeholder:"someone@example.mil"}),y.jsx(Xt,{label:"Display name",value:s,onChange:a,placeholder:"Defaults to the email"}),y.jsx(pr,{label:"Role",ariaLabel:"Role",value:l,onValueChange:m=>u(Hvt(m)),options:Bvt}),y.jsx(Xt,{label:"Password",type:"password",value:c,onChange:d,placeholder:"12 characters or more",autoComplete:"new-password"})]}),h.isError&&y.jsx("p",{className:"mt-2 text-xs text-red-600",children:h.error instanceof Error?h.error.message:"Could not save."}),y.jsx("p",{className:X("mt-2 text-xs",As),children:"No role carries permission to load a snapshot. Publishing is something an application does from a pipeline, with a retryable snapshot id."}),y.jsxs("div",{className:"mt-3 flex gap-2",children:[y.jsx("button",{type:"submit",disabled:h.isPending||i.trim().length===0||c.length<12,className:"rounded-md bg-zinc-950 px-3 py-1.5 text-xs text-zinc-50 disabled:opacity-40 dark:bg-zinc-100 dark:text-zinc-950",children:h.isPending?"Saving…":"Save"}),y.jsx("button",{type:"button",onClick:()=>r(!1),className:X("rounded-md px-3 py-1.5 text-xs",As),children:"Cancel"})]})]}):y.jsx("button",{type:"button",onClick:()=>r(!0),className:X("rounded-lg border border-dashed px-4 py-3 text-left text-sm",Cg,As,"hover:text-zinc-600 dark:hover:text-zinc-300"),children:"+ Add someone"})}const Vvt={token:{icon:J8e,tone:"text-emerald-600",hint:"Authenticates with an access token — rotation and revocation belong to the identity provider."},key:{icon:cP,tone:"text-amber-600",hint:"Authenticates with a long-lived static key, revoked only by editing its row."},session:{icon:Mq,tone:"text-sky-600",hint:"Holds no credential of its own. Reachable only by a person signing in, and it caps what any of them can do."}};function Wvt({principal:e}){const t=Vvt[e.authMethod],n=t.icon;return y.jsxs("div",{className:X("rounded-lg border p-4",Cg,sA),children:[y.jsxs("div",{className:"flex flex-wrap items-start justify-between gap-3",children:[y.jsxs("div",{className:"min-w-0",children:[y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx("span",{className:"text-sm font-medium",children:e.displayName}),!e.active&&y.jsx("span",{className:"rounded-sm bg-zinc-100 px-1.5 py-0.5 font-mono text-[10px] uppercase text-zinc-500 dark:bg-zinc-800",children:"disabled"})]}),y.jsx("div",{className:X("mt-0.5 font-mono text-[11px]",As),children:e.id})]}),y.jsxs("div",{className:"flex items-center gap-4",children:[y.jsx(kt,{content:t.hint,children:y.jsxs("span",{className:X("flex cursor-help items-center gap-1.5 font-mono text-[10px] uppercase tracking-wider",t.tone),children:[y.jsx(n,{size:13}),e.authMethod]})}),y.jsx("span",{className:X("font-mono text-[11px]",As),children:e.lastSeenAt?`seen ${new Date(e.lastSeenAt).toLocaleString()}`:"never seen"})]})]}),y.jsxs("div",{className:"mt-4 grid gap-3 sm:grid-cols-2 lg:grid-cols-4",children:[y.jsx(ol,{label:"Scopes",values:e.scopes,tone:"neutral"}),y.jsx(ol,{label:"May write",values:e.writeTypes,tone:"write",emptyNote:"nothing"}),y.jsx(ol,{label:"May read",values:e.readTypes??["every type"],tone:"neutral"}),y.jsx(ol,{label:"Owns",values:e.ownedTypes,tone:"own",emptyNote:"no types published"})]}),e.classifications.length>0&&y.jsx("div",{className:"mt-3",children:y.jsx(ol,{label:"May see",values:e.classifications,tone:"classified"})})]})}function Nle({title:e,note:t,children:n}){return y.jsxs("div",{className:"mt-10",children:[y.jsx("h2",{className:"text-sm font-semibold tracking-tight",children:e}),y.jsx("p",{className:X("mt-0.5 max-w-2xl text-xs",As),children:t}),y.jsx("div",{className:"mt-3 flex flex-col gap-3",children:n})]})}function xk({children:e}){return y.jsx("p",{className:X("rounded-lg border border-dashed px-4 py-8 text-center text-sm",Cg,As),children:e})}function Lle({message:e,onRetry:t}){return y.jsxs("div",{className:"rounded-lg border border-red-200 bg-red-50 px-4 py-6 text-center dark:border-red-900 dark:bg-red-950/40",children:[y.jsx("p",{className:"text-sm text-red-700 dark:text-red-300",children:e}),y.jsx("button",{type:"button",onClick:t,className:"mt-2 rounded-md border border-red-300 px-3 py-1 text-xs text-red-700 dark:border-red-800 dark:text-red-300",children:"Try again"})]})}const qvt={neutral:"bg-zinc-100 text-zinc-600 dark:bg-zinc-800 dark:text-zinc-300",write:"bg-sky-100 text-sky-700 dark:bg-sky-950 dark:text-sky-300",own:"bg-emerald-100 text-emerald-700 dark:bg-emerald-950 dark:text-emerald-300",classified:"bg-amber-100 text-amber-700 dark:bg-amber-950 dark:text-amber-300"};function ol({label:e,values:t,tone:n,emptyNote:r="—"}){return y.jsxs("div",{children:[y.jsx("div",{className:X("font-mono text-[10px] uppercase tracking-[0.14em]",As),children:e}),y.jsx("div",{className:"mt-1 flex flex-wrap gap-1",children:t.length===0?y.jsx("span",{className:X("text-xs italic",As),children:r}):t.map(i=>y.jsx("span",{className:X("rounded-sm px-1.5 py-0.5 font-mono text-[10px]",qvt[n]),children:i},i))})]})}const GE=6;function Gvt(e,t,n){const r=new Map(e.map(s=>[s.id,s])),i=new Map;for(const s of t)i.set(s.to,[...i.get(s.to)??[],s.from]);const o=[];for(const s of e)s.kind==="sink"&&(typeof s.targetType!="string"||s.targetType.trim().length===0||o.push(...Kvt(s,r,i,n)));return o}function Kvt(e,t,n,r){const i=[],o=[];for(const s of n.get(e.id)??[]){const a=t.get(s);if(!a)continue;if(a.kind!=="source"){Yvt(a.id,t,n,r)&&o.push(a);continue}const l=r.sourceShape(a.id);l&&i.push(...Qvt(a,e,l,r))}return o.length>0&&i.push(Xvt(o,e)),i}function Yvt(e,t,n,r){const i=new Set([e]),o=[e];for(;o.length>0;){const s=o.pop();if(s===void 0)break;const a=t.get(s);if((a==null?void 0:a.kind)==="source"&&r.sourceShape(a.id))return!0;for(const l of n.get(s)??[])i.has(l)||(i.add(l),o.push(l))}return!1}function Xvt(e,t){const n=e.map(r=>`"${kn(r)}"`).join(", ");return{level:"warning",code:"shape-not-checked",message:`Whether what reaches "${kn(t)}" fits ${t.targetType.trim()} could not be checked: ${n} ${e.length===1?"sits":"sit"} in between, and ${e.length===1?"it hands":"they hand"} the sink rows ${e.length===1?"it":"they"} computed. What a transform emits is whatever its code returns, and what a call node emits is decided by a workflow this graph does not own — neither is knowable without running it, which this canvas does not do. The columns are compared only where a source feeds a sink directly. This is not a problem with the graph; it is the check declining to guess.`,nodeIds:[...e.map(r=>r.id),t.id],edgeIds:[]}}function Qvt(e,t,n,r){const i=t.targetType.trim(),o=r.targetShape(i);if(!o)return[{level:"warning",code:"shape-not-checked",message:`"${kn(e)}" reads ${n.columns.length} column${n.columns.length===1?"":"s"}, but there is nothing to compare them against: this console cannot see a type called ${i}. It may not be published yet, or it may be one this viewer is not allowed to read. The server checks it either way on save.`,nodeIds:[e.id,t.id],edgeIds:[]}];const s=Zvt(n,o),a=[];return s.respelled.length>0&&a.push(t1t(e,t,o,s.respelled)),s.missing.length>0&&a.push(n1t(e,t,o,s.missing)),s.unproven.length>0&&a.push(r1t(e,t,o,s.unproven,n)),a}function Zvt(e,t){const n=new Map(e.columns.map(i=>[i.name,i])),r={respelled:[],missing:[],unproven:[]};for(const i of t.properties){const o=n.get(i.name);if(o){const a=Jvt(i,o);a&&r.unproven.push(a);continue}const s=i.columnName;if(s&&s!==i.name&&n.has(s)){r.respelled.push({property:i,spelling:s});continue}r.missing.push(i)}return r}function Jvt(e,t){const n=`\`${e.name}\``;if(t.type===null||t.confidence==="unknown")return`${n} — discovery reached no conclusion about it${t.sourceType?` (the source calls it ${t.sourceType})`:""}, and ${e.type} is what the type expects`;if(!e1t(e.type,t.type))return`${n} — the source reports ${t.type} and the type says ${e.type}, so each value is converted on the way in and the ones that will not convert are written as null`;if(e.nullable===!1&&t.nullable===!0)return`${n} — the type says it is never null and the source says its column may be`}function e1t(e,t){return e===t?!0:e==="string"||e==="json"||e==="unknown"}function t1t(e,t,n,r){const i=r.slice(0,GE).map(({property:o,spelling:s})=>`\`${s}\` → \`${o.name}\``).join(", ");return{level:"error",code:"shape-source-spelling",message:`"${kn(e)}" produces ${Dj(r.length,"column")} that ${n.name} knows under a different name: ${i}${CY(r.length)}. The load looks every field up by the property's own name, and a source wired straight into a sink hands its records over exactly as they arrive — so each of these would be written as null in every row, and the load would still report the rows it read. Rename the ${r.length===1?"property":"properties"} on ${n.name} to the spelling the source uses, which publishing now accepts; where a name cannot become a column even cleaned, put a transform between them to rename the field instead.`,nodeIds:[e.id,t.id],edgeIds:[]}}function n1t(e,t,n,r){const i=r.slice(0,GE).map(o=>`\`${o.name}\``).join(", ");return{level:"error",code:"shape-missing-column",message:`"${kn(e)}" does not produce ${Dj(r.length,"column")} that ${n.name} is made of: ${i}${CY(r.length)}. Nothing between a source and a sink adds a field, so ${r.length===1?"it":"each of them"} would be null in every row "${kn(t)}" commits, on every run, and the run would report success.`,nodeIds:[e.id,t.id],edgeIds:[]}}function r1t(e,t,n,r,i){const o=r.slice(0,GE).join("; ");return{level:"warning",code:"shape-unproven",message:`${Dj(r.length,"column")} between "${kn(e)}" and ${n.name} could not be decided from the schemas alone: ${o}${CY(r.length)}. ${i1t(i)} Nothing here says the graph is wrong — it says this much of it was not proven right.`,nodeIds:[e.id,t.id],edgeIds:[]}}function i1t(e){if(e.basis==="sample"){const t=e.sampled??0;return`The types came from ${Dj(t,"record")} read out of the source, so they are an inference over what was seen and not a statement about the rest.`}return e.basis==="driver"?`The types came from the driver's description of the result set and no rows were read (sampled ${e.sampled??0}), so the column names are the source's own and nothing at all is known about the values.`:"The discovery behind this did not say how it knows, so treat the types as unproven."}function Dj(e,t){return`${e} ${t}${e===1?"":"s"}`}function CY(e){return e>GE?`, and ${e-GE} more`:""}const o1t=new Set(["cycle","self-edge","duplicate-edge","shape-source-spelling","shape-missing-column"]);function LOe(e,t,n){if(!o1t.has(e))return[];const r=new Set(t);return n.filter(i=>r.has(i.from)&&r.has(i.to)).map(i=>Fo(i))}function Fo(e){return`${e.from}->${e.to}`}function s1t(e,t){const{nodes:n,edges:r}=e,i=[];for(const o of Ke.validateWorkflow({nodes:n,edges:r}))i.push({level:"error",code:o.code,message:o.message,nodeIds:o.nodeIds,edgeIds:LOe(o.code,o.nodeIds,r)});for(const o of n){const s=kn(o);if(o.kind==="transform"){o.transformId.length>0&&!t.transformIds.has(o.transformId)&&i.push({level:"error",code:"missing-transform",message:`"${s}" points at a transform that no longer exists. It was probably deleted from the Transforms tab.`,nodeIds:[o.id],edgeIds:[]});continue}if(o.kind!=="sink")continue;(typeof o.targetType=="string"?o.targetType.trim():"").length===0&&i.push({level:"error",code:"sink-has-no-type",message:`"${s}" does not say which object type it writes, so there would be nothing for the run to commit into. The type is chosen on the sink because the sink is the node that commits.`,nodeIds:[o.id],edgeIds:[]})}return i.push(...a1t(e,t)),i}function a1t(e,t){return t.shapes?Gvt(e.nodes,e.edges,t.shapes).map(n=>({...n,edgeIds:LOe(n.code,n.nodeIds,e.edges)})):[]}function l1t(e,t,n){if(t===n)return!0;const r=new Map;for(const s of e)r.set(s.from,[...r.get(s.from)??[],s.to]);const i=new Set([n]),o=[n];for(;o.length>0;){const s=o.pop();if(s===void 0)break;for(const a of r.get(s)??[]){if(a===t)return!0;i.has(a)||(i.add(a),o.push(a))}}return!1}function tc(e,t,n,r){if(n===r)return{ok:!1,reason:"A node cannot feed itself."};const i=e.find(s=>s.id===n),o=e.find(s=>s.id===r);return!i||!o?{ok:!1,reason:"One end of that connection is not a node."}:i.kind==="sink"?{ok:!1,reason:`"${kn(i)}" commits its rows. Nothing runs after a sink.`}:o.kind==="source"?{ok:!1,reason:`"${kn(o)}" reads from a system, so nothing can feed into it.`}:t.some(s=>s.from===n&&s.to===r)?{ok:!1,reason:`Those two are already wired together, and wiring them twice would send "${kn(o)}" the same rows twice.`}:o.kind==="if"&&t.some(s=>s.to===r)?{ok:!1,reason:`"${kn(o)}" already has something feeding it. An if node is a gate — it passes one stream straight down whichever branch it takes — so it cannot merge two. Wire both into a transform and gate that instead.`}:l1t(t,n,r)?{ok:!1,reason:`That would close a loop: "${kn(o)}" already feeds "${kn(i)}", directly or through other nodes. A ${bn.singular} that loops has no order to run in.`}:{ok:!0}}function u1t(e){return e.some(t=>t.level==="error")}function XU(e){const t=new Map;for(const n of e)for(const r of n.nodeIds){const i=t.get(r)??[];i.push(n),t.set(r,i)}return t}Ke.CONNECTOR_KINDS.filter(e=>e==="file"||e==="s3");function c1t(e,t,n,r,i,o,s,a,l,u=2){const c=F7e(n.current,{event:e,orientation:r,loopFocus:i,rtl:o,cols:u,disabledIndices:s,minIndex:a,maxIndex:l,prevIndex:t>l?a:t,stopEvent:!0});return wh(n.current,c)?void 0:c}function EY(e){return e==null?ki:e.type.startsWith("key")?jve:e.type.startsWith("mouse")||e.type.startsWith("pointer")?Dve:ki}const IOe=A.createContext(void 0),POe=A.createContext(void 0),jOe=A.createContext(void 0),DOe=A.createContext(!1),$Oe=A.createContext("");function Bd(){const e=A.useContext(IOe);if(!e)throw new Error(Br(22));return e}function TY(){const e=A.useContext(POe);if(!e)throw new Error(Br(23));return e}function aA(){const e=A.useContext(jOe);if(!e)throw new Error(Br(24));return e}function d1t(){return A.useContext($Oe)}function f1t(){return A.useContext(DOe)}const h1t={id:e=>e.id,labelId:e=>e.labelId,items:e=>e.items,selectedValue:e=>e.selectedValue,hasSelectionChips:e=>{const t=e.selectedValue;return Array.isArray(t)&&t.length>0},hasSelectedValue:e=>{const{selectedValue:t,selectionMode:n}=e;return t==null?!1:n==="multiple"&&Array.isArray(t)?t.length>0:!0},hasNullItemLabel:(e,t)=>t?U1e(e.items):!1,open:e=>e.open,mounted:e=>e.mounted,forceMounted:e=>e.forceMounted,inline:e=>e.inline,activeIndex:e=>e.activeIndex,selectedIndex:e=>e.selectedIndex,isActive:(e,t)=>e.activeIndex===t,isSelected:(e,t)=>{const n=e.isItemEqualToValue,r=e.selectedValue;return Array.isArray(r)?r.some(i=>cu(t,i,n)):cu(t,r,n)},transitionStatus:e=>e.transitionStatus,popupProps:e=>e.popupProps,listProps:e=>e.listProps,inputProps:e=>e.inputProps,triggerProps:e=>e.triggerProps,itemRoot:e=>e.itemRoot,positionerElement:e=>e.positionerElement,listElement:e=>e.listElement,popupId:e=>e.popupId,triggerElement:e=>e.triggerElement,inputElement:e=>e.inputElement,inputGroupElement:e=>e.inputGroupElement,popupSide:e=>e.popupSide,openMethod:e=>e.openMethod,inputInsidePopup:e=>e.inputInsidePopup,inputOwnsFormValue:e=>e.inputOwnsFormValue,selectionMode:e=>e.selectionMode,name:e=>e.name,form:e=>e.form,disabled:e=>e.disabled,readOnly:e=>e.readOnly,required:e=>e.required,grid:e=>e.grid,virtualized:e=>e.virtualized,itemToStringLabel:e=>e.itemToStringLabel,isItemEqualToValue:e=>e.isItemEqualToValue,modal:e=>e.modal,autoHighlight:e=>e.autoHighlight};function p1t(e){return e==null?void 0:`${e}-popup`}function m1t(e,t){return(n,r)=>n==null?!1:e.contains(n,r,t)}function zOe(e){return Array.isArray(e)?e.map(t=>zOe(t)).join(","):e==null?"":String(e)}const Ile=new Map;function g1t(e={}){const{locale:t,...n}=e,r={usage:"search",sensitivity:"base",ignorePunctuation:!0,...n},i=`${zOe(t)}|${JSON.stringify(r)}`,o=Ile.get(i);if(o)return o;const s=new Intl.Collator(t,r),a={contains(l,u,c){if(!u)return!0;const d=Sh(l,c);for(let h=0;h<=d.length-u.length;h+=1)if(s.compare(d.slice(h,h+u.length),u)===0)return!0;return!1},startsWith(l,u,c){if(!u)return!0;const d=Sh(l,c);return s.compare(d.slice(0,u.length),u)===0},endsWith(l,u,c){if(!u)return!0;const d=Sh(l,c),h=u.length;return d.length>=h&&s.compare(d.slice(d.length-h),u)===0}};return Ile.set(i,a),a}const FOe=g1t;function y1t(e,t=!1){const{overflowY:n}=ka(e);return n!=="auto"&&n!=="scroll"?!1:t?e.clientHeight>0:e.scrollHeight>e.clientHeight}const BOe=Symbol("none"),S8={value:BOe,index:-1};function b1t(e,t,n){const r=e.get(t);if(r!==void 0||n===jP)return r;for(const[i,o]of e)if(cu(i,t,n))return o}function v1t(e){const{id:t,onOpenChangeComplete:n,defaultSelectedValue:r=null,selectedValue:i,onSelectedValueChange:o,defaultInputValue:s,inputValue:a,open:l,defaultOpen:u=!1,selectionMode:c,onItemHighlighted:d,name:h,form:m,disabled:g=!1,readOnly:b=!1,required:v=!1,inputRef:w,grid:S=!1,items:C,filteredItems:E,filter:T,filterQuery:O,openOnInputClick:M=!0,autoHighlight:N=!1,keepHighlight:I=!1,highlightItemOnHover:D=!0,loopFocus:P=!0,itemToStringLabel:F,itemToStringValue:z,isItemEqualToValue:$=jP,virtualized:B=!1,inline:H=!1,fillInputOnItemPress:U=!0,modal:W=!1,limit:q=-1,autoComplete:Y="list",formAutoComplete:Q,locale:G,submitOnItemClick:le=!1}=e,{clearErrors:K}=CG(),{setDirty:te,validityData:de,setFilled:ue,name:ae,disabled:ie,setTouched:he,setFocused:fe,validationMode:se,validation:Se}=Mb(),pe=Ww(),Ee=PP({id:t}),ke=FOe({locale:G}),Ie=Array.isArray(C)?null:C;if(Ie&&typeof Ie.label!="function")throw new Error(Br(100));const Be=Ie?Ie.data:C,Oe=Ie==null?void 0:Ie.value,Le=Oe?void 0:Be,ge=A.useMemo(()=>{if(!E||!Oe)return;const Je=NM(E),nt=Je.map(Oe);let en;return{values:nt,findItem(j,ee){if(!en){en=new Map;for(let ce=0;ce<nt.length;ce+=1)en.has(nt[ce])||en.set(nt[ce],Je[ce])}return b1t(en,j,ee)}}},[E,Oe]),$e=A.useMemo(()=>Ie?Je=>Ie.label(Je,$,nt=>{const en=ge==null?void 0:ge.findItem(nt,$);return en!=null?Ie.itemLabel(en):Sh(nt,F)}):F,[Ie,F,ge,$]),Ye=A.useMemo(()=>Ie?Object.assign(Je=>Ie.itemLabel(Je),{selected:Je=>Sh(Je,$e)}):F,[Ie,$e,F]);function tt(Je){return Sh(Je,$e)}const[Ae,_e]=A.useState(!1),[He,Ue]=A.useState(null),Ve=A.useRef(He),gt=A.useRef([]),rt=A.useRef([]),xt=A.useRef(null),$t=A.useRef(null),zt=A.useRef(null),vn=A.useRef(null),_n=A.useRef(null),Vn=A.useRef(!1),Ln=A.useRef(null),ln=A.useRef(null),mr=A.useRef(null),Yn=A.useRef(S8),Yt=A.useRef(null),Ht=A.useRef([]),on=A.useRef(null),Jt=ie||g,yt=ae??h,pt=c==="multiple",Fe=c==="single",Qe=a!==void 0||s!==void 0,ut=Be!==void 0,qt=E!==void 0;let Vt;N==="always"?Vt="always":Vt=N?"input-change":!1;const[it,sn]=$y({controlled:i,default:pt?r??Ws:r,name:"Combobox",state:"selectedValue"}),zn=A.useMemo(()=>T===null?()=>!0:T!==void 0?T:m1t(ke,Ye),[T,ke,Ye]),er=Ti(()=>Qe?s??"":Fe?tt(it):"").current,[Qt,tr]=$y({controlled:a,default:er,name:"Combobox",state:"inputValue"}),[cn,nr]=$y({controlled:l,default:u,name:"Combobox",state:"open"}),bo=kG(Be),Mr=!cn&&He!==null?He:String(Qt).trim(),zi=Fe?tt(it):"",Ms=Fe&&!Ae&&Mr!==""&&zi.length===Mr.length&&ke.contains(zi,Mr),Ri=Ms?"":O??Mr,La=ut&&qt&&Ms&&(!Ie||Ie.hasValue(it,$)),Uo=A.useMemo(()=>Be?NM(Be):Ws,[Be]),vo=A.useMemo(()=>{if(E&&!La)return E;if(!Be)return Ws;if(bo){const nt=Be,en=[];let j=0;for(const ee of nt){if(q>-1&&j>=q)break;const ce=q>-1?q-j:1/0,me=Ri===""?ee.items.slice(0,ce):[];if(Ri!=="")for(const xe of ee.items){if(me.length>=ce)break;zn(xe,Ri,Ye)&&me.push(xe)}if(me.length>0){const xe={...ee,items:me};en.push(xe),j+=me.length}}return en}if(Ri==="")return q>-1?Uo.slice(0,q):Uo;const Je=[];for(const nt of Uo){if(q>-1&&Je.length>=q)break;zn(nt,Ri,Ye)&&Je.push(nt)}return Je},[E,La,Be,bo,Ri,q,zn,Ye,Uo]),kr=A.useMemo(()=>{if(ge&&vo===E)return ge.values;const Je=NM(vo);return Oe?Je.map(nt=>Oe(nt)):Je},[vo,E,ge,Oe]),Ct=Ti(()=>{let Je=null;return H&&cn&&ut&&c!=="none"&&(Je=wC(kr,it,$,pt)),new Fw({id:Ee,labelId:void 0,selectedValue:it,open:cn,items:Le,selectionMode:c,name:yt,form:m,disabled:Jt,readOnly:b,required:v,grid:S,virtualized:B,openOnInputClick:M,itemToStringLabel:$e,isItemEqualToValue:$,modal:W,autoHighlight:Vt,submitOnItemClick:le,hasInputValue:Qe,mounted:!1,forceMounted:!1,transitionStatus:"idle",inline:H,activeIndex:null,selectedIndex:Je,popupProps:{},listProps:{},inputProps:{},triggerProps:{},itemRoot:{props:Un,id:Ee,selectionMode:c,disabled:Jt,readOnly:b,isItemEqualToValue:$},positionerElement:null,listElement:null,popupId:void 0,triggerElement:null,inputElement:null,inputGroupElement:null,popupSide:null,openMethod:null,inputInsidePopup:!0,inputOwnsFormValue:c==="none"},{onOpenChangeComplete:ar,setOpen:ar,setInputValue:ar,setSelectedValue:ar,setIndices:ar,handleSelection:ar,forceMount:ar,requestSubmit:ar,listRef:gt,labelsRef:rt,popupRef:xt,emptyRef:_n,inputRef:$t,startDismissRef:zt,endDismissRef:vn,chipsContainerRef:Ln,clearRef:ln,valuesRef:Ht,pointerDownItemRef:on,selectionEventRef:mr},h1t)}).current,cs=c==="none"?Qt:it,fc=A.useMemo(()=>c==="none"?cs:Array.isArray(it)?it.map(Je=>Vu(Je,z)):Vu(it,z),[cs,z,c,it]),pu=at(d),Fi=at(n),Hr=Ct.useState("activeIndex"),Te=Ct.useState("selectedIndex"),Xe=Ct.useState("positionerElement"),Ze=Ct.useState("listElement"),Ft=Ct.useState("triggerElement"),In=Ct.useState("inputElement"),_r=Ct.useState("inputGroupElement"),rr=Ct.useState("inline"),gi=Ct.useState("inputInsidePopup"),hc=Ct.useState("inputOwnsFormValue"),ia=Fe&&!gi&&Qt===zi,ml=ci(Ft),{openMethod:mu,triggerProps:ds}=EG(cn),si=at(()=>fc);SG(gi?ml:$t,Ee,cs,si,!Jt,h);const pc=at(()=>{Be?rt.current=kr.map(tt):Ct.set("forceMounted",!0)}),Ia=at((Je,nt,en,j)=>{if(nt===-1){if(Yn.current===S8)return;Yn.current=S8}else Yn.current={value:Je,index:nt};pu(Je,Ive(en,j,{index:nt}))}),fs=at(Je=>{const nt={};Je.activeIndex!==void 0&&(nt.activeIndex=Je.activeIndex),Je.selectedIndex!==void 0&&(nt.selectedIndex=Je.selectedIndex),Ct.update(nt);const en=Je.activeIndex;if(en===void 0)return;const j=Je.type||ki;en===null?Ia(void 0,-1,j,Je.event):Ia(Ht.current[en],en,j,Je.event)}),ai=at((Je,nt)=>{var en;if((en=e.onInputValueChange)==null||en.call(e,Je,nt),!nt.isCanceled){if(Vn.current=nt.reason===Lc,nt.reason===A1){cn&&He!==null&&Ue(null);const j=nt.event,ee=j.inputType;if(j.type==="compositionend"||ee!=null&&ee!==""&&ee!=="insertReplacementText"){const me=Je.trim()!=="";me&&_e(!0),Yt.current={hasQuery:me};const xe=Ct.state.listElement;if(!Ct.state.virtualized&&xe){const De=xt.current;for(const bt of Lx(xe.firstElementChild??xe)){if(!Ar(bt)||(De?!Rt(De,bt):bt.getAttribute("role")==="dialog"))break;if(y1t(bt)){bt.scrollTop=0;break}}}me&&Vt&&Ct.state.activeIndex==null&&(cn||rr)&&Ct.set("activeIndex",0)}}else nt.reason===Lc&&Je===""&&Ct.state.inputInsidePopup&&(Yt.current={hasQuery:!1,selection:!0});tr(Je)}}),Pa=at(Je=>{const nt=!Je&&gi&&!rr&&Qt!==""&&(String(Qt).trim()===He||Qt===zi);!Je&&(nt||Qt===""||ia)&&_e(!1),Ue(null),nt&&ai("",Et(Lc))}),[tp,mc]=A.useState(!1),ja=at((Je,nt)=>{var ee,ce;if(cn===Je)return;nt.reason===Vw&&ut&&kr.length===0&&!_n.current&&nt.allowPropagation();const en=nt,j=MP(en);if((ee=e.onOpenChange)==null||ee.call(e,Je,en),(ce=Yt.current)!=null&&ce.hasQuery&&nt.reason===A1===nt.isCanceled&&(Yt.current=null),!nt.isCanceled&&(Je&&He!==null&&Pa(nt.reason===A1),!Je&&Ae&&(Fe?(rr||Ue(Mr),Mr===""&&_e(!1)):pt&&(rr||Ue(Mr),gi&&fs({activeIndex:null}),(!gi||rr)&&ai("",Et(Lc,nt.event,void 0,{isItemPress:nt.reason===eg})))),Je||mc(j()),nr(Je),!Je&&gi&&(nt.reason===gg||nt.reason===E2)&&(he(!0),fe(!1),se==="onBlur"))){const me=c==="none"?Qt:it;Se.commit(me)}}),gu=at((Je,nt)=>{if(o==null||o(Je,nt),nt.isCanceled)return;sn(Je),(c==="none"&&xt.current&&U||Fe&&!Ct.state.inputInsidePopup)&&ai(tt(Je),Et(nt.reason,nt.event))}),En=at((Je,nt)=>{var me;const en=ji(Je),j=mr.current??Je;mr.current=null;const ee=Et(eg,j),ce=(me=mg(en,"a"))==null?void 0:me.getAttribute("href");if(ce){ce.startsWith("#")&&ja(!1,ee);return}if(pt){const xe=Array.isArray(it)?it:[],De=oN(xe,nt,$),bt=De?H1e(xe,nt,$):[...xe,nt];if(gu(bt,ee),ee.isCanceled||!($t.current?$t.current.value.trim()!=="":!1))return;if(Ct.state.inputInsidePopup){ai("",Et(Lc,ee.event,void 0,{isItemPress:!0}));const mt=Yt.current;mt&&!De&&(mt.toggledValue=nt)}else ja(!1,ee)}else{if(gu(nt,ee),ee.isCanceled)return;ja(!1,ee)}}),Gg=at(()=>{var nt,en;const Je=((nt=Se.inputRef.current)==null?void 0:nt.form)??((en=Ct.state.inputElement)==null?void 0:en.form);Je&&typeof Je.requestSubmit=="function"&&Je.requestSubmit()}),np=at(()=>{if(Fi==null||Fi(!1),_e(!1),Ue(null),fs(c==="none"?{activeIndex:null,selectedIndex:null}:{activeIndex:null}),pt&&$t.current&&$t.current.value!==""&&!Vn.current&&ai("",Et(Lc)),Fe)if(Ct.state.inputInsidePopup)$t.current&&$t.current.value!==""&&ai("",Et(Lc));else{const Je=tt(it);$t.current&&$t.current.value!==Je&&ai(Je,Et(Je===""?Lc:ki))}}),yu=A.useMemo(()=>rr&&Xe?{current:mg(Xe,'[role="dialog"]')}:xt,[rr,Xe]),{mounted:Da,transitionStatus:xo,forceUnmount:Kg}=cG({open:cn,ref:yu,preventUnmountOnClose:tp,setPreventUnmountOnClose:mc,onUnmount:np});A.useImperativeHandle(e.actionsRef,()=>({unmount:Kg,close:()=>ja(!1,Et(T2))}),[Kg,ja]),et(function(){const nt=Ve.current!==null&&He===null;if(Ve.current=He,cn&&(!nt||!ut)||(cn||(on.current=null),c==="none"))return;const en=ut?kr:Ht.current;fs({selectedIndex:wC(en,it,$,pt)})},[cn,He,it,c,pt,ut,kr,$,fs]),et(()=>{Be&&(Ht.current=kr,gt.current.length=kr.length)},[Be,kr]),et(()=>{var Je;!cn&&((Je=Yt.current)!=null&&Je.hasQuery)&&(Yt.current=null)},[cn]),et(()=>{var me;if(!cn&&rr&&yu.current){Yt.current=null;return}const Je=ut||qt?kr:Ht.current,nt=Yt.current;if(nt){const xe=cn||rr||((me=Ct.state.positionerElement)==null?void 0:me.hidden)===!1;if(nt.hasQuery){const De=$t.current;!Vt||String(Qt).trim()===""||rr&&Vt!=="always"&&(!De||Ss(De.ownerDocument)!==De)?Yt.current=null:xe&&(Je[0]!==void 0||!ut&&!qt)&&(Ct.set("activeIndex",0),Yt.current=null)}else if(String(Qt).trim()===""&&(Yt.current=null,xe)){const De=nt.selection;Vt==="always"&&!De&&Ct.state.selectionMode==="none"&&Ct.set("activeIndex",0),queueMicrotask(()=>{if(!Ct.state.open&&(!Ct.state.inline||yu.current)||$t.current&&$t.current.value.trim()!=="")return;const bt=Ct.state.selectedValue,an=Ct.state.selectionMode==="multiple";if(an&&Array.isArray(bt)?bt.length>0:Ct.state.selectionMode!=="none"&&bt!=null){const Zt=ut||qt?kr:Ht.current,gr=_1(Zt,nt.toggledValue,Ct.state.isItemEqualToValue);Ct.set("activeIndex",gr!==-1?gr:wC(Zt,bt,Ct.state.isItemEqualToValue,an))}else De?Ct.set("activeIndex",null):Vt==="always"&&Ct.set("activeIndex",0)})}}if(!cn&&!rr)return;const en=Ct.state.activeIndex;if(en==null){if(Vt==="always"&&Je.length>0){Ct.set("activeIndex",0);return}Ia(void 0,-1,ki);return}if(en>=Je.length){Ia(void 0,-1,ki),Ct.set("activeIndex",null);return}const j=Je[en],ee=Yn.current.value,ce=ee!==BOe&&cu(j,ee,Ct.state.isItemEqualToValue);(Yn.current.index!==en||!ce)&&Ia(j,en,ki)},[Hr,Vt,Ia,qt,ut,kr,rr,cn,yu,Ct,Qt]),et(()=>{if(c==="none"){ue(String(Qt)!=="");return}ue(pt?Array.isArray(it)&&it.length>0:it!=null)},[ue,c,Qt,it,pt]),A.useEffect(()=>{ut&&Vt&&kr.length===0&&fs({activeIndex:null})},[ut,Vt,kr.length,fs]);function vS(){cn&&Mr!==""&&Mr!==String(er)&&!ia&&_e(!0)}function Yg(){cn&&He!==null&&Pa(!1)}let Xg=!1;function Vd(){!Xg&&Qt!==zi&&(Xg=!0,ai(zi,Et(ki)))}function hs(){c!=="none"&&(K(yt),te(F1e(it,de.initialValue,$)),Se.change(it),Fe&&!Qe&&!gi&&Vd())}function rp(){Fe&&!Qe&&!gi&&!Ae&&Vd()}function Vb(){c==="none"&&(K(yt),te(Qt!==de.initialValue),Se.change(Qt))}Rf(Mr,vS),Rf(cn,Yg),Rf(it,hs),Rf(zi,rp),Rf(Be,rp),Rf(Qt,Vb);const $a=v1e({open:rr?!0:cn,onOpenChange:ja,elements:{reference:gi?Ft:In,floating:Xe}}),gl=S?"grid":"listbox",Wd=cn||rr,Qg=Wd?"true":"false",za=A.useMemo(()=>{const Je=(In==null?void 0:In.tagName)==="INPUT",nt=In==null||Je,en=nt||Wd,j=nt?{autoComplete:"off",spellCheck:"false",autoCorrect:"off",autoCapitalize:"none"}:{};return en&&(j.role="combobox",j["aria-expanded"]=Qg,j["aria-haspopup"]=gl,j["aria-controls"]=Wd?Ze==null?void 0:Ze.id:void 0,j["aria-autocomplete"]=b?"none":Y),{reference:j,floating:{role:"presentation"}}},[In,Wd,Qg,gl,Ze==null?void 0:Ze.id,Y,b]),Wb=aG($a,{enabled:!Jt&&M,event:"mousedown-only",toggle:!1,touchOpenDelay:gi?0:100,reason:T7e}),qd=O2($a,{enabled:!Jt&&!rr,outsidePressEvent:{mouse:"sloppy",touch:"intentional"},bubbles:rr?!0:void 0,outsidePress(Je){const nt=ji(Je);return!Rt(Ft,nt)&&!Rt(ln.current,nt)&&!Rt(Ln.current,nt)&&!Rt(_r,nt)}}),bu=vG($a,{enabled:!Jt,id:Ee,listRef:gt,activeIndex:Hr,selectedIndex:Te,virtual:!0,loopFocus:P,allowEscape:P&&!Vt,focusItemOnOpen:Ae||c==="none"&&!Vt?!1:"auto",focusItemOnHover:D,resetOnPointerLeave:!I,orientation:S?"horizontal":void 0,rtl:pe==="rtl",disabledIndices:Ws,grid:S?c1t:void 0,onNavigate(Je,nt){!nt&&!cn&&!(rr&&Je===null)||xo==="ending"||fs({activeIndex:Je,type:EY(nt),event:nt==null?void 0:nt.nativeEvent})}}),ip=A.useMemo(()=>Qs(bu.reference,{onKeyDown(Je){S&&Ct.state.activeIndex==null&&(Je.key==="ArrowLeft"||Je.key==="ArrowRight")&&Je.preventBaseUIHandler()}},qd.reference,Wb.reference,za.reference),[bu.reference,qd.reference,Wb.reference,za.reference,S,Ct]),Zg=A.useMemo(()=>Qs(R2,qd.floating),[qd.floating]),qb=A.useMemo(()=>Qs(bu.floating,za.floating),[bu.floating,za.floating]),Gd=A.useMemo(()=>{const Je=bu.item;return{props:Je?{...Je,onFocus:void 0}:Un,id:Ee,selectionMode:c,disabled:Jt,readOnly:b,isItemEqualToValue:$}},[bu.item,Ee,c,Jt,b,$]);Ct.useContextCallback("setOpen",ja),Ct.useContextCallback("setInputValue",ai),Ct.useContextCallback("setSelectedValue",gu),Ct.useContextCallback("setIndices",fs),Ct.useContextCallback("handleSelection",En),Ct.useContextCallback("forceMount",pc),Ct.useContextCallback("requestSubmit",Gg),Ct.useContextCallback("onOpenChangeComplete",n),wve(()=>{Ct.update({inline:H,popupProps:Zg,listProps:qb,inputProps:ip,triggerProps:ds,itemRoot:Gd})});const _s={id:Ee,selectedValue:it,open:cn,mounted:Da,transitionStatus:xo,items:Le,inline:H,popupProps:Zg,listProps:qb,inputProps:ip,triggerProps:ds,itemRoot:Gd,openMethod:mu,selectionMode:c,name:yt,form:m,disabled:Jt,readOnly:b,required:v,grid:S,virtualized:B,openOnInputClick:M,itemToStringLabel:$e,modal:W,autoHighlight:Vt,isItemEqualToValue:$,submitOnItemClick:le,hasInputValue:Qe};et(()=>{Ct.update({..._s,inputOwnsFormValue:c==="none"&&(H||!Ct.state.inputInsidePopup)})},[Ct,...Object.values(_s)]);const Jg=uu(w,Se.inputRef),e0=A.useMemo(()=>({query:Mr,hasItems:ut,filteredItems:vo,flatFilteredValues:kr}),[Mr,ut,vo,kr]),gc=A.useMemo(()=>Array.isArray(cs)?"":Vu(cs,z),[cs,z]),yc=pt&&Array.isArray(it)&&it.length>0,op=pt||c==="none"&&hc?void 0:yt,t0=A.useMemo(()=>!pt||!Array.isArray(it)||!yt?null:it.map(Je=>{const nt=Vu(Je,z);return y.jsx("input",{type:"hidden",form:m,name:yt,value:nt,disabled:Jt},nt)}),[pt,it,m,yt,z,Jt]),n0=y.jsxs(A.Fragment,{children:[e.children,y.jsx("input",{...Se.getValidationProps(Jt,{onFocus(){var Je;if(gi){Ft==null||Ft.focus();return}(Je=$t.current||Ft)==null||Je.focus()},onChange(Je){if(Je.nativeEvent.defaultPrevented||Jt||b)return;const nt=Je.currentTarget.value,en=nt.toLowerCase(),j=Et(ki,Je.nativeEvent),ee=()=>Ht.current.findIndex(me=>Vu(me,z).toLowerCase()===en||tt(me).toLowerCase()===en);function ce(){if(pt)return;if(c==="none"){ai(nt,j);return}let me=ee();me===-1&&(me=Ht.current.findIndex((De,bt)=>{const an=rt.current[bt];return an!=null&&an.toLowerCase()===en}));const xe=me===-1?void 0:Ht.current[me];xe!=null&&(gu==null||gu(xe,j))}Fe&&(pc(),Be&&ee()===-1&&Ct.set("forceMounted",!0)),queueMicrotask(ce)}}),id:Ee&&op==null?`${Ee}-hidden-input`:void 0,form:m,name:op,autoComplete:Q,disabled:Jt,required:v&&!yc,readOnly:b,value:gc,ref:Jg,style:op?bP:yP,tabIndex:-1,"aria-hidden":!0,suppressHydrationWarning:!0}),t0]});return y.jsx(IOe.Provider,{value:Ct,children:y.jsx(POe.Provider,{value:$a,children:y.jsx(DOe.Provider,{value:ut,children:y.jsx(jOe.Provider,{value:e0,children:y.jsx($Oe.Provider,{value:Qt,children:n0})})})})})}function x1t(e){const{openOnInputClick:t=!1,value:n,defaultValue:r,onValueChange:i,mode:o="list",itemToStringValue:s,...a}=e,l=(o==="inline"||o==="both")&&!e.readOnly,u=o==="inline"||o==="none",c=n!==void 0,[d,h]=A.useState(r??""),[m,g]=A.useState("");A.useEffect(()=>{(c||!l)&&g("")},[n,c,l]);let b;l&&m!==""?b=m:c?b=n??"":b=d;const v=FOe({locale:a.locale}),w=String((c?n:d)??"").trim(),S=u||a.filter===null?null:a.filter??v.contains;function C(T,O){g(""),c||h(T),i==null||i(T,O)}function E(T,O){var M;(M=e.onItemHighlighted)==null||M.call(e,T,O),O.reason!==Dve&&g(l&&T!=null?Sh(T,s):"")}return y.jsx(v1t,{...a,itemToStringLabel:s,openOnInputClick:t,selectionMode:"none",fillInputOnItemPress:!0,filter:S,filterQuery:o==="both"?w:void 0,autoComplete:o,inputValue:b,defaultInputValue:r,onInputValueChange:C,onItemHighlighted:E})}const w1t="data-popup-side",S1t="data-list-empty",k1t={...G_,...wG,popupSide:e=>e?{[w1t]:e}:null,listEmpty:e=>e?{[S1t]:""}:null};function C1t(e){const t=e.useState("mounted"),n=e.useState("popupSide"),r=e.useState("positionerElement");return t&&r?n:null}function AY(){return aA().filteredItems.length===0}function E1t(e){return e==="rtl"?["ArrowRight","ArrowLeft"]:["ArrowLeft","ArrowRight"]}function HOe(e,t,n){const r=e.context.listRef.current[t];r&&(e.context.selectionEventRef.current=n,r.click(),e.context.selectionEventRef.current=null)}const T1t=A.createContext(void 0);function A1t(){return A.useContext(T1t)}const UOe=A.createContext(void 0);function OY(e){const t=A.useContext(UOe);if(t===void 0&&!e)throw new Error(Br(21));return t}const VOe=A.forwardRef(function(t,n){const r=Bd(),{buttonRef:i,getButtonProps:o}=Kh({native:!1}),s=uu(n,i);function a(u){r.context.setOpen(!1,Et(Pve,u.nativeEvent,u.currentTarget))}const l=o({onClick:a});return y.jsx("span",{ref:s,...l,"aria-label":"Dismiss",tabIndex:void 0,style:bP})}),O1t=A.forwardRef(function(t,n){const{render:r,className:i,disabled:o=!1,id:s,style:a,...l}=t,{state:u,disabled:c,setTouched:d,validationMode:h,validation:m}=Mb(),{labelId:g}=IP(),b=A1t(),w=!!OY(!0),S=Bd(),C=d1t(),E=Ww(),T=S.useState("required"),O=S.useState("disabled"),M=S.useState("readOnly"),N=S.useState("name"),I=S.useState("form"),D=S.useState("selectionMode"),P=S.useState("autoHighlight"),F=S.useState("inputProps"),z=S.useState("triggerProps"),$=S.useState("open"),B=S.useState("mounted"),H=S.useState("selectedValue"),U=S.useState("id"),W=S.useState("inline"),q=S.useState("modal"),Y=!!P,Q=C1t(S),G=c||O||o,le=AY(),K=TG(G,S.context.inputRef),te=w||W,de=!te||q,ue=Ca(s??(te?void 0:U)),ae=w?D1e:u,[ie,he]=A.useState(null),fe=A.useRef(!1),se=A.useRef(null);et(()=>{$||(se.current=null)},[$]);const Se=D==="none"&&!w,pe=at(ge=>{const $e=w||S.state.inline;$e&&!S.state.hasInputValue&&S.context.setInputValue("",Et(ki)),S.update({inputElement:ge,inputInsidePopup:$e,inputOwnsFormValue:Se})}),Ee=w?l:m.getValidationProps(G,l);function ke(ge){S.context.setIndices({activeIndex:null,selectedIndex:null,type:EY(ge),event:ge})}const Ie={...ae,open:$,disabled:G,readOnly:M,popupSide:Q,listEmpty:le};function Be(ge){if(!b)return;let $e;const Ye=b.chipsRef.current.length,[tt]=E1t(E);return ge.key===tt&&(ge.currentTarget.selectionStart??0)===0&&H.length>0&&(ge.preventDefault(),$e=Ye>0?Ye-1:void 0),$e}const Oe=$n("input",t,{state:Ie,ref:[n,S.context.inputRef,pe],props:[F,z,{value:ie??C,"aria-readonly":M||void 0,"aria-required":T||void 0,"aria-labelledby":g,disabled:G,readOnly:M,required:D==="none"?T:void 0,form:I,...Se&&N&&{name:N},id:ue,onFocus(){if(K(!0),!W)return;const ge=se.current;se.current=null,!(ge==null||!Object.hasOwn(S.context.valuesRef.current,ge))&&S.context.setIndices({activeIndex:ge})},onBlur(){d(!0),K(!1);const ge=S.state.activeIndex;if(W&&ge!==null&&P!=="always"&&(se.current=ge,S.context.setIndices({activeIndex:null})),h==="onBlur"){const $e=D==="none"?C:H;m.commit($e)}},onCompositionStart(ge){q_||(fe.current=!0,he(ge.currentTarget.value))},onCompositionEnd(ge){fe.current=!1;const $e=ge.currentTarget.value;he(null),S.context.setInputValue($e,Et(A1,ge.nativeEvent))},onChange(ge){const $e=ge.nativeEvent,Ye=$e.inputType,tt=!Ye||Ye==="insertReplacementText",Ae=fe.current||!tt;function _e(gt){M||G||!gt||!Ae||(S.context.setOpen(!0,Et(A1,$e)),Y||ke($e))}if(fe.current){const gt=ge.currentTarget.value;he(gt),gt===""&&!S.state.openOnInputClick&&!S.state.inputInsidePopup&&S.context.setOpen(!1,Et(Lc,$e));const rt=gt.trim(),xt=Y&&rt!=="";_e(rt),$&&S.state.activeIndex!==null&&!xt&&ke($e);return}const He=Et(A1,$e);if(S.context.setInputValue(ge.currentTarget.value,He),He.isCanceled)return;const Ue=ge.currentTarget.value==="",Ve=Et(Lc,$e);Ue&&!S.state.inputInsidePopup&&(D==="single"&&S.context.setSelectedValue(null,Ve),S.state.openOnInputClick||S.context.setOpen(!1,Ve)),_e(ge.currentTarget.value.trim()),$&&S.state.activeIndex!==null&&!Y&&ke($e)},onKeyDown(ge){var _e;if(ge.ctrlKey||ge.shiftKey||ge.altKey||ge.metaKey)return;if(G||M){M&&ge.key==="Enter"&&$&&S.state.activeIndex!==null&&No(ge);return}const $e=ge.currentTarget,Ye=$e.scrollWidth-$e.clientWidth,tt=E==="rtl";if(ge.key==="Home"){No(ge);const He=$ne&&tt?$e.value.length:0;$e.setSelectionRange(He,He),$e.scrollLeft=0;return}if(ge.key==="End"){No(ge);const He=$ne&&tt?0:$e.value.length;$e.setSelectionRange(He,He),$e.scrollLeft=tt?-Ye:Ye;return}if(!B&&ge.key==="Escape"){const He=D==="multiple"&&Array.isArray(H)?H.length===0:H===null,Ue=Et(Vw,ge.nativeEvent),Ve=D==="multiple"?[]:null;S.context.setInputValue("",Ue),S.context.setSelectedValue(Ve,Ue),!He&&!S.state.inline&&!Ue.isPropagationAllowed&&ge.stopPropagation();return}if(b&&ge.key==="Backspace"&&$e.value===""&&Array.isArray(H)&&H.length>0){const He=b.chipsRef.current.length,Ue=He>0?He-1:H.length-1,Ve=H.filter((gt,rt)=>rt!==Ue);ke(ge.nativeEvent),S.context.setSelectedValue(Ve,Et(ki,ge.nativeEvent));return}const Ae=Be(ge);if(Ae!==void 0&&((_e=b==null?void 0:b.chipsRef.current[Ae])==null||_e.focus()),ge.which!==229&&ge.key==="Enter"&&$){const He=S.state.activeIndex,Ue=ge.nativeEvent;if(He===null){if(W)return;S.context.setOpen(!1,Et(ki,Ue));return}No(ge),HOe(S,He,Ue)}}},Ee],stateAttributesMapping:k1t}),Le=w?y.jsx(z1e.Provider,{value:$1e,children:Oe}):Oe;return y.jsxs(A.Fragment,{children:[$&&de&&y.jsx(VOe,{ref:S.context.startDismissRef}),Le]})}),R1t=A.forwardRef(function(t,n){const{render:r,className:i,style:o,...s}=t;return $n("span",t,{ref:n,props:[{"aria-hidden":!0,children:"▼"},s]})}),M1t=A.createContext(null);function _1t(){return A.useContext(M1t)}function N1t(e){const{children:t}=e,{filteredItems:n}=aA(),r=_1t(),i=r?r.items:n;return y.jsx(A.Fragment,{children:i.map(t)})}const L1t=A.forwardRef(function(t,n){var r;const{render:i,className:o,style:s,children:a,...l}=t,u=Bd(),c=TY(),d=!!OY(!0),{filteredItems:h,hasItems:m}=aA(),g=u.useState("selectionMode"),b=u.useState("grid"),v=u.useState("readOnly"),w=u.useState("listProps"),S=u.useState("virtualized"),C=u.useState("forceMounted"),E=g==="multiple",T=h.length===0,O=at(z=>{u.set("positionerElement",z)}),M=at(z=>{u.set("listElement",z)}),N=A.useMemo(()=>typeof a=="function"?r||(r=y.jsx(N1t,{children:a})):a,[a]),I={empty:T},D=c.useState("floatingId"),P=$n("div",t,{state:I,ref:[n,M,d?null:O],props:[w,{children:N,tabIndex:-1,id:D,role:b?"grid":"listbox","aria-multiselectable":E?"true":void 0,"aria-readonly":!b&&v?!0:void 0,onKeyDown(z){if(!(u.state.disabled||u.state.readOnly)&&z.key==="Enter"){const $=u.state.activeIndex;if($==null)return;No(z),HOe(u,$,z.nativeEvent)}}},l]});if(S)return P;const F=m&&!C?void 0:u.context.labelsRef;return y.jsx(_2,{elementsRef:u.context.listRef,labelsRef:F,children:P})}),I1t="⁠",P1t=200;function j1t(e){const t=e.ownerDocument.createTreeWalker(e,NodeFilter.SHOW_TEXT);let n=null;for(;t.nextNode();){const r=t.currentNode;r.nodeValue!==""&&(n=r)}return n}function D1t(e=!0){const t=Qi(),n=A.useRef(null);return A.useEffect(()=>{if(!e||k2)return;const r=n.current;if(r==null)return;const i=j1t(r);if(i==null)return;const o=i.data,s=`${o}${I1t}`;return i.nodeValue=s,t.start(P1t,()=>{i.nodeValue===s&&(i.nodeValue=o)}),()=>{t.clear(),i.nodeValue===s&&(i.nodeValue=o)}},[e,n,t]),n}const WOe=A.createContext(void 0);function $1t(){const e=A.useContext(WOe);if(e===void 0)throw new Error(Br(20));return e}const z1t=A.forwardRef(function(t,n){const{keepMounted:r=!1,...i}=t,o=Bd(),s=o.useState("mounted"),a=o.useState("forceMounted");return s||r||a?y.jsx(WOe.Provider,{value:r,children:y.jsx(OP,{ref:n,...i})}):null}),F1t=A.forwardRef(function(t,n){const{render:r,className:i,anchor:o,positionMethod:s,side:a,align:l,sideOffset:u,alignOffset:c,collisionBoundary:d="clipping-ancestors",collisionPadding:h,arrowPadding:m,sticky:g,disableAnchorTracking:b=!1,collisionAvoidance:v=iG,style:w,...S}=t,C=Bd(),E=TY(),T=$1t(),O=C.useState("modal"),M=C.useState("open"),N=C.useState("mounted"),I=C.useState("openMethod"),D=C.useState("positionerElement"),P=C.useState("triggerElement"),F=C.useState("inputElement"),z=C.useState("inputGroupElement"),$=C.useState("inputInsidePopup"),B=C.useState("transitionStatus"),H=AY(),W=$P({anchor:o??($?P:z??F),floatingRootContext:E,positionMethod:s,mounted:N,side:a,sideOffset:u,align:l,alignOffset:c,arrowPadding:m,collisionBoundary:d,collisionPadding:h,sticky:g,disableAnchorTracking:b,keepMounted:T,collisionAvoidance:v,lazyFlip:!0});AG(M&&O,I==="touch",D,P);const q={open:M,side:W.side,align:W.align,anchorHidden:W.anchorHidden,empty:H};et(()=>{C.set("popupSide",W.side)},[C,W.side]);const Y=at(G=>{C.set("positionerElement",G)}),Q=FP(t,q,{styles:W.positionerStyles,transitionStatus:B,props:S,refs:[n,Y],hidden:!N,inert:!M});return y.jsxs(UOe.Provider,{value:W,children:[N&&O&&y.jsx(zP,{inert:M2(!M),cutout:z??F??P}),Q]})}),B1t={...Hw,...Bw},H1t=A.forwardRef(function(t,n){const{render:r,className:i,style:o,initialFocus:s,finalFocus:a,...l}=t,u=Bd(),c=OY(),d=TY(),h=u.useState("mounted"),m=u.useState("open"),g=u.useState("openMethod"),b=u.useState("popupProps"),v=u.useState("transitionStatus"),w=u.useState("inputInsidePopup"),S=u.useState("inputElement"),C=u.useState("modal"),E=u.useState("id"),T=AY(),O=l.id??(w?p1t(E):void 0);et(()=>{var z;return u.set("popupId",((z=u.context.popupRef.current)==null?void 0:z.id)||O),()=>{u.set("popupId",void 0)}},[u,O]),Ig({open:m,ref:u.context.popupRef,onComplete(){m&&u.context.onOpenChangeComplete(!0)}});const M={open:m,side:c.side,align:c.align,anchorHidden:c.anchorHidden,transitionStatus:v,empty:T},N=$n("div",t,{state:M,ref:[n,u.context.popupRef],props:[b,{id:O,role:w?"dialog":"presentation",onFocus(z){var B;const $=ji(z.nativeEvent);g!=="touch"&&(Rt(u.state.listElement,$)||$===z.currentTarget)&&((B=u.context.inputRef.current)==null||B.focus())}},N2(v),l],stateAttributesMapping:B1t}),D=s===void 0?w?z=>z==="touch"?u.context.popupRef.current:S:!1:s;let P;a!=null?P=a:P=w?void 0:!1;const F=!w||C;return y.jsx(RP,{context:d,disabled:!h,modal:F,openInteractionType:g,initialFocus:D,returnFocus:P,getInsideElements:()=>[u.context.startDismissRef.current,u.context.endDismissRef.current],children:y.jsxs(A.Fragment,{children:[N,F&&y.jsx(VOe,{ref:u.context.endDismissRef})]})})}),U1t=A.createContext(void 0),V1t=A.createContext(!1);function W1t(){return A.useContext(V1t)}function qOe(e){const{componentProps:t,forwardedRef:n,virtualized:r,indexFromFilter:i}=e,{render:o,className:s,style:a,value:l=null,index:u,disabled:c=!1,nativeButton:d=!1,...h}=t,m=A.useRef(null),g=L2({guess:!0,index:u,textRef:m}),b=Bd(),v=W1t(),w=f1t(),{props:S,id:C,selectionMode:E,disabled:T,readOnly:O,isItemEqualToValue:M}=b.useState("itemRoot"),N=T||c,I=E!=="none",D=u??i??g.index,P=D!==-1,F=b.useState("isActive",D),z=b.useState("isSelected",l),$=A.useRef(null),B=C!=null&&P?`${C}-${D}`:void 0,H=z&&I;et(()=>{if(!(P&&(r||u!=null)))return;const te=b.context.listRef.current;return te[D]=$.current,()=>{delete te[D]}},[P,r,D,u,b]),et(()=>{if(!P||w)return;const K=b.context.valuesRef.current;return K[D]=l,()=>{delete K[D]}},[P,w,D,l,b]),et(()=>{if(!P||w)return;const K=b.state.selectedValue;let te=b.state.selectedIndex;b.state.selectionMode==="multiple"&&Array.isArray(K)?te=B1e(D,l,b.context.valuesRef.current,K,M,te):cu(l,K,M)&&(te=D),b.set("selectedIndex",te)},[P,w,b,D,l,M]);const{getButtonProps:U,buttonRef:W}=Kh({disabled:N,focusableWhenDisabled:!0,native:d,composite:!0}),q={disabled:N,selected:H,highlighted:F};function Y(K){function te(){b.context.handleSelection(K,l)}b.state.submitOnItemClick?(mi.flushSync(te),b.context.requestSubmit()):te()}const Q={id:B,role:v?"gridcell":"option","aria-selected":I?H:void 0,tabIndex:void 0,onPointerDownCapture(K){K.isPrimary&&(b.context.pointerDownItemRef.current=K.currentTarget),K.preventDefault()},onMouseDown(K){K.preventDefault()},onClick(K){N||O||Y(K.nativeEvent)},onMouseUp(K){const te=b.context.pointerDownItemRef.current===K.currentTarget;b.context.pointerDownItemRef.current=null,!(N||O||K.button!==0||te||!F)&&Y(K.nativeEvent)}},G=$n("div",t,{ref:[W,n,g.ref,$],state:q,props:[S,Q,h,U]}),le=A.useMemo(()=>({selected:H,textRef:m}),[H,m]);return y.jsx(U1t.Provider,{value:le,children:G})}function q1t(e){const{componentProps:t,forwardedRef:n}=e,i=Bd().useState("isItemEqualToValue"),{flatFilteredValues:o}=aA(),s=t.value??null,a=_1(o,s,i);return y.jsx(qOe,{componentProps:t,forwardedRef:n,virtualized:!0,indexFromFilter:a})}const G1t=A.memo(A.forwardRef(function(t,n){const i=Bd().useState("virtualized");return i&&t.index==null?y.jsx(q1t,{componentProps:t,forwardedRef:n}):y.jsx(qOe,{componentProps:t,forwardedRef:n,virtualized:i,indexFromFilter:void 0})})),K1t=G1t,Y1t=A.forwardRef(function(t,n){const{render:r,className:i,style:o,children:s,...a}=t,{filteredItems:l}=aA(),u=Bd(),c=D1t(),d=l.length===0?s:null;return $n("div",t,{ref:[n,u.context.emptyRef,c],props:[{children:d,role:"status","aria-live":"polite","aria-atomic":!0},a]})}),X1t=X("w-full rounded-md border py-1.5 pl-2 pr-7 text-xs outline-none","border-zinc-200 bg-white text-zinc-900 placeholder:text-zinc-400","dark:border-zinc-800 dark:bg-zinc-900 dark:text-zinc-100 dark:placeholder:text-zinc-600","focus-visible:border-sky-500 focus-visible:ring-2 focus-visible:ring-sky-500/15","disabled:opacity-40");function Q1t({value:e,onValueChange:t,onSelect:n,options:r,emptyMessage:i="Nothing here matches that.",placeholder:o,disabled:s,ariaLabel:a,className:l}){const[u,c]=A.useState(void 0),d=u===void 0?r:r.filter(h=>Z1t(h,u));return y.jsxs(x1t,{items:d,filteredItems:d,value:e,onValueChange:(h,m)=>{m.reason!=="item-press"&&(c(h),t(h))},onOpenChange:()=>c(void 0),openOnInputClick:!0,disabled:s,children:[y.jsxs("div",{className:X("relative",l),children:[y.jsx(O1t,{"aria-label":a,placeholder:o,spellCheck:!1,className:X1t}),y.jsx(R1t,{className:"pointer-events-none absolute inset-y-0 right-2 flex items-center",children:y.jsx(Eq,{size:12,className:"shrink-0 text-zinc-400"})})]}),y.jsx(z1t,{children:y.jsx(F1t,{sideOffset:4,className:"z-50",children:y.jsxs(H1t,{className:X("max-h-72 w-[var(--anchor-width)] overflow-y-auto rounded-md border p-1 shadow-md","border-zinc-200 bg-white dark:border-zinc-800 dark:bg-zinc-900","origin-[var(--transform-origin)] transition-[opacity,transform] duration-100 ease-out","data-[starting-style]:scale-95 data-[starting-style]:opacity-0","data-[ending-style]:scale-95 data-[ending-style]:opacity-0","motion-reduce:transition-none motion-reduce:data-[starting-style]:scale-100 motion-reduce:data-[ending-style]:scale-100"),children:[y.jsx(Y1t,{className:"px-2 py-1.5 text-[11px] leading-relaxed text-zinc-400 dark:text-zinc-500",children:d.length===0?i:null}),y.jsx(L1t,{children:d.map(h=>y.jsxs(K1t,{value:h,disabled:h.disabled,onClick:()=>{h.disabled||n==null||n(h)},className:X("flex cursor-default items-start gap-2 rounded-sm px-2 py-1.5 text-xs outline-none","data-[highlighted]:bg-zinc-100 dark:data-[highlighted]:bg-zinc-800","data-[disabled]:opacity-40"),children:[y.jsx("span",{className:"mt-0.5 w-3 shrink-0",children:h.value===e&&!h.disabled&&y.jsx(aP,{size:11,className:"text-sky-600"})}),y.jsxs("span",{className:"min-w-0 flex-1",children:[y.jsx("span",{className:"block truncate",title:h.label,children:h.label}),h.hint&&y.jsx("span",{className:"mt-0.5 block truncate font-mono text-[10px] text-zinc-400 dark:text-zinc-500",children:h.hint})]})]},h.value))})]})})})]})}function Z1t(e,t){const n=t.trim().toLowerCase();return n.length===0?!0:`${e.label} ${e.keywords??""}`.toLowerCase().includes(n)}function Ple({label:e,hint:t,...n}){return y.jsxs("label",{className:"block",children:[y.jsx("span",{className:"mb-1 block font-mono text-[10px] uppercase tracking-[0.14em] text-zinc-400 dark:text-zinc-500",children:e}),y.jsx(Q1t,{...n}),t&&y.jsx("span",{className:"mt-1 block text-[11px] leading-relaxed text-zinc-400 dark:text-zinc-500",children:t})]})}function Gr(e){return function(){return e}}const GOe=Math.cos,BL=Math.sin,lc=Math.sqrt,HL=Math.PI,$j=2*HL,QU=Math.PI,ZU=2*QU,$0=1e-6,J1t=ZU-$0;function KOe(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function ext(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return KOe;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 txt{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?KOe:ext(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,s){this._append`C${+t},${+n},${+r},${+i},${this._x1=+o},${this._y1=+s}`}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 s=this._x1,a=this._y1,l=r-t,u=i-n,c=s-t,d=a-n,h=c*c+d*d;if(this._x1===null)this._append`M${this._x1=t},${this._y1=n}`;else if(h>$0)if(!(Math.abs(d*l-u*c)>$0)||!o)this._append`L${this._x1=t},${this._y1=n}`;else{let m=r-s,g=i-a,b=l*l+u*u,v=m*m+g*g,w=Math.sqrt(b),S=Math.sqrt(h),C=o*Math.tan((QU-Math.acos((b+h-v)/(2*w*S)))/2),E=C/S,T=C/w;Math.abs(E-1)>$0&&this._append`L${t+E*c},${n+E*d}`,this._append`A${o},${o},0,0,${+(d*m>c*g)},${this._x1=t+T*l},${this._y1=n+T*u}`}}arc(t,n,r,i,o,s){if(t=+t,n=+n,r=+r,s=!!s,r<0)throw new Error(`negative radius: ${r}`);let a=r*Math.cos(i),l=r*Math.sin(i),u=t+a,c=n+l,d=1^s,h=s?i-o:o-i;this._x1===null?this._append`M${u},${c}`:(Math.abs(this._x1-u)>$0||Math.abs(this._y1-c)>$0)&&this._append`L${u},${c}`,r&&(h<0&&(h=h%ZU+ZU),h>J1t?this._append`A${r},${r},0,1,${d},${t-a},${n-l}A${r},${r},0,1,${d},${this._x1=u},${this._y1=c}`:h>$0&&this._append`A${r},${r},0,${+(h>=QU)},${d},${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 RY(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 txt(t)}function MY(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function YOe(e){this._context=e}YOe.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 zj(e){return new YOe(e)}function XOe(e){return e[0]}function QOe(e){return e[1]}function Fj(e,t){var n=Gr(!0),r=null,i=zj,o=null,s=RY(a);e=typeof e=="function"?e:e===void 0?XOe:Gr(e),t=typeof t=="function"?t:t===void 0?QOe:Gr(t);function a(l){var u,c=(l=MY(l)).length,d,h=!1,m;for(r==null&&(o=i(m=s())),u=0;u<=c;++u)!(u<c&&n(d=l[u],u,l))===h&&((h=!h)?o.lineStart():o.lineEnd()),h&&o.point(+e(d,u,l),+t(d,u,l));if(m)return o=null,m+""||null}return a.x=function(l){return arguments.length?(e=typeof l=="function"?l:Gr(+l),a):e},a.y=function(l){return arguments.length?(t=typeof l=="function"?l:Gr(+l),a):t},a.defined=function(l){return arguments.length?(n=typeof l=="function"?l:Gr(!!l),a):n},a.curve=function(l){return arguments.length?(i=l,r!=null&&(o=i(r)),a):i},a.context=function(l){return arguments.length?(l==null?r=o=null:o=i(r=l),a):r},a}function dC(e,t,n){var r=null,i=Gr(!0),o=null,s=zj,a=null,l=RY(u);e=typeof e=="function"?e:e===void 0?XOe:Gr(+e),t=typeof t=="function"?t:Gr(t===void 0?0:+t),n=typeof n=="function"?n:n===void 0?QOe:Gr(+n);function u(d){var h,m,g,b=(d=MY(d)).length,v,w=!1,S,C=new Array(b),E=new Array(b);for(o==null&&(a=s(S=l())),h=0;h<=b;++h){if(!(h<b&&i(v=d[h],h,d))===w)if(w=!w)m=h,a.areaStart(),a.lineStart();else{for(a.lineEnd(),a.lineStart(),g=h-1;g>=m;--g)a.point(C[g],E[g]);a.lineEnd(),a.areaEnd()}w&&(C[h]=+e(v,h,d),E[h]=+t(v,h,d),a.point(r?+r(v,h,d):C[h],n?+n(v,h,d):E[h]))}if(S)return a=null,S+""||null}function c(){return Fj().defined(i).curve(s).context(o)}return u.x=function(d){return arguments.length?(e=typeof d=="function"?d:Gr(+d),r=null,u):e},u.x0=function(d){return arguments.length?(e=typeof d=="function"?d:Gr(+d),u):e},u.x1=function(d){return arguments.length?(r=d==null?null:typeof d=="function"?d:Gr(+d),u):r},u.y=function(d){return arguments.length?(t=typeof d=="function"?d:Gr(+d),n=null,u):t},u.y0=function(d){return arguments.length?(t=typeof d=="function"?d:Gr(+d),u):t},u.y1=function(d){return arguments.length?(n=d==null?null:typeof d=="function"?d:Gr(+d),u):n},u.lineX0=u.lineY0=function(){return c().x(e).y(t)},u.lineY1=function(){return c().x(e).y(n)},u.lineX1=function(){return c().x(r).y(t)},u.defined=function(d){return arguments.length?(i=typeof d=="function"?d:Gr(!!d),u):i},u.curve=function(d){return arguments.length?(s=d,o!=null&&(a=s(o)),u):s},u.context=function(d){return arguments.length?(d==null?o=a=null:a=s(o=d),u):o},u}class ZOe{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 nxt(e){return new ZOe(e,!0)}function rxt(e){return new ZOe(e,!1)}const _Y={draw(e,t){const n=lc(t/HL);e.moveTo(n,0),e.arc(0,0,n,0,$j)}},ixt={draw(e,t){const n=lc(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()}},JOe=lc(1/3),oxt=JOe*2,sxt={draw(e,t){const n=lc(t/oxt),r=n*JOe;e.moveTo(0,-n),e.lineTo(r,0),e.lineTo(0,n),e.lineTo(-r,0),e.closePath()}},axt={draw(e,t){const n=lc(t),r=-n/2;e.rect(r,r,n,n)}},lxt=.8908130915292852,eRe=BL(HL/10)/BL(7*HL/10),uxt=BL($j/10)*eRe,cxt=-GOe($j/10)*eRe,dxt={draw(e,t){const n=lc(t*lxt),r=uxt*n,i=cxt*n;e.moveTo(0,-n),e.lineTo(r,i);for(let o=1;o<5;++o){const s=$j*o/5,a=GOe(s),l=BL(s);e.lineTo(l*n,-a*n),e.lineTo(a*r-l*i,l*r+a*i)}e.closePath()}},k8=lc(3),fxt={draw(e,t){const n=-lc(t/(k8*3));e.moveTo(0,n*2),e.lineTo(-k8*n,-n),e.lineTo(k8*n,-n),e.closePath()}},Ol=-.5,Rl=lc(3)/2,JU=1/lc(12),hxt=(JU/2+1)*3,pxt={draw(e,t){const n=lc(t/hxt),r=n/2,i=n*JU,o=r,s=n*JU+n,a=-o,l=s;e.moveTo(r,i),e.lineTo(o,s),e.lineTo(a,l),e.lineTo(Ol*r-Rl*i,Rl*r+Ol*i),e.lineTo(Ol*o-Rl*s,Rl*o+Ol*s),e.lineTo(Ol*a-Rl*l,Rl*a+Ol*l),e.lineTo(Ol*r+Rl*i,Ol*i-Rl*r),e.lineTo(Ol*o+Rl*s,Ol*s-Rl*o),e.lineTo(Ol*a+Rl*l,Ol*l-Rl*a),e.closePath()}};function mxt(e,t){let n=null,r=RY(i);e=typeof e=="function"?e:Gr(e||_Y),t=typeof t=="function"?t:Gr(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:Gr(o),i):e},i.size=function(o){return arguments.length?(t=typeof o=="function"?o:Gr(+o),i):t},i.context=function(o){return arguments.length?(n=o??null,i):n},i}function UL(){}function VL(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 tRe(e){this._context=e}tRe.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:VL(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:VL(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function gxt(e){return new tRe(e)}function nRe(e){this._context=e}nRe.prototype={areaStart:UL,areaEnd:UL,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:VL(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function yxt(e){return new nRe(e)}function rRe(e){this._context=e}rRe.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:VL(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function bxt(e){return new rRe(e)}function iRe(e){this._context=e}iRe.prototype={areaStart:UL,areaEnd:UL,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 vxt(e){return new iRe(e)}function jle(e){return e<0?-1:1}function Dle(e,t,n){var r=e._x1-e._x0,i=t-e._x1,o=(e._y1-e._y0)/(r||i<0&&-0),s=(n-e._y1)/(i||r<0&&-0),a=(o*i+s*r)/(r+i);return(jle(o)+jle(s))*Math.min(Math.abs(o),Math.abs(s),.5*Math.abs(a))||0}function $le(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function C8(e,t,n){var r=e._x0,i=e._y0,o=e._x1,s=e._y1,a=(o-r)/3;e._context.bezierCurveTo(r+a,i+a*t,o-a,s-a*n,o,s)}function WL(e){this._context=e}WL.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:C8(this,this._t0,$le(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,C8(this,$le(this,n=Dle(this,e,t)),n);break;default:C8(this,this._t0,n=Dle(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function oRe(e){this._context=new sRe(e)}(oRe.prototype=Object.create(WL.prototype)).point=function(e,t){WL.prototype.point.call(this,t,e)};function sRe(e){this._context=e}sRe.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 NY(e){return new WL(e)}function xxt(e){return new oRe(e)}function aRe(e){this._context=e}aRe.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=zle(e),i=zle(t),o=0,s=1;s<n;++o,++s)this._context.bezierCurveTo(r[0][o],i[0][o],r[1][o],i[1][o],e[s],t[s]);(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 zle(e){var t,n=e.length-1,r,i=new Array(n),o=new Array(n),s=new Array(n);for(i[0]=0,o[0]=2,s[0]=e[0]+2*e[1],t=1;t<n-1;++t)i[t]=1,o[t]=4,s[t]=4*e[t]+2*e[t+1];for(i[n-1]=2,o[n-1]=7,s[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)r=i[t]/o[t-1],o[t]-=r,s[t]-=r*s[t-1];for(i[n-1]=s[n-1]/o[n-1],t=n-2;t>=0;--t)i[t]=(s[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 lRe(e){return new aRe(e)}function Bj(e,t){this._context=e,this._t=t}Bj.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 wxt(e){return new Bj(e,.5)}function Sxt(e){return new Bj(e,0)}function kxt(e){return new Bj(e,1)}function Zx(e,t){if((s=e.length)>1)for(var n=1,r,i,o=e[t[0]],s,a=o.length;n<s;++n)for(i=o,o=e[t[n]],r=0;r<a;++r)o[r][1]+=o[r][0]=isNaN(i[r][1])?i[r][0]:i[r][1]}function eV(e){for(var t=e.length,n=new Array(t);--t>=0;)n[t]=t;return n}function Cxt(e,t){return e[t]}function Ext(e){const t=[];return t.key=e,t}function Txt(){var e=Gr([]),t=eV,n=Zx,r=Cxt;function i(o){var s=Array.from(e.apply(this,arguments),Ext),a,l=s.length,u=-1,c;for(const d of o)for(a=0,++u;a<l;++a)(s[a][u]=[0,+r(d,s[a].key,u,o)]).data=d;for(a=0,c=MY(t(s));a<l;++a)s[c[a]].index=a;return n(s,c),s}return i.keys=function(o){return arguments.length?(e=typeof o=="function"?o:Gr(Array.from(o)),i):e},i.value=function(o){return arguments.length?(r=typeof o=="function"?o:Gr(+o),i):r},i.order=function(o){return arguments.length?(t=o==null?eV:typeof o=="function"?o:Gr(Array.from(o)),i):t},i.offset=function(o){return arguments.length?(n=o??Zx,i):n},i}function Axt(e,t){if((r=e.length)>0){for(var n,r,i=0,o=e[0].length,s;i<o;++i){for(s=n=0;n<r;++n)s+=e[n][i][1]||0;if(s)for(n=0;n<r;++n)e[n][i][1]/=s}Zx(e,t)}}function Oxt(e,t){if((i=e.length)>0){for(var n=0,r=e[t[0]],i,o=r.length;n<o;++n){for(var s=0,a=0;s<i;++s)a+=e[s][n][1]||0;r[n][1]+=r[n][0]=-a/2}Zx(e,t)}}function Rxt(e,t){if(!(!((s=e.length)>0)||!((o=(i=e[t[0]]).length)>0))){for(var n=0,r=1,i,o,s;r<o;++r){for(var a=0,l=0,u=0;a<s;++a){for(var c=e[t[a]],d=c[r][1]||0,h=c[r-1][1]||0,m=(d-h)/2,g=0;g<a;++g){var b=e[t[g]],v=b[r][1]||0,w=b[r-1][1]||0;m+=v-w}l+=d,u+=m*d}i[r-1][1]+=i[r-1][0]=n,l&&(n-=u/l)}i[r-1][1]+=i[r-1][0]=n,Zx(e,t)}}var E8={exports:{}};/*!
2832
+ ${JSON.stringify(e,null,2)}`})]})}const As="text-zinc-400 dark:text-zinc-500",Cg="border-zinc-200 dark:border-zinc-800",sA="bg-white dark:bg-zinc-900";function jvt({value:e,onChange:t}){return y.jsxs("label",{className:"mt-3 block",children:[y.jsx("span",{className:"sr-only",children:"Search people"}),y.jsx("input",{type:"search",value:e,onChange:n=>t(n.target.value),placeholder:"Search by name or email",className:X("w-full rounded-md border px-3 py-1.5 text-sm",Cg,sA,"placeholder:text-zinc-400 dark:placeholder:text-zinc-600")})]})}function Dvt({page:e,onOffset:t,busy:n}){const r=e.people.length,i=e.total===0?0:e.offset+1,o=e.offset+r,s=o<e.total;return y.jsxs("div",{className:X("mt-3 flex items-center justify-between text-xs",As),children:[y.jsx("span",{children:e.total===0?"No people":`Showing ${i}–${o} of ${e.total.toLocaleString()}`}),(e.offset>0||s)&&y.jsxs("span",{className:"flex gap-2",children:[y.jsx("button",{type:"button",disabled:e.offset===0||n,onClick:()=>t(Math.max(0,e.offset-e.limit)),className:"disabled:opacity-40",children:"Previous"}),y.jsx("button",{type:"button",disabled:!s||n,onClick:()=>t(e.offset+e.limit),className:"disabled:opacity-40",children:"Next"})]})]})}function $vt({identity:e,onSignOut:t,signOutPending:n,canAddPeople:r,title:i="Access",eyebrow:o="Governance",intro:s="Two kinds of caller reach this catalog. Applications hold keys and act on their own behalf. People sign in and act through an application, and can never do more than both of them may."}){var b,v,w,S;const a=Sr(),l=Cn({queryKey:rn.principals,queryFn:()=>a.listPrincipals(),staleTime:3e4}),[u,c]=A.useState(""),[d,h]=A.useState(0),m=Cn({queryKey:[...rn.people,{search:u,offset:d}],queryFn:()=>a.listPeople({...u?{search:u}:{},offset:d}),staleTime:3e4,placeholderData:C=>C}),g=r??(e==null?void 0:e.scopes.includes("catalog:admin"))??!1;return y.jsx(Qh,{children:y.jsxs("div",{className:"mx-auto max-w-5xl px-8 py-8",children:[y.jsx("p",{className:X("font-mono text-[11px] uppercase tracking-[0.18em]",As),children:o}),y.jsx("h1",{className:"mt-1 text-2xl font-semibold tracking-tight",children:i}),y.jsx("p",{className:"mt-1 max-w-2xl text-sm text-zinc-500 dark:text-zinc-400",children:s}),e&&y.jsx(zvt,{identity:e,onSignOut:t,signOutPending:n}),y.jsxs(Nle,{title:"People",note:"Sign in to the console. Capped by the application they sign in through.",children:[y.jsx(jvt,{value:u,onChange:C=>{c(C),h(0)}}),g&&y.jsx(Uvt,{}),m.isPending&&y.jsx(xk,{children:"Reading people…"}),m.isError&&y.jsx(Lle,{message:m.error instanceof Error?m.error.message:"Could not read the people list.",onRetry:()=>m.refetch()}),(b=m.data)==null?void 0:b.people.map(C=>y.jsx(Fvt,{person:C},C.email)),((v=m.data)==null?void 0:v.people.length)===0&&(u?y.jsxs(xk,{children:["Nobody matches “",u,"”."]}):y.jsx(xk,{children:"Nobody can sign in yet. Seed the first administrator from the environment before anybody can reach this console as a person."})),m.data&&y.jsx(Dvt,{page:m.data,onOffset:h,busy:m.isFetching})]}),y.jsxs(Nle,{title:"Applications",note:"Provisioned by an operator — a console that could hand grants out is one that stops leaving a trail.",children:[l.isPending&&y.jsx(xk,{children:"Reading applications…"}),l.isError&&y.jsx(Lle,{message:l.error instanceof Error?l.error.message:"Could not read the application list.",onRetry:()=>l.refetch()}),(w=l.data)==null?void 0:w.map(C=>y.jsx(Wvt,{principal:C},C.id)),((S=l.data)==null?void 0:S.length)===0&&y.jsx(xk,{children:"No applications are provisioned."})]})]})})}function zvt({identity:e,onSignOut:t,signOutPending:n}){const r=e.actor===null;return y.jsxs("div",{className:X("mt-6 rounded-lg border p-4",sA,r?"border-amber-500/40":Cg),children:[y.jsxs("div",{className:"flex flex-wrap items-start justify-between gap-3",children:[y.jsxs("div",{className:"min-w-0",children:[y.jsx("div",{className:X("font-mono text-[10px] uppercase tracking-[0.14em]",As),children:r?"Acting as an application":"Signed in"}),y.jsxs("div",{className:"mt-1 flex items-center gap-2 text-sm font-medium",children:[r?y.jsx(cP,{size:14}):y.jsx(v$e,{size:14}),e.displayName]}),y.jsxs("div",{className:X("mt-1 font-mono text-[11px]",As),children:["recorded as ",e.principalId]}),r&&y.jsx("p",{className:"mt-2 max-w-md text-xs text-amber-600",children:"Nothing you do here will name you. This is the application-key path, kept for local development — sign in to be attributable."})]}),y.jsxs("div",{className:"flex items-center gap-4",children:[e.session&&y.jsxs("span",{className:X("font-mono text-[11px]",As),children:["expires ",new Date(e.session.expiresAt).toLocaleTimeString()," · idle"," ",e.session.idleMinutes,"m"]}),!r&&t&&y.jsxs("button",{type:"button",onClick:t,disabled:n,className:X("flex items-center gap-1.5 rounded-md border px-3 py-1.5 text-xs disabled:opacity-40",Cg,"hover:bg-zinc-50 dark:hover:bg-zinc-800"),children:[y.jsx(M8e,{size:13}),n?"Signing out…":"Sign out"]})]})]}),y.jsxs("div",{className:"mt-4 grid gap-3 sm:grid-cols-2 lg:grid-cols-4",children:[y.jsx(ol,{label:"Effective scopes",values:e.scopes,tone:"neutral"}),y.jsx(ol,{label:"May write",values:e.writeTypes,tone:"write",emptyNote:"nothing"}),y.jsx(ol,{label:"May read",values:e.readTypes??["every type"],tone:"neutral"}),y.jsx(ol,{label:"May see",values:e.classifications,tone:"classified",emptyNote:"nothing classified"})]})]})}function Fvt({person:e}){return y.jsxs("div",{className:X("rounded-lg border p-4",Cg,sA),children:[y.jsxs("div",{className:"flex flex-wrap items-start justify-between gap-3",children:[y.jsxs("div",{className:"min-w-0",children:[y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx("span",{className:"text-sm font-medium",children:e.displayName}),y.jsx("span",{className:"rounded-sm bg-zinc-100 px-1.5 py-0.5 font-mono text-[10px] uppercase text-zinc-500 dark:bg-zinc-800",children:e.role}),!e.active&&y.jsx("span",{className:"rounded-sm bg-red-100 px-1.5 py-0.5 font-mono text-[10px] uppercase text-red-600 dark:bg-red-950",children:"disabled"})]}),y.jsx("div",{className:X("mt-0.5 font-mono text-[11px]",As),children:e.principalId})]}),y.jsxs("div",{className:X("flex items-center gap-4 font-mono text-[11px]",As),children:[y.jsx(kt,{content:"Sessions currently alive — not expired, not idled out, not revoked.",children:y.jsxs("span",{className:"cursor-help",children:[e.liveSessions," live"]})}),y.jsx("span",{children:e.lastLoginAt?`last in ${new Date(e.lastLoginAt).toLocaleString()}`:"never signed in"})]})]}),y.jsxs("div",{className:"mt-4 grid gap-3 sm:grid-cols-2 lg:grid-cols-4",children:[y.jsx(ol,{label:"Effective scopes",values:e.effective.scopes,tone:"neutral",emptyNote:"nothing"}),y.jsx(ol,{label:"May write",values:e.effective.writeTypes,tone:"write",emptyNote:"nothing"}),y.jsx(ol,{label:"May read",values:e.effective.readTypes??["every type"],tone:"neutral"}),y.jsx(ol,{label:"May see",values:e.effective.classifications,tone:"classified",emptyNote:"nothing classified"})]})]})}const Bvt=[{value:"viewer",label:"viewer",hint:"read"},{value:"curator",label:"curator",hint:"read, curate"},{value:"admin",label:"admin",hint:"read, curate, administer"}];function Hvt(e){return e==="curator"||e==="admin"?e:"viewer"}function Uvt(){const e=Sr(),t=ra(),[n,r]=A.useState(!1),[i,o]=A.useState(""),[s,a]=A.useState(""),[l,u]=A.useState("viewer"),[c,d]=A.useState(""),h=Jn({mutationFn:()=>e.upsertPerson({email:i.trim(),displayName:s.trim()||i.trim(),role:l,password:c}),onSuccess:()=>{o(""),a(""),d(""),r(!1),t.invalidateQueries({queryKey:rn.people})}});return n?y.jsxs("form",{className:X("rounded-lg border p-4",Cg,sA),onSubmit:m=>{m.preventDefault(),h.mutate()},children:[y.jsxs("div",{className:"grid gap-3 sm:grid-cols-2",children:[y.jsx(Xt,{label:"Email",type:"email",value:i,onChange:o,placeholder:"someone@example.mil"}),y.jsx(Xt,{label:"Display name",value:s,onChange:a,placeholder:"Defaults to the email"}),y.jsx(pr,{label:"Role",ariaLabel:"Role",value:l,onValueChange:m=>u(Hvt(m)),options:Bvt}),y.jsx(Xt,{label:"Password",type:"password",value:c,onChange:d,placeholder:"12 characters or more",autoComplete:"new-password"})]}),h.isError&&y.jsx("p",{className:"mt-2 text-xs text-red-600",children:h.error instanceof Error?h.error.message:"Could not save."}),y.jsx("p",{className:X("mt-2 text-xs",As),children:"No role carries permission to load a snapshot. Publishing is something an application does from a pipeline, with a retryable snapshot id."}),y.jsxs("div",{className:"mt-3 flex gap-2",children:[y.jsx("button",{type:"submit",disabled:h.isPending||i.trim().length===0||c.length<12,className:"rounded-md bg-zinc-950 px-3 py-1.5 text-xs text-zinc-50 disabled:opacity-40 dark:bg-zinc-100 dark:text-zinc-950",children:h.isPending?"Saving…":"Save"}),y.jsx("button",{type:"button",onClick:()=>r(!1),className:X("rounded-md px-3 py-1.5 text-xs",As),children:"Cancel"})]})]}):y.jsx("button",{type:"button",onClick:()=>r(!0),className:X("rounded-lg border border-dashed px-4 py-3 text-left text-sm",Cg,As,"hover:text-zinc-600 dark:hover:text-zinc-300"),children:"+ Add someone"})}const Vvt={token:{icon:J8e,tone:"text-emerald-600",hint:"Authenticates with an access token — rotation and revocation belong to the identity provider."},key:{icon:cP,tone:"text-amber-600",hint:"Authenticates with a long-lived static key, revoked only by editing its row."},session:{icon:Mq,tone:"text-sky-600",hint:"Holds no credential of its own. Reachable only by a person signing in, and it caps what any of them can do."}};function Wvt({principal:e}){const t=Vvt[e.authMethod],n=t.icon;return y.jsxs("div",{className:X("rounded-lg border p-4",Cg,sA),children:[y.jsxs("div",{className:"flex flex-wrap items-start justify-between gap-3",children:[y.jsxs("div",{className:"min-w-0",children:[y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx("span",{className:"text-sm font-medium",children:e.displayName}),!e.active&&y.jsx("span",{className:"rounded-sm bg-zinc-100 px-1.5 py-0.5 font-mono text-[10px] uppercase text-zinc-500 dark:bg-zinc-800",children:"disabled"})]}),y.jsx("div",{className:X("mt-0.5 font-mono text-[11px]",As),children:e.id})]}),y.jsxs("div",{className:"flex items-center gap-4",children:[y.jsx(kt,{content:t.hint,children:y.jsxs("span",{className:X("flex cursor-help items-center gap-1.5 font-mono text-[10px] uppercase tracking-wider",t.tone),children:[y.jsx(n,{size:13}),e.authMethod]})}),y.jsx("span",{className:X("font-mono text-[11px]",As),children:e.lastSeenAt?`seen ${new Date(e.lastSeenAt).toLocaleString()}`:"never seen"})]})]}),y.jsxs("div",{className:"mt-4 grid gap-3 sm:grid-cols-2 lg:grid-cols-4",children:[y.jsx(ol,{label:"Scopes",values:e.scopes,tone:"neutral"}),y.jsx(ol,{label:"May write",values:e.writeTypes,tone:"write",emptyNote:"nothing"}),y.jsx(ol,{label:"May read",values:e.readTypes??["every type"],tone:"neutral"}),y.jsx(ol,{label:"Owns",values:e.ownedTypes,tone:"own",emptyNote:"no types published"})]}),e.classifications.length>0&&y.jsx("div",{className:"mt-3",children:y.jsx(ol,{label:"May see",values:e.classifications,tone:"classified"})})]})}function Nle({title:e,note:t,children:n}){return y.jsxs("div",{className:"mt-10",children:[y.jsx("h2",{className:"text-sm font-semibold tracking-tight",children:e}),y.jsx("p",{className:X("mt-0.5 max-w-2xl text-xs",As),children:t}),y.jsx("div",{className:"mt-3 flex flex-col gap-3",children:n})]})}function xk({children:e}){return y.jsx("p",{className:X("rounded-lg border border-dashed px-4 py-8 text-center text-sm",Cg,As),children:e})}function Lle({message:e,onRetry:t}){return y.jsxs("div",{className:"rounded-lg border border-red-200 bg-red-50 px-4 py-6 text-center dark:border-red-900 dark:bg-red-950/40",children:[y.jsx("p",{className:"text-sm text-red-700 dark:text-red-300",children:e}),y.jsx("button",{type:"button",onClick:t,className:"mt-2 rounded-md border border-red-300 px-3 py-1 text-xs text-red-700 dark:border-red-800 dark:text-red-300",children:"Try again"})]})}const qvt={neutral:"bg-zinc-100 text-zinc-600 dark:bg-zinc-800 dark:text-zinc-300",write:"bg-sky-100 text-sky-700 dark:bg-sky-950 dark:text-sky-300",own:"bg-emerald-100 text-emerald-700 dark:bg-emerald-950 dark:text-emerald-300",classified:"bg-amber-100 text-amber-700 dark:bg-amber-950 dark:text-amber-300"};function ol({label:e,values:t,tone:n,emptyNote:r="—"}){return y.jsxs("div",{children:[y.jsx("div",{className:X("font-mono text-[10px] uppercase tracking-[0.14em]",As),children:e}),y.jsx("div",{className:"mt-1 flex flex-wrap gap-1",children:t.length===0?y.jsx("span",{className:X("text-xs italic",As),children:r}):t.map(i=>y.jsx("span",{className:X("rounded-sm px-1.5 py-0.5 font-mono text-[10px]",qvt[n]),children:i},i))})]})}const GE=6;function Gvt(e,t,n){const r=new Map(e.map(s=>[s.id,s])),i=new Map;for(const s of t)i.set(s.to,[...i.get(s.to)??[],s.from]);const o=[];for(const s of e)s.kind==="sink"&&(typeof s.targetType!="string"||s.targetType.trim().length===0||o.push(...Kvt(s,r,i,n)));return o}function Kvt(e,t,n,r){const i=[],o=[];for(const s of n.get(e.id)??[]){const a=t.get(s);if(!a)continue;if(a.kind!=="source"){Yvt(a.id,t,n,r)&&o.push(a);continue}const l=r.sourceShape(a.id);l&&i.push(...Qvt(a,e,l,r))}return o.length>0&&i.push(Xvt(o,e)),i}function Yvt(e,t,n,r){const i=new Set([e]),o=[e];for(;o.length>0;){const s=o.pop();if(s===void 0)break;const a=t.get(s);if((a==null?void 0:a.kind)==="source"&&r.sourceShape(a.id))return!0;for(const l of n.get(s)??[])i.has(l)||(i.add(l),o.push(l))}return!1}function Xvt(e,t){const n=e.map(r=>`"${kn(r)}"`).join(", ");return{level:"warning",code:"shape-not-checked",message:`Whether what reaches "${kn(t)}" fits ${t.targetType.trim()} could not be checked: ${n} ${e.length===1?"sits":"sit"} in between, and ${e.length===1?"it hands":"they hand"} the sink rows ${e.length===1?"it":"they"} computed. What a transform emits is whatever its code returns, and what a call node emits is decided by a workflow this graph does not own — neither is knowable without running it, which this canvas does not do. The columns are compared only where a source feeds a sink directly. This is not a problem with the graph; it is the check declining to guess.`,nodeIds:[...e.map(r=>r.id),t.id],edgeIds:[]}}function Qvt(e,t,n,r){const i=t.targetType.trim(),o=r.targetShape(i);if(!o)return[{level:"warning",code:"shape-not-checked",message:`"${kn(e)}" reads ${n.columns.length} column${n.columns.length===1?"":"s"}, but there is nothing to compare them against: this console cannot see a type called ${i}. It may not be published yet, or it may be one this viewer is not allowed to read. The server checks it either way on save.`,nodeIds:[e.id,t.id],edgeIds:[]}];const s=Zvt(n,o),a=[];return s.respelled.length>0&&a.push(t1t(e,t,o,s.respelled)),s.missing.length>0&&a.push(n1t(e,t,o,s.missing)),s.unproven.length>0&&a.push(r1t(e,t,o,s.unproven,n)),a}function Zvt(e,t){const n=new Map(e.columns.map(i=>[i.name,i])),r={respelled:[],missing:[],unproven:[]};for(const i of t.properties){const o=n.get(i.name);if(o){const a=Jvt(i,o);a&&r.unproven.push(a);continue}const s=i.columnName;if(s&&s!==i.name&&n.has(s)){r.respelled.push({property:i,spelling:s});continue}r.missing.push(i)}return r}function Jvt(e,t){const n=`\`${e.name}\``;if(t.type===null||t.confidence==="unknown")return`${n} — discovery reached no conclusion about it${t.sourceType?` (the source calls it ${t.sourceType})`:""}, and ${e.type} is what the type expects`;if(!e1t(e.type,t.type))return`${n} — the source reports ${t.type} and the type says ${e.type}, so each value is converted on the way in and the ones that will not convert are written as null`;if(e.nullable===!1&&t.nullable===!0)return`${n} — the type says it is never null and the source says its column may be`}function e1t(e,t){return e===t?!0:e==="string"||e==="json"||e==="unknown"}function t1t(e,t,n,r){const i=r.slice(0,GE).map(({property:o,spelling:s})=>`\`${s}\` → \`${o.name}\``).join(", ");return{level:"error",code:"shape-source-spelling",message:`"${kn(e)}" produces ${Dj(r.length,"column")} that ${n.name} knows under a different name: ${i}${CY(r.length)}. The load looks every field up by the property's own name, and a source wired straight into a sink hands its records over exactly as they arrive — so each of these would be written as null in every row, and the load would still report the rows it read. Rename the ${r.length===1?"property":"properties"} on ${n.name} to the spelling the source uses, which publishing now accepts; where a name cannot become a column even cleaned, put a transform between them to rename the field instead.`,nodeIds:[e.id,t.id],edgeIds:[]}}function n1t(e,t,n,r){const i=r.slice(0,GE).map(o=>`\`${o.name}\``).join(", ");return{level:"error",code:"shape-missing-column",message:`"${kn(e)}" does not produce ${Dj(r.length,"column")} that ${n.name} is made of: ${i}${CY(r.length)}. Nothing between a source and a sink adds a field, so ${r.length===1?"it":"each of them"} would be null in every row "${kn(t)}" commits, on every run, and the run would report success.`,nodeIds:[e.id,t.id],edgeIds:[]}}function r1t(e,t,n,r,i){const o=r.slice(0,GE).join("; ");return{level:"warning",code:"shape-unproven",message:`${Dj(r.length,"column")} between "${kn(e)}" and ${n.name} could not be decided from the schemas alone: ${o}${CY(r.length)}. ${i1t(i)} Nothing here says the graph is wrong — it says this much of it was not proven right.`,nodeIds:[e.id,t.id],edgeIds:[]}}function i1t(e){if(e.basis==="sample"){const t=e.sampled??0;return`The types came from ${Dj(t,"record")} read out of the source, so they are an inference over what was seen and not a statement about the rest.`}return e.basis==="driver"?`The types came from the driver's description of the result set and no rows were read (sampled ${e.sampled??0}), so the column names are the source's own and nothing at all is known about the values.`:"The discovery behind this did not say how it knows, so treat the types as unproven."}function Dj(e,t){return`${e} ${t}${e===1?"":"s"}`}function CY(e){return e>GE?`, and ${e-GE} more`:""}const o1t=new Set(["cycle","self-edge","duplicate-edge","shape-source-spelling","shape-missing-column"]);function LOe(e,t,n){if(!o1t.has(e))return[];const r=new Set(t);return n.filter(i=>r.has(i.from)&&r.has(i.to)).map(i=>Fo(i))}function Fo(e){return`${e.from}->${e.to}`}function s1t(e,t){const{nodes:n,edges:r}=e,i=[];for(const o of Ke.validateWorkflow({nodes:n,edges:r}))i.push({level:"error",code:o.code,message:o.message,nodeIds:o.nodeIds,edgeIds:LOe(o.code,o.nodeIds,r)});for(const o of n){const s=kn(o);if(o.kind==="transform"){o.transformId.length>0&&!t.transformIds.has(o.transformId)&&i.push({level:"error",code:"missing-transform",message:`"${s}" points at a transform that no longer exists. It was probably deleted from the Transforms tab.`,nodeIds:[o.id],edgeIds:[]});continue}if(o.kind!=="sink")continue;(typeof o.targetType=="string"?o.targetType.trim():"").length===0&&i.push({level:"error",code:"sink-has-no-type",message:`"${s}" does not say which object type it writes, so there would be nothing for the run to commit into. The type is chosen on the sink because the sink is the node that commits.`,nodeIds:[o.id],edgeIds:[]})}return i.push(...a1t(e,t)),i}function a1t(e,t){return t.shapes?Gvt(e.nodes,e.edges,t.shapes).map(n=>({...n,edgeIds:LOe(n.code,n.nodeIds,e.edges)})):[]}function l1t(e,t,n){if(t===n)return!0;const r=new Map;for(const s of e)r.set(s.from,[...r.get(s.from)??[],s.to]);const i=new Set([n]),o=[n];for(;o.length>0;){const s=o.pop();if(s===void 0)break;for(const a of r.get(s)??[]){if(a===t)return!0;i.has(a)||(i.add(a),o.push(a))}}return!1}function tc(e,t,n,r){if(n===r)return{ok:!1,reason:"A node cannot feed itself."};const i=e.find(s=>s.id===n),o=e.find(s=>s.id===r);return!i||!o?{ok:!1,reason:"One end of that connection is not a node."}:i.kind==="sink"?{ok:!1,reason:`"${kn(i)}" commits its rows. Nothing runs after a sink.`}:o.kind==="source"?{ok:!1,reason:`"${kn(o)}" reads from a system, so nothing can feed into it.`}:t.some(s=>s.from===n&&s.to===r)?{ok:!1,reason:`Those two are already wired together, and wiring them twice would send "${kn(o)}" the same rows twice.`}:o.kind==="if"&&t.some(s=>s.to===r)?{ok:!1,reason:`"${kn(o)}" already has something feeding it. An if node is a gate — it passes one stream straight down whichever branch it takes — so it cannot merge two. Wire both into a transform and gate that instead.`}:l1t(t,n,r)?{ok:!1,reason:`That would close a loop: "${kn(o)}" already feeds "${kn(i)}", directly or through other nodes. A ${bn.singular} that loops has no order to run in.`}:{ok:!0}}function u1t(e){return e.some(t=>t.level==="error")}function XU(e){const t=new Map;for(const n of e)for(const r of n.nodeIds){const i=t.get(r)??[];i.push(n),t.set(r,i)}return t}Ke.CONNECTOR_KINDS.filter(e=>e==="file"||e==="s3");function c1t(e,t,n,r,i,o,s,a,l,u=2){const c=F7e(n.current,{event:e,orientation:r,loopFocus:i,rtl:o,cols:u,disabledIndices:s,minIndex:a,maxIndex:l,prevIndex:t>l?a:t,stopEvent:!0});return wh(n.current,c)?void 0:c}function EY(e){return e==null?ki:e.type.startsWith("key")?jve:e.type.startsWith("mouse")||e.type.startsWith("pointer")?Dve:ki}const IOe=A.createContext(void 0),POe=A.createContext(void 0),jOe=A.createContext(void 0),DOe=A.createContext(!1),$Oe=A.createContext("");function Bd(){const e=A.useContext(IOe);if(!e)throw new Error(Br(22));return e}function TY(){const e=A.useContext(POe);if(!e)throw new Error(Br(23));return e}function aA(){const e=A.useContext(jOe);if(!e)throw new Error(Br(24));return e}function d1t(){return A.useContext($Oe)}function f1t(){return A.useContext(DOe)}const h1t={id:e=>e.id,labelId:e=>e.labelId,items:e=>e.items,selectedValue:e=>e.selectedValue,hasSelectionChips:e=>{const t=e.selectedValue;return Array.isArray(t)&&t.length>0},hasSelectedValue:e=>{const{selectedValue:t,selectionMode:n}=e;return t==null?!1:n==="multiple"&&Array.isArray(t)?t.length>0:!0},hasNullItemLabel:(e,t)=>t?U1e(e.items):!1,open:e=>e.open,mounted:e=>e.mounted,forceMounted:e=>e.forceMounted,inline:e=>e.inline,activeIndex:e=>e.activeIndex,selectedIndex:e=>e.selectedIndex,isActive:(e,t)=>e.activeIndex===t,isSelected:(e,t)=>{const n=e.isItemEqualToValue,r=e.selectedValue;return Array.isArray(r)?r.some(i=>cu(t,i,n)):cu(t,r,n)},transitionStatus:e=>e.transitionStatus,popupProps:e=>e.popupProps,listProps:e=>e.listProps,inputProps:e=>e.inputProps,triggerProps:e=>e.triggerProps,itemRoot:e=>e.itemRoot,positionerElement:e=>e.positionerElement,listElement:e=>e.listElement,popupId:e=>e.popupId,triggerElement:e=>e.triggerElement,inputElement:e=>e.inputElement,inputGroupElement:e=>e.inputGroupElement,popupSide:e=>e.popupSide,openMethod:e=>e.openMethod,inputInsidePopup:e=>e.inputInsidePopup,inputOwnsFormValue:e=>e.inputOwnsFormValue,selectionMode:e=>e.selectionMode,name:e=>e.name,form:e=>e.form,disabled:e=>e.disabled,readOnly:e=>e.readOnly,required:e=>e.required,grid:e=>e.grid,virtualized:e=>e.virtualized,itemToStringLabel:e=>e.itemToStringLabel,isItemEqualToValue:e=>e.isItemEqualToValue,modal:e=>e.modal,autoHighlight:e=>e.autoHighlight};function p1t(e){return e==null?void 0:`${e}-popup`}function m1t(e,t){return(n,r)=>n==null?!1:e.contains(n,r,t)}function zOe(e){return Array.isArray(e)?e.map(t=>zOe(t)).join(","):e==null?"":String(e)}const Ile=new Map;function g1t(e={}){const{locale:t,...n}=e,r={usage:"search",sensitivity:"base",ignorePunctuation:!0,...n},i=`${zOe(t)}|${JSON.stringify(r)}`,o=Ile.get(i);if(o)return o;const s=new Intl.Collator(t,r),a={contains(l,u,c){if(!u)return!0;const d=Sh(l,c);for(let h=0;h<=d.length-u.length;h+=1)if(s.compare(d.slice(h,h+u.length),u)===0)return!0;return!1},startsWith(l,u,c){if(!u)return!0;const d=Sh(l,c);return s.compare(d.slice(0,u.length),u)===0},endsWith(l,u,c){if(!u)return!0;const d=Sh(l,c),h=u.length;return d.length>=h&&s.compare(d.slice(d.length-h),u)===0}};return Ile.set(i,a),a}const FOe=g1t;function y1t(e,t=!1){const{overflowY:n}=ka(e);return n!=="auto"&&n!=="scroll"?!1:t?e.clientHeight>0:e.scrollHeight>e.clientHeight}const BOe=Symbol("none"),S8={value:BOe,index:-1};function b1t(e,t,n){const r=e.get(t);if(r!==void 0||n===jP)return r;for(const[i,o]of e)if(cu(i,t,n))return o}function v1t(e){const{id:t,onOpenChangeComplete:n,defaultSelectedValue:r=null,selectedValue:i,onSelectedValueChange:o,defaultInputValue:s,inputValue:a,open:l,defaultOpen:u=!1,selectionMode:c,onItemHighlighted:d,name:h,form:m,disabled:g=!1,readOnly:b=!1,required:v=!1,inputRef:w,grid:S=!1,items:C,filteredItems:E,filter:T,filterQuery:O,openOnInputClick:M=!0,autoHighlight:N=!1,keepHighlight:I=!1,highlightItemOnHover:D=!0,loopFocus:P=!0,itemToStringLabel:F,itemToStringValue:z,isItemEqualToValue:$=jP,virtualized:B=!1,inline:H=!1,fillInputOnItemPress:U=!0,modal:W=!1,limit:q=-1,autoComplete:Y="list",formAutoComplete:Q,locale:G,submitOnItemClick:le=!1}=e,{clearErrors:K}=CG(),{setDirty:te,validityData:de,setFilled:ue,name:ae,disabled:ie,setTouched:he,setFocused:fe,validationMode:se,validation:Se}=Mb(),pe=Ww(),Ee=PP({id:t}),ke=FOe({locale:G}),Ie=Array.isArray(C)?null:C;if(Ie&&typeof Ie.label!="function")throw new Error(Br(100));const Be=Ie?Ie.data:C,Oe=Ie==null?void 0:Ie.value,Le=Oe?void 0:Be,ge=A.useMemo(()=>{if(!E||!Oe)return;const Je=NM(E),nt=Je.map(Oe);let en;return{values:nt,findItem(j,ee){if(!en){en=new Map;for(let ce=0;ce<nt.length;ce+=1)en.has(nt[ce])||en.set(nt[ce],Je[ce])}return b1t(en,j,ee)}}},[E,Oe]),$e=A.useMemo(()=>Ie?Je=>Ie.label(Je,$,nt=>{const en=ge==null?void 0:ge.findItem(nt,$);return en!=null?Ie.itemLabel(en):Sh(nt,F)}):F,[Ie,F,ge,$]),Ye=A.useMemo(()=>Ie?Object.assign(Je=>Ie.itemLabel(Je),{selected:Je=>Sh(Je,$e)}):F,[Ie,$e,F]);function tt(Je){return Sh(Je,$e)}const[Ae,_e]=A.useState(!1),[He,Ue]=A.useState(null),Ve=A.useRef(He),gt=A.useRef([]),rt=A.useRef([]),xt=A.useRef(null),$t=A.useRef(null),zt=A.useRef(null),vn=A.useRef(null),_n=A.useRef(null),Vn=A.useRef(!1),Ln=A.useRef(null),ln=A.useRef(null),mr=A.useRef(null),Yn=A.useRef(S8),Yt=A.useRef(null),Ht=A.useRef([]),on=A.useRef(null),Jt=ie||g,yt=ae??h,pt=c==="multiple",Fe=c==="single",Qe=a!==void 0||s!==void 0,ut=Be!==void 0,qt=E!==void 0;let Vt;N==="always"?Vt="always":Vt=N?"input-change":!1;const[it,sn]=$y({controlled:i,default:pt?r??Ws:r,name:"Combobox",state:"selectedValue"}),zn=A.useMemo(()=>T===null?()=>!0:T!==void 0?T:m1t(ke,Ye),[T,ke,Ye]),er=Ti(()=>Qe?s??"":Fe?tt(it):"").current,[Qt,tr]=$y({controlled:a,default:er,name:"Combobox",state:"inputValue"}),[cn,nr]=$y({controlled:l,default:u,name:"Combobox",state:"open"}),bo=kG(Be),Mr=!cn&&He!==null?He:String(Qt).trim(),zi=Fe?tt(it):"",Ms=Fe&&!Ae&&Mr!==""&&zi.length===Mr.length&&ke.contains(zi,Mr),Ri=Ms?"":O??Mr,La=ut&&qt&&Ms&&(!Ie||Ie.hasValue(it,$)),Uo=A.useMemo(()=>Be?NM(Be):Ws,[Be]),vo=A.useMemo(()=>{if(E&&!La)return E;if(!Be)return Ws;if(bo){const nt=Be,en=[];let j=0;for(const ee of nt){if(q>-1&&j>=q)break;const ce=q>-1?q-j:1/0,me=Ri===""?ee.items.slice(0,ce):[];if(Ri!=="")for(const xe of ee.items){if(me.length>=ce)break;zn(xe,Ri,Ye)&&me.push(xe)}if(me.length>0){const xe={...ee,items:me};en.push(xe),j+=me.length}}return en}if(Ri==="")return q>-1?Uo.slice(0,q):Uo;const Je=[];for(const nt of Uo){if(q>-1&&Je.length>=q)break;zn(nt,Ri,Ye)&&Je.push(nt)}return Je},[E,La,Be,bo,Ri,q,zn,Ye,Uo]),kr=A.useMemo(()=>{if(ge&&vo===E)return ge.values;const Je=NM(vo);return Oe?Je.map(nt=>Oe(nt)):Je},[vo,E,ge,Oe]),Ct=Ti(()=>{let Je=null;return H&&cn&&ut&&c!=="none"&&(Je=wC(kr,it,$,pt)),new Fw({id:Ee,labelId:void 0,selectedValue:it,open:cn,items:Le,selectionMode:c,name:yt,form:m,disabled:Jt,readOnly:b,required:v,grid:S,virtualized:B,openOnInputClick:M,itemToStringLabel:$e,isItemEqualToValue:$,modal:W,autoHighlight:Vt,submitOnItemClick:le,hasInputValue:Qe,mounted:!1,forceMounted:!1,transitionStatus:"idle",inline:H,activeIndex:null,selectedIndex:Je,popupProps:{},listProps:{},inputProps:{},triggerProps:{},itemRoot:{props:Un,id:Ee,selectionMode:c,disabled:Jt,readOnly:b,isItemEqualToValue:$},positionerElement:null,listElement:null,popupId:void 0,triggerElement:null,inputElement:null,inputGroupElement:null,popupSide:null,openMethod:null,inputInsidePopup:!0,inputOwnsFormValue:c==="none"},{onOpenChangeComplete:ar,setOpen:ar,setInputValue:ar,setSelectedValue:ar,setIndices:ar,handleSelection:ar,forceMount:ar,requestSubmit:ar,listRef:gt,labelsRef:rt,popupRef:xt,emptyRef:_n,inputRef:$t,startDismissRef:zt,endDismissRef:vn,chipsContainerRef:Ln,clearRef:ln,valuesRef:Ht,pointerDownItemRef:on,selectionEventRef:mr},h1t)}).current,cs=c==="none"?Qt:it,fc=A.useMemo(()=>c==="none"?cs:Array.isArray(it)?it.map(Je=>Vu(Je,z)):Vu(it,z),[cs,z,c,it]),pu=at(d),Fi=at(n),Hr=Ct.useState("activeIndex"),Te=Ct.useState("selectedIndex"),Xe=Ct.useState("positionerElement"),Ze=Ct.useState("listElement"),Ft=Ct.useState("triggerElement"),In=Ct.useState("inputElement"),_r=Ct.useState("inputGroupElement"),rr=Ct.useState("inline"),gi=Ct.useState("inputInsidePopup"),hc=Ct.useState("inputOwnsFormValue"),ia=Fe&&!gi&&Qt===zi,ml=ci(Ft),{openMethod:mu,triggerProps:ds}=EG(cn),si=at(()=>fc);SG(gi?ml:$t,Ee,cs,si,!Jt,h);const pc=at(()=>{Be?rt.current=kr.map(tt):Ct.set("forceMounted",!0)}),Ia=at((Je,nt,en,j)=>{if(nt===-1){if(Yn.current===S8)return;Yn.current=S8}else Yn.current={value:Je,index:nt};pu(Je,Ive(en,j,{index:nt}))}),fs=at(Je=>{const nt={};Je.activeIndex!==void 0&&(nt.activeIndex=Je.activeIndex),Je.selectedIndex!==void 0&&(nt.selectedIndex=Je.selectedIndex),Ct.update(nt);const en=Je.activeIndex;if(en===void 0)return;const j=Je.type||ki;en===null?Ia(void 0,-1,j,Je.event):Ia(Ht.current[en],en,j,Je.event)}),ai=at((Je,nt)=>{var en;if((en=e.onInputValueChange)==null||en.call(e,Je,nt),!nt.isCanceled){if(Vn.current=nt.reason===Lc,nt.reason===A1){cn&&He!==null&&Ue(null);const j=nt.event,ee=j.inputType;if(j.type==="compositionend"||ee!=null&&ee!==""&&ee!=="insertReplacementText"){const me=Je.trim()!=="";me&&_e(!0),Yt.current={hasQuery:me};const xe=Ct.state.listElement;if(!Ct.state.virtualized&&xe){const De=xt.current;for(const bt of Lx(xe.firstElementChild??xe)){if(!Ar(bt)||(De?!Rt(De,bt):bt.getAttribute("role")==="dialog"))break;if(y1t(bt)){bt.scrollTop=0;break}}}me&&Vt&&Ct.state.activeIndex==null&&(cn||rr)&&Ct.set("activeIndex",0)}}else nt.reason===Lc&&Je===""&&Ct.state.inputInsidePopup&&(Yt.current={hasQuery:!1,selection:!0});tr(Je)}}),Pa=at(Je=>{const nt=!Je&&gi&&!rr&&Qt!==""&&(String(Qt).trim()===He||Qt===zi);!Je&&(nt||Qt===""||ia)&&_e(!1),Ue(null),nt&&ai("",Et(Lc))}),[tp,mc]=A.useState(!1),ja=at((Je,nt)=>{var ee,ce;if(cn===Je)return;nt.reason===Vw&&ut&&kr.length===0&&!_n.current&&nt.allowPropagation();const en=nt,j=MP(en);if((ee=e.onOpenChange)==null||ee.call(e,Je,en),(ce=Yt.current)!=null&&ce.hasQuery&&nt.reason===A1===nt.isCanceled&&(Yt.current=null),!nt.isCanceled&&(Je&&He!==null&&Pa(nt.reason===A1),!Je&&Ae&&(Fe?(rr||Ue(Mr),Mr===""&&_e(!1)):pt&&(rr||Ue(Mr),gi&&fs({activeIndex:null}),(!gi||rr)&&ai("",Et(Lc,nt.event,void 0,{isItemPress:nt.reason===eg})))),Je||mc(j()),nr(Je),!Je&&gi&&(nt.reason===gg||nt.reason===E2)&&(he(!0),fe(!1),se==="onBlur"))){const me=c==="none"?Qt:it;Se.commit(me)}}),gu=at((Je,nt)=>{if(o==null||o(Je,nt),nt.isCanceled)return;sn(Je),(c==="none"&&xt.current&&U||Fe&&!Ct.state.inputInsidePopup)&&ai(tt(Je),Et(nt.reason,nt.event))}),En=at((Je,nt)=>{var me;const en=ji(Je),j=mr.current??Je;mr.current=null;const ee=Et(eg,j),ce=(me=mg(en,"a"))==null?void 0:me.getAttribute("href");if(ce){ce.startsWith("#")&&ja(!1,ee);return}if(pt){const xe=Array.isArray(it)?it:[],De=oN(xe,nt,$),bt=De?H1e(xe,nt,$):[...xe,nt];if(gu(bt,ee),ee.isCanceled||!($t.current?$t.current.value.trim()!=="":!1))return;if(Ct.state.inputInsidePopup){ai("",Et(Lc,ee.event,void 0,{isItemPress:!0}));const mt=Yt.current;mt&&!De&&(mt.toggledValue=nt)}else ja(!1,ee)}else{if(gu(nt,ee),ee.isCanceled)return;ja(!1,ee)}}),Gg=at(()=>{var nt,en;const Je=((nt=Se.inputRef.current)==null?void 0:nt.form)??((en=Ct.state.inputElement)==null?void 0:en.form);Je&&typeof Je.requestSubmit=="function"&&Je.requestSubmit()}),np=at(()=>{if(Fi==null||Fi(!1),_e(!1),Ue(null),fs(c==="none"?{activeIndex:null,selectedIndex:null}:{activeIndex:null}),pt&&$t.current&&$t.current.value!==""&&!Vn.current&&ai("",Et(Lc)),Fe)if(Ct.state.inputInsidePopup)$t.current&&$t.current.value!==""&&ai("",Et(Lc));else{const Je=tt(it);$t.current&&$t.current.value!==Je&&ai(Je,Et(Je===""?Lc:ki))}}),yu=A.useMemo(()=>rr&&Xe?{current:mg(Xe,'[role="dialog"]')}:xt,[rr,Xe]),{mounted:Da,transitionStatus:xo,forceUnmount:Kg}=cG({open:cn,ref:yu,preventUnmountOnClose:tp,setPreventUnmountOnClose:mc,onUnmount:np});A.useImperativeHandle(e.actionsRef,()=>({unmount:Kg,close:()=>ja(!1,Et(T2))}),[Kg,ja]),et(function(){const nt=Ve.current!==null&&He===null;if(Ve.current=He,cn&&(!nt||!ut)||(cn||(on.current=null),c==="none"))return;const en=ut?kr:Ht.current;fs({selectedIndex:wC(en,it,$,pt)})},[cn,He,it,c,pt,ut,kr,$,fs]),et(()=>{Be&&(Ht.current=kr,gt.current.length=kr.length)},[Be,kr]),et(()=>{var Je;!cn&&((Je=Yt.current)!=null&&Je.hasQuery)&&(Yt.current=null)},[cn]),et(()=>{var me;if(!cn&&rr&&yu.current){Yt.current=null;return}const Je=ut||qt?kr:Ht.current,nt=Yt.current;if(nt){const xe=cn||rr||((me=Ct.state.positionerElement)==null?void 0:me.hidden)===!1;if(nt.hasQuery){const De=$t.current;!Vt||String(Qt).trim()===""||rr&&Vt!=="always"&&(!De||Ss(De.ownerDocument)!==De)?Yt.current=null:xe&&(Je[0]!==void 0||!ut&&!qt)&&(Ct.set("activeIndex",0),Yt.current=null)}else if(String(Qt).trim()===""&&(Yt.current=null,xe)){const De=nt.selection;Vt==="always"&&!De&&Ct.state.selectionMode==="none"&&Ct.set("activeIndex",0),queueMicrotask(()=>{if(!Ct.state.open&&(!Ct.state.inline||yu.current)||$t.current&&$t.current.value.trim()!=="")return;const bt=Ct.state.selectedValue,an=Ct.state.selectionMode==="multiple";if(an&&Array.isArray(bt)?bt.length>0:Ct.state.selectionMode!=="none"&&bt!=null){const Zt=ut||qt?kr:Ht.current,gr=_1(Zt,nt.toggledValue,Ct.state.isItemEqualToValue);Ct.set("activeIndex",gr!==-1?gr:wC(Zt,bt,Ct.state.isItemEqualToValue,an))}else De?Ct.set("activeIndex",null):Vt==="always"&&Ct.set("activeIndex",0)})}}if(!cn&&!rr)return;const en=Ct.state.activeIndex;if(en==null){if(Vt==="always"&&Je.length>0){Ct.set("activeIndex",0);return}Ia(void 0,-1,ki);return}if(en>=Je.length){Ia(void 0,-1,ki),Ct.set("activeIndex",null);return}const j=Je[en],ee=Yn.current.value,ce=ee!==BOe&&cu(j,ee,Ct.state.isItemEqualToValue);(Yn.current.index!==en||!ce)&&Ia(j,en,ki)},[Hr,Vt,Ia,qt,ut,kr,rr,cn,yu,Ct,Qt]),et(()=>{if(c==="none"){ue(String(Qt)!=="");return}ue(pt?Array.isArray(it)&&it.length>0:it!=null)},[ue,c,Qt,it,pt]),A.useEffect(()=>{ut&&Vt&&kr.length===0&&fs({activeIndex:null})},[ut,Vt,kr.length,fs]);function vS(){cn&&Mr!==""&&Mr!==String(er)&&!ia&&_e(!0)}function Yg(){cn&&He!==null&&Pa(!1)}let Xg=!1;function Vd(){!Xg&&Qt!==zi&&(Xg=!0,ai(zi,Et(ki)))}function hs(){c!=="none"&&(K(yt),te(F1e(it,de.initialValue,$)),Se.change(it),Fe&&!Qe&&!gi&&Vd())}function rp(){Fe&&!Qe&&!gi&&!Ae&&Vd()}function Vb(){c==="none"&&(K(yt),te(Qt!==de.initialValue),Se.change(Qt))}Rf(Mr,vS),Rf(cn,Yg),Rf(it,hs),Rf(zi,rp),Rf(Be,rp),Rf(Qt,Vb);const $a=v1e({open:rr?!0:cn,onOpenChange:ja,elements:{reference:gi?Ft:In,floating:Xe}}),gl=S?"grid":"listbox",Wd=cn||rr,Qg=Wd?"true":"false",za=A.useMemo(()=>{const Je=(In==null?void 0:In.tagName)==="INPUT",nt=In==null||Je,en=nt||Wd,j=nt?{autoComplete:"off",spellCheck:"false",autoCorrect:"off",autoCapitalize:"none"}:{};return en&&(j.role="combobox",j["aria-expanded"]=Qg,j["aria-haspopup"]=gl,j["aria-controls"]=Wd?Ze==null?void 0:Ze.id:void 0,j["aria-autocomplete"]=b?"none":Y),{reference:j,floating:{role:"presentation"}}},[In,Wd,Qg,gl,Ze==null?void 0:Ze.id,Y,b]),Wb=aG($a,{enabled:!Jt&&M,event:"mousedown-only",toggle:!1,touchOpenDelay:gi?0:100,reason:T7e}),qd=O2($a,{enabled:!Jt&&!rr,outsidePressEvent:{mouse:"sloppy",touch:"intentional"},bubbles:rr?!0:void 0,outsidePress(Je){const nt=ji(Je);return!Rt(Ft,nt)&&!Rt(ln.current,nt)&&!Rt(Ln.current,nt)&&!Rt(_r,nt)}}),bu=vG($a,{enabled:!Jt,id:Ee,listRef:gt,activeIndex:Hr,selectedIndex:Te,virtual:!0,loopFocus:P,allowEscape:P&&!Vt,focusItemOnOpen:Ae||c==="none"&&!Vt?!1:"auto",focusItemOnHover:D,resetOnPointerLeave:!I,orientation:S?"horizontal":void 0,rtl:pe==="rtl",disabledIndices:Ws,grid:S?c1t:void 0,onNavigate(Je,nt){!nt&&!cn&&!(rr&&Je===null)||xo==="ending"||fs({activeIndex:Je,type:EY(nt),event:nt==null?void 0:nt.nativeEvent})}}),ip=A.useMemo(()=>Qs(bu.reference,{onKeyDown(Je){S&&Ct.state.activeIndex==null&&(Je.key==="ArrowLeft"||Je.key==="ArrowRight")&&Je.preventBaseUIHandler()}},qd.reference,Wb.reference,za.reference),[bu.reference,qd.reference,Wb.reference,za.reference,S,Ct]),Zg=A.useMemo(()=>Qs(R2,qd.floating),[qd.floating]),qb=A.useMemo(()=>Qs(bu.floating,za.floating),[bu.floating,za.floating]),Gd=A.useMemo(()=>{const Je=bu.item;return{props:Je?{...Je,onFocus:void 0}:Un,id:Ee,selectionMode:c,disabled:Jt,readOnly:b,isItemEqualToValue:$}},[bu.item,Ee,c,Jt,b,$]);Ct.useContextCallback("setOpen",ja),Ct.useContextCallback("setInputValue",ai),Ct.useContextCallback("setSelectedValue",gu),Ct.useContextCallback("setIndices",fs),Ct.useContextCallback("handleSelection",En),Ct.useContextCallback("forceMount",pc),Ct.useContextCallback("requestSubmit",Gg),Ct.useContextCallback("onOpenChangeComplete",n),wve(()=>{Ct.update({inline:H,popupProps:Zg,listProps:qb,inputProps:ip,triggerProps:ds,itemRoot:Gd})});const _s={id:Ee,selectedValue:it,open:cn,mounted:Da,transitionStatus:xo,items:Le,inline:H,popupProps:Zg,listProps:qb,inputProps:ip,triggerProps:ds,itemRoot:Gd,openMethod:mu,selectionMode:c,name:yt,form:m,disabled:Jt,readOnly:b,required:v,grid:S,virtualized:B,openOnInputClick:M,itemToStringLabel:$e,modal:W,autoHighlight:Vt,isItemEqualToValue:$,submitOnItemClick:le,hasInputValue:Qe};et(()=>{Ct.update({..._s,inputOwnsFormValue:c==="none"&&(H||!Ct.state.inputInsidePopup)})},[Ct,...Object.values(_s)]);const Jg=uu(w,Se.inputRef),e0=A.useMemo(()=>({query:Mr,hasItems:ut,filteredItems:vo,flatFilteredValues:kr}),[Mr,ut,vo,kr]),gc=A.useMemo(()=>Array.isArray(cs)?"":Vu(cs,z),[cs,z]),yc=pt&&Array.isArray(it)&&it.length>0,op=pt||c==="none"&&hc?void 0:yt,t0=A.useMemo(()=>!pt||!Array.isArray(it)||!yt?null:it.map(Je=>{const nt=Vu(Je,z);return y.jsx("input",{type:"hidden",form:m,name:yt,value:nt,disabled:Jt},nt)}),[pt,it,m,yt,z,Jt]),n0=y.jsxs(A.Fragment,{children:[e.children,y.jsx("input",{...Se.getValidationProps(Jt,{onFocus(){var Je;if(gi){Ft==null||Ft.focus();return}(Je=$t.current||Ft)==null||Je.focus()},onChange(Je){if(Je.nativeEvent.defaultPrevented||Jt||b)return;const nt=Je.currentTarget.value,en=nt.toLowerCase(),j=Et(ki,Je.nativeEvent),ee=()=>Ht.current.findIndex(me=>Vu(me,z).toLowerCase()===en||tt(me).toLowerCase()===en);function ce(){if(pt)return;if(c==="none"){ai(nt,j);return}let me=ee();me===-1&&(me=Ht.current.findIndex((De,bt)=>{const an=rt.current[bt];return an!=null&&an.toLowerCase()===en}));const xe=me===-1?void 0:Ht.current[me];xe!=null&&(gu==null||gu(xe,j))}Fe&&(pc(),Be&&ee()===-1&&Ct.set("forceMounted",!0)),queueMicrotask(ce)}}),id:Ee&&op==null?`${Ee}-hidden-input`:void 0,form:m,name:op,autoComplete:Q,disabled:Jt,required:v&&!yc,readOnly:b,value:gc,ref:Jg,style:op?bP:yP,tabIndex:-1,"aria-hidden":!0,suppressHydrationWarning:!0}),t0]});return y.jsx(IOe.Provider,{value:Ct,children:y.jsx(POe.Provider,{value:$a,children:y.jsx(DOe.Provider,{value:ut,children:y.jsx(jOe.Provider,{value:e0,children:y.jsx($Oe.Provider,{value:Qt,children:n0})})})})})}function x1t(e){const{openOnInputClick:t=!1,value:n,defaultValue:r,onValueChange:i,mode:o="list",itemToStringValue:s,...a}=e,l=(o==="inline"||o==="both")&&!e.readOnly,u=o==="inline"||o==="none",c=n!==void 0,[d,h]=A.useState(r??""),[m,g]=A.useState("");A.useEffect(()=>{(c||!l)&&g("")},[n,c,l]);let b;l&&m!==""?b=m:c?b=n??"":b=d;const v=FOe({locale:a.locale}),w=String((c?n:d)??"").trim(),S=u||a.filter===null?null:a.filter??v.contains;function C(T,O){g(""),c||h(T),i==null||i(T,O)}function E(T,O){var M;(M=e.onItemHighlighted)==null||M.call(e,T,O),O.reason!==Dve&&g(l&&T!=null?Sh(T,s):"")}return y.jsx(v1t,{...a,itemToStringLabel:s,openOnInputClick:t,selectionMode:"none",fillInputOnItemPress:!0,filter:S,filterQuery:o==="both"?w:void 0,autoComplete:o,inputValue:b,defaultInputValue:r,onInputValueChange:C,onItemHighlighted:E})}const w1t="data-popup-side",S1t="data-list-empty",k1t={...G_,...wG,popupSide:e=>e?{[w1t]:e}:null,listEmpty:e=>e?{[S1t]:""}:null};function C1t(e){const t=e.useState("mounted"),n=e.useState("popupSide"),r=e.useState("positionerElement");return t&&r?n:null}function AY(){return aA().filteredItems.length===0}function E1t(e){return e==="rtl"?["ArrowRight","ArrowLeft"]:["ArrowLeft","ArrowRight"]}function HOe(e,t,n){const r=e.context.listRef.current[t];r&&(e.context.selectionEventRef.current=n,r.click(),e.context.selectionEventRef.current=null)}const T1t=A.createContext(void 0);function A1t(){return A.useContext(T1t)}const UOe=A.createContext(void 0);function OY(e){const t=A.useContext(UOe);if(t===void 0&&!e)throw new Error(Br(21));return t}const VOe=A.forwardRef(function(t,n){const r=Bd(),{buttonRef:i,getButtonProps:o}=Kh({native:!1}),s=uu(n,i);function a(u){r.context.setOpen(!1,Et(Pve,u.nativeEvent,u.currentTarget))}const l=o({onClick:a});return y.jsx("span",{ref:s,...l,"aria-label":"Dismiss",tabIndex:void 0,style:bP})}),O1t=A.forwardRef(function(t,n){const{render:r,className:i,disabled:o=!1,id:s,style:a,...l}=t,{state:u,disabled:c,setTouched:d,validationMode:h,validation:m}=Mb(),{labelId:g}=IP(),b=A1t(),w=!!OY(!0),S=Bd(),C=d1t(),E=Ww(),T=S.useState("required"),O=S.useState("disabled"),M=S.useState("readOnly"),N=S.useState("name"),I=S.useState("form"),D=S.useState("selectionMode"),P=S.useState("autoHighlight"),F=S.useState("inputProps"),z=S.useState("triggerProps"),$=S.useState("open"),B=S.useState("mounted"),H=S.useState("selectedValue"),U=S.useState("id"),W=S.useState("inline"),q=S.useState("modal"),Y=!!P,Q=C1t(S),G=c||O||o,le=AY(),K=TG(G,S.context.inputRef),te=w||W,de=!te||q,ue=Ca(s??(te?void 0:U)),ae=w?D1e:u,[ie,he]=A.useState(null),fe=A.useRef(!1),se=A.useRef(null);et(()=>{$||(se.current=null)},[$]);const Se=D==="none"&&!w,pe=at(ge=>{const $e=w||S.state.inline;$e&&!S.state.hasInputValue&&S.context.setInputValue("",Et(ki)),S.update({inputElement:ge,inputInsidePopup:$e,inputOwnsFormValue:Se})}),Ee=w?l:m.getValidationProps(G,l);function ke(ge){S.context.setIndices({activeIndex:null,selectedIndex:null,type:EY(ge),event:ge})}const Ie={...ae,open:$,disabled:G,readOnly:M,popupSide:Q,listEmpty:le};function Be(ge){if(!b)return;let $e;const Ye=b.chipsRef.current.length,[tt]=E1t(E);return ge.key===tt&&(ge.currentTarget.selectionStart??0)===0&&H.length>0&&(ge.preventDefault(),$e=Ye>0?Ye-1:void 0),$e}const Oe=$n("input",t,{state:Ie,ref:[n,S.context.inputRef,pe],props:[F,z,{value:ie??C,"aria-readonly":M||void 0,"aria-required":T||void 0,"aria-labelledby":g,disabled:G,readOnly:M,required:D==="none"?T:void 0,form:I,...Se&&N&&{name:N},id:ue,onFocus(){if(K(!0),!W)return;const ge=se.current;se.current=null,!(ge==null||!Object.hasOwn(S.context.valuesRef.current,ge))&&S.context.setIndices({activeIndex:ge})},onBlur(){d(!0),K(!1);const ge=S.state.activeIndex;if(W&&ge!==null&&P!=="always"&&(se.current=ge,S.context.setIndices({activeIndex:null})),h==="onBlur"){const $e=D==="none"?C:H;m.commit($e)}},onCompositionStart(ge){q_||(fe.current=!0,he(ge.currentTarget.value))},onCompositionEnd(ge){fe.current=!1;const $e=ge.currentTarget.value;he(null),S.context.setInputValue($e,Et(A1,ge.nativeEvent))},onChange(ge){const $e=ge.nativeEvent,Ye=$e.inputType,tt=!Ye||Ye==="insertReplacementText",Ae=fe.current||!tt;function _e(gt){M||G||!gt||!Ae||(S.context.setOpen(!0,Et(A1,$e)),Y||ke($e))}if(fe.current){const gt=ge.currentTarget.value;he(gt),gt===""&&!S.state.openOnInputClick&&!S.state.inputInsidePopup&&S.context.setOpen(!1,Et(Lc,$e));const rt=gt.trim(),xt=Y&&rt!=="";_e(rt),$&&S.state.activeIndex!==null&&!xt&&ke($e);return}const He=Et(A1,$e);if(S.context.setInputValue(ge.currentTarget.value,He),He.isCanceled)return;const Ue=ge.currentTarget.value==="",Ve=Et(Lc,$e);Ue&&!S.state.inputInsidePopup&&(D==="single"&&S.context.setSelectedValue(null,Ve),S.state.openOnInputClick||S.context.setOpen(!1,Ve)),_e(ge.currentTarget.value.trim()),$&&S.state.activeIndex!==null&&!Y&&ke($e)},onKeyDown(ge){var _e;if(ge.ctrlKey||ge.shiftKey||ge.altKey||ge.metaKey)return;if(G||M){M&&ge.key==="Enter"&&$&&S.state.activeIndex!==null&&No(ge);return}const $e=ge.currentTarget,Ye=$e.scrollWidth-$e.clientWidth,tt=E==="rtl";if(ge.key==="Home"){No(ge);const He=$ne&&tt?$e.value.length:0;$e.setSelectionRange(He,He),$e.scrollLeft=0;return}if(ge.key==="End"){No(ge);const He=$ne&&tt?0:$e.value.length;$e.setSelectionRange(He,He),$e.scrollLeft=tt?-Ye:Ye;return}if(!B&&ge.key==="Escape"){const He=D==="multiple"&&Array.isArray(H)?H.length===0:H===null,Ue=Et(Vw,ge.nativeEvent),Ve=D==="multiple"?[]:null;S.context.setInputValue("",Ue),S.context.setSelectedValue(Ve,Ue),!He&&!S.state.inline&&!Ue.isPropagationAllowed&&ge.stopPropagation();return}if(b&&ge.key==="Backspace"&&$e.value===""&&Array.isArray(H)&&H.length>0){const He=b.chipsRef.current.length,Ue=He>0?He-1:H.length-1,Ve=H.filter((gt,rt)=>rt!==Ue);ke(ge.nativeEvent),S.context.setSelectedValue(Ve,Et(ki,ge.nativeEvent));return}const Ae=Be(ge);if(Ae!==void 0&&((_e=b==null?void 0:b.chipsRef.current[Ae])==null||_e.focus()),ge.which!==229&&ge.key==="Enter"&&$){const He=S.state.activeIndex,Ue=ge.nativeEvent;if(He===null){if(W)return;S.context.setOpen(!1,Et(ki,Ue));return}No(ge),HOe(S,He,Ue)}}},Ee],stateAttributesMapping:k1t}),Le=w?y.jsx(z1e.Provider,{value:$1e,children:Oe}):Oe;return y.jsxs(A.Fragment,{children:[$&&de&&y.jsx(VOe,{ref:S.context.startDismissRef}),Le]})}),R1t=A.forwardRef(function(t,n){const{render:r,className:i,style:o,...s}=t;return $n("span",t,{ref:n,props:[{"aria-hidden":!0,children:"▼"},s]})}),M1t=A.createContext(null);function _1t(){return A.useContext(M1t)}function N1t(e){const{children:t}=e,{filteredItems:n}=aA(),r=_1t(),i=r?r.items:n;return y.jsx(A.Fragment,{children:i.map(t)})}const L1t=A.forwardRef(function(t,n){var r;const{render:i,className:o,style:s,children:a,...l}=t,u=Bd(),c=TY(),d=!!OY(!0),{filteredItems:h,hasItems:m}=aA(),g=u.useState("selectionMode"),b=u.useState("grid"),v=u.useState("readOnly"),w=u.useState("listProps"),S=u.useState("virtualized"),C=u.useState("forceMounted"),E=g==="multiple",T=h.length===0,O=at(z=>{u.set("positionerElement",z)}),M=at(z=>{u.set("listElement",z)}),N=A.useMemo(()=>typeof a=="function"?r||(r=y.jsx(N1t,{children:a})):a,[a]),I={empty:T},D=c.useState("floatingId"),P=$n("div",t,{state:I,ref:[n,M,d?null:O],props:[w,{children:N,tabIndex:-1,id:D,role:b?"grid":"listbox","aria-multiselectable":E?"true":void 0,"aria-readonly":!b&&v?!0:void 0,onKeyDown(z){if(!(u.state.disabled||u.state.readOnly)&&z.key==="Enter"){const $=u.state.activeIndex;if($==null)return;No(z),HOe(u,$,z.nativeEvent)}}},l]});if(S)return P;const F=m&&!C?void 0:u.context.labelsRef;return y.jsx(_2,{elementsRef:u.context.listRef,labelsRef:F,children:P})}),I1t="⁠",P1t=200;function j1t(e){const t=e.ownerDocument.createTreeWalker(e,NodeFilter.SHOW_TEXT);let n=null;for(;t.nextNode();){const r=t.currentNode;r.nodeValue!==""&&(n=r)}return n}function D1t(e=!0){const t=Qi(),n=A.useRef(null);return A.useEffect(()=>{if(!e||k2)return;const r=n.current;if(r==null)return;const i=j1t(r);if(i==null)return;const o=i.data,s=`${o}${I1t}`;return i.nodeValue=s,t.start(P1t,()=>{i.nodeValue===s&&(i.nodeValue=o)}),()=>{t.clear(),i.nodeValue===s&&(i.nodeValue=o)}},[e,n,t]),n}const WOe=A.createContext(void 0);function $1t(){const e=A.useContext(WOe);if(e===void 0)throw new Error(Br(20));return e}const z1t=A.forwardRef(function(t,n){const{keepMounted:r=!1,...i}=t,o=Bd(),s=o.useState("mounted"),a=o.useState("forceMounted");return s||r||a?y.jsx(WOe.Provider,{value:r,children:y.jsx(OP,{ref:n,...i})}):null}),F1t=A.forwardRef(function(t,n){const{render:r,className:i,anchor:o,positionMethod:s,side:a,align:l,sideOffset:u,alignOffset:c,collisionBoundary:d="clipping-ancestors",collisionPadding:h,arrowPadding:m,sticky:g,disableAnchorTracking:b=!1,collisionAvoidance:v=iG,style:w,...S}=t,C=Bd(),E=TY(),T=$1t(),O=C.useState("modal"),M=C.useState("open"),N=C.useState("mounted"),I=C.useState("openMethod"),D=C.useState("positionerElement"),P=C.useState("triggerElement"),F=C.useState("inputElement"),z=C.useState("inputGroupElement"),$=C.useState("inputInsidePopup"),B=C.useState("transitionStatus"),H=AY(),W=$P({anchor:o??($?P:z??F),floatingRootContext:E,positionMethod:s,mounted:N,side:a,sideOffset:u,align:l,alignOffset:c,arrowPadding:m,collisionBoundary:d,collisionPadding:h,sticky:g,disableAnchorTracking:b,keepMounted:T,collisionAvoidance:v,lazyFlip:!0});AG(M&&O,I==="touch",D,P);const q={open:M,side:W.side,align:W.align,anchorHidden:W.anchorHidden,empty:H};et(()=>{C.set("popupSide",W.side)},[C,W.side]);const Y=at(G=>{C.set("positionerElement",G)}),Q=FP(t,q,{styles:W.positionerStyles,transitionStatus:B,props:S,refs:[n,Y],hidden:!N,inert:!M});return y.jsxs(UOe.Provider,{value:W,children:[N&&O&&y.jsx(zP,{inert:M2(!M),cutout:z??F??P}),Q]})}),B1t={...Hw,...Bw},H1t=A.forwardRef(function(t,n){const{render:r,className:i,style:o,initialFocus:s,finalFocus:a,...l}=t,u=Bd(),c=OY(),d=TY(),h=u.useState("mounted"),m=u.useState("open"),g=u.useState("openMethod"),b=u.useState("popupProps"),v=u.useState("transitionStatus"),w=u.useState("inputInsidePopup"),S=u.useState("inputElement"),C=u.useState("modal"),E=u.useState("id"),T=AY(),O=l.id??(w?p1t(E):void 0);et(()=>{var z;return u.set("popupId",((z=u.context.popupRef.current)==null?void 0:z.id)||O),()=>{u.set("popupId",void 0)}},[u,O]),Ig({open:m,ref:u.context.popupRef,onComplete(){m&&u.context.onOpenChangeComplete(!0)}});const M={open:m,side:c.side,align:c.align,anchorHidden:c.anchorHidden,transitionStatus:v,empty:T},N=$n("div",t,{state:M,ref:[n,u.context.popupRef],props:[b,{id:O,role:w?"dialog":"presentation",onFocus(z){var B;const $=ji(z.nativeEvent);g!=="touch"&&(Rt(u.state.listElement,$)||$===z.currentTarget)&&((B=u.context.inputRef.current)==null||B.focus())}},N2(v),l],stateAttributesMapping:B1t}),D=s===void 0?w?z=>z==="touch"?u.context.popupRef.current:S:!1:s;let P;a!=null?P=a:P=w?void 0:!1;const F=!w||C;return y.jsx(RP,{context:d,disabled:!h,modal:F,openInteractionType:g,initialFocus:D,returnFocus:P,getInsideElements:()=>[u.context.startDismissRef.current,u.context.endDismissRef.current],children:y.jsxs(A.Fragment,{children:[N,F&&y.jsx(VOe,{ref:u.context.endDismissRef})]})})}),U1t=A.createContext(void 0),V1t=A.createContext(!1);function W1t(){return A.useContext(V1t)}function qOe(e){const{componentProps:t,forwardedRef:n,virtualized:r,indexFromFilter:i}=e,{render:o,className:s,style:a,value:l=null,index:u,disabled:c=!1,nativeButton:d=!1,...h}=t,m=A.useRef(null),g=L2({guess:!0,index:u,textRef:m}),b=Bd(),v=W1t(),w=f1t(),{props:S,id:C,selectionMode:E,disabled:T,readOnly:O,isItemEqualToValue:M}=b.useState("itemRoot"),N=T||c,I=E!=="none",D=u??i??g.index,P=D!==-1,F=b.useState("isActive",D),z=b.useState("isSelected",l),$=A.useRef(null),B=C!=null&&P?`${C}-${D}`:void 0,H=z&&I;et(()=>{if(!(P&&(r||u!=null)))return;const te=b.context.listRef.current;return te[D]=$.current,()=>{delete te[D]}},[P,r,D,u,b]),et(()=>{if(!P||w)return;const K=b.context.valuesRef.current;return K[D]=l,()=>{delete K[D]}},[P,w,D,l,b]),et(()=>{if(!P||w)return;const K=b.state.selectedValue;let te=b.state.selectedIndex;b.state.selectionMode==="multiple"&&Array.isArray(K)?te=B1e(D,l,b.context.valuesRef.current,K,M,te):cu(l,K,M)&&(te=D),b.set("selectedIndex",te)},[P,w,b,D,l,M]);const{getButtonProps:U,buttonRef:W}=Kh({disabled:N,focusableWhenDisabled:!0,native:d,composite:!0}),q={disabled:N,selected:H,highlighted:F};function Y(K){function te(){b.context.handleSelection(K,l)}b.state.submitOnItemClick?(mi.flushSync(te),b.context.requestSubmit()):te()}const Q={id:B,role:v?"gridcell":"option","aria-selected":I?H:void 0,tabIndex:void 0,onPointerDownCapture(K){K.isPrimary&&(b.context.pointerDownItemRef.current=K.currentTarget),K.preventDefault()},onMouseDown(K){K.preventDefault()},onClick(K){N||O||Y(K.nativeEvent)},onMouseUp(K){const te=b.context.pointerDownItemRef.current===K.currentTarget;b.context.pointerDownItemRef.current=null,!(N||O||K.button!==0||te||!F)&&Y(K.nativeEvent)}},G=$n("div",t,{ref:[W,n,g.ref,$],state:q,props:[S,Q,h,U]}),le=A.useMemo(()=>({selected:H,textRef:m}),[H,m]);return y.jsx(U1t.Provider,{value:le,children:G})}function q1t(e){const{componentProps:t,forwardedRef:n}=e,i=Bd().useState("isItemEqualToValue"),{flatFilteredValues:o}=aA(),s=t.value??null,a=_1(o,s,i);return y.jsx(qOe,{componentProps:t,forwardedRef:n,virtualized:!0,indexFromFilter:a})}const G1t=A.memo(A.forwardRef(function(t,n){const i=Bd().useState("virtualized");return i&&t.index==null?y.jsx(q1t,{componentProps:t,forwardedRef:n}):y.jsx(qOe,{componentProps:t,forwardedRef:n,virtualized:i,indexFromFilter:void 0})})),K1t=G1t,Y1t=A.forwardRef(function(t,n){const{render:r,className:i,style:o,children:s,...a}=t,{filteredItems:l}=aA(),u=Bd(),c=D1t(),d=l.length===0?s:null;return $n("div",t,{ref:[n,u.context.emptyRef,c],props:[{children:d,role:"status","aria-live":"polite","aria-atomic":!0},a]})}),X1t=X("w-full rounded-md border py-1.5 pl-2 pr-7 text-xs outline-none","border-zinc-200 bg-white text-zinc-900 placeholder:text-zinc-400","dark:border-zinc-800 dark:bg-zinc-900 dark:text-zinc-100 dark:placeholder:text-zinc-600","focus-visible:border-sky-500 focus-visible:ring-2 focus-visible:ring-sky-500/15","disabled:opacity-40");function Q1t({value:e,onValueChange:t,onSelect:n,options:r,emptyMessage:i="Nothing here matches that.",placeholder:o,disabled:s,ariaLabel:a,className:l}){const[u,c]=A.useState(void 0),d=u===void 0?r:r.filter(h=>Z1t(h,u));return y.jsxs(x1t,{items:d,filteredItems:d,value:e,onValueChange:(h,m)=>{m.reason!=="item-press"&&(c(h),t(h))},onOpenChange:()=>c(void 0),openOnInputClick:!0,disabled:s,children:[y.jsxs("div",{className:X("relative",l),children:[y.jsx(O1t,{"aria-label":a,placeholder:o,spellCheck:!1,className:X1t}),y.jsx(R1t,{className:"pointer-events-none absolute inset-y-0 right-2 flex items-center",children:y.jsx(Eq,{size:12,className:"shrink-0 text-zinc-400"})})]}),y.jsx(z1t,{children:y.jsx(F1t,{sideOffset:4,className:"z-50",children:y.jsxs(H1t,{className:X("max-h-72 w-[var(--anchor-width)] overflow-y-auto rounded-md border p-1 shadow-md","border-zinc-200 bg-white dark:border-zinc-800 dark:bg-zinc-900","origin-[var(--transform-origin)] transition-[opacity,transform] duration-100 ease-out","data-[starting-style]:scale-95 data-[starting-style]:opacity-0","data-[ending-style]:scale-95 data-[ending-style]:opacity-0","motion-reduce:transition-none motion-reduce:data-[starting-style]:scale-100 motion-reduce:data-[ending-style]:scale-100"),children:[y.jsx(Y1t,{className:"px-2 py-1.5 text-[11px] leading-relaxed text-zinc-400 dark:text-zinc-500",children:d.length===0?i:null}),y.jsx(L1t,{children:d.map(h=>y.jsxs(K1t,{value:h,disabled:h.disabled,onClick:()=>{h.disabled||n==null||n(h)},className:X("flex cursor-default items-start gap-2 rounded-sm px-2 py-1.5 text-xs outline-none","data-[highlighted]:bg-zinc-100 dark:data-[highlighted]:bg-zinc-800","data-[disabled]:opacity-40"),children:[y.jsx("span",{className:"mt-0.5 w-3 shrink-0",children:h.value===e&&!h.disabled&&y.jsx(aP,{size:11,className:"text-sky-600"})}),y.jsxs("span",{className:"min-w-0 flex-1",children:[y.jsx("span",{className:"block truncate",title:h.label,children:h.label}),h.hint&&y.jsx("span",{className:"mt-0.5 block truncate font-mono text-[10px] text-zinc-400 dark:text-zinc-500",children:h.hint})]})]},h.value))})]})})})]})}function Z1t(e,t){const n=t.trim().toLowerCase();return n.length===0?!0:`${e.label} ${e.keywords??""}`.toLowerCase().includes(n)}function Ple({label:e,hint:t,...n}){return y.jsxs("label",{className:"block",children:[y.jsx("span",{className:"mb-1 block font-mono text-[10px] uppercase tracking-[0.14em] text-zinc-400 dark:text-zinc-500",children:e}),y.jsx(Q1t,{...n}),t&&y.jsx("span",{className:"mt-1 block text-[11px] leading-relaxed text-zinc-400 dark:text-zinc-500",children:t})]})}var k8,jle;function Fg(){if(jle)return k8;jle=1;function e(t){var n=typeof t;return t!=null&&(n=="object"||n=="function")}return k8=e,k8}var C8,Dle;function GOe(){if(Dle)return C8;Dle=1;var e=typeof qO=="object"&&qO&&qO.Object===Object&&qO;return C8=e,C8}var E8,$le;function Hd(){if($le)return E8;$le=1;var e=GOe(),t=typeof self=="object"&&self&&self.Object===Object&&self,n=e||t||Function("return this")();return E8=n,E8}var T8,zle;function J1t(){if(zle)return T8;zle=1;var e=Hd(),t=function(){return e.Date.now()};return T8=t,T8}var A8,Fle;function ext(){if(Fle)return A8;Fle=1;var e=/\s/;function t(n){for(var r=n.length;r--&&e.test(n.charAt(r)););return r}return A8=t,A8}var O8,Ble;function txt(){if(Ble)return O8;Ble=1;var e=ext(),t=/^\s+/;function n(r){return r&&r.slice(0,e(r)+1).replace(t,"")}return O8=n,O8}var R8,Hle;function lA(){if(Hle)return R8;Hle=1;var e=Hd(),t=e.Symbol;return R8=t,R8}var M8,Ule;function nxt(){if(Ule)return M8;Ule=1;var e=lA(),t=Object.prototype,n=t.hasOwnProperty,r=t.toString,i=e?e.toStringTag:void 0;function o(s){var a=n.call(s,i),l=s[i];try{s[i]=void 0;var u=!0}catch{}var c=r.call(s);return u&&(a?s[i]=l:delete s[i]),c}return M8=o,M8}var _8,Vle;function rxt(){if(Vle)return _8;Vle=1;var e=Object.prototype,t=e.toString;function n(r){return t.call(r)}return _8=n,_8}var N8,Wle;function Zh(){if(Wle)return N8;Wle=1;var e=lA(),t=nxt(),n=rxt(),r="[object Null]",i="[object Undefined]",o=e?e.toStringTag:void 0;function s(a){return a==null?a===void 0?i:r:o&&o in Object(a)?t(a):n(a)}return N8=s,N8}var L8,qle;function Jh(){if(qle)return L8;qle=1;function e(t){return t!=null&&typeof t=="object"}return L8=e,L8}var I8,Gle;function rS(){if(Gle)return I8;Gle=1;var e=Zh(),t=Jh(),n="[object Symbol]";function r(i){return typeof i=="symbol"||t(i)&&e(i)==n}return I8=r,I8}var P8,Kle;function KOe(){if(Kle)return P8;Kle=1;var e=txt(),t=Fg(),n=rS(),r=NaN,i=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,s=/^0o[0-7]+$/i,a=parseInt;function l(u){if(typeof u=="number")return u;if(n(u))return r;if(t(u)){var c=typeof u.valueOf=="function"?u.valueOf():u;u=t(c)?c+"":c}if(typeof u!="string")return u===0?u:+u;u=e(u);var d=o.test(u);return d||s.test(u)?a(u.slice(2),d?2:8):i.test(u)?r:+u}return P8=l,P8}var j8,Yle;function YOe(){if(Yle)return j8;Yle=1;var e=Fg(),t=J1t(),n=KOe(),r="Expected a function",i=Math.max,o=Math.min;function s(a,l,u){var c,d,h,m,g,b,v=0,w=!1,S=!1,C=!0;if(typeof a!="function")throw new TypeError(r);l=n(l)||0,e(u)&&(w=!!u.leading,S="maxWait"in u,h=S?i(n(u.maxWait)||0,l):h,C="trailing"in u?!!u.trailing:C);function E(z){var $=c,B=d;return c=d=void 0,v=z,m=a.apply(B,$),m}function T(z){return v=z,g=setTimeout(N,l),w?E(z):m}function O(z){var $=z-b,B=z-v,H=l-$;return S?o(H,h-B):H}function M(z){var $=z-b,B=z-v;return b===void 0||$>=l||$<0||S&&B>=h}function N(){var z=t();if(M(z))return I(z);g=setTimeout(N,O(z))}function I(z){return g=void 0,C&&c?E(z):(c=d=void 0,m)}function D(){g!==void 0&&clearTimeout(g),v=0,c=b=d=g=void 0}function P(){return g===void 0?m:I(t())}function F(){var z=t(),$=M(z);if(c=arguments,d=this,b=z,$){if(g===void 0)return T(b);if(S)return clearTimeout(g),g=setTimeout(N,l),E(b)}return g===void 0&&(g=setTimeout(N,l)),m}return F.cancel=D,F.flush=P,F}return j8=s,j8}var ixt=YOe();const oxt=cr(ixt),sxt=[],Xle={width:0,height:0,top:0,left:0};function axt(){let{initialSize:e=Xle,debounceTime:t=300,ignoreDimensions:n=sxt,enableDebounceLeadingCall:r=!0,resizeObserverPolyfill:i}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const o=A.useRef(null),s=A.useRef(0),[a,l]=A.useState({...Xle,...e}),u=A.useMemo(()=>{const c=Array.isArray(n)?n:[n];return oxt(d=>{l(h=>Object.keys(h).filter(v=>h[v]!==d[v]).every(v=>c.includes(v))?h:d)},t,{leading:r})},[t,r,n]);return A.useEffect(()=>{const c=i||window.ResizeObserver,d=new c(h=>{h.forEach(m=>{const{left:g,top:b,width:v,height:w}=(m==null?void 0:m.contentRect)??{};s.current=window.requestAnimationFrame(()=>{u({width:v,height:w,top:b,left:g})})})});return o.current&&d.observe(o.current),()=>{window.cancelAnimationFrame(s.current),d.disconnect(),u.cancel()}},[u,i]),{parentRef:o,resize:u,...a}}const lxt={width:"100%",height:"100%"};function RY(e){let{className:t,children:n,debounceTime:r,ignoreDimensions:i,initialSize:o,parentSizeStyles:s=lxt,enableDebounceLeadingCall:a=!0,resizeObserverPolyfill:l,...u}=e;const{parentRef:c,resize:d,...h}=axt({initialSize:o,debounceTime:r,ignoreDimensions:i,enableDebounceLeadingCall:a,resizeObserverPolyfill:l});return y.jsx("div",{style:s,ref:c,className:t,...u,children:n({...h,ref:c.current,resize:d})})}function Gr(e){return function(){return e}}const XOe=Math.cos,BL=Math.sin,lc=Math.sqrt,HL=Math.PI,$j=2*HL,QU=Math.PI,ZU=2*QU,$0=1e-6,uxt=ZU-$0;function QOe(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function cxt(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return QOe;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 dxt{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?QOe:cxt(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,s){this._append`C${+t},${+n},${+r},${+i},${this._x1=+o},${this._y1=+s}`}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 s=this._x1,a=this._y1,l=r-t,u=i-n,c=s-t,d=a-n,h=c*c+d*d;if(this._x1===null)this._append`M${this._x1=t},${this._y1=n}`;else if(h>$0)if(!(Math.abs(d*l-u*c)>$0)||!o)this._append`L${this._x1=t},${this._y1=n}`;else{let m=r-s,g=i-a,b=l*l+u*u,v=m*m+g*g,w=Math.sqrt(b),S=Math.sqrt(h),C=o*Math.tan((QU-Math.acos((b+h-v)/(2*w*S)))/2),E=C/S,T=C/w;Math.abs(E-1)>$0&&this._append`L${t+E*c},${n+E*d}`,this._append`A${o},${o},0,0,${+(d*m>c*g)},${this._x1=t+T*l},${this._y1=n+T*u}`}}arc(t,n,r,i,o,s){if(t=+t,n=+n,r=+r,s=!!s,r<0)throw new Error(`negative radius: ${r}`);let a=r*Math.cos(i),l=r*Math.sin(i),u=t+a,c=n+l,d=1^s,h=s?i-o:o-i;this._x1===null?this._append`M${u},${c}`:(Math.abs(this._x1-u)>$0||Math.abs(this._y1-c)>$0)&&this._append`L${u},${c}`,r&&(h<0&&(h=h%ZU+ZU),h>uxt?this._append`A${r},${r},0,1,${d},${t-a},${n-l}A${r},${r},0,1,${d},${this._x1=u},${this._y1=c}`:h>$0&&this._append`A${r},${r},0,${+(h>=QU)},${d},${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 MY(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 dxt(t)}function _Y(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function ZOe(e){this._context=e}ZOe.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 zj(e){return new ZOe(e)}function JOe(e){return e[0]}function eRe(e){return e[1]}function Fj(e,t){var n=Gr(!0),r=null,i=zj,o=null,s=MY(a);e=typeof e=="function"?e:e===void 0?JOe:Gr(e),t=typeof t=="function"?t:t===void 0?eRe:Gr(t);function a(l){var u,c=(l=_Y(l)).length,d,h=!1,m;for(r==null&&(o=i(m=s())),u=0;u<=c;++u)!(u<c&&n(d=l[u],u,l))===h&&((h=!h)?o.lineStart():o.lineEnd()),h&&o.point(+e(d,u,l),+t(d,u,l));if(m)return o=null,m+""||null}return a.x=function(l){return arguments.length?(e=typeof l=="function"?l:Gr(+l),a):e},a.y=function(l){return arguments.length?(t=typeof l=="function"?l:Gr(+l),a):t},a.defined=function(l){return arguments.length?(n=typeof l=="function"?l:Gr(!!l),a):n},a.curve=function(l){return arguments.length?(i=l,r!=null&&(o=i(r)),a):i},a.context=function(l){return arguments.length?(l==null?r=o=null:o=i(r=l),a):r},a}function dC(e,t,n){var r=null,i=Gr(!0),o=null,s=zj,a=null,l=MY(u);e=typeof e=="function"?e:e===void 0?JOe:Gr(+e),t=typeof t=="function"?t:Gr(t===void 0?0:+t),n=typeof n=="function"?n:n===void 0?eRe:Gr(+n);function u(d){var h,m,g,b=(d=_Y(d)).length,v,w=!1,S,C=new Array(b),E=new Array(b);for(o==null&&(a=s(S=l())),h=0;h<=b;++h){if(!(h<b&&i(v=d[h],h,d))===w)if(w=!w)m=h,a.areaStart(),a.lineStart();else{for(a.lineEnd(),a.lineStart(),g=h-1;g>=m;--g)a.point(C[g],E[g]);a.lineEnd(),a.areaEnd()}w&&(C[h]=+e(v,h,d),E[h]=+t(v,h,d),a.point(r?+r(v,h,d):C[h],n?+n(v,h,d):E[h]))}if(S)return a=null,S+""||null}function c(){return Fj().defined(i).curve(s).context(o)}return u.x=function(d){return arguments.length?(e=typeof d=="function"?d:Gr(+d),r=null,u):e},u.x0=function(d){return arguments.length?(e=typeof d=="function"?d:Gr(+d),u):e},u.x1=function(d){return arguments.length?(r=d==null?null:typeof d=="function"?d:Gr(+d),u):r},u.y=function(d){return arguments.length?(t=typeof d=="function"?d:Gr(+d),n=null,u):t},u.y0=function(d){return arguments.length?(t=typeof d=="function"?d:Gr(+d),u):t},u.y1=function(d){return arguments.length?(n=d==null?null:typeof d=="function"?d:Gr(+d),u):n},u.lineX0=u.lineY0=function(){return c().x(e).y(t)},u.lineY1=function(){return c().x(e).y(n)},u.lineX1=function(){return c().x(r).y(t)},u.defined=function(d){return arguments.length?(i=typeof d=="function"?d:Gr(!!d),u):i},u.curve=function(d){return arguments.length?(s=d,o!=null&&(a=s(o)),u):s},u.context=function(d){return arguments.length?(d==null?o=a=null:a=s(o=d),u):o},u}class tRe{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 fxt(e){return new tRe(e,!0)}function hxt(e){return new tRe(e,!1)}const NY={draw(e,t){const n=lc(t/HL);e.moveTo(n,0),e.arc(0,0,n,0,$j)}},pxt={draw(e,t){const n=lc(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()}},nRe=lc(1/3),mxt=nRe*2,gxt={draw(e,t){const n=lc(t/mxt),r=n*nRe;e.moveTo(0,-n),e.lineTo(r,0),e.lineTo(0,n),e.lineTo(-r,0),e.closePath()}},yxt={draw(e,t){const n=lc(t),r=-n/2;e.rect(r,r,n,n)}},bxt=.8908130915292852,rRe=BL(HL/10)/BL(7*HL/10),vxt=BL($j/10)*rRe,xxt=-XOe($j/10)*rRe,wxt={draw(e,t){const n=lc(t*bxt),r=vxt*n,i=xxt*n;e.moveTo(0,-n),e.lineTo(r,i);for(let o=1;o<5;++o){const s=$j*o/5,a=XOe(s),l=BL(s);e.lineTo(l*n,-a*n),e.lineTo(a*r-l*i,l*r+a*i)}e.closePath()}},D8=lc(3),Sxt={draw(e,t){const n=-lc(t/(D8*3));e.moveTo(0,n*2),e.lineTo(-D8*n,-n),e.lineTo(D8*n,-n),e.closePath()}},Ol=-.5,Rl=lc(3)/2,JU=1/lc(12),kxt=(JU/2+1)*3,Cxt={draw(e,t){const n=lc(t/kxt),r=n/2,i=n*JU,o=r,s=n*JU+n,a=-o,l=s;e.moveTo(r,i),e.lineTo(o,s),e.lineTo(a,l),e.lineTo(Ol*r-Rl*i,Rl*r+Ol*i),e.lineTo(Ol*o-Rl*s,Rl*o+Ol*s),e.lineTo(Ol*a-Rl*l,Rl*a+Ol*l),e.lineTo(Ol*r+Rl*i,Ol*i-Rl*r),e.lineTo(Ol*o+Rl*s,Ol*s-Rl*o),e.lineTo(Ol*a+Rl*l,Ol*l-Rl*a),e.closePath()}};function Ext(e,t){let n=null,r=MY(i);e=typeof e=="function"?e:Gr(e||NY),t=typeof t=="function"?t:Gr(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:Gr(o),i):e},i.size=function(o){return arguments.length?(t=typeof o=="function"?o:Gr(+o),i):t},i.context=function(o){return arguments.length?(n=o??null,i):n},i}function UL(){}function VL(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 iRe(e){this._context=e}iRe.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:VL(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:VL(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function Txt(e){return new iRe(e)}function oRe(e){this._context=e}oRe.prototype={areaStart:UL,areaEnd:UL,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:VL(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function Axt(e){return new oRe(e)}function sRe(e){this._context=e}sRe.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:VL(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function Oxt(e){return new sRe(e)}function aRe(e){this._context=e}aRe.prototype={areaStart:UL,areaEnd:UL,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 Rxt(e){return new aRe(e)}function Qle(e){return e<0?-1:1}function Zle(e,t,n){var r=e._x1-e._x0,i=t-e._x1,o=(e._y1-e._y0)/(r||i<0&&-0),s=(n-e._y1)/(i||r<0&&-0),a=(o*i+s*r)/(r+i);return(Qle(o)+Qle(s))*Math.min(Math.abs(o),Math.abs(s),.5*Math.abs(a))||0}function Jle(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function $8(e,t,n){var r=e._x0,i=e._y0,o=e._x1,s=e._y1,a=(o-r)/3;e._context.bezierCurveTo(r+a,i+a*t,o-a,s-a*n,o,s)}function WL(e){this._context=e}WL.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:$8(this,this._t0,Jle(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,$8(this,Jle(this,n=Zle(this,e,t)),n);break;default:$8(this,this._t0,n=Zle(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function lRe(e){this._context=new uRe(e)}(lRe.prototype=Object.create(WL.prototype)).point=function(e,t){WL.prototype.point.call(this,t,e)};function uRe(e){this._context=e}uRe.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 LY(e){return new WL(e)}function Mxt(e){return new lRe(e)}function cRe(e){this._context=e}cRe.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=eue(e),i=eue(t),o=0,s=1;s<n;++o,++s)this._context.bezierCurveTo(r[0][o],i[0][o],r[1][o],i[1][o],e[s],t[s]);(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 eue(e){var t,n=e.length-1,r,i=new Array(n),o=new Array(n),s=new Array(n);for(i[0]=0,o[0]=2,s[0]=e[0]+2*e[1],t=1;t<n-1;++t)i[t]=1,o[t]=4,s[t]=4*e[t]+2*e[t+1];for(i[n-1]=2,o[n-1]=7,s[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)r=i[t]/o[t-1],o[t]-=r,s[t]-=r*s[t-1];for(i[n-1]=s[n-1]/o[n-1],t=n-2;t>=0;--t)i[t]=(s[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 dRe(e){return new cRe(e)}function Bj(e,t){this._context=e,this._t=t}Bj.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 _xt(e){return new Bj(e,.5)}function Nxt(e){return new Bj(e,0)}function Lxt(e){return new Bj(e,1)}function Zx(e,t){if((s=e.length)>1)for(var n=1,r,i,o=e[t[0]],s,a=o.length;n<s;++n)for(i=o,o=e[t[n]],r=0;r<a;++r)o[r][1]+=o[r][0]=isNaN(i[r][1])?i[r][0]:i[r][1]}function eV(e){for(var t=e.length,n=new Array(t);--t>=0;)n[t]=t;return n}function Ixt(e,t){return e[t]}function Pxt(e){const t=[];return t.key=e,t}function jxt(){var e=Gr([]),t=eV,n=Zx,r=Ixt;function i(o){var s=Array.from(e.apply(this,arguments),Pxt),a,l=s.length,u=-1,c;for(const d of o)for(a=0,++u;a<l;++a)(s[a][u]=[0,+r(d,s[a].key,u,o)]).data=d;for(a=0,c=_Y(t(s));a<l;++a)s[c[a]].index=a;return n(s,c),s}return i.keys=function(o){return arguments.length?(e=typeof o=="function"?o:Gr(Array.from(o)),i):e},i.value=function(o){return arguments.length?(r=typeof o=="function"?o:Gr(+o),i):r},i.order=function(o){return arguments.length?(t=o==null?eV:typeof o=="function"?o:Gr(Array.from(o)),i):t},i.offset=function(o){return arguments.length?(n=o??Zx,i):n},i}function Dxt(e,t){if((r=e.length)>0){for(var n,r,i=0,o=e[0].length,s;i<o;++i){for(s=n=0;n<r;++n)s+=e[n][i][1]||0;if(s)for(n=0;n<r;++n)e[n][i][1]/=s}Zx(e,t)}}function $xt(e,t){if((i=e.length)>0){for(var n=0,r=e[t[0]],i,o=r.length;n<o;++n){for(var s=0,a=0;s<i;++s)a+=e[s][n][1]||0;r[n][1]+=r[n][0]=-a/2}Zx(e,t)}}function zxt(e,t){if(!(!((s=e.length)>0)||!((o=(i=e[t[0]]).length)>0))){for(var n=0,r=1,i,o,s;r<o;++r){for(var a=0,l=0,u=0;a<s;++a){for(var c=e[t[a]],d=c[r][1]||0,h=c[r-1][1]||0,m=(d-h)/2,g=0;g<a;++g){var b=e[t[g]],v=b[r][1]||0,w=b[r-1][1]||0;m+=v-w}l+=d,u+=m*d}i[r-1][1]+=i[r-1][0]=n,l&&(n-=u/l)}i[r-1][1]+=i[r-1][0]=n,Zx(e,t)}}var z8={exports:{}};/*!
2833
2833
  Copyright (c) 2018 Jed Watson.
2834
2834
  Licensed under the MIT License (MIT), see
2835
2835
  http://jedwatson.github.io/classnames
2836
- */var Fle;function Mxt(){return Fle||(Fle=1,(function(e){(function(){var t={}.hasOwnProperty;function n(){for(var o="",s=0;s<arguments.length;s++){var a=arguments[s];a&&(o=i(o,r(a)))}return o}function r(o){if(typeof o=="string"||typeof o=="number")return o;if(typeof o!="object")return"";if(Array.isArray(o))return n.apply(null,o);if(o.toString!==Object.prototype.toString&&!o.toString.toString().includes("[native code]"))return o.toString();var s="";for(var a in o)t.call(o,a)&&o[a]&&(s=i(s,a));return s}function i(o,s){return s?o?o+" "+s:o+s:o}e.exports?(n.default=n,e.exports=n):window.classNames=n})()})(E8)),E8.exports}var _xt=Mxt();const rS=cr(_xt);function Hu(e,t){e(t)}function Nxt(){let{x:e,x0:t,x1:n,y:r,y0:i,y1:o,defined:s,curve:a}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const l=dC();return e&&Hu(l.x,e),t&&Hu(l.x0,t),n&&Hu(l.x1,n),r&&Hu(l.y,r),i&&Hu(l.y0,i),o&&Hu(l.y1,o),s&&l.defined(s),a&&l.curve(a),l}function Lxt(){let{x:e,y:t,defined:n,curve:r}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const i=Fj();return e&&Hu(i.x,e),t&&Hu(i.y,t),n&&i.defined(n),r&&i.curve(r),i}function uRe(e){let{top:t=0,left:n=0,transform:r,className:i,children:o,innerRef:s,...a}=e;return y.jsx("g",{ref:s,className:rS("visx-group",i),transform:r||`translate(${n}, ${t})`,...a,children:o})}function cRe(e){let{from:t={x:0,y:0},to:n={x:1,y:1},fill:r="transparent",className:i,innerRef:o,...s}=e;const a=t.x===n.x||t.y===n.y;return y.jsx("line",{ref:o,className:rS("visx-line",i),x1:t.x,y1:t.y,x2:n.x,y2:n.y,fill:r,shapeRendering:a?"crispEdges":"auto",...s})}function LY(e){let{children:t,data:n=[],x:r,y:i,fill:o="transparent",className:s,curve:a,innerRef:l,defined:u=()=>!0,...c}=e;const d=Lxt({x:r,y:i,defined:u,curve:a});return t?y.jsx(y.Fragment,{children:t({path:d})}):y.jsx("path",{ref:l,className:rS("visx-linepath",s),d:d(n)||"",fill:o,strokeLinecap:"round",...c})}function IY(e){let{x:t,x0:n,x1:r,y:i,y1:o,y0:s,yScale:a,data:l=[],defined:u=()=>!0,className:c,curve:d,innerRef:h,children:m,...g}=e;const b=Nxt({x:t,x0:n,x1:r,defined:u,curve:d});return s==null?b.y0(a.range()[0]):Hu(b.y0,s),i&&!o&&Hu(b.y1,i),o&&!i&&Hu(b.y1,o),m?y.jsx(y.Fragment,{children:m({path:b})}):y.jsx("path",{ref:h,className:rS("visx-area-closed",c),d:b(l)||"",...g})}function Hj(e){return e===!1?{left:!1,right:!1,any:!1}:e==="left"?{left:!0,right:!1,any:!0}:e==="right"?{left:!1,right:!0,any:!0}:{left:!0,right:!0,any:!0}}function qL(e){return[{offset:"0%",opacity:e.left?0:1},{offset:"15%",opacity:1},{offset:"85%",opacity:1},{offset:"100%",opacity:e.right?0:1}]}function GL(e){return{gradientUnits:"userSpaceOnUse",x1:0,x2:e,y1:0,y2:0}}function Ixt({gradientId:e,strokeGradientId:t,edgeMaskId:n,edgeGradientId:r,fill:i,fillOpacity:o,gradientToOpacity:s,gradientSpan:a=1,resolvedStroke:l,isPatternFill:u,fadeEdges:c,innerWidth:d,innerHeight:h}){const m=Hj(c),g=m.any?qL(m):null,v=m.any&&!u?qL(m):null,w=Math.min(1,Math.max(.01,a)),S=`${w*100}%`;return y.jsxs("defs",{children:[u?null:y.jsxs("linearGradient",{id:e,x1:"0%",x2:"0%",y1:"0%",y2:"100%",children:[y.jsx("stop",{offset:"0%",style:{stopColor:i,stopOpacity:o}}),y.jsx("stop",{offset:S,style:{stopColor:i,stopOpacity:s}}),w<1?y.jsx("stop",{offset:"100%",style:{stopColor:i,stopOpacity:s}}):null]}),g?y.jsx("linearGradient",{id:t,...GL(d),children:g.map(C=>y.jsx("stop",{offset:C.offset,style:{stopColor:l,stopOpacity:C.opacity}},C.offset))}):null,v?y.jsxs(y.Fragment,{children:[y.jsx("linearGradient",{id:r,...GL(d),children:v.map(C=>y.jsx("stop",{offset:C.offset,style:{stopColor:"white",stopOpacity:C.opacity}},C.offset))}),y.jsx("mask",{id:n,children:y.jsx("rect",{fill:`url(#${r})`,height:h,width:d,x:"0",y:"0"})})]}):null]})}function ug(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function Pxt(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function Uj(e){let t,n,r;e.length!==2?(t=ug,n=(a,l)=>ug(e(a),l),r=(a,l)=>e(a)-l):(t=e===ug||e===Pxt?e:jxt,n=e,r=e);function i(a,l,u=0,c=a.length){if(u<c){if(t(l,l)!==0)return c;do{const d=u+c>>>1;n(a[d],l)<0?u=d+1:c=d}while(u<c)}return u}function o(a,l,u=0,c=a.length){if(u<c){if(t(l,l)!==0)return c;do{const d=u+c>>>1;n(a[d],l)<=0?u=d+1:c=d}while(u<c)}return u}function s(a,l,u=0,c=a.length){const d=i(a,l,u,c-1);return d>u&&r(a[d-1],l)>-r(a[d],l)?d-1:d}return{left:i,center:s,right:o}}function jxt(){return 0}function dRe(e){return e===null?NaN:+e}function*Dxt(e,t){for(let n of e)n!=null&&(n=+n)>=n&&(yield n)}const $xt=Uj(ug),lA=$xt.right;Uj(dRe).center;function Ble(e,t){let n,r;if(t===void 0)for(const i of e)i!=null&&(n===void 0?i>=i&&(n=r=i):(n>i&&(n=i),r<i&&(r=i)));else{let i=-1;for(let o of e)(o=t(o,++i,e))!=null&&(n===void 0?o>=o&&(n=r=o):(n>o&&(n=o),r<o&&(r=o)))}return[n,r]}class Hle extends Map{constructor(t,n=Bxt){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(Ule(this,t))}has(t){return super.has(Ule(this,t))}set(t,n){return super.set(zxt(this,t),n)}delete(t){return super.delete(Fxt(this,t))}}function Ule({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function zxt({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function Fxt({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function Bxt(e){return e!==null&&typeof e=="object"?e.valueOf():e}function Hxt(e=ug){if(e===ug)return fRe;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 fRe(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}const Uxt=Math.sqrt(50),Vxt=Math.sqrt(10),Wxt=Math.sqrt(2);function KL(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),s=o>=Uxt?10:o>=Vxt?5:o>=Wxt?2:1;let a,l,u;return i<0?(u=Math.pow(10,-i)/s,a=Math.round(e*u),l=Math.round(t*u),a/u<e&&++a,l/u>t&&--l,u=-u):(u=Math.pow(10,i)*s,a=Math.round(e/u),l=Math.round(t/u),a*u<e&&++a,l*u>t&&--l),l<a&&.5<=n&&n<2?KL(e,t,n*2):[a,l,u]}function tV(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[i,o,s]=r?KL(t,e,n):KL(e,t,n);if(!(o>=i))return[];const a=o-i+1,l=new Array(a);if(r)if(s<0)for(let u=0;u<a;++u)l[u]=(o-u)/-s;else for(let u=0;u<a;++u)l[u]=(o-u)*s;else if(s<0)for(let u=0;u<a;++u)l[u]=(i+u)/-s;else for(let u=0;u<a;++u)l[u]=(i+u)*s;return l}function nV(e,t,n){return t=+t,e=+e,n=+n,KL(e,t,n)[2]}function rV(e,t,n){t=+t,e=+e,n=+n;const r=t<e,i=r?nV(t,e,n):nV(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}function Vle(e,t){let n;for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);return n}function Wle(e,t){let n;for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);return n}function hRe(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?fRe:Hxt(i);r>n;){if(r-n>600){const l=r-n+1,u=t-n+1,c=Math.log(l),d=.5*Math.exp(2*c/3),h=.5*Math.sqrt(c*d*(l-d)/l)*(u-l/2<0?-1:1),m=Math.max(n,Math.floor(t-u*d/l+h)),g=Math.min(r,Math.floor(t+(l-u)*d/l+h));hRe(e,t,m,g,i)}const o=e[t];let s=n,a=r;for(wk(e,n,t),i(e[r],o)>0&&wk(e,n,r);s<a;){for(wk(e,s,a),++s,--a;i(e[s],o)<0;)++s;for(;i(e[a],o)>0;)--a}i(e[n],o)===0?wk(e,n,a):(++a,wk(e,a,r)),a<=t&&(n=a+1),t<=a&&(r=a-1)}return e}function wk(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function qxt(e,t,n){if(e=Float64Array.from(Dxt(e)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return Wle(e);if(t>=1)return Vle(e);var r,i=(r-1)*t,o=Math.floor(i),s=Vle(hRe(e,o).subarray(0,o+1)),a=Wle(e.subarray(o+1));return s+(a-s)*(i-o)}}function Gxt(e,t,n=dRe){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),s=+n(e[o],o,e),a=+n(e[o+1],o+1,e);return s+(a-s)*(i-o)}}function Kxt(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 hu(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function Zh(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 iV=Symbol("implicit");function PY(){var e=new Hle,t=[],n=[],r=iV;function i(o){let s=e.get(o);if(s===void 0){if(r!==iV)return r;e.set(o,s=t.push(o)-1)}return n[s%n.length]}return i.domain=function(o){if(!arguments.length)return t.slice();t=[],e=new Hle;for(const s of o)e.has(s)||e.set(s,t.push(s)-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 PY(t,n).unknown(r)},hu.apply(i,arguments),i}function Jx(){var e=PY().unknown(void 0),t=e.domain,n=e.range,r=0,i=1,o,s,a=!1,l=0,u=0,c=.5;delete e.unknown;function d(){var h=t().length,m=i<r,g=m?i:r,b=m?r:i;o=(b-g)/Math.max(1,h-l+u*2),a&&(o=Math.floor(o)),g+=(b-g-o*(h-l))*c,s=o*(1-l),a&&(g=Math.round(g),s=Math.round(s));var v=Kxt(h).map(function(w){return g+o*w});return n(m?v.reverse():v)}return e.domain=function(h){return arguments.length?(t(h),d()):t()},e.range=function(h){return arguments.length?([r,i]=h,r=+r,i=+i,d()):[r,i]},e.rangeRound=function(h){return[r,i]=h,r=+r,i=+i,a=!0,d()},e.bandwidth=function(){return s},e.step=function(){return o},e.round=function(h){return arguments.length?(a=!!h,d()):a},e.padding=function(h){return arguments.length?(l=Math.min(1,u=+h),d()):l},e.paddingInner=function(h){return arguments.length?(l=Math.min(1,h),d()):l},e.paddingOuter=function(h){return arguments.length?(u=+h,d()):u},e.align=function(h){return arguments.length?(c=Math.max(0,Math.min(1,h)),d()):c},e.copy=function(){return Jx(t(),[r,i]).round(a).paddingInner(l).paddingOuter(u).align(c)},hu.apply(d(),arguments)}function pRe(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return pRe(t())},e}function GC(){return pRe(Jx.apply(null,arguments).paddingInner(1))}function iS(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function uA(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function Fg(){}var gb=.7,ew=1/gb,H1="\\s*([+-]?\\d+)\\s*",KE="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Sd="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Yxt=/^#([0-9a-f]{3,8})$/,Xxt=new RegExp(`^rgb\\(${H1},${H1},${H1}\\)$`),Qxt=new RegExp(`^rgb\\(${Sd},${Sd},${Sd}\\)$`),Zxt=new RegExp(`^rgba\\(${H1},${H1},${H1},${KE}\\)$`),Jxt=new RegExp(`^rgba\\(${Sd},${Sd},${Sd},${KE}\\)$`),ewt=new RegExp(`^hsl\\(${KE},${Sd},${Sd}\\)$`),twt=new RegExp(`^hsla\\(${KE},${Sd},${Sd},${KE}\\)$`),qle={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};iS(Fg,yb,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Gle,formatHex:Gle,formatHex8:nwt,formatHsl:rwt,formatRgb:Kle,toString:Kle});function Gle(){return this.rgb().formatHex()}function nwt(){return this.rgb().formatHex8()}function rwt(){return mRe(this).formatHsl()}function Kle(){return this.rgb().formatRgb()}function yb(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=Yxt.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?Yle(t):n===3?new jo(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?nM(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?nM(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=Xxt.exec(e))?new jo(t[1],t[2],t[3],1):(t=Qxt.exec(e))?new jo(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=Zxt.exec(e))?nM(t[1],t[2],t[3],t[4]):(t=Jxt.exec(e))?nM(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=ewt.exec(e))?Zle(t[1],t[2]/100,t[3]/100,1):(t=twt.exec(e))?Zle(t[1],t[2]/100,t[3]/100,t[4]):qle.hasOwnProperty(e)?Yle(qle[e]):e==="transparent"?new jo(NaN,NaN,NaN,0):null}function Yle(e){return new jo(e>>16&255,e>>8&255,e&255,1)}function nM(e,t,n,r){return r<=0&&(e=t=n=NaN),new jo(e,t,n,r)}function jY(e){return e instanceof Fg||(e=yb(e)),e?(e=e.rgb(),new jo(e.r,e.g,e.b,e.opacity)):new jo}function oV(e,t,n,r){return arguments.length===1?jY(e):new jo(e,t,n,r??1)}function jo(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}iS(jo,oV,uA(Fg,{brighter(e){return e=e==null?ew:Math.pow(ew,e),new jo(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?gb:Math.pow(gb,e),new jo(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new jo(Qy(this.r),Qy(this.g),Qy(this.b),YL(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:Xle,formatHex:Xle,formatHex8:iwt,formatRgb:Qle,toString:Qle}));function Xle(){return`#${iy(this.r)}${iy(this.g)}${iy(this.b)}`}function iwt(){return`#${iy(this.r)}${iy(this.g)}${iy(this.b)}${iy((isNaN(this.opacity)?1:this.opacity)*255)}`}function Qle(){const e=YL(this.opacity);return`${e===1?"rgb(":"rgba("}${Qy(this.r)}, ${Qy(this.g)}, ${Qy(this.b)}${e===1?")":`, ${e})`}`}function YL(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Qy(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function iy(e){return e=Qy(e),(e<16?"0":"")+e.toString(16)}function Zle(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new Gu(e,t,n,r)}function mRe(e){if(e instanceof Gu)return new Gu(e.h,e.s,e.l,e.opacity);if(e instanceof Fg||(e=yb(e)),!e)return new Gu;if(e instanceof Gu)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),s=NaN,a=o-i,l=(o+i)/2;return a?(t===o?s=(n-r)/a+(n<r)*6:n===o?s=(r-t)/a+2:s=(t-n)/a+4,a/=l<.5?o+i:2-o-i,s*=60):a=l>0&&l<1?0:s,new Gu(s,a,l,e.opacity)}function sV(e,t,n,r){return arguments.length===1?mRe(e):new Gu(e,t,n,r??1)}function Gu(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}iS(Gu,sV,uA(Fg,{brighter(e){return e=e==null?ew:Math.pow(ew,e),new Gu(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?gb:Math.pow(gb,e),new Gu(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 jo(T8(e>=240?e-240:e+120,i,r),T8(e,i,r),T8(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new Gu(Jle(this.h),rM(this.s),rM(this.l),YL(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=YL(this.opacity);return`${e===1?"hsl(":"hsla("}${Jle(this.h)}, ${rM(this.s)*100}%, ${rM(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Jle(e){return e=(e||0)%360,e<0?e+360:e}function rM(e){return Math.max(0,Math.min(1,e||0))}function T8(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 gRe=Math.PI/180,yRe=180/Math.PI,XL=18,bRe=.96422,vRe=1,xRe=.82521,wRe=4/29,U1=6/29,SRe=3*U1*U1,owt=U1*U1*U1;function kRe(e){if(e instanceof kd)return new kd(e.l,e.a,e.b,e.opacity);if(e instanceof ch)return CRe(e);e instanceof jo||(e=jY(e));var t=M8(e.r),n=M8(e.g),r=M8(e.b),i=A8((.2225045*t+.7168786*n+.0606169*r)/vRe),o,s;return t===n&&n===r?o=s=i:(o=A8((.4360747*t+.3850649*n+.1430804*r)/bRe),s=A8((.0139322*t+.0971045*n+.7141733*r)/xRe)),new kd(116*i-16,500*(o-i),200*(i-s),e.opacity)}function aV(e,t,n,r){return arguments.length===1?kRe(e):new kd(e,t,n,r??1)}function kd(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}iS(kd,aV,uA(Fg,{brighter(e){return new kd(this.l+XL*(e??1),this.a,this.b,this.opacity)},darker(e){return new kd(this.l-XL*(e??1),this.a,this.b,this.opacity)},rgb(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,n=isNaN(this.b)?e:e-this.b/200;return t=bRe*O8(t),e=vRe*O8(e),n=xRe*O8(n),new jo(R8(3.1338561*t-1.6168667*e-.4906146*n),R8(-.9787684*t+1.9161415*e+.033454*n),R8(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}}));function A8(e){return e>owt?Math.pow(e,1/3):e/SRe+wRe}function O8(e){return e>U1?e*e*e:SRe*(e-wRe)}function R8(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function M8(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function swt(e){if(e instanceof ch)return new ch(e.h,e.c,e.l,e.opacity);if(e instanceof kd||(e=kRe(e)),e.a===0&&e.b===0)return new ch(NaN,0<e.l&&e.l<100?0:NaN,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*yRe;return new ch(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}function lV(e,t,n,r){return arguments.length===1?swt(e):new ch(e,t,n,r??1)}function ch(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}function CRe(e){if(isNaN(e.h))return new kd(e.l,0,0,e.opacity);var t=e.h*gRe;return new kd(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}iS(ch,lV,uA(Fg,{brighter(e){return new ch(this.h,this.c,this.l+XL*(e??1),this.opacity)},darker(e){return new ch(this.h,this.c,this.l-XL*(e??1),this.opacity)},rgb(){return CRe(this).rgb()}}));var ERe=-.14861,DY=1.78277,$Y=-.29227,Vj=-.90649,YE=1.97294,eue=YE*Vj,tue=YE*DY,nue=DY*$Y-Vj*ERe;function awt(e){if(e instanceof Zy)return new Zy(e.h,e.s,e.l,e.opacity);e instanceof jo||(e=jY(e));var t=e.r/255,n=e.g/255,r=e.b/255,i=(nue*r+eue*t-tue*n)/(nue+eue-tue),o=r-i,s=(YE*(n-i)-$Y*o)/Vj,a=Math.sqrt(s*s+o*o)/(YE*i*(1-i)),l=a?Math.atan2(s,o)*yRe-120:NaN;return new Zy(l<0?l+360:l,a,i,e.opacity)}function uV(e,t,n,r){return arguments.length===1?awt(e):new Zy(e,t,n,r??1)}function Zy(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}iS(Zy,uV,uA(Fg,{brighter(e){return e=e==null?ew:Math.pow(ew,e),new Zy(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?gb:Math.pow(gb,e),new Zy(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=isNaN(this.h)?0:(this.h+120)*gRe,t=+this.l,n=isNaN(this.s)?0:this.s*t*(1-t),r=Math.cos(e),i=Math.sin(e);return new jo(255*(t+n*(ERe*r+DY*i)),255*(t+n*($Y*r+Vj*i)),255*(t+n*(YE*r)),this.opacity)}}));const Wj=e=>()=>e;function TRe(e,t){return function(n){return e+n*t}}function lwt(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 zY(e,t){var n=t-e;return n?TRe(e,n>180||n<-180?n-360*Math.round(n/360):n):Wj(isNaN(e)?t:e)}function uwt(e){return(e=+e)==1?Do:function(t,n){return n-t?lwt(t,n,e):Wj(isNaN(t)?n:t)}}function Do(e,t){var n=t-e;return n?TRe(e,n):Wj(isNaN(e)?t:e)}const XE=(function e(t){var n=uwt(t);function r(i,o){var s=n((i=oV(i)).r,(o=oV(o)).r),a=n(i.g,o.g),l=n(i.b,o.b),u=Do(i.opacity,o.opacity);return function(c){return i.r=s(c),i.g=a(c),i.b=l(c),i.opacity=u(c),i+""}}return r.gamma=e,r})(1);function cwt(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 dwt(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function fwt(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=new Array(r),o=new Array(n),s;for(s=0;s<r;++s)i[s]=Ah(e[s],t[s]);for(;s<n;++s)o[s]=t[s];return function(a){for(s=0;s<r;++s)o[s]=i[s](a);return o}}function hwt(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function Uu(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function pwt(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]=Ah(e[i],t[i]):r[i]=t[i];return function(o){for(i in n)r[i]=n[i](o);return r}}var cV=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,_8=new RegExp(cV.source,"g");function mwt(e){return function(){return e}}function gwt(e){return function(t){return e(t)+""}}function ARe(e,t){var n=cV.lastIndex=_8.lastIndex=0,r,i,o,s=-1,a=[],l=[];for(e=e+"",t=t+"";(r=cV.exec(e))&&(i=_8.exec(t));)(o=i.index)>n&&(o=t.slice(n,o),a[s]?a[s]+=o:a[++s]=o),(r=r[0])===(i=i[0])?a[s]?a[s]+=i:a[++s]=i:(a[++s]=null,l.push({i:s,x:Uu(r,i)})),n=_8.lastIndex;return n<t.length&&(o=t.slice(n),a[s]?a[s]+=o:a[++s]=o),a.length<2?l[0]?gwt(l[0].x):mwt(t):(t=l.length,function(u){for(var c=0,d;c<t;++c)a[(d=l[c]).i]=d.x(u);return a.join("")})}function Ah(e,t){var n=typeof t,r;return t==null||n==="boolean"?Wj(t):(n==="number"?Uu:n==="string"?(r=yb(t))?(t=r,XE):ARe:t instanceof yb?XE:t instanceof Date?hwt:dwt(t)?cwt:Array.isArray(t)?fwt:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?pwt:Uu)(e,t)}function qj(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}var rue=180/Math.PI,dV={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function ORe(e,t,n,r,i,o){var s,a,l;return(s=Math.sqrt(e*e+t*t))&&(e/=s,t/=s),(l=e*n+t*r)&&(n-=e*l,r-=t*l),(a=Math.sqrt(n*n+r*r))&&(n/=a,r/=a,l/=a),e*r<t*n&&(e=-e,t=-t,l=-l,s=-s),{translateX:i,translateY:o,rotate:Math.atan2(t,e)*rue,skewX:Math.atan(l)*rue,scaleX:s,scaleY:a}}var iM;function ywt(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?dV:ORe(t.a,t.b,t.c,t.d,t.e,t.f)}function bwt(e){return e==null||(iM||(iM=document.createElementNS("http://www.w3.org/2000/svg","g")),iM.setAttribute("transform",e),!(e=iM.transform.baseVal.consolidate()))?dV:(e=e.matrix,ORe(e.a,e.b,e.c,e.d,e.e,e.f))}function RRe(e,t,n,r){function i(u){return u.length?u.pop()+" ":""}function o(u,c,d,h,m,g){if(u!==d||c!==h){var b=m.push("translate(",null,t,null,n);g.push({i:b-4,x:Uu(u,d)},{i:b-2,x:Uu(c,h)})}else(d||h)&&m.push("translate("+d+t+h+n)}function s(u,c,d,h){u!==c?(u-c>180?c+=360:c-u>180&&(u+=360),h.push({i:d.push(i(d)+"rotate(",null,r)-2,x:Uu(u,c)})):c&&d.push(i(d)+"rotate("+c+r)}function a(u,c,d,h){u!==c?h.push({i:d.push(i(d)+"skewX(",null,r)-2,x:Uu(u,c)}):c&&d.push(i(d)+"skewX("+c+r)}function l(u,c,d,h,m,g){if(u!==d||c!==h){var b=m.push(i(m)+"scale(",null,",",null,")");g.push({i:b-4,x:Uu(u,d)},{i:b-2,x:Uu(c,h)})}else(d!==1||h!==1)&&m.push(i(m)+"scale("+d+","+h+")")}return function(u,c){var d=[],h=[];return u=e(u),c=e(c),o(u.translateX,u.translateY,c.translateX,c.translateY,d,h),s(u.rotate,c.rotate,d,h),a(u.skewX,c.skewX,d,h),l(u.scaleX,u.scaleY,c.scaleX,c.scaleY,d,h),u=c=null,function(m){for(var g=-1,b=h.length,v;++g<b;)d[(v=h[g]).i]=v.x(m);return d.join("")}}}var vwt=RRe(ywt,"px, ","px)","deg)"),xwt=RRe(bwt,", ",")",")"),wwt=1e-12;function iue(e){return((e=Math.exp(e))+1/e)/2}function Swt(e){return((e=Math.exp(e))-1/e)/2}function kwt(e){return((e=Math.exp(2*e))-1)/(e+1)}const k_=(function e(t,n,r){function i(o,s){var a=o[0],l=o[1],u=o[2],c=s[0],d=s[1],h=s[2],m=c-a,g=d-l,b=m*m+g*g,v,w;if(b<wwt)w=Math.log(h/u)/t,v=function(M){return[a+M*m,l+M*g,u*Math.exp(t*M*w)]};else{var S=Math.sqrt(b),C=(h*h-u*u+r*b)/(2*u*n*S),E=(h*h-u*u-r*b)/(2*h*n*S),T=Math.log(Math.sqrt(C*C+1)-C),O=Math.log(Math.sqrt(E*E+1)-E);w=(O-T)/t,v=function(M){var N=M*w,I=iue(T),D=u/(n*S)*(I*kwt(t*N+T)-Swt(T));return[a+D*m,l+D*g,u*I/iue(t*N+T)]}}return v.duration=w*1e3*t/Math.SQRT2,v}return i.rho=function(o){var s=Math.max(.001,+o),a=s*s,l=a*a;return e(s,a,l)},i})(Math.SQRT2,2,4);function MRe(e){return function(t,n){var r=e((t=sV(t)).h,(n=sV(n)).h),i=Do(t.s,n.s),o=Do(t.l,n.l),s=Do(t.opacity,n.opacity);return function(a){return t.h=r(a),t.s=i(a),t.l=o(a),t.opacity=s(a),t+""}}}const Cwt=MRe(zY);var Ewt=MRe(Do);function Twt(e,t){var n=Do((e=aV(e)).l,(t=aV(t)).l),r=Do(e.a,t.a),i=Do(e.b,t.b),o=Do(e.opacity,t.opacity);return function(s){return e.l=n(s),e.a=r(s),e.b=i(s),e.opacity=o(s),e+""}}function _Re(e){return function(t,n){var r=e((t=lV(t)).h,(n=lV(n)).h),i=Do(t.c,n.c),o=Do(t.l,n.l),s=Do(t.opacity,n.opacity);return function(a){return t.h=r(a),t.c=i(a),t.l=o(a),t.opacity=s(a),t+""}}}const Awt=_Re(zY);var Owt=_Re(Do);function NRe(e){return(function t(n){n=+n;function r(i,o){var s=e((i=uV(i)).h,(o=uV(o)).h),a=Do(i.s,o.s),l=Do(i.l,o.l),u=Do(i.opacity,o.opacity);return function(c){return i.h=s(c),i.s=a(c),i.l=l(Math.pow(c,n)),i.opacity=u(c),i+""}}return r.gamma=t,r})(1)}const Rwt=NRe(zY);var Mwt=NRe(Do);function _wt(e,t){t===void 0&&(t=e,e=Ah);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(s){var a=Math.max(0,Math.min(r-1,Math.floor(s*=r)));return o[a](s-a)}}function Nwt(e){return function(){return e}}function QL(e){return+e}var oue=[0,1];function Gs(e){return e}function fV(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:Nwt(isNaN(t)?NaN:.5)}function Lwt(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function Iwt(e,t,n){var r=e[0],i=e[1],o=t[0],s=t[1];return i<r?(r=fV(i,r),o=n(s,o)):(r=fV(r,i),o=n(o,s)),function(a){return o(r(a))}}function Pwt(e,t,n){var r=Math.min(e.length,t.length)-1,i=new Array(r),o=new Array(r),s=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++s<r;)i[s]=fV(e[s],e[s+1]),o[s]=n(t[s],t[s+1]);return function(a){var l=lA(e,a,1,r)-1;return o[l](i[l](a))}}function cA(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Gj(){var e=oue,t=oue,n=Ah,r,i,o,s=Gs,a,l,u;function c(){var h=Math.min(e.length,t.length);return s!==Gs&&(s=Lwt(e[0],e[h-1])),a=h>2?Pwt:Iwt,l=u=null,d}function d(h){return h==null||isNaN(h=+h)?o:(l||(l=a(e.map(r),t,n)))(r(s(h)))}return d.invert=function(h){return s(i((u||(u=a(t,e.map(r),Uu)))(h)))},d.domain=function(h){return arguments.length?(e=Array.from(h,QL),c()):e.slice()},d.range=function(h){return arguments.length?(t=Array.from(h),c()):t.slice()},d.rangeRound=function(h){return t=Array.from(h),n=qj,c()},d.clamp=function(h){return arguments.length?(s=h?!0:Gs,c()):s!==Gs},d.interpolate=function(h){return arguments.length?(n=h,c()):n},d.unknown=function(h){return arguments.length?(o=h,d):o},function(h,m){return r=h,i=m,c()}}function FY(){return Gj()(Gs,Gs)}function jwt(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function ZL(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function tw(e){return e=ZL(Math.abs(e)),e?e[1]:NaN}function Dwt(e,t){return function(n,r){for(var i=n.length,o=[],s=0,a=e[0],l=0;i>0&&a>0&&(l+a+1>r&&(a=Math.max(1,r-l)),o.push(n.substring(i-=a,i+a)),!((l+=a+1)>r));)a=e[s=(s+1)%e.length];return o.reverse().join(t)}}function $wt(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var zwt=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function QE(e){if(!(t=zwt.exec(e)))throw new Error("invalid format: "+e);var t;return new BY({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]})}QE.prototype=BY.prototype;function BY(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+""}BY.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 Fwt(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 LRe;function Bwt(e,t){var n=ZL(e,t);if(!n)return e+"";var r=n[0],i=n[1],o=i-(LRe=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,s=r.length;return o===s?r:o>s?r+new Array(o-s+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+ZL(e,Math.max(0,t+o-1))[0]}function sue(e,t){var n=ZL(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 aue={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:jwt,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)=>sue(e*100,t),r:sue,s:Bwt,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function lue(e){return e}var uue=Array.prototype.map,cue=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function Hwt(e){var t=e.grouping===void 0||e.thousands===void 0?lue:Dwt(uue.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?lue:$wt(uue.call(e.numerals,String)),s=e.percent===void 0?"%":e.percent+"",a=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function u(d){d=QE(d);var h=d.fill,m=d.align,g=d.sign,b=d.symbol,v=d.zero,w=d.width,S=d.comma,C=d.precision,E=d.trim,T=d.type;T==="n"?(S=!0,T="g"):aue[T]||(C===void 0&&(C=12),E=!0,T="g"),(v||h==="0"&&m==="=")&&(v=!0,h="0",m="=");var O=b==="$"?n:b==="#"&&/[boxX]/.test(T)?"0"+T.toLowerCase():"",M=b==="$"?r:/[%p]/.test(T)?s:"",N=aue[T],I=/[defgprs%]/.test(T);C=C===void 0?6:/[gprs]/.test(T)?Math.max(1,Math.min(21,C)):Math.max(0,Math.min(20,C));function D(P){var F=O,z=M,$,B,H;if(T==="c")z=N(P)+z,P="";else{P=+P;var U=P<0||1/P<0;if(P=isNaN(P)?l:N(Math.abs(P),C),E&&(P=Fwt(P)),U&&+P==0&&g!=="+"&&(U=!1),F=(U?g==="("?g:a:g==="-"||g==="("?"":g)+F,z=(T==="s"?cue[8+LRe/3]:"")+z+(U&&g==="("?")":""),I){for($=-1,B=P.length;++$<B;)if(H=P.charCodeAt($),48>H||H>57){z=(H===46?i+P.slice($+1):P.slice($))+z,P=P.slice(0,$);break}}}S&&!v&&(P=t(P,1/0));var W=F.length+P.length+z.length,q=W<w?new Array(w-W+1).join(h):"";switch(S&&v&&(P=t(q+P,q.length?w-z.length:1/0),q=""),m){case"<":P=F+P+z+q;break;case"=":P=F+q+P+z;break;case"^":P=q.slice(0,W=q.length>>1)+F+P+z+q.slice(W);break;default:P=q+F+P+z;break}return o(P)}return D.toString=function(){return d+""},D}function c(d,h){var m=u((d=QE(d),d.type="f",d)),g=Math.max(-8,Math.min(8,Math.floor(tw(h)/3)))*3,b=Math.pow(10,-g),v=cue[8+g/3];return function(w){return m(b*w)+v}}return{format:u,formatPrefix:c}}var oM,HY,IRe;Uwt({thousands:",",grouping:[3],currency:["$",""]});function Uwt(e){return oM=Hwt(e),HY=oM.format,IRe=oM.formatPrefix,oM}function Vwt(e){return Math.max(0,-tw(Math.abs(e)))}function Wwt(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(tw(t)/3)))*3-tw(Math.abs(e)))}function qwt(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,tw(t)-tw(e))+1}function PRe(e,t,n,r){var i=rV(e,t,n),o;switch(r=QE(r??",f"),r.type){case"s":{var s=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(o=Wwt(i,s))&&(r.precision=o),IRe(r,s)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(o=qwt(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=o-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(o=Vwt(i))&&(r.precision=o-(r.type==="%")*2);break}}return HY(r)}function Bg(e){var t=e.domain;return e.ticks=function(n){var r=t();return tV(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var i=t();return PRe(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,s=r[i],a=r[o],l,u,c=10;for(a<s&&(u=s,s=a,a=u,u=i,i=o,o=u);c-- >0;){if(u=nV(s,a,n),u===l)return r[i]=s,r[o]=a,t(r);if(u>0)s=Math.floor(s/u)*u,a=Math.ceil(a/u)*u;else if(u<0)s=Math.ceil(s*u)/u,a=Math.floor(a*u)/u;else break;l=u}return e},e}function ZE(){var e=FY();return e.copy=function(){return cA(e,ZE())},hu.apply(e,arguments),Bg(e)}function jRe(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,QL),n):e.slice()},n.unknown=function(r){return arguments.length?(t=r,n):t},n.copy=function(){return jRe(e).unknown(t)},e=arguments.length?Array.from(e,QL):[0,1],Bg(n)}function DRe(e,t){e=e.slice();var n=0,r=e.length-1,i=e[n],o=e[r],s;return o<i&&(s=n,n=r,r=s,s=i,i=o,o=s),e[n]=t.floor(i),e[r]=t.ceil(o),e}function due(e){return Math.log(e)}function fue(e){return Math.exp(e)}function Gwt(e){return-Math.log(-e)}function Kwt(e){return-Math.exp(-e)}function Ywt(e){return isFinite(e)?+("1e"+e):e<0?0:e}function Xwt(e){return e===10?Ywt:e===Math.E?Math.exp:t=>Math.pow(e,t)}function Qwt(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 hue(e){return(t,n)=>-e(-t,n)}function UY(e){const t=e(due,fue),n=t.domain;let r=10,i,o;function s(){return i=Qwt(r),o=Xwt(r),n()[0]<0?(i=hue(i),o=hue(o),e(Gwt,Kwt)):e(due,fue),t}return t.base=function(a){return arguments.length?(r=+a,s()):r},t.domain=function(a){return arguments.length?(n(a),s()):n()},t.ticks=a=>{const l=n();let u=l[0],c=l[l.length-1];const d=c<u;d&&([u,c]=[c,u]);let h=i(u),m=i(c),g,b;const v=a==null?10:+a;let w=[];if(!(r%1)&&m-h<v){if(h=Math.floor(h),m=Math.ceil(m),u>0){for(;h<=m;++h)for(g=1;g<r;++g)if(b=h<0?g/o(-h):g*o(h),!(b<u)){if(b>c)break;w.push(b)}}else for(;h<=m;++h)for(g=r-1;g>=1;--g)if(b=h>0?g/o(-h):g*o(h),!(b<u)){if(b>c)break;w.push(b)}w.length*2<v&&(w=tV(u,c,v))}else w=tV(h,m,Math.min(m-h,v)).map(o);return d?w.reverse():w},t.tickFormat=(a,l)=>{if(a==null&&(a=10),l==null&&(l=r===10?"s":","),typeof l!="function"&&(!(r%1)&&(l=QE(l)).precision==null&&(l.trim=!0),l=HY(l)),a===1/0)return l;const u=Math.max(1,r*a/t.ticks().length);return c=>{let d=c/o(Math.round(i(c)));return d*r<r-.5&&(d*=r),d<=u?l(c):""}},t.nice=()=>n(DRe(n(),{floor:a=>o(Math.floor(i(a))),ceil:a=>o(Math.ceil(i(a)))})),t}function $Re(){const e=UY(Gj()).domain([1,10]);return e.copy=()=>cA(e,$Re()).base(e.base()),hu.apply(e,arguments),e}function pue(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function mue(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function VY(e){var t=1,n=e(pue(t),mue(t));return n.constant=function(r){return arguments.length?e(pue(t=+r),mue(t)):t},Bg(n)}function zRe(){var e=VY(Gj());return e.copy=function(){return cA(e,zRe()).constant(e.constant())},hu.apply(e,arguments)}function gue(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function Zwt(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function Jwt(e){return e<0?-e*e:e*e}function WY(e){var t=e(Gs,Gs),n=1;function r(){return n===1?e(Gs,Gs):n===.5?e(Zwt,Jwt):e(gue(n),gue(1/n))}return t.exponent=function(i){return arguments.length?(n=+i,r()):n},Bg(t)}function qY(){var e=WY(Gj());return e.copy=function(){return cA(e,qY()).exponent(e.exponent())},hu.apply(e,arguments),e}function eSt(){return qY.apply(null,arguments).exponent(.5)}function yue(e){return Math.sign(e)*e*e}function tSt(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function FRe(){var e=FY(),t=[0,1],n=!1,r;function i(o){var s=tSt(e(o));return isNaN(s)?r:n?Math.round(s):s}return i.invert=function(o){return e.invert(yue(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,QL)).map(yue)),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 FRe(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},hu.apply(i,arguments),Bg(i)}function BRe(){var e=[],t=[],n=[],r;function i(){var s=0,a=Math.max(1,t.length);for(n=new Array(a-1);++s<a;)n[s-1]=Gxt(e,s/a);return o}function o(s){return s==null||isNaN(s=+s)?r:t[lA(n,s)]}return o.invertExtent=function(s){var a=t.indexOf(s);return a<0?[NaN,NaN]:[a>0?n[a-1]:e[0],a<n.length?n[a]:e[e.length-1]]},o.domain=function(s){if(!arguments.length)return e.slice();e=[];for(let a of s)a!=null&&!isNaN(a=+a)&&e.push(a);return e.sort(ug),i()},o.range=function(s){return arguments.length?(t=Array.from(s),i()):t.slice()},o.unknown=function(s){return arguments.length?(r=s,o):r},o.quantiles=function(){return n.slice()},o.copy=function(){return BRe().domain(e).range(t).unknown(r)},hu.apply(o,arguments)}function HRe(){var e=0,t=1,n=1,r=[.5],i=[0,1],o;function s(l){return l!=null&&l<=l?i[lA(r,l,0,n)]:o}function a(){var l=-1;for(r=new Array(n);++l<n;)r[l]=((l+1)*t-(l-n)*e)/(n+1);return s}return s.domain=function(l){return arguments.length?([e,t]=l,e=+e,t=+t,a()):[e,t]},s.range=function(l){return arguments.length?(n=(i=Array.from(l)).length-1,a()):i.slice()},s.invertExtent=function(l){var u=i.indexOf(l);return u<0?[NaN,NaN]:u<1?[e,r[0]]:u>=n?[r[n-1],t]:[r[u-1],r[u]]},s.unknown=function(l){return arguments.length&&(o=l),s},s.thresholds=function(){return r.slice()},s.copy=function(){return HRe().domain([e,t]).range(i).unknown(o)},hu.apply(Bg(s),arguments)}function URe(){var e=[.5],t=[0,1],n,r=1;function i(o){return o!=null&&o<=o?t[lA(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 s=t.indexOf(o);return[e[s-1],e[s]]},i.unknown=function(o){return arguments.length?(n=o,i):n},i.copy=function(){return URe().domain(e).range(t).unknown(n)},hu.apply(i,arguments)}const N8=new Date,L8=new Date;function yo(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 s=i(o),a=i.ceil(o);return o-s<a-o?s:a},i.offset=(o,s)=>(t(o=new Date(+o),s==null?1:Math.floor(s)),o),i.range=(o,s,a)=>{const l=[];if(o=i.ceil(o),a=a==null?1:Math.floor(a),!(o<s)||!(a>0))return l;let u;do l.push(u=new Date(+o)),t(o,a),e(o);while(u<o&&o<s);return l},i.filter=o=>yo(s=>{if(s>=s)for(;e(s),!o(s);)s.setTime(s-1)},(s,a)=>{if(s>=s)if(a<0)for(;++a<=0;)for(;t(s,-1),!o(s););else for(;--a>=0;)for(;t(s,1),!o(s););}),n&&(i.count=(o,s)=>(N8.setTime(+o),L8.setTime(+s),e(N8),e(L8),Math.floor(n(N8,L8))),i.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?i.filter(r?s=>r(s)%o===0:s=>i.count(0,s)%o===0):i)),i}const JL=yo(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);JL.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?yo(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):JL);JL.range;const dh=1e3,Jl=dh*60,fh=Jl*60,Bh=fh*24,GY=Bh*7,bue=Bh*30,I8=Bh*365,hh=yo(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*dh)},(e,t)=>(t-e)/dh,e=>e.getUTCSeconds());hh.range;const Kj=yo(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*dh)},(e,t)=>{e.setTime(+e+t*Jl)},(e,t)=>(t-e)/Jl,e=>e.getMinutes());Kj.range;const Yj=yo(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Jl)},(e,t)=>(t-e)/Jl,e=>e.getUTCMinutes());Yj.range;const Xj=yo(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*dh-e.getMinutes()*Jl)},(e,t)=>{e.setTime(+e+t*fh)},(e,t)=>(t-e)/fh,e=>e.getHours());Xj.range;const Qj=yo(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*fh)},(e,t)=>(t-e)/fh,e=>e.getUTCHours());Qj.range;const oS=yo(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Jl)/Bh,e=>e.getDate()-1);oS.range;const dA=yo(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Bh,e=>e.getUTCDate()-1);dA.range;const VRe=yo(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Bh,e=>Math.floor(e/Bh));VRe.range;function jb(e){return yo(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())*Jl)/GY)}const fA=jb(0),eI=jb(1),nSt=jb(2),rSt=jb(3),nw=jb(4),iSt=jb(5),oSt=jb(6);fA.range;eI.range;nSt.range;rSt.range;nw.range;iSt.range;oSt.range;function Db(e){return yo(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)/GY)}const hA=Db(0),tI=Db(1),sSt=Db(2),aSt=Db(3),rw=Db(4),lSt=Db(5),uSt=Db(6);hA.range;tI.range;sSt.range;aSt.range;rw.range;lSt.range;uSt.range;const Zj=yo(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());Zj.range;const Jj=yo(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());Jj.range;const _d=yo(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());_d.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:yo(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)});_d.range;const Nd=yo(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());Nd.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:yo(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)});Nd.range;function WRe(e,t,n,r,i,o){const s=[[hh,1,dh],[hh,5,5*dh],[hh,15,15*dh],[hh,30,30*dh],[o,1,Jl],[o,5,5*Jl],[o,15,15*Jl],[o,30,30*Jl],[i,1,fh],[i,3,3*fh],[i,6,6*fh],[i,12,12*fh],[r,1,Bh],[r,2,2*Bh],[n,1,GY],[t,1,bue],[t,3,3*bue],[e,1,I8]];function a(u,c,d){const h=c<u;h&&([u,c]=[c,u]);const m=d&&typeof d.range=="function"?d:l(u,c,d),g=m?m.range(u,+c+1):[];return h?g.reverse():g}function l(u,c,d){const h=Math.abs(c-u)/d,m=Uj(([,,v])=>v).right(s,h);if(m===s.length)return e.every(rV(u/I8,c/I8,d));if(m===0)return JL.every(Math.max(rV(u,c,d),1));const[g,b]=s[h/s[m-1][2]<s[m][2]/h?m-1:m];return g.every(b)}return[a,l]}const[cSt,dSt]=WRe(Nd,Jj,hA,VRe,Qj,Yj),[fSt,hSt]=WRe(_d,Zj,fA,oS,Xj,Kj);function P8(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 j8(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 Sk(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function pSt(e){var t=e.dateTime,n=e.date,r=e.time,i=e.periods,o=e.days,s=e.shortDays,a=e.months,l=e.shortMonths,u=kk(i),c=Ck(i),d=kk(o),h=Ck(o),m=kk(s),g=Ck(s),b=kk(a),v=Ck(a),w=kk(l),S=Ck(l),C={a:U,A:W,b:q,B:Y,c:null,d:Cue,e:Cue,f:DSt,g:GSt,G:YSt,H:ISt,I:PSt,j:jSt,L:qRe,m:$St,M:zSt,p:Q,q:G,Q:Aue,s:Oue,S:FSt,u:BSt,U:HSt,V:USt,w:VSt,W:WSt,x:null,X:null,y:qSt,Y:KSt,Z:XSt,"%":Tue},E={a:le,A:K,b:te,B:de,c:null,d:Eue,e:Eue,f:ekt,g:ckt,G:fkt,H:QSt,I:ZSt,j:JSt,L:KRe,m:tkt,M:nkt,p:ue,q:ae,Q:Aue,s:Oue,S:rkt,u:ikt,U:okt,V:skt,w:akt,W:lkt,x:null,X:null,y:ukt,Y:dkt,Z:hkt,"%":Tue},T={a:D,A:P,b:F,B:z,c:$,d:Sue,e:Sue,f:MSt,g:wue,G:xue,H:kue,I:kue,j:TSt,L:RSt,m:ESt,M:ASt,p:I,q:CSt,Q:NSt,s:LSt,S:OSt,u:vSt,U:xSt,V:wSt,w:bSt,W:SSt,x:B,X:H,y:wue,Y:xue,Z:kSt,"%":_St};C.x=O(n,C),C.X=O(r,C),C.c=O(t,C),E.x=O(n,E),E.X=O(r,E),E.c=O(t,E);function O(ie,he){return function(fe){var se=[],Se=-1,pe=0,Ee=ie.length,ke,Ie,Be;for(fe instanceof Date||(fe=new Date(+fe));++Se<Ee;)ie.charCodeAt(Se)===37&&(se.push(ie.slice(pe,Se)),(Ie=vue[ke=ie.charAt(++Se)])!=null?ke=ie.charAt(++Se):Ie=ke==="e"?" ":"0",(Be=he[ke])&&(ke=Be(fe,Ie)),se.push(ke),pe=Se+1);return se.push(ie.slice(pe,Se)),se.join("")}}function M(ie,he){return function(fe){var se=Sk(1900,void 0,1),Se=N(se,ie,fe+="",0),pe,Ee;if(Se!=fe.length)return null;if("Q"in se)return new Date(se.Q);if("s"in se)return new Date(se.s*1e3+("L"in se?se.L:0));if(he&&!("Z"in se)&&(se.Z=0),"p"in se&&(se.H=se.H%12+se.p*12),se.m===void 0&&(se.m="q"in se?se.q:0),"V"in se){if(se.V<1||se.V>53)return null;"w"in se||(se.w=1),"Z"in se?(pe=j8(Sk(se.y,0,1)),Ee=pe.getUTCDay(),pe=Ee>4||Ee===0?tI.ceil(pe):tI(pe),pe=dA.offset(pe,(se.V-1)*7),se.y=pe.getUTCFullYear(),se.m=pe.getUTCMonth(),se.d=pe.getUTCDate()+(se.w+6)%7):(pe=P8(Sk(se.y,0,1)),Ee=pe.getDay(),pe=Ee>4||Ee===0?eI.ceil(pe):eI(pe),pe=oS.offset(pe,(se.V-1)*7),se.y=pe.getFullYear(),se.m=pe.getMonth(),se.d=pe.getDate()+(se.w+6)%7)}else("W"in se||"U"in se)&&("w"in se||(se.w="u"in se?se.u%7:"W"in se?1:0),Ee="Z"in se?j8(Sk(se.y,0,1)).getUTCDay():P8(Sk(se.y,0,1)).getDay(),se.m=0,se.d="W"in se?(se.w+6)%7+se.W*7-(Ee+5)%7:se.w+se.U*7-(Ee+6)%7);return"Z"in se?(se.H+=se.Z/100|0,se.M+=se.Z%100,j8(se)):P8(se)}}function N(ie,he,fe,se){for(var Se=0,pe=he.length,Ee=fe.length,ke,Ie;Se<pe;){if(se>=Ee)return-1;if(ke=he.charCodeAt(Se++),ke===37){if(ke=he.charAt(Se++),Ie=T[ke in vue?he.charAt(Se++):ke],!Ie||(se=Ie(ie,fe,se))<0)return-1}else if(ke!=fe.charCodeAt(se++))return-1}return se}function I(ie,he,fe){var se=u.exec(he.slice(fe));return se?(ie.p=c.get(se[0].toLowerCase()),fe+se[0].length):-1}function D(ie,he,fe){var se=m.exec(he.slice(fe));return se?(ie.w=g.get(se[0].toLowerCase()),fe+se[0].length):-1}function P(ie,he,fe){var se=d.exec(he.slice(fe));return se?(ie.w=h.get(se[0].toLowerCase()),fe+se[0].length):-1}function F(ie,he,fe){var se=w.exec(he.slice(fe));return se?(ie.m=S.get(se[0].toLowerCase()),fe+se[0].length):-1}function z(ie,he,fe){var se=b.exec(he.slice(fe));return se?(ie.m=v.get(se[0].toLowerCase()),fe+se[0].length):-1}function $(ie,he,fe){return N(ie,t,he,fe)}function B(ie,he,fe){return N(ie,n,he,fe)}function H(ie,he,fe){return N(ie,r,he,fe)}function U(ie){return s[ie.getDay()]}function W(ie){return o[ie.getDay()]}function q(ie){return l[ie.getMonth()]}function Y(ie){return a[ie.getMonth()]}function Q(ie){return i[+(ie.getHours()>=12)]}function G(ie){return 1+~~(ie.getMonth()/3)}function le(ie){return s[ie.getUTCDay()]}function K(ie){return o[ie.getUTCDay()]}function te(ie){return l[ie.getUTCMonth()]}function de(ie){return a[ie.getUTCMonth()]}function ue(ie){return i[+(ie.getUTCHours()>=12)]}function ae(ie){return 1+~~(ie.getUTCMonth()/3)}return{format:function(ie){var he=O(ie+="",C);return he.toString=function(){return ie},he},parse:function(ie){var he=M(ie+="",!1);return he.toString=function(){return ie},he},utcFormat:function(ie){var he=O(ie+="",E);return he.toString=function(){return ie},he},utcParse:function(ie){var he=M(ie+="",!0);return he.toString=function(){return ie},he}}}var vue={"-":"",_:" ",0:"0"},Ho=/^\s*\d+/,mSt=/^%/,gSt=/[\\^$*+?|[\]().{}]/g;function ur(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 ySt(e){return e.replace(gSt,"\\$&")}function kk(e){return new RegExp("^(?:"+e.map(ySt).join("|")+")","i")}function Ck(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function bSt(e,t,n){var r=Ho.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function vSt(e,t,n){var r=Ho.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function xSt(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function wSt(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function SSt(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function xue(e,t,n){var r=Ho.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function wue(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function kSt(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 CSt(e,t,n){var r=Ho.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function ESt(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function Sue(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function TSt(e,t,n){var r=Ho.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function kue(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function ASt(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function OSt(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function RSt(e,t,n){var r=Ho.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function MSt(e,t,n){var r=Ho.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function _St(e,t,n){var r=mSt.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function NSt(e,t,n){var r=Ho.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function LSt(e,t,n){var r=Ho.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function Cue(e,t){return ur(e.getDate(),t,2)}function ISt(e,t){return ur(e.getHours(),t,2)}function PSt(e,t){return ur(e.getHours()%12||12,t,2)}function jSt(e,t){return ur(1+oS.count(_d(e),e),t,3)}function qRe(e,t){return ur(e.getMilliseconds(),t,3)}function DSt(e,t){return qRe(e,t)+"000"}function $St(e,t){return ur(e.getMonth()+1,t,2)}function zSt(e,t){return ur(e.getMinutes(),t,2)}function FSt(e,t){return ur(e.getSeconds(),t,2)}function BSt(e){var t=e.getDay();return t===0?7:t}function HSt(e,t){return ur(fA.count(_d(e)-1,e),t,2)}function GRe(e){var t=e.getDay();return t>=4||t===0?nw(e):nw.ceil(e)}function USt(e,t){return e=GRe(e),ur(nw.count(_d(e),e)+(_d(e).getDay()===4),t,2)}function VSt(e){return e.getDay()}function WSt(e,t){return ur(eI.count(_d(e)-1,e),t,2)}function qSt(e,t){return ur(e.getFullYear()%100,t,2)}function GSt(e,t){return e=GRe(e),ur(e.getFullYear()%100,t,2)}function KSt(e,t){return ur(e.getFullYear()%1e4,t,4)}function YSt(e,t){var n=e.getDay();return e=n>=4||n===0?nw(e):nw.ceil(e),ur(e.getFullYear()%1e4,t,4)}function XSt(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+ur(t/60|0,"0",2)+ur(t%60,"0",2)}function Eue(e,t){return ur(e.getUTCDate(),t,2)}function QSt(e,t){return ur(e.getUTCHours(),t,2)}function ZSt(e,t){return ur(e.getUTCHours()%12||12,t,2)}function JSt(e,t){return ur(1+dA.count(Nd(e),e),t,3)}function KRe(e,t){return ur(e.getUTCMilliseconds(),t,3)}function ekt(e,t){return KRe(e,t)+"000"}function tkt(e,t){return ur(e.getUTCMonth()+1,t,2)}function nkt(e,t){return ur(e.getUTCMinutes(),t,2)}function rkt(e,t){return ur(e.getUTCSeconds(),t,2)}function ikt(e){var t=e.getUTCDay();return t===0?7:t}function okt(e,t){return ur(hA.count(Nd(e)-1,e),t,2)}function YRe(e){var t=e.getUTCDay();return t>=4||t===0?rw(e):rw.ceil(e)}function skt(e,t){return e=YRe(e),ur(rw.count(Nd(e),e)+(Nd(e).getUTCDay()===4),t,2)}function akt(e){return e.getUTCDay()}function lkt(e,t){return ur(tI.count(Nd(e)-1,e),t,2)}function ukt(e,t){return ur(e.getUTCFullYear()%100,t,2)}function ckt(e,t){return e=YRe(e),ur(e.getUTCFullYear()%100,t,2)}function dkt(e,t){return ur(e.getUTCFullYear()%1e4,t,4)}function fkt(e,t){var n=e.getUTCDay();return e=n>=4||n===0?rw(e):rw.ceil(e),ur(e.getUTCFullYear()%1e4,t,4)}function hkt(){return"+0000"}function Tue(){return"%"}function Aue(e){return+e}function Oue(e){return Math.floor(+e/1e3)}var zv,XRe,QRe;pkt({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 pkt(e){return zv=pSt(e),XRe=zv.format,zv.parse,QRe=zv.utcFormat,zv.utcParse,zv}function mkt(e){return new Date(e)}function gkt(e){return e instanceof Date?+e:+new Date(+e)}function KY(e,t,n,r,i,o,s,a,l,u){var c=FY(),d=c.invert,h=c.domain,m=u(".%L"),g=u(":%S"),b=u("%I:%M"),v=u("%I %p"),w=u("%a %d"),S=u("%b %d"),C=u("%B"),E=u("%Y");function T(O){return(l(O)<O?m:a(O)<O?g:s(O)<O?b:o(O)<O?v:r(O)<O?i(O)<O?w:S:n(O)<O?C:E)(O)}return c.invert=function(O){return new Date(d(O))},c.domain=function(O){return arguments.length?h(Array.from(O,gkt)):h().map(mkt)},c.ticks=function(O){var M=h();return e(M[0],M[M.length-1],O??10)},c.tickFormat=function(O,M){return M==null?T:u(M)},c.nice=function(O){var M=h();return(!O||typeof O.range!="function")&&(O=t(M[0],M[M.length-1],O??10)),O?h(DRe(M,O)):c},c.copy=function(){return cA(c,KY(e,t,n,r,i,o,s,a,l,u))},c}function ZRe(){return hu.apply(KY(fSt,hSt,_d,Zj,fA,oS,Xj,Kj,hh,XRe).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function ykt(){return hu.apply(KY(cSt,dSt,Nd,Jj,hA,dA,Qj,Yj,hh,QRe).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function eD(){var e=0,t=1,n,r,i,o,s=Gs,a=!1,l;function u(d){return d==null||isNaN(d=+d)?l:s(i===0?.5:(d=(o(d)-n)*i,a?Math.max(0,Math.min(1,d)):d))}u.domain=function(d){return arguments.length?([e,t]=d,n=o(e=+e),r=o(t=+t),i=n===r?0:1/(r-n),u):[e,t]},u.clamp=function(d){return arguments.length?(a=!!d,u):a},u.interpolator=function(d){return arguments.length?(s=d,u):s};function c(d){return function(h){var m,g;return arguments.length?([m,g]=h,s=d(m,g),u):[s(0),s(1)]}}return u.range=c(Ah),u.rangeRound=c(qj),u.unknown=function(d){return arguments.length?(l=d,u):l},function(d){return o=d,n=d(e),r=d(t),i=n===r?0:1/(r-n),u}}function Hg(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function JRe(){var e=Bg(eD()(Gs));return e.copy=function(){return Hg(e,JRe())},Zh.apply(e,arguments)}function eMe(){var e=UY(eD()).domain([1,10]);return e.copy=function(){return Hg(e,eMe()).base(e.base())},Zh.apply(e,arguments)}function tMe(){var e=VY(eD());return e.copy=function(){return Hg(e,tMe()).constant(e.constant())},Zh.apply(e,arguments)}function YY(){var e=WY(eD());return e.copy=function(){return Hg(e,YY()).exponent(e.exponent())},Zh.apply(e,arguments)}function bkt(){return YY.apply(null,arguments).exponent(.5)}function nMe(){var e=[],t=Gs;function n(r){if(r!=null&&!isNaN(r=+r))return t((lA(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(ug),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)=>qxt(e,o/r))},n.copy=function(){return nMe(t).domain(e)},Zh.apply(n,arguments)}function tD(){var e=0,t=.5,n=1,r=1,i,o,s,a,l,u=Gs,c,d=!1,h;function m(b){return isNaN(b=+b)?h:(b=.5+((b=+c(b))-o)*(r*b<r*o?a:l),u(d?Math.max(0,Math.min(1,b)):b))}m.domain=function(b){return arguments.length?([e,t,n]=b,i=c(e=+e),o=c(t=+t),s=c(n=+n),a=i===o?0:.5/(o-i),l=o===s?0:.5/(s-o),r=o<i?-1:1,m):[e,t,n]},m.clamp=function(b){return arguments.length?(d=!!b,m):d},m.interpolator=function(b){return arguments.length?(u=b,m):u};function g(b){return function(v){var w,S,C;return arguments.length?([w,S,C]=v,u=_wt(b,[w,S,C]),m):[u(0),u(.5),u(1)]}}return m.range=g(Ah),m.rangeRound=g(qj),m.unknown=function(b){return arguments.length?(h=b,m):h},function(b){return c=b,i=b(e),o=b(t),s=b(n),a=i===o?0:.5/(o-i),l=o===s?0:.5/(s-o),r=o<i?-1:1,m}}function rMe(){var e=Bg(tD()(Gs));return e.copy=function(){return Hg(e,rMe())},Zh.apply(e,arguments)}function iMe(){var e=UY(tD()).domain([.1,1,10]);return e.copy=function(){return Hg(e,iMe()).base(e.base())},Zh.apply(e,arguments)}function oMe(){var e=VY(tD());return e.copy=function(){return Hg(e,oMe()).constant(e.constant())},Zh.apply(e,arguments)}function XY(){var e=WY(tD());return e.copy=function(){return Hg(e,XY()).exponent(e.exponent())},Zh.apply(e,arguments)}function vkt(){return XY.apply(null,arguments).exponent(.5)}function xkt(e,t){t.domain&&("nice"in e||"quantiles"in e||"padding"in e,e.domain(t.domain))}function wkt(e,t){t.range&&("padding"in e,e.range(t.range))}function Skt(e,t){"align"in e&&"align"in t&&typeof t.align<"u"&&e.align(t.align)}function kkt(e,t){"base"in e&&"base"in t&&typeof t.base<"u"&&e.base(t.base)}function Ckt(e,t){"clamp"in e&&"clamp"in t&&typeof t.clamp<"u"&&e.clamp(t.clamp)}function Ekt(e,t){"constant"in e&&"constant"in t&&typeof t.constant<"u"&&e.constant(t.constant)}function Tkt(e,t){"exponent"in e&&"exponent"in t&&typeof t.exponent<"u"&&e.exponent(t.exponent)}const Rue={lab:Twt,hcl:Awt,"hcl-long":Owt,hsl:Cwt,"hsl-long":Ewt,cubehelix:Rwt,"cubehelix-long":Mwt,rgb:XE};function Akt(e){switch(e){case"lab":case"hcl":case"hcl-long":case"hsl":case"hsl-long":case"cubehelix":case"cubehelix-long":case"rgb":return Rue[e]}const{type:t,gamma:n}=e,r=Rue[t];return typeof n>"u"?r:r.gamma(n)}function Okt(e,t){if("interpolate"in t&&"interpolate"in e&&typeof t.interpolate<"u"){const n=Akt(t.interpolate);e.interpolate(n)}}const Rkt=new Date(Date.UTC(2020,1,2,3,4,5)),Mkt="%Y-%m-%d %H:%M";function _kt(e){return e.tickFormat(1,Mkt)(Rkt)==="2020-02-02 03:04"}const Mue={day:oS,hour:Xj,minute:Kj,month:Zj,second:hh,week:fA,year:_d},_ue={day:dA,hour:Qj,minute:Yj,month:Jj,second:hh,week:hA,year:Nd};function Nkt(e,t){if("nice"in t&&typeof t.nice<"u"&&"nice"in e){const{nice:n}=t;if(typeof n=="boolean")n&&e.nice();else if(typeof n=="number")e.nice(n);else{const r=e,i=_kt(r);if(typeof n=="string")r.nice(i?_ue[n]:Mue[n]);else{const{interval:o,step:s}=n,a=(i?_ue[o]:Mue[o]).every(s);a!=null&&r.nice(a)}}}}function Lkt(e,t){"padding"in e&&"padding"in t&&typeof t.padding<"u"&&e.padding(t.padding),"paddingInner"in e&&"paddingInner"in t&&typeof t.paddingInner<"u"&&e.paddingInner(t.paddingInner),"paddingOuter"in e&&"paddingOuter"in t&&typeof t.paddingOuter<"u"&&e.paddingOuter(t.paddingOuter)}function Ikt(e,t){if(t.reverse){const n=e.range().slice().reverse();"padding"in e,e.range(n)}}function Pkt(e,t){"round"in t&&typeof t.round<"u"&&(t.round&&"interpolate"in t&&typeof t.interpolate<"u"?console.warn("[visx/scale/applyRound] ignoring round: scale config contains round and interpolate. only applying interpolate. config:",t):"round"in e?e.round(t.round):"interpolate"in e&&t.round&&e.interpolate(qj))}function jkt(e,t){"unknown"in e&&"unknown"in t&&typeof t.unknown<"u"&&e.unknown(t.unknown)}function Dkt(e,t){if("zero"in t&&t.zero===!0){const n=e.domain(),[r,i]=n,o=i<r,[s,a]=o?[i,r]:[r,i],l=[Math.min(0,s),Math.max(0,a)];e.domain(o?l.reverse():l)}}const $kt=["domain","nice","zero","interpolate","round","range","reverse","align","base","clamp","constant","exponent","padding","unknown"],zkt={domain:xkt,nice:Nkt,zero:Dkt,interpolate:Okt,round:Pkt,align:Skt,base:kkt,clamp:Ckt,constant:Ekt,exponent:Tkt,padding:Lkt,range:wkt,reverse:Ikt,unknown:jkt};function QY(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];const r=new Set(t),i=$kt.filter(o=>r.has(o));return function(s,a){return typeof a<"u"&&i.forEach(l=>{zkt[l](s,a)}),s}}const Fkt=QY("domain","range","reverse","align","padding","round");function Bkt(e){return Fkt(Jx(),e)}const Hkt=QY("domain","range","reverse","clamp","interpolate","nice","round","zero");function Hh(e){return Hkt(ZE(),e)}const Ukt=QY("domain","range","reverse","clamp","interpolate","nice","round");function Vkt(e){return Ukt(ZRe(),e)}function sMe(e){if((typeof e=="function"||typeof e=="object"&&e)&&"valueOf"in e){const t=e.valueOf();if(typeof t=="number")return t}return e}function aMe(e,t){const n=e;return"ticks"in n?n.ticks(t):n.domain().filter((r,i,o)=>t==null||o.length<=t||i%Math.round((o.length-1)/t)===0)}const Yu="left";function ph(e){return e==null||e===""?Yu:String(e)}function nD(e){const t=new Map;for(const n of e){const r=ph(n.yAxisId),i=t.get(r)??[];i.push(n),t.set(r,i)}return t}function lMe(e,t){const n=e[Yu];return n||(Object.values(e)[0]??t)}function Wkt({lines:e,innerHeight:t,resolveDomain:n}){const r=nD(e),i={};for(const[o,s]of r){const a=s.map(u=>u.dataKey),l=n(a);i[o]=Hh({range:[t,0],domain:l,nice:!0})}return i[Yu]||(i[Yu]=Hh({range:[t,0],domain:[0,100],nice:!0})),i}function qkt({lines:e,innerHeight:t,domainsByAxis:n}){const r=nD(e),i={};for(const[o]of r){const s=n[o]??n[Yu]??[0,100];i[o]=Hh({range:[t,0],domain:s})}return i[Yu]||(i[Yu]=Hh({range:[t,0],domain:n[Yu]??[0,100]})),i}function Gkt(e){return{[Yu]:e}}const Bo={background:"var(--chart-background)",foreground:"var(--chart-foreground)",foregroundMuted:"var(--chart-foreground-muted)",linePrimary:"var(--chart-line-primary)",crosshair:"var(--chart-crosshair)",grid:"var(--chart-grid)",tooltipBackground:"var(--chart-tooltip-background)"},D8=["var(--chart-1)","var(--chart-2)","var(--chart-3)","var(--chart-4)","var(--chart-5)"],uMe=A.createContext(null),cMe=A.createContext(null);function dMe({children:e,value:t}){const n=A.useMemo(()=>({data:t.data,renderData:t.renderData,xScale:t.xScale,yScale:t.yScale,yScales:t.yScales,width:t.width,height:t.height,innerWidth:t.innerWidth,innerHeight:t.innerHeight,margin:t.margin,columnWidth:t.columnWidth,containerRef:t.containerRef,lines:t.lines,referenceAreas:t.referenceAreas,chartPhase:t.chartPhase,chartStatus:t.chartStatus,loadingLabel:t.loadingLabel,yDomainTweenDuration:t.yDomainTweenDuration,yDomainSkeletonByAxis:t.yDomainSkeletonByAxis,yDomainTargetByAxis:t.yDomainTargetByAxis,isLoaded:t.isLoaded,animationDuration:t.animationDuration,animationEasing:t.animationEasing,enterTransition:t.enterTransition,revealEpoch:t.revealEpoch,notifyLoadingPulseComplete:t.notifyLoadingPulseComplete,xAccessor:t.xAccessor,dateLabels:t.dateLabels,xDomain:t.xDomain,xDomainSlotCount:t.xDomainSlotCount,barScale:t.barScale,bandWidth:t.bandWidth,barXAccessor:t.barXAccessor,orientation:t.orientation,stacked:t.stacked,stackOffsets:t.stackOffsets,composedBarDataKeys:t.composedBarDataKeys,composedBarSize:t.composedBarSize,composedMaxBarSize:t.composedMaxBarSize,composedBarGap:t.composedBarGap,composedStacked:t.composedStacked,composedStackOffsets:t.composedStackOffsets,composedStackGap:t.composedStackGap}),[t.data,t.renderData,t.xScale,t.yScale,t.yScales,t.width,t.height,t.innerWidth,t.innerHeight,t.margin,t.columnWidth,t.containerRef,t.lines,t.referenceAreas,t.chartPhase,t.chartStatus,t.loadingLabel,t.yDomainTweenDuration,t.yDomainSkeletonByAxis,t.yDomainTargetByAxis,t.isLoaded,t.animationDuration,t.animationEasing,t.enterTransition,t.revealEpoch,t.notifyLoadingPulseComplete,t.xAccessor,t.dateLabels,t.xDomain,t.xDomainSlotCount,t.barScale,t.bandWidth,t.barXAccessor,t.orientation,t.stacked,t.stackOffsets,t.composedBarDataKeys,t.composedBarSize,t.composedMaxBarSize,t.composedBarGap,t.composedStacked,t.composedStackOffsets,t.composedStackGap]),r=A.useMemo(()=>({tooltipData:t.tooltipData,setTooltipData:t.setTooltipData,selection:t.selection,clearSelection:t.clearSelection,hoveredBarIndex:t.hoveredBarIndex,setHoveredBarIndex:t.setHoveredBarIndex,hoveredCandleIndex:t.hoveredCandleIndex,setHoveredCandleIndex:t.setHoveredCandleIndex}),[t.tooltipData,t.setTooltipData,t.selection,t.clearSelection,t.hoveredBarIndex,t.setHoveredBarIndex,t.hoveredCandleIndex,t.setHoveredCandleIndex]);return y.jsx(uMe.Provider,{value:n,children:y.jsx(cMe.Provider,{value:r,children:e})})}function _a(){const e=A.useContext(uMe);if(!e)throw new Error("useChartStable must be used within a ChartProvider. Make sure your component is wrapped in <LineChart>, <AreaChart>, <BarChart>, or <ComposedChart>.");return e}function pA(e){const{yScales:t,yScale:n}=_a(),r=e==null||e===""?Yu:String(e);return t[r]??n}function mA(){const e=A.useContext(cMe);if(!e)throw new Error("useChartHover must be used within a ChartProvider. Make sure your component is wrapped in <LineChart>, <AreaChart>, <BarChart>, or <ComposedChart>.");return e}function ZY(){const e=_a(),t=mA();return{...e,...t}}const JY=A.createContext({});function gA(e){const t=A.useRef(null);return t.current===null&&(t.current=e()),t.current}const Kkt=typeof window<"u",rD=Kkt?A.useLayoutEffect:A.useEffect,iD=A.createContext(null);function eX(e,t){e.indexOf(t)===-1&&e.push(t)}function iw(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const Ld=(e,t,n)=>n>t?t:n<e?e:n;let oD=()=>{};const Eg={},fMe=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),hMe=e=>typeof e=="object"&&e!==null,pMe=e=>/^0[^.\s]+$/u.test(e);function mMe(e){let t;return()=>(t===void 0&&(t=e()),t)}const su=e=>e,yA=(...e)=>e.reduce((t,n)=>r=>n(t(r))),ow=(e,t,n)=>{const r=t-e;return r?(n-e)/r:1};class tX{constructor(){this.subscriptions=[]}add(t){return eX(this.subscriptions,t),()=>iw(this.subscriptions,t)}notify(t,n,r){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](t,n,r);else for(let o=0;o<i;o++){const s=this.subscriptions[o];s&&s(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const Sa=e=>e*1e3,eu=e=>e/1e3,gMe=(e,t)=>t?e*(1e3/t):0,Ykt=(e,t,n)=>{const r=t-e;return((n-e)%r+r)%r+e},yMe=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,Xkt=1e-7,Qkt=12;function Zkt(e,t,n,r,i){let o,s,a=0;do s=t+(n-t)/2,o=yMe(s,r,i)-e,o>0?n=s:t=s;while(Math.abs(o)>Xkt&&++a<Qkt);return s}function bA(e,t,n,r){if(e===t&&n===r)return su;const i=o=>Zkt(o,0,1,e,n);return o=>o===0||o===1?o:yMe(i(o),t,r)}const bMe=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,nX=e=>t=>1-e(1-t),vMe=bA(.33,1.53,.69,.99),rX=nX(vMe),xMe=bMe(rX),wMe=e=>e>=1?1:(e*=2)<1?.5*rX(e):.5*(2-Math.pow(2,-10*(e-1))),iX=e=>1-Math.sin(Math.acos(e)),SMe=nX(iX),kMe=bMe(iX),Jkt=bA(.42,0,1,1),eCt=bA(0,0,.58,1),CMe=bA(.42,0,.58,1),EMe=e=>Array.isArray(e)&&typeof e[0]!="number";function TMe(e,t){return EMe(e)?e[Ykt(0,e.length,t)]:e}const AMe=e=>Array.isArray(e)&&typeof e[0]=="number",tCt={linear:su,easeIn:Jkt,easeInOut:CMe,easeOut:eCt,circIn:iX,circInOut:kMe,circOut:SMe,backIn:rX,backInOut:xMe,backOut:vMe,anticipate:wMe},nCt=e=>typeof e=="string",Nue=e=>{if(AMe(e)){oD(e.length===4);const[t,n,r,i]=e;return bA(t,n,r,i)}else if(nCt(e))return tCt[e];return e},sM=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function rCt(e){let t=new Set,n=new Set,r=!1,i=!1;const o=new WeakSet;let s={delta:0,timestamp:0,isProcessing:!1};function a(u){o.has(u)&&(l.schedule(u),e()),u(s)}const l={schedule:(u,c=!1,d=!1)=>{const m=d&&r?t:n;return c&&o.add(u),m.add(u),u},cancel:u=>{n.delete(u),o.delete(u)},process:u=>{if(s=u,r){i=!0;return}r=!0;const c=t;t=n,n=c,t.forEach(a),t.clear(),r=!1,i&&(i=!1,l.process(u))}};return l}const iCt=40;function OMe(e,t){let n=!1,r=!0;const i={delta:0,timestamp:0,isProcessing:!1},o=()=>n=!0,s=sM.reduce((C,E)=>(C[E]=rCt(o),C),{}),{setup:a,read:l,resolveKeyframes:u,preUpdate:c,update:d,preRender:h,render:m,postRender:g}=s,b=()=>{const C=Eg.useManualTiming,E=C?i.timestamp:performance.now();n=!1,C||(i.delta=r?1e3/60:Math.max(Math.min(E-i.timestamp,iCt),1)),i.timestamp=E,i.isProcessing=!0,a.process(i),l.process(i),u.process(i),c.process(i),d.process(i),h.process(i),m.process(i),g.process(i),i.isProcessing=!1,n&&t&&(r=!1,e(b))},v=()=>{n=!0,r=!0,i.isProcessing||e(b)};return{schedule:sM.reduce((C,E)=>{const T=s[E];return C[E]=(O,M=!1,N=!1)=>(n||v(),T.schedule(O,M,N)),C},{}),cancel:C=>{for(let E=0;E<sM.length;E++)s[sM[E]].cancel(C)},state:i,steps:s}}const{schedule:Rr,cancel:Uh,state:es,steps:$8}=OMe(typeof requestAnimationFrame<"u"?requestAnimationFrame:su,!0);let C_;function oCt(){C_=void 0}const Ks={now:()=>(C_===void 0&&Ks.set(es.isProcessing||Eg.useManualTiming?es.timestamp:performance.now()),C_),set:e=>{C_=e,queueMicrotask(oCt)}},RMe=e=>t=>typeof t=="string"&&t.startsWith(e),MMe=RMe("--"),sCt=RMe("var(--"),oX=e=>sCt(e)?aCt.test(e.split("/*")[0].trim()):!1,aCt=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function Lue(e){return typeof e!="string"?!1:e.split("/*")[0].includes("var(--")}const sS={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},JE={...sS,transform:e=>Ld(0,1,e)},aM={...sS,default:1},KC=e=>Math.round(e*1e5)/1e5,sX=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function lCt(e){return e==null}const uCt=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,aX=(e,t)=>n=>!!(typeof n=="string"&&uCt.test(n)&&n.startsWith(e)||t&&!lCt(n)&&Object.prototype.hasOwnProperty.call(n,t)),_Me=(e,t,n)=>r=>{if(typeof r!="string")return r;const[i,o,s,a]=r.match(sX);return{[e]:parseFloat(i),[t]:parseFloat(o),[n]:parseFloat(s),alpha:a!==void 0?parseFloat(a):1}},cCt=e=>Ld(0,255,e),z8={...sS,transform:e=>Math.round(cCt(e))},oy={test:aX("rgb","red"),parse:_Me("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+z8.transform(e)+", "+z8.transform(t)+", "+z8.transform(n)+", "+KC(JE.transform(r))+")"};function dCt(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}const hV={test:aX("#"),parse:dCt,transform:oy.transform},vA=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Tf=vA("deg"),Cd=vA("%"),Dt=vA("px"),fCt=vA("vh"),hCt=vA("vw"),Iue={...Cd,parse:e=>Cd.parse(e)/100,transform:e=>Cd.transform(e*100)},v1={test:aX("hsl","hue"),parse:_Me("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+Cd.transform(KC(t))+", "+Cd.transform(KC(n))+", "+KC(JE.transform(r))+")"},Yi={test:e=>oy.test(e)||hV.test(e)||v1.test(e),parse:e=>oy.test(e)?oy.parse(e):v1.test(e)?v1.parse(e):hV.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?oy.transform(e):v1.transform(e),getAnimatableNone:e=>{const t=Yi.parse(e);return t.alpha=0,Yi.transform(t)}},pCt=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function mCt(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(sX))==null?void 0:t.length)||0)+(((n=e.match(pCt))==null?void 0:n.length)||0)>0}const NMe="number",LMe="color",gCt="var",yCt="var(",Pue="${}",bCt=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function sw(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},i=[];let o=0;const a=t.replace(bCt,l=>(Yi.test(l)?(r.color.push(o),i.push(LMe),n.push(Yi.parse(l))):l.startsWith(yCt)?(r.var.push(o),i.push(gCt),n.push(l)):(r.number.push(o),i.push(NMe),n.push(parseFloat(l))),++o,Pue)).split(Pue);return{values:n,split:a,indexes:r,types:i}}function vCt(e){return sw(e).values}function IMe({split:e,types:t}){const n=e.length;return r=>{let i="";for(let o=0;o<n;o++)if(i+=e[o],r[o]!==void 0){const s=t[o];s===NMe?i+=KC(r[o]):s===LMe?i+=Yi.transform(r[o]):i+=r[o]}return i}}function xCt(e){return IMe(sw(e))}const wCt=e=>typeof e=="number"?0:Yi.test(e)?Yi.getAnimatableNone(e):e,SCt=(e,t)=>typeof e=="number"?t!=null&&t.trim().endsWith("/")?e:0:wCt(e);function kCt(e){const t=sw(e);return IMe(t)(t.values.map((r,i)=>SCt(r,t.split[i])))}const nc={test:mCt,parse:vCt,createTransformer:xCt,getAnimatableNone:kCt};function F8(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function CCt({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,o=0,s=0;if(!t)i=o=s=n;else{const a=n<.5?n*(1+t):n+t-n*t,l=2*n-a;i=F8(l,a,e+1/3),o=F8(l,a,e),s=F8(l,a,e-1/3)}return{red:Math.round(i*255),green:Math.round(o*255),blue:Math.round(s*255),alpha:r}}function nI(e,t){return n=>n>0?t:e}const jr=(e,t,n)=>e+(t-e)*n,B8=(e,t,n)=>{const r=e*e,i=n*(t*t-r)+r;return i<0?0:Math.sqrt(i)},ECt=[hV,oy,v1],TCt=e=>ECt.find(t=>t.test(e));function jue(e){const t=TCt(e);if(!t)return!1;let n=t.parse(e);return t===v1&&(n=CCt(n)),n}const Due=(e,t)=>{const n=jue(e),r=jue(t);if(!n||!r)return nI(e,t);const i={...n};return o=>(i.red=B8(n.red,r.red,o),i.green=B8(n.green,r.green,o),i.blue=B8(n.blue,r.blue,o),i.alpha=jr(n.alpha,r.alpha,o),oy.transform(i))},pV=new Set(["none","hidden"]);function ACt(e,t){return pV.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function OCt(e,t){return n=>jr(e,t,n)}function lX(e){return typeof e=="number"?OCt:typeof e=="string"?oX(e)?nI:Yi.test(e)?Due:_Ct:Array.isArray(e)?PMe:typeof e=="object"?Yi.test(e)?Due:RCt:nI}function PMe(e,t){const n=[...e],r=n.length,i=e.map((o,s)=>lX(o)(o,t[s]));return o=>{for(let s=0;s<r;s++)n[s]=i[s](o);return n}}function RCt(e,t){const n={...e,...t},r={};for(const i in n)e[i]!==void 0&&t[i]!==void 0&&(r[i]=lX(e[i])(e[i],t[i]));return i=>{for(const o in r)n[o]=r[o](i);return n}}function MCt(e,t){const n=[],r={color:0,var:0,number:0};for(let i=0;i<t.values.length;i++){const o=t.types[i],s=e.indexes[o][r[o]],a=e.values[s]??0;n[i]=a,r[o]++}return n}const _Ct=(e,t)=>{const n=nc.createTransformer(t),r=sw(e),i=sw(t);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?pV.has(e)&&!i.values.length||pV.has(t)&&!r.values.length?ACt(e,t):yA(PMe(MCt(r,i),i.values),n):nI(e,t)};function jMe(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?jr(e,t,n):lX(e)(e,t)}const NCt=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>Rr.update(t,n),stop:()=>Uh(t),now:()=>es.isProcessing?es.timestamp:Ks.now()}},DMe=(e,t,n=10)=>{let r="";const i=Math.max(Math.round(t/n),2);for(let o=0;o<i;o++)r+=Math.round(e(o/(i-1))*1e4)/1e4+", ";return`linear(${r.substring(0,r.length-2)})`},rI=2e4;function uX(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<rI;)t+=n,r=e.next(t);return t>=rI?1/0:t}function $Me(e,t=100,n){const r=n({...e,keyframes:[0,t]}),i=Math.min(uX(r),rI);return{type:"keyframes",ease:o=>r.next(i*o).value/t,duration:eu(i)}}const wi={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};function mV(e,t){return e*Math.sqrt(1-t*t)}const LCt=12;function ICt(e,t,n){let r=n;for(let i=1;i<LCt;i++)r=r-e(r)/t(r);return r}const H8=.001;function PCt({duration:e=wi.duration,bounce:t=wi.bounce,velocity:n=wi.velocity,mass:r=wi.mass}){let i,o,s=1-t;s=Ld(wi.minDamping,wi.maxDamping,s),e=Ld(wi.minDuration,wi.maxDuration,eu(e)),s<1?(i=u=>{const c=u*s,d=c*e,h=c-n,m=mV(u,s),g=Math.exp(-d);return H8-h/m*g},o=u=>{const d=u*s*e,h=d*n+n,m=Math.pow(s,2)*Math.pow(u,2)*e,g=Math.exp(-d),b=mV(Math.pow(u,2),s);return(-i(u)+H8>0?-1:1)*((h-m)*g)/b}):(i=u=>{const c=Math.exp(-u*e),d=(u-n)*e+1;return-H8+c*d},o=u=>{const c=Math.exp(-u*e),d=(n-u)*(e*e);return c*d});const a=5/e,l=ICt(i,o,a);if(e=Sa(e),isNaN(l))return{stiffness:wi.stiffness,damping:wi.damping,duration:e};{const u=Math.pow(l,2)*r;return{stiffness:u,damping:s*2*Math.sqrt(r*u),duration:e}}}const jCt=["duration","bounce"],DCt=["stiffness","damping","mass"];function $ue(e,t){return t.some(n=>e[n]!==void 0)}function $Ct(e){let t={velocity:wi.velocity,stiffness:wi.stiffness,damping:wi.damping,mass:wi.mass,isResolvedFromDuration:!1,...e};if(!$ue(e,DCt)&&$ue(e,jCt))if(t.velocity=0,e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),i=r*r,o=2*Ld(.05,1,1-(e.bounce||0))*Math.sqrt(i);t={...t,mass:wi.mass,stiffness:i,damping:o}}else{const n=PCt({...e,velocity:0});t={...t,...n,mass:wi.mass},t.isResolvedFromDuration=!0}return t}function eT(e=wi.visualDuration,t=wi.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:i}=n;const o=n.keyframes[0],s=n.keyframes[n.keyframes.length-1],a={done:!1,value:o},{stiffness:l,damping:u,mass:c,duration:d,velocity:h,isResolvedFromDuration:m}=$Ct({...n,velocity:-eu(n.velocity||0)}),g=h||0,b=u/(2*Math.sqrt(l*c)),v=s-o,w=eu(Math.sqrt(l/c)),S=Math.abs(v)<5;r||(r=S?wi.restSpeed.granular:wi.restSpeed.default),i||(i=S?wi.restDelta.granular:wi.restDelta.default);let C,E,T,O,M,N;if(b<1)T=mV(w,b),O=(g+b*w*v)/T,C=D=>{const P=Math.exp(-b*w*D);return s-P*(O*Math.sin(T*D)+v*Math.cos(T*D))},M=b*w*O+v*T,N=b*w*v-O*T,E=D=>Math.exp(-b*w*D)*(M*Math.sin(T*D)+N*Math.cos(T*D));else if(b===1){C=P=>s-Math.exp(-w*P)*(v+(g+w*v)*P);const D=g+w*v;E=P=>Math.exp(-w*P)*(w*D*P-g)}else{const D=w*Math.sqrt(b*b-1);C=$=>{const B=Math.exp(-b*w*$),H=Math.min(D*$,300);return s-B*((g+b*w*v)*Math.sinh(H)+D*v*Math.cosh(H))/D};const P=(g+b*w*v)/D,F=b*w*P-v*D,z=b*w*v-P*D;E=$=>{const B=Math.exp(-b*w*$),H=Math.min(D*$,300);return B*(F*Math.sinh(H)+z*Math.cosh(H))}}const I={calculatedDuration:m&&d||null,velocity:D=>Sa(E(D)),next:D=>{if(!m&&b<1){const F=Math.exp(-b*w*D),z=Math.sin(T*D),$=Math.cos(T*D),B=s-F*(O*z+v*$),H=Sa(F*(M*z+N*$));return a.done=Math.abs(H)<=r&&Math.abs(s-B)<=i,a.value=a.done?s:B,a}const P=C(D);if(m)a.done=D>=d;else{const F=Sa(E(D));a.done=Math.abs(F)<=r&&Math.abs(s-P)<=i}return a.value=a.done?s:P,a},toString:()=>{const D=Math.min(uX(I),rI),P=DMe(F=>I.next(D*F).value,D,30);return D+"ms "+P},toTransition:()=>{}};return I}eT.applyToOptions=e=>{const t=$Me(e,100,eT);return e.ease=t.ease,e.duration=Sa(t.duration),e.type="keyframes",e};const zCt=5;function zMe(e,t,n){const r=Math.max(t-zCt,0);return gMe(n-e(r),t-r)}function gV({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:o=500,modifyTarget:s,min:a,max:l,restDelta:u=.5,restSpeed:c}){const d=e[0],h={done:!1,value:d},m=N=>a!==void 0&&N<a||l!==void 0&&N>l,g=N=>a===void 0?l:l===void 0||Math.abs(a-N)<Math.abs(l-N)?a:l;let b=n*t;const v=d+b,w=s===void 0?v:s(v);w!==v&&(b=w-d);const S=N=>-b*Math.exp(-N/r),C=N=>w+S(N),E=N=>{const I=S(N),D=C(N);h.done=Math.abs(I)<=u,h.value=h.done?w:D};let T,O;const M=N=>{m(h.value)&&(T=N,O=eT({keyframes:[h.value,g(h.value)],velocity:zMe(C,N,h.value),damping:i,stiffness:o,restDelta:u,restSpeed:c}))};return M(0),{calculatedDuration:null,next:N=>{let I=!1;return!O&&T===void 0&&(I=!0,E(N),M(N)),T!==void 0&&N>=T?O.next(N-T):(!I&&E(N),h)}}}function FCt(e,t,n){const r=[],i=n||Eg.mix||jMe,o=e.length-1;for(let s=0;s<o;s++){let a=i(e[s],e[s+1]);if(t){const l=Array.isArray(t)?t[s]||su:t;a=yA(l,a)}r.push(a)}return r}function FMe(e,t,{clamp:n=!0,ease:r,mixer:i}={}){const o=e.length;if(oD(o===t.length),o===1)return()=>t[0];if(o===2&&t[0]===t[1])return()=>t[1];const s=e[0]===e[1];e[0]>e[o-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=FCt(t,r,i),l=a.length,u=c=>{if(s&&c<e[0])return t[0];let d=0;if(l>1)for(;d<e.length-2&&!(c<e[d+1]);d++);const h=ow(e[d],e[d+1],c);return a[d](h)};return n?c=>u(Ld(e[0],e[o-1],c)):u}function BMe(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const i=ow(0,t,r);e.push(jr(n,1,i))}}function HMe(e){const t=[0];return BMe(t,e.length-1),t}function BCt(e,t){return e.map(n=>n*t)}function HCt(e,t){return e.map(()=>t||CMe).splice(0,e.length-1)}function YC({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const i=EMe(r)?r.map(Nue):Nue(r),o={done:!1,value:t[0]},s=BCt(n&&n.length===t.length?n:HMe(t),e),a=FMe(s,t,{ease:Array.isArray(i)?i:HCt(t,i)});return{calculatedDuration:e,next:l=>(o.value=a(l),o.done=l>=e,o)}}const UCt=e=>e!==null;function sD(e,{repeat:t,repeatType:n="loop"},r,i=1){const o=e.filter(UCt),a=i<0||t&&n!=="loop"&&t%2===1?0:o.length-1;return!a||r===void 0?o[a]:r}const VCt={decay:gV,inertia:gV,tween:YC,keyframes:YC,spring:eT};function UMe(e){typeof e.type=="string"&&(e.type=VCt[e.type])}class cX{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const WCt=e=>e/100;class tT extends cX{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.delayState={done:!1,value:void 0},this.stop=()=>{var r,i;const{motionValue:n}=this.options;n&&n.updatedAt!==Ks.now()&&this.tick(Ks.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(i=(r=this.options).onStop)==null||i.call(r))},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;UMe(t);const{type:n=YC,repeat:r=0,repeatDelay:i=0,repeatType:o,velocity:s=0}=t;let{keyframes:a}=t;const l=n||YC;l!==YC&&typeof a[0]!="number"&&(this.mixKeyframes=yA(WCt,jMe(a[0],a[1])),a=[0,100]);const u=l({...t,keyframes:a});o==="mirror"&&(this.mirroredGenerator=l({...t,keyframes:[...a].reverse(),velocity:-s})),u.calculatedDuration===null&&(u.calculatedDuration=uX(u));const{calculatedDuration:c}=u;this.calculatedDuration=c,this.resolvedDuration=c+i,this.totalDuration=this.resolvedDuration*(r+1)-i,this.generator=u}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:r,totalDuration:i,mixKeyframes:o,mirroredGenerator:s,resolvedDuration:a,calculatedDuration:l}=this;if(this.startTime===null)return r.next(0);const{delay:u=0,keyframes:c,repeat:d,repeatType:h,repeatDelay:m,type:g,onUpdate:b,finalKeyframe:v}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-i/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const w=this.currentTime-u*(this.playbackSpeed>=0?1:-1),S=this.playbackSpeed>=0?w<0:w>i;this.currentTime=Math.max(w,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=i);let C=this.currentTime,E=r;if(d){const N=Math.min(this.currentTime,i)/a;let I=Math.floor(N),D=N%1;!D&&N>=1&&(D=1),D===1&&I--,I=Math.min(I,d+1),!!(I%2)&&(h==="reverse"?(D=1-D,m&&(D-=m/a)):h==="mirror"&&(E=s)),C=Ld(0,1,D)*a}let T;S?(this.delayState.value=c[0],T=this.delayState):T=E.next(C),o&&!S&&(T.value=o(T.value));let{done:O}=T;!S&&l!==null&&(O=this.playbackSpeed>=0?this.currentTime>=i:this.currentTime<=0);const M=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&O);return M&&g!==gV&&(T.value=sD(c,this.options,v,this.speed)),b&&b(T.value),M&&this.finish(),T}then(t,n){return this.finished.then(t,n)}get duration(){return eu(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+eu(t)}get time(){return eu(this.currentTime)}set time(t){t=Sa(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?this.driver.start(!1):(this.startTime=0,this.state="paused",this.holdTime=t,this.tick(t))}getGeneratorVelocity(){const t=this.currentTime;if(t<=0)return this.options.velocity||0;if(this.generator.velocity)return this.generator.velocity(t);const n=this.generator.next(t).value;return zMe(r=>this.generator.next(r).value,t,n)}get speed(){return this.playbackSpeed}set speed(t){const n=this.playbackSpeed!==t;n&&this.driver&&this.updateTime(Ks.now()),this.playbackSpeed=t,n&&this.driver&&(this.time=eu(this.currentTime))}play(){var i,o;if(this.isStopped)return;const{driver:t=NCt,startTime:n}=this.options;this.driver||(this.driver=t(s=>this.tick(s))),(o=(i=this.options).onPlay)==null||o.call(i);const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=n??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(Ks.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var t,n;this.notifyFinished(),this.teardown(),this.state="finished",(n=(t=this.options).onComplete)==null||n.call(t)}cancel(){var t,n;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(n=(t=this.options).onCancel)==null||n.call(t)}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){var n;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(n=this.driver)==null||n.stop(),t.observe(this)}}function qCt(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const sy=e=>e*180/Math.PI,yV=e=>{const t=sy(Math.atan2(e[1],e[0]));return bV(t)},GCt={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:yV,rotateZ:yV,skewX:e=>sy(Math.atan(e[1])),skewY:e=>sy(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},bV=e=>(e=e%360,e<0&&(e+=360),e),zue=yV,Fue=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),Bue=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),KCt={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:Fue,scaleY:Bue,scale:e=>(Fue(e)+Bue(e))/2,rotateX:e=>bV(sy(Math.atan2(e[6],e[5]))),rotateY:e=>bV(sy(Math.atan2(-e[2],e[0]))),rotateZ:zue,rotate:zue,skewX:e=>sy(Math.atan(e[4])),skewY:e=>sy(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function vV(e){return e.includes("scale")?1:0}function xV(e,t){if(!e||e==="none")return vV(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,i;if(n)r=KCt,i=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=GCt,i=a}if(!i)return vV(t);const o=r[t],s=i[1].split(",").map(XCt);return typeof o=="function"?o(s):s[o]}const YCt=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return xV(n,t)};function XCt(e){return parseFloat(e.trim())}const aS=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],lS=new Set([...aS,"pathRotation"]),Hue=e=>e===sS||e===Dt,QCt=new Set(["x","y","z"]),ZCt=aS.filter(e=>!QCt.has(e));function JCt(e){const t=[];return ZCt.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const Ym={width:({x:e},{paddingLeft:t="0",paddingRight:n="0",boxSizing:r})=>{const i=e.max-e.min;return r==="border-box"?i:i-parseFloat(t)-parseFloat(n)},height:({y:e},{paddingTop:t="0",paddingBottom:n="0",boxSizing:r})=>{const i=e.max-e.min;return r==="border-box"?i:i-parseFloat(t)-parseFloat(n)},top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>xV(t,"x"),y:(e,{transform:t})=>xV(t,"y")};Ym.translateX=Ym.x;Ym.translateY=Ym.y;const Jy=new Set;let wV=!1,SV=!1,kV=!1;function VMe(){if(SV){const e=Array.from(Jy).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const i=JCt(r);i.length&&(n.set(r,i),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const i=n.get(r);i&&i.forEach(([o,s])=>{var a;(a=r.getValue(o))==null||a.set(s)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}SV=!1,wV=!1,Jy.forEach(e=>e.complete(kV)),Jy.clear()}function WMe(){Jy.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(SV=!0)})}function eEt(){kV=!0,WMe(),VMe(),kV=!1}class dX{constructor(t,n,r,i,o,s=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=i,this.element=o,this.isAsync=s}scheduleResolve(){this.state="scheduled",this.isAsync?(Jy.add(this),wV||(wV=!0,Rr.read(WMe),Rr.resolveKeyframes(VMe))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:i}=this;if(t[0]===null){const o=i==null?void 0:i.get(),s=t[t.length-1];if(o!==void 0)t[0]=o;else if(r&&n){const a=r.readValue(n,s);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=s),i&&o===void 0&&i.set(t[0])}qCt(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),Jy.delete(this)}cancel(){this.state==="scheduled"&&(Jy.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const tEt=e=>e.startsWith("--");function qMe(e,t,n){tEt(t)?e.style.setProperty(t,n):e.style[t]=n}const nEt={};function GMe(e,t){const n=mMe(e);return()=>nEt[t]??n()}const rEt=GMe(()=>window.ScrollTimeline!==void 0,"scrollTimeline"),KMe=GMe(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),fC=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,Uue={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:fC([0,.65,.55,1]),circOut:fC([.55,0,1,.45]),backIn:fC([.31,.01,.66,-.59]),backOut:fC([.33,1.53,.69,.99])};function YMe(e,t){if(e)return typeof e=="function"?KMe()?DMe(e,t):"ease-out":AMe(e)?fC(e):Array.isArray(e)?e.map(n=>YMe(n,t)||Uue.easeOut):Uue[e]}function iEt(e,t,n,{delay:r=0,duration:i=300,repeat:o=0,repeatType:s="loop",ease:a="easeOut",times:l}={},u=void 0){const c={[t]:n};l&&(c.offset=l);const d=YMe(a,i);Array.isArray(d)&&(c.easing=d);const h={delay:r,duration:i,easing:Array.isArray(d)?"linear":d,fill:"both",iterations:o+1,direction:s==="reverse"?"alternate":"normal"};return u&&(h.pseudoElement=u),e.animate(c,h)}function fX(e){return typeof e=="function"&&"applyToOptions"in e}function oEt({type:e,...t}){return fX(e)&&KMe()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class XMe extends cX{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;const{element:n,name:r,keyframes:i,pseudoElement:o,allowFlatten:s=!1,finalKeyframe:a,onComplete:l}=t;this.isPseudoElement=!!o,this.allowFlatten=s,this.options=t,oD(typeof t.type!="string");const u=oEt(t);this.animation=iEt(n,r,i,u,o),u.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!o){const c=sD(i,this.options,a,this.speed);this.updateMotionValue&&this.updateMotionValue(c),qMe(n,r,c),this.animation.cancel()}l==null||l(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var t,n;(n=(t=this.animation).finish)==null||n.call(t)}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){var n,r,i;const t=(n=this.options)==null?void 0:n.element;!this.isPseudoElement&&(t!=null&&t.isConnected)&&((i=(r=this.animation).commitStyles)==null||i.call(r))}get duration(){var n,r;const t=((r=(n=this.animation.effect)==null?void 0:n.getComputedTiming)==null?void 0:r.call(n).duration)||0;return eu(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+eu(t)}get time(){return eu(Number(this.animation.currentTime)||0)}set time(t){const n=this.finishedTime!==null;this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=Sa(t),n&&this.animation.pause()}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t}attachTimeline({timeline:t,rangeStart:n,rangeEnd:r,observe:i}){var o;return this.allowFlatten&&((o=this.animation.effect)==null||o.updateTiming({easing:"linear"})),this.animation.onfinish=null,t&&rEt()?(this.animation.timeline=t,n&&(this.animation.rangeStart=n),r&&(this.animation.rangeEnd=r),su):i(this)}}const QMe={anticipate:wMe,backInOut:xMe,circInOut:kMe};function sEt(e){return e in QMe}function aEt(e){typeof e.ease=="string"&&sEt(e.ease)&&(e.ease=QMe[e.ease])}const U8=10;class lEt extends XMe{constructor(t){aEt(t),UMe(t),super(t),t.startTime!==void 0&&t.autoplay!==!1&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:i,element:o,...s}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const a=new tT({...s,autoplay:!1}),l=Math.max(U8,Ks.now()-this.startTime),u=Ld(0,U8,l-U8),c=a.sample(l).value,{name:d}=this.options;o&&d&&qMe(o,d,c),n.setWithVelocity(a.sample(Math.max(0,l-u)).value,c,u),a.stop()}}const Vue=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(nc.test(e)||e==="0")&&!e.startsWith("url("));function uEt(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function cEt(e,t,n,r){const i=e[0];if(i===null)return!1;if(t==="display"||t==="visibility")return!0;const o=e[e.length-1],s=Vue(i,t),a=Vue(o,t);return!s||!a?!1:uEt(e)||(n==="spring"||fX(n))&&r}function CV(e){e.duration=0,e.type="keyframes"}const ZMe=new Set(["opacity","clipPath","filter","transform","backgroundColor"]),dEt=/^(?:oklch|oklab|lab|lch|color|color-mix|light-dark)\(/;function fEt(e){for(let t=0;t<e.length;t++)if(typeof e[t]=="string"&&dEt.test(e[t]))return!0;return!1}const hEt=new Set(["color","backgroundColor","outlineColor","fill","stroke","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"]),pEt=mMe(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function mEt(e){var d;const{motionValue:t,name:n,repeatDelay:r,repeatType:i,damping:o,type:s,keyframes:a}=e,l=(d=t==null?void 0:t.owner)==null?void 0:d.current;if(!(l instanceof HTMLElement)&&!(l instanceof SVGElement))return!1;const{onUpdate:u,transformTemplate:c}=t.owner.getProps();return pEt()&&n&&(ZMe.has(n)||hEt.has(n)&&fEt(a))&&(n!=="transform"||!c)&&!u&&!r&&i!=="mirror"&&o!==0&&s!=="inertia"}const gEt=40;class yEt extends cX{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:i=0,repeatDelay:o=0,repeatType:s="loop",keyframes:a,name:l,motionValue:u,element:c,...d}){var g;super(),this.stop=()=>{var b,v;this._animation&&(this._animation.stop(),(b=this.stopTimeline)==null||b.call(this)),(v=this.keyframeResolver)==null||v.cancel()},this.createdAt=Ks.now();const h={autoplay:t,delay:n,type:r,repeat:i,repeatDelay:o,repeatType:s,name:l,motionValue:u,element:c,...d},m=(c==null?void 0:c.KeyframeResolver)||dX;this.keyframeResolver=new m(a,(b,v,w)=>this.onKeyframesResolved(b,v,h,!w),l,u,c),(g=this.keyframeResolver)==null||g.scheduleResolve()}onKeyframesResolved(t,n,r,i){var w,S;this.keyframeResolver=void 0;const{name:o,type:s,velocity:a,delay:l,isHandoff:u,onUpdate:c}=r;this.resolvedAt=Ks.now();let d=!0;cEt(t,o,s,a)||(d=!1,(Eg.instantAnimations||!l)&&(c==null||c(sD(t,r,n))),t[0]=t[t.length-1],CV(r),r.repeat=0);const m={startTime:i?this.resolvedAt?this.resolvedAt-this.createdAt>gEt?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},g=d&&!u&&mEt(m),b=(S=(w=m.motionValue)==null?void 0:w.owner)==null?void 0:S.current;let v;if(g)try{v=new lEt({...m,element:b})}catch{v=new tT(m)}else v=new tT(m);v.finished.then(()=>{this.notifyFinished()}).catch(su),this.pendingTimeline&&(this.stopTimeline=v.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=v}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){var t;return this._animation||((t=this.keyframeResolver)==null||t.resume(),eEt()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){var t;this._animation&&this.animation.cancel(),(t=this.keyframeResolver)==null||t.cancel()}}class bEt{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}get finished(){return Promise.all(this.animations.map(t=>t.finished))}getAll(t){return this.animations[0][t]}setAll(t,n){for(let r=0;r<this.animations.length;r++)this.animations[r][t]=n}attachTimeline(t){const n=this.animations.map(r=>r.attachTimeline(t));return()=>{n.forEach((r,i)=>{r&&r(),this.animations[i].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get state(){return this.getAll("state")}get startTime(){return this.getAll("startTime")}get duration(){return Wue(this.animations,"duration")}get iterationDuration(){return Wue(this.animations,"iterationDuration")}runAll(t){this.animations.forEach(n=>n[t]())}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}function Wue(e,t){let n=0;for(let r=0;r<e.length;r++){const i=e[r][t];i!==null&&i>n&&(n=i)}return n}class vEt extends bEt{then(t,n){return this.finished.finally(t).then(()=>{})}}function JMe(e,t,n,r=0,i=1){const o=Array.from(e).sort((u,c)=>u.sortNodePosition(c)).indexOf(t),s=e.size,a=(s-1)*r;return typeof n=="function"?n(o,s):i===1?o*r:a-o*r}const que=30,xEt=e=>!isNaN(parseFloat(e)),XC={current:void 0};class wEt{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var o;const i=Ks.now();if(this.updatedAt!==i&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&((o=this.events.change)==null||o.notify(this.current),this.dependents))for(const s of this.dependents)s.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=Ks.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=xEt(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new tX);const r=this.events[t].add(n);return t==="change"?()=>{r(),Rr.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){var t;(t=this.events.change)==null||t.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return XC.current&&XC.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){const t=Ks.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>que)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,que);return gMe(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){var t,n;(t=this.dependents)==null||t.clear(),(n=this.events.destroy)==null||n.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Tg(e,t){return new wEt(e,t)}function e_e(e,t){if(e!=null&&e.inherit&&t){const{inherit:n,...r}=e;return{...t,...r}}return e}function hX(e,t){const n=(e==null?void 0:e[t])??(e==null?void 0:e.default)??e;return n!==e?e_e(n,e):n}const SEt={type:"spring",stiffness:500,damping:25,restSpeed:10},kEt=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),CEt={type:"keyframes",duration:.8},EEt={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},TEt=(e,{keyframes:t})=>t.length>2?CEt:lS.has(e)?e.startsWith("scale")?kEt(t[1]):SEt:EEt,AEt=new Set(["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from","elapsed"]);function OEt(e){for(const t in e)if(!AEt.has(t))return!0;return!1}const pX=(e,t,n,r={},i,o)=>s=>{const a=hX(r,e)||{},l=a.delay||r.delay||0;let{elapsed:u=0}=r;u=u-Sa(l);const c={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-u,onUpdate:h=>{t.set(h),a.onUpdate&&a.onUpdate(h)},onComplete:()=>{s(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:o?void 0:i};OEt(a)||Object.assign(c,TEt(e,c)),c.duration&&(c.duration=Sa(c.duration)),c.repeatDelay&&(c.repeatDelay=Sa(c.repeatDelay)),c.from!==void 0&&(c.keyframes[0]=c.from);let d=!1;if((c.type===!1||c.duration===0&&!c.repeatDelay)&&(CV(c),c.delay===0&&(d=!0)),(Eg.instantAnimations||Eg.skipAnimations||i!=null&&i.shouldSkipAnimations||a.skipAnimations)&&(d=!0,CV(c),c.delay=0),c.allowFlatten=!a.type&&!a.ease,d&&!o&&t.get()!==void 0){const h=sD(c.keyframes,a);if(h!==void 0){Rr.update(()=>{c.onUpdate(h),c.onComplete()});return}}return a.isSync?new tT(c):new yEt(c)},REt=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function MEt(e){const t=REt.exec(e);if(!t)return[,];const[,n,r,i]=t;return[`--${n??r}`,i]}function t_e(e,t,n=1){const[r,i]=MEt(e);if(!r)return;const o=window.getComputedStyle(t).getPropertyValue(r);if(o){const s=o.trim();return fMe(s)?parseFloat(s):s}return oX(i)?t_e(i,t,n+1):i}function Gue(e){const t=[{},{}];return e==null||e.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function mX(e,t,n,r){if(typeof t=="function"){const[i,o]=Gue(r);t=t(n!==void 0?n:e.custom,i,o)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[i,o]=Gue(r);t=t(n!==void 0?n:e.custom,i,o)}return t}function eb(e,t,n){const r=e.getProps();return mX(r,t,n!==void 0?n:r.custom,e)}const n_e=new Set(["width","height","top","left","right","bottom",...aS]),EV=e=>Array.isArray(e);function _Et(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Tg(n))}function NEt(e){return EV(e)?e[e.length-1]||0:e}function LEt(e,t){const n=eb(e,t);let{transitionEnd:r={},transition:i={},...o}=n||{};o={...o,...r};for(const s in o){const a=NEt(o[s]);_Et(e,s,a)}}const Pi=e=>!!(e&&e.getVelocity);function IEt(e){return!!(Pi(e)&&e.add)}function TV(e,t){const n=e.getValue("willChange");if(IEt(n))return n.add(t);if(!n&&Eg.WillChange){const r=new Eg.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function gX(e){return e.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const PEt="framerAppearId",r_e="data-"+gX(PEt);function i_e(e){return e.props[r_e]}function jEt({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function yX(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:o,transitionEnd:s,...a}=t;const l=e.getDefaultTransition();o=o?e_e(o,l):l;const u=o==null?void 0:o.reduceMotion,c=o==null?void 0:o.skipAnimations;r&&(o=r);const d=[],h=i&&e.animationState&&e.animationState.getState()[i],m=o==null?void 0:o.path;m&&m.animateVisualElement(e,a,o,n,d);for(const g in a){const b=e.getValue(g,e.latestValues[g]??null),v=a[g];if(v===void 0||h&&jEt(h,g))continue;const w={delay:n,...hX(o||{},g)};c&&(w.skipAnimations=!0);const S=b.get();if(S!==void 0&&!b.isAnimating()&&!Array.isArray(v)&&v===S&&!w.velocity){Rr.update(()=>b.set(v));continue}let C=!1;if(window.MotionHandoffAnimation){const O=i_e(e);if(O){const M=window.MotionHandoffAnimation(O,g,Rr);M!==null&&(w.startTime=M,C=!0)}}TV(e,g);const E=u??e.shouldReduceMotion;b.start(pX(g,b,v,E&&n_e.has(g)?{type:!1}:w,e,C));const T=b.animation;T&&d.push(T)}if(s){const g=()=>Rr.update(()=>{s&&LEt(e,s)});d.length?Promise.all(d).then(g):g()}return d}function AV(e,t,n={}){var l;const r=eb(e,t,n.type==="exit"?(l=e.presenceContext)==null?void 0:l.custom:void 0);let{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);const o=r?()=>Promise.all(yX(e,r,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:c=0,staggerChildren:d,staggerDirection:h}=i;return DEt(e,t,u,c,d,h,n)}:()=>Promise.resolve(),{when:a}=i;if(a){const[u,c]=a==="beforeChildren"?[o,s]:[s,o];return u().then(()=>c())}else return Promise.all([o(),s(n.delay)])}function DEt(e,t,n=0,r=0,i=0,o=1,s){const a=[];for(const l of e.variantChildren)l.notify("AnimationStart",t),a.push(AV(l,t,{...s,delay:n+(typeof r=="function"?0:r)+JMe(e.variantChildren,l,r,i,o)}).then(()=>l.notify("AnimationComplete",t)));return Promise.all(a)}function $Et(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const i=t.map(o=>AV(e,o,n));r=Promise.all(i)}else if(typeof t=="string")r=AV(e,t,n);else{const i=typeof t=="function"?eb(e,t,n.custom):t;r=Promise.all(yX(e,i,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}const zEt={test:e=>e==="auto",parse:e=>e},o_e=e=>t=>t.test(e),s_e=[sS,Dt,Cd,Tf,hCt,fCt,zEt],Kue=e=>s_e.find(o_e(e));function FEt(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||pMe(e):!0}const BEt=new Set(["brightness","contrast","saturate","opacity"]);function HEt(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(sX)||[];if(!r)return e;const i=n.replace(r,"");let o=BEt.has(t)?1:0;return r!==n&&(o*=100),t+"("+o+i+")"}const UEt=/\b([a-z-]*)\(.*?\)/gu,OV={...nc,getAnimatableNone:e=>{const t=e.match(UEt);return t?t.map(HEt).join(" "):e}},RV={...nc,getAnimatableNone:e=>{const t=nc.parse(e);return nc.createTransformer(e)(t.map(r=>typeof r=="number"?0:typeof r=="object"?{...r,alpha:1}:r))}},Yue={...sS,transform:Math.round},VEt={rotate:Tf,pathRotation:Tf,rotateX:Tf,rotateY:Tf,rotateZ:Tf,scale:aM,scaleX:aM,scaleY:aM,scaleZ:aM,skew:Tf,skewX:Tf,skewY:Tf,distance:Dt,translateX:Dt,translateY:Dt,translateZ:Dt,x:Dt,y:Dt,z:Dt,perspective:Dt,transformPerspective:Dt,opacity:JE,originX:Iue,originY:Iue,originZ:Dt},iI={borderWidth:Dt,borderTopWidth:Dt,borderRightWidth:Dt,borderBottomWidth:Dt,borderLeftWidth:Dt,borderRadius:Dt,borderTopLeftRadius:Dt,borderTopRightRadius:Dt,borderBottomRightRadius:Dt,borderBottomLeftRadius:Dt,width:Dt,maxWidth:Dt,height:Dt,maxHeight:Dt,top:Dt,right:Dt,bottom:Dt,left:Dt,inset:Dt,insetBlock:Dt,insetBlockStart:Dt,insetBlockEnd:Dt,insetInline:Dt,insetInlineStart:Dt,insetInlineEnd:Dt,padding:Dt,paddingTop:Dt,paddingRight:Dt,paddingBottom:Dt,paddingLeft:Dt,paddingBlock:Dt,paddingBlockStart:Dt,paddingBlockEnd:Dt,paddingInline:Dt,paddingInlineStart:Dt,paddingInlineEnd:Dt,margin:Dt,marginTop:Dt,marginRight:Dt,marginBottom:Dt,marginLeft:Dt,marginBlock:Dt,marginBlockStart:Dt,marginBlockEnd:Dt,marginInline:Dt,marginInlineStart:Dt,marginInlineEnd:Dt,fontSize:Dt,backgroundPositionX:Dt,backgroundPositionY:Dt,...VEt,zIndex:Yue,fillOpacity:JE,strokeOpacity:JE,numOctaves:Yue},WEt={...iI,color:Yi,backgroundColor:Yi,outlineColor:Yi,fill:Yi,stroke:Yi,borderColor:Yi,borderTopColor:Yi,borderRightColor:Yi,borderBottomColor:Yi,borderLeftColor:Yi,filter:OV,WebkitFilter:OV,mask:RV,WebkitMask:RV},a_e=e=>WEt[e],qEt=new Set([OV,RV]);function l_e(e,t){let n=a_e(e);return qEt.has(n)||(n=nc),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const GEt=new Set(["auto","none","0"]);function KEt(e,t,n){let r=0,i;for(;r<e.length&&!i;){const o=e[r];typeof o=="string"&&!GEt.has(o)&&sw(o).values.length&&(i=e[r]),r++}if(i&&n)for(const o of t)e[o]=l_e(n,i)}class YEt extends dX{constructor(t,n,r,i,o){super(t,n,r,i,o,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let c=0;c<t.length;c++){let d=t[c];if(typeof d=="string"&&(d=d.trim(),oX(d))){const h=t_e(d,n.current);h!==void 0&&(t[c]=h),c===t.length-1&&(this.finalKeyframe=d)}}if(this.resolveNoneKeyframes(),!n_e.has(r)||t.length!==2)return;const[i,o]=t,s=Kue(i),a=Kue(o),l=Lue(i),u=Lue(o);if(l!==u&&Ym[r]){this.needsMeasurement=!0;return}if(s!==a)if(Hue(s)&&Hue(a))for(let c=0;c<t.length;c++){const d=t[c];typeof d=="string"&&(t[c]=parseFloat(d))}else Ym[r]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,r=[];for(let i=0;i<t.length;i++)(t[i]===null||FEt(t[i]))&&r.push(i);r.length&&KEt(t,r,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:r}=this;if(!t||!t.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Ym[r](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const i=n[n.length-1];i!==void 0&&t.getValue(r,i).jump(i,!1)}measureEndState(){var a;const{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;const i=t.getValue(n);i&&i.jump(this.measuredOrigin,!1);const o=r.length-1,s=r[o];r[o]=Ym[n](t.measureViewportBox(),window.getComputedStyle(t.current)),s!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=s),(a=this.removedTransforms)!=null&&a.length&&this.removedTransforms.forEach(([l,u])=>{t.getValue(l).set(u)}),this.resolveNoneKeyframes()}}const bX=["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"];function vX(e,t,n){if(e==null)return[];if(e instanceof EventTarget)return[e];if(typeof e=="string"){let r=document;t&&(r=t.current);const i=(n==null?void 0:n[e])??r.querySelectorAll(e);return i?Array.from(i):[]}return Array.from(e).filter(r=>r!=null)}const MV=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function E_(e){return hMe(e)&&"offsetHeight"in e&&!("ownerSVGElement"in e)}const{schedule:xX}=OMe(queueMicrotask,!1),_u={x:!1,y:!1};function u_e(){return _u.x||_u.y}function XEt(e){return e==="x"||e==="y"?_u[e]?null:(_u[e]=!0,()=>{_u[e]=!1}):_u.x||_u.y?null:(_u.x=_u.y=!0,()=>{_u.x=_u.y=!1})}function c_e(e,t){const n=vX(e),r=new AbortController,i={passive:!0,...t,signal:r.signal};return[n,i,()=>r.abort()]}function QEt(e){return!(e.pointerType==="touch"||u_e())}function ZEt(e,t,n={}){const[r,i,o]=c_e(e,n);return r.forEach(s=>{let a=!1,l=!1,u;const c=()=>{s.removeEventListener("pointerleave",g)},d=v=>{u&&(u(v),u=void 0),c()},h=v=>{a=!1,window.removeEventListener("pointerup",h),window.removeEventListener("pointercancel",h),l&&(l=!1,d(v))},m=()=>{a=!0,window.addEventListener("pointerup",h,i),window.addEventListener("pointercancel",h,i)},g=v=>{if(v.pointerType!=="touch"){if(a){l=!0;return}d(v)}},b=v=>{if(!QEt(v))return;l=!1;const w=t(s,v);typeof w=="function"&&(u=w,s.addEventListener("pointerleave",g,i))};s.addEventListener("pointerenter",b,i),s.addEventListener("pointerdown",m,i)}),o}const d_e=(e,t)=>t?e===t?!0:d_e(e,t.parentElement):!1,wX=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,JEt=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function eTt(e){return JEt.has(e.tagName)||e.isContentEditable===!0}const tTt=new Set(["INPUT","SELECT","TEXTAREA"]);function nTt(e){return tTt.has(e.tagName)||e.isContentEditable===!0}const T_=new WeakSet;function Xue(e){return t=>{t.key==="Enter"&&e(t)}}function V8(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const rTt=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=Xue(()=>{if(T_.has(n))return;V8(n,"down");const i=Xue(()=>{V8(n,"up")}),o=()=>V8(n,"cancel");n.addEventListener("keyup",i,t),n.addEventListener("blur",o,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function Que(e){return wX(e)&&!u_e()}const Zue=new WeakSet;function iTt(e,t,n={}){const[r,i,o]=c_e(e,n),s=a=>{const l=a.currentTarget;if(!Que(a)||Zue.has(a))return;T_.add(l),n.stopPropagation&&Zue.add(a);const u=t(l,a),c={...i,capture:!0},d=(g,b)=>{window.removeEventListener("pointerup",h,c),window.removeEventListener("pointercancel",m,c),T_.has(l)&&T_.delete(l),Que(g)&&typeof u=="function"&&u(g,{success:b})},h=g=>{d(g,l===window||l===document||n.useGlobalTarget||d_e(l,g.target))},m=g=>{d(g,!1)};window.addEventListener("pointerup",h,c),window.addEventListener("pointercancel",m,c)};return r.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",s,i),E_(a)&&(a.addEventListener("focus",u=>rTt(u,i)),!eTt(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),o}function aD(e){return hMe(e)&&"ownerSVGElement"in e}const A_=new WeakMap;let Gp;const f_e=(e,t,n)=>(r,i)=>i&&i[0]?i[0][e+"Size"]:aD(r)&&"getBBox"in r?r.getBBox()[t]:r[n],oTt=f_e("inline","width","offsetWidth"),sTt=f_e("block","height","offsetHeight");function aTt({target:e,borderBoxSize:t}){var n;(n=A_.get(e))==null||n.forEach(r=>{r(e,{get width(){return oTt(e,t)},get height(){return sTt(e,t)}})})}function lTt(e){e.forEach(aTt)}function uTt(){typeof ResizeObserver>"u"||(Gp=new ResizeObserver(lTt))}function cTt(e,t){Gp||uTt();const n=vX(e);return n.forEach(r=>{let i=A_.get(r);i||(i=new Set,A_.set(r,i)),i.add(t),Gp==null||Gp.observe(r)}),()=>{n.forEach(r=>{const i=A_.get(r);i==null||i.delete(t),i!=null&&i.size||Gp==null||Gp.unobserve(r)})}}const O_=new Set;let x1;function dTt(){x1=()=>{const e={get width(){return window.innerWidth},get height(){return window.innerHeight}};O_.forEach(t=>t(e))},window.addEventListener("resize",x1)}function fTt(e){return O_.add(e),x1||dTt(),()=>{O_.delete(e),!O_.size&&typeof x1=="function"&&(window.removeEventListener("resize",x1),x1=void 0)}}function Jue(e,t){return typeof e=="function"?fTt(e):cTt(e,t)}function h_e(e){return aD(e)&&e.tagName==="svg"}function hTt(...e){const t=!Array.isArray(e[0]),n=t?0:-1,r=e[0+n],i=e[1+n],o=e[2+n],s=e[3+n],a=FMe(i,o,s);return t?a(r):a}function pTt(e,t,n={}){const r=e.get();let i=null,o=r,s;const a=typeof r=="string"?r.replace(/[\d.-]/g,""):void 0,l=()=>{i&&(i.stop(),i=null),e.animation=void 0},u=()=>{const d=ece(e.get()),h=ece(o);if(d===h){l();return}const m=i?i.getGeneratorVelocity():e.getVelocity();l(),i=new tT({keyframes:[d,h],velocity:m,type:"spring",restDelta:.001,restSpeed:.01,...n,onUpdate:s})},c=()=>{var d;u(),e.animation=i??void 0,(d=e.events.animationStart)==null||d.notify(),i==null||i.then(()=>{var h;e.animation=void 0,(h=e.events.animationComplete)==null||h.notify()})};if(e.attach((d,h)=>{o=d,s=m=>h(W8(m,a)),Rr.postRender(c)},l),Pi(t)){let d=n.skipInitialAnimation===!0;const h=t.on("change",g=>{d?(d=!1,e.jump(W8(g,a),!1)):e.set(W8(g,a))}),m=e.on("destroy",h);return()=>{h(),m()}}return l}function W8(e,t){return t?e+t:e}function ece(e){return typeof e=="number"?e:parseFloat(e)}const mTt=[...s_e,Yi,nc],gTt=e=>mTt.find(o_e(e)),tce=()=>({translate:0,scale:1,origin:0,originPoint:0}),w1=()=>({x:tce(),y:tce()}),nce=()=>({min:0,max:0}),Gi=()=>({x:nce(),y:nce()}),nT=new WeakMap;function lD(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function rT(e){return typeof e=="string"||Array.isArray(e)}const SX=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],kX=["initial",...SX];function uD(e){return lD(e.animate)||kX.some(t=>rT(e[t]))}function p_e(e){return!!(uD(e)||e.variants)}function yTt(e,t,n){for(const r in t){const i=t[r],o=n[r];if(Pi(i))e.addValue(r,i);else if(Pi(o))e.addValue(r,Tg(i,{owner:e}));else if(o!==i)if(e.hasValue(r)){const s=e.getValue(r);s.liveStyle===!0?s.jump(i):s.hasAnimated||s.set(i)}else{const s=e.getStaticValue(r);e.addValue(r,Tg(s!==void 0?s:i,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const oI={current:null},CX={current:!1},bTt=typeof window<"u";function m_e(){if(CX.current=!0,!!bTt)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>oI.current=e.matches;e.addEventListener("change",t),t()}else oI.current=!1}const rce=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let sI={};function g_e(e){sI=e}function vTt(){return sI}class y_e{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:i,skipAnimations:o,blockInitialAnimation:s,visualState:a},l={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.shouldSkipAnimations=!1,this.values=new Map,this.KeyframeResolver=dX,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.hasBeenMounted=!1,this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const m=Ks.now();this.renderScheduledAt<m&&(this.renderScheduledAt=m,Rr.render(this.render,!1,!0))};const{latestValues:u,renderState:c}=a;this.latestValues=u,this.baseTarget={...u},this.initialValues=n.initial?{...u}:{},this.renderState=c,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=i,this.skipAnimationsConfig=o,this.options=l,this.blockInitialAnimation=!!s,this.isControllingVariants=uD(n),this.isVariantNode=p_e(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:d,...h}=this.scrapeMotionValuesFromProps(n,{},this);for(const m in h){const g=h[m];u[m]!==void 0&&Pi(g)&&g.set(u[m])}}mount(t){var n,r;if(this.hasBeenMounted)for(const i in this.initialValues)(n=this.values.get(i))==null||n.jump(this.initialValues[i]),this.latestValues[i]=this.initialValues[i];this.current=t,nT.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((i,o)=>this.bindToMotionValue(o,i)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(CX.current||m_e(),this.shouldReduceMotion=oI.current),this.shouldSkipAnimations=this.skipAnimationsConfig??!1,(r=this.parent)==null||r.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=!0}unmount(){var t;this.projection&&this.projection.unmount(),Uh(this.notifyUpdate),Uh(this.render),this.valueSubscriptions.forEach(n=>n()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(t=this.parent)==null||t.removeChild(this);for(const n in this.events)this.events[n].clear();for(const n in this.features){const r=this.features[n];r&&(r.unmount(),r.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){if(this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)(),n.accelerate&&ZMe.has(t)&&this.current instanceof HTMLElement){const{factory:s,keyframes:a,times:l,ease:u,duration:c}=n.accelerate,d=new XMe({element:this.current,name:t,keyframes:a,times:l,ease:u,duration:Sa(c)}),h=s(d);this.valueSubscriptions.set(t,()=>{h(),d.cancel()});return}const r=lS.has(t);r&&this.onBindTransform&&this.onBindTransform();const i=n.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&Rr.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let o;typeof window<"u"&&window.MotionCheckAppearSync&&(o=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{i(),o&&o()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in sI){const n=sI[t];if(!n)continue;const{isEnabled:r,Feature:i}=n;if(!this.features[t]&&i&&r(this.props)&&(this.features[t]=new i(this)),this.features[t]){const o=this.features[t];o.isMounted?o.update():(o.mount(),o.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Gi()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<rce.length;r++){const i=rce[r];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);const o="on"+i,s=t[o];s&&(this.propEventSubscriptions[i]=this.on(i,s))}this.prevMotionValues=yTt(this,this.scrapeMotionValuesFromProps(t,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Tg(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(fMe(r)||pMe(r))?r=parseFloat(r):!gTt(r)&&nc.test(n)&&(r=l_e(t,n)),this.setBaseTarget(t,Pi(r)?r.get():r)),Pi(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var o;const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const s=mX(this.props,n,(o=this.presenceContext)==null?void 0:o.custom);s&&(r=s[t])}if(n&&r!==void 0)return r;const i=this.getBaseTargetFromProps(this.props,t);return i!==void 0&&!Pi(i)?i:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new tX),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){xX.render(this.render)}}class b_e extends y_e{constructor(){super(...arguments),this.KeyframeResolver=YEt}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){const r=t.style;return r?r[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;Pi(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}class Ug{constructor(t){this.isMounted=!1,this.node=t}update(){}}function v_e({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function xTt({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function wTt(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function q8(e){return e===void 0||e===1}function _V({scale:e,scaleX:t,scaleY:n}){return!q8(e)||!q8(t)||!q8(n)}function z0(e){return _V(e)||x_e(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function x_e(e){return ice(e.x)||ice(e.y)}function ice(e){return e&&e!=="0%"}function aI(e,t,n){const r=e-n,i=t*r;return n+i}function oce(e,t,n,r,i){return i!==void 0&&(e=aI(e,i,r)),aI(e,n,r)+t}function NV(e,t=0,n=1,r,i){e.min=oce(e.min,t,n,r,i),e.max=oce(e.max,t,n,r,i)}function w_e(e,{x:t,y:n}){NV(e.x,t.translate,t.scale,t.originPoint),NV(e.y,n.translate,n.scale,n.originPoint)}const sce=.999999999999,ace=1.0000000000001;function STt(e,t,n,r=!1){var a;const i=n.length;if(!i)return;t.x=t.y=1;let o,s;for(let l=0;l<i;l++){o=n[l],s=o.projectionDelta;const{visualElement:u}=o.options;u&&u.props.style&&u.props.style.display==="contents"||(r&&o.options.layoutScroll&&o.scroll&&o!==o.root&&(od(e.x,-o.scroll.offset.x),od(e.y,-o.scroll.offset.y)),s&&(t.x*=s.x.scale,t.y*=s.y.scale,w_e(e,s)),r&&z0(o.latestValues)&&R_(e,o.latestValues,(a=o.layout)==null?void 0:a.layoutBox))}t.x<ace&&t.x>sce&&(t.x=1),t.y<ace&&t.y>sce&&(t.y=1)}function od(e,t){e.min+=t,e.max+=t}function lce(e,t,n,r,i=.5){const o=jr(e.min,e.max,i);NV(e,t,n,o,r)}function uce(e,t){return typeof e=="string"?parseFloat(e)/100*(t.max-t.min):e}function R_(e,t,n){const r=n??e;lce(e.x,uce(t.x,r.x),t.scaleX,t.scale,t.originX),lce(e.y,uce(t.y,r.y),t.scaleY,t.scale,t.originY)}function S_e(e,t){return v_e(wTt(e.getBoundingClientRect(),t))}function kTt(e,t,n){const r=S_e(e,n),{scroll:i}=t;return i&&(od(r.x,i.offset.x),od(r.y,i.offset.y)),r}const CTt={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},ETt=aS.length;function TTt(e,t,n){let r="",i=!0;for(let s=0;s<ETt;s++){const a=aS[s],l=e[a];if(l===void 0)continue;let u=!0;if(typeof l=="number")u=l===(a.startsWith("scale")?1:0);else{const c=parseFloat(l);u=a.startsWith("scale")?c===1:c===0}if(!u||n){const c=MV(l,iI[a]);if(!u){i=!1;const d=CTt[a]||a;r+=`${d}(${c}) `}n&&(t[a]=c)}}const o=e.pathRotation;return o&&(i=!1,r+=`rotate(${MV(o,iI.pathRotation)}) `),r=r.trim(),n?r=n(t,i?"":r):i&&(r="none"),r}function EX(e,t,n){const{style:r,vars:i,transformOrigin:o}=e;let s=!1,a=!1;for(const l in t){const u=t[l];if(lS.has(l)){s=!0;continue}else if(MMe(l)){i[l]=u;continue}else{const c=MV(u,iI[l]);l.startsWith("origin")?(a=!0,o[l]=c):r[l]=c}}if(t.transform||(s||n?r.transform=TTt(t,e.transform,n):r.transform&&(r.transform="none")),a){const{originX:l="50%",originY:u="50%",originZ:c=0}=o;r.transformOrigin=`${l} ${u} ${c}`}}function k_e(e,{style:t,vars:n},r,i){const o=e.style;let s;for(s in t)o[s]=t[s];i==null||i.applyProjectionStyles(o,r);for(s in n)o.setProperty(s,n[s])}function cce(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const Ek={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(Dt.test(e))e=parseFloat(e);else return e;const n=cce(e,t.target.x),r=cce(e,t.target.y);return`${n}% ${r}%`}},ATt={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,i=nc.parse(e);if(i.length>5)return r;const o=nc.createTransformer(e),s=typeof i[0]!="number"?1:0,a=n.x.scale*t.x,l=n.y.scale*t.y;i[0+s]/=a,i[1+s]/=l;const u=jr(a,l,.5);return typeof i[2+s]=="number"&&(i[2+s]/=u),typeof i[3+s]=="number"&&(i[3+s]/=u),o(i)}},LV={borderRadius:{...Ek,applyTo:[...bX]},borderTopLeftRadius:Ek,borderTopRightRadius:Ek,borderBottomLeftRadius:Ek,borderBottomRightRadius:Ek,boxShadow:ATt};function C_e(e,{layout:t,layoutId:n}){return lS.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!LV[e]||e==="opacity")}function TX(e,t,n){var s;const r=e.style,i=t==null?void 0:t.style,o={};if(!r)return o;for(const a in r)(Pi(r[a])||i&&Pi(i[a])||C_e(a,e)||((s=n==null?void 0:n.getValue(a))==null?void 0:s.liveStyle)!==void 0)&&(o[a]=r[a]);return o}function OTt(e){return window.getComputedStyle(e)}class E_e extends b_e{constructor(){super(...arguments),this.type="html",this.renderInstance=k_e}mount(t){oD(!!t.style),super.mount(t)}readValueFromInstance(t,n){var r;if(lS.has(n))return(r=this.projection)!=null&&r.isProjecting?vV(n):YCt(t,n);{const i=OTt(t),o=(MMe(n)?i.getPropertyValue(n):i[n])||0;return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(t,{transformPagePoint:n}){return S_e(t,n)}build(t,n,r){EX(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return TX(t,n,r)}}function RTt(e,t){return e in t}class MTt extends y_e{constructor(){super(...arguments),this.type="object"}readValueFromInstance(t,n){if(RTt(n,t)){const r=t[n];if(typeof r=="string"||typeof r=="number")return r}}getBaseTargetFromProps(){}removeValueFromRenderState(t,n){delete n.output[t]}measureInstanceViewportBox(){return Gi()}build(t,n){Object.assign(t.output,n)}renderInstance(t,{output:n}){Object.assign(t,n)}sortInstanceNodePosition(){return 0}}const _Tt={offset:"stroke-dashoffset",array:"stroke-dasharray"},NTt={offset:"strokeDashoffset",array:"strokeDasharray"};function LTt(e,t,n=1,r=0,i=!0){e.pathLength=1;const o=i?_Tt:NTt;e[o.offset]=`${-r}`,e[o.array]=`${t} ${n}`}const ITt=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function T_e(e,{attrX:t,attrY:n,attrScale:r,pathLength:i,pathSpacing:o=1,pathOffset:s=0,...a},l,u,c){if(EX(e,a,u),l){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:d,style:h}=e;d.transform&&(h.transform=d.transform,delete d.transform),(h.transform||d.transformOrigin)&&(h.transformOrigin=d.transformOrigin??"50% 50%",delete d.transformOrigin),h.transform&&(h.transformBox=(c==null?void 0:c.transformBox)??"fill-box",delete d.transformBox);for(const m of ITt)d[m]!==void 0&&(h[m]=d[m],delete d[m]);t!==void 0&&(d.x=t),n!==void 0&&(d.y=n),r!==void 0&&(d.scale=r),i!==void 0&&LTt(d,i,o,s,!1)}const A_e=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]),O_e=e=>typeof e=="string"&&e.toLowerCase()==="svg";function PTt(e,t,n,r){k_e(e,t,void 0,r);for(const i in t.attrs)e.setAttribute(A_e.has(i)?i:gX(i),t.attrs[i])}function R_e(e,t,n){const r=TX(e,t,n);for(const i in e)if(Pi(e[i])||Pi(t[i])){const o=aS.indexOf(i)!==-1?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i;r[o]=e[i]}return r}class M_e extends b_e{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Gi}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(lS.has(n)){const r=a_e(n);return r&&r.default||0}return n=A_e.has(n)?n:gX(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return R_e(t,n,r)}build(t,n,r){T_e(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,i){PTt(t,n,r,i)}mount(t){this.isSVGTag=O_e(t.tagName),super.mount(t)}}const jTt=kX.length;function __e(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?__e(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<jTt;n++){const r=kX[n],i=e.props[r];(rT(i)||i===!1)&&(t[r]=i)}return t}function N_e(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}const DTt=[...SX].reverse(),$Tt=SX.length;function zTt(e){return t=>Promise.all(t.map(({animation:n,options:r})=>$Et(e,n,r)))}function FTt(e){let t=zTt(e),n=dce(),r=!0,i=!1;const o=u=>(c,d)=>{var m;const h=eb(e,d,u==="exit"?(m=e.presenceContext)==null?void 0:m.custom:void 0);if(h){const{transition:g,transitionEnd:b,...v}=h;c={...c,...v,...b}}return c};function s(u){t=u(e)}function a(u){const{props:c}=e,d=__e(e.parent)||{},h=[],m=new Set;let g={},b=1/0;for(let w=0;w<$Tt;w++){const S=DTt[w],C=n[S],E=c[S]!==void 0?c[S]:d[S],T=rT(E),O=S===u?C.isActive:null;O===!1&&(b=w);let M=E===d[S]&&E!==c[S]&&T;if(M&&(r||i)&&e.manuallyAnimateOnMount&&(M=!1),C.protectedKeys={...g},!C.isActive&&O===null||!E&&!C.prevProp||lD(E)||typeof E=="boolean")continue;if(S==="exit"&&C.isActive&&O!==!0){C.prevResolvedValues&&(g={...g,...C.prevResolvedValues});continue}const N=BTt(C.prevProp,E);let I=N||S===u&&C.isActive&&!M&&T||w>b&&T,D=!1;const P=Array.isArray(E)?E:[E];let F=P.reduce(o(S),{});O===!1&&(F={});const{prevResolvedValues:z={}}=C,$={...z,...F},B=W=>{I=!0,m.has(W)&&(D=!0,m.delete(W)),C.needsAnimating[W]=!0;const q=e.getValue(W);q&&(q.liveStyle=!1)};for(const W in $){const q=F[W],Y=z[W];if(g.hasOwnProperty(W))continue;let Q=!1;EV(q)&&EV(Y)?Q=!N_e(q,Y)||N:Q=q!==Y,Q?q!=null?B(W):m.add(W):q!==void 0&&m.has(W)?B(W):C.protectedKeys[W]=!0}C.prevProp=E,C.prevResolvedValues=F,C.isActive&&(g={...g,...F}),(r||i)&&e.blockInitialAnimation&&(I=!1);const H=M&&N;I&&(!H||D)&&h.push(...P.map(W=>{const q={type:S};if(typeof W=="string"&&(r||i)&&!H&&e.manuallyAnimateOnMount&&e.parent){const{parent:Y}=e,Q=eb(Y,W);if(Y.enteringChildren&&Q){const{delayChildren:G}=Q.transition||{};q.delay=JMe(Y.enteringChildren,e,G)}}return{animation:W,options:q}}))}if(m.size){const w={};if(typeof c.initial!="boolean"){const S=eb(e,Array.isArray(c.initial)?c.initial[0]:c.initial);S&&S.transition&&(w.transition=S.transition)}m.forEach(S=>{const C=e.getBaseTarget(S),E=e.getValue(S);E&&(E.liveStyle=!0),w[S]=C??null}),h.push({animation:w})}let v=!!h.length;return r&&(c.initial===!1||c.initial===c.animate)&&!e.manuallyAnimateOnMount&&(v=!1),r=!1,i=!1,v?t(h):Promise.resolve()}function l(u,c){var h;if(n[u].isActive===c)return Promise.resolve();(h=e.variantChildren)==null||h.forEach(m=>{var g;return(g=m.animationState)==null?void 0:g.setActive(u,c)}),n[u].isActive=c;const d=a(u);for(const m in n)n[m].protectedKeys={};return d}return{animateChanges:a,setActive:l,setAnimateFunction:s,getState:()=>n,reset:()=>{n=dce(),i=!0}}}function BTt(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!N_e(t,e):!1}function M0(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function dce(){return{animate:M0(!0),whileInView:M0(),whileHover:M0(),whileTap:M0(),whileDrag:M0(),whileFocus:M0(),exit:M0()}}function IV(e,t){e.min=t.min,e.max=t.max}function Tu(e,t){IV(e.x,t.x),IV(e.y,t.y)}function fce(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}const L_e=1e-4,HTt=1-L_e,UTt=1+L_e,I_e=.01,VTt=0-I_e,WTt=0+I_e;function Ys(e){return e.max-e.min}function qTt(e,t,n){return Math.abs(e-t)<=n}function hce(e,t,n,r=.5){e.origin=r,e.originPoint=jr(t.min,t.max,e.origin),e.scale=Ys(n)/Ys(t),e.translate=jr(n.min,n.max,e.origin)-e.originPoint,(e.scale>=HTt&&e.scale<=UTt||isNaN(e.scale))&&(e.scale=1),(e.translate>=VTt&&e.translate<=WTt||isNaN(e.translate))&&(e.translate=0)}function QC(e,t,n,r){hce(e.x,t.x,n.x,r?r.originX:void 0),hce(e.y,t.y,n.y,r?r.originY:void 0)}function pce(e,t,n,r=0){const i=r?jr(n.min,n.max,r):n.min;e.min=i+t.min,e.max=e.min+Ys(t)}function GTt(e,t,n,r){pce(e.x,t.x,n.x,r==null?void 0:r.x),pce(e.y,t.y,n.y,r==null?void 0:r.y)}function mce(e,t,n,r=0){const i=r?jr(n.min,n.max,r):n.min;e.min=t.min-i,e.max=e.min+Ys(t)}function lI(e,t,n,r){mce(e.x,t.x,n.x,r==null?void 0:r.x),mce(e.y,t.y,n.y,r==null?void 0:r.y)}function gce(e,t,n,r,i){return e-=t,e=aI(e,1/n,r),i!==void 0&&(e=aI(e,1/i,r)),e}function KTt(e,t=0,n=1,r=.5,i,o=e,s=e){if(Cd.test(t)&&(t=parseFloat(t),t=jr(s.min,s.max,t/100)-s.min),typeof t!="number")return;let a=jr(o.min,o.max,r);e===o&&(a-=t),e.min=gce(e.min,t,n,a,i),e.max=gce(e.max,t,n,a,i)}function yce(e,t,[n,r,i],o,s){KTt(e,t[n],t[r],t[i],t.scale,o,s)}const YTt=["x","scaleX","originX"],XTt=["y","scaleY","originY"];function bce(e,t,n,r){yce(e.x,t,YTt,n?n.x:void 0,r?r.x:void 0),yce(e.y,t,XTt,n?n.y:void 0,r?r.y:void 0)}function vce(e){return e.translate===0&&e.scale===1}function P_e(e){return vce(e.x)&&vce(e.y)}function xce(e,t){return e.min===t.min&&e.max===t.max}function QTt(e,t){return xce(e.x,t.x)&&xce(e.y,t.y)}function wce(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function j_e(e,t){return wce(e.x,t.x)&&wce(e.y,t.y)}function Sce(e){return Ys(e.x)/Ys(e.y)}function kce(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function Dc(e){return[e("x"),e("y")]}function ZTt(e,t,n){let r="";const i=e.x.translate/t.x,o=e.y.translate/t.y,s=(n==null?void 0:n.z)||0;if((i||o||s)&&(r=`translate3d(${i}px, ${o}px, ${s}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:u,rotate:c,pathRotation:d,rotateX:h,rotateY:m,skewX:g,skewY:b}=n;u&&(r=`perspective(${u}px) ${r}`),c&&(r+=`rotate(${c}deg) `),d&&(r+=`rotate(${d}deg) `),h&&(r+=`rotateX(${h}deg) `),m&&(r+=`rotateY(${m}deg) `),g&&(r+=`skewX(${g}deg) `),b&&(r+=`skewY(${b}deg) `)}const a=e.x.scale*t.x,l=e.y.scale*t.y;return(a!==1||l!==1)&&(r+=`scale(${a}, ${l})`),r||"none"}const JTt=bX.length,Cce=e=>typeof e=="string"?parseFloat(e):e,Ece=e=>typeof e=="number"||Dt.test(e);function e2t(e,t,n,r,i,o){i?(e.opacity=jr(0,n.opacity??1,t2t(r)),e.opacityExit=jr(t.opacity??1,0,n2t(r))):o&&(e.opacity=jr(t.opacity??1,n.opacity??1,r));for(let s=0;s<JTt;s++){const a=bX[s];let l=Tce(t,a),u=Tce(n,a);if(l===void 0&&u===void 0)continue;l||(l=0),u||(u=0),l===0||u===0||Ece(l)===Ece(u)?(e[a]=Math.max(jr(Cce(l),Cce(u),r),0),(Cd.test(u)||Cd.test(l))&&(e[a]+="%")):e[a]=u}(t.rotate||n.rotate)&&(e.rotate=jr(t.rotate||0,n.rotate||0,r))}function Tce(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const t2t=D_e(0,.5,SMe),n2t=D_e(.5,.95,su);function D_e(e,t,n){return r=>r<e?0:r>t?1:n(ow(e,t,r))}function $_e(e,t,n){const r=Pi(e)?e:Tg(e);return r.start(pX("",r,t,n)),r.animation}function iT(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)}const r2t=(e,t)=>e.depth-t.depth;class i2t{constructor(){this.children=[],this.isDirty=!1}add(t){eX(this.children,t),this.isDirty=!0}remove(t){iw(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(r2t),this.isDirty=!1,this.children.forEach(t)}}function o2t(e,t){const n=Ks.now(),r=({timestamp:i})=>{const o=i-n;o>=t&&(Uh(r),e(o-t))};return Rr.setup(r,!0),()=>Uh(r)}function M_(e){return Pi(e)?e.get():e}class s2t{constructor(){this.members=[]}add(t){eX(this.members,t);for(let n=this.members.length-1;n>=0;n--){const r=this.members[n];if(r===t||r===this.lead||r===this.prevLead)continue;const i=r.instance;(!i||i.isConnected===!1)&&!r.snapshot&&(iw(this.members,r),r.unmount())}t.scheduleRender()}remove(t){if(iw(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){var n;for(let r=this.members.indexOf(t)-1;r>=0;r--){const i=this.members[r];if(i.isPresent!==!1&&((n=i.instance)==null?void 0:n.isConnected)!==!1)return this.promote(i),!0}return!1}promote(t,n){var i;const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.updateSnapshot(),t.scheduleRender();const{layoutDependency:o}=r.options,{layoutDependency:s}=t.options;(o===void 0||o!==s)&&(t.resumeFrom=r,n&&(r.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),(i=t.root)!=null&&i.isUpdating&&(t.isLayoutDirty=!0)),t.options.crossfade===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{var n,r,i,o,s;(r=(n=t.options).onExitComplete)==null||r.call(n),(s=(i=t.resumingFrom)==null?void 0:(o=i.options).onExitComplete)==null||s.call(o)})}scheduleRender(){this.members.forEach(t=>t.instance&&t.scheduleRender(!1))}removeLeadSnapshot(){var t;(t=this.lead)!=null&&t.snapshot&&(this.lead.snapshot=void 0)}}const __={hasAnimatedSinceResize:!0,hasEverUpdated:!1},G8=["","X","Y","Z"],a2t=1e3;let l2t=0;function K8(e,t,n,r){const{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}function z_e(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=i_e(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:i,layoutId:o}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",Rr,!(i||o))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&z_e(r)}function F_e({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(s={},a=t==null?void 0:t()){this.id=l2t++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(d2t),this.nodes.forEach(y2t),this.nodes.forEach(b2t),this.nodes.forEach(f2t)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let l=0;l<this.path.length;l++)this.path[l].shouldResetTransform=!0;this.root===this&&(this.nodes=new i2t)}addEventListener(s,a){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new tX),this.eventHandlers.get(s).add(a)}notifyListeners(s,...a){const l=this.eventHandlers.get(s);l&&l.notify(...a)}hasListeners(s){return this.eventHandlers.has(s)}mount(s){if(this.instance)return;this.isSVG=aD(s)&&!h_e(s),this.instance=s;const{layoutId:a,layout:l,visualElement:u}=this.options;if(u&&!u.current&&u.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(l||a)&&(this.isLayoutDirty=!0),e){let c,d=0;const h=()=>this.root.updateBlockedByResize=!1;Rr.read(()=>{d=window.innerWidth}),e(s,()=>{const m=window.innerWidth;m!==d&&(d=m,this.root.updateBlockedByResize=!0,c&&c(),c=o2t(h,250),__.hasAnimatedSinceResize&&(__.hasAnimatedSinceResize=!1,this.nodes.forEach(Rce)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&u&&(a||l)&&this.addEventListener("didUpdate",({delta:c,hasLayoutChanged:d,hasRelativeLayoutChanged:h,layout:m})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const g=this.options.transition||u.getDefaultTransition()||k2t,{onLayoutAnimationStart:b,onLayoutAnimationComplete:v}=u.getProps(),w=!this.targetLayout||!j_e(this.targetLayout,m),S=!d&&h;if(this.options.layoutRoot||this.resumeFrom||S||d&&(w||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const C={...hX(g,"layout"),onPlay:b,onComplete:v};(u.shouldReduceMotion||this.options.layoutRoot)&&(C.delay=0,C.type=!1),this.startAnimation(C),this.setAnimationOrigin(c,S,C.path)}else d||Rce(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=m})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Uh(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(v2t),this.animationId++)}getTransformTemplate(){const{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&z_e(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let c=0;c<this.path.length;c++){const d=this.path[c];d.shouldResetTransform=!0,(typeof d.latestValues.x=="string"||typeof d.latestValues.y=="string")&&(d.isLayoutDirty=!0),d.updateScroll("snapshot"),d.options.layoutRoot&&d.willUpdate(!1)}const{layoutId:a,layout:l}=this.options;if(a===void 0&&!l)return;const u=this.getTransformTemplate();this.prevTransformTemplateValue=u?u(this.latestValues,""):void 0,this.updateSnapshot(),s&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){const l=this.updateBlockedByResize;this.unblockUpdate(),this.updateBlockedByResize=!1,this.clearAllSnapshots(),l&&this.nodes.forEach(p2t),this.nodes.forEach(Ace);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(Oce);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(m2t),this.nodes.forEach(g2t),this.nodes.forEach(u2t),this.nodes.forEach(c2t)):this.nodes.forEach(Oce),this.clearAllSnapshots();const a=Ks.now();es.delta=Ld(0,1e3/60,a-es.timestamp),es.timestamp=a,es.isProcessing=!0,$8.update.process(es),$8.preRender.process(es),$8.render.process(es),es.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,xX.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(h2t),this.sharedNodes.forEach(x2t)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,Rr.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){Rr.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Ys(this.snapshot.measuredBox.x)&&!Ys(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l<this.path.length;l++)this.path[l].updateScroll();const s=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected||(this.layoutCorrected=Gi()),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,s?s.layoutBox:void 0)}updateScroll(s="measure"){let a=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===s&&(a=!1),a&&this.instance){const l=r(this.instance);this.scroll={animationId:this.root.animationId,phase:s,isRoot:l,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:l}}}resetTransform(){if(!i)return;const s=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,a=this.projectionDelta&&!P_e(this.projectionDelta),l=this.getTransformTemplate(),u=l?l(this.latestValues,""):void 0,c=u!==this.prevTransformTemplateValue;s&&this.instance&&(a||z0(this.latestValues)||c)&&(i(this.instance,u),this.shouldResetTransform=!1,this.scheduleRender())}measure(s=!0){const a=this.measurePageBox();let l=this.removeElementScroll(a);return s&&(l=this.removeTransform(l)),C2t(l),{animationId:this.root.animationId,measuredBox:a,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){var u;const{visualElement:s}=this.options;if(!s)return Gi();const a=s.measureViewportBox();if(!(((u=this.scroll)==null?void 0:u.wasRoot)||this.path.some(E2t))){const{scroll:c}=this.root;c&&(od(a.x,c.offset.x),od(a.y,c.offset.y))}return a}removeElementScroll(s){var l;const a=Gi();if(Tu(a,s),(l=this.scroll)!=null&&l.wasRoot)return a;for(let u=0;u<this.path.length;u++){const c=this.path[u],{scroll:d,options:h}=c;c!==this.root&&d&&h.layoutScroll&&(d.wasRoot&&Tu(a,s),od(a.x,d.offset.x),od(a.y,d.offset.y))}return a}applyTransform(s,a=!1,l){var c,d;const u=l||Gi();Tu(u,s);for(let h=0;h<this.path.length;h++){const m=this.path[h];!a&&m.options.layoutScroll&&m.scroll&&m!==m.root&&(od(u.x,-m.scroll.offset.x),od(u.y,-m.scroll.offset.y)),z0(m.latestValues)&&R_(u,m.latestValues,(c=m.layout)==null?void 0:c.layoutBox)}return z0(this.latestValues)&&R_(u,this.latestValues,(d=this.layout)==null?void 0:d.layoutBox),u}removeTransform(s){var l;const a=Gi();Tu(a,s);for(let u=0;u<this.path.length;u++){const c=this.path[u];if(!z0(c.latestValues))continue;let d;c.instance&&(_V(c.latestValues)&&c.updateSnapshot(),d=Gi(),Tu(d,c.measurePageBox())),bce(a,c.latestValues,(l=c.snapshot)==null?void 0:l.layoutBox,d)}return z0(this.latestValues)&&bce(a,this.latestValues),a}setTargetDelta(s){this.targetDelta=s,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(s){this.options={...this.options,...s,crossfade:s.crossfade!==void 0?s.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==es.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){var m;const a=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=a.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=a.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=a.isSharedProjectionDirty);const l=!!this.resumingFrom||this!==a;if(!(s||l&&this.isSharedProjectionDirty||this.isProjectionDirty||(m=this.parent)!=null&&m.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:c,layoutId:d}=this.options;if(!this.layout||!(c||d))return;this.resolvedRelativeTargetAt=es.timestamp;const h=this.getClosestProjectingParent();h&&this.linkedParentVersion!==h.layoutVersion&&!h.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(this.options.layoutAnchor!==!1&&h&&h.layout?this.createRelativeTarget(h,this.layout.layoutBox,h.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=Gi(),this.targetWithTransforms=Gi()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),GTt(this.target,this.relativeTarget,this.relativeParent.target,this.options.layoutAnchor||void 0)):this.targetDelta?(this.resumingFrom?this.applyTransform(this.layout.layoutBox,!1,this.target):Tu(this.target,this.layout.layoutBox),w_e(this.target,this.targetDelta)):Tu(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,this.options.layoutAnchor!==!1&&h&&!!h.resumingFrom==!!this.resumingFrom&&!h.options.layoutScroll&&h.target&&this.animationProgress!==1?this.createRelativeTarget(h,this.target,h.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||_V(this.parent.latestValues)||x_e(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(s,a,l){this.relativeParent=s,this.linkedParentVersion=s.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Gi(),this.relativeTargetOrigin=Gi(),lI(this.relativeTargetOrigin,a,l,this.options.layoutAnchor||void 0),Tu(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){var g;const s=this.getLead(),a=!!this.resumingFrom||this!==s;let l=!0;if((this.isProjectionDirty||(g=this.parent)!=null&&g.isProjectionDirty)&&(l=!1),a&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===es.timestamp&&(l=!1),l)return;const{layout:u,layoutId:c}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(u||c))return;Tu(this.layoutCorrected,this.layout.layoutBox);const d=this.treeScale.x,h=this.treeScale.y;STt(this.layoutCorrected,this.treeScale,this.path,a),s.layout&&!s.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(s.target=s.layout.layoutBox,s.targetWithTransforms=Gi());const{target:m}=s;if(!m){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(fce(this.prevProjectionDelta.x,this.projectionDelta.x),fce(this.prevProjectionDelta.y,this.projectionDelta.y)),QC(this.projectionDelta,this.layoutCorrected,m,this.latestValues),(this.treeScale.x!==d||this.treeScale.y!==h||!kce(this.projectionDelta.x,this.prevProjectionDelta.x)||!kce(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",m))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){var a;if((a=this.options.visualElement)==null||a.scheduleRender(),s){const l=this.getStack();l&&l.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=w1(),this.projectionDelta=w1(),this.projectionDeltaWithTransform=w1()}setAnimationOrigin(s,a=!1,l){const u=this.snapshot,c=u?u.latestValues:{},d={...this.latestValues},h=w1();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const m=Gi(),g=u?u.source:void 0,b=this.layout?this.layout.source:void 0,v=g!==b,w=this.getStack(),S=!w||w.members.length<=1,C=!!(v&&!S&&this.options.crossfade===!0&&!this.path.some(S2t));this.animationProgress=0;let E;const T=l==null?void 0:l.interpolateProjection(s);this.mixTargetDelta=O=>{const M=O/1e3,N=T==null?void 0:T(M);N?(h.x.translate=N.x,h.x.scale=jr(s.x.scale,1,M),h.x.origin=s.x.origin,h.x.originPoint=s.x.originPoint,h.y.translate=N.y,h.y.scale=jr(s.y.scale,1,M),h.y.origin=s.y.origin,h.y.originPoint=s.y.originPoint):(Mce(h.x,s.x,M),Mce(h.y,s.y,M)),this.setTargetDelta(h),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(lI(m,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0),w2t(this.relativeTarget,this.relativeTargetOrigin,m,M),E&&QTt(this.relativeTarget,E)&&(this.isProjectionDirty=!1),E||(E=Gi()),Tu(E,this.relativeTarget)),v&&(this.animationValues=d,e2t(d,c,this.latestValues,M,C,S)),N&&N.rotate!==void 0&&(this.animationValues||(this.animationValues=d),this.animationValues.pathRotation=N.rotate),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=M},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){var a,l,u;this.notifyListeners("animationStart"),(a=this.currentAnimation)==null||a.stop(),(u=(l=this.resumingFrom)==null?void 0:l.currentAnimation)==null||u.stop(),this.pendingAnimation&&(Uh(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=Rr.update(()=>{__.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=Tg(0)),this.motionValue.jump(0,!1),this.currentAnimation=$_e(this.motionValue,[0,1e3],{...s,velocity:0,isSync:!0,onUpdate:c=>{this.mixTargetDelta(c),s.onUpdate&&s.onUpdate(c)},onComplete:()=>{s.onComplete&&s.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(a2t),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const s=this.getLead();let{targetWithTransforms:a,target:l,layout:u,latestValues:c}=s;if(!(!a||!l||!u)){if(this!==s&&this.layout&&u&&B_e(this.options.animationType,this.layout.layoutBox,u.layoutBox)){l=this.target||Gi();const d=Ys(this.layout.layoutBox.x);l.x.min=s.target.x.min,l.x.max=l.x.min+d;const h=Ys(this.layout.layoutBox.y);l.y.min=s.target.y.min,l.y.max=l.y.min+h}Tu(a,l),R_(a,c),QC(this.projectionDeltaWithTransform,this.layoutCorrected,a,c)}}registerSharedNode(s,a){this.sharedNodes.has(s)||this.sharedNodes.set(s,new s2t),this.sharedNodes.get(s).add(a);const u=a.options.initialPromotionConfig;a.promote({transition:u?u.transition:void 0,preserveFollowOpacity:u&&u.shouldPreserveFollowOpacity?u.shouldPreserveFollowOpacity(a):void 0})}isLead(){const s=this.getStack();return s?s.lead===this:!0}getLead(){var a;const{layoutId:s}=this.options;return s?((a=this.getStack())==null?void 0:a.lead)||this:this}getPrevLead(){var a;const{layoutId:s}=this.options;return s?(a=this.getStack())==null?void 0:a.prevLead:void 0}getStack(){const{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:a,preserveFollowOpacity:l}={}){const u=this.getStack();u&&u.promote(this,l),s&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const s=this.getStack();return s?s.relegate(this):!1}resetSkewAndRotation(){const{visualElement:s}=this.options;if(!s)return;let a=!1;const{latestValues:l}=s;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(a=!0),!a)return;const u={};l.z&&K8("z",s,u,this.animationValues);for(let c=0;c<G8.length;c++)K8(`rotate${G8[c]}`,s,u,this.animationValues),K8(`skew${G8[c]}`,s,u,this.animationValues);s.render();for(const c in u)s.setStaticValue(c,u[c]),this.animationValues&&(this.animationValues[c]=u[c]);s.scheduleRender()}applyProjectionStyles(s,a){if(!this.instance||this.isSVG)return;if(!this.isVisible){s.visibility="hidden";return}const l=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,s.visibility="",s.opacity="",s.pointerEvents=M_(a==null?void 0:a.pointerEvents)||"",s.transform=l?l(this.latestValues,""):"none";return}const u=this.getLead();if(!this.projectionDelta||!this.layout||!u.target){this.options.layoutId&&(s.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,s.pointerEvents=M_(a==null?void 0:a.pointerEvents)||""),this.hasProjected&&!z0(this.latestValues)&&(s.transform=l?l({},""):"none",this.hasProjected=!1);return}s.visibility="";const c=u.animationValues||u.latestValues;this.applyTransformsToTarget();let d=ZTt(this.projectionDeltaWithTransform,this.treeScale,c);l&&(d=l(c,d)),s.transform=d;const{x:h,y:m}=this.projectionDelta;s.transformOrigin=`${h.origin*100}% ${m.origin*100}% 0`,u.animationValues?s.opacity=u===this?c.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:c.opacityExit:s.opacity=u===this?c.opacity!==void 0?c.opacity:"":c.opacityExit!==void 0?c.opacityExit:0;for(const g in LV){if(c[g]===void 0)continue;const{correct:b,applyTo:v,isCSSVariable:w}=LV[g],S=d==="none"?c[g]:b(c[g],u);if(v){const C=v.length;for(let E=0;E<C;E++)s[v[E]]=S}else w?this.options.visualElement.renderState.vars[g]=S:s[g]=S}this.options.layoutId&&(s.pointerEvents=u===this?M_(a==null?void 0:a.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>{var a;return(a=s.currentAnimation)==null?void 0:a.stop()}),this.root.nodes.forEach(Ace),this.root.sharedNodes.clear()}}}function u2t(e){e.updateLayout()}function c2t(e){var n;const t=((n=e.resumeFrom)==null?void 0:n.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:i}=e.layout,{animationType:o}=e.options,s=t.source!==e.layout.source;if(o==="size")Dc(d=>{const h=s?t.measuredBox[d]:t.layoutBox[d],m=Ys(h);h.min=r[d].min,h.max=h.min+m});else if(o==="x"||o==="y"){const d=o==="x"?"y":"x";IV(s?t.measuredBox[d]:t.layoutBox[d],r[d])}else B_e(o,t.layoutBox,r)&&Dc(d=>{const h=s?t.measuredBox[d]:t.layoutBox[d],m=Ys(r[d]);h.max=h.min+m,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+m)});const a=w1();QC(a,r,t.layoutBox);const l=w1();s?QC(l,e.applyTransform(i,!0),t.measuredBox):QC(l,r,t.layoutBox);const u=!P_e(a);let c=!1;if(!e.resumeFrom){const d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){const{snapshot:h,layout:m}=d;if(h&&m){const g=e.options.layoutAnchor||void 0,b=Gi();lI(b,t.layoutBox,h.layoutBox,g);const v=Gi();lI(v,r,m.layoutBox,g),j_e(b,v)||(c=!0),d.options.layoutRoot&&(e.relativeTarget=v,e.relativeTargetOrigin=b,e.relativeParent=d)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:t,delta:l,layoutDelta:a,hasLayoutChanged:u,hasRelativeLayoutChanged:c})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function d2t(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function f2t(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function h2t(e){e.clearSnapshot()}function Ace(e){e.clearMeasurements()}function p2t(e){e.isLayoutDirty=!0,e.updateLayout()}function Oce(e){e.isLayoutDirty=!1}function m2t(e){e.isAnimationBlocked&&e.layout&&!e.isLayoutDirty&&(e.snapshot=e.layout,e.isLayoutDirty=!0)}function g2t(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function Rce(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function y2t(e){e.resolveTargetDelta()}function b2t(e){e.calcProjection()}function v2t(e){e.resetSkewAndRotation()}function x2t(e){e.removeLeadSnapshot()}function Mce(e,t,n){e.translate=jr(t.translate,0,n),e.scale=jr(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function _ce(e,t,n,r){e.min=jr(t.min,n.min,r),e.max=jr(t.max,n.max,r)}function w2t(e,t,n,r){_ce(e.x,t.x,n.x,r),_ce(e.y,t.y,n.y,r)}function S2t(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const k2t={duration:.45,ease:[.4,0,.1,1]},Nce=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Lce=Nce("applewebkit/")&&!Nce("chrome/")?Math.round:su;function Ice(e){e.min=Lce(e.min),e.max=Lce(e.max)}function C2t(e){Ice(e.x),Ice(e.y)}function B_e(e,t,n){return e==="position"||e==="preserve-aspect"&&!qTt(Sce(t),Sce(n),.2)}function E2t(e){var t;return e!==e.root&&((t=e.scroll)==null?void 0:t.wasRoot)}const T2t=F_e({attachResizeListener:(e,t)=>iT(e,"resize",t),measureScroll:()=>{var e,t;return{x:document.documentElement.scrollLeft||((e=document.body)==null?void 0:e.scrollLeft)||0,y:document.documentElement.scrollTop||((t=document.body)==null?void 0:t.scrollTop)||0}},checkIsScrollRoot:()=>!0}),Y8={current:void 0},H_e=F_e({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Y8.current){const e=new T2t({});e.mount(window),e.setOptions({layoutScroll:!0}),Y8.current=e}return Y8.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),xA=A.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function Pce(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function A2t(...e){return t=>{let n=!1;const r=e.map(i=>{const o=Pce(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():Pce(e[i],null)}}}}function O2t(...e){return A.useCallback(A2t(...e),e)}class R2t extends A.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(E_(n)&&t.isPresent&&!this.props.isPresent&&this.props.pop!==!1){const r=n.offsetParent,i=E_(r)&&r.offsetWidth||0,o=E_(r)&&r.offsetHeight||0,s=getComputedStyle(n),a=this.props.sizeRef.current;a.height=parseFloat(s.height),a.width=parseFloat(s.width),a.top=n.offsetTop,a.left=n.offsetLeft,a.right=i-a.width-a.left,a.bottom=o-a.height-a.top,a.direction=s.direction}return null}componentDidUpdate(){}render(){return this.props.children}}function M2t({children:e,isPresent:t,anchorX:n,anchorY:r,root:i,pop:o}){var h;const s=A.useId(),a=A.useRef(null),l=A.useRef({width:0,height:0,top:0,left:0,right:0,bottom:0,direction:"ltr"}),{nonce:u}=A.useContext(xA),c=o!==!1?((h=e.props)==null?void 0:h.ref)??(e==null?void 0:e.ref):void 0,d=O2t(a,c);return A.useInsertionEffect(()=>{const{width:m,height:g,top:b,left:v,right:w,bottom:S,direction:C}=l.current;if(t||o===!1||!a.current||!m||!g)return;const E=C==="rtl",T=n==="left"?E?`right: ${w}`:`left: ${v}`:E?`left: ${v}`:`right: ${w}`,O=r==="bottom"?`bottom: ${S}`:`top: ${b}`;a.current.dataset.motionPopId=s;const M=document.createElement("style");u&&(M.nonce=u);const N=i??document.head;return N.appendChild(M),M.sheet&&M.sheet.insertRule(`
2836
+ */var tue;function Fxt(){return tue||(tue=1,(function(e){(function(){var t={}.hasOwnProperty;function n(){for(var o="",s=0;s<arguments.length;s++){var a=arguments[s];a&&(o=i(o,r(a)))}return o}function r(o){if(typeof o=="string"||typeof o=="number")return o;if(typeof o!="object")return"";if(Array.isArray(o))return n.apply(null,o);if(o.toString!==Object.prototype.toString&&!o.toString.toString().includes("[native code]"))return o.toString();var s="";for(var a in o)t.call(o,a)&&o[a]&&(s=i(s,a));return s}function i(o,s){return s?o?o+" "+s:o+s:o}e.exports?(n.default=n,e.exports=n):window.classNames=n})()})(z8)),z8.exports}var Bxt=Fxt();const iS=cr(Bxt);function Hu(e,t){e(t)}function Hxt(){let{x:e,x0:t,x1:n,y:r,y0:i,y1:o,defined:s,curve:a}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const l=dC();return e&&Hu(l.x,e),t&&Hu(l.x0,t),n&&Hu(l.x1,n),r&&Hu(l.y,r),i&&Hu(l.y0,i),o&&Hu(l.y1,o),s&&l.defined(s),a&&l.curve(a),l}function Uxt(){let{x:e,y:t,defined:n,curve:r}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const i=Fj();return e&&Hu(i.x,e),t&&Hu(i.y,t),n&&i.defined(n),r&&i.curve(r),i}function fRe(e){let{top:t=0,left:n=0,transform:r,className:i,children:o,innerRef:s,...a}=e;return y.jsx("g",{ref:s,className:iS("visx-group",i),transform:r||`translate(${n}, ${t})`,...a,children:o})}function hRe(e){let{from:t={x:0,y:0},to:n={x:1,y:1},fill:r="transparent",className:i,innerRef:o,...s}=e;const a=t.x===n.x||t.y===n.y;return y.jsx("line",{ref:o,className:iS("visx-line",i),x1:t.x,y1:t.y,x2:n.x,y2:n.y,fill:r,shapeRendering:a?"crispEdges":"auto",...s})}function IY(e){let{children:t,data:n=[],x:r,y:i,fill:o="transparent",className:s,curve:a,innerRef:l,defined:u=()=>!0,...c}=e;const d=Uxt({x:r,y:i,defined:u,curve:a});return t?y.jsx(y.Fragment,{children:t({path:d})}):y.jsx("path",{ref:l,className:iS("visx-linepath",s),d:d(n)||"",fill:o,strokeLinecap:"round",...c})}function PY(e){let{x:t,x0:n,x1:r,y:i,y1:o,y0:s,yScale:a,data:l=[],defined:u=()=>!0,className:c,curve:d,innerRef:h,children:m,...g}=e;const b=Hxt({x:t,x0:n,x1:r,defined:u,curve:d});return s==null?b.y0(a.range()[0]):Hu(b.y0,s),i&&!o&&Hu(b.y1,i),o&&!i&&Hu(b.y1,o),m?y.jsx(y.Fragment,{children:m({path:b})}):y.jsx("path",{ref:h,className:iS("visx-area-closed",c),d:b(l)||"",...g})}function Hj(e){return e===!1?{left:!1,right:!1,any:!1}:e==="left"?{left:!0,right:!1,any:!0}:e==="right"?{left:!1,right:!0,any:!0}:{left:!0,right:!0,any:!0}}function qL(e){return[{offset:"0%",opacity:e.left?0:1},{offset:"15%",opacity:1},{offset:"85%",opacity:1},{offset:"100%",opacity:e.right?0:1}]}function GL(e){return{gradientUnits:"userSpaceOnUse",x1:0,x2:e,y1:0,y2:0}}function Vxt({gradientId:e,strokeGradientId:t,edgeMaskId:n,edgeGradientId:r,fill:i,fillOpacity:o,gradientToOpacity:s,gradientSpan:a=1,resolvedStroke:l,isPatternFill:u,fadeEdges:c,innerWidth:d,innerHeight:h}){const m=Hj(c),g=m.any?qL(m):null,v=m.any&&!u?qL(m):null,w=Math.min(1,Math.max(.01,a)),S=`${w*100}%`;return y.jsxs("defs",{children:[u?null:y.jsxs("linearGradient",{id:e,x1:"0%",x2:"0%",y1:"0%",y2:"100%",children:[y.jsx("stop",{offset:"0%",style:{stopColor:i,stopOpacity:o}}),y.jsx("stop",{offset:S,style:{stopColor:i,stopOpacity:s}}),w<1?y.jsx("stop",{offset:"100%",style:{stopColor:i,stopOpacity:s}}):null]}),g?y.jsx("linearGradient",{id:t,...GL(d),children:g.map(C=>y.jsx("stop",{offset:C.offset,style:{stopColor:l,stopOpacity:C.opacity}},C.offset))}):null,v?y.jsxs(y.Fragment,{children:[y.jsx("linearGradient",{id:r,...GL(d),children:v.map(C=>y.jsx("stop",{offset:C.offset,style:{stopColor:"white",stopOpacity:C.opacity}},C.offset))}),y.jsx("mask",{id:n,children:y.jsx("rect",{fill:`url(#${r})`,height:h,width:d,x:"0",y:"0"})})]}):null]})}function ug(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function Wxt(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function Uj(e){let t,n,r;e.length!==2?(t=ug,n=(a,l)=>ug(e(a),l),r=(a,l)=>e(a)-l):(t=e===ug||e===Wxt?e:qxt,n=e,r=e);function i(a,l,u=0,c=a.length){if(u<c){if(t(l,l)!==0)return c;do{const d=u+c>>>1;n(a[d],l)<0?u=d+1:c=d}while(u<c)}return u}function o(a,l,u=0,c=a.length){if(u<c){if(t(l,l)!==0)return c;do{const d=u+c>>>1;n(a[d],l)<=0?u=d+1:c=d}while(u<c)}return u}function s(a,l,u=0,c=a.length){const d=i(a,l,u,c-1);return d>u&&r(a[d-1],l)>-r(a[d],l)?d-1:d}return{left:i,center:s,right:o}}function qxt(){return 0}function pRe(e){return e===null?NaN:+e}function*Gxt(e,t){for(let n of e)n!=null&&(n=+n)>=n&&(yield n)}const Kxt=Uj(ug),uA=Kxt.right;Uj(pRe).center;function nue(e,t){let n,r;if(t===void 0)for(const i of e)i!=null&&(n===void 0?i>=i&&(n=r=i):(n>i&&(n=i),r<i&&(r=i)));else{let i=-1;for(let o of e)(o=t(o,++i,e))!=null&&(n===void 0?o>=o&&(n=r=o):(n>o&&(n=o),r<o&&(r=o)))}return[n,r]}class rue extends Map{constructor(t,n=Qxt){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(iue(this,t))}has(t){return super.has(iue(this,t))}set(t,n){return super.set(Yxt(this,t),n)}delete(t){return super.delete(Xxt(this,t))}}function iue({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function Yxt({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function Xxt({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function Qxt(e){return e!==null&&typeof e=="object"?e.valueOf():e}function Zxt(e=ug){if(e===ug)return mRe;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 mRe(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}const Jxt=Math.sqrt(50),ewt=Math.sqrt(10),twt=Math.sqrt(2);function KL(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),s=o>=Jxt?10:o>=ewt?5:o>=twt?2:1;let a,l,u;return i<0?(u=Math.pow(10,-i)/s,a=Math.round(e*u),l=Math.round(t*u),a/u<e&&++a,l/u>t&&--l,u=-u):(u=Math.pow(10,i)*s,a=Math.round(e/u),l=Math.round(t/u),a*u<e&&++a,l*u>t&&--l),l<a&&.5<=n&&n<2?KL(e,t,n*2):[a,l,u]}function tV(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[i,o,s]=r?KL(t,e,n):KL(e,t,n);if(!(o>=i))return[];const a=o-i+1,l=new Array(a);if(r)if(s<0)for(let u=0;u<a;++u)l[u]=(o-u)/-s;else for(let u=0;u<a;++u)l[u]=(o-u)*s;else if(s<0)for(let u=0;u<a;++u)l[u]=(i+u)/-s;else for(let u=0;u<a;++u)l[u]=(i+u)*s;return l}function nV(e,t,n){return t=+t,e=+e,n=+n,KL(e,t,n)[2]}function rV(e,t,n){t=+t,e=+e,n=+n;const r=t<e,i=r?nV(t,e,n):nV(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}function oue(e,t){let n;for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);return n}function sue(e,t){let n;for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);return n}function gRe(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?mRe:Zxt(i);r>n;){if(r-n>600){const l=r-n+1,u=t-n+1,c=Math.log(l),d=.5*Math.exp(2*c/3),h=.5*Math.sqrt(c*d*(l-d)/l)*(u-l/2<0?-1:1),m=Math.max(n,Math.floor(t-u*d/l+h)),g=Math.min(r,Math.floor(t+(l-u)*d/l+h));gRe(e,t,m,g,i)}const o=e[t];let s=n,a=r;for(wk(e,n,t),i(e[r],o)>0&&wk(e,n,r);s<a;){for(wk(e,s,a),++s,--a;i(e[s],o)<0;)++s;for(;i(e[a],o)>0;)--a}i(e[n],o)===0?wk(e,n,a):(++a,wk(e,a,r)),a<=t&&(n=a+1),t<=a&&(r=a-1)}return e}function wk(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function nwt(e,t,n){if(e=Float64Array.from(Gxt(e)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return sue(e);if(t>=1)return oue(e);var r,i=(r-1)*t,o=Math.floor(i),s=oue(gRe(e,o).subarray(0,o+1)),a=sue(e.subarray(o+1));return s+(a-s)*(i-o)}}function rwt(e,t,n=pRe){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),s=+n(e[o],o,e),a=+n(e[o+1],o+1,e);return s+(a-s)*(i-o)}}function iwt(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 hu(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function ep(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 iV=Symbol("implicit");function jY(){var e=new rue,t=[],n=[],r=iV;function i(o){let s=e.get(o);if(s===void 0){if(r!==iV)return r;e.set(o,s=t.push(o)-1)}return n[s%n.length]}return i.domain=function(o){if(!arguments.length)return t.slice();t=[],e=new rue;for(const s of o)e.has(s)||e.set(s,t.push(s)-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 jY(t,n).unknown(r)},hu.apply(i,arguments),i}function Jx(){var e=jY().unknown(void 0),t=e.domain,n=e.range,r=0,i=1,o,s,a=!1,l=0,u=0,c=.5;delete e.unknown;function d(){var h=t().length,m=i<r,g=m?i:r,b=m?r:i;o=(b-g)/Math.max(1,h-l+u*2),a&&(o=Math.floor(o)),g+=(b-g-o*(h-l))*c,s=o*(1-l),a&&(g=Math.round(g),s=Math.round(s));var v=iwt(h).map(function(w){return g+o*w});return n(m?v.reverse():v)}return e.domain=function(h){return arguments.length?(t(h),d()):t()},e.range=function(h){return arguments.length?([r,i]=h,r=+r,i=+i,d()):[r,i]},e.rangeRound=function(h){return[r,i]=h,r=+r,i=+i,a=!0,d()},e.bandwidth=function(){return s},e.step=function(){return o},e.round=function(h){return arguments.length?(a=!!h,d()):a},e.padding=function(h){return arguments.length?(l=Math.min(1,u=+h),d()):l},e.paddingInner=function(h){return arguments.length?(l=Math.min(1,h),d()):l},e.paddingOuter=function(h){return arguments.length?(u=+h,d()):u},e.align=function(h){return arguments.length?(c=Math.max(0,Math.min(1,h)),d()):c},e.copy=function(){return Jx(t(),[r,i]).round(a).paddingInner(l).paddingOuter(u).align(c)},hu.apply(d(),arguments)}function yRe(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return yRe(t())},e}function GC(){return yRe(Jx.apply(null,arguments).paddingInner(1))}function oS(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function cA(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function Bg(){}var gb=.7,ew=1/gb,H1="\\s*([+-]?\\d+)\\s*",KE="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Sd="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",owt=/^#([0-9a-f]{3,8})$/,swt=new RegExp(`^rgb\\(${H1},${H1},${H1}\\)$`),awt=new RegExp(`^rgb\\(${Sd},${Sd},${Sd}\\)$`),lwt=new RegExp(`^rgba\\(${H1},${H1},${H1},${KE}\\)$`),uwt=new RegExp(`^rgba\\(${Sd},${Sd},${Sd},${KE}\\)$`),cwt=new RegExp(`^hsl\\(${KE},${Sd},${Sd}\\)$`),dwt=new RegExp(`^hsla\\(${KE},${Sd},${Sd},${KE}\\)$`),aue={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};oS(Bg,yb,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:lue,formatHex:lue,formatHex8:fwt,formatHsl:hwt,formatRgb:uue,toString:uue});function lue(){return this.rgb().formatHex()}function fwt(){return this.rgb().formatHex8()}function hwt(){return bRe(this).formatHsl()}function uue(){return this.rgb().formatRgb()}function yb(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=owt.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?cue(t):n===3?new jo(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?nM(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?nM(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=swt.exec(e))?new jo(t[1],t[2],t[3],1):(t=awt.exec(e))?new jo(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=lwt.exec(e))?nM(t[1],t[2],t[3],t[4]):(t=uwt.exec(e))?nM(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=cwt.exec(e))?hue(t[1],t[2]/100,t[3]/100,1):(t=dwt.exec(e))?hue(t[1],t[2]/100,t[3]/100,t[4]):aue.hasOwnProperty(e)?cue(aue[e]):e==="transparent"?new jo(NaN,NaN,NaN,0):null}function cue(e){return new jo(e>>16&255,e>>8&255,e&255,1)}function nM(e,t,n,r){return r<=0&&(e=t=n=NaN),new jo(e,t,n,r)}function DY(e){return e instanceof Bg||(e=yb(e)),e?(e=e.rgb(),new jo(e.r,e.g,e.b,e.opacity)):new jo}function oV(e,t,n,r){return arguments.length===1?DY(e):new jo(e,t,n,r??1)}function jo(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}oS(jo,oV,cA(Bg,{brighter(e){return e=e==null?ew:Math.pow(ew,e),new jo(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?gb:Math.pow(gb,e),new jo(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new jo(Qy(this.r),Qy(this.g),Qy(this.b),YL(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:due,formatHex:due,formatHex8:pwt,formatRgb:fue,toString:fue}));function due(){return`#${iy(this.r)}${iy(this.g)}${iy(this.b)}`}function pwt(){return`#${iy(this.r)}${iy(this.g)}${iy(this.b)}${iy((isNaN(this.opacity)?1:this.opacity)*255)}`}function fue(){const e=YL(this.opacity);return`${e===1?"rgb(":"rgba("}${Qy(this.r)}, ${Qy(this.g)}, ${Qy(this.b)}${e===1?")":`, ${e})`}`}function YL(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Qy(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function iy(e){return e=Qy(e),(e<16?"0":"")+e.toString(16)}function hue(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new Gu(e,t,n,r)}function bRe(e){if(e instanceof Gu)return new Gu(e.h,e.s,e.l,e.opacity);if(e instanceof Bg||(e=yb(e)),!e)return new Gu;if(e instanceof Gu)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),s=NaN,a=o-i,l=(o+i)/2;return a?(t===o?s=(n-r)/a+(n<r)*6:n===o?s=(r-t)/a+2:s=(t-n)/a+4,a/=l<.5?o+i:2-o-i,s*=60):a=l>0&&l<1?0:s,new Gu(s,a,l,e.opacity)}function sV(e,t,n,r){return arguments.length===1?bRe(e):new Gu(e,t,n,r??1)}function Gu(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}oS(Gu,sV,cA(Bg,{brighter(e){return e=e==null?ew:Math.pow(ew,e),new Gu(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?gb:Math.pow(gb,e),new Gu(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 jo(F8(e>=240?e-240:e+120,i,r),F8(e,i,r),F8(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new Gu(pue(this.h),rM(this.s),rM(this.l),YL(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=YL(this.opacity);return`${e===1?"hsl(":"hsla("}${pue(this.h)}, ${rM(this.s)*100}%, ${rM(this.l)*100}%${e===1?")":`, ${e})`}`}}));function pue(e){return e=(e||0)%360,e<0?e+360:e}function rM(e){return Math.max(0,Math.min(1,e||0))}function F8(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 vRe=Math.PI/180,xRe=180/Math.PI,XL=18,wRe=.96422,SRe=1,kRe=.82521,CRe=4/29,U1=6/29,ERe=3*U1*U1,mwt=U1*U1*U1;function TRe(e){if(e instanceof kd)return new kd(e.l,e.a,e.b,e.opacity);if(e instanceof ch)return ARe(e);e instanceof jo||(e=DY(e));var t=V8(e.r),n=V8(e.g),r=V8(e.b),i=B8((.2225045*t+.7168786*n+.0606169*r)/SRe),o,s;return t===n&&n===r?o=s=i:(o=B8((.4360747*t+.3850649*n+.1430804*r)/wRe),s=B8((.0139322*t+.0971045*n+.7141733*r)/kRe)),new kd(116*i-16,500*(o-i),200*(i-s),e.opacity)}function aV(e,t,n,r){return arguments.length===1?TRe(e):new kd(e,t,n,r??1)}function kd(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}oS(kd,aV,cA(Bg,{brighter(e){return new kd(this.l+XL*(e??1),this.a,this.b,this.opacity)},darker(e){return new kd(this.l-XL*(e??1),this.a,this.b,this.opacity)},rgb(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,n=isNaN(this.b)?e:e-this.b/200;return t=wRe*H8(t),e=SRe*H8(e),n=kRe*H8(n),new jo(U8(3.1338561*t-1.6168667*e-.4906146*n),U8(-.9787684*t+1.9161415*e+.033454*n),U8(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}}));function B8(e){return e>mwt?Math.pow(e,1/3):e/ERe+CRe}function H8(e){return e>U1?e*e*e:ERe*(e-CRe)}function U8(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function V8(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function gwt(e){if(e instanceof ch)return new ch(e.h,e.c,e.l,e.opacity);if(e instanceof kd||(e=TRe(e)),e.a===0&&e.b===0)return new ch(NaN,0<e.l&&e.l<100?0:NaN,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*xRe;return new ch(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}function lV(e,t,n,r){return arguments.length===1?gwt(e):new ch(e,t,n,r??1)}function ch(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}function ARe(e){if(isNaN(e.h))return new kd(e.l,0,0,e.opacity);var t=e.h*vRe;return new kd(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}oS(ch,lV,cA(Bg,{brighter(e){return new ch(this.h,this.c,this.l+XL*(e??1),this.opacity)},darker(e){return new ch(this.h,this.c,this.l-XL*(e??1),this.opacity)},rgb(){return ARe(this).rgb()}}));var ORe=-.14861,$Y=1.78277,zY=-.29227,Vj=-.90649,YE=1.97294,mue=YE*Vj,gue=YE*$Y,yue=$Y*zY-Vj*ORe;function ywt(e){if(e instanceof Zy)return new Zy(e.h,e.s,e.l,e.opacity);e instanceof jo||(e=DY(e));var t=e.r/255,n=e.g/255,r=e.b/255,i=(yue*r+mue*t-gue*n)/(yue+mue-gue),o=r-i,s=(YE*(n-i)-zY*o)/Vj,a=Math.sqrt(s*s+o*o)/(YE*i*(1-i)),l=a?Math.atan2(s,o)*xRe-120:NaN;return new Zy(l<0?l+360:l,a,i,e.opacity)}function uV(e,t,n,r){return arguments.length===1?ywt(e):new Zy(e,t,n,r??1)}function Zy(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}oS(Zy,uV,cA(Bg,{brighter(e){return e=e==null?ew:Math.pow(ew,e),new Zy(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?gb:Math.pow(gb,e),new Zy(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=isNaN(this.h)?0:(this.h+120)*vRe,t=+this.l,n=isNaN(this.s)?0:this.s*t*(1-t),r=Math.cos(e),i=Math.sin(e);return new jo(255*(t+n*(ORe*r+$Y*i)),255*(t+n*(zY*r+Vj*i)),255*(t+n*(YE*r)),this.opacity)}}));const Wj=e=>()=>e;function RRe(e,t){return function(n){return e+n*t}}function bwt(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 FY(e,t){var n=t-e;return n?RRe(e,n>180||n<-180?n-360*Math.round(n/360):n):Wj(isNaN(e)?t:e)}function vwt(e){return(e=+e)==1?Do:function(t,n){return n-t?bwt(t,n,e):Wj(isNaN(t)?n:t)}}function Do(e,t){var n=t-e;return n?RRe(e,n):Wj(isNaN(e)?t:e)}const XE=(function e(t){var n=vwt(t);function r(i,o){var s=n((i=oV(i)).r,(o=oV(o)).r),a=n(i.g,o.g),l=n(i.b,o.b),u=Do(i.opacity,o.opacity);return function(c){return i.r=s(c),i.g=a(c),i.b=l(c),i.opacity=u(c),i+""}}return r.gamma=e,r})(1);function xwt(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 wwt(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function Swt(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=new Array(r),o=new Array(n),s;for(s=0;s<r;++s)i[s]=Ah(e[s],t[s]);for(;s<n;++s)o[s]=t[s];return function(a){for(s=0;s<r;++s)o[s]=i[s](a);return o}}function kwt(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function Uu(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function Cwt(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]=Ah(e[i],t[i]):r[i]=t[i];return function(o){for(i in n)r[i]=n[i](o);return r}}var cV=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,W8=new RegExp(cV.source,"g");function Ewt(e){return function(){return e}}function Twt(e){return function(t){return e(t)+""}}function MRe(e,t){var n=cV.lastIndex=W8.lastIndex=0,r,i,o,s=-1,a=[],l=[];for(e=e+"",t=t+"";(r=cV.exec(e))&&(i=W8.exec(t));)(o=i.index)>n&&(o=t.slice(n,o),a[s]?a[s]+=o:a[++s]=o),(r=r[0])===(i=i[0])?a[s]?a[s]+=i:a[++s]=i:(a[++s]=null,l.push({i:s,x:Uu(r,i)})),n=W8.lastIndex;return n<t.length&&(o=t.slice(n),a[s]?a[s]+=o:a[++s]=o),a.length<2?l[0]?Twt(l[0].x):Ewt(t):(t=l.length,function(u){for(var c=0,d;c<t;++c)a[(d=l[c]).i]=d.x(u);return a.join("")})}function Ah(e,t){var n=typeof t,r;return t==null||n==="boolean"?Wj(t):(n==="number"?Uu:n==="string"?(r=yb(t))?(t=r,XE):MRe:t instanceof yb?XE:t instanceof Date?kwt:wwt(t)?xwt:Array.isArray(t)?Swt:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?Cwt:Uu)(e,t)}function qj(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}var bue=180/Math.PI,dV={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function _Re(e,t,n,r,i,o){var s,a,l;return(s=Math.sqrt(e*e+t*t))&&(e/=s,t/=s),(l=e*n+t*r)&&(n-=e*l,r-=t*l),(a=Math.sqrt(n*n+r*r))&&(n/=a,r/=a,l/=a),e*r<t*n&&(e=-e,t=-t,l=-l,s=-s),{translateX:i,translateY:o,rotate:Math.atan2(t,e)*bue,skewX:Math.atan(l)*bue,scaleX:s,scaleY:a}}var iM;function Awt(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?dV:_Re(t.a,t.b,t.c,t.d,t.e,t.f)}function Owt(e){return e==null||(iM||(iM=document.createElementNS("http://www.w3.org/2000/svg","g")),iM.setAttribute("transform",e),!(e=iM.transform.baseVal.consolidate()))?dV:(e=e.matrix,_Re(e.a,e.b,e.c,e.d,e.e,e.f))}function NRe(e,t,n,r){function i(u){return u.length?u.pop()+" ":""}function o(u,c,d,h,m,g){if(u!==d||c!==h){var b=m.push("translate(",null,t,null,n);g.push({i:b-4,x:Uu(u,d)},{i:b-2,x:Uu(c,h)})}else(d||h)&&m.push("translate("+d+t+h+n)}function s(u,c,d,h){u!==c?(u-c>180?c+=360:c-u>180&&(u+=360),h.push({i:d.push(i(d)+"rotate(",null,r)-2,x:Uu(u,c)})):c&&d.push(i(d)+"rotate("+c+r)}function a(u,c,d,h){u!==c?h.push({i:d.push(i(d)+"skewX(",null,r)-2,x:Uu(u,c)}):c&&d.push(i(d)+"skewX("+c+r)}function l(u,c,d,h,m,g){if(u!==d||c!==h){var b=m.push(i(m)+"scale(",null,",",null,")");g.push({i:b-4,x:Uu(u,d)},{i:b-2,x:Uu(c,h)})}else(d!==1||h!==1)&&m.push(i(m)+"scale("+d+","+h+")")}return function(u,c){var d=[],h=[];return u=e(u),c=e(c),o(u.translateX,u.translateY,c.translateX,c.translateY,d,h),s(u.rotate,c.rotate,d,h),a(u.skewX,c.skewX,d,h),l(u.scaleX,u.scaleY,c.scaleX,c.scaleY,d,h),u=c=null,function(m){for(var g=-1,b=h.length,v;++g<b;)d[(v=h[g]).i]=v.x(m);return d.join("")}}}var Rwt=NRe(Awt,"px, ","px)","deg)"),Mwt=NRe(Owt,", ",")",")"),_wt=1e-12;function vue(e){return((e=Math.exp(e))+1/e)/2}function Nwt(e){return((e=Math.exp(e))-1/e)/2}function Lwt(e){return((e=Math.exp(2*e))-1)/(e+1)}const k_=(function e(t,n,r){function i(o,s){var a=o[0],l=o[1],u=o[2],c=s[0],d=s[1],h=s[2],m=c-a,g=d-l,b=m*m+g*g,v,w;if(b<_wt)w=Math.log(h/u)/t,v=function(M){return[a+M*m,l+M*g,u*Math.exp(t*M*w)]};else{var S=Math.sqrt(b),C=(h*h-u*u+r*b)/(2*u*n*S),E=(h*h-u*u-r*b)/(2*h*n*S),T=Math.log(Math.sqrt(C*C+1)-C),O=Math.log(Math.sqrt(E*E+1)-E);w=(O-T)/t,v=function(M){var N=M*w,I=vue(T),D=u/(n*S)*(I*Lwt(t*N+T)-Nwt(T));return[a+D*m,l+D*g,u*I/vue(t*N+T)]}}return v.duration=w*1e3*t/Math.SQRT2,v}return i.rho=function(o){var s=Math.max(.001,+o),a=s*s,l=a*a;return e(s,a,l)},i})(Math.SQRT2,2,4);function LRe(e){return function(t,n){var r=e((t=sV(t)).h,(n=sV(n)).h),i=Do(t.s,n.s),o=Do(t.l,n.l),s=Do(t.opacity,n.opacity);return function(a){return t.h=r(a),t.s=i(a),t.l=o(a),t.opacity=s(a),t+""}}}const Iwt=LRe(FY);var Pwt=LRe(Do);function jwt(e,t){var n=Do((e=aV(e)).l,(t=aV(t)).l),r=Do(e.a,t.a),i=Do(e.b,t.b),o=Do(e.opacity,t.opacity);return function(s){return e.l=n(s),e.a=r(s),e.b=i(s),e.opacity=o(s),e+""}}function IRe(e){return function(t,n){var r=e((t=lV(t)).h,(n=lV(n)).h),i=Do(t.c,n.c),o=Do(t.l,n.l),s=Do(t.opacity,n.opacity);return function(a){return t.h=r(a),t.c=i(a),t.l=o(a),t.opacity=s(a),t+""}}}const Dwt=IRe(FY);var $wt=IRe(Do);function PRe(e){return(function t(n){n=+n;function r(i,o){var s=e((i=uV(i)).h,(o=uV(o)).h),a=Do(i.s,o.s),l=Do(i.l,o.l),u=Do(i.opacity,o.opacity);return function(c){return i.h=s(c),i.s=a(c),i.l=l(Math.pow(c,n)),i.opacity=u(c),i+""}}return r.gamma=t,r})(1)}const zwt=PRe(FY);var Fwt=PRe(Do);function Bwt(e,t){t===void 0&&(t=e,e=Ah);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(s){var a=Math.max(0,Math.min(r-1,Math.floor(s*=r)));return o[a](s-a)}}function Hwt(e){return function(){return e}}function QL(e){return+e}var xue=[0,1];function Gs(e){return e}function fV(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:Hwt(isNaN(t)?NaN:.5)}function Uwt(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function Vwt(e,t,n){var r=e[0],i=e[1],o=t[0],s=t[1];return i<r?(r=fV(i,r),o=n(s,o)):(r=fV(r,i),o=n(o,s)),function(a){return o(r(a))}}function Wwt(e,t,n){var r=Math.min(e.length,t.length)-1,i=new Array(r),o=new Array(r),s=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++s<r;)i[s]=fV(e[s],e[s+1]),o[s]=n(t[s],t[s+1]);return function(a){var l=uA(e,a,1,r)-1;return o[l](i[l](a))}}function dA(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Gj(){var e=xue,t=xue,n=Ah,r,i,o,s=Gs,a,l,u;function c(){var h=Math.min(e.length,t.length);return s!==Gs&&(s=Uwt(e[0],e[h-1])),a=h>2?Wwt:Vwt,l=u=null,d}function d(h){return h==null||isNaN(h=+h)?o:(l||(l=a(e.map(r),t,n)))(r(s(h)))}return d.invert=function(h){return s(i((u||(u=a(t,e.map(r),Uu)))(h)))},d.domain=function(h){return arguments.length?(e=Array.from(h,QL),c()):e.slice()},d.range=function(h){return arguments.length?(t=Array.from(h),c()):t.slice()},d.rangeRound=function(h){return t=Array.from(h),n=qj,c()},d.clamp=function(h){return arguments.length?(s=h?!0:Gs,c()):s!==Gs},d.interpolate=function(h){return arguments.length?(n=h,c()):n},d.unknown=function(h){return arguments.length?(o=h,d):o},function(h,m){return r=h,i=m,c()}}function BY(){return Gj()(Gs,Gs)}function qwt(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function ZL(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function tw(e){return e=ZL(Math.abs(e)),e?e[1]:NaN}function Gwt(e,t){return function(n,r){for(var i=n.length,o=[],s=0,a=e[0],l=0;i>0&&a>0&&(l+a+1>r&&(a=Math.max(1,r-l)),o.push(n.substring(i-=a,i+a)),!((l+=a+1)>r));)a=e[s=(s+1)%e.length];return o.reverse().join(t)}}function Kwt(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var Ywt=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function QE(e){if(!(t=Ywt.exec(e)))throw new Error("invalid format: "+e);var t;return new HY({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]})}QE.prototype=HY.prototype;function HY(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+""}HY.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 Xwt(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 jRe;function Qwt(e,t){var n=ZL(e,t);if(!n)return e+"";var r=n[0],i=n[1],o=i-(jRe=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,s=r.length;return o===s?r:o>s?r+new Array(o-s+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+ZL(e,Math.max(0,t+o-1))[0]}function wue(e,t){var n=ZL(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 Sue={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:qwt,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)=>wue(e*100,t),r:wue,s:Qwt,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function kue(e){return e}var Cue=Array.prototype.map,Eue=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function Zwt(e){var t=e.grouping===void 0||e.thousands===void 0?kue:Gwt(Cue.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?kue:Kwt(Cue.call(e.numerals,String)),s=e.percent===void 0?"%":e.percent+"",a=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function u(d){d=QE(d);var h=d.fill,m=d.align,g=d.sign,b=d.symbol,v=d.zero,w=d.width,S=d.comma,C=d.precision,E=d.trim,T=d.type;T==="n"?(S=!0,T="g"):Sue[T]||(C===void 0&&(C=12),E=!0,T="g"),(v||h==="0"&&m==="=")&&(v=!0,h="0",m="=");var O=b==="$"?n:b==="#"&&/[boxX]/.test(T)?"0"+T.toLowerCase():"",M=b==="$"?r:/[%p]/.test(T)?s:"",N=Sue[T],I=/[defgprs%]/.test(T);C=C===void 0?6:/[gprs]/.test(T)?Math.max(1,Math.min(21,C)):Math.max(0,Math.min(20,C));function D(P){var F=O,z=M,$,B,H;if(T==="c")z=N(P)+z,P="";else{P=+P;var U=P<0||1/P<0;if(P=isNaN(P)?l:N(Math.abs(P),C),E&&(P=Xwt(P)),U&&+P==0&&g!=="+"&&(U=!1),F=(U?g==="("?g:a:g==="-"||g==="("?"":g)+F,z=(T==="s"?Eue[8+jRe/3]:"")+z+(U&&g==="("?")":""),I){for($=-1,B=P.length;++$<B;)if(H=P.charCodeAt($),48>H||H>57){z=(H===46?i+P.slice($+1):P.slice($))+z,P=P.slice(0,$);break}}}S&&!v&&(P=t(P,1/0));var W=F.length+P.length+z.length,q=W<w?new Array(w-W+1).join(h):"";switch(S&&v&&(P=t(q+P,q.length?w-z.length:1/0),q=""),m){case"<":P=F+P+z+q;break;case"=":P=F+q+P+z;break;case"^":P=q.slice(0,W=q.length>>1)+F+P+z+q.slice(W);break;default:P=q+F+P+z;break}return o(P)}return D.toString=function(){return d+""},D}function c(d,h){var m=u((d=QE(d),d.type="f",d)),g=Math.max(-8,Math.min(8,Math.floor(tw(h)/3)))*3,b=Math.pow(10,-g),v=Eue[8+g/3];return function(w){return m(b*w)+v}}return{format:u,formatPrefix:c}}var oM,UY,DRe;Jwt({thousands:",",grouping:[3],currency:["$",""]});function Jwt(e){return oM=Zwt(e),UY=oM.format,DRe=oM.formatPrefix,oM}function eSt(e){return Math.max(0,-tw(Math.abs(e)))}function tSt(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(tw(t)/3)))*3-tw(Math.abs(e)))}function nSt(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,tw(t)-tw(e))+1}function $Re(e,t,n,r){var i=rV(e,t,n),o;switch(r=QE(r??",f"),r.type){case"s":{var s=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(o=tSt(i,s))&&(r.precision=o),DRe(r,s)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(o=nSt(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=o-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(o=eSt(i))&&(r.precision=o-(r.type==="%")*2);break}}return UY(r)}function Hg(e){var t=e.domain;return e.ticks=function(n){var r=t();return tV(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var i=t();return $Re(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,s=r[i],a=r[o],l,u,c=10;for(a<s&&(u=s,s=a,a=u,u=i,i=o,o=u);c-- >0;){if(u=nV(s,a,n),u===l)return r[i]=s,r[o]=a,t(r);if(u>0)s=Math.floor(s/u)*u,a=Math.ceil(a/u)*u;else if(u<0)s=Math.ceil(s*u)/u,a=Math.floor(a*u)/u;else break;l=u}return e},e}function ZE(){var e=BY();return e.copy=function(){return dA(e,ZE())},hu.apply(e,arguments),Hg(e)}function zRe(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,QL),n):e.slice()},n.unknown=function(r){return arguments.length?(t=r,n):t},n.copy=function(){return zRe(e).unknown(t)},e=arguments.length?Array.from(e,QL):[0,1],Hg(n)}function FRe(e,t){e=e.slice();var n=0,r=e.length-1,i=e[n],o=e[r],s;return o<i&&(s=n,n=r,r=s,s=i,i=o,o=s),e[n]=t.floor(i),e[r]=t.ceil(o),e}function Tue(e){return Math.log(e)}function Aue(e){return Math.exp(e)}function rSt(e){return-Math.log(-e)}function iSt(e){return-Math.exp(-e)}function oSt(e){return isFinite(e)?+("1e"+e):e<0?0:e}function sSt(e){return e===10?oSt:e===Math.E?Math.exp:t=>Math.pow(e,t)}function aSt(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 Oue(e){return(t,n)=>-e(-t,n)}function VY(e){const t=e(Tue,Aue),n=t.domain;let r=10,i,o;function s(){return i=aSt(r),o=sSt(r),n()[0]<0?(i=Oue(i),o=Oue(o),e(rSt,iSt)):e(Tue,Aue),t}return t.base=function(a){return arguments.length?(r=+a,s()):r},t.domain=function(a){return arguments.length?(n(a),s()):n()},t.ticks=a=>{const l=n();let u=l[0],c=l[l.length-1];const d=c<u;d&&([u,c]=[c,u]);let h=i(u),m=i(c),g,b;const v=a==null?10:+a;let w=[];if(!(r%1)&&m-h<v){if(h=Math.floor(h),m=Math.ceil(m),u>0){for(;h<=m;++h)for(g=1;g<r;++g)if(b=h<0?g/o(-h):g*o(h),!(b<u)){if(b>c)break;w.push(b)}}else for(;h<=m;++h)for(g=r-1;g>=1;--g)if(b=h>0?g/o(-h):g*o(h),!(b<u)){if(b>c)break;w.push(b)}w.length*2<v&&(w=tV(u,c,v))}else w=tV(h,m,Math.min(m-h,v)).map(o);return d?w.reverse():w},t.tickFormat=(a,l)=>{if(a==null&&(a=10),l==null&&(l=r===10?"s":","),typeof l!="function"&&(!(r%1)&&(l=QE(l)).precision==null&&(l.trim=!0),l=UY(l)),a===1/0)return l;const u=Math.max(1,r*a/t.ticks().length);return c=>{let d=c/o(Math.round(i(c)));return d*r<r-.5&&(d*=r),d<=u?l(c):""}},t.nice=()=>n(FRe(n(),{floor:a=>o(Math.floor(i(a))),ceil:a=>o(Math.ceil(i(a)))})),t}function BRe(){const e=VY(Gj()).domain([1,10]);return e.copy=()=>dA(e,BRe()).base(e.base()),hu.apply(e,arguments),e}function Rue(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function Mue(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function WY(e){var t=1,n=e(Rue(t),Mue(t));return n.constant=function(r){return arguments.length?e(Rue(t=+r),Mue(t)):t},Hg(n)}function HRe(){var e=WY(Gj());return e.copy=function(){return dA(e,HRe()).constant(e.constant())},hu.apply(e,arguments)}function _ue(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function lSt(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function uSt(e){return e<0?-e*e:e*e}function qY(e){var t=e(Gs,Gs),n=1;function r(){return n===1?e(Gs,Gs):n===.5?e(lSt,uSt):e(_ue(n),_ue(1/n))}return t.exponent=function(i){return arguments.length?(n=+i,r()):n},Hg(t)}function GY(){var e=qY(Gj());return e.copy=function(){return dA(e,GY()).exponent(e.exponent())},hu.apply(e,arguments),e}function cSt(){return GY.apply(null,arguments).exponent(.5)}function Nue(e){return Math.sign(e)*e*e}function dSt(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function URe(){var e=BY(),t=[0,1],n=!1,r;function i(o){var s=dSt(e(o));return isNaN(s)?r:n?Math.round(s):s}return i.invert=function(o){return e.invert(Nue(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,QL)).map(Nue)),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 URe(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},hu.apply(i,arguments),Hg(i)}function VRe(){var e=[],t=[],n=[],r;function i(){var s=0,a=Math.max(1,t.length);for(n=new Array(a-1);++s<a;)n[s-1]=rwt(e,s/a);return o}function o(s){return s==null||isNaN(s=+s)?r:t[uA(n,s)]}return o.invertExtent=function(s){var a=t.indexOf(s);return a<0?[NaN,NaN]:[a>0?n[a-1]:e[0],a<n.length?n[a]:e[e.length-1]]},o.domain=function(s){if(!arguments.length)return e.slice();e=[];for(let a of s)a!=null&&!isNaN(a=+a)&&e.push(a);return e.sort(ug),i()},o.range=function(s){return arguments.length?(t=Array.from(s),i()):t.slice()},o.unknown=function(s){return arguments.length?(r=s,o):r},o.quantiles=function(){return n.slice()},o.copy=function(){return VRe().domain(e).range(t).unknown(r)},hu.apply(o,arguments)}function WRe(){var e=0,t=1,n=1,r=[.5],i=[0,1],o;function s(l){return l!=null&&l<=l?i[uA(r,l,0,n)]:o}function a(){var l=-1;for(r=new Array(n);++l<n;)r[l]=((l+1)*t-(l-n)*e)/(n+1);return s}return s.domain=function(l){return arguments.length?([e,t]=l,e=+e,t=+t,a()):[e,t]},s.range=function(l){return arguments.length?(n=(i=Array.from(l)).length-1,a()):i.slice()},s.invertExtent=function(l){var u=i.indexOf(l);return u<0?[NaN,NaN]:u<1?[e,r[0]]:u>=n?[r[n-1],t]:[r[u-1],r[u]]},s.unknown=function(l){return arguments.length&&(o=l),s},s.thresholds=function(){return r.slice()},s.copy=function(){return WRe().domain([e,t]).range(i).unknown(o)},hu.apply(Hg(s),arguments)}function qRe(){var e=[.5],t=[0,1],n,r=1;function i(o){return o!=null&&o<=o?t[uA(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 s=t.indexOf(o);return[e[s-1],e[s]]},i.unknown=function(o){return arguments.length?(n=o,i):n},i.copy=function(){return qRe().domain(e).range(t).unknown(n)},hu.apply(i,arguments)}const q8=new Date,G8=new Date;function yo(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 s=i(o),a=i.ceil(o);return o-s<a-o?s:a},i.offset=(o,s)=>(t(o=new Date(+o),s==null?1:Math.floor(s)),o),i.range=(o,s,a)=>{const l=[];if(o=i.ceil(o),a=a==null?1:Math.floor(a),!(o<s)||!(a>0))return l;let u;do l.push(u=new Date(+o)),t(o,a),e(o);while(u<o&&o<s);return l},i.filter=o=>yo(s=>{if(s>=s)for(;e(s),!o(s);)s.setTime(s-1)},(s,a)=>{if(s>=s)if(a<0)for(;++a<=0;)for(;t(s,-1),!o(s););else for(;--a>=0;)for(;t(s,1),!o(s););}),n&&(i.count=(o,s)=>(q8.setTime(+o),G8.setTime(+s),e(q8),e(G8),Math.floor(n(q8,G8))),i.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?i.filter(r?s=>r(s)%o===0:s=>i.count(0,s)%o===0):i)),i}const JL=yo(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);JL.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?yo(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):JL);JL.range;const dh=1e3,Jl=dh*60,fh=Jl*60,Bh=fh*24,KY=Bh*7,Lue=Bh*30,K8=Bh*365,hh=yo(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*dh)},(e,t)=>(t-e)/dh,e=>e.getUTCSeconds());hh.range;const Kj=yo(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*dh)},(e,t)=>{e.setTime(+e+t*Jl)},(e,t)=>(t-e)/Jl,e=>e.getMinutes());Kj.range;const Yj=yo(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Jl)},(e,t)=>(t-e)/Jl,e=>e.getUTCMinutes());Yj.range;const Xj=yo(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*dh-e.getMinutes()*Jl)},(e,t)=>{e.setTime(+e+t*fh)},(e,t)=>(t-e)/fh,e=>e.getHours());Xj.range;const Qj=yo(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*fh)},(e,t)=>(t-e)/fh,e=>e.getUTCHours());Qj.range;const sS=yo(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Jl)/Bh,e=>e.getDate()-1);sS.range;const fA=yo(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Bh,e=>e.getUTCDate()-1);fA.range;const GRe=yo(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Bh,e=>Math.floor(e/Bh));GRe.range;function jb(e){return yo(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())*Jl)/KY)}const hA=jb(0),eI=jb(1),fSt=jb(2),hSt=jb(3),nw=jb(4),pSt=jb(5),mSt=jb(6);hA.range;eI.range;fSt.range;hSt.range;nw.range;pSt.range;mSt.range;function Db(e){return yo(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)/KY)}const pA=Db(0),tI=Db(1),gSt=Db(2),ySt=Db(3),rw=Db(4),bSt=Db(5),vSt=Db(6);pA.range;tI.range;gSt.range;ySt.range;rw.range;bSt.range;vSt.range;const Zj=yo(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());Zj.range;const Jj=yo(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());Jj.range;const _d=yo(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());_d.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:yo(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)});_d.range;const Nd=yo(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());Nd.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:yo(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)});Nd.range;function KRe(e,t,n,r,i,o){const s=[[hh,1,dh],[hh,5,5*dh],[hh,15,15*dh],[hh,30,30*dh],[o,1,Jl],[o,5,5*Jl],[o,15,15*Jl],[o,30,30*Jl],[i,1,fh],[i,3,3*fh],[i,6,6*fh],[i,12,12*fh],[r,1,Bh],[r,2,2*Bh],[n,1,KY],[t,1,Lue],[t,3,3*Lue],[e,1,K8]];function a(u,c,d){const h=c<u;h&&([u,c]=[c,u]);const m=d&&typeof d.range=="function"?d:l(u,c,d),g=m?m.range(u,+c+1):[];return h?g.reverse():g}function l(u,c,d){const h=Math.abs(c-u)/d,m=Uj(([,,v])=>v).right(s,h);if(m===s.length)return e.every(rV(u/K8,c/K8,d));if(m===0)return JL.every(Math.max(rV(u,c,d),1));const[g,b]=s[h/s[m-1][2]<s[m][2]/h?m-1:m];return g.every(b)}return[a,l]}const[xSt,wSt]=KRe(Nd,Jj,pA,GRe,Qj,Yj),[SSt,kSt]=KRe(_d,Zj,hA,sS,Xj,Kj);function Y8(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 X8(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 Sk(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function CSt(e){var t=e.dateTime,n=e.date,r=e.time,i=e.periods,o=e.days,s=e.shortDays,a=e.months,l=e.shortMonths,u=kk(i),c=Ck(i),d=kk(o),h=Ck(o),m=kk(s),g=Ck(s),b=kk(a),v=Ck(a),w=kk(l),S=Ck(l),C={a:U,A:W,b:q,B:Y,c:null,d:zue,e:zue,f:GSt,g:rkt,G:okt,H:VSt,I:WSt,j:qSt,L:YRe,m:KSt,M:YSt,p:Q,q:G,Q:Hue,s:Uue,S:XSt,u:QSt,U:ZSt,V:JSt,w:ekt,W:tkt,x:null,X:null,y:nkt,Y:ikt,Z:skt,"%":Bue},E={a:le,A:K,b:te,B:de,c:null,d:Fue,e:Fue,f:ckt,g:xkt,G:Skt,H:akt,I:lkt,j:ukt,L:QRe,m:dkt,M:fkt,p:ue,q:ae,Q:Hue,s:Uue,S:hkt,u:pkt,U:mkt,V:gkt,w:ykt,W:bkt,x:null,X:null,y:vkt,Y:wkt,Z:kkt,"%":Bue},T={a:D,A:P,b:F,B:z,c:$,d:Due,e:Due,f:FSt,g:jue,G:Pue,H:$ue,I:$ue,j:jSt,L:zSt,m:PSt,M:DSt,p:I,q:ISt,Q:HSt,s:USt,S:$St,u:RSt,U:MSt,V:_St,w:OSt,W:NSt,x:B,X:H,y:jue,Y:Pue,Z:LSt,"%":BSt};C.x=O(n,C),C.X=O(r,C),C.c=O(t,C),E.x=O(n,E),E.X=O(r,E),E.c=O(t,E);function O(ie,he){return function(fe){var se=[],Se=-1,pe=0,Ee=ie.length,ke,Ie,Be;for(fe instanceof Date||(fe=new Date(+fe));++Se<Ee;)ie.charCodeAt(Se)===37&&(se.push(ie.slice(pe,Se)),(Ie=Iue[ke=ie.charAt(++Se)])!=null?ke=ie.charAt(++Se):Ie=ke==="e"?" ":"0",(Be=he[ke])&&(ke=Be(fe,Ie)),se.push(ke),pe=Se+1);return se.push(ie.slice(pe,Se)),se.join("")}}function M(ie,he){return function(fe){var se=Sk(1900,void 0,1),Se=N(se,ie,fe+="",0),pe,Ee;if(Se!=fe.length)return null;if("Q"in se)return new Date(se.Q);if("s"in se)return new Date(se.s*1e3+("L"in se?se.L:0));if(he&&!("Z"in se)&&(se.Z=0),"p"in se&&(se.H=se.H%12+se.p*12),se.m===void 0&&(se.m="q"in se?se.q:0),"V"in se){if(se.V<1||se.V>53)return null;"w"in se||(se.w=1),"Z"in se?(pe=X8(Sk(se.y,0,1)),Ee=pe.getUTCDay(),pe=Ee>4||Ee===0?tI.ceil(pe):tI(pe),pe=fA.offset(pe,(se.V-1)*7),se.y=pe.getUTCFullYear(),se.m=pe.getUTCMonth(),se.d=pe.getUTCDate()+(se.w+6)%7):(pe=Y8(Sk(se.y,0,1)),Ee=pe.getDay(),pe=Ee>4||Ee===0?eI.ceil(pe):eI(pe),pe=sS.offset(pe,(se.V-1)*7),se.y=pe.getFullYear(),se.m=pe.getMonth(),se.d=pe.getDate()+(se.w+6)%7)}else("W"in se||"U"in se)&&("w"in se||(se.w="u"in se?se.u%7:"W"in se?1:0),Ee="Z"in se?X8(Sk(se.y,0,1)).getUTCDay():Y8(Sk(se.y,0,1)).getDay(),se.m=0,se.d="W"in se?(se.w+6)%7+se.W*7-(Ee+5)%7:se.w+se.U*7-(Ee+6)%7);return"Z"in se?(se.H+=se.Z/100|0,se.M+=se.Z%100,X8(se)):Y8(se)}}function N(ie,he,fe,se){for(var Se=0,pe=he.length,Ee=fe.length,ke,Ie;Se<pe;){if(se>=Ee)return-1;if(ke=he.charCodeAt(Se++),ke===37){if(ke=he.charAt(Se++),Ie=T[ke in Iue?he.charAt(Se++):ke],!Ie||(se=Ie(ie,fe,se))<0)return-1}else if(ke!=fe.charCodeAt(se++))return-1}return se}function I(ie,he,fe){var se=u.exec(he.slice(fe));return se?(ie.p=c.get(se[0].toLowerCase()),fe+se[0].length):-1}function D(ie,he,fe){var se=m.exec(he.slice(fe));return se?(ie.w=g.get(se[0].toLowerCase()),fe+se[0].length):-1}function P(ie,he,fe){var se=d.exec(he.slice(fe));return se?(ie.w=h.get(se[0].toLowerCase()),fe+se[0].length):-1}function F(ie,he,fe){var se=w.exec(he.slice(fe));return se?(ie.m=S.get(se[0].toLowerCase()),fe+se[0].length):-1}function z(ie,he,fe){var se=b.exec(he.slice(fe));return se?(ie.m=v.get(se[0].toLowerCase()),fe+se[0].length):-1}function $(ie,he,fe){return N(ie,t,he,fe)}function B(ie,he,fe){return N(ie,n,he,fe)}function H(ie,he,fe){return N(ie,r,he,fe)}function U(ie){return s[ie.getDay()]}function W(ie){return o[ie.getDay()]}function q(ie){return l[ie.getMonth()]}function Y(ie){return a[ie.getMonth()]}function Q(ie){return i[+(ie.getHours()>=12)]}function G(ie){return 1+~~(ie.getMonth()/3)}function le(ie){return s[ie.getUTCDay()]}function K(ie){return o[ie.getUTCDay()]}function te(ie){return l[ie.getUTCMonth()]}function de(ie){return a[ie.getUTCMonth()]}function ue(ie){return i[+(ie.getUTCHours()>=12)]}function ae(ie){return 1+~~(ie.getUTCMonth()/3)}return{format:function(ie){var he=O(ie+="",C);return he.toString=function(){return ie},he},parse:function(ie){var he=M(ie+="",!1);return he.toString=function(){return ie},he},utcFormat:function(ie){var he=O(ie+="",E);return he.toString=function(){return ie},he},utcParse:function(ie){var he=M(ie+="",!0);return he.toString=function(){return ie},he}}}var Iue={"-":"",_:" ",0:"0"},Ho=/^\s*\d+/,ESt=/^%/,TSt=/[\\^$*+?|[\]().{}]/g;function ur(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 ASt(e){return e.replace(TSt,"\\$&")}function kk(e){return new RegExp("^(?:"+e.map(ASt).join("|")+")","i")}function Ck(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function OSt(e,t,n){var r=Ho.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function RSt(e,t,n){var r=Ho.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function MSt(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function _St(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function NSt(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function Pue(e,t,n){var r=Ho.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function jue(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function LSt(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 ISt(e,t,n){var r=Ho.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function PSt(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function Due(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function jSt(e,t,n){var r=Ho.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function $ue(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function DSt(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function $St(e,t,n){var r=Ho.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function zSt(e,t,n){var r=Ho.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function FSt(e,t,n){var r=Ho.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function BSt(e,t,n){var r=ESt.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function HSt(e,t,n){var r=Ho.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function USt(e,t,n){var r=Ho.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function zue(e,t){return ur(e.getDate(),t,2)}function VSt(e,t){return ur(e.getHours(),t,2)}function WSt(e,t){return ur(e.getHours()%12||12,t,2)}function qSt(e,t){return ur(1+sS.count(_d(e),e),t,3)}function YRe(e,t){return ur(e.getMilliseconds(),t,3)}function GSt(e,t){return YRe(e,t)+"000"}function KSt(e,t){return ur(e.getMonth()+1,t,2)}function YSt(e,t){return ur(e.getMinutes(),t,2)}function XSt(e,t){return ur(e.getSeconds(),t,2)}function QSt(e){var t=e.getDay();return t===0?7:t}function ZSt(e,t){return ur(hA.count(_d(e)-1,e),t,2)}function XRe(e){var t=e.getDay();return t>=4||t===0?nw(e):nw.ceil(e)}function JSt(e,t){return e=XRe(e),ur(nw.count(_d(e),e)+(_d(e).getDay()===4),t,2)}function ekt(e){return e.getDay()}function tkt(e,t){return ur(eI.count(_d(e)-1,e),t,2)}function nkt(e,t){return ur(e.getFullYear()%100,t,2)}function rkt(e,t){return e=XRe(e),ur(e.getFullYear()%100,t,2)}function ikt(e,t){return ur(e.getFullYear()%1e4,t,4)}function okt(e,t){var n=e.getDay();return e=n>=4||n===0?nw(e):nw.ceil(e),ur(e.getFullYear()%1e4,t,4)}function skt(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+ur(t/60|0,"0",2)+ur(t%60,"0",2)}function Fue(e,t){return ur(e.getUTCDate(),t,2)}function akt(e,t){return ur(e.getUTCHours(),t,2)}function lkt(e,t){return ur(e.getUTCHours()%12||12,t,2)}function ukt(e,t){return ur(1+fA.count(Nd(e),e),t,3)}function QRe(e,t){return ur(e.getUTCMilliseconds(),t,3)}function ckt(e,t){return QRe(e,t)+"000"}function dkt(e,t){return ur(e.getUTCMonth()+1,t,2)}function fkt(e,t){return ur(e.getUTCMinutes(),t,2)}function hkt(e,t){return ur(e.getUTCSeconds(),t,2)}function pkt(e){var t=e.getUTCDay();return t===0?7:t}function mkt(e,t){return ur(pA.count(Nd(e)-1,e),t,2)}function ZRe(e){var t=e.getUTCDay();return t>=4||t===0?rw(e):rw.ceil(e)}function gkt(e,t){return e=ZRe(e),ur(rw.count(Nd(e),e)+(Nd(e).getUTCDay()===4),t,2)}function ykt(e){return e.getUTCDay()}function bkt(e,t){return ur(tI.count(Nd(e)-1,e),t,2)}function vkt(e,t){return ur(e.getUTCFullYear()%100,t,2)}function xkt(e,t){return e=ZRe(e),ur(e.getUTCFullYear()%100,t,2)}function wkt(e,t){return ur(e.getUTCFullYear()%1e4,t,4)}function Skt(e,t){var n=e.getUTCDay();return e=n>=4||n===0?rw(e):rw.ceil(e),ur(e.getUTCFullYear()%1e4,t,4)}function kkt(){return"+0000"}function Bue(){return"%"}function Hue(e){return+e}function Uue(e){return Math.floor(+e/1e3)}var zv,JRe,eMe;Ckt({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 Ckt(e){return zv=CSt(e),JRe=zv.format,zv.parse,eMe=zv.utcFormat,zv.utcParse,zv}function Ekt(e){return new Date(e)}function Tkt(e){return e instanceof Date?+e:+new Date(+e)}function YY(e,t,n,r,i,o,s,a,l,u){var c=BY(),d=c.invert,h=c.domain,m=u(".%L"),g=u(":%S"),b=u("%I:%M"),v=u("%I %p"),w=u("%a %d"),S=u("%b %d"),C=u("%B"),E=u("%Y");function T(O){return(l(O)<O?m:a(O)<O?g:s(O)<O?b:o(O)<O?v:r(O)<O?i(O)<O?w:S:n(O)<O?C:E)(O)}return c.invert=function(O){return new Date(d(O))},c.domain=function(O){return arguments.length?h(Array.from(O,Tkt)):h().map(Ekt)},c.ticks=function(O){var M=h();return e(M[0],M[M.length-1],O??10)},c.tickFormat=function(O,M){return M==null?T:u(M)},c.nice=function(O){var M=h();return(!O||typeof O.range!="function")&&(O=t(M[0],M[M.length-1],O??10)),O?h(FRe(M,O)):c},c.copy=function(){return dA(c,YY(e,t,n,r,i,o,s,a,l,u))},c}function tMe(){return hu.apply(YY(SSt,kSt,_d,Zj,hA,sS,Xj,Kj,hh,JRe).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function Akt(){return hu.apply(YY(xSt,wSt,Nd,Jj,pA,fA,Qj,Yj,hh,eMe).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function eD(){var e=0,t=1,n,r,i,o,s=Gs,a=!1,l;function u(d){return d==null||isNaN(d=+d)?l:s(i===0?.5:(d=(o(d)-n)*i,a?Math.max(0,Math.min(1,d)):d))}u.domain=function(d){return arguments.length?([e,t]=d,n=o(e=+e),r=o(t=+t),i=n===r?0:1/(r-n),u):[e,t]},u.clamp=function(d){return arguments.length?(a=!!d,u):a},u.interpolator=function(d){return arguments.length?(s=d,u):s};function c(d){return function(h){var m,g;return arguments.length?([m,g]=h,s=d(m,g),u):[s(0),s(1)]}}return u.range=c(Ah),u.rangeRound=c(qj),u.unknown=function(d){return arguments.length?(l=d,u):l},function(d){return o=d,n=d(e),r=d(t),i=n===r?0:1/(r-n),u}}function Ug(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function nMe(){var e=Hg(eD()(Gs));return e.copy=function(){return Ug(e,nMe())},ep.apply(e,arguments)}function rMe(){var e=VY(eD()).domain([1,10]);return e.copy=function(){return Ug(e,rMe()).base(e.base())},ep.apply(e,arguments)}function iMe(){var e=WY(eD());return e.copy=function(){return Ug(e,iMe()).constant(e.constant())},ep.apply(e,arguments)}function XY(){var e=qY(eD());return e.copy=function(){return Ug(e,XY()).exponent(e.exponent())},ep.apply(e,arguments)}function Okt(){return XY.apply(null,arguments).exponent(.5)}function oMe(){var e=[],t=Gs;function n(r){if(r!=null&&!isNaN(r=+r))return t((uA(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(ug),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)=>nwt(e,o/r))},n.copy=function(){return oMe(t).domain(e)},ep.apply(n,arguments)}function tD(){var e=0,t=.5,n=1,r=1,i,o,s,a,l,u=Gs,c,d=!1,h;function m(b){return isNaN(b=+b)?h:(b=.5+((b=+c(b))-o)*(r*b<r*o?a:l),u(d?Math.max(0,Math.min(1,b)):b))}m.domain=function(b){return arguments.length?([e,t,n]=b,i=c(e=+e),o=c(t=+t),s=c(n=+n),a=i===o?0:.5/(o-i),l=o===s?0:.5/(s-o),r=o<i?-1:1,m):[e,t,n]},m.clamp=function(b){return arguments.length?(d=!!b,m):d},m.interpolator=function(b){return arguments.length?(u=b,m):u};function g(b){return function(v){var w,S,C;return arguments.length?([w,S,C]=v,u=Bwt(b,[w,S,C]),m):[u(0),u(.5),u(1)]}}return m.range=g(Ah),m.rangeRound=g(qj),m.unknown=function(b){return arguments.length?(h=b,m):h},function(b){return c=b,i=b(e),o=b(t),s=b(n),a=i===o?0:.5/(o-i),l=o===s?0:.5/(s-o),r=o<i?-1:1,m}}function sMe(){var e=Hg(tD()(Gs));return e.copy=function(){return Ug(e,sMe())},ep.apply(e,arguments)}function aMe(){var e=VY(tD()).domain([.1,1,10]);return e.copy=function(){return Ug(e,aMe()).base(e.base())},ep.apply(e,arguments)}function lMe(){var e=WY(tD());return e.copy=function(){return Ug(e,lMe()).constant(e.constant())},ep.apply(e,arguments)}function QY(){var e=qY(tD());return e.copy=function(){return Ug(e,QY()).exponent(e.exponent())},ep.apply(e,arguments)}function Rkt(){return QY.apply(null,arguments).exponent(.5)}function Mkt(e,t){t.domain&&("nice"in e||"quantiles"in e||"padding"in e,e.domain(t.domain))}function _kt(e,t){t.range&&("padding"in e,e.range(t.range))}function Nkt(e,t){"align"in e&&"align"in t&&typeof t.align<"u"&&e.align(t.align)}function Lkt(e,t){"base"in e&&"base"in t&&typeof t.base<"u"&&e.base(t.base)}function Ikt(e,t){"clamp"in e&&"clamp"in t&&typeof t.clamp<"u"&&e.clamp(t.clamp)}function Pkt(e,t){"constant"in e&&"constant"in t&&typeof t.constant<"u"&&e.constant(t.constant)}function jkt(e,t){"exponent"in e&&"exponent"in t&&typeof t.exponent<"u"&&e.exponent(t.exponent)}const Vue={lab:jwt,hcl:Dwt,"hcl-long":$wt,hsl:Iwt,"hsl-long":Pwt,cubehelix:zwt,"cubehelix-long":Fwt,rgb:XE};function Dkt(e){switch(e){case"lab":case"hcl":case"hcl-long":case"hsl":case"hsl-long":case"cubehelix":case"cubehelix-long":case"rgb":return Vue[e]}const{type:t,gamma:n}=e,r=Vue[t];return typeof n>"u"?r:r.gamma(n)}function $kt(e,t){if("interpolate"in t&&"interpolate"in e&&typeof t.interpolate<"u"){const n=Dkt(t.interpolate);e.interpolate(n)}}const zkt=new Date(Date.UTC(2020,1,2,3,4,5)),Fkt="%Y-%m-%d %H:%M";function Bkt(e){return e.tickFormat(1,Fkt)(zkt)==="2020-02-02 03:04"}const Wue={day:sS,hour:Xj,minute:Kj,month:Zj,second:hh,week:hA,year:_d},que={day:fA,hour:Qj,minute:Yj,month:Jj,second:hh,week:pA,year:Nd};function Hkt(e,t){if("nice"in t&&typeof t.nice<"u"&&"nice"in e){const{nice:n}=t;if(typeof n=="boolean")n&&e.nice();else if(typeof n=="number")e.nice(n);else{const r=e,i=Bkt(r);if(typeof n=="string")r.nice(i?que[n]:Wue[n]);else{const{interval:o,step:s}=n,a=(i?que[o]:Wue[o]).every(s);a!=null&&r.nice(a)}}}}function Ukt(e,t){"padding"in e&&"padding"in t&&typeof t.padding<"u"&&e.padding(t.padding),"paddingInner"in e&&"paddingInner"in t&&typeof t.paddingInner<"u"&&e.paddingInner(t.paddingInner),"paddingOuter"in e&&"paddingOuter"in t&&typeof t.paddingOuter<"u"&&e.paddingOuter(t.paddingOuter)}function Vkt(e,t){if(t.reverse){const n=e.range().slice().reverse();"padding"in e,e.range(n)}}function Wkt(e,t){"round"in t&&typeof t.round<"u"&&(t.round&&"interpolate"in t&&typeof t.interpolate<"u"?console.warn("[visx/scale/applyRound] ignoring round: scale config contains round and interpolate. only applying interpolate. config:",t):"round"in e?e.round(t.round):"interpolate"in e&&t.round&&e.interpolate(qj))}function qkt(e,t){"unknown"in e&&"unknown"in t&&typeof t.unknown<"u"&&e.unknown(t.unknown)}function Gkt(e,t){if("zero"in t&&t.zero===!0){const n=e.domain(),[r,i]=n,o=i<r,[s,a]=o?[i,r]:[r,i],l=[Math.min(0,s),Math.max(0,a)];e.domain(o?l.reverse():l)}}const Kkt=["domain","nice","zero","interpolate","round","range","reverse","align","base","clamp","constant","exponent","padding","unknown"],Ykt={domain:Mkt,nice:Hkt,zero:Gkt,interpolate:$kt,round:Wkt,align:Nkt,base:Lkt,clamp:Ikt,constant:Pkt,exponent:jkt,padding:Ukt,range:_kt,reverse:Vkt,unknown:qkt};function ZY(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];const r=new Set(t),i=Kkt.filter(o=>r.has(o));return function(s,a){return typeof a<"u"&&i.forEach(l=>{Ykt[l](s,a)}),s}}const Xkt=ZY("domain","range","reverse","align","padding","round");function Qkt(e){return Xkt(Jx(),e)}const Zkt=ZY("domain","range","reverse","clamp","interpolate","nice","round","zero");function Hh(e){return Zkt(ZE(),e)}const Jkt=ZY("domain","range","reverse","clamp","interpolate","nice","round");function eCt(e){return Jkt(tMe(),e)}function uMe(e){if((typeof e=="function"||typeof e=="object"&&e)&&"valueOf"in e){const t=e.valueOf();if(typeof t=="number")return t}return e}function cMe(e,t){const n=e;return"ticks"in n?n.ticks(t):n.domain().filter((r,i,o)=>t==null||o.length<=t||i%Math.round((o.length-1)/t)===0)}const Yu="left";function ph(e){return e==null||e===""?Yu:String(e)}function nD(e){const t=new Map;for(const n of e){const r=ph(n.yAxisId),i=t.get(r)??[];i.push(n),t.set(r,i)}return t}function dMe(e,t){const n=e[Yu];return n||(Object.values(e)[0]??t)}function tCt({lines:e,innerHeight:t,resolveDomain:n}){const r=nD(e),i={};for(const[o,s]of r){const a=s.map(u=>u.dataKey),l=n(a);i[o]=Hh({range:[t,0],domain:l,nice:!0})}return i[Yu]||(i[Yu]=Hh({range:[t,0],domain:[0,100],nice:!0})),i}function nCt({lines:e,innerHeight:t,domainsByAxis:n}){const r=nD(e),i={};for(const[o]of r){const s=n[o]??n[Yu]??[0,100];i[o]=Hh({range:[t,0],domain:s})}return i[Yu]||(i[Yu]=Hh({range:[t,0],domain:n[Yu]??[0,100]})),i}function rCt(e){return{[Yu]:e}}const Bo={background:"var(--chart-background)",foreground:"var(--chart-foreground)",foregroundMuted:"var(--chart-foreground-muted)",linePrimary:"var(--chart-line-primary)",crosshair:"var(--chart-crosshair)",grid:"var(--chart-grid)",tooltipBackground:"var(--chart-tooltip-background)"},Q8=["var(--chart-1)","var(--chart-2)","var(--chart-3)","var(--chart-4)","var(--chart-5)"],fMe=A.createContext(null),hMe=A.createContext(null);function pMe({children:e,value:t}){const n=A.useMemo(()=>({data:t.data,renderData:t.renderData,xScale:t.xScale,yScale:t.yScale,yScales:t.yScales,width:t.width,height:t.height,innerWidth:t.innerWidth,innerHeight:t.innerHeight,margin:t.margin,columnWidth:t.columnWidth,containerRef:t.containerRef,lines:t.lines,referenceAreas:t.referenceAreas,chartPhase:t.chartPhase,chartStatus:t.chartStatus,loadingLabel:t.loadingLabel,yDomainTweenDuration:t.yDomainTweenDuration,yDomainSkeletonByAxis:t.yDomainSkeletonByAxis,yDomainTargetByAxis:t.yDomainTargetByAxis,isLoaded:t.isLoaded,animationDuration:t.animationDuration,animationEasing:t.animationEasing,enterTransition:t.enterTransition,revealEpoch:t.revealEpoch,notifyLoadingPulseComplete:t.notifyLoadingPulseComplete,xAccessor:t.xAccessor,dateLabels:t.dateLabels,xDomain:t.xDomain,xDomainSlotCount:t.xDomainSlotCount,barScale:t.barScale,bandWidth:t.bandWidth,barXAccessor:t.barXAccessor,orientation:t.orientation,stacked:t.stacked,stackOffsets:t.stackOffsets,composedBarDataKeys:t.composedBarDataKeys,composedBarSize:t.composedBarSize,composedMaxBarSize:t.composedMaxBarSize,composedBarGap:t.composedBarGap,composedStacked:t.composedStacked,composedStackOffsets:t.composedStackOffsets,composedStackGap:t.composedStackGap}),[t.data,t.renderData,t.xScale,t.yScale,t.yScales,t.width,t.height,t.innerWidth,t.innerHeight,t.margin,t.columnWidth,t.containerRef,t.lines,t.referenceAreas,t.chartPhase,t.chartStatus,t.loadingLabel,t.yDomainTweenDuration,t.yDomainSkeletonByAxis,t.yDomainTargetByAxis,t.isLoaded,t.animationDuration,t.animationEasing,t.enterTransition,t.revealEpoch,t.notifyLoadingPulseComplete,t.xAccessor,t.dateLabels,t.xDomain,t.xDomainSlotCount,t.barScale,t.bandWidth,t.barXAccessor,t.orientation,t.stacked,t.stackOffsets,t.composedBarDataKeys,t.composedBarSize,t.composedMaxBarSize,t.composedBarGap,t.composedStacked,t.composedStackOffsets,t.composedStackGap]),r=A.useMemo(()=>({tooltipData:t.tooltipData,setTooltipData:t.setTooltipData,selection:t.selection,clearSelection:t.clearSelection,hoveredBarIndex:t.hoveredBarIndex,setHoveredBarIndex:t.setHoveredBarIndex,hoveredCandleIndex:t.hoveredCandleIndex,setHoveredCandleIndex:t.setHoveredCandleIndex}),[t.tooltipData,t.setTooltipData,t.selection,t.clearSelection,t.hoveredBarIndex,t.setHoveredBarIndex,t.hoveredCandleIndex,t.setHoveredCandleIndex]);return y.jsx(fMe.Provider,{value:n,children:y.jsx(hMe.Provider,{value:r,children:e})})}function _a(){const e=A.useContext(fMe);if(!e)throw new Error("useChartStable must be used within a ChartProvider. Make sure your component is wrapped in <LineChart>, <AreaChart>, <BarChart>, or <ComposedChart>.");return e}function mA(e){const{yScales:t,yScale:n}=_a(),r=e==null||e===""?Yu:String(e);return t[r]??n}function gA(){const e=A.useContext(hMe);if(!e)throw new Error("useChartHover must be used within a ChartProvider. Make sure your component is wrapped in <LineChart>, <AreaChart>, <BarChart>, or <ComposedChart>.");return e}function JY(){const e=_a(),t=gA();return{...e,...t}}const eX=A.createContext({});function yA(e){const t=A.useRef(null);return t.current===null&&(t.current=e()),t.current}const iCt=typeof window<"u",rD=iCt?A.useLayoutEffect:A.useEffect,iD=A.createContext(null);function tX(e,t){e.indexOf(t)===-1&&e.push(t)}function iw(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const Ld=(e,t,n)=>n>t?t:n<e?e:n;let oD=()=>{};const Eg={},mMe=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),gMe=e=>typeof e=="object"&&e!==null,yMe=e=>/^0[^.\s]+$/u.test(e);function bMe(e){let t;return()=>(t===void 0&&(t=e()),t)}const su=e=>e,bA=(...e)=>e.reduce((t,n)=>r=>n(t(r))),ow=(e,t,n)=>{const r=t-e;return r?(n-e)/r:1};class nX{constructor(){this.subscriptions=[]}add(t){return tX(this.subscriptions,t),()=>iw(this.subscriptions,t)}notify(t,n,r){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](t,n,r);else for(let o=0;o<i;o++){const s=this.subscriptions[o];s&&s(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const Sa=e=>e*1e3,eu=e=>e/1e3,vMe=(e,t)=>t?e*(1e3/t):0,oCt=(e,t,n)=>{const r=t-e;return((n-e)%r+r)%r+e},xMe=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,sCt=1e-7,aCt=12;function lCt(e,t,n,r,i){let o,s,a=0;do s=t+(n-t)/2,o=xMe(s,r,i)-e,o>0?n=s:t=s;while(Math.abs(o)>sCt&&++a<aCt);return s}function vA(e,t,n,r){if(e===t&&n===r)return su;const i=o=>lCt(o,0,1,e,n);return o=>o===0||o===1?o:xMe(i(o),t,r)}const wMe=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,rX=e=>t=>1-e(1-t),SMe=vA(.33,1.53,.69,.99),iX=rX(SMe),kMe=wMe(iX),CMe=e=>e>=1?1:(e*=2)<1?.5*iX(e):.5*(2-Math.pow(2,-10*(e-1))),oX=e=>1-Math.sin(Math.acos(e)),EMe=rX(oX),TMe=wMe(oX),uCt=vA(.42,0,1,1),cCt=vA(0,0,.58,1),AMe=vA(.42,0,.58,1),OMe=e=>Array.isArray(e)&&typeof e[0]!="number";function RMe(e,t){return OMe(e)?e[oCt(0,e.length,t)]:e}const MMe=e=>Array.isArray(e)&&typeof e[0]=="number",dCt={linear:su,easeIn:uCt,easeInOut:AMe,easeOut:cCt,circIn:oX,circInOut:TMe,circOut:EMe,backIn:iX,backInOut:kMe,backOut:SMe,anticipate:CMe},fCt=e=>typeof e=="string",Gue=e=>{if(MMe(e)){oD(e.length===4);const[t,n,r,i]=e;return vA(t,n,r,i)}else if(fCt(e))return dCt[e];return e},sM=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function hCt(e){let t=new Set,n=new Set,r=!1,i=!1;const o=new WeakSet;let s={delta:0,timestamp:0,isProcessing:!1};function a(u){o.has(u)&&(l.schedule(u),e()),u(s)}const l={schedule:(u,c=!1,d=!1)=>{const m=d&&r?t:n;return c&&o.add(u),m.add(u),u},cancel:u=>{n.delete(u),o.delete(u)},process:u=>{if(s=u,r){i=!0;return}r=!0;const c=t;t=n,n=c,t.forEach(a),t.clear(),r=!1,i&&(i=!1,l.process(u))}};return l}const pCt=40;function _Me(e,t){let n=!1,r=!0;const i={delta:0,timestamp:0,isProcessing:!1},o=()=>n=!0,s=sM.reduce((C,E)=>(C[E]=hCt(o),C),{}),{setup:a,read:l,resolveKeyframes:u,preUpdate:c,update:d,preRender:h,render:m,postRender:g}=s,b=()=>{const C=Eg.useManualTiming,E=C?i.timestamp:performance.now();n=!1,C||(i.delta=r?1e3/60:Math.max(Math.min(E-i.timestamp,pCt),1)),i.timestamp=E,i.isProcessing=!0,a.process(i),l.process(i),u.process(i),c.process(i),d.process(i),h.process(i),m.process(i),g.process(i),i.isProcessing=!1,n&&t&&(r=!1,e(b))},v=()=>{n=!0,r=!0,i.isProcessing||e(b)};return{schedule:sM.reduce((C,E)=>{const T=s[E];return C[E]=(O,M=!1,N=!1)=>(n||v(),T.schedule(O,M,N)),C},{}),cancel:C=>{for(let E=0;E<sM.length;E++)s[sM[E]].cancel(C)},state:i,steps:s}}const{schedule:Rr,cancel:Uh,state:es,steps:Z8}=_Me(typeof requestAnimationFrame<"u"?requestAnimationFrame:su,!0);let C_;function mCt(){C_=void 0}const Ks={now:()=>(C_===void 0&&Ks.set(es.isProcessing||Eg.useManualTiming?es.timestamp:performance.now()),C_),set:e=>{C_=e,queueMicrotask(mCt)}},NMe=e=>t=>typeof t=="string"&&t.startsWith(e),LMe=NMe("--"),gCt=NMe("var(--"),sX=e=>gCt(e)?yCt.test(e.split("/*")[0].trim()):!1,yCt=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function Kue(e){return typeof e!="string"?!1:e.split("/*")[0].includes("var(--")}const aS={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},JE={...aS,transform:e=>Ld(0,1,e)},aM={...aS,default:1},KC=e=>Math.round(e*1e5)/1e5,aX=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function bCt(e){return e==null}const vCt=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,lX=(e,t)=>n=>!!(typeof n=="string"&&vCt.test(n)&&n.startsWith(e)||t&&!bCt(n)&&Object.prototype.hasOwnProperty.call(n,t)),IMe=(e,t,n)=>r=>{if(typeof r!="string")return r;const[i,o,s,a]=r.match(aX);return{[e]:parseFloat(i),[t]:parseFloat(o),[n]:parseFloat(s),alpha:a!==void 0?parseFloat(a):1}},xCt=e=>Ld(0,255,e),J8={...aS,transform:e=>Math.round(xCt(e))},oy={test:lX("rgb","red"),parse:IMe("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+J8.transform(e)+", "+J8.transform(t)+", "+J8.transform(n)+", "+KC(JE.transform(r))+")"};function wCt(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}const hV={test:lX("#"),parse:wCt,transform:oy.transform},xA=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Tf=xA("deg"),Cd=xA("%"),Dt=xA("px"),SCt=xA("vh"),kCt=xA("vw"),Yue={...Cd,parse:e=>Cd.parse(e)/100,transform:e=>Cd.transform(e*100)},v1={test:lX("hsl","hue"),parse:IMe("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+Cd.transform(KC(t))+", "+Cd.transform(KC(n))+", "+KC(JE.transform(r))+")"},Yi={test:e=>oy.test(e)||hV.test(e)||v1.test(e),parse:e=>oy.test(e)?oy.parse(e):v1.test(e)?v1.parse(e):hV.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?oy.transform(e):v1.transform(e),getAnimatableNone:e=>{const t=Yi.parse(e);return t.alpha=0,Yi.transform(t)}},CCt=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function ECt(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(aX))==null?void 0:t.length)||0)+(((n=e.match(CCt))==null?void 0:n.length)||0)>0}const PMe="number",jMe="color",TCt="var",ACt="var(",Xue="${}",OCt=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function sw(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},i=[];let o=0;const a=t.replace(OCt,l=>(Yi.test(l)?(r.color.push(o),i.push(jMe),n.push(Yi.parse(l))):l.startsWith(ACt)?(r.var.push(o),i.push(TCt),n.push(l)):(r.number.push(o),i.push(PMe),n.push(parseFloat(l))),++o,Xue)).split(Xue);return{values:n,split:a,indexes:r,types:i}}function RCt(e){return sw(e).values}function DMe({split:e,types:t}){const n=e.length;return r=>{let i="";for(let o=0;o<n;o++)if(i+=e[o],r[o]!==void 0){const s=t[o];s===PMe?i+=KC(r[o]):s===jMe?i+=Yi.transform(r[o]):i+=r[o]}return i}}function MCt(e){return DMe(sw(e))}const _Ct=e=>typeof e=="number"?0:Yi.test(e)?Yi.getAnimatableNone(e):e,NCt=(e,t)=>typeof e=="number"?t!=null&&t.trim().endsWith("/")?e:0:_Ct(e);function LCt(e){const t=sw(e);return DMe(t)(t.values.map((r,i)=>NCt(r,t.split[i])))}const nc={test:ECt,parse:RCt,createTransformer:MCt,getAnimatableNone:LCt};function e$(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function ICt({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,o=0,s=0;if(!t)i=o=s=n;else{const a=n<.5?n*(1+t):n+t-n*t,l=2*n-a;i=e$(l,a,e+1/3),o=e$(l,a,e),s=e$(l,a,e-1/3)}return{red:Math.round(i*255),green:Math.round(o*255),blue:Math.round(s*255),alpha:r}}function nI(e,t){return n=>n>0?t:e}const jr=(e,t,n)=>e+(t-e)*n,t$=(e,t,n)=>{const r=e*e,i=n*(t*t-r)+r;return i<0?0:Math.sqrt(i)},PCt=[hV,oy,v1],jCt=e=>PCt.find(t=>t.test(e));function Que(e){const t=jCt(e);if(!t)return!1;let n=t.parse(e);return t===v1&&(n=ICt(n)),n}const Zue=(e,t)=>{const n=Que(e),r=Que(t);if(!n||!r)return nI(e,t);const i={...n};return o=>(i.red=t$(n.red,r.red,o),i.green=t$(n.green,r.green,o),i.blue=t$(n.blue,r.blue,o),i.alpha=jr(n.alpha,r.alpha,o),oy.transform(i))},pV=new Set(["none","hidden"]);function DCt(e,t){return pV.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function $Ct(e,t){return n=>jr(e,t,n)}function uX(e){return typeof e=="number"?$Ct:typeof e=="string"?sX(e)?nI:Yi.test(e)?Zue:BCt:Array.isArray(e)?$Me:typeof e=="object"?Yi.test(e)?Zue:zCt:nI}function $Me(e,t){const n=[...e],r=n.length,i=e.map((o,s)=>uX(o)(o,t[s]));return o=>{for(let s=0;s<r;s++)n[s]=i[s](o);return n}}function zCt(e,t){const n={...e,...t},r={};for(const i in n)e[i]!==void 0&&t[i]!==void 0&&(r[i]=uX(e[i])(e[i],t[i]));return i=>{for(const o in r)n[o]=r[o](i);return n}}function FCt(e,t){const n=[],r={color:0,var:0,number:0};for(let i=0;i<t.values.length;i++){const o=t.types[i],s=e.indexes[o][r[o]],a=e.values[s]??0;n[i]=a,r[o]++}return n}const BCt=(e,t)=>{const n=nc.createTransformer(t),r=sw(e),i=sw(t);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?pV.has(e)&&!i.values.length||pV.has(t)&&!r.values.length?DCt(e,t):bA($Me(FCt(r,i),i.values),n):nI(e,t)};function zMe(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?jr(e,t,n):uX(e)(e,t)}const HCt=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>Rr.update(t,n),stop:()=>Uh(t),now:()=>es.isProcessing?es.timestamp:Ks.now()}},FMe=(e,t,n=10)=>{let r="";const i=Math.max(Math.round(t/n),2);for(let o=0;o<i;o++)r+=Math.round(e(o/(i-1))*1e4)/1e4+", ";return`linear(${r.substring(0,r.length-2)})`},rI=2e4;function cX(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<rI;)t+=n,r=e.next(t);return t>=rI?1/0:t}function BMe(e,t=100,n){const r=n({...e,keyframes:[0,t]}),i=Math.min(cX(r),rI);return{type:"keyframes",ease:o=>r.next(i*o).value/t,duration:eu(i)}}const wi={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};function mV(e,t){return e*Math.sqrt(1-t*t)}const UCt=12;function VCt(e,t,n){let r=n;for(let i=1;i<UCt;i++)r=r-e(r)/t(r);return r}const n$=.001;function WCt({duration:e=wi.duration,bounce:t=wi.bounce,velocity:n=wi.velocity,mass:r=wi.mass}){let i,o,s=1-t;s=Ld(wi.minDamping,wi.maxDamping,s),e=Ld(wi.minDuration,wi.maxDuration,eu(e)),s<1?(i=u=>{const c=u*s,d=c*e,h=c-n,m=mV(u,s),g=Math.exp(-d);return n$-h/m*g},o=u=>{const d=u*s*e,h=d*n+n,m=Math.pow(s,2)*Math.pow(u,2)*e,g=Math.exp(-d),b=mV(Math.pow(u,2),s);return(-i(u)+n$>0?-1:1)*((h-m)*g)/b}):(i=u=>{const c=Math.exp(-u*e),d=(u-n)*e+1;return-n$+c*d},o=u=>{const c=Math.exp(-u*e),d=(n-u)*(e*e);return c*d});const a=5/e,l=VCt(i,o,a);if(e=Sa(e),isNaN(l))return{stiffness:wi.stiffness,damping:wi.damping,duration:e};{const u=Math.pow(l,2)*r;return{stiffness:u,damping:s*2*Math.sqrt(r*u),duration:e}}}const qCt=["duration","bounce"],GCt=["stiffness","damping","mass"];function Jue(e,t){return t.some(n=>e[n]!==void 0)}function KCt(e){let t={velocity:wi.velocity,stiffness:wi.stiffness,damping:wi.damping,mass:wi.mass,isResolvedFromDuration:!1,...e};if(!Jue(e,GCt)&&Jue(e,qCt))if(t.velocity=0,e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),i=r*r,o=2*Ld(.05,1,1-(e.bounce||0))*Math.sqrt(i);t={...t,mass:wi.mass,stiffness:i,damping:o}}else{const n=WCt({...e,velocity:0});t={...t,...n,mass:wi.mass},t.isResolvedFromDuration=!0}return t}function eT(e=wi.visualDuration,t=wi.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:i}=n;const o=n.keyframes[0],s=n.keyframes[n.keyframes.length-1],a={done:!1,value:o},{stiffness:l,damping:u,mass:c,duration:d,velocity:h,isResolvedFromDuration:m}=KCt({...n,velocity:-eu(n.velocity||0)}),g=h||0,b=u/(2*Math.sqrt(l*c)),v=s-o,w=eu(Math.sqrt(l/c)),S=Math.abs(v)<5;r||(r=S?wi.restSpeed.granular:wi.restSpeed.default),i||(i=S?wi.restDelta.granular:wi.restDelta.default);let C,E,T,O,M,N;if(b<1)T=mV(w,b),O=(g+b*w*v)/T,C=D=>{const P=Math.exp(-b*w*D);return s-P*(O*Math.sin(T*D)+v*Math.cos(T*D))},M=b*w*O+v*T,N=b*w*v-O*T,E=D=>Math.exp(-b*w*D)*(M*Math.sin(T*D)+N*Math.cos(T*D));else if(b===1){C=P=>s-Math.exp(-w*P)*(v+(g+w*v)*P);const D=g+w*v;E=P=>Math.exp(-w*P)*(w*D*P-g)}else{const D=w*Math.sqrt(b*b-1);C=$=>{const B=Math.exp(-b*w*$),H=Math.min(D*$,300);return s-B*((g+b*w*v)*Math.sinh(H)+D*v*Math.cosh(H))/D};const P=(g+b*w*v)/D,F=b*w*P-v*D,z=b*w*v-P*D;E=$=>{const B=Math.exp(-b*w*$),H=Math.min(D*$,300);return B*(F*Math.sinh(H)+z*Math.cosh(H))}}const I={calculatedDuration:m&&d||null,velocity:D=>Sa(E(D)),next:D=>{if(!m&&b<1){const F=Math.exp(-b*w*D),z=Math.sin(T*D),$=Math.cos(T*D),B=s-F*(O*z+v*$),H=Sa(F*(M*z+N*$));return a.done=Math.abs(H)<=r&&Math.abs(s-B)<=i,a.value=a.done?s:B,a}const P=C(D);if(m)a.done=D>=d;else{const F=Sa(E(D));a.done=Math.abs(F)<=r&&Math.abs(s-P)<=i}return a.value=a.done?s:P,a},toString:()=>{const D=Math.min(cX(I),rI),P=FMe(F=>I.next(D*F).value,D,30);return D+"ms "+P},toTransition:()=>{}};return I}eT.applyToOptions=e=>{const t=BMe(e,100,eT);return e.ease=t.ease,e.duration=Sa(t.duration),e.type="keyframes",e};const YCt=5;function HMe(e,t,n){const r=Math.max(t-YCt,0);return vMe(n-e(r),t-r)}function gV({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:o=500,modifyTarget:s,min:a,max:l,restDelta:u=.5,restSpeed:c}){const d=e[0],h={done:!1,value:d},m=N=>a!==void 0&&N<a||l!==void 0&&N>l,g=N=>a===void 0?l:l===void 0||Math.abs(a-N)<Math.abs(l-N)?a:l;let b=n*t;const v=d+b,w=s===void 0?v:s(v);w!==v&&(b=w-d);const S=N=>-b*Math.exp(-N/r),C=N=>w+S(N),E=N=>{const I=S(N),D=C(N);h.done=Math.abs(I)<=u,h.value=h.done?w:D};let T,O;const M=N=>{m(h.value)&&(T=N,O=eT({keyframes:[h.value,g(h.value)],velocity:HMe(C,N,h.value),damping:i,stiffness:o,restDelta:u,restSpeed:c}))};return M(0),{calculatedDuration:null,next:N=>{let I=!1;return!O&&T===void 0&&(I=!0,E(N),M(N)),T!==void 0&&N>=T?O.next(N-T):(!I&&E(N),h)}}}function XCt(e,t,n){const r=[],i=n||Eg.mix||zMe,o=e.length-1;for(let s=0;s<o;s++){let a=i(e[s],e[s+1]);if(t){const l=Array.isArray(t)?t[s]||su:t;a=bA(l,a)}r.push(a)}return r}function UMe(e,t,{clamp:n=!0,ease:r,mixer:i}={}){const o=e.length;if(oD(o===t.length),o===1)return()=>t[0];if(o===2&&t[0]===t[1])return()=>t[1];const s=e[0]===e[1];e[0]>e[o-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=XCt(t,r,i),l=a.length,u=c=>{if(s&&c<e[0])return t[0];let d=0;if(l>1)for(;d<e.length-2&&!(c<e[d+1]);d++);const h=ow(e[d],e[d+1],c);return a[d](h)};return n?c=>u(Ld(e[0],e[o-1],c)):u}function VMe(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const i=ow(0,t,r);e.push(jr(n,1,i))}}function WMe(e){const t=[0];return VMe(t,e.length-1),t}function QCt(e,t){return e.map(n=>n*t)}function ZCt(e,t){return e.map(()=>t||AMe).splice(0,e.length-1)}function YC({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const i=OMe(r)?r.map(Gue):Gue(r),o={done:!1,value:t[0]},s=QCt(n&&n.length===t.length?n:WMe(t),e),a=UMe(s,t,{ease:Array.isArray(i)?i:ZCt(t,i)});return{calculatedDuration:e,next:l=>(o.value=a(l),o.done=l>=e,o)}}const JCt=e=>e!==null;function sD(e,{repeat:t,repeatType:n="loop"},r,i=1){const o=e.filter(JCt),a=i<0||t&&n!=="loop"&&t%2===1?0:o.length-1;return!a||r===void 0?o[a]:r}const eEt={decay:gV,inertia:gV,tween:YC,keyframes:YC,spring:eT};function qMe(e){typeof e.type=="string"&&(e.type=eEt[e.type])}class dX{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const tEt=e=>e/100;class tT extends dX{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.delayState={done:!1,value:void 0},this.stop=()=>{var r,i;const{motionValue:n}=this.options;n&&n.updatedAt!==Ks.now()&&this.tick(Ks.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(i=(r=this.options).onStop)==null||i.call(r))},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;qMe(t);const{type:n=YC,repeat:r=0,repeatDelay:i=0,repeatType:o,velocity:s=0}=t;let{keyframes:a}=t;const l=n||YC;l!==YC&&typeof a[0]!="number"&&(this.mixKeyframes=bA(tEt,zMe(a[0],a[1])),a=[0,100]);const u=l({...t,keyframes:a});o==="mirror"&&(this.mirroredGenerator=l({...t,keyframes:[...a].reverse(),velocity:-s})),u.calculatedDuration===null&&(u.calculatedDuration=cX(u));const{calculatedDuration:c}=u;this.calculatedDuration=c,this.resolvedDuration=c+i,this.totalDuration=this.resolvedDuration*(r+1)-i,this.generator=u}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:r,totalDuration:i,mixKeyframes:o,mirroredGenerator:s,resolvedDuration:a,calculatedDuration:l}=this;if(this.startTime===null)return r.next(0);const{delay:u=0,keyframes:c,repeat:d,repeatType:h,repeatDelay:m,type:g,onUpdate:b,finalKeyframe:v}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-i/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const w=this.currentTime-u*(this.playbackSpeed>=0?1:-1),S=this.playbackSpeed>=0?w<0:w>i;this.currentTime=Math.max(w,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=i);let C=this.currentTime,E=r;if(d){const N=Math.min(this.currentTime,i)/a;let I=Math.floor(N),D=N%1;!D&&N>=1&&(D=1),D===1&&I--,I=Math.min(I,d+1),!!(I%2)&&(h==="reverse"?(D=1-D,m&&(D-=m/a)):h==="mirror"&&(E=s)),C=Ld(0,1,D)*a}let T;S?(this.delayState.value=c[0],T=this.delayState):T=E.next(C),o&&!S&&(T.value=o(T.value));let{done:O}=T;!S&&l!==null&&(O=this.playbackSpeed>=0?this.currentTime>=i:this.currentTime<=0);const M=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&O);return M&&g!==gV&&(T.value=sD(c,this.options,v,this.speed)),b&&b(T.value),M&&this.finish(),T}then(t,n){return this.finished.then(t,n)}get duration(){return eu(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+eu(t)}get time(){return eu(this.currentTime)}set time(t){t=Sa(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?this.driver.start(!1):(this.startTime=0,this.state="paused",this.holdTime=t,this.tick(t))}getGeneratorVelocity(){const t=this.currentTime;if(t<=0)return this.options.velocity||0;if(this.generator.velocity)return this.generator.velocity(t);const n=this.generator.next(t).value;return HMe(r=>this.generator.next(r).value,t,n)}get speed(){return this.playbackSpeed}set speed(t){const n=this.playbackSpeed!==t;n&&this.driver&&this.updateTime(Ks.now()),this.playbackSpeed=t,n&&this.driver&&(this.time=eu(this.currentTime))}play(){var i,o;if(this.isStopped)return;const{driver:t=HCt,startTime:n}=this.options;this.driver||(this.driver=t(s=>this.tick(s))),(o=(i=this.options).onPlay)==null||o.call(i);const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=n??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(Ks.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var t,n;this.notifyFinished(),this.teardown(),this.state="finished",(n=(t=this.options).onComplete)==null||n.call(t)}cancel(){var t,n;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(n=(t=this.options).onCancel)==null||n.call(t)}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){var n;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(n=this.driver)==null||n.stop(),t.observe(this)}}function nEt(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const sy=e=>e*180/Math.PI,yV=e=>{const t=sy(Math.atan2(e[1],e[0]));return bV(t)},rEt={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:yV,rotateZ:yV,skewX:e=>sy(Math.atan(e[1])),skewY:e=>sy(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},bV=e=>(e=e%360,e<0&&(e+=360),e),ece=yV,tce=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),nce=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),iEt={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:tce,scaleY:nce,scale:e=>(tce(e)+nce(e))/2,rotateX:e=>bV(sy(Math.atan2(e[6],e[5]))),rotateY:e=>bV(sy(Math.atan2(-e[2],e[0]))),rotateZ:ece,rotate:ece,skewX:e=>sy(Math.atan(e[4])),skewY:e=>sy(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function vV(e){return e.includes("scale")?1:0}function xV(e,t){if(!e||e==="none")return vV(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,i;if(n)r=iEt,i=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=rEt,i=a}if(!i)return vV(t);const o=r[t],s=i[1].split(",").map(sEt);return typeof o=="function"?o(s):s[o]}const oEt=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return xV(n,t)};function sEt(e){return parseFloat(e.trim())}const lS=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],uS=new Set([...lS,"pathRotation"]),rce=e=>e===aS||e===Dt,aEt=new Set(["x","y","z"]),lEt=lS.filter(e=>!aEt.has(e));function uEt(e){const t=[];return lEt.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const Ym={width:({x:e},{paddingLeft:t="0",paddingRight:n="0",boxSizing:r})=>{const i=e.max-e.min;return r==="border-box"?i:i-parseFloat(t)-parseFloat(n)},height:({y:e},{paddingTop:t="0",paddingBottom:n="0",boxSizing:r})=>{const i=e.max-e.min;return r==="border-box"?i:i-parseFloat(t)-parseFloat(n)},top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>xV(t,"x"),y:(e,{transform:t})=>xV(t,"y")};Ym.translateX=Ym.x;Ym.translateY=Ym.y;const Jy=new Set;let wV=!1,SV=!1,kV=!1;function GMe(){if(SV){const e=Array.from(Jy).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const i=uEt(r);i.length&&(n.set(r,i),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const i=n.get(r);i&&i.forEach(([o,s])=>{var a;(a=r.getValue(o))==null||a.set(s)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}SV=!1,wV=!1,Jy.forEach(e=>e.complete(kV)),Jy.clear()}function KMe(){Jy.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(SV=!0)})}function cEt(){kV=!0,KMe(),GMe(),kV=!1}class fX{constructor(t,n,r,i,o,s=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=i,this.element=o,this.isAsync=s}scheduleResolve(){this.state="scheduled",this.isAsync?(Jy.add(this),wV||(wV=!0,Rr.read(KMe),Rr.resolveKeyframes(GMe))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:i}=this;if(t[0]===null){const o=i==null?void 0:i.get(),s=t[t.length-1];if(o!==void 0)t[0]=o;else if(r&&n){const a=r.readValue(n,s);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=s),i&&o===void 0&&i.set(t[0])}nEt(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),Jy.delete(this)}cancel(){this.state==="scheduled"&&(Jy.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const dEt=e=>e.startsWith("--");function YMe(e,t,n){dEt(t)?e.style.setProperty(t,n):e.style[t]=n}const fEt={};function XMe(e,t){const n=bMe(e);return()=>fEt[t]??n()}const hEt=XMe(()=>window.ScrollTimeline!==void 0,"scrollTimeline"),QMe=XMe(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),fC=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,ice={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:fC([0,.65,.55,1]),circOut:fC([.55,0,1,.45]),backIn:fC([.31,.01,.66,-.59]),backOut:fC([.33,1.53,.69,.99])};function ZMe(e,t){if(e)return typeof e=="function"?QMe()?FMe(e,t):"ease-out":MMe(e)?fC(e):Array.isArray(e)?e.map(n=>ZMe(n,t)||ice.easeOut):ice[e]}function pEt(e,t,n,{delay:r=0,duration:i=300,repeat:o=0,repeatType:s="loop",ease:a="easeOut",times:l}={},u=void 0){const c={[t]:n};l&&(c.offset=l);const d=ZMe(a,i);Array.isArray(d)&&(c.easing=d);const h={delay:r,duration:i,easing:Array.isArray(d)?"linear":d,fill:"both",iterations:o+1,direction:s==="reverse"?"alternate":"normal"};return u&&(h.pseudoElement=u),e.animate(c,h)}function hX(e){return typeof e=="function"&&"applyToOptions"in e}function mEt({type:e,...t}){return hX(e)&&QMe()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class JMe extends dX{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;const{element:n,name:r,keyframes:i,pseudoElement:o,allowFlatten:s=!1,finalKeyframe:a,onComplete:l}=t;this.isPseudoElement=!!o,this.allowFlatten=s,this.options=t,oD(typeof t.type!="string");const u=mEt(t);this.animation=pEt(n,r,i,u,o),u.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!o){const c=sD(i,this.options,a,this.speed);this.updateMotionValue&&this.updateMotionValue(c),YMe(n,r,c),this.animation.cancel()}l==null||l(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var t,n;(n=(t=this.animation).finish)==null||n.call(t)}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){var n,r,i;const t=(n=this.options)==null?void 0:n.element;!this.isPseudoElement&&(t!=null&&t.isConnected)&&((i=(r=this.animation).commitStyles)==null||i.call(r))}get duration(){var n,r;const t=((r=(n=this.animation.effect)==null?void 0:n.getComputedTiming)==null?void 0:r.call(n).duration)||0;return eu(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+eu(t)}get time(){return eu(Number(this.animation.currentTime)||0)}set time(t){const n=this.finishedTime!==null;this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=Sa(t),n&&this.animation.pause()}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t}attachTimeline({timeline:t,rangeStart:n,rangeEnd:r,observe:i}){var o;return this.allowFlatten&&((o=this.animation.effect)==null||o.updateTiming({easing:"linear"})),this.animation.onfinish=null,t&&hEt()?(this.animation.timeline=t,n&&(this.animation.rangeStart=n),r&&(this.animation.rangeEnd=r),su):i(this)}}const e_e={anticipate:CMe,backInOut:kMe,circInOut:TMe};function gEt(e){return e in e_e}function yEt(e){typeof e.ease=="string"&&gEt(e.ease)&&(e.ease=e_e[e.ease])}const r$=10;class bEt extends JMe{constructor(t){yEt(t),qMe(t),super(t),t.startTime!==void 0&&t.autoplay!==!1&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:i,element:o,...s}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const a=new tT({...s,autoplay:!1}),l=Math.max(r$,Ks.now()-this.startTime),u=Ld(0,r$,l-r$),c=a.sample(l).value,{name:d}=this.options;o&&d&&YMe(o,d,c),n.setWithVelocity(a.sample(Math.max(0,l-u)).value,c,u),a.stop()}}const oce=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(nc.test(e)||e==="0")&&!e.startsWith("url("));function vEt(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function xEt(e,t,n,r){const i=e[0];if(i===null)return!1;if(t==="display"||t==="visibility")return!0;const o=e[e.length-1],s=oce(i,t),a=oce(o,t);return!s||!a?!1:vEt(e)||(n==="spring"||hX(n))&&r}function CV(e){e.duration=0,e.type="keyframes"}const t_e=new Set(["opacity","clipPath","filter","transform","backgroundColor"]),wEt=/^(?:oklch|oklab|lab|lch|color|color-mix|light-dark)\(/;function SEt(e){for(let t=0;t<e.length;t++)if(typeof e[t]=="string"&&wEt.test(e[t]))return!0;return!1}const kEt=new Set(["color","backgroundColor","outlineColor","fill","stroke","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"]),CEt=bMe(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function EEt(e){var d;const{motionValue:t,name:n,repeatDelay:r,repeatType:i,damping:o,type:s,keyframes:a}=e,l=(d=t==null?void 0:t.owner)==null?void 0:d.current;if(!(l instanceof HTMLElement)&&!(l instanceof SVGElement))return!1;const{onUpdate:u,transformTemplate:c}=t.owner.getProps();return CEt()&&n&&(t_e.has(n)||kEt.has(n)&&SEt(a))&&(n!=="transform"||!c)&&!u&&!r&&i!=="mirror"&&o!==0&&s!=="inertia"}const TEt=40;class AEt extends dX{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:i=0,repeatDelay:o=0,repeatType:s="loop",keyframes:a,name:l,motionValue:u,element:c,...d}){var g;super(),this.stop=()=>{var b,v;this._animation&&(this._animation.stop(),(b=this.stopTimeline)==null||b.call(this)),(v=this.keyframeResolver)==null||v.cancel()},this.createdAt=Ks.now();const h={autoplay:t,delay:n,type:r,repeat:i,repeatDelay:o,repeatType:s,name:l,motionValue:u,element:c,...d},m=(c==null?void 0:c.KeyframeResolver)||fX;this.keyframeResolver=new m(a,(b,v,w)=>this.onKeyframesResolved(b,v,h,!w),l,u,c),(g=this.keyframeResolver)==null||g.scheduleResolve()}onKeyframesResolved(t,n,r,i){var w,S;this.keyframeResolver=void 0;const{name:o,type:s,velocity:a,delay:l,isHandoff:u,onUpdate:c}=r;this.resolvedAt=Ks.now();let d=!0;xEt(t,o,s,a)||(d=!1,(Eg.instantAnimations||!l)&&(c==null||c(sD(t,r,n))),t[0]=t[t.length-1],CV(r),r.repeat=0);const m={startTime:i?this.resolvedAt?this.resolvedAt-this.createdAt>TEt?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},g=d&&!u&&EEt(m),b=(S=(w=m.motionValue)==null?void 0:w.owner)==null?void 0:S.current;let v;if(g)try{v=new bEt({...m,element:b})}catch{v=new tT(m)}else v=new tT(m);v.finished.then(()=>{this.notifyFinished()}).catch(su),this.pendingTimeline&&(this.stopTimeline=v.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=v}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){var t;return this._animation||((t=this.keyframeResolver)==null||t.resume(),cEt()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){var t;this._animation&&this.animation.cancel(),(t=this.keyframeResolver)==null||t.cancel()}}class OEt{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}get finished(){return Promise.all(this.animations.map(t=>t.finished))}getAll(t){return this.animations[0][t]}setAll(t,n){for(let r=0;r<this.animations.length;r++)this.animations[r][t]=n}attachTimeline(t){const n=this.animations.map(r=>r.attachTimeline(t));return()=>{n.forEach((r,i)=>{r&&r(),this.animations[i].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get state(){return this.getAll("state")}get startTime(){return this.getAll("startTime")}get duration(){return sce(this.animations,"duration")}get iterationDuration(){return sce(this.animations,"iterationDuration")}runAll(t){this.animations.forEach(n=>n[t]())}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}function sce(e,t){let n=0;for(let r=0;r<e.length;r++){const i=e[r][t];i!==null&&i>n&&(n=i)}return n}class REt extends OEt{then(t,n){return this.finished.finally(t).then(()=>{})}}function n_e(e,t,n,r=0,i=1){const o=Array.from(e).sort((u,c)=>u.sortNodePosition(c)).indexOf(t),s=e.size,a=(s-1)*r;return typeof n=="function"?n(o,s):i===1?o*r:a-o*r}const ace=30,MEt=e=>!isNaN(parseFloat(e)),XC={current:void 0};class _Et{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var o;const i=Ks.now();if(this.updatedAt!==i&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&((o=this.events.change)==null||o.notify(this.current),this.dependents))for(const s of this.dependents)s.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=Ks.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=MEt(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new nX);const r=this.events[t].add(n);return t==="change"?()=>{r(),Rr.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){var t;(t=this.events.change)==null||t.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return XC.current&&XC.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){const t=Ks.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>ace)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,ace);return vMe(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){var t,n;(t=this.dependents)==null||t.clear(),(n=this.events.destroy)==null||n.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Tg(e,t){return new _Et(e,t)}function r_e(e,t){if(e!=null&&e.inherit&&t){const{inherit:n,...r}=e;return{...t,...r}}return e}function pX(e,t){const n=(e==null?void 0:e[t])??(e==null?void 0:e.default)??e;return n!==e?r_e(n,e):n}const NEt={type:"spring",stiffness:500,damping:25,restSpeed:10},LEt=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),IEt={type:"keyframes",duration:.8},PEt={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},jEt=(e,{keyframes:t})=>t.length>2?IEt:uS.has(e)?e.startsWith("scale")?LEt(t[1]):NEt:PEt,DEt=new Set(["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from","elapsed"]);function $Et(e){for(const t in e)if(!DEt.has(t))return!0;return!1}const mX=(e,t,n,r={},i,o)=>s=>{const a=pX(r,e)||{},l=a.delay||r.delay||0;let{elapsed:u=0}=r;u=u-Sa(l);const c={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-u,onUpdate:h=>{t.set(h),a.onUpdate&&a.onUpdate(h)},onComplete:()=>{s(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:o?void 0:i};$Et(a)||Object.assign(c,jEt(e,c)),c.duration&&(c.duration=Sa(c.duration)),c.repeatDelay&&(c.repeatDelay=Sa(c.repeatDelay)),c.from!==void 0&&(c.keyframes[0]=c.from);let d=!1;if((c.type===!1||c.duration===0&&!c.repeatDelay)&&(CV(c),c.delay===0&&(d=!0)),(Eg.instantAnimations||Eg.skipAnimations||i!=null&&i.shouldSkipAnimations||a.skipAnimations)&&(d=!0,CV(c),c.delay=0),c.allowFlatten=!a.type&&!a.ease,d&&!o&&t.get()!==void 0){const h=sD(c.keyframes,a);if(h!==void 0){Rr.update(()=>{c.onUpdate(h),c.onComplete()});return}}return a.isSync?new tT(c):new AEt(c)},zEt=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function FEt(e){const t=zEt.exec(e);if(!t)return[,];const[,n,r,i]=t;return[`--${n??r}`,i]}function i_e(e,t,n=1){const[r,i]=FEt(e);if(!r)return;const o=window.getComputedStyle(t).getPropertyValue(r);if(o){const s=o.trim();return mMe(s)?parseFloat(s):s}return sX(i)?i_e(i,t,n+1):i}function lce(e){const t=[{},{}];return e==null||e.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function gX(e,t,n,r){if(typeof t=="function"){const[i,o]=lce(r);t=t(n!==void 0?n:e.custom,i,o)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[i,o]=lce(r);t=t(n!==void 0?n:e.custom,i,o)}return t}function eb(e,t,n){const r=e.getProps();return gX(r,t,n!==void 0?n:r.custom,e)}const o_e=new Set(["width","height","top","left","right","bottom",...lS]),EV=e=>Array.isArray(e);function BEt(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Tg(n))}function HEt(e){return EV(e)?e[e.length-1]||0:e}function UEt(e,t){const n=eb(e,t);let{transitionEnd:r={},transition:i={},...o}=n||{};o={...o,...r};for(const s in o){const a=HEt(o[s]);BEt(e,s,a)}}const Pi=e=>!!(e&&e.getVelocity);function VEt(e){return!!(Pi(e)&&e.add)}function TV(e,t){const n=e.getValue("willChange");if(VEt(n))return n.add(t);if(!n&&Eg.WillChange){const r=new Eg.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function yX(e){return e.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const WEt="framerAppearId",s_e="data-"+yX(WEt);function a_e(e){return e.props[s_e]}function qEt({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function bX(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:o,transitionEnd:s,...a}=t;const l=e.getDefaultTransition();o=o?r_e(o,l):l;const u=o==null?void 0:o.reduceMotion,c=o==null?void 0:o.skipAnimations;r&&(o=r);const d=[],h=i&&e.animationState&&e.animationState.getState()[i],m=o==null?void 0:o.path;m&&m.animateVisualElement(e,a,o,n,d);for(const g in a){const b=e.getValue(g,e.latestValues[g]??null),v=a[g];if(v===void 0||h&&qEt(h,g))continue;const w={delay:n,...pX(o||{},g)};c&&(w.skipAnimations=!0);const S=b.get();if(S!==void 0&&!b.isAnimating()&&!Array.isArray(v)&&v===S&&!w.velocity){Rr.update(()=>b.set(v));continue}let C=!1;if(window.MotionHandoffAnimation){const O=a_e(e);if(O){const M=window.MotionHandoffAnimation(O,g,Rr);M!==null&&(w.startTime=M,C=!0)}}TV(e,g);const E=u??e.shouldReduceMotion;b.start(mX(g,b,v,E&&o_e.has(g)?{type:!1}:w,e,C));const T=b.animation;T&&d.push(T)}if(s){const g=()=>Rr.update(()=>{s&&UEt(e,s)});d.length?Promise.all(d).then(g):g()}return d}function AV(e,t,n={}){var l;const r=eb(e,t,n.type==="exit"?(l=e.presenceContext)==null?void 0:l.custom:void 0);let{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);const o=r?()=>Promise.all(bX(e,r,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:c=0,staggerChildren:d,staggerDirection:h}=i;return GEt(e,t,u,c,d,h,n)}:()=>Promise.resolve(),{when:a}=i;if(a){const[u,c]=a==="beforeChildren"?[o,s]:[s,o];return u().then(()=>c())}else return Promise.all([o(),s(n.delay)])}function GEt(e,t,n=0,r=0,i=0,o=1,s){const a=[];for(const l of e.variantChildren)l.notify("AnimationStart",t),a.push(AV(l,t,{...s,delay:n+(typeof r=="function"?0:r)+n_e(e.variantChildren,l,r,i,o)}).then(()=>l.notify("AnimationComplete",t)));return Promise.all(a)}function KEt(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const i=t.map(o=>AV(e,o,n));r=Promise.all(i)}else if(typeof t=="string")r=AV(e,t,n);else{const i=typeof t=="function"?eb(e,t,n.custom):t;r=Promise.all(bX(e,i,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}const YEt={test:e=>e==="auto",parse:e=>e},l_e=e=>t=>t.test(e),u_e=[aS,Dt,Cd,Tf,kCt,SCt,YEt],uce=e=>u_e.find(l_e(e));function XEt(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||yMe(e):!0}const QEt=new Set(["brightness","contrast","saturate","opacity"]);function ZEt(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(aX)||[];if(!r)return e;const i=n.replace(r,"");let o=QEt.has(t)?1:0;return r!==n&&(o*=100),t+"("+o+i+")"}const JEt=/\b([a-z-]*)\(.*?\)/gu,OV={...nc,getAnimatableNone:e=>{const t=e.match(JEt);return t?t.map(ZEt).join(" "):e}},RV={...nc,getAnimatableNone:e=>{const t=nc.parse(e);return nc.createTransformer(e)(t.map(r=>typeof r=="number"?0:typeof r=="object"?{...r,alpha:1}:r))}},cce={...aS,transform:Math.round},eTt={rotate:Tf,pathRotation:Tf,rotateX:Tf,rotateY:Tf,rotateZ:Tf,scale:aM,scaleX:aM,scaleY:aM,scaleZ:aM,skew:Tf,skewX:Tf,skewY:Tf,distance:Dt,translateX:Dt,translateY:Dt,translateZ:Dt,x:Dt,y:Dt,z:Dt,perspective:Dt,transformPerspective:Dt,opacity:JE,originX:Yue,originY:Yue,originZ:Dt},iI={borderWidth:Dt,borderTopWidth:Dt,borderRightWidth:Dt,borderBottomWidth:Dt,borderLeftWidth:Dt,borderRadius:Dt,borderTopLeftRadius:Dt,borderTopRightRadius:Dt,borderBottomRightRadius:Dt,borderBottomLeftRadius:Dt,width:Dt,maxWidth:Dt,height:Dt,maxHeight:Dt,top:Dt,right:Dt,bottom:Dt,left:Dt,inset:Dt,insetBlock:Dt,insetBlockStart:Dt,insetBlockEnd:Dt,insetInline:Dt,insetInlineStart:Dt,insetInlineEnd:Dt,padding:Dt,paddingTop:Dt,paddingRight:Dt,paddingBottom:Dt,paddingLeft:Dt,paddingBlock:Dt,paddingBlockStart:Dt,paddingBlockEnd:Dt,paddingInline:Dt,paddingInlineStart:Dt,paddingInlineEnd:Dt,margin:Dt,marginTop:Dt,marginRight:Dt,marginBottom:Dt,marginLeft:Dt,marginBlock:Dt,marginBlockStart:Dt,marginBlockEnd:Dt,marginInline:Dt,marginInlineStart:Dt,marginInlineEnd:Dt,fontSize:Dt,backgroundPositionX:Dt,backgroundPositionY:Dt,...eTt,zIndex:cce,fillOpacity:JE,strokeOpacity:JE,numOctaves:cce},tTt={...iI,color:Yi,backgroundColor:Yi,outlineColor:Yi,fill:Yi,stroke:Yi,borderColor:Yi,borderTopColor:Yi,borderRightColor:Yi,borderBottomColor:Yi,borderLeftColor:Yi,filter:OV,WebkitFilter:OV,mask:RV,WebkitMask:RV},c_e=e=>tTt[e],nTt=new Set([OV,RV]);function d_e(e,t){let n=c_e(e);return nTt.has(n)||(n=nc),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const rTt=new Set(["auto","none","0"]);function iTt(e,t,n){let r=0,i;for(;r<e.length&&!i;){const o=e[r];typeof o=="string"&&!rTt.has(o)&&sw(o).values.length&&(i=e[r]),r++}if(i&&n)for(const o of t)e[o]=d_e(n,i)}class oTt extends fX{constructor(t,n,r,i,o){super(t,n,r,i,o,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let c=0;c<t.length;c++){let d=t[c];if(typeof d=="string"&&(d=d.trim(),sX(d))){const h=i_e(d,n.current);h!==void 0&&(t[c]=h),c===t.length-1&&(this.finalKeyframe=d)}}if(this.resolveNoneKeyframes(),!o_e.has(r)||t.length!==2)return;const[i,o]=t,s=uce(i),a=uce(o),l=Kue(i),u=Kue(o);if(l!==u&&Ym[r]){this.needsMeasurement=!0;return}if(s!==a)if(rce(s)&&rce(a))for(let c=0;c<t.length;c++){const d=t[c];typeof d=="string"&&(t[c]=parseFloat(d))}else Ym[r]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,r=[];for(let i=0;i<t.length;i++)(t[i]===null||XEt(t[i]))&&r.push(i);r.length&&iTt(t,r,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:r}=this;if(!t||!t.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Ym[r](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const i=n[n.length-1];i!==void 0&&t.getValue(r,i).jump(i,!1)}measureEndState(){var a;const{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;const i=t.getValue(n);i&&i.jump(this.measuredOrigin,!1);const o=r.length-1,s=r[o];r[o]=Ym[n](t.measureViewportBox(),window.getComputedStyle(t.current)),s!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=s),(a=this.removedTransforms)!=null&&a.length&&this.removedTransforms.forEach(([l,u])=>{t.getValue(l).set(u)}),this.resolveNoneKeyframes()}}const vX=["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"];function xX(e,t,n){if(e==null)return[];if(e instanceof EventTarget)return[e];if(typeof e=="string"){let r=document;t&&(r=t.current);const i=(n==null?void 0:n[e])??r.querySelectorAll(e);return i?Array.from(i):[]}return Array.from(e).filter(r=>r!=null)}const MV=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function E_(e){return gMe(e)&&"offsetHeight"in e&&!("ownerSVGElement"in e)}const{schedule:wX}=_Me(queueMicrotask,!1),_u={x:!1,y:!1};function f_e(){return _u.x||_u.y}function sTt(e){return e==="x"||e==="y"?_u[e]?null:(_u[e]=!0,()=>{_u[e]=!1}):_u.x||_u.y?null:(_u.x=_u.y=!0,()=>{_u.x=_u.y=!1})}function h_e(e,t){const n=xX(e),r=new AbortController,i={passive:!0,...t,signal:r.signal};return[n,i,()=>r.abort()]}function aTt(e){return!(e.pointerType==="touch"||f_e())}function lTt(e,t,n={}){const[r,i,o]=h_e(e,n);return r.forEach(s=>{let a=!1,l=!1,u;const c=()=>{s.removeEventListener("pointerleave",g)},d=v=>{u&&(u(v),u=void 0),c()},h=v=>{a=!1,window.removeEventListener("pointerup",h),window.removeEventListener("pointercancel",h),l&&(l=!1,d(v))},m=()=>{a=!0,window.addEventListener("pointerup",h,i),window.addEventListener("pointercancel",h,i)},g=v=>{if(v.pointerType!=="touch"){if(a){l=!0;return}d(v)}},b=v=>{if(!aTt(v))return;l=!1;const w=t(s,v);typeof w=="function"&&(u=w,s.addEventListener("pointerleave",g,i))};s.addEventListener("pointerenter",b,i),s.addEventListener("pointerdown",m,i)}),o}const p_e=(e,t)=>t?e===t?!0:p_e(e,t.parentElement):!1,SX=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,uTt=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function cTt(e){return uTt.has(e.tagName)||e.isContentEditable===!0}const dTt=new Set(["INPUT","SELECT","TEXTAREA"]);function fTt(e){return dTt.has(e.tagName)||e.isContentEditable===!0}const T_=new WeakSet;function dce(e){return t=>{t.key==="Enter"&&e(t)}}function i$(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const hTt=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=dce(()=>{if(T_.has(n))return;i$(n,"down");const i=dce(()=>{i$(n,"up")}),o=()=>i$(n,"cancel");n.addEventListener("keyup",i,t),n.addEventListener("blur",o,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function fce(e){return SX(e)&&!f_e()}const hce=new WeakSet;function pTt(e,t,n={}){const[r,i,o]=h_e(e,n),s=a=>{const l=a.currentTarget;if(!fce(a)||hce.has(a))return;T_.add(l),n.stopPropagation&&hce.add(a);const u=t(l,a),c={...i,capture:!0},d=(g,b)=>{window.removeEventListener("pointerup",h,c),window.removeEventListener("pointercancel",m,c),T_.has(l)&&T_.delete(l),fce(g)&&typeof u=="function"&&u(g,{success:b})},h=g=>{d(g,l===window||l===document||n.useGlobalTarget||p_e(l,g.target))},m=g=>{d(g,!1)};window.addEventListener("pointerup",h,c),window.addEventListener("pointercancel",m,c)};return r.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",s,i),E_(a)&&(a.addEventListener("focus",u=>hTt(u,i)),!cTt(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),o}function aD(e){return gMe(e)&&"ownerSVGElement"in e}const A_=new WeakMap;let Gp;const m_e=(e,t,n)=>(r,i)=>i&&i[0]?i[0][e+"Size"]:aD(r)&&"getBBox"in r?r.getBBox()[t]:r[n],mTt=m_e("inline","width","offsetWidth"),gTt=m_e("block","height","offsetHeight");function yTt({target:e,borderBoxSize:t}){var n;(n=A_.get(e))==null||n.forEach(r=>{r(e,{get width(){return mTt(e,t)},get height(){return gTt(e,t)}})})}function bTt(e){e.forEach(yTt)}function vTt(){typeof ResizeObserver>"u"||(Gp=new ResizeObserver(bTt))}function xTt(e,t){Gp||vTt();const n=xX(e);return n.forEach(r=>{let i=A_.get(r);i||(i=new Set,A_.set(r,i)),i.add(t),Gp==null||Gp.observe(r)}),()=>{n.forEach(r=>{const i=A_.get(r);i==null||i.delete(t),i!=null&&i.size||Gp==null||Gp.unobserve(r)})}}const O_=new Set;let x1;function wTt(){x1=()=>{const e={get width(){return window.innerWidth},get height(){return window.innerHeight}};O_.forEach(t=>t(e))},window.addEventListener("resize",x1)}function STt(e){return O_.add(e),x1||wTt(),()=>{O_.delete(e),!O_.size&&typeof x1=="function"&&(window.removeEventListener("resize",x1),x1=void 0)}}function pce(e,t){return typeof e=="function"?STt(e):xTt(e,t)}function g_e(e){return aD(e)&&e.tagName==="svg"}function kTt(...e){const t=!Array.isArray(e[0]),n=t?0:-1,r=e[0+n],i=e[1+n],o=e[2+n],s=e[3+n],a=UMe(i,o,s);return t?a(r):a}function CTt(e,t,n={}){const r=e.get();let i=null,o=r,s;const a=typeof r=="string"?r.replace(/[\d.-]/g,""):void 0,l=()=>{i&&(i.stop(),i=null),e.animation=void 0},u=()=>{const d=mce(e.get()),h=mce(o);if(d===h){l();return}const m=i?i.getGeneratorVelocity():e.getVelocity();l(),i=new tT({keyframes:[d,h],velocity:m,type:"spring",restDelta:.001,restSpeed:.01,...n,onUpdate:s})},c=()=>{var d;u(),e.animation=i??void 0,(d=e.events.animationStart)==null||d.notify(),i==null||i.then(()=>{var h;e.animation=void 0,(h=e.events.animationComplete)==null||h.notify()})};if(e.attach((d,h)=>{o=d,s=m=>h(o$(m,a)),Rr.postRender(c)},l),Pi(t)){let d=n.skipInitialAnimation===!0;const h=t.on("change",g=>{d?(d=!1,e.jump(o$(g,a),!1)):e.set(o$(g,a))}),m=e.on("destroy",h);return()=>{h(),m()}}return l}function o$(e,t){return t?e+t:e}function mce(e){return typeof e=="number"?e:parseFloat(e)}const ETt=[...u_e,Yi,nc],TTt=e=>ETt.find(l_e(e)),gce=()=>({translate:0,scale:1,origin:0,originPoint:0}),w1=()=>({x:gce(),y:gce()}),yce=()=>({min:0,max:0}),Gi=()=>({x:yce(),y:yce()}),nT=new WeakMap;function lD(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function rT(e){return typeof e=="string"||Array.isArray(e)}const kX=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],CX=["initial",...kX];function uD(e){return lD(e.animate)||CX.some(t=>rT(e[t]))}function y_e(e){return!!(uD(e)||e.variants)}function ATt(e,t,n){for(const r in t){const i=t[r],o=n[r];if(Pi(i))e.addValue(r,i);else if(Pi(o))e.addValue(r,Tg(i,{owner:e}));else if(o!==i)if(e.hasValue(r)){const s=e.getValue(r);s.liveStyle===!0?s.jump(i):s.hasAnimated||s.set(i)}else{const s=e.getStaticValue(r);e.addValue(r,Tg(s!==void 0?s:i,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const oI={current:null},EX={current:!1},OTt=typeof window<"u";function b_e(){if(EX.current=!0,!!OTt)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>oI.current=e.matches;e.addEventListener("change",t),t()}else oI.current=!1}const bce=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let sI={};function v_e(e){sI=e}function RTt(){return sI}class x_e{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:i,skipAnimations:o,blockInitialAnimation:s,visualState:a},l={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.shouldSkipAnimations=!1,this.values=new Map,this.KeyframeResolver=fX,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.hasBeenMounted=!1,this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const m=Ks.now();this.renderScheduledAt<m&&(this.renderScheduledAt=m,Rr.render(this.render,!1,!0))};const{latestValues:u,renderState:c}=a;this.latestValues=u,this.baseTarget={...u},this.initialValues=n.initial?{...u}:{},this.renderState=c,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=i,this.skipAnimationsConfig=o,this.options=l,this.blockInitialAnimation=!!s,this.isControllingVariants=uD(n),this.isVariantNode=y_e(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:d,...h}=this.scrapeMotionValuesFromProps(n,{},this);for(const m in h){const g=h[m];u[m]!==void 0&&Pi(g)&&g.set(u[m])}}mount(t){var n,r;if(this.hasBeenMounted)for(const i in this.initialValues)(n=this.values.get(i))==null||n.jump(this.initialValues[i]),this.latestValues[i]=this.initialValues[i];this.current=t,nT.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((i,o)=>this.bindToMotionValue(o,i)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(EX.current||b_e(),this.shouldReduceMotion=oI.current),this.shouldSkipAnimations=this.skipAnimationsConfig??!1,(r=this.parent)==null||r.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=!0}unmount(){var t;this.projection&&this.projection.unmount(),Uh(this.notifyUpdate),Uh(this.render),this.valueSubscriptions.forEach(n=>n()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(t=this.parent)==null||t.removeChild(this);for(const n in this.events)this.events[n].clear();for(const n in this.features){const r=this.features[n];r&&(r.unmount(),r.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){if(this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)(),n.accelerate&&t_e.has(t)&&this.current instanceof HTMLElement){const{factory:s,keyframes:a,times:l,ease:u,duration:c}=n.accelerate,d=new JMe({element:this.current,name:t,keyframes:a,times:l,ease:u,duration:Sa(c)}),h=s(d);this.valueSubscriptions.set(t,()=>{h(),d.cancel()});return}const r=uS.has(t);r&&this.onBindTransform&&this.onBindTransform();const i=n.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&Rr.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let o;typeof window<"u"&&window.MotionCheckAppearSync&&(o=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{i(),o&&o()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in sI){const n=sI[t];if(!n)continue;const{isEnabled:r,Feature:i}=n;if(!this.features[t]&&i&&r(this.props)&&(this.features[t]=new i(this)),this.features[t]){const o=this.features[t];o.isMounted?o.update():(o.mount(),o.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Gi()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<bce.length;r++){const i=bce[r];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);const o="on"+i,s=t[o];s&&(this.propEventSubscriptions[i]=this.on(i,s))}this.prevMotionValues=ATt(this,this.scrapeMotionValuesFromProps(t,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Tg(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(mMe(r)||yMe(r))?r=parseFloat(r):!TTt(r)&&nc.test(n)&&(r=d_e(t,n)),this.setBaseTarget(t,Pi(r)?r.get():r)),Pi(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var o;const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const s=gX(this.props,n,(o=this.presenceContext)==null?void 0:o.custom);s&&(r=s[t])}if(n&&r!==void 0)return r;const i=this.getBaseTargetFromProps(this.props,t);return i!==void 0&&!Pi(i)?i:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new nX),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){wX.render(this.render)}}class w_e extends x_e{constructor(){super(...arguments),this.KeyframeResolver=oTt}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){const r=t.style;return r?r[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;Pi(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}class Vg{constructor(t){this.isMounted=!1,this.node=t}update(){}}function S_e({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function MTt({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function _Tt(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function s$(e){return e===void 0||e===1}function _V({scale:e,scaleX:t,scaleY:n}){return!s$(e)||!s$(t)||!s$(n)}function z0(e){return _V(e)||k_e(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function k_e(e){return vce(e.x)||vce(e.y)}function vce(e){return e&&e!=="0%"}function aI(e,t,n){const r=e-n,i=t*r;return n+i}function xce(e,t,n,r,i){return i!==void 0&&(e=aI(e,i,r)),aI(e,n,r)+t}function NV(e,t=0,n=1,r,i){e.min=xce(e.min,t,n,r,i),e.max=xce(e.max,t,n,r,i)}function C_e(e,{x:t,y:n}){NV(e.x,t.translate,t.scale,t.originPoint),NV(e.y,n.translate,n.scale,n.originPoint)}const wce=.999999999999,Sce=1.0000000000001;function NTt(e,t,n,r=!1){var a;const i=n.length;if(!i)return;t.x=t.y=1;let o,s;for(let l=0;l<i;l++){o=n[l],s=o.projectionDelta;const{visualElement:u}=o.options;u&&u.props.style&&u.props.style.display==="contents"||(r&&o.options.layoutScroll&&o.scroll&&o!==o.root&&(od(e.x,-o.scroll.offset.x),od(e.y,-o.scroll.offset.y)),s&&(t.x*=s.x.scale,t.y*=s.y.scale,C_e(e,s)),r&&z0(o.latestValues)&&R_(e,o.latestValues,(a=o.layout)==null?void 0:a.layoutBox))}t.x<Sce&&t.x>wce&&(t.x=1),t.y<Sce&&t.y>wce&&(t.y=1)}function od(e,t){e.min+=t,e.max+=t}function kce(e,t,n,r,i=.5){const o=jr(e.min,e.max,i);NV(e,t,n,o,r)}function Cce(e,t){return typeof e=="string"?parseFloat(e)/100*(t.max-t.min):e}function R_(e,t,n){const r=n??e;kce(e.x,Cce(t.x,r.x),t.scaleX,t.scale,t.originX),kce(e.y,Cce(t.y,r.y),t.scaleY,t.scale,t.originY)}function E_e(e,t){return S_e(_Tt(e.getBoundingClientRect(),t))}function LTt(e,t,n){const r=E_e(e,n),{scroll:i}=t;return i&&(od(r.x,i.offset.x),od(r.y,i.offset.y)),r}const ITt={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},PTt=lS.length;function jTt(e,t,n){let r="",i=!0;for(let s=0;s<PTt;s++){const a=lS[s],l=e[a];if(l===void 0)continue;let u=!0;if(typeof l=="number")u=l===(a.startsWith("scale")?1:0);else{const c=parseFloat(l);u=a.startsWith("scale")?c===1:c===0}if(!u||n){const c=MV(l,iI[a]);if(!u){i=!1;const d=ITt[a]||a;r+=`${d}(${c}) `}n&&(t[a]=c)}}const o=e.pathRotation;return o&&(i=!1,r+=`rotate(${MV(o,iI.pathRotation)}) `),r=r.trim(),n?r=n(t,i?"":r):i&&(r="none"),r}function TX(e,t,n){const{style:r,vars:i,transformOrigin:o}=e;let s=!1,a=!1;for(const l in t){const u=t[l];if(uS.has(l)){s=!0;continue}else if(LMe(l)){i[l]=u;continue}else{const c=MV(u,iI[l]);l.startsWith("origin")?(a=!0,o[l]=c):r[l]=c}}if(t.transform||(s||n?r.transform=jTt(t,e.transform,n):r.transform&&(r.transform="none")),a){const{originX:l="50%",originY:u="50%",originZ:c=0}=o;r.transformOrigin=`${l} ${u} ${c}`}}function T_e(e,{style:t,vars:n},r,i){const o=e.style;let s;for(s in t)o[s]=t[s];i==null||i.applyProjectionStyles(o,r);for(s in n)o.setProperty(s,n[s])}function Ece(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const Ek={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(Dt.test(e))e=parseFloat(e);else return e;const n=Ece(e,t.target.x),r=Ece(e,t.target.y);return`${n}% ${r}%`}},DTt={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,i=nc.parse(e);if(i.length>5)return r;const o=nc.createTransformer(e),s=typeof i[0]!="number"?1:0,a=n.x.scale*t.x,l=n.y.scale*t.y;i[0+s]/=a,i[1+s]/=l;const u=jr(a,l,.5);return typeof i[2+s]=="number"&&(i[2+s]/=u),typeof i[3+s]=="number"&&(i[3+s]/=u),o(i)}},LV={borderRadius:{...Ek,applyTo:[...vX]},borderTopLeftRadius:Ek,borderTopRightRadius:Ek,borderBottomLeftRadius:Ek,borderBottomRightRadius:Ek,boxShadow:DTt};function A_e(e,{layout:t,layoutId:n}){return uS.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!LV[e]||e==="opacity")}function AX(e,t,n){var s;const r=e.style,i=t==null?void 0:t.style,o={};if(!r)return o;for(const a in r)(Pi(r[a])||i&&Pi(i[a])||A_e(a,e)||((s=n==null?void 0:n.getValue(a))==null?void 0:s.liveStyle)!==void 0)&&(o[a]=r[a]);return o}function $Tt(e){return window.getComputedStyle(e)}class O_e extends w_e{constructor(){super(...arguments),this.type="html",this.renderInstance=T_e}mount(t){oD(!!t.style),super.mount(t)}readValueFromInstance(t,n){var r;if(uS.has(n))return(r=this.projection)!=null&&r.isProjecting?vV(n):oEt(t,n);{const i=$Tt(t),o=(LMe(n)?i.getPropertyValue(n):i[n])||0;return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(t,{transformPagePoint:n}){return E_e(t,n)}build(t,n,r){TX(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return AX(t,n,r)}}function zTt(e,t){return e in t}class FTt extends x_e{constructor(){super(...arguments),this.type="object"}readValueFromInstance(t,n){if(zTt(n,t)){const r=t[n];if(typeof r=="string"||typeof r=="number")return r}}getBaseTargetFromProps(){}removeValueFromRenderState(t,n){delete n.output[t]}measureInstanceViewportBox(){return Gi()}build(t,n){Object.assign(t.output,n)}renderInstance(t,{output:n}){Object.assign(t,n)}sortInstanceNodePosition(){return 0}}const BTt={offset:"stroke-dashoffset",array:"stroke-dasharray"},HTt={offset:"strokeDashoffset",array:"strokeDasharray"};function UTt(e,t,n=1,r=0,i=!0){e.pathLength=1;const o=i?BTt:HTt;e[o.offset]=`${-r}`,e[o.array]=`${t} ${n}`}const VTt=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function R_e(e,{attrX:t,attrY:n,attrScale:r,pathLength:i,pathSpacing:o=1,pathOffset:s=0,...a},l,u,c){if(TX(e,a,u),l){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:d,style:h}=e;d.transform&&(h.transform=d.transform,delete d.transform),(h.transform||d.transformOrigin)&&(h.transformOrigin=d.transformOrigin??"50% 50%",delete d.transformOrigin),h.transform&&(h.transformBox=(c==null?void 0:c.transformBox)??"fill-box",delete d.transformBox);for(const m of VTt)d[m]!==void 0&&(h[m]=d[m],delete d[m]);t!==void 0&&(d.x=t),n!==void 0&&(d.y=n),r!==void 0&&(d.scale=r),i!==void 0&&UTt(d,i,o,s,!1)}const M_e=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]),__e=e=>typeof e=="string"&&e.toLowerCase()==="svg";function WTt(e,t,n,r){T_e(e,t,void 0,r);for(const i in t.attrs)e.setAttribute(M_e.has(i)?i:yX(i),t.attrs[i])}function N_e(e,t,n){const r=AX(e,t,n);for(const i in e)if(Pi(e[i])||Pi(t[i])){const o=lS.indexOf(i)!==-1?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i;r[o]=e[i]}return r}class L_e extends w_e{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Gi}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(uS.has(n)){const r=c_e(n);return r&&r.default||0}return n=M_e.has(n)?n:yX(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return N_e(t,n,r)}build(t,n,r){R_e(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,i){WTt(t,n,r,i)}mount(t){this.isSVGTag=__e(t.tagName),super.mount(t)}}const qTt=CX.length;function I_e(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?I_e(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<qTt;n++){const r=CX[n],i=e.props[r];(rT(i)||i===!1)&&(t[r]=i)}return t}function P_e(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}const GTt=[...kX].reverse(),KTt=kX.length;function YTt(e){return t=>Promise.all(t.map(({animation:n,options:r})=>KEt(e,n,r)))}function XTt(e){let t=YTt(e),n=Tce(),r=!0,i=!1;const o=u=>(c,d)=>{var m;const h=eb(e,d,u==="exit"?(m=e.presenceContext)==null?void 0:m.custom:void 0);if(h){const{transition:g,transitionEnd:b,...v}=h;c={...c,...v,...b}}return c};function s(u){t=u(e)}function a(u){const{props:c}=e,d=I_e(e.parent)||{},h=[],m=new Set;let g={},b=1/0;for(let w=0;w<KTt;w++){const S=GTt[w],C=n[S],E=c[S]!==void 0?c[S]:d[S],T=rT(E),O=S===u?C.isActive:null;O===!1&&(b=w);let M=E===d[S]&&E!==c[S]&&T;if(M&&(r||i)&&e.manuallyAnimateOnMount&&(M=!1),C.protectedKeys={...g},!C.isActive&&O===null||!E&&!C.prevProp||lD(E)||typeof E=="boolean")continue;if(S==="exit"&&C.isActive&&O!==!0){C.prevResolvedValues&&(g={...g,...C.prevResolvedValues});continue}const N=QTt(C.prevProp,E);let I=N||S===u&&C.isActive&&!M&&T||w>b&&T,D=!1;const P=Array.isArray(E)?E:[E];let F=P.reduce(o(S),{});O===!1&&(F={});const{prevResolvedValues:z={}}=C,$={...z,...F},B=W=>{I=!0,m.has(W)&&(D=!0,m.delete(W)),C.needsAnimating[W]=!0;const q=e.getValue(W);q&&(q.liveStyle=!1)};for(const W in $){const q=F[W],Y=z[W];if(g.hasOwnProperty(W))continue;let Q=!1;EV(q)&&EV(Y)?Q=!P_e(q,Y)||N:Q=q!==Y,Q?q!=null?B(W):m.add(W):q!==void 0&&m.has(W)?B(W):C.protectedKeys[W]=!0}C.prevProp=E,C.prevResolvedValues=F,C.isActive&&(g={...g,...F}),(r||i)&&e.blockInitialAnimation&&(I=!1);const H=M&&N;I&&(!H||D)&&h.push(...P.map(W=>{const q={type:S};if(typeof W=="string"&&(r||i)&&!H&&e.manuallyAnimateOnMount&&e.parent){const{parent:Y}=e,Q=eb(Y,W);if(Y.enteringChildren&&Q){const{delayChildren:G}=Q.transition||{};q.delay=n_e(Y.enteringChildren,e,G)}}return{animation:W,options:q}}))}if(m.size){const w={};if(typeof c.initial!="boolean"){const S=eb(e,Array.isArray(c.initial)?c.initial[0]:c.initial);S&&S.transition&&(w.transition=S.transition)}m.forEach(S=>{const C=e.getBaseTarget(S),E=e.getValue(S);E&&(E.liveStyle=!0),w[S]=C??null}),h.push({animation:w})}let v=!!h.length;return r&&(c.initial===!1||c.initial===c.animate)&&!e.manuallyAnimateOnMount&&(v=!1),r=!1,i=!1,v?t(h):Promise.resolve()}function l(u,c){var h;if(n[u].isActive===c)return Promise.resolve();(h=e.variantChildren)==null||h.forEach(m=>{var g;return(g=m.animationState)==null?void 0:g.setActive(u,c)}),n[u].isActive=c;const d=a(u);for(const m in n)n[m].protectedKeys={};return d}return{animateChanges:a,setActive:l,setAnimateFunction:s,getState:()=>n,reset:()=>{n=Tce(),i=!0}}}function QTt(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!P_e(t,e):!1}function M0(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Tce(){return{animate:M0(!0),whileInView:M0(),whileHover:M0(),whileTap:M0(),whileDrag:M0(),whileFocus:M0(),exit:M0()}}function IV(e,t){e.min=t.min,e.max=t.max}function Tu(e,t){IV(e.x,t.x),IV(e.y,t.y)}function Ace(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}const j_e=1e-4,ZTt=1-j_e,JTt=1+j_e,D_e=.01,e2t=0-D_e,t2t=0+D_e;function Ys(e){return e.max-e.min}function n2t(e,t,n){return Math.abs(e-t)<=n}function Oce(e,t,n,r=.5){e.origin=r,e.originPoint=jr(t.min,t.max,e.origin),e.scale=Ys(n)/Ys(t),e.translate=jr(n.min,n.max,e.origin)-e.originPoint,(e.scale>=ZTt&&e.scale<=JTt||isNaN(e.scale))&&(e.scale=1),(e.translate>=e2t&&e.translate<=t2t||isNaN(e.translate))&&(e.translate=0)}function QC(e,t,n,r){Oce(e.x,t.x,n.x,r?r.originX:void 0),Oce(e.y,t.y,n.y,r?r.originY:void 0)}function Rce(e,t,n,r=0){const i=r?jr(n.min,n.max,r):n.min;e.min=i+t.min,e.max=e.min+Ys(t)}function r2t(e,t,n,r){Rce(e.x,t.x,n.x,r==null?void 0:r.x),Rce(e.y,t.y,n.y,r==null?void 0:r.y)}function Mce(e,t,n,r=0){const i=r?jr(n.min,n.max,r):n.min;e.min=t.min-i,e.max=e.min+Ys(t)}function lI(e,t,n,r){Mce(e.x,t.x,n.x,r==null?void 0:r.x),Mce(e.y,t.y,n.y,r==null?void 0:r.y)}function _ce(e,t,n,r,i){return e-=t,e=aI(e,1/n,r),i!==void 0&&(e=aI(e,1/i,r)),e}function i2t(e,t=0,n=1,r=.5,i,o=e,s=e){if(Cd.test(t)&&(t=parseFloat(t),t=jr(s.min,s.max,t/100)-s.min),typeof t!="number")return;let a=jr(o.min,o.max,r);e===o&&(a-=t),e.min=_ce(e.min,t,n,a,i),e.max=_ce(e.max,t,n,a,i)}function Nce(e,t,[n,r,i],o,s){i2t(e,t[n],t[r],t[i],t.scale,o,s)}const o2t=["x","scaleX","originX"],s2t=["y","scaleY","originY"];function Lce(e,t,n,r){Nce(e.x,t,o2t,n?n.x:void 0,r?r.x:void 0),Nce(e.y,t,s2t,n?n.y:void 0,r?r.y:void 0)}function Ice(e){return e.translate===0&&e.scale===1}function $_e(e){return Ice(e.x)&&Ice(e.y)}function Pce(e,t){return e.min===t.min&&e.max===t.max}function a2t(e,t){return Pce(e.x,t.x)&&Pce(e.y,t.y)}function jce(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function z_e(e,t){return jce(e.x,t.x)&&jce(e.y,t.y)}function Dce(e){return Ys(e.x)/Ys(e.y)}function $ce(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function Dc(e){return[e("x"),e("y")]}function l2t(e,t,n){let r="";const i=e.x.translate/t.x,o=e.y.translate/t.y,s=(n==null?void 0:n.z)||0;if((i||o||s)&&(r=`translate3d(${i}px, ${o}px, ${s}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:u,rotate:c,pathRotation:d,rotateX:h,rotateY:m,skewX:g,skewY:b}=n;u&&(r=`perspective(${u}px) ${r}`),c&&(r+=`rotate(${c}deg) `),d&&(r+=`rotate(${d}deg) `),h&&(r+=`rotateX(${h}deg) `),m&&(r+=`rotateY(${m}deg) `),g&&(r+=`skewX(${g}deg) `),b&&(r+=`skewY(${b}deg) `)}const a=e.x.scale*t.x,l=e.y.scale*t.y;return(a!==1||l!==1)&&(r+=`scale(${a}, ${l})`),r||"none"}const u2t=vX.length,zce=e=>typeof e=="string"?parseFloat(e):e,Fce=e=>typeof e=="number"||Dt.test(e);function c2t(e,t,n,r,i,o){i?(e.opacity=jr(0,n.opacity??1,d2t(r)),e.opacityExit=jr(t.opacity??1,0,f2t(r))):o&&(e.opacity=jr(t.opacity??1,n.opacity??1,r));for(let s=0;s<u2t;s++){const a=vX[s];let l=Bce(t,a),u=Bce(n,a);if(l===void 0&&u===void 0)continue;l||(l=0),u||(u=0),l===0||u===0||Fce(l)===Fce(u)?(e[a]=Math.max(jr(zce(l),zce(u),r),0),(Cd.test(u)||Cd.test(l))&&(e[a]+="%")):e[a]=u}(t.rotate||n.rotate)&&(e.rotate=jr(t.rotate||0,n.rotate||0,r))}function Bce(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const d2t=F_e(0,.5,EMe),f2t=F_e(.5,.95,su);function F_e(e,t,n){return r=>r<e?0:r>t?1:n(ow(e,t,r))}function B_e(e,t,n){const r=Pi(e)?e:Tg(e);return r.start(mX("",r,t,n)),r.animation}function iT(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)}const h2t=(e,t)=>e.depth-t.depth;class p2t{constructor(){this.children=[],this.isDirty=!1}add(t){tX(this.children,t),this.isDirty=!0}remove(t){iw(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(h2t),this.isDirty=!1,this.children.forEach(t)}}function m2t(e,t){const n=Ks.now(),r=({timestamp:i})=>{const o=i-n;o>=t&&(Uh(r),e(o-t))};return Rr.setup(r,!0),()=>Uh(r)}function M_(e){return Pi(e)?e.get():e}class g2t{constructor(){this.members=[]}add(t){tX(this.members,t);for(let n=this.members.length-1;n>=0;n--){const r=this.members[n];if(r===t||r===this.lead||r===this.prevLead)continue;const i=r.instance;(!i||i.isConnected===!1)&&!r.snapshot&&(iw(this.members,r),r.unmount())}t.scheduleRender()}remove(t){if(iw(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){var n;for(let r=this.members.indexOf(t)-1;r>=0;r--){const i=this.members[r];if(i.isPresent!==!1&&((n=i.instance)==null?void 0:n.isConnected)!==!1)return this.promote(i),!0}return!1}promote(t,n){var i;const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.updateSnapshot(),t.scheduleRender();const{layoutDependency:o}=r.options,{layoutDependency:s}=t.options;(o===void 0||o!==s)&&(t.resumeFrom=r,n&&(r.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),(i=t.root)!=null&&i.isUpdating&&(t.isLayoutDirty=!0)),t.options.crossfade===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{var n,r,i,o,s;(r=(n=t.options).onExitComplete)==null||r.call(n),(s=(i=t.resumingFrom)==null?void 0:(o=i.options).onExitComplete)==null||s.call(o)})}scheduleRender(){this.members.forEach(t=>t.instance&&t.scheduleRender(!1))}removeLeadSnapshot(){var t;(t=this.lead)!=null&&t.snapshot&&(this.lead.snapshot=void 0)}}const __={hasAnimatedSinceResize:!0,hasEverUpdated:!1},a$=["","X","Y","Z"],y2t=1e3;let b2t=0;function l$(e,t,n,r){const{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}function H_e(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=a_e(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:i,layoutId:o}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",Rr,!(i||o))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&H_e(r)}function U_e({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(s={},a=t==null?void 0:t()){this.id=b2t++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(w2t),this.nodes.forEach(A2t),this.nodes.forEach(O2t),this.nodes.forEach(S2t)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let l=0;l<this.path.length;l++)this.path[l].shouldResetTransform=!0;this.root===this&&(this.nodes=new p2t)}addEventListener(s,a){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new nX),this.eventHandlers.get(s).add(a)}notifyListeners(s,...a){const l=this.eventHandlers.get(s);l&&l.notify(...a)}hasListeners(s){return this.eventHandlers.has(s)}mount(s){if(this.instance)return;this.isSVG=aD(s)&&!g_e(s),this.instance=s;const{layoutId:a,layout:l,visualElement:u}=this.options;if(u&&!u.current&&u.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(l||a)&&(this.isLayoutDirty=!0),e){let c,d=0;const h=()=>this.root.updateBlockedByResize=!1;Rr.read(()=>{d=window.innerWidth}),e(s,()=>{const m=window.innerWidth;m!==d&&(d=m,this.root.updateBlockedByResize=!0,c&&c(),c=m2t(h,250),__.hasAnimatedSinceResize&&(__.hasAnimatedSinceResize=!1,this.nodes.forEach(Vce)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&u&&(a||l)&&this.addEventListener("didUpdate",({delta:c,hasLayoutChanged:d,hasRelativeLayoutChanged:h,layout:m})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const g=this.options.transition||u.getDefaultTransition()||L2t,{onLayoutAnimationStart:b,onLayoutAnimationComplete:v}=u.getProps(),w=!this.targetLayout||!z_e(this.targetLayout,m),S=!d&&h;if(this.options.layoutRoot||this.resumeFrom||S||d&&(w||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const C={...pX(g,"layout"),onPlay:b,onComplete:v};(u.shouldReduceMotion||this.options.layoutRoot)&&(C.delay=0,C.type=!1),this.startAnimation(C),this.setAnimationOrigin(c,S,C.path)}else d||Vce(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=m})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Uh(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(R2t),this.animationId++)}getTransformTemplate(){const{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&H_e(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let c=0;c<this.path.length;c++){const d=this.path[c];d.shouldResetTransform=!0,(typeof d.latestValues.x=="string"||typeof d.latestValues.y=="string")&&(d.isLayoutDirty=!0),d.updateScroll("snapshot"),d.options.layoutRoot&&d.willUpdate(!1)}const{layoutId:a,layout:l}=this.options;if(a===void 0&&!l)return;const u=this.getTransformTemplate();this.prevTransformTemplateValue=u?u(this.latestValues,""):void 0,this.updateSnapshot(),s&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){const l=this.updateBlockedByResize;this.unblockUpdate(),this.updateBlockedByResize=!1,this.clearAllSnapshots(),l&&this.nodes.forEach(C2t),this.nodes.forEach(Hce);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(Uce);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(E2t),this.nodes.forEach(T2t),this.nodes.forEach(v2t),this.nodes.forEach(x2t)):this.nodes.forEach(Uce),this.clearAllSnapshots();const a=Ks.now();es.delta=Ld(0,1e3/60,a-es.timestamp),es.timestamp=a,es.isProcessing=!0,Z8.update.process(es),Z8.preRender.process(es),Z8.render.process(es),es.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,wX.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(k2t),this.sharedNodes.forEach(M2t)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,Rr.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){Rr.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Ys(this.snapshot.measuredBox.x)&&!Ys(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l<this.path.length;l++)this.path[l].updateScroll();const s=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected||(this.layoutCorrected=Gi()),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,s?s.layoutBox:void 0)}updateScroll(s="measure"){let a=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===s&&(a=!1),a&&this.instance){const l=r(this.instance);this.scroll={animationId:this.root.animationId,phase:s,isRoot:l,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:l}}}resetTransform(){if(!i)return;const s=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,a=this.projectionDelta&&!$_e(this.projectionDelta),l=this.getTransformTemplate(),u=l?l(this.latestValues,""):void 0,c=u!==this.prevTransformTemplateValue;s&&this.instance&&(a||z0(this.latestValues)||c)&&(i(this.instance,u),this.shouldResetTransform=!1,this.scheduleRender())}measure(s=!0){const a=this.measurePageBox();let l=this.removeElementScroll(a);return s&&(l=this.removeTransform(l)),I2t(l),{animationId:this.root.animationId,measuredBox:a,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){var u;const{visualElement:s}=this.options;if(!s)return Gi();const a=s.measureViewportBox();if(!(((u=this.scroll)==null?void 0:u.wasRoot)||this.path.some(P2t))){const{scroll:c}=this.root;c&&(od(a.x,c.offset.x),od(a.y,c.offset.y))}return a}removeElementScroll(s){var l;const a=Gi();if(Tu(a,s),(l=this.scroll)!=null&&l.wasRoot)return a;for(let u=0;u<this.path.length;u++){const c=this.path[u],{scroll:d,options:h}=c;c!==this.root&&d&&h.layoutScroll&&(d.wasRoot&&Tu(a,s),od(a.x,d.offset.x),od(a.y,d.offset.y))}return a}applyTransform(s,a=!1,l){var c,d;const u=l||Gi();Tu(u,s);for(let h=0;h<this.path.length;h++){const m=this.path[h];!a&&m.options.layoutScroll&&m.scroll&&m!==m.root&&(od(u.x,-m.scroll.offset.x),od(u.y,-m.scroll.offset.y)),z0(m.latestValues)&&R_(u,m.latestValues,(c=m.layout)==null?void 0:c.layoutBox)}return z0(this.latestValues)&&R_(u,this.latestValues,(d=this.layout)==null?void 0:d.layoutBox),u}removeTransform(s){var l;const a=Gi();Tu(a,s);for(let u=0;u<this.path.length;u++){const c=this.path[u];if(!z0(c.latestValues))continue;let d;c.instance&&(_V(c.latestValues)&&c.updateSnapshot(),d=Gi(),Tu(d,c.measurePageBox())),Lce(a,c.latestValues,(l=c.snapshot)==null?void 0:l.layoutBox,d)}return z0(this.latestValues)&&Lce(a,this.latestValues),a}setTargetDelta(s){this.targetDelta=s,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(s){this.options={...this.options,...s,crossfade:s.crossfade!==void 0?s.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==es.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){var m;const a=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=a.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=a.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=a.isSharedProjectionDirty);const l=!!this.resumingFrom||this!==a;if(!(s||l&&this.isSharedProjectionDirty||this.isProjectionDirty||(m=this.parent)!=null&&m.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:c,layoutId:d}=this.options;if(!this.layout||!(c||d))return;this.resolvedRelativeTargetAt=es.timestamp;const h=this.getClosestProjectingParent();h&&this.linkedParentVersion!==h.layoutVersion&&!h.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(this.options.layoutAnchor!==!1&&h&&h.layout?this.createRelativeTarget(h,this.layout.layoutBox,h.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=Gi(),this.targetWithTransforms=Gi()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),r2t(this.target,this.relativeTarget,this.relativeParent.target,this.options.layoutAnchor||void 0)):this.targetDelta?(this.resumingFrom?this.applyTransform(this.layout.layoutBox,!1,this.target):Tu(this.target,this.layout.layoutBox),C_e(this.target,this.targetDelta)):Tu(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,this.options.layoutAnchor!==!1&&h&&!!h.resumingFrom==!!this.resumingFrom&&!h.options.layoutScroll&&h.target&&this.animationProgress!==1?this.createRelativeTarget(h,this.target,h.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||_V(this.parent.latestValues)||k_e(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(s,a,l){this.relativeParent=s,this.linkedParentVersion=s.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Gi(),this.relativeTargetOrigin=Gi(),lI(this.relativeTargetOrigin,a,l,this.options.layoutAnchor||void 0),Tu(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){var g;const s=this.getLead(),a=!!this.resumingFrom||this!==s;let l=!0;if((this.isProjectionDirty||(g=this.parent)!=null&&g.isProjectionDirty)&&(l=!1),a&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===es.timestamp&&(l=!1),l)return;const{layout:u,layoutId:c}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(u||c))return;Tu(this.layoutCorrected,this.layout.layoutBox);const d=this.treeScale.x,h=this.treeScale.y;NTt(this.layoutCorrected,this.treeScale,this.path,a),s.layout&&!s.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(s.target=s.layout.layoutBox,s.targetWithTransforms=Gi());const{target:m}=s;if(!m){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Ace(this.prevProjectionDelta.x,this.projectionDelta.x),Ace(this.prevProjectionDelta.y,this.projectionDelta.y)),QC(this.projectionDelta,this.layoutCorrected,m,this.latestValues),(this.treeScale.x!==d||this.treeScale.y!==h||!$ce(this.projectionDelta.x,this.prevProjectionDelta.x)||!$ce(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",m))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){var a;if((a=this.options.visualElement)==null||a.scheduleRender(),s){const l=this.getStack();l&&l.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=w1(),this.projectionDelta=w1(),this.projectionDeltaWithTransform=w1()}setAnimationOrigin(s,a=!1,l){const u=this.snapshot,c=u?u.latestValues:{},d={...this.latestValues},h=w1();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const m=Gi(),g=u?u.source:void 0,b=this.layout?this.layout.source:void 0,v=g!==b,w=this.getStack(),S=!w||w.members.length<=1,C=!!(v&&!S&&this.options.crossfade===!0&&!this.path.some(N2t));this.animationProgress=0;let E;const T=l==null?void 0:l.interpolateProjection(s);this.mixTargetDelta=O=>{const M=O/1e3,N=T==null?void 0:T(M);N?(h.x.translate=N.x,h.x.scale=jr(s.x.scale,1,M),h.x.origin=s.x.origin,h.x.originPoint=s.x.originPoint,h.y.translate=N.y,h.y.scale=jr(s.y.scale,1,M),h.y.origin=s.y.origin,h.y.originPoint=s.y.originPoint):(Wce(h.x,s.x,M),Wce(h.y,s.y,M)),this.setTargetDelta(h),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(lI(m,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0),_2t(this.relativeTarget,this.relativeTargetOrigin,m,M),E&&a2t(this.relativeTarget,E)&&(this.isProjectionDirty=!1),E||(E=Gi()),Tu(E,this.relativeTarget)),v&&(this.animationValues=d,c2t(d,c,this.latestValues,M,C,S)),N&&N.rotate!==void 0&&(this.animationValues||(this.animationValues=d),this.animationValues.pathRotation=N.rotate),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=M},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){var a,l,u;this.notifyListeners("animationStart"),(a=this.currentAnimation)==null||a.stop(),(u=(l=this.resumingFrom)==null?void 0:l.currentAnimation)==null||u.stop(),this.pendingAnimation&&(Uh(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=Rr.update(()=>{__.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=Tg(0)),this.motionValue.jump(0,!1),this.currentAnimation=B_e(this.motionValue,[0,1e3],{...s,velocity:0,isSync:!0,onUpdate:c=>{this.mixTargetDelta(c),s.onUpdate&&s.onUpdate(c)},onComplete:()=>{s.onComplete&&s.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(y2t),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const s=this.getLead();let{targetWithTransforms:a,target:l,layout:u,latestValues:c}=s;if(!(!a||!l||!u)){if(this!==s&&this.layout&&u&&V_e(this.options.animationType,this.layout.layoutBox,u.layoutBox)){l=this.target||Gi();const d=Ys(this.layout.layoutBox.x);l.x.min=s.target.x.min,l.x.max=l.x.min+d;const h=Ys(this.layout.layoutBox.y);l.y.min=s.target.y.min,l.y.max=l.y.min+h}Tu(a,l),R_(a,c),QC(this.projectionDeltaWithTransform,this.layoutCorrected,a,c)}}registerSharedNode(s,a){this.sharedNodes.has(s)||this.sharedNodes.set(s,new g2t),this.sharedNodes.get(s).add(a);const u=a.options.initialPromotionConfig;a.promote({transition:u?u.transition:void 0,preserveFollowOpacity:u&&u.shouldPreserveFollowOpacity?u.shouldPreserveFollowOpacity(a):void 0})}isLead(){const s=this.getStack();return s?s.lead===this:!0}getLead(){var a;const{layoutId:s}=this.options;return s?((a=this.getStack())==null?void 0:a.lead)||this:this}getPrevLead(){var a;const{layoutId:s}=this.options;return s?(a=this.getStack())==null?void 0:a.prevLead:void 0}getStack(){const{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:a,preserveFollowOpacity:l}={}){const u=this.getStack();u&&u.promote(this,l),s&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const s=this.getStack();return s?s.relegate(this):!1}resetSkewAndRotation(){const{visualElement:s}=this.options;if(!s)return;let a=!1;const{latestValues:l}=s;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(a=!0),!a)return;const u={};l.z&&l$("z",s,u,this.animationValues);for(let c=0;c<a$.length;c++)l$(`rotate${a$[c]}`,s,u,this.animationValues),l$(`skew${a$[c]}`,s,u,this.animationValues);s.render();for(const c in u)s.setStaticValue(c,u[c]),this.animationValues&&(this.animationValues[c]=u[c]);s.scheduleRender()}applyProjectionStyles(s,a){if(!this.instance||this.isSVG)return;if(!this.isVisible){s.visibility="hidden";return}const l=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,s.visibility="",s.opacity="",s.pointerEvents=M_(a==null?void 0:a.pointerEvents)||"",s.transform=l?l(this.latestValues,""):"none";return}const u=this.getLead();if(!this.projectionDelta||!this.layout||!u.target){this.options.layoutId&&(s.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,s.pointerEvents=M_(a==null?void 0:a.pointerEvents)||""),this.hasProjected&&!z0(this.latestValues)&&(s.transform=l?l({},""):"none",this.hasProjected=!1);return}s.visibility="";const c=u.animationValues||u.latestValues;this.applyTransformsToTarget();let d=l2t(this.projectionDeltaWithTransform,this.treeScale,c);l&&(d=l(c,d)),s.transform=d;const{x:h,y:m}=this.projectionDelta;s.transformOrigin=`${h.origin*100}% ${m.origin*100}% 0`,u.animationValues?s.opacity=u===this?c.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:c.opacityExit:s.opacity=u===this?c.opacity!==void 0?c.opacity:"":c.opacityExit!==void 0?c.opacityExit:0;for(const g in LV){if(c[g]===void 0)continue;const{correct:b,applyTo:v,isCSSVariable:w}=LV[g],S=d==="none"?c[g]:b(c[g],u);if(v){const C=v.length;for(let E=0;E<C;E++)s[v[E]]=S}else w?this.options.visualElement.renderState.vars[g]=S:s[g]=S}this.options.layoutId&&(s.pointerEvents=u===this?M_(a==null?void 0:a.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>{var a;return(a=s.currentAnimation)==null?void 0:a.stop()}),this.root.nodes.forEach(Hce),this.root.sharedNodes.clear()}}}function v2t(e){e.updateLayout()}function x2t(e){var n;const t=((n=e.resumeFrom)==null?void 0:n.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:i}=e.layout,{animationType:o}=e.options,s=t.source!==e.layout.source;if(o==="size")Dc(d=>{const h=s?t.measuredBox[d]:t.layoutBox[d],m=Ys(h);h.min=r[d].min,h.max=h.min+m});else if(o==="x"||o==="y"){const d=o==="x"?"y":"x";IV(s?t.measuredBox[d]:t.layoutBox[d],r[d])}else V_e(o,t.layoutBox,r)&&Dc(d=>{const h=s?t.measuredBox[d]:t.layoutBox[d],m=Ys(r[d]);h.max=h.min+m,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+m)});const a=w1();QC(a,r,t.layoutBox);const l=w1();s?QC(l,e.applyTransform(i,!0),t.measuredBox):QC(l,r,t.layoutBox);const u=!$_e(a);let c=!1;if(!e.resumeFrom){const d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){const{snapshot:h,layout:m}=d;if(h&&m){const g=e.options.layoutAnchor||void 0,b=Gi();lI(b,t.layoutBox,h.layoutBox,g);const v=Gi();lI(v,r,m.layoutBox,g),z_e(b,v)||(c=!0),d.options.layoutRoot&&(e.relativeTarget=v,e.relativeTargetOrigin=b,e.relativeParent=d)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:t,delta:l,layoutDelta:a,hasLayoutChanged:u,hasRelativeLayoutChanged:c})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function w2t(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function S2t(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function k2t(e){e.clearSnapshot()}function Hce(e){e.clearMeasurements()}function C2t(e){e.isLayoutDirty=!0,e.updateLayout()}function Uce(e){e.isLayoutDirty=!1}function E2t(e){e.isAnimationBlocked&&e.layout&&!e.isLayoutDirty&&(e.snapshot=e.layout,e.isLayoutDirty=!0)}function T2t(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function Vce(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function A2t(e){e.resolveTargetDelta()}function O2t(e){e.calcProjection()}function R2t(e){e.resetSkewAndRotation()}function M2t(e){e.removeLeadSnapshot()}function Wce(e,t,n){e.translate=jr(t.translate,0,n),e.scale=jr(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function qce(e,t,n,r){e.min=jr(t.min,n.min,r),e.max=jr(t.max,n.max,r)}function _2t(e,t,n,r){qce(e.x,t.x,n.x,r),qce(e.y,t.y,n.y,r)}function N2t(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const L2t={duration:.45,ease:[.4,0,.1,1]},Gce=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Kce=Gce("applewebkit/")&&!Gce("chrome/")?Math.round:su;function Yce(e){e.min=Kce(e.min),e.max=Kce(e.max)}function I2t(e){Yce(e.x),Yce(e.y)}function V_e(e,t,n){return e==="position"||e==="preserve-aspect"&&!n2t(Dce(t),Dce(n),.2)}function P2t(e){var t;return e!==e.root&&((t=e.scroll)==null?void 0:t.wasRoot)}const j2t=U_e({attachResizeListener:(e,t)=>iT(e,"resize",t),measureScroll:()=>{var e,t;return{x:document.documentElement.scrollLeft||((e=document.body)==null?void 0:e.scrollLeft)||0,y:document.documentElement.scrollTop||((t=document.body)==null?void 0:t.scrollTop)||0}},checkIsScrollRoot:()=>!0}),u$={current:void 0},W_e=U_e({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!u$.current){const e=new j2t({});e.mount(window),e.setOptions({layoutScroll:!0}),u$.current=e}return u$.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),wA=A.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function Xce(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function D2t(...e){return t=>{let n=!1;const r=e.map(i=>{const o=Xce(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():Xce(e[i],null)}}}}function $2t(...e){return A.useCallback(D2t(...e),e)}class z2t extends A.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(E_(n)&&t.isPresent&&!this.props.isPresent&&this.props.pop!==!1){const r=n.offsetParent,i=E_(r)&&r.offsetWidth||0,o=E_(r)&&r.offsetHeight||0,s=getComputedStyle(n),a=this.props.sizeRef.current;a.height=parseFloat(s.height),a.width=parseFloat(s.width),a.top=n.offsetTop,a.left=n.offsetLeft,a.right=i-a.width-a.left,a.bottom=o-a.height-a.top,a.direction=s.direction}return null}componentDidUpdate(){}render(){return this.props.children}}function F2t({children:e,isPresent:t,anchorX:n,anchorY:r,root:i,pop:o}){var h;const s=A.useId(),a=A.useRef(null),l=A.useRef({width:0,height:0,top:0,left:0,right:0,bottom:0,direction:"ltr"}),{nonce:u}=A.useContext(wA),c=o!==!1?((h=e.props)==null?void 0:h.ref)??(e==null?void 0:e.ref):void 0,d=$2t(a,c);return A.useInsertionEffect(()=>{const{width:m,height:g,top:b,left:v,right:w,bottom:S,direction:C}=l.current;if(t||o===!1||!a.current||!m||!g)return;const E=C==="rtl",T=n==="left"?E?`right: ${w}`:`left: ${v}`:E?`left: ${v}`:`right: ${w}`,O=r==="bottom"?`bottom: ${S}`:`top: ${b}`;a.current.dataset.motionPopId=s;const M=document.createElement("style");u&&(M.nonce=u);const N=i??document.head;return N.appendChild(M),M.sheet&&M.sheet.insertRule(`
2837
2837
  [data-motion-pop-id="${s}"] {
2838
2838
  position: absolute !important;
2839
2839
  width: ${m}px !important;
@@ -2841,7 +2841,7 @@ ${JSON.stringify(e,null,2)}`})]})}const As="text-zinc-400 dark:text-zinc-500",Cg
2841
2841
  ${T}px !important;
2842
2842
  ${O}px !important;
2843
2843
  }
2844
- `),()=>{var I;(I=a.current)==null||I.removeAttribute("data-motion-pop-id"),N.contains(M)&&N.removeChild(M)}},[t]),y.jsx(R2t,{isPresent:t,childRef:a,sizeRef:l,pop:o,children:o===!1?e:A.cloneElement(e,{ref:d})})}const _2t=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:i,presenceAffectsLayout:o,mode:s,anchorX:a,anchorY:l,root:u})=>{const c=gA(N2t),d=A.useId(),h=A.useRef(n),m=A.useRef(r);rD(()=>{h.current=n,m.current=r});let g=!0,b=A.useMemo(()=>(g=!1,{id:d,initial:t,isPresent:n,custom:i,onExitComplete:v=>{c.set(v,!0);for(const w of c.values())if(!w)return;r&&r()},register:v=>(c.set(v,!1),()=>{var w;c.delete(v),!h.current&&!c.size&&((w=m.current)==null||w.call(m))})}),[n,c,r]);return o&&g&&(b={...b}),A.useMemo(()=>{c.forEach((v,w)=>c.set(w,!1))},[n]),A.useEffect(()=>{!n&&!c.size&&r&&r()},[n]),e=y.jsx(M2t,{pop:s==="popLayout",isPresent:n,anchorX:a,anchorY:l,root:u,children:e}),y.jsx(iD.Provider,{value:b,children:e})};function N2t(){return new Map}function U_e(e=!0){const t=A.useContext(iD);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:i}=t,o=A.useId();A.useEffect(()=>{if(e)return i(o)},[e]);const s=A.useCallback(()=>e&&r&&r(o),[o,r,e]);return!n&&r?[!1,s]:[!0]}const lM=e=>e.key||"";function jce(e){const t=[];return A.Children.forEach(e,n=>{A.isValidElement(n)&&t.push(n)}),t}const cD=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:i=!0,mode:o="sync",propagate:s=!1,anchorX:a="left",anchorY:l="top",root:u})=>{const[c,d]=U_e(s),h=A.useMemo(()=>jce(e),[e]),m=s&&!c?[]:h.map(lM),g=A.useRef(!0),b=A.useRef(h),v=gA(()=>new Map),w=A.useRef(new Set),[S,C]=A.useState(h),[E,T]=A.useState(h);rD(()=>{g.current=!1,b.current=h;for(let N=0;N<E.length;N++){const I=lM(E[N]);m.includes(I)?(v.delete(I),w.current.delete(I)):v.get(I)!==!0&&v.set(I,!1)}},[E,m.length,m.join("-")]);const O=[];if(h!==S){let N=[...h];for(let I=0;I<E.length;I++){const D=E[I],P=lM(D);m.includes(P)||(N.splice(I,0,D),O.push(D))}return o==="wait"&&O.length&&(N=O),T(jce(N)),C(h),null}const{forceRender:M}=A.useContext(JY);return y.jsx(y.Fragment,{children:E.map(N=>{const I=lM(N),D=s&&!c?!1:h===E||m.includes(I),P=()=>{if(w.current.has(I))return;if(v.has(I))w.current.add(I),v.set(I,!0);else return;let F=!0;v.forEach(z=>{z||(F=!1)}),F&&(M==null||M(),T(b.current),s&&(d==null||d()),r&&r())};return y.jsx(_2t,{isPresent:D,initial:!g.current||n?void 0:!1,custom:t,presenceAffectsLayout:i,mode:o,root:u,onExitComplete:D?void 0:P,anchorX:a,anchorY:l,children:N},I)})})},V_e=A.createContext({strict:!1}),Dce={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]};let $ce=!1;function L2t(){if($ce)return;const e={};for(const t in Dce)e[t]={isEnabled:n=>Dce[t].some(r=>!!n[r])};g_e(e),$ce=!0}function W_e(){return L2t(),vTt()}function I2t(e){const t=W_e();for(const n in e)t[n]={...t[n],...e[n]};g_e(t)}const P2t=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","propagate","ignoreStrict","viewport"]);function uI(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||P2t.has(e)}let q_e=e=>!uI(e);function j2t(e){typeof e=="function"&&(q_e=t=>t.startsWith("on")?!uI(t):e(t))}try{j2t(require("@emotion/is-prop-valid").default)}catch{}function D2t(e,t,n){const r={};for(const i in e)i==="values"&&typeof e.values=="object"||Pi(e[i])||(q_e(i)||n===!0&&uI(i)||!t&&!uI(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}const dD=A.createContext({});function $2t(e,t){if(uD(e)){const{initial:n,animate:r}=e;return{initial:n===!1||rT(n)?n:void 0,animate:rT(r)?r:void 0}}return e.inherit!==!1?t:{}}function z2t(e){const{initial:t,animate:n}=$2t(e,A.useContext(dD));return A.useMemo(()=>({initial:t,animate:n}),[zce(t),zce(n)])}function zce(e){return Array.isArray(e)?e.join(" "):e}const AX=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function G_e(e,t,n){for(const r in t)!Pi(t[r])&&!C_e(r,n)&&(e[r]=t[r])}function F2t({transformTemplate:e},t){return A.useMemo(()=>{const n=AX();return EX(n,t,e),Object.assign({},n.vars,n.style)},[t])}function B2t(e,t){const n=e.style||{},r={};return G_e(r,n,e),Object.assign(r,F2t(e,t)),r}function H2t(e,t){const n={},r=B2t(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const K_e=()=>({...AX(),attrs:{}});function U2t(e,t,n,r){const i=A.useMemo(()=>{const o=K_e();return T_e(o,t,O_e(r),e.transformTemplate,e.style),{...o.attrs,style:{...o.style}}},[t]);if(e.style){const o={};G_e(o,e.style,e),i.style={...o,...i.style}}return i}const V2t=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function OX(e){return typeof e!="string"||e.includes("-")?!1:!!(V2t.indexOf(e)>-1||/[A-Z]/u.test(e))}function W2t(e,t,n,{latestValues:r},i,o=!1,s){const l=(s??OX(e)?U2t:H2t)(t,r,i,e),u=D2t(t,typeof e=="string",o),c=e!==A.Fragment?{...u,...l,ref:n}:{},{children:d}=t,h=A.useMemo(()=>Pi(d)?d.get():d,[d]);return A.createElement(e,{...c,children:h})}function q2t({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,i){return{latestValues:G2t(n,r,i,e),renderState:t()}}function G2t(e,t,n,r){const i={},o=r(e,{});for(const h in o)i[h]=M_(o[h]);let{initial:s,animate:a}=e;const l=uD(e),u=p_e(e);t&&u&&!l&&e.inherit!==!1&&(s===void 0&&(s=t.initial),a===void 0&&(a=t.animate));let c=n?n.initial===!1:!1;c=c||s===!1;const d=c?a:s;if(d&&typeof d!="boolean"&&!lD(d)){const h=Array.isArray(d)?d:[d];for(let m=0;m<h.length;m++){const g=mX(e,h[m]);if(g){const{transitionEnd:b,transition:v,...w}=g;for(const S in w){let C=w[S];if(Array.isArray(C)){const E=c?C.length-1:0;C=C[E]}C!==null&&(i[S]=C)}for(const S in b)i[S]=b[S]}}}return i}const Y_e=e=>(t,n)=>{const r=A.useContext(dD),i=A.useContext(iD),o=()=>q2t(e,t,r,i);return n?o():gA(o)},K2t=Y_e({scrapeMotionValuesFromProps:TX,createRenderState:AX}),Y2t=Y_e({scrapeMotionValuesFromProps:R_e,createRenderState:K_e}),X2t=Symbol.for("motionComponentSymbol");function Q2t(e,t,n){const r=A.useRef(n);A.useInsertionEffect(()=>{r.current=n});const i=A.useRef(null);return A.useCallback(o=>{var a;o&&((a=e.onMount)==null||a.call(e,o)),t&&(o?t.mount(o):t.unmount());const s=r.current;if(typeof s=="function")if(o){const l=s(o);typeof l=="function"&&(i.current=l)}else i.current?(i.current(),i.current=null):s(o);else s&&(s.current=o)},[t])}const X_e=A.createContext({});function c1(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function Z2t(e,t,n,r,i,o){var C,E;const{visualElement:s}=A.useContext(dD),a=A.useContext(V_e),l=A.useContext(iD),u=A.useContext(xA),c=u.reducedMotion,d=u.skipAnimations,h=A.useRef(null),m=A.useRef(!1);r=r||a.renderer,!h.current&&r&&(h.current=r(e,{visualState:t,parent:s,props:n,presenceContext:l,blockInitialAnimation:l?l.initial===!1:!1,reducedMotionConfig:c,skipAnimations:d,isSVG:o}),m.current&&h.current&&(h.current.manuallyAnimateOnMount=!0));const g=h.current,b=A.useContext(X_e);g&&!g.projection&&i&&(g.type==="html"||g.type==="svg")&&J2t(h.current,n,i,b);const v=A.useRef(!1);A.useInsertionEffect(()=>{g&&v.current&&g.update(n,l)});const w=n[r_e],S=A.useRef(!!w&&typeof window<"u"&&!((C=window.MotionHandoffIsComplete)!=null&&C.call(window,w))&&((E=window.MotionHasOptimisedAnimation)==null?void 0:E.call(window,w)));return rD(()=>{m.current=!0,g&&(v.current=!0,window.MotionIsMounted=!0,g.updateFeatures(),g.scheduleRenderMicrotask(),S.current&&g.animationState&&g.animationState.animateChanges())}),A.useEffect(()=>{g&&(!S.current&&g.animationState&&g.animationState.animateChanges(),S.current&&(queueMicrotask(()=>{var T;(T=window.MotionHandoffMarkAsComplete)==null||T.call(window,w)}),S.current=!1),g.enteringChildren=void 0)}),g}function J2t(e,t,n,r){const{layoutId:i,layout:o,drag:s,dragConstraints:a,layoutScroll:l,layoutRoot:u,layoutAnchor:c,layoutCrossfade:d}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:Q_e(e.parent)),e.projection.setOptions({layoutId:i,layout:o,alwaysMeasureLayout:!!s||a&&c1(a),visualElement:e,animationType:typeof o=="string"?o:"both",initialPromotionConfig:r,crossfade:d,layoutScroll:l,layoutRoot:u,layoutAnchor:c})}function Q_e(e){if(e)return e.options.allowProjection!==!1?e.projection:Q_e(e.parent)}function X8(e,{forwardMotionProps:t=!1,type:n}={},r,i){r&&I2t(r);const o=n?n==="svg":OX(e),s=o?Y2t:K2t;function a(u,c){let d;const h={...A.useContext(xA),...u,layoutId:eAt(u)},{isStatic:m}=h,g=z2t(u),b=s(u,m);if(!m&&typeof window<"u"){tAt();const v=nAt(h);d=v.MeasureLayout,g.visualElement=Z2t(e,b,h,i,v.ProjectionNode,o)}return y.jsxs(dD.Provider,{value:g,children:[d&&g.visualElement?y.jsx(d,{visualElement:g.visualElement,...h}):null,W2t(e,u,Q2t(b,g.visualElement,c),b,m,t,o)]})}a.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const l=A.forwardRef(a);return l[X2t]=e,l}function eAt({layoutId:e}){const t=A.useContext(JY).id;return t&&e!==void 0?t+"-"+e:e}function tAt(e,t){A.useContext(V_e).strict}function nAt(e){const t=W_e(),{drag:n,layout:r}=t;if(!n&&!r)return{};const i={...n,...r};return{MeasureLayout:n!=null&&n.isEnabled(e)||r!=null&&r.isEnabled(e)?i.MeasureLayout:void 0,ProjectionNode:i.ProjectionNode}}function rAt(e,t){if(typeof Proxy>"u")return X8;const n=new Map,r=(o,s)=>X8(o,s,e,t),i=(o,s)=>r(o,s);return new Proxy(i,{get:(o,s)=>s==="create"?r:(n.has(s)||n.set(s,X8(s,void 0,e,t)),n.get(s))})}const iAt=(e,t)=>t.isSVG??OX(e)?new M_e(t):new E_e(t,{allowProjection:e!==A.Fragment});class oAt extends Ug{constructor(t){super(t),t.animationState||(t.animationState=FTt(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();lD(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)==null||t.call(this)}}let sAt=0;class aAt extends Ug{constructor(){super(...arguments),this.id=sAt++,this.isExitComplete=!1}update(){var o;if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;if(t&&r===!1){if(this.isExitComplete){const{initial:s,custom:a}=this.node.getProps();if(typeof s=="string"||typeof s=="object"&&s!==null&&!Array.isArray(s)){const l=eb(this.node,s,a);if(l){const{transition:u,transitionEnd:c,...d}=l;for(const h in d)(o=this.node.getValue(h))==null||o.jump(d[h])}}this.node.animationState.reset(),this.node.animationState.animateChanges()}else this.node.animationState.setActive("exit",!1);this.isExitComplete=!1;return}const i=this.node.animationState.setActive("exit",!t);n&&!t&&i.then(()=>{this.isExitComplete=!0,n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const lAt={animation:{Feature:oAt},exit:{Feature:aAt}};function wA(e){return{point:{x:e.pageX,y:e.pageY}}}const uAt=e=>t=>wX(t)&&e(t,wA(t));function ZC(e,t,n,r){return iT(e,t,uAt(n),r)}const Z_e=({current:e})=>e?e.ownerDocument.defaultView:null,Fce=(e,t)=>Math.abs(e-t);function cAt(e,t){const n=Fce(e.x,t.x),r=Fce(e.y,t.y);return Math.sqrt(n**2+r**2)}const Bce=new Set(["auto","scroll"]);class J_e{constructor(t,n,{transformPagePoint:r,contextWindow:i=window,dragSnapToOrigin:o=!1,distanceThreshold:s=3,element:a}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=g=>{this.handleScroll(g.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=uM(this.lastRawMoveEventInfo,this.transformPagePoint));const g=Q8(this.lastMoveEventInfo,this.history),b=this.startEvent!==null,v=cAt(g.offset,{x:0,y:0})>=this.distanceThreshold;if(!b&&!v)return;const{point:w}=g,{timestamp:S}=es;this.history.push({...w,timestamp:S});const{onStart:C,onMove:E}=this.handlers;b||(C&&C(this.lastMoveEvent,g),this.startEvent=this.lastMoveEvent),E&&E(this.lastMoveEvent,g)},this.handlePointerMove=(g,b)=>{this.lastMoveEvent=g,this.lastRawMoveEventInfo=b,this.lastMoveEventInfo=uM(b,this.transformPagePoint),Rr.update(this.updatePoint,!0)},this.handlePointerUp=(g,b)=>{this.end();const{onEnd:v,onSessionEnd:w,resumeAnimation:S}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&S&&S(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const C=Q8(g.type==="pointercancel"?this.lastMoveEventInfo:uM(b,this.transformPagePoint),this.history);this.startEvent&&v&&v(g,C),w&&w(g,C)},!wX(t))return;this.dragSnapToOrigin=o,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=s,this.contextWindow=i||window;const l=wA(t),u=uM(l,this.transformPagePoint),{point:c}=u,{timestamp:d}=es;this.history=[{...c,timestamp:d}];const{onSessionStart:h}=n;h&&h(t,Q8(u,this.history));const m={passive:!0,capture:!0};this.removeListeners=yA(ZC(this.contextWindow,"pointermove",this.handlePointerMove,m),ZC(this.contextWindow,"pointerup",this.handlePointerUp,m),ZC(this.contextWindow,"pointercancel",this.handlePointerUp,m)),a&&this.startScrollTracking(a)}startScrollTracking(t){let n=t.parentElement;for(;n;){const r=getComputedStyle(n);(Bce.has(r.overflowX)||Bce.has(r.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0}),window.addEventListener("scroll",this.onWindowScroll),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const n=this.scrollPositions.get(t);if(!n)return;const r=t===window,i=r?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},o={x:i.x-n.x,y:i.y-n.y};o.x===0&&o.y===0||(r?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=o.x,this.lastMoveEventInfo.point.y+=o.y):this.history.length>0&&(this.history[0].x-=o.x,this.history[0].y-=o.y),this.scrollPositions.set(t,i),Rr.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),Uh(this.updatePoint)}}function uM(e,t){return t?{point:t(e.point)}:e}function Hce(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Q8({point:e},t){return{point:e,delta:Hce(e,eNe(t)),offset:Hce(e,dAt(t)),velocity:fAt(t,.1)}}function dAt(e){return e[0]}function eNe(e){return e[e.length-1]}function fAt(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const i=eNe(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>Sa(t)));)n--;if(!r)return{x:0,y:0};r===e[0]&&e.length>2&&i.timestamp-r.timestamp>Sa(t)*2&&(r=e[1]);const o=eu(i.timestamp-r.timestamp);if(o===0)return{x:0,y:0};const s={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function hAt(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?jr(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?jr(n,e,r.max):Math.min(e,n)),e}function Uce(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function pAt(e,{top:t,left:n,bottom:r,right:i}){return{x:Uce(e.x,n,i),y:Uce(e.y,t,r)}}function Vce(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function mAt(e,t){return{x:Vce(e.x,t.x),y:Vce(e.y,t.y)}}function gAt(e,t){let n=.5;const r=Ys(e),i=Ys(t);return i>r?n=ow(t.min,t.max-r,e.min):r>i&&(n=ow(e.min,e.max-i,t.min)),Ld(0,1,n)}function yAt(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const PV=.35;function bAt(e=PV){return e===!1?e=0:e===!0&&(e=PV),{x:Wce(e,"left","right"),y:Wce(e,"top","bottom")}}function Wce(e,t,n){return{min:qce(e,t),max:qce(e,n)}}function qce(e,t){return typeof e=="number"?e:e[t]||0}const vAt=new WeakMap;class xAt{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=Gi(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:i}=this.visualElement;if(i&&i.isPresent===!1)return;const o=d=>{n&&this.snapToCursor(wA(d).point),this.stopAnimation()},s=(d,h)=>{const{drag:m,dragPropagation:g,onDragStart:b}=this.getProps();if(m&&!g&&(this.openDragLock&&this.openDragLock(),this.openDragLock=XEt(m),!this.openDragLock))return;this.latestPointerEvent=d,this.latestPanInfo=h,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Dc(w=>{let S=this.getAxisMotionValue(w).get()||0;if(Cd.test(S)){const{projection:C}=this.visualElement;if(C&&C.layout){const E=C.layout.layoutBox[w];E&&(S=Ys(E)*(parseFloat(S)/100))}}this.originPoint[w]=S}),b&&Rr.update(()=>b(d,h),!1,!0),TV(this.visualElement,"transform");const{animationState:v}=this.visualElement;v&&v.setActive("whileDrag",!0)},a=(d,h)=>{this.latestPointerEvent=d,this.latestPanInfo=h;const{dragPropagation:m,dragDirectionLock:g,onDirectionLock:b,onDrag:v}=this.getProps();if(!m&&!this.openDragLock)return;const{offset:w}=h;if(g&&this.currentDirection===null){this.currentDirection=SAt(w),this.currentDirection!==null&&b&&b(this.currentDirection);return}this.updateAxis("x",h.point,w),this.updateAxis("y",h.point,w),this.visualElement.render(),v&&Rr.update(()=>v(d,h),!1,!0)},l=(d,h)=>{this.latestPointerEvent=d,this.latestPanInfo=h,this.stop(d,h),this.latestPointerEvent=null,this.latestPanInfo=null},u=()=>{const{dragSnapToOrigin:d}=this.getProps();(d||this.constraints)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:c}=this.getProps();this.panSession=new J_e(t,{onSessionStart:o,onStart:s,onMove:a,onSessionEnd:l,resumeAnimation:u},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:c,distanceThreshold:r,contextWindow:Z_e(this.visualElement),element:this.visualElement.current})}stop(t,n){const r=t||this.latestPointerEvent,i=n||this.latestPanInfo,o=this.isDragging;if(this.cancel(),!o||!i||!r)return;const{velocity:s}=i;this.startAnimation(s);const{onDragEnd:a}=this.getProps();a&&Rr.postRender(()=>a(r,i))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.endPanSession();const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(t,n,r){const{drag:i}=this.getProps();if(!r||!cM(t,i,this.currentDirection))return;const o=this.getAxisMotionValue(t);let s=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(s=hAt(s,this.constraints[t],this.elastic[t])),o.set(s)}resolveConstraints(){var o;const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(o=this.visualElement.projection)==null?void 0:o.layout,i=this.constraints;t&&c1(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=pAt(r.layoutBox,t):this.constraints=!1,this.elastic=bAt(n),i!==this.constraints&&!c1(t)&&r&&this.constraints&&!this.hasMutatedConstraints&&Dc(s=>{this.constraints!==!1&&this.getAxisMotionValue(s)&&(this.constraints[s]=yAt(r.layoutBox[s],this.constraints[s]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!c1(t))return!1;const r=t.current,{projection:i}=this.visualElement;if(!i||!i.layout)return!1;i.root&&(i.root.scroll=void 0,i.root.updateScroll());const o=kTt(r,i.root,this.visualElement.getTransformPagePoint());let s=mAt(i.layout.layoutBox,o);if(n){const a=n(xTt(s));this.hasMutatedConstraints=!!a,a&&(s=v_e(a))}return s}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:i,dragTransition:o,dragSnapToOrigin:s,onDragTransitionEnd:a}=this.getProps(),l=this.constraints||{},u=Dc(c=>{if(!cM(c,n,this.currentDirection))return;let d=l&&l[c]||{};(s===!0||s===c)&&(d={min:0,max:0});const h=i?200:1e6,m=i?40:1e7,g={type:"inertia",velocity:r?t[c]:0,bounceStiffness:h,bounceDamping:m,timeConstant:750,restDelta:1,restSpeed:10,...o,...d};return this.startAxisValueAnimation(c,g)});return Promise.all(u).then(a)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return TV(this.visualElement,t),r.start(pX(t,r,0,n,this.visualElement,!1))}stopAnimation(){Dc(t=>this.getAxisMotionValue(t).stop())}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,i=this.visualElement.getProps()[n];return i||this.visualElement.getValue(t,this.visualElement.latestValues[t]??0)}snapToCursor(t){Dc(n=>{const{drag:r}=this.getProps();if(!cM(n,r,this.currentDirection))return;const{projection:i}=this.visualElement,o=this.getAxisMotionValue(n);if(i&&i.layout){const{min:s,max:a}=i.layout.layoutBox[n],l=o.get()||0;o.set(t[n]-jr(s,a,.5)+l)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!c1(n)||!r||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};Dc(s=>{const a=this.getAxisMotionValue(s);if(a&&this.constraints!==!1){const l=a.get();i[s]=gAt({min:l,max:l},this.constraints[s])}});const{transformTemplate:o}=this.visualElement.getProps();this.visualElement.current.style.transform=o?o({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.constraints=!1,this.resolveConstraints(),Dc(s=>{if(!cM(s,t,null))return;const a=this.getAxisMotionValue(s),{min:l,max:u}=this.constraints[s];a.set(jr(l,u,i[s]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;vAt.set(this.visualElement,this);const t=this.visualElement.current,n=ZC(t,"pointerdown",u=>{const{drag:c,dragListener:d=!0}=this.getProps(),h=u.target,m=h!==t&&nTt(h);c&&d&&!m&&this.start(u)});let r;const i=()=>{const{dragConstraints:u}=this.getProps();c1(u)&&u.current&&(this.constraints=this.resolveRefConstraints(),r||(r=wAt(t,u.current,()=>this.scalePositionWithinConstraints())))},{projection:o}=this.visualElement,s=o.addEventListener("measure",i);o&&!o.layout&&(o.root&&o.root.updateScroll(),o.updateLayout()),Rr.read(i);const a=iT(window,"resize",()=>this.scalePositionWithinConstraints()),l=o.addEventListener("didUpdate",(({delta:u,hasLayoutChanged:c})=>{this.isDragging&&c&&(Dc(d=>{const h=this.getAxisMotionValue(d);h&&(this.originPoint[d]+=u[d].translate,h.set(h.get()+u[d].translate))}),this.visualElement.render())}));return()=>{a(),n(),s(),l&&l(),r&&r()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:i=!1,dragConstraints:o=!1,dragElastic:s=PV,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:i,dragConstraints:o,dragElastic:s,dragMomentum:a}}}function Gce(e){let t=!0;return()=>{if(t){t=!1;return}e()}}function wAt(e,t,n){const r=Jue(e,Gce(n)),i=Jue(t,Gce(n));return()=>{r(),i()}}function cM(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function SAt(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class kAt extends Ug{constructor(t){super(t),this.removeGroupControls=su,this.removeListeners=su,this.controls=new xAt(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||su}update(){const{dragControls:t}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};t!==n&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}}const Z8=e=>(t,n)=>{e&&Rr.update(()=>e(t,n),!1,!0)};class CAt extends Ug{constructor(){super(...arguments),this.removePointerDownListener=su}onPointerDown(t){this.session=new J_e(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Z_e(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:i}=this.node.getProps();return{onSessionStart:Z8(t),onStart:Z8(n),onMove:Z8(r),onEnd:(o,s)=>{delete this.session,i&&Rr.postRender(()=>i(o,s))}}}mount(){this.removePointerDownListener=ZC(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let J8=!1;class EAt extends A.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:i}=this.props,{projection:o}=t;o&&(n.group&&n.group.add(o),r&&r.register&&i&&r.register(o),J8&&o.root.didUpdate(),o.addEventListener("animationComplete",()=>{this.safeToRemove()}),o.setOptions({...o.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),__.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:i,isPresent:o}=this.props,{projection:s}=r;return s&&(s.isPresent=o,t.layoutDependency!==n&&s.setOptions({...s.options,layoutDependency:n}),J8=!0,i||t.layoutDependency!==n||n===void 0||t.isPresent!==o?s.willUpdate():this.safeToRemove(),t.isPresent!==o&&(o?s.promote():s.relegate()||Rr.postRender(()=>{const a=s.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{visualElement:t,layoutAnchor:n}=this.props,{projection:r}=t;r&&(r.options.layoutAnchor=n,r.root.didUpdate(),xX.postRender(()=>{!r.currentAnimation&&r.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:i}=t;J8=!0,i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),r&&r.deregister&&r.deregister(i))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function tNe(e){const[t,n]=U_e(),r=A.useContext(JY);return y.jsx(EAt,{...e,layoutGroup:r,switchLayoutGroup:A.useContext(X_e),isPresent:t,safeToRemove:n})}const TAt={pan:{Feature:CAt},drag:{Feature:kAt,ProjectionNode:H_e,MeasureLayout:tNe}};function Kce(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const i="onHover"+n,o=r[i];o&&Rr.postRender(()=>o(t,wA(t)))}class AAt extends Ug{mount(){const{current:t}=this.node;t&&(this.unmount=ZEt(t,(n,r)=>(Kce(this.node,r,"Start"),i=>Kce(this.node,i,"End"))))}unmount(){}}class OAt extends Ug{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=yA(iT(this.node.current,"focus",()=>this.onFocus()),iT(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function Yce(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const i="onTap"+(n==="End"?"":n),o=r[i];o&&Rr.postRender(()=>o(t,wA(t)))}class RAt extends Ug{mount(){const{current:t}=this.node;if(!t)return;const{globalTapTarget:n,propagate:r}=this.node.props;this.unmount=iTt(t,(i,o)=>(Yce(this.node,o,"Start"),(s,{success:a})=>Yce(this.node,s,a?"End":"Cancel")),{useGlobalTarget:n,stopPropagation:(r==null?void 0:r.tap)===!1})}unmount(){}}const jV=new WeakMap,e$=new WeakMap,MAt=e=>{const t=jV.get(e.target);t&&t(e)},_At=e=>{e.forEach(MAt)};function NAt({root:e,...t}){const n=e||document;e$.has(n)||e$.set(n,{});const r=e$.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(_At,{root:e,...t})),r[i]}function LAt(e,t,n){const r=NAt(t);return jV.set(e,n),r.observe(e),()=>{jV.delete(e),r.unobserve(e)}}const IAt={some:0,all:1};class PAt extends Ug{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){var l;(l=this.stopObserver)==null||l.call(this);const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:i="some",once:o}=t,s={root:n?n.current:void 0,rootMargin:r,threshold:typeof i=="number"?i:IAt[i]},a=u=>{const{isIntersecting:c}=u;if(this.isInView===c||(this.isInView=c,o&&!c&&this.hasEnteredView))return;c&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",c);const{onViewportEnter:d,onViewportLeave:h}=this.node.getProps(),m=c?d:h;m&&m(u)};this.stopObserver=LAt(this.node.current,s,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(jAt(t,n))&&this.startObserver()}unmount(){var t;(t=this.stopObserver)==null||t.call(this),this.hasEnteredView=!1,this.isInView=!1}}function jAt({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const DAt={inView:{Feature:PAt},tap:{Feature:RAt},focus:{Feature:OAt},hover:{Feature:AAt}},$At={layout:{ProjectionNode:H_e,MeasureLayout:tNe}},zAt={...lAt,...DAt,...TAt,...$At},FAt=rAt(zAt,iAt);function fD(e){const t=gA(()=>Tg(e)),{isStatic:n}=A.useContext(xA);if(n){const[,r]=A.useState(e);A.useEffect(()=>t.on("change",r),[])}return t}function nNe(e,t){const n=fD(t()),r=()=>n.set(t());return r(),rD(()=>{const i=()=>Rr.preRender(r,!1,!0),o=e.map(s=>s.on("change",i));return()=>{o.forEach(s=>s()),Uh(r)}}),n}function BAt(e){XC.current=[],e();const t=nNe(XC.current,e);return XC.current=void 0,t}function bb(e,t,n,r){if(typeof e=="function")return BAt(e);const o=typeof t=="function"?t:hTt(t,n,r),s=Array.isArray(e)?Xce(e,o):Xce([e],([l])=>o(l)),a=Array.isArray(e)?void 0:e.accelerate;return a&&!a.isTransformed&&typeof t!="function"&&Array.isArray(n)&&(r==null?void 0:r.clamp)!==!1&&(s.accelerate={...a,times:t,keyframes:n,isTransformed:!0}),s}function Xce(e,t){const n=gA(()=>[]);return nNe(e,()=>{n.length=0;const r=e.length;for(let i=0;i<r;i++)n[i]=e[i].get();return t(n)})}function HAt(e,t={}){const{isStatic:n}=A.useContext(xA),r=()=>Pi(e)?e.get():e;if(n)return bb(r);const i=fD(r());return A.useInsertionEffect(()=>pTt(i,e,t),[i,JSON.stringify(t)]),i}function fl(e,t={}){return HAt(e,{type:"spring",...t})}function uc(){!CX.current&&m_e();const[e]=A.useState(oI.current);return e}function RX(e){return typeof e=="object"&&!Array.isArray(e)}function rNe(e,t,n,r){return e==null?[]:typeof e=="string"&&RX(t)?vX(e,n,r):e instanceof NodeList?Array.from(e):Array.isArray(e)?e.filter(i=>i!=null):[e]}function UAt(e,t,n){return e*(t+1)+n*t}function Qce(e,t,n,r){return typeof t=="number"?t:t.startsWith("-")||t.startsWith("+")?Math.max(0,e+parseFloat(t)):t==="<"?n:t.startsWith("<")?Math.max(0,n+parseFloat(t.slice(1))):r.get(t)??e}function VAt(e,t,n){for(let r=0;r<e.length;r++){const i=e[r];i.at>t&&i.at<n&&(iw(e,i),r--)}}function WAt(e,t,n,r,i,o){VAt(e,i,o);for(let s=0;s<t.length;s++)e.push({value:t[s],at:jr(i,o,r[s]),easing:TMe(n,s)})}function qAt(e,t,n=0){const r=t+1+t*n;for(let i=0;i<e.length;i++)e[i]=e[i]/r}function GAt(e,t){return e.at===t.at?e.value===null?1:t.value===null?-1:0:e.at-t.at}const KAt="easeInOut",YAt=20;function XAt(e,{defaultTransition:t={},...n}={},r,i){const o=t.duration||.3,s=new Map,a=new Map,l={},u=new Map;let c=0,d=0,h=0;for(let m=0;m<e.length;m++){const g=e[m];if(typeof g=="string"){u.set(g,d);continue}else if(!Array.isArray(g)){u.set(g.name,Qce(d,g.at,c,u));continue}let[b,v,w={}]=g;w.at!==void 0&&(d=Qce(d,w.at,c,u));let S=0;const C=(E,T,O,M=0,N=0)=>{const I=QAt(E),{delay:D=0,times:P=HMe(I),type:F=t.type||"keyframes",repeat:z,repeatType:$,repeatDelay:B=0,...H}=T;let{ease:U=t.ease||"easeOut",duration:W}=T;const q=typeof D=="function"?D(M,N):D,Y=I.length,Q=fX(F)?F:i==null?void 0:i[F||"keyframes"];if(Y<=2&&Q){let te=100;if(Y===2&&eOt(I)){const ae=I[1]-I[0];te=Math.abs(ae)}const de={...t,...H};W!==void 0&&(de.duration=Sa(W));const ue=$Me(de,te,Q);U=ue.ease,W=ue.duration}W??(W=o);const G=d+q;P.length===1&&P[0]===0&&(P[1]=1);const le=P.length-I.length;if(le>0&&BMe(P,le),I.length===1&&I.unshift(null),z&&z<YAt){const te=W>0?B/W:0;W=UAt(W,z,B);const de=[...I],ue=[...P];U=Array.isArray(U)?[...U]:[U];const ae=[...U],ie=$==="reverse"||$==="mirror";let he=de,fe=ae;ie&&(he=[...de].reverse(),$==="reverse"&&(fe=[...ae].reverse().map(se=>typeof se=="function"?nX(se):se)));for(let se=0;se<z;se++){const Se=ie&&se%2===0,pe=Se?he:de,Ee=Se?fe:ae,ke=(se+1)*(1+te);te>0&&(I.push(I[I.length-1]),P.push(ke),U.push("linear")),I.push(...pe);for(let Ie=0;Ie<pe.length;Ie++)P.push(ue[Ie]+ke),U.push(Ie===0?"linear":TMe(Ee,Ie-1))}qAt(P,z,te)}const K=G+W;WAt(O,I,U,P,G,K),S=Math.max(q+W,S),h=Math.max(K,h)};if(Pi(b)){const E=Zce(b,a);C(v,w,Jce("default",E))}else{const E=rNe(b,v,r,l),T=E.length;for(let O=0;O<T;O++){v=v,w=w;const M=E[O],N=Zce(M,a);for(const I in v)C(v[I],ZAt(w,I),Jce(I,N),O,T)}}c=d,d+=S}return a.forEach((m,g)=>{for(const b in m){const v=m[b];v.sort(GAt);const w=[],S=[],C=[];for(let M=0;M<v.length;M++){const{at:N,value:I,easing:D}=v[M];w.push(I),S.push(ow(0,h,N)),C.push(D||"easeOut")}S[0]!==0&&(S.unshift(0),w.unshift(w[0]),C.unshift(KAt)),S[S.length-1]!==1&&(S.push(1),w.push(null)),s.has(g)||s.set(g,{keyframes:{},transition:{}});const E=s.get(g);E.keyframes[b]=w;const{type:T,...O}=t;E.transition[b]={...O,duration:h,ease:C,times:S,...n}}}),s}function Zce(e,t){return!t.has(e)&&t.set(e,{}),t.get(e)}function Jce(e,t){return t[e]||(t[e]=[]),t[e]}function QAt(e){return Array.isArray(e)?e:[e]}function ZAt(e,t){return e&&e[t]?{...e,...e[t]}:{...e}}const JAt=e=>typeof e=="number",eOt=e=>e.every(JAt);function tOt(e){const t={presenceContext:null,props:{},visualState:{renderState:{transform:{},transformOrigin:{},style:{},vars:{},attrs:{}},latestValues:{}}},n=aD(e)&&!h_e(e)?new M_e(t):new E_e(t);n.mount(e),nT.set(e,n)}function nOt(e){const t={presenceContext:null,props:{},visualState:{renderState:{output:{}},latestValues:{}}},n=new MTt(t);n.mount(e),nT.set(e,n)}function rOt(e,t){return Pi(e)||typeof e=="number"||typeof e=="string"&&!RX(t)}function iNe(e,t,n,r){const i=[];if(rOt(e,t))i.push($_e(e,RX(t)&&t.default||t,n&&(n.default||n)));else{if(e==null)return i;const o=rNe(e,t,r),s=o.length;for(let a=0;a<s;a++){const l=o[a],u=l instanceof Element?tOt:nOt;nT.has(l)||u(l);const c=nT.get(l),d={...n};"delay"in d&&typeof d.delay=="function"&&(d.delay=d.delay(a,s)),i.push(...yX(c,{...t,transition:d},{}))}}return i}function iOt(e,t,n){const r=[],i=e.map(s=>{if(Array.isArray(s)&&typeof s[0]=="function"){const a=s[0],l=Tg(0);return l.on("change",a),s.length===1?[l,[0,1]]:s.length===2?[l,[0,1],s[1]]:[l,s[1],s[2]]}return s});return XAt(i,t,n,{spring:eT}).forEach(({keyframes:s,transition:a},l)=>{r.push(...iNe(l,s,a))}),r}function oOt(e){return Array.isArray(e)&&e.some(Array.isArray)}function sOt(e={}){const{scope:t,reduceMotion:n,skipAnimations:r}=e;function i(o,s,a){let l=[],u;const c={};if(n!==void 0&&(c.reduceMotion=n),r!==void 0&&(c.skipAnimations=r),oOt(o)){const{onComplete:h,...m}=s||{};typeof h=="function"&&(u=h),l=iOt(o,{...c,...m},t)}else{const{onComplete:h,...m}=a||{};typeof h=="function"&&(u=h),l=iNe(o,s,{...c,...m},t)}const d=new vEt(l);return u&&d.finished.then(u),t&&(t.animations.push(d),d.finished.then(()=>{iw(t.animations,d)})),d}return i}const mh=sOt(),or=FAt,DV=2.2,MX=280,oNe=.45,aOt=30,tu=[.85,0,.15,1],JC=10;function sNe(e){switch(e){case"loading":return"loop";case"exiting":return"exit";case"revealingLoading":return"enter";default:return null}}function lOt(e,t,n,r){const i=fD(0),o=e+JC*2,s=e+JC,a=bb(i,u=>u<=.5?u/.5*o:(1-(u-.5)/.5)*o),l=bb(i,u=>{if(u<=.5)return-JC;const c=(u-.5)/.5;return s-(1-c)*o});return A.useEffect(()=>{if(e<=0)return;const u=DV/2;let c=!1,d;const h=()=>{c||r==null||r()},m=g=>{const b=u*((1-g)/.5);d=mh(i,1,{duration:Math.max(b,.01),ease:[...tu],onComplete:h})};if(t==="loop")return i.set(0),d=mh(i,1,{duration:DV,ease:[...tu],onComplete:h}),()=>{c=!0,d==null||d.stop()};if(t==="exit"){const g=i.get();if(g<.5){const b=u*((.5-g)/.5);d=mh(i,.5,{duration:Math.max(b,.01),ease:[...tu],onComplete:()=>{c||m(.5)}})}else m(g);return()=>{c=!0,d==null||d.stop()}}if(t==="enter")return i.set(0),d=mh(i,.5,{duration:u,ease:[...tu],onComplete:h}),()=>{c=!0,d==null||d.stop()}},[e,n,t,r,i]),{clipX:l,clipWidth:a}}function _X({pathD:e,mode:t="loop",loopEpoch:n=0,stroke:r=Bo.foreground,strokeOpacity:i=.5,strokeWidth:o=2.5,onCycleComplete:s}){const{innerWidth:a,innerHeight:l}=_a(),u=A.useId(),c=`line-loading-clip-${u}`,d=`line-loading-gradient-${u}`,h=qL(Hj(!0)),m=l+JC*2,{clipX:g,clipWidth:b}=lOt(a,t,n,s);return a<=0?null:y.jsxs(y.Fragment,{children:[y.jsxs("defs",{children:[y.jsx("clipPath",{id:c,children:y.jsx(or.rect,{height:m,style:{width:b,x:g},y:-JC})}),y.jsx("linearGradient",{id:d,...GL(a),children:h.map(v=>y.jsx("stop",{offset:v.offset,stopColor:r,stopOpacity:v.opacity},v.offset))})]}),y.jsx("path",{clipPath:`url(#${c})`,d:e,fill:"none",opacity:i,stroke:`url(#${d})`,strokeLinecap:"round",strokeWidth:o})]})}_X.displayName="LineLoadingPulseStroke";const aNe=2,t$=-1,uOt=2,cOt=25,dOt=20,fOt=80,hOt=14,pOt=2,mOt=12,gOt="var(--foreground)",yOt=.45,bOt=.55,vOt=.18,xOt=.02,wOt=.7;function lNe(e){const t=Math.sin(e)*43758.5453;return t-Math.floor(t)}function uNe(e,t=0,n=dOt,r=fOt){const i=r-n;return Array.from({length:e},(o,s)=>n+Math.floor(lNe((s+1)*12.9898+t)*i))}function SOt(e,t=0){return Array.from({length:e},(n,r)=>lNe((r+1)*78.233+t)<.5?-1:1)}function kOt(e=17,t=.05,n=.9){return Array.from({length:e},(r,i)=>{const o=i/(e-1),s=Math.sin(o*Math.PI)**2,a=t+s*(n-t);return{offset:`${(o*100).toFixed(0)}%`,opacity:Number(a.toFixed(3))}})}function cNe({chartId:e,width:t,height:n,durationSeconds:r,onSweepComplete:i}){const o=A.useMemo(()=>kOt(),[]),s=A.useRef(t$),a=A.useCallback(l=>{const u=typeof l.x=="number"?l.x:t$;u>=1&&s.current<1&&i(),s.current=u},[i]);return y.jsxs(y.Fragment,{children:[y.jsx("linearGradient",{id:`${e}-grad`,x1:"0",x2:"1",y1:"0",y2:"0",children:o.map(({offset:l,opacity:u})=>y.jsx("stop",{offset:l,stopColor:"white",stopOpacity:u},l))}),y.jsx("pattern",{height:"1",id:`${e}-pattern`,patternContentUnits:"objectBoundingBox",patternTransform:`rotate(${cOt})`,patternUnits:"objectBoundingBox",width:3,x:"0",y:"0",children:y.jsx(or.rect,{animate:{x:uOt},fill:`url(#${e}-grad)`,height:"1",initial:{x:t$},onUpdate:a,transition:{duration:r,ease:"linear",repeat:Number.POSITIVE_INFINITY,repeatType:"loop"},width:"1",y:"0"})}),y.jsx("mask",{id:`${e}-mask`,maskUnits:"userSpaceOnUse",children:y.jsx("rect",{fill:`url(#${e}-pattern)`,height:n,width:t})})]})}function NX({curve:e,withArea:t=!1,mode:n="loop",onTransitionComplete:r,stroke:i=Bo.foreground,strokeOpacity:o=bOt,strokeWidth:s=2,pointCount:a=hOt,durationSeconds:l=aNe}){const{innerWidth:u,innerHeight:c}=_a(),d=uc(),m=`line-sweep-${A.useId().replace(/[^a-zA-Z0-9_-]/g,"")}`,g=n==="loop",[b,v]=A.useState(0),w=A.useCallback(()=>{g&&v(F=>F+1)},[g]),S=A.useMemo(()=>uNe(a,b),[a,b]);if(A.useEffect(()=>{d&&!g&&(r==null||r())},[d,g,r]),u<=0||c<=0||S.length<2)return null;const C=Hh({domain:[0,S.length-1],range:[0,u]}),E=Hh({domain:[0,100],range:[c,0]}),T=S.map((F,z)=>({index:z,value:F})),O=F=>C(F.index),M=F=>E(F.value),N=y.jsxs(y.Fragment,{children:[t?y.jsx(IY,{curve:e,data:T,fill:`url(#${m}-area)`,x:O,y:M,yScale:E}):null,y.jsx(LY,{curve:e,data:T,fill:"none",stroke:i,strokeLinecap:"round",strokeOpacity:o,strokeWidth:s,x:O,y:M})]}),I=t?y.jsxs("linearGradient",{id:`${m}-area`,x1:"0",x2:"0",y1:"0",y2:"1",children:[y.jsx("stop",{offset:"0%",stopColor:i,stopOpacity:vOt}),y.jsx("stop",{offset:"100%",stopColor:i,stopOpacity:xOt})]}):null;if(d)return y.jsxs(y.Fragment,{children:[I?y.jsx("defs",{children:I}):null,N]});const D=`url(#${m}-mask)`,P=y.jsxs("defs",{children:[I,y.jsx(cNe,{chartId:m,durationSeconds:l,height:c,onSweepComplete:w,width:u})]});return g?y.jsxs(y.Fragment,{children:[P,y.jsx("g",{mask:D,children:N})]}):y.jsxs(y.Fragment,{children:[P,y.jsx(or.g,{animate:{opacity:n==="exit"?0:1},initial:{opacity:n==="exit"?1:0},mask:D,onAnimationComplete:r,transition:{duration:oNe,ease:[...tu]},children:N})]})}NX.displayName="LineLoadingSweep";function COt({heights:e,signs:t,innerWidth:n,innerHeight:r,baseline:i,barFraction:o,fill:s,fillOpacity:a}){const l=n/e.length,u=l*o,c=l*(1-o)/2,d=i==="center",h=d?r/2:r,m=d?r/2:r;return y.jsx(y.Fragment,{children:e.map((g,b)=>{const v=d?t[b]??1:1,w=Math.max(1,m*(g/100)),S=b*l+c,C=v===1?h-w:h;return y.jsx("rect",{fill:s,fillOpacity:a,height:w,rx:pOt,width:u,x:S,y:C},`${S.toFixed(2)}-${g}`)})})}function dNe({innerWidth:e,innerHeight:t,barCount:n=mOt,fill:r=gOt,fillOpacity:i=yOt,baseline:o="bottom",barFraction:s=wOt,durationSeconds:a=aNe}){const l=uc(),c=`bar-sweep-${A.useId().replace(/[^a-zA-Z0-9_-]/g,"")}`,[d,h]=A.useState(0),m=A.useCallback(()=>h(w=>w+1),[]),g=A.useMemo(()=>uNe(n,d),[n,d]),b=A.useMemo(()=>SOt(n,d),[n,d]);if(e<=0||t<=0)return null;const v=y.jsx(COt,{barFraction:s,baseline:o,fill:r,fillOpacity:i,heights:g,innerHeight:t,innerWidth:e,signs:b});return l?v:y.jsxs(y.Fragment,{children:[y.jsx("defs",{children:y.jsx(cNe,{chartId:c,durationSeconds:a,height:t,onSweepComplete:m,width:e})}),y.jsx("g",{mask:`url(#${c}-mask)`,children:v})]})}dNe.displayName="BarLoadingSkeleton";const EOt={pathD:null,pathLength:0};function fNe(e,t){const[n,r]=A.useState(EOt);return A.useEffect(()=>{const i=e.current;if(!i)return;const o=i.getAttribute("d"),s=o?i.getTotalLength():0;r(a=>a.pathD===o&&a.pathLength===s?a:{pathD:o,pathLength:s})},t),n}function LX(e,t){return e!=null&&e>=0&&e<t-1}function TOt(e,t,n,r){const i=e[t];return i?n(r(i))??0:0}function AOt({pathD:e,pathLength:t,dashStartLength:n,dashStartX:r,innerWidth:i,innerHeight:o,stroke:s,strokeWidth:a,dashArray:l}){const u=A.useId().replace(/:/g,"");if(!e||t<=0||n>=t)return null;const c=a*2,d=Math.max(0,i-r+c);return y.jsxs(y.Fragment,{children:[y.jsx("defs",{children:y.jsx("clipPath",{id:u,children:y.jsx("rect",{height:o+c,width:d,x:r-a,y:-a})})}),y.jsx("path",{d:e,fill:"none",stroke:s,strokeDasharray:`${n} ${Math.max(1,t-n)}`,strokeLinecap:"round",strokeWidth:a}),y.jsx("path",{clipPath:`url(#${u})`,d:e,fill:"none",stroke:s,strokeDasharray:l,strokeLinecap:"round",strokeWidth:a})]})}function OOt({dashFromIndex:e,dashArray:t,data:n,pathD:r,pathLength:i,innerWidth:o,innerHeight:s,stroke:a,strokeWidth:l,xScale:u,xAccessor:c}){const d=LX(e,n.length),h=A.useMemo(()=>!d||e==null?0:TOt(n,e,u,c),[d,e,n,u,c]),m=A.useMemo(()=>!d||e==null||i<=0?0:e/Math.max(1,n.length-1)*i,[d,e,n.length,i]);return!d||e==null||i<=0?null:y.jsx(AOt,{dashArray:t,dashStartLength:m,dashStartX:h,innerHeight:s,innerWidth:o,pathD:r,pathLength:i,stroke:a,strokeWidth:l})}const hNe=A.memo(OOt);function pNe({pathRef:e,visible:t,stroke:n,strokeWidth:r,height:i,x:o,width:s}){const a=A.useId();return t&&e.current?y.jsxs(y.Fragment,{children:[y.jsx("defs",{children:y.jsx("clipPath",{id:a,children:y.jsx(or.rect,{height:i,width:s,x:o,y:0})})}),y.jsx(or.path,{animate:{opacity:1},clipPath:`url(#${a})`,d:e.current.getAttribute("d")||"",exit:{opacity:0},fill:"none",initial:{opacity:0},stroke:n,strokeLinecap:"round",strokeWidth:r,transition:{duration:.4,ease:"easeInOut"}})]}):null}pNe.displayName="HighlightSegment";const cI={tooltipSpring:{stiffness:300,damping:30},tooltipBoxSpring:{stiffness:100,damping:20},highlightSpring:{stiffness:180,damping:28}},ROt=A.createContext(null);function $b(){return A.useContext(ROt)??cI}const _0=cI.tooltipBoxSpring.damping;function MOt(e){if(e===0)return{animate:!1,springConfig:cI.tooltipBoxSpring};const t=e??_0;let n=cI.tooltipBoxSpring.stiffness;if(t<_0){const r=(_0-t)/_0;n+=r*400}else if(t>_0){const r=(t-_0)/(100-_0);n-=r*85}return{animate:!0,springConfig:{stiffness:Math.max(12,Math.round(n)),damping:t}}}const N_={x:0,width:0,isActive:!1};function _Ot(e,t,n,r,i){if(e.length===0)return N_;if(i!=null&&i.active){const h=Math.min(i.startX,i.endX),m=Math.abs(i.endX-i.startX);return{x:h,width:m,isActive:!0}}if(!r)return N_;const o=r.index,s=Math.max(0,o-1),a=Math.min(e.length-1,o+1),l=e[s],u=e[a];if(!(l&&u))return N_;const c=t(n(l))??0,d=t(n(u))??0;return{x:c,width:Math.max(0,d-c),isActive:!0}}function NOt({enabled:e=!0}={}){const{data:t,xScale:n,xAccessor:r}=_a(),{tooltipData:i,selection:o}=mA(),{highlightSpring:s}=$b(),a=A.useMemo(()=>e?_Ot(t,n,r,i,o):N_,[e,t,n,r,i,o]),l=fl(0,s),u=fl(0,s),c=A.useRef(!1);return a.isActive&&!c.current?(l.jump(a.x),u.jump(a.width)):(l.set(a.x),u.set(a.width)),c.current=a.isActive,{xSpring:l,widthSpring:u,isActive:a.isActive}}function IX({enabled:e,height:t,pathRef:n,stroke:r,strokeWidth:i}){const{isLoaded:o}=_a(),{xSpring:s,widthSpring:a,isActive:l}=NOt({enabled:e});return y.jsx(pNe,{height:t,pathRef:n,stroke:r,strokeWidth:i,visible:e&&l&&o,width:a,x:s})}IX.displayName="SeriesHighlightLayer";const LOt=A.createContext(null);function PX(){return A.useContext(LOt)??{hoveredIndex:null,setHoveredIndex:()=>{}}}function jX({enabled:e=!0,dimOpacity:t=.5,durationSec:n=.4,seriesIndex:r,children:i}){const{tooltipData:o,selection:s}=mA(),{hoveredIndex:a}=PX(),l=o!==null||(s==null?void 0:s.active)===!0,c=e&&(l||a!==null&&r!==void 0&&a!==r)?t:1;return y.jsx(or.g,{animate:{opacity:c},initial:{opacity:1},transition:{duration:n,ease:"easeInOut"},children:i})}jX.displayName="SeriesHoverDim";const mNe="cubic-bezier(0.85, 0, 0.15, 1)",gNe=1100,oT={type:"tween",duration:gNe/1e3,ease:[.85,0,.15,1]};function yNe(e){return(e==null?void 0:e.type)==="tween"?{...e,ease:e.ease??oT.ease}:{type:"tween",duration:typeof(e==null?void 0:e.duration)=="number"?e.duration:gNe/1e3,ease:oT.ease}}function bNe({fill:e,stroke:t,strokeWidth:n,ringGap:r,outlineWidth:i,outlineColor:o,radius:s}){const a=t??e??"currentColor",l=o??a,u=n>0?s+r+n:s,c=i>0?u+i/2:0;return y.jsxs(y.Fragment,{children:[i>0?y.jsx("circle",{cx:0,cy:0,fill:"none",r:c,stroke:l,strokeWidth:i}):null,y.jsx("circle",{cx:0,cy:0,fill:e,r:s}),n>0?y.jsx("circle",{cx:0,cy:0,fill:"none",r:s+r+n/2,stroke:a,strokeWidth:n}):null]})}const vNe=A.memo(function({cx:t,cy:n,scale:r=1,fill:i,stroke:o,strokeWidth:s=2,ringGap:a=2,outlineWidth:l=0,outlineColor:u,radius:c=5}){return y.jsx("g",{transform:`translate(${t}, ${n}) scale(${r})`,children:y.jsx(bNe,{fill:i,outlineColor:u,outlineWidth:l,radius:c,ringGap:a,stroke:o,strokeWidth:s})})});function IOt({dataKey:e,index:t,cx:n,cy:r,enterBlur:i=2,revealDelay:o,revealEpoch:s,enterDuration:a,fill:l,stroke:u,strokeWidth:c=2,ringGap:d=2,outlineWidth:h=0,outlineColor:m,radius:g=5}){const b={hidden:{opacity:0,filter:`blur(${i}px)`,scale:1},visible:{opacity:1,filter:"blur(0px)",scale:1,transition:{delay:o,duration:a,ease:oT.ease}}};return y.jsx("g",{transform:`translate(${n}, ${r})`,children:y.jsx(or.g,{animate:"visible",initial:"hidden",variants:b,children:y.jsx(bNe,{fill:l,outlineColor:m,outlineWidth:h,radius:g,ringGap:d,stroke:u,strokeWidth:c})},`${e}-${t}-${s}`)})}function POt(e){const t=e.radius??5,n=e.strokeWidth??2,r=e.ringGap??2,i=e.outlineWidth??0,o=e.showActiveHighlight??!0,s=n>0?r+n:0,a=i>0?i:0,l=o?t*.35:0;return t+s+a+l+2}function DX({dataKey:e,fill:t,stroke:n,strokeWidth:r=2,ringGap:i=2,outlineWidth:o=0,outlineColor:s,radius:a=5,animate:l=!0,fadeOnHover:u=!0,inactiveOpacity:c=.5,inactiveBlur:d=2,enterBlur:h=2,showActiveHighlight:m=!0}){const{data:g,xScale:b,innerWidth:v,enterTransition:w,animationDuration:S,revealEpoch:C,isLoaded:E,xAccessor:T,lines:O}=_a(),M=A.useMemo(()=>{const G=O.findIndex(le=>le.dataKey===e);return G>=0?G:0},[O,e]),N=O[M],I=pA(N==null?void 0:N.yAxisId),D=D8[M%D8.length]??D8[0],P=t??(N==null?void 0:N.stroke)??D,F=n??P,z=A.useMemo(()=>POt({radius:a,strokeWidth:r,ringGap:i,outlineWidth:o,showActiveHighlight:m}),[a,r,i,o,m]),$=yNe(w).duration??S/1e3,B=.5,H=l&&!E,U=A.useCallback(G=>{const le=G[e];return typeof le=="number"?I(le)??0:null},[e,I]),W=A.useMemo(()=>g.flatMap((G,le)=>{const K=U(G);if(K===null)return[];const te=b(T(G))??0,de=Math.max(0,te-z),ue=v>0&&H?de/v*$:0;return[{index:le,cx:te,cy:K,revealDelay:ue}]}),[g,U,b,T,v,H,$,z]),q=A.useMemo(()=>({fill:P,stroke:F,strokeWidth:r,ringGap:i,outlineWidth:o,outlineColor:s,radius:a}),[P,F,r,i,o,s,a]);if(H)return y.jsx("g",{children:W.map(G=>y.jsx(IOt,{cx:G.cx,cy:G.cy,dataKey:e,enterBlur:h,enterDuration:B,index:G.index,revealDelay:G.revealDelay,revealEpoch:C??0,...q},`${e}-${G.index}`))});const Y=W.map(G=>y.jsx(vNe,{cx:G.cx,cy:G.cy,...q},`${e}-${G.index}`)),Q=m?1.35:1;return y.jsxs("g",{children:[y.jsx(jOt,{enabled:u,inactiveBlur:d,inactiveOpacity:c,seriesIndex:M,children:Y}),y.jsx(DOt,{activeScale:Q,enabled:u,markerStyle:q,points:W})]})}DX.displayName="SeriesMarkers";function jOt({enabled:e,inactiveOpacity:t,inactiveBlur:n,seriesIndex:r,children:i}){const{tooltipData:o}=mA(),{hoveredIndex:s}=PX(),l=e&&(o!==null||s!==null&&s!==r);return y.jsx("g",{opacity:l?t:1,style:{transition:"opacity 0.15s ease-in-out, filter 0.15s ease-in-out",filter:l&&n>0?`blur(${n}px)`:"none"},children:i})}function DOt({enabled:e,points:t,markerStyle:n,activeScale:r}){const{tooltipData:i}=mA();if(!e||i===null)return null;const o=t.find(s=>s.index===i.index);return o?y.jsx(vNe,{cx:o.cx,cy:o.cy,scale:r,...n}):null}function $Ot(e,t,n,r){const i=sNe(e),o=t===!1?null:n??(t===!0?"loop":i),s=o!=null,a=e==="revealing"||e==="ready"||e==="exitingReady",[l,u]=A.useState(0);return{handleLoadingPulseComplete:A.useCallback(()=>{if(o==="loop"){window.setTimeout(()=>{u(d=>d+1)},MX);return}r==null||r()},[r,o]),pulseMode:o,pulseEpoch:l,showLoadingPulse:s,showSeriesContent:a}}function $X({dataKey:e,yAxisId:t,fill:n=Bo.linePrimary,fillOpacity:r=.4,stroke:i,strokeWidth:o=2,curve:s=NY,animate:a=!0,showLine:l=!0,showHighlight:u=!0,gradientToOpacity:c=0,gradientSpan:d=1,fadeEdges:h=!1,showMarkers:m=!1,markers:g,dashFromIndex:b,dashArray:v="6,4",loading:w,loadingStroke:S=Bo.foreground,loadingStrokeOpacity:C=.5,loadingPulseMode:E,loadingStyle:T="pulse"}){const{data:O,renderData:M,xScale:N,innerHeight:I,innerWidth:D,xAccessor:P,lines:F,chartPhase:z,notifyLoadingPulseComplete:$}=_a(),B=pA(t),{handleLoadingPulseComplete:H,pulseMode:U,pulseEpoch:W,showLoadingPulse:q,showSeriesContent:Y}=$Ot(z,w,E,$),Q=A.useMemo(()=>{const _e=F.findIndex(He=>He.dataKey===e);return _e>=0?_e:0},[F,e]),G=A.useRef(null),{pathLength:le,pathD:K}=fNe(G,[M,D,b,l,Y,q]),te=A.useId(),de=`area-gradient-${e}-${te}`,ue=`area-stroke-gradient-${e}-${te}`,ae=`area-edge-mask-${e}-${te}`,ie=`${ae}-gradient`,he=n.startsWith("url("),fe=he||r>0,se=he?n:`url(#${de})`,Se=i||(he?Bo.linePrimary:n),pe=A.useCallback(_e=>{const He=_e[e];return typeof He=="number"?B(He)??0:0},[e,B]),Ee=LX(b,O.length),ke=Hj(h),Ie=ke.any&&!he;let Be=Se;!Ie&&ke.any&&(Be=`url(#${ue})`);const Oe=u&&l&&!q&&Y,Le=Y&&l;let ge="transparent";Le&&!Ee&&(ge=Be);const $e=l&&(Y||q),Ye=y.jsxs(y.Fragment,{children:[Y&&fe?y.jsx(IY,{curve:s,data:M,fill:se,x:_e=>N(P(_e))??0,y:pe,yScale:B}):null,$e?y.jsxs(y.Fragment,{children:[y.jsx(LY,{curve:s,data:M,innerRef:G,stroke:ge,strokeLinecap:"round",strokeWidth:o,x:_e=>N(P(_e))??0,y:pe}),Le?y.jsx(hNe,{dashArray:v,dashFromIndex:b,data:O,innerHeight:I,innerWidth:D,pathD:K,pathLength:le,stroke:Be,strokeWidth:o,xAccessor:P,xScale:N}):null]}):null]}),tt=q&&D>0&&T==="sweep",Ae=q&&D>0&&!tt;return y.jsxs(y.Fragment,{children:[y.jsx(Ixt,{edgeGradientId:ie,edgeMaskId:ae,fadeEdges:h,fill:n,fillOpacity:r,gradientId:de,gradientSpan:d,gradientToOpacity:c,innerHeight:I,innerWidth:D,isPatternFill:he,resolvedStroke:Se,strokeGradientId:ue}),y.jsx(jX,{dimOpacity:.6,enabled:u,seriesIndex:Q,children:Ie?y.jsx("g",{mask:`url(#${ae})`,children:Ye}):Ye}),y.jsx(IX,{enabled:Oe,height:I,pathRef:G,stroke:Se,strokeWidth:o}),m&&Y?y.jsx(DX,{animate:a,dataKey:e,...g,fill:(g==null?void 0:g.fill)??Se,stroke:(g==null?void 0:g.stroke)??(g==null?void 0:g.fill)??Se}):null,tt?y.jsx(NX,{curve:s,mode:U??"loop",onTransitionComplete:H,stroke:S,strokeOpacity:C,strokeWidth:o,withArea:!0},"loading-sweep"):null,Ae&&K?y.jsx(_X,{loopEpoch:W,mode:U??void 0,onCycleComplete:H,pathD:K,stroke:S,strokeOpacity:C,strokeWidth:o},"loading-pulse"):null]})}$X.displayName="Area";var n$,ede;function Vg(){if(ede)return n$;ede=1;function e(t){var n=typeof t;return t!=null&&(n=="object"||n=="function")}return n$=e,n$}var r$,tde;function xNe(){if(tde)return r$;tde=1;var e=typeof qO=="object"&&qO&&qO.Object===Object&&qO;return r$=e,r$}var i$,nde;function Hd(){if(nde)return i$;nde=1;var e=xNe(),t=typeof self=="object"&&self&&self.Object===Object&&self,n=e||t||Function("return this")();return i$=n,i$}var o$,rde;function zOt(){if(rde)return o$;rde=1;var e=Hd(),t=function(){return e.Date.now()};return o$=t,o$}var s$,ide;function FOt(){if(ide)return s$;ide=1;var e=/\s/;function t(n){for(var r=n.length;r--&&e.test(n.charAt(r)););return r}return s$=t,s$}var a$,ode;function BOt(){if(ode)return a$;ode=1;var e=FOt(),t=/^\s+/;function n(r){return r&&r.slice(0,e(r)+1).replace(t,"")}return a$=n,a$}var l$,sde;function SA(){if(sde)return l$;sde=1;var e=Hd(),t=e.Symbol;return l$=t,l$}var u$,ade;function HOt(){if(ade)return u$;ade=1;var e=SA(),t=Object.prototype,n=t.hasOwnProperty,r=t.toString,i=e?e.toStringTag:void 0;function o(s){var a=n.call(s,i),l=s[i];try{s[i]=void 0;var u=!0}catch{}var c=r.call(s);return u&&(a?s[i]=l:delete s[i]),c}return u$=o,u$}var c$,lde;function UOt(){if(lde)return c$;lde=1;var e=Object.prototype,t=e.toString;function n(r){return t.call(r)}return c$=n,c$}var d$,ude;function Jh(){if(ude)return d$;ude=1;var e=SA(),t=HOt(),n=UOt(),r="[object Null]",i="[object Undefined]",o=e?e.toStringTag:void 0;function s(a){return a==null?a===void 0?i:r:o&&o in Object(a)?t(a):n(a)}return d$=s,d$}var f$,cde;function ep(){if(cde)return f$;cde=1;function e(t){return t!=null&&typeof t=="object"}return f$=e,f$}var h$,dde;function uS(){if(dde)return h$;dde=1;var e=Jh(),t=ep(),n="[object Symbol]";function r(i){return typeof i=="symbol"||t(i)&&e(i)==n}return h$=r,h$}var p$,fde;function wNe(){if(fde)return p$;fde=1;var e=BOt(),t=Vg(),n=uS(),r=NaN,i=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,s=/^0o[0-7]+$/i,a=parseInt;function l(u){if(typeof u=="number")return u;if(n(u))return r;if(t(u)){var c=typeof u.valueOf=="function"?u.valueOf():u;u=t(c)?c+"":c}if(typeof u!="string")return u===0?u:+u;u=e(u);var d=o.test(u);return d||s.test(u)?a(u.slice(2),d?2:8):i.test(u)?r:+u}return p$=l,p$}var m$,hde;function SNe(){if(hde)return m$;hde=1;var e=Vg(),t=zOt(),n=wNe(),r="Expected a function",i=Math.max,o=Math.min;function s(a,l,u){var c,d,h,m,g,b,v=0,w=!1,S=!1,C=!0;if(typeof a!="function")throw new TypeError(r);l=n(l)||0,e(u)&&(w=!!u.leading,S="maxWait"in u,h=S?i(n(u.maxWait)||0,l):h,C="trailing"in u?!!u.trailing:C);function E(z){var $=c,B=d;return c=d=void 0,v=z,m=a.apply(B,$),m}function T(z){return v=z,g=setTimeout(N,l),w?E(z):m}function O(z){var $=z-b,B=z-v,H=l-$;return S?o(H,h-B):H}function M(z){var $=z-b,B=z-v;return b===void 0||$>=l||$<0||S&&B>=h}function N(){var z=t();if(M(z))return I(z);g=setTimeout(N,O(z))}function I(z){return g=void 0,C&&c?E(z):(c=d=void 0,m)}function D(){g!==void 0&&clearTimeout(g),v=0,c=b=d=g=void 0}function P(){return g===void 0?m:I(t())}function F(){var z=t(),$=M(z);if(c=arguments,d=this,b=z,$){if(g===void 0)return T(b);if(S)return clearTimeout(g),g=setTimeout(N,l),E(b)}return g===void 0&&(g=setTimeout(N,l)),m}return F.cancel=D,F.flush=P,F}return m$=s,m$}var VOt=SNe();const WOt=cr(VOt),qOt=[],pde={width:0,height:0,top:0,left:0};function GOt(){let{initialSize:e=pde,debounceTime:t=300,ignoreDimensions:n=qOt,enableDebounceLeadingCall:r=!0,resizeObserverPolyfill:i}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const o=A.useRef(null),s=A.useRef(0),[a,l]=A.useState({...pde,...e}),u=A.useMemo(()=>{const c=Array.isArray(n)?n:[n];return WOt(d=>{l(h=>Object.keys(h).filter(v=>h[v]!==d[v]).every(v=>c.includes(v))?h:d)},t,{leading:r})},[t,r,n]);return A.useEffect(()=>{const c=i||window.ResizeObserver,d=new c(h=>{h.forEach(m=>{const{left:g,top:b,width:v,height:w}=(m==null?void 0:m.contentRect)??{};s.current=window.requestAnimationFrame(()=>{u({width:v,height:w,top:b,left:g})})})});return o.current&&d.observe(o.current),()=>{window.cancelAnimationFrame(s.current),d.disconnect(),u.cancel()}},[u,i]),{parentRef:o,resize:u,...a}}const KOt={width:"100%",height:"100%"};function zX(e){let{className:t,children:n,debounceTime:r,ignoreDimensions:i,initialSize:o,parentSizeStyles:s=KOt,enableDebounceLeadingCall:a=!0,resizeObserverPolyfill:l,...u}=e;const{parentRef:c,resize:d,...h}=GOt({initialSize:o,debounceTime:r,ignoreDimensions:i,enableDebounceLeadingCall:a,resizeObserverPolyfill:l});return y.jsx("div",{style:s,ref:c,className:t,...u,children:n({...h,ref:c.current,resize:d})})}function YOt({text:e,duration:t=1,isStopped:n=!1,paused:r=!1,className:i,...o}){const s=uc(),a=n||r||s===!0,l=A.useCallback(u=>({running:{color:["var(--color)","var(--shimmering-color)","var(--color)"],transition:{duration:t,repeat:Number.POSITIVE_INFINITY,repeatType:"loop",repeatDelay:e.length*.05,delay:u*t/e.length,ease:"easeInOut"}},stopped:{color:"var(--color)",transition:{duration:t*.5,ease:"easeOut"}}}),[t,e.length]);return y.jsxs(or.span,{className:X("inline-flex select-none items-center leading-none","[--color:var(--muted-foreground)] [--shimmering-color:var(--foreground)]",i),...o,children:[e.split("").map((u,c)=>y.jsx(or.span,{animate:a?"stopped":"running","aria-hidden":!0,className:"inline-block whitespace-pre leading-none",initial:"stopped",variants:l(c),children:u},c)),y.jsx("span",{className:"sr-only",children:e})]})}function kNe({text:e="Loading",className:t,exiting:n=!1}){return e.trim()?y.jsx(or.div,{animate:{y:n?aOt:0,opacity:n?0:1,filter:n?"blur(2px)":"blur(0px)"},"aria-live":"polite",className:X("pointer-events-none absolute inset-0 flex items-center justify-center",t),initial:!1,role:"status",transition:{duration:oNe,ease:[...tu]},children:y.jsx(YOt,{className:"font-medium text-sm tracking-wide [--color:var(--muted-foreground)] [--shimmering-color:var(--foreground)]",text:e})}):null}const FX="ready",kA=500,mde=.02;function hD(e){return e==="loading"?"loading":"ready"}function XOt(e){return e==="ready"}const QOt={chartPhase:"ready",chartStatus:"ready",loadingLabel:void 0,yDomainTweenDuration:kA,yDomainSkeletonByAxis:{left:[0,100]},yDomainTargetByAxis:{left:[0,100]}};function CNe({dataKey:e,fill:t,curve:n=NY}){const{renderData:r,xScale:i,yScale:o,xAccessor:s}=_a();return y.jsx(IY,{curve:n,data:r,fill:t,x:a=>i(s(a))??0,y:a=>{const l=a[e];return typeof l=="number"?o(l)??0:0},yScale:o})}CNe.displayName="PatternArea";const ZOt="__chartClipPassthrough";function BX(e){return typeof e=="function"&&e[ZOt]===!0}function HX(e){if(BX(e.type)){const t=e.props.children;if(A.isValidElement(t))return HX(t)}return e}function ENe(e,t){let n=0;const r=i=>{A.Children.forEach(i,o=>{if(A.isValidElement(o)){if(o.type===A.Fragment){r(o.props.children);return}t(o,n),n+=1}})};r(e)}const JOt=new Set(["Background","Grid","XAxis","YAxis","BarXAxis","BarYAxis","LiveXAxis","LiveYAxis"]),eRt=new Set(["ReferenceArea","BarColumnTrack"]);function TNe(e){const t=e.type;if(t.__isChartMarkers||t.__isPostOverlay)return!0;const n=typeof e.type=="function"&&(t.displayName||t.name)||"";return n==="ChartMarkers"||n==="MarkerGroup"||n==="ChartBrush"}function ANe(e){const t=e.type,n=typeof e.type=="function"&&(t.displayName||t.name)||"";return eRt.has(n)}function ONe(e){const t=e.type,n=typeof e.type=="function"&&(t.displayName||t.name)||"";return JOt.has(n)}function dM(e){return e.map((t,n)=>A.cloneElement(t,{key:t.key??`chart-layer-${n}`}))}function RNe(e){const t=e.type;return typeof e.type=="function"&&(t.displayName||t.name)||""}const tRt=new Set(["Lines","Circles","Waves","Hexagons","Path","Pattern"]);function MNe(e){const t=RNe(e);return t.includes("Pattern")||tRt.has(t)}function _Ne(e){const t=RNe(e);return t.includes("Gradient")||t==="LinearGradient"||t==="RadialGradient"}const Ag=new Intl.DateTimeFormat("en-US",{month:"short",day:"numeric"}),nRt=new Intl.DateTimeFormat("en-US",{weekday:"short",month:"short",day:"numeric"}),rRt=new Intl.NumberFormat("en-US").format;function iRt({clipPathId:e,height:t,targetWidth:n,enterTransition:r,revealEpoch:i,padding:o=0,animating:s=!0,mode:a="reveal",onComplete:l}){const u=yNe(r),c=Math.max(0,n+o*2),d=t+o*2;if(!s)return y.jsx("clipPath",{id:e,children:y.jsx("rect",{height:d,width:c,x:-o,y:-o})});if(a==="conceal"){const h=-o+c;return y.jsx("clipPath",{id:e,children:y.jsx(or.rect,{animate:{width:0,x:h},height:d,initial:{width:c,x:-o},onAnimationComplete:()=>l==null?void 0:l(),transition:u,y:-o},`conceal-${i}`)})}return y.jsx("clipPath",{id:e,children:y.jsx(or.rect,{animate:{width:c},height:d,initial:{width:0},transition:u,width:c,x:-o,y:-o},`reveal-${i}`)})}function oRt(e,t,n=[]){const r=e.length;if(t>=r||t<3)return e;const i=(l,u)=>{if(n.length===0){for(const h of Object.values(l))if(typeof h=="number")return h;return u}let c=0,d=0;for(const h of n){const m=l[h];typeof m=="number"&&(c+=m,d++)}return d>0?c/d:u},o=[e[0]],s=(r-2)/(t-2);let a=0;for(let l=0;l<t-2;l++){const u=Math.floor((l+1)*s)+1,c=Math.min(Math.floor((l+2)*s)+1,r-1),d=Math.floor((l+2)*s)+1,h=Math.min(Math.floor((l+3)*s)+1,r),m=Math.max(0,h-d);let g=r-1,b=i(e[r-1],r-1);if(m>0){g=0,b=0;for(let T=d;T<h;T++)g+=T,b+=i(e[T],T);g/=m,b/=m}const v=e[a],w=a,S=i(v,a);let C=-1,E=u;for(let T=u;T<c;T++){const O=Math.abs((w-g)*(i(e[T],T)-S)-(w-T)*(b-S))*.5;O>C&&(C=O,E=T)}o.push(e[E]),a=E}return o.push(e[r-1]),o}function sRt(e){return Math.max(64,Math.ceil(e*1.5))}function aRt(e,t,n){const r=t[0].getTime(),i=t[1].getTime(),o=Math.min(r,i),s=Math.max(r,i);return e.filter(a=>{const l=n(a).getTime();return l>=o&&l<=s})}const lRt="value",uRt=7;function cRt(e={}){const t=e.dataKey??lRt,n=e.pointCount??uRt,r=e.baseDate??new Date("2025-01-01");return Array.from({length:n},(i,o)=>{const s=new Date(r);return s.setDate(r.getDate()+o),{date:s,[t]:Math.round(110+Math.sin(o*1.15)*36+o*9)}})}function dRt(e,t){return e.map((n,r)=>({...n,[t]:Math.round(95+Math.sin(r*1.05)*28+r*7)}))}function fRt(e){let t=Number.POSITIVE_INFINITY,n=Number.NEGATIVE_INFINITY;for(const r of e)for(const i of r)i.value<t&&(t=i.value),i.value>n&&(n=i.value);return t===Number.POSITIVE_INFINITY?null:{minValue:t,maxValue:n}}function hRt(e){let t=Number.POSITIVE_INFINITY,n=Number.NEGATIVE_INFINITY;for(const r of e)for(const i of r){const o=i.date.getTime();o<t&&(t=o),o>n&&(n=o)}return t===Number.POSITIVE_INFINITY?null:{minTime:t,maxTime:n}}function pRt(e){const t=e.type;return typeof e.type=="function"&&(t.displayName||t.name)||""}function mRt(e){return pRt(e)==="ProjectionLine"}function gRt(e){return e!=null&&e.length?e.map(t=>({date:t.date instanceof Date?t.date:new Date(t.date),value:t.value})):[]}function yRt(e){const t=[],n=r=>{A.Children.forEach(r,i=>{if(!A.isValidElement(i))return;if(i.type===A.Fragment){n(i.props.children);return}if(mRt(i)){const s=i.props,a=gRt(s==null?void 0:s.data);a.length>=2&&t.push({yAxisId:ph(s==null?void 0:s.yAxisId),data:a});return}if(BX(i.type)){n(i.props.children);return}const o=i.props;o!=null&&o.children&&n(o.children)})};return n(e),t}function gde(e,t,n){const r=t.filter(c=>c.yAxisId===n).map(c=>c.data),i=fRt(r);if(!i)return e;const[o,s]=e,a=Math.min(o,i.minValue),l=Math.max(s,i.maxValue);if(a>=0&&o>=0)return[0,l<=0?100:l*1.1];const u=(l-a)*.05||1;return[a-u,l+u]}function bRt(e,t){const n=t.map(i=>i.data),r=hRt(n);return r?Math.max(e,r.maxTime):e}function vRt(e){const t=e.type;return typeof e.type=="function"&&(t.displayName||t.name)||""}function xRt(e){return vRt(e)==="ReferenceArea"}function NNe(e){const t=[],n=r=>{A.Children.forEach(r,i=>{if(!A.isValidElement(i))return;if(xRt(i)){const s=i.props;s&&t.push({yAxisId:ph(s.yAxisId),y1:s.y1,y2:s.y2,axisLabelColor:s.axisLabelColor});return}const o=i.props;o!=null&&o.children&&n(o.children)})};return n(e),t}const wRt=A.createContext(null);function SRt(e){const{innerWidth:t,dataLength:n,columnWidth:r,seriesCount:i,composedBarSize:o,composedMaxBarSize:s,composedBarGap:a=4,stacked:l=!1}=e,u=a,c=l?1:Math.max(1,i);let d=r;d<=0&&(d=n<2?t:t/(n-1));let h=o??Math.min(d*.88,s??Number.POSITIVE_INFINITY);if(s!=null&&(h=Math.min(h,s)),c>1){const m=d*.92;c*h+(c-1)*u>m&&m>0&&(h=Math.max(4,(m-(c-1)*u)/c))}return Math.max(2,h)}function kRt(e){const{barWidth:t,seriesCount:n,gap:r=4,stacked:i=!1}=e;if(i||n<=1)return Math.ceil(t/2);const o=n*t+(n-1)*r;return Math.ceil(o/2)}const CRt=A.createContext(!1);function ERt(){return A.useContext(CRt)}function yde(e){const n=Hh({domain:e,range:[0,1],nice:!0}).domain();return[n[0]??e[0],n[1]??e[1]]}function bde(e,t){const n=Math.max(Math.abs(t[1]-t[0]),Math.abs(e[1]-e[0]),1),r=Math.abs(t[0]-e[0])/n,i=Math.abs(t[1]-e[1])/n;return r>=mde||i>=mde}function TRt(e){return e==="loading"||e==="revealingLoading"}function ARt(e){return e==="loading"||e==="exiting"||e==="gridTweenLoading"}function ORt(e){return e==="gridTweenLoading"||e==="gridTweenReady"}function RRt(e,t,n){switch(e){case"loading":case"exiting":case"gridTweenLoading":return t;case"exitingReady":case"gridTweenReady":case"revealing":case"ready":return n;default:return n}}function vde({lines:e,resolveDomain:t}){const n=nD(e),r={};for(const[i,o]of n){const s=o.map(a=>a.dataKey);r[ph(i)]=yde(t(s))}return r.left||(r.left=yde([0,100])),r}function LNe(e,t){const n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(const i of n){const o=e[i],s=t[i];if(!(o&&s)||o[0]!==s[0]||o[1]!==s[1])return!1}return!0}function MRt(e,t,n){return[e[0]+(t[0]-e[0])*n,e[1]+(t[1]-e[1])*n]}function um(e,t,n){LNe(n.current,e)||(t(e),n.current=e)}function xde({destination:e,durationMs:t,enabled:n,reducedMotion:r,animatedRef:i,setAnimatedByAxis:o,onSettled:s}){if(LNe(i.current,e)){s==null||s();return}if(!n||r){um(e,o,i),s==null||s();return}const a=Object.keys(e),l=i.current;let u=!1;for(const h of a){const m=l[h]??e[h]??[0,100],g=e[h]??m;if(bde(m,g)){u=!0;break}}if(!u){um(e,o,i),s==null||s();return}const c={};for(const h of a)c[h]=l[h]??e[h]??[0,100];return mh(0,1,{duration:t/1e3,ease:[...tu],onUpdate:h=>{const m={};for(const g of a){const b=c[g]??e[g]??[0,100],v=e[g]??b;m[g]=bde(b,v)?MRt(b,v,h):v}i.current=m,o(m)},onComplete:()=>{um(e,o,i),s==null||s()}})}function _Rt({enabled:e,durationMs:t,chartPhase:n,skeletonByAxis:r,targetByAxis:i,onSettled:o,tweenOnTargetChange:s=!1}){const a=uc(),l=RRt(n,r,i),u=A.useRef(l);u.current=l;const c=A.useRef(r);c.current=r;const d=A.useRef(i);d.current=i;const[h,m]=A.useState(l),g=A.useRef(h),b=A.useRef(n),v=A.useRef(o);v.current=o,A.useEffect(()=>{g.current=h},[h]),A.useEffect(()=>{if(b.current===n)return;b.current=n;const C=()=>{var T;(T=v.current)==null||T.call(v)};if(n==="exiting"){um(c.current,m,g);return}if(n==="exitingReady"){um(d.current,m,g);return}if(n==="loading"){um(c.current,m,g);return}if(n==="revealing"||n==="ready"){um(d.current,m,g);return}if(!ORt(n))return;const E=xde({destination:u.current,durationMs:t,enabled:e,reducedMotion:a,animatedRef:g,setAnimatedByAxis:m,onSettled:C});return()=>E==null?void 0:E.stop()},[n,t,e,a]);const w=JSON.stringify(i),S=A.useRef(w);return A.useEffect(()=>{if(!(n==="ready"||n==="revealing")){S.current=w;return}if(S.current!==w){if(S.current=w,s&&n==="ready"){const E=xde({destination:d.current,durationMs:t,enabled:e,reducedMotion:a,animatedRef:g,setAnimatedByAxis:m,onSettled:()=>{var T;return(T=v.current)==null?void 0:T.call(v)}});return()=>E==null?void 0:E.stop()}um(d.current,m,g)}},[n,t,e,a,w,s]),h}class aw{constructor(t){ne(this,"x",0);ne(this,"y",0);let{x:n=0,y:r=0}=t;this.x=n,this.y=r}value(){return{x:this.x,y:this.y}}toArray(){return[this.x,this.y]}}function NRt(e){return!!e&&e instanceof Element}function LRt(e){return!!e&&(e instanceof SVGElement||"ownerSVGElement"in e)}function IRt(e){return!!e&&"createSVGPoint"in e}function PRt(e){return!!e&&"getScreenCTM"in e}function jRt(e){return!!e&&"changedTouches"in e}function DRt(e){return!!e&&"clientX"in e}function $Rt(e){return!!e&&(e instanceof Event||"nativeEvent"in e&&e.nativeEvent instanceof Event)}const g$={x:0,y:0};function zRt(e){if(!e)return{...g$};if(jRt(e))return e.changedTouches.length>0?{x:e.changedTouches[0].clientX,y:e.changedTouches[0].clientY}:{...g$};if(DRt(e))return{x:e.clientX,y:e.clientY};const t=e==null?void 0:e.target,n=t&&"getBoundingClientRect"in t?t.getBoundingClientRect():null;return n?{x:n.x+n.width/2,y:n.y+n.height/2}:{...g$}}function wde(e,t){if(!e||!t)return null;const n=zRt(t),r=LRt(e)?e.ownerSVGElement:e,i=PRt(r)?r.getScreenCTM():null;if(IRt(r)&&i){let s=r.createSVGPoint();return s.x=n.x,s.y=n.y,s=s.matrixTransform(i.inverse()),new aw({x:s.x,y:s.y})}const o=e.getBoundingClientRect();return new aw({x:n.x-o.left-e.clientLeft,y:n.y-o.top-e.clientTop})}function $V(e,t){if(NRt(e)&&t)return wde(e,t);if($Rt(e)){const n=e,r=n.target;if(r)return wde(r,n)}return null}function FRt(e){if(typeof e=="object"&&e!==null&&"index"in e&&typeof e.index=="number"){const{index:t,x:n}=e;return typeof n=="number"?`${t}:${Math.round(n)}`:String(t)}return JSON.stringify(e)}function INe(){const[e,t]=A.useState(null),n=A.useRef(null),r=A.useRef(null),i=A.useRef(null),o=A.useRef(null);A.useEffect(()=>()=>{i.current!==null&&cancelAnimationFrame(i.current)},[]);const s=A.useCallback((c,d)=>{d!==n.current&&(n.current=d,t(c))},[]),a=A.useCallback((c,d)=>{const h=d??FRt(c);r.current=c,o.current=h,h!==n.current&&i.current===null&&(i.current=requestAnimationFrame(()=>{i.current=null;const m=r.current,g=o.current;m&&g&&s(m,g)}))},[s]),l=A.useCallback(()=>{i.current!==null&&(cancelAnimationFrame(i.current),i.current=null),r.current=null,o.current=null,n.current=null,t(null)},[]),u=A.useCallback(()=>{n.current=null},[]);return{tooltipData:e,setTooltipData:t,scheduleTooltip:a,clearTooltip:l,resetTooltipDedupe:u}}function BRt({xScale:e,yScale:t,yScales:n,data:r,lines:i,margin:o,xAccessor:s,bisectDate:a,canInteract:l}){const[u,c]=A.useState(null),{tooltipData:d,setTooltipData:h,scheduleTooltip:m,clearTooltip:g,resetTooltipDedupe:b}=INe(),v=A.useRef(!1),w=A.useRef(0),S=A.useRef(null),C=A.useCallback(H=>{const U=e.invert(H),W=a(r,U,1),q=r[W-1],Y=r[W];if(!q)return null;let Q=q,G=W-1;if(Y){const K=s(q).getTime(),te=s(Y).getTime();U.getTime()-K>te-U.getTime()&&(Q=Y,G=W)}const le={};for(const K of i){const te=Q[K.dataKey];if(typeof te=="number"){const de=n[ph(K.yAxisId)]??t;le[K.dataKey]=de(te)??0}}return{point:Q,index:G,x:e(s(Q))??0,yPositions:le}},[e,t,n,r,i,s,a]),E=A.useCallback(H=>{const U=e.invert(H),W=a(r,U,1),q=r[W-1],Y=r[W];if(!q)return 0;if(Y){const Q=s(q).getTime(),G=s(Y).getTime();if(U.getTime()-Q>G-U.getTime())return W}return W-1},[e,r,s,a]),T=A.useCallback((H,U=0)=>{let W=null;if("touches"in H){const q=H.touches[U];if(!q)return null;const Y=H.currentTarget.ownerSVGElement;if(!Y)return null;W=$V(Y,q)}else W=$V(H);return W?W.x-o.left:null},[o.left]),O=A.useCallback(H=>{const U=T(H);if(U===null)return;if(v.current){const q=Math.min(w.current,U),Y=Math.max(w.current,U);c({startX:q,endX:Y,startIndex:E(q),endIndex:E(Y),active:!0});return}S.current=U;const W=C(U);W&&m(W)},[T,C,E,m]),M=A.useCallback(()=>{S.current=null,g(),v.current&&(v.current=!1),c(null)},[g]),N=A.useCallback(H=>{const U=T(H);U!==null&&(v.current=!0,w.current=U,g(),c(null))},[T,g]),I=A.useCallback(()=>{v.current&&(v.current=!1),c(null)},[]),D=A.useCallback(H=>{if(H.touches.length===1){H.preventDefault();const U=T(H,0);if(U===null)return;S.current=U;const W=C(U);W&&m(W)}else if(H.touches.length===2){H.preventDefault(),b(),g();const U=T(H,0),W=T(H,1);if(U===null||W===null)return;const q=Math.min(U,W),Y=Math.max(U,W);c({startX:q,endX:Y,startIndex:E(q),endIndex:E(Y),active:!0})}},[T,C,E,m,b,g]),P=A.useCallback(H=>{if(H.touches.length===1){H.preventDefault();const U=T(H,0);if(U===null)return;S.current=U;const W=C(U);W&&m(W)}else if(H.touches.length===2){H.preventDefault();const U=T(H,0),W=T(H,1);if(U===null||W===null)return;const q=Math.min(U,W),Y=Math.max(U,W);c({startX:q,endX:Y,startIndex:E(q),endIndex:E(Y),active:!0})}},[T,C,E,m]),F=A.useCallback(()=>{g(),c(null)},[g]),z=A.useCallback(()=>{c(null)},[]);return A.useEffect(()=>{if(!l||S.current===null)return;const H=C(S.current);if(H){m(H,`${H.index}:${Math.round(H.x)}`);return}g()},[l,g,C,m]),{tooltipData:d,setTooltipData:h,selection:u,clearSelection:z,interactionHandlers:l?{onMouseMove:O,onMouseLeave:M,onMouseDown:N,onMouseUp:I,onTouchStart:D,onTouchMove:P,onTouchEnd:F}:{},interactionStyle:{cursor:l?"crosshair":"default",touchAction:"none"}}}function HRt({chartStatus:e,targetData:t,skeletonData:n,animationDuration:r,yDomainTweenDuration:i,revealSignature:o="",skipEnterReveal:s=!1}){const[a,l]=A.useState(()=>hD(e)),[u,c]=A.useState(()=>e==="loading"?n:t),[d,h]=A.useState(0),[m,g]=A.useState(0),[b,v]=A.useState(()=>e==="ready"),w=A.useRef(e),S=A.useRef(a);S.current=a,A.useEffect(()=>{const O=w.current;if(O!==e){if(w.current=e,e==="ready"&&O==="loading"){v(!1),r<=0?i<=0?(c(t),l("revealing")):l("gridTweenReady"):l("exiting");return}e==="loading"&&O==="ready"&&(v(!1),r<=0?i<=0?(c(n),l("loading")):l("gridTweenLoading"):(g(M=>M+1),l("exitingReady")))}},[r,e,n,t,i]),A.useEffect(()=>{s||e==="ready"&&S.current==="ready"&&(l("revealing"),v(!1))},[r,e,o,s]),A.useEffect(()=>{switch(a){case"loading":e==="loading"&&c(n);break;case"exiting":c(n);break;case"exitingReady":case"gridTweenLoading":case"gridTweenReady":case"revealing":case"ready":c(t);break}},[a,e,n,t]);const C=A.useCallback(()=>{S.current==="exiting"&&l("gridTweenReady")},[]),E=A.useCallback(()=>{S.current==="exitingReady"&&l("gridTweenLoading")},[]),T=A.useCallback(()=>{if(S.current==="gridTweenLoading"){l("loading");return}S.current==="gridTweenReady"&&l("revealing")},[]);return A.useEffect(()=>{if(a!=="revealing")return;if(h(M=>M+1),r<=0){l("ready"),v(!0);return}const O=window.setTimeout(()=>{l("ready"),v(!0)},r);return()=>window.clearTimeout(O)},[r,a]),{chartPhase:a,plotData:u,revealEpoch:d,concealEpoch:m,isLoaded:b,notifyLoadingPulseComplete:C,notifyRevealConcealComplete:E,notifyYDomainTweenComplete:T}}function URt(e,t){let n=Number.POSITIVE_INFINITY,r=Number.NEGATIVE_INFINITY;for(const i of e)for(const o of t){const s=i[o];typeof s=="number"&&(s<n&&(n=s),s>r&&(r=s))}return n===Number.POSITIVE_INFINITY?{minValue:0,maxValue:100}:{minValue:n,maxValue:r}}function VRt(e,t,n){if(n!=null&&n>0)return[0,n*1.1];const{minValue:r,maxValue:i}=URt(e,t);if(r>=0)return[0,i<=0?100:i*1.1];const o=(i-r)*.05||1;return[r-o,i+o]}function WRt(e,t){return e.key!=null?e:A.cloneElement(e,{key:`chart-child-${t}`})}function PNe(e){const{width:t,height:n}=e;return t<10||n<10?null:y.jsx(qRt,{...e})}const qRt=A.memo(function({width:t,height:n,data:r,xDataKey:i,margin:o,animationDuration:s,animationEasing:a=mNe,enterTransition:l,revealSignature:u="",children:c,containerRef:d,lines:h,clipPathId:m,composedBarDataKeys:g,composedBarSize:b,composedMaxBarSize:v,composedBarGap:w,composedStacked:S,composedStackOffsets:C,composedStackGap:E,yScaleDomainMax:T,chartStatus:O=FX,loadingLabel:M,yDomainTween:N=!0,yDomainTweenDuration:I=kA,xDomain:D,xDomainSlotCount:P,tweenYDomainOnXDomainChange:F=!1,onPhaseChange:z}){const $=ERt(),B=t-o.left-o.right,H=n-o.top-o.bottom,U=A.useCallback((yt,pt)=>{const Fe=nD(h),ut=Fe.size===1&&Fe.has(Yu)&&T!=null?T:void 0;return VRt(yt,pt,ut)},[h,T]),W=A.useMemo(()=>{var pt;const yt=((pt=h[0])==null?void 0:pt.dataKey)??"value";return r.length===0?cRt({dataKey:yt}):dRt(r,yt)},[r,h]),{chartPhase:q,plotData:Y,revealEpoch:Q,concealEpoch:G,isLoaded:le,notifyLoadingPulseComplete:K,notifyRevealConcealComplete:te,notifyYDomainTweenComplete:de}=HRt({animationDuration:s,chartStatus:O,revealSignature:u,skeletonData:W,skipEnterReveal:$,targetData:r,yDomainTweenDuration:I});A.useEffect(()=>{z==null||z(q)},[q,z]);const ue=A.useCallback(yt=>{const pt=yt[i];return pt instanceof Date?pt:new Date(pt)},[i]),ae=A.useMemo(()=>Uj(yt=>ue(yt)).left,[ue]),ie=A.useMemo(()=>D?aRt(Y,D,ue):Y,[Y,D,ue]),he=A.useMemo(()=>yRt(c),[c]),fe=A.useMemo(()=>{const yt=D?D[0].getTime():Ble(Y,Fe=>ue(Fe).getTime())[0]??0;let pt=D?D[1].getTime():Ble(Y,Fe=>ue(Fe).getTime())[1]??yt;return D||(pt=bRt(pt,he)),Vkt({range:[0,B],domain:[yt,pt]})},[B,Y,he,ue,D]),se=D?Y:ie,Se=A.useMemo(()=>{const yt=h.map(pt=>pt.dataKey);return oRt(se,sRt(B),yt)},[se,B,h]),pe=A.useMemo(()=>{const yt=D&&P!=null?P:ie.length;return yt<2?0:B/(yt-1)},[B,ie.length,D,P]),Ee=A.useMemo(()=>vde({lines:h,resolveDomain:yt=>U(W,yt)}),[h,U,W]),ke=A.useMemo(()=>{const yt=vde({lines:h,resolveDomain:Fe=>U(D?ie:r,Fe)});if(he.length===0)return yt;const pt={...yt};for(const Fe of Object.keys(yt))pt[Fe]=gde(yt[Fe]??[0,100],he,Fe);for(const Fe of he)pt[Fe.yAxisId]||(pt[Fe.yAxisId]=gde([0,100],he,Fe.yAxisId));return pt},[r,h,he,U,ie,D]),Be=_Rt({chartPhase:q,durationMs:I,enabled:N,onSettled:de,skeletonByAxis:Ee,targetByAxis:ke,tweenOnTargetChange:N||F&&D!=null}),Oe=A.useMemo(()=>qkt({domainsByAxis:Be,innerHeight:H,lines:h}),[Be,H,h]),Le=lMe(Oe,Hh({range:[H,0],domain:[0,100],nice:!0})),ge=A.useMemo(()=>ie.map(yt=>Ag.format(ue(yt))),[ie,ue]),$e=le&&XOt(q),{tooltipData:Ye,setTooltipData:tt,selection:Ae,clearSelection:_e,interactionHandlers:He,interactionStyle:Ue}=BRt({bisectDate:ae,canInteract:$e,data:ie,lines:h,margin:o,xAccessor:ue,xScale:fe,yScale:Le,yScales:Oe}),Ve=[],gt=[],rt=[],xt=[],$t=[];A.Children.forEach(c,(yt,pt)=>{if(!A.isValidElement(yt))return;const Fe=WRt(yt,pt),Qe=HX(Fe);_Ne(Qe)?Ve.push(Qe):MNe(Qe)?xt.push(Qe):TNe(Qe)?$t.push(Qe):ONe(Qe)?gt.push(Qe):ANe(Qe)?rt.push(Qe):xt.push(Qe)});const[zt,vn]=A.useState(()=>new Map),_n=A.useCallback((yt,pt)=>{vn(Fe=>{const Qe=Fe.get(yt);if(Qe&&Qe.yAxisId===pt.yAxisId&&Qe.y1===pt.y1&&Qe.y2===pt.y2&&Qe.axisLabelColor===pt.axisLabelColor)return Fe;const ut=new Map(Fe);return ut.set(yt,pt),ut})},[]),Vn=A.useCallback(yt=>{vn(pt=>{if(!pt.has(yt))return pt;const Fe=new Map(pt);return Fe.delete(yt),Fe})},[]),Ln=A.useMemo(()=>({registerReferenceArea:_n,unregisterReferenceArea:Vn}),[_n,Vn]),ln=A.useMemo(()=>{const yt=NNe(c),pt=[...zt.values()];return pt.length===0?yt:yt.length===0?pt:[...yt,...pt]},[c,zt]),mr=A.useMemo(()=>({data:ie,renderData:Se,xScale:fe,yScale:Le,yScales:Oe,width:t,height:n,innerWidth:B,innerHeight:H,margin:o,columnWidth:pe,tooltipData:Ye,setTooltipData:tt,containerRef:d,lines:h,referenceAreas:ln,chartPhase:q,chartStatus:O,loadingLabel:M,yDomainTweenDuration:I,yDomainSkeletonByAxis:Ee,yDomainTargetByAxis:ke,isLoaded:le,animationDuration:s,animationEasing:a,enterTransition:l,revealEpoch:Q,notifyLoadingPulseComplete:K,xAccessor:ue,dateLabels:ge,xDomain:D,xDomainSlotCount:P,selection:Ae,clearSelection:_e,composedBarDataKeys:g,composedBarSize:b,composedMaxBarSize:v,composedBarGap:w,composedStacked:S,composedStackOffsets:C,composedStackGap:E}),[ie,Se,fe,Le,Oe,t,n,B,H,o,pe,Ye,tt,d,h,ln,q,O,M,I,Ee,ke,le,s,a,l,Q,K,ue,ge,D,P,Ae,_e,g,b,v,w,S,C,E]),Yn=!$&&Se.length>1&&B>0&&s>0,Yt=q==="revealing",Ht=q==="exitingReady"&&s>0,on=l??{...oT,duration:s/1e3},Jt=A.useMemo(()=>{if(!(g!=null&&g.length))return 0;const yt=SRt({columnWidth:pe,composedBarGap:w,composedBarSize:b,composedMaxBarSize:v,dataLength:Y.length,innerWidth:B,seriesCount:g.length,stacked:S});return kRt({barWidth:yt,gap:w,seriesCount:g.length,stacked:S})},[pe,g,w,b,v,S,B,Y.length]);return y.jsx(wRt.Provider,{value:Ln,children:y.jsx(dMe,{value:mr,children:y.jsxs("svg",{"aria-hidden":"true",height:n,width:t,children:[y.jsxs("defs",{children:[Ve,Yn?y.jsx(iRt,{animating:Yt||Ht,clipPathId:m,enterTransition:on,height:H+20,mode:Ht?"conceal":"reveal",onComplete:Ht?te:void 0,padding:Jt,revealEpoch:Ht?G:Q,targetWidth:B}):null]}),y.jsx("rect",{fill:"transparent",height:n,width:t,x:0,y:0}),y.jsxs("g",{...He,style:Ue,transform:`translate(${o.left},${o.top})`,children:[y.jsx("rect",{fill:"transparent",height:H,width:B,x:0,y:0}),gt,rt,Yn?y.jsx("g",{clipPath:`url(#${m})`,children:xt}):xt,$t]})]})})})}),GRt={top:40,right:40,bottom:40,left:40};function KRt(e){const t=[];return A.Children.forEach(e,n=>{if(!A.isValidElement(n))return;const r=n.type,i=typeof n.type=="function"&&(r.displayName||r.name)||"",o=n.props,s=i==="PatternArea"||n.type===CNe;(i==="Area"||n.type===$X||o&&typeof o.dataKey=="string"&&o.dataKey.length>0&&!s)&&(o!=null&&o.dataKey)&&t.push({dataKey:o.dataKey,stroke:o.stroke||o.fill||"var(--chart-line-primary)",strokeWidth:o.strokeWidth||2,yAxisId:o.yAxisId})}),t}function YRt({width:e,height:t,data:n,xDataKey:r,margin:i,animationDuration:o,animationEasing:s,enterTransition:a,revealSignature:l,chartStatus:u,loadingLabel:c,yDomainTweenDuration:d,yDomainTween:h,xDomain:m,xDomainSlotCount:g,tweenYDomainOnXDomainChange:b,children:v,containerRef:w,onPhaseChange:S}){const C=A.useMemo(()=>KRt(v),[v]);return y.jsx(PNe,{animationDuration:o,animationEasing:s,chartStatus:u,clipPathId:"chart-area-grow-clip",containerRef:w,data:n,enterTransition:a,height:t,lines:C,loadingLabel:c,margin:i,onPhaseChange:S,revealSignature:l,tweenYDomainOnXDomainChange:b,width:e,xDataKey:r,xDomain:m,xDomainSlotCount:g,yDomainTween:h,yDomainTweenDuration:d,children:v})}function XRt({data:e,xDataKey:t="date",margin:n,animationDuration:r=1100,animationEasing:i,enterTransition:o,revealSignature:s,aspectRatio:a="2 / 1",className:l="",status:u=FX,loadingLabel:c,yDomainTweenDuration:d=kA,yDomainTween:h=!0,xDomain:m,xDomainSlotCount:g,tweenYDomainOnXDomainChange:b=!1,style:v,onPhaseChange:w,children:S}){const C=A.useRef(null),E={...GRt,...n},[T,O]=A.useState(()=>hD(u)),M=A.useCallback(I=>{O(I),w==null||w(I)},[w]),N=!!(c!=null&&c.trim()&&(T==="loading"||T==="exiting"||T==="gridTweenReady"||T==="revealingLoading"));return y.jsxs("div",{className:X("relative w-full",l),ref:C,style:{aspectRatio:a,touchAction:"none",...v},children:[y.jsx(zX,{debounceTime:10,children:({width:I,height:D})=>y.jsx(YRt,{animationDuration:r,animationEasing:i,chartStatus:u,containerRef:C,data:e,enterTransition:o,height:D,loadingLabel:c,margin:E,onPhaseChange:M,revealSignature:s,tweenYDomainOnXDomainChange:b,width:I,xDataKey:t,xDomain:m,xDomainSlotCount:g,yDomainTween:h,yDomainTweenDuration:d,children:S})}),N?y.jsx(kNe,{exiting:T!=="loading",text:c}):null]})}const QRt=7,ZRt=.45;function JRt(e,t){const n=Math.max(0,e-t);return Math.min(t*.22,Math.max(0,n-1),QRt)}function eMt(e,t,n){const r=Math.min(1,Math.max(0,e)),i=Math.min(n,Math.max(0,t)),o=r*i;return{depth:o,perspectiveRise:o*ZRt}}function tMt(e,t,n=oT){return{...e??n,delay:t}}function nMt(e,t,n,r,i,o,s){var g;const a=r/2;if(a<=0)return 0;const l=((g=e.step)==null?void 0:g.call(e))??t,u=JRt(l,t),d=(e(n(i))??0)+t/2,h=Math.min(1,Math.abs((d-a)/a)),m=Math.abs(s-o);return eMt(h,m,u).perspectiveRise}function rMt({x:e,y:t,width:n,height:r,fill:i,rx:o,ry:s,index:a,isFaded:l,animationType:u,innerHeight:c,fadedOpacity:d,staggerDelay:h,enterTransition:m,revealEpoch:g,isHorizontal:b}){const v=tMt(m,a*h);if(u==="fade")return y.jsx(or.rect,{animate:{opacity:l?d:1,filter:"blur(0px)"},fill:i,height:r,initial:{opacity:0,filter:"blur(2px)"},rx:o,ry:s,transition:v,width:n,x:e,y:t},`fade-${a}-${g}`);const w=b?{width:0,height:r,x:0,y:t}:{width:n,height:0,x:e,y:c},S=b?{width:n,height:r,x:0,y:t}:{width:n,height:r,x:e,y:t};return y.jsx("g",{opacity:l?d:1,style:{transition:"opacity 0.15s ease-in-out"},children:y.jsx(or.rect,{animate:S,fill:i,initial:w,rx:o,ry:s,transition:v},`grow-${a}-${g}`)})}const iMt=A.memo(function({dataKey:t,yAxisId:n,fill:r=Bo.linePrimary,lineCap:i="round",animate:o=!0,animationType:s="grow",fadedOpacity:a=.3,staggerDelay:l,stackGap:u=0,groupGap:c=4,perspective:d=!1,minBarHeight:h=0,barScale:m,bandWidth:g,barXAccessor:b}){const{data:v,yScale:w,innerHeight:S,innerWidth:C,isLoaded:E,hoveredBarIndex:T,lines:O,orientation:M,stacked:N,stackOffsets:I,animationDuration:D,enterTransition:P,revealEpoch:F=0}=ZY(),$=(D||1100)*.4,B=l??(v.length>1?$/1e3/v.length:0),H=A.useId(),U=M==="horizontal",{hoveredIndex:W}=PX(),q=A.useMemo(()=>{const ue=O.findIndex(ae=>ae.dataKey===t);return ue>=0?ue:0},[O,t]),Y=O[q],Q=pA(n??(Y==null?void 0:Y.yAxisId)),G=W!==null&&W!==q,le=O.length,K=q===le-1,te=A.useMemo(()=>{if(!g||le===0)return 0;if(N)return g;const ue=le>1?c:0;return(g-ue*(le-1))/le},[g,le,N,c]),de=A.useMemo(()=>d?0:typeof i=="number"?i:i==="round"&&te?Math.min(te/2,8):0,[i,te,d]);return y.jsx("g",{className:`bar-series-${H}`,children:v.map((ue,ae)=>{var $e,Ye;const ie=ue[t];if(typeof ie!="number")return null;const he=b(ue),fe=m(he)??0;let se,Se,pe,Ee;const ke=U?w:Q;if(U){const tt=ke(ie)??0;if(Ee=tt,pe=te,N&&I){const Ae=(($e=I.get(ae))==null?void 0:$e.get(t))??0;se=ke(Ae)??0,Ee=tt-se;const _e=q*u;se+=_e,!K&&u>0&&(Ee=Math.max(0,Ee-u))}else{se=0;const Ae=le>1?c:0;Se=fe+q*(te+Ae)}Se=N?fe:fe+q*(te+(le>1?c:0))}else{const tt=ke(ie)??0;if(pe=S-tt,Ee=te,N&&I){const _e=((Ye=I.get(ae))==null?void 0:Ye.get(t))??0,He=ke(_e)??S,Ue=q*u;Se=He-pe-Ue,!K&&u>0&&(pe=Math.max(0,pe-u))}else{Se=tt;const _e=le>1?c:0;se=fe+q*(te+_e)}se=N?fe:fe+q*(te+(le>1?c:0));let Ae=!1;if(!N&&h>0&&ie>=0&&pe<h){const _e=ke(0)??S;pe=h,Se=_e-h,Ae=!0}if(d&&ie>0&&!Ae&&(!N||K)){const _e=ke(0)??S,He=nMt(m,g,b,C,ue,Se,_e),Ue=Math.min(He,Math.max(0,pe-1));Se+=Ue,pe-=Ue}}const Ie=T!==null&&T!==ae||G,Be=`bar-${t}-${he}`,Oe=!N||u>0||K,Le=Oe?de:0,ge=Oe?de:0;return o&&!E?y.jsx(rMt,{animationType:s,enterTransition:P,fadedOpacity:a,fill:r,height:pe,index:ae,innerHeight:S,isFaded:Ie,isHorizontal:U,revealEpoch:F,rx:Le,ry:ge,staggerDelay:B,width:Ee,x:se,y:Se},Be):y.jsx("rect",{fill:r,height:pe,opacity:Ie?a:1,rx:Le,ry:ge,style:{cursor:"default",transition:"opacity 0.15s ease-in-out"},width:Ee,x:se,y:Se},Be)})})});function jNe(e){const{barScale:t,bandWidth:n,barXAccessor:r}=_a();return t&&n&&r?y.jsx(iMt,{...e,bandWidth:n,barScale:t,barXAccessor:r}):(console.warn("Bar component must be used within a BarChart"),null)}jNe.displayName="Bar";function oMt({barLengthPx:e,squareSize:t,gap:n,fit:r=!1}){if(e<=0||t<=0)return{count:0,positions:[],columnHeight:0,squareSize:t,gap:n};if(r){const l=Math.max(1,Math.floor((e+n)/(t+n))),u=l>1?Math.max(0,(e-l*t)/(l-1)):0,c=t+u,d=e,h=[];for(let m=0;m<l;m++)h.push(d-t-m*c);return{count:l,positions:h,columnHeight:d,squareSize:t,gap:u}}const i=t+n,o=Math.max(1,Math.round(e/i)),s=o*t+Math.max(0,o-1)*n,a=[];for(let l=0;l<o;l++){const u=l*i;a.push(s-t-u)}return{count:o,positions:a,columnHeight:s,squareSize:t,gap:n}}function sMt({baselineY:e,barLengthPx:t,squareSize:n,gap:r,fit:i=!1}){const{count:o,squareSize:s,columnHeight:a}=oMt({barLengthPx:t,squareSize:n,gap:r,fit:i});return o===0?e:e-a+s/2}const aMt=12,lMt={top:40,right:40,bottom:40,left:40};function uMt(e){const t=[];return ENe(e,n=>{const r=n.type;if(r.__isBarDepthLayer)return;const i=typeof n.type=="function"&&(r.displayName||r.name)||"",o=n.props;if((i==="Bar"||i==="BarSquares"||o&&typeof o.dataKey=="string"&&o.dataKey.length>0)&&(o!=null&&o.dataKey)){const a=o.stroke||o.fill||"var(--chart-line-primary)";t.push({dataKey:o.dataKey,stroke:a,strokeWidth:0,yAxisId:o.yAxisId})}}),t}function cMt(e){const{width:t,height:n}=e;return t<10||n<10?null:y.jsx(dMt,{...e})}const dMt=A.memo(function({width:t,height:n,data:r,xDataKey:i,margin:o,animationDuration:s,animationEasing:a,enterTransition:l,revealSignature:u="",barGap:c,barWidthProp:d,orientation:h,stacked:m,stackGap:g,squareSnap:b,children:v,containerRef:w,onPhaseChange:S,status:C}){const{tooltipData:E,setTooltipData:T,scheduleTooltip:O,clearTooltip:M}=INe(),[N,I]=A.useState(!1),[D,P]=A.useState(0),F=(E==null?void 0:E.index)??null,z=h==="horizontal",$=A.useMemo(()=>uMt(v),[v]),B=t-o.left-o.right,H=n-o.top-o.bottom,U=A.useCallback(Oe=>{const Le=Oe[i];return Le instanceof Date?Ag.format(Le):String(Le??"")},[i]),W=A.useCallback(Oe=>{const Le=Oe[i];return Le instanceof Date?Le:new Date},[i]),q=A.useMemo(()=>{const Oe=r.map(ge=>U(ge));return Bkt({range:z?[0,H]:[0,B],domain:Oe,padding:c})},[B,H,r,U,c,z]),Y=d??q.bandwidth(),Q=A.useMemo(()=>{if(m){let Le=0;for(const ge of r){let $e=0;for(const Ye of $){const tt=ge[Ye.dataKey];typeof tt=="number"&&($e+=tt)}$e>Le&&(Le=$e)}return Le||100}let Oe=0;for(const Le of $)for(const ge of r){const $e=ge[Le.dataKey];typeof $e=="number"&&$e>Oe&&(Oe=$e)}return Oe||100},[r,$,m]),G=A.useMemo(()=>Hh({range:z?[0,B]:[H,0],domain:[0,Q*1.1],nice:!0}),[B,H,Q,z]),le=A.useMemo(()=>z?Gkt(G):Wkt({lines:$,innerHeight:H,resolveDomain:Oe=>{let Le=0;for(const ge of r)for(const $e of Oe){const Ye=ge[$e];typeof Ye=="number"&&Ye>Le&&(Le=Ye)}return[0,(Le||100)*1.1]}}),[r,H,z,$,G]),K=lMe(le,G),te=A.useMemo(()=>{if(!m)return;const Oe=new Map;for(let Le=0;Le<r.length;Le++){const ge=r[Le];if(!ge)continue;const $e=new Map;let Ye=0;for(const tt of $){$e.set(tt.dataKey,Ye);const Ae=ge[tt.dataKey];typeof Ae=="number"&&(Ye+=Ae)}Oe.set(Le,$e)}return Oe},[r,$,m]),de=A.useMemo(()=>r.length<1?0:z?H/r.length:B/r.length,[B,H,r.length,z]),ue=A.useMemo(()=>r.map(Oe=>U(Oe)),[r,U]),ae=A.useMemo(()=>{const Oe=Date.now(),Le=Oe-r.length*24*60*60*1e3,ge={...q,domain:()=>[new Date(Le),new Date(Oe)],range:()=>[0,B],invert:$e=>new Date(Le+$e/B*(Oe-Le)),copy:()=>ge};return ge},[q,B,r.length]);A.useEffect(()=>{if(P(ge=>ge+1),I(!1),C==="loading")return;const Oe=r.length>1?s*.4:0,Le=setTimeout(()=>{I(!0)},s+Oe);return()=>clearTimeout(Le)},[s,u,C]),A.useEffect(()=>{S==null||S(N?"ready":"revealing")},[N,S]);const ie=A.useCallback(Oe=>{const Le=$V(Oe);if(!Le)return;const ge=z?Le.y-o.top:Le.x-o.left,$e=Math.floor(ge/de),Ye=Math.max(0,Math.min(r.length-1,$e)),tt=r[Ye];if(!tt)return;const Ae={},_e={},He=q(U(tt))??0;if(z){const Ve=$.length,gt=Ve>1?4:0,rt=Ve>0?(Y-gt*(Ve-1))/Ve:Y;if(m){let xt=0;for(const $t of $){const zt=tt[$t.dataKey];if(typeof zt=="number"){xt+=zt;const vn=le[ph($t.yAxisId)]??G;_e[$t.dataKey]=vn(xt)??0,Ae[$t.dataKey]=He+Y/2}}}else $.forEach((xt,$t)=>{const zt=tt[xt.dataKey];if(typeof zt=="number"){const vn=le[ph(xt.yAxisId)]??G;_e[xt.dataKey]=vn(zt)??0,Ae[xt.dataKey]=He+$t*(rt+gt)+rt/2}})}else if(m){let Ve=0,gt=0;for(const rt of $){const xt=tt[rt.dataKey];if(typeof xt=="number"){Ve+=xt;const $t=le[ph(rt.yAxisId)]??K,zt=gt*g;Ae[rt.dataKey]=($t(Ve)??0)-zt,gt++}}}else{const Ve=$.length,gt=Ve>1?4:0,rt=Ve>0?(Y-gt*(Ve-1))/Ve:Y;$.forEach((xt,$t)=>{const zt=tt[xt.dataKey];if(typeof zt=="number"){const vn=le[ph(xt.yAxisId)]??K,_n=vn(0)??H,Vn=vn(zt)??0,Ln=_n-Vn;b&&!z&&zt>0?Ae[xt.dataKey]=sMt({baselineY:_n,barLengthPx:Ln,squareSize:rt,gap:b.squareGap,fit:b.fit}):Ae[xt.dataKey]=Vn,_e[xt.dataKey]=He+$t*(rt+gt)+rt/2}})}let Ue;z?Ue=Math.max(...Object.values(_e),0):Ue=He+Y/2,O({point:tt,index:Ye,x:Ue,yPositions:Ae,xPositions:Object.keys(_e).length>0?_e:void 0})},[q,G,r,$,o.left,o.top,U,de,Y,z,m,g,O,le,K,b,H]),he=A.useCallback(()=>{M()},[M]),fe=N,se=[],Se=[],pe=[],Ee=[],ke=[];ENe(v,Oe=>{const Le=HX(Oe);_Ne(Oe)?se.push(Oe):MNe(Oe)?Ee.push(Oe):TNe(Le)?ke.push(Le):ONe(Le)?Se.push(BX(Oe.type)?Le:Oe):ANe(Le)?pe.push(Le):Ee.push(Oe)});const Ie=A.useMemo(()=>NNe(v),[v]),Be={...QOt,chartPhase:hD(C),chartStatus:C,data:r,renderData:r,xScale:ae,yScale:z?G:K,yScales:le,width:t,height:n,innerWidth:B,innerHeight:H,margin:o,columnWidth:de,tooltipData:E,setTooltipData:T,containerRef:w,lines:$,referenceAreas:Ie,isLoaded:N,animationDuration:s,animationEasing:a,enterTransition:l,revealEpoch:D,xAccessor:W,dateLabels:ue,barScale:q,bandWidth:Y,hoveredBarIndex:F,barXAccessor:U,orientation:h,stacked:m,stackOffsets:te,squareSnap:b};return y.jsx(dMe,{value:Be,children:y.jsxs("svg",{"aria-hidden":"true",className:"overflow-visible",height:n,width:t,children:[se.length>0&&y.jsx("defs",{children:se}),y.jsx("rect",{fill:"transparent",height:n,width:t,x:0,y:0}),y.jsxs("g",{onMouseLeave:fe?he:void 0,onMouseMove:fe?ie:void 0,style:{cursor:fe?"crosshair":"default"},transform:`translate(${o.left},${o.top})`,children:[y.jsx("rect",{fill:"transparent",height:H,width:B,x:0,y:0}),dM(Se),dM(pe),C==="loading"?y.jsx(dNe,{barCount:r.length||aMt,innerHeight:H,innerWidth:B}):dM(Ee),dM(ke)]})]})})});function DNe({data:e,xDataKey:t="name",margin:n,animationDuration:r=1100,animationEasing:i=mNe,enterTransition:o,revealSignature:s,aspectRatio:a="2 / 1",className:l="",barGap:u=.2,barWidth:c,orientation:d="vertical",stacked:h=!1,stackGap:m=0,squareSnap:g,children:b,onPhaseChange:v,status:w="ready"}){const S=A.useRef(null),C={...lMt,...n};return y.jsx("div",{className:X("relative w-full overflow-visible",l),ref:S,style:{aspectRatio:a},children:y.jsx(zX,{debounceTime:10,children:({width:E,height:T})=>y.jsx(cMt,{animationDuration:r,animationEasing:i,barGap:u,barWidthProp:c,containerRef:S,data:e,enterTransition:o,height:T,margin:C,onPhaseChange:v,orientation:d,revealSignature:s,squareSnap:g,stacked:h,stackGap:m,status:w,width:E,xDataKey:t,children:b})})})}DNe.displayName="BarChart";function $Ne(e){return"bandwidth"in e?e.bandwidth():0}function Sde(e){let{top:t=0,left:n=0,scale:r,width:i,stroke:o="#eaf0f6",strokeWidth:s=1,strokeDasharray:a,className:l,children:u,numTicks:c=10,lineStyle:d,offset:h,tickValues:m,...g}=e;const b=m??aMe(r,c),v=(h??0)+$Ne(r)/2,w=b.map((S,C)=>{const E=(sMe(r(S))??0)+v;return{index:C,from:new aw({x:0,y:E}),to:new aw({x:i,y:E})}});return y.jsx(uRe,{className:rS("visx-rows",l),top:t,left:n,children:u?u({lines:w}):w.map(S=>{let{from:C,to:E,index:T}=S;return y.jsx(cRe,{from:C,to:E,stroke:o,strokeWidth:s,strokeDasharray:a,style:d,...g},`row-line-${T}`)})})}function fMt(e){let{top:t=0,left:n=0,scale:r,height:i,stroke:o="#eaf0f6",strokeWidth:s=1,strokeDasharray:a,className:l,numTicks:u=10,lineStyle:c,offset:d,tickValues:h,children:m,...g}=e;const b=h??aMe(r,u),v=(d??0)+$Ne(r)/2,w=b.map((S,C)=>{const E=(sMe(r(S))??0)+v;return{index:C,from:new aw({x:E,y:0}),to:new aw({x:E,y:i})}});return y.jsx(uRe,{className:rS("visx-columns",l),top:t,left:n,children:m?m({lines:w}):w.map(S=>{let{from:C,to:E,index:T}=S;return y.jsx(cRe,{from:C,to:E,stroke:o,strokeWidth:s,strokeDasharray:a,style:c,...g},`column-line-${T}`)})})}function hMt({innerWidth:e,shimmer:t,shimmerLength:n,shimmerSpeed:r,shimmerSync:i,active:o,oneShot:s=!1}){const a=fD(0),l=uc(),u=DV/Math.max(r,.1),c=o&&t&&l!==!0&&e>0;A.useEffect(()=>{if(!c)return;let m=!1,g,b;const v=()=>{m||(a.set(0),b=mh(a,1,{duration:u,ease:[...tu],onComplete:()=>{m||(g=window.setTimeout(v,MX))}}))};return i&&s?(a.set(0),b=mh(a,1,{duration:u/2,ease:[...tu]}),()=>b==null?void 0:b.stop()):i?(v(),()=>{m=!0,b==null||b.stop(),g!==void 0&&window.clearTimeout(g)}):(a.set(0),b=mh(a,1,{duration:u,repeat:Number.POSITIVE_INFINITY,ease:[...tu]}),()=>b==null?void 0:b.stop())},[s,a,u,c,i]);const d=bb(a,m=>-n+m*(e+n*2)),h=bb(d,m=>`translate(${m}, 0)`);return{shimmerEnabled:c,shimmerTransform:h}}const pMt=140,mMt=1,gMt="color-mix(in oklch, var(--foreground) 68%, transparent)";function zNe(e,t){return!t||e.length<=2?e:e.slice(1,-1)}function yMt(e){const{hideHorizontalEdgeLines:t,numTicksRows:n,rowTickValues:r,yScale:i}=e,o=r??(i.ticks?i.ticks(n):[]),s=zNe(o,t);if(!(s===o&&!r&&!t))return s.length>0?s:void 0}function L_({horizontal:e=!0,vertical:t=!1,numTicksRows:n=5,numTicksColumns:r=10,rowTickValues:i,stroke:o=Bo.grid,loadingStroke:s,strokeOpacity:a=1,strokeWidth:l=1,strokeDasharray:u="4,4",highlightRowValues:c,highlightRowStroke:d=Bo.foregroundMuted,highlightRowStrokeOpacity:h=1,highlightRowStrokeWidth:m=1,highlightRowStrokeDasharray:g="0",fadeHorizontal:b=!0,fadeVertical:v=!1,hideHorizontalEdgeLines:w=!1,hideVerticalEdgeLines:S=!1,yAxisId:C,shimmer:E=!1,shimmerStroke:T=gMt,shimmerLength:O=pMt,shimmerSpeed:M=mMt,shimmerSync:N=!1}){const{xScale:I,innerWidth:D,innerHeight:P,orientation:F,barScale:z,chartPhase:$}=_a(),B=pA(C),H=E&&TRt($),U=ARt($)&&s!=null?s:o,{shimmerEnabled:W,shimmerTransform:q}=hMt({innerWidth:D,shimmer:E,shimmerLength:O,shimmerSpeed:M,shimmerSync:N,active:H}),Q=F==="horizontal"&&z?B:I,G=yMt({hideHorizontalEdgeLines:w,numTicksRows:n,rowTickValues:i,yScale:B}),le=t&&Q&&typeof Q=="function"&&S?(()=>{var Se;const fe=((Se=Q.ticks)==null?void 0:Se.call(Q,r))??[],se=zNe(fe,!0);return se.length>0?se:void 0})():void 0,K=A.useId(),te=`grid-rows-fade-${K}`,de=`${te}-gradient`,ue=`grid-shimmer-${K}`,ae=`grid-cols-fade-${K}`,ie=`${ae}-gradient`,he=b?`url(#${te})`:void 0;return y.jsxs("g",{className:"chart-grid",children:[e&&b&&y.jsxs("defs",{children:[y.jsxs("linearGradient",{id:de,x1:"0%",x2:"100%",y1:"0%",y2:"0%",children:[y.jsx("stop",{offset:"0%",style:{stopColor:"white",stopOpacity:0}}),y.jsx("stop",{offset:"10%",style:{stopColor:"white",stopOpacity:1}}),y.jsx("stop",{offset:"90%",style:{stopColor:"white",stopOpacity:1}}),y.jsx("stop",{offset:"100%",style:{stopColor:"white",stopOpacity:0}})]}),y.jsx("mask",{id:te,children:y.jsx("rect",{fill:`url(#${de})`,height:P,width:D,x:"0",y:"0"})})]}),e&&W?y.jsx("defs",{children:y.jsxs(or.linearGradient,{gradientTransform:q,gradientUnits:"userSpaceOnUse",id:ue,x1:0,x2:O,y1:0,y2:0,children:[y.jsx("stop",{offset:"0%",stopColor:T,stopOpacity:0}),y.jsx("stop",{offset:"35%",stopColor:T,stopOpacity:.45}),y.jsx("stop",{offset:"50%",stopColor:T,stopOpacity:1}),y.jsx("stop",{offset:"65%",stopColor:T,stopOpacity:.45}),y.jsx("stop",{offset:"100%",stopColor:T,stopOpacity:0})]})}):null,t&&v&&y.jsxs("defs",{children:[y.jsxs("linearGradient",{id:ie,x1:"0%",x2:"0%",y1:"0%",y2:"100%",children:[y.jsx("stop",{offset:"0%",style:{stopColor:"white",stopOpacity:0}}),y.jsx("stop",{offset:"10%",style:{stopColor:"white",stopOpacity:1}}),y.jsx("stop",{offset:"90%",style:{stopColor:"white",stopOpacity:1}}),y.jsx("stop",{offset:"100%",style:{stopColor:"white",stopOpacity:0}})]}),y.jsx("mask",{id:ae,children:y.jsx("rect",{fill:`url(#${ie})`,height:P,width:D,x:"0",y:"0"})})]}),e&&y.jsxs("g",{mask:he,children:[y.jsx(Sde,{numTicks:G?void 0:n,scale:B,stroke:U,strokeDasharray:u,strokeOpacity:a,strokeWidth:l,tickValues:G,width:D}),W?y.jsx(Sde,{numTicks:G?void 0:n,scale:B,stroke:`url(#${ue})`,strokeDasharray:u,strokeOpacity:1,strokeWidth:l,tickValues:G,width:D}):null]}),e&&c&&c.length>0?y.jsx("g",{className:"chart-grid-highlight-rows",children:c.map(fe=>{const se=B(fe);return se==null||!Number.isFinite(se)?null:y.jsx("line",{stroke:d,strokeDasharray:g,strokeOpacity:h,strokeWidth:m,x1:0,x2:D,y1:se,y2:se},fe)})}):null,t&&Q&&typeof Q=="function"&&y.jsx("g",{mask:v?`url(#${ae})`:void 0,children:y.jsx(fMt,{height:P,numTicks:le?void 0:r,scale:Q,stroke:o,strokeDasharray:u,strokeOpacity:a,strokeWidth:l,tickValues:le})})]})}L_.displayName="Grid";function kde(e,t,n,r,i){return e.map((o,s)=>{var u;const a=t(o),l=o[i];return{x:n(a)??0,y:typeof l=="number"?r(l)??0:0,key:String(((u=a.getTime)==null?void 0:u.call(a))??s)}})}function bMt(e,t,n){if(n>=1)return t;if(n<=0)return e.length>0?e:t;const r=new Map(e.map(i=>[i.key,i]));return t.map((i,o)=>{const s=r.get(i.key);if(s)return{key:i.key,x:s.x+(i.x-s.x)*n,y:s.y+(i.y-s.y)*n};const a=o>0?t[o-1]:void 0,l=a?r.get(a.key):void 0,u=o<t.length-1?t[o+1]:void 0,c=u?r.get(u.key):void 0,d=l??c??e[0]??i;return{key:i.key,x:d.x+(i.x-d.x)*n,y:d.y+(i.y-d.y)*n}})}function vMt(e,t){return e.length===0?"":Fj().x(r=>r.x).y(r=>r.y).curve(t)(e)??""}function xMt({renderData:e,xAccessor:t,dataKey:n,innerWidth:r,xDomainMin:i,xDomainMax:o}){const s=e.map(a=>{const l=t(a),u=a[n];return`${l.getTime()}:${typeof u=="number"?u:""}`});return`${r}|${i}|${o}|${s.join(",")}`}function wMt({renderData:e,xAccessor:t,xScale:n,yScale:r,dataKey:i,curve:o,chartPhase:s,durationMs:a,innerWidth:l,enabled:u}){const c=uc(),[d,h]=A.useState(null),m=A.useRef(null),g=A.useRef(!1),b=A.useMemo(()=>{var O;const T=n;return((O=T.domain)==null?void 0:O.call(T))??[new Date(0),new Date(0)]},[n]),v=A.useMemo(()=>{var T,O,M,N;return xMt({renderData:e,xAccessor:t,dataKey:i,innerWidth:l,xDomainMin:((O=(T=b[0])==null?void 0:T.getTime)==null?void 0:O.call(T))??0,xDomainMax:((N=(M=b[1])==null?void 0:M.getTime)==null?void 0:N.call(M))??0})},[e,t,i,l,b]),w=A.useMemo(()=>kde(e,t,n,r,i),[e,t,n,r,i]),S=A.useRef(v);A.useEffect(()=>{g.current||(m.current=w)},[w]),A.useEffect(()=>{if(!(u&&!c&&s==="ready"&&a>0&&e.length>0)){g.current=!1,h(null),m.current=w,S.current=v;return}if(S.current===v)return;S.current=v;const O=m.current??w;if(O.length===0){m.current=w;return}g.current=!0;const M=O,N=mh(0,1,{duration:a/1e3,ease:[...tu],onUpdate:I=>{const D=kde(e,t,n,r,i),P=bMt(M,D,I);m.current=P,h(P)},onComplete:()=>{g.current=!1,m.current=w,h(null)}});return()=>{N.stop(),g.current=!1}},[v,s,a,u,c,e,t,n,r,i,w]);const C=d??w;return{pathD:A.useMemo(()=>vMt(C,o),[C,o]),isPathAnimating:d!=null}}function SMt({animatedPathD:e,curve:t,getY:n,pathRef:r,renderData:i,strokeWidth:o,useDataTransitionPath:s,visibleStroke:a,xAccessor:l,xScale:u}){return s&&e?y.jsx("path",{d:e,fill:"none",ref:r,stroke:a,strokeLinecap:"round",strokeWidth:o}):y.jsx(LY,{curve:t,data:i,innerRef:r,stroke:a,strokeLinecap:"round",strokeWidth:o,x:c=>u(l(c))??0,y:n})}function kMt({curve:e,handleLoadingPulseComplete:t,innerWidth:n,loadingStroke:r,loadingStrokeOpacity:i,loadingStyle:o,pathD:s,pulseEpoch:a,pulseMode:l,showLoadingPulse:u,strokeWidth:c}){const d=u&&n>0&&o==="sweep",h=u&&n>0&&!d;return y.jsxs(y.Fragment,{children:[d?y.jsx(NX,{curve:e,mode:l??"loop",onTransitionComplete:t,stroke:r,strokeOpacity:i,strokeWidth:c},"loading-sweep"):null,h&&s?y.jsx(_X,{loopEpoch:a,mode:l??void 0,onCycleComplete:t,pathD:s,stroke:r,strokeOpacity:i,strokeWidth:c},"loading-pulse"):null]})}function UX({dataKey:e,yAxisId:t,stroke:n=Bo.linePrimary,strokeWidth:r=2.5,curve:i=lRe,animate:o=!0,fadeEdges:s=!0,showHighlight:a=!0,showMarkers:l=!1,markers:u,dashFromIndex:c,dashArray:d="6,4",loading:h,loadingStroke:m=Bo.foreground,loadingStrokeOpacity:g=.5,loadingPulseMode:b,onLoadingPulseCycleComplete:v,loadingStyle:w="pulse"}){const{data:S,renderData:C,xScale:E,innerHeight:T,innerWidth:O,xAccessor:M,lines:N,chartPhase:I,notifyLoadingPulseComplete:D,yDomainTweenDuration:P}=_a(),F=pA(t),z=o&&I==="ready",{pathD:$}=wMt({chartPhase:I,curve:i,dataKey:e,durationMs:P,enabled:z,innerWidth:O,renderData:C,xAccessor:M,xScale:E,yScale:F}),B=sNe(I),H=h===!1?null:b??(h===!0?"loop":B),U=H!=null,[W,q]=A.useState(0),Y=a&&!U,Q=A.useCallback(()=>{if(v==null||v(),H==="loop"){window.setTimeout(()=>{q(Ee=>Ee+1)},MX);return}D==null||D()},[D,v,H]),G=A.useMemo(()=>{const Ee=N.findIndex(ke=>ke.dataKey===e);return Ee>=0?Ee:0},[N,e]),le=A.useRef(null),{pathLength:K,pathD:te}=fNe(le,[C,O,c,o,z?$:null]),de=A.useId(),ue=`line-gradient-${e}-${de}`,ae=A.useCallback(Ee=>{const ke=Ee[e];return typeof ke=="number"?F(ke)??0:0},[e,F]),ie=LX(c,S.length),he=Hj(s),fe=he.any?`url(#${ue})`:n,se=he.any?qL(he):null,Se=I==="revealing"||I==="ready"||I==="exitingReady";let pe="transparent";return Se&&!ie&&(pe=fe),y.jsxs(y.Fragment,{children:[se?y.jsx("defs",{children:y.jsx("linearGradient",{id:ue,...GL(O),children:se.map(Ee=>y.jsx("stop",{offset:Ee.offset,style:{stopColor:n,stopOpacity:Ee.opacity}},Ee.offset))})}):null,y.jsxs(jX,{dimOpacity:.3,enabled:Y,seriesIndex:G,children:[y.jsx(SMt,{animatedPathD:$,curve:i,getY:ae,pathRef:le,renderData:C,strokeWidth:r,useDataTransitionPath:z,visibleStroke:pe,xAccessor:M,xScale:E}),y.jsx(hNe,{dashArray:d,dashFromIndex:c,data:S,innerHeight:T,innerWidth:O,pathD:te,pathLength:K,stroke:fe,strokeWidth:r,xAccessor:M,xScale:E})]}),l?y.jsx(DX,{animate:o,dataKey:e,...u,fill:(u==null?void 0:u.fill)??n,stroke:(u==null?void 0:u.stroke)??(u==null?void 0:u.fill)??n}):null,y.jsx(IX,{enabled:Y,height:T,pathRef:le,stroke:n,strokeWidth:r}),y.jsx(kMt,{curve:i,handleLoadingPulseComplete:Q,innerWidth:O,loadingStroke:m,loadingStrokeOpacity:g,loadingStyle:w,pathD:te,pulseEpoch:W,pulseMode:H,showLoadingPulse:U,strokeWidth:r})]})}UX.displayName="Line";const CMt={top:40,right:40,bottom:40,left:40},EMt=new Set(["ProfitLossLine","LineSeriesTerminalMarker","Area","SeriesBar","Scatter","Candlestick","Bar","PatternArea"]);function TMt(e){const t=e.type;return typeof e.type=="function"&&(t.displayName||t.name)||""}function AMt(e,t){if(!(t!=null&&t.dataKey))return!1;const n=TMt(e);return n==="Line"||e.type===UX?!0:EMt.has(n)?!1:typeof t.dataKey=="string"&&t.dataKey.length>0}function OMt(e){const t=[],n=r=>{A.Children.forEach(r,i=>{if(!A.isValidElement(i))return;const o=i.props;if(AMt(i,o)&&(o!=null&&o.dataKey)){t.push({dataKey:o.dataKey,stroke:o.stroke||"var(--chart-line-primary)",strokeWidth:o.strokeWidth||2.5,yAxisId:o.yAxisId});return}const s=i.props;s!=null&&s.children&&n(s.children)})};return n(e),t}function RMt({width:e,height:t,data:n,xDataKey:r,margin:i,animationDuration:o,animationEasing:s,enterTransition:a,revealSignature:l,chartStatus:u,loadingLabel:c,yDomainTweenDuration:d,yDomainTween:h,xDomain:m,xDomainSlotCount:g,tweenYDomainOnXDomainChange:b,children:v,containerRef:w,onPhaseChange:S}){const C=A.useMemo(()=>OMt(v),[v]);return y.jsx(PNe,{animationDuration:o,animationEasing:s,chartStatus:u,clipPathId:"chart-grow-clip",containerRef:w,data:n,enterTransition:a,height:t,lines:C,loadingLabel:c,margin:i,onPhaseChange:S,revealSignature:l,tweenYDomainOnXDomainChange:b,width:e,xDataKey:r,xDomain:m,xDomainSlotCount:g,yDomainTween:h,yDomainTweenDuration:d,children:v})}function MMt({data:e,xDataKey:t="date",margin:n,animationDuration:r=1100,animationEasing:i,enterTransition:o,revealSignature:s,aspectRatio:a="2 / 1",className:l="",status:u=FX,loadingLabel:c,yDomainTweenDuration:d=kA,yDomainTween:h=!0,xDomain:m,xDomainSlotCount:g,tweenYDomainOnXDomainChange:b=!1,style:v,onPhaseChange:w,children:S}){const C=A.useRef(null),E={...CMt,...n},[T,O]=A.useState(()=>hD(u)),M=A.useCallback(I=>{O(I),w==null||w(I)},[w]),N=!!(c!=null&&c.trim()&&(T==="loading"||T==="exiting"||T==="gridTweenReady"||T==="revealingLoading"));return y.jsxs("div",{className:X("relative w-full",l),ref:C,style:{...a?{aspectRatio:a}:void 0,touchAction:"none",...v},children:[y.jsx(zX,{debounceTime:10,children:({width:I,height:D})=>y.jsx(RMt,{animationDuration:r,animationEasing:i,chartStatus:u,containerRef:C,data:e,enterTransition:o,height:D,loadingLabel:c,margin:E,onPhaseChange:M,revealSignature:s,tweenYDomainOnXDomainChange:b,width:I,xDataKey:t,xDomain:m,xDomainSlotCount:g,yDomainTween:h,yDomainTweenDuration:d,children:S})}),N?y.jsx(kNe,{exiting:T!=="loading",text:c}):null]})}const Cde=24,_Mt=60,NMt=A.memo(function({currentIndex:t,labels:n}){const r=n[t]??n[0]??"";return y.jsx("div",{className:"overflow-hidden rounded-full bg-zinc-900 px-4 py-1 text-white shadow-lg dark:bg-zinc-100 dark:text-zinc-900",children:y.jsx("div",{className:"flex h-6 items-center justify-center",children:y.jsx("span",{className:"whitespace-nowrap font-medium text-sm",children:r})})})}),LMt=A.memo(function({currentIndex:t,labels:n}){const r=A.useMemo(()=>n.map((u,c)=>{const d=u.split(" "),h=d[0]||"",m=d[1]||"";return{month:h,day:m,full:u,key:`${u}::${c}`}}),[n]),i=A.useMemo(()=>{const u=[];return r.forEach((c,d)=>{const h=u.at(-1);(!h||h.month!==c.month)&&u.push({month:c.month,key:`${c.month}-${d}`,startIndex:d})}),u},[r]),o=A.useMemo(()=>{if(t<0||t>=r.length)return 0;for(let u=i.length-1;u>=0;u--){const c=i[u];if(c&&c.startIndex<=t)return u}return 0},[t,r.length,i]),s=A.useRef(-1),a=fl(0,{stiffness:400,damping:35}),l=fl(0,{stiffness:400,damping:35});if(a.set(-t*Cde),o>=0){const u=s.current===-1,c=s.current!==o;(u||c)&&(l.set(-o*Cde),s.current=o)}return y.jsx("div",{className:"overflow-hidden rounded-full bg-zinc-900 px-4 py-1 text-white shadow-lg dark:bg-zinc-100 dark:text-zinc-900",children:y.jsx("div",{className:"relative h-6 overflow-hidden",children:y.jsxs("div",{className:"flex items-center justify-center gap-1",children:[y.jsx("div",{className:"relative h-6 overflow-hidden",children:y.jsx(or.div,{className:"flex flex-col",style:{y:l},children:i.map(u=>y.jsx("div",{className:"flex h-6 shrink-0 items-center justify-center",children:y.jsx("span",{className:"whitespace-nowrap font-medium text-sm",children:u.month})},u.key))})}),y.jsx("div",{className:"relative h-6 overflow-hidden",children:y.jsx(or.div,{className:"flex flex-col",style:{y:a},children:r.map(u=>y.jsx("div",{className:"flex h-6 shrink-0 items-center justify-center",children:y.jsx("span",{className:"whitespace-nowrap font-medium text-sm",children:u.day})},u.key))})})]})})})});function FNe({currentIndex:e,labels:t,visible:n}){return!n||t.length===0?null:t.length>_Mt?y.jsx(NMt,{currentIndex:e,labels:t}):y.jsx(LMt,{currentIndex:e,labels:t})}FNe.displayName="DateTicker";function BNe(e){const[t,n]=A.useState(!1);A.useEffect(()=>{n(!0)},[]);const r=e.containerRef.current;return!(t&&r)||!e.visible?null:y.jsx(IMt,{...e,container:r})}function IMt({x:e,y:t,containerWidth:n,containerHeight:r,offset:i=16,className:o="",children:s,left:a,top:l,flipped:u,springConfig:c,animate:d=!0,entrance:h=!0,panelStyle:m,backgroundColor:g=Bo.tooltipBackground,container:b}){const{tooltipBoxSpring:v}=$b(),w=c??v,S=A.useRef(null),C=A.useRef(180),E=A.useRef(80),[T,O]=A.useState({left:e,top:t}),M=C.current,N=E.current,I=e+M+i>n,D=I?e-i-M:e+i,P=Math.max(i,Math.min(t-N/2,r-N-i)),F=fl(D,w),z=fl(P,w);d&&a===void 0&&F.set(D),d&&l===void 0&&z.set(P),A.useLayoutEffect(()=>{if(!S.current)return;const le=S.current,K=le.offsetWidth,te=le.offsetHeight;K>0&&(C.current=K),te>0&&(E.current=te);const de=C.current,ue=E.current,ie=e+de+i>n?e-i-de:e+i,he=Math.max(i,Math.min(t-ue/2,r-ue-i));if(!d){O({left:ie,top:he});return}a===void 0&&F.set(ie),l===void 0&&z.set(he)},[e,t,n,r,i,a,l,d,F,z]);const $=A.useRef(I),[B,H]=A.useState(0);A.useEffect(()=>{$.current!==I&&(H(le=>le+1),$.current=I)},[I]);const U=d?a??F:T.left,W=d?l??z:T.top,q=u??I,Y=q?"right top":"left top",Q=X("min-w-[140px] overflow-hidden rounded-lg text-chart-tooltip-foreground shadow-lg",(m==null?void 0:m.backgroundColor)===void 0&&g===Bo.tooltipBackground&&"bg-chart-tooltip-background",(m==null?void 0:m.backdropFilter)===void 0&&"backdrop-blur-md"),G={transformOrigin:Y,...(m==null?void 0:m.backgroundColor)===void 0&&{backgroundColor:g},...m};return h?mi.createPortal(y.jsx(or.div,{animate:{opacity:1},className:X("pointer-events-none absolute z-50",o),exit:{opacity:0},initial:{opacity:0},ref:S,style:{left:U,top:W},transition:{duration:.1},children:y.jsx(or.div,{animate:{scale:1,opacity:1,x:0},className:Q,initial:{scale:.85,opacity:0,x:q?20:-20},style:G,transition:{type:"spring",stiffness:300,damping:25},children:s},B)}),b):mi.createPortal(y.jsx("div",{className:X("pointer-events-none absolute z-50",o),ref:S,style:{left:T.left,top:T.top},children:y.jsx("div",{className:Q,style:G,children:s})}),b)}BNe.displayName="TooltipBox";function HNe({title:e,rows:t,children:n}){return y.jsx("div",{className:"overflow-hidden",children:y.jsxs("div",{className:"px-3 py-2.5",children:[e&&y.jsx("div",{className:"mb-2 text-left font-medium text-chart-tooltip-foreground text-xs",children:e}),y.jsx("div",{className:"space-y-1.5",children:t.map(r=>y.jsxs("div",{className:"flex items-center justify-between gap-4",children:[y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx("span",{className:"h-2.5 w-2.5 shrink-0 rounded-full",style:{backgroundColor:r.color}}),y.jsx("span",{className:"text-chart-tooltip-muted text-sm",children:r.label})]}),y.jsx("span",{className:"font-medium text-chart-tooltip-foreground text-sm tabular-nums",children:typeof r.value=="number"?rRt(r.value):r.value})]},`${r.label}-${r.color}`))}),n&&y.jsx("div",{className:"mt-2 transition-opacity duration-200 ease-out",children:n})]})})}HNe.displayName="TooltipContent";function UNe(e,t){return e*2*Math.max(0,Math.min(.5,t))}function PMt({x:e,y:t,halfExtent:n,cornerRadiusFraction:r,fill:i,stroke:o,strokeWidth:s,springConfig:a}){const{tooltipSpring:l}=$b(),u=a??l,c=fl(e,u),d=fl(t,u),h=n*2,m=UNe(n,r),g=bb(c,v=>v-n),b=bb(d,v=>v-n);return c.set(e),d.set(t),y.jsx(or.rect,{fill:i,height:h,rx:m,ry:m,stroke:o,strokeWidth:s,width:h,x:g,y:b})}function VNe({x:e,y:t,visible:n,color:r,size:i=5,strokeColor:o=Bo.background,strokeWidth:s=2,variant:a="dot",cornerRadiusFraction:l=.25,springConfig:u,animate:c=!0}){const{tooltipSpring:d}=$b(),h=u??d,m=fl(e,h),g=fl(t,h),b=a==="ring",v=b?"transparent":r,w=b?r:o,S=b?s??1.5:s;if(c&&!b&&(m.set(e),g.set(t)),!n)return null;if(b){if(c)return y.jsx(PMt,{cornerRadiusFraction:l,fill:v,halfExtent:i,springConfig:u,stroke:w,strokeWidth:S,x:e,y:t});const C=i*2,E=UNe(i,l);return y.jsx("rect",{fill:v,height:C,rx:E,ry:E,stroke:w,strokeWidth:S,width:C,x:e-i,y:t-i})}return c?y.jsx(or.circle,{cx:m,cy:g,fill:v,r:i,stroke:w,strokeWidth:S}):y.jsx("circle",{cx:e,cy:t,fill:v,r:i,stroke:w,strokeWidth:S})}VNe.displayName="TooltipDot";function jMt(e){return e===!1||e==="none"?{top:!1,bottom:!1,any:!1}:e===!0||e==="both"?{top:!0,bottom:!0,any:!0}:e==="top"?{top:!0,bottom:!1,any:!0}:{top:!1,bottom:!0,any:!0}}function DMt(e,t=10){const n=Math.min(40,Math.max(2,t)),r=100-n;return e.any?e.top&&e.bottom?[{offset:"0%",opacity:0},{offset:`${n}%`,opacity:1},{offset:"50%",opacity:1},{offset:`${r}%`,opacity:1},{offset:"100%",opacity:0}]:e.top?[{offset:"0%",opacity:0},{offset:`${n}%`,opacity:1},{offset:"100%",opacity:1}]:[{offset:"0%",opacity:1},{offset:`${r}%`,opacity:1},{offset:"100%",opacity:0}]:[{offset:"0%",opacity:1}]}function $Mt(e){if(typeof e=="number")return e;switch(e){case"line":return 1;case"thin":return 2;case"medium":return 4;case"thick":return 8;default:return 1}}function WNe(e){return e.visible?y.jsx(zMt,{...e}):null}function zMt({x:e,visible:t,height:n,width:r="line",span:i,columnWidth:o,colorEdge:s=Bo.crosshair,colorMid:a=Bo.crosshair,fadeEdges:l="both",fadeLength:u=10,animate:c=!0,gradientId:d="tooltip-indicator-gradient",springConfig:h,strokeDasharray:m}){const{tooltipSpring:g}=$b(),b=h??g,v=i!==void 0&&o!==void 0?i*o:$Mt(r),w=e-v/2,S=e,C=fl(w,b),E=fl(S,b);c&&(C.set(w),E.set(S)),A.useEffect(()=>{C.set(w),E.set(S)},[E,C,S,w,t]);const T=a||s,O=jMt(l);if(!!m){const I=Math.max(1,v);return c?y.jsx(or.line,{stroke:T,strokeDasharray:m,strokeWidth:I,x1:E,x2:E,y1:0,y2:n}):y.jsx("line",{stroke:T,strokeDasharray:m,strokeWidth:I,x1:S,x2:S,y1:0,y2:n})}if(!O.any)return c?y.jsx(or.rect,{fill:T,height:n,width:v,x:C,y:0}):y.jsx("rect",{fill:T,height:n,width:v,x:w,y:0});const N=DMt(O,u);return y.jsxs("g",{children:[y.jsx("defs",{children:y.jsx("linearGradient",{id:d,x1:"0%",x2:"0%",y1:"0%",y2:"100%",children:N.map(I=>y.jsx("stop",{offset:I.offset,style:{stopColor:T,stopOpacity:I.opacity}},I.offset))})}),c?y.jsx(or.rect,{fill:`url(#${d})`,height:n,width:v,x:C,y:0}):y.jsx("rect",{fill:`url(#${d})`,height:n,width:v,x:w,y:0})]})}WNe.displayName="TooltipIndicator";const FMt=A.memo(function({showDatePill:t=!0,showCrosshair:n=!0,showDots:r=!0,dotVariant:i="dot",dotSize:o=5,dotRadiusFraction:s,dotScale:a=1,dotStrokeWidth:l,indicatorColor:u,content:c,rows:d,dotColor:h,children:m,className:g="",container:b,springConfig:v,matchCrosshair:w=!1,damping:S,indicatorDasharray:C,indicatorFadeEdges:E,indicatorFadeLength:T,boxSpringConfig:O,panelStyle:M,backgroundColor:N}){var Oe;const{tooltipData:I,width:D,height:P,innerHeight:F,margin:z,columnWidth:$,lines:B,xAccessor:H,dateLabels:U,containerRef:W,orientation:q,barXAccessor:Y,bandWidth:Q,squareSnap:G}=ZY(),{tooltipSpring:le}=$b(),K=q==="horizontal",te=U.length>60,de=A.useMemo(()=>{if(i!=="ring"||!Q||B.length===0)return o*a;const Le=B.length,ge=(G==null?void 0:G.groupGap)??(Le>1?4:0);return(Q-ge*(Le-1))/Le/2*a},[Q,a,o,i,B.length,G==null?void 0:G.groupGap]),ue=A.useMemo(()=>O?{animate:!te,springConfig:O}:w?{animate:!te,springConfig:v??le}:MOt(S),[O,S,te,w,v,le]),ae=I!==null,ie=(I==null?void 0:I.x)??0,he=ie+z.left,fe=(Oe=B[0])==null?void 0:Oe.dataKey,Se=(fe?(I==null?void 0:I.yPositions[fe])??0:0)+z.top,pe=A.useMemo(()=>I?d?d(I.point):B.map(Le=>({color:Le.stroke,label:Le.dataKey,value:I.point[Le.dataKey]??0})):[],[I,B,d]),Ee=A.useMemo(()=>(Le,ge)=>{var $e;if(d&&(($e=pe[ge])!=null&&$e.color))return pe[ge].color;if(h!=null){if(typeof h=="function"&&I)return h(I.point,Le);if(typeof h=="string")return h}return Le.stroke},[h,d,I,pe]),ke=A.useMemo(()=>u==null?Bo.crosshair:typeof u=="function"?I?u(I.point):Bo.crosshair:u,[u,I]),Ie=A.useMemo(()=>{if(I)return Y?Y(I.point):nRt.format(H(I.point))},[I,Y,H]),Be=y.jsxs(y.Fragment,{children:[n&&y.jsx("svg",{"aria-hidden":"true",className:"pointer-events-none absolute inset-0",height:"100%",width:"100%",children:y.jsx("g",{transform:`translate(${z.left},${z.top})`,children:y.jsx(WNe,{animate:!te,colorEdge:ke,colorMid:ke,columnWidth:$,fadeEdges:C?"none":E??"both",fadeLength:T,height:F,springConfig:v,strokeDasharray:C,visible:ae,width:"line",x:ie})})}),r&&ae&&!K&&y.jsx("svg",{"aria-hidden":"true",className:"pointer-events-none absolute inset-0",height:"100%",width:"100%",children:y.jsx("g",{transform:`translate(${z.left},${z.top})`,children:B.map((Le,ge)=>{var $e;return y.jsx(VNe,{color:Ee(Le,ge),cornerRadiusFraction:i==="ring"?s:void 0,size:de,springConfig:v,strokeColor:Bo.background,strokeWidth:i==="ring"?l:void 0,variant:i,visible:ae,x:(($e=I==null?void 0:I.xPositions)==null?void 0:$e[Le.dataKey])??ie,y:(I==null?void 0:I.yPositions[Le.dataKey])??0},Le.dataKey)})})}),y.jsx(BNe,{animate:ue.animate,backgroundColor:N,className:g,containerHeight:P,containerRef:W,containerWidth:D,panelStyle:M,springConfig:ue.springConfig,top:K?void 0:z.top,visible:ae,x:he,y:K?Se:z.top,children:c&&I?c({point:I.point,index:I.index}):!c&&y.jsx(HNe,{rows:pe,title:Ie,children:m})}),y.jsx(BMt,{currentIndex:(I==null?void 0:I.index)??0,discreteInteraction:te,enabled:t&&!K,labels:U,springConfig:v,visible:ae,xWithMargin:he})]});return mi.createPortal(Be,b)});function I_(e){const{containerRef:t}=_a(),[n,r]=A.useState(!1);A.useEffect(()=>{r(!0)},[]);const i=t.current;return n&&i?y.jsx(FMt,{...e,container:i}):null}I_.displayName="ChartTooltip";function BMt(e){return e.enabled&&e.visible&&e.labels.length>0?y.jsx(HMt,{...e}):null}function HMt({labels:e,currentIndex:t,xWithMargin:n,discreteInteraction:r,springConfig:i,visible:o}){const{tooltipSpring:s}=$b(),l=fl(n,i??s);return r||l.set(n),A.useEffect(()=>{l.set(n)},[l,o]),y.jsx(or.div,{className:"pointer-events-none absolute z-50",style:{left:r?n:l,transform:"translateX(-50%)",bottom:4},children:y.jsx(FNe,{currentIndex:t,labels:e,visible:o})})}const UMt=kA;function VMt({label:e,x:t,crosshairX:n,hoveredLabel:r,isHovering:i,tickerHalfWidth:o,animatePosition:s}){const l=o+20;let u=1;if(i&&n!==null){const c=Math.abs(t-n);c<o||r&&e===r?u=0:c<l&&(u=(c-o)/20)}return y.jsx("div",{className:"absolute",style:{left:t,bottom:12,width:0,display:"flex",justifyContent:"center",transition:s?`left ${UMt}ms cubic-bezier(${tu.join(", ")})`:void 0},children:y.jsx("span",{className:X("whitespace-nowrap text-chart-label text-xs"),style:{opacity:u,transition:"opacity 0.4s ease-in-out"},children:e})})}const WMt=400;function qMt(e,t){if(t<0||t>e)return 0;let n=1;for(let r=0;r<t;r++)n=n*(e-r)/(r+1);return n}function qNe(e,t){if(t===1)return e>=1?[[e]]:[];const n=[];for(let r=1;r<=e-(t-1);r++)for(const i of qNe(e-r,t-1))n.push([r,...i]);return n}function GMt(e){const t=[0];let n=0;for(const r of e)n+=r,t.push(n);return t}function GNe(e,t){const n=e-1;if(n<=0)return[0];const r=Array.from({length:t},(o,s)=>Math.round(s/(t-1)*n)),i=[...new Set(r)].sort((o,s)=>o-s);return i[0]!==0&&i.unshift(0),i.at(-1)!==n&&i.push(n),[...new Set(i)].sort((o,s)=>o-s)}function KMt(e,t){const n=e-1;if(n<=0)return[[0]];const r=t-1;return r<=0?[[0]]:qMt(n-1,r-1)>WMt?[GNe(e,t)]:qNe(n,r).map(GMt)}function YMt(e,t,n,r){const i=new Set,o=[];for(const s of e){const a=t[s];if(!a)continue;const l=n[s]??Ag.format(r(a));i.has(l)||(i.add(l),o.push(s))}return o}function KNe(e){const t=[];for(let n=1;n<e.length;n++){const r=e[n],i=e[n-1];r==null||i==null||t.push(r-i)}return t}function XMt(e){const t=KNe(e),n=Math.min(...t),r=t.indexOf(n);return r===t.length-1?0:r===0?1:2}function Ede(e,t,n){if(e.length<2)return{score:Number.POSITIVE_INFINITY,symmetryPenalty:Number.POSITIVE_INFINITY,countDistance:Number.POSITIVE_INFINITY,edgePreference:Number.POSITIVE_INFINITY};const r=[];for(let g=1;g<e.length;g++){const b=e[g],v=e[g-1];b==null||v==null||r.push(t(b)-t(v))}const i=Math.min(...r),o=Math.max(...r),s=r.reduce((g,b)=>g+b,0)/r.length,a=s>0?(o-i)/s:o-i,l=Math.abs(e.length-n),u=KNe(e),c=Math.min(...u),d=u.indexOf(c),h=d>0&&d<u.length-1?.08:0,m=u.reduce((g,b,v)=>g+Math.abs(b-(u.at(-1-v)??b)),0)/u.length;return{score:a+.1*l+h+m*.02,symmetryPenalty:m,countDistance:l,edgePreference:XMt(e)}}function QMt(e,t,n,r){return e.score<t.score-1e-6?!0:Math.abs(e.score-t.score)>1e-6?!1:n<r?!0:n>r?!1:e.symmetryPenalty<t.symmetryPenalty-1e-6?!0:e.symmetryPenalty>t.symmetryPenalty+1e-6?!1:e.edgePreference<t.edgePreference}function ZMt(e,t,n){if(e<=0)return[];if(e===1)return[0];if(e<=t)return Array.from({length:e},(u,c)=>c);const r=(n==null?void 0:n.resolveXPx)??(u=>u),i=Math.max(2,t-1),o=Math.min(e,t+1);let s=GNe(e,t),a=Ede(s,r,t),l=a.countDistance;for(let u=i;u<=o;u++)for(const c of KMt(e,u)){const d=n!=null&&n.data&&n.dateLabels&&n.xAccessor?YMt(c,n.data,n.dateLabels,n.xAccessor):c;if(d.length<2)continue;const h=Ede(d,r,t),m=Math.abs(d.length-t);QMt(h,a,m,l)&&(s=d,a=h,l=m)}return s}function JMt({data:e,dateLabels:t,marginLeft:n,targetTickCount:r,xAccessor:i,xScale:o}){const s=new Set,a=[],l=u=>{const c=e[u];return c?o(i(c))??0:u};for(const u of ZMt(e.length,r,{data:e,dateLabels:t,resolveXPx:l,xAccessor:i})){const c=e[u];if(!c)continue;const d=i(c),h=t[u]??Ag.format(d);s.has(h)||(s.add(h),a.push({date:d,label:h,x:(o(d)??0)+n}))}return a}function Tde({marginLeft:e,numTicks:t,xScale:n}){const r=n.domain(),i=r[0],o=r[1];if(!(i&&o))return[];const s=i.getTime(),l=o.getTime()-s,u=Math.max(2,t),c=new Set,d=[];for(let h=0;h<u;h++){const m=h/(u-1),g=new Date(s+m*l),b=Ag.format(g);c.has(b)||(c.add(b),d.push({date:g,label:b,x:(n(g)??0)+e}))}return d}function e_t(e,t,n){if(e.length===0)return!1;const r=n.domain()[1],i=e.at(-1);return r&&i?r.getTime()>t(i).getTime():!1}function t_t(e,t,n,r,i,o){if(t.length===0||o<=0)return e;const s=t.at(-1),a=r.domain()[1];if(!(s&&a))return e;const u=n(s).getTime(),c=a.getTime();if(c<=u)return e;const d=new Set(e.map(b=>b.label)),h=[],m=Math.min(o,3);for(let b=1;b<=m;b++){const v=new Date(u+b/(m+1)*(c-u)),w=Ag.format(v);d.has(w)||(d.add(w),h.push({date:v,label:w,x:(r(v)??0)+i}))}const g=Ag.format(a);return d.has(g)||h.push({date:a,label:g,x:(r(a)??0)+i}),h.length===0?e:[...e,...h].sort((b,v)=>b.x-v.x)}function P_(e){const{containerRef:t}=_a(),[n,r]=A.useState(!1);A.useEffect(()=>{r(!0)},[]);const i=t.current;return n&&i?y.jsx(n_t,{...e,container:i}):null}const n_t=A.memo(function({numTicks:t=5,tickerHalfWidth:n=50,tickMode:r="data",container:i}){const{xScale:o,margin:s,tooltipData:a,data:l,xAccessor:u,dateLabels:c,xDomain:d}=ZY(),h=A.useMemo(()=>{const v=r==="data"&&e_t(l,u,o);if(r==="domain")return Tde({marginLeft:s.left,numTicks:t,xScale:o});if(v&&d==null)return Tde({marginLeft:s.left,numTicks:t,xScale:o});const w=JMt({data:l,dateLabels:c,marginLeft:s.left,targetTickCount:t,xAccessor:u,xScale:o});return v&&d!=null?t_t(w,l,u,o,s.left,Math.max(1,t-w.length+1)):w},[r,d,l,c,u,o,s.left,t]),m=a!==null,g=a?a.x+s.left:null,b=m&&a?c[a.index]??Ag.format(u(a.point)):null;return mi.createPortal(y.jsx("div",{className:"pointer-events-none absolute inset-0",children:h.map(v=>y.jsx(VMt,{animatePosition:d==null,crosshairX:g,hoveredLabel:b,isHovering:m,label:v.label,tickerHalfWidth:n,x:v.x},`${v.date.getTime()}-${v.x}`))}),i)});P_.displayName="XAxis";const r_t=5;function i_t({result:e,visualization:t,height:n=220}){const{labelColumn:r,valueColumns:i}=mEe(e,t),o=i.slice(0,r_t),s=A.useMemo(()=>Tst(e,r),[e,r]),a=A.useMemo(()=>s?e.rows.map(l=>{const u=l[r];return{...l,date:u instanceof Date?u:new Date(String(u))}}):e.rows.map(l=>({...l,name:l[r]})),[e.rows,r,s]);return o.length===0?y.jsx(oH,{result:e,visualization:t,height:n}):t.kind==="bar"?y.jsx("div",{style:{height:n},children:y.jsxs(DNe,{data:a,xDataKey:"name",aspectRatio:"auto",className:"h-full",children:[y.jsx(L_,{}),y.jsx(P_,{}),o.map((l,u)=>y.jsx(jNe,{dataKey:l,fill:Lp[u%Lp.length]},l)),y.jsx(I_,{})]})}):s?t.kind==="area"?y.jsx("div",{style:{height:n},children:y.jsxs(XRt,{data:a,xDataKey:"date",aspectRatio:"auto",className:"h-full",children:[y.jsx(L_,{}),y.jsx(P_,{}),o.map((l,u)=>y.jsx($X,{dataKey:l,fill:Lp[u%Lp.length],stroke:Lp[u%Lp.length]},l)),y.jsx(I_,{})]})}):y.jsx("div",{style:{height:n},children:y.jsxs(MMt,{data:a,xDataKey:"date",aspectRatio:"auto",className:"h-full",children:[y.jsx(L_,{}),y.jsx(P_,{}),o.map((l,u)=>y.jsx(UX,{dataKey:l,stroke:Lp[u%Lp.length]},l)),y.jsx(I_,{})]})}):y.jsx(oH,{result:e,visualization:t,height:n})}var y$,Ade;function Na(){if(Ade)return y$;Ade=1;var e=Array.isArray;return y$=e,y$}var b$,Ode;function VX(){if(Ode)return b$;Ode=1;var e=Na(),t=uS(),n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,r=/^\w*$/;function i(o,s){if(e(o))return!1;var a=typeof o;return a=="number"||a=="symbol"||a=="boolean"||o==null||t(o)?!0:r.test(o)||!n.test(o)||s!=null&&o in Object(s)}return b$=i,b$}var v$,Rde;function WX(){if(Rde)return v$;Rde=1;var e=Jh(),t=Vg(),n="[object AsyncFunction]",r="[object Function]",i="[object GeneratorFunction]",o="[object Proxy]";function s(a){if(!t(a))return!1;var l=e(a);return l==r||l==i||l==n||l==o}return v$=s,v$}var x$,Mde;function o_t(){if(Mde)return x$;Mde=1;var e=Hd(),t=e["__core-js_shared__"];return x$=t,x$}var w$,_de;function s_t(){if(_de)return w$;_de=1;var e=o_t(),t=(function(){var r=/[^.]+$/.exec(e&&e.keys&&e.keys.IE_PROTO||"");return r?"Symbol(src)_1."+r:""})();function n(r){return!!t&&t in r}return w$=n,w$}var S$,Nde;function YNe(){if(Nde)return S$;Nde=1;var e=Function.prototype,t=e.toString;function n(r){if(r!=null){try{return t.call(r)}catch{}try{return r+""}catch{}}return""}return S$=n,S$}var k$,Lde;function a_t(){if(Lde)return k$;Lde=1;var e=WX(),t=s_t(),n=Vg(),r=YNe(),i=/[\\^$.*+?()[\]{}|]/g,o=/^\[object .+?Constructor\]$/,s=Function.prototype,a=Object.prototype,l=s.toString,u=a.hasOwnProperty,c=RegExp("^"+l.call(u).replace(i,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function d(h){if(!n(h)||t(h))return!1;var m=e(h)?c:o;return m.test(r(h))}return k$=d,k$}var C$,Ide;function l_t(){if(Ide)return C$;Ide=1;function e(t,n){return t==null?void 0:t[n]}return C$=e,C$}var E$,Pde;function zb(){if(Pde)return E$;Pde=1;var e=a_t(),t=l_t();function n(r,i){var o=t(r,i);return e(o)?o:void 0}return E$=n,E$}var T$,jde;function pD(){if(jde)return T$;jde=1;var e=zb(),t=e(Object,"create");return T$=t,T$}var A$,Dde;function u_t(){if(Dde)return A$;Dde=1;var e=pD();function t(){this.__data__=e?e(null):{},this.size=0}return A$=t,A$}var O$,$de;function c_t(){if($de)return O$;$de=1;function e(t){var n=this.has(t)&&delete this.__data__[t];return this.size-=n?1:0,n}return O$=e,O$}var R$,zde;function d_t(){if(zde)return R$;zde=1;var e=pD(),t="__lodash_hash_undefined__",n=Object.prototype,r=n.hasOwnProperty;function i(o){var s=this.__data__;if(e){var a=s[o];return a===t?void 0:a}return r.call(s,o)?s[o]:void 0}return R$=i,R$}var M$,Fde;function f_t(){if(Fde)return M$;Fde=1;var e=pD(),t=Object.prototype,n=t.hasOwnProperty;function r(i){var o=this.__data__;return e?o[i]!==void 0:n.call(o,i)}return M$=r,M$}var _$,Bde;function h_t(){if(Bde)return _$;Bde=1;var e=pD(),t="__lodash_hash_undefined__";function n(r,i){var o=this.__data__;return this.size+=this.has(r)?0:1,o[r]=e&&i===void 0?t:i,this}return _$=n,_$}var N$,Hde;function p_t(){if(Hde)return N$;Hde=1;var e=u_t(),t=c_t(),n=d_t(),r=f_t(),i=h_t();function o(s){var a=-1,l=s==null?0:s.length;for(this.clear();++a<l;){var u=s[a];this.set(u[0],u[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,N$=o,N$}var L$,Ude;function m_t(){if(Ude)return L$;Ude=1;function e(){this.__data__=[],this.size=0}return L$=e,L$}var I$,Vde;function qX(){if(Vde)return I$;Vde=1;function e(t,n){return t===n||t!==t&&n!==n}return I$=e,I$}var P$,Wde;function mD(){if(Wde)return P$;Wde=1;var e=qX();function t(n,r){for(var i=n.length;i--;)if(e(n[i][0],r))return i;return-1}return P$=t,P$}var j$,qde;function g_t(){if(qde)return j$;qde=1;var e=mD(),t=Array.prototype,n=t.splice;function r(i){var o=this.__data__,s=e(o,i);if(s<0)return!1;var a=o.length-1;return s==a?o.pop():n.call(o,s,1),--this.size,!0}return j$=r,j$}var D$,Gde;function y_t(){if(Gde)return D$;Gde=1;var e=mD();function t(n){var r=this.__data__,i=e(r,n);return i<0?void 0:r[i][1]}return D$=t,D$}var $$,Kde;function b_t(){if(Kde)return $$;Kde=1;var e=mD();function t(n){return e(this.__data__,n)>-1}return $$=t,$$}var z$,Yde;function v_t(){if(Yde)return z$;Yde=1;var e=mD();function t(n,r){var i=this.__data__,o=e(i,n);return o<0?(++this.size,i.push([n,r])):i[o][1]=r,this}return z$=t,z$}var F$,Xde;function gD(){if(Xde)return F$;Xde=1;var e=m_t(),t=g_t(),n=y_t(),r=b_t(),i=v_t();function o(s){var a=-1,l=s==null?0:s.length;for(this.clear();++a<l;){var u=s[a];this.set(u[0],u[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,F$=o,F$}var B$,Qde;function GX(){if(Qde)return B$;Qde=1;var e=zb(),t=Hd(),n=e(t,"Map");return B$=n,B$}var H$,Zde;function x_t(){if(Zde)return H$;Zde=1;var e=p_t(),t=gD(),n=GX();function r(){this.size=0,this.__data__={hash:new e,map:new(n||t),string:new e}}return H$=r,H$}var U$,Jde;function w_t(){if(Jde)return U$;Jde=1;function e(t){var n=typeof t;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?t!=="__proto__":t===null}return U$=e,U$}var V$,efe;function yD(){if(efe)return V$;efe=1;var e=w_t();function t(n,r){var i=n.__data__;return e(r)?i[typeof r=="string"?"string":"hash"]:i.map}return V$=t,V$}var W$,tfe;function S_t(){if(tfe)return W$;tfe=1;var e=yD();function t(n){var r=e(this,n).delete(n);return this.size-=r?1:0,r}return W$=t,W$}var q$,nfe;function k_t(){if(nfe)return q$;nfe=1;var e=yD();function t(n){return e(this,n).get(n)}return q$=t,q$}var G$,rfe;function C_t(){if(rfe)return G$;rfe=1;var e=yD();function t(n){return e(this,n).has(n)}return G$=t,G$}var K$,ife;function E_t(){if(ife)return K$;ife=1;var e=yD();function t(n,r){var i=e(this,n),o=i.size;return i.set(n,r),this.size+=i.size==o?0:1,this}return K$=t,K$}var Y$,ofe;function KX(){if(ofe)return Y$;ofe=1;var e=x_t(),t=S_t(),n=k_t(),r=C_t(),i=E_t();function o(s){var a=-1,l=s==null?0:s.length;for(this.clear();++a<l;){var u=s[a];this.set(u[0],u[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,Y$=o,Y$}var X$,sfe;function XNe(){if(sfe)return X$;sfe=1;var e=KX(),t="Expected a function";function n(r,i){if(typeof r!="function"||i!=null&&typeof i!="function")throw new TypeError(t);var o=function(){var s=arguments,a=i?i.apply(this,s):s[0],l=o.cache;if(l.has(a))return l.get(a);var u=r.apply(this,s);return o.cache=l.set(a,u)||l,u};return o.cache=new(n.Cache||e),o}return n.Cache=e,X$=n,X$}var Q$,afe;function T_t(){if(afe)return Q$;afe=1;var e=XNe(),t=500;function n(r){var i=e(r,function(s){return o.size===t&&o.clear(),s}),o=i.cache;return i}return Q$=n,Q$}var Z$,lfe;function A_t(){if(lfe)return Z$;lfe=1;var e=T_t(),t=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,n=/\\(\\)?/g,r=e(function(i){var o=[];return i.charCodeAt(0)===46&&o.push(""),i.replace(t,function(s,a,l,u){o.push(l?u.replace(n,"$1"):a||s)}),o});return Z$=r,Z$}var J$,ufe;function YX(){if(ufe)return J$;ufe=1;function e(t,n){for(var r=-1,i=t==null?0:t.length,o=Array(i);++r<i;)o[r]=n(t[r],r,t);return o}return J$=e,J$}var ez,cfe;function O_t(){if(cfe)return ez;cfe=1;var e=SA(),t=YX(),n=Na(),r=uS(),i=e?e.prototype:void 0,o=i?i.toString:void 0;function s(a){if(typeof a=="string")return a;if(n(a))return t(a,s)+"";if(r(a))return o?o.call(a):"";var l=a+"";return l=="0"&&1/a==-1/0?"-0":l}return ez=s,ez}var tz,dfe;function QNe(){if(dfe)return tz;dfe=1;var e=O_t();function t(n){return n==null?"":e(n)}return tz=t,tz}var nz,ffe;function ZNe(){if(ffe)return nz;ffe=1;var e=Na(),t=VX(),n=A_t(),r=QNe();function i(o,s){return e(o)?o:t(o,s)?[o]:n(r(o))}return nz=i,nz}var rz,hfe;function bD(){if(hfe)return rz;hfe=1;var e=uS();function t(n){if(typeof n=="string"||e(n))return n;var r=n+"";return r=="0"&&1/n==-1/0?"-0":r}return rz=t,rz}var iz,pfe;function XX(){if(pfe)return iz;pfe=1;var e=ZNe(),t=bD();function n(r,i){i=e(i,r);for(var o=0,s=i.length;r!=null&&o<s;)r=r[t(i[o++])];return o&&o==s?r:void 0}return iz=n,iz}var oz,mfe;function JNe(){if(mfe)return oz;mfe=1;var e=XX();function t(n,r,i){var o=n==null?void 0:e(n,r);return o===void 0?i:o}return oz=t,oz}var R_t=JNe();const au=cr(R_t);var sz,gfe;function M_t(){if(gfe)return sz;gfe=1;function e(t){return t==null}return sz=e,sz}var __t=M_t();const Rn=cr(__t);var az,yfe;function N_t(){if(yfe)return az;yfe=1;var e=Jh(),t=Na(),n=ep(),r="[object String]";function i(o){return typeof o=="string"||!t(o)&&n(o)&&e(o)==r}return az=i,az}var L_t=N_t();const vb=cr(L_t);var I_t=WX();const yn=cr(I_t);var P_t=Vg();const cS=cr(P_t);var lz={exports:{}},br={};/**
2844
+ `),()=>{var I;(I=a.current)==null||I.removeAttribute("data-motion-pop-id"),N.contains(M)&&N.removeChild(M)}},[t]),y.jsx(z2t,{isPresent:t,childRef:a,sizeRef:l,pop:o,children:o===!1?e:A.cloneElement(e,{ref:d})})}const B2t=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:i,presenceAffectsLayout:o,mode:s,anchorX:a,anchorY:l,root:u})=>{const c=yA(H2t),d=A.useId(),h=A.useRef(n),m=A.useRef(r);rD(()=>{h.current=n,m.current=r});let g=!0,b=A.useMemo(()=>(g=!1,{id:d,initial:t,isPresent:n,custom:i,onExitComplete:v=>{c.set(v,!0);for(const w of c.values())if(!w)return;r&&r()},register:v=>(c.set(v,!1),()=>{var w;c.delete(v),!h.current&&!c.size&&((w=m.current)==null||w.call(m))})}),[n,c,r]);return o&&g&&(b={...b}),A.useMemo(()=>{c.forEach((v,w)=>c.set(w,!1))},[n]),A.useEffect(()=>{!n&&!c.size&&r&&r()},[n]),e=y.jsx(F2t,{pop:s==="popLayout",isPresent:n,anchorX:a,anchorY:l,root:u,children:e}),y.jsx(iD.Provider,{value:b,children:e})};function H2t(){return new Map}function q_e(e=!0){const t=A.useContext(iD);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:i}=t,o=A.useId();A.useEffect(()=>{if(e)return i(o)},[e]);const s=A.useCallback(()=>e&&r&&r(o),[o,r,e]);return!n&&r?[!1,s]:[!0]}const lM=e=>e.key||"";function Qce(e){const t=[];return A.Children.forEach(e,n=>{A.isValidElement(n)&&t.push(n)}),t}const cD=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:i=!0,mode:o="sync",propagate:s=!1,anchorX:a="left",anchorY:l="top",root:u})=>{const[c,d]=q_e(s),h=A.useMemo(()=>Qce(e),[e]),m=s&&!c?[]:h.map(lM),g=A.useRef(!0),b=A.useRef(h),v=yA(()=>new Map),w=A.useRef(new Set),[S,C]=A.useState(h),[E,T]=A.useState(h);rD(()=>{g.current=!1,b.current=h;for(let N=0;N<E.length;N++){const I=lM(E[N]);m.includes(I)?(v.delete(I),w.current.delete(I)):v.get(I)!==!0&&v.set(I,!1)}},[E,m.length,m.join("-")]);const O=[];if(h!==S){let N=[...h];for(let I=0;I<E.length;I++){const D=E[I],P=lM(D);m.includes(P)||(N.splice(I,0,D),O.push(D))}return o==="wait"&&O.length&&(N=O),T(Qce(N)),C(h),null}const{forceRender:M}=A.useContext(eX);return y.jsx(y.Fragment,{children:E.map(N=>{const I=lM(N),D=s&&!c?!1:h===E||m.includes(I),P=()=>{if(w.current.has(I))return;if(v.has(I))w.current.add(I),v.set(I,!0);else return;let F=!0;v.forEach(z=>{z||(F=!1)}),F&&(M==null||M(),T(b.current),s&&(d==null||d()),r&&r())};return y.jsx(B2t,{isPresent:D,initial:!g.current||n?void 0:!1,custom:t,presenceAffectsLayout:i,mode:o,root:u,onExitComplete:D?void 0:P,anchorX:a,anchorY:l,children:N},I)})})},G_e=A.createContext({strict:!1}),Zce={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]};let Jce=!1;function U2t(){if(Jce)return;const e={};for(const t in Zce)e[t]={isEnabled:n=>Zce[t].some(r=>!!n[r])};v_e(e),Jce=!0}function K_e(){return U2t(),RTt()}function V2t(e){const t=K_e();for(const n in e)t[n]={...t[n],...e[n]};v_e(t)}const W2t=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","propagate","ignoreStrict","viewport"]);function uI(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||W2t.has(e)}let Y_e=e=>!uI(e);function q2t(e){typeof e=="function"&&(Y_e=t=>t.startsWith("on")?!uI(t):e(t))}try{q2t(require("@emotion/is-prop-valid").default)}catch{}function G2t(e,t,n){const r={};for(const i in e)i==="values"&&typeof e.values=="object"||Pi(e[i])||(Y_e(i)||n===!0&&uI(i)||!t&&!uI(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}const dD=A.createContext({});function K2t(e,t){if(uD(e)){const{initial:n,animate:r}=e;return{initial:n===!1||rT(n)?n:void 0,animate:rT(r)?r:void 0}}return e.inherit!==!1?t:{}}function Y2t(e){const{initial:t,animate:n}=K2t(e,A.useContext(dD));return A.useMemo(()=>({initial:t,animate:n}),[ede(t),ede(n)])}function ede(e){return Array.isArray(e)?e.join(" "):e}const OX=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function X_e(e,t,n){for(const r in t)!Pi(t[r])&&!A_e(r,n)&&(e[r]=t[r])}function X2t({transformTemplate:e},t){return A.useMemo(()=>{const n=OX();return TX(n,t,e),Object.assign({},n.vars,n.style)},[t])}function Q2t(e,t){const n=e.style||{},r={};return X_e(r,n,e),Object.assign(r,X2t(e,t)),r}function Z2t(e,t){const n={},r=Q2t(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const Q_e=()=>({...OX(),attrs:{}});function J2t(e,t,n,r){const i=A.useMemo(()=>{const o=Q_e();return R_e(o,t,__e(r),e.transformTemplate,e.style),{...o.attrs,style:{...o.style}}},[t]);if(e.style){const o={};X_e(o,e.style,e),i.style={...o,...i.style}}return i}const eAt=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function RX(e){return typeof e!="string"||e.includes("-")?!1:!!(eAt.indexOf(e)>-1||/[A-Z]/u.test(e))}function tAt(e,t,n,{latestValues:r},i,o=!1,s){const l=(s??RX(e)?J2t:Z2t)(t,r,i,e),u=G2t(t,typeof e=="string",o),c=e!==A.Fragment?{...u,...l,ref:n}:{},{children:d}=t,h=A.useMemo(()=>Pi(d)?d.get():d,[d]);return A.createElement(e,{...c,children:h})}function nAt({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,i){return{latestValues:rAt(n,r,i,e),renderState:t()}}function rAt(e,t,n,r){const i={},o=r(e,{});for(const h in o)i[h]=M_(o[h]);let{initial:s,animate:a}=e;const l=uD(e),u=y_e(e);t&&u&&!l&&e.inherit!==!1&&(s===void 0&&(s=t.initial),a===void 0&&(a=t.animate));let c=n?n.initial===!1:!1;c=c||s===!1;const d=c?a:s;if(d&&typeof d!="boolean"&&!lD(d)){const h=Array.isArray(d)?d:[d];for(let m=0;m<h.length;m++){const g=gX(e,h[m]);if(g){const{transitionEnd:b,transition:v,...w}=g;for(const S in w){let C=w[S];if(Array.isArray(C)){const E=c?C.length-1:0;C=C[E]}C!==null&&(i[S]=C)}for(const S in b)i[S]=b[S]}}}return i}const Z_e=e=>(t,n)=>{const r=A.useContext(dD),i=A.useContext(iD),o=()=>nAt(e,t,r,i);return n?o():yA(o)},iAt=Z_e({scrapeMotionValuesFromProps:AX,createRenderState:OX}),oAt=Z_e({scrapeMotionValuesFromProps:N_e,createRenderState:Q_e}),sAt=Symbol.for("motionComponentSymbol");function aAt(e,t,n){const r=A.useRef(n);A.useInsertionEffect(()=>{r.current=n});const i=A.useRef(null);return A.useCallback(o=>{var a;o&&((a=e.onMount)==null||a.call(e,o)),t&&(o?t.mount(o):t.unmount());const s=r.current;if(typeof s=="function")if(o){const l=s(o);typeof l=="function"&&(i.current=l)}else i.current?(i.current(),i.current=null):s(o);else s&&(s.current=o)},[t])}const J_e=A.createContext({});function c1(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function lAt(e,t,n,r,i,o){var C,E;const{visualElement:s}=A.useContext(dD),a=A.useContext(G_e),l=A.useContext(iD),u=A.useContext(wA),c=u.reducedMotion,d=u.skipAnimations,h=A.useRef(null),m=A.useRef(!1);r=r||a.renderer,!h.current&&r&&(h.current=r(e,{visualState:t,parent:s,props:n,presenceContext:l,blockInitialAnimation:l?l.initial===!1:!1,reducedMotionConfig:c,skipAnimations:d,isSVG:o}),m.current&&h.current&&(h.current.manuallyAnimateOnMount=!0));const g=h.current,b=A.useContext(J_e);g&&!g.projection&&i&&(g.type==="html"||g.type==="svg")&&uAt(h.current,n,i,b);const v=A.useRef(!1);A.useInsertionEffect(()=>{g&&v.current&&g.update(n,l)});const w=n[s_e],S=A.useRef(!!w&&typeof window<"u"&&!((C=window.MotionHandoffIsComplete)!=null&&C.call(window,w))&&((E=window.MotionHasOptimisedAnimation)==null?void 0:E.call(window,w)));return rD(()=>{m.current=!0,g&&(v.current=!0,window.MotionIsMounted=!0,g.updateFeatures(),g.scheduleRenderMicrotask(),S.current&&g.animationState&&g.animationState.animateChanges())}),A.useEffect(()=>{g&&(!S.current&&g.animationState&&g.animationState.animateChanges(),S.current&&(queueMicrotask(()=>{var T;(T=window.MotionHandoffMarkAsComplete)==null||T.call(window,w)}),S.current=!1),g.enteringChildren=void 0)}),g}function uAt(e,t,n,r){const{layoutId:i,layout:o,drag:s,dragConstraints:a,layoutScroll:l,layoutRoot:u,layoutAnchor:c,layoutCrossfade:d}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:eNe(e.parent)),e.projection.setOptions({layoutId:i,layout:o,alwaysMeasureLayout:!!s||a&&c1(a),visualElement:e,animationType:typeof o=="string"?o:"both",initialPromotionConfig:r,crossfade:d,layoutScroll:l,layoutRoot:u,layoutAnchor:c})}function eNe(e){if(e)return e.options.allowProjection!==!1?e.projection:eNe(e.parent)}function c$(e,{forwardMotionProps:t=!1,type:n}={},r,i){r&&V2t(r);const o=n?n==="svg":RX(e),s=o?oAt:iAt;function a(u,c){let d;const h={...A.useContext(wA),...u,layoutId:cAt(u)},{isStatic:m}=h,g=Y2t(u),b=s(u,m);if(!m&&typeof window<"u"){dAt();const v=fAt(h);d=v.MeasureLayout,g.visualElement=lAt(e,b,h,i,v.ProjectionNode,o)}return y.jsxs(dD.Provider,{value:g,children:[d&&g.visualElement?y.jsx(d,{visualElement:g.visualElement,...h}):null,tAt(e,u,aAt(b,g.visualElement,c),b,m,t,o)]})}a.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const l=A.forwardRef(a);return l[sAt]=e,l}function cAt({layoutId:e}){const t=A.useContext(eX).id;return t&&e!==void 0?t+"-"+e:e}function dAt(e,t){A.useContext(G_e).strict}function fAt(e){const t=K_e(),{drag:n,layout:r}=t;if(!n&&!r)return{};const i={...n,...r};return{MeasureLayout:n!=null&&n.isEnabled(e)||r!=null&&r.isEnabled(e)?i.MeasureLayout:void 0,ProjectionNode:i.ProjectionNode}}function hAt(e,t){if(typeof Proxy>"u")return c$;const n=new Map,r=(o,s)=>c$(o,s,e,t),i=(o,s)=>r(o,s);return new Proxy(i,{get:(o,s)=>s==="create"?r:(n.has(s)||n.set(s,c$(s,void 0,e,t)),n.get(s))})}const pAt=(e,t)=>t.isSVG??RX(e)?new L_e(t):new O_e(t,{allowProjection:e!==A.Fragment});class mAt extends Vg{constructor(t){super(t),t.animationState||(t.animationState=XTt(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();lD(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)==null||t.call(this)}}let gAt=0;class yAt extends Vg{constructor(){super(...arguments),this.id=gAt++,this.isExitComplete=!1}update(){var o;if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;if(t&&r===!1){if(this.isExitComplete){const{initial:s,custom:a}=this.node.getProps();if(typeof s=="string"||typeof s=="object"&&s!==null&&!Array.isArray(s)){const l=eb(this.node,s,a);if(l){const{transition:u,transitionEnd:c,...d}=l;for(const h in d)(o=this.node.getValue(h))==null||o.jump(d[h])}}this.node.animationState.reset(),this.node.animationState.animateChanges()}else this.node.animationState.setActive("exit",!1);this.isExitComplete=!1;return}const i=this.node.animationState.setActive("exit",!t);n&&!t&&i.then(()=>{this.isExitComplete=!0,n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const bAt={animation:{Feature:mAt},exit:{Feature:yAt}};function SA(e){return{point:{x:e.pageX,y:e.pageY}}}const vAt=e=>t=>SX(t)&&e(t,SA(t));function ZC(e,t,n,r){return iT(e,t,vAt(n),r)}const tNe=({current:e})=>e?e.ownerDocument.defaultView:null,tde=(e,t)=>Math.abs(e-t);function xAt(e,t){const n=tde(e.x,t.x),r=tde(e.y,t.y);return Math.sqrt(n**2+r**2)}const nde=new Set(["auto","scroll"]);class nNe{constructor(t,n,{transformPagePoint:r,contextWindow:i=window,dragSnapToOrigin:o=!1,distanceThreshold:s=3,element:a}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=g=>{this.handleScroll(g.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=uM(this.lastRawMoveEventInfo,this.transformPagePoint));const g=d$(this.lastMoveEventInfo,this.history),b=this.startEvent!==null,v=xAt(g.offset,{x:0,y:0})>=this.distanceThreshold;if(!b&&!v)return;const{point:w}=g,{timestamp:S}=es;this.history.push({...w,timestamp:S});const{onStart:C,onMove:E}=this.handlers;b||(C&&C(this.lastMoveEvent,g),this.startEvent=this.lastMoveEvent),E&&E(this.lastMoveEvent,g)},this.handlePointerMove=(g,b)=>{this.lastMoveEvent=g,this.lastRawMoveEventInfo=b,this.lastMoveEventInfo=uM(b,this.transformPagePoint),Rr.update(this.updatePoint,!0)},this.handlePointerUp=(g,b)=>{this.end();const{onEnd:v,onSessionEnd:w,resumeAnimation:S}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&S&&S(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const C=d$(g.type==="pointercancel"?this.lastMoveEventInfo:uM(b,this.transformPagePoint),this.history);this.startEvent&&v&&v(g,C),w&&w(g,C)},!SX(t))return;this.dragSnapToOrigin=o,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=s,this.contextWindow=i||window;const l=SA(t),u=uM(l,this.transformPagePoint),{point:c}=u,{timestamp:d}=es;this.history=[{...c,timestamp:d}];const{onSessionStart:h}=n;h&&h(t,d$(u,this.history));const m={passive:!0,capture:!0};this.removeListeners=bA(ZC(this.contextWindow,"pointermove",this.handlePointerMove,m),ZC(this.contextWindow,"pointerup",this.handlePointerUp,m),ZC(this.contextWindow,"pointercancel",this.handlePointerUp,m)),a&&this.startScrollTracking(a)}startScrollTracking(t){let n=t.parentElement;for(;n;){const r=getComputedStyle(n);(nde.has(r.overflowX)||nde.has(r.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0}),window.addEventListener("scroll",this.onWindowScroll),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const n=this.scrollPositions.get(t);if(!n)return;const r=t===window,i=r?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},o={x:i.x-n.x,y:i.y-n.y};o.x===0&&o.y===0||(r?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=o.x,this.lastMoveEventInfo.point.y+=o.y):this.history.length>0&&(this.history[0].x-=o.x,this.history[0].y-=o.y),this.scrollPositions.set(t,i),Rr.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),Uh(this.updatePoint)}}function uM(e,t){return t?{point:t(e.point)}:e}function rde(e,t){return{x:e.x-t.x,y:e.y-t.y}}function d$({point:e},t){return{point:e,delta:rde(e,rNe(t)),offset:rde(e,wAt(t)),velocity:SAt(t,.1)}}function wAt(e){return e[0]}function rNe(e){return e[e.length-1]}function SAt(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const i=rNe(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>Sa(t)));)n--;if(!r)return{x:0,y:0};r===e[0]&&e.length>2&&i.timestamp-r.timestamp>Sa(t)*2&&(r=e[1]);const o=eu(i.timestamp-r.timestamp);if(o===0)return{x:0,y:0};const s={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function kAt(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?jr(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?jr(n,e,r.max):Math.min(e,n)),e}function ide(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function CAt(e,{top:t,left:n,bottom:r,right:i}){return{x:ide(e.x,n,i),y:ide(e.y,t,r)}}function ode(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function EAt(e,t){return{x:ode(e.x,t.x),y:ode(e.y,t.y)}}function TAt(e,t){let n=.5;const r=Ys(e),i=Ys(t);return i>r?n=ow(t.min,t.max-r,e.min):r>i&&(n=ow(e.min,e.max-i,t.min)),Ld(0,1,n)}function AAt(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const PV=.35;function OAt(e=PV){return e===!1?e=0:e===!0&&(e=PV),{x:sde(e,"left","right"),y:sde(e,"top","bottom")}}function sde(e,t,n){return{min:ade(e,t),max:ade(e,n)}}function ade(e,t){return typeof e=="number"?e:e[t]||0}const RAt=new WeakMap;class MAt{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=Gi(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:i}=this.visualElement;if(i&&i.isPresent===!1)return;const o=d=>{n&&this.snapToCursor(SA(d).point),this.stopAnimation()},s=(d,h)=>{const{drag:m,dragPropagation:g,onDragStart:b}=this.getProps();if(m&&!g&&(this.openDragLock&&this.openDragLock(),this.openDragLock=sTt(m),!this.openDragLock))return;this.latestPointerEvent=d,this.latestPanInfo=h,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Dc(w=>{let S=this.getAxisMotionValue(w).get()||0;if(Cd.test(S)){const{projection:C}=this.visualElement;if(C&&C.layout){const E=C.layout.layoutBox[w];E&&(S=Ys(E)*(parseFloat(S)/100))}}this.originPoint[w]=S}),b&&Rr.update(()=>b(d,h),!1,!0),TV(this.visualElement,"transform");const{animationState:v}=this.visualElement;v&&v.setActive("whileDrag",!0)},a=(d,h)=>{this.latestPointerEvent=d,this.latestPanInfo=h;const{dragPropagation:m,dragDirectionLock:g,onDirectionLock:b,onDrag:v}=this.getProps();if(!m&&!this.openDragLock)return;const{offset:w}=h;if(g&&this.currentDirection===null){this.currentDirection=NAt(w),this.currentDirection!==null&&b&&b(this.currentDirection);return}this.updateAxis("x",h.point,w),this.updateAxis("y",h.point,w),this.visualElement.render(),v&&Rr.update(()=>v(d,h),!1,!0)},l=(d,h)=>{this.latestPointerEvent=d,this.latestPanInfo=h,this.stop(d,h),this.latestPointerEvent=null,this.latestPanInfo=null},u=()=>{const{dragSnapToOrigin:d}=this.getProps();(d||this.constraints)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:c}=this.getProps();this.panSession=new nNe(t,{onSessionStart:o,onStart:s,onMove:a,onSessionEnd:l,resumeAnimation:u},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:c,distanceThreshold:r,contextWindow:tNe(this.visualElement),element:this.visualElement.current})}stop(t,n){const r=t||this.latestPointerEvent,i=n||this.latestPanInfo,o=this.isDragging;if(this.cancel(),!o||!i||!r)return;const{velocity:s}=i;this.startAnimation(s);const{onDragEnd:a}=this.getProps();a&&Rr.postRender(()=>a(r,i))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.endPanSession();const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(t,n,r){const{drag:i}=this.getProps();if(!r||!cM(t,i,this.currentDirection))return;const o=this.getAxisMotionValue(t);let s=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(s=kAt(s,this.constraints[t],this.elastic[t])),o.set(s)}resolveConstraints(){var o;const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(o=this.visualElement.projection)==null?void 0:o.layout,i=this.constraints;t&&c1(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=CAt(r.layoutBox,t):this.constraints=!1,this.elastic=OAt(n),i!==this.constraints&&!c1(t)&&r&&this.constraints&&!this.hasMutatedConstraints&&Dc(s=>{this.constraints!==!1&&this.getAxisMotionValue(s)&&(this.constraints[s]=AAt(r.layoutBox[s],this.constraints[s]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!c1(t))return!1;const r=t.current,{projection:i}=this.visualElement;if(!i||!i.layout)return!1;i.root&&(i.root.scroll=void 0,i.root.updateScroll());const o=LTt(r,i.root,this.visualElement.getTransformPagePoint());let s=EAt(i.layout.layoutBox,o);if(n){const a=n(MTt(s));this.hasMutatedConstraints=!!a,a&&(s=S_e(a))}return s}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:i,dragTransition:o,dragSnapToOrigin:s,onDragTransitionEnd:a}=this.getProps(),l=this.constraints||{},u=Dc(c=>{if(!cM(c,n,this.currentDirection))return;let d=l&&l[c]||{};(s===!0||s===c)&&(d={min:0,max:0});const h=i?200:1e6,m=i?40:1e7,g={type:"inertia",velocity:r?t[c]:0,bounceStiffness:h,bounceDamping:m,timeConstant:750,restDelta:1,restSpeed:10,...o,...d};return this.startAxisValueAnimation(c,g)});return Promise.all(u).then(a)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return TV(this.visualElement,t),r.start(mX(t,r,0,n,this.visualElement,!1))}stopAnimation(){Dc(t=>this.getAxisMotionValue(t).stop())}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,i=this.visualElement.getProps()[n];return i||this.visualElement.getValue(t,this.visualElement.latestValues[t]??0)}snapToCursor(t){Dc(n=>{const{drag:r}=this.getProps();if(!cM(n,r,this.currentDirection))return;const{projection:i}=this.visualElement,o=this.getAxisMotionValue(n);if(i&&i.layout){const{min:s,max:a}=i.layout.layoutBox[n],l=o.get()||0;o.set(t[n]-jr(s,a,.5)+l)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!c1(n)||!r||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};Dc(s=>{const a=this.getAxisMotionValue(s);if(a&&this.constraints!==!1){const l=a.get();i[s]=TAt({min:l,max:l},this.constraints[s])}});const{transformTemplate:o}=this.visualElement.getProps();this.visualElement.current.style.transform=o?o({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.constraints=!1,this.resolveConstraints(),Dc(s=>{if(!cM(s,t,null))return;const a=this.getAxisMotionValue(s),{min:l,max:u}=this.constraints[s];a.set(jr(l,u,i[s]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;RAt.set(this.visualElement,this);const t=this.visualElement.current,n=ZC(t,"pointerdown",u=>{const{drag:c,dragListener:d=!0}=this.getProps(),h=u.target,m=h!==t&&fTt(h);c&&d&&!m&&this.start(u)});let r;const i=()=>{const{dragConstraints:u}=this.getProps();c1(u)&&u.current&&(this.constraints=this.resolveRefConstraints(),r||(r=_At(t,u.current,()=>this.scalePositionWithinConstraints())))},{projection:o}=this.visualElement,s=o.addEventListener("measure",i);o&&!o.layout&&(o.root&&o.root.updateScroll(),o.updateLayout()),Rr.read(i);const a=iT(window,"resize",()=>this.scalePositionWithinConstraints()),l=o.addEventListener("didUpdate",(({delta:u,hasLayoutChanged:c})=>{this.isDragging&&c&&(Dc(d=>{const h=this.getAxisMotionValue(d);h&&(this.originPoint[d]+=u[d].translate,h.set(h.get()+u[d].translate))}),this.visualElement.render())}));return()=>{a(),n(),s(),l&&l(),r&&r()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:i=!1,dragConstraints:o=!1,dragElastic:s=PV,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:i,dragConstraints:o,dragElastic:s,dragMomentum:a}}}function lde(e){let t=!0;return()=>{if(t){t=!1;return}e()}}function _At(e,t,n){const r=pce(e,lde(n)),i=pce(t,lde(n));return()=>{r(),i()}}function cM(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function NAt(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class LAt extends Vg{constructor(t){super(t),this.removeGroupControls=su,this.removeListeners=su,this.controls=new MAt(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||su}update(){const{dragControls:t}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};t!==n&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}}const f$=e=>(t,n)=>{e&&Rr.update(()=>e(t,n),!1,!0)};class IAt extends Vg{constructor(){super(...arguments),this.removePointerDownListener=su}onPointerDown(t){this.session=new nNe(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:tNe(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:i}=this.node.getProps();return{onSessionStart:f$(t),onStart:f$(n),onMove:f$(r),onEnd:(o,s)=>{delete this.session,i&&Rr.postRender(()=>i(o,s))}}}mount(){this.removePointerDownListener=ZC(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let h$=!1;class PAt extends A.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:i}=this.props,{projection:o}=t;o&&(n.group&&n.group.add(o),r&&r.register&&i&&r.register(o),h$&&o.root.didUpdate(),o.addEventListener("animationComplete",()=>{this.safeToRemove()}),o.setOptions({...o.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),__.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:i,isPresent:o}=this.props,{projection:s}=r;return s&&(s.isPresent=o,t.layoutDependency!==n&&s.setOptions({...s.options,layoutDependency:n}),h$=!0,i||t.layoutDependency!==n||n===void 0||t.isPresent!==o?s.willUpdate():this.safeToRemove(),t.isPresent!==o&&(o?s.promote():s.relegate()||Rr.postRender(()=>{const a=s.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{visualElement:t,layoutAnchor:n}=this.props,{projection:r}=t;r&&(r.options.layoutAnchor=n,r.root.didUpdate(),wX.postRender(()=>{!r.currentAnimation&&r.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:i}=t;h$=!0,i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),r&&r.deregister&&r.deregister(i))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function iNe(e){const[t,n]=q_e(),r=A.useContext(eX);return y.jsx(PAt,{...e,layoutGroup:r,switchLayoutGroup:A.useContext(J_e),isPresent:t,safeToRemove:n})}const jAt={pan:{Feature:IAt},drag:{Feature:LAt,ProjectionNode:W_e,MeasureLayout:iNe}};function ude(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const i="onHover"+n,o=r[i];o&&Rr.postRender(()=>o(t,SA(t)))}class DAt extends Vg{mount(){const{current:t}=this.node;t&&(this.unmount=lTt(t,(n,r)=>(ude(this.node,r,"Start"),i=>ude(this.node,i,"End"))))}unmount(){}}class $At extends Vg{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=bA(iT(this.node.current,"focus",()=>this.onFocus()),iT(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function cde(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const i="onTap"+(n==="End"?"":n),o=r[i];o&&Rr.postRender(()=>o(t,SA(t)))}class zAt extends Vg{mount(){const{current:t}=this.node;if(!t)return;const{globalTapTarget:n,propagate:r}=this.node.props;this.unmount=pTt(t,(i,o)=>(cde(this.node,o,"Start"),(s,{success:a})=>cde(this.node,s,a?"End":"Cancel")),{useGlobalTarget:n,stopPropagation:(r==null?void 0:r.tap)===!1})}unmount(){}}const jV=new WeakMap,p$=new WeakMap,FAt=e=>{const t=jV.get(e.target);t&&t(e)},BAt=e=>{e.forEach(FAt)};function HAt({root:e,...t}){const n=e||document;p$.has(n)||p$.set(n,{});const r=p$.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(BAt,{root:e,...t})),r[i]}function UAt(e,t,n){const r=HAt(t);return jV.set(e,n),r.observe(e),()=>{jV.delete(e),r.unobserve(e)}}const VAt={some:0,all:1};class WAt extends Vg{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){var l;(l=this.stopObserver)==null||l.call(this);const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:i="some",once:o}=t,s={root:n?n.current:void 0,rootMargin:r,threshold:typeof i=="number"?i:VAt[i]},a=u=>{const{isIntersecting:c}=u;if(this.isInView===c||(this.isInView=c,o&&!c&&this.hasEnteredView))return;c&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",c);const{onViewportEnter:d,onViewportLeave:h}=this.node.getProps(),m=c?d:h;m&&m(u)};this.stopObserver=UAt(this.node.current,s,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(qAt(t,n))&&this.startObserver()}unmount(){var t;(t=this.stopObserver)==null||t.call(this),this.hasEnteredView=!1,this.isInView=!1}}function qAt({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const GAt={inView:{Feature:WAt},tap:{Feature:zAt},focus:{Feature:$At},hover:{Feature:DAt}},KAt={layout:{ProjectionNode:W_e,MeasureLayout:iNe}},YAt={...bAt,...GAt,...jAt,...KAt},XAt=hAt(YAt,pAt);function fD(e){const t=yA(()=>Tg(e)),{isStatic:n}=A.useContext(wA);if(n){const[,r]=A.useState(e);A.useEffect(()=>t.on("change",r),[])}return t}function oNe(e,t){const n=fD(t()),r=()=>n.set(t());return r(),rD(()=>{const i=()=>Rr.preRender(r,!1,!0),o=e.map(s=>s.on("change",i));return()=>{o.forEach(s=>s()),Uh(r)}}),n}function QAt(e){XC.current=[],e();const t=oNe(XC.current,e);return XC.current=void 0,t}function bb(e,t,n,r){if(typeof e=="function")return QAt(e);const o=typeof t=="function"?t:kTt(t,n,r),s=Array.isArray(e)?dde(e,o):dde([e],([l])=>o(l)),a=Array.isArray(e)?void 0:e.accelerate;return a&&!a.isTransformed&&typeof t!="function"&&Array.isArray(n)&&(r==null?void 0:r.clamp)!==!1&&(s.accelerate={...a,times:t,keyframes:n,isTransformed:!0}),s}function dde(e,t){const n=yA(()=>[]);return oNe(e,()=>{n.length=0;const r=e.length;for(let i=0;i<r;i++)n[i]=e[i].get();return t(n)})}function ZAt(e,t={}){const{isStatic:n}=A.useContext(wA),r=()=>Pi(e)?e.get():e;if(n)return bb(r);const i=fD(r());return A.useInsertionEffect(()=>CTt(i,e,t),[i,JSON.stringify(t)]),i}function fl(e,t={}){return ZAt(e,{type:"spring",...t})}function uc(){!EX.current&&b_e();const[e]=A.useState(oI.current);return e}function MX(e){return typeof e=="object"&&!Array.isArray(e)}function sNe(e,t,n,r){return e==null?[]:typeof e=="string"&&MX(t)?xX(e,n,r):e instanceof NodeList?Array.from(e):Array.isArray(e)?e.filter(i=>i!=null):[e]}function JAt(e,t,n){return e*(t+1)+n*t}function fde(e,t,n,r){return typeof t=="number"?t:t.startsWith("-")||t.startsWith("+")?Math.max(0,e+parseFloat(t)):t==="<"?n:t.startsWith("<")?Math.max(0,n+parseFloat(t.slice(1))):r.get(t)??e}function eOt(e,t,n){for(let r=0;r<e.length;r++){const i=e[r];i.at>t&&i.at<n&&(iw(e,i),r--)}}function tOt(e,t,n,r,i,o){eOt(e,i,o);for(let s=0;s<t.length;s++)e.push({value:t[s],at:jr(i,o,r[s]),easing:RMe(n,s)})}function nOt(e,t,n=0){const r=t+1+t*n;for(let i=0;i<e.length;i++)e[i]=e[i]/r}function rOt(e,t){return e.at===t.at?e.value===null?1:t.value===null?-1:0:e.at-t.at}const iOt="easeInOut",oOt=20;function sOt(e,{defaultTransition:t={},...n}={},r,i){const o=t.duration||.3,s=new Map,a=new Map,l={},u=new Map;let c=0,d=0,h=0;for(let m=0;m<e.length;m++){const g=e[m];if(typeof g=="string"){u.set(g,d);continue}else if(!Array.isArray(g)){u.set(g.name,fde(d,g.at,c,u));continue}let[b,v,w={}]=g;w.at!==void 0&&(d=fde(d,w.at,c,u));let S=0;const C=(E,T,O,M=0,N=0)=>{const I=aOt(E),{delay:D=0,times:P=WMe(I),type:F=t.type||"keyframes",repeat:z,repeatType:$,repeatDelay:B=0,...H}=T;let{ease:U=t.ease||"easeOut",duration:W}=T;const q=typeof D=="function"?D(M,N):D,Y=I.length,Q=hX(F)?F:i==null?void 0:i[F||"keyframes"];if(Y<=2&&Q){let te=100;if(Y===2&&cOt(I)){const ae=I[1]-I[0];te=Math.abs(ae)}const de={...t,...H};W!==void 0&&(de.duration=Sa(W));const ue=BMe(de,te,Q);U=ue.ease,W=ue.duration}W??(W=o);const G=d+q;P.length===1&&P[0]===0&&(P[1]=1);const le=P.length-I.length;if(le>0&&VMe(P,le),I.length===1&&I.unshift(null),z&&z<oOt){const te=W>0?B/W:0;W=JAt(W,z,B);const de=[...I],ue=[...P];U=Array.isArray(U)?[...U]:[U];const ae=[...U],ie=$==="reverse"||$==="mirror";let he=de,fe=ae;ie&&(he=[...de].reverse(),$==="reverse"&&(fe=[...ae].reverse().map(se=>typeof se=="function"?rX(se):se)));for(let se=0;se<z;se++){const Se=ie&&se%2===0,pe=Se?he:de,Ee=Se?fe:ae,ke=(se+1)*(1+te);te>0&&(I.push(I[I.length-1]),P.push(ke),U.push("linear")),I.push(...pe);for(let Ie=0;Ie<pe.length;Ie++)P.push(ue[Ie]+ke),U.push(Ie===0?"linear":RMe(Ee,Ie-1))}nOt(P,z,te)}const K=G+W;tOt(O,I,U,P,G,K),S=Math.max(q+W,S),h=Math.max(K,h)};if(Pi(b)){const E=hde(b,a);C(v,w,pde("default",E))}else{const E=sNe(b,v,r,l),T=E.length;for(let O=0;O<T;O++){v=v,w=w;const M=E[O],N=hde(M,a);for(const I in v)C(v[I],lOt(w,I),pde(I,N),O,T)}}c=d,d+=S}return a.forEach((m,g)=>{for(const b in m){const v=m[b];v.sort(rOt);const w=[],S=[],C=[];for(let M=0;M<v.length;M++){const{at:N,value:I,easing:D}=v[M];w.push(I),S.push(ow(0,h,N)),C.push(D||"easeOut")}S[0]!==0&&(S.unshift(0),w.unshift(w[0]),C.unshift(iOt)),S[S.length-1]!==1&&(S.push(1),w.push(null)),s.has(g)||s.set(g,{keyframes:{},transition:{}});const E=s.get(g);E.keyframes[b]=w;const{type:T,...O}=t;E.transition[b]={...O,duration:h,ease:C,times:S,...n}}}),s}function hde(e,t){return!t.has(e)&&t.set(e,{}),t.get(e)}function pde(e,t){return t[e]||(t[e]=[]),t[e]}function aOt(e){return Array.isArray(e)?e:[e]}function lOt(e,t){return e&&e[t]?{...e,...e[t]}:{...e}}const uOt=e=>typeof e=="number",cOt=e=>e.every(uOt);function dOt(e){const t={presenceContext:null,props:{},visualState:{renderState:{transform:{},transformOrigin:{},style:{},vars:{},attrs:{}},latestValues:{}}},n=aD(e)&&!g_e(e)?new L_e(t):new O_e(t);n.mount(e),nT.set(e,n)}function fOt(e){const t={presenceContext:null,props:{},visualState:{renderState:{output:{}},latestValues:{}}},n=new FTt(t);n.mount(e),nT.set(e,n)}function hOt(e,t){return Pi(e)||typeof e=="number"||typeof e=="string"&&!MX(t)}function aNe(e,t,n,r){const i=[];if(hOt(e,t))i.push(B_e(e,MX(t)&&t.default||t,n&&(n.default||n)));else{if(e==null)return i;const o=sNe(e,t,r),s=o.length;for(let a=0;a<s;a++){const l=o[a],u=l instanceof Element?dOt:fOt;nT.has(l)||u(l);const c=nT.get(l),d={...n};"delay"in d&&typeof d.delay=="function"&&(d.delay=d.delay(a,s)),i.push(...bX(c,{...t,transition:d},{}))}}return i}function pOt(e,t,n){const r=[],i=e.map(s=>{if(Array.isArray(s)&&typeof s[0]=="function"){const a=s[0],l=Tg(0);return l.on("change",a),s.length===1?[l,[0,1]]:s.length===2?[l,[0,1],s[1]]:[l,s[1],s[2]]}return s});return sOt(i,t,n,{spring:eT}).forEach(({keyframes:s,transition:a},l)=>{r.push(...aNe(l,s,a))}),r}function mOt(e){return Array.isArray(e)&&e.some(Array.isArray)}function gOt(e={}){const{scope:t,reduceMotion:n,skipAnimations:r}=e;function i(o,s,a){let l=[],u;const c={};if(n!==void 0&&(c.reduceMotion=n),r!==void 0&&(c.skipAnimations=r),mOt(o)){const{onComplete:h,...m}=s||{};typeof h=="function"&&(u=h),l=pOt(o,{...c,...m},t)}else{const{onComplete:h,...m}=a||{};typeof h=="function"&&(u=h),l=aNe(o,s,{...c,...m},t)}const d=new REt(l);return u&&d.finished.then(u),t&&(t.animations.push(d),d.finished.then(()=>{iw(t.animations,d)})),d}return i}const mh=gOt(),or=XAt,DV=2.2,_X=280,lNe=.45,yOt=30,tu=[.85,0,.15,1],JC=10;function uNe(e){switch(e){case"loading":return"loop";case"exiting":return"exit";case"revealingLoading":return"enter";default:return null}}function bOt(e,t,n,r){const i=fD(0),o=e+JC*2,s=e+JC,a=bb(i,u=>u<=.5?u/.5*o:(1-(u-.5)/.5)*o),l=bb(i,u=>{if(u<=.5)return-JC;const c=(u-.5)/.5;return s-(1-c)*o});return A.useEffect(()=>{if(e<=0)return;const u=DV/2;let c=!1,d;const h=()=>{c||r==null||r()},m=g=>{const b=u*((1-g)/.5);d=mh(i,1,{duration:Math.max(b,.01),ease:[...tu],onComplete:h})};if(t==="loop")return i.set(0),d=mh(i,1,{duration:DV,ease:[...tu],onComplete:h}),()=>{c=!0,d==null||d.stop()};if(t==="exit"){const g=i.get();if(g<.5){const b=u*((.5-g)/.5);d=mh(i,.5,{duration:Math.max(b,.01),ease:[...tu],onComplete:()=>{c||m(.5)}})}else m(g);return()=>{c=!0,d==null||d.stop()}}if(t==="enter")return i.set(0),d=mh(i,.5,{duration:u,ease:[...tu],onComplete:h}),()=>{c=!0,d==null||d.stop()}},[e,n,t,r,i]),{clipX:l,clipWidth:a}}function NX({pathD:e,mode:t="loop",loopEpoch:n=0,stroke:r=Bo.foreground,strokeOpacity:i=.5,strokeWidth:o=2.5,onCycleComplete:s}){const{innerWidth:a,innerHeight:l}=_a(),u=A.useId(),c=`line-loading-clip-${u}`,d=`line-loading-gradient-${u}`,h=qL(Hj(!0)),m=l+JC*2,{clipX:g,clipWidth:b}=bOt(a,t,n,s);return a<=0?null:y.jsxs(y.Fragment,{children:[y.jsxs("defs",{children:[y.jsx("clipPath",{id:c,children:y.jsx(or.rect,{height:m,style:{width:b,x:g},y:-JC})}),y.jsx("linearGradient",{id:d,...GL(a),children:h.map(v=>y.jsx("stop",{offset:v.offset,stopColor:r,stopOpacity:v.opacity},v.offset))})]}),y.jsx("path",{clipPath:`url(#${c})`,d:e,fill:"none",opacity:i,stroke:`url(#${d})`,strokeLinecap:"round",strokeWidth:o})]})}NX.displayName="LineLoadingPulseStroke";const cNe=2,m$=-1,vOt=2,xOt=25,wOt=20,SOt=80,kOt=14,COt=2,EOt=12,TOt="var(--foreground)",AOt=.45,OOt=.55,ROt=.18,MOt=.02,_Ot=.7;function dNe(e){const t=Math.sin(e)*43758.5453;return t-Math.floor(t)}function fNe(e,t=0,n=wOt,r=SOt){const i=r-n;return Array.from({length:e},(o,s)=>n+Math.floor(dNe((s+1)*12.9898+t)*i))}function NOt(e,t=0){return Array.from({length:e},(n,r)=>dNe((r+1)*78.233+t)<.5?-1:1)}function LOt(e=17,t=.05,n=.9){return Array.from({length:e},(r,i)=>{const o=i/(e-1),s=Math.sin(o*Math.PI)**2,a=t+s*(n-t);return{offset:`${(o*100).toFixed(0)}%`,opacity:Number(a.toFixed(3))}})}function hNe({chartId:e,width:t,height:n,durationSeconds:r,onSweepComplete:i}){const o=A.useMemo(()=>LOt(),[]),s=A.useRef(m$),a=A.useCallback(l=>{const u=typeof l.x=="number"?l.x:m$;u>=1&&s.current<1&&i(),s.current=u},[i]);return y.jsxs(y.Fragment,{children:[y.jsx("linearGradient",{id:`${e}-grad`,x1:"0",x2:"1",y1:"0",y2:"0",children:o.map(({offset:l,opacity:u})=>y.jsx("stop",{offset:l,stopColor:"white",stopOpacity:u},l))}),y.jsx("pattern",{height:"1",id:`${e}-pattern`,patternContentUnits:"objectBoundingBox",patternTransform:`rotate(${xOt})`,patternUnits:"objectBoundingBox",width:3,x:"0",y:"0",children:y.jsx(or.rect,{animate:{x:vOt},fill:`url(#${e}-grad)`,height:"1",initial:{x:m$},onUpdate:a,transition:{duration:r,ease:"linear",repeat:Number.POSITIVE_INFINITY,repeatType:"loop"},width:"1",y:"0"})}),y.jsx("mask",{id:`${e}-mask`,maskUnits:"userSpaceOnUse",children:y.jsx("rect",{fill:`url(#${e}-pattern)`,height:n,width:t})})]})}function LX({curve:e,withArea:t=!1,mode:n="loop",onTransitionComplete:r,stroke:i=Bo.foreground,strokeOpacity:o=OOt,strokeWidth:s=2,pointCount:a=kOt,durationSeconds:l=cNe}){const{innerWidth:u,innerHeight:c}=_a(),d=uc(),m=`line-sweep-${A.useId().replace(/[^a-zA-Z0-9_-]/g,"")}`,g=n==="loop",[b,v]=A.useState(0),w=A.useCallback(()=>{g&&v(F=>F+1)},[g]),S=A.useMemo(()=>fNe(a,b),[a,b]);if(A.useEffect(()=>{d&&!g&&(r==null||r())},[d,g,r]),u<=0||c<=0||S.length<2)return null;const C=Hh({domain:[0,S.length-1],range:[0,u]}),E=Hh({domain:[0,100],range:[c,0]}),T=S.map((F,z)=>({index:z,value:F})),O=F=>C(F.index),M=F=>E(F.value),N=y.jsxs(y.Fragment,{children:[t?y.jsx(PY,{curve:e,data:T,fill:`url(#${m}-area)`,x:O,y:M,yScale:E}):null,y.jsx(IY,{curve:e,data:T,fill:"none",stroke:i,strokeLinecap:"round",strokeOpacity:o,strokeWidth:s,x:O,y:M})]}),I=t?y.jsxs("linearGradient",{id:`${m}-area`,x1:"0",x2:"0",y1:"0",y2:"1",children:[y.jsx("stop",{offset:"0%",stopColor:i,stopOpacity:ROt}),y.jsx("stop",{offset:"100%",stopColor:i,stopOpacity:MOt})]}):null;if(d)return y.jsxs(y.Fragment,{children:[I?y.jsx("defs",{children:I}):null,N]});const D=`url(#${m}-mask)`,P=y.jsxs("defs",{children:[I,y.jsx(hNe,{chartId:m,durationSeconds:l,height:c,onSweepComplete:w,width:u})]});return g?y.jsxs(y.Fragment,{children:[P,y.jsx("g",{mask:D,children:N})]}):y.jsxs(y.Fragment,{children:[P,y.jsx(or.g,{animate:{opacity:n==="exit"?0:1},initial:{opacity:n==="exit"?1:0},mask:D,onAnimationComplete:r,transition:{duration:lNe,ease:[...tu]},children:N})]})}LX.displayName="LineLoadingSweep";function IOt({heights:e,signs:t,innerWidth:n,innerHeight:r,baseline:i,barFraction:o,fill:s,fillOpacity:a}){const l=n/e.length,u=l*o,c=l*(1-o)/2,d=i==="center",h=d?r/2:r,m=d?r/2:r;return y.jsx(y.Fragment,{children:e.map((g,b)=>{const v=d?t[b]??1:1,w=Math.max(1,m*(g/100)),S=b*l+c,C=v===1?h-w:h;return y.jsx("rect",{fill:s,fillOpacity:a,height:w,rx:COt,width:u,x:S,y:C},`${S.toFixed(2)}-${g}`)})})}function pNe({innerWidth:e,innerHeight:t,barCount:n=EOt,fill:r=TOt,fillOpacity:i=AOt,baseline:o="bottom",barFraction:s=_Ot,durationSeconds:a=cNe}){const l=uc(),c=`bar-sweep-${A.useId().replace(/[^a-zA-Z0-9_-]/g,"")}`,[d,h]=A.useState(0),m=A.useCallback(()=>h(w=>w+1),[]),g=A.useMemo(()=>fNe(n,d),[n,d]),b=A.useMemo(()=>NOt(n,d),[n,d]);if(e<=0||t<=0)return null;const v=y.jsx(IOt,{barFraction:s,baseline:o,fill:r,fillOpacity:i,heights:g,innerHeight:t,innerWidth:e,signs:b});return l?v:y.jsxs(y.Fragment,{children:[y.jsx("defs",{children:y.jsx(hNe,{chartId:c,durationSeconds:a,height:t,onSweepComplete:m,width:e})}),y.jsx("g",{mask:`url(#${c}-mask)`,children:v})]})}pNe.displayName="BarLoadingSkeleton";const POt={pathD:null,pathLength:0};function mNe(e,t){const[n,r]=A.useState(POt);return A.useEffect(()=>{const i=e.current;if(!i)return;const o=i.getAttribute("d"),s=o?i.getTotalLength():0;r(a=>a.pathD===o&&a.pathLength===s?a:{pathD:o,pathLength:s})},t),n}function IX(e,t){return e!=null&&e>=0&&e<t-1}function jOt(e,t,n,r){const i=e[t];return i?n(r(i))??0:0}function DOt({pathD:e,pathLength:t,dashStartLength:n,dashStartX:r,innerWidth:i,innerHeight:o,stroke:s,strokeWidth:a,dashArray:l}){const u=A.useId().replace(/:/g,"");if(!e||t<=0||n>=t)return null;const c=a*2,d=Math.max(0,i-r+c);return y.jsxs(y.Fragment,{children:[y.jsx("defs",{children:y.jsx("clipPath",{id:u,children:y.jsx("rect",{height:o+c,width:d,x:r-a,y:-a})})}),y.jsx("path",{d:e,fill:"none",stroke:s,strokeDasharray:`${n} ${Math.max(1,t-n)}`,strokeLinecap:"round",strokeWidth:a}),y.jsx("path",{clipPath:`url(#${u})`,d:e,fill:"none",stroke:s,strokeDasharray:l,strokeLinecap:"round",strokeWidth:a})]})}function $Ot({dashFromIndex:e,dashArray:t,data:n,pathD:r,pathLength:i,innerWidth:o,innerHeight:s,stroke:a,strokeWidth:l,xScale:u,xAccessor:c}){const d=IX(e,n.length),h=A.useMemo(()=>!d||e==null?0:jOt(n,e,u,c),[d,e,n,u,c]),m=A.useMemo(()=>!d||e==null||i<=0?0:e/Math.max(1,n.length-1)*i,[d,e,n.length,i]);return!d||e==null||i<=0?null:y.jsx(DOt,{dashArray:t,dashStartLength:m,dashStartX:h,innerHeight:s,innerWidth:o,pathD:r,pathLength:i,stroke:a,strokeWidth:l})}const gNe=A.memo($Ot);function yNe({pathRef:e,visible:t,stroke:n,strokeWidth:r,height:i,x:o,width:s}){const a=A.useId();return t&&e.current?y.jsxs(y.Fragment,{children:[y.jsx("defs",{children:y.jsx("clipPath",{id:a,children:y.jsx(or.rect,{height:i,width:s,x:o,y:0})})}),y.jsx(or.path,{animate:{opacity:1},clipPath:`url(#${a})`,d:e.current.getAttribute("d")||"",exit:{opacity:0},fill:"none",initial:{opacity:0},stroke:n,strokeLinecap:"round",strokeWidth:r,transition:{duration:.4,ease:"easeInOut"}})]}):null}yNe.displayName="HighlightSegment";const cI={tooltipSpring:{stiffness:300,damping:30},tooltipBoxSpring:{stiffness:100,damping:20},highlightSpring:{stiffness:180,damping:28}},zOt=A.createContext(null);function $b(){return A.useContext(zOt)??cI}const _0=cI.tooltipBoxSpring.damping;function FOt(e){if(e===0)return{animate:!1,springConfig:cI.tooltipBoxSpring};const t=e??_0;let n=cI.tooltipBoxSpring.stiffness;if(t<_0){const r=(_0-t)/_0;n+=r*400}else if(t>_0){const r=(t-_0)/(100-_0);n-=r*85}return{animate:!0,springConfig:{stiffness:Math.max(12,Math.round(n)),damping:t}}}const N_={x:0,width:0,isActive:!1};function BOt(e,t,n,r,i){if(e.length===0)return N_;if(i!=null&&i.active){const h=Math.min(i.startX,i.endX),m=Math.abs(i.endX-i.startX);return{x:h,width:m,isActive:!0}}if(!r)return N_;const o=r.index,s=Math.max(0,o-1),a=Math.min(e.length-1,o+1),l=e[s],u=e[a];if(!(l&&u))return N_;const c=t(n(l))??0,d=t(n(u))??0;return{x:c,width:Math.max(0,d-c),isActive:!0}}function HOt({enabled:e=!0}={}){const{data:t,xScale:n,xAccessor:r}=_a(),{tooltipData:i,selection:o}=gA(),{highlightSpring:s}=$b(),a=A.useMemo(()=>e?BOt(t,n,r,i,o):N_,[e,t,n,r,i,o]),l=fl(0,s),u=fl(0,s),c=A.useRef(!1);return a.isActive&&!c.current?(l.jump(a.x),u.jump(a.width)):(l.set(a.x),u.set(a.width)),c.current=a.isActive,{xSpring:l,widthSpring:u,isActive:a.isActive}}function PX({enabled:e,height:t,pathRef:n,stroke:r,strokeWidth:i}){const{isLoaded:o}=_a(),{xSpring:s,widthSpring:a,isActive:l}=HOt({enabled:e});return y.jsx(yNe,{height:t,pathRef:n,stroke:r,strokeWidth:i,visible:e&&l&&o,width:a,x:s})}PX.displayName="SeriesHighlightLayer";const UOt=A.createContext(null);function jX(){return A.useContext(UOt)??{hoveredIndex:null,setHoveredIndex:()=>{}}}function DX({enabled:e=!0,dimOpacity:t=.5,durationSec:n=.4,seriesIndex:r,children:i}){const{tooltipData:o,selection:s}=gA(),{hoveredIndex:a}=jX(),l=o!==null||(s==null?void 0:s.active)===!0,c=e&&(l||a!==null&&r!==void 0&&a!==r)?t:1;return y.jsx(or.g,{animate:{opacity:c},initial:{opacity:1},transition:{duration:n,ease:"easeInOut"},children:i})}DX.displayName="SeriesHoverDim";const bNe="cubic-bezier(0.85, 0, 0.15, 1)",vNe=1100,oT={type:"tween",duration:vNe/1e3,ease:[.85,0,.15,1]};function xNe(e){return(e==null?void 0:e.type)==="tween"?{...e,ease:e.ease??oT.ease}:{type:"tween",duration:typeof(e==null?void 0:e.duration)=="number"?e.duration:vNe/1e3,ease:oT.ease}}function wNe({fill:e,stroke:t,strokeWidth:n,ringGap:r,outlineWidth:i,outlineColor:o,radius:s}){const a=t??e??"currentColor",l=o??a,u=n>0?s+r+n:s,c=i>0?u+i/2:0;return y.jsxs(y.Fragment,{children:[i>0?y.jsx("circle",{cx:0,cy:0,fill:"none",r:c,stroke:l,strokeWidth:i}):null,y.jsx("circle",{cx:0,cy:0,fill:e,r:s}),n>0?y.jsx("circle",{cx:0,cy:0,fill:"none",r:s+r+n/2,stroke:a,strokeWidth:n}):null]})}const SNe=A.memo(function({cx:t,cy:n,scale:r=1,fill:i,stroke:o,strokeWidth:s=2,ringGap:a=2,outlineWidth:l=0,outlineColor:u,radius:c=5}){return y.jsx("g",{transform:`translate(${t}, ${n}) scale(${r})`,children:y.jsx(wNe,{fill:i,outlineColor:u,outlineWidth:l,radius:c,ringGap:a,stroke:o,strokeWidth:s})})});function VOt({dataKey:e,index:t,cx:n,cy:r,enterBlur:i=2,revealDelay:o,revealEpoch:s,enterDuration:a,fill:l,stroke:u,strokeWidth:c=2,ringGap:d=2,outlineWidth:h=0,outlineColor:m,radius:g=5}){const b={hidden:{opacity:0,filter:`blur(${i}px)`,scale:1},visible:{opacity:1,filter:"blur(0px)",scale:1,transition:{delay:o,duration:a,ease:oT.ease}}};return y.jsx("g",{transform:`translate(${n}, ${r})`,children:y.jsx(or.g,{animate:"visible",initial:"hidden",variants:b,children:y.jsx(wNe,{fill:l,outlineColor:m,outlineWidth:h,radius:g,ringGap:d,stroke:u,strokeWidth:c})},`${e}-${t}-${s}`)})}function WOt(e){const t=e.radius??5,n=e.strokeWidth??2,r=e.ringGap??2,i=e.outlineWidth??0,o=e.showActiveHighlight??!0,s=n>0?r+n:0,a=i>0?i:0,l=o?t*.35:0;return t+s+a+l+2}function $X({dataKey:e,fill:t,stroke:n,strokeWidth:r=2,ringGap:i=2,outlineWidth:o=0,outlineColor:s,radius:a=5,animate:l=!0,fadeOnHover:u=!0,inactiveOpacity:c=.5,inactiveBlur:d=2,enterBlur:h=2,showActiveHighlight:m=!0}){const{data:g,xScale:b,innerWidth:v,enterTransition:w,animationDuration:S,revealEpoch:C,isLoaded:E,xAccessor:T,lines:O}=_a(),M=A.useMemo(()=>{const G=O.findIndex(le=>le.dataKey===e);return G>=0?G:0},[O,e]),N=O[M],I=mA(N==null?void 0:N.yAxisId),D=Q8[M%Q8.length]??Q8[0],P=t??(N==null?void 0:N.stroke)??D,F=n??P,z=A.useMemo(()=>WOt({radius:a,strokeWidth:r,ringGap:i,outlineWidth:o,showActiveHighlight:m}),[a,r,i,o,m]),$=xNe(w).duration??S/1e3,B=.5,H=l&&!E,U=A.useCallback(G=>{const le=G[e];return typeof le=="number"?I(le)??0:null},[e,I]),W=A.useMemo(()=>g.flatMap((G,le)=>{const K=U(G);if(K===null)return[];const te=b(T(G))??0,de=Math.max(0,te-z),ue=v>0&&H?de/v*$:0;return[{index:le,cx:te,cy:K,revealDelay:ue}]}),[g,U,b,T,v,H,$,z]),q=A.useMemo(()=>({fill:P,stroke:F,strokeWidth:r,ringGap:i,outlineWidth:o,outlineColor:s,radius:a}),[P,F,r,i,o,s,a]);if(H)return y.jsx("g",{children:W.map(G=>y.jsx(VOt,{cx:G.cx,cy:G.cy,dataKey:e,enterBlur:h,enterDuration:B,index:G.index,revealDelay:G.revealDelay,revealEpoch:C??0,...q},`${e}-${G.index}`))});const Y=W.map(G=>y.jsx(SNe,{cx:G.cx,cy:G.cy,...q},`${e}-${G.index}`)),Q=m?1.35:1;return y.jsxs("g",{children:[y.jsx(qOt,{enabled:u,inactiveBlur:d,inactiveOpacity:c,seriesIndex:M,children:Y}),y.jsx(GOt,{activeScale:Q,enabled:u,markerStyle:q,points:W})]})}$X.displayName="SeriesMarkers";function qOt({enabled:e,inactiveOpacity:t,inactiveBlur:n,seriesIndex:r,children:i}){const{tooltipData:o}=gA(),{hoveredIndex:s}=jX(),l=e&&(o!==null||s!==null&&s!==r);return y.jsx("g",{opacity:l?t:1,style:{transition:"opacity 0.15s ease-in-out, filter 0.15s ease-in-out",filter:l&&n>0?`blur(${n}px)`:"none"},children:i})}function GOt({enabled:e,points:t,markerStyle:n,activeScale:r}){const{tooltipData:i}=gA();if(!e||i===null)return null;const o=t.find(s=>s.index===i.index);return o?y.jsx(SNe,{cx:o.cx,cy:o.cy,scale:r,...n}):null}function KOt(e,t,n,r){const i=uNe(e),o=t===!1?null:n??(t===!0?"loop":i),s=o!=null,a=e==="revealing"||e==="ready"||e==="exitingReady",[l,u]=A.useState(0);return{handleLoadingPulseComplete:A.useCallback(()=>{if(o==="loop"){window.setTimeout(()=>{u(d=>d+1)},_X);return}r==null||r()},[r,o]),pulseMode:o,pulseEpoch:l,showLoadingPulse:s,showSeriesContent:a}}function zX({dataKey:e,yAxisId:t,fill:n=Bo.linePrimary,fillOpacity:r=.4,stroke:i,strokeWidth:o=2,curve:s=LY,animate:a=!0,showLine:l=!0,showHighlight:u=!0,gradientToOpacity:c=0,gradientSpan:d=1,fadeEdges:h=!1,showMarkers:m=!1,markers:g,dashFromIndex:b,dashArray:v="6,4",loading:w,loadingStroke:S=Bo.foreground,loadingStrokeOpacity:C=.5,loadingPulseMode:E,loadingStyle:T="pulse"}){const{data:O,renderData:M,xScale:N,innerHeight:I,innerWidth:D,xAccessor:P,lines:F,chartPhase:z,notifyLoadingPulseComplete:$}=_a(),B=mA(t),{handleLoadingPulseComplete:H,pulseMode:U,pulseEpoch:W,showLoadingPulse:q,showSeriesContent:Y}=KOt(z,w,E,$),Q=A.useMemo(()=>{const _e=F.findIndex(He=>He.dataKey===e);return _e>=0?_e:0},[F,e]),G=A.useRef(null),{pathLength:le,pathD:K}=mNe(G,[M,D,b,l,Y,q]),te=A.useId(),de=`area-gradient-${e}-${te}`,ue=`area-stroke-gradient-${e}-${te}`,ae=`area-edge-mask-${e}-${te}`,ie=`${ae}-gradient`,he=n.startsWith("url("),fe=he||r>0,se=he?n:`url(#${de})`,Se=i||(he?Bo.linePrimary:n),pe=A.useCallback(_e=>{const He=_e[e];return typeof He=="number"?B(He)??0:0},[e,B]),Ee=IX(b,O.length),ke=Hj(h),Ie=ke.any&&!he;let Be=Se;!Ie&&ke.any&&(Be=`url(#${ue})`);const Oe=u&&l&&!q&&Y,Le=Y&&l;let ge="transparent";Le&&!Ee&&(ge=Be);const $e=l&&(Y||q),Ye=y.jsxs(y.Fragment,{children:[Y&&fe?y.jsx(PY,{curve:s,data:M,fill:se,x:_e=>N(P(_e))??0,y:pe,yScale:B}):null,$e?y.jsxs(y.Fragment,{children:[y.jsx(IY,{curve:s,data:M,innerRef:G,stroke:ge,strokeLinecap:"round",strokeWidth:o,x:_e=>N(P(_e))??0,y:pe}),Le?y.jsx(gNe,{dashArray:v,dashFromIndex:b,data:O,innerHeight:I,innerWidth:D,pathD:K,pathLength:le,stroke:Be,strokeWidth:o,xAccessor:P,xScale:N}):null]}):null]}),tt=q&&D>0&&T==="sweep",Ae=q&&D>0&&!tt;return y.jsxs(y.Fragment,{children:[y.jsx(Vxt,{edgeGradientId:ie,edgeMaskId:ae,fadeEdges:h,fill:n,fillOpacity:r,gradientId:de,gradientSpan:d,gradientToOpacity:c,innerHeight:I,innerWidth:D,isPatternFill:he,resolvedStroke:Se,strokeGradientId:ue}),y.jsx(DX,{dimOpacity:.6,enabled:u,seriesIndex:Q,children:Ie?y.jsx("g",{mask:`url(#${ae})`,children:Ye}):Ye}),y.jsx(PX,{enabled:Oe,height:I,pathRef:G,stroke:Se,strokeWidth:o}),m&&Y?y.jsx($X,{animate:a,dataKey:e,...g,fill:(g==null?void 0:g.fill)??Se,stroke:(g==null?void 0:g.stroke)??(g==null?void 0:g.fill)??Se}):null,tt?y.jsx(LX,{curve:s,mode:U??"loop",onTransitionComplete:H,stroke:S,strokeOpacity:C,strokeWidth:o,withArea:!0},"loading-sweep"):null,Ae&&K?y.jsx(NX,{loopEpoch:W,mode:U??void 0,onCycleComplete:H,pathD:K,stroke:S,strokeOpacity:C,strokeWidth:o},"loading-pulse"):null]})}zX.displayName="Area";function YOt({text:e,duration:t=1,isStopped:n=!1,paused:r=!1,className:i,...o}){const s=uc(),a=n||r||s===!0,l=A.useCallback(u=>({running:{color:["var(--color)","var(--shimmering-color)","var(--color)"],transition:{duration:t,repeat:Number.POSITIVE_INFINITY,repeatType:"loop",repeatDelay:e.length*.05,delay:u*t/e.length,ease:"easeInOut"}},stopped:{color:"var(--color)",transition:{duration:t*.5,ease:"easeOut"}}}),[t,e.length]);return y.jsxs(or.span,{className:X("inline-flex select-none items-center leading-none","[--color:var(--muted-foreground)] [--shimmering-color:var(--foreground)]",i),...o,children:[e.split("").map((u,c)=>y.jsx(or.span,{animate:a?"stopped":"running","aria-hidden":!0,className:"inline-block whitespace-pre leading-none",initial:"stopped",variants:l(c),children:u},c)),y.jsx("span",{className:"sr-only",children:e})]})}function kNe({text:e="Loading",className:t,exiting:n=!1}){return e.trim()?y.jsx(or.div,{animate:{y:n?yOt:0,opacity:n?0:1,filter:n?"blur(2px)":"blur(0px)"},"aria-live":"polite",className:X("pointer-events-none absolute inset-0 flex items-center justify-center",t),initial:!1,role:"status",transition:{duration:lNe,ease:[...tu]},children:y.jsx(YOt,{className:"font-medium text-sm tracking-wide [--color:var(--muted-foreground)] [--shimmering-color:var(--foreground)]",text:e})}):null}const FX="ready",kA=500,mde=.02;function hD(e){return e==="loading"?"loading":"ready"}function XOt(e){return e==="ready"}const QOt={chartPhase:"ready",chartStatus:"ready",loadingLabel:void 0,yDomainTweenDuration:kA,yDomainSkeletonByAxis:{left:[0,100]},yDomainTargetByAxis:{left:[0,100]}};function CNe({dataKey:e,fill:t,curve:n=LY}){const{renderData:r,xScale:i,yScale:o,xAccessor:s}=_a();return y.jsx(PY,{curve:n,data:r,fill:t,x:a=>i(s(a))??0,y:a=>{const l=a[e];return typeof l=="number"?o(l)??0:0},yScale:o})}CNe.displayName="PatternArea";const ZOt="__chartClipPassthrough";function BX(e){return typeof e=="function"&&e[ZOt]===!0}function HX(e){if(BX(e.type)){const t=e.props.children;if(A.isValidElement(t))return HX(t)}return e}function ENe(e,t){let n=0;const r=i=>{A.Children.forEach(i,o=>{if(A.isValidElement(o)){if(o.type===A.Fragment){r(o.props.children);return}t(o,n),n+=1}})};r(e)}const JOt=new Set(["Background","Grid","XAxis","YAxis","BarXAxis","BarYAxis","LiveXAxis","LiveYAxis"]),eRt=new Set(["ReferenceArea","BarColumnTrack"]);function TNe(e){const t=e.type;if(t.__isChartMarkers||t.__isPostOverlay)return!0;const n=typeof e.type=="function"&&(t.displayName||t.name)||"";return n==="ChartMarkers"||n==="MarkerGroup"||n==="ChartBrush"}function ANe(e){const t=e.type,n=typeof e.type=="function"&&(t.displayName||t.name)||"";return eRt.has(n)}function ONe(e){const t=e.type,n=typeof e.type=="function"&&(t.displayName||t.name)||"";return JOt.has(n)}function dM(e){return e.map((t,n)=>A.cloneElement(t,{key:t.key??`chart-layer-${n}`}))}function RNe(e){const t=e.type;return typeof e.type=="function"&&(t.displayName||t.name)||""}const tRt=new Set(["Lines","Circles","Waves","Hexagons","Path","Pattern"]);function MNe(e){const t=RNe(e);return t.includes("Pattern")||tRt.has(t)}function _Ne(e){const t=RNe(e);return t.includes("Gradient")||t==="LinearGradient"||t==="RadialGradient"}const Ag=new Intl.DateTimeFormat("en-US",{month:"short",day:"numeric"}),nRt=new Intl.DateTimeFormat("en-US",{weekday:"short",month:"short",day:"numeric"}),rRt=new Intl.NumberFormat("en-US").format;function iRt({clipPathId:e,height:t,targetWidth:n,enterTransition:r,revealEpoch:i,padding:o=0,animating:s=!0,mode:a="reveal",onComplete:l}){const u=xNe(r),c=Math.max(0,n+o*2),d=t+o*2;if(!s)return y.jsx("clipPath",{id:e,children:y.jsx("rect",{height:d,width:c,x:-o,y:-o})});if(a==="conceal"){const h=-o+c;return y.jsx("clipPath",{id:e,children:y.jsx(or.rect,{animate:{width:0,x:h},height:d,initial:{width:c,x:-o},onAnimationComplete:()=>l==null?void 0:l(),transition:u,y:-o},`conceal-${i}`)})}return y.jsx("clipPath",{id:e,children:y.jsx(or.rect,{animate:{width:c},height:d,initial:{width:0},transition:u,width:c,x:-o,y:-o},`reveal-${i}`)})}function oRt(e,t,n=[]){const r=e.length;if(t>=r||t<3)return e;const i=(l,u)=>{if(n.length===0){for(const h of Object.values(l))if(typeof h=="number")return h;return u}let c=0,d=0;for(const h of n){const m=l[h];typeof m=="number"&&(c+=m,d++)}return d>0?c/d:u},o=[e[0]],s=(r-2)/(t-2);let a=0;for(let l=0;l<t-2;l++){const u=Math.floor((l+1)*s)+1,c=Math.min(Math.floor((l+2)*s)+1,r-1),d=Math.floor((l+2)*s)+1,h=Math.min(Math.floor((l+3)*s)+1,r),m=Math.max(0,h-d);let g=r-1,b=i(e[r-1],r-1);if(m>0){g=0,b=0;for(let T=d;T<h;T++)g+=T,b+=i(e[T],T);g/=m,b/=m}const v=e[a],w=a,S=i(v,a);let C=-1,E=u;for(let T=u;T<c;T++){const O=Math.abs((w-g)*(i(e[T],T)-S)-(w-T)*(b-S))*.5;O>C&&(C=O,E=T)}o.push(e[E]),a=E}return o.push(e[r-1]),o}function sRt(e){return Math.max(64,Math.ceil(e*1.5))}function aRt(e,t,n){const r=t[0].getTime(),i=t[1].getTime(),o=Math.min(r,i),s=Math.max(r,i);return e.filter(a=>{const l=n(a).getTime();return l>=o&&l<=s})}const lRt="value",uRt=7;function cRt(e={}){const t=e.dataKey??lRt,n=e.pointCount??uRt,r=e.baseDate??new Date("2025-01-01");return Array.from({length:n},(i,o)=>{const s=new Date(r);return s.setDate(r.getDate()+o),{date:s,[t]:Math.round(110+Math.sin(o*1.15)*36+o*9)}})}function dRt(e,t){return e.map((n,r)=>({...n,[t]:Math.round(95+Math.sin(r*1.05)*28+r*7)}))}function fRt(e){let t=Number.POSITIVE_INFINITY,n=Number.NEGATIVE_INFINITY;for(const r of e)for(const i of r)i.value<t&&(t=i.value),i.value>n&&(n=i.value);return t===Number.POSITIVE_INFINITY?null:{minValue:t,maxValue:n}}function hRt(e){let t=Number.POSITIVE_INFINITY,n=Number.NEGATIVE_INFINITY;for(const r of e)for(const i of r){const o=i.date.getTime();o<t&&(t=o),o>n&&(n=o)}return t===Number.POSITIVE_INFINITY?null:{minTime:t,maxTime:n}}function pRt(e){const t=e.type;return typeof e.type=="function"&&(t.displayName||t.name)||""}function mRt(e){return pRt(e)==="ProjectionLine"}function gRt(e){return e!=null&&e.length?e.map(t=>({date:t.date instanceof Date?t.date:new Date(t.date),value:t.value})):[]}function yRt(e){const t=[],n=r=>{A.Children.forEach(r,i=>{if(!A.isValidElement(i))return;if(i.type===A.Fragment){n(i.props.children);return}if(mRt(i)){const s=i.props,a=gRt(s==null?void 0:s.data);a.length>=2&&t.push({yAxisId:ph(s==null?void 0:s.yAxisId),data:a});return}if(BX(i.type)){n(i.props.children);return}const o=i.props;o!=null&&o.children&&n(o.children)})};return n(e),t}function gde(e,t,n){const r=t.filter(c=>c.yAxisId===n).map(c=>c.data),i=fRt(r);if(!i)return e;const[o,s]=e,a=Math.min(o,i.minValue),l=Math.max(s,i.maxValue);if(a>=0&&o>=0)return[0,l<=0?100:l*1.1];const u=(l-a)*.05||1;return[a-u,l+u]}function bRt(e,t){const n=t.map(i=>i.data),r=hRt(n);return r?Math.max(e,r.maxTime):e}function vRt(e){const t=e.type;return typeof e.type=="function"&&(t.displayName||t.name)||""}function xRt(e){return vRt(e)==="ReferenceArea"}function NNe(e){const t=[],n=r=>{A.Children.forEach(r,i=>{if(!A.isValidElement(i))return;if(xRt(i)){const s=i.props;s&&t.push({yAxisId:ph(s.yAxisId),y1:s.y1,y2:s.y2,axisLabelColor:s.axisLabelColor});return}const o=i.props;o!=null&&o.children&&n(o.children)})};return n(e),t}const wRt=A.createContext(null);function SRt(e){const{innerWidth:t,dataLength:n,columnWidth:r,seriesCount:i,composedBarSize:o,composedMaxBarSize:s,composedBarGap:a=4,stacked:l=!1}=e,u=a,c=l?1:Math.max(1,i);let d=r;d<=0&&(d=n<2?t:t/(n-1));let h=o??Math.min(d*.88,s??Number.POSITIVE_INFINITY);if(s!=null&&(h=Math.min(h,s)),c>1){const m=d*.92;c*h+(c-1)*u>m&&m>0&&(h=Math.max(4,(m-(c-1)*u)/c))}return Math.max(2,h)}function kRt(e){const{barWidth:t,seriesCount:n,gap:r=4,stacked:i=!1}=e;if(i||n<=1)return Math.ceil(t/2);const o=n*t+(n-1)*r;return Math.ceil(o/2)}const CRt=A.createContext(!1);function ERt(){return A.useContext(CRt)}function yde(e){const n=Hh({domain:e,range:[0,1],nice:!0}).domain();return[n[0]??e[0],n[1]??e[1]]}function bde(e,t){const n=Math.max(Math.abs(t[1]-t[0]),Math.abs(e[1]-e[0]),1),r=Math.abs(t[0]-e[0])/n,i=Math.abs(t[1]-e[1])/n;return r>=mde||i>=mde}function TRt(e){return e==="loading"||e==="revealingLoading"}function ARt(e){return e==="loading"||e==="exiting"||e==="gridTweenLoading"}function ORt(e){return e==="gridTweenLoading"||e==="gridTweenReady"}function RRt(e,t,n){switch(e){case"loading":case"exiting":case"gridTweenLoading":return t;case"exitingReady":case"gridTweenReady":case"revealing":case"ready":return n;default:return n}}function vde({lines:e,resolveDomain:t}){const n=nD(e),r={};for(const[i,o]of n){const s=o.map(a=>a.dataKey);r[ph(i)]=yde(t(s))}return r.left||(r.left=yde([0,100])),r}function LNe(e,t){const n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(const i of n){const o=e[i],s=t[i];if(!(o&&s)||o[0]!==s[0]||o[1]!==s[1])return!1}return!0}function MRt(e,t,n){return[e[0]+(t[0]-e[0])*n,e[1]+(t[1]-e[1])*n]}function um(e,t,n){LNe(n.current,e)||(t(e),n.current=e)}function xde({destination:e,durationMs:t,enabled:n,reducedMotion:r,animatedRef:i,setAnimatedByAxis:o,onSettled:s}){if(LNe(i.current,e)){s==null||s();return}if(!n||r){um(e,o,i),s==null||s();return}const a=Object.keys(e),l=i.current;let u=!1;for(const h of a){const m=l[h]??e[h]??[0,100],g=e[h]??m;if(bde(m,g)){u=!0;break}}if(!u){um(e,o,i),s==null||s();return}const c={};for(const h of a)c[h]=l[h]??e[h]??[0,100];return mh(0,1,{duration:t/1e3,ease:[...tu],onUpdate:h=>{const m={};for(const g of a){const b=c[g]??e[g]??[0,100],v=e[g]??b;m[g]=bde(b,v)?MRt(b,v,h):v}i.current=m,o(m)},onComplete:()=>{um(e,o,i),s==null||s()}})}function _Rt({enabled:e,durationMs:t,chartPhase:n,skeletonByAxis:r,targetByAxis:i,onSettled:o,tweenOnTargetChange:s=!1}){const a=uc(),l=RRt(n,r,i),u=A.useRef(l);u.current=l;const c=A.useRef(r);c.current=r;const d=A.useRef(i);d.current=i;const[h,m]=A.useState(l),g=A.useRef(h),b=A.useRef(n),v=A.useRef(o);v.current=o,A.useEffect(()=>{g.current=h},[h]),A.useEffect(()=>{if(b.current===n)return;b.current=n;const C=()=>{var T;(T=v.current)==null||T.call(v)};if(n==="exiting"){um(c.current,m,g);return}if(n==="exitingReady"){um(d.current,m,g);return}if(n==="loading"){um(c.current,m,g);return}if(n==="revealing"||n==="ready"){um(d.current,m,g);return}if(!ORt(n))return;const E=xde({destination:u.current,durationMs:t,enabled:e,reducedMotion:a,animatedRef:g,setAnimatedByAxis:m,onSettled:C});return()=>E==null?void 0:E.stop()},[n,t,e,a]);const w=JSON.stringify(i),S=A.useRef(w);return A.useEffect(()=>{if(!(n==="ready"||n==="revealing")){S.current=w;return}if(S.current!==w){if(S.current=w,s&&n==="ready"){const E=xde({destination:d.current,durationMs:t,enabled:e,reducedMotion:a,animatedRef:g,setAnimatedByAxis:m,onSettled:()=>{var T;return(T=v.current)==null?void 0:T.call(v)}});return()=>E==null?void 0:E.stop()}um(d.current,m,g)}},[n,t,e,a,w,s]),h}class aw{constructor(t){ne(this,"x",0);ne(this,"y",0);let{x:n=0,y:r=0}=t;this.x=n,this.y=r}value(){return{x:this.x,y:this.y}}toArray(){return[this.x,this.y]}}function NRt(e){return!!e&&e instanceof Element}function LRt(e){return!!e&&(e instanceof SVGElement||"ownerSVGElement"in e)}function IRt(e){return!!e&&"createSVGPoint"in e}function PRt(e){return!!e&&"getScreenCTM"in e}function jRt(e){return!!e&&"changedTouches"in e}function DRt(e){return!!e&&"clientX"in e}function $Rt(e){return!!e&&(e instanceof Event||"nativeEvent"in e&&e.nativeEvent instanceof Event)}const g$={x:0,y:0};function zRt(e){if(!e)return{...g$};if(jRt(e))return e.changedTouches.length>0?{x:e.changedTouches[0].clientX,y:e.changedTouches[0].clientY}:{...g$};if(DRt(e))return{x:e.clientX,y:e.clientY};const t=e==null?void 0:e.target,n=t&&"getBoundingClientRect"in t?t.getBoundingClientRect():null;return n?{x:n.x+n.width/2,y:n.y+n.height/2}:{...g$}}function wde(e,t){if(!e||!t)return null;const n=zRt(t),r=LRt(e)?e.ownerSVGElement:e,i=PRt(r)?r.getScreenCTM():null;if(IRt(r)&&i){let s=r.createSVGPoint();return s.x=n.x,s.y=n.y,s=s.matrixTransform(i.inverse()),new aw({x:s.x,y:s.y})}const o=e.getBoundingClientRect();return new aw({x:n.x-o.left-e.clientLeft,y:n.y-o.top-e.clientTop})}function $V(e,t){if(NRt(e)&&t)return wde(e,t);if($Rt(e)){const n=e,r=n.target;if(r)return wde(r,n)}return null}function FRt(e){if(typeof e=="object"&&e!==null&&"index"in e&&typeof e.index=="number"){const{index:t,x:n}=e;return typeof n=="number"?`${t}:${Math.round(n)}`:String(t)}return JSON.stringify(e)}function INe(){const[e,t]=A.useState(null),n=A.useRef(null),r=A.useRef(null),i=A.useRef(null),o=A.useRef(null);A.useEffect(()=>()=>{i.current!==null&&cancelAnimationFrame(i.current)},[]);const s=A.useCallback((c,d)=>{d!==n.current&&(n.current=d,t(c))},[]),a=A.useCallback((c,d)=>{const h=d??FRt(c);r.current=c,o.current=h,h!==n.current&&i.current===null&&(i.current=requestAnimationFrame(()=>{i.current=null;const m=r.current,g=o.current;m&&g&&s(m,g)}))},[s]),l=A.useCallback(()=>{i.current!==null&&(cancelAnimationFrame(i.current),i.current=null),r.current=null,o.current=null,n.current=null,t(null)},[]),u=A.useCallback(()=>{n.current=null},[]);return{tooltipData:e,setTooltipData:t,scheduleTooltip:a,clearTooltip:l,resetTooltipDedupe:u}}function BRt({xScale:e,yScale:t,yScales:n,data:r,lines:i,margin:o,xAccessor:s,bisectDate:a,canInteract:l}){const[u,c]=A.useState(null),{tooltipData:d,setTooltipData:h,scheduleTooltip:m,clearTooltip:g,resetTooltipDedupe:b}=INe(),v=A.useRef(!1),w=A.useRef(0),S=A.useRef(null),C=A.useCallback(H=>{const U=e.invert(H),W=a(r,U,1),q=r[W-1],Y=r[W];if(!q)return null;let Q=q,G=W-1;if(Y){const K=s(q).getTime(),te=s(Y).getTime();U.getTime()-K>te-U.getTime()&&(Q=Y,G=W)}const le={};for(const K of i){const te=Q[K.dataKey];if(typeof te=="number"){const de=n[ph(K.yAxisId)]??t;le[K.dataKey]=de(te)??0}}return{point:Q,index:G,x:e(s(Q))??0,yPositions:le}},[e,t,n,r,i,s,a]),E=A.useCallback(H=>{const U=e.invert(H),W=a(r,U,1),q=r[W-1],Y=r[W];if(!q)return 0;if(Y){const Q=s(q).getTime(),G=s(Y).getTime();if(U.getTime()-Q>G-U.getTime())return W}return W-1},[e,r,s,a]),T=A.useCallback((H,U=0)=>{let W=null;if("touches"in H){const q=H.touches[U];if(!q)return null;const Y=H.currentTarget.ownerSVGElement;if(!Y)return null;W=$V(Y,q)}else W=$V(H);return W?W.x-o.left:null},[o.left]),O=A.useCallback(H=>{const U=T(H);if(U===null)return;if(v.current){const q=Math.min(w.current,U),Y=Math.max(w.current,U);c({startX:q,endX:Y,startIndex:E(q),endIndex:E(Y),active:!0});return}S.current=U;const W=C(U);W&&m(W)},[T,C,E,m]),M=A.useCallback(()=>{S.current=null,g(),v.current&&(v.current=!1),c(null)},[g]),N=A.useCallback(H=>{const U=T(H);U!==null&&(v.current=!0,w.current=U,g(),c(null))},[T,g]),I=A.useCallback(()=>{v.current&&(v.current=!1),c(null)},[]),D=A.useCallback(H=>{if(H.touches.length===1){H.preventDefault();const U=T(H,0);if(U===null)return;S.current=U;const W=C(U);W&&m(W)}else if(H.touches.length===2){H.preventDefault(),b(),g();const U=T(H,0),W=T(H,1);if(U===null||W===null)return;const q=Math.min(U,W),Y=Math.max(U,W);c({startX:q,endX:Y,startIndex:E(q),endIndex:E(Y),active:!0})}},[T,C,E,m,b,g]),P=A.useCallback(H=>{if(H.touches.length===1){H.preventDefault();const U=T(H,0);if(U===null)return;S.current=U;const W=C(U);W&&m(W)}else if(H.touches.length===2){H.preventDefault();const U=T(H,0),W=T(H,1);if(U===null||W===null)return;const q=Math.min(U,W),Y=Math.max(U,W);c({startX:q,endX:Y,startIndex:E(q),endIndex:E(Y),active:!0})}},[T,C,E,m]),F=A.useCallback(()=>{g(),c(null)},[g]),z=A.useCallback(()=>{c(null)},[]);return A.useEffect(()=>{if(!l||S.current===null)return;const H=C(S.current);if(H){m(H,`${H.index}:${Math.round(H.x)}`);return}g()},[l,g,C,m]),{tooltipData:d,setTooltipData:h,selection:u,clearSelection:z,interactionHandlers:l?{onMouseMove:O,onMouseLeave:M,onMouseDown:N,onMouseUp:I,onTouchStart:D,onTouchMove:P,onTouchEnd:F}:{},interactionStyle:{cursor:l?"crosshair":"default",touchAction:"none"}}}function HRt({chartStatus:e,targetData:t,skeletonData:n,animationDuration:r,yDomainTweenDuration:i,revealSignature:o="",skipEnterReveal:s=!1}){const[a,l]=A.useState(()=>hD(e)),[u,c]=A.useState(()=>e==="loading"?n:t),[d,h]=A.useState(0),[m,g]=A.useState(0),[b,v]=A.useState(()=>e==="ready"),w=A.useRef(e),S=A.useRef(a);S.current=a,A.useEffect(()=>{const O=w.current;if(O!==e){if(w.current=e,e==="ready"&&O==="loading"){v(!1),r<=0?i<=0?(c(t),l("revealing")):l("gridTweenReady"):l("exiting");return}e==="loading"&&O==="ready"&&(v(!1),r<=0?i<=0?(c(n),l("loading")):l("gridTweenLoading"):(g(M=>M+1),l("exitingReady")))}},[r,e,n,t,i]),A.useEffect(()=>{s||e==="ready"&&S.current==="ready"&&(l("revealing"),v(!1))},[r,e,o,s]),A.useEffect(()=>{switch(a){case"loading":e==="loading"&&c(n);break;case"exiting":c(n);break;case"exitingReady":case"gridTweenLoading":case"gridTweenReady":case"revealing":case"ready":c(t);break}},[a,e,n,t]);const C=A.useCallback(()=>{S.current==="exiting"&&l("gridTweenReady")},[]),E=A.useCallback(()=>{S.current==="exitingReady"&&l("gridTweenLoading")},[]),T=A.useCallback(()=>{if(S.current==="gridTweenLoading"){l("loading");return}S.current==="gridTweenReady"&&l("revealing")},[]);return A.useEffect(()=>{if(a!=="revealing")return;if(h(M=>M+1),r<=0){l("ready"),v(!0);return}const O=window.setTimeout(()=>{l("ready"),v(!0)},r);return()=>window.clearTimeout(O)},[r,a]),{chartPhase:a,plotData:u,revealEpoch:d,concealEpoch:m,isLoaded:b,notifyLoadingPulseComplete:C,notifyRevealConcealComplete:E,notifyYDomainTweenComplete:T}}function URt(e,t){let n=Number.POSITIVE_INFINITY,r=Number.NEGATIVE_INFINITY;for(const i of e)for(const o of t){const s=i[o];typeof s=="number"&&(s<n&&(n=s),s>r&&(r=s))}return n===Number.POSITIVE_INFINITY?{minValue:0,maxValue:100}:{minValue:n,maxValue:r}}function VRt(e,t,n){if(n!=null&&n>0)return[0,n*1.1];const{minValue:r,maxValue:i}=URt(e,t);if(r>=0)return[0,i<=0?100:i*1.1];const o=(i-r)*.05||1;return[r-o,i+o]}function WRt(e,t){return e.key!=null?e:A.cloneElement(e,{key:`chart-child-${t}`})}function PNe(e){const{width:t,height:n}=e;return t<10||n<10?null:y.jsx(qRt,{...e})}const qRt=A.memo(function({width:t,height:n,data:r,xDataKey:i,margin:o,animationDuration:s,animationEasing:a=bNe,enterTransition:l,revealSignature:u="",children:c,containerRef:d,lines:h,clipPathId:m,composedBarDataKeys:g,composedBarSize:b,composedMaxBarSize:v,composedBarGap:w,composedStacked:S,composedStackOffsets:C,composedStackGap:E,yScaleDomainMax:T,chartStatus:O=FX,loadingLabel:M,yDomainTween:N=!0,yDomainTweenDuration:I=kA,xDomain:D,xDomainSlotCount:P,tweenYDomainOnXDomainChange:F=!1,onPhaseChange:z}){const $=ERt(),B=t-o.left-o.right,H=n-o.top-o.bottom,U=A.useCallback((yt,pt)=>{const Fe=nD(h),ut=Fe.size===1&&Fe.has(Yu)&&T!=null?T:void 0;return VRt(yt,pt,ut)},[h,T]),W=A.useMemo(()=>{var pt;const yt=((pt=h[0])==null?void 0:pt.dataKey)??"value";return r.length===0?cRt({dataKey:yt}):dRt(r,yt)},[r,h]),{chartPhase:q,plotData:Y,revealEpoch:Q,concealEpoch:G,isLoaded:le,notifyLoadingPulseComplete:K,notifyRevealConcealComplete:te,notifyYDomainTweenComplete:de}=HRt({animationDuration:s,chartStatus:O,revealSignature:u,skeletonData:W,skipEnterReveal:$,targetData:r,yDomainTweenDuration:I});A.useEffect(()=>{z==null||z(q)},[q,z]);const ue=A.useCallback(yt=>{const pt=yt[i];return pt instanceof Date?pt:new Date(pt)},[i]),ae=A.useMemo(()=>Uj(yt=>ue(yt)).left,[ue]),ie=A.useMemo(()=>D?aRt(Y,D,ue):Y,[Y,D,ue]),he=A.useMemo(()=>yRt(c),[c]),fe=A.useMemo(()=>{const yt=D?D[0].getTime():nue(Y,Fe=>ue(Fe).getTime())[0]??0;let pt=D?D[1].getTime():nue(Y,Fe=>ue(Fe).getTime())[1]??yt;return D||(pt=bRt(pt,he)),eCt({range:[0,B],domain:[yt,pt]})},[B,Y,he,ue,D]),se=D?Y:ie,Se=A.useMemo(()=>{const yt=h.map(pt=>pt.dataKey);return oRt(se,sRt(B),yt)},[se,B,h]),pe=A.useMemo(()=>{const yt=D&&P!=null?P:ie.length;return yt<2?0:B/(yt-1)},[B,ie.length,D,P]),Ee=A.useMemo(()=>vde({lines:h,resolveDomain:yt=>U(W,yt)}),[h,U,W]),ke=A.useMemo(()=>{const yt=vde({lines:h,resolveDomain:Fe=>U(D?ie:r,Fe)});if(he.length===0)return yt;const pt={...yt};for(const Fe of Object.keys(yt))pt[Fe]=gde(yt[Fe]??[0,100],he,Fe);for(const Fe of he)pt[Fe.yAxisId]||(pt[Fe.yAxisId]=gde([0,100],he,Fe.yAxisId));return pt},[r,h,he,U,ie,D]),Be=_Rt({chartPhase:q,durationMs:I,enabled:N,onSettled:de,skeletonByAxis:Ee,targetByAxis:ke,tweenOnTargetChange:N||F&&D!=null}),Oe=A.useMemo(()=>nCt({domainsByAxis:Be,innerHeight:H,lines:h}),[Be,H,h]),Le=dMe(Oe,Hh({range:[H,0],domain:[0,100],nice:!0})),ge=A.useMemo(()=>ie.map(yt=>Ag.format(ue(yt))),[ie,ue]),$e=le&&XOt(q),{tooltipData:Ye,setTooltipData:tt,selection:Ae,clearSelection:_e,interactionHandlers:He,interactionStyle:Ue}=BRt({bisectDate:ae,canInteract:$e,data:ie,lines:h,margin:o,xAccessor:ue,xScale:fe,yScale:Le,yScales:Oe}),Ve=[],gt=[],rt=[],xt=[],$t=[];A.Children.forEach(c,(yt,pt)=>{if(!A.isValidElement(yt))return;const Fe=WRt(yt,pt),Qe=HX(Fe);_Ne(Qe)?Ve.push(Qe):MNe(Qe)?xt.push(Qe):TNe(Qe)?$t.push(Qe):ONe(Qe)?gt.push(Qe):ANe(Qe)?rt.push(Qe):xt.push(Qe)});const[zt,vn]=A.useState(()=>new Map),_n=A.useCallback((yt,pt)=>{vn(Fe=>{const Qe=Fe.get(yt);if(Qe&&Qe.yAxisId===pt.yAxisId&&Qe.y1===pt.y1&&Qe.y2===pt.y2&&Qe.axisLabelColor===pt.axisLabelColor)return Fe;const ut=new Map(Fe);return ut.set(yt,pt),ut})},[]),Vn=A.useCallback(yt=>{vn(pt=>{if(!pt.has(yt))return pt;const Fe=new Map(pt);return Fe.delete(yt),Fe})},[]),Ln=A.useMemo(()=>({registerReferenceArea:_n,unregisterReferenceArea:Vn}),[_n,Vn]),ln=A.useMemo(()=>{const yt=NNe(c),pt=[...zt.values()];return pt.length===0?yt:yt.length===0?pt:[...yt,...pt]},[c,zt]),mr=A.useMemo(()=>({data:ie,renderData:Se,xScale:fe,yScale:Le,yScales:Oe,width:t,height:n,innerWidth:B,innerHeight:H,margin:o,columnWidth:pe,tooltipData:Ye,setTooltipData:tt,containerRef:d,lines:h,referenceAreas:ln,chartPhase:q,chartStatus:O,loadingLabel:M,yDomainTweenDuration:I,yDomainSkeletonByAxis:Ee,yDomainTargetByAxis:ke,isLoaded:le,animationDuration:s,animationEasing:a,enterTransition:l,revealEpoch:Q,notifyLoadingPulseComplete:K,xAccessor:ue,dateLabels:ge,xDomain:D,xDomainSlotCount:P,selection:Ae,clearSelection:_e,composedBarDataKeys:g,composedBarSize:b,composedMaxBarSize:v,composedBarGap:w,composedStacked:S,composedStackOffsets:C,composedStackGap:E}),[ie,Se,fe,Le,Oe,t,n,B,H,o,pe,Ye,tt,d,h,ln,q,O,M,I,Ee,ke,le,s,a,l,Q,K,ue,ge,D,P,Ae,_e,g,b,v,w,S,C,E]),Yn=!$&&Se.length>1&&B>0&&s>0,Yt=q==="revealing",Ht=q==="exitingReady"&&s>0,on=l??{...oT,duration:s/1e3},Jt=A.useMemo(()=>{if(!(g!=null&&g.length))return 0;const yt=SRt({columnWidth:pe,composedBarGap:w,composedBarSize:b,composedMaxBarSize:v,dataLength:Y.length,innerWidth:B,seriesCount:g.length,stacked:S});return kRt({barWidth:yt,gap:w,seriesCount:g.length,stacked:S})},[pe,g,w,b,v,S,B,Y.length]);return y.jsx(wRt.Provider,{value:Ln,children:y.jsx(pMe,{value:mr,children:y.jsxs("svg",{"aria-hidden":"true",height:n,width:t,children:[y.jsxs("defs",{children:[Ve,Yn?y.jsx(iRt,{animating:Yt||Ht,clipPathId:m,enterTransition:on,height:H+20,mode:Ht?"conceal":"reveal",onComplete:Ht?te:void 0,padding:Jt,revealEpoch:Ht?G:Q,targetWidth:B}):null]}),y.jsx("rect",{fill:"transparent",height:n,width:t,x:0,y:0}),y.jsxs("g",{...He,style:Ue,transform:`translate(${o.left},${o.top})`,children:[y.jsx("rect",{fill:"transparent",height:H,width:B,x:0,y:0}),gt,rt,Yn?y.jsx("g",{clipPath:`url(#${m})`,children:xt}):xt,$t]})]})})})}),GRt={top:40,right:40,bottom:40,left:40};function KRt(e){const t=[];return A.Children.forEach(e,n=>{if(!A.isValidElement(n))return;const r=n.type,i=typeof n.type=="function"&&(r.displayName||r.name)||"",o=n.props,s=i==="PatternArea"||n.type===CNe;(i==="Area"||n.type===zX||o&&typeof o.dataKey=="string"&&o.dataKey.length>0&&!s)&&(o!=null&&o.dataKey)&&t.push({dataKey:o.dataKey,stroke:o.stroke||o.fill||"var(--chart-line-primary)",strokeWidth:o.strokeWidth||2,yAxisId:o.yAxisId})}),t}function YRt({width:e,height:t,data:n,xDataKey:r,margin:i,animationDuration:o,animationEasing:s,enterTransition:a,revealSignature:l,chartStatus:u,loadingLabel:c,yDomainTweenDuration:d,yDomainTween:h,xDomain:m,xDomainSlotCount:g,tweenYDomainOnXDomainChange:b,children:v,containerRef:w,onPhaseChange:S}){const C=A.useMemo(()=>KRt(v),[v]);return y.jsx(PNe,{animationDuration:o,animationEasing:s,chartStatus:u,clipPathId:"chart-area-grow-clip",containerRef:w,data:n,enterTransition:a,height:t,lines:C,loadingLabel:c,margin:i,onPhaseChange:S,revealSignature:l,tweenYDomainOnXDomainChange:b,width:e,xDataKey:r,xDomain:m,xDomainSlotCount:g,yDomainTween:h,yDomainTweenDuration:d,children:v})}function XRt({data:e,xDataKey:t="date",margin:n,animationDuration:r=1100,animationEasing:i,enterTransition:o,revealSignature:s,aspectRatio:a="2 / 1",className:l="",status:u=FX,loadingLabel:c,yDomainTweenDuration:d=kA,yDomainTween:h=!0,xDomain:m,xDomainSlotCount:g,tweenYDomainOnXDomainChange:b=!1,style:v,onPhaseChange:w,children:S}){const C=A.useRef(null),E={...GRt,...n},[T,O]=A.useState(()=>hD(u)),M=A.useCallback(I=>{O(I),w==null||w(I)},[w]),N=!!(c!=null&&c.trim()&&(T==="loading"||T==="exiting"||T==="gridTweenReady"||T==="revealingLoading"));return y.jsxs("div",{className:X("relative w-full",l),ref:C,style:{aspectRatio:a,touchAction:"none",...v},children:[y.jsx(RY,{debounceTime:10,children:({width:I,height:D})=>y.jsx(YRt,{animationDuration:r,animationEasing:i,chartStatus:u,containerRef:C,data:e,enterTransition:o,height:D,loadingLabel:c,margin:E,onPhaseChange:M,revealSignature:s,tweenYDomainOnXDomainChange:b,width:I,xDataKey:t,xDomain:m,xDomainSlotCount:g,yDomainTween:h,yDomainTweenDuration:d,children:S})}),N?y.jsx(kNe,{exiting:T!=="loading",text:c}):null]})}function QRt({barLengthPx:e,squareSize:t,gap:n,fit:r=!1}){if(e<=0||t<=0)return{count:0,positions:[],columnHeight:0,squareSize:t,gap:n};if(r){const l=Math.max(1,Math.floor((e+n)/(t+n))),u=l>1?Math.max(0,(e-l*t)/(l-1)):0,c=t+u,d=e,h=[];for(let m=0;m<l;m++)h.push(d-t-m*c);return{count:l,positions:h,columnHeight:d,squareSize:t,gap:u}}const i=t+n,o=Math.max(1,Math.round(e/i)),s=o*t+Math.max(0,o-1)*n,a=[];for(let l=0;l<o;l++){const u=l*i;a.push(s-t-u)}return{count:o,positions:a,columnHeight:s,squareSize:t,gap:n}}function ZRt({baselineY:e,barLengthPx:t,squareSize:n,gap:r,fit:i=!1}){const{count:o,squareSize:s,columnHeight:a}=QRt({barLengthPx:t,squareSize:n,gap:r,fit:i});return o===0?e:e-a+s/2}const JRt=12,eMt={top:40,right:40,bottom:40,left:40};function tMt(e){const t=[];return ENe(e,n=>{const r=n.type;if(r.__isBarDepthLayer)return;const i=typeof n.type=="function"&&(r.displayName||r.name)||"",o=n.props;if((i==="Bar"||i==="BarSquares"||o&&typeof o.dataKey=="string"&&o.dataKey.length>0)&&(o!=null&&o.dataKey)){const a=o.stroke||o.fill||"var(--chart-line-primary)";t.push({dataKey:o.dataKey,stroke:a,strokeWidth:0,yAxisId:o.yAxisId})}}),t}function nMt(e){const{width:t,height:n}=e;return t<10||n<10?null:y.jsx(rMt,{...e})}const rMt=A.memo(function({width:t,height:n,data:r,xDataKey:i,margin:o,animationDuration:s,animationEasing:a,enterTransition:l,revealSignature:u="",barGap:c,barWidthProp:d,orientation:h,stacked:m,stackGap:g,squareSnap:b,children:v,containerRef:w,onPhaseChange:S,status:C}){const{tooltipData:E,setTooltipData:T,scheduleTooltip:O,clearTooltip:M}=INe(),[N,I]=A.useState(!1),[D,P]=A.useState(0),F=(E==null?void 0:E.index)??null,z=h==="horizontal",$=A.useMemo(()=>tMt(v),[v]),B=t-o.left-o.right,H=n-o.top-o.bottom,U=A.useCallback(Oe=>{const Le=Oe[i];return Le instanceof Date?Ag.format(Le):String(Le??"")},[i]),W=A.useCallback(Oe=>{const Le=Oe[i];return Le instanceof Date?Le:new Date},[i]),q=A.useMemo(()=>{const Oe=r.map(ge=>U(ge));return Qkt({range:z?[0,H]:[0,B],domain:Oe,padding:c})},[B,H,r,U,c,z]),Y=d??q.bandwidth(),Q=A.useMemo(()=>{if(m){let Le=0;for(const ge of r){let $e=0;for(const Ye of $){const tt=ge[Ye.dataKey];typeof tt=="number"&&($e+=tt)}$e>Le&&(Le=$e)}return Le||100}let Oe=0;for(const Le of $)for(const ge of r){const $e=ge[Le.dataKey];typeof $e=="number"&&$e>Oe&&(Oe=$e)}return Oe||100},[r,$,m]),G=A.useMemo(()=>Hh({range:z?[0,B]:[H,0],domain:[0,Q*1.1],nice:!0}),[B,H,Q,z]),le=A.useMemo(()=>z?rCt(G):tCt({lines:$,innerHeight:H,resolveDomain:Oe=>{let Le=0;for(const ge of r)for(const $e of Oe){const Ye=ge[$e];typeof Ye=="number"&&Ye>Le&&(Le=Ye)}return[0,(Le||100)*1.1]}}),[r,H,z,$,G]),K=dMe(le,G),te=A.useMemo(()=>{if(!m)return;const Oe=new Map;for(let Le=0;Le<r.length;Le++){const ge=r[Le];if(!ge)continue;const $e=new Map;let Ye=0;for(const tt of $){$e.set(tt.dataKey,Ye);const Ae=ge[tt.dataKey];typeof Ae=="number"&&(Ye+=Ae)}Oe.set(Le,$e)}return Oe},[r,$,m]),de=A.useMemo(()=>r.length<1?0:z?H/r.length:B/r.length,[B,H,r.length,z]),ue=A.useMemo(()=>r.map(Oe=>U(Oe)),[r,U]),ae=A.useMemo(()=>{const Oe=Date.now(),Le=Oe-r.length*24*60*60*1e3,ge={...q,domain:()=>[new Date(Le),new Date(Oe)],range:()=>[0,B],invert:$e=>new Date(Le+$e/B*(Oe-Le)),copy:()=>ge};return ge},[q,B,r.length]);A.useEffect(()=>{if(P(ge=>ge+1),I(!1),C==="loading")return;const Oe=r.length>1?s*.4:0,Le=setTimeout(()=>{I(!0)},s+Oe);return()=>clearTimeout(Le)},[s,u,C]),A.useEffect(()=>{S==null||S(N?"ready":"revealing")},[N,S]);const ie=A.useCallback(Oe=>{const Le=$V(Oe);if(!Le)return;const ge=z?Le.y-o.top:Le.x-o.left,$e=Math.floor(ge/de),Ye=Math.max(0,Math.min(r.length-1,$e)),tt=r[Ye];if(!tt)return;const Ae={},_e={},He=q(U(tt))??0;if(z){const Ve=$.length,gt=Ve>1?4:0,rt=Ve>0?(Y-gt*(Ve-1))/Ve:Y;if(m){let xt=0;for(const $t of $){const zt=tt[$t.dataKey];if(typeof zt=="number"){xt+=zt;const vn=le[ph($t.yAxisId)]??G;_e[$t.dataKey]=vn(xt)??0,Ae[$t.dataKey]=He+Y/2}}}else $.forEach((xt,$t)=>{const zt=tt[xt.dataKey];if(typeof zt=="number"){const vn=le[ph(xt.yAxisId)]??G;_e[xt.dataKey]=vn(zt)??0,Ae[xt.dataKey]=He+$t*(rt+gt)+rt/2}})}else if(m){let Ve=0,gt=0;for(const rt of $){const xt=tt[rt.dataKey];if(typeof xt=="number"){Ve+=xt;const $t=le[ph(rt.yAxisId)]??K,zt=gt*g;Ae[rt.dataKey]=($t(Ve)??0)-zt,gt++}}}else{const Ve=$.length,gt=Ve>1?4:0,rt=Ve>0?(Y-gt*(Ve-1))/Ve:Y;$.forEach((xt,$t)=>{const zt=tt[xt.dataKey];if(typeof zt=="number"){const vn=le[ph(xt.yAxisId)]??K,_n=vn(0)??H,Vn=vn(zt)??0,Ln=_n-Vn;b&&!z&&zt>0?Ae[xt.dataKey]=ZRt({baselineY:_n,barLengthPx:Ln,squareSize:rt,gap:b.squareGap,fit:b.fit}):Ae[xt.dataKey]=Vn,_e[xt.dataKey]=He+$t*(rt+gt)+rt/2}})}let Ue;z?Ue=Math.max(...Object.values(_e),0):Ue=He+Y/2,O({point:tt,index:Ye,x:Ue,yPositions:Ae,xPositions:Object.keys(_e).length>0?_e:void 0})},[q,G,r,$,o.left,o.top,U,de,Y,z,m,g,O,le,K,b,H]),he=A.useCallback(()=>{M()},[M]),fe=N,se=[],Se=[],pe=[],Ee=[],ke=[];ENe(v,Oe=>{const Le=HX(Oe);_Ne(Oe)?se.push(Oe):MNe(Oe)?Ee.push(Oe):TNe(Le)?ke.push(Le):ONe(Le)?Se.push(BX(Oe.type)?Le:Oe):ANe(Le)?pe.push(Le):Ee.push(Oe)});const Ie=A.useMemo(()=>NNe(v),[v]),Be={...QOt,chartPhase:hD(C),chartStatus:C,data:r,renderData:r,xScale:ae,yScale:z?G:K,yScales:le,width:t,height:n,innerWidth:B,innerHeight:H,margin:o,columnWidth:de,tooltipData:E,setTooltipData:T,containerRef:w,lines:$,referenceAreas:Ie,isLoaded:N,animationDuration:s,animationEasing:a,enterTransition:l,revealEpoch:D,xAccessor:W,dateLabels:ue,barScale:q,bandWidth:Y,hoveredBarIndex:F,barXAccessor:U,orientation:h,stacked:m,stackOffsets:te,squareSnap:b};return y.jsx(pMe,{value:Be,children:y.jsxs("svg",{"aria-hidden":"true",className:"overflow-visible",height:n,width:t,children:[se.length>0&&y.jsx("defs",{children:se}),y.jsx("rect",{fill:"transparent",height:n,width:t,x:0,y:0}),y.jsxs("g",{onMouseLeave:fe?he:void 0,onMouseMove:fe?ie:void 0,style:{cursor:fe?"crosshair":"default"},transform:`translate(${o.left},${o.top})`,children:[y.jsx("rect",{fill:"transparent",height:H,width:B,x:0,y:0}),dM(Se),dM(pe),C==="loading"?y.jsx(pNe,{barCount:r.length||JRt,innerHeight:H,innerWidth:B}):dM(Ee),dM(ke)]})]})})});function jNe({data:e,xDataKey:t="name",margin:n,animationDuration:r=1100,animationEasing:i=bNe,enterTransition:o,revealSignature:s,aspectRatio:a="2 / 1",className:l="",barGap:u=.2,barWidth:c,orientation:d="vertical",stacked:h=!1,stackGap:m=0,squareSnap:g,children:b,onPhaseChange:v,status:w="ready"}){const S=A.useRef(null),C={...eMt,...n};return y.jsx("div",{className:X("relative w-full overflow-visible",l),ref:S,style:{aspectRatio:a},children:y.jsx(RY,{debounceTime:10,children:({width:E,height:T})=>y.jsx(nMt,{animationDuration:r,animationEasing:i,barGap:u,barWidthProp:c,containerRef:S,data:e,enterTransition:o,height:T,margin:C,onPhaseChange:v,orientation:d,revealSignature:s,squareSnap:g,stacked:h,stackGap:m,status:w,width:E,xDataKey:t,children:b})})})}jNe.displayName="BarChart";const iMt=7,oMt=.45;function sMt(e,t){const n=Math.max(0,e-t);return Math.min(t*.22,Math.max(0,n-1),iMt)}function aMt(e,t,n){const r=Math.min(1,Math.max(0,e)),i=Math.min(n,Math.max(0,t)),o=r*i;return{depth:o,perspectiveRise:o*oMt}}function lMt(e,t,n=oT){return{...e??n,delay:t}}function uMt(e,t,n,r,i,o,s){var g;const a=r/2;if(a<=0)return 0;const l=((g=e.step)==null?void 0:g.call(e))??t,u=sMt(l,t),d=(e(n(i))??0)+t/2,h=Math.min(1,Math.abs((d-a)/a)),m=Math.abs(s-o);return aMt(h,m,u).perspectiveRise}function cMt({x:e,y:t,width:n,height:r,fill:i,rx:o,ry:s,index:a,isFaded:l,animationType:u,innerHeight:c,fadedOpacity:d,staggerDelay:h,enterTransition:m,revealEpoch:g,isHorizontal:b}){const v=lMt(m,a*h);if(u==="fade")return y.jsx(or.rect,{animate:{opacity:l?d:1,filter:"blur(0px)"},fill:i,height:r,initial:{opacity:0,filter:"blur(2px)"},rx:o,ry:s,transition:v,width:n,x:e,y:t},`fade-${a}-${g}`);const w=b?{width:0,height:r,x:0,y:t}:{width:n,height:0,x:e,y:c},S=b?{width:n,height:r,x:0,y:t}:{width:n,height:r,x:e,y:t};return y.jsx("g",{opacity:l?d:1,style:{transition:"opacity 0.15s ease-in-out"},children:y.jsx(or.rect,{animate:S,fill:i,initial:w,rx:o,ry:s,transition:v},`grow-${a}-${g}`)})}const dMt=A.memo(function({dataKey:t,yAxisId:n,fill:r=Bo.linePrimary,lineCap:i="round",animate:o=!0,animationType:s="grow",fadedOpacity:a=.3,staggerDelay:l,stackGap:u=0,groupGap:c=4,perspective:d=!1,minBarHeight:h=0,barScale:m,bandWidth:g,barXAccessor:b}){const{data:v,yScale:w,innerHeight:S,innerWidth:C,isLoaded:E,hoveredBarIndex:T,lines:O,orientation:M,stacked:N,stackOffsets:I,animationDuration:D,enterTransition:P,revealEpoch:F=0}=JY(),$=(D||1100)*.4,B=l??(v.length>1?$/1e3/v.length:0),H=A.useId(),U=M==="horizontal",{hoveredIndex:W}=jX(),q=A.useMemo(()=>{const ue=O.findIndex(ae=>ae.dataKey===t);return ue>=0?ue:0},[O,t]),Y=O[q],Q=mA(n??(Y==null?void 0:Y.yAxisId)),G=W!==null&&W!==q,le=O.length,K=q===le-1,te=A.useMemo(()=>{if(!g||le===0)return 0;if(N)return g;const ue=le>1?c:0;return(g-ue*(le-1))/le},[g,le,N,c]),de=A.useMemo(()=>d?0:typeof i=="number"?i:i==="round"&&te?Math.min(te/2,8):0,[i,te,d]);return y.jsx("g",{className:`bar-series-${H}`,children:v.map((ue,ae)=>{var $e,Ye;const ie=ue[t];if(typeof ie!="number")return null;const he=b(ue),fe=m(he)??0;let se,Se,pe,Ee;const ke=U?w:Q;if(U){const tt=ke(ie)??0;if(Ee=tt,pe=te,N&&I){const Ae=(($e=I.get(ae))==null?void 0:$e.get(t))??0;se=ke(Ae)??0,Ee=tt-se;const _e=q*u;se+=_e,!K&&u>0&&(Ee=Math.max(0,Ee-u))}else{se=0;const Ae=le>1?c:0;Se=fe+q*(te+Ae)}Se=N?fe:fe+q*(te+(le>1?c:0))}else{const tt=ke(ie)??0;if(pe=S-tt,Ee=te,N&&I){const _e=((Ye=I.get(ae))==null?void 0:Ye.get(t))??0,He=ke(_e)??S,Ue=q*u;Se=He-pe-Ue,!K&&u>0&&(pe=Math.max(0,pe-u))}else{Se=tt;const _e=le>1?c:0;se=fe+q*(te+_e)}se=N?fe:fe+q*(te+(le>1?c:0));let Ae=!1;if(!N&&h>0&&ie>=0&&pe<h){const _e=ke(0)??S;pe=h,Se=_e-h,Ae=!0}if(d&&ie>0&&!Ae&&(!N||K)){const _e=ke(0)??S,He=uMt(m,g,b,C,ue,Se,_e),Ue=Math.min(He,Math.max(0,pe-1));Se+=Ue,pe-=Ue}}const Ie=T!==null&&T!==ae||G,Be=`bar-${t}-${he}`,Oe=!N||u>0||K,Le=Oe?de:0,ge=Oe?de:0;return o&&!E?y.jsx(cMt,{animationType:s,enterTransition:P,fadedOpacity:a,fill:r,height:pe,index:ae,innerHeight:S,isFaded:Ie,isHorizontal:U,revealEpoch:F,rx:Le,ry:ge,staggerDelay:B,width:Ee,x:se,y:Se},Be):y.jsx("rect",{fill:r,height:pe,opacity:Ie?a:1,rx:Le,ry:ge,style:{cursor:"default",transition:"opacity 0.15s ease-in-out"},width:Ee,x:se,y:Se},Be)})})});function DNe(e){const{barScale:t,bandWidth:n,barXAccessor:r}=_a();return t&&n&&r?y.jsx(dMt,{...e,bandWidth:n,barScale:t,barXAccessor:r}):(console.warn("Bar component must be used within a BarChart"),null)}DNe.displayName="Bar";function $Ne(e){return"bandwidth"in e?e.bandwidth():0}function Sde(e){let{top:t=0,left:n=0,scale:r,width:i,stroke:o="#eaf0f6",strokeWidth:s=1,strokeDasharray:a,className:l,children:u,numTicks:c=10,lineStyle:d,offset:h,tickValues:m,...g}=e;const b=m??cMe(r,c),v=(h??0)+$Ne(r)/2,w=b.map((S,C)=>{const E=(uMe(r(S))??0)+v;return{index:C,from:new aw({x:0,y:E}),to:new aw({x:i,y:E})}});return y.jsx(fRe,{className:iS("visx-rows",l),top:t,left:n,children:u?u({lines:w}):w.map(S=>{let{from:C,to:E,index:T}=S;return y.jsx(hRe,{from:C,to:E,stroke:o,strokeWidth:s,strokeDasharray:a,style:d,...g},`row-line-${T}`)})})}function fMt(e){let{top:t=0,left:n=0,scale:r,height:i,stroke:o="#eaf0f6",strokeWidth:s=1,strokeDasharray:a,className:l,numTicks:u=10,lineStyle:c,offset:d,tickValues:h,children:m,...g}=e;const b=h??cMe(r,u),v=(d??0)+$Ne(r)/2,w=b.map((S,C)=>{const E=(uMe(r(S))??0)+v;return{index:C,from:new aw({x:E,y:0}),to:new aw({x:E,y:i})}});return y.jsx(fRe,{className:iS("visx-columns",l),top:t,left:n,children:m?m({lines:w}):w.map(S=>{let{from:C,to:E,index:T}=S;return y.jsx(hRe,{from:C,to:E,stroke:o,strokeWidth:s,strokeDasharray:a,style:c,...g},`column-line-${T}`)})})}function hMt({innerWidth:e,shimmer:t,shimmerLength:n,shimmerSpeed:r,shimmerSync:i,active:o,oneShot:s=!1}){const a=fD(0),l=uc(),u=DV/Math.max(r,.1),c=o&&t&&l!==!0&&e>0;A.useEffect(()=>{if(!c)return;let m=!1,g,b;const v=()=>{m||(a.set(0),b=mh(a,1,{duration:u,ease:[...tu],onComplete:()=>{m||(g=window.setTimeout(v,_X))}}))};return i&&s?(a.set(0),b=mh(a,1,{duration:u/2,ease:[...tu]}),()=>b==null?void 0:b.stop()):i?(v(),()=>{m=!0,b==null||b.stop(),g!==void 0&&window.clearTimeout(g)}):(a.set(0),b=mh(a,1,{duration:u,repeat:Number.POSITIVE_INFINITY,ease:[...tu]}),()=>b==null?void 0:b.stop())},[s,a,u,c,i]);const d=bb(a,m=>-n+m*(e+n*2)),h=bb(d,m=>`translate(${m}, 0)`);return{shimmerEnabled:c,shimmerTransform:h}}const pMt=140,mMt=1,gMt="color-mix(in oklch, var(--foreground) 68%, transparent)";function zNe(e,t){return!t||e.length<=2?e:e.slice(1,-1)}function yMt(e){const{hideHorizontalEdgeLines:t,numTicksRows:n,rowTickValues:r,yScale:i}=e,o=r??(i.ticks?i.ticks(n):[]),s=zNe(o,t);if(!(s===o&&!r&&!t))return s.length>0?s:void 0}function L_({horizontal:e=!0,vertical:t=!1,numTicksRows:n=5,numTicksColumns:r=10,rowTickValues:i,stroke:o=Bo.grid,loadingStroke:s,strokeOpacity:a=1,strokeWidth:l=1,strokeDasharray:u="4,4",highlightRowValues:c,highlightRowStroke:d=Bo.foregroundMuted,highlightRowStrokeOpacity:h=1,highlightRowStrokeWidth:m=1,highlightRowStrokeDasharray:g="0",fadeHorizontal:b=!0,fadeVertical:v=!1,hideHorizontalEdgeLines:w=!1,hideVerticalEdgeLines:S=!1,yAxisId:C,shimmer:E=!1,shimmerStroke:T=gMt,shimmerLength:O=pMt,shimmerSpeed:M=mMt,shimmerSync:N=!1}){const{xScale:I,innerWidth:D,innerHeight:P,orientation:F,barScale:z,chartPhase:$}=_a(),B=mA(C),H=E&&TRt($),U=ARt($)&&s!=null?s:o,{shimmerEnabled:W,shimmerTransform:q}=hMt({innerWidth:D,shimmer:E,shimmerLength:O,shimmerSpeed:M,shimmerSync:N,active:H}),Q=F==="horizontal"&&z?B:I,G=yMt({hideHorizontalEdgeLines:w,numTicksRows:n,rowTickValues:i,yScale:B}),le=t&&Q&&typeof Q=="function"&&S?(()=>{var Se;const fe=((Se=Q.ticks)==null?void 0:Se.call(Q,r))??[],se=zNe(fe,!0);return se.length>0?se:void 0})():void 0,K=A.useId(),te=`grid-rows-fade-${K}`,de=`${te}-gradient`,ue=`grid-shimmer-${K}`,ae=`grid-cols-fade-${K}`,ie=`${ae}-gradient`,he=b?`url(#${te})`:void 0;return y.jsxs("g",{className:"chart-grid",children:[e&&b&&y.jsxs("defs",{children:[y.jsxs("linearGradient",{id:de,x1:"0%",x2:"100%",y1:"0%",y2:"0%",children:[y.jsx("stop",{offset:"0%",style:{stopColor:"white",stopOpacity:0}}),y.jsx("stop",{offset:"10%",style:{stopColor:"white",stopOpacity:1}}),y.jsx("stop",{offset:"90%",style:{stopColor:"white",stopOpacity:1}}),y.jsx("stop",{offset:"100%",style:{stopColor:"white",stopOpacity:0}})]}),y.jsx("mask",{id:te,children:y.jsx("rect",{fill:`url(#${de})`,height:P,width:D,x:"0",y:"0"})})]}),e&&W?y.jsx("defs",{children:y.jsxs(or.linearGradient,{gradientTransform:q,gradientUnits:"userSpaceOnUse",id:ue,x1:0,x2:O,y1:0,y2:0,children:[y.jsx("stop",{offset:"0%",stopColor:T,stopOpacity:0}),y.jsx("stop",{offset:"35%",stopColor:T,stopOpacity:.45}),y.jsx("stop",{offset:"50%",stopColor:T,stopOpacity:1}),y.jsx("stop",{offset:"65%",stopColor:T,stopOpacity:.45}),y.jsx("stop",{offset:"100%",stopColor:T,stopOpacity:0})]})}):null,t&&v&&y.jsxs("defs",{children:[y.jsxs("linearGradient",{id:ie,x1:"0%",x2:"0%",y1:"0%",y2:"100%",children:[y.jsx("stop",{offset:"0%",style:{stopColor:"white",stopOpacity:0}}),y.jsx("stop",{offset:"10%",style:{stopColor:"white",stopOpacity:1}}),y.jsx("stop",{offset:"90%",style:{stopColor:"white",stopOpacity:1}}),y.jsx("stop",{offset:"100%",style:{stopColor:"white",stopOpacity:0}})]}),y.jsx("mask",{id:ae,children:y.jsx("rect",{fill:`url(#${ie})`,height:P,width:D,x:"0",y:"0"})})]}),e&&y.jsxs("g",{mask:he,children:[y.jsx(Sde,{numTicks:G?void 0:n,scale:B,stroke:U,strokeDasharray:u,strokeOpacity:a,strokeWidth:l,tickValues:G,width:D}),W?y.jsx(Sde,{numTicks:G?void 0:n,scale:B,stroke:`url(#${ue})`,strokeDasharray:u,strokeOpacity:1,strokeWidth:l,tickValues:G,width:D}):null]}),e&&c&&c.length>0?y.jsx("g",{className:"chart-grid-highlight-rows",children:c.map(fe=>{const se=B(fe);return se==null||!Number.isFinite(se)?null:y.jsx("line",{stroke:d,strokeDasharray:g,strokeOpacity:h,strokeWidth:m,x1:0,x2:D,y1:se,y2:se},fe)})}):null,t&&Q&&typeof Q=="function"&&y.jsx("g",{mask:v?`url(#${ae})`:void 0,children:y.jsx(fMt,{height:P,numTicks:le?void 0:r,scale:Q,stroke:o,strokeDasharray:u,strokeOpacity:a,strokeWidth:l,tickValues:le})})]})}L_.displayName="Grid";function kde(e,t,n,r,i){return e.map((o,s)=>{var u;const a=t(o),l=o[i];return{x:n(a)??0,y:typeof l=="number"?r(l)??0:0,key:String(((u=a.getTime)==null?void 0:u.call(a))??s)}})}function bMt(e,t,n){if(n>=1)return t;if(n<=0)return e.length>0?e:t;const r=new Map(e.map(i=>[i.key,i]));return t.map((i,o)=>{const s=r.get(i.key);if(s)return{key:i.key,x:s.x+(i.x-s.x)*n,y:s.y+(i.y-s.y)*n};const a=o>0?t[o-1]:void 0,l=a?r.get(a.key):void 0,u=o<t.length-1?t[o+1]:void 0,c=u?r.get(u.key):void 0,d=l??c??e[0]??i;return{key:i.key,x:d.x+(i.x-d.x)*n,y:d.y+(i.y-d.y)*n}})}function vMt(e,t){return e.length===0?"":Fj().x(r=>r.x).y(r=>r.y).curve(t)(e)??""}function xMt({renderData:e,xAccessor:t,dataKey:n,innerWidth:r,xDomainMin:i,xDomainMax:o}){const s=e.map(a=>{const l=t(a),u=a[n];return`${l.getTime()}:${typeof u=="number"?u:""}`});return`${r}|${i}|${o}|${s.join(",")}`}function wMt({renderData:e,xAccessor:t,xScale:n,yScale:r,dataKey:i,curve:o,chartPhase:s,durationMs:a,innerWidth:l,enabled:u}){const c=uc(),[d,h]=A.useState(null),m=A.useRef(null),g=A.useRef(!1),b=A.useMemo(()=>{var O;const T=n;return((O=T.domain)==null?void 0:O.call(T))??[new Date(0),new Date(0)]},[n]),v=A.useMemo(()=>{var T,O,M,N;return xMt({renderData:e,xAccessor:t,dataKey:i,innerWidth:l,xDomainMin:((O=(T=b[0])==null?void 0:T.getTime)==null?void 0:O.call(T))??0,xDomainMax:((N=(M=b[1])==null?void 0:M.getTime)==null?void 0:N.call(M))??0})},[e,t,i,l,b]),w=A.useMemo(()=>kde(e,t,n,r,i),[e,t,n,r,i]),S=A.useRef(v);A.useEffect(()=>{g.current||(m.current=w)},[w]),A.useEffect(()=>{if(!(u&&!c&&s==="ready"&&a>0&&e.length>0)){g.current=!1,h(null),m.current=w,S.current=v;return}if(S.current===v)return;S.current=v;const O=m.current??w;if(O.length===0){m.current=w;return}g.current=!0;const M=O,N=mh(0,1,{duration:a/1e3,ease:[...tu],onUpdate:I=>{const D=kde(e,t,n,r,i),P=bMt(M,D,I);m.current=P,h(P)},onComplete:()=>{g.current=!1,m.current=w,h(null)}});return()=>{N.stop(),g.current=!1}},[v,s,a,u,c,e,t,n,r,i,w]);const C=d??w;return{pathD:A.useMemo(()=>vMt(C,o),[C,o]),isPathAnimating:d!=null}}function SMt({animatedPathD:e,curve:t,getY:n,pathRef:r,renderData:i,strokeWidth:o,useDataTransitionPath:s,visibleStroke:a,xAccessor:l,xScale:u}){return s&&e?y.jsx("path",{d:e,fill:"none",ref:r,stroke:a,strokeLinecap:"round",strokeWidth:o}):y.jsx(IY,{curve:t,data:i,innerRef:r,stroke:a,strokeLinecap:"round",strokeWidth:o,x:c=>u(l(c))??0,y:n})}function kMt({curve:e,handleLoadingPulseComplete:t,innerWidth:n,loadingStroke:r,loadingStrokeOpacity:i,loadingStyle:o,pathD:s,pulseEpoch:a,pulseMode:l,showLoadingPulse:u,strokeWidth:c}){const d=u&&n>0&&o==="sweep",h=u&&n>0&&!d;return y.jsxs(y.Fragment,{children:[d?y.jsx(LX,{curve:e,mode:l??"loop",onTransitionComplete:t,stroke:r,strokeOpacity:i,strokeWidth:c},"loading-sweep"):null,h&&s?y.jsx(NX,{loopEpoch:a,mode:l??void 0,onCycleComplete:t,pathD:s,stroke:r,strokeOpacity:i,strokeWidth:c},"loading-pulse"):null]})}function UX({dataKey:e,yAxisId:t,stroke:n=Bo.linePrimary,strokeWidth:r=2.5,curve:i=dRe,animate:o=!0,fadeEdges:s=!0,showHighlight:a=!0,showMarkers:l=!1,markers:u,dashFromIndex:c,dashArray:d="6,4",loading:h,loadingStroke:m=Bo.foreground,loadingStrokeOpacity:g=.5,loadingPulseMode:b,onLoadingPulseCycleComplete:v,loadingStyle:w="pulse"}){const{data:S,renderData:C,xScale:E,innerHeight:T,innerWidth:O,xAccessor:M,lines:N,chartPhase:I,notifyLoadingPulseComplete:D,yDomainTweenDuration:P}=_a(),F=mA(t),z=o&&I==="ready",{pathD:$}=wMt({chartPhase:I,curve:i,dataKey:e,durationMs:P,enabled:z,innerWidth:O,renderData:C,xAccessor:M,xScale:E,yScale:F}),B=uNe(I),H=h===!1?null:b??(h===!0?"loop":B),U=H!=null,[W,q]=A.useState(0),Y=a&&!U,Q=A.useCallback(()=>{if(v==null||v(),H==="loop"){window.setTimeout(()=>{q(Ee=>Ee+1)},_X);return}D==null||D()},[D,v,H]),G=A.useMemo(()=>{const Ee=N.findIndex(ke=>ke.dataKey===e);return Ee>=0?Ee:0},[N,e]),le=A.useRef(null),{pathLength:K,pathD:te}=mNe(le,[C,O,c,o,z?$:null]),de=A.useId(),ue=`line-gradient-${e}-${de}`,ae=A.useCallback(Ee=>{const ke=Ee[e];return typeof ke=="number"?F(ke)??0:0},[e,F]),ie=IX(c,S.length),he=Hj(s),fe=he.any?`url(#${ue})`:n,se=he.any?qL(he):null,Se=I==="revealing"||I==="ready"||I==="exitingReady";let pe="transparent";return Se&&!ie&&(pe=fe),y.jsxs(y.Fragment,{children:[se?y.jsx("defs",{children:y.jsx("linearGradient",{id:ue,...GL(O),children:se.map(Ee=>y.jsx("stop",{offset:Ee.offset,style:{stopColor:n,stopOpacity:Ee.opacity}},Ee.offset))})}):null,y.jsxs(DX,{dimOpacity:.3,enabled:Y,seriesIndex:G,children:[y.jsx(SMt,{animatedPathD:$,curve:i,getY:ae,pathRef:le,renderData:C,strokeWidth:r,useDataTransitionPath:z,visibleStroke:pe,xAccessor:M,xScale:E}),y.jsx(gNe,{dashArray:d,dashFromIndex:c,data:S,innerHeight:T,innerWidth:O,pathD:te,pathLength:K,stroke:fe,strokeWidth:r,xAccessor:M,xScale:E})]}),l?y.jsx($X,{animate:o,dataKey:e,...u,fill:(u==null?void 0:u.fill)??n,stroke:(u==null?void 0:u.stroke)??(u==null?void 0:u.fill)??n}):null,y.jsx(PX,{enabled:Y,height:T,pathRef:le,stroke:n,strokeWidth:r}),y.jsx(kMt,{curve:i,handleLoadingPulseComplete:Q,innerWidth:O,loadingStroke:m,loadingStrokeOpacity:g,loadingStyle:w,pathD:te,pulseEpoch:W,pulseMode:H,showLoadingPulse:U,strokeWidth:r})]})}UX.displayName="Line";const CMt={top:40,right:40,bottom:40,left:40},EMt=new Set(["ProfitLossLine","LineSeriesTerminalMarker","Area","SeriesBar","Scatter","Candlestick","Bar","PatternArea"]);function TMt(e){const t=e.type;return typeof e.type=="function"&&(t.displayName||t.name)||""}function AMt(e,t){if(!(t!=null&&t.dataKey))return!1;const n=TMt(e);return n==="Line"||e.type===UX?!0:EMt.has(n)?!1:typeof t.dataKey=="string"&&t.dataKey.length>0}function OMt(e){const t=[],n=r=>{A.Children.forEach(r,i=>{if(!A.isValidElement(i))return;const o=i.props;if(AMt(i,o)&&(o!=null&&o.dataKey)){t.push({dataKey:o.dataKey,stroke:o.stroke||"var(--chart-line-primary)",strokeWidth:o.strokeWidth||2.5,yAxisId:o.yAxisId});return}const s=i.props;s!=null&&s.children&&n(s.children)})};return n(e),t}function RMt({width:e,height:t,data:n,xDataKey:r,margin:i,animationDuration:o,animationEasing:s,enterTransition:a,revealSignature:l,chartStatus:u,loadingLabel:c,yDomainTweenDuration:d,yDomainTween:h,xDomain:m,xDomainSlotCount:g,tweenYDomainOnXDomainChange:b,children:v,containerRef:w,onPhaseChange:S}){const C=A.useMemo(()=>OMt(v),[v]);return y.jsx(PNe,{animationDuration:o,animationEasing:s,chartStatus:u,clipPathId:"chart-grow-clip",containerRef:w,data:n,enterTransition:a,height:t,lines:C,loadingLabel:c,margin:i,onPhaseChange:S,revealSignature:l,tweenYDomainOnXDomainChange:b,width:e,xDataKey:r,xDomain:m,xDomainSlotCount:g,yDomainTween:h,yDomainTweenDuration:d,children:v})}function MMt({data:e,xDataKey:t="date",margin:n,animationDuration:r=1100,animationEasing:i,enterTransition:o,revealSignature:s,aspectRatio:a="2 / 1",className:l="",status:u=FX,loadingLabel:c,yDomainTweenDuration:d=kA,yDomainTween:h=!0,xDomain:m,xDomainSlotCount:g,tweenYDomainOnXDomainChange:b=!1,style:v,onPhaseChange:w,children:S}){const C=A.useRef(null),E={...CMt,...n},[T,O]=A.useState(()=>hD(u)),M=A.useCallback(I=>{O(I),w==null||w(I)},[w]),N=!!(c!=null&&c.trim()&&(T==="loading"||T==="exiting"||T==="gridTweenReady"||T==="revealingLoading"));return y.jsxs("div",{className:X("relative w-full",l),ref:C,style:{...a?{aspectRatio:a}:void 0,touchAction:"none",...v},children:[y.jsx(RY,{debounceTime:10,children:({width:I,height:D})=>y.jsx(RMt,{animationDuration:r,animationEasing:i,chartStatus:u,containerRef:C,data:e,enterTransition:o,height:D,loadingLabel:c,margin:E,onPhaseChange:M,revealSignature:s,tweenYDomainOnXDomainChange:b,width:I,xDataKey:t,xDomain:m,xDomainSlotCount:g,yDomainTween:h,yDomainTweenDuration:d,children:S})}),N?y.jsx(kNe,{exiting:T!=="loading",text:c}):null]})}const Cde=24,_Mt=60,NMt=A.memo(function({currentIndex:t,labels:n}){const r=n[t]??n[0]??"";return y.jsx("div",{className:"overflow-hidden rounded-full bg-zinc-900 px-4 py-1 text-white shadow-lg dark:bg-zinc-100 dark:text-zinc-900",children:y.jsx("div",{className:"flex h-6 items-center justify-center",children:y.jsx("span",{className:"whitespace-nowrap font-medium text-sm",children:r})})})}),LMt=A.memo(function({currentIndex:t,labels:n}){const r=A.useMemo(()=>n.map((u,c)=>{const d=u.split(" "),h=d[0]||"",m=d[1]||"";return{month:h,day:m,full:u,key:`${u}::${c}`}}),[n]),i=A.useMemo(()=>{const u=[];return r.forEach((c,d)=>{const h=u.at(-1);(!h||h.month!==c.month)&&u.push({month:c.month,key:`${c.month}-${d}`,startIndex:d})}),u},[r]),o=A.useMemo(()=>{if(t<0||t>=r.length)return 0;for(let u=i.length-1;u>=0;u--){const c=i[u];if(c&&c.startIndex<=t)return u}return 0},[t,r.length,i]),s=A.useRef(-1),a=fl(0,{stiffness:400,damping:35}),l=fl(0,{stiffness:400,damping:35});if(a.set(-t*Cde),o>=0){const u=s.current===-1,c=s.current!==o;(u||c)&&(l.set(-o*Cde),s.current=o)}return y.jsx("div",{className:"overflow-hidden rounded-full bg-zinc-900 px-4 py-1 text-white shadow-lg dark:bg-zinc-100 dark:text-zinc-900",children:y.jsx("div",{className:"relative h-6 overflow-hidden",children:y.jsxs("div",{className:"flex items-center justify-center gap-1",children:[y.jsx("div",{className:"relative h-6 overflow-hidden",children:y.jsx(or.div,{className:"flex flex-col",style:{y:l},children:i.map(u=>y.jsx("div",{className:"flex h-6 shrink-0 items-center justify-center",children:y.jsx("span",{className:"whitespace-nowrap font-medium text-sm",children:u.month})},u.key))})}),y.jsx("div",{className:"relative h-6 overflow-hidden",children:y.jsx(or.div,{className:"flex flex-col",style:{y:a},children:r.map(u=>y.jsx("div",{className:"flex h-6 shrink-0 items-center justify-center",children:y.jsx("span",{className:"whitespace-nowrap font-medium text-sm",children:u.day})},u.key))})})]})})})});function FNe({currentIndex:e,labels:t,visible:n}){return!n||t.length===0?null:t.length>_Mt?y.jsx(NMt,{currentIndex:e,labels:t}):y.jsx(LMt,{currentIndex:e,labels:t})}FNe.displayName="DateTicker";function BNe(e){const[t,n]=A.useState(!1);A.useEffect(()=>{n(!0)},[]);const r=e.containerRef.current;return!(t&&r)||!e.visible?null:y.jsx(IMt,{...e,container:r})}function IMt({x:e,y:t,containerWidth:n,containerHeight:r,offset:i=16,className:o="",children:s,left:a,top:l,flipped:u,springConfig:c,animate:d=!0,entrance:h=!0,panelStyle:m,backgroundColor:g=Bo.tooltipBackground,container:b}){const{tooltipBoxSpring:v}=$b(),w=c??v,S=A.useRef(null),C=A.useRef(180),E=A.useRef(80),[T,O]=A.useState({left:e,top:t}),M=C.current,N=E.current,I=e+M+i>n,D=I?e-i-M:e+i,P=Math.max(i,Math.min(t-N/2,r-N-i)),F=fl(D,w),z=fl(P,w);d&&a===void 0&&F.set(D),d&&l===void 0&&z.set(P),A.useLayoutEffect(()=>{if(!S.current)return;const le=S.current,K=le.offsetWidth,te=le.offsetHeight;K>0&&(C.current=K),te>0&&(E.current=te);const de=C.current,ue=E.current,ie=e+de+i>n?e-i-de:e+i,he=Math.max(i,Math.min(t-ue/2,r-ue-i));if(!d){O({left:ie,top:he});return}a===void 0&&F.set(ie),l===void 0&&z.set(he)},[e,t,n,r,i,a,l,d,F,z]);const $=A.useRef(I),[B,H]=A.useState(0);A.useEffect(()=>{$.current!==I&&(H(le=>le+1),$.current=I)},[I]);const U=d?a??F:T.left,W=d?l??z:T.top,q=u??I,Y=q?"right top":"left top",Q=X("min-w-[140px] overflow-hidden rounded-lg text-chart-tooltip-foreground shadow-lg",(m==null?void 0:m.backgroundColor)===void 0&&g===Bo.tooltipBackground&&"bg-chart-tooltip-background",(m==null?void 0:m.backdropFilter)===void 0&&"backdrop-blur-md"),G={transformOrigin:Y,...(m==null?void 0:m.backgroundColor)===void 0&&{backgroundColor:g},...m};return h?mi.createPortal(y.jsx(or.div,{animate:{opacity:1},className:X("pointer-events-none absolute z-50",o),exit:{opacity:0},initial:{opacity:0},ref:S,style:{left:U,top:W},transition:{duration:.1},children:y.jsx(or.div,{animate:{scale:1,opacity:1,x:0},className:Q,initial:{scale:.85,opacity:0,x:q?20:-20},style:G,transition:{type:"spring",stiffness:300,damping:25},children:s},B)}),b):mi.createPortal(y.jsx("div",{className:X("pointer-events-none absolute z-50",o),ref:S,style:{left:T.left,top:T.top},children:y.jsx("div",{className:Q,style:G,children:s})}),b)}BNe.displayName="TooltipBox";function HNe({title:e,rows:t,children:n}){return y.jsx("div",{className:"overflow-hidden",children:y.jsxs("div",{className:"px-3 py-2.5",children:[e&&y.jsx("div",{className:"mb-2 text-left font-medium text-chart-tooltip-foreground text-xs",children:e}),y.jsx("div",{className:"space-y-1.5",children:t.map(r=>y.jsxs("div",{className:"flex items-center justify-between gap-4",children:[y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx("span",{className:"h-2.5 w-2.5 shrink-0 rounded-full",style:{backgroundColor:r.color}}),y.jsx("span",{className:"text-chart-tooltip-muted text-sm",children:r.label})]}),y.jsx("span",{className:"font-medium text-chart-tooltip-foreground text-sm tabular-nums",children:typeof r.value=="number"?rRt(r.value):r.value})]},`${r.label}-${r.color}`))}),n&&y.jsx("div",{className:"mt-2 transition-opacity duration-200 ease-out",children:n})]})})}HNe.displayName="TooltipContent";function UNe(e,t){return e*2*Math.max(0,Math.min(.5,t))}function PMt({x:e,y:t,halfExtent:n,cornerRadiusFraction:r,fill:i,stroke:o,strokeWidth:s,springConfig:a}){const{tooltipSpring:l}=$b(),u=a??l,c=fl(e,u),d=fl(t,u),h=n*2,m=UNe(n,r),g=bb(c,v=>v-n),b=bb(d,v=>v-n);return c.set(e),d.set(t),y.jsx(or.rect,{fill:i,height:h,rx:m,ry:m,stroke:o,strokeWidth:s,width:h,x:g,y:b})}function VNe({x:e,y:t,visible:n,color:r,size:i=5,strokeColor:o=Bo.background,strokeWidth:s=2,variant:a="dot",cornerRadiusFraction:l=.25,springConfig:u,animate:c=!0}){const{tooltipSpring:d}=$b(),h=u??d,m=fl(e,h),g=fl(t,h),b=a==="ring",v=b?"transparent":r,w=b?r:o,S=b?s??1.5:s;if(c&&!b&&(m.set(e),g.set(t)),!n)return null;if(b){if(c)return y.jsx(PMt,{cornerRadiusFraction:l,fill:v,halfExtent:i,springConfig:u,stroke:w,strokeWidth:S,x:e,y:t});const C=i*2,E=UNe(i,l);return y.jsx("rect",{fill:v,height:C,rx:E,ry:E,stroke:w,strokeWidth:S,width:C,x:e-i,y:t-i})}return c?y.jsx(or.circle,{cx:m,cy:g,fill:v,r:i,stroke:w,strokeWidth:S}):y.jsx("circle",{cx:e,cy:t,fill:v,r:i,stroke:w,strokeWidth:S})}VNe.displayName="TooltipDot";function jMt(e){return e===!1||e==="none"?{top:!1,bottom:!1,any:!1}:e===!0||e==="both"?{top:!0,bottom:!0,any:!0}:e==="top"?{top:!0,bottom:!1,any:!0}:{top:!1,bottom:!0,any:!0}}function DMt(e,t=10){const n=Math.min(40,Math.max(2,t)),r=100-n;return e.any?e.top&&e.bottom?[{offset:"0%",opacity:0},{offset:`${n}%`,opacity:1},{offset:"50%",opacity:1},{offset:`${r}%`,opacity:1},{offset:"100%",opacity:0}]:e.top?[{offset:"0%",opacity:0},{offset:`${n}%`,opacity:1},{offset:"100%",opacity:1}]:[{offset:"0%",opacity:1},{offset:`${r}%`,opacity:1},{offset:"100%",opacity:0}]:[{offset:"0%",opacity:1}]}function $Mt(e){if(typeof e=="number")return e;switch(e){case"line":return 1;case"thin":return 2;case"medium":return 4;case"thick":return 8;default:return 1}}function WNe(e){return e.visible?y.jsx(zMt,{...e}):null}function zMt({x:e,visible:t,height:n,width:r="line",span:i,columnWidth:o,colorEdge:s=Bo.crosshair,colorMid:a=Bo.crosshair,fadeEdges:l="both",fadeLength:u=10,animate:c=!0,gradientId:d="tooltip-indicator-gradient",springConfig:h,strokeDasharray:m}){const{tooltipSpring:g}=$b(),b=h??g,v=i!==void 0&&o!==void 0?i*o:$Mt(r),w=e-v/2,S=e,C=fl(w,b),E=fl(S,b);c&&(C.set(w),E.set(S)),A.useEffect(()=>{C.set(w),E.set(S)},[E,C,S,w,t]);const T=a||s,O=jMt(l);if(!!m){const I=Math.max(1,v);return c?y.jsx(or.line,{stroke:T,strokeDasharray:m,strokeWidth:I,x1:E,x2:E,y1:0,y2:n}):y.jsx("line",{stroke:T,strokeDasharray:m,strokeWidth:I,x1:S,x2:S,y1:0,y2:n})}if(!O.any)return c?y.jsx(or.rect,{fill:T,height:n,width:v,x:C,y:0}):y.jsx("rect",{fill:T,height:n,width:v,x:w,y:0});const N=DMt(O,u);return y.jsxs("g",{children:[y.jsx("defs",{children:y.jsx("linearGradient",{id:d,x1:"0%",x2:"0%",y1:"0%",y2:"100%",children:N.map(I=>y.jsx("stop",{offset:I.offset,style:{stopColor:T,stopOpacity:I.opacity}},I.offset))})}),c?y.jsx(or.rect,{fill:`url(#${d})`,height:n,width:v,x:C,y:0}):y.jsx("rect",{fill:`url(#${d})`,height:n,width:v,x:w,y:0})]})}WNe.displayName="TooltipIndicator";const FMt=A.memo(function({showDatePill:t=!0,showCrosshair:n=!0,showDots:r=!0,dotVariant:i="dot",dotSize:o=5,dotRadiusFraction:s,dotScale:a=1,dotStrokeWidth:l,indicatorColor:u,content:c,rows:d,dotColor:h,children:m,className:g="",container:b,springConfig:v,matchCrosshair:w=!1,damping:S,indicatorDasharray:C,indicatorFadeEdges:E,indicatorFadeLength:T,boxSpringConfig:O,panelStyle:M,backgroundColor:N}){var Oe;const{tooltipData:I,width:D,height:P,innerHeight:F,margin:z,columnWidth:$,lines:B,xAccessor:H,dateLabels:U,containerRef:W,orientation:q,barXAccessor:Y,bandWidth:Q,squareSnap:G}=JY(),{tooltipSpring:le}=$b(),K=q==="horizontal",te=U.length>60,de=A.useMemo(()=>{if(i!=="ring"||!Q||B.length===0)return o*a;const Le=B.length,ge=(G==null?void 0:G.groupGap)??(Le>1?4:0);return(Q-ge*(Le-1))/Le/2*a},[Q,a,o,i,B.length,G==null?void 0:G.groupGap]),ue=A.useMemo(()=>O?{animate:!te,springConfig:O}:w?{animate:!te,springConfig:v??le}:FOt(S),[O,S,te,w,v,le]),ae=I!==null,ie=(I==null?void 0:I.x)??0,he=ie+z.left,fe=(Oe=B[0])==null?void 0:Oe.dataKey,Se=(fe?(I==null?void 0:I.yPositions[fe])??0:0)+z.top,pe=A.useMemo(()=>I?d?d(I.point):B.map(Le=>({color:Le.stroke,label:Le.dataKey,value:I.point[Le.dataKey]??0})):[],[I,B,d]),Ee=A.useMemo(()=>(Le,ge)=>{var $e;if(d&&(($e=pe[ge])!=null&&$e.color))return pe[ge].color;if(h!=null){if(typeof h=="function"&&I)return h(I.point,Le);if(typeof h=="string")return h}return Le.stroke},[h,d,I,pe]),ke=A.useMemo(()=>u==null?Bo.crosshair:typeof u=="function"?I?u(I.point):Bo.crosshair:u,[u,I]),Ie=A.useMemo(()=>{if(I)return Y?Y(I.point):nRt.format(H(I.point))},[I,Y,H]),Be=y.jsxs(y.Fragment,{children:[n&&y.jsx("svg",{"aria-hidden":"true",className:"pointer-events-none absolute inset-0",height:"100%",width:"100%",children:y.jsx("g",{transform:`translate(${z.left},${z.top})`,children:y.jsx(WNe,{animate:!te,colorEdge:ke,colorMid:ke,columnWidth:$,fadeEdges:C?"none":E??"both",fadeLength:T,height:F,springConfig:v,strokeDasharray:C,visible:ae,width:"line",x:ie})})}),r&&ae&&!K&&y.jsx("svg",{"aria-hidden":"true",className:"pointer-events-none absolute inset-0",height:"100%",width:"100%",children:y.jsx("g",{transform:`translate(${z.left},${z.top})`,children:B.map((Le,ge)=>{var $e;return y.jsx(VNe,{color:Ee(Le,ge),cornerRadiusFraction:i==="ring"?s:void 0,size:de,springConfig:v,strokeColor:Bo.background,strokeWidth:i==="ring"?l:void 0,variant:i,visible:ae,x:(($e=I==null?void 0:I.xPositions)==null?void 0:$e[Le.dataKey])??ie,y:(I==null?void 0:I.yPositions[Le.dataKey])??0},Le.dataKey)})})}),y.jsx(BNe,{animate:ue.animate,backgroundColor:N,className:g,containerHeight:P,containerRef:W,containerWidth:D,panelStyle:M,springConfig:ue.springConfig,top:K?void 0:z.top,visible:ae,x:he,y:K?Se:z.top,children:c&&I?c({point:I.point,index:I.index}):!c&&y.jsx(HNe,{rows:pe,title:Ie,children:m})}),y.jsx(BMt,{currentIndex:(I==null?void 0:I.index)??0,discreteInteraction:te,enabled:t&&!K,labels:U,springConfig:v,visible:ae,xWithMargin:he})]});return mi.createPortal(Be,b)});function I_(e){const{containerRef:t}=_a(),[n,r]=A.useState(!1);A.useEffect(()=>{r(!0)},[]);const i=t.current;return n&&i?y.jsx(FMt,{...e,container:i}):null}I_.displayName="ChartTooltip";function BMt(e){return e.enabled&&e.visible&&e.labels.length>0?y.jsx(HMt,{...e}):null}function HMt({labels:e,currentIndex:t,xWithMargin:n,discreteInteraction:r,springConfig:i,visible:o}){const{tooltipSpring:s}=$b(),l=fl(n,i??s);return r||l.set(n),A.useEffect(()=>{l.set(n)},[l,o]),y.jsx(or.div,{className:"pointer-events-none absolute z-50",style:{left:r?n:l,transform:"translateX(-50%)",bottom:4},children:y.jsx(FNe,{currentIndex:t,labels:e,visible:o})})}const UMt=kA;function VMt({label:e,x:t,crosshairX:n,hoveredLabel:r,isHovering:i,tickerHalfWidth:o,animatePosition:s}){const l=o+20;let u=1;if(i&&n!==null){const c=Math.abs(t-n);c<o||r&&e===r?u=0:c<l&&(u=(c-o)/20)}return y.jsx("div",{className:"absolute",style:{left:t,bottom:12,width:0,display:"flex",justifyContent:"center",transition:s?`left ${UMt}ms cubic-bezier(${tu.join(", ")})`:void 0},children:y.jsx("span",{className:X("whitespace-nowrap text-chart-label text-xs"),style:{opacity:u,transition:"opacity 0.4s ease-in-out"},children:e})})}const WMt=400;function qMt(e,t){if(t<0||t>e)return 0;let n=1;for(let r=0;r<t;r++)n=n*(e-r)/(r+1);return n}function qNe(e,t){if(t===1)return e>=1?[[e]]:[];const n=[];for(let r=1;r<=e-(t-1);r++)for(const i of qNe(e-r,t-1))n.push([r,...i]);return n}function GMt(e){const t=[0];let n=0;for(const r of e)n+=r,t.push(n);return t}function GNe(e,t){const n=e-1;if(n<=0)return[0];const r=Array.from({length:t},(o,s)=>Math.round(s/(t-1)*n)),i=[...new Set(r)].sort((o,s)=>o-s);return i[0]!==0&&i.unshift(0),i.at(-1)!==n&&i.push(n),[...new Set(i)].sort((o,s)=>o-s)}function KMt(e,t){const n=e-1;if(n<=0)return[[0]];const r=t-1;return r<=0?[[0]]:qMt(n-1,r-1)>WMt?[GNe(e,t)]:qNe(n,r).map(GMt)}function YMt(e,t,n,r){const i=new Set,o=[];for(const s of e){const a=t[s];if(!a)continue;const l=n[s]??Ag.format(r(a));i.has(l)||(i.add(l),o.push(s))}return o}function KNe(e){const t=[];for(let n=1;n<e.length;n++){const r=e[n],i=e[n-1];r==null||i==null||t.push(r-i)}return t}function XMt(e){const t=KNe(e),n=Math.min(...t),r=t.indexOf(n);return r===t.length-1?0:r===0?1:2}function Ede(e,t,n){if(e.length<2)return{score:Number.POSITIVE_INFINITY,symmetryPenalty:Number.POSITIVE_INFINITY,countDistance:Number.POSITIVE_INFINITY,edgePreference:Number.POSITIVE_INFINITY};const r=[];for(let g=1;g<e.length;g++){const b=e[g],v=e[g-1];b==null||v==null||r.push(t(b)-t(v))}const i=Math.min(...r),o=Math.max(...r),s=r.reduce((g,b)=>g+b,0)/r.length,a=s>0?(o-i)/s:o-i,l=Math.abs(e.length-n),u=KNe(e),c=Math.min(...u),d=u.indexOf(c),h=d>0&&d<u.length-1?.08:0,m=u.reduce((g,b,v)=>g+Math.abs(b-(u.at(-1-v)??b)),0)/u.length;return{score:a+.1*l+h+m*.02,symmetryPenalty:m,countDistance:l,edgePreference:XMt(e)}}function QMt(e,t,n,r){return e.score<t.score-1e-6?!0:Math.abs(e.score-t.score)>1e-6?!1:n<r?!0:n>r?!1:e.symmetryPenalty<t.symmetryPenalty-1e-6?!0:e.symmetryPenalty>t.symmetryPenalty+1e-6?!1:e.edgePreference<t.edgePreference}function ZMt(e,t,n){if(e<=0)return[];if(e===1)return[0];if(e<=t)return Array.from({length:e},(u,c)=>c);const r=(n==null?void 0:n.resolveXPx)??(u=>u),i=Math.max(2,t-1),o=Math.min(e,t+1);let s=GNe(e,t),a=Ede(s,r,t),l=a.countDistance;for(let u=i;u<=o;u++)for(const c of KMt(e,u)){const d=n!=null&&n.data&&n.dateLabels&&n.xAccessor?YMt(c,n.data,n.dateLabels,n.xAccessor):c;if(d.length<2)continue;const h=Ede(d,r,t),m=Math.abs(d.length-t);QMt(h,a,m,l)&&(s=d,a=h,l=m)}return s}function JMt({data:e,dateLabels:t,marginLeft:n,targetTickCount:r,xAccessor:i,xScale:o}){const s=new Set,a=[],l=u=>{const c=e[u];return c?o(i(c))??0:u};for(const u of ZMt(e.length,r,{data:e,dateLabels:t,resolveXPx:l,xAccessor:i})){const c=e[u];if(!c)continue;const d=i(c),h=t[u]??Ag.format(d);s.has(h)||(s.add(h),a.push({date:d,label:h,x:(o(d)??0)+n}))}return a}function Tde({marginLeft:e,numTicks:t,xScale:n}){const r=n.domain(),i=r[0],o=r[1];if(!(i&&o))return[];const s=i.getTime(),l=o.getTime()-s,u=Math.max(2,t),c=new Set,d=[];for(let h=0;h<u;h++){const m=h/(u-1),g=new Date(s+m*l),b=Ag.format(g);c.has(b)||(c.add(b),d.push({date:g,label:b,x:(n(g)??0)+e}))}return d}function e_t(e,t,n){if(e.length===0)return!1;const r=n.domain()[1],i=e.at(-1);return r&&i?r.getTime()>t(i).getTime():!1}function t_t(e,t,n,r,i,o){if(t.length===0||o<=0)return e;const s=t.at(-1),a=r.domain()[1];if(!(s&&a))return e;const u=n(s).getTime(),c=a.getTime();if(c<=u)return e;const d=new Set(e.map(b=>b.label)),h=[],m=Math.min(o,3);for(let b=1;b<=m;b++){const v=new Date(u+b/(m+1)*(c-u)),w=Ag.format(v);d.has(w)||(d.add(w),h.push({date:v,label:w,x:(r(v)??0)+i}))}const g=Ag.format(a);return d.has(g)||h.push({date:a,label:g,x:(r(a)??0)+i}),h.length===0?e:[...e,...h].sort((b,v)=>b.x-v.x)}function P_(e){const{containerRef:t}=_a(),[n,r]=A.useState(!1);A.useEffect(()=>{r(!0)},[]);const i=t.current;return n&&i?y.jsx(n_t,{...e,container:i}):null}const n_t=A.memo(function({numTicks:t=5,tickerHalfWidth:n=50,tickMode:r="data",container:i}){const{xScale:o,margin:s,tooltipData:a,data:l,xAccessor:u,dateLabels:c,xDomain:d}=JY(),h=A.useMemo(()=>{const v=r==="data"&&e_t(l,u,o);if(r==="domain")return Tde({marginLeft:s.left,numTicks:t,xScale:o});if(v&&d==null)return Tde({marginLeft:s.left,numTicks:t,xScale:o});const w=JMt({data:l,dateLabels:c,marginLeft:s.left,targetTickCount:t,xAccessor:u,xScale:o});return v&&d!=null?t_t(w,l,u,o,s.left,Math.max(1,t-w.length+1)):w},[r,d,l,c,u,o,s.left,t]),m=a!==null,g=a?a.x+s.left:null,b=m&&a?c[a.index]??Ag.format(u(a.point)):null;return mi.createPortal(y.jsx("div",{className:"pointer-events-none absolute inset-0",children:h.map(v=>y.jsx(VMt,{animatePosition:d==null,crosshairX:g,hoveredLabel:b,isHovering:m,label:v.label,tickerHalfWidth:n,x:v.x},`${v.date.getTime()}-${v.x}`))}),i)});P_.displayName="XAxis";const r_t=5;function i_t({result:e,visualization:t,height:n=220}){const{labelColumn:r,valueColumns:i}=mEe(e,t),o=i.slice(0,r_t),s=A.useMemo(()=>Tst(e,r),[e,r]),a=A.useMemo(()=>s?e.rows.map(l=>{const u=l[r];return{...l,date:u instanceof Date?u:new Date(String(u))}}):e.rows.map(l=>({...l,name:l[r]})),[e.rows,r,s]);return o.length===0?y.jsx(oH,{result:e,visualization:t,height:n}):t.kind==="bar"?y.jsx("div",{style:{height:n},children:y.jsxs(jNe,{data:a,xDataKey:"name",aspectRatio:"auto",className:"h-full",children:[y.jsx(L_,{}),y.jsx(P_,{}),o.map((l,u)=>y.jsx(DNe,{dataKey:l,fill:Lp[u%Lp.length]},l)),y.jsx(I_,{})]})}):s?t.kind==="area"?y.jsx("div",{style:{height:n},children:y.jsxs(XRt,{data:a,xDataKey:"date",aspectRatio:"auto",className:"h-full",children:[y.jsx(L_,{}),y.jsx(P_,{}),o.map((l,u)=>y.jsx(zX,{dataKey:l,fill:Lp[u%Lp.length],stroke:Lp[u%Lp.length]},l)),y.jsx(I_,{})]})}):y.jsx("div",{style:{height:n},children:y.jsxs(MMt,{data:a,xDataKey:"date",aspectRatio:"auto",className:"h-full",children:[y.jsx(L_,{}),y.jsx(P_,{}),o.map((l,u)=>y.jsx(UX,{dataKey:l,stroke:Lp[u%Lp.length]},l)),y.jsx(I_,{})]})}):y.jsx(oH,{result:e,visualization:t,height:n})}var y$,Ade;function Na(){if(Ade)return y$;Ade=1;var e=Array.isArray;return y$=e,y$}var b$,Ode;function VX(){if(Ode)return b$;Ode=1;var e=Na(),t=rS(),n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,r=/^\w*$/;function i(o,s){if(e(o))return!1;var a=typeof o;return a=="number"||a=="symbol"||a=="boolean"||o==null||t(o)?!0:r.test(o)||!n.test(o)||s!=null&&o in Object(s)}return b$=i,b$}var v$,Rde;function WX(){if(Rde)return v$;Rde=1;var e=Zh(),t=Fg(),n="[object AsyncFunction]",r="[object Function]",i="[object GeneratorFunction]",o="[object Proxy]";function s(a){if(!t(a))return!1;var l=e(a);return l==r||l==i||l==n||l==o}return v$=s,v$}var x$,Mde;function o_t(){if(Mde)return x$;Mde=1;var e=Hd(),t=e["__core-js_shared__"];return x$=t,x$}var w$,_de;function s_t(){if(_de)return w$;_de=1;var e=o_t(),t=(function(){var r=/[^.]+$/.exec(e&&e.keys&&e.keys.IE_PROTO||"");return r?"Symbol(src)_1."+r:""})();function n(r){return!!t&&t in r}return w$=n,w$}var S$,Nde;function YNe(){if(Nde)return S$;Nde=1;var e=Function.prototype,t=e.toString;function n(r){if(r!=null){try{return t.call(r)}catch{}try{return r+""}catch{}}return""}return S$=n,S$}var k$,Lde;function a_t(){if(Lde)return k$;Lde=1;var e=WX(),t=s_t(),n=Fg(),r=YNe(),i=/[\\^$.*+?()[\]{}|]/g,o=/^\[object .+?Constructor\]$/,s=Function.prototype,a=Object.prototype,l=s.toString,u=a.hasOwnProperty,c=RegExp("^"+l.call(u).replace(i,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function d(h){if(!n(h)||t(h))return!1;var m=e(h)?c:o;return m.test(r(h))}return k$=d,k$}var C$,Ide;function l_t(){if(Ide)return C$;Ide=1;function e(t,n){return t==null?void 0:t[n]}return C$=e,C$}var E$,Pde;function zb(){if(Pde)return E$;Pde=1;var e=a_t(),t=l_t();function n(r,i){var o=t(r,i);return e(o)?o:void 0}return E$=n,E$}var T$,jde;function pD(){if(jde)return T$;jde=1;var e=zb(),t=e(Object,"create");return T$=t,T$}var A$,Dde;function u_t(){if(Dde)return A$;Dde=1;var e=pD();function t(){this.__data__=e?e(null):{},this.size=0}return A$=t,A$}var O$,$de;function c_t(){if($de)return O$;$de=1;function e(t){var n=this.has(t)&&delete this.__data__[t];return this.size-=n?1:0,n}return O$=e,O$}var R$,zde;function d_t(){if(zde)return R$;zde=1;var e=pD(),t="__lodash_hash_undefined__",n=Object.prototype,r=n.hasOwnProperty;function i(o){var s=this.__data__;if(e){var a=s[o];return a===t?void 0:a}return r.call(s,o)?s[o]:void 0}return R$=i,R$}var M$,Fde;function f_t(){if(Fde)return M$;Fde=1;var e=pD(),t=Object.prototype,n=t.hasOwnProperty;function r(i){var o=this.__data__;return e?o[i]!==void 0:n.call(o,i)}return M$=r,M$}var _$,Bde;function h_t(){if(Bde)return _$;Bde=1;var e=pD(),t="__lodash_hash_undefined__";function n(r,i){var o=this.__data__;return this.size+=this.has(r)?0:1,o[r]=e&&i===void 0?t:i,this}return _$=n,_$}var N$,Hde;function p_t(){if(Hde)return N$;Hde=1;var e=u_t(),t=c_t(),n=d_t(),r=f_t(),i=h_t();function o(s){var a=-1,l=s==null?0:s.length;for(this.clear();++a<l;){var u=s[a];this.set(u[0],u[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,N$=o,N$}var L$,Ude;function m_t(){if(Ude)return L$;Ude=1;function e(){this.__data__=[],this.size=0}return L$=e,L$}var I$,Vde;function qX(){if(Vde)return I$;Vde=1;function e(t,n){return t===n||t!==t&&n!==n}return I$=e,I$}var P$,Wde;function mD(){if(Wde)return P$;Wde=1;var e=qX();function t(n,r){for(var i=n.length;i--;)if(e(n[i][0],r))return i;return-1}return P$=t,P$}var j$,qde;function g_t(){if(qde)return j$;qde=1;var e=mD(),t=Array.prototype,n=t.splice;function r(i){var o=this.__data__,s=e(o,i);if(s<0)return!1;var a=o.length-1;return s==a?o.pop():n.call(o,s,1),--this.size,!0}return j$=r,j$}var D$,Gde;function y_t(){if(Gde)return D$;Gde=1;var e=mD();function t(n){var r=this.__data__,i=e(r,n);return i<0?void 0:r[i][1]}return D$=t,D$}var $$,Kde;function b_t(){if(Kde)return $$;Kde=1;var e=mD();function t(n){return e(this.__data__,n)>-1}return $$=t,$$}var z$,Yde;function v_t(){if(Yde)return z$;Yde=1;var e=mD();function t(n,r){var i=this.__data__,o=e(i,n);return o<0?(++this.size,i.push([n,r])):i[o][1]=r,this}return z$=t,z$}var F$,Xde;function gD(){if(Xde)return F$;Xde=1;var e=m_t(),t=g_t(),n=y_t(),r=b_t(),i=v_t();function o(s){var a=-1,l=s==null?0:s.length;for(this.clear();++a<l;){var u=s[a];this.set(u[0],u[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,F$=o,F$}var B$,Qde;function GX(){if(Qde)return B$;Qde=1;var e=zb(),t=Hd(),n=e(t,"Map");return B$=n,B$}var H$,Zde;function x_t(){if(Zde)return H$;Zde=1;var e=p_t(),t=gD(),n=GX();function r(){this.size=0,this.__data__={hash:new e,map:new(n||t),string:new e}}return H$=r,H$}var U$,Jde;function w_t(){if(Jde)return U$;Jde=1;function e(t){var n=typeof t;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?t!=="__proto__":t===null}return U$=e,U$}var V$,efe;function yD(){if(efe)return V$;efe=1;var e=w_t();function t(n,r){var i=n.__data__;return e(r)?i[typeof r=="string"?"string":"hash"]:i.map}return V$=t,V$}var W$,tfe;function S_t(){if(tfe)return W$;tfe=1;var e=yD();function t(n){var r=e(this,n).delete(n);return this.size-=r?1:0,r}return W$=t,W$}var q$,nfe;function k_t(){if(nfe)return q$;nfe=1;var e=yD();function t(n){return e(this,n).get(n)}return q$=t,q$}var G$,rfe;function C_t(){if(rfe)return G$;rfe=1;var e=yD();function t(n){return e(this,n).has(n)}return G$=t,G$}var K$,ife;function E_t(){if(ife)return K$;ife=1;var e=yD();function t(n,r){var i=e(this,n),o=i.size;return i.set(n,r),this.size+=i.size==o?0:1,this}return K$=t,K$}var Y$,ofe;function KX(){if(ofe)return Y$;ofe=1;var e=x_t(),t=S_t(),n=k_t(),r=C_t(),i=E_t();function o(s){var a=-1,l=s==null?0:s.length;for(this.clear();++a<l;){var u=s[a];this.set(u[0],u[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,Y$=o,Y$}var X$,sfe;function XNe(){if(sfe)return X$;sfe=1;var e=KX(),t="Expected a function";function n(r,i){if(typeof r!="function"||i!=null&&typeof i!="function")throw new TypeError(t);var o=function(){var s=arguments,a=i?i.apply(this,s):s[0],l=o.cache;if(l.has(a))return l.get(a);var u=r.apply(this,s);return o.cache=l.set(a,u)||l,u};return o.cache=new(n.Cache||e),o}return n.Cache=e,X$=n,X$}var Q$,afe;function T_t(){if(afe)return Q$;afe=1;var e=XNe(),t=500;function n(r){var i=e(r,function(s){return o.size===t&&o.clear(),s}),o=i.cache;return i}return Q$=n,Q$}var Z$,lfe;function A_t(){if(lfe)return Z$;lfe=1;var e=T_t(),t=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,n=/\\(\\)?/g,r=e(function(i){var o=[];return i.charCodeAt(0)===46&&o.push(""),i.replace(t,function(s,a,l,u){o.push(l?u.replace(n,"$1"):a||s)}),o});return Z$=r,Z$}var J$,ufe;function YX(){if(ufe)return J$;ufe=1;function e(t,n){for(var r=-1,i=t==null?0:t.length,o=Array(i);++r<i;)o[r]=n(t[r],r,t);return o}return J$=e,J$}var ez,cfe;function O_t(){if(cfe)return ez;cfe=1;var e=lA(),t=YX(),n=Na(),r=rS(),i=e?e.prototype:void 0,o=i?i.toString:void 0;function s(a){if(typeof a=="string")return a;if(n(a))return t(a,s)+"";if(r(a))return o?o.call(a):"";var l=a+"";return l=="0"&&1/a==-1/0?"-0":l}return ez=s,ez}var tz,dfe;function QNe(){if(dfe)return tz;dfe=1;var e=O_t();function t(n){return n==null?"":e(n)}return tz=t,tz}var nz,ffe;function ZNe(){if(ffe)return nz;ffe=1;var e=Na(),t=VX(),n=A_t(),r=QNe();function i(o,s){return e(o)?o:t(o,s)?[o]:n(r(o))}return nz=i,nz}var rz,hfe;function bD(){if(hfe)return rz;hfe=1;var e=rS();function t(n){if(typeof n=="string"||e(n))return n;var r=n+"";return r=="0"&&1/n==-1/0?"-0":r}return rz=t,rz}var iz,pfe;function XX(){if(pfe)return iz;pfe=1;var e=ZNe(),t=bD();function n(r,i){i=e(i,r);for(var o=0,s=i.length;r!=null&&o<s;)r=r[t(i[o++])];return o&&o==s?r:void 0}return iz=n,iz}var oz,mfe;function JNe(){if(mfe)return oz;mfe=1;var e=XX();function t(n,r,i){var o=n==null?void 0:e(n,r);return o===void 0?i:o}return oz=t,oz}var R_t=JNe();const au=cr(R_t);var sz,gfe;function M_t(){if(gfe)return sz;gfe=1;function e(t){return t==null}return sz=e,sz}var __t=M_t();const Rn=cr(__t);var az,yfe;function N_t(){if(yfe)return az;yfe=1;var e=Zh(),t=Na(),n=Jh(),r="[object String]";function i(o){return typeof o=="string"||!t(o)&&n(o)&&e(o)==r}return az=i,az}var L_t=N_t();const vb=cr(L_t);var I_t=WX();const yn=cr(I_t);var P_t=Fg();const cS=cr(P_t);var lz={exports:{}},br={};/**
2845
2845
  * @license React
2846
2846
  * react-is.production.min.js
2847
2847
  *
@@ -2849,23 +2849,23 @@ ${JSON.stringify(e,null,2)}`})]})}const As="text-zinc-400 dark:text-zinc-500",Cg
2849
2849
  *
2850
2850
  * This source code is licensed under the MIT license found in the
2851
2851
  * LICENSE file in the root directory of this source tree.
2852
- */var bfe;function j_t(){if(bfe)return br;bfe=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),s=Symbol.for("react.context"),a=Symbol.for("react.server_context"),l=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),c=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),m=Symbol.for("react.offscreen"),g;g=Symbol.for("react.module.reference");function b(v){if(typeof v=="object"&&v!==null){var w=v.$$typeof;switch(w){case e:switch(v=v.type,v){case n:case i:case r:case u:case c:return v;default:switch(v=v&&v.$$typeof,v){case a:case s:case l:case h:case d:case o:return v;default:return w}}case t:return w}}}return br.ContextConsumer=s,br.ContextProvider=o,br.Element=e,br.ForwardRef=l,br.Fragment=n,br.Lazy=h,br.Memo=d,br.Portal=t,br.Profiler=i,br.StrictMode=r,br.Suspense=u,br.SuspenseList=c,br.isAsyncMode=function(){return!1},br.isConcurrentMode=function(){return!1},br.isContextConsumer=function(v){return b(v)===s},br.isContextProvider=function(v){return b(v)===o},br.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===e},br.isForwardRef=function(v){return b(v)===l},br.isFragment=function(v){return b(v)===n},br.isLazy=function(v){return b(v)===h},br.isMemo=function(v){return b(v)===d},br.isPortal=function(v){return b(v)===t},br.isProfiler=function(v){return b(v)===i},br.isStrictMode=function(v){return b(v)===r},br.isSuspense=function(v){return b(v)===u},br.isSuspenseList=function(v){return b(v)===c},br.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===n||v===i||v===r||v===u||v===c||v===m||typeof v=="object"&&v!==null&&(v.$$typeof===h||v.$$typeof===d||v.$$typeof===o||v.$$typeof===s||v.$$typeof===l||v.$$typeof===g||v.getModuleId!==void 0)},br.typeOf=b,br}var vfe;function D_t(){return vfe||(vfe=1,lz.exports=j_t()),lz.exports}var $_t=D_t(),uz,xfe;function eLe(){if(xfe)return uz;xfe=1;var e=Jh(),t=ep(),n="[object Number]";function r(i){return typeof i=="number"||t(i)&&e(i)==n}return uz=r,uz}var cz,wfe;function z_t(){if(wfe)return cz;wfe=1;var e=eLe();function t(n){return e(n)&&n!=+n}return cz=t,cz}var F_t=z_t();const dS=cr(F_t);var B_t=eLe();const H_t=cr(B_t);var Xu=function(t){return t===0?0:t>0?1:-1},ay=function(t){return vb(t)&&t.indexOf("%")===t.length-1},ft=function(t){return H_t(t)&&!dS(t)},U_t=function(t){return Rn(t)},ho=function(t){return ft(t)||vb(t)},V_t=0,fS=function(t){var n=++V_t;return"".concat(t||"").concat(n)},xb=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(!ft(t)&&!vb(t))return r;var o;if(ay(t)){var s=t.indexOf("%");o=n*parseFloat(t.slice(0,s))/100}else o=+t;return dS(o)&&(o=r),i&&o>n&&(o=n),o},cm=function(t){if(!t)return null;var n=Object.keys(t);return n&&n.length?t[n[0]]:null},W_t=function(t){if(!Array.isArray(t))return!1;for(var n=t.length,r={},i=0;i<n;i++)if(!r[t[i]])r[t[i]]=!0;else return!0;return!1},is=function(t,n){return ft(t)&&ft(n)?function(r){return t+r*(n-t)}:function(){return n}};function dI(e,t,n){return!e||!e.length?null:e.find(function(r){return r&&(typeof t=="function"?t(r):au(r,t))===n})}var q_t=function(t,n){return ft(t)&&ft(n)?t-n:vb(t)&&vb(n)?t.localeCompare(n):t instanceof Date&&n instanceof Date?t.getTime()-n.getTime():String(t).localeCompare(String(n))};function V1(e,t){for(var n in e)if({}.hasOwnProperty.call(e,n)&&(!{}.hasOwnProperty.call(t,n)||e[n]!==t[n]))return!1;for(var r in t)if({}.hasOwnProperty.call(t,r)&&!{}.hasOwnProperty.call(e,r))return!1;return!0}function zV(e){"@babel/helpers - typeof";return zV=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},zV(e)}var G_t=["viewBox","children"],K_t=["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"],Sfe=["points","pathLength"],dz={svg:G_t,polygon:Sfe,polyline:Sfe},QX=["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"],fI=function(t,n){if(!t||typeof t=="function"||typeof t=="boolean")return null;var r=t;if(A.isValidElement(t)&&(r=t.props),!cS(r))return null;var i={};return Object.keys(r).forEach(function(o){QX.includes(o)&&(i[o]=n||function(s){return r[o](r,s)})}),i},Y_t=function(t,n,r){return function(i){return t(n,r,i),null}},hI=function(t,n,r){if(!cS(t)||zV(t)!=="object")return null;var i=null;return Object.keys(t).forEach(function(o){var s=t[o];QX.includes(o)&&typeof s=="function"&&(i||(i={}),i[o]=Y_t(s,n,r))}),i},X_t=["children"],Q_t=["children"];function kfe(e,t){if(e==null)return{};var n=Z_t(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Z_t(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function FV(e){"@babel/helpers - typeof";return FV=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},FV(e)}var Cfe={click:"onClick",mousedown:"onMouseDown",mouseup:"onMouseUp",mouseover:"onMouseOver",mousemove:"onMouseMove",mouseout:"onMouseOut",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",touchcancel:"onTouchCancel",touchend:"onTouchEnd",touchmove:"onTouchMove",touchstart:"onTouchStart",contextmenu:"onContextMenu",dblclick:"onDoubleClick"},Oh=function(t){return typeof t=="string"?t:t?t.displayName||t.name||"Component":""},Efe=null,fz=null,ZX=function e(t){if(t===Efe&&Array.isArray(fz))return fz;var n=[];return A.Children.forEach(t,function(r){Rn(r)||($_t.isFragment(r)?n=n.concat(e(r.props.children)):n.push(r))}),fz=n,Efe=t,n};function lu(e,t){var n=[],r=[];return Array.isArray(t)?r=t.map(function(i){return Oh(i)}):r=[Oh(t)],ZX(e).forEach(function(i){var o=au(i,"type.displayName")||au(i,"type.name");r.indexOf(o)!==-1&&n.push(i)}),n}function tl(e,t){var n=lu(e,t);return n&&n[0]}var Tfe=function(t){if(!t||!t.props)return!1;var n=t.props,r=n.width,i=n.height;return!(!ft(r)||r<=0||!ft(i)||i<=0)},J_t=["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColormatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-url","foreignObject","g","glyph","glyphRef","hkern","image","line","lineGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","script","set","stop","style","svg","switch","symbol","text","textPath","title","tref","tspan","use","view","vkern"],eNt=function(t){return t&&t.type&&vb(t.type)&&J_t.indexOf(t.type)>=0},tLe=function(t){return t&&FV(t)==="object"&&"clipDot"in t},tNt=function(t,n,r,i){var o,s=(o=dz==null?void 0:dz[i])!==null&&o!==void 0?o:[];return n.startsWith("data-")||!yn(t)&&(i&&s.includes(n)||K_t.includes(n))||r&&QX.includes(n)},wn=function(t,n,r){if(!t||typeof t=="function"||typeof t=="boolean")return null;var i=t;if(A.isValidElement(t)&&(i=t.props),!cS(i))return null;var o={};return Object.keys(i).forEach(function(s){var a;tNt((a=i)===null||a===void 0?void 0:a[s],s,n,r)&&(o[s]=i[s])}),o},BV=function e(t,n){if(t===n)return!0;var r=A.Children.count(t);if(r!==A.Children.count(n))return!1;if(r===0)return!0;if(r===1)return Afe(Array.isArray(t)?t[0]:t,Array.isArray(n)?n[0]:n);for(var i=0;i<r;i++){var o=t[i],s=n[i];if(Array.isArray(o)||Array.isArray(s)){if(!e(o,s))return!1}else if(!Afe(o,s))return!1}return!0},Afe=function(t,n){if(Rn(t)&&Rn(n))return!0;if(!Rn(t)&&!Rn(n)){var r=t.props||{},i=r.children,o=kfe(r,X_t),s=n.props||{},a=s.children,l=kfe(s,Q_t);return i&&a?V1(o,l)&&BV(i,a):!i&&!a?V1(o,l):!1}return!1},Ofe=function(t,n){var r=[],i={};return ZX(t).forEach(function(o,s){if(eNt(o))r.push(o);else if(o){var a=Oh(o.type),l=n[a]||{},u=l.handler,c=l.once;if(u&&(!c||!i[a])){var d=u(o,a,s);r.push(d),i[a]=!0}}}),r},nNt=function(t){var n=t&&t.type;return n&&Cfe[n]?Cfe[n]:null},rNt=function(t,n){return ZX(n).indexOf(t)},iNt=["children","width","height","viewBox","className","style","title","desc"];function HV(){return HV=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},HV.apply(this,arguments)}function oNt(e,t){if(e==null)return{};var n=sNt(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function sNt(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function UV(e){var t=e.children,n=e.width,r=e.height,i=e.viewBox,o=e.className,s=e.style,a=e.title,l=e.desc,u=oNt(e,iNt),c=i||{width:n,height:r,x:0,y:0},d=Hn("recharts-surface",o);return we.createElement("svg",HV({},wn(u,!0,"svg"),{className:d,width:n,height:r,style:s,viewBox:"".concat(c.x," ").concat(c.y," ").concat(c.width," ").concat(c.height)}),we.createElement("title",null,a),we.createElement("desc",null,l),t)}var aNt=["children","className"];function VV(){return VV=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},VV.apply(this,arguments)}function lNt(e,t){if(e==null)return{};var n=uNt(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function uNt(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var Yr=we.forwardRef(function(e,t){var n=e.children,r=e.className,i=lNt(e,aNt),o=Hn("recharts-layer",r);return we.createElement("g",VV({className:o},wn(i,!0),{ref:t}),n)}),Rh=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]},hz,Rfe;function cNt(){if(Rfe)return hz;Rfe=1;function e(t,n,r){var i=-1,o=t.length;n<0&&(n=-n>o?0:o+n),r=r>o?o:r,r<0&&(r+=o),o=n>r?0:r-n>>>0,n>>>=0;for(var s=Array(o);++i<o;)s[i]=t[i+n];return s}return hz=e,hz}var pz,Mfe;function dNt(){if(Mfe)return pz;Mfe=1;var e=cNt();function t(n,r,i){var o=n.length;return i=i===void 0?o:i,!r&&i>=o?n:e(n,r,i)}return pz=t,pz}var mz,_fe;function nLe(){if(_fe)return mz;_fe=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",i=t+n+r,o="\\ufe0e\\ufe0f",s="\\u200d",a=RegExp("["+s+e+i+o+"]");function l(u){return a.test(u)}return mz=l,mz}var gz,Nfe;function fNt(){if(Nfe)return gz;Nfe=1;function e(t){return t.split("")}return gz=e,gz}var yz,Lfe;function hNt(){if(Lfe)return yz;Lfe=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",i=t+n+r,o="\\ufe0e\\ufe0f",s="["+e+"]",a="["+i+"]",l="\\ud83c[\\udffb-\\udfff]",u="(?:"+a+"|"+l+")",c="[^"+e+"]",d="(?:\\ud83c[\\udde6-\\uddff]){2}",h="[\\ud800-\\udbff][\\udc00-\\udfff]",m="\\u200d",g=u+"?",b="["+o+"]?",v="(?:"+m+"(?:"+[c,d,h].join("|")+")"+b+g+")*",w=b+g+v,S="(?:"+[c+a+"?",a,d,h,s].join("|")+")",C=RegExp(l+"(?="+l+")|"+S+w,"g");function E(T){return T.match(C)||[]}return yz=E,yz}var bz,Ife;function pNt(){if(Ife)return bz;Ife=1;var e=fNt(),t=nLe(),n=hNt();function r(i){return t(i)?n(i):e(i)}return bz=r,bz}var vz,Pfe;function mNt(){if(Pfe)return vz;Pfe=1;var e=dNt(),t=nLe(),n=pNt(),r=QNe();function i(o){return function(s){s=r(s);var a=t(s)?n(s):void 0,l=a?a[0]:s.charAt(0),u=a?e(a,1).join(""):s.slice(1);return l[o]()+u}}return vz=i,vz}var xz,jfe;function gNt(){if(jfe)return xz;jfe=1;var e=mNt(),t=e("toUpperCase");return xz=t,xz}var yNt=gNt();const vD=cr(yNt);function sT(e){"@babel/helpers - typeof";return sT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},sT(e)}var bNt=["type","size","sizeType"];function WV(){return WV=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},WV.apply(this,arguments)}function Dfe(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 $fe(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Dfe(Object(n),!0).forEach(function(r){vNt(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Dfe(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function vNt(e,t,n){return t=xNt(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function xNt(e){var t=wNt(e,"string");return sT(t)=="symbol"?t:t+""}function wNt(e,t){if(sT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(sT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function SNt(e,t){if(e==null)return{};var n=kNt(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function kNt(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var rLe={symbolCircle:_Y,symbolCross:ixt,symbolDiamond:sxt,symbolSquare:axt,symbolStar:dxt,symbolTriangle:fxt,symbolWye:pxt},CNt=Math.PI/180,ENt=function(t){var n="symbol".concat(vD(t));return rLe[n]||_Y},TNt=function(t,n,r){if(n==="area")return t;switch(r){case"cross":return 5*t*t/9;case"diamond":return .5*t*t/Math.sqrt(3);case"square":return t*t;case"star":{var i=18*CNt;return 1.25*t*t*(Math.tan(i)-Math.tan(i*2)*Math.pow(Math.tan(i),2))}case"triangle":return Math.sqrt(3)*t*t/4;case"wye":return(21-10*Math.sqrt(3))*t*t/8;default:return Math.PI*t*t/4}},ANt=function(t,n){rLe["symbol".concat(vD(t))]=n},JX=function(t){var n=t.type,r=n===void 0?"circle":n,i=t.size,o=i===void 0?64:i,s=t.sizeType,a=s===void 0?"area":s,l=SNt(t,bNt),u=$fe($fe({},l),{},{type:r,size:o,sizeType:a}),c=function(){var v=ENt(r),w=mxt().type(v).size(TNt(o,a,r));return w()},d=u.className,h=u.cx,m=u.cy,g=wn(u,!0);return h===+h&&m===+m&&o===+o?we.createElement("path",WV({},g,{className:Hn("recharts-symbols",d),transform:"translate(".concat(h,", ").concat(m,")"),d:c()})):null};JX.registerSymbol=ANt;function lw(e){"@babel/helpers - typeof";return lw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},lw(e)}function qV(){return qV=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},qV.apply(this,arguments)}function zfe(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 ONt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?zfe(Object(n),!0).forEach(function(r){aT(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zfe(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function RNt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function MNt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,oLe(r.key),r)}}function _Nt(e,t,n){return t&&MNt(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function NNt(e,t,n){return t=pI(t),LNt(e,iLe()?Reflect.construct(t,n||[],pI(e).constructor):t.apply(e,n))}function LNt(e,t){if(t&&(lw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return INt(e)}function INt(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function iLe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(iLe=function(){return!!e})()}function pI(e){return pI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},pI(e)}function PNt(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&GV(e,t)}function GV(e,t){return GV=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},GV(e,t)}function aT(e,t,n){return t=oLe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function oLe(e){var t=jNt(e,"string");return lw(t)=="symbol"?t:t+""}function jNt(e,t){if(lw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(lw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Ml=32,eQ=(function(e){function t(){return RNt(this,t),NNt(this,t,arguments)}return PNt(t,e),_Nt(t,[{key:"renderIcon",value:function(r){var i=this.props.inactiveColor,o=Ml/2,s=Ml/6,a=Ml/3,l=r.inactive?i:r.color;if(r.type==="plainline")return we.createElement("line",{strokeWidth:4,fill:"none",stroke:l,strokeDasharray:r.payload.strokeDasharray,x1:0,y1:o,x2:Ml,y2:o,className:"recharts-legend-icon"});if(r.type==="line")return we.createElement("path",{strokeWidth:4,fill:"none",stroke:l,d:"M0,".concat(o,"h").concat(a,`
2852
+ */var bfe;function j_t(){if(bfe)return br;bfe=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),s=Symbol.for("react.context"),a=Symbol.for("react.server_context"),l=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),c=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),m=Symbol.for("react.offscreen"),g;g=Symbol.for("react.module.reference");function b(v){if(typeof v=="object"&&v!==null){var w=v.$$typeof;switch(w){case e:switch(v=v.type,v){case n:case i:case r:case u:case c:return v;default:switch(v=v&&v.$$typeof,v){case a:case s:case l:case h:case d:case o:return v;default:return w}}case t:return w}}}return br.ContextConsumer=s,br.ContextProvider=o,br.Element=e,br.ForwardRef=l,br.Fragment=n,br.Lazy=h,br.Memo=d,br.Portal=t,br.Profiler=i,br.StrictMode=r,br.Suspense=u,br.SuspenseList=c,br.isAsyncMode=function(){return!1},br.isConcurrentMode=function(){return!1},br.isContextConsumer=function(v){return b(v)===s},br.isContextProvider=function(v){return b(v)===o},br.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===e},br.isForwardRef=function(v){return b(v)===l},br.isFragment=function(v){return b(v)===n},br.isLazy=function(v){return b(v)===h},br.isMemo=function(v){return b(v)===d},br.isPortal=function(v){return b(v)===t},br.isProfiler=function(v){return b(v)===i},br.isStrictMode=function(v){return b(v)===r},br.isSuspense=function(v){return b(v)===u},br.isSuspenseList=function(v){return b(v)===c},br.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===n||v===i||v===r||v===u||v===c||v===m||typeof v=="object"&&v!==null&&(v.$$typeof===h||v.$$typeof===d||v.$$typeof===o||v.$$typeof===s||v.$$typeof===l||v.$$typeof===g||v.getModuleId!==void 0)},br.typeOf=b,br}var vfe;function D_t(){return vfe||(vfe=1,lz.exports=j_t()),lz.exports}var $_t=D_t(),uz,xfe;function eLe(){if(xfe)return uz;xfe=1;var e=Zh(),t=Jh(),n="[object Number]";function r(i){return typeof i=="number"||t(i)&&e(i)==n}return uz=r,uz}var cz,wfe;function z_t(){if(wfe)return cz;wfe=1;var e=eLe();function t(n){return e(n)&&n!=+n}return cz=t,cz}var F_t=z_t();const dS=cr(F_t);var B_t=eLe();const H_t=cr(B_t);var Xu=function(t){return t===0?0:t>0?1:-1},ay=function(t){return vb(t)&&t.indexOf("%")===t.length-1},ft=function(t){return H_t(t)&&!dS(t)},U_t=function(t){return Rn(t)},ho=function(t){return ft(t)||vb(t)},V_t=0,fS=function(t){var n=++V_t;return"".concat(t||"").concat(n)},xb=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(!ft(t)&&!vb(t))return r;var o;if(ay(t)){var s=t.indexOf("%");o=n*parseFloat(t.slice(0,s))/100}else o=+t;return dS(o)&&(o=r),i&&o>n&&(o=n),o},cm=function(t){if(!t)return null;var n=Object.keys(t);return n&&n.length?t[n[0]]:null},W_t=function(t){if(!Array.isArray(t))return!1;for(var n=t.length,r={},i=0;i<n;i++)if(!r[t[i]])r[t[i]]=!0;else return!0;return!1},is=function(t,n){return ft(t)&&ft(n)?function(r){return t+r*(n-t)}:function(){return n}};function dI(e,t,n){return!e||!e.length?null:e.find(function(r){return r&&(typeof t=="function"?t(r):au(r,t))===n})}var q_t=function(t,n){return ft(t)&&ft(n)?t-n:vb(t)&&vb(n)?t.localeCompare(n):t instanceof Date&&n instanceof Date?t.getTime()-n.getTime():String(t).localeCompare(String(n))};function V1(e,t){for(var n in e)if({}.hasOwnProperty.call(e,n)&&(!{}.hasOwnProperty.call(t,n)||e[n]!==t[n]))return!1;for(var r in t)if({}.hasOwnProperty.call(t,r)&&!{}.hasOwnProperty.call(e,r))return!1;return!0}function zV(e){"@babel/helpers - typeof";return zV=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},zV(e)}var G_t=["viewBox","children"],K_t=["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"],Sfe=["points","pathLength"],dz={svg:G_t,polygon:Sfe,polyline:Sfe},QX=["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"],fI=function(t,n){if(!t||typeof t=="function"||typeof t=="boolean")return null;var r=t;if(A.isValidElement(t)&&(r=t.props),!cS(r))return null;var i={};return Object.keys(r).forEach(function(o){QX.includes(o)&&(i[o]=n||function(s){return r[o](r,s)})}),i},Y_t=function(t,n,r){return function(i){return t(n,r,i),null}},hI=function(t,n,r){if(!cS(t)||zV(t)!=="object")return null;var i=null;return Object.keys(t).forEach(function(o){var s=t[o];QX.includes(o)&&typeof s=="function"&&(i||(i={}),i[o]=Y_t(s,n,r))}),i},X_t=["children"],Q_t=["children"];function kfe(e,t){if(e==null)return{};var n=Z_t(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Z_t(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function FV(e){"@babel/helpers - typeof";return FV=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},FV(e)}var Cfe={click:"onClick",mousedown:"onMouseDown",mouseup:"onMouseUp",mouseover:"onMouseOver",mousemove:"onMouseMove",mouseout:"onMouseOut",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",touchcancel:"onTouchCancel",touchend:"onTouchEnd",touchmove:"onTouchMove",touchstart:"onTouchStart",contextmenu:"onContextMenu",dblclick:"onDoubleClick"},Oh=function(t){return typeof t=="string"?t:t?t.displayName||t.name||"Component":""},Efe=null,fz=null,ZX=function e(t){if(t===Efe&&Array.isArray(fz))return fz;var n=[];return A.Children.forEach(t,function(r){Rn(r)||($_t.isFragment(r)?n=n.concat(e(r.props.children)):n.push(r))}),fz=n,Efe=t,n};function lu(e,t){var n=[],r=[];return Array.isArray(t)?r=t.map(function(i){return Oh(i)}):r=[Oh(t)],ZX(e).forEach(function(i){var o=au(i,"type.displayName")||au(i,"type.name");r.indexOf(o)!==-1&&n.push(i)}),n}function tl(e,t){var n=lu(e,t);return n&&n[0]}var Tfe=function(t){if(!t||!t.props)return!1;var n=t.props,r=n.width,i=n.height;return!(!ft(r)||r<=0||!ft(i)||i<=0)},J_t=["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColormatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-url","foreignObject","g","glyph","glyphRef","hkern","image","line","lineGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","script","set","stop","style","svg","switch","symbol","text","textPath","title","tref","tspan","use","view","vkern"],eNt=function(t){return t&&t.type&&vb(t.type)&&J_t.indexOf(t.type)>=0},tLe=function(t){return t&&FV(t)==="object"&&"clipDot"in t},tNt=function(t,n,r,i){var o,s=(o=dz==null?void 0:dz[i])!==null&&o!==void 0?o:[];return n.startsWith("data-")||!yn(t)&&(i&&s.includes(n)||K_t.includes(n))||r&&QX.includes(n)},wn=function(t,n,r){if(!t||typeof t=="function"||typeof t=="boolean")return null;var i=t;if(A.isValidElement(t)&&(i=t.props),!cS(i))return null;var o={};return Object.keys(i).forEach(function(s){var a;tNt((a=i)===null||a===void 0?void 0:a[s],s,n,r)&&(o[s]=i[s])}),o},BV=function e(t,n){if(t===n)return!0;var r=A.Children.count(t);if(r!==A.Children.count(n))return!1;if(r===0)return!0;if(r===1)return Afe(Array.isArray(t)?t[0]:t,Array.isArray(n)?n[0]:n);for(var i=0;i<r;i++){var o=t[i],s=n[i];if(Array.isArray(o)||Array.isArray(s)){if(!e(o,s))return!1}else if(!Afe(o,s))return!1}return!0},Afe=function(t,n){if(Rn(t)&&Rn(n))return!0;if(!Rn(t)&&!Rn(n)){var r=t.props||{},i=r.children,o=kfe(r,X_t),s=n.props||{},a=s.children,l=kfe(s,Q_t);return i&&a?V1(o,l)&&BV(i,a):!i&&!a?V1(o,l):!1}return!1},Ofe=function(t,n){var r=[],i={};return ZX(t).forEach(function(o,s){if(eNt(o))r.push(o);else if(o){var a=Oh(o.type),l=n[a]||{},u=l.handler,c=l.once;if(u&&(!c||!i[a])){var d=u(o,a,s);r.push(d),i[a]=!0}}}),r},nNt=function(t){var n=t&&t.type;return n&&Cfe[n]?Cfe[n]:null},rNt=function(t,n){return ZX(n).indexOf(t)},iNt=["children","width","height","viewBox","className","style","title","desc"];function HV(){return HV=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},HV.apply(this,arguments)}function oNt(e,t){if(e==null)return{};var n=sNt(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function sNt(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function UV(e){var t=e.children,n=e.width,r=e.height,i=e.viewBox,o=e.className,s=e.style,a=e.title,l=e.desc,u=oNt(e,iNt),c=i||{width:n,height:r,x:0,y:0},d=Hn("recharts-surface",o);return we.createElement("svg",HV({},wn(u,!0,"svg"),{className:d,width:n,height:r,style:s,viewBox:"".concat(c.x," ").concat(c.y," ").concat(c.width," ").concat(c.height)}),we.createElement("title",null,a),we.createElement("desc",null,l),t)}var aNt=["children","className"];function VV(){return VV=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},VV.apply(this,arguments)}function lNt(e,t){if(e==null)return{};var n=uNt(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function uNt(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var Yr=we.forwardRef(function(e,t){var n=e.children,r=e.className,i=lNt(e,aNt),o=Hn("recharts-layer",r);return we.createElement("g",VV({className:o},wn(i,!0),{ref:t}),n)}),Rh=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]},hz,Rfe;function cNt(){if(Rfe)return hz;Rfe=1;function e(t,n,r){var i=-1,o=t.length;n<0&&(n=-n>o?0:o+n),r=r>o?o:r,r<0&&(r+=o),o=n>r?0:r-n>>>0,n>>>=0;for(var s=Array(o);++i<o;)s[i]=t[i+n];return s}return hz=e,hz}var pz,Mfe;function dNt(){if(Mfe)return pz;Mfe=1;var e=cNt();function t(n,r,i){var o=n.length;return i=i===void 0?o:i,!r&&i>=o?n:e(n,r,i)}return pz=t,pz}var mz,_fe;function nLe(){if(_fe)return mz;_fe=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",i=t+n+r,o="\\ufe0e\\ufe0f",s="\\u200d",a=RegExp("["+s+e+i+o+"]");function l(u){return a.test(u)}return mz=l,mz}var gz,Nfe;function fNt(){if(Nfe)return gz;Nfe=1;function e(t){return t.split("")}return gz=e,gz}var yz,Lfe;function hNt(){if(Lfe)return yz;Lfe=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",i=t+n+r,o="\\ufe0e\\ufe0f",s="["+e+"]",a="["+i+"]",l="\\ud83c[\\udffb-\\udfff]",u="(?:"+a+"|"+l+")",c="[^"+e+"]",d="(?:\\ud83c[\\udde6-\\uddff]){2}",h="[\\ud800-\\udbff][\\udc00-\\udfff]",m="\\u200d",g=u+"?",b="["+o+"]?",v="(?:"+m+"(?:"+[c,d,h].join("|")+")"+b+g+")*",w=b+g+v,S="(?:"+[c+a+"?",a,d,h,s].join("|")+")",C=RegExp(l+"(?="+l+")|"+S+w,"g");function E(T){return T.match(C)||[]}return yz=E,yz}var bz,Ife;function pNt(){if(Ife)return bz;Ife=1;var e=fNt(),t=nLe(),n=hNt();function r(i){return t(i)?n(i):e(i)}return bz=r,bz}var vz,Pfe;function mNt(){if(Pfe)return vz;Pfe=1;var e=dNt(),t=nLe(),n=pNt(),r=QNe();function i(o){return function(s){s=r(s);var a=t(s)?n(s):void 0,l=a?a[0]:s.charAt(0),u=a?e(a,1).join(""):s.slice(1);return l[o]()+u}}return vz=i,vz}var xz,jfe;function gNt(){if(jfe)return xz;jfe=1;var e=mNt(),t=e("toUpperCase");return xz=t,xz}var yNt=gNt();const vD=cr(yNt);function sT(e){"@babel/helpers - typeof";return sT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},sT(e)}var bNt=["type","size","sizeType"];function WV(){return WV=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},WV.apply(this,arguments)}function Dfe(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 $fe(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Dfe(Object(n),!0).forEach(function(r){vNt(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Dfe(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function vNt(e,t,n){return t=xNt(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function xNt(e){var t=wNt(e,"string");return sT(t)=="symbol"?t:t+""}function wNt(e,t){if(sT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(sT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function SNt(e,t){if(e==null)return{};var n=kNt(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function kNt(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var rLe={symbolCircle:NY,symbolCross:pxt,symbolDiamond:gxt,symbolSquare:yxt,symbolStar:wxt,symbolTriangle:Sxt,symbolWye:Cxt},CNt=Math.PI/180,ENt=function(t){var n="symbol".concat(vD(t));return rLe[n]||NY},TNt=function(t,n,r){if(n==="area")return t;switch(r){case"cross":return 5*t*t/9;case"diamond":return .5*t*t/Math.sqrt(3);case"square":return t*t;case"star":{var i=18*CNt;return 1.25*t*t*(Math.tan(i)-Math.tan(i*2)*Math.pow(Math.tan(i),2))}case"triangle":return Math.sqrt(3)*t*t/4;case"wye":return(21-10*Math.sqrt(3))*t*t/8;default:return Math.PI*t*t/4}},ANt=function(t,n){rLe["symbol".concat(vD(t))]=n},JX=function(t){var n=t.type,r=n===void 0?"circle":n,i=t.size,o=i===void 0?64:i,s=t.sizeType,a=s===void 0?"area":s,l=SNt(t,bNt),u=$fe($fe({},l),{},{type:r,size:o,sizeType:a}),c=function(){var v=ENt(r),w=Ext().type(v).size(TNt(o,a,r));return w()},d=u.className,h=u.cx,m=u.cy,g=wn(u,!0);return h===+h&&m===+m&&o===+o?we.createElement("path",WV({},g,{className:Hn("recharts-symbols",d),transform:"translate(".concat(h,", ").concat(m,")"),d:c()})):null};JX.registerSymbol=ANt;function lw(e){"@babel/helpers - typeof";return lw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},lw(e)}function qV(){return qV=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},qV.apply(this,arguments)}function zfe(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 ONt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?zfe(Object(n),!0).forEach(function(r){aT(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zfe(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function RNt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function MNt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,oLe(r.key),r)}}function _Nt(e,t,n){return t&&MNt(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function NNt(e,t,n){return t=pI(t),LNt(e,iLe()?Reflect.construct(t,n||[],pI(e).constructor):t.apply(e,n))}function LNt(e,t){if(t&&(lw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return INt(e)}function INt(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function iLe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(iLe=function(){return!!e})()}function pI(e){return pI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},pI(e)}function PNt(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&GV(e,t)}function GV(e,t){return GV=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},GV(e,t)}function aT(e,t,n){return t=oLe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function oLe(e){var t=jNt(e,"string");return lw(t)=="symbol"?t:t+""}function jNt(e,t){if(lw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(lw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Ml=32,eQ=(function(e){function t(){return RNt(this,t),NNt(this,t,arguments)}return PNt(t,e),_Nt(t,[{key:"renderIcon",value:function(r){var i=this.props.inactiveColor,o=Ml/2,s=Ml/6,a=Ml/3,l=r.inactive?i:r.color;if(r.type==="plainline")return we.createElement("line",{strokeWidth:4,fill:"none",stroke:l,strokeDasharray:r.payload.strokeDasharray,x1:0,y1:o,x2:Ml,y2:o,className:"recharts-legend-icon"});if(r.type==="line")return we.createElement("path",{strokeWidth:4,fill:"none",stroke:l,d:"M0,".concat(o,"h").concat(a,`
2853
2853
  A`).concat(s,",").concat(s,",0,1,1,").concat(2*a,",").concat(o,`
2854
2854
  H`).concat(Ml,"M").concat(2*a,",").concat(o,`
2855
- A`).concat(s,",").concat(s,",0,1,1,").concat(a,",").concat(o),className:"recharts-legend-icon"});if(r.type==="rect")return we.createElement("path",{stroke:"none",fill:l,d:"M0,".concat(Ml/8,"h").concat(Ml,"v").concat(Ml*3/4,"h").concat(-Ml,"z"),className:"recharts-legend-icon"});if(we.isValidElement(r.legendIcon)){var u=ONt({},r);return delete u.legendIcon,we.cloneElement(r.legendIcon,u)}return we.createElement(JX,{fill:l,cx:o,cy:o,size:Ml,sizeType:"diameter",type:r.type})}},{key:"renderItems",value:function(){var r=this,i=this.props,o=i.payload,s=i.iconSize,a=i.layout,l=i.formatter,u=i.inactiveColor,c={x:0,y:0,width:Ml,height:Ml},d={display:a==="horizontal"?"inline-block":"block",marginRight:10},h={display:"inline-block",verticalAlign:"middle",marginRight:4};return o.map(function(m,g){var b=m.formatter||l,v=Hn(aT(aT({"recharts-legend-item":!0},"legend-item-".concat(g),!0),"inactive",m.inactive));if(m.type==="none")return null;var w=yn(m.value)?null:m.value;Rh(!yn(m.value),`The name property is also required when using a function for the dataKey of a chart's cartesian components. Ex: <Bar name="Name of my Data"/>`);var S=m.inactive?u:m.color;return we.createElement("li",qV({className:v,style:d,key:"legend-item-".concat(g)},hI(r.props,m,g)),we.createElement(UV,{width:s,height:s,viewBox:c,style:h},r.renderIcon(m)),we.createElement("span",{className:"recharts-legend-item-text",style:{color:S}},b?b(w,m,g):w))})}},{key:"render",value:function(){var r=this.props,i=r.payload,o=r.layout,s=r.align;if(!i||!i.length)return null;var a={padding:0,margin:0,textAlign:o==="horizontal"?s:"left"};return we.createElement("ul",{className:"recharts-default-legend",style:a},this.renderItems())}}])})(A.PureComponent);aT(eQ,"displayName","Legend");aT(eQ,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"middle",inactiveColor:"#ccc"});var wz,Ffe;function DNt(){if(Ffe)return wz;Ffe=1;var e=gD();function t(){this.__data__=new e,this.size=0}return wz=t,wz}var Sz,Bfe;function $Nt(){if(Bfe)return Sz;Bfe=1;function e(t){var n=this.__data__,r=n.delete(t);return this.size=n.size,r}return Sz=e,Sz}var kz,Hfe;function zNt(){if(Hfe)return kz;Hfe=1;function e(t){return this.__data__.get(t)}return kz=e,kz}var Cz,Ufe;function FNt(){if(Ufe)return Cz;Ufe=1;function e(t){return this.__data__.has(t)}return Cz=e,Cz}var Ez,Vfe;function BNt(){if(Vfe)return Ez;Vfe=1;var e=gD(),t=GX(),n=KX(),r=200;function i(o,s){var a=this.__data__;if(a instanceof e){var l=a.__data__;if(!t||l.length<r-1)return l.push([o,s]),this.size=++a.size,this;a=this.__data__=new n(l)}return a.set(o,s),this.size=a.size,this}return Ez=i,Ez}var Tz,Wfe;function sLe(){if(Wfe)return Tz;Wfe=1;var e=gD(),t=DNt(),n=$Nt(),r=zNt(),i=FNt(),o=BNt();function s(a){var l=this.__data__=new e(a);this.size=l.size}return s.prototype.clear=t,s.prototype.delete=n,s.prototype.get=r,s.prototype.has=i,s.prototype.set=o,Tz=s,Tz}var Az,qfe;function HNt(){if(qfe)return Az;qfe=1;var e="__lodash_hash_undefined__";function t(n){return this.__data__.set(n,e),this}return Az=t,Az}var Oz,Gfe;function UNt(){if(Gfe)return Oz;Gfe=1;function e(t){return this.__data__.has(t)}return Oz=e,Oz}var Rz,Kfe;function aLe(){if(Kfe)return Rz;Kfe=1;var e=KX(),t=HNt(),n=UNt();function r(i){var o=-1,s=i==null?0:i.length;for(this.__data__=new e;++o<s;)this.add(i[o])}return r.prototype.add=r.prototype.push=t,r.prototype.has=n,Rz=r,Rz}var Mz,Yfe;function lLe(){if(Yfe)return Mz;Yfe=1;function e(t,n){for(var r=-1,i=t==null?0:t.length;++r<i;)if(n(t[r],r,t))return!0;return!1}return Mz=e,Mz}var _z,Xfe;function uLe(){if(Xfe)return _z;Xfe=1;function e(t,n){return t.has(n)}return _z=e,_z}var Nz,Qfe;function cLe(){if(Qfe)return Nz;Qfe=1;var e=aLe(),t=lLe(),n=uLe(),r=1,i=2;function o(s,a,l,u,c,d){var h=l&r,m=s.length,g=a.length;if(m!=g&&!(h&&g>m))return!1;var b=d.get(s),v=d.get(a);if(b&&v)return b==a&&v==s;var w=-1,S=!0,C=l&i?new e:void 0;for(d.set(s,a),d.set(a,s);++w<m;){var E=s[w],T=a[w];if(u)var O=h?u(T,E,w,a,s,d):u(E,T,w,s,a,d);if(O!==void 0){if(O)continue;S=!1;break}if(C){if(!t(a,function(M,N){if(!n(C,N)&&(E===M||c(E,M,l,u,d)))return C.push(N)})){S=!1;break}}else if(!(E===T||c(E,T,l,u,d))){S=!1;break}}return d.delete(s),d.delete(a),S}return Nz=o,Nz}var Lz,Zfe;function VNt(){if(Zfe)return Lz;Zfe=1;var e=Hd(),t=e.Uint8Array;return Lz=t,Lz}var Iz,Jfe;function WNt(){if(Jfe)return Iz;Jfe=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(i,o){r[++n]=[o,i]}),r}return Iz=e,Iz}var Pz,ehe;function tQ(){if(ehe)return Pz;ehe=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(i){r[++n]=i}),r}return Pz=e,Pz}var jz,the;function qNt(){if(the)return jz;the=1;var e=SA(),t=VNt(),n=qX(),r=cLe(),i=WNt(),o=tQ(),s=1,a=2,l="[object Boolean]",u="[object Date]",c="[object Error]",d="[object Map]",h="[object Number]",m="[object RegExp]",g="[object Set]",b="[object String]",v="[object Symbol]",w="[object ArrayBuffer]",S="[object DataView]",C=e?e.prototype:void 0,E=C?C.valueOf:void 0;function T(O,M,N,I,D,P,F){switch(N){case S:if(O.byteLength!=M.byteLength||O.byteOffset!=M.byteOffset)return!1;O=O.buffer,M=M.buffer;case w:return!(O.byteLength!=M.byteLength||!P(new t(O),new t(M)));case l:case u:case h:return n(+O,+M);case c:return O.name==M.name&&O.message==M.message;case m:case b:return O==M+"";case d:var z=i;case g:var $=I&s;if(z||(z=o),O.size!=M.size&&!$)return!1;var B=F.get(O);if(B)return B==M;I|=a,F.set(O,M);var H=r(z(O),z(M),I,D,P,F);return F.delete(O),H;case v:if(E)return E.call(O)==E.call(M)}return!1}return jz=T,jz}var Dz,nhe;function dLe(){if(nhe)return Dz;nhe=1;function e(t,n){for(var r=-1,i=n.length,o=t.length;++r<i;)t[o+r]=n[r];return t}return Dz=e,Dz}var $z,rhe;function GNt(){if(rhe)return $z;rhe=1;var e=dLe(),t=Na();function n(r,i,o){var s=i(r);return t(r)?s:e(s,o(r))}return $z=n,$z}var zz,ihe;function KNt(){if(ihe)return zz;ihe=1;function e(t,n){for(var r=-1,i=t==null?0:t.length,o=0,s=[];++r<i;){var a=t[r];n(a,r,t)&&(s[o++]=a)}return s}return zz=e,zz}var Fz,ohe;function YNt(){if(ohe)return Fz;ohe=1;function e(){return[]}return Fz=e,Fz}var Bz,she;function XNt(){if(she)return Bz;she=1;var e=KNt(),t=YNt(),n=Object.prototype,r=n.propertyIsEnumerable,i=Object.getOwnPropertySymbols,o=i?function(s){return s==null?[]:(s=Object(s),e(i(s),function(a){return r.call(s,a)}))}:t;return Bz=o,Bz}var Hz,ahe;function QNt(){if(ahe)return Hz;ahe=1;function e(t,n){for(var r=-1,i=Array(t);++r<t;)i[r]=n(r);return i}return Hz=e,Hz}var Uz,lhe;function ZNt(){if(lhe)return Uz;lhe=1;var e=Jh(),t=ep(),n="[object Arguments]";function r(i){return t(i)&&e(i)==n}return Uz=r,Uz}var Vz,uhe;function nQ(){if(uhe)return Vz;uhe=1;var e=ZNt(),t=ep(),n=Object.prototype,r=n.hasOwnProperty,i=n.propertyIsEnumerable,o=e((function(){return arguments})())?e:function(s){return t(s)&&r.call(s,"callee")&&!i.call(s,"callee")};return Vz=o,Vz}var hC={exports:{}},Wz,che;function JNt(){if(che)return Wz;che=1;function e(){return!1}return Wz=e,Wz}hC.exports;var dhe;function fLe(){return dhe||(dhe=1,(function(e,t){var n=Hd(),r=JNt(),i=t&&!t.nodeType&&t,o=i&&!0&&e&&!e.nodeType&&e,s=o&&o.exports===i,a=s?n.Buffer:void 0,l=a?a.isBuffer:void 0,u=l||r;e.exports=u})(hC,hC.exports)),hC.exports}var qz,fhe;function rQ(){if(fhe)return qz;fhe=1;var e=9007199254740991,t=/^(?:0|[1-9]\d*)$/;function n(r,i){var o=typeof r;return i=i??e,!!i&&(o=="number"||o!="symbol"&&t.test(r))&&r>-1&&r%1==0&&r<i}return qz=n,qz}var Gz,hhe;function iQ(){if(hhe)return Gz;hhe=1;var e=9007199254740991;function t(n){return typeof n=="number"&&n>-1&&n%1==0&&n<=e}return Gz=t,Gz}var Kz,phe;function eLt(){if(phe)return Kz;phe=1;var e=Jh(),t=iQ(),n=ep(),r="[object Arguments]",i="[object Array]",o="[object Boolean]",s="[object Date]",a="[object Error]",l="[object Function]",u="[object Map]",c="[object Number]",d="[object Object]",h="[object RegExp]",m="[object Set]",g="[object String]",b="[object WeakMap]",v="[object ArrayBuffer]",w="[object DataView]",S="[object Float32Array]",C="[object Float64Array]",E="[object Int8Array]",T="[object Int16Array]",O="[object Int32Array]",M="[object Uint8Array]",N="[object Uint8ClampedArray]",I="[object Uint16Array]",D="[object Uint32Array]",P={};P[S]=P[C]=P[E]=P[T]=P[O]=P[M]=P[N]=P[I]=P[D]=!0,P[r]=P[i]=P[v]=P[o]=P[w]=P[s]=P[a]=P[l]=P[u]=P[c]=P[d]=P[h]=P[m]=P[g]=P[b]=!1;function F(z){return n(z)&&t(z.length)&&!!P[e(z)]}return Kz=F,Kz}var Yz,mhe;function hLe(){if(mhe)return Yz;mhe=1;function e(t){return function(n){return t(n)}}return Yz=e,Yz}var pC={exports:{}};pC.exports;var ghe;function tLt(){return ghe||(ghe=1,(function(e,t){var n=xNe(),r=t&&!t.nodeType&&t,i=r&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===r,s=o&&n.process,a=(function(){try{var l=i&&i.require&&i.require("util").types;return l||s&&s.binding&&s.binding("util")}catch{}})();e.exports=a})(pC,pC.exports)),pC.exports}var Xz,yhe;function pLe(){if(yhe)return Xz;yhe=1;var e=eLt(),t=hLe(),n=tLt(),r=n&&n.isTypedArray,i=r?t(r):e;return Xz=i,Xz}var Qz,bhe;function nLt(){if(bhe)return Qz;bhe=1;var e=QNt(),t=nQ(),n=Na(),r=fLe(),i=rQ(),o=pLe(),s=Object.prototype,a=s.hasOwnProperty;function l(u,c){var d=n(u),h=!d&&t(u),m=!d&&!h&&r(u),g=!d&&!h&&!m&&o(u),b=d||h||m||g,v=b?e(u.length,String):[],w=v.length;for(var S in u)(c||a.call(u,S))&&!(b&&(S=="length"||m&&(S=="offset"||S=="parent")||g&&(S=="buffer"||S=="byteLength"||S=="byteOffset")||i(S,w)))&&v.push(S);return v}return Qz=l,Qz}var Zz,vhe;function rLt(){if(vhe)return Zz;vhe=1;var e=Object.prototype;function t(n){var r=n&&n.constructor,i=typeof r=="function"&&r.prototype||e;return n===i}return Zz=t,Zz}var Jz,xhe;function mLe(){if(xhe)return Jz;xhe=1;function e(t,n){return function(r){return t(n(r))}}return Jz=e,Jz}var eF,whe;function iLt(){if(whe)return eF;whe=1;var e=mLe(),t=e(Object.keys,Object);return eF=t,eF}var tF,She;function oLt(){if(She)return tF;She=1;var e=rLt(),t=iLt(),n=Object.prototype,r=n.hasOwnProperty;function i(o){if(!e(o))return t(o);var s=[];for(var a in Object(o))r.call(o,a)&&a!="constructor"&&s.push(a);return s}return tF=i,tF}var nF,khe;function CA(){if(khe)return nF;khe=1;var e=WX(),t=iQ();function n(r){return r!=null&&t(r.length)&&!e(r)}return nF=n,nF}var rF,Che;function xD(){if(Che)return rF;Che=1;var e=nLt(),t=oLt(),n=CA();function r(i){return n(i)?e(i):t(i)}return rF=r,rF}var iF,Ehe;function sLt(){if(Ehe)return iF;Ehe=1;var e=GNt(),t=XNt(),n=xD();function r(i){return e(i,n,t)}return iF=r,iF}var oF,The;function aLt(){if(The)return oF;The=1;var e=sLt(),t=1,n=Object.prototype,r=n.hasOwnProperty;function i(o,s,a,l,u,c){var d=a&t,h=e(o),m=h.length,g=e(s),b=g.length;if(m!=b&&!d)return!1;for(var v=m;v--;){var w=h[v];if(!(d?w in s:r.call(s,w)))return!1}var S=c.get(o),C=c.get(s);if(S&&C)return S==s&&C==o;var E=!0;c.set(o,s),c.set(s,o);for(var T=d;++v<m;){w=h[v];var O=o[w],M=s[w];if(l)var N=d?l(M,O,w,s,o,c):l(O,M,w,o,s,c);if(!(N===void 0?O===M||u(O,M,a,l,c):N)){E=!1;break}T||(T=w=="constructor")}if(E&&!T){var I=o.constructor,D=s.constructor;I!=D&&"constructor"in o&&"constructor"in s&&!(typeof I=="function"&&I instanceof I&&typeof D=="function"&&D instanceof D)&&(E=!1)}return c.delete(o),c.delete(s),E}return oF=i,oF}var sF,Ahe;function lLt(){if(Ahe)return sF;Ahe=1;var e=zb(),t=Hd(),n=e(t,"DataView");return sF=n,sF}var aF,Ohe;function uLt(){if(Ohe)return aF;Ohe=1;var e=zb(),t=Hd(),n=e(t,"Promise");return aF=n,aF}var lF,Rhe;function gLe(){if(Rhe)return lF;Rhe=1;var e=zb(),t=Hd(),n=e(t,"Set");return lF=n,lF}var uF,Mhe;function cLt(){if(Mhe)return uF;Mhe=1;var e=zb(),t=Hd(),n=e(t,"WeakMap");return uF=n,uF}var cF,_he;function dLt(){if(_he)return cF;_he=1;var e=lLt(),t=GX(),n=uLt(),r=gLe(),i=cLt(),o=Jh(),s=YNe(),a="[object Map]",l="[object Object]",u="[object Promise]",c="[object Set]",d="[object WeakMap]",h="[object DataView]",m=s(e),g=s(t),b=s(n),v=s(r),w=s(i),S=o;return(e&&S(new e(new ArrayBuffer(1)))!=h||t&&S(new t)!=a||n&&S(n.resolve())!=u||r&&S(new r)!=c||i&&S(new i)!=d)&&(S=function(C){var E=o(C),T=E==l?C.constructor:void 0,O=T?s(T):"";if(O)switch(O){case m:return h;case g:return a;case b:return u;case v:return c;case w:return d}return E}),cF=S,cF}var dF,Nhe;function fLt(){if(Nhe)return dF;Nhe=1;var e=sLe(),t=cLe(),n=qNt(),r=aLt(),i=dLt(),o=Na(),s=fLe(),a=pLe(),l=1,u="[object Arguments]",c="[object Array]",d="[object Object]",h=Object.prototype,m=h.hasOwnProperty;function g(b,v,w,S,C,E){var T=o(b),O=o(v),M=T?c:i(b),N=O?c:i(v);M=M==u?d:M,N=N==u?d:N;var I=M==d,D=N==d,P=M==N;if(P&&s(b)){if(!s(v))return!1;T=!0,I=!1}if(P&&!I)return E||(E=new e),T||a(b)?t(b,v,w,S,C,E):n(b,v,M,w,S,C,E);if(!(w&l)){var F=I&&m.call(b,"__wrapped__"),z=D&&m.call(v,"__wrapped__");if(F||z){var $=F?b.value():b,B=z?v.value():v;return E||(E=new e),C($,B,w,S,E)}}return P?(E||(E=new e),r(b,v,w,S,C,E)):!1}return dF=g,dF}var fF,Lhe;function oQ(){if(Lhe)return fF;Lhe=1;var e=fLt(),t=ep();function n(r,i,o,s,a){return r===i?!0:r==null||i==null||!t(r)&&!t(i)?r!==r&&i!==i:e(r,i,o,s,n,a)}return fF=n,fF}var hF,Ihe;function hLt(){if(Ihe)return hF;Ihe=1;var e=sLe(),t=oQ(),n=1,r=2;function i(o,s,a,l){var u=a.length,c=u,d=!l;if(o==null)return!c;for(o=Object(o);u--;){var h=a[u];if(d&&h[2]?h[1]!==o[h[0]]:!(h[0]in o))return!1}for(;++u<c;){h=a[u];var m=h[0],g=o[m],b=h[1];if(d&&h[2]){if(g===void 0&&!(m in o))return!1}else{var v=new e;if(l)var w=l(g,b,m,o,s,v);if(!(w===void 0?t(b,g,n|r,l,v):w))return!1}}return!0}return hF=i,hF}var pF,Phe;function yLe(){if(Phe)return pF;Phe=1;var e=Vg();function t(n){return n===n&&!e(n)}return pF=t,pF}var mF,jhe;function pLt(){if(jhe)return mF;jhe=1;var e=yLe(),t=xD();function n(r){for(var i=t(r),o=i.length;o--;){var s=i[o],a=r[s];i[o]=[s,a,e(a)]}return i}return mF=n,mF}var gF,Dhe;function bLe(){if(Dhe)return gF;Dhe=1;function e(t,n){return function(r){return r==null?!1:r[t]===n&&(n!==void 0||t in Object(r))}}return gF=e,gF}var yF,$he;function mLt(){if($he)return yF;$he=1;var e=hLt(),t=pLt(),n=bLe();function r(i){var o=t(i);return o.length==1&&o[0][2]?n(o[0][0],o[0][1]):function(s){return s===i||e(s,i,o)}}return yF=r,yF}var bF,zhe;function gLt(){if(zhe)return bF;zhe=1;function e(t,n){return t!=null&&n in Object(t)}return bF=e,bF}var vF,Fhe;function yLt(){if(Fhe)return vF;Fhe=1;var e=ZNe(),t=nQ(),n=Na(),r=rQ(),i=iQ(),o=bD();function s(a,l,u){l=e(l,a);for(var c=-1,d=l.length,h=!1;++c<d;){var m=o(l[c]);if(!(h=a!=null&&u(a,m)))break;a=a[m]}return h||++c!=d?h:(d=a==null?0:a.length,!!d&&i(d)&&r(m,d)&&(n(a)||t(a)))}return vF=s,vF}var xF,Bhe;function bLt(){if(Bhe)return xF;Bhe=1;var e=gLt(),t=yLt();function n(r,i){return r!=null&&t(r,i,e)}return xF=n,xF}var wF,Hhe;function vLt(){if(Hhe)return wF;Hhe=1;var e=oQ(),t=JNe(),n=bLt(),r=VX(),i=yLe(),o=bLe(),s=bD(),a=1,l=2;function u(c,d){return r(c)&&i(d)?o(s(c),d):function(h){var m=t(h,c);return m===void 0&&m===d?n(h,c):e(d,m,a|l)}}return wF=u,wF}var SF,Uhe;function hS(){if(Uhe)return SF;Uhe=1;function e(t){return t}return SF=e,SF}var kF,Vhe;function xLt(){if(Vhe)return kF;Vhe=1;function e(t){return function(n){return n==null?void 0:n[t]}}return kF=e,kF}var CF,Whe;function wLt(){if(Whe)return CF;Whe=1;var e=XX();function t(n){return function(r){return e(r,n)}}return CF=t,CF}var EF,qhe;function SLt(){if(qhe)return EF;qhe=1;var e=xLt(),t=wLt(),n=VX(),r=bD();function i(o){return n(o)?e(r(o)):t(o)}return EF=i,EF}var TF,Ghe;function Wg(){if(Ghe)return TF;Ghe=1;var e=mLt(),t=vLt(),n=hS(),r=Na(),i=SLt();function o(s){return typeof s=="function"?s:s==null?n:typeof s=="object"?r(s)?t(s[0],s[1]):e(s):i(s)}return TF=o,TF}var AF,Khe;function vLe(){if(Khe)return AF;Khe=1;function e(t,n,r,i){for(var o=t.length,s=r+(i?1:-1);i?s--:++s<o;)if(n(t[s],s,t))return s;return-1}return AF=e,AF}var OF,Yhe;function kLt(){if(Yhe)return OF;Yhe=1;function e(t){return t!==t}return OF=e,OF}var RF,Xhe;function CLt(){if(Xhe)return RF;Xhe=1;function e(t,n,r){for(var i=r-1,o=t.length;++i<o;)if(t[i]===n)return i;return-1}return RF=e,RF}var MF,Qhe;function ELt(){if(Qhe)return MF;Qhe=1;var e=vLe(),t=kLt(),n=CLt();function r(i,o,s){return o===o?n(i,o,s):e(i,t,s)}return MF=r,MF}var _F,Zhe;function TLt(){if(Zhe)return _F;Zhe=1;var e=ELt();function t(n,r){var i=n==null?0:n.length;return!!i&&e(n,r,0)>-1}return _F=t,_F}var NF,Jhe;function ALt(){if(Jhe)return NF;Jhe=1;function e(t,n,r){for(var i=-1,o=t==null?0:t.length;++i<o;)if(r(n,t[i]))return!0;return!1}return NF=e,NF}var LF,epe;function OLt(){if(epe)return LF;epe=1;function e(){}return LF=e,LF}var IF,tpe;function RLt(){if(tpe)return IF;tpe=1;var e=gLe(),t=OLt(),n=tQ(),r=1/0,i=e&&1/n(new e([,-0]))[1]==r?function(o){return new e(o)}:t;return IF=i,IF}var PF,npe;function MLt(){if(npe)return PF;npe=1;var e=aLe(),t=TLt(),n=ALt(),r=uLe(),i=RLt(),o=tQ(),s=200;function a(l,u,c){var d=-1,h=t,m=l.length,g=!0,b=[],v=b;if(c)g=!1,h=n;else if(m>=s){var w=u?null:i(l);if(w)return o(w);g=!1,h=r,v=new e}else v=u?[]:b;e:for(;++d<m;){var S=l[d],C=u?u(S):S;if(S=c||S!==0?S:0,g&&C===C){for(var E=v.length;E--;)if(v[E]===C)continue e;u&&v.push(C),b.push(S)}else h(v,C,c)||(v!==b&&v.push(C),b.push(S))}return b}return PF=a,PF}var jF,rpe;function _Lt(){if(rpe)return jF;rpe=1;var e=Wg(),t=MLt();function n(r,i){return r&&r.length?t(r,e(i,2)):[]}return jF=n,jF}var NLt=_Lt();const ipe=cr(NLt);function xLe(e,t,n){return t===!0?ipe(e,n):yn(t)?ipe(e,t):e}function uw(e){"@babel/helpers - typeof";return uw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},uw(e)}var LLt=["ref"];function ope(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 bf(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ope(Object(n),!0).forEach(function(r){wD(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ope(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ILt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function spe(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,SLe(r.key),r)}}function PLt(e,t,n){return t&&spe(e.prototype,t),n&&spe(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function jLt(e,t,n){return t=mI(t),DLt(e,wLe()?Reflect.construct(t,n||[],mI(e).constructor):t.apply(e,n))}function DLt(e,t){if(t&&(uw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return $Lt(e)}function $Lt(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function wLe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(wLe=function(){return!!e})()}function mI(e){return mI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},mI(e)}function zLt(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&KV(e,t)}function KV(e,t){return KV=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},KV(e,t)}function wD(e,t,n){return t=SLe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function SLe(e){var t=FLt(e,"string");return uw(t)=="symbol"?t:t+""}function FLt(e,t){if(uw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(uw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function BLt(e,t){if(e==null)return{};var n=HLt(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function HLt(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function ULt(e){return e.value}function VLt(e,t){if(we.isValidElement(e))return we.cloneElement(e,t);if(typeof e=="function")return we.createElement(e,t);t.ref;var n=BLt(t,LLt);return we.createElement(eQ,n)}var ape=1,tb=(function(e){function t(){var n;ILt(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=jLt(this,t,[].concat(i)),wD(n,"lastBoundingBox",{width:-1,height:-1}),n}return zLt(t,e),PLt(t,[{key:"componentDidMount",value:function(){this.updateBBox()}},{key:"componentDidUpdate",value:function(){this.updateBBox()}},{key:"getBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var r=this.wrapperNode.getBoundingClientRect();return r.height=this.wrapperNode.offsetHeight,r.width=this.wrapperNode.offsetWidth,r}return null}},{key:"updateBBox",value:function(){var r=this.props.onBBoxUpdate,i=this.getBBox();i?(Math.abs(i.width-this.lastBoundingBox.width)>ape||Math.abs(i.height-this.lastBoundingBox.height)>ape)&&(this.lastBoundingBox.width=i.width,this.lastBoundingBox.height=i.height,r&&r(i)):(this.lastBoundingBox.width!==-1||this.lastBoundingBox.height!==-1)&&(this.lastBoundingBox.width=-1,this.lastBoundingBox.height=-1,r&&r(null))}},{key:"getBBoxSnapshot",value:function(){return this.lastBoundingBox.width>=0&&this.lastBoundingBox.height>=0?bf({},this.lastBoundingBox):{width:0,height:0}}},{key:"getDefaultPosition",value:function(r){var i=this.props,o=i.layout,s=i.align,a=i.verticalAlign,l=i.margin,u=i.chartWidth,c=i.chartHeight,d,h;if(!r||(r.left===void 0||r.left===null)&&(r.right===void 0||r.right===null))if(s==="center"&&o==="vertical"){var m=this.getBBoxSnapshot();d={left:((u||0)-m.width)/2}}else d=s==="right"?{right:l&&l.right||0}:{left:l&&l.left||0};if(!r||(r.top===void 0||r.top===null)&&(r.bottom===void 0||r.bottom===null))if(a==="middle"){var g=this.getBBoxSnapshot();h={top:((c||0)-g.height)/2}}else h=a==="bottom"?{bottom:l&&l.bottom||0}:{top:l&&l.top||0};return bf(bf({},d),h)}},{key:"render",value:function(){var r=this,i=this.props,o=i.content,s=i.width,a=i.height,l=i.wrapperStyle,u=i.payloadUniqBy,c=i.payload,d=bf(bf({position:"absolute",width:s||"auto",height:a||"auto"},this.getDefaultPosition(l)),l);return we.createElement("div",{className:"recharts-legend-wrapper",style:d,ref:function(m){r.wrapperNode=m}},VLt(o,bf(bf({},this.props),{},{payload:xLe(c,u,ULt)})))}}],[{key:"getWithHeight",value:function(r,i){var o=bf(bf({},this.defaultProps),r.props),s=o.layout;return s==="vertical"&&ft(r.props.height)?{height:r.props.height}:s==="horizontal"?{width:r.props.width||i}:null}}])})(A.PureComponent);wD(tb,"displayName","Legend");wD(tb,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"});var DF,lpe;function WLt(){if(lpe)return DF;lpe=1;var e=SA(),t=nQ(),n=Na(),r=e?e.isConcatSpreadable:void 0;function i(o){return n(o)||t(o)||!!(r&&o&&o[r])}return DF=i,DF}var $F,upe;function kLe(){if(upe)return $F;upe=1;var e=dLe(),t=WLt();function n(r,i,o,s,a){var l=-1,u=r.length;for(o||(o=t),a||(a=[]);++l<u;){var c=r[l];i>0&&o(c)?i>1?n(c,i-1,o,s,a):e(a,c):s||(a[a.length]=c)}return a}return $F=n,$F}var zF,cpe;function qLt(){if(cpe)return zF;cpe=1;function e(t){return function(n,r,i){for(var o=-1,s=Object(n),a=i(n),l=a.length;l--;){var u=a[t?l:++o];if(r(s[u],u,s)===!1)break}return n}}return zF=e,zF}var FF,dpe;function GLt(){if(dpe)return FF;dpe=1;var e=qLt(),t=e();return FF=t,FF}var BF,fpe;function CLe(){if(fpe)return BF;fpe=1;var e=GLt(),t=xD();function n(r,i){return r&&e(r,i,t)}return BF=n,BF}var HF,hpe;function KLt(){if(hpe)return HF;hpe=1;var e=CA();function t(n,r){return function(i,o){if(i==null)return i;if(!e(i))return n(i,o);for(var s=i.length,a=r?s:-1,l=Object(i);(r?a--:++a<s)&&o(l[a],a,l)!==!1;);return i}}return HF=t,HF}var UF,ppe;function sQ(){if(ppe)return UF;ppe=1;var e=CLe(),t=KLt(),n=t(e);return UF=n,UF}var VF,mpe;function ELe(){if(mpe)return VF;mpe=1;var e=sQ(),t=CA();function n(r,i){var o=-1,s=t(r)?Array(r.length):[];return e(r,function(a,l,u){s[++o]=i(a,l,u)}),s}return VF=n,VF}var WF,gpe;function YLt(){if(gpe)return WF;gpe=1;function e(t,n){var r=t.length;for(t.sort(n);r--;)t[r]=t[r].value;return t}return WF=e,WF}var qF,ype;function XLt(){if(ype)return qF;ype=1;var e=uS();function t(n,r){if(n!==r){var i=n!==void 0,o=n===null,s=n===n,a=e(n),l=r!==void 0,u=r===null,c=r===r,d=e(r);if(!u&&!d&&!a&&n>r||a&&l&&c&&!u&&!d||o&&l&&c||!i&&c||!s)return 1;if(!o&&!a&&!d&&n<r||d&&i&&s&&!o&&!a||u&&i&&s||!l&&s||!c)return-1}return 0}return qF=t,qF}var GF,bpe;function QLt(){if(bpe)return GF;bpe=1;var e=XLt();function t(n,r,i){for(var o=-1,s=n.criteria,a=r.criteria,l=s.length,u=i.length;++o<l;){var c=e(s[o],a[o]);if(c){if(o>=u)return c;var d=i[o];return c*(d=="desc"?-1:1)}}return n.index-r.index}return GF=t,GF}var KF,vpe;function ZLt(){if(vpe)return KF;vpe=1;var e=YX(),t=XX(),n=Wg(),r=ELe(),i=YLt(),o=hLe(),s=QLt(),a=hS(),l=Na();function u(c,d,h){d.length?d=e(d,function(b){return l(b)?function(v){return t(v,b.length===1?b[0]:b)}:b}):d=[a];var m=-1;d=e(d,o(n));var g=r(c,function(b,v,w){var S=e(d,function(C){return C(b)});return{criteria:S,index:++m,value:b}});return i(g,function(b,v){return s(b,v,h)})}return KF=u,KF}var YF,xpe;function JLt(){if(xpe)return YF;xpe=1;function e(t,n,r){switch(r.length){case 0:return t.call(n);case 1:return t.call(n,r[0]);case 2:return t.call(n,r[0],r[1]);case 3:return t.call(n,r[0],r[1],r[2])}return t.apply(n,r)}return YF=e,YF}var XF,wpe;function eIt(){if(wpe)return XF;wpe=1;var e=JLt(),t=Math.max;function n(r,i,o){return i=t(i===void 0?r.length-1:i,0),function(){for(var s=arguments,a=-1,l=t(s.length-i,0),u=Array(l);++a<l;)u[a]=s[i+a];a=-1;for(var c=Array(i+1);++a<i;)c[a]=s[a];return c[i]=o(u),e(r,this,c)}}return XF=n,XF}var QF,Spe;function tIt(){if(Spe)return QF;Spe=1;function e(t){return function(){return t}}return QF=e,QF}var ZF,kpe;function TLe(){if(kpe)return ZF;kpe=1;var e=zb(),t=(function(){try{var n=e(Object,"defineProperty");return n({},"",{}),n}catch{}})();return ZF=t,ZF}var JF,Cpe;function nIt(){if(Cpe)return JF;Cpe=1;var e=tIt(),t=TLe(),n=hS(),r=t?function(i,o){return t(i,"toString",{configurable:!0,enumerable:!1,value:e(o),writable:!0})}:n;return JF=r,JF}var eB,Epe;function rIt(){if(Epe)return eB;Epe=1;var e=800,t=16,n=Date.now;function r(i){var o=0,s=0;return function(){var a=n(),l=t-(a-s);if(s=a,l>0){if(++o>=e)return arguments[0]}else o=0;return i.apply(void 0,arguments)}}return eB=r,eB}var tB,Tpe;function iIt(){if(Tpe)return tB;Tpe=1;var e=nIt(),t=rIt(),n=t(e);return tB=n,tB}var nB,Ape;function oIt(){if(Ape)return nB;Ape=1;var e=hS(),t=eIt(),n=iIt();function r(i,o){return n(t(i,o,e),i+"")}return nB=r,nB}var rB,Ope;function SD(){if(Ope)return rB;Ope=1;var e=qX(),t=CA(),n=rQ(),r=Vg();function i(o,s,a){if(!r(a))return!1;var l=typeof s;return(l=="number"?t(a)&&n(s,a.length):l=="string"&&s in a)?e(a[s],o):!1}return rB=i,rB}var iB,Rpe;function sIt(){if(Rpe)return iB;Rpe=1;var e=kLe(),t=ZLt(),n=oIt(),r=SD(),i=n(function(o,s){if(o==null)return[];var a=s.length;return a>1&&r(o,s[0],s[1])?s=[]:a>2&&r(s[0],s[1],s[2])&&(s=[s[0]]),t(o,e(s,1),[])});return iB=i,iB}var aIt=sIt();const aQ=cr(aIt);function lT(e){"@babel/helpers - typeof";return lT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},lT(e)}function YV(){return YV=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},YV.apply(this,arguments)}function lIt(e,t){return fIt(e)||dIt(e,t)||cIt(e,t)||uIt()}function uIt(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2856
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function cIt(e,t){if(e){if(typeof e=="string")return Mpe(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Mpe(e,t)}}function Mpe(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function dIt(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,s,a=[],l=!0,u=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(l=(r=o.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(c){u=!0,i=c}finally{try{if(!l&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw i}}return a}}function fIt(e){if(Array.isArray(e))return e}function _pe(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 oB(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?_pe(Object(n),!0).forEach(function(r){hIt(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_pe(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function hIt(e,t,n){return t=pIt(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pIt(e){var t=mIt(e,"string");return lT(t)=="symbol"?t:t+""}function mIt(e,t){if(lT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(lT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function gIt(e){return Array.isArray(e)&&ho(e[0])&&ho(e[1])?e.join(" ~ "):e}var yIt=function(t){var n=t.separator,r=n===void 0?" : ":n,i=t.contentStyle,o=i===void 0?{}:i,s=t.itemStyle,a=s===void 0?{}:s,l=t.labelStyle,u=l===void 0?{}:l,c=t.payload,d=t.formatter,h=t.itemSorter,m=t.wrapperClassName,g=t.labelClassName,b=t.label,v=t.labelFormatter,w=t.accessibilityLayer,S=w===void 0?!1:w,C=function(){if(c&&c.length){var F={padding:0,margin:0},z=(h?aQ(c,h):c).map(function($,B){if($.type==="none")return null;var H=oB({display:"block",paddingTop:4,paddingBottom:4,color:$.color||"#000"},a),U=$.formatter||d||gIt,W=$.value,q=$.name,Y=W,Q=q;if(U&&Y!=null&&Q!=null){var G=U(W,q,$,B,c);if(Array.isArray(G)){var le=lIt(G,2);Y=le[0],Q=le[1]}else Y=G}return we.createElement("li",{className:"recharts-tooltip-item",key:"tooltip-item-".concat(B),style:H},ho(Q)?we.createElement("span",{className:"recharts-tooltip-item-name"},Q):null,ho(Q)?we.createElement("span",{className:"recharts-tooltip-item-separator"},r):null,we.createElement("span",{className:"recharts-tooltip-item-value"},Y),we.createElement("span",{className:"recharts-tooltip-item-unit"},$.unit||""))});return we.createElement("ul",{className:"recharts-tooltip-item-list",style:F},z)}return null},E=oB({margin:0,padding:10,backgroundColor:"#fff",border:"1px solid #ccc",whiteSpace:"nowrap"},o),T=oB({margin:0},u),O=!Rn(b),M=O?b:"",N=Hn("recharts-default-tooltip",m),I=Hn("recharts-tooltip-label",g);O&&v&&c!==void 0&&c!==null&&(M=v(b,c));var D=S?{role:"status","aria-live":"assertive"}:{};return we.createElement("div",YV({className:N,style:E},D),we.createElement("p",{className:I,style:T},we.isValidElement(M)?M:"".concat(M)),C())};function uT(e){"@babel/helpers - typeof";return uT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},uT(e)}function fM(e,t,n){return t=bIt(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function bIt(e){var t=vIt(e,"string");return uT(t)=="symbol"?t:t+""}function vIt(e,t){if(uT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(uT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Tk="recharts-tooltip-wrapper",xIt={visibility:"hidden"};function wIt(e){var t=e.coordinate,n=e.translateX,r=e.translateY;return Hn(Tk,fM(fM(fM(fM({},"".concat(Tk,"-right"),ft(n)&&t&&ft(t.x)&&n>=t.x),"".concat(Tk,"-left"),ft(n)&&t&&ft(t.x)&&n<t.x),"".concat(Tk,"-bottom"),ft(r)&&t&&ft(t.y)&&r>=t.y),"".concat(Tk,"-top"),ft(r)&&t&&ft(t.y)&&r<t.y))}function Npe(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.key,i=e.offsetTopLeft,o=e.position,s=e.reverseDirection,a=e.tooltipDimension,l=e.viewBox,u=e.viewBoxDimension;if(o&&ft(o[r]))return o[r];var c=n[r]-a-i,d=n[r]+i;if(t[r])return s[r]?c:d;if(s[r]){var h=c,m=l[r];return h<m?Math.max(d,l[r]):Math.max(c,l[r])}var g=d+a,b=l[r]+u;return g>b?Math.max(c,l[r]):Math.max(d,l[r])}function SIt(e){var t=e.translateX,n=e.translateY,r=e.useTranslate3d;return{transform:r?"translate3d(".concat(t,"px, ").concat(n,"px, 0)"):"translate(".concat(t,"px, ").concat(n,"px)")}}function kIt(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.offsetTopLeft,i=e.position,o=e.reverseDirection,s=e.tooltipBox,a=e.useTranslate3d,l=e.viewBox,u,c,d;return s.height>0&&s.width>0&&n?(c=Npe({allowEscapeViewBox:t,coordinate:n,key:"x",offsetTopLeft:r,position:i,reverseDirection:o,tooltipDimension:s.width,viewBox:l,viewBoxDimension:l.width}),d=Npe({allowEscapeViewBox:t,coordinate:n,key:"y",offsetTopLeft:r,position:i,reverseDirection:o,tooltipDimension:s.height,viewBox:l,viewBoxDimension:l.height}),u=SIt({translateX:c,translateY:d,useTranslate3d:a})):u=xIt,{cssProperties:u,cssClasses:wIt({translateX:c,translateY:d,coordinate:n})}}function cw(e){"@babel/helpers - typeof";return cw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},cw(e)}function Lpe(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 Ipe(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Lpe(Object(n),!0).forEach(function(r){QV(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Lpe(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function CIt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function EIt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,OLe(r.key),r)}}function TIt(e,t,n){return t&&EIt(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function AIt(e,t,n){return t=gI(t),OIt(e,ALe()?Reflect.construct(t,n||[],gI(e).constructor):t.apply(e,n))}function OIt(e,t){if(t&&(cw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return RIt(e)}function RIt(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ALe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(ALe=function(){return!!e})()}function gI(e){return gI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},gI(e)}function MIt(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&XV(e,t)}function XV(e,t){return XV=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},XV(e,t)}function QV(e,t,n){return t=OLe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function OLe(e){var t=_It(e,"string");return cw(t)=="symbol"?t:t+""}function _It(e,t){if(cw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(cw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Ppe=1,NIt=(function(e){function t(){var n;CIt(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=AIt(this,t,[].concat(i)),QV(n,"state",{dismissed:!1,dismissedAtCoordinate:{x:0,y:0},lastBoundingBox:{width:-1,height:-1}}),QV(n,"handleKeyDown",function(s){if(s.key==="Escape"){var a,l,u,c;n.setState({dismissed:!0,dismissedAtCoordinate:{x:(a=(l=n.props.coordinate)===null||l===void 0?void 0:l.x)!==null&&a!==void 0?a:0,y:(u=(c=n.props.coordinate)===null||c===void 0?void 0:c.y)!==null&&u!==void 0?u:0}})}}),n}return MIt(t,e),TIt(t,[{key:"updateBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var r=this.wrapperNode.getBoundingClientRect();(Math.abs(r.width-this.state.lastBoundingBox.width)>Ppe||Math.abs(r.height-this.state.lastBoundingBox.height)>Ppe)&&this.setState({lastBoundingBox:{width:r.width,height:r.height}})}else(this.state.lastBoundingBox.width!==-1||this.state.lastBoundingBox.height!==-1)&&this.setState({lastBoundingBox:{width:-1,height:-1}})}},{key:"componentDidMount",value:function(){document.addEventListener("keydown",this.handleKeyDown),this.updateBBox()}},{key:"componentWillUnmount",value:function(){document.removeEventListener("keydown",this.handleKeyDown)}},{key:"componentDidUpdate",value:function(){var r,i;this.props.active&&this.updateBBox(),this.state.dismissed&&(((r=this.props.coordinate)===null||r===void 0?void 0:r.x)!==this.state.dismissedAtCoordinate.x||((i=this.props.coordinate)===null||i===void 0?void 0:i.y)!==this.state.dismissedAtCoordinate.y)&&(this.state.dismissed=!1)}},{key:"render",value:function(){var r=this,i=this.props,o=i.active,s=i.allowEscapeViewBox,a=i.animationDuration,l=i.animationEasing,u=i.children,c=i.coordinate,d=i.hasPayload,h=i.isAnimationActive,m=i.offset,g=i.position,b=i.reverseDirection,v=i.useTranslate3d,w=i.viewBox,S=i.wrapperStyle,C=kIt({allowEscapeViewBox:s,coordinate:c,offsetTopLeft:m,position:g,reverseDirection:b,tooltipBox:this.state.lastBoundingBox,useTranslate3d:v,viewBox:w}),E=C.cssClasses,T=C.cssProperties,O=Ipe(Ipe({transition:h&&o?"transform ".concat(a,"ms ").concat(l):void 0},T),{},{pointerEvents:"none",visibility:!this.state.dismissed&&o&&d?"visible":"hidden",position:"absolute",top:0,left:0},S);return we.createElement("div",{tabIndex:-1,className:E,style:O,ref:function(N){r.wrapperNode=N}},u)}}])})(A.PureComponent),LIt=function(){return!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout)},Fb={isSsr:LIt()};function dw(e){"@babel/helpers - typeof";return dw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},dw(e)}function jpe(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 Dpe(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?jpe(Object(n),!0).forEach(function(r){lQ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):jpe(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function IIt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function PIt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,MLe(r.key),r)}}function jIt(e,t,n){return t&&PIt(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function DIt(e,t,n){return t=yI(t),$It(e,RLe()?Reflect.construct(t,n||[],yI(e).constructor):t.apply(e,n))}function $It(e,t){if(t&&(dw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return zIt(e)}function zIt(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function RLe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(RLe=function(){return!!e})()}function yI(e){return yI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},yI(e)}function FIt(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ZV(e,t)}function ZV(e,t){return ZV=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},ZV(e,t)}function lQ(e,t,n){return t=MLe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function MLe(e){var t=BIt(e,"string");return dw(t)=="symbol"?t:t+""}function BIt(e,t){if(dw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(dw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function HIt(e){return e.dataKey}function UIt(e,t){return we.isValidElement(e)?we.cloneElement(e,t):typeof e=="function"?we.createElement(e,t):we.createElement(yIt,t)}var Fc=(function(e){function t(){return IIt(this,t),DIt(this,t,arguments)}return FIt(t,e),jIt(t,[{key:"render",value:function(){var r=this,i=this.props,o=i.active,s=i.allowEscapeViewBox,a=i.animationDuration,l=i.animationEasing,u=i.content,c=i.coordinate,d=i.filterNull,h=i.isAnimationActive,m=i.offset,g=i.payload,b=i.payloadUniqBy,v=i.position,w=i.reverseDirection,S=i.useTranslate3d,C=i.viewBox,E=i.wrapperStyle,T=g??[];d&&T.length&&(T=xLe(g.filter(function(M){return M.value!=null&&(M.hide!==!0||r.props.includeHidden)}),b,HIt));var O=T.length>0;return we.createElement(NIt,{allowEscapeViewBox:s,animationDuration:a,animationEasing:l,isAnimationActive:h,active:o,coordinate:c,hasPayload:O,offset:m,position:v,reverseDirection:w,useTranslate3d:S,viewBox:C,wrapperStyle:E},UIt(u,Dpe(Dpe({},this.props),{},{payload:T})))}}])})(A.PureComponent);lQ(Fc,"displayName","Tooltip");lQ(Fc,"defaultProps",{accessibilityLayer:!1,allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",contentStyle:{},coordinate:{x:0,y:0},cursor:!0,cursorStyle:{},filterNull:!0,isAnimationActive:!Fb.isSsr,itemStyle:{},labelStyle:{},offset:10,reverseDirection:{x:!1,y:!1},separator:" : ",trigger:"hover",useTranslate3d:!1,viewBox:{x:0,y:0,height:0,width:0},wrapperStyle:{}});var sB,$pe;function VIt(){if($pe)return sB;$pe=1;var e=SNe(),t=Vg(),n="Expected a function";function r(i,o,s){var a=!0,l=!0;if(typeof i!="function")throw new TypeError(n);return t(s)&&(a="leading"in s?!!s.leading:a,l="trailing"in s?!!s.trailing:l),e(i,o,{leading:a,maxWait:o,trailing:l})}return sB=r,sB}var WIt=VIt();const _Le=cr(WIt);function cT(e){"@babel/helpers - typeof";return cT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},cT(e)}function zpe(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 hM(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?zpe(Object(n),!0).forEach(function(r){qIt(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zpe(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function qIt(e,t,n){return t=GIt(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function GIt(e){var t=KIt(e,"string");return cT(t)=="symbol"?t:t+""}function KIt(e,t){if(cT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(cT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function YIt(e,t){return JIt(e)||ZIt(e,t)||QIt(e,t)||XIt()}function XIt(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2855
+ A`).concat(s,",").concat(s,",0,1,1,").concat(a,",").concat(o),className:"recharts-legend-icon"});if(r.type==="rect")return we.createElement("path",{stroke:"none",fill:l,d:"M0,".concat(Ml/8,"h").concat(Ml,"v").concat(Ml*3/4,"h").concat(-Ml,"z"),className:"recharts-legend-icon"});if(we.isValidElement(r.legendIcon)){var u=ONt({},r);return delete u.legendIcon,we.cloneElement(r.legendIcon,u)}return we.createElement(JX,{fill:l,cx:o,cy:o,size:Ml,sizeType:"diameter",type:r.type})}},{key:"renderItems",value:function(){var r=this,i=this.props,o=i.payload,s=i.iconSize,a=i.layout,l=i.formatter,u=i.inactiveColor,c={x:0,y:0,width:Ml,height:Ml},d={display:a==="horizontal"?"inline-block":"block",marginRight:10},h={display:"inline-block",verticalAlign:"middle",marginRight:4};return o.map(function(m,g){var b=m.formatter||l,v=Hn(aT(aT({"recharts-legend-item":!0},"legend-item-".concat(g),!0),"inactive",m.inactive));if(m.type==="none")return null;var w=yn(m.value)?null:m.value;Rh(!yn(m.value),`The name property is also required when using a function for the dataKey of a chart's cartesian components. Ex: <Bar name="Name of my Data"/>`);var S=m.inactive?u:m.color;return we.createElement("li",qV({className:v,style:d,key:"legend-item-".concat(g)},hI(r.props,m,g)),we.createElement(UV,{width:s,height:s,viewBox:c,style:h},r.renderIcon(m)),we.createElement("span",{className:"recharts-legend-item-text",style:{color:S}},b?b(w,m,g):w))})}},{key:"render",value:function(){var r=this.props,i=r.payload,o=r.layout,s=r.align;if(!i||!i.length)return null;var a={padding:0,margin:0,textAlign:o==="horizontal"?s:"left"};return we.createElement("ul",{className:"recharts-default-legend",style:a},this.renderItems())}}])})(A.PureComponent);aT(eQ,"displayName","Legend");aT(eQ,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"middle",inactiveColor:"#ccc"});var wz,Ffe;function DNt(){if(Ffe)return wz;Ffe=1;var e=gD();function t(){this.__data__=new e,this.size=0}return wz=t,wz}var Sz,Bfe;function $Nt(){if(Bfe)return Sz;Bfe=1;function e(t){var n=this.__data__,r=n.delete(t);return this.size=n.size,r}return Sz=e,Sz}var kz,Hfe;function zNt(){if(Hfe)return kz;Hfe=1;function e(t){return this.__data__.get(t)}return kz=e,kz}var Cz,Ufe;function FNt(){if(Ufe)return Cz;Ufe=1;function e(t){return this.__data__.has(t)}return Cz=e,Cz}var Ez,Vfe;function BNt(){if(Vfe)return Ez;Vfe=1;var e=gD(),t=GX(),n=KX(),r=200;function i(o,s){var a=this.__data__;if(a instanceof e){var l=a.__data__;if(!t||l.length<r-1)return l.push([o,s]),this.size=++a.size,this;a=this.__data__=new n(l)}return a.set(o,s),this.size=a.size,this}return Ez=i,Ez}var Tz,Wfe;function sLe(){if(Wfe)return Tz;Wfe=1;var e=gD(),t=DNt(),n=$Nt(),r=zNt(),i=FNt(),o=BNt();function s(a){var l=this.__data__=new e(a);this.size=l.size}return s.prototype.clear=t,s.prototype.delete=n,s.prototype.get=r,s.prototype.has=i,s.prototype.set=o,Tz=s,Tz}var Az,qfe;function HNt(){if(qfe)return Az;qfe=1;var e="__lodash_hash_undefined__";function t(n){return this.__data__.set(n,e),this}return Az=t,Az}var Oz,Gfe;function UNt(){if(Gfe)return Oz;Gfe=1;function e(t){return this.__data__.has(t)}return Oz=e,Oz}var Rz,Kfe;function aLe(){if(Kfe)return Rz;Kfe=1;var e=KX(),t=HNt(),n=UNt();function r(i){var o=-1,s=i==null?0:i.length;for(this.__data__=new e;++o<s;)this.add(i[o])}return r.prototype.add=r.prototype.push=t,r.prototype.has=n,Rz=r,Rz}var Mz,Yfe;function lLe(){if(Yfe)return Mz;Yfe=1;function e(t,n){for(var r=-1,i=t==null?0:t.length;++r<i;)if(n(t[r],r,t))return!0;return!1}return Mz=e,Mz}var _z,Xfe;function uLe(){if(Xfe)return _z;Xfe=1;function e(t,n){return t.has(n)}return _z=e,_z}var Nz,Qfe;function cLe(){if(Qfe)return Nz;Qfe=1;var e=aLe(),t=lLe(),n=uLe(),r=1,i=2;function o(s,a,l,u,c,d){var h=l&r,m=s.length,g=a.length;if(m!=g&&!(h&&g>m))return!1;var b=d.get(s),v=d.get(a);if(b&&v)return b==a&&v==s;var w=-1,S=!0,C=l&i?new e:void 0;for(d.set(s,a),d.set(a,s);++w<m;){var E=s[w],T=a[w];if(u)var O=h?u(T,E,w,a,s,d):u(E,T,w,s,a,d);if(O!==void 0){if(O)continue;S=!1;break}if(C){if(!t(a,function(M,N){if(!n(C,N)&&(E===M||c(E,M,l,u,d)))return C.push(N)})){S=!1;break}}else if(!(E===T||c(E,T,l,u,d))){S=!1;break}}return d.delete(s),d.delete(a),S}return Nz=o,Nz}var Lz,Zfe;function VNt(){if(Zfe)return Lz;Zfe=1;var e=Hd(),t=e.Uint8Array;return Lz=t,Lz}var Iz,Jfe;function WNt(){if(Jfe)return Iz;Jfe=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(i,o){r[++n]=[o,i]}),r}return Iz=e,Iz}var Pz,ehe;function tQ(){if(ehe)return Pz;ehe=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(i){r[++n]=i}),r}return Pz=e,Pz}var jz,the;function qNt(){if(the)return jz;the=1;var e=lA(),t=VNt(),n=qX(),r=cLe(),i=WNt(),o=tQ(),s=1,a=2,l="[object Boolean]",u="[object Date]",c="[object Error]",d="[object Map]",h="[object Number]",m="[object RegExp]",g="[object Set]",b="[object String]",v="[object Symbol]",w="[object ArrayBuffer]",S="[object DataView]",C=e?e.prototype:void 0,E=C?C.valueOf:void 0;function T(O,M,N,I,D,P,F){switch(N){case S:if(O.byteLength!=M.byteLength||O.byteOffset!=M.byteOffset)return!1;O=O.buffer,M=M.buffer;case w:return!(O.byteLength!=M.byteLength||!P(new t(O),new t(M)));case l:case u:case h:return n(+O,+M);case c:return O.name==M.name&&O.message==M.message;case m:case b:return O==M+"";case d:var z=i;case g:var $=I&s;if(z||(z=o),O.size!=M.size&&!$)return!1;var B=F.get(O);if(B)return B==M;I|=a,F.set(O,M);var H=r(z(O),z(M),I,D,P,F);return F.delete(O),H;case v:if(E)return E.call(O)==E.call(M)}return!1}return jz=T,jz}var Dz,nhe;function dLe(){if(nhe)return Dz;nhe=1;function e(t,n){for(var r=-1,i=n.length,o=t.length;++r<i;)t[o+r]=n[r];return t}return Dz=e,Dz}var $z,rhe;function GNt(){if(rhe)return $z;rhe=1;var e=dLe(),t=Na();function n(r,i,o){var s=i(r);return t(r)?s:e(s,o(r))}return $z=n,$z}var zz,ihe;function KNt(){if(ihe)return zz;ihe=1;function e(t,n){for(var r=-1,i=t==null?0:t.length,o=0,s=[];++r<i;){var a=t[r];n(a,r,t)&&(s[o++]=a)}return s}return zz=e,zz}var Fz,ohe;function YNt(){if(ohe)return Fz;ohe=1;function e(){return[]}return Fz=e,Fz}var Bz,she;function XNt(){if(she)return Bz;she=1;var e=KNt(),t=YNt(),n=Object.prototype,r=n.propertyIsEnumerable,i=Object.getOwnPropertySymbols,o=i?function(s){return s==null?[]:(s=Object(s),e(i(s),function(a){return r.call(s,a)}))}:t;return Bz=o,Bz}var Hz,ahe;function QNt(){if(ahe)return Hz;ahe=1;function e(t,n){for(var r=-1,i=Array(t);++r<t;)i[r]=n(r);return i}return Hz=e,Hz}var Uz,lhe;function ZNt(){if(lhe)return Uz;lhe=1;var e=Zh(),t=Jh(),n="[object Arguments]";function r(i){return t(i)&&e(i)==n}return Uz=r,Uz}var Vz,uhe;function nQ(){if(uhe)return Vz;uhe=1;var e=ZNt(),t=Jh(),n=Object.prototype,r=n.hasOwnProperty,i=n.propertyIsEnumerable,o=e((function(){return arguments})())?e:function(s){return t(s)&&r.call(s,"callee")&&!i.call(s,"callee")};return Vz=o,Vz}var hC={exports:{}},Wz,che;function JNt(){if(che)return Wz;che=1;function e(){return!1}return Wz=e,Wz}hC.exports;var dhe;function fLe(){return dhe||(dhe=1,(function(e,t){var n=Hd(),r=JNt(),i=t&&!t.nodeType&&t,o=i&&!0&&e&&!e.nodeType&&e,s=o&&o.exports===i,a=s?n.Buffer:void 0,l=a?a.isBuffer:void 0,u=l||r;e.exports=u})(hC,hC.exports)),hC.exports}var qz,fhe;function rQ(){if(fhe)return qz;fhe=1;var e=9007199254740991,t=/^(?:0|[1-9]\d*)$/;function n(r,i){var o=typeof r;return i=i??e,!!i&&(o=="number"||o!="symbol"&&t.test(r))&&r>-1&&r%1==0&&r<i}return qz=n,qz}var Gz,hhe;function iQ(){if(hhe)return Gz;hhe=1;var e=9007199254740991;function t(n){return typeof n=="number"&&n>-1&&n%1==0&&n<=e}return Gz=t,Gz}var Kz,phe;function eLt(){if(phe)return Kz;phe=1;var e=Zh(),t=iQ(),n=Jh(),r="[object Arguments]",i="[object Array]",o="[object Boolean]",s="[object Date]",a="[object Error]",l="[object Function]",u="[object Map]",c="[object Number]",d="[object Object]",h="[object RegExp]",m="[object Set]",g="[object String]",b="[object WeakMap]",v="[object ArrayBuffer]",w="[object DataView]",S="[object Float32Array]",C="[object Float64Array]",E="[object Int8Array]",T="[object Int16Array]",O="[object Int32Array]",M="[object Uint8Array]",N="[object Uint8ClampedArray]",I="[object Uint16Array]",D="[object Uint32Array]",P={};P[S]=P[C]=P[E]=P[T]=P[O]=P[M]=P[N]=P[I]=P[D]=!0,P[r]=P[i]=P[v]=P[o]=P[w]=P[s]=P[a]=P[l]=P[u]=P[c]=P[d]=P[h]=P[m]=P[g]=P[b]=!1;function F(z){return n(z)&&t(z.length)&&!!P[e(z)]}return Kz=F,Kz}var Yz,mhe;function hLe(){if(mhe)return Yz;mhe=1;function e(t){return function(n){return t(n)}}return Yz=e,Yz}var pC={exports:{}};pC.exports;var ghe;function tLt(){return ghe||(ghe=1,(function(e,t){var n=GOe(),r=t&&!t.nodeType&&t,i=r&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===r,s=o&&n.process,a=(function(){try{var l=i&&i.require&&i.require("util").types;return l||s&&s.binding&&s.binding("util")}catch{}})();e.exports=a})(pC,pC.exports)),pC.exports}var Xz,yhe;function pLe(){if(yhe)return Xz;yhe=1;var e=eLt(),t=hLe(),n=tLt(),r=n&&n.isTypedArray,i=r?t(r):e;return Xz=i,Xz}var Qz,bhe;function nLt(){if(bhe)return Qz;bhe=1;var e=QNt(),t=nQ(),n=Na(),r=fLe(),i=rQ(),o=pLe(),s=Object.prototype,a=s.hasOwnProperty;function l(u,c){var d=n(u),h=!d&&t(u),m=!d&&!h&&r(u),g=!d&&!h&&!m&&o(u),b=d||h||m||g,v=b?e(u.length,String):[],w=v.length;for(var S in u)(c||a.call(u,S))&&!(b&&(S=="length"||m&&(S=="offset"||S=="parent")||g&&(S=="buffer"||S=="byteLength"||S=="byteOffset")||i(S,w)))&&v.push(S);return v}return Qz=l,Qz}var Zz,vhe;function rLt(){if(vhe)return Zz;vhe=1;var e=Object.prototype;function t(n){var r=n&&n.constructor,i=typeof r=="function"&&r.prototype||e;return n===i}return Zz=t,Zz}var Jz,xhe;function mLe(){if(xhe)return Jz;xhe=1;function e(t,n){return function(r){return t(n(r))}}return Jz=e,Jz}var eF,whe;function iLt(){if(whe)return eF;whe=1;var e=mLe(),t=e(Object.keys,Object);return eF=t,eF}var tF,She;function oLt(){if(She)return tF;She=1;var e=rLt(),t=iLt(),n=Object.prototype,r=n.hasOwnProperty;function i(o){if(!e(o))return t(o);var s=[];for(var a in Object(o))r.call(o,a)&&a!="constructor"&&s.push(a);return s}return tF=i,tF}var nF,khe;function CA(){if(khe)return nF;khe=1;var e=WX(),t=iQ();function n(r){return r!=null&&t(r.length)&&!e(r)}return nF=n,nF}var rF,Che;function xD(){if(Che)return rF;Che=1;var e=nLt(),t=oLt(),n=CA();function r(i){return n(i)?e(i):t(i)}return rF=r,rF}var iF,Ehe;function sLt(){if(Ehe)return iF;Ehe=1;var e=GNt(),t=XNt(),n=xD();function r(i){return e(i,n,t)}return iF=r,iF}var oF,The;function aLt(){if(The)return oF;The=1;var e=sLt(),t=1,n=Object.prototype,r=n.hasOwnProperty;function i(o,s,a,l,u,c){var d=a&t,h=e(o),m=h.length,g=e(s),b=g.length;if(m!=b&&!d)return!1;for(var v=m;v--;){var w=h[v];if(!(d?w in s:r.call(s,w)))return!1}var S=c.get(o),C=c.get(s);if(S&&C)return S==s&&C==o;var E=!0;c.set(o,s),c.set(s,o);for(var T=d;++v<m;){w=h[v];var O=o[w],M=s[w];if(l)var N=d?l(M,O,w,s,o,c):l(O,M,w,o,s,c);if(!(N===void 0?O===M||u(O,M,a,l,c):N)){E=!1;break}T||(T=w=="constructor")}if(E&&!T){var I=o.constructor,D=s.constructor;I!=D&&"constructor"in o&&"constructor"in s&&!(typeof I=="function"&&I instanceof I&&typeof D=="function"&&D instanceof D)&&(E=!1)}return c.delete(o),c.delete(s),E}return oF=i,oF}var sF,Ahe;function lLt(){if(Ahe)return sF;Ahe=1;var e=zb(),t=Hd(),n=e(t,"DataView");return sF=n,sF}var aF,Ohe;function uLt(){if(Ohe)return aF;Ohe=1;var e=zb(),t=Hd(),n=e(t,"Promise");return aF=n,aF}var lF,Rhe;function gLe(){if(Rhe)return lF;Rhe=1;var e=zb(),t=Hd(),n=e(t,"Set");return lF=n,lF}var uF,Mhe;function cLt(){if(Mhe)return uF;Mhe=1;var e=zb(),t=Hd(),n=e(t,"WeakMap");return uF=n,uF}var cF,_he;function dLt(){if(_he)return cF;_he=1;var e=lLt(),t=GX(),n=uLt(),r=gLe(),i=cLt(),o=Zh(),s=YNe(),a="[object Map]",l="[object Object]",u="[object Promise]",c="[object Set]",d="[object WeakMap]",h="[object DataView]",m=s(e),g=s(t),b=s(n),v=s(r),w=s(i),S=o;return(e&&S(new e(new ArrayBuffer(1)))!=h||t&&S(new t)!=a||n&&S(n.resolve())!=u||r&&S(new r)!=c||i&&S(new i)!=d)&&(S=function(C){var E=o(C),T=E==l?C.constructor:void 0,O=T?s(T):"";if(O)switch(O){case m:return h;case g:return a;case b:return u;case v:return c;case w:return d}return E}),cF=S,cF}var dF,Nhe;function fLt(){if(Nhe)return dF;Nhe=1;var e=sLe(),t=cLe(),n=qNt(),r=aLt(),i=dLt(),o=Na(),s=fLe(),a=pLe(),l=1,u="[object Arguments]",c="[object Array]",d="[object Object]",h=Object.prototype,m=h.hasOwnProperty;function g(b,v,w,S,C,E){var T=o(b),O=o(v),M=T?c:i(b),N=O?c:i(v);M=M==u?d:M,N=N==u?d:N;var I=M==d,D=N==d,P=M==N;if(P&&s(b)){if(!s(v))return!1;T=!0,I=!1}if(P&&!I)return E||(E=new e),T||a(b)?t(b,v,w,S,C,E):n(b,v,M,w,S,C,E);if(!(w&l)){var F=I&&m.call(b,"__wrapped__"),z=D&&m.call(v,"__wrapped__");if(F||z){var $=F?b.value():b,B=z?v.value():v;return E||(E=new e),C($,B,w,S,E)}}return P?(E||(E=new e),r(b,v,w,S,C,E)):!1}return dF=g,dF}var fF,Lhe;function oQ(){if(Lhe)return fF;Lhe=1;var e=fLt(),t=Jh();function n(r,i,o,s,a){return r===i?!0:r==null||i==null||!t(r)&&!t(i)?r!==r&&i!==i:e(r,i,o,s,n,a)}return fF=n,fF}var hF,Ihe;function hLt(){if(Ihe)return hF;Ihe=1;var e=sLe(),t=oQ(),n=1,r=2;function i(o,s,a,l){var u=a.length,c=u,d=!l;if(o==null)return!c;for(o=Object(o);u--;){var h=a[u];if(d&&h[2]?h[1]!==o[h[0]]:!(h[0]in o))return!1}for(;++u<c;){h=a[u];var m=h[0],g=o[m],b=h[1];if(d&&h[2]){if(g===void 0&&!(m in o))return!1}else{var v=new e;if(l)var w=l(g,b,m,o,s,v);if(!(w===void 0?t(b,g,n|r,l,v):w))return!1}}return!0}return hF=i,hF}var pF,Phe;function yLe(){if(Phe)return pF;Phe=1;var e=Fg();function t(n){return n===n&&!e(n)}return pF=t,pF}var mF,jhe;function pLt(){if(jhe)return mF;jhe=1;var e=yLe(),t=xD();function n(r){for(var i=t(r),o=i.length;o--;){var s=i[o],a=r[s];i[o]=[s,a,e(a)]}return i}return mF=n,mF}var gF,Dhe;function bLe(){if(Dhe)return gF;Dhe=1;function e(t,n){return function(r){return r==null?!1:r[t]===n&&(n!==void 0||t in Object(r))}}return gF=e,gF}var yF,$he;function mLt(){if($he)return yF;$he=1;var e=hLt(),t=pLt(),n=bLe();function r(i){var o=t(i);return o.length==1&&o[0][2]?n(o[0][0],o[0][1]):function(s){return s===i||e(s,i,o)}}return yF=r,yF}var bF,zhe;function gLt(){if(zhe)return bF;zhe=1;function e(t,n){return t!=null&&n in Object(t)}return bF=e,bF}var vF,Fhe;function yLt(){if(Fhe)return vF;Fhe=1;var e=ZNe(),t=nQ(),n=Na(),r=rQ(),i=iQ(),o=bD();function s(a,l,u){l=e(l,a);for(var c=-1,d=l.length,h=!1;++c<d;){var m=o(l[c]);if(!(h=a!=null&&u(a,m)))break;a=a[m]}return h||++c!=d?h:(d=a==null?0:a.length,!!d&&i(d)&&r(m,d)&&(n(a)||t(a)))}return vF=s,vF}var xF,Bhe;function bLt(){if(Bhe)return xF;Bhe=1;var e=gLt(),t=yLt();function n(r,i){return r!=null&&t(r,i,e)}return xF=n,xF}var wF,Hhe;function vLt(){if(Hhe)return wF;Hhe=1;var e=oQ(),t=JNe(),n=bLt(),r=VX(),i=yLe(),o=bLe(),s=bD(),a=1,l=2;function u(c,d){return r(c)&&i(d)?o(s(c),d):function(h){var m=t(h,c);return m===void 0&&m===d?n(h,c):e(d,m,a|l)}}return wF=u,wF}var SF,Uhe;function hS(){if(Uhe)return SF;Uhe=1;function e(t){return t}return SF=e,SF}var kF,Vhe;function xLt(){if(Vhe)return kF;Vhe=1;function e(t){return function(n){return n==null?void 0:n[t]}}return kF=e,kF}var CF,Whe;function wLt(){if(Whe)return CF;Whe=1;var e=XX();function t(n){return function(r){return e(r,n)}}return CF=t,CF}var EF,qhe;function SLt(){if(qhe)return EF;qhe=1;var e=xLt(),t=wLt(),n=VX(),r=bD();function i(o){return n(o)?e(r(o)):t(o)}return EF=i,EF}var TF,Ghe;function Wg(){if(Ghe)return TF;Ghe=1;var e=mLt(),t=vLt(),n=hS(),r=Na(),i=SLt();function o(s){return typeof s=="function"?s:s==null?n:typeof s=="object"?r(s)?t(s[0],s[1]):e(s):i(s)}return TF=o,TF}var AF,Khe;function vLe(){if(Khe)return AF;Khe=1;function e(t,n,r,i){for(var o=t.length,s=r+(i?1:-1);i?s--:++s<o;)if(n(t[s],s,t))return s;return-1}return AF=e,AF}var OF,Yhe;function kLt(){if(Yhe)return OF;Yhe=1;function e(t){return t!==t}return OF=e,OF}var RF,Xhe;function CLt(){if(Xhe)return RF;Xhe=1;function e(t,n,r){for(var i=r-1,o=t.length;++i<o;)if(t[i]===n)return i;return-1}return RF=e,RF}var MF,Qhe;function ELt(){if(Qhe)return MF;Qhe=1;var e=vLe(),t=kLt(),n=CLt();function r(i,o,s){return o===o?n(i,o,s):e(i,t,s)}return MF=r,MF}var _F,Zhe;function TLt(){if(Zhe)return _F;Zhe=1;var e=ELt();function t(n,r){var i=n==null?0:n.length;return!!i&&e(n,r,0)>-1}return _F=t,_F}var NF,Jhe;function ALt(){if(Jhe)return NF;Jhe=1;function e(t,n,r){for(var i=-1,o=t==null?0:t.length;++i<o;)if(r(n,t[i]))return!0;return!1}return NF=e,NF}var LF,epe;function OLt(){if(epe)return LF;epe=1;function e(){}return LF=e,LF}var IF,tpe;function RLt(){if(tpe)return IF;tpe=1;var e=gLe(),t=OLt(),n=tQ(),r=1/0,i=e&&1/n(new e([,-0]))[1]==r?function(o){return new e(o)}:t;return IF=i,IF}var PF,npe;function MLt(){if(npe)return PF;npe=1;var e=aLe(),t=TLt(),n=ALt(),r=uLe(),i=RLt(),o=tQ(),s=200;function a(l,u,c){var d=-1,h=t,m=l.length,g=!0,b=[],v=b;if(c)g=!1,h=n;else if(m>=s){var w=u?null:i(l);if(w)return o(w);g=!1,h=r,v=new e}else v=u?[]:b;e:for(;++d<m;){var S=l[d],C=u?u(S):S;if(S=c||S!==0?S:0,g&&C===C){for(var E=v.length;E--;)if(v[E]===C)continue e;u&&v.push(C),b.push(S)}else h(v,C,c)||(v!==b&&v.push(C),b.push(S))}return b}return PF=a,PF}var jF,rpe;function _Lt(){if(rpe)return jF;rpe=1;var e=Wg(),t=MLt();function n(r,i){return r&&r.length?t(r,e(i,2)):[]}return jF=n,jF}var NLt=_Lt();const ipe=cr(NLt);function xLe(e,t,n){return t===!0?ipe(e,n):yn(t)?ipe(e,t):e}function uw(e){"@babel/helpers - typeof";return uw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},uw(e)}var LLt=["ref"];function ope(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 bf(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ope(Object(n),!0).forEach(function(r){wD(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ope(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ILt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function spe(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,SLe(r.key),r)}}function PLt(e,t,n){return t&&spe(e.prototype,t),n&&spe(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function jLt(e,t,n){return t=mI(t),DLt(e,wLe()?Reflect.construct(t,n||[],mI(e).constructor):t.apply(e,n))}function DLt(e,t){if(t&&(uw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return $Lt(e)}function $Lt(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function wLe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(wLe=function(){return!!e})()}function mI(e){return mI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},mI(e)}function zLt(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&KV(e,t)}function KV(e,t){return KV=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},KV(e,t)}function wD(e,t,n){return t=SLe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function SLe(e){var t=FLt(e,"string");return uw(t)=="symbol"?t:t+""}function FLt(e,t){if(uw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(uw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function BLt(e,t){if(e==null)return{};var n=HLt(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function HLt(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function ULt(e){return e.value}function VLt(e,t){if(we.isValidElement(e))return we.cloneElement(e,t);if(typeof e=="function")return we.createElement(e,t);t.ref;var n=BLt(t,LLt);return we.createElement(eQ,n)}var ape=1,tb=(function(e){function t(){var n;ILt(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=jLt(this,t,[].concat(i)),wD(n,"lastBoundingBox",{width:-1,height:-1}),n}return zLt(t,e),PLt(t,[{key:"componentDidMount",value:function(){this.updateBBox()}},{key:"componentDidUpdate",value:function(){this.updateBBox()}},{key:"getBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var r=this.wrapperNode.getBoundingClientRect();return r.height=this.wrapperNode.offsetHeight,r.width=this.wrapperNode.offsetWidth,r}return null}},{key:"updateBBox",value:function(){var r=this.props.onBBoxUpdate,i=this.getBBox();i?(Math.abs(i.width-this.lastBoundingBox.width)>ape||Math.abs(i.height-this.lastBoundingBox.height)>ape)&&(this.lastBoundingBox.width=i.width,this.lastBoundingBox.height=i.height,r&&r(i)):(this.lastBoundingBox.width!==-1||this.lastBoundingBox.height!==-1)&&(this.lastBoundingBox.width=-1,this.lastBoundingBox.height=-1,r&&r(null))}},{key:"getBBoxSnapshot",value:function(){return this.lastBoundingBox.width>=0&&this.lastBoundingBox.height>=0?bf({},this.lastBoundingBox):{width:0,height:0}}},{key:"getDefaultPosition",value:function(r){var i=this.props,o=i.layout,s=i.align,a=i.verticalAlign,l=i.margin,u=i.chartWidth,c=i.chartHeight,d,h;if(!r||(r.left===void 0||r.left===null)&&(r.right===void 0||r.right===null))if(s==="center"&&o==="vertical"){var m=this.getBBoxSnapshot();d={left:((u||0)-m.width)/2}}else d=s==="right"?{right:l&&l.right||0}:{left:l&&l.left||0};if(!r||(r.top===void 0||r.top===null)&&(r.bottom===void 0||r.bottom===null))if(a==="middle"){var g=this.getBBoxSnapshot();h={top:((c||0)-g.height)/2}}else h=a==="bottom"?{bottom:l&&l.bottom||0}:{top:l&&l.top||0};return bf(bf({},d),h)}},{key:"render",value:function(){var r=this,i=this.props,o=i.content,s=i.width,a=i.height,l=i.wrapperStyle,u=i.payloadUniqBy,c=i.payload,d=bf(bf({position:"absolute",width:s||"auto",height:a||"auto"},this.getDefaultPosition(l)),l);return we.createElement("div",{className:"recharts-legend-wrapper",style:d,ref:function(m){r.wrapperNode=m}},VLt(o,bf(bf({},this.props),{},{payload:xLe(c,u,ULt)})))}}],[{key:"getWithHeight",value:function(r,i){var o=bf(bf({},this.defaultProps),r.props),s=o.layout;return s==="vertical"&&ft(r.props.height)?{height:r.props.height}:s==="horizontal"?{width:r.props.width||i}:null}}])})(A.PureComponent);wD(tb,"displayName","Legend");wD(tb,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"});var DF,lpe;function WLt(){if(lpe)return DF;lpe=1;var e=lA(),t=nQ(),n=Na(),r=e?e.isConcatSpreadable:void 0;function i(o){return n(o)||t(o)||!!(r&&o&&o[r])}return DF=i,DF}var $F,upe;function kLe(){if(upe)return $F;upe=1;var e=dLe(),t=WLt();function n(r,i,o,s,a){var l=-1,u=r.length;for(o||(o=t),a||(a=[]);++l<u;){var c=r[l];i>0&&o(c)?i>1?n(c,i-1,o,s,a):e(a,c):s||(a[a.length]=c)}return a}return $F=n,$F}var zF,cpe;function qLt(){if(cpe)return zF;cpe=1;function e(t){return function(n,r,i){for(var o=-1,s=Object(n),a=i(n),l=a.length;l--;){var u=a[t?l:++o];if(r(s[u],u,s)===!1)break}return n}}return zF=e,zF}var FF,dpe;function GLt(){if(dpe)return FF;dpe=1;var e=qLt(),t=e();return FF=t,FF}var BF,fpe;function CLe(){if(fpe)return BF;fpe=1;var e=GLt(),t=xD();function n(r,i){return r&&e(r,i,t)}return BF=n,BF}var HF,hpe;function KLt(){if(hpe)return HF;hpe=1;var e=CA();function t(n,r){return function(i,o){if(i==null)return i;if(!e(i))return n(i,o);for(var s=i.length,a=r?s:-1,l=Object(i);(r?a--:++a<s)&&o(l[a],a,l)!==!1;);return i}}return HF=t,HF}var UF,ppe;function sQ(){if(ppe)return UF;ppe=1;var e=CLe(),t=KLt(),n=t(e);return UF=n,UF}var VF,mpe;function ELe(){if(mpe)return VF;mpe=1;var e=sQ(),t=CA();function n(r,i){var o=-1,s=t(r)?Array(r.length):[];return e(r,function(a,l,u){s[++o]=i(a,l,u)}),s}return VF=n,VF}var WF,gpe;function YLt(){if(gpe)return WF;gpe=1;function e(t,n){var r=t.length;for(t.sort(n);r--;)t[r]=t[r].value;return t}return WF=e,WF}var qF,ype;function XLt(){if(ype)return qF;ype=1;var e=rS();function t(n,r){if(n!==r){var i=n!==void 0,o=n===null,s=n===n,a=e(n),l=r!==void 0,u=r===null,c=r===r,d=e(r);if(!u&&!d&&!a&&n>r||a&&l&&c&&!u&&!d||o&&l&&c||!i&&c||!s)return 1;if(!o&&!a&&!d&&n<r||d&&i&&s&&!o&&!a||u&&i&&s||!l&&s||!c)return-1}return 0}return qF=t,qF}var GF,bpe;function QLt(){if(bpe)return GF;bpe=1;var e=XLt();function t(n,r,i){for(var o=-1,s=n.criteria,a=r.criteria,l=s.length,u=i.length;++o<l;){var c=e(s[o],a[o]);if(c){if(o>=u)return c;var d=i[o];return c*(d=="desc"?-1:1)}}return n.index-r.index}return GF=t,GF}var KF,vpe;function ZLt(){if(vpe)return KF;vpe=1;var e=YX(),t=XX(),n=Wg(),r=ELe(),i=YLt(),o=hLe(),s=QLt(),a=hS(),l=Na();function u(c,d,h){d.length?d=e(d,function(b){return l(b)?function(v){return t(v,b.length===1?b[0]:b)}:b}):d=[a];var m=-1;d=e(d,o(n));var g=r(c,function(b,v,w){var S=e(d,function(C){return C(b)});return{criteria:S,index:++m,value:b}});return i(g,function(b,v){return s(b,v,h)})}return KF=u,KF}var YF,xpe;function JLt(){if(xpe)return YF;xpe=1;function e(t,n,r){switch(r.length){case 0:return t.call(n);case 1:return t.call(n,r[0]);case 2:return t.call(n,r[0],r[1]);case 3:return t.call(n,r[0],r[1],r[2])}return t.apply(n,r)}return YF=e,YF}var XF,wpe;function eIt(){if(wpe)return XF;wpe=1;var e=JLt(),t=Math.max;function n(r,i,o){return i=t(i===void 0?r.length-1:i,0),function(){for(var s=arguments,a=-1,l=t(s.length-i,0),u=Array(l);++a<l;)u[a]=s[i+a];a=-1;for(var c=Array(i+1);++a<i;)c[a]=s[a];return c[i]=o(u),e(r,this,c)}}return XF=n,XF}var QF,Spe;function tIt(){if(Spe)return QF;Spe=1;function e(t){return function(){return t}}return QF=e,QF}var ZF,kpe;function TLe(){if(kpe)return ZF;kpe=1;var e=zb(),t=(function(){try{var n=e(Object,"defineProperty");return n({},"",{}),n}catch{}})();return ZF=t,ZF}var JF,Cpe;function nIt(){if(Cpe)return JF;Cpe=1;var e=tIt(),t=TLe(),n=hS(),r=t?function(i,o){return t(i,"toString",{configurable:!0,enumerable:!1,value:e(o),writable:!0})}:n;return JF=r,JF}var eB,Epe;function rIt(){if(Epe)return eB;Epe=1;var e=800,t=16,n=Date.now;function r(i){var o=0,s=0;return function(){var a=n(),l=t-(a-s);if(s=a,l>0){if(++o>=e)return arguments[0]}else o=0;return i.apply(void 0,arguments)}}return eB=r,eB}var tB,Tpe;function iIt(){if(Tpe)return tB;Tpe=1;var e=nIt(),t=rIt(),n=t(e);return tB=n,tB}var nB,Ape;function oIt(){if(Ape)return nB;Ape=1;var e=hS(),t=eIt(),n=iIt();function r(i,o){return n(t(i,o,e),i+"")}return nB=r,nB}var rB,Ope;function SD(){if(Ope)return rB;Ope=1;var e=qX(),t=CA(),n=rQ(),r=Fg();function i(o,s,a){if(!r(a))return!1;var l=typeof s;return(l=="number"?t(a)&&n(s,a.length):l=="string"&&s in a)?e(a[s],o):!1}return rB=i,rB}var iB,Rpe;function sIt(){if(Rpe)return iB;Rpe=1;var e=kLe(),t=ZLt(),n=oIt(),r=SD(),i=n(function(o,s){if(o==null)return[];var a=s.length;return a>1&&r(o,s[0],s[1])?s=[]:a>2&&r(s[0],s[1],s[2])&&(s=[s[0]]),t(o,e(s,1),[])});return iB=i,iB}var aIt=sIt();const aQ=cr(aIt);function lT(e){"@babel/helpers - typeof";return lT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},lT(e)}function YV(){return YV=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},YV.apply(this,arguments)}function lIt(e,t){return fIt(e)||dIt(e,t)||cIt(e,t)||uIt()}function uIt(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2856
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function cIt(e,t){if(e){if(typeof e=="string")return Mpe(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Mpe(e,t)}}function Mpe(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function dIt(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,s,a=[],l=!0,u=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(l=(r=o.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(c){u=!0,i=c}finally{try{if(!l&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw i}}return a}}function fIt(e){if(Array.isArray(e))return e}function _pe(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 oB(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?_pe(Object(n),!0).forEach(function(r){hIt(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_pe(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function hIt(e,t,n){return t=pIt(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pIt(e){var t=mIt(e,"string");return lT(t)=="symbol"?t:t+""}function mIt(e,t){if(lT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(lT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function gIt(e){return Array.isArray(e)&&ho(e[0])&&ho(e[1])?e.join(" ~ "):e}var yIt=function(t){var n=t.separator,r=n===void 0?" : ":n,i=t.contentStyle,o=i===void 0?{}:i,s=t.itemStyle,a=s===void 0?{}:s,l=t.labelStyle,u=l===void 0?{}:l,c=t.payload,d=t.formatter,h=t.itemSorter,m=t.wrapperClassName,g=t.labelClassName,b=t.label,v=t.labelFormatter,w=t.accessibilityLayer,S=w===void 0?!1:w,C=function(){if(c&&c.length){var F={padding:0,margin:0},z=(h?aQ(c,h):c).map(function($,B){if($.type==="none")return null;var H=oB({display:"block",paddingTop:4,paddingBottom:4,color:$.color||"#000"},a),U=$.formatter||d||gIt,W=$.value,q=$.name,Y=W,Q=q;if(U&&Y!=null&&Q!=null){var G=U(W,q,$,B,c);if(Array.isArray(G)){var le=lIt(G,2);Y=le[0],Q=le[1]}else Y=G}return we.createElement("li",{className:"recharts-tooltip-item",key:"tooltip-item-".concat(B),style:H},ho(Q)?we.createElement("span",{className:"recharts-tooltip-item-name"},Q):null,ho(Q)?we.createElement("span",{className:"recharts-tooltip-item-separator"},r):null,we.createElement("span",{className:"recharts-tooltip-item-value"},Y),we.createElement("span",{className:"recharts-tooltip-item-unit"},$.unit||""))});return we.createElement("ul",{className:"recharts-tooltip-item-list",style:F},z)}return null},E=oB({margin:0,padding:10,backgroundColor:"#fff",border:"1px solid #ccc",whiteSpace:"nowrap"},o),T=oB({margin:0},u),O=!Rn(b),M=O?b:"",N=Hn("recharts-default-tooltip",m),I=Hn("recharts-tooltip-label",g);O&&v&&c!==void 0&&c!==null&&(M=v(b,c));var D=S?{role:"status","aria-live":"assertive"}:{};return we.createElement("div",YV({className:N,style:E},D),we.createElement("p",{className:I,style:T},we.isValidElement(M)?M:"".concat(M)),C())};function uT(e){"@babel/helpers - typeof";return uT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},uT(e)}function fM(e,t,n){return t=bIt(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function bIt(e){var t=vIt(e,"string");return uT(t)=="symbol"?t:t+""}function vIt(e,t){if(uT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(uT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Tk="recharts-tooltip-wrapper",xIt={visibility:"hidden"};function wIt(e){var t=e.coordinate,n=e.translateX,r=e.translateY;return Hn(Tk,fM(fM(fM(fM({},"".concat(Tk,"-right"),ft(n)&&t&&ft(t.x)&&n>=t.x),"".concat(Tk,"-left"),ft(n)&&t&&ft(t.x)&&n<t.x),"".concat(Tk,"-bottom"),ft(r)&&t&&ft(t.y)&&r>=t.y),"".concat(Tk,"-top"),ft(r)&&t&&ft(t.y)&&r<t.y))}function Npe(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.key,i=e.offsetTopLeft,o=e.position,s=e.reverseDirection,a=e.tooltipDimension,l=e.viewBox,u=e.viewBoxDimension;if(o&&ft(o[r]))return o[r];var c=n[r]-a-i,d=n[r]+i;if(t[r])return s[r]?c:d;if(s[r]){var h=c,m=l[r];return h<m?Math.max(d,l[r]):Math.max(c,l[r])}var g=d+a,b=l[r]+u;return g>b?Math.max(c,l[r]):Math.max(d,l[r])}function SIt(e){var t=e.translateX,n=e.translateY,r=e.useTranslate3d;return{transform:r?"translate3d(".concat(t,"px, ").concat(n,"px, 0)"):"translate(".concat(t,"px, ").concat(n,"px)")}}function kIt(e){var t=e.allowEscapeViewBox,n=e.coordinate,r=e.offsetTopLeft,i=e.position,o=e.reverseDirection,s=e.tooltipBox,a=e.useTranslate3d,l=e.viewBox,u,c,d;return s.height>0&&s.width>0&&n?(c=Npe({allowEscapeViewBox:t,coordinate:n,key:"x",offsetTopLeft:r,position:i,reverseDirection:o,tooltipDimension:s.width,viewBox:l,viewBoxDimension:l.width}),d=Npe({allowEscapeViewBox:t,coordinate:n,key:"y",offsetTopLeft:r,position:i,reverseDirection:o,tooltipDimension:s.height,viewBox:l,viewBoxDimension:l.height}),u=SIt({translateX:c,translateY:d,useTranslate3d:a})):u=xIt,{cssProperties:u,cssClasses:wIt({translateX:c,translateY:d,coordinate:n})}}function cw(e){"@babel/helpers - typeof";return cw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},cw(e)}function Lpe(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 Ipe(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Lpe(Object(n),!0).forEach(function(r){QV(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Lpe(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function CIt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function EIt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,OLe(r.key),r)}}function TIt(e,t,n){return t&&EIt(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function AIt(e,t,n){return t=gI(t),OIt(e,ALe()?Reflect.construct(t,n||[],gI(e).constructor):t.apply(e,n))}function OIt(e,t){if(t&&(cw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return RIt(e)}function RIt(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ALe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(ALe=function(){return!!e})()}function gI(e){return gI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},gI(e)}function MIt(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&XV(e,t)}function XV(e,t){return XV=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},XV(e,t)}function QV(e,t,n){return t=OLe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function OLe(e){var t=_It(e,"string");return cw(t)=="symbol"?t:t+""}function _It(e,t){if(cw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(cw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Ppe=1,NIt=(function(e){function t(){var n;CIt(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=AIt(this,t,[].concat(i)),QV(n,"state",{dismissed:!1,dismissedAtCoordinate:{x:0,y:0},lastBoundingBox:{width:-1,height:-1}}),QV(n,"handleKeyDown",function(s){if(s.key==="Escape"){var a,l,u,c;n.setState({dismissed:!0,dismissedAtCoordinate:{x:(a=(l=n.props.coordinate)===null||l===void 0?void 0:l.x)!==null&&a!==void 0?a:0,y:(u=(c=n.props.coordinate)===null||c===void 0?void 0:c.y)!==null&&u!==void 0?u:0}})}}),n}return MIt(t,e),TIt(t,[{key:"updateBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var r=this.wrapperNode.getBoundingClientRect();(Math.abs(r.width-this.state.lastBoundingBox.width)>Ppe||Math.abs(r.height-this.state.lastBoundingBox.height)>Ppe)&&this.setState({lastBoundingBox:{width:r.width,height:r.height}})}else(this.state.lastBoundingBox.width!==-1||this.state.lastBoundingBox.height!==-1)&&this.setState({lastBoundingBox:{width:-1,height:-1}})}},{key:"componentDidMount",value:function(){document.addEventListener("keydown",this.handleKeyDown),this.updateBBox()}},{key:"componentWillUnmount",value:function(){document.removeEventListener("keydown",this.handleKeyDown)}},{key:"componentDidUpdate",value:function(){var r,i;this.props.active&&this.updateBBox(),this.state.dismissed&&(((r=this.props.coordinate)===null||r===void 0?void 0:r.x)!==this.state.dismissedAtCoordinate.x||((i=this.props.coordinate)===null||i===void 0?void 0:i.y)!==this.state.dismissedAtCoordinate.y)&&(this.state.dismissed=!1)}},{key:"render",value:function(){var r=this,i=this.props,o=i.active,s=i.allowEscapeViewBox,a=i.animationDuration,l=i.animationEasing,u=i.children,c=i.coordinate,d=i.hasPayload,h=i.isAnimationActive,m=i.offset,g=i.position,b=i.reverseDirection,v=i.useTranslate3d,w=i.viewBox,S=i.wrapperStyle,C=kIt({allowEscapeViewBox:s,coordinate:c,offsetTopLeft:m,position:g,reverseDirection:b,tooltipBox:this.state.lastBoundingBox,useTranslate3d:v,viewBox:w}),E=C.cssClasses,T=C.cssProperties,O=Ipe(Ipe({transition:h&&o?"transform ".concat(a,"ms ").concat(l):void 0},T),{},{pointerEvents:"none",visibility:!this.state.dismissed&&o&&d?"visible":"hidden",position:"absolute",top:0,left:0},S);return we.createElement("div",{tabIndex:-1,className:E,style:O,ref:function(N){r.wrapperNode=N}},u)}}])})(A.PureComponent),LIt=function(){return!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout)},Fb={isSsr:LIt()};function dw(e){"@babel/helpers - typeof";return dw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},dw(e)}function jpe(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 Dpe(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?jpe(Object(n),!0).forEach(function(r){lQ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):jpe(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function IIt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function PIt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,MLe(r.key),r)}}function jIt(e,t,n){return t&&PIt(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function DIt(e,t,n){return t=yI(t),$It(e,RLe()?Reflect.construct(t,n||[],yI(e).constructor):t.apply(e,n))}function $It(e,t){if(t&&(dw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return zIt(e)}function zIt(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function RLe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(RLe=function(){return!!e})()}function yI(e){return yI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},yI(e)}function FIt(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ZV(e,t)}function ZV(e,t){return ZV=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},ZV(e,t)}function lQ(e,t,n){return t=MLe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function MLe(e){var t=BIt(e,"string");return dw(t)=="symbol"?t:t+""}function BIt(e,t){if(dw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(dw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function HIt(e){return e.dataKey}function UIt(e,t){return we.isValidElement(e)?we.cloneElement(e,t):typeof e=="function"?we.createElement(e,t):we.createElement(yIt,t)}var Fc=(function(e){function t(){return IIt(this,t),DIt(this,t,arguments)}return FIt(t,e),jIt(t,[{key:"render",value:function(){var r=this,i=this.props,o=i.active,s=i.allowEscapeViewBox,a=i.animationDuration,l=i.animationEasing,u=i.content,c=i.coordinate,d=i.filterNull,h=i.isAnimationActive,m=i.offset,g=i.payload,b=i.payloadUniqBy,v=i.position,w=i.reverseDirection,S=i.useTranslate3d,C=i.viewBox,E=i.wrapperStyle,T=g??[];d&&T.length&&(T=xLe(g.filter(function(M){return M.value!=null&&(M.hide!==!0||r.props.includeHidden)}),b,HIt));var O=T.length>0;return we.createElement(NIt,{allowEscapeViewBox:s,animationDuration:a,animationEasing:l,isAnimationActive:h,active:o,coordinate:c,hasPayload:O,offset:m,position:v,reverseDirection:w,useTranslate3d:S,viewBox:C,wrapperStyle:E},UIt(u,Dpe(Dpe({},this.props),{},{payload:T})))}}])})(A.PureComponent);lQ(Fc,"displayName","Tooltip");lQ(Fc,"defaultProps",{accessibilityLayer:!1,allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",contentStyle:{},coordinate:{x:0,y:0},cursor:!0,cursorStyle:{},filterNull:!0,isAnimationActive:!Fb.isSsr,itemStyle:{},labelStyle:{},offset:10,reverseDirection:{x:!1,y:!1},separator:" : ",trigger:"hover",useTranslate3d:!1,viewBox:{x:0,y:0,height:0,width:0},wrapperStyle:{}});var sB,$pe;function VIt(){if($pe)return sB;$pe=1;var e=YOe(),t=Fg(),n="Expected a function";function r(i,o,s){var a=!0,l=!0;if(typeof i!="function")throw new TypeError(n);return t(s)&&(a="leading"in s?!!s.leading:a,l="trailing"in s?!!s.trailing:l),e(i,o,{leading:a,maxWait:o,trailing:l})}return sB=r,sB}var WIt=VIt();const _Le=cr(WIt);function cT(e){"@babel/helpers - typeof";return cT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},cT(e)}function zpe(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 hM(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?zpe(Object(n),!0).forEach(function(r){qIt(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zpe(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function qIt(e,t,n){return t=GIt(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function GIt(e){var t=KIt(e,"string");return cT(t)=="symbol"?t:t+""}function KIt(e,t){if(cT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(cT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function YIt(e,t){return JIt(e)||ZIt(e,t)||QIt(e,t)||XIt()}function XIt(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2857
2857
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function QIt(e,t){if(e){if(typeof e=="string")return Fpe(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Fpe(e,t)}}function Fpe(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function ZIt(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,s,a=[],l=!0,u=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(l=(r=o.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(c){u=!0,i=c}finally{try{if(!l&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw i}}return a}}function JIt(e){if(Array.isArray(e))return e}var ePt=A.forwardRef(function(e,t){var n=e.aspect,r=e.initialDimension,i=r===void 0?{width:-1,height:-1}:r,o=e.width,s=o===void 0?"100%":o,a=e.height,l=a===void 0?"100%":a,u=e.minWidth,c=u===void 0?0:u,d=e.minHeight,h=e.maxHeight,m=e.children,g=e.debounce,b=g===void 0?0:g,v=e.id,w=e.className,S=e.onResize,C=e.style,E=C===void 0?{}:C,T=A.useRef(null),O=A.useRef();O.current=S,A.useImperativeHandle(t,function(){return Object.defineProperty(T.current,"current",{get:function(){return console.warn("The usage of ref.current.current is deprecated and will no longer be supported."),T.current},configurable:!0})});var M=A.useState({containerWidth:i.width,containerHeight:i.height}),N=YIt(M,2),I=N[0],D=N[1],P=A.useCallback(function(z,$){D(function(B){var H=Math.round(z),U=Math.round($);return B.containerWidth===H&&B.containerHeight===U?B:{containerWidth:H,containerHeight:U}})},[]);A.useEffect(function(){var z=function(q){var Y,Q=q[0].contentRect,G=Q.width,le=Q.height;P(G,le),(Y=O.current)===null||Y===void 0||Y.call(O,G,le)};b>0&&(z=_Le(z,b,{trailing:!0,leading:!1}));var $=new ResizeObserver(z),B=T.current.getBoundingClientRect(),H=B.width,U=B.height;return P(H,U),$.observe(T.current),function(){$.disconnect()}},[P,b]);var F=A.useMemo(function(){var z=I.containerWidth,$=I.containerHeight;if(z<0||$<0)return null;Rh(ay(s)||ay(l),`The width(%s) and height(%s) are both fixed numbers,
2858
2858
  maybe you don't need to use a ResponsiveContainer.`,s,l),Rh(!n||n>0,"The aspect(%s) must be greater than zero.",n);var B=ay(s)?z:s,H=ay(l)?$:l;n&&n>0&&(B?H=B/n:H&&(B=H*n),h&&H>h&&(H=h)),Rh(B>0||H>0,`The width(%s) and height(%s) of chart should be greater than 0,
2859
2859
  please check the style of container, or the props width(%s) and height(%s),
2860
2860
  or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the
2861
2861
  height and width.`,B,H,s,l,c,d,n);var U=!Array.isArray(m)&&Oh(m.type).endsWith("Chart");return we.Children.map(m,function(W){return we.isValidElement(W)?A.cloneElement(W,hM({width:B,height:H},U?{style:hM({height:"100%",width:"100%",maxHeight:H,maxWidth:B},W.props.style)}:{})):W})},[n,m,l,h,d,c,I,s]);return we.createElement("div",{id:v?"".concat(v):void 0,className:Hn("recharts-responsive-container",w),style:hM(hM({},E),{},{width:s,height:l,minWidth:c,minHeight:d,maxHeight:h}),ref:T},F)}),NLe=function(t){return null};NLe.displayName="Cell";function dT(e){"@babel/helpers - typeof";return dT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},dT(e)}function Bpe(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 JV(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Bpe(Object(n),!0).forEach(function(r){tPt(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Bpe(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function tPt(e,t,n){return t=nPt(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function nPt(e){var t=rPt(e,"string");return dT(t)=="symbol"?t:t+""}function rPt(e,t){if(dT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(dT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Fv={widthCache:{},cacheCount:0},iPt=2e3,oPt={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},Hpe="recharts_measurement_span";function sPt(e){var t=JV({},e);return Object.keys(t).forEach(function(n){t[n]||delete t[n]}),t}var eE=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(t==null||Fb.isSsr)return{width:0,height:0};var r=sPt(n),i=JSON.stringify({text:t,copyStyle:r});if(Fv.widthCache[i])return Fv.widthCache[i];try{var o=document.getElementById(Hpe);o||(o=document.createElement("span"),o.setAttribute("id",Hpe),o.setAttribute("aria-hidden","true"),document.body.appendChild(o));var s=JV(JV({},oPt),r);Object.assign(o.style,s),o.textContent="".concat(t);var a=o.getBoundingClientRect(),l={width:a.width,height:a.height};return Fv.widthCache[i]=l,++Fv.cacheCount>iPt&&(Fv.cacheCount=0,Fv.widthCache={}),l}catch{return{width:0,height:0}}},aPt=function(t){return{top:t.top+window.scrollY-document.documentElement.clientTop,left:t.left+window.scrollX-document.documentElement.clientLeft}};function fT(e){"@babel/helpers - typeof";return fT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},fT(e)}function bI(e,t){return dPt(e)||cPt(e,t)||uPt(e,t)||lPt()}function lPt(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2862
2862
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function uPt(e,t){if(e){if(typeof e=="string")return Upe(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Upe(e,t)}}function Upe(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function cPt(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,s,a=[],l=!0,u=!1;try{if(o=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=o.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(c){u=!0,i=c}finally{try{if(!l&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw i}}return a}}function dPt(e){if(Array.isArray(e))return e}function fPt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Vpe(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,pPt(r.key),r)}}function hPt(e,t,n){return t&&Vpe(e.prototype,t),n&&Vpe(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function pPt(e){var t=mPt(e,"string");return fT(t)=="symbol"?t:t+""}function mPt(e,t){if(fT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(fT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Wpe=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,qpe=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,gPt=/^px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q$/,yPt=/(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/,LLe={cm:96/2.54,mm:96/25.4,pt:96/72,pc:96/6,in:96,Q:96/(2.54*40),px:1},bPt=Object.keys(LLe),S1="NaN";function vPt(e,t){return e*LLe[t]}var pM=(function(){function e(t,n){fPt(this,e),this.num=t,this.unit=n,this.num=t,this.unit=n,Number.isNaN(t)&&(this.unit=""),n!==""&&!gPt.test(n)&&(this.num=NaN,this.unit=""),bPt.includes(n)&&(this.num=vPt(t,n),this.unit="px")}return hPt(e,[{key:"add",value:function(n){return this.unit!==n.unit?new e(NaN,""):new e(this.num+n.num,this.unit)}},{key:"subtract",value:function(n){return this.unit!==n.unit?new e(NaN,""):new e(this.num-n.num,this.unit)}},{key:"multiply",value:function(n){return this.unit!==""&&n.unit!==""&&this.unit!==n.unit?new e(NaN,""):new e(this.num*n.num,this.unit||n.unit)}},{key:"divide",value:function(n){return this.unit!==""&&n.unit!==""&&this.unit!==n.unit?new e(NaN,""):new e(this.num/n.num,this.unit||n.unit)}},{key:"toString",value:function(){return"".concat(this.num).concat(this.unit)}},{key:"isNaN",value:function(){return Number.isNaN(this.num)}}],[{key:"parse",value:function(n){var r,i=(r=yPt.exec(n))!==null&&r!==void 0?r:[],o=bI(i,3),s=o[1],a=o[2];return new e(parseFloat(s),a??"")}}])})();function ILe(e){if(e.includes(S1))return S1;for(var t=e;t.includes("*")||t.includes("/");){var n,r=(n=Wpe.exec(t))!==null&&n!==void 0?n:[],i=bI(r,4),o=i[1],s=i[2],a=i[3],l=pM.parse(o??""),u=pM.parse(a??""),c=s==="*"?l.multiply(u):l.divide(u);if(c.isNaN())return S1;t=t.replace(Wpe,c.toString())}for(;t.includes("+")||/.-\d+(?:\.\d+)?/.test(t);){var d,h=(d=qpe.exec(t))!==null&&d!==void 0?d:[],m=bI(h,4),g=m[1],b=m[2],v=m[3],w=pM.parse(g??""),S=pM.parse(v??""),C=b==="+"?w.add(S):w.subtract(S);if(C.isNaN())return S1;t=t.replace(qpe,C.toString())}return t}var Gpe=/\(([^()]*)\)/;function xPt(e){for(var t=e;t.includes("(");){var n=Gpe.exec(t),r=bI(n,2),i=r[1];t=t.replace(Gpe,ILe(i))}return t}function wPt(e){var t=e.replace(/\s+/g,"");return t=xPt(t),t=ILe(t),t}function SPt(e){try{return wPt(e)}catch{return S1}}function aB(e){var t=SPt(e.slice(5,-1));return t===S1?"":t}var kPt=["x","y","lineHeight","capHeight","scaleToFit","textAnchor","verticalAnchor","fill"],CPt=["dx","dy","angle","className","breakAll"];function eW(){return eW=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},eW.apply(this,arguments)}function Kpe(e,t){if(e==null)return{};var n=EPt(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function EPt(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Ype(e,t){return RPt(e)||OPt(e,t)||APt(e,t)||TPt()}function TPt(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2863
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function APt(e,t){if(e){if(typeof e=="string")return Xpe(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Xpe(e,t)}}function Xpe(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function OPt(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,s,a=[],l=!0,u=!1;try{if(o=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=o.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(c){u=!0,i=c}finally{try{if(!l&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw i}}return a}}function RPt(e){if(Array.isArray(e))return e}var PLe=/[ \f\n\r\t\v\u2028\u2029]+/,jLe=function(t){var n=t.children,r=t.breakAll,i=t.style;try{var o=[];Rn(n)||(r?o=n.toString().split(""):o=n.toString().split(PLe));var s=o.map(function(l){return{word:l,width:eE(l,i).width}}),a=r?0:eE(" ",i).width;return{wordsWithComputedWidth:s,spaceWidth:a}}catch{return null}},MPt=function(t,n,r,i,o){var s=t.maxLines,a=t.children,l=t.style,u=t.breakAll,c=ft(s),d=a,h=function(){var B=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return B.reduce(function(H,U){var W=U.word,q=U.width,Y=H[H.length-1];if(Y&&(i==null||o||Y.width+q+r<Number(i)))Y.words.push(W),Y.width+=q+r;else{var Q={words:[W],width:q};H.push(Q)}return H},[])},m=h(n),g=function(B){return B.reduce(function(H,U){return H.width>U.width?H:U})};if(!c)return m;for(var b="…",v=function(B){var H=d.slice(0,B),U=jLe({breakAll:u,style:l,children:H+b}).wordsWithComputedWidth,W=h(U),q=W.length>s||g(W).width>Number(i);return[q,W]},w=0,S=d.length-1,C=0,E;w<=S&&C<=d.length-1;){var T=Math.floor((w+S)/2),O=T-1,M=v(O),N=Ype(M,2),I=N[0],D=N[1],P=v(T),F=Ype(P,1),z=F[0];if(!I&&!z&&(w=T+1),I&&z&&(S=T-1),!I&&z){E=D;break}C++}return E||m},Qpe=function(t){var n=Rn(t)?[]:t.toString().split(PLe);return[{words:n}]},_Pt=function(t){var n=t.width,r=t.scaleToFit,i=t.children,o=t.style,s=t.breakAll,a=t.maxLines;if((n||r)&&!Fb.isSsr){var l,u,c=jLe({breakAll:s,children:i,style:o});if(c){var d=c.wordsWithComputedWidth,h=c.spaceWidth;l=d,u=h}else return Qpe(i);return MPt({breakAll:s,children:i,maxLines:a,style:o},l,u,n,r)}return Qpe(i)},Zpe="#808080",vI=function(t){var n=t.x,r=n===void 0?0:n,i=t.y,o=i===void 0?0:i,s=t.lineHeight,a=s===void 0?"1em":s,l=t.capHeight,u=l===void 0?"0.71em":l,c=t.scaleToFit,d=c===void 0?!1:c,h=t.textAnchor,m=h===void 0?"start":h,g=t.verticalAnchor,b=g===void 0?"end":g,v=t.fill,w=v===void 0?Zpe:v,S=Kpe(t,kPt),C=A.useMemo(function(){return _Pt({breakAll:S.breakAll,children:S.children,maxLines:S.maxLines,scaleToFit:d,style:S.style,width:S.width})},[S.breakAll,S.children,S.maxLines,d,S.style,S.width]),E=S.dx,T=S.dy,O=S.angle,M=S.className,N=S.breakAll,I=Kpe(S,CPt);if(!ho(r)||!ho(o))return null;var D=r+(ft(E)?E:0),P=o+(ft(T)?T:0),F;switch(b){case"start":F=aB("calc(".concat(u,")"));break;case"middle":F=aB("calc(".concat((C.length-1)/2," * -").concat(a," + (").concat(u," / 2))"));break;default:F=aB("calc(".concat(C.length-1," * -").concat(a,")"));break}var z=[];if(d){var $=C[0].width,B=S.width;z.push("scale(".concat((ft(B)?B/$:1)/$,")"))}return O&&z.push("rotate(".concat(O,", ").concat(D,", ").concat(P,")")),z.length&&(I.transform=z.join(" ")),we.createElement("text",eW({},wn(I,!0),{x:D,y:P,className:Hn("recharts-text",M),textAnchor:m,fill:w.includes("url")?Zpe:w}),C.map(function(H,U){var W=H.words.join(N?"":" ");return we.createElement("tspan",{x:D,dy:U===0?F:a,key:"".concat(W,"-").concat(U)},W)}))};const Jpe=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:Jx,scaleDiverging:rMe,scaleDivergingLog:iMe,scaleDivergingPow:XY,scaleDivergingSqrt:vkt,scaleDivergingSymlog:oMe,scaleIdentity:jRe,scaleImplicit:iV,scaleLinear:ZE,scaleLog:$Re,scaleOrdinal:PY,scalePoint:GC,scalePow:qY,scaleQuantile:BRe,scaleQuantize:HRe,scaleRadial:FRe,scaleSequential:JRe,scaleSequentialLog:eMe,scaleSequentialPow:YY,scaleSequentialQuantile:nMe,scaleSequentialSqrt:bkt,scaleSequentialSymlog:tMe,scaleSqrt:eSt,scaleSymlog:zRe,scaleThreshold:URe,scaleTime:ZRe,scaleUtc:ykt,tickFormat:PRe},Symbol.toStringTag,{value:"Module"}));var lB,eme;function DLe(){if(eme)return lB;eme=1;var e=uS();function t(n,r,i){for(var o=-1,s=n.length;++o<s;){var a=n[o],l=r(a);if(l!=null&&(u===void 0?l===l&&!e(l):i(l,u)))var u=l,c=a}return c}return lB=t,lB}var uB,tme;function NPt(){if(tme)return uB;tme=1;function e(t,n){return t>n}return uB=e,uB}var cB,nme;function LPt(){if(nme)return cB;nme=1;var e=DLe(),t=NPt(),n=hS();function r(i){return i&&i.length?e(i,n,t):void 0}return cB=r,cB}var IPt=LPt();const Xm=cr(IPt);var dB,rme;function PPt(){if(rme)return dB;rme=1;function e(t,n){return t<n}return dB=e,dB}var fB,ime;function jPt(){if(ime)return fB;ime=1;var e=DLe(),t=PPt(),n=hS();function r(i){return i&&i.length?e(i,n,t):void 0}return fB=r,fB}var DPt=jPt();const kD=cr(DPt);var hB,ome;function $Pt(){if(ome)return hB;ome=1;var e=YX(),t=Wg(),n=ELe(),r=Na();function i(o,s){var a=r(o)?e:n;return a(o,t(s,3))}return hB=i,hB}var pB,sme;function zPt(){if(sme)return pB;sme=1;var e=kLe(),t=$Pt();function n(r,i){return e(t(r,i),1)}return pB=n,pB}var FPt=zPt();const BPt=cr(FPt);var mB,ame;function HPt(){if(ame)return mB;ame=1;var e=oQ();function t(n,r){return e(n,r)}return mB=t,mB}var UPt=HPt();const fw=cr(UPt);var pS=1e9,VPt={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},cQ,di=!0,fu="[DecimalError] ",nb=fu+"Invalid argument: ",uQ=fu+"Exponent out of range: ",mS=Math.floor,F0=Math.pow,WPt=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,sl,Mo=1e7,ni=7,$Le=9007199254740991,xI=mS($Le/ni),Mt={};Mt.absoluteValue=Mt.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e};Mt.comparedTo=Mt.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};Mt.decimalPlaces=Mt.dp=function(){var e=this,t=e.d.length-1,n=(t-e.e)*ni;if(t=e.d[t],t)for(;t%10==0;t/=10)n--;return n<0?0:n};Mt.dividedBy=Mt.div=function(e){return Mh(this,new this.constructor(e))};Mt.dividedToIntegerBy=Mt.idiv=function(e){var t=this,n=t.constructor;return Fr(Mh(t,new n(e),0,1),n.precision)};Mt.equals=Mt.eq=function(e){return!this.cmp(e)};Mt.exponent=function(){return Zi(this)};Mt.greaterThan=Mt.gt=function(e){return this.cmp(e)>0};Mt.greaterThanOrEqualTo=Mt.gte=function(e){return this.cmp(e)>=0};Mt.isInteger=Mt.isint=function(){return this.e>this.d.length-2};Mt.isNegative=Mt.isneg=function(){return this.s<0};Mt.isPositive=Mt.ispos=function(){return this.s>0};Mt.isZero=function(){return this.s===0};Mt.lessThan=Mt.lt=function(e){return this.cmp(e)<0};Mt.lessThanOrEqualTo=Mt.lte=function(e){return this.cmp(e)<1};Mt.logarithm=Mt.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(sl))throw Error(fu+"NaN");if(n.s<1)throw Error(fu+(n.s?"NaN":"-Infinity"));return n.eq(sl)?new r(0):(di=!1,t=Mh(hT(n,o),hT(e,o),o),di=!0,Fr(t,i))};Mt.minus=Mt.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?BLe(t,e):zLe(t,(e.s=-e.s,e))};Mt.modulo=Mt.mod=function(e){var t,n=this,r=n.constructor,i=r.precision;if(e=new r(e),!e.s)throw Error(fu+"NaN");return n.s?(di=!1,t=Mh(n,e,0,1).times(e),di=!0,n.minus(t)):Fr(new r(n),i)};Mt.naturalExponential=Mt.exp=function(){return FLe(this)};Mt.naturalLogarithm=Mt.ln=function(){return hT(this)};Mt.negated=Mt.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};Mt.plus=Mt.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?zLe(t,e):BLe(t,(e.s=-e.s,e))};Mt.precision=Mt.sd=function(e){var t,n,r,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(nb+e);if(t=Zi(i)+1,r=i.d.length-1,n=r*ni+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};Mt.squareRoot=Mt.sqrt=function(){var e,t,n,r,i,o,s,a=this,l=a.constructor;if(a.s<1){if(!a.s)return new l(0);throw Error(fu+"NaN")}for(e=Zi(a),di=!1,i=Math.sqrt(+a),i==0||i==1/0?(t=md(a.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=mS((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 l(t)):r=new l(i.toString()),n=l.precision,i=s=n+3;;)if(o=r,r=o.plus(Mh(a,o,s+2)).times(.5),md(o.d).slice(0,s)===(t=md(r.d)).slice(0,s)){if(t=t.slice(s-3,s+1),i==s&&t=="4999"){if(Fr(o,n+1,0),o.times(o).eq(a)){r=o;break}}else if(t!="9999")break;s+=4}return di=!0,Fr(r,n)};Mt.times=Mt.mul=function(e){var t,n,r,i,o,s,a,l,u,c=this,d=c.constructor,h=c.d,m=(e=new d(e)).d;if(!c.s||!e.s)return new d(0);for(e.s*=c.s,n=c.e+e.e,l=h.length,u=m.length,l<u&&(o=h,h=m,m=o,s=l,l=u,u=s),o=[],s=l+u,r=s;r--;)o.push(0);for(r=u;--r>=0;){for(t=0,i=l+r;i>r;)a=o[i]+m[r]*h[i-r-1]+t,o[i--]=a%Mo|0,t=a/Mo|0;o[i]=(o[i]+t)%Mo|0}for(;!o[--s];)o.pop();return t?++n:o.shift(),e.d=o,e.e=n,di?Fr(e,d.precision):e};Mt.toDecimalPlaces=Mt.todp=function(e,t){var n=this,r=n.constructor;return n=new r(n),e===void 0?n:(Id(e,0,pS),t===void 0?t=r.rounding:Id(t,0,8),Fr(n,e+Zi(n)+1,t))};Mt.toExponential=function(e,t){var n,r=this,i=r.constructor;return e===void 0?n=wb(r,!0):(Id(e,0,pS),t===void 0?t=i.rounding:Id(t,0,8),r=Fr(new i(r),e+1,t),n=wb(r,!0,e+1)),n};Mt.toFixed=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?wb(i):(Id(e,0,pS),t===void 0?t=o.rounding:Id(t,0,8),r=Fr(new o(i),e+Zi(i)+1,t),n=wb(r.abs(),!1,e+Zi(r)+1),i.isneg()&&!i.isZero()?"-"+n:n)};Mt.toInteger=Mt.toint=function(){var e=this,t=e.constructor;return Fr(new t(e),Zi(e)+1,t.rounding)};Mt.toNumber=function(){return+this};Mt.toPower=Mt.pow=function(e){var t,n,r,i,o,s,a=this,l=a.constructor,u=12,c=+(e=new l(e));if(!e.s)return new l(sl);if(a=new l(a),!a.s){if(e.s<1)throw Error(fu+"Infinity");return a}if(a.eq(sl))return a;if(r=l.precision,e.eq(sl))return Fr(a,r);if(t=e.e,n=e.d.length-1,s=t>=n,o=a.s,s){if((n=c<0?-c:c)<=$Le){for(i=new l(sl),t=Math.ceil(r/ni+4),di=!1;n%2&&(i=i.times(a),ume(i.d,t)),n=mS(n/2),n!==0;)a=a.times(a),ume(a.d,t);return di=!0,e.s<0?new l(sl).div(i):Fr(i,r)}}else if(o<0)throw Error(fu+"NaN");return o=o<0&&e.d[Math.max(t,n)]&1?-1:1,a.s=1,di=!1,i=e.times(hT(a,r+u)),di=!0,i=FLe(i),i.s=o,i};Mt.toPrecision=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?(n=Zi(i),r=wb(i,n<=o.toExpNeg||n>=o.toExpPos)):(Id(e,1,pS),t===void 0?t=o.rounding:Id(t,0,8),i=Fr(new o(i),e,t),n=Zi(i),r=wb(i,e<=n||n<=o.toExpNeg,e)),r};Mt.toSignificantDigits=Mt.tosd=function(e,t){var n=this,r=n.constructor;return e===void 0?(e=r.precision,t=r.rounding):(Id(e,1,pS),t===void 0?t=r.rounding:Id(t,0,8)),Fr(new r(n),e,t)};Mt.toString=Mt.valueOf=Mt.val=Mt.toJSON=Mt[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=Zi(e),n=e.constructor;return wb(e,t<=n.toExpNeg||t>=n.toExpPos)};function zLe(e,t){var n,r,i,o,s,a,l,u,c=e.constructor,d=c.precision;if(!e.s||!t.s)return t.s||(t=new c(e)),di?Fr(t,d):t;if(l=e.d,u=t.d,s=e.e,i=t.e,l=l.slice(),o=s-i,o){for(o<0?(r=l,o=-o,a=u.length):(r=u,i=s,a=l.length),s=Math.ceil(d/ni),a=s>a?s+1:a+1,o>a&&(o=a,r.length=1),r.reverse();o--;)r.push(0);r.reverse()}for(a=l.length,o=u.length,a-o<0&&(o=a,r=u,u=l,l=r),n=0;o;)n=(l[--o]=l[o]+u[o]+n)/Mo|0,l[o]%=Mo;for(n&&(l.unshift(n),++i),a=l.length;l[--a]==0;)l.pop();return t.d=l,t.e=i,di?Fr(t,d):t}function Id(e,t,n){if(e!==~~e||e<t||e>n)throw Error(nb+e)}function md(e){var t,n,r,i=e.length-1,o="",s=e[0];if(i>0){for(o+=s,t=1;t<i;t++)r=e[t]+"",n=ni-r.length,n&&(o+=im(n)),o+=r;s=e[t],r=s+"",n=ni-r.length,n&&(o+=im(n))}else if(s===0)return"0";for(;s%10===0;)s/=10;return o+s}var Mh=(function(){function e(r,i){var o,s=0,a=r.length;for(r=r.slice();a--;)o=r[a]*i+s,r[a]=o%Mo|0,s=o/Mo|0;return s&&r.unshift(s),r}function t(r,i,o,s){var a,l;if(o!=s)l=o>s?1:-1;else for(a=l=0;a<o;a++)if(r[a]!=i[a]){l=r[a]>i[a]?1:-1;break}return l}function n(r,i,o){for(var s=0;o--;)r[o]-=s,s=r[o]<i[o]?1:0,r[o]=s*Mo+r[o]-i[o];for(;!r[0]&&r.length>1;)r.shift()}return function(r,i,o,s){var a,l,u,c,d,h,m,g,b,v,w,S,C,E,T,O,M,N,I=r.constructor,D=r.s==i.s?1:-1,P=r.d,F=i.d;if(!r.s)return new I(r);if(!i.s)throw Error(fu+"Division by zero");for(l=r.e-i.e,M=F.length,T=P.length,m=new I(D),g=m.d=[],u=0;F[u]==(P[u]||0);)++u;if(F[u]>(P[u]||0)&&--l,o==null?S=o=I.precision:s?S=o+(Zi(r)-Zi(i))+1:S=o,S<0)return new I(0);if(S=S/ni+2|0,u=0,M==1)for(c=0,F=F[0],S++;(u<T||c)&&S--;u++)C=c*Mo+(P[u]||0),g[u]=C/F|0,c=C%F|0;else{for(c=Mo/(F[0]+1)|0,c>1&&(F=e(F,c),P=e(P,c),M=F.length,T=P.length),E=M,b=P.slice(0,M),v=b.length;v<M;)b[v++]=0;N=F.slice(),N.unshift(0),O=F[0],F[1]>=Mo/2&&++O;do c=0,a=t(F,b,M,v),a<0?(w=b[0],M!=v&&(w=w*Mo+(b[1]||0)),c=w/O|0,c>1?(c>=Mo&&(c=Mo-1),d=e(F,c),h=d.length,v=b.length,a=t(d,b,h,v),a==1&&(c--,n(d,M<h?N:F,h))):(c==0&&(a=c=1),d=F.slice()),h=d.length,h<v&&d.unshift(0),n(b,d,v),a==-1&&(v=b.length,a=t(F,b,M,v),a<1&&(c++,n(b,M<v?N:F,v))),v=b.length):a===0&&(c++,b=[0]),g[u++]=c,a&&b[0]?b[v++]=P[E]||0:(b=[P[E]],v=1);while((E++<T||b[0]!==void 0)&&S--)}return g[0]||g.shift(),m.e=l,Fr(m,s?o+Zi(m)+1:o)}})();function FLe(e,t){var n,r,i,o,s,a,l=0,u=0,c=e.constructor,d=c.precision;if(Zi(e)>16)throw Error(uQ+Zi(e));if(!e.s)return new c(sl);for(di=!1,a=d,s=new c(.03125);e.abs().gte(.1);)e=e.times(s),u+=5;for(r=Math.log(F0(2,u))/Math.LN10*2+5|0,a+=r,n=i=o=new c(sl),c.precision=a;;){if(i=Fr(i.times(e),a),n=n.times(++l),s=o.plus(Mh(i,n,a)),md(s.d).slice(0,a)===md(o.d).slice(0,a)){for(;u--;)o=Fr(o.times(o),a);return c.precision=d,t==null?(di=!0,Fr(o,d)):o}o=s}}function Zi(e){for(var t=e.e*ni,n=e.d[0];n>=10;n/=10)t++;return t}function gB(e,t,n){if(t>e.LN10.sd())throw di=!0,n&&(e.precision=n),Error(fu+"LN10 precision limit exceeded");return Fr(new e(e.LN10),t)}function im(e){for(var t="";e--;)t+="0";return t}function hT(e,t){var n,r,i,o,s,a,l,u,c,d=1,h=10,m=e,g=m.d,b=m.constructor,v=b.precision;if(m.s<1)throw Error(fu+(m.s?"NaN":"-Infinity"));if(m.eq(sl))return new b(0);if(t==null?(di=!1,u=v):u=t,m.eq(10))return t==null&&(di=!0),gB(b,u);if(u+=h,b.precision=u,n=md(g),r=n.charAt(0),o=Zi(m),Math.abs(o)<15e14){for(;r<7&&r!=1||r==1&&n.charAt(1)>3;)m=m.times(e),n=md(m.d),r=n.charAt(0),d++;o=Zi(m),r>1?(m=new b("0."+n),o++):m=new b(r+"."+n.slice(1))}else return l=gB(b,u+2,v).times(o+""),m=hT(new b(r+"."+n.slice(1)),u-h).plus(l),b.precision=v,t==null?(di=!0,Fr(m,v)):m;for(a=s=m=Mh(m.minus(sl),m.plus(sl),u),c=Fr(m.times(m),u),i=3;;){if(s=Fr(s.times(c),u),l=a.plus(Mh(s,new b(i),u)),md(l.d).slice(0,u)===md(a.d).slice(0,u))return a=a.times(2),o!==0&&(a=a.plus(gB(b,u+2,v).times(o+""))),a=Mh(a,new b(d),u),b.precision=v,t==null?(di=!0,Fr(a,v)):a;a=l,i+=2}}function lme(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=mS(n/ni),e.d=[],r=(n+1)%ni,n<0&&(r+=ni),r<i){for(r&&e.d.push(+t.slice(0,r)),i-=ni;r<i;)e.d.push(+t.slice(r,r+=ni));t=t.slice(r),r=ni-t.length}else r-=i;for(;r--;)t+="0";if(e.d.push(+t),di&&(e.e>xI||e.e<-xI))throw Error(uQ+n)}else e.s=0,e.e=0,e.d=[0];return e}function Fr(e,t,n){var r,i,o,s,a,l,u,c,d=e.d;for(s=1,o=d[0];o>=10;o/=10)s++;if(r=t-s,r<0)r+=ni,i=t,u=d[c=0];else{if(c=Math.ceil((r+1)/ni),o=d.length,c>=o)return e;for(u=o=d[c],s=1;o>=10;o/=10)s++;r%=ni,i=r-ni+s}if(n!==void 0&&(o=F0(10,s-i-1),a=u/o%10|0,l=t<0||d[c+1]!==void 0||u%o,l=n<4?(a||l)&&(n==0||n==(e.s<0?3:2)):a>5||a==5&&(n==4||l||n==6&&(r>0?i>0?u/F0(10,s-i):0:d[c-1])%10&1||n==(e.s<0?8:7))),t<1||!d[0])return l?(o=Zi(e),d.length=1,t=t-o-1,d[0]=F0(10,(ni-t%ni)%ni),e.e=mS(-t/ni)||0):(d.length=1,d[0]=e.e=e.s=0),e;if(r==0?(d.length=c,o=1,c--):(d.length=c+1,o=F0(10,ni-r),d[c]=i>0?(u/F0(10,s-i)%F0(10,i)|0)*o:0),l)for(;;)if(c==0){(d[0]+=o)==Mo&&(d[0]=1,++e.e);break}else{if(d[c]+=o,d[c]!=Mo)break;d[c--]=0,o=1}for(r=d.length;d[--r]===0;)d.pop();if(di&&(e.e>xI||e.e<-xI))throw Error(uQ+Zi(e));return e}function BLe(e,t){var n,r,i,o,s,a,l,u,c,d,h=e.constructor,m=h.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new h(e),di?Fr(t,m):t;if(l=e.d,d=t.d,r=t.e,u=e.e,l=l.slice(),s=u-r,s){for(c=s<0,c?(n=l,s=-s,a=d.length):(n=d,r=u,a=l.length),i=Math.max(Math.ceil(m/ni),a)+2,s>i&&(s=i,n.length=1),n.reverse(),i=s;i--;)n.push(0);n.reverse()}else{for(i=l.length,a=d.length,c=i<a,c&&(a=i),i=0;i<a;i++)if(l[i]!=d[i]){c=l[i]<d[i];break}s=0}for(c&&(n=l,l=d,d=n,t.s=-t.s),a=l.length,i=d.length-a;i>0;--i)l[a++]=0;for(i=d.length;i>s;){if(l[--i]<d[i]){for(o=i;o&&l[--o]===0;)l[o]=Mo-1;--l[o],l[i]+=Mo}l[i]-=d[i]}for(;l[--a]===0;)l.pop();for(;l[0]===0;l.shift())--r;return l[0]?(t.d=l,t.e=r,di?Fr(t,m):t):new h(0)}function wb(e,t,n){var r,i=Zi(e),o=md(e.d),s=o.length;return t?(n&&(r=n-s)>0?o=o.charAt(0)+"."+o.slice(1)+im(r):s>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(i<0?"e":"e+")+i):i<0?(o="0."+im(-i-1)+o,n&&(r=n-s)>0&&(o+=im(r))):i>=s?(o+=im(i+1-s),n&&(r=n-i-1)>0&&(o=o+"."+im(r))):((r=i+1)<s&&(o=o.slice(0,r)+"."+o.slice(r)),n&&(r=n-s)>0&&(i+1===s&&(o+="."),o+=im(r))),e.s<0?"-"+o:o}function ume(e,t){if(e.length>t)return e.length=t,!0}function HLe(e){var t,n,r;function i(o){var s=this;if(!(s instanceof i))return new i(o);if(s.constructor=i,o instanceof i){s.s=o.s,s.e=o.e,s.d=(o=o.d)?o.slice():o;return}if(typeof o=="number"){if(o*0!==0)throw Error(nb+o);if(o>0)s.s=1;else if(o<0)o=-o,s.s=-1;else{s.s=0,s.e=0,s.d=[0];return}if(o===~~o&&o<1e7){s.e=0,s.d=[o];return}return lme(s,o.toString())}else if(typeof o!="string")throw Error(nb+o);if(o.charCodeAt(0)===45?(o=o.slice(1),s.s=-1):s.s=1,WPt.test(o))lme(s,o);else throw Error(nb+o)}if(i.prototype=Mt,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=HLe,i.config=i.set=qPt,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 qPt(e){if(!e||typeof e!="object")throw Error(fu+"Object expected");var t,n,r,i=["precision",1,pS,"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(mS(r)===r&&r>=i[t+1]&&r<=i[t+2])this[n]=r;else throw Error(nb+n+": "+r);if((r=e[n="LN10"])!==void 0)if(r==Math.LN10)this[n]=new this(r);else throw Error(nb+n+": "+r);return this}var cQ=HLe(VPt);sl=new cQ(1);const Ir=cQ;function GPt(e){return QPt(e)||XPt(e)||YPt(e)||KPt()}function KPt(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
2863
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function APt(e,t){if(e){if(typeof e=="string")return Xpe(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Xpe(e,t)}}function Xpe(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function OPt(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,s,a=[],l=!0,u=!1;try{if(o=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=o.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(c){u=!0,i=c}finally{try{if(!l&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw i}}return a}}function RPt(e){if(Array.isArray(e))return e}var PLe=/[ \f\n\r\t\v\u2028\u2029]+/,jLe=function(t){var n=t.children,r=t.breakAll,i=t.style;try{var o=[];Rn(n)||(r?o=n.toString().split(""):o=n.toString().split(PLe));var s=o.map(function(l){return{word:l,width:eE(l,i).width}}),a=r?0:eE(" ",i).width;return{wordsWithComputedWidth:s,spaceWidth:a}}catch{return null}},MPt=function(t,n,r,i,o){var s=t.maxLines,a=t.children,l=t.style,u=t.breakAll,c=ft(s),d=a,h=function(){var B=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return B.reduce(function(H,U){var W=U.word,q=U.width,Y=H[H.length-1];if(Y&&(i==null||o||Y.width+q+r<Number(i)))Y.words.push(W),Y.width+=q+r;else{var Q={words:[W],width:q};H.push(Q)}return H},[])},m=h(n),g=function(B){return B.reduce(function(H,U){return H.width>U.width?H:U})};if(!c)return m;for(var b="…",v=function(B){var H=d.slice(0,B),U=jLe({breakAll:u,style:l,children:H+b}).wordsWithComputedWidth,W=h(U),q=W.length>s||g(W).width>Number(i);return[q,W]},w=0,S=d.length-1,C=0,E;w<=S&&C<=d.length-1;){var T=Math.floor((w+S)/2),O=T-1,M=v(O),N=Ype(M,2),I=N[0],D=N[1],P=v(T),F=Ype(P,1),z=F[0];if(!I&&!z&&(w=T+1),I&&z&&(S=T-1),!I&&z){E=D;break}C++}return E||m},Qpe=function(t){var n=Rn(t)?[]:t.toString().split(PLe);return[{words:n}]},_Pt=function(t){var n=t.width,r=t.scaleToFit,i=t.children,o=t.style,s=t.breakAll,a=t.maxLines;if((n||r)&&!Fb.isSsr){var l,u,c=jLe({breakAll:s,children:i,style:o});if(c){var d=c.wordsWithComputedWidth,h=c.spaceWidth;l=d,u=h}else return Qpe(i);return MPt({breakAll:s,children:i,maxLines:a,style:o},l,u,n,r)}return Qpe(i)},Zpe="#808080",vI=function(t){var n=t.x,r=n===void 0?0:n,i=t.y,o=i===void 0?0:i,s=t.lineHeight,a=s===void 0?"1em":s,l=t.capHeight,u=l===void 0?"0.71em":l,c=t.scaleToFit,d=c===void 0?!1:c,h=t.textAnchor,m=h===void 0?"start":h,g=t.verticalAnchor,b=g===void 0?"end":g,v=t.fill,w=v===void 0?Zpe:v,S=Kpe(t,kPt),C=A.useMemo(function(){return _Pt({breakAll:S.breakAll,children:S.children,maxLines:S.maxLines,scaleToFit:d,style:S.style,width:S.width})},[S.breakAll,S.children,S.maxLines,d,S.style,S.width]),E=S.dx,T=S.dy,O=S.angle,M=S.className,N=S.breakAll,I=Kpe(S,CPt);if(!ho(r)||!ho(o))return null;var D=r+(ft(E)?E:0),P=o+(ft(T)?T:0),F;switch(b){case"start":F=aB("calc(".concat(u,")"));break;case"middle":F=aB("calc(".concat((C.length-1)/2," * -").concat(a," + (").concat(u," / 2))"));break;default:F=aB("calc(".concat(C.length-1," * -").concat(a,")"));break}var z=[];if(d){var $=C[0].width,B=S.width;z.push("scale(".concat((ft(B)?B/$:1)/$,")"))}return O&&z.push("rotate(".concat(O,", ").concat(D,", ").concat(P,")")),z.length&&(I.transform=z.join(" ")),we.createElement("text",eW({},wn(I,!0),{x:D,y:P,className:Hn("recharts-text",M),textAnchor:m,fill:w.includes("url")?Zpe:w}),C.map(function(H,U){var W=H.words.join(N?"":" ");return we.createElement("tspan",{x:D,dy:U===0?F:a,key:"".concat(W,"-").concat(U)},W)}))};const Jpe=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:Jx,scaleDiverging:sMe,scaleDivergingLog:aMe,scaleDivergingPow:QY,scaleDivergingSqrt:Rkt,scaleDivergingSymlog:lMe,scaleIdentity:zRe,scaleImplicit:iV,scaleLinear:ZE,scaleLog:BRe,scaleOrdinal:jY,scalePoint:GC,scalePow:GY,scaleQuantile:VRe,scaleQuantize:WRe,scaleRadial:URe,scaleSequential:nMe,scaleSequentialLog:rMe,scaleSequentialPow:XY,scaleSequentialQuantile:oMe,scaleSequentialSqrt:Okt,scaleSequentialSymlog:iMe,scaleSqrt:cSt,scaleSymlog:HRe,scaleThreshold:qRe,scaleTime:tMe,scaleUtc:Akt,tickFormat:$Re},Symbol.toStringTag,{value:"Module"}));var lB,eme;function DLe(){if(eme)return lB;eme=1;var e=rS();function t(n,r,i){for(var o=-1,s=n.length;++o<s;){var a=n[o],l=r(a);if(l!=null&&(u===void 0?l===l&&!e(l):i(l,u)))var u=l,c=a}return c}return lB=t,lB}var uB,tme;function NPt(){if(tme)return uB;tme=1;function e(t,n){return t>n}return uB=e,uB}var cB,nme;function LPt(){if(nme)return cB;nme=1;var e=DLe(),t=NPt(),n=hS();function r(i){return i&&i.length?e(i,n,t):void 0}return cB=r,cB}var IPt=LPt();const Xm=cr(IPt);var dB,rme;function PPt(){if(rme)return dB;rme=1;function e(t,n){return t<n}return dB=e,dB}var fB,ime;function jPt(){if(ime)return fB;ime=1;var e=DLe(),t=PPt(),n=hS();function r(i){return i&&i.length?e(i,n,t):void 0}return fB=r,fB}var DPt=jPt();const kD=cr(DPt);var hB,ome;function $Pt(){if(ome)return hB;ome=1;var e=YX(),t=Wg(),n=ELe(),r=Na();function i(o,s){var a=r(o)?e:n;return a(o,t(s,3))}return hB=i,hB}var pB,sme;function zPt(){if(sme)return pB;sme=1;var e=kLe(),t=$Pt();function n(r,i){return e(t(r,i),1)}return pB=n,pB}var FPt=zPt();const BPt=cr(FPt);var mB,ame;function HPt(){if(ame)return mB;ame=1;var e=oQ();function t(n,r){return e(n,r)}return mB=t,mB}var UPt=HPt();const fw=cr(UPt);var pS=1e9,VPt={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},cQ,di=!0,fu="[DecimalError] ",nb=fu+"Invalid argument: ",uQ=fu+"Exponent out of range: ",mS=Math.floor,F0=Math.pow,WPt=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,sl,Mo=1e7,ni=7,$Le=9007199254740991,xI=mS($Le/ni),Mt={};Mt.absoluteValue=Mt.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e};Mt.comparedTo=Mt.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};Mt.decimalPlaces=Mt.dp=function(){var e=this,t=e.d.length-1,n=(t-e.e)*ni;if(t=e.d[t],t)for(;t%10==0;t/=10)n--;return n<0?0:n};Mt.dividedBy=Mt.div=function(e){return Mh(this,new this.constructor(e))};Mt.dividedToIntegerBy=Mt.idiv=function(e){var t=this,n=t.constructor;return Fr(Mh(t,new n(e),0,1),n.precision)};Mt.equals=Mt.eq=function(e){return!this.cmp(e)};Mt.exponent=function(){return Zi(this)};Mt.greaterThan=Mt.gt=function(e){return this.cmp(e)>0};Mt.greaterThanOrEqualTo=Mt.gte=function(e){return this.cmp(e)>=0};Mt.isInteger=Mt.isint=function(){return this.e>this.d.length-2};Mt.isNegative=Mt.isneg=function(){return this.s<0};Mt.isPositive=Mt.ispos=function(){return this.s>0};Mt.isZero=function(){return this.s===0};Mt.lessThan=Mt.lt=function(e){return this.cmp(e)<0};Mt.lessThanOrEqualTo=Mt.lte=function(e){return this.cmp(e)<1};Mt.logarithm=Mt.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(sl))throw Error(fu+"NaN");if(n.s<1)throw Error(fu+(n.s?"NaN":"-Infinity"));return n.eq(sl)?new r(0):(di=!1,t=Mh(hT(n,o),hT(e,o),o),di=!0,Fr(t,i))};Mt.minus=Mt.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?BLe(t,e):zLe(t,(e.s=-e.s,e))};Mt.modulo=Mt.mod=function(e){var t,n=this,r=n.constructor,i=r.precision;if(e=new r(e),!e.s)throw Error(fu+"NaN");return n.s?(di=!1,t=Mh(n,e,0,1).times(e),di=!0,n.minus(t)):Fr(new r(n),i)};Mt.naturalExponential=Mt.exp=function(){return FLe(this)};Mt.naturalLogarithm=Mt.ln=function(){return hT(this)};Mt.negated=Mt.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};Mt.plus=Mt.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?zLe(t,e):BLe(t,(e.s=-e.s,e))};Mt.precision=Mt.sd=function(e){var t,n,r,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(nb+e);if(t=Zi(i)+1,r=i.d.length-1,n=r*ni+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};Mt.squareRoot=Mt.sqrt=function(){var e,t,n,r,i,o,s,a=this,l=a.constructor;if(a.s<1){if(!a.s)return new l(0);throw Error(fu+"NaN")}for(e=Zi(a),di=!1,i=Math.sqrt(+a),i==0||i==1/0?(t=md(a.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=mS((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 l(t)):r=new l(i.toString()),n=l.precision,i=s=n+3;;)if(o=r,r=o.plus(Mh(a,o,s+2)).times(.5),md(o.d).slice(0,s)===(t=md(r.d)).slice(0,s)){if(t=t.slice(s-3,s+1),i==s&&t=="4999"){if(Fr(o,n+1,0),o.times(o).eq(a)){r=o;break}}else if(t!="9999")break;s+=4}return di=!0,Fr(r,n)};Mt.times=Mt.mul=function(e){var t,n,r,i,o,s,a,l,u,c=this,d=c.constructor,h=c.d,m=(e=new d(e)).d;if(!c.s||!e.s)return new d(0);for(e.s*=c.s,n=c.e+e.e,l=h.length,u=m.length,l<u&&(o=h,h=m,m=o,s=l,l=u,u=s),o=[],s=l+u,r=s;r--;)o.push(0);for(r=u;--r>=0;){for(t=0,i=l+r;i>r;)a=o[i]+m[r]*h[i-r-1]+t,o[i--]=a%Mo|0,t=a/Mo|0;o[i]=(o[i]+t)%Mo|0}for(;!o[--s];)o.pop();return t?++n:o.shift(),e.d=o,e.e=n,di?Fr(e,d.precision):e};Mt.toDecimalPlaces=Mt.todp=function(e,t){var n=this,r=n.constructor;return n=new r(n),e===void 0?n:(Id(e,0,pS),t===void 0?t=r.rounding:Id(t,0,8),Fr(n,e+Zi(n)+1,t))};Mt.toExponential=function(e,t){var n,r=this,i=r.constructor;return e===void 0?n=wb(r,!0):(Id(e,0,pS),t===void 0?t=i.rounding:Id(t,0,8),r=Fr(new i(r),e+1,t),n=wb(r,!0,e+1)),n};Mt.toFixed=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?wb(i):(Id(e,0,pS),t===void 0?t=o.rounding:Id(t,0,8),r=Fr(new o(i),e+Zi(i)+1,t),n=wb(r.abs(),!1,e+Zi(r)+1),i.isneg()&&!i.isZero()?"-"+n:n)};Mt.toInteger=Mt.toint=function(){var e=this,t=e.constructor;return Fr(new t(e),Zi(e)+1,t.rounding)};Mt.toNumber=function(){return+this};Mt.toPower=Mt.pow=function(e){var t,n,r,i,o,s,a=this,l=a.constructor,u=12,c=+(e=new l(e));if(!e.s)return new l(sl);if(a=new l(a),!a.s){if(e.s<1)throw Error(fu+"Infinity");return a}if(a.eq(sl))return a;if(r=l.precision,e.eq(sl))return Fr(a,r);if(t=e.e,n=e.d.length-1,s=t>=n,o=a.s,s){if((n=c<0?-c:c)<=$Le){for(i=new l(sl),t=Math.ceil(r/ni+4),di=!1;n%2&&(i=i.times(a),ume(i.d,t)),n=mS(n/2),n!==0;)a=a.times(a),ume(a.d,t);return di=!0,e.s<0?new l(sl).div(i):Fr(i,r)}}else if(o<0)throw Error(fu+"NaN");return o=o<0&&e.d[Math.max(t,n)]&1?-1:1,a.s=1,di=!1,i=e.times(hT(a,r+u)),di=!0,i=FLe(i),i.s=o,i};Mt.toPrecision=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?(n=Zi(i),r=wb(i,n<=o.toExpNeg||n>=o.toExpPos)):(Id(e,1,pS),t===void 0?t=o.rounding:Id(t,0,8),i=Fr(new o(i),e,t),n=Zi(i),r=wb(i,e<=n||n<=o.toExpNeg,e)),r};Mt.toSignificantDigits=Mt.tosd=function(e,t){var n=this,r=n.constructor;return e===void 0?(e=r.precision,t=r.rounding):(Id(e,1,pS),t===void 0?t=r.rounding:Id(t,0,8)),Fr(new r(n),e,t)};Mt.toString=Mt.valueOf=Mt.val=Mt.toJSON=Mt[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=Zi(e),n=e.constructor;return wb(e,t<=n.toExpNeg||t>=n.toExpPos)};function zLe(e,t){var n,r,i,o,s,a,l,u,c=e.constructor,d=c.precision;if(!e.s||!t.s)return t.s||(t=new c(e)),di?Fr(t,d):t;if(l=e.d,u=t.d,s=e.e,i=t.e,l=l.slice(),o=s-i,o){for(o<0?(r=l,o=-o,a=u.length):(r=u,i=s,a=l.length),s=Math.ceil(d/ni),a=s>a?s+1:a+1,o>a&&(o=a,r.length=1),r.reverse();o--;)r.push(0);r.reverse()}for(a=l.length,o=u.length,a-o<0&&(o=a,r=u,u=l,l=r),n=0;o;)n=(l[--o]=l[o]+u[o]+n)/Mo|0,l[o]%=Mo;for(n&&(l.unshift(n),++i),a=l.length;l[--a]==0;)l.pop();return t.d=l,t.e=i,di?Fr(t,d):t}function Id(e,t,n){if(e!==~~e||e<t||e>n)throw Error(nb+e)}function md(e){var t,n,r,i=e.length-1,o="",s=e[0];if(i>0){for(o+=s,t=1;t<i;t++)r=e[t]+"",n=ni-r.length,n&&(o+=im(n)),o+=r;s=e[t],r=s+"",n=ni-r.length,n&&(o+=im(n))}else if(s===0)return"0";for(;s%10===0;)s/=10;return o+s}var Mh=(function(){function e(r,i){var o,s=0,a=r.length;for(r=r.slice();a--;)o=r[a]*i+s,r[a]=o%Mo|0,s=o/Mo|0;return s&&r.unshift(s),r}function t(r,i,o,s){var a,l;if(o!=s)l=o>s?1:-1;else for(a=l=0;a<o;a++)if(r[a]!=i[a]){l=r[a]>i[a]?1:-1;break}return l}function n(r,i,o){for(var s=0;o--;)r[o]-=s,s=r[o]<i[o]?1:0,r[o]=s*Mo+r[o]-i[o];for(;!r[0]&&r.length>1;)r.shift()}return function(r,i,o,s){var a,l,u,c,d,h,m,g,b,v,w,S,C,E,T,O,M,N,I=r.constructor,D=r.s==i.s?1:-1,P=r.d,F=i.d;if(!r.s)return new I(r);if(!i.s)throw Error(fu+"Division by zero");for(l=r.e-i.e,M=F.length,T=P.length,m=new I(D),g=m.d=[],u=0;F[u]==(P[u]||0);)++u;if(F[u]>(P[u]||0)&&--l,o==null?S=o=I.precision:s?S=o+(Zi(r)-Zi(i))+1:S=o,S<0)return new I(0);if(S=S/ni+2|0,u=0,M==1)for(c=0,F=F[0],S++;(u<T||c)&&S--;u++)C=c*Mo+(P[u]||0),g[u]=C/F|0,c=C%F|0;else{for(c=Mo/(F[0]+1)|0,c>1&&(F=e(F,c),P=e(P,c),M=F.length,T=P.length),E=M,b=P.slice(0,M),v=b.length;v<M;)b[v++]=0;N=F.slice(),N.unshift(0),O=F[0],F[1]>=Mo/2&&++O;do c=0,a=t(F,b,M,v),a<0?(w=b[0],M!=v&&(w=w*Mo+(b[1]||0)),c=w/O|0,c>1?(c>=Mo&&(c=Mo-1),d=e(F,c),h=d.length,v=b.length,a=t(d,b,h,v),a==1&&(c--,n(d,M<h?N:F,h))):(c==0&&(a=c=1),d=F.slice()),h=d.length,h<v&&d.unshift(0),n(b,d,v),a==-1&&(v=b.length,a=t(F,b,M,v),a<1&&(c++,n(b,M<v?N:F,v))),v=b.length):a===0&&(c++,b=[0]),g[u++]=c,a&&b[0]?b[v++]=P[E]||0:(b=[P[E]],v=1);while((E++<T||b[0]!==void 0)&&S--)}return g[0]||g.shift(),m.e=l,Fr(m,s?o+Zi(m)+1:o)}})();function FLe(e,t){var n,r,i,o,s,a,l=0,u=0,c=e.constructor,d=c.precision;if(Zi(e)>16)throw Error(uQ+Zi(e));if(!e.s)return new c(sl);for(di=!1,a=d,s=new c(.03125);e.abs().gte(.1);)e=e.times(s),u+=5;for(r=Math.log(F0(2,u))/Math.LN10*2+5|0,a+=r,n=i=o=new c(sl),c.precision=a;;){if(i=Fr(i.times(e),a),n=n.times(++l),s=o.plus(Mh(i,n,a)),md(s.d).slice(0,a)===md(o.d).slice(0,a)){for(;u--;)o=Fr(o.times(o),a);return c.precision=d,t==null?(di=!0,Fr(o,d)):o}o=s}}function Zi(e){for(var t=e.e*ni,n=e.d[0];n>=10;n/=10)t++;return t}function gB(e,t,n){if(t>e.LN10.sd())throw di=!0,n&&(e.precision=n),Error(fu+"LN10 precision limit exceeded");return Fr(new e(e.LN10),t)}function im(e){for(var t="";e--;)t+="0";return t}function hT(e,t){var n,r,i,o,s,a,l,u,c,d=1,h=10,m=e,g=m.d,b=m.constructor,v=b.precision;if(m.s<1)throw Error(fu+(m.s?"NaN":"-Infinity"));if(m.eq(sl))return new b(0);if(t==null?(di=!1,u=v):u=t,m.eq(10))return t==null&&(di=!0),gB(b,u);if(u+=h,b.precision=u,n=md(g),r=n.charAt(0),o=Zi(m),Math.abs(o)<15e14){for(;r<7&&r!=1||r==1&&n.charAt(1)>3;)m=m.times(e),n=md(m.d),r=n.charAt(0),d++;o=Zi(m),r>1?(m=new b("0."+n),o++):m=new b(r+"."+n.slice(1))}else return l=gB(b,u+2,v).times(o+""),m=hT(new b(r+"."+n.slice(1)),u-h).plus(l),b.precision=v,t==null?(di=!0,Fr(m,v)):m;for(a=s=m=Mh(m.minus(sl),m.plus(sl),u),c=Fr(m.times(m),u),i=3;;){if(s=Fr(s.times(c),u),l=a.plus(Mh(s,new b(i),u)),md(l.d).slice(0,u)===md(a.d).slice(0,u))return a=a.times(2),o!==0&&(a=a.plus(gB(b,u+2,v).times(o+""))),a=Mh(a,new b(d),u),b.precision=v,t==null?(di=!0,Fr(a,v)):a;a=l,i+=2}}function lme(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=mS(n/ni),e.d=[],r=(n+1)%ni,n<0&&(r+=ni),r<i){for(r&&e.d.push(+t.slice(0,r)),i-=ni;r<i;)e.d.push(+t.slice(r,r+=ni));t=t.slice(r),r=ni-t.length}else r-=i;for(;r--;)t+="0";if(e.d.push(+t),di&&(e.e>xI||e.e<-xI))throw Error(uQ+n)}else e.s=0,e.e=0,e.d=[0];return e}function Fr(e,t,n){var r,i,o,s,a,l,u,c,d=e.d;for(s=1,o=d[0];o>=10;o/=10)s++;if(r=t-s,r<0)r+=ni,i=t,u=d[c=0];else{if(c=Math.ceil((r+1)/ni),o=d.length,c>=o)return e;for(u=o=d[c],s=1;o>=10;o/=10)s++;r%=ni,i=r-ni+s}if(n!==void 0&&(o=F0(10,s-i-1),a=u/o%10|0,l=t<0||d[c+1]!==void 0||u%o,l=n<4?(a||l)&&(n==0||n==(e.s<0?3:2)):a>5||a==5&&(n==4||l||n==6&&(r>0?i>0?u/F0(10,s-i):0:d[c-1])%10&1||n==(e.s<0?8:7))),t<1||!d[0])return l?(o=Zi(e),d.length=1,t=t-o-1,d[0]=F0(10,(ni-t%ni)%ni),e.e=mS(-t/ni)||0):(d.length=1,d[0]=e.e=e.s=0),e;if(r==0?(d.length=c,o=1,c--):(d.length=c+1,o=F0(10,ni-r),d[c]=i>0?(u/F0(10,s-i)%F0(10,i)|0)*o:0),l)for(;;)if(c==0){(d[0]+=o)==Mo&&(d[0]=1,++e.e);break}else{if(d[c]+=o,d[c]!=Mo)break;d[c--]=0,o=1}for(r=d.length;d[--r]===0;)d.pop();if(di&&(e.e>xI||e.e<-xI))throw Error(uQ+Zi(e));return e}function BLe(e,t){var n,r,i,o,s,a,l,u,c,d,h=e.constructor,m=h.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new h(e),di?Fr(t,m):t;if(l=e.d,d=t.d,r=t.e,u=e.e,l=l.slice(),s=u-r,s){for(c=s<0,c?(n=l,s=-s,a=d.length):(n=d,r=u,a=l.length),i=Math.max(Math.ceil(m/ni),a)+2,s>i&&(s=i,n.length=1),n.reverse(),i=s;i--;)n.push(0);n.reverse()}else{for(i=l.length,a=d.length,c=i<a,c&&(a=i),i=0;i<a;i++)if(l[i]!=d[i]){c=l[i]<d[i];break}s=0}for(c&&(n=l,l=d,d=n,t.s=-t.s),a=l.length,i=d.length-a;i>0;--i)l[a++]=0;for(i=d.length;i>s;){if(l[--i]<d[i]){for(o=i;o&&l[--o]===0;)l[o]=Mo-1;--l[o],l[i]+=Mo}l[i]-=d[i]}for(;l[--a]===0;)l.pop();for(;l[0]===0;l.shift())--r;return l[0]?(t.d=l,t.e=r,di?Fr(t,m):t):new h(0)}function wb(e,t,n){var r,i=Zi(e),o=md(e.d),s=o.length;return t?(n&&(r=n-s)>0?o=o.charAt(0)+"."+o.slice(1)+im(r):s>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(i<0?"e":"e+")+i):i<0?(o="0."+im(-i-1)+o,n&&(r=n-s)>0&&(o+=im(r))):i>=s?(o+=im(i+1-s),n&&(r=n-i-1)>0&&(o=o+"."+im(r))):((r=i+1)<s&&(o=o.slice(0,r)+"."+o.slice(r)),n&&(r=n-s)>0&&(i+1===s&&(o+="."),o+=im(r))),e.s<0?"-"+o:o}function ume(e,t){if(e.length>t)return e.length=t,!0}function HLe(e){var t,n,r;function i(o){var s=this;if(!(s instanceof i))return new i(o);if(s.constructor=i,o instanceof i){s.s=o.s,s.e=o.e,s.d=(o=o.d)?o.slice():o;return}if(typeof o=="number"){if(o*0!==0)throw Error(nb+o);if(o>0)s.s=1;else if(o<0)o=-o,s.s=-1;else{s.s=0,s.e=0,s.d=[0];return}if(o===~~o&&o<1e7){s.e=0,s.d=[o];return}return lme(s,o.toString())}else if(typeof o!="string")throw Error(nb+o);if(o.charCodeAt(0)===45?(o=o.slice(1),s.s=-1):s.s=1,WPt.test(o))lme(s,o);else throw Error(nb+o)}if(i.prototype=Mt,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=HLe,i.config=i.set=qPt,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 qPt(e){if(!e||typeof e!="object")throw Error(fu+"Object expected");var t,n,r,i=["precision",1,pS,"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(mS(r)===r&&r>=i[t+1]&&r<=i[t+2])this[n]=r;else throw Error(nb+n+": "+r);if((r=e[n="LN10"])!==void 0)if(r==Math.LN10)this[n]=new this(r);else throw Error(nb+n+": "+r);return this}var cQ=HLe(VPt);sl=new cQ(1);const Ir=cQ;function GPt(e){return QPt(e)||XPt(e)||YPt(e)||KPt()}function KPt(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
2864
2864
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function YPt(e,t){if(e){if(typeof e=="string")return tW(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return tW(e,t)}}function XPt(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function QPt(e){if(Array.isArray(e))return tW(e)}function tW(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var ZPt=function(t){return t},ULe={},VLe=function(t){return t===ULe},cme=function(t){return function n(){return arguments.length===0||arguments.length===1&&VLe(arguments.length<=0?void 0:arguments[0])?n:t.apply(void 0,arguments)}},JPt=function e(t,n){return t===1?n:cme(function(){for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];var s=i.filter(function(a){return a!==ULe}).length;return s>=t?n.apply(void 0,i):e(t-s,cme(function(){for(var a=arguments.length,l=new Array(a),u=0;u<a;u++)l[u]=arguments[u];var c=i.map(function(d){return VLe(d)?l.shift():d});return n.apply(void 0,GPt(c).concat(l))}))})},CD=function(t){return JPt(t.length,t)},nW=function(t,n){for(var r=[],i=t;i<n;++i)r[i-t]=i;return r},ejt=CD(function(e,t){return Array.isArray(t)?t.map(e):Object.keys(t).map(function(n){return t[n]}).map(e)}),tjt=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];if(!n.length)return ZPt;var i=n.reverse(),o=i[0],s=i.slice(1);return function(){return s.reduce(function(a,l){return l(a)},o.apply(void 0,arguments))}},rW=function(t){return Array.isArray(t)?t.reverse():t.split("").reverse.join("")},WLe=function(t){var n=null,r=null;return function(){for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return n&&o.every(function(a,l){return a===n[l]})||(n=o,r=t.apply(void 0,o)),r}};function njt(e){var t;return e===0?t=1:t=Math.floor(new Ir(e).abs().log(10).toNumber())+1,t}function rjt(e,t,n){for(var r=new Ir(e),i=0,o=[];r.lt(t)&&i<1e5;)o.push(r.toNumber()),r=r.add(n),i++;return o}var ijt=CD(function(e,t,n){var r=+e,i=+t;return r+n*(i-r)}),ojt=CD(function(e,t,n){var r=t-+e;return r=r||1/0,(n-e)/r}),sjt=CD(function(e,t,n){var r=t-+e;return r=r||1/0,Math.max(0,Math.min(1,(n-e)/r))});const ED={rangeStep:rjt,getDigitCount:njt,interpolateNumber:ijt,uninterpolateNumber:ojt,uninterpolateTruncation:sjt};function iW(e){return ujt(e)||ljt(e)||qLe(e)||ajt()}function ajt(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
2865
2865
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ljt(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function ujt(e){if(Array.isArray(e))return oW(e)}function pT(e,t){return fjt(e)||djt(e,t)||qLe(e,t)||cjt()}function cjt(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2866
2866
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function qLe(e,t){if(e){if(typeof e=="string")return oW(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return oW(e,t)}}function oW(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function djt(e,t){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(e)))){var n=[],r=!0,i=!1,o=void 0;try{for(var s=e[Symbol.iterator](),a;!(r=(a=s.next()).done)&&(n.push(a.value),!(t&&n.length===t));r=!0);}catch(l){i=!0,o=l}finally{try{!r&&s.return!=null&&s.return()}finally{if(i)throw o}}return n}}function fjt(e){if(Array.isArray(e))return e}function GLe(e){var t=pT(e,2),n=t[0],r=t[1],i=n,o=r;return n>r&&(i=r,o=n),[i,o]}function KLe(e,t,n){if(e.lte(0))return new Ir(0);var r=ED.getDigitCount(e.toNumber()),i=new Ir(10).pow(r),o=e.div(i),s=r!==1?.05:.1,a=new Ir(Math.ceil(o.div(s).toNumber())).add(n).mul(s),l=a.mul(i);return t?l:new Ir(Math.ceil(l))}function hjt(e,t,n){var r=1,i=new Ir(e);if(!i.isint()&&n){var o=Math.abs(e);o<1?(r=new Ir(10).pow(ED.getDigitCount(e)-1),i=new Ir(Math.floor(i.div(r).toNumber())).mul(r)):o>1&&(i=new Ir(Math.floor(e)))}else e===0?i=new Ir(Math.floor((t-1)/2)):n||(i=new Ir(Math.floor(e)));var s=Math.floor((t-1)/2),a=tjt(ejt(function(l){return i.add(new Ir(l-s).mul(r)).toNumber()}),nW);return a(0,t)}function YLe(e,t,n,r){var i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;if(!Number.isFinite((t-e)/(n-1)))return{step:new Ir(0),tickMin:new Ir(0),tickMax:new Ir(0)};var o=KLe(new Ir(t).sub(e).div(n-1),r,i),s;e<=0&&t>=0?s=new Ir(0):(s=new Ir(e).add(t).div(2),s=s.sub(new Ir(s).mod(o)));var a=Math.ceil(s.sub(e).div(o).toNumber()),l=Math.ceil(new Ir(t).sub(s).div(o).toNumber()),u=a+l+1;return u>n?YLe(e,t,n,r,i+1):(u<n&&(l=t>0?l+(n-u):l,a=t>0?a:a+(n-u)),{step:o,tickMin:s.sub(new Ir(a).mul(o)),tickMax:s.add(new Ir(l).mul(o))})}function pjt(e){var t=pT(e,2),n=t[0],r=t[1],i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,s=Math.max(i,2),a=GLe([n,r]),l=pT(a,2),u=l[0],c=l[1];if(u===-1/0||c===1/0){var d=c===1/0?[u].concat(iW(nW(0,i-1).map(function(){return 1/0}))):[].concat(iW(nW(0,i-1).map(function(){return-1/0})),[c]);return n>r?rW(d):d}if(u===c)return hjt(u,i,o);var h=YLe(u,c,s,o),m=h.step,g=h.tickMin,b=h.tickMax,v=ED.rangeStep(g,b.add(new Ir(.1).mul(m)),m);return n>r?rW(v):v}function mjt(e,t){var n=pT(e,2),r=n[0],i=n[1],o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,s=GLe([r,i]),a=pT(s,2),l=a[0],u=a[1];if(l===-1/0||u===1/0)return[r,i];if(l===u)return[l];var c=Math.max(t,2),d=KLe(new Ir(u).sub(l).div(c-1),o,0),h=[].concat(iW(ED.rangeStep(new Ir(l),new Ir(u).sub(new Ir(.99).mul(d)),d)),[u]);return r>i?rW(h):h}var gjt=WLe(pjt),yjt=WLe(mjt),bjt="Invariant failed";function Sb(e,t){throw new Error(bjt)}var vjt=["offset","layout","width","dataKey","data","dataPointFormatter","xAxis","yAxis"];function hw(e){"@babel/helpers - typeof";return hw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},hw(e)}function wI(){return wI=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},wI.apply(this,arguments)}function xjt(e,t){return Cjt(e)||kjt(e,t)||Sjt(e,t)||wjt()}function wjt(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2867
2867
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Sjt(e,t){if(e){if(typeof e=="string")return dme(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return dme(e,t)}}function dme(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function kjt(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,s,a=[],l=!0,u=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(l=(r=o.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(c){u=!0,i=c}finally{try{if(!l&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw i}}return a}}function Cjt(e){if(Array.isArray(e))return e}function Ejt(e,t){if(e==null)return{};var n=Tjt(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function Tjt(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function Ajt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ojt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,ZLe(r.key),r)}}function Rjt(e,t,n){return t&&Ojt(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Mjt(e,t,n){return t=SI(t),_jt(e,XLe()?Reflect.construct(t,n||[],SI(e).constructor):t.apply(e,n))}function _jt(e,t){if(t&&(hw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Njt(e)}function Njt(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function XLe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(XLe=function(){return!!e})()}function SI(e){return SI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},SI(e)}function Ljt(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&sW(e,t)}function sW(e,t){return sW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},sW(e,t)}function QLe(e,t,n){return t=ZLe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ZLe(e){var t=Ijt(e,"string");return hw(t)=="symbol"?t:t+""}function Ijt(e,t){if(hw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(hw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var EA=(function(e){function t(){return Ajt(this,t),Mjt(this,t,arguments)}return Ljt(t,e),Rjt(t,[{key:"render",value:function(){var r=this.props,i=r.offset,o=r.layout,s=r.width,a=r.dataKey,l=r.data,u=r.dataPointFormatter,c=r.xAxis,d=r.yAxis,h=Ejt(r,vjt),m=wn(h,!1);this.props.direction==="x"&&c.type!=="number"&&Sb();var g=l.map(function(b){var v=u(b,a),w=v.x,S=v.y,C=v.value,E=v.errorVal;if(!E)return null;var T=[],O,M;if(Array.isArray(E)){var N=xjt(E,2);O=N[0],M=N[1]}else O=M=E;if(o==="vertical"){var I=c.scale,D=S+i,P=D+s,F=D-s,z=I(C-O),$=I(C+M);T.push({x1:$,y1:P,x2:$,y2:F}),T.push({x1:z,y1:D,x2:$,y2:D}),T.push({x1:z,y1:P,x2:z,y2:F})}else if(o==="horizontal"){var B=d.scale,H=w+i,U=H-s,W=H+s,q=B(C-O),Y=B(C+M);T.push({x1:U,y1:Y,x2:W,y2:Y}),T.push({x1:H,y1:q,x2:H,y2:Y}),T.push({x1:U,y1:q,x2:W,y2:q})}return we.createElement(Yr,wI({className:"recharts-errorBar",key:"bar-".concat(T.map(function(Q){return"".concat(Q.x1,"-").concat(Q.x2,"-").concat(Q.y1,"-").concat(Q.y2)}))},m),T.map(function(Q){return we.createElement("line",wI({},Q,{key:"line-".concat(Q.x1,"-").concat(Q.x2,"-").concat(Q.y1,"-").concat(Q.y2)}))}))});return we.createElement(Yr,{className:"recharts-errorBars"},g)}}])})(we.Component);QLe(EA,"defaultProps",{stroke:"black",strokeWidth:1.5,width:5,offset:0,layout:"horizontal"});QLe(EA,"displayName","ErrorBar");function mT(e){"@babel/helpers - typeof";return mT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},mT(e)}function fme(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 N0(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?fme(Object(n),!0).forEach(function(r){Pjt(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fme(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Pjt(e,t,n){return t=jjt(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function jjt(e){var t=Djt(e,"string");return mT(t)=="symbol"?t:t+""}function Djt(e,t){if(mT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(mT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var JLe=function(t){var n=t.children,r=t.formattedGraphicalItems,i=t.legendWidth,o=t.legendContent,s=tl(n,tb);if(!s)return null;var a=tb.defaultProps,l=a!==void 0?N0(N0({},a),s.props):{},u;return s.props&&s.props.payload?u=s.props&&s.props.payload:o==="children"?u=(r||[]).reduce(function(c,d){var h=d.item,m=d.props,g=m.sectors||m.data||[];return c.concat(g.map(function(b){return{type:s.props.iconType||h.props.legendType,value:b.name,color:b.fill,payload:b}}))},[]):u=(r||[]).map(function(c){var d=c.item,h=d.type.defaultProps,m=h!==void 0?N0(N0({},h),d.props):{},g=m.dataKey,b=m.name,v=m.legendType,w=m.hide;return{inactive:w,dataKey:g,type:l.iconType||v||"square",color:dQ(d),value:b||g,payload:m}}),N0(N0(N0({},l),tb.getWithHeight(s,i)),{},{payload:u,item:s})};function gT(e){"@babel/helpers - typeof";return gT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},gT(e)}function hme(e){return Bjt(e)||Fjt(e)||zjt(e)||$jt()}function $jt(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
2868
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function zjt(e,t){if(e){if(typeof e=="string")return aW(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return aW(e,t)}}function Fjt(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Bjt(e){if(Array.isArray(e))return aW(e)}function aW(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function pme(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 Si(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?pme(Object(n),!0).forEach(function(r){W1(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pme(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function W1(e,t,n){return t=Hjt(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Hjt(e){var t=Ujt(e,"string");return gT(t)=="symbol"?t:t+""}function Ujt(e,t){if(gT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(gT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function na(e,t,n){return Rn(e)||Rn(t)?n:ho(t)?au(e,t,n):yn(t)?t(e):n}function tE(e,t,n,r){var i=BPt(e,function(a){return na(a,t)});if(n==="number"){var o=i.filter(function(a){return ft(a)||parseFloat(a)});return o.length?[kD(o),Xm(o)]:[1/0,-1/0]}var s=r?i.filter(function(a){return!Rn(a)}):i;return s.map(function(a){return ho(a)||a instanceof Date?a:""})}var Vjt=function(t){var n,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],i=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,s=-1,a=(n=r==null?void 0:r.length)!==null&&n!==void 0?n:0;if(a<=1)return 0;if(o&&o.axisType==="angleAxis"&&Math.abs(Math.abs(o.range[1]-o.range[0])-360)<=1e-6)for(var l=o.range,u=0;u<a;u++){var c=u>0?i[u-1].coordinate:i[a-1].coordinate,d=i[u].coordinate,h=u>=a-1?i[0].coordinate:i[u+1].coordinate,m=void 0;if(Xu(d-c)!==Xu(h-d)){var g=[];if(Xu(h-d)===Xu(l[1]-l[0])){m=h;var b=d+l[1]-l[0];g[0]=Math.min(b,(b+c)/2),g[1]=Math.max(b,(b+c)/2)}else{m=c;var v=h+l[1]-l[0];g[0]=Math.min(d,(v+d)/2),g[1]=Math.max(d,(v+d)/2)}var w=[Math.min(d,(m+d)/2),Math.max(d,(m+d)/2)];if(t>w[0]&&t<=w[1]||t>=g[0]&&t<=g[1]){s=i[u].index;break}}else{var S=Math.min(c,h),C=Math.max(c,h);if(t>(S+d)/2&&t<=(C+d)/2){s=i[u].index;break}}}else for(var E=0;E<a;E++)if(E===0&&t<=(r[E].coordinate+r[E+1].coordinate)/2||E>0&&E<a-1&&t>(r[E].coordinate+r[E-1].coordinate)/2&&t<=(r[E].coordinate+r[E+1].coordinate)/2||E===a-1&&t>(r[E].coordinate+r[E-1].coordinate)/2){s=r[E].index;break}return s},dQ=function(t){var n,r=t,i=r.type.displayName,o=(n=t.type)!==null&&n!==void 0&&n.defaultProps?Si(Si({},t.type.defaultProps),t.props):t.props,s=o.stroke,a=o.fill,l;switch(i){case"Line":l=s;break;case"Area":case"Radar":l=s&&s!=="none"?s:a;break;default:l=a;break}return l},Wjt=function(t){var n=t.barSize,r=t.totalSize,i=t.stackGroups,o=i===void 0?{}:i;if(!o)return{};for(var s={},a=Object.keys(o),l=0,u=a.length;l<u;l++)for(var c=o[a[l]].stackGroups,d=Object.keys(c),h=0,m=d.length;h<m;h++){var g=c[d[h]],b=g.items,v=g.cateAxisId,w=b.filter(function(M){return Oh(M.type).indexOf("Bar")>=0});if(w&&w.length){var S=w[0].type.defaultProps,C=S!==void 0?Si(Si({},S),w[0].props):w[0].props,E=C.barSize,T=C[v];s[T]||(s[T]=[]);var O=Rn(E)?n:E;s[T].push({item:w[0],stackList:w.slice(1),barSize:Rn(O)?void 0:xb(O,r,0)})}}return s},qjt=function(t){var n=t.barGap,r=t.barCategoryGap,i=t.bandSize,o=t.sizeList,s=o===void 0?[]:o,a=t.maxBarSize,l=s.length;if(l<1)return null;var u=xb(n,i,0,!0),c,d=[];if(s[0].barSize===+s[0].barSize){var h=!1,m=i/l,g=s.reduce(function(E,T){return E+T.barSize||0},0);g+=(l-1)*u,g>=i&&(g-=(l-1)*u,u=0),g>=i&&m>0&&(h=!0,m*=.9,g=l*m);var b=(i-g)/2>>0,v={offset:b-u,size:0};c=s.reduce(function(E,T){var O={item:T.item,position:{offset:v.offset+v.size+u,size:h?m:T.barSize}},M=[].concat(hme(E),[O]);return v=M[M.length-1].position,T.stackList&&T.stackList.length&&T.stackList.forEach(function(N){M.push({item:N,position:v})}),M},d)}else{var w=xb(r,i,0,!0);i-2*w-(l-1)*u<=0&&(u=0);var S=(i-2*w-(l-1)*u)/l;S>1&&(S>>=0);var C=a===+a?Math.min(S,a):S;c=s.reduce(function(E,T,O){var M=[].concat(hme(E),[{item:T.item,position:{offset:w+(S+u)*O+(S-C)/2,size:C}}]);return T.stackList&&T.stackList.length&&T.stackList.forEach(function(N){M.push({item:N,position:M[M.length-1].position})}),M},d)}return c},Gjt=function(t,n,r,i){var o=r.children,s=r.width,a=r.margin,l=s-(a.left||0)-(a.right||0),u=JLe({children:o,legendWidth:l});if(u){var c=i||{},d=c.width,h=c.height,m=u.align,g=u.verticalAlign,b=u.layout;if((b==="vertical"||b==="horizontal"&&g==="middle")&&m!=="center"&&ft(t[m]))return Si(Si({},t),{},W1({},m,t[m]+(d||0)));if((b==="horizontal"||b==="vertical"&&m==="center")&&g!=="middle"&&ft(t[g]))return Si(Si({},t),{},W1({},g,t[g]+(h||0)))}return t},Kjt=function(t,n,r){return Rn(n)?!0:t==="horizontal"?n==="yAxis":t==="vertical"||r==="x"?n==="xAxis":r==="y"?n==="yAxis":!0},eIe=function(t,n,r,i,o){var s=n.props.children,a=lu(s,EA).filter(function(u){return Kjt(i,o,u.props.direction)});if(a&&a.length){var l=a.map(function(u){return u.props.dataKey});return t.reduce(function(u,c){var d=na(c,r);if(Rn(d))return u;var h=Array.isArray(d)?[kD(d),Xm(d)]:[d,d],m=l.reduce(function(g,b){var v=na(c,b,0),w=h[0]-Math.abs(Array.isArray(v)?v[0]:v),S=h[1]+Math.abs(Array.isArray(v)?v[1]:v);return[Math.min(w,g[0]),Math.max(S,g[1])]},[1/0,-1/0]);return[Math.min(m[0],u[0]),Math.max(m[1],u[1])]},[1/0,-1/0])}return null},Yjt=function(t,n,r,i,o){var s=n.map(function(a){return eIe(t,a,r,o,i)}).filter(function(a){return!Rn(a)});return s&&s.length?s.reduce(function(a,l){return[Math.min(a[0],l[0]),Math.max(a[1],l[1])]},[1/0,-1/0]):null},tIe=function(t,n,r,i,o){var s=n.map(function(l){var u=l.props.dataKey;return r==="number"&&u&&eIe(t,l,u,i)||tE(t,u,r,o)});if(r==="number")return s.reduce(function(l,u){return[Math.min(l[0],u[0]),Math.max(l[1],u[1])]},[1/0,-1/0]);var a={};return s.reduce(function(l,u){for(var c=0,d=u.length;c<d;c++)a[u[c]]||(a[u[c]]=!0,l.push(u[c]));return l},[])},nIe=function(t,n){return t==="horizontal"&&n==="xAxis"||t==="vertical"&&n==="yAxis"||t==="centric"&&n==="angleAxis"||t==="radial"&&n==="radiusAxis"},rIe=function(t,n,r,i){if(i)return t.map(function(l){return l.coordinate});var o,s,a=t.map(function(l){return l.coordinate===n&&(o=!0),l.coordinate===r&&(s=!0),l.coordinate});return o||a.push(n),s||a.push(r),a},gh=function(t,n,r){if(!t)return null;var i=t.scale,o=t.duplicateDomain,s=t.type,a=t.range,l=t.realScaleType==="scaleBand"?i.bandwidth()/2:2,u=(n||r)&&s==="category"&&i.bandwidth?i.bandwidth()/l:0;if(u=t.axisType==="angleAxis"&&(a==null?void 0:a.length)>=2?Xu(a[0]-a[1])*2*u:u,n&&(t.ticks||t.niceTicks)){var c=(t.ticks||t.niceTicks).map(function(d){var h=o?o.indexOf(d):d;return{coordinate:i(h)+u,value:d,offset:u}});return c.filter(function(d){return!dS(d.coordinate)})}return t.isCategorical&&t.categoricalDomain?t.categoricalDomain.map(function(d,h){return{coordinate:i(d)+u,value:d,index:h,offset:u}}):i.ticks&&!r?i.ticks(t.tickCount).map(function(d){return{coordinate:i(d)+u,value:d,offset:u}}):i.domain().map(function(d,h){return{coordinate:i(d)+u,value:o?o[d]:d,index:h,offset:u}})},yB=new WeakMap,mM=function(t,n){if(typeof n!="function")return t;yB.has(t)||yB.set(t,new WeakMap);var r=yB.get(t);if(r.has(n))return r.get(n);var i=function(){t.apply(void 0,arguments),n.apply(void 0,arguments)};return r.set(n,i),i},Xjt=function(t,n,r){var i=t.scale,o=t.type,s=t.layout,a=t.axisType;if(i==="auto")return s==="radial"&&a==="radiusAxis"?{scale:Jx(),realScaleType:"band"}:s==="radial"&&a==="angleAxis"?{scale:ZE(),realScaleType:"linear"}:o==="category"&&n&&(n.indexOf("LineChart")>=0||n.indexOf("AreaChart")>=0||n.indexOf("ComposedChart")>=0&&!r)?{scale:GC(),realScaleType:"point"}:o==="category"?{scale:Jx(),realScaleType:"band"}:{scale:ZE(),realScaleType:"linear"};if(vb(i)){var l="scale".concat(vD(i));return{scale:(Jpe[l]||GC)(),realScaleType:Jpe[l]?l:"point"}}return yn(i)?{scale:i}:{scale:GC(),realScaleType:"point"}},mme=1e-4,Qjt=function(t){var n=t.domain();if(!(!n||n.length<=2)){var r=n.length,i=t.range(),o=Math.min(i[0],i[1])-mme,s=Math.max(i[0],i[1])+mme,a=t(n[0]),l=t(n[r-1]);(a<o||a>s||l<o||l>s)&&t.domain([n[0],n[r-1]])}},Zjt=function(t,n){if(!t)return null;for(var r=0,i=t.length;r<i;r++)if(t[r].item===n)return t[r].position;return null},Jjt=function(t,n){if(!n||n.length!==2||!ft(n[0])||!ft(n[1]))return t;var r=Math.min(n[0],n[1]),i=Math.max(n[0],n[1]),o=[t[0],t[1]];return(!ft(t[0])||t[0]<r)&&(o[0]=r),(!ft(t[1])||t[1]>i)&&(o[1]=i),o[0]>i&&(o[0]=i),o[1]<r&&(o[1]=r),o},eDt=function(t){var n=t.length;if(!(n<=0))for(var r=0,i=t[0].length;r<i;++r)for(var o=0,s=0,a=0;a<n;++a){var l=dS(t[a][r][1])?t[a][r][0]:t[a][r][1];l>=0?(t[a][r][0]=o,t[a][r][1]=o+l,o=t[a][r][1]):(t[a][r][0]=s,t[a][r][1]=s+l,s=t[a][r][1])}},tDt=function(t){var n=t.length;if(!(n<=0))for(var r=0,i=t[0].length;r<i;++r)for(var o=0,s=0;s<n;++s){var a=dS(t[s][r][1])?t[s][r][0]:t[s][r][1];a>=0?(t[s][r][0]=o,t[s][r][1]=o+a,o=t[s][r][1]):(t[s][r][0]=0,t[s][r][1]=0)}},nDt={sign:eDt,expand:Axt,none:Zx,silhouette:Oxt,wiggle:Rxt,positive:tDt},rDt=function(t,n,r){var i=n.map(function(a){return a.props.dataKey}),o=nDt[r],s=Txt().keys(i).value(function(a,l){return+na(a,l,0)}).order(eV).offset(o);return s(t)},iDt=function(t,n,r,i,o,s){if(!t)return null;var a=s?n.reverse():n,l={},u=a.reduce(function(d,h){var m,g=(m=h.type)!==null&&m!==void 0&&m.defaultProps?Si(Si({},h.type.defaultProps),h.props):h.props,b=g.stackId,v=g.hide;if(v)return d;var w=g[r],S=d[w]||{hasStack:!1,stackGroups:{}};if(ho(b)){var C=S.stackGroups[b]||{numericAxisId:r,cateAxisId:i,items:[]};C.items.push(h),S.hasStack=!0,S.stackGroups[b]=C}else S.stackGroups[fS("_stackId_")]={numericAxisId:r,cateAxisId:i,items:[h]};return Si(Si({},d),{},W1({},w,S))},l),c={};return Object.keys(u).reduce(function(d,h){var m=u[h];if(m.hasStack){var g={};m.stackGroups=Object.keys(m.stackGroups).reduce(function(b,v){var w=m.stackGroups[v];return Si(Si({},b),{},W1({},v,{numericAxisId:r,cateAxisId:i,items:w.items,stackedData:rDt(t,w.items,o)}))},g)}return Si(Si({},d),{},W1({},h,m))},c)},oDt=function(t,n){var r=n.realScaleType,i=n.type,o=n.tickCount,s=n.originalDomain,a=n.allowDecimals,l=r||n.scale;if(l!=="auto"&&l!=="linear")return null;if(o&&i==="number"&&s&&(s[0]==="auto"||s[1]==="auto")){var u=t.domain();if(!u.length)return null;var c=gjt(u,o,a);return t.domain([kD(c),Xm(c)]),{niceTicks:c}}if(o&&i==="number"){var d=t.domain(),h=yjt(d,o,a);return{niceTicks:h}}return null};function kI(e){var t=e.axis,n=e.ticks,r=e.bandSize,i=e.entry,o=e.index,s=e.dataKey;if(t.type==="category"){if(!t.allowDuplicatedCategory&&t.dataKey&&!Rn(i[t.dataKey])){var a=dI(n,"value",i[t.dataKey]);if(a)return a.coordinate+r/2}return n[o]?n[o].coordinate+r/2:null}var l=na(i,Rn(s)?t.dataKey:s);return Rn(l)?null:t.scale(l)}var gme=function(t){var n=t.axis,r=t.ticks,i=t.offset,o=t.bandSize,s=t.entry,a=t.index;if(n.type==="category")return r[a]?r[a].coordinate+i:null;var l=na(s,n.dataKey,n.domain[a]);return Rn(l)?null:n.scale(l)-o/2+i},sDt=function(t){var n=t.numericAxis,r=n.scale.domain();if(n.type==="number"){var i=Math.min(r[0],r[1]),o=Math.max(r[0],r[1]);return i<=0&&o>=0?0:o<0?o:i}return r[0]},aDt=function(t,n){var r,i=(r=t.type)!==null&&r!==void 0&&r.defaultProps?Si(Si({},t.type.defaultProps),t.props):t.props,o=i.stackId;if(ho(o)){var s=n[o];if(s){var a=s.items.indexOf(t);return a>=0?s.stackedData[a]:null}}return null},lDt=function(t){return t.reduce(function(n,r){return[kD(r.concat([n[0]]).filter(ft)),Xm(r.concat([n[1]]).filter(ft))]},[1/0,-1/0])},iIe=function(t,n,r){return Object.keys(t).reduce(function(i,o){var s=t[o],a=s.stackedData,l=a.reduce(function(u,c){var d=lDt(c.slice(n,r+1));return[Math.min(u[0],d[0]),Math.max(u[1],d[1])]},[1/0,-1/0]);return[Math.min(l[0],i[0]),Math.max(l[1],i[1])]},[1/0,-1/0]).map(function(i){return i===1/0||i===-1/0?0:i})},yme=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,bme=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,lW=function(t,n,r){if(yn(t))return t(n,r);if(!Array.isArray(t))return n;var i=[];if(ft(t[0]))i[0]=r?t[0]:Math.min(t[0],n[0]);else if(yme.test(t[0])){var o=+yme.exec(t[0])[1];i[0]=n[0]-o}else yn(t[0])?i[0]=t[0](n[0]):i[0]=n[0];if(ft(t[1]))i[1]=r?t[1]:Math.max(t[1],n[1]);else if(bme.test(t[1])){var s=+bme.exec(t[1])[1];i[1]=n[1]+s}else yn(t[1])?i[1]=t[1](n[1]):i[1]=n[1];return i},CI=function(t,n,r){if(t&&t.scale&&t.scale.bandwidth){var i=t.scale.bandwidth();if(!r||i>0)return i}if(t&&n&&n.length>=2){for(var o=aQ(n,function(d){return d.coordinate}),s=1/0,a=1,l=o.length;a<l;a++){var u=o[a],c=o[a-1];s=Math.min((u.coordinate||0)-(c.coordinate||0),s)}return s===1/0?0:s}return r?void 0:0},vme=function(t,n,r){return!t||!t.length||fw(t,au(r,"type.defaultProps.domain"))?n:t},oIe=function(t,n){var r=t.type.defaultProps?Si(Si({},t.type.defaultProps),t.props):t.props,i=r.dataKey,o=r.name,s=r.unit,a=r.formatter,l=r.tooltipType,u=r.chartType,c=r.hide;return Si(Si({},wn(t,!1)),{},{dataKey:i,unit:s,formatter:a,name:o||i,color:dQ(t),value:na(n,i),type:l,payload:n,chartType:u,hide:c})};function yT(e){"@babel/helpers - typeof";return yT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},yT(e)}function xme(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 wme(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?xme(Object(n),!0).forEach(function(r){uDt(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):xme(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function uDt(e,t,n){return t=cDt(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cDt(e){var t=dDt(e,"string");return yT(t)=="symbol"?t:t+""}function dDt(e,t){if(yT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(yT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var EI=Math.PI/180,fDt=function(t){return t*180/Math.PI},ls=function(t,n,r,i){return{x:t+Math.cos(-EI*i)*r,y:n+Math.sin(-EI*i)*r}},hDt=function(t,n){var r=t.x,i=t.y,o=n.x,s=n.y;return Math.sqrt(Math.pow(r-o,2)+Math.pow(i-s,2))},pDt=function(t,n){var r=t.x,i=t.y,o=n.cx,s=n.cy,a=hDt({x:r,y:i},{x:o,y:s});if(a<=0)return{radius:a};var l=(r-o)/a,u=Math.acos(l);return i>s&&(u=2*Math.PI-u),{radius:a,angle:fDt(u),angleInRadian:u}},mDt=function(t){var n=t.startAngle,r=t.endAngle,i=Math.floor(n/360),o=Math.floor(r/360),s=Math.min(i,o);return{startAngle:n-s*360,endAngle:r-s*360}},gDt=function(t,n){var r=n.startAngle,i=n.endAngle,o=Math.floor(r/360),s=Math.floor(i/360),a=Math.min(o,s);return t+a*360},Sme=function(t,n){var r=t.x,i=t.y,o=pDt({x:r,y:i},n),s=o.radius,a=o.angle,l=n.innerRadius,u=n.outerRadius;if(s<l||s>u)return!1;if(s===0)return!0;var c=mDt(n),d=c.startAngle,h=c.endAngle,m=a,g;if(d<=h){for(;m>h;)m-=360;for(;m<d;)m+=360;g=m>=d&&m<=h}else{for(;m>d;)m-=360;for(;m<h;)m+=360;g=m>=h&&m<=d}return g?wme(wme({},n),{},{radius:s,angle:gDt(m,n)}):null};function bT(e){"@babel/helpers - typeof";return bT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},bT(e)}var yDt=["offset"];function bDt(e){return SDt(e)||wDt(e)||xDt(e)||vDt()}function vDt(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
2868
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function zjt(e,t){if(e){if(typeof e=="string")return aW(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return aW(e,t)}}function Fjt(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Bjt(e){if(Array.isArray(e))return aW(e)}function aW(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function pme(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 Si(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?pme(Object(n),!0).forEach(function(r){W1(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pme(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function W1(e,t,n){return t=Hjt(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Hjt(e){var t=Ujt(e,"string");return gT(t)=="symbol"?t:t+""}function Ujt(e,t){if(gT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(gT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function na(e,t,n){return Rn(e)||Rn(t)?n:ho(t)?au(e,t,n):yn(t)?t(e):n}function tE(e,t,n,r){var i=BPt(e,function(a){return na(a,t)});if(n==="number"){var o=i.filter(function(a){return ft(a)||parseFloat(a)});return o.length?[kD(o),Xm(o)]:[1/0,-1/0]}var s=r?i.filter(function(a){return!Rn(a)}):i;return s.map(function(a){return ho(a)||a instanceof Date?a:""})}var Vjt=function(t){var n,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],i=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,s=-1,a=(n=r==null?void 0:r.length)!==null&&n!==void 0?n:0;if(a<=1)return 0;if(o&&o.axisType==="angleAxis"&&Math.abs(Math.abs(o.range[1]-o.range[0])-360)<=1e-6)for(var l=o.range,u=0;u<a;u++){var c=u>0?i[u-1].coordinate:i[a-1].coordinate,d=i[u].coordinate,h=u>=a-1?i[0].coordinate:i[u+1].coordinate,m=void 0;if(Xu(d-c)!==Xu(h-d)){var g=[];if(Xu(h-d)===Xu(l[1]-l[0])){m=h;var b=d+l[1]-l[0];g[0]=Math.min(b,(b+c)/2),g[1]=Math.max(b,(b+c)/2)}else{m=c;var v=h+l[1]-l[0];g[0]=Math.min(d,(v+d)/2),g[1]=Math.max(d,(v+d)/2)}var w=[Math.min(d,(m+d)/2),Math.max(d,(m+d)/2)];if(t>w[0]&&t<=w[1]||t>=g[0]&&t<=g[1]){s=i[u].index;break}}else{var S=Math.min(c,h),C=Math.max(c,h);if(t>(S+d)/2&&t<=(C+d)/2){s=i[u].index;break}}}else for(var E=0;E<a;E++)if(E===0&&t<=(r[E].coordinate+r[E+1].coordinate)/2||E>0&&E<a-1&&t>(r[E].coordinate+r[E-1].coordinate)/2&&t<=(r[E].coordinate+r[E+1].coordinate)/2||E===a-1&&t>(r[E].coordinate+r[E-1].coordinate)/2){s=r[E].index;break}return s},dQ=function(t){var n,r=t,i=r.type.displayName,o=(n=t.type)!==null&&n!==void 0&&n.defaultProps?Si(Si({},t.type.defaultProps),t.props):t.props,s=o.stroke,a=o.fill,l;switch(i){case"Line":l=s;break;case"Area":case"Radar":l=s&&s!=="none"?s:a;break;default:l=a;break}return l},Wjt=function(t){var n=t.barSize,r=t.totalSize,i=t.stackGroups,o=i===void 0?{}:i;if(!o)return{};for(var s={},a=Object.keys(o),l=0,u=a.length;l<u;l++)for(var c=o[a[l]].stackGroups,d=Object.keys(c),h=0,m=d.length;h<m;h++){var g=c[d[h]],b=g.items,v=g.cateAxisId,w=b.filter(function(M){return Oh(M.type).indexOf("Bar")>=0});if(w&&w.length){var S=w[0].type.defaultProps,C=S!==void 0?Si(Si({},S),w[0].props):w[0].props,E=C.barSize,T=C[v];s[T]||(s[T]=[]);var O=Rn(E)?n:E;s[T].push({item:w[0],stackList:w.slice(1),barSize:Rn(O)?void 0:xb(O,r,0)})}}return s},qjt=function(t){var n=t.barGap,r=t.barCategoryGap,i=t.bandSize,o=t.sizeList,s=o===void 0?[]:o,a=t.maxBarSize,l=s.length;if(l<1)return null;var u=xb(n,i,0,!0),c,d=[];if(s[0].barSize===+s[0].barSize){var h=!1,m=i/l,g=s.reduce(function(E,T){return E+T.barSize||0},0);g+=(l-1)*u,g>=i&&(g-=(l-1)*u,u=0),g>=i&&m>0&&(h=!0,m*=.9,g=l*m);var b=(i-g)/2>>0,v={offset:b-u,size:0};c=s.reduce(function(E,T){var O={item:T.item,position:{offset:v.offset+v.size+u,size:h?m:T.barSize}},M=[].concat(hme(E),[O]);return v=M[M.length-1].position,T.stackList&&T.stackList.length&&T.stackList.forEach(function(N){M.push({item:N,position:v})}),M},d)}else{var w=xb(r,i,0,!0);i-2*w-(l-1)*u<=0&&(u=0);var S=(i-2*w-(l-1)*u)/l;S>1&&(S>>=0);var C=a===+a?Math.min(S,a):S;c=s.reduce(function(E,T,O){var M=[].concat(hme(E),[{item:T.item,position:{offset:w+(S+u)*O+(S-C)/2,size:C}}]);return T.stackList&&T.stackList.length&&T.stackList.forEach(function(N){M.push({item:N,position:M[M.length-1].position})}),M},d)}return c},Gjt=function(t,n,r,i){var o=r.children,s=r.width,a=r.margin,l=s-(a.left||0)-(a.right||0),u=JLe({children:o,legendWidth:l});if(u){var c=i||{},d=c.width,h=c.height,m=u.align,g=u.verticalAlign,b=u.layout;if((b==="vertical"||b==="horizontal"&&g==="middle")&&m!=="center"&&ft(t[m]))return Si(Si({},t),{},W1({},m,t[m]+(d||0)));if((b==="horizontal"||b==="vertical"&&m==="center")&&g!=="middle"&&ft(t[g]))return Si(Si({},t),{},W1({},g,t[g]+(h||0)))}return t},Kjt=function(t,n,r){return Rn(n)?!0:t==="horizontal"?n==="yAxis":t==="vertical"||r==="x"?n==="xAxis":r==="y"?n==="yAxis":!0},eIe=function(t,n,r,i,o){var s=n.props.children,a=lu(s,EA).filter(function(u){return Kjt(i,o,u.props.direction)});if(a&&a.length){var l=a.map(function(u){return u.props.dataKey});return t.reduce(function(u,c){var d=na(c,r);if(Rn(d))return u;var h=Array.isArray(d)?[kD(d),Xm(d)]:[d,d],m=l.reduce(function(g,b){var v=na(c,b,0),w=h[0]-Math.abs(Array.isArray(v)?v[0]:v),S=h[1]+Math.abs(Array.isArray(v)?v[1]:v);return[Math.min(w,g[0]),Math.max(S,g[1])]},[1/0,-1/0]);return[Math.min(m[0],u[0]),Math.max(m[1],u[1])]},[1/0,-1/0])}return null},Yjt=function(t,n,r,i,o){var s=n.map(function(a){return eIe(t,a,r,o,i)}).filter(function(a){return!Rn(a)});return s&&s.length?s.reduce(function(a,l){return[Math.min(a[0],l[0]),Math.max(a[1],l[1])]},[1/0,-1/0]):null},tIe=function(t,n,r,i,o){var s=n.map(function(l){var u=l.props.dataKey;return r==="number"&&u&&eIe(t,l,u,i)||tE(t,u,r,o)});if(r==="number")return s.reduce(function(l,u){return[Math.min(l[0],u[0]),Math.max(l[1],u[1])]},[1/0,-1/0]);var a={};return s.reduce(function(l,u){for(var c=0,d=u.length;c<d;c++)a[u[c]]||(a[u[c]]=!0,l.push(u[c]));return l},[])},nIe=function(t,n){return t==="horizontal"&&n==="xAxis"||t==="vertical"&&n==="yAxis"||t==="centric"&&n==="angleAxis"||t==="radial"&&n==="radiusAxis"},rIe=function(t,n,r,i){if(i)return t.map(function(l){return l.coordinate});var o,s,a=t.map(function(l){return l.coordinate===n&&(o=!0),l.coordinate===r&&(s=!0),l.coordinate});return o||a.push(n),s||a.push(r),a},gh=function(t,n,r){if(!t)return null;var i=t.scale,o=t.duplicateDomain,s=t.type,a=t.range,l=t.realScaleType==="scaleBand"?i.bandwidth()/2:2,u=(n||r)&&s==="category"&&i.bandwidth?i.bandwidth()/l:0;if(u=t.axisType==="angleAxis"&&(a==null?void 0:a.length)>=2?Xu(a[0]-a[1])*2*u:u,n&&(t.ticks||t.niceTicks)){var c=(t.ticks||t.niceTicks).map(function(d){var h=o?o.indexOf(d):d;return{coordinate:i(h)+u,value:d,offset:u}});return c.filter(function(d){return!dS(d.coordinate)})}return t.isCategorical&&t.categoricalDomain?t.categoricalDomain.map(function(d,h){return{coordinate:i(d)+u,value:d,index:h,offset:u}}):i.ticks&&!r?i.ticks(t.tickCount).map(function(d){return{coordinate:i(d)+u,value:d,offset:u}}):i.domain().map(function(d,h){return{coordinate:i(d)+u,value:o?o[d]:d,index:h,offset:u}})},yB=new WeakMap,mM=function(t,n){if(typeof n!="function")return t;yB.has(t)||yB.set(t,new WeakMap);var r=yB.get(t);if(r.has(n))return r.get(n);var i=function(){t.apply(void 0,arguments),n.apply(void 0,arguments)};return r.set(n,i),i},Xjt=function(t,n,r){var i=t.scale,o=t.type,s=t.layout,a=t.axisType;if(i==="auto")return s==="radial"&&a==="radiusAxis"?{scale:Jx(),realScaleType:"band"}:s==="radial"&&a==="angleAxis"?{scale:ZE(),realScaleType:"linear"}:o==="category"&&n&&(n.indexOf("LineChart")>=0||n.indexOf("AreaChart")>=0||n.indexOf("ComposedChart")>=0&&!r)?{scale:GC(),realScaleType:"point"}:o==="category"?{scale:Jx(),realScaleType:"band"}:{scale:ZE(),realScaleType:"linear"};if(vb(i)){var l="scale".concat(vD(i));return{scale:(Jpe[l]||GC)(),realScaleType:Jpe[l]?l:"point"}}return yn(i)?{scale:i}:{scale:GC(),realScaleType:"point"}},mme=1e-4,Qjt=function(t){var n=t.domain();if(!(!n||n.length<=2)){var r=n.length,i=t.range(),o=Math.min(i[0],i[1])-mme,s=Math.max(i[0],i[1])+mme,a=t(n[0]),l=t(n[r-1]);(a<o||a>s||l<o||l>s)&&t.domain([n[0],n[r-1]])}},Zjt=function(t,n){if(!t)return null;for(var r=0,i=t.length;r<i;r++)if(t[r].item===n)return t[r].position;return null},Jjt=function(t,n){if(!n||n.length!==2||!ft(n[0])||!ft(n[1]))return t;var r=Math.min(n[0],n[1]),i=Math.max(n[0],n[1]),o=[t[0],t[1]];return(!ft(t[0])||t[0]<r)&&(o[0]=r),(!ft(t[1])||t[1]>i)&&(o[1]=i),o[0]>i&&(o[0]=i),o[1]<r&&(o[1]=r),o},eDt=function(t){var n=t.length;if(!(n<=0))for(var r=0,i=t[0].length;r<i;++r)for(var o=0,s=0,a=0;a<n;++a){var l=dS(t[a][r][1])?t[a][r][0]:t[a][r][1];l>=0?(t[a][r][0]=o,t[a][r][1]=o+l,o=t[a][r][1]):(t[a][r][0]=s,t[a][r][1]=s+l,s=t[a][r][1])}},tDt=function(t){var n=t.length;if(!(n<=0))for(var r=0,i=t[0].length;r<i;++r)for(var o=0,s=0;s<n;++s){var a=dS(t[s][r][1])?t[s][r][0]:t[s][r][1];a>=0?(t[s][r][0]=o,t[s][r][1]=o+a,o=t[s][r][1]):(t[s][r][0]=0,t[s][r][1]=0)}},nDt={sign:eDt,expand:Dxt,none:Zx,silhouette:$xt,wiggle:zxt,positive:tDt},rDt=function(t,n,r){var i=n.map(function(a){return a.props.dataKey}),o=nDt[r],s=jxt().keys(i).value(function(a,l){return+na(a,l,0)}).order(eV).offset(o);return s(t)},iDt=function(t,n,r,i,o,s){if(!t)return null;var a=s?n.reverse():n,l={},u=a.reduce(function(d,h){var m,g=(m=h.type)!==null&&m!==void 0&&m.defaultProps?Si(Si({},h.type.defaultProps),h.props):h.props,b=g.stackId,v=g.hide;if(v)return d;var w=g[r],S=d[w]||{hasStack:!1,stackGroups:{}};if(ho(b)){var C=S.stackGroups[b]||{numericAxisId:r,cateAxisId:i,items:[]};C.items.push(h),S.hasStack=!0,S.stackGroups[b]=C}else S.stackGroups[fS("_stackId_")]={numericAxisId:r,cateAxisId:i,items:[h]};return Si(Si({},d),{},W1({},w,S))},l),c={};return Object.keys(u).reduce(function(d,h){var m=u[h];if(m.hasStack){var g={};m.stackGroups=Object.keys(m.stackGroups).reduce(function(b,v){var w=m.stackGroups[v];return Si(Si({},b),{},W1({},v,{numericAxisId:r,cateAxisId:i,items:w.items,stackedData:rDt(t,w.items,o)}))},g)}return Si(Si({},d),{},W1({},h,m))},c)},oDt=function(t,n){var r=n.realScaleType,i=n.type,o=n.tickCount,s=n.originalDomain,a=n.allowDecimals,l=r||n.scale;if(l!=="auto"&&l!=="linear")return null;if(o&&i==="number"&&s&&(s[0]==="auto"||s[1]==="auto")){var u=t.domain();if(!u.length)return null;var c=gjt(u,o,a);return t.domain([kD(c),Xm(c)]),{niceTicks:c}}if(o&&i==="number"){var d=t.domain(),h=yjt(d,o,a);return{niceTicks:h}}return null};function kI(e){var t=e.axis,n=e.ticks,r=e.bandSize,i=e.entry,o=e.index,s=e.dataKey;if(t.type==="category"){if(!t.allowDuplicatedCategory&&t.dataKey&&!Rn(i[t.dataKey])){var a=dI(n,"value",i[t.dataKey]);if(a)return a.coordinate+r/2}return n[o]?n[o].coordinate+r/2:null}var l=na(i,Rn(s)?t.dataKey:s);return Rn(l)?null:t.scale(l)}var gme=function(t){var n=t.axis,r=t.ticks,i=t.offset,o=t.bandSize,s=t.entry,a=t.index;if(n.type==="category")return r[a]?r[a].coordinate+i:null;var l=na(s,n.dataKey,n.domain[a]);return Rn(l)?null:n.scale(l)-o/2+i},sDt=function(t){var n=t.numericAxis,r=n.scale.domain();if(n.type==="number"){var i=Math.min(r[0],r[1]),o=Math.max(r[0],r[1]);return i<=0&&o>=0?0:o<0?o:i}return r[0]},aDt=function(t,n){var r,i=(r=t.type)!==null&&r!==void 0&&r.defaultProps?Si(Si({},t.type.defaultProps),t.props):t.props,o=i.stackId;if(ho(o)){var s=n[o];if(s){var a=s.items.indexOf(t);return a>=0?s.stackedData[a]:null}}return null},lDt=function(t){return t.reduce(function(n,r){return[kD(r.concat([n[0]]).filter(ft)),Xm(r.concat([n[1]]).filter(ft))]},[1/0,-1/0])},iIe=function(t,n,r){return Object.keys(t).reduce(function(i,o){var s=t[o],a=s.stackedData,l=a.reduce(function(u,c){var d=lDt(c.slice(n,r+1));return[Math.min(u[0],d[0]),Math.max(u[1],d[1])]},[1/0,-1/0]);return[Math.min(l[0],i[0]),Math.max(l[1],i[1])]},[1/0,-1/0]).map(function(i){return i===1/0||i===-1/0?0:i})},yme=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,bme=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,lW=function(t,n,r){if(yn(t))return t(n,r);if(!Array.isArray(t))return n;var i=[];if(ft(t[0]))i[0]=r?t[0]:Math.min(t[0],n[0]);else if(yme.test(t[0])){var o=+yme.exec(t[0])[1];i[0]=n[0]-o}else yn(t[0])?i[0]=t[0](n[0]):i[0]=n[0];if(ft(t[1]))i[1]=r?t[1]:Math.max(t[1],n[1]);else if(bme.test(t[1])){var s=+bme.exec(t[1])[1];i[1]=n[1]+s}else yn(t[1])?i[1]=t[1](n[1]):i[1]=n[1];return i},CI=function(t,n,r){if(t&&t.scale&&t.scale.bandwidth){var i=t.scale.bandwidth();if(!r||i>0)return i}if(t&&n&&n.length>=2){for(var o=aQ(n,function(d){return d.coordinate}),s=1/0,a=1,l=o.length;a<l;a++){var u=o[a],c=o[a-1];s=Math.min((u.coordinate||0)-(c.coordinate||0),s)}return s===1/0?0:s}return r?void 0:0},vme=function(t,n,r){return!t||!t.length||fw(t,au(r,"type.defaultProps.domain"))?n:t},oIe=function(t,n){var r=t.type.defaultProps?Si(Si({},t.type.defaultProps),t.props):t.props,i=r.dataKey,o=r.name,s=r.unit,a=r.formatter,l=r.tooltipType,u=r.chartType,c=r.hide;return Si(Si({},wn(t,!1)),{},{dataKey:i,unit:s,formatter:a,name:o||i,color:dQ(t),value:na(n,i),type:l,payload:n,chartType:u,hide:c})};function yT(e){"@babel/helpers - typeof";return yT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},yT(e)}function xme(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 wme(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?xme(Object(n),!0).forEach(function(r){uDt(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):xme(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function uDt(e,t,n){return t=cDt(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cDt(e){var t=dDt(e,"string");return yT(t)=="symbol"?t:t+""}function dDt(e,t){if(yT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(yT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var EI=Math.PI/180,fDt=function(t){return t*180/Math.PI},ls=function(t,n,r,i){return{x:t+Math.cos(-EI*i)*r,y:n+Math.sin(-EI*i)*r}},hDt=function(t,n){var r=t.x,i=t.y,o=n.x,s=n.y;return Math.sqrt(Math.pow(r-o,2)+Math.pow(i-s,2))},pDt=function(t,n){var r=t.x,i=t.y,o=n.cx,s=n.cy,a=hDt({x:r,y:i},{x:o,y:s});if(a<=0)return{radius:a};var l=(r-o)/a,u=Math.acos(l);return i>s&&(u=2*Math.PI-u),{radius:a,angle:fDt(u),angleInRadian:u}},mDt=function(t){var n=t.startAngle,r=t.endAngle,i=Math.floor(n/360),o=Math.floor(r/360),s=Math.min(i,o);return{startAngle:n-s*360,endAngle:r-s*360}},gDt=function(t,n){var r=n.startAngle,i=n.endAngle,o=Math.floor(r/360),s=Math.floor(i/360),a=Math.min(o,s);return t+a*360},Sme=function(t,n){var r=t.x,i=t.y,o=pDt({x:r,y:i},n),s=o.radius,a=o.angle,l=n.innerRadius,u=n.outerRadius;if(s<l||s>u)return!1;if(s===0)return!0;var c=mDt(n),d=c.startAngle,h=c.endAngle,m=a,g;if(d<=h){for(;m>h;)m-=360;for(;m<d;)m+=360;g=m>=d&&m<=h}else{for(;m>d;)m-=360;for(;m<h;)m+=360;g=m>=h&&m<=d}return g?wme(wme({},n),{},{radius:s,angle:gDt(m,n)}):null};function bT(e){"@babel/helpers - typeof";return bT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},bT(e)}var yDt=["offset"];function bDt(e){return SDt(e)||wDt(e)||xDt(e)||vDt()}function vDt(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
2869
2869
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function xDt(e,t){if(e){if(typeof e=="string")return uW(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return uW(e,t)}}function wDt(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function SDt(e){if(Array.isArray(e))return uW(e)}function uW(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function kDt(e,t){if(e==null)return{};var n=CDt(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function CDt(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function kme(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 no(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?kme(Object(n),!0).forEach(function(r){EDt(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):kme(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function EDt(e,t,n){return t=TDt(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function TDt(e){var t=ADt(e,"string");return bT(t)=="symbol"?t:t+""}function ADt(e,t){if(bT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(bT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function vT(){return vT=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},vT.apply(this,arguments)}var ODt=function(t){var n=t.value,r=t.formatter,i=Rn(t.children)?n:t.children;return yn(r)?r(i):i},RDt=function(t,n){var r=Xu(n-t),i=Math.min(Math.abs(n-t),360);return r*i},MDt=function(t,n,r){var i=t.position,o=t.viewBox,s=t.offset,a=t.className,l=o,u=l.cx,c=l.cy,d=l.innerRadius,h=l.outerRadius,m=l.startAngle,g=l.endAngle,b=l.clockWise,v=(d+h)/2,w=RDt(m,g),S=w>=0?1:-1,C,E;i==="insideStart"?(C=m+S*s,E=b):i==="insideEnd"?(C=g-S*s,E=!b):i==="end"&&(C=g+S*s,E=b),E=w<=0?E:!E;var T=ls(u,c,v,C),O=ls(u,c,v,C+(E?1:-1)*359),M="M".concat(T.x,",").concat(T.y,`
2870
2870
  A`).concat(v,",").concat(v,",0,1,").concat(E?0:1,`,
2871
2871
  `).concat(O.x,",").concat(O.y),N=Rn(t.id)?fS("recharts-radial-line-"):t.id;return we.createElement("text",vT({},r,{dominantBaseline:"central",className:Hn("recharts-radial-bar-label",a)}),we.createElement("defs",null,we.createElement("path",{id:N,d:M})),we.createElement("textPath",{xlinkHref:"#".concat(N)},n))},_Dt=function(t){var n=t.viewBox,r=t.offset,i=t.position,o=n,s=o.cx,a=o.cy,l=o.innerRadius,u=o.outerRadius,c=o.startAngle,d=o.endAngle,h=(c+d)/2;if(i==="outside"){var m=ls(s,a,u+r,h),g=m.x,b=m.y;return{x:g,y:b,textAnchor:g>=s?"start":"end",verticalAnchor:"middle"}}if(i==="center")return{x:s,y:a,textAnchor:"middle",verticalAnchor:"middle"};if(i==="centerTop")return{x:s,y:a,textAnchor:"middle",verticalAnchor:"start"};if(i==="centerBottom")return{x:s,y:a,textAnchor:"middle",verticalAnchor:"end"};var v=(l+u)/2,w=ls(s,a,v,h),S=w.x,C=w.y;return{x:S,y:C,textAnchor:"middle",verticalAnchor:"middle"}},NDt=function(t){var n=t.viewBox,r=t.parentViewBox,i=t.offset,o=t.position,s=n,a=s.x,l=s.y,u=s.width,c=s.height,d=c>=0?1:-1,h=d*i,m=d>0?"end":"start",g=d>0?"start":"end",b=u>=0?1:-1,v=b*i,w=b>0?"end":"start",S=b>0?"start":"end";if(o==="top"){var C={x:a+u/2,y:l-d*i,textAnchor:"middle",verticalAnchor:m};return no(no({},C),r?{height:Math.max(l-r.y,0),width:u}:{})}if(o==="bottom"){var E={x:a+u/2,y:l+c+h,textAnchor:"middle",verticalAnchor:g};return no(no({},E),r?{height:Math.max(r.y+r.height-(l+c),0),width:u}:{})}if(o==="left"){var T={x:a-v,y:l+c/2,textAnchor:w,verticalAnchor:"middle"};return no(no({},T),r?{width:Math.max(T.x-r.x,0),height:c}:{})}if(o==="right"){var O={x:a+u+v,y:l+c/2,textAnchor:S,verticalAnchor:"middle"};return no(no({},O),r?{width:Math.max(r.x+r.width-O.x,0),height:c}:{})}var M=r?{width:u,height:c}:{};return o==="insideLeft"?no({x:a+v,y:l+c/2,textAnchor:S,verticalAnchor:"middle"},M):o==="insideRight"?no({x:a+u-v,y:l+c/2,textAnchor:w,verticalAnchor:"middle"},M):o==="insideTop"?no({x:a+u/2,y:l+h,textAnchor:"middle",verticalAnchor:g},M):o==="insideBottom"?no({x:a+u/2,y:l+c-h,textAnchor:"middle",verticalAnchor:m},M):o==="insideTopLeft"?no({x:a+v,y:l+h,textAnchor:S,verticalAnchor:g},M):o==="insideTopRight"?no({x:a+u-v,y:l+h,textAnchor:w,verticalAnchor:g},M):o==="insideBottomLeft"?no({x:a+v,y:l+c-h,textAnchor:S,verticalAnchor:m},M):o==="insideBottomRight"?no({x:a+u-v,y:l+c-h,textAnchor:w,verticalAnchor:m},M):cS(o)&&(ft(o.x)||ay(o.x))&&(ft(o.y)||ay(o.y))?no({x:a+xb(o.x,u),y:l+xb(o.y,c),textAnchor:"end",verticalAnchor:"end"},M):no({x:a+u/2,y:l+c/2,textAnchor:"middle",verticalAnchor:"middle"},M)},LDt=function(t){return"cx"in t&&ft(t.cx)};function ks(e){var t=e.offset,n=t===void 0?5:t,r=kDt(e,yDt),i=no({offset:n},r),o=i.viewBox,s=i.position,a=i.value,l=i.children,u=i.content,c=i.className,d=c===void 0?"":c,h=i.textBreakAll;if(!o||Rn(a)&&Rn(l)&&!A.isValidElement(u)&&!yn(u))return null;if(A.isValidElement(u))return A.cloneElement(u,i);var m;if(yn(u)){if(m=A.createElement(u,i),A.isValidElement(m))return m}else m=ODt(i);var g=LDt(o),b=wn(i,!0);if(g&&(s==="insideStart"||s==="insideEnd"||s==="end"))return MDt(i,m,b);var v=g?_Dt(i):NDt(i);return we.createElement(vI,vT({className:Hn("recharts-label",d)},b,v,{breakAll:h}),m)}ks.displayName="Label";var sIe=function(t){var n=t.cx,r=t.cy,i=t.angle,o=t.startAngle,s=t.endAngle,a=t.r,l=t.radius,u=t.innerRadius,c=t.outerRadius,d=t.x,h=t.y,m=t.top,g=t.left,b=t.width,v=t.height,w=t.clockWise,S=t.labelViewBox;if(S)return S;if(ft(b)&&ft(v)){if(ft(d)&&ft(h))return{x:d,y:h,width:b,height:v};if(ft(m)&&ft(g))return{x:m,y:g,width:b,height:v}}return ft(d)&&ft(h)?{x:d,y:h,width:0,height:0}:ft(n)&&ft(r)?{cx:n,cy:r,startAngle:o||i||0,endAngle:s||i||0,innerRadius:u||0,outerRadius:c||l||a||0,clockWise:w}:t.viewBox?t.viewBox:{}},IDt=function(t,n){return t?t===!0?we.createElement(ks,{key:"label-implicit",viewBox:n}):ho(t)?we.createElement(ks,{key:"label-implicit",viewBox:n,value:t}):A.isValidElement(t)?t.type===ks?A.cloneElement(t,{key:"label-implicit",viewBox:n}):we.createElement(ks,{key:"label-implicit",content:t,viewBox:n}):yn(t)?we.createElement(ks,{key:"label-implicit",content:t,viewBox:n}):cS(t)?we.createElement(ks,vT({viewBox:n},t,{key:"label-implicit"})):null:null},PDt=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!t||!t.children&&r&&!t.label)return null;var i=t.children,o=sIe(t),s=lu(i,ks).map(function(l,u){return A.cloneElement(l,{viewBox:n||o,key:"label-".concat(u)})});if(!r)return s;var a=IDt(t.label,n||o);return[a].concat(bDt(s))};ks.parseViewBox=sIe;ks.renderCallByParent=PDt;var bB,Cme;function jDt(){if(Cme)return bB;Cme=1;function e(t){var n=t==null?0:t.length;return n?t[n-1]:void 0}return bB=e,bB}var DDt=jDt();const $Dt=cr(DDt);function xT(e){"@babel/helpers - typeof";return xT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},xT(e)}var zDt=["valueAccessor"],FDt=["data","dataKey","clockWise","id","textBreakAll"];function BDt(e){return WDt(e)||VDt(e)||UDt(e)||HDt()}function HDt(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
@@ -2886,7 +2886,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2886
2886
  `);if(i>0){var O=gM({cx:n,cy:r,radius:i,angle:u,sign:d,isExternal:!0,cornerRadius:s,cornerIsExternal:l}),M=O.circleTangency,N=O.lineTangency,I=O.theta,D=gM({cx:n,cy:r,radius:i,angle:c,sign:-d,isExternal:!0,cornerRadius:s,cornerIsExternal:l}),P=D.circleTangency,F=D.lineTangency,z=D.theta,$=l?Math.abs(u-c):Math.abs(u-c)-I-z;if($<0&&s===0)return"".concat(T,"L").concat(n,",").concat(r,"Z");T+="L".concat(F.x,",").concat(F.y,`
2887
2887
  A`).concat(s,",").concat(s,",0,0,").concat(+(d<0),",").concat(P.x,",").concat(P.y,`
2888
2888
  A`).concat(i,",").concat(i,",0,").concat(+($>180),",").concat(+(d>0),",").concat(M.x,",").concat(M.y,`
2889
- A`).concat(s,",").concat(s,",0,0,").concat(+(d<0),",").concat(N.x,",").concat(N.y,"Z")}else T+="L".concat(n,",").concat(r,"Z");return T},i3t={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},lIe=function(t){var n=Rme(Rme({},i3t),t),r=n.cx,i=n.cy,o=n.innerRadius,s=n.outerRadius,a=n.cornerRadius,l=n.forceCornerRadius,u=n.cornerIsExternal,c=n.startAngle,d=n.endAngle,h=n.className;if(s<o||c===d)return null;var m=Hn("recharts-sector",h),g=s-o,b=xb(a,g,0,!0),v;return b>0&&Math.abs(c-d)<360?v=r3t({cx:r,cy:i,innerRadius:o,outerRadius:s,cornerRadius:Math.min(b,g/2),forceCornerRadius:l,cornerIsExternal:u,startAngle:c,endAngle:d}):v=aIe({cx:r,cy:i,innerRadius:o,outerRadius:s,startAngle:c,endAngle:d}),we.createElement("path",dW({},wn(n,!0),{className:m,d:v,role:"img"}))};function ST(e){"@babel/helpers - typeof";return ST=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ST(e)}function fW(){return fW=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},fW.apply(this,arguments)}function Mme(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 _me(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Mme(Object(n),!0).forEach(function(r){o3t(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Mme(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function o3t(e,t,n){return t=s3t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function s3t(e){var t=a3t(e,"string");return ST(t)=="symbol"?t:t+""}function a3t(e,t){if(ST(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(ST(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Nme={curveBasisClosed:yxt,curveBasisOpen:bxt,curveBasis:gxt,curveBumpX:nxt,curveBumpY:rxt,curveLinearClosed:vxt,curveLinear:zj,curveMonotoneX:NY,curveMonotoneY:xxt,curveNatural:lRe,curveStep:wxt,curveStepAfter:kxt,curveStepBefore:Sxt},yM=function(t){return t.x===+t.x&&t.y===+t.y},Ak=function(t){return t.x},Ok=function(t){return t.y},l3t=function(t,n){if(yn(t))return t;var r="curve".concat(vD(t));return(r==="curveMonotone"||r==="curveBump")&&n?Nme["".concat(r).concat(n==="vertical"?"Y":"X")]:Nme[r]||zj},u3t=function(t){var n=t.type,r=n===void 0?"linear":n,i=t.points,o=i===void 0?[]:i,s=t.baseLine,a=t.layout,l=t.connectNulls,u=l===void 0?!1:l,c=l3t(r,a),d=u?o.filter(function(b){return yM(b)}):o,h;if(Array.isArray(s)){var m=u?s.filter(function(b){return yM(b)}):s,g=d.map(function(b,v){return _me(_me({},b),{},{base:m[v]})});return a==="vertical"?h=dC().y(Ok).x1(Ak).x0(function(b){return b.base.x}):h=dC().x(Ak).y1(Ok).y0(function(b){return b.base.y}),h.defined(yM).curve(c),h(g)}return a==="vertical"&&ft(s)?h=dC().y(Ok).x1(Ak).x0(s):ft(s)?h=dC().x(Ak).y1(Ok).y0(s):h=Fj().x(Ak).y(Ok),h.defined(yM).curve(c),h(d)},q1=function(t){var n=t.className,r=t.points,i=t.path,o=t.pathRef;if((!r||!r.length)&&!i)return null;var s=r&&r.length?u3t(t):i;return A.createElement("path",fW({},wn(t,!1),fI(t),{className:Hn("recharts-curve",n),d:s,ref:o}))},vB={exports:{}},xB,Lme;function c3t(){if(Lme)return xB;Lme=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return xB=e,xB}var wB,Ime;function d3t(){if(Ime)return wB;Ime=1;var e=c3t();function t(){}function n(){}return n.resetWarningCache=t,wB=function(){function r(s,a,l,u,c,d){if(d!==e){var h=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw h.name="Invariant Violation",h}}r.isRequired=r;function i(){return r}var o={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:i,element:r,elementType:r,instanceOf:i,node:r,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:n,resetWarningCache:t};return o.PropTypes=o,o},wB}var Pme;function f3t(){return Pme||(Pme=1,vB.exports=d3t()()),vB.exports}var h3t=f3t();const vr=cr(h3t);function p3t(e){typeof requestAnimationFrame<"u"&&requestAnimationFrame(e)}function jme(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=-1,r=function i(o){n<0&&(n=o),o-n>t?(e(o),n=-1):p3t(i)};requestAnimationFrame(r)}function hW(e){"@babel/helpers - typeof";return hW=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},hW(e)}function m3t(e){return v3t(e)||b3t(e)||y3t(e)||g3t()}function g3t(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2889
+ A`).concat(s,",").concat(s,",0,0,").concat(+(d<0),",").concat(N.x,",").concat(N.y,"Z")}else T+="L".concat(n,",").concat(r,"Z");return T},i3t={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},lIe=function(t){var n=Rme(Rme({},i3t),t),r=n.cx,i=n.cy,o=n.innerRadius,s=n.outerRadius,a=n.cornerRadius,l=n.forceCornerRadius,u=n.cornerIsExternal,c=n.startAngle,d=n.endAngle,h=n.className;if(s<o||c===d)return null;var m=Hn("recharts-sector",h),g=s-o,b=xb(a,g,0,!0),v;return b>0&&Math.abs(c-d)<360?v=r3t({cx:r,cy:i,innerRadius:o,outerRadius:s,cornerRadius:Math.min(b,g/2),forceCornerRadius:l,cornerIsExternal:u,startAngle:c,endAngle:d}):v=aIe({cx:r,cy:i,innerRadius:o,outerRadius:s,startAngle:c,endAngle:d}),we.createElement("path",dW({},wn(n,!0),{className:m,d:v,role:"img"}))};function ST(e){"@babel/helpers - typeof";return ST=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ST(e)}function fW(){return fW=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},fW.apply(this,arguments)}function Mme(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 _me(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Mme(Object(n),!0).forEach(function(r){o3t(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Mme(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function o3t(e,t,n){return t=s3t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function s3t(e){var t=a3t(e,"string");return ST(t)=="symbol"?t:t+""}function a3t(e,t){if(ST(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(ST(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Nme={curveBasisClosed:Axt,curveBasisOpen:Oxt,curveBasis:Txt,curveBumpX:fxt,curveBumpY:hxt,curveLinearClosed:Rxt,curveLinear:zj,curveMonotoneX:LY,curveMonotoneY:Mxt,curveNatural:dRe,curveStep:_xt,curveStepAfter:Lxt,curveStepBefore:Nxt},yM=function(t){return t.x===+t.x&&t.y===+t.y},Ak=function(t){return t.x},Ok=function(t){return t.y},l3t=function(t,n){if(yn(t))return t;var r="curve".concat(vD(t));return(r==="curveMonotone"||r==="curveBump")&&n?Nme["".concat(r).concat(n==="vertical"?"Y":"X")]:Nme[r]||zj},u3t=function(t){var n=t.type,r=n===void 0?"linear":n,i=t.points,o=i===void 0?[]:i,s=t.baseLine,a=t.layout,l=t.connectNulls,u=l===void 0?!1:l,c=l3t(r,a),d=u?o.filter(function(b){return yM(b)}):o,h;if(Array.isArray(s)){var m=u?s.filter(function(b){return yM(b)}):s,g=d.map(function(b,v){return _me(_me({},b),{},{base:m[v]})});return a==="vertical"?h=dC().y(Ok).x1(Ak).x0(function(b){return b.base.x}):h=dC().x(Ak).y1(Ok).y0(function(b){return b.base.y}),h.defined(yM).curve(c),h(g)}return a==="vertical"&&ft(s)?h=dC().y(Ok).x1(Ak).x0(s):ft(s)?h=dC().x(Ak).y1(Ok).y0(s):h=Fj().x(Ak).y(Ok),h.defined(yM).curve(c),h(d)},q1=function(t){var n=t.className,r=t.points,i=t.path,o=t.pathRef;if((!r||!r.length)&&!i)return null;var s=r&&r.length?u3t(t):i;return A.createElement("path",fW({},wn(t,!1),fI(t),{className:Hn("recharts-curve",n),d:s,ref:o}))},vB={exports:{}},xB,Lme;function c3t(){if(Lme)return xB;Lme=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return xB=e,xB}var wB,Ime;function d3t(){if(Ime)return wB;Ime=1;var e=c3t();function t(){}function n(){}return n.resetWarningCache=t,wB=function(){function r(s,a,l,u,c,d){if(d!==e){var h=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw h.name="Invariant Violation",h}}r.isRequired=r;function i(){return r}var o={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:i,element:r,elementType:r,instanceOf:i,node:r,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:n,resetWarningCache:t};return o.PropTypes=o,o},wB}var Pme;function f3t(){return Pme||(Pme=1,vB.exports=d3t()()),vB.exports}var h3t=f3t();const vr=cr(h3t);function p3t(e){typeof requestAnimationFrame<"u"&&requestAnimationFrame(e)}function jme(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=-1,r=function i(o){n<0&&(n=o),o-n>t?(e(o),n=-1):p3t(i)};requestAnimationFrame(r)}function hW(e){"@babel/helpers - typeof";return hW=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},hW(e)}function m3t(e){return v3t(e)||b3t(e)||y3t(e)||g3t()}function g3t(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2890
2890
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function y3t(e,t){if(e){if(typeof e=="string")return Dme(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Dme(e,t)}}function Dme(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function b3t(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function v3t(e){if(Array.isArray(e))return e}function x3t(){var e={},t=function(){return null},n=!1,r=function i(o){if(!n){if(Array.isArray(o)){if(!o.length)return;var s=o,a=m3t(s),l=a[0],u=a.slice(1);if(typeof l=="number"){jme(i.bind(null,u),l);return}i(l),jme(i.bind(null,u));return}hW(o)==="object"&&(e=o,t(e)),typeof o=="function"&&o()}};return{stop:function(){n=!0},start:function(o){n=!1,r(o)},subscribe:function(o){return t=o,function(){t=function(){return null}}}}}function kT(e){"@babel/helpers - typeof";return kT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},kT(e)}function $me(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 zme(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?$me(Object(n),!0).forEach(function(r){uIe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$me(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function uIe(e,t,n){return t=w3t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function w3t(e){var t=S3t(e,"string");return kT(t)==="symbol"?t:String(t)}function S3t(e,t){if(kT(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(kT(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var k3t=function(t,n){return[Object.keys(t),Object.keys(n)].reduce(function(r,i){return r.filter(function(o){return i.includes(o)})})},C3t=function(t){return t},E3t=function(t){return t.replace(/([A-Z])/g,function(n){return"-".concat(n.toLowerCase())})},nE=function(t,n){return Object.keys(n).reduce(function(r,i){return zme(zme({},r),{},uIe({},i,t(i,n[i])))},{})},Fme=function(t,n,r){return t.map(function(i){return"".concat(E3t(i)," ").concat(n,"ms ").concat(r)}).join(",")};function T3t(e,t){return R3t(e)||O3t(e,t)||cIe(e,t)||A3t()}function A3t(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2891
2891
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function O3t(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,s,a=[],l=!0,u=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(l=(r=o.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(c){u=!0,i=c}finally{try{if(!l&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw i}}return a}}function R3t(e){if(Array.isArray(e))return e}function M3t(e){return L3t(e)||N3t(e)||cIe(e)||_3t()}function _3t(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
2892
2892
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function cIe(e,t){if(e){if(typeof e=="string")return pW(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return pW(e,t)}}function N3t(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function L3t(e){if(Array.isArray(e))return pW(e)}function pW(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var AI=1e-4,dIe=function(t,n){return[0,3*t,3*n-6*t,3*t-3*n+1]},fIe=function(t,n){return t.map(function(r,i){return r*Math.pow(n,i)}).reduce(function(r,i){return r+i})},Bme=function(t,n){return function(r){var i=dIe(t,n);return fIe(i,r)}},I3t=function(t,n){return function(r){var i=dIe(t,n),o=[].concat(M3t(i.map(function(s,a){return s*a}).slice(1)),[0]);return fIe(o,r)}},Hme=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=n[0],o=n[1],s=n[2],a=n[3];if(n.length===1)switch(n[0]){case"linear":i=0,o=0,s=1,a=1;break;case"ease":i=.25,o=.1,s=.25,a=1;break;case"ease-in":i=.42,o=0,s=1,a=1;break;case"ease-out":i=.42,o=0,s=.58,a=1;break;case"ease-in-out":i=0,o=0,s=.58,a=1;break;default:{var l=n[0].split("(");if(l[0]==="cubic-bezier"&&l[1].split(")")[0].split(",").length===4){var u=l[1].split(")")[0].split(",").map(function(v){return parseFloat(v)}),c=T3t(u,4);i=c[0],o=c[1],s=c[2],a=c[3]}}}var d=Bme(i,s),h=Bme(o,a),m=I3t(i,s),g=function(w){return w>1?1:w<0?0:w},b=function(w){for(var S=w>1?1:w,C=S,E=0;E<8;++E){var T=d(C)-S,O=m(C);if(Math.abs(T-S)<AI||O<AI)return h(C);C=g(C-T/O)}return h(C)};return b.isStepper=!1,b},P3t=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.stiff,r=n===void 0?100:n,i=t.damping,o=i===void 0?8:i,s=t.dt,a=s===void 0?17:s,l=function(c,d,h){var m=-(c-d)*r,g=h*o,b=h+(m-g)*a/1e3,v=h*a/1e3+c;return Math.abs(v-d)<AI&&Math.abs(b)<AI?[d,0]:[v,b]};return l.isStepper=!0,l.dt=a,l},j3t=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=n[0];if(typeof i=="string")switch(i){case"ease":case"ease-in-out":case"ease-out":case"ease-in":case"linear":return Hme(i);case"spring":return P3t();default:if(i.split("(")[0]==="cubic-bezier")return Hme(i)}return typeof i=="function"?i:null};function CT(e){"@babel/helpers - typeof";return CT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},CT(e)}function Ume(e){return z3t(e)||$3t(e)||hIe(e)||D3t()}function D3t(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
@@ -2903,8 +2903,8 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
2903
2903
  L `).concat(t+r,",").concat(n+i-a*g,`
2904
2904
  A `).concat(g,",").concat(g,",0,0,").concat(u,",").concat(t+r-l*g,",").concat(n+i,`
2905
2905
  L `).concat(t+l*g,",").concat(n+i,`
2906
- A `).concat(g,",").concat(g,",0,0,").concat(u,",").concat(t,",").concat(n+i-a*g," Z")}else c="M ".concat(t,",").concat(n," h ").concat(r," v ").concat(i," h ").concat(-r," Z");return c},g5t=function(t,n){if(!t||!n)return!1;var r=t.x,i=t.y,o=n.x,s=n.y,a=n.width,l=n.height;if(Math.abs(a)>0&&Math.abs(l)>0){var u=Math.min(o,o+a),c=Math.max(o,o+a),d=Math.min(s,s+l),h=Math.max(s,s+l);return r>=u&&r<=c&&i>=d&&i<=h}return!1},y5t={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},fQ=function(t){var n=Kme(Kme({},y5t),t),r=A.useRef(),i=A.useState(-1),o=l5t(i,2),s=o[0],a=o[1];A.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var E=r.current.getTotalLength();E&&a(E)}catch{}},[]);var l=n.x,u=n.y,c=n.width,d=n.height,h=n.radius,m=n.className,g=n.animationEasing,b=n.animationDuration,v=n.animationBegin,w=n.isAnimationActive,S=n.isUpdateAnimationActive;if(l!==+l||u!==+u||c!==+c||d!==+d||c===0||d===0)return null;var C=Hn("recharts-rectangle",m);return S?we.createElement(Pd,{canBegin:s>0,from:{width:c,height:d,x:l,y:u},to:{width:c,height:d,x:l,y:u},duration:b,animationEasing:g,isActive:S},function(E){var T=E.width,O=E.height,M=E.x,N=E.y;return we.createElement(Pd,{canBegin:s>0,from:"0px ".concat(s===-1?1:s,"px"),to:"".concat(s,"px 0px"),attributeName:"strokeDasharray",begin:v,duration:b,isActive:w,easing:g},we.createElement("path",MI({},wn(n,!0),{className:C,d:Yme(M,N,T,O,h),ref:r})))}):we.createElement("path",MI({},wn(n,!0),{className:C,d:Yme(l,u,c,d,h)}))};function SW(){return SW=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},SW.apply(this,arguments)}var TD=function(t){var n=t.cx,r=t.cy,i=t.r,o=t.className,s=Hn("recharts-dot",o);return n===+n&&r===+r&&i===+i?A.createElement("circle",SW({},wn(t,!1),fI(t),{className:s,cx:n,cy:r,r:i})):null};function TT(e){"@babel/helpers - typeof";return TT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},TT(e)}var b5t=["x","y","top","left","width","height","className"];function kW(){return kW=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},kW.apply(this,arguments)}function Xme(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 v5t(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Xme(Object(n),!0).forEach(function(r){x5t(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Xme(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function x5t(e,t,n){return t=w5t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function w5t(e){var t=S5t(e,"string");return TT(t)=="symbol"?t:t+""}function S5t(e,t){if(TT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(TT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function k5t(e,t){if(e==null)return{};var n=C5t(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function C5t(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var E5t=function(t,n,r,i,o,s){return"M".concat(t,",").concat(o,"v").concat(i,"M").concat(s,",").concat(n,"h").concat(r)},T5t=function(t){var n=t.x,r=n===void 0?0:n,i=t.y,o=i===void 0?0:i,s=t.top,a=s===void 0?0:s,l=t.left,u=l===void 0?0:l,c=t.width,d=c===void 0?0:c,h=t.height,m=h===void 0?0:h,g=t.className,b=k5t(t,b5t),v=v5t({x:r,y:o,top:a,left:u,width:d,height:m},b);return!ft(r)||!ft(o)||!ft(d)||!ft(m)||!ft(a)||!ft(u)?null:we.createElement("path",kW({},wn(v,!0),{className:Hn("recharts-cross",g),d:E5t(r,o,d,m,a,u)}))},kB,Qme;function A5t(){if(Qme)return kB;Qme=1;var e=mLe(),t=e(Object.getPrototypeOf,Object);return kB=t,kB}var CB,Zme;function O5t(){if(Zme)return CB;Zme=1;var e=Jh(),t=A5t(),n=ep(),r="[object Object]",i=Function.prototype,o=Object.prototype,s=i.toString,a=o.hasOwnProperty,l=s.call(Object);function u(c){if(!n(c)||e(c)!=r)return!1;var d=t(c);if(d===null)return!0;var h=a.call(d,"constructor")&&d.constructor;return typeof h=="function"&&h instanceof h&&s.call(h)==l}return CB=u,CB}var R5t=O5t();const M5t=cr(R5t);var EB,Jme;function _5t(){if(Jme)return EB;Jme=1;var e=Jh(),t=ep(),n="[object Boolean]";function r(i){return i===!0||i===!1||t(i)&&e(i)==n}return EB=r,EB}var N5t=_5t();const L5t=cr(N5t);function AT(e){"@babel/helpers - typeof";return AT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},AT(e)}function _I(){return _I=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},_I.apply(this,arguments)}function I5t(e,t){return $5t(e)||D5t(e,t)||j5t(e,t)||P5t()}function P5t(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2907
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function j5t(e,t){if(e){if(typeof e=="string")return ege(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ege(e,t)}}function ege(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function D5t(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,s,a=[],l=!0,u=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(l=(r=o.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(c){u=!0,i=c}finally{try{if(!l&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw i}}return a}}function $5t(e){if(Array.isArray(e))return e}function tge(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 nge(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?tge(Object(n),!0).forEach(function(r){z5t(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function z5t(e,t,n){return t=F5t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function F5t(e){var t=B5t(e,"string");return AT(t)=="symbol"?t:t+""}function B5t(e,t){if(AT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(AT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var rge=function(t,n,r,i,o){var s=r-i,a;return a="M ".concat(t,",").concat(n),a+="L ".concat(t+r,",").concat(n),a+="L ".concat(t+r-s/2,",").concat(n+o),a+="L ".concat(t+r-s/2-i,",").concat(n+o),a+="L ".concat(t,",").concat(n," Z"),a},H5t={x:0,y:0,upperWidth:0,lowerWidth:0,height:0,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},U5t=function(t){var n=nge(nge({},H5t),t),r=A.useRef(),i=A.useState(-1),o=I5t(i,2),s=o[0],a=o[1];A.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var C=r.current.getTotalLength();C&&a(C)}catch{}},[]);var l=n.x,u=n.y,c=n.upperWidth,d=n.lowerWidth,h=n.height,m=n.className,g=n.animationEasing,b=n.animationDuration,v=n.animationBegin,w=n.isUpdateAnimationActive;if(l!==+l||u!==+u||c!==+c||d!==+d||h!==+h||c===0&&d===0||h===0)return null;var S=Hn("recharts-trapezoid",m);return w?we.createElement(Pd,{canBegin:s>0,from:{upperWidth:0,lowerWidth:0,height:h,x:l,y:u},to:{upperWidth:c,lowerWidth:d,height:h,x:l,y:u},duration:b,animationEasing:g,isActive:w},function(C){var E=C.upperWidth,T=C.lowerWidth,O=C.height,M=C.x,N=C.y;return we.createElement(Pd,{canBegin:s>0,from:"0px ".concat(s===-1?1:s,"px"),to:"".concat(s,"px 0px"),attributeName:"strokeDasharray",begin:v,duration:b,easing:g},we.createElement("path",_I({},wn(n,!0),{className:S,d:rge(M,N,E,T,O),ref:r})))}):we.createElement("g",null,we.createElement("path",_I({},wn(n,!0),{className:S,d:rge(l,u,c,d,h)})))},V5t=["option","shapeType","propTransformer","activeClassName","isActive"];function OT(e){"@babel/helpers - typeof";return OT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},OT(e)}function W5t(e,t){if(e==null)return{};var n=q5t(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function q5t(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function ige(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 NI(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ige(Object(n),!0).forEach(function(r){G5t(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ige(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function G5t(e,t,n){return t=K5t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function K5t(e){var t=Y5t(e,"string");return OT(t)=="symbol"?t:t+""}function Y5t(e,t){if(OT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(OT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function X5t(e,t){return NI(NI({},t),e)}function Q5t(e,t){return e==="symbols"}function oge(e){var t=e.shapeType,n=e.elementProps;switch(t){case"rectangle":return we.createElement(fQ,n);case"trapezoid":return we.createElement(U5t,n);case"sector":return we.createElement(lIe,n);case"symbols":if(Q5t(t))return we.createElement(JX,n);break;default:return null}}function Z5t(e){return A.isValidElement(e)?e.props:e}function J5t(e){var t=e.option,n=e.shapeType,r=e.propTransformer,i=r===void 0?X5t:r,o=e.activeClassName,s=o===void 0?"recharts-active-shape":o,a=e.isActive,l=W5t(e,V5t),u;if(A.isValidElement(t))u=A.cloneElement(t,NI(NI({},l),Z5t(t)));else if(yn(t))u=t(l);else if(M5t(t)&&!L5t(t)){var c=i(t,l);u=we.createElement(oge,{shapeType:n,elementProps:c})}else{var d=l;u=we.createElement(oge,{shapeType:n,elementProps:d})}return a?we.createElement(Yr,{className:s},u):u}function AD(e,t){return t!=null&&"trapezoids"in e.props}function OD(e,t){return t!=null&&"sectors"in e.props}function RT(e,t){return t!=null&&"points"in e.props}function e6t(e,t){var n,r,i=e.x===(t==null||(n=t.labelViewBox)===null||n===void 0?void 0:n.x)||e.x===t.x,o=e.y===(t==null||(r=t.labelViewBox)===null||r===void 0?void 0:r.y)||e.y===t.y;return i&&o}function t6t(e,t){var n=e.endAngle===t.endAngle,r=e.startAngle===t.startAngle;return n&&r}function n6t(e,t){var n=e.x===t.x,r=e.y===t.y,i=e.z===t.z;return n&&r&&i}function r6t(e,t){var n;return AD(e,t)?n=e6t:OD(e,t)?n=t6t:RT(e,t)&&(n=n6t),n}function i6t(e,t){var n;return AD(e,t)?n="trapezoids":OD(e,t)?n="sectors":RT(e,t)&&(n="points"),n}function o6t(e,t){if(AD(e,t)){var n;return(n=t.tooltipPayload)===null||n===void 0||(n=n[0])===null||n===void 0||(n=n.payload)===null||n===void 0?void 0:n.payload}if(OD(e,t)){var r;return(r=t.tooltipPayload)===null||r===void 0||(r=r[0])===null||r===void 0||(r=r.payload)===null||r===void 0?void 0:r.payload}return RT(e,t)?t.payload:{}}function s6t(e){var t=e.activeTooltipItem,n=e.graphicalItem,r=e.itemData,i=i6t(n,t),o=o6t(n,t),s=r.filter(function(l,u){var c=fw(o,l),d=n.props[i].filter(function(g){var b=r6t(n,t);return b(g,t)}),h=n.props[i].indexOf(d[d.length-1]),m=u===h;return c&&m}),a=r.indexOf(s[s.length-1]);return a}var TB,sge;function a6t(){if(sge)return TB;sge=1;var e=Math.ceil,t=Math.max;function n(r,i,o,s){for(var a=-1,l=t(e((i-r)/(o||1)),0),u=Array(l);l--;)u[s?l:++a]=r,r+=o;return u}return TB=n,TB}var AB,age;function mIe(){if(age)return AB;age=1;var e=wNe(),t=1/0,n=17976931348623157e292;function r(i){if(!i)return i===0?i:0;if(i=e(i),i===t||i===-t){var o=i<0?-1:1;return o*n}return i===i?i:0}return AB=r,AB}var OB,lge;function l6t(){if(lge)return OB;lge=1;var e=a6t(),t=SD(),n=mIe();function r(i){return function(o,s,a){return a&&typeof a!="number"&&t(o,s,a)&&(s=a=void 0),o=n(o),s===void 0?(s=o,o=0):s=n(s),a=a===void 0?o<s?1:-1:n(a),e(o,s,a,i)}}return OB=r,OB}var RB,uge;function u6t(){if(uge)return RB;uge=1;var e=l6t(),t=e();return RB=t,RB}var c6t=u6t();const LI=cr(c6t);function MT(e){"@babel/helpers - typeof";return MT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},MT(e)}function cge(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 dge(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?cge(Object(n),!0).forEach(function(r){gIe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):cge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function gIe(e,t,n){return t=d6t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function d6t(e){var t=f6t(e,"string");return MT(t)=="symbol"?t:t+""}function f6t(e,t){if(MT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(MT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var h6t=["Webkit","Moz","O","ms"],p6t=function(t,n){var r=t.replace(/(\w)/,function(o){return o.toUpperCase()}),i=h6t.reduce(function(o,s){return dge(dge({},o),{},gIe({},s+r,n))},{});return i[t]=n,i};function mw(e){"@babel/helpers - typeof";return mw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},mw(e)}function II(){return II=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},II.apply(this,arguments)}function fge(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 MB(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?fge(Object(n),!0).forEach(function(r){Ya(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function m6t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function hge(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,bIe(r.key),r)}}function g6t(e,t,n){return t&&hge(e.prototype,t),n&&hge(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function y6t(e,t,n){return t=PI(t),b6t(e,yIe()?Reflect.construct(t,n||[],PI(e).constructor):t.apply(e,n))}function b6t(e,t){if(t&&(mw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return v6t(e)}function v6t(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function yIe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(yIe=function(){return!!e})()}function PI(e){return PI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},PI(e)}function x6t(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&CW(e,t)}function CW(e,t){return CW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},CW(e,t)}function Ya(e,t,n){return t=bIe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function bIe(e){var t=w6t(e,"string");return mw(t)=="symbol"?t:t+""}function w6t(e,t){if(mw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(mw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var S6t=function(t){var n=t.data,r=t.startIndex,i=t.endIndex,o=t.x,s=t.width,a=t.travellerWidth;if(!n||!n.length)return{};var l=n.length,u=GC().domain(LI(0,l)).range([o,o+s-a]),c=u.domain().map(function(d){return u(d)});return{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,isTravellerFocused:!1,startX:u(r),endX:u(i),scale:u,scaleValues:c}},pge=function(t){return t.changedTouches&&!!t.changedTouches.length},gw=(function(e){function t(n){var r;return m6t(this,t),r=y6t(this,t,[n]),Ya(r,"handleDrag",function(i){r.leaveTimer&&(clearTimeout(r.leaveTimer),r.leaveTimer=null),r.state.isTravellerMoving?r.handleTravellerMove(i):r.state.isSlideMoving&&r.handleSlideDrag(i)}),Ya(r,"handleTouchMove",function(i){i.changedTouches!=null&&i.changedTouches.length>0&&r.handleDrag(i.changedTouches[0])}),Ya(r,"handleDragEnd",function(){r.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var i=r.props,o=i.endIndex,s=i.onDragEnd,a=i.startIndex;s==null||s({endIndex:o,startIndex:a})}),r.detachDragEndListener()}),Ya(r,"handleLeaveWrapper",function(){(r.state.isTravellerMoving||r.state.isSlideMoving)&&(r.leaveTimer=window.setTimeout(r.handleDragEnd,r.props.leaveTimeOut))}),Ya(r,"handleEnterSlideOrTraveller",function(){r.setState({isTextActive:!0})}),Ya(r,"handleLeaveSlideOrTraveller",function(){r.setState({isTextActive:!1})}),Ya(r,"handleSlideDragStart",function(i){var o=pge(i)?i.changedTouches[0]:i;r.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:o.pageX}),r.attachDragEndListener()}),r.travellerDragStartHandlers={startX:r.handleTravellerDragStart.bind(r,"startX"),endX:r.handleTravellerDragStart.bind(r,"endX")},r.state={},r}return x6t(t,e),g6t(t,[{key:"componentWillUnmount",value:function(){this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null),this.detachDragEndListener()}},{key:"getIndex",value:function(r){var i=r.startX,o=r.endX,s=this.state.scaleValues,a=this.props,l=a.gap,u=a.data,c=u.length-1,d=Math.min(i,o),h=Math.max(i,o),m=t.getIndexInRange(s,d),g=t.getIndexInRange(s,h);return{startIndex:m-m%l,endIndex:g===c?c:g-g%l}}},{key:"getTextOfTick",value:function(r){var i=this.props,o=i.data,s=i.tickFormatter,a=i.dataKey,l=na(o[r],a,r);return yn(s)?s(l,r):l}},{key:"attachDragEndListener",value:function(){window.addEventListener("mouseup",this.handleDragEnd,!0),window.addEventListener("touchend",this.handleDragEnd,!0),window.addEventListener("mousemove",this.handleDrag,!0)}},{key:"detachDragEndListener",value:function(){window.removeEventListener("mouseup",this.handleDragEnd,!0),window.removeEventListener("touchend",this.handleDragEnd,!0),window.removeEventListener("mousemove",this.handleDrag,!0)}},{key:"handleSlideDrag",value:function(r){var i=this.state,o=i.slideMoveStartX,s=i.startX,a=i.endX,l=this.props,u=l.x,c=l.width,d=l.travellerWidth,h=l.startIndex,m=l.endIndex,g=l.onChange,b=r.pageX-o;b>0?b=Math.min(b,u+c-d-a,u+c-d-s):b<0&&(b=Math.max(b,u-s,u-a));var v=this.getIndex({startX:s+b,endX:a+b});(v.startIndex!==h||v.endIndex!==m)&&g&&g(v),this.setState({startX:s+b,endX:a+b,slideMoveStartX:r.pageX})}},{key:"handleTravellerDragStart",value:function(r,i){var o=pge(i)?i.changedTouches[0]:i;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:r,brushMoveStartX:o.pageX}),this.attachDragEndListener()}},{key:"handleTravellerMove",value:function(r){var i=this.state,o=i.brushMoveStartX,s=i.movingTravellerId,a=i.endX,l=i.startX,u=this.state[s],c=this.props,d=c.x,h=c.width,m=c.travellerWidth,g=c.onChange,b=c.gap,v=c.data,w={startX:this.state.startX,endX:this.state.endX},S=r.pageX-o;S>0?S=Math.min(S,d+h-m-u):S<0&&(S=Math.max(S,d-u)),w[s]=u+S;var C=this.getIndex(w),E=C.startIndex,T=C.endIndex,O=function(){var N=v.length-1;return s==="startX"&&(a>l?E%b===0:T%b===0)||a<l&&T===N||s==="endX"&&(a>l?T%b===0:E%b===0)||a>l&&T===N};this.setState(Ya(Ya({},s,u+S),"brushMoveStartX",r.pageX),function(){g&&O()&&g(C)})}},{key:"handleTravellerMoveKeyboard",value:function(r,i){var o=this,s=this.state,a=s.scaleValues,l=s.startX,u=s.endX,c=this.state[i],d=a.indexOf(c);if(d!==-1){var h=d+r;if(!(h===-1||h>=a.length)){var m=a[h];i==="startX"&&m>=u||i==="endX"&&m<=l||this.setState(Ya({},i,m),function(){o.props.onChange(o.getIndex({startX:o.state.startX,endX:o.state.endX}))})}}}},{key:"renderBackground",value:function(){var r=this.props,i=r.x,o=r.y,s=r.width,a=r.height,l=r.fill,u=r.stroke;return we.createElement("rect",{stroke:u,fill:l,x:i,y:o,width:s,height:a})}},{key:"renderPanorama",value:function(){var r=this.props,i=r.x,o=r.y,s=r.width,a=r.height,l=r.data,u=r.children,c=r.padding,d=A.Children.only(u);return d?we.cloneElement(d,{x:i,y:o,width:s,height:a,margin:c,compact:!0,data:l}):null}},{key:"renderTravellerLayer",value:function(r,i){var o,s,a=this,l=this.props,u=l.y,c=l.travellerWidth,d=l.height,h=l.traveller,m=l.ariaLabel,g=l.data,b=l.startIndex,v=l.endIndex,w=Math.max(r,this.props.x),S=MB(MB({},wn(this.props,!1)),{},{x:w,y:u,width:c,height:d}),C=m||"Min value: ".concat((o=g[b])===null||o===void 0?void 0:o.name,", Max value: ").concat((s=g[v])===null||s===void 0?void 0:s.name);return we.createElement(Yr,{tabIndex:0,role:"slider","aria-label":C,"aria-valuenow":r,className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[i],onTouchStart:this.travellerDragStartHandlers[i],onKeyDown:function(T){["ArrowLeft","ArrowRight"].includes(T.key)&&(T.preventDefault(),T.stopPropagation(),a.handleTravellerMoveKeyboard(T.key==="ArrowRight"?1:-1,i))},onFocus:function(){a.setState({isTravellerFocused:!0})},onBlur:function(){a.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},t.renderTraveller(h,S))}},{key:"renderSlide",value:function(r,i){var o=this.props,s=o.y,a=o.height,l=o.stroke,u=o.travellerWidth,c=Math.min(r,i)+u,d=Math.max(Math.abs(i-r)-u,0);return we.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:l,fillOpacity:.2,x:c,y:s,width:d,height:a})}},{key:"renderText",value:function(){var r=this.props,i=r.startIndex,o=r.endIndex,s=r.y,a=r.height,l=r.travellerWidth,u=r.stroke,c=this.state,d=c.startX,h=c.endX,m=5,g={pointerEvents:"none",fill:u};return we.createElement(Yr,{className:"recharts-brush-texts"},we.createElement(vI,II({textAnchor:"end",verticalAnchor:"middle",x:Math.min(d,h)-m,y:s+a/2},g),this.getTextOfTick(i)),we.createElement(vI,II({textAnchor:"start",verticalAnchor:"middle",x:Math.max(d,h)+l+m,y:s+a/2},g),this.getTextOfTick(o)))}},{key:"render",value:function(){var r=this.props,i=r.data,o=r.className,s=r.children,a=r.x,l=r.y,u=r.width,c=r.height,d=r.alwaysShowText,h=this.state,m=h.startX,g=h.endX,b=h.isTextActive,v=h.isSlideMoving,w=h.isTravellerMoving,S=h.isTravellerFocused;if(!i||!i.length||!ft(a)||!ft(l)||!ft(u)||!ft(c)||u<=0||c<=0)return null;var C=Hn("recharts-brush",o),E=we.Children.count(s)===1,T=p6t("userSelect","none");return we.createElement(Yr,{className:C,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:T},this.renderBackground(),E&&this.renderPanorama(),this.renderSlide(m,g),this.renderTravellerLayer(m,"startX"),this.renderTravellerLayer(g,"endX"),(b||v||w||S||d)&&this.renderText())}}],[{key:"renderDefaultTraveller",value:function(r){var i=r.x,o=r.y,s=r.width,a=r.height,l=r.stroke,u=Math.floor(o+a/2)-1;return we.createElement(we.Fragment,null,we.createElement("rect",{x:i,y:o,width:s,height:a,fill:l,stroke:"none"}),we.createElement("line",{x1:i+1,y1:u,x2:i+s-1,y2:u,fill:"none",stroke:"#fff"}),we.createElement("line",{x1:i+1,y1:u+2,x2:i+s-1,y2:u+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(r,i){var o;return we.isValidElement(r)?o=we.cloneElement(r,i):yn(r)?o=r(i):o=t.renderDefaultTraveller(i),o}},{key:"getDerivedStateFromProps",value:function(r,i){var o=r.data,s=r.width,a=r.x,l=r.travellerWidth,u=r.updateId,c=r.startIndex,d=r.endIndex;if(o!==i.prevData||u!==i.prevUpdateId)return MB({prevData:o,prevTravellerWidth:l,prevUpdateId:u,prevX:a,prevWidth:s},o&&o.length?S6t({data:o,width:s,x:a,travellerWidth:l,startIndex:c,endIndex:d}):{scale:null,scaleValues:null});if(i.scale&&(s!==i.prevWidth||a!==i.prevX||l!==i.prevTravellerWidth)){i.scale.range([a,a+s-l]);var h=i.scale.domain().map(function(m){return i.scale(m)});return{prevData:o,prevTravellerWidth:l,prevUpdateId:u,prevX:a,prevWidth:s,startX:i.scale(r.startIndex),endX:i.scale(r.endIndex),scaleValues:h}}return null}},{key:"getIndexInRange",value:function(r,i){for(var o=r.length,s=0,a=o-1;a-s>1;){var l=Math.floor((s+a)/2);r[l]>i?a=l:s=l}return i>=r[a]?a:s}}])})(A.PureComponent);Ya(gw,"displayName","Brush");Ya(gw,"defaultProps",{height:40,travellerWidth:5,gap:1,fill:"#fff",stroke:"#666",padding:{top:1,right:1,bottom:1,left:1},leaveTimeOut:1e3,alwaysShowText:!1});var _B,mge;function k6t(){if(mge)return _B;mge=1;var e=sQ();function t(n,r){var i;return e(n,function(o,s,a){return i=r(o,s,a),!i}),!!i}return _B=t,_B}var NB,gge;function C6t(){if(gge)return NB;gge=1;var e=lLe(),t=Wg(),n=k6t(),r=Na(),i=SD();function o(s,a,l){var u=r(s)?e:n;return l&&i(s,a,l)&&(a=void 0),u(s,t(a,3))}return NB=o,NB}var E6t=C6t();const T6t=cr(E6t);var Ed=function(t,n){var r=t.alwaysShow,i=t.ifOverflow;return r&&(i="extendDomain"),i===n},LB,yge;function A6t(){if(yge)return LB;yge=1;var e=TLe();function t(n,r,i){r=="__proto__"&&e?e(n,r,{configurable:!0,enumerable:!0,value:i,writable:!0}):n[r]=i}return LB=t,LB}var IB,bge;function O6t(){if(bge)return IB;bge=1;var e=A6t(),t=CLe(),n=Wg();function r(i,o){var s={};return o=n(o,3),t(i,function(a,l,u){e(s,l,o(a,l,u))}),s}return IB=r,IB}var R6t=O6t();const M6t=cr(R6t);var PB,vge;function _6t(){if(vge)return PB;vge=1;function e(t,n){for(var r=-1,i=t==null?0:t.length;++r<i;)if(!n(t[r],r,t))return!1;return!0}return PB=e,PB}var jB,xge;function N6t(){if(xge)return jB;xge=1;var e=sQ();function t(n,r){var i=!0;return e(n,function(o,s,a){return i=!!r(o,s,a),i}),i}return jB=t,jB}var DB,wge;function L6t(){if(wge)return DB;wge=1;var e=_6t(),t=N6t(),n=Wg(),r=Na(),i=SD();function o(s,a,l){var u=r(s)?e:t;return l&&i(s,a,l)&&(a=void 0),u(s,n(a,3))}return DB=o,DB}var I6t=L6t();const vIe=cr(I6t);var P6t=["x","y"];function _T(e){"@babel/helpers - typeof";return _T=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_T(e)}function EW(){return EW=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},EW.apply(this,arguments)}function Sge(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 Rk(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Sge(Object(n),!0).forEach(function(r){j6t(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Sge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function j6t(e,t,n){return t=D6t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function D6t(e){var t=$6t(e,"string");return _T(t)=="symbol"?t:t+""}function $6t(e,t){if(_T(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(_T(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function z6t(e,t){if(e==null)return{};var n=F6t(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function F6t(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function B6t(e,t){var n=e.x,r=e.y,i=z6t(e,P6t),o="".concat(n),s=parseInt(o,10),a="".concat(r),l=parseInt(a,10),u="".concat(t.height||i.height),c=parseInt(u,10),d="".concat(t.width||i.width),h=parseInt(d,10);return Rk(Rk(Rk(Rk(Rk({},t),i),s?{x:s}:{}),l?{y:l}:{}),{},{height:c,width:h,name:t.name,radius:t.radius})}function kge(e){return we.createElement(J5t,EW({shapeType:"rectangle",propTransformer:B6t,activeClassName:"recharts-active-bar"},e))}var H6t=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return function(r,i){if(typeof t=="number")return t;var o=ft(r)||U_t(r);return o?t(r,i):(o||Sb(),n)}},U6t=["value","background"],xIe;function yw(e){"@babel/helpers - typeof";return yw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},yw(e)}function V6t(e,t){if(e==null)return{};var n=W6t(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function W6t(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function jI(){return jI=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},jI.apply(this,arguments)}function Cge(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 Ki(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Cge(Object(n),!0).forEach(function(r){Qm(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Cge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function q6t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ege(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,SIe(r.key),r)}}function G6t(e,t,n){return t&&Ege(e.prototype,t),n&&Ege(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function K6t(e,t,n){return t=DI(t),Y6t(e,wIe()?Reflect.construct(t,n||[],DI(e).constructor):t.apply(e,n))}function Y6t(e,t){if(t&&(yw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return X6t(e)}function X6t(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function wIe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(wIe=function(){return!!e})()}function DI(e){return DI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},DI(e)}function Q6t(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&TW(e,t)}function TW(e,t){return TW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},TW(e,t)}function Qm(e,t,n){return t=SIe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function SIe(e){var t=Z6t(e,"string");return yw(t)=="symbol"?t:t+""}function Z6t(e,t){if(yw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(yw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Bb=(function(e){function t(){var n;q6t(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=K6t(this,t,[].concat(i)),Qm(n,"state",{isAnimationFinished:!1}),Qm(n,"id",fS("recharts-bar-")),Qm(n,"handleAnimationEnd",function(){var s=n.props.onAnimationEnd;n.setState({isAnimationFinished:!0}),s&&s()}),Qm(n,"handleAnimationStart",function(){var s=n.props.onAnimationStart;n.setState({isAnimationFinished:!1}),s&&s()}),n}return Q6t(t,e),G6t(t,[{key:"renderRectanglesStatically",value:function(r){var i=this,o=this.props,s=o.shape,a=o.dataKey,l=o.activeIndex,u=o.activeBar,c=wn(this.props,!1);return r&&r.map(function(d,h){var m=h===l,g=m?u:s,b=Ki(Ki(Ki({},c),d),{},{isActive:m,option:g,index:h,dataKey:a,onAnimationStart:i.handleAnimationStart,onAnimationEnd:i.handleAnimationEnd});return we.createElement(Yr,jI({className:"recharts-bar-rectangle"},hI(i.props,d,h),{key:"rectangle-".concat(d==null?void 0:d.x,"-").concat(d==null?void 0:d.y,"-").concat(d==null?void 0:d.value,"-").concat(h)}),we.createElement(kge,b))})}},{key:"renderRectanglesWithAnimation",value:function(){var r=this,i=this.props,o=i.data,s=i.layout,a=i.isAnimationActive,l=i.animationBegin,u=i.animationDuration,c=i.animationEasing,d=i.animationId,h=this.state.prevData;return we.createElement(Pd,{begin:l,duration:u,isActive:a,easing:c,from:{t:0},to:{t:1},key:"bar-".concat(d),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(m){var g=m.t,b=o.map(function(v,w){var S=h&&h[w];if(S){var C=is(S.x,v.x),E=is(S.y,v.y),T=is(S.width,v.width),O=is(S.height,v.height);return Ki(Ki({},v),{},{x:C(g),y:E(g),width:T(g),height:O(g)})}if(s==="horizontal"){var M=is(0,v.height),N=M(g);return Ki(Ki({},v),{},{y:v.y+v.height-N,height:N})}var I=is(0,v.width),D=I(g);return Ki(Ki({},v),{},{width:D})});return we.createElement(Yr,null,r.renderRectanglesStatically(b))})}},{key:"renderRectangles",value:function(){var r=this.props,i=r.data,o=r.isAnimationActive,s=this.state.prevData;return o&&i&&i.length&&(!s||!fw(s,i))?this.renderRectanglesWithAnimation():this.renderRectanglesStatically(i)}},{key:"renderBackground",value:function(){var r=this,i=this.props,o=i.data,s=i.dataKey,a=i.activeIndex,l=wn(this.props.background,!1);return o.map(function(u,c){u.value;var d=u.background,h=V6t(u,U6t);if(!d)return null;var m=Ki(Ki(Ki(Ki(Ki({},h),{},{fill:"#eee"},d),l),hI(r.props,u,c)),{},{onAnimationStart:r.handleAnimationStart,onAnimationEnd:r.handleAnimationEnd,dataKey:s,index:c,className:"recharts-bar-background-rectangle"});return we.createElement(kge,jI({key:"background-bar-".concat(c),option:r.props.background,isActive:c===a},m))})}},{key:"renderErrorBar",value:function(r,i){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var o=this.props,s=o.data,a=o.xAxis,l=o.yAxis,u=o.layout,c=o.children,d=lu(c,EA);if(!d)return null;var h=u==="vertical"?s[0].height/2:s[0].width/2,m=function(v,w){var S=Array.isArray(v.value)?v.value[1]:v.value;return{x:v.x,y:v.y,value:S,errorVal:na(v,w)}},g={clipPath:r?"url(#clipPath-".concat(i,")"):null};return we.createElement(Yr,g,d.map(function(b){return we.cloneElement(b,{key:"error-bar-".concat(i,"-").concat(b.props.dataKey),data:s,xAxis:a,yAxis:l,layout:u,offset:h,dataPointFormatter:m})}))}},{key:"render",value:function(){var r=this.props,i=r.hide,o=r.data,s=r.className,a=r.xAxis,l=r.yAxis,u=r.left,c=r.top,d=r.width,h=r.height,m=r.isAnimationActive,g=r.background,b=r.id;if(i||!o||!o.length)return null;var v=this.state.isAnimationFinished,w=Hn("recharts-bar",s),S=a&&a.allowDataOverflow,C=l&&l.allowDataOverflow,E=S||C,T=Rn(b)?this.id:b;return we.createElement(Yr,{className:w},S||C?we.createElement("defs",null,we.createElement("clipPath",{id:"clipPath-".concat(T)},we.createElement("rect",{x:S?u:u-d/2,y:C?c:c-h/2,width:S?d:d*2,height:C?h:h*2}))):null,we.createElement(Yr,{className:"recharts-bar-rectangles",clipPath:E?"url(#clipPath-".concat(T,")"):null},g?this.renderBackground():null,this.renderRectangles()),this.renderErrorBar(E,T),(!m||v)&&_h.renderCallByParent(this.props,o))}}],[{key:"getDerivedStateFromProps",value:function(r,i){return r.animationId!==i.prevAnimationId?{prevAnimationId:r.animationId,curData:r.data,prevData:i.curData}:r.data!==i.curData?{curData:r.data}:null}}])})(A.PureComponent);xIe=Bb;Qm(Bb,"displayName","Bar");Qm(Bb,"defaultProps",{xAxisId:0,yAxisId:0,legendType:"rect",minPointSize:0,hide:!1,data:[],layout:"vertical",activeBar:!1,isAnimationActive:!Fb.isSsr,animationBegin:0,animationDuration:400,animationEasing:"ease"});Qm(Bb,"getComposedData",function(e){var t=e.props,n=e.item,r=e.barPosition,i=e.bandSize,o=e.xAxis,s=e.yAxis,a=e.xAxisTicks,l=e.yAxisTicks,u=e.stackedData,c=e.dataStartIndex,d=e.displayedData,h=e.offset,m=Zjt(r,n);if(!m)return null;var g=t.layout,b=n.type.defaultProps,v=b!==void 0?Ki(Ki({},b),n.props):n.props,w=v.dataKey,S=v.children,C=v.minPointSize,E=g==="horizontal"?s:o,T=u?E.scale.domain():null,O=sDt({numericAxis:E}),M=lu(S,NLe),N=d.map(function(I,D){var P,F,z,$,B,H;u?P=Jjt(u[c+D],T):(P=na(I,w),Array.isArray(P)||(P=[O,P]));var U=H6t(C,xIe.defaultProps.minPointSize)(P[1],D);if(g==="horizontal"){var W,q=[s.scale(P[0]),s.scale(P[1])],Y=q[0],Q=q[1];F=gme({axis:o,ticks:a,bandSize:i,offset:m.offset,entry:I,index:D}),z=(W=Q??Y)!==null&&W!==void 0?W:void 0,$=m.size;var G=Y-Q;if(B=Number.isNaN(G)?0:G,H={x:F,y:s.y,width:$,height:s.height},Math.abs(U)>0&&Math.abs(B)<Math.abs(U)){var le=Xu(B||U)*(Math.abs(U)-Math.abs(B));z-=le,B+=le}}else{var K=[o.scale(P[0]),o.scale(P[1])],te=K[0],de=K[1];if(F=te,z=gme({axis:s,ticks:l,bandSize:i,offset:m.offset,entry:I,index:D}),$=de-te,B=m.size,H={x:o.x,y:z,width:o.width,height:B},Math.abs(U)>0&&Math.abs($)<Math.abs(U)){var ue=Xu($||U)*(Math.abs(U)-Math.abs($));$+=ue}}return Ki(Ki(Ki({},I),{},{x:F,y:z,width:$,height:B,value:u?P:P[1],payload:I,background:H},M&&M[D]&&M[D].props),{},{tooltipPayload:[oIe(n,I)],tooltipPosition:{x:F+$/2,y:z+B/2}})});return Ki({data:N,layout:g},h)});function NT(e){"@babel/helpers - typeof";return NT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},NT(e)}function J6t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Tge(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,kIe(r.key),r)}}function e4t(e,t,n){return t&&Tge(e.prototype,t),n&&Tge(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Age(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 $u(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Age(Object(n),!0).forEach(function(r){RD(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Age(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function RD(e,t,n){return t=kIe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function kIe(e){var t=t4t(e,"string");return NT(t)=="symbol"?t:t+""}function t4t(e,t){if(NT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(NT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var hQ=function(t,n,r,i,o){var s=t.width,a=t.height,l=t.layout,u=t.children,c=Object.keys(n),d={left:r.left,leftMirror:r.left,right:s-r.right,rightMirror:s-r.right,top:r.top,topMirror:r.top,bottom:a-r.bottom,bottomMirror:a-r.bottom},h=!!tl(u,Bb);return c.reduce(function(m,g){var b=n[g],v=b.orientation,w=b.domain,S=b.padding,C=S===void 0?{}:S,E=b.mirror,T=b.reversed,O="".concat(v).concat(E?"Mirror":""),M,N,I,D,P;if(b.type==="number"&&(b.padding==="gap"||b.padding==="no-gap")){var F=w[1]-w[0],z=1/0,$=b.categoricalDomain.sort(q_t);if($.forEach(function(K,te){te>0&&(z=Math.min((K||0)-($[te-1]||0),z))}),Number.isFinite(z)){var B=z/F,H=b.layout==="vertical"?r.height:r.width;if(b.padding==="gap"&&(M=B*H/2),b.padding==="no-gap"){var U=xb(t.barCategoryGap,B*H),W=B*H/2;M=W-U-(W-U)/H*U}}}i==="xAxis"?N=[r.left+(C.left||0)+(M||0),r.left+r.width-(C.right||0)-(M||0)]:i==="yAxis"?N=l==="horizontal"?[r.top+r.height-(C.bottom||0),r.top+(C.top||0)]:[r.top+(C.top||0)+(M||0),r.top+r.height-(C.bottom||0)-(M||0)]:N=b.range,T&&(N=[N[1],N[0]]);var q=Xjt(b,o,h),Y=q.scale,Q=q.realScaleType;Y.domain(w).range(N),Qjt(Y);var G=oDt(Y,$u($u({},b),{},{realScaleType:Q}));i==="xAxis"?(P=v==="top"&&!E||v==="bottom"&&E,I=r.left,D=d[O]-P*b.height):i==="yAxis"&&(P=v==="left"&&!E||v==="right"&&E,I=d[O]-P*b.width,D=r.top);var le=$u($u($u({},b),G),{},{realScaleType:Q,x:I,y:D,scale:Y,width:i==="xAxis"?r.width:b.width,height:i==="yAxis"?r.height:b.height});return le.bandSize=CI(le,G),!b.hide&&i==="xAxis"?d[O]+=(P?-1:1)*le.height:b.hide||(d[O]+=(P?-1:1)*le.width),$u($u({},m),{},RD({},g,le))},{})},CIe=function(t,n){var r=t.x,i=t.y,o=n.x,s=n.y;return{x:Math.min(r,o),y:Math.min(i,s),width:Math.abs(o-r),height:Math.abs(s-i)}},n4t=function(t){var n=t.x1,r=t.y1,i=t.x2,o=t.y2;return CIe({x:n,y:r},{x:i,y:o})},EIe=(function(){function e(t){J6t(this,e),this.scale=t}return e4t(e,[{key:"domain",get:function(){return this.scale.domain}},{key:"range",get:function(){return this.scale.range}},{key:"rangeMin",get:function(){return this.range()[0]}},{key:"rangeMax",get:function(){return this.range()[1]}},{key:"bandwidth",get:function(){return this.scale.bandwidth}},{key:"apply",value:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.bandAware,o=r.position;if(n!==void 0){if(o)switch(o){case"start":return this.scale(n);case"middle":{var s=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+s}case"end":{var a=this.bandwidth?this.bandwidth():0;return this.scale(n)+a}default:return this.scale(n)}if(i){var l=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+l}return this.scale(n)}}},{key:"isInRange",value:function(n){var r=this.range(),i=r[0],o=r[r.length-1];return i<=o?n>=i&&n<=o:n>=o&&n<=i}}],[{key:"create",value:function(n){return new e(n)}}])})();RD(EIe,"EPS",1e-4);var pQ=function(t){var n=Object.keys(t).reduce(function(r,i){return $u($u({},r),{},RD({},i,EIe.create(t[i])))},{});return $u($u({},n),{},{apply:function(i){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s=o.bandAware,a=o.position;return M6t(i,function(l,u){return n[u].apply(l,{bandAware:s,position:a})})},isInRange:function(i){return vIe(i,function(o,s){return n[s].isInRange(o)})}})};function r4t(e){return(e%180+180)%180}var i4t=function(t){var n=t.width,r=t.height,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,o=r4t(i),s=o*Math.PI/180,a=Math.atan(r/n),l=s>a&&s<Math.PI-a?r/Math.sin(s):n/Math.cos(s);return Math.abs(l)},$B,Oge;function o4t(){if(Oge)return $B;Oge=1;var e=Wg(),t=CA(),n=xD();function r(i){return function(o,s,a){var l=Object(o);if(!t(o)){var u=e(s,3);o=n(o),s=function(d){return u(l[d],d,l)}}var c=i(o,s,a);return c>-1?l[u?o[c]:c]:void 0}}return $B=r,$B}var zB,Rge;function s4t(){if(Rge)return zB;Rge=1;var e=mIe();function t(n){var r=e(n),i=r%1;return r===r?i?r-i:r:0}return zB=t,zB}var FB,Mge;function a4t(){if(Mge)return FB;Mge=1;var e=vLe(),t=Wg(),n=s4t(),r=Math.max;function i(o,s,a){var l=o==null?0:o.length;if(!l)return-1;var u=a==null?0:n(a);return u<0&&(u=r(l+u,0)),e(o,t(s,3),u)}return FB=i,FB}var BB,_ge;function l4t(){if(_ge)return BB;_ge=1;var e=o4t(),t=a4t(),n=e(t);return BB=n,BB}var u4t=l4t();const c4t=cr(u4t);var d4t=XNe();const f4t=cr(d4t);var h4t=f4t(function(e){return{x:e.left,y:e.top,width:e.width,height:e.height}},function(e){return["l",e.left,"t",e.top,"w",e.width,"h",e.height].join("")}),mQ=A.createContext(void 0),gQ=A.createContext(void 0),TIe=A.createContext(void 0),AIe=A.createContext({}),OIe=A.createContext(void 0),RIe=A.createContext(0),MIe=A.createContext(0),Nge=function(t){var n=t.state,r=n.xAxisMap,i=n.yAxisMap,o=n.offset,s=t.clipPathId,a=t.children,l=t.width,u=t.height,c=h4t(o);return we.createElement(mQ.Provider,{value:r},we.createElement(gQ.Provider,{value:i},we.createElement(AIe.Provider,{value:o},we.createElement(TIe.Provider,{value:c},we.createElement(OIe.Provider,{value:s},we.createElement(RIe.Provider,{value:u},we.createElement(MIe.Provider,{value:l},a)))))))},p4t=function(){return A.useContext(OIe)},_Ie=function(t){var n=A.useContext(mQ);n==null&&Sb();var r=n[t];return r==null&&Sb(),r},m4t=function(){var t=A.useContext(mQ);return cm(t)},g4t=function(){var t=A.useContext(gQ),n=c4t(t,function(r){return vIe(r.domain,Number.isFinite)});return n||cm(t)},NIe=function(t){var n=A.useContext(gQ);n==null&&Sb();var r=n[t];return r==null&&Sb(),r},y4t=function(){var t=A.useContext(TIe);return t},b4t=function(){return A.useContext(AIe)},yQ=function(){return A.useContext(MIe)},bQ=function(){return A.useContext(RIe)};function bw(e){"@babel/helpers - typeof";return bw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},bw(e)}function v4t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function x4t(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,IIe(r.key),r)}}function w4t(e,t,n){return t&&x4t(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function S4t(e,t,n){return t=$I(t),k4t(e,LIe()?Reflect.construct(t,n||[],$I(e).constructor):t.apply(e,n))}function k4t(e,t){if(t&&(bw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return C4t(e)}function C4t(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function LIe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(LIe=function(){return!!e})()}function $I(e){return $I=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},$I(e)}function E4t(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&AW(e,t)}function AW(e,t){return AW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},AW(e,t)}function Lge(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 Ige(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Lge(Object(n),!0).forEach(function(r){vQ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Lge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function vQ(e,t,n){return t=IIe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function IIe(e){var t=T4t(e,"string");return bw(t)=="symbol"?t:t+""}function T4t(e,t){if(bw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(bw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function A4t(e,t){return _4t(e)||M4t(e,t)||R4t(e,t)||O4t()}function O4t(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2906
+ A `).concat(g,",").concat(g,",0,0,").concat(u,",").concat(t,",").concat(n+i-a*g," Z")}else c="M ".concat(t,",").concat(n," h ").concat(r," v ").concat(i," h ").concat(-r," Z");return c},g5t=function(t,n){if(!t||!n)return!1;var r=t.x,i=t.y,o=n.x,s=n.y,a=n.width,l=n.height;if(Math.abs(a)>0&&Math.abs(l)>0){var u=Math.min(o,o+a),c=Math.max(o,o+a),d=Math.min(s,s+l),h=Math.max(s,s+l);return r>=u&&r<=c&&i>=d&&i<=h}return!1},y5t={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},fQ=function(t){var n=Kme(Kme({},y5t),t),r=A.useRef(),i=A.useState(-1),o=l5t(i,2),s=o[0],a=o[1];A.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var E=r.current.getTotalLength();E&&a(E)}catch{}},[]);var l=n.x,u=n.y,c=n.width,d=n.height,h=n.radius,m=n.className,g=n.animationEasing,b=n.animationDuration,v=n.animationBegin,w=n.isAnimationActive,S=n.isUpdateAnimationActive;if(l!==+l||u!==+u||c!==+c||d!==+d||c===0||d===0)return null;var C=Hn("recharts-rectangle",m);return S?we.createElement(Pd,{canBegin:s>0,from:{width:c,height:d,x:l,y:u},to:{width:c,height:d,x:l,y:u},duration:b,animationEasing:g,isActive:S},function(E){var T=E.width,O=E.height,M=E.x,N=E.y;return we.createElement(Pd,{canBegin:s>0,from:"0px ".concat(s===-1?1:s,"px"),to:"".concat(s,"px 0px"),attributeName:"strokeDasharray",begin:v,duration:b,isActive:w,easing:g},we.createElement("path",MI({},wn(n,!0),{className:C,d:Yme(M,N,T,O,h),ref:r})))}):we.createElement("path",MI({},wn(n,!0),{className:C,d:Yme(l,u,c,d,h)}))};function SW(){return SW=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},SW.apply(this,arguments)}var TD=function(t){var n=t.cx,r=t.cy,i=t.r,o=t.className,s=Hn("recharts-dot",o);return n===+n&&r===+r&&i===+i?A.createElement("circle",SW({},wn(t,!1),fI(t),{className:s,cx:n,cy:r,r:i})):null};function TT(e){"@babel/helpers - typeof";return TT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},TT(e)}var b5t=["x","y","top","left","width","height","className"];function kW(){return kW=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},kW.apply(this,arguments)}function Xme(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 v5t(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Xme(Object(n),!0).forEach(function(r){x5t(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Xme(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function x5t(e,t,n){return t=w5t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function w5t(e){var t=S5t(e,"string");return TT(t)=="symbol"?t:t+""}function S5t(e,t){if(TT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(TT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function k5t(e,t){if(e==null)return{};var n=C5t(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function C5t(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var E5t=function(t,n,r,i,o,s){return"M".concat(t,",").concat(o,"v").concat(i,"M").concat(s,",").concat(n,"h").concat(r)},T5t=function(t){var n=t.x,r=n===void 0?0:n,i=t.y,o=i===void 0?0:i,s=t.top,a=s===void 0?0:s,l=t.left,u=l===void 0?0:l,c=t.width,d=c===void 0?0:c,h=t.height,m=h===void 0?0:h,g=t.className,b=k5t(t,b5t),v=v5t({x:r,y:o,top:a,left:u,width:d,height:m},b);return!ft(r)||!ft(o)||!ft(d)||!ft(m)||!ft(a)||!ft(u)?null:we.createElement("path",kW({},wn(v,!0),{className:Hn("recharts-cross",g),d:E5t(r,o,d,m,a,u)}))},kB,Qme;function A5t(){if(Qme)return kB;Qme=1;var e=mLe(),t=e(Object.getPrototypeOf,Object);return kB=t,kB}var CB,Zme;function O5t(){if(Zme)return CB;Zme=1;var e=Zh(),t=A5t(),n=Jh(),r="[object Object]",i=Function.prototype,o=Object.prototype,s=i.toString,a=o.hasOwnProperty,l=s.call(Object);function u(c){if(!n(c)||e(c)!=r)return!1;var d=t(c);if(d===null)return!0;var h=a.call(d,"constructor")&&d.constructor;return typeof h=="function"&&h instanceof h&&s.call(h)==l}return CB=u,CB}var R5t=O5t();const M5t=cr(R5t);var EB,Jme;function _5t(){if(Jme)return EB;Jme=1;var e=Zh(),t=Jh(),n="[object Boolean]";function r(i){return i===!0||i===!1||t(i)&&e(i)==n}return EB=r,EB}var N5t=_5t();const L5t=cr(N5t);function AT(e){"@babel/helpers - typeof";return AT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},AT(e)}function _I(){return _I=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},_I.apply(this,arguments)}function I5t(e,t){return $5t(e)||D5t(e,t)||j5t(e,t)||P5t()}function P5t(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2907
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function j5t(e,t){if(e){if(typeof e=="string")return ege(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ege(e,t)}}function ege(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function D5t(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,s,a=[],l=!0,u=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(l=(r=o.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(c){u=!0,i=c}finally{try{if(!l&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw i}}return a}}function $5t(e){if(Array.isArray(e))return e}function tge(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 nge(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?tge(Object(n),!0).forEach(function(r){z5t(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function z5t(e,t,n){return t=F5t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function F5t(e){var t=B5t(e,"string");return AT(t)=="symbol"?t:t+""}function B5t(e,t){if(AT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(AT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var rge=function(t,n,r,i,o){var s=r-i,a;return a="M ".concat(t,",").concat(n),a+="L ".concat(t+r,",").concat(n),a+="L ".concat(t+r-s/2,",").concat(n+o),a+="L ".concat(t+r-s/2-i,",").concat(n+o),a+="L ".concat(t,",").concat(n," Z"),a},H5t={x:0,y:0,upperWidth:0,lowerWidth:0,height:0,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},U5t=function(t){var n=nge(nge({},H5t),t),r=A.useRef(),i=A.useState(-1),o=I5t(i,2),s=o[0],a=o[1];A.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var C=r.current.getTotalLength();C&&a(C)}catch{}},[]);var l=n.x,u=n.y,c=n.upperWidth,d=n.lowerWidth,h=n.height,m=n.className,g=n.animationEasing,b=n.animationDuration,v=n.animationBegin,w=n.isUpdateAnimationActive;if(l!==+l||u!==+u||c!==+c||d!==+d||h!==+h||c===0&&d===0||h===0)return null;var S=Hn("recharts-trapezoid",m);return w?we.createElement(Pd,{canBegin:s>0,from:{upperWidth:0,lowerWidth:0,height:h,x:l,y:u},to:{upperWidth:c,lowerWidth:d,height:h,x:l,y:u},duration:b,animationEasing:g,isActive:w},function(C){var E=C.upperWidth,T=C.lowerWidth,O=C.height,M=C.x,N=C.y;return we.createElement(Pd,{canBegin:s>0,from:"0px ".concat(s===-1?1:s,"px"),to:"".concat(s,"px 0px"),attributeName:"strokeDasharray",begin:v,duration:b,easing:g},we.createElement("path",_I({},wn(n,!0),{className:S,d:rge(M,N,E,T,O),ref:r})))}):we.createElement("g",null,we.createElement("path",_I({},wn(n,!0),{className:S,d:rge(l,u,c,d,h)})))},V5t=["option","shapeType","propTransformer","activeClassName","isActive"];function OT(e){"@babel/helpers - typeof";return OT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},OT(e)}function W5t(e,t){if(e==null)return{};var n=q5t(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function q5t(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function ige(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 NI(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ige(Object(n),!0).forEach(function(r){G5t(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ige(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function G5t(e,t,n){return t=K5t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function K5t(e){var t=Y5t(e,"string");return OT(t)=="symbol"?t:t+""}function Y5t(e,t){if(OT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(OT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function X5t(e,t){return NI(NI({},t),e)}function Q5t(e,t){return e==="symbols"}function oge(e){var t=e.shapeType,n=e.elementProps;switch(t){case"rectangle":return we.createElement(fQ,n);case"trapezoid":return we.createElement(U5t,n);case"sector":return we.createElement(lIe,n);case"symbols":if(Q5t(t))return we.createElement(JX,n);break;default:return null}}function Z5t(e){return A.isValidElement(e)?e.props:e}function J5t(e){var t=e.option,n=e.shapeType,r=e.propTransformer,i=r===void 0?X5t:r,o=e.activeClassName,s=o===void 0?"recharts-active-shape":o,a=e.isActive,l=W5t(e,V5t),u;if(A.isValidElement(t))u=A.cloneElement(t,NI(NI({},l),Z5t(t)));else if(yn(t))u=t(l);else if(M5t(t)&&!L5t(t)){var c=i(t,l);u=we.createElement(oge,{shapeType:n,elementProps:c})}else{var d=l;u=we.createElement(oge,{shapeType:n,elementProps:d})}return a?we.createElement(Yr,{className:s},u):u}function AD(e,t){return t!=null&&"trapezoids"in e.props}function OD(e,t){return t!=null&&"sectors"in e.props}function RT(e,t){return t!=null&&"points"in e.props}function e6t(e,t){var n,r,i=e.x===(t==null||(n=t.labelViewBox)===null||n===void 0?void 0:n.x)||e.x===t.x,o=e.y===(t==null||(r=t.labelViewBox)===null||r===void 0?void 0:r.y)||e.y===t.y;return i&&o}function t6t(e,t){var n=e.endAngle===t.endAngle,r=e.startAngle===t.startAngle;return n&&r}function n6t(e,t){var n=e.x===t.x,r=e.y===t.y,i=e.z===t.z;return n&&r&&i}function r6t(e,t){var n;return AD(e,t)?n=e6t:OD(e,t)?n=t6t:RT(e,t)&&(n=n6t),n}function i6t(e,t){var n;return AD(e,t)?n="trapezoids":OD(e,t)?n="sectors":RT(e,t)&&(n="points"),n}function o6t(e,t){if(AD(e,t)){var n;return(n=t.tooltipPayload)===null||n===void 0||(n=n[0])===null||n===void 0||(n=n.payload)===null||n===void 0?void 0:n.payload}if(OD(e,t)){var r;return(r=t.tooltipPayload)===null||r===void 0||(r=r[0])===null||r===void 0||(r=r.payload)===null||r===void 0?void 0:r.payload}return RT(e,t)?t.payload:{}}function s6t(e){var t=e.activeTooltipItem,n=e.graphicalItem,r=e.itemData,i=i6t(n,t),o=o6t(n,t),s=r.filter(function(l,u){var c=fw(o,l),d=n.props[i].filter(function(g){var b=r6t(n,t);return b(g,t)}),h=n.props[i].indexOf(d[d.length-1]),m=u===h;return c&&m}),a=r.indexOf(s[s.length-1]);return a}var TB,sge;function a6t(){if(sge)return TB;sge=1;var e=Math.ceil,t=Math.max;function n(r,i,o,s){for(var a=-1,l=t(e((i-r)/(o||1)),0),u=Array(l);l--;)u[s?l:++a]=r,r+=o;return u}return TB=n,TB}var AB,age;function mIe(){if(age)return AB;age=1;var e=KOe(),t=1/0,n=17976931348623157e292;function r(i){if(!i)return i===0?i:0;if(i=e(i),i===t||i===-t){var o=i<0?-1:1;return o*n}return i===i?i:0}return AB=r,AB}var OB,lge;function l6t(){if(lge)return OB;lge=1;var e=a6t(),t=SD(),n=mIe();function r(i){return function(o,s,a){return a&&typeof a!="number"&&t(o,s,a)&&(s=a=void 0),o=n(o),s===void 0?(s=o,o=0):s=n(s),a=a===void 0?o<s?1:-1:n(a),e(o,s,a,i)}}return OB=r,OB}var RB,uge;function u6t(){if(uge)return RB;uge=1;var e=l6t(),t=e();return RB=t,RB}var c6t=u6t();const LI=cr(c6t);function MT(e){"@babel/helpers - typeof";return MT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},MT(e)}function cge(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 dge(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?cge(Object(n),!0).forEach(function(r){gIe(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):cge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function gIe(e,t,n){return t=d6t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function d6t(e){var t=f6t(e,"string");return MT(t)=="symbol"?t:t+""}function f6t(e,t){if(MT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(MT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var h6t=["Webkit","Moz","O","ms"],p6t=function(t,n){var r=t.replace(/(\w)/,function(o){return o.toUpperCase()}),i=h6t.reduce(function(o,s){return dge(dge({},o),{},gIe({},s+r,n))},{});return i[t]=n,i};function mw(e){"@babel/helpers - typeof";return mw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},mw(e)}function II(){return II=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},II.apply(this,arguments)}function fge(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 MB(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?fge(Object(n),!0).forEach(function(r){Ya(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function m6t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function hge(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,bIe(r.key),r)}}function g6t(e,t,n){return t&&hge(e.prototype,t),n&&hge(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function y6t(e,t,n){return t=PI(t),b6t(e,yIe()?Reflect.construct(t,n||[],PI(e).constructor):t.apply(e,n))}function b6t(e,t){if(t&&(mw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return v6t(e)}function v6t(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function yIe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(yIe=function(){return!!e})()}function PI(e){return PI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},PI(e)}function x6t(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&CW(e,t)}function CW(e,t){return CW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},CW(e,t)}function Ya(e,t,n){return t=bIe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function bIe(e){var t=w6t(e,"string");return mw(t)=="symbol"?t:t+""}function w6t(e,t){if(mw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(mw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var S6t=function(t){var n=t.data,r=t.startIndex,i=t.endIndex,o=t.x,s=t.width,a=t.travellerWidth;if(!n||!n.length)return{};var l=n.length,u=GC().domain(LI(0,l)).range([o,o+s-a]),c=u.domain().map(function(d){return u(d)});return{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,isTravellerFocused:!1,startX:u(r),endX:u(i),scale:u,scaleValues:c}},pge=function(t){return t.changedTouches&&!!t.changedTouches.length},gw=(function(e){function t(n){var r;return m6t(this,t),r=y6t(this,t,[n]),Ya(r,"handleDrag",function(i){r.leaveTimer&&(clearTimeout(r.leaveTimer),r.leaveTimer=null),r.state.isTravellerMoving?r.handleTravellerMove(i):r.state.isSlideMoving&&r.handleSlideDrag(i)}),Ya(r,"handleTouchMove",function(i){i.changedTouches!=null&&i.changedTouches.length>0&&r.handleDrag(i.changedTouches[0])}),Ya(r,"handleDragEnd",function(){r.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var i=r.props,o=i.endIndex,s=i.onDragEnd,a=i.startIndex;s==null||s({endIndex:o,startIndex:a})}),r.detachDragEndListener()}),Ya(r,"handleLeaveWrapper",function(){(r.state.isTravellerMoving||r.state.isSlideMoving)&&(r.leaveTimer=window.setTimeout(r.handleDragEnd,r.props.leaveTimeOut))}),Ya(r,"handleEnterSlideOrTraveller",function(){r.setState({isTextActive:!0})}),Ya(r,"handleLeaveSlideOrTraveller",function(){r.setState({isTextActive:!1})}),Ya(r,"handleSlideDragStart",function(i){var o=pge(i)?i.changedTouches[0]:i;r.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:o.pageX}),r.attachDragEndListener()}),r.travellerDragStartHandlers={startX:r.handleTravellerDragStart.bind(r,"startX"),endX:r.handleTravellerDragStart.bind(r,"endX")},r.state={},r}return x6t(t,e),g6t(t,[{key:"componentWillUnmount",value:function(){this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null),this.detachDragEndListener()}},{key:"getIndex",value:function(r){var i=r.startX,o=r.endX,s=this.state.scaleValues,a=this.props,l=a.gap,u=a.data,c=u.length-1,d=Math.min(i,o),h=Math.max(i,o),m=t.getIndexInRange(s,d),g=t.getIndexInRange(s,h);return{startIndex:m-m%l,endIndex:g===c?c:g-g%l}}},{key:"getTextOfTick",value:function(r){var i=this.props,o=i.data,s=i.tickFormatter,a=i.dataKey,l=na(o[r],a,r);return yn(s)?s(l,r):l}},{key:"attachDragEndListener",value:function(){window.addEventListener("mouseup",this.handleDragEnd,!0),window.addEventListener("touchend",this.handleDragEnd,!0),window.addEventListener("mousemove",this.handleDrag,!0)}},{key:"detachDragEndListener",value:function(){window.removeEventListener("mouseup",this.handleDragEnd,!0),window.removeEventListener("touchend",this.handleDragEnd,!0),window.removeEventListener("mousemove",this.handleDrag,!0)}},{key:"handleSlideDrag",value:function(r){var i=this.state,o=i.slideMoveStartX,s=i.startX,a=i.endX,l=this.props,u=l.x,c=l.width,d=l.travellerWidth,h=l.startIndex,m=l.endIndex,g=l.onChange,b=r.pageX-o;b>0?b=Math.min(b,u+c-d-a,u+c-d-s):b<0&&(b=Math.max(b,u-s,u-a));var v=this.getIndex({startX:s+b,endX:a+b});(v.startIndex!==h||v.endIndex!==m)&&g&&g(v),this.setState({startX:s+b,endX:a+b,slideMoveStartX:r.pageX})}},{key:"handleTravellerDragStart",value:function(r,i){var o=pge(i)?i.changedTouches[0]:i;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:r,brushMoveStartX:o.pageX}),this.attachDragEndListener()}},{key:"handleTravellerMove",value:function(r){var i=this.state,o=i.brushMoveStartX,s=i.movingTravellerId,a=i.endX,l=i.startX,u=this.state[s],c=this.props,d=c.x,h=c.width,m=c.travellerWidth,g=c.onChange,b=c.gap,v=c.data,w={startX:this.state.startX,endX:this.state.endX},S=r.pageX-o;S>0?S=Math.min(S,d+h-m-u):S<0&&(S=Math.max(S,d-u)),w[s]=u+S;var C=this.getIndex(w),E=C.startIndex,T=C.endIndex,O=function(){var N=v.length-1;return s==="startX"&&(a>l?E%b===0:T%b===0)||a<l&&T===N||s==="endX"&&(a>l?T%b===0:E%b===0)||a>l&&T===N};this.setState(Ya(Ya({},s,u+S),"brushMoveStartX",r.pageX),function(){g&&O()&&g(C)})}},{key:"handleTravellerMoveKeyboard",value:function(r,i){var o=this,s=this.state,a=s.scaleValues,l=s.startX,u=s.endX,c=this.state[i],d=a.indexOf(c);if(d!==-1){var h=d+r;if(!(h===-1||h>=a.length)){var m=a[h];i==="startX"&&m>=u||i==="endX"&&m<=l||this.setState(Ya({},i,m),function(){o.props.onChange(o.getIndex({startX:o.state.startX,endX:o.state.endX}))})}}}},{key:"renderBackground",value:function(){var r=this.props,i=r.x,o=r.y,s=r.width,a=r.height,l=r.fill,u=r.stroke;return we.createElement("rect",{stroke:u,fill:l,x:i,y:o,width:s,height:a})}},{key:"renderPanorama",value:function(){var r=this.props,i=r.x,o=r.y,s=r.width,a=r.height,l=r.data,u=r.children,c=r.padding,d=A.Children.only(u);return d?we.cloneElement(d,{x:i,y:o,width:s,height:a,margin:c,compact:!0,data:l}):null}},{key:"renderTravellerLayer",value:function(r,i){var o,s,a=this,l=this.props,u=l.y,c=l.travellerWidth,d=l.height,h=l.traveller,m=l.ariaLabel,g=l.data,b=l.startIndex,v=l.endIndex,w=Math.max(r,this.props.x),S=MB(MB({},wn(this.props,!1)),{},{x:w,y:u,width:c,height:d}),C=m||"Min value: ".concat((o=g[b])===null||o===void 0?void 0:o.name,", Max value: ").concat((s=g[v])===null||s===void 0?void 0:s.name);return we.createElement(Yr,{tabIndex:0,role:"slider","aria-label":C,"aria-valuenow":r,className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[i],onTouchStart:this.travellerDragStartHandlers[i],onKeyDown:function(T){["ArrowLeft","ArrowRight"].includes(T.key)&&(T.preventDefault(),T.stopPropagation(),a.handleTravellerMoveKeyboard(T.key==="ArrowRight"?1:-1,i))},onFocus:function(){a.setState({isTravellerFocused:!0})},onBlur:function(){a.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},t.renderTraveller(h,S))}},{key:"renderSlide",value:function(r,i){var o=this.props,s=o.y,a=o.height,l=o.stroke,u=o.travellerWidth,c=Math.min(r,i)+u,d=Math.max(Math.abs(i-r)-u,0);return we.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:l,fillOpacity:.2,x:c,y:s,width:d,height:a})}},{key:"renderText",value:function(){var r=this.props,i=r.startIndex,o=r.endIndex,s=r.y,a=r.height,l=r.travellerWidth,u=r.stroke,c=this.state,d=c.startX,h=c.endX,m=5,g={pointerEvents:"none",fill:u};return we.createElement(Yr,{className:"recharts-brush-texts"},we.createElement(vI,II({textAnchor:"end",verticalAnchor:"middle",x:Math.min(d,h)-m,y:s+a/2},g),this.getTextOfTick(i)),we.createElement(vI,II({textAnchor:"start",verticalAnchor:"middle",x:Math.max(d,h)+l+m,y:s+a/2},g),this.getTextOfTick(o)))}},{key:"render",value:function(){var r=this.props,i=r.data,o=r.className,s=r.children,a=r.x,l=r.y,u=r.width,c=r.height,d=r.alwaysShowText,h=this.state,m=h.startX,g=h.endX,b=h.isTextActive,v=h.isSlideMoving,w=h.isTravellerMoving,S=h.isTravellerFocused;if(!i||!i.length||!ft(a)||!ft(l)||!ft(u)||!ft(c)||u<=0||c<=0)return null;var C=Hn("recharts-brush",o),E=we.Children.count(s)===1,T=p6t("userSelect","none");return we.createElement(Yr,{className:C,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:T},this.renderBackground(),E&&this.renderPanorama(),this.renderSlide(m,g),this.renderTravellerLayer(m,"startX"),this.renderTravellerLayer(g,"endX"),(b||v||w||S||d)&&this.renderText())}}],[{key:"renderDefaultTraveller",value:function(r){var i=r.x,o=r.y,s=r.width,a=r.height,l=r.stroke,u=Math.floor(o+a/2)-1;return we.createElement(we.Fragment,null,we.createElement("rect",{x:i,y:o,width:s,height:a,fill:l,stroke:"none"}),we.createElement("line",{x1:i+1,y1:u,x2:i+s-1,y2:u,fill:"none",stroke:"#fff"}),we.createElement("line",{x1:i+1,y1:u+2,x2:i+s-1,y2:u+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(r,i){var o;return we.isValidElement(r)?o=we.cloneElement(r,i):yn(r)?o=r(i):o=t.renderDefaultTraveller(i),o}},{key:"getDerivedStateFromProps",value:function(r,i){var o=r.data,s=r.width,a=r.x,l=r.travellerWidth,u=r.updateId,c=r.startIndex,d=r.endIndex;if(o!==i.prevData||u!==i.prevUpdateId)return MB({prevData:o,prevTravellerWidth:l,prevUpdateId:u,prevX:a,prevWidth:s},o&&o.length?S6t({data:o,width:s,x:a,travellerWidth:l,startIndex:c,endIndex:d}):{scale:null,scaleValues:null});if(i.scale&&(s!==i.prevWidth||a!==i.prevX||l!==i.prevTravellerWidth)){i.scale.range([a,a+s-l]);var h=i.scale.domain().map(function(m){return i.scale(m)});return{prevData:o,prevTravellerWidth:l,prevUpdateId:u,prevX:a,prevWidth:s,startX:i.scale(r.startIndex),endX:i.scale(r.endIndex),scaleValues:h}}return null}},{key:"getIndexInRange",value:function(r,i){for(var o=r.length,s=0,a=o-1;a-s>1;){var l=Math.floor((s+a)/2);r[l]>i?a=l:s=l}return i>=r[a]?a:s}}])})(A.PureComponent);Ya(gw,"displayName","Brush");Ya(gw,"defaultProps",{height:40,travellerWidth:5,gap:1,fill:"#fff",stroke:"#666",padding:{top:1,right:1,bottom:1,left:1},leaveTimeOut:1e3,alwaysShowText:!1});var _B,mge;function k6t(){if(mge)return _B;mge=1;var e=sQ();function t(n,r){var i;return e(n,function(o,s,a){return i=r(o,s,a),!i}),!!i}return _B=t,_B}var NB,gge;function C6t(){if(gge)return NB;gge=1;var e=lLe(),t=Wg(),n=k6t(),r=Na(),i=SD();function o(s,a,l){var u=r(s)?e:n;return l&&i(s,a,l)&&(a=void 0),u(s,t(a,3))}return NB=o,NB}var E6t=C6t();const T6t=cr(E6t);var Ed=function(t,n){var r=t.alwaysShow,i=t.ifOverflow;return r&&(i="extendDomain"),i===n},LB,yge;function A6t(){if(yge)return LB;yge=1;var e=TLe();function t(n,r,i){r=="__proto__"&&e?e(n,r,{configurable:!0,enumerable:!0,value:i,writable:!0}):n[r]=i}return LB=t,LB}var IB,bge;function O6t(){if(bge)return IB;bge=1;var e=A6t(),t=CLe(),n=Wg();function r(i,o){var s={};return o=n(o,3),t(i,function(a,l,u){e(s,l,o(a,l,u))}),s}return IB=r,IB}var R6t=O6t();const M6t=cr(R6t);var PB,vge;function _6t(){if(vge)return PB;vge=1;function e(t,n){for(var r=-1,i=t==null?0:t.length;++r<i;)if(!n(t[r],r,t))return!1;return!0}return PB=e,PB}var jB,xge;function N6t(){if(xge)return jB;xge=1;var e=sQ();function t(n,r){var i=!0;return e(n,function(o,s,a){return i=!!r(o,s,a),i}),i}return jB=t,jB}var DB,wge;function L6t(){if(wge)return DB;wge=1;var e=_6t(),t=N6t(),n=Wg(),r=Na(),i=SD();function o(s,a,l){var u=r(s)?e:t;return l&&i(s,a,l)&&(a=void 0),u(s,n(a,3))}return DB=o,DB}var I6t=L6t();const vIe=cr(I6t);var P6t=["x","y"];function _T(e){"@babel/helpers - typeof";return _T=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_T(e)}function EW(){return EW=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},EW.apply(this,arguments)}function Sge(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 Rk(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Sge(Object(n),!0).forEach(function(r){j6t(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Sge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function j6t(e,t,n){return t=D6t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function D6t(e){var t=$6t(e,"string");return _T(t)=="symbol"?t:t+""}function $6t(e,t){if(_T(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(_T(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function z6t(e,t){if(e==null)return{};var n=F6t(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function F6t(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function B6t(e,t){var n=e.x,r=e.y,i=z6t(e,P6t),o="".concat(n),s=parseInt(o,10),a="".concat(r),l=parseInt(a,10),u="".concat(t.height||i.height),c=parseInt(u,10),d="".concat(t.width||i.width),h=parseInt(d,10);return Rk(Rk(Rk(Rk(Rk({},t),i),s?{x:s}:{}),l?{y:l}:{}),{},{height:c,width:h,name:t.name,radius:t.radius})}function kge(e){return we.createElement(J5t,EW({shapeType:"rectangle",propTransformer:B6t,activeClassName:"recharts-active-bar"},e))}var H6t=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return function(r,i){if(typeof t=="number")return t;var o=ft(r)||U_t(r);return o?t(r,i):(o||Sb(),n)}},U6t=["value","background"],xIe;function yw(e){"@babel/helpers - typeof";return yw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},yw(e)}function V6t(e,t){if(e==null)return{};var n=W6t(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function W6t(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function jI(){return jI=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},jI.apply(this,arguments)}function Cge(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 Ki(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Cge(Object(n),!0).forEach(function(r){Qm(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Cge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function q6t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ege(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,SIe(r.key),r)}}function G6t(e,t,n){return t&&Ege(e.prototype,t),n&&Ege(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function K6t(e,t,n){return t=DI(t),Y6t(e,wIe()?Reflect.construct(t,n||[],DI(e).constructor):t.apply(e,n))}function Y6t(e,t){if(t&&(yw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return X6t(e)}function X6t(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function wIe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(wIe=function(){return!!e})()}function DI(e){return DI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},DI(e)}function Q6t(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&TW(e,t)}function TW(e,t){return TW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},TW(e,t)}function Qm(e,t,n){return t=SIe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function SIe(e){var t=Z6t(e,"string");return yw(t)=="symbol"?t:t+""}function Z6t(e,t){if(yw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(yw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Bb=(function(e){function t(){var n;q6t(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=K6t(this,t,[].concat(i)),Qm(n,"state",{isAnimationFinished:!1}),Qm(n,"id",fS("recharts-bar-")),Qm(n,"handleAnimationEnd",function(){var s=n.props.onAnimationEnd;n.setState({isAnimationFinished:!0}),s&&s()}),Qm(n,"handleAnimationStart",function(){var s=n.props.onAnimationStart;n.setState({isAnimationFinished:!1}),s&&s()}),n}return Q6t(t,e),G6t(t,[{key:"renderRectanglesStatically",value:function(r){var i=this,o=this.props,s=o.shape,a=o.dataKey,l=o.activeIndex,u=o.activeBar,c=wn(this.props,!1);return r&&r.map(function(d,h){var m=h===l,g=m?u:s,b=Ki(Ki(Ki({},c),d),{},{isActive:m,option:g,index:h,dataKey:a,onAnimationStart:i.handleAnimationStart,onAnimationEnd:i.handleAnimationEnd});return we.createElement(Yr,jI({className:"recharts-bar-rectangle"},hI(i.props,d,h),{key:"rectangle-".concat(d==null?void 0:d.x,"-").concat(d==null?void 0:d.y,"-").concat(d==null?void 0:d.value,"-").concat(h)}),we.createElement(kge,b))})}},{key:"renderRectanglesWithAnimation",value:function(){var r=this,i=this.props,o=i.data,s=i.layout,a=i.isAnimationActive,l=i.animationBegin,u=i.animationDuration,c=i.animationEasing,d=i.animationId,h=this.state.prevData;return we.createElement(Pd,{begin:l,duration:u,isActive:a,easing:c,from:{t:0},to:{t:1},key:"bar-".concat(d),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(m){var g=m.t,b=o.map(function(v,w){var S=h&&h[w];if(S){var C=is(S.x,v.x),E=is(S.y,v.y),T=is(S.width,v.width),O=is(S.height,v.height);return Ki(Ki({},v),{},{x:C(g),y:E(g),width:T(g),height:O(g)})}if(s==="horizontal"){var M=is(0,v.height),N=M(g);return Ki(Ki({},v),{},{y:v.y+v.height-N,height:N})}var I=is(0,v.width),D=I(g);return Ki(Ki({},v),{},{width:D})});return we.createElement(Yr,null,r.renderRectanglesStatically(b))})}},{key:"renderRectangles",value:function(){var r=this.props,i=r.data,o=r.isAnimationActive,s=this.state.prevData;return o&&i&&i.length&&(!s||!fw(s,i))?this.renderRectanglesWithAnimation():this.renderRectanglesStatically(i)}},{key:"renderBackground",value:function(){var r=this,i=this.props,o=i.data,s=i.dataKey,a=i.activeIndex,l=wn(this.props.background,!1);return o.map(function(u,c){u.value;var d=u.background,h=V6t(u,U6t);if(!d)return null;var m=Ki(Ki(Ki(Ki(Ki({},h),{},{fill:"#eee"},d),l),hI(r.props,u,c)),{},{onAnimationStart:r.handleAnimationStart,onAnimationEnd:r.handleAnimationEnd,dataKey:s,index:c,className:"recharts-bar-background-rectangle"});return we.createElement(kge,jI({key:"background-bar-".concat(c),option:r.props.background,isActive:c===a},m))})}},{key:"renderErrorBar",value:function(r,i){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var o=this.props,s=o.data,a=o.xAxis,l=o.yAxis,u=o.layout,c=o.children,d=lu(c,EA);if(!d)return null;var h=u==="vertical"?s[0].height/2:s[0].width/2,m=function(v,w){var S=Array.isArray(v.value)?v.value[1]:v.value;return{x:v.x,y:v.y,value:S,errorVal:na(v,w)}},g={clipPath:r?"url(#clipPath-".concat(i,")"):null};return we.createElement(Yr,g,d.map(function(b){return we.cloneElement(b,{key:"error-bar-".concat(i,"-").concat(b.props.dataKey),data:s,xAxis:a,yAxis:l,layout:u,offset:h,dataPointFormatter:m})}))}},{key:"render",value:function(){var r=this.props,i=r.hide,o=r.data,s=r.className,a=r.xAxis,l=r.yAxis,u=r.left,c=r.top,d=r.width,h=r.height,m=r.isAnimationActive,g=r.background,b=r.id;if(i||!o||!o.length)return null;var v=this.state.isAnimationFinished,w=Hn("recharts-bar",s),S=a&&a.allowDataOverflow,C=l&&l.allowDataOverflow,E=S||C,T=Rn(b)?this.id:b;return we.createElement(Yr,{className:w},S||C?we.createElement("defs",null,we.createElement("clipPath",{id:"clipPath-".concat(T)},we.createElement("rect",{x:S?u:u-d/2,y:C?c:c-h/2,width:S?d:d*2,height:C?h:h*2}))):null,we.createElement(Yr,{className:"recharts-bar-rectangles",clipPath:E?"url(#clipPath-".concat(T,")"):null},g?this.renderBackground():null,this.renderRectangles()),this.renderErrorBar(E,T),(!m||v)&&_h.renderCallByParent(this.props,o))}}],[{key:"getDerivedStateFromProps",value:function(r,i){return r.animationId!==i.prevAnimationId?{prevAnimationId:r.animationId,curData:r.data,prevData:i.curData}:r.data!==i.curData?{curData:r.data}:null}}])})(A.PureComponent);xIe=Bb;Qm(Bb,"displayName","Bar");Qm(Bb,"defaultProps",{xAxisId:0,yAxisId:0,legendType:"rect",minPointSize:0,hide:!1,data:[],layout:"vertical",activeBar:!1,isAnimationActive:!Fb.isSsr,animationBegin:0,animationDuration:400,animationEasing:"ease"});Qm(Bb,"getComposedData",function(e){var t=e.props,n=e.item,r=e.barPosition,i=e.bandSize,o=e.xAxis,s=e.yAxis,a=e.xAxisTicks,l=e.yAxisTicks,u=e.stackedData,c=e.dataStartIndex,d=e.displayedData,h=e.offset,m=Zjt(r,n);if(!m)return null;var g=t.layout,b=n.type.defaultProps,v=b!==void 0?Ki(Ki({},b),n.props):n.props,w=v.dataKey,S=v.children,C=v.minPointSize,E=g==="horizontal"?s:o,T=u?E.scale.domain():null,O=sDt({numericAxis:E}),M=lu(S,NLe),N=d.map(function(I,D){var P,F,z,$,B,H;u?P=Jjt(u[c+D],T):(P=na(I,w),Array.isArray(P)||(P=[O,P]));var U=H6t(C,xIe.defaultProps.minPointSize)(P[1],D);if(g==="horizontal"){var W,q=[s.scale(P[0]),s.scale(P[1])],Y=q[0],Q=q[1];F=gme({axis:o,ticks:a,bandSize:i,offset:m.offset,entry:I,index:D}),z=(W=Q??Y)!==null&&W!==void 0?W:void 0,$=m.size;var G=Y-Q;if(B=Number.isNaN(G)?0:G,H={x:F,y:s.y,width:$,height:s.height},Math.abs(U)>0&&Math.abs(B)<Math.abs(U)){var le=Xu(B||U)*(Math.abs(U)-Math.abs(B));z-=le,B+=le}}else{var K=[o.scale(P[0]),o.scale(P[1])],te=K[0],de=K[1];if(F=te,z=gme({axis:s,ticks:l,bandSize:i,offset:m.offset,entry:I,index:D}),$=de-te,B=m.size,H={x:o.x,y:z,width:o.width,height:B},Math.abs(U)>0&&Math.abs($)<Math.abs(U)){var ue=Xu($||U)*(Math.abs(U)-Math.abs($));$+=ue}}return Ki(Ki(Ki({},I),{},{x:F,y:z,width:$,height:B,value:u?P:P[1],payload:I,background:H},M&&M[D]&&M[D].props),{},{tooltipPayload:[oIe(n,I)],tooltipPosition:{x:F+$/2,y:z+B/2}})});return Ki({data:N,layout:g},h)});function NT(e){"@babel/helpers - typeof";return NT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},NT(e)}function J6t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Tge(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,kIe(r.key),r)}}function e4t(e,t,n){return t&&Tge(e.prototype,t),n&&Tge(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Age(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 $u(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Age(Object(n),!0).forEach(function(r){RD(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Age(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function RD(e,t,n){return t=kIe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function kIe(e){var t=t4t(e,"string");return NT(t)=="symbol"?t:t+""}function t4t(e,t){if(NT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(NT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var hQ=function(t,n,r,i,o){var s=t.width,a=t.height,l=t.layout,u=t.children,c=Object.keys(n),d={left:r.left,leftMirror:r.left,right:s-r.right,rightMirror:s-r.right,top:r.top,topMirror:r.top,bottom:a-r.bottom,bottomMirror:a-r.bottom},h=!!tl(u,Bb);return c.reduce(function(m,g){var b=n[g],v=b.orientation,w=b.domain,S=b.padding,C=S===void 0?{}:S,E=b.mirror,T=b.reversed,O="".concat(v).concat(E?"Mirror":""),M,N,I,D,P;if(b.type==="number"&&(b.padding==="gap"||b.padding==="no-gap")){var F=w[1]-w[0],z=1/0,$=b.categoricalDomain.sort(q_t);if($.forEach(function(K,te){te>0&&(z=Math.min((K||0)-($[te-1]||0),z))}),Number.isFinite(z)){var B=z/F,H=b.layout==="vertical"?r.height:r.width;if(b.padding==="gap"&&(M=B*H/2),b.padding==="no-gap"){var U=xb(t.barCategoryGap,B*H),W=B*H/2;M=W-U-(W-U)/H*U}}}i==="xAxis"?N=[r.left+(C.left||0)+(M||0),r.left+r.width-(C.right||0)-(M||0)]:i==="yAxis"?N=l==="horizontal"?[r.top+r.height-(C.bottom||0),r.top+(C.top||0)]:[r.top+(C.top||0)+(M||0),r.top+r.height-(C.bottom||0)-(M||0)]:N=b.range,T&&(N=[N[1],N[0]]);var q=Xjt(b,o,h),Y=q.scale,Q=q.realScaleType;Y.domain(w).range(N),Qjt(Y);var G=oDt(Y,$u($u({},b),{},{realScaleType:Q}));i==="xAxis"?(P=v==="top"&&!E||v==="bottom"&&E,I=r.left,D=d[O]-P*b.height):i==="yAxis"&&(P=v==="left"&&!E||v==="right"&&E,I=d[O]-P*b.width,D=r.top);var le=$u($u($u({},b),G),{},{realScaleType:Q,x:I,y:D,scale:Y,width:i==="xAxis"?r.width:b.width,height:i==="yAxis"?r.height:b.height});return le.bandSize=CI(le,G),!b.hide&&i==="xAxis"?d[O]+=(P?-1:1)*le.height:b.hide||(d[O]+=(P?-1:1)*le.width),$u($u({},m),{},RD({},g,le))},{})},CIe=function(t,n){var r=t.x,i=t.y,o=n.x,s=n.y;return{x:Math.min(r,o),y:Math.min(i,s),width:Math.abs(o-r),height:Math.abs(s-i)}},n4t=function(t){var n=t.x1,r=t.y1,i=t.x2,o=t.y2;return CIe({x:n,y:r},{x:i,y:o})},EIe=(function(){function e(t){J6t(this,e),this.scale=t}return e4t(e,[{key:"domain",get:function(){return this.scale.domain}},{key:"range",get:function(){return this.scale.range}},{key:"rangeMin",get:function(){return this.range()[0]}},{key:"rangeMax",get:function(){return this.range()[1]}},{key:"bandwidth",get:function(){return this.scale.bandwidth}},{key:"apply",value:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.bandAware,o=r.position;if(n!==void 0){if(o)switch(o){case"start":return this.scale(n);case"middle":{var s=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+s}case"end":{var a=this.bandwidth?this.bandwidth():0;return this.scale(n)+a}default:return this.scale(n)}if(i){var l=this.bandwidth?this.bandwidth()/2:0;return this.scale(n)+l}return this.scale(n)}}},{key:"isInRange",value:function(n){var r=this.range(),i=r[0],o=r[r.length-1];return i<=o?n>=i&&n<=o:n>=o&&n<=i}}],[{key:"create",value:function(n){return new e(n)}}])})();RD(EIe,"EPS",1e-4);var pQ=function(t){var n=Object.keys(t).reduce(function(r,i){return $u($u({},r),{},RD({},i,EIe.create(t[i])))},{});return $u($u({},n),{},{apply:function(i){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s=o.bandAware,a=o.position;return M6t(i,function(l,u){return n[u].apply(l,{bandAware:s,position:a})})},isInRange:function(i){return vIe(i,function(o,s){return n[s].isInRange(o)})}})};function r4t(e){return(e%180+180)%180}var i4t=function(t){var n=t.width,r=t.height,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,o=r4t(i),s=o*Math.PI/180,a=Math.atan(r/n),l=s>a&&s<Math.PI-a?r/Math.sin(s):n/Math.cos(s);return Math.abs(l)},$B,Oge;function o4t(){if(Oge)return $B;Oge=1;var e=Wg(),t=CA(),n=xD();function r(i){return function(o,s,a){var l=Object(o);if(!t(o)){var u=e(s,3);o=n(o),s=function(d){return u(l[d],d,l)}}var c=i(o,s,a);return c>-1?l[u?o[c]:c]:void 0}}return $B=r,$B}var zB,Rge;function s4t(){if(Rge)return zB;Rge=1;var e=mIe();function t(n){var r=e(n),i=r%1;return r===r?i?r-i:r:0}return zB=t,zB}var FB,Mge;function a4t(){if(Mge)return FB;Mge=1;var e=vLe(),t=Wg(),n=s4t(),r=Math.max;function i(o,s,a){var l=o==null?0:o.length;if(!l)return-1;var u=a==null?0:n(a);return u<0&&(u=r(l+u,0)),e(o,t(s,3),u)}return FB=i,FB}var BB,_ge;function l4t(){if(_ge)return BB;_ge=1;var e=o4t(),t=a4t(),n=e(t);return BB=n,BB}var u4t=l4t();const c4t=cr(u4t);var d4t=XNe();const f4t=cr(d4t);var h4t=f4t(function(e){return{x:e.left,y:e.top,width:e.width,height:e.height}},function(e){return["l",e.left,"t",e.top,"w",e.width,"h",e.height].join("")}),mQ=A.createContext(void 0),gQ=A.createContext(void 0),TIe=A.createContext(void 0),AIe=A.createContext({}),OIe=A.createContext(void 0),RIe=A.createContext(0),MIe=A.createContext(0),Nge=function(t){var n=t.state,r=n.xAxisMap,i=n.yAxisMap,o=n.offset,s=t.clipPathId,a=t.children,l=t.width,u=t.height,c=h4t(o);return we.createElement(mQ.Provider,{value:r},we.createElement(gQ.Provider,{value:i},we.createElement(AIe.Provider,{value:o},we.createElement(TIe.Provider,{value:c},we.createElement(OIe.Provider,{value:s},we.createElement(RIe.Provider,{value:u},we.createElement(MIe.Provider,{value:l},a)))))))},p4t=function(){return A.useContext(OIe)},_Ie=function(t){var n=A.useContext(mQ);n==null&&Sb();var r=n[t];return r==null&&Sb(),r},m4t=function(){var t=A.useContext(mQ);return cm(t)},g4t=function(){var t=A.useContext(gQ),n=c4t(t,function(r){return vIe(r.domain,Number.isFinite)});return n||cm(t)},NIe=function(t){var n=A.useContext(gQ);n==null&&Sb();var r=n[t];return r==null&&Sb(),r},y4t=function(){var t=A.useContext(TIe);return t},b4t=function(){return A.useContext(AIe)},yQ=function(){return A.useContext(MIe)},bQ=function(){return A.useContext(RIe)};function bw(e){"@babel/helpers - typeof";return bw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},bw(e)}function v4t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function x4t(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,IIe(r.key),r)}}function w4t(e,t,n){return t&&x4t(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function S4t(e,t,n){return t=$I(t),k4t(e,LIe()?Reflect.construct(t,n||[],$I(e).constructor):t.apply(e,n))}function k4t(e,t){if(t&&(bw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return C4t(e)}function C4t(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function LIe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(LIe=function(){return!!e})()}function $I(e){return $I=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},$I(e)}function E4t(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&AW(e,t)}function AW(e,t){return AW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},AW(e,t)}function Lge(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 Ige(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Lge(Object(n),!0).forEach(function(r){vQ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Lge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function vQ(e,t,n){return t=IIe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function IIe(e){var t=T4t(e,"string");return bw(t)=="symbol"?t:t+""}function T4t(e,t){if(bw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(bw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function A4t(e,t){return _4t(e)||M4t(e,t)||R4t(e,t)||O4t()}function O4t(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
2908
2908
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function R4t(e,t){if(e){if(typeof e=="string")return Pge(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Pge(e,t)}}function Pge(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function M4t(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,s,a=[],l=!0,u=!1;try{if(o=(n=n.call(e)).next,t!==0)for(;!(l=(r=o.call(n)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(c){u=!0,i=c}finally{try{if(!l&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw i}}return a}}function _4t(e){if(Array.isArray(e))return e}function OW(){return OW=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},OW.apply(this,arguments)}var N4t=function(t,n){var r;return we.isValidElement(t)?r=we.cloneElement(t,n):yn(t)?r=t(n):r=we.createElement("line",OW({},n,{className:"recharts-reference-line-line"})),r},L4t=function(t,n,r,i,o,s,a,l,u){var c=o.x,d=o.y,h=o.width,m=o.height;if(r){var g=u.y,b=t.y.apply(g,{position:s});if(Ed(u,"discard")&&!t.y.isInRange(b))return null;var v=[{x:c+h,y:b},{x:c,y:b}];return l==="left"?v.reverse():v}if(n){var w=u.x,S=t.x.apply(w,{position:s});if(Ed(u,"discard")&&!t.x.isInRange(S))return null;var C=[{x:S,y:d+m},{x:S,y:d}];return a==="top"?C.reverse():C}if(i){var E=u.segment,T=E.map(function(O){return t.apply(O,{position:s})});return Ed(u,"discard")&&T6t(T,function(O){return!t.isInRange(O)})?null:T}return null};function I4t(e){var t=e.x,n=e.y,r=e.segment,i=e.xAxisId,o=e.yAxisId,s=e.shape,a=e.className,l=e.alwaysShow,u=p4t(),c=_Ie(i),d=NIe(o),h=y4t();if(!u||!h)return null;Rh(l===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var m=pQ({x:c.scale,y:d.scale}),g=ho(t),b=ho(n),v=r&&r.length===2,w=L4t(m,g,b,v,h,e.position,c.orientation,d.orientation,e);if(!w)return null;var S=A4t(w,2),C=S[0],E=C.x,T=C.y,O=S[1],M=O.x,N=O.y,I=Ed(e,"hidden")?"url(#".concat(u,")"):void 0,D=Ige(Ige({clipPath:I},wn(e,!0)),{},{x1:E,y1:T,x2:M,y2:N});return we.createElement(Yr,{className:Hn("recharts-reference-line",a)},N4t(s,D),ks.renderCallByParent(e,n4t({x1:E,y1:T,x2:M,y2:N})))}var xQ=(function(e){function t(){return v4t(this,t),S4t(this,t,arguments)}return E4t(t,e),w4t(t,[{key:"render",value:function(){return we.createElement(I4t,this.props)}}])})(we.Component);vQ(xQ,"displayName","ReferenceLine");vQ(xQ,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,fill:"none",stroke:"#ccc",fillOpacity:1,strokeWidth:1,position:"middle"});function RW(){return RW=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},RW.apply(this,arguments)}function vw(e){"@babel/helpers - typeof";return vw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},vw(e)}function jge(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 Dge(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?jge(Object(n),!0).forEach(function(r){MD(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):jge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function P4t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function j4t(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,jIe(r.key),r)}}function D4t(e,t,n){return t&&j4t(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function $4t(e,t,n){return t=zI(t),z4t(e,PIe()?Reflect.construct(t,n||[],zI(e).constructor):t.apply(e,n))}function z4t(e,t){if(t&&(vw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return F4t(e)}function F4t(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function PIe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(PIe=function(){return!!e})()}function zI(e){return zI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},zI(e)}function B4t(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&MW(e,t)}function MW(e,t){return MW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},MW(e,t)}function MD(e,t,n){return t=jIe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function jIe(e){var t=H4t(e,"string");return vw(t)=="symbol"?t:t+""}function H4t(e,t){if(vw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(vw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var U4t=function(t){var n=t.x,r=t.y,i=t.xAxis,o=t.yAxis,s=pQ({x:i.scale,y:o.scale}),a=s.apply({x:n,y:r},{bandAware:!0});return Ed(t,"discard")&&!s.isInRange(a)?null:a},_D=(function(e){function t(){return P4t(this,t),$4t(this,t,arguments)}return B4t(t,e),D4t(t,[{key:"render",value:function(){var r=this.props,i=r.x,o=r.y,s=r.r,a=r.alwaysShow,l=r.clipPathId,u=ho(i),c=ho(o);if(Rh(a===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.'),!u||!c)return null;var d=U4t(this.props);if(!d)return null;var h=d.x,m=d.y,g=this.props,b=g.shape,v=g.className,w=Ed(this.props,"hidden")?"url(#".concat(l,")"):void 0,S=Dge(Dge({clipPath:w},wn(this.props,!0)),{},{cx:h,cy:m});return we.createElement(Yr,{className:Hn("recharts-reference-dot",v)},t.renderDot(b,S),ks.renderCallByParent(this.props,{x:h-s,y:m-s,width:2*s,height:2*s}))}}])})(we.Component);MD(_D,"displayName","ReferenceDot");MD(_D,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#fff",stroke:"#ccc",fillOpacity:1,strokeWidth:1});MD(_D,"renderDot",function(e,t){var n;return we.isValidElement(e)?n=we.cloneElement(e,t):yn(e)?n=e(t):n=we.createElement(TD,RW({},t,{cx:t.cx,cy:t.cy,className:"recharts-reference-dot-dot"})),n});function _W(){return _W=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},_W.apply(this,arguments)}function xw(e){"@babel/helpers - typeof";return xw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},xw(e)}function $ge(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 zge(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?$ge(Object(n),!0).forEach(function(r){ND(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$ge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function V4t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function W4t(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,$Ie(r.key),r)}}function q4t(e,t,n){return t&&W4t(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function G4t(e,t,n){return t=FI(t),K4t(e,DIe()?Reflect.construct(t,n||[],FI(e).constructor):t.apply(e,n))}function K4t(e,t){if(t&&(xw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Y4t(e)}function Y4t(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function DIe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(DIe=function(){return!!e})()}function FI(e){return FI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},FI(e)}function X4t(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&NW(e,t)}function NW(e,t){return NW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},NW(e,t)}function ND(e,t,n){return t=$Ie(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function $Ie(e){var t=Q4t(e,"string");return xw(t)=="symbol"?t:t+""}function Q4t(e,t){if(xw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(xw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Z4t=function(t,n,r,i,o){var s=o.x1,a=o.x2,l=o.y1,u=o.y2,c=o.xAxis,d=o.yAxis;if(!c||!d)return null;var h=pQ({x:c.scale,y:d.scale}),m={x:t?h.x.apply(s,{position:"start"}):h.x.rangeMin,y:r?h.y.apply(l,{position:"start"}):h.y.rangeMin},g={x:n?h.x.apply(a,{position:"end"}):h.x.rangeMax,y:i?h.y.apply(u,{position:"end"}):h.y.rangeMax};return Ed(o,"discard")&&(!h.isInRange(m)||!h.isInRange(g))?null:CIe(m,g)},LD=(function(e){function t(){return V4t(this,t),G4t(this,t,arguments)}return X4t(t,e),q4t(t,[{key:"render",value:function(){var r=this.props,i=r.x1,o=r.x2,s=r.y1,a=r.y2,l=r.className,u=r.alwaysShow,c=r.clipPathId;Rh(u===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var d=ho(i),h=ho(o),m=ho(s),g=ho(a),b=this.props.shape;if(!d&&!h&&!m&&!g&&!b)return null;var v=Z4t(d,h,m,g,this.props);if(!v&&!b)return null;var w=Ed(this.props,"hidden")?"url(#".concat(c,")"):void 0;return we.createElement(Yr,{className:Hn("recharts-reference-area",l)},t.renderRect(b,zge(zge({clipPath:w},wn(this.props,!0)),v)),ks.renderCallByParent(this.props,v))}}])})(we.Component);ND(LD,"displayName","ReferenceArea");ND(LD,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#ccc",fillOpacity:.5,stroke:"none",strokeWidth:1});ND(LD,"renderRect",function(e,t){var n;return we.isValidElement(e)?n=we.cloneElement(e,t):yn(e)?n=e(t):n=we.createElement(fQ,_W({},t,{className:"recharts-reference-area-rect"})),n});function zIe(e,t,n){if(t<1)return[];if(t===1&&n===void 0)return e;for(var r=[],i=0;i<e.length;i+=t)r.push(e[i]);return r}function J4t(e,t,n){var r={width:e.width+t.width,height:e.height+t.height};return i4t(r,n)}function e8t(e,t,n){var r=n==="width",i=e.x,o=e.y,s=e.width,a=e.height;return t===1?{start:r?i:o,end:r?i+s:o+a}:{start:r?i+s:o+a,end:r?i:o}}function BI(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 t8t(e,t){return zIe(e,t+1)}function n8t(e,t,n,r,i){for(var o=(r||[]).slice(),s=t.start,a=t.end,l=0,u=1,c=s,d=function(){var g=r==null?void 0:r[l];if(g===void 0)return{v:zIe(r,u)};var b=l,v,w=function(){return v===void 0&&(v=n(g,b)),v},S=g.coordinate,C=l===0||BI(e,S,w,c,a);C||(l=0,c=s,u+=1),C&&(c=S+e*(w()/2+i),l+=u)},h;u<=o.length;)if(h=d(),h)return h.v;return[]}function LT(e){"@babel/helpers - typeof";return LT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},LT(e)}function Fge(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 ws(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Fge(Object(n),!0).forEach(function(r){r8t(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Fge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function r8t(e,t,n){return t=i8t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i8t(e){var t=o8t(e,"string");return LT(t)=="symbol"?t:t+""}function o8t(e,t){if(LT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(LT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function s8t(e,t,n,r,i){for(var o=(r||[]).slice(),s=o.length,a=t.start,l=t.end,u=function(h){var m=o[h],g,b=function(){return g===void 0&&(g=n(m,h)),g};if(h===s-1){var v=e*(m.coordinate+e*b()/2-l);o[h]=m=ws(ws({},m),{},{tickCoord:v>0?m.coordinate-v*e:m.coordinate})}else o[h]=m=ws(ws({},m),{},{tickCoord:m.coordinate});var w=BI(e,m.tickCoord,b,a,l);w&&(l=m.tickCoord-e*(b()/2+i),o[h]=ws(ws({},m),{},{isShow:!0}))},c=s-1;c>=0;c--)u(c);return o}function a8t(e,t,n,r,i,o){var s=(r||[]).slice(),a=s.length,l=t.start,u=t.end;if(o){var c=r[a-1],d=n(c,a-1),h=e*(c.coordinate+e*d/2-u);s[a-1]=c=ws(ws({},c),{},{tickCoord:h>0?c.coordinate-h*e:c.coordinate});var m=BI(e,c.tickCoord,function(){return d},l,u);m&&(u=c.tickCoord-e*(d/2+i),s[a-1]=ws(ws({},c),{},{isShow:!0}))}for(var g=o?a-1:a,b=function(S){var C=s[S],E,T=function(){return E===void 0&&(E=n(C,S)),E};if(S===0){var O=e*(C.coordinate-e*T()/2-l);s[S]=C=ws(ws({},C),{},{tickCoord:O<0?C.coordinate-O*e:C.coordinate})}else s[S]=C=ws(ws({},C),{},{tickCoord:C.coordinate});var M=BI(e,C.tickCoord,T,l,u);M&&(l=C.tickCoord+e*(T()/2+i),s[S]=ws(ws({},C),{},{isShow:!0}))},v=0;v<g;v++)b(v);return s}function wQ(e,t,n){var r=e.tick,i=e.ticks,o=e.viewBox,s=e.minTickGap,a=e.orientation,l=e.interval,u=e.tickFormatter,c=e.unit,d=e.angle;if(!i||!i.length||!r)return[];if(ft(l)||Fb.isSsr)return t8t(i,typeof l=="number"&&ft(l)?l:0);var h=[],m=a==="top"||a==="bottom"?"width":"height",g=c&&m==="width"?eE(c,{fontSize:t,letterSpacing:n}):{width:0,height:0},b=function(C,E){var T=yn(u)?u(C.value,E):C.value;return m==="width"?J4t(eE(T,{fontSize:t,letterSpacing:n}),g,d):eE(T,{fontSize:t,letterSpacing:n})[m]},v=i.length>=2?Xu(i[1].coordinate-i[0].coordinate):1,w=e8t(o,v,m);return l==="equidistantPreserveStart"?n8t(v,w,b,i,s):(l==="preserveStart"||l==="preserveStartEnd"?h=a8t(v,w,b,i,s,l==="preserveStartEnd"):h=s8t(v,w,b,i,s),h.filter(function(S){return S.isShow}))}var l8t=["viewBox"],u8t=["viewBox"],c8t=["ticks"];function ww(e){"@babel/helpers - typeof";return ww=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ww(e)}function k1(){return k1=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},k1.apply(this,arguments)}function Bge(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?Bge(Object(n),!0).forEach(function(r){SQ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Bge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function HB(e,t){if(e==null)return{};var n=d8t(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function d8t(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function f8t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Hge(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,BIe(r.key),r)}}function h8t(e,t,n){return t&&Hge(e.prototype,t),n&&Hge(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function p8t(e,t,n){return t=HI(t),m8t(e,FIe()?Reflect.construct(t,n||[],HI(e).constructor):t.apply(e,n))}function m8t(e,t){if(t&&(ww(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return g8t(e)}function g8t(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function FIe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(FIe=function(){return!!e})()}function HI(e){return HI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},HI(e)}function y8t(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&LW(e,t)}function LW(e,t){return LW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},LW(e,t)}function SQ(e,t,n){return t=BIe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function BIe(e){var t=b8t(e,"string");return ww(t)=="symbol"?t:t+""}function b8t(e,t){if(ww(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(ww(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var gS=(function(e){function t(n){var r;return f8t(this,t),r=p8t(this,t,[n]),r.state={fontSize:"",letterSpacing:""},r}return y8t(t,e),h8t(t,[{key:"shouldComponentUpdate",value:function(r,i){var o=r.viewBox,s=HB(r,l8t),a=this.props,l=a.viewBox,u=HB(a,u8t);return!V1(o,l)||!V1(s,u)||!V1(i,this.state)}},{key:"componentDidMount",value:function(){var r=this.layerReference;if(r){var i=r.getElementsByClassName("recharts-cartesian-axis-tick-value")[0];i&&this.setState({fontSize:window.getComputedStyle(i).fontSize,letterSpacing:window.getComputedStyle(i).letterSpacing})}}},{key:"getTickLineCoord",value:function(r){var i=this.props,o=i.x,s=i.y,a=i.width,l=i.height,u=i.orientation,c=i.tickSize,d=i.mirror,h=i.tickMargin,m,g,b,v,w,S,C=d?-1:1,E=r.tickSize||c,T=ft(r.tickCoord)?r.tickCoord:r.coordinate;switch(u){case"top":m=g=r.coordinate,v=s+ +!d*l,b=v-C*E,S=b-C*h,w=T;break;case"left":b=v=r.coordinate,g=o+ +!d*a,m=g-C*E,w=m-C*h,S=T;break;case"right":b=v=r.coordinate,g=o+ +d*a,m=g+C*E,w=m+C*h,S=T;break;default:m=g=r.coordinate,v=s+ +d*l,b=v+C*E,S=b+C*h,w=T;break}return{line:{x1:m,y1:b,x2:g,y2:v},tick:{x:w,y:S}}}},{key:"getTickTextAnchor",value:function(){var r=this.props,i=r.orientation,o=r.mirror,s;switch(i){case"left":s=o?"start":"end";break;case"right":s=o?"end":"start";break;default:s="middle";break}return s}},{key:"getTickVerticalAnchor",value:function(){var r=this.props,i=r.orientation,o=r.mirror,s="end";switch(i){case"left":case"right":s="middle";break;case"top":s=o?"start":"end";break;default:s=o?"end":"start";break}return s}},{key:"renderAxisLine",value:function(){var r=this.props,i=r.x,o=r.y,s=r.width,a=r.height,l=r.orientation,u=r.mirror,c=r.axisLine,d=to(to(to({},wn(this.props,!1)),wn(c,!1)),{},{fill:"none"});if(l==="top"||l==="bottom"){var h=+(l==="top"&&!u||l==="bottom"&&u);d=to(to({},d),{},{x1:i,y1:o+h*a,x2:i+s,y2:o+h*a})}else{var m=+(l==="left"&&!u||l==="right"&&u);d=to(to({},d),{},{x1:i+m*s,y1:o,x2:i+m*s,y2:o+a})}return we.createElement("line",k1({},d,{className:Hn("recharts-cartesian-axis-line",au(c,"className"))}))}},{key:"renderTicks",value:function(r,i,o){var s=this,a=this.props,l=a.tickLine,u=a.stroke,c=a.tick,d=a.tickFormatter,h=a.unit,m=wQ(to(to({},this.props),{},{ticks:r}),i,o),g=this.getTickTextAnchor(),b=this.getTickVerticalAnchor(),v=wn(this.props,!1),w=wn(c,!1),S=to(to({},v),{},{fill:"none"},wn(l,!1)),C=m.map(function(E,T){var O=s.getTickLineCoord(E),M=O.line,N=O.tick,I=to(to(to(to({textAnchor:g,verticalAnchor:b},v),{},{stroke:"none",fill:u},w),N),{},{index:T,payload:E,visibleTicksCount:m.length,tickFormatter:d});return we.createElement(Yr,k1({className:"recharts-cartesian-axis-tick",key:"tick-".concat(E.value,"-").concat(E.coordinate,"-").concat(E.tickCoord)},hI(s.props,E,T)),l&&we.createElement("line",k1({},S,M,{className:Hn("recharts-cartesian-axis-tick-line",au(l,"className"))})),c&&t.renderTickItem(c,I,"".concat(yn(d)?d(E.value,T):E.value).concat(h||"")))});return we.createElement("g",{className:"recharts-cartesian-axis-ticks"},C)}},{key:"render",value:function(){var r=this,i=this.props,o=i.axisLine,s=i.width,a=i.height,l=i.ticksGenerator,u=i.className,c=i.hide;if(c)return null;var d=this.props,h=d.ticks,m=HB(d,c8t),g=h;return yn(l)&&(g=h&&h.length>0?l(this.props):l(m)),s<=0||a<=0||!g||!g.length?null:we.createElement(Yr,{className:Hn("recharts-cartesian-axis",u),ref:function(v){r.layerReference=v}},o&&this.renderAxisLine(),this.renderTicks(g,this.state.fontSize,this.state.letterSpacing),ks.renderCallByParent(this.props))}}],[{key:"renderTickItem",value:function(r,i,o){var s,a=Hn(i.className,"recharts-cartesian-axis-tick-value");return we.isValidElement(r)?s=we.cloneElement(r,to(to({},i),{},{className:a})):yn(r)?s=r(to(to({},i),{},{className:a})):s=we.createElement(vI,k1({},i,{className:"recharts-cartesian-axis-tick-value"}),o),s}}])})(A.Component);SQ(gS,"displayName","CartesianAxis");SQ(gS,"defaultProps",{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"});var v8t=["x1","y1","x2","y2","key"],x8t=["offset"];function kb(e){"@babel/helpers - typeof";return kb=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},kb(e)}function Uge(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 Cs(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Uge(Object(n),!0).forEach(function(r){w8t(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Uge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function w8t(e,t,n){return t=S8t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function S8t(e){var t=k8t(e,"string");return kb(t)=="symbol"?t:t+""}function k8t(e,t){if(kb(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(kb(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ly(){return ly=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ly.apply(this,arguments)}function Vge(e,t){if(e==null)return{};var n=C8t(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function C8t(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}var E8t=function(t){var n=t.fill;if(!n||n==="none")return null;var r=t.fillOpacity,i=t.x,o=t.y,s=t.width,a=t.height,l=t.ry;return we.createElement("rect",{x:i,y:o,ry:l,width:s,height:a,stroke:"none",fill:n,fillOpacity:r,className:"recharts-cartesian-grid-bg"})};function HIe(e,t){var n;if(we.isValidElement(e))n=we.cloneElement(e,t);else if(yn(e))n=e(t);else{var r=t.x1,i=t.y1,o=t.x2,s=t.y2,a=t.key,l=Vge(t,v8t),u=wn(l,!1);u.offset;var c=Vge(u,x8t);n=we.createElement("line",ly({},c,{x1:r,y1:i,x2:o,y2:s,fill:"none",key:a}))}return n}function T8t(e){var t=e.x,n=e.width,r=e.horizontal,i=r===void 0?!0:r,o=e.horizontalPoints;if(!i||!o||!o.length)return null;var s=o.map(function(a,l){var u=Cs(Cs({},e),{},{x1:t,y1:a,x2:t+n,y2:a,key:"line-".concat(l),index:l});return HIe(i,u)});return we.createElement("g",{className:"recharts-cartesian-grid-horizontal"},s)}function A8t(e){var t=e.y,n=e.height,r=e.vertical,i=r===void 0?!0:r,o=e.verticalPoints;if(!i||!o||!o.length)return null;var s=o.map(function(a,l){var u=Cs(Cs({},e),{},{x1:a,y1:t,x2:a,y2:t+n,key:"line-".concat(l),index:l});return HIe(i,u)});return we.createElement("g",{className:"recharts-cartesian-grid-vertical"},s)}function O8t(e){var t=e.horizontalFill,n=e.fillOpacity,r=e.x,i=e.y,o=e.width,s=e.height,a=e.horizontalPoints,l=e.horizontal,u=l===void 0?!0:l;if(!u||!t||!t.length)return null;var c=a.map(function(h){return Math.round(h+i-i)}).sort(function(h,m){return h-m});i!==c[0]&&c.unshift(0);var d=c.map(function(h,m){var g=!c[m+1],b=g?i+s-h:c[m+1]-h;if(b<=0)return null;var v=m%t.length;return we.createElement("rect",{key:"react-".concat(m),y:h,x:r,height:b,width:o,stroke:"none",fill:t[v],fillOpacity:n,className:"recharts-cartesian-grid-bg"})});return we.createElement("g",{className:"recharts-cartesian-gridstripes-horizontal"},d)}function R8t(e){var t=e.vertical,n=t===void 0?!0:t,r=e.verticalFill,i=e.fillOpacity,o=e.x,s=e.y,a=e.width,l=e.height,u=e.verticalPoints;if(!n||!r||!r.length)return null;var c=u.map(function(h){return Math.round(h+o-o)}).sort(function(h,m){return h-m});o!==c[0]&&c.unshift(0);var d=c.map(function(h,m){var g=!c[m+1],b=g?o+a-h:c[m+1]-h;if(b<=0)return null;var v=m%r.length;return we.createElement("rect",{key:"react-".concat(m),x:h,y:s,width:b,height:l,stroke:"none",fill:r[v],fillOpacity:i,className:"recharts-cartesian-grid-bg"})});return we.createElement("g",{className:"recharts-cartesian-gridstripes-vertical"},d)}var M8t=function(t,n){var r=t.xAxis,i=t.width,o=t.height,s=t.offset;return rIe(wQ(Cs(Cs(Cs({},gS.defaultProps),r),{},{ticks:gh(r,!0),viewBox:{x:0,y:0,width:i,height:o}})),s.left,s.left+s.width,n)},_8t=function(t,n){var r=t.yAxis,i=t.width,o=t.height,s=t.offset;return rIe(wQ(Cs(Cs(Cs({},gS.defaultProps),r),{},{ticks:gh(r,!0),viewBox:{x:0,y:0,width:i,height:o}})),s.top,s.top+s.height,n)},Bv={horizontal:!0,vertical:!0,stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[]};function j_(e){var t,n,r,i,o,s,a=yQ(),l=bQ(),u=b4t(),c=Cs(Cs({},e),{},{stroke:(t=e.stroke)!==null&&t!==void 0?t:Bv.stroke,fill:(n=e.fill)!==null&&n!==void 0?n:Bv.fill,horizontal:(r=e.horizontal)!==null&&r!==void 0?r:Bv.horizontal,horizontalFill:(i=e.horizontalFill)!==null&&i!==void 0?i:Bv.horizontalFill,vertical:(o=e.vertical)!==null&&o!==void 0?o:Bv.vertical,verticalFill:(s=e.verticalFill)!==null&&s!==void 0?s:Bv.verticalFill,x:ft(e.x)?e.x:u.left,y:ft(e.y)?e.y:u.top,width:ft(e.width)?e.width:u.width,height:ft(e.height)?e.height:u.height}),d=c.x,h=c.y,m=c.width,g=c.height,b=c.syncWithTicks,v=c.horizontalValues,w=c.verticalValues,S=m4t(),C=g4t();if(!ft(m)||m<=0||!ft(g)||g<=0||!ft(d)||d!==+d||!ft(h)||h!==+h)return null;var E=c.verticalCoordinatesGenerator||M8t,T=c.horizontalCoordinatesGenerator||_8t,O=c.horizontalPoints,M=c.verticalPoints;if((!O||!O.length)&&yn(T)){var N=v&&v.length,I=T({yAxis:C?Cs(Cs({},C),{},{ticks:N?v:C.ticks}):void 0,width:a,height:l,offset:u},N?!0:b);Rh(Array.isArray(I),"horizontalCoordinatesGenerator should return Array but instead it returned [".concat(kb(I),"]")),Array.isArray(I)&&(O=I)}if((!M||!M.length)&&yn(E)){var D=w&&w.length,P=E({xAxis:S?Cs(Cs({},S),{},{ticks:D?w:S.ticks}):void 0,width:a,height:l,offset:u},D?!0:b);Rh(Array.isArray(P),"verticalCoordinatesGenerator should return Array but instead it returned [".concat(kb(P),"]")),Array.isArray(P)&&(M=P)}return we.createElement("g",{className:"recharts-cartesian-grid"},we.createElement(E8t,{fill:c.fill,fillOpacity:c.fillOpacity,x:c.x,y:c.y,width:c.width,height:c.height,ry:c.ry}),we.createElement(T8t,ly({},c,{offset:u,horizontalPoints:O,xAxis:S,yAxis:C})),we.createElement(A8t,ly({},c,{offset:u,verticalPoints:M,xAxis:S,yAxis:C})),we.createElement(O8t,ly({},c,{horizontalPoints:O})),we.createElement(R8t,ly({},c,{verticalPoints:M})))}j_.displayName="CartesianGrid";var N8t=["type","layout","connectNulls","ref"],L8t=["key"];function Sw(e){"@babel/helpers - typeof";return Sw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Sw(e)}function Wge(e,t){if(e==null)return{};var n=I8t(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function I8t(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function rE(){return rE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},rE.apply(this,arguments)}function qge(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 Ka(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?qge(Object(n),!0).forEach(function(r){zu(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):qge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Hv(e){return $8t(e)||D8t(e)||j8t(e)||P8t()}function P8t(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
2909
2909
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function j8t(e,t){if(e){if(typeof e=="string")return IW(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return IW(e,t)}}function D8t(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function $8t(e){if(Array.isArray(e))return IW(e)}function IW(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function z8t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Gge(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,VIe(r.key),r)}}function F8t(e,t,n){return t&&Gge(e.prototype,t),n&&Gge(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function B8t(e,t,n){return t=UI(t),H8t(e,UIe()?Reflect.construct(t,n||[],UI(e).constructor):t.apply(e,n))}function H8t(e,t){if(t&&(Sw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return U8t(e)}function U8t(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function UIe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(UIe=function(){return!!e})()}function UI(e){return UI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},UI(e)}function V8t(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&PW(e,t)}function PW(e,t){return PW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},PW(e,t)}function zu(e,t,n){return t=VIe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function VIe(e){var t=W8t(e,"string");return Sw(t)=="symbol"?t:t+""}function W8t(e,t){if(Sw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Sw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var TA=(function(e){function t(){var n;z8t(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=B8t(this,t,[].concat(i)),zu(n,"state",{isAnimationFinished:!0,totalLength:0}),zu(n,"generateSimpleStrokeDasharray",function(s,a){return"".concat(a,"px ").concat(s-a,"px")}),zu(n,"getStrokeDasharray",function(s,a,l){var u=l.reduce(function(w,S){return w+S});if(!u)return n.generateSimpleStrokeDasharray(a,s);for(var c=Math.floor(s/u),d=s%u,h=a-s,m=[],g=0,b=0;g<l.length;b+=l[g],++g)if(b+l[g]>d){m=[].concat(Hv(l.slice(0,g)),[d-b]);break}var v=m.length%2===0?[0,h]:[h];return[].concat(Hv(t.repeat(l,c)),Hv(m),v).map(function(w){return"".concat(w,"px")}).join(", ")}),zu(n,"id",fS("recharts-line-")),zu(n,"pathRef",function(s){n.mainCurve=s}),zu(n,"handleAnimationEnd",function(){n.setState({isAnimationFinished:!0}),n.props.onAnimationEnd&&n.props.onAnimationEnd()}),zu(n,"handleAnimationStart",function(){n.setState({isAnimationFinished:!1}),n.props.onAnimationStart&&n.props.onAnimationStart()}),n}return V8t(t,e),F8t(t,[{key:"componentDidMount",value:function(){if(this.props.isAnimationActive){var r=this.getTotalLength();this.setState({totalLength:r})}}},{key:"componentDidUpdate",value:function(){if(this.props.isAnimationActive){var r=this.getTotalLength();r!==this.state.totalLength&&this.setState({totalLength:r})}}},{key:"getTotalLength",value:function(){var r=this.mainCurve;try{return r&&r.getTotalLength&&r.getTotalLength()||0}catch{return 0}}},{key:"renderErrorBar",value:function(r,i){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var o=this.props,s=o.points,a=o.xAxis,l=o.yAxis,u=o.layout,c=o.children,d=lu(c,EA);if(!d)return null;var h=function(b,v){return{x:b.x,y:b.y,value:b.value,errorVal:na(b.payload,v)}},m={clipPath:r?"url(#clipPath-".concat(i,")"):null};return we.createElement(Yr,m,d.map(function(g){return we.cloneElement(g,{key:"bar-".concat(g.props.dataKey),data:s,xAxis:a,yAxis:l,layout:u,dataPointFormatter:h})}))}},{key:"renderDots",value:function(r,i,o){var s=this.props.isAnimationActive;if(s&&!this.state.isAnimationFinished)return null;var a=this.props,l=a.dot,u=a.points,c=a.dataKey,d=wn(this.props,!1),h=wn(l,!0),m=u.map(function(b,v){var w=Ka(Ka(Ka({key:"dot-".concat(v),r:3},d),h),{},{index:v,cx:b.x,cy:b.y,value:b.value,dataKey:c,payload:b.payload,points:u});return t.renderDotItem(l,w)}),g={clipPath:r?"url(#clipPath-".concat(i?"":"dots-").concat(o,")"):null};return we.createElement(Yr,rE({className:"recharts-line-dots",key:"dots"},g),m)}},{key:"renderCurveStatically",value:function(r,i,o,s){var a=this.props,l=a.type,u=a.layout,c=a.connectNulls;a.ref;var d=Wge(a,N8t),h=Ka(Ka(Ka({},wn(d,!0)),{},{fill:"none",className:"recharts-line-curve",clipPath:i?"url(#clipPath-".concat(o,")"):null,points:r},s),{},{type:l,layout:u,connectNulls:c});return we.createElement(q1,rE({},h,{pathRef:this.pathRef}))}},{key:"renderCurveWithAnimation",value:function(r,i){var o=this,s=this.props,a=s.points,l=s.strokeDasharray,u=s.isAnimationActive,c=s.animationBegin,d=s.animationDuration,h=s.animationEasing,m=s.animationId,g=s.animateNewValues,b=s.width,v=s.height,w=this.state,S=w.prevPoints,C=w.totalLength;return we.createElement(Pd,{begin:c,duration:d,isActive:u,easing:h,from:{t:0},to:{t:1},key:"line-".concat(m),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(E){var T=E.t;if(S){var O=S.length/a.length,M=a.map(function(F,z){var $=Math.floor(z*O);if(S[$]){var B=S[$],H=is(B.x,F.x),U=is(B.y,F.y);return Ka(Ka({},F),{},{x:H(T),y:U(T)})}if(g){var W=is(b*2,F.x),q=is(v/2,F.y);return Ka(Ka({},F),{},{x:W(T),y:q(T)})}return Ka(Ka({},F),{},{x:F.x,y:F.y})});return o.renderCurveStatically(M,r,i)}var N=is(0,C),I=N(T),D;if(l){var P="".concat(l).split(/[,\s]+/gim).map(function(F){return parseFloat(F)});D=o.getStrokeDasharray(I,C,P)}else D=o.generateSimpleStrokeDasharray(C,I);return o.renderCurveStatically(a,r,i,{strokeDasharray:D})})}},{key:"renderCurve",value:function(r,i){var o=this.props,s=o.points,a=o.isAnimationActive,l=this.state,u=l.prevPoints,c=l.totalLength;return a&&s&&s.length&&(!u&&c>0||!fw(u,s))?this.renderCurveWithAnimation(r,i):this.renderCurveStatically(s,r,i)}},{key:"render",value:function(){var r,i=this.props,o=i.hide,s=i.dot,a=i.points,l=i.className,u=i.xAxis,c=i.yAxis,d=i.top,h=i.left,m=i.width,g=i.height,b=i.isAnimationActive,v=i.id;if(o||!a||!a.length)return null;var w=this.state.isAnimationFinished,S=a.length===1,C=Hn("recharts-line",l),E=u&&u.allowDataOverflow,T=c&&c.allowDataOverflow,O=E||T,M=Rn(v)?this.id:v,N=(r=wn(s,!1))!==null&&r!==void 0?r:{r:3,strokeWidth:2},I=N.r,D=I===void 0?3:I,P=N.strokeWidth,F=P===void 0?2:P,z=tLe(s)?s:{},$=z.clipDot,B=$===void 0?!0:$,H=D*2+F;return we.createElement(Yr,{className:C},E||T?we.createElement("defs",null,we.createElement("clipPath",{id:"clipPath-".concat(M)},we.createElement("rect",{x:E?h:h-m/2,y:T?d:d-g/2,width:E?m:m*2,height:T?g:g*2})),!B&&we.createElement("clipPath",{id:"clipPath-dots-".concat(M)},we.createElement("rect",{x:h-H/2,y:d-H/2,width:m+H,height:g+H}))):null,!S&&this.renderCurve(O,M),this.renderErrorBar(O,M),(S||s)&&this.renderDots(O,B,M),(!b||w)&&_h.renderCallByParent(this.props,a))}}],[{key:"getDerivedStateFromProps",value:function(r,i){return r.animationId!==i.prevAnimationId?{prevAnimationId:r.animationId,curPoints:r.points,prevPoints:i.curPoints}:r.points!==i.curPoints?{curPoints:r.points}:null}},{key:"repeat",value:function(r,i){for(var o=r.length%2!==0?[].concat(Hv(r),[0]):r,s=[],a=0;a<i;++a)s=[].concat(Hv(s),Hv(o));return s}},{key:"renderDotItem",value:function(r,i){var o;if(we.isValidElement(r))o=we.cloneElement(r,i);else if(yn(r))o=r(i);else{var s=i.key,a=Wge(i,L8t),l=Hn("recharts-line-dot",typeof r!="boolean"?r.className:"");o=we.createElement(TD,rE({key:s},a,{className:l}))}return o}}])})(A.PureComponent);zu(TA,"displayName","Line");zu(TA,"defaultProps",{xAxisId:0,yAxisId:0,connectNulls:!1,activeDot:!0,dot:!0,legendType:"line",stroke:"#3182bd",strokeWidth:1,fill:"#fff",points:[],isAnimationActive:!Fb.isSsr,animateNewValues:!0,animationBegin:0,animationDuration:1500,animationEasing:"ease",hide:!1,label:!1});zu(TA,"getComposedData",function(e){var t=e.props,n=e.xAxis,r=e.yAxis,i=e.xAxisTicks,o=e.yAxisTicks,s=e.dataKey,a=e.bandSize,l=e.displayedData,u=e.offset,c=t.layout,d=l.map(function(h,m){var g=na(h,s);return c==="horizontal"?{x:kI({axis:n,ticks:i,bandSize:a,entry:h,index:m}),y:Rn(g)?null:r.scale(g),value:g,payload:h}:{x:Rn(g)?null:n.scale(g),y:kI({axis:r,ticks:o,bandSize:a,entry:h,index:m}),value:g,payload:h}});return Ka({points:d,layout:c},u)});var q8t=["layout","type","stroke","connectNulls","isRange","ref"],G8t=["key"],WIe;function kw(e){"@babel/helpers - typeof";return kw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},kw(e)}function qIe(e,t){if(e==null)return{};var n=K8t(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function K8t(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function uy(){return uy=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},uy.apply(this,arguments)}function Kge(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?Kge(Object(n),!0).forEach(function(r){gd(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Kge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Y8t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Yge(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,KIe(r.key),r)}}function X8t(e,t,n){return t&&Yge(e.prototype,t),n&&Yge(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Q8t(e,t,n){return t=VI(t),Z8t(e,GIe()?Reflect.construct(t,n||[],VI(e).constructor):t.apply(e,n))}function Z8t(e,t){if(t&&(kw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return J8t(e)}function J8t(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function GIe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(GIe=function(){return!!e})()}function VI(e){return VI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},VI(e)}function e$t(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&jW(e,t)}function jW(e,t){return jW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},jW(e,t)}function gd(e,t,n){return t=KIe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function KIe(e){var t=t$t(e,"string");return kw(t)=="symbol"?t:t+""}function t$t(e,t){if(kw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(kw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var qg=(function(e){function t(){var n;Y8t(this,t);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return n=Q8t(this,t,[].concat(i)),gd(n,"state",{isAnimationFinished:!0}),gd(n,"id",fS("recharts-area-")),gd(n,"handleAnimationEnd",function(){var s=n.props.onAnimationEnd;n.setState({isAnimationFinished:!0}),yn(s)&&s()}),gd(n,"handleAnimationStart",function(){var s=n.props.onAnimationStart;n.setState({isAnimationFinished:!1}),yn(s)&&s()}),n}return e$t(t,e),X8t(t,[{key:"renderDots",value:function(r,i,o){var s=this.props.isAnimationActive,a=this.state.isAnimationFinished;if(s&&!a)return null;var l=this.props,u=l.dot,c=l.points,d=l.dataKey,h=wn(this.props,!1),m=wn(u,!0),g=c.map(function(v,w){var S=Kp(Kp(Kp({key:"dot-".concat(w),r:3},h),m),{},{index:w,cx:v.x,cy:v.y,dataKey:d,value:v.value,payload:v.payload,points:c});return t.renderDotItem(u,S)}),b={clipPath:r?"url(#clipPath-".concat(i?"":"dots-").concat(o,")"):null};return we.createElement(Yr,uy({className:"recharts-area-dots"},b),g)}},{key:"renderHorizontalRect",value:function(r){var i=this.props,o=i.baseLine,s=i.points,a=i.strokeWidth,l=s[0].x,u=s[s.length-1].x,c=r*Math.abs(l-u),d=Xm(s.map(function(h){return h.y||0}));return ft(o)&&typeof o=="number"?d=Math.max(o,d):o&&Array.isArray(o)&&o.length&&(d=Math.max(Xm(o.map(function(h){return h.y||0})),d)),ft(d)?we.createElement("rect",{x:l<u?l:l-c,y:0,width:c,height:Math.floor(d+(a?parseInt("".concat(a),10):1))}):null}},{key:"renderVerticalRect",value:function(r){var i=this.props,o=i.baseLine,s=i.points,a=i.strokeWidth,l=s[0].y,u=s[s.length-1].y,c=r*Math.abs(l-u),d=Xm(s.map(function(h){return h.x||0}));return ft(o)&&typeof o=="number"?d=Math.max(o,d):o&&Array.isArray(o)&&o.length&&(d=Math.max(Xm(o.map(function(h){return h.x||0})),d)),ft(d)?we.createElement("rect",{x:0,y:l<u?l:l-c,width:d+(a?parseInt("".concat(a),10):1),height:Math.floor(c)}):null}},{key:"renderClipRect",value:function(r){var i=this.props.layout;return i==="vertical"?this.renderVerticalRect(r):this.renderHorizontalRect(r)}},{key:"renderAreaStatically",value:function(r,i,o,s){var a=this.props,l=a.layout,u=a.type,c=a.stroke,d=a.connectNulls,h=a.isRange;a.ref;var m=qIe(a,q8t);return we.createElement(Yr,{clipPath:o?"url(#clipPath-".concat(s,")"):null},we.createElement(q1,uy({},wn(m,!0),{points:r,connectNulls:d,type:u,baseLine:i,layout:l,stroke:"none",className:"recharts-area-area"})),c!=="none"&&we.createElement(q1,uy({},wn(this.props,!1),{className:"recharts-area-curve",layout:l,type:u,connectNulls:d,fill:"none",points:r})),c!=="none"&&h&&we.createElement(q1,uy({},wn(this.props,!1),{className:"recharts-area-curve",layout:l,type:u,connectNulls:d,fill:"none",points:i})))}},{key:"renderAreaWithAnimation",value:function(r,i){var o=this,s=this.props,a=s.points,l=s.baseLine,u=s.isAnimationActive,c=s.animationBegin,d=s.animationDuration,h=s.animationEasing,m=s.animationId,g=this.state,b=g.prevPoints,v=g.prevBaseLine;return we.createElement(Pd,{begin:c,duration:d,isActive:u,easing:h,from:{t:0},to:{t:1},key:"area-".concat(m),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(w){var S=w.t;if(b){var C=b.length/a.length,E=a.map(function(N,I){var D=Math.floor(I*C);if(b[D]){var P=b[D],F=is(P.x,N.x),z=is(P.y,N.y);return Kp(Kp({},N),{},{x:F(S),y:z(S)})}return N}),T;if(ft(l)&&typeof l=="number"){var O=is(v,l);T=O(S)}else if(Rn(l)||dS(l)){var M=is(v,0);T=M(S)}else T=l.map(function(N,I){var D=Math.floor(I*C);if(v[D]){var P=v[D],F=is(P.x,N.x),z=is(P.y,N.y);return Kp(Kp({},N),{},{x:F(S),y:z(S)})}return N});return o.renderAreaStatically(E,T,r,i)}return we.createElement(Yr,null,we.createElement("defs",null,we.createElement("clipPath",{id:"animationClipPath-".concat(i)},o.renderClipRect(S))),we.createElement(Yr,{clipPath:"url(#animationClipPath-".concat(i,")")},o.renderAreaStatically(a,l,r,i)))})}},{key:"renderArea",value:function(r,i){var o=this.props,s=o.points,a=o.baseLine,l=o.isAnimationActive,u=this.state,c=u.prevPoints,d=u.prevBaseLine,h=u.totalLength;return l&&s&&s.length&&(!c&&h>0||!fw(c,s)||!fw(d,a))?this.renderAreaWithAnimation(r,i):this.renderAreaStatically(s,a,r,i)}},{key:"render",value:function(){var r,i=this.props,o=i.hide,s=i.dot,a=i.points,l=i.className,u=i.top,c=i.left,d=i.xAxis,h=i.yAxis,m=i.width,g=i.height,b=i.isAnimationActive,v=i.id;if(o||!a||!a.length)return null;var w=this.state.isAnimationFinished,S=a.length===1,C=Hn("recharts-area",l),E=d&&d.allowDataOverflow,T=h&&h.allowDataOverflow,O=E||T,M=Rn(v)?this.id:v,N=(r=wn(s,!1))!==null&&r!==void 0?r:{r:3,strokeWidth:2},I=N.r,D=I===void 0?3:I,P=N.strokeWidth,F=P===void 0?2:P,z=tLe(s)?s:{},$=z.clipDot,B=$===void 0?!0:$,H=D*2+F;return we.createElement(Yr,{className:C},E||T?we.createElement("defs",null,we.createElement("clipPath",{id:"clipPath-".concat(M)},we.createElement("rect",{x:E?c:c-m/2,y:T?u:u-g/2,width:E?m:m*2,height:T?g:g*2})),!B&&we.createElement("clipPath",{id:"clipPath-dots-".concat(M)},we.createElement("rect",{x:c-H/2,y:u-H/2,width:m+H,height:g+H}))):null,S?null:this.renderArea(O,M),(s||S)&&this.renderDots(O,B,M),(!b||w)&&_h.renderCallByParent(this.props,a))}}],[{key:"getDerivedStateFromProps",value:function(r,i){return r.animationId!==i.prevAnimationId?{prevAnimationId:r.animationId,curPoints:r.points,curBaseLine:r.baseLine,prevPoints:i.curPoints,prevBaseLine:i.curBaseLine}:r.points!==i.curPoints||r.baseLine!==i.curBaseLine?{curPoints:r.points,curBaseLine:r.baseLine}:null}}])})(A.PureComponent);WIe=qg;gd(qg,"displayName","Area");gd(qg,"defaultProps",{stroke:"#3182bd",fill:"#3182bd",fillOpacity:.6,xAxisId:0,yAxisId:0,legendType:"line",connectNulls:!1,points:[],dot:!1,activeDot:!0,hide:!1,isAnimationActive:!Fb.isSsr,animationBegin:0,animationDuration:1500,animationEasing:"ease"});gd(qg,"getBaseValue",function(e,t,n,r){var i=e.layout,o=e.baseValue,s=t.props.baseValue,a=s??o;if(ft(a)&&typeof a=="number")return a;var l=i==="horizontal"?r:n,u=l.scale.domain();if(l.type==="number"){var c=Math.max(u[0],u[1]),d=Math.min(u[0],u[1]);return a==="dataMin"?d:a==="dataMax"||c<0?c:Math.max(Math.min(u[0],u[1]),0)}return a==="dataMin"?u[0]:a==="dataMax"?u[1]:u[0]});gd(qg,"getComposedData",function(e){var t=e.props,n=e.item,r=e.xAxis,i=e.yAxis,o=e.xAxisTicks,s=e.yAxisTicks,a=e.bandSize,l=e.dataKey,u=e.stackedData,c=e.dataStartIndex,d=e.displayedData,h=e.offset,m=t.layout,g=u&&u.length,b=WIe.getBaseValue(t,n,r,i),v=m==="horizontal",w=!1,S=d.map(function(E,T){var O;g?O=u[c+T]:(O=na(E,l),Array.isArray(O)?w=!0:O=[b,O]);var M=O[1]==null||g&&na(E,l)==null;return v?{x:kI({axis:r,ticks:o,bandSize:a,entry:E,index:T}),y:M?null:i.scale(O[1]),value:O,payload:E}:{x:M?null:r.scale(O[1]),y:kI({axis:i,ticks:s,bandSize:a,entry:E,index:T}),value:O,payload:E}}),C;return g||w?C=S.map(function(E){var T=Array.isArray(E.value)?E.value[0]:null;return v?{x:E.x,y:T!=null&&E.y!=null?i.scale(T):null}:{x:T!=null?r.scale(T):null,y:E.y}}):C=v?i.scale(b):r.scale(b),Kp({points:S,baseLine:C,layout:m,isRange:w},h)});gd(qg,"renderDotItem",function(e,t){var n;if(we.isValidElement(e))n=we.cloneElement(e,t);else if(yn(e))n=e(t);else{var r=Hn("recharts-area-dot",typeof e!="boolean"?e.className:""),i=t.key,o=qIe(t,G8t);n=we.createElement(TD,uy({},o,{key:i,className:r}))}return n});function Cw(e){"@babel/helpers - typeof";return Cw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Cw(e)}function n$t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r$t(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,QIe(r.key),r)}}function i$t(e,t,n){return t&&r$t(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function o$t(e,t,n){return t=WI(t),s$t(e,YIe()?Reflect.construct(t,n||[],WI(e).constructor):t.apply(e,n))}function s$t(e,t){if(t&&(Cw(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return a$t(e)}function a$t(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function YIe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(YIe=function(){return!!e})()}function WI(e){return WI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},WI(e)}function l$t(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&DW(e,t)}function DW(e,t){return DW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},DW(e,t)}function XIe(e,t,n){return t=QIe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function QIe(e){var t=u$t(e,"string");return Cw(t)=="symbol"?t:t+""}function u$t(e,t){if(Cw(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Cw(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function $W(){return $W=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},$W.apply(this,arguments)}function c$t(e){var t=e.xAxisId,n=yQ(),r=bQ(),i=_Ie(t);return i==null?null:A.createElement(gS,$W({},i,{className:Hn("recharts-".concat(i.axisType," ").concat(i.axisType),i.className),viewBox:{x:0,y:0,width:n,height:r},ticksGenerator:function(s){return gh(s,!0)}}))}var cg=(function(e){function t(){return n$t(this,t),o$t(this,t,arguments)}return l$t(t,e),i$t(t,[{key:"render",value:function(){return A.createElement(c$t,this.props)}}])})(A.Component);XIe(cg,"displayName","XAxis");XIe(cg,"defaultProps",{allowDecimals:!0,hide:!1,orientation:"bottom",width:0,height:30,mirror:!1,xAxisId:0,tickCount:5,type:"category",padding:{left:0,right:0},allowDataOverflow:!1,scale:"auto",reversed:!1,allowDuplicatedCategory:!0});function Ew(e){"@babel/helpers - typeof";return Ew=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ew(e)}function d$t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function f$t(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,ePe(r.key),r)}}function h$t(e,t,n){return t&&f$t(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function p$t(e,t,n){return t=qI(t),m$t(e,ZIe()?Reflect.construct(t,n||[],qI(e).constructor):t.apply(e,n))}function m$t(e,t){if(t&&(Ew(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return g$t(e)}function g$t(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ZIe(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(ZIe=function(){return!!e})()}function qI(e){return qI=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},qI(e)}function y$t(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&zW(e,t)}function zW(e,t){return zW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},zW(e,t)}function JIe(e,t,n){return t=ePe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ePe(e){var t=b$t(e,"string");return Ew(t)=="symbol"?t:t+""}function b$t(e,t){if(Ew(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(Ew(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function FW(){return FW=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},FW.apply(this,arguments)}var v$t=function(t){var n=t.yAxisId,r=yQ(),i=bQ(),o=NIe(n);return o==null?null:A.createElement(gS,FW({},o,{className:Hn("recharts-".concat(o.axisType," ").concat(o.axisType),o.className),viewBox:{x:0,y:0,width:r,height:i},ticksGenerator:function(a){return gh(a,!0)}}))},dg=(function(e){function t(){return d$t(this,t),p$t(this,t,arguments)}return y$t(t,e),h$t(t,[{key:"render",value:function(){return A.createElement(v$t,this.props)}}])})(A.Component);JIe(dg,"displayName","YAxis");JIe(dg,"defaultProps",{allowDuplicatedCategory:!0,allowDecimals:!0,hide:!1,orientation:"left",width:60,height:0,mirror:!1,yAxisId:0,tickCount:5,type:"number",padding:{top:0,bottom:0},allowDataOverflow:!1,scale:"auto",reversed:!1});function Xge(e){return k$t(e)||S$t(e)||w$t(e)||x$t()}function x$t(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
2910
2910
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function w$t(e,t){if(e){if(typeof e=="string")return BW(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return BW(e,t)}}function S$t(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function k$t(e){if(Array.isArray(e))return BW(e)}function BW(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var HW=function(t,n,r,i,o){var s=lu(t,xQ),a=lu(t,_D),l=[].concat(Xge(s),Xge(a)),u=lu(t,LD),c="".concat(i,"Id"),d=i[0],h=n;if(l.length&&(h=l.reduce(function(b,v){if(v.props[c]===r&&Ed(v.props,"extendDomain")&&ft(v.props[d])){var w=v.props[d];return[Math.min(b[0],w),Math.max(b[1],w)]}return b},h)),u.length){var m="".concat(d,"1"),g="".concat(d,"2");h=u.reduce(function(b,v){if(v.props[c]===r&&Ed(v.props,"extendDomain")&&ft(v.props[m])&&ft(v.props[g])){var w=v.props[m],S=v.props[g];return[Math.min(b[0],w,S),Math.max(b[1],w,S)]}return b},h)}return o&&o.length&&(h=o.reduce(function(b,v){return ft(v)?[Math.min(b[0],v),Math.max(b[1],v)]:b},h)),h},UB={exports:{}},Qge;function C$t(){return Qge||(Qge=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(l,u,c){this.fn=l,this.context=u,this.once=c||!1}function o(l,u,c,d,h){if(typeof c!="function")throw new TypeError("The listener must be a function");var m=new i(c,d||l,h),g=n?n+u:u;return l._events[g]?l._events[g].fn?l._events[g]=[l._events[g],m]:l._events[g].push(m):(l._events[g]=m,l._eventsCount++),l}function s(l,u){--l._eventsCount===0?l._events=new r:delete l._events[u]}function a(){this._events=new r,this._eventsCount=0}a.prototype.eventNames=function(){var u=[],c,d;if(this._eventsCount===0)return u;for(d in c=this._events)t.call(c,d)&&u.push(n?d.slice(1):d);return Object.getOwnPropertySymbols?u.concat(Object.getOwnPropertySymbols(c)):u},a.prototype.listeners=function(u){var c=n?n+u:u,d=this._events[c];if(!d)return[];if(d.fn)return[d.fn];for(var h=0,m=d.length,g=new Array(m);h<m;h++)g[h]=d[h].fn;return g},a.prototype.listenerCount=function(u){var c=n?n+u:u,d=this._events[c];return d?d.fn?1:d.length:0},a.prototype.emit=function(u,c,d,h,m,g){var b=n?n+u:u;if(!this._events[b])return!1;var v=this._events[b],w=arguments.length,S,C;if(v.fn){switch(v.once&&this.removeListener(u,v.fn,void 0,!0),w){case 1:return v.fn.call(v.context),!0;case 2:return v.fn.call(v.context,c),!0;case 3:return v.fn.call(v.context,c,d),!0;case 4:return v.fn.call(v.context,c,d,h),!0;case 5:return v.fn.call(v.context,c,d,h,m),!0;case 6:return v.fn.call(v.context,c,d,h,m,g),!0}for(C=1,S=new Array(w-1);C<w;C++)S[C-1]=arguments[C];v.fn.apply(v.context,S)}else{var E=v.length,T;for(C=0;C<E;C++)switch(v[C].once&&this.removeListener(u,v[C].fn,void 0,!0),w){case 1:v[C].fn.call(v[C].context);break;case 2:v[C].fn.call(v[C].context,c);break;case 3:v[C].fn.call(v[C].context,c,d);break;case 4:v[C].fn.call(v[C].context,c,d,h);break;default:if(!S)for(T=1,S=new Array(w-1);T<w;T++)S[T-1]=arguments[T];v[C].fn.apply(v[C].context,S)}}return!0},a.prototype.on=function(u,c,d){return o(this,u,c,d,!1)},a.prototype.once=function(u,c,d){return o(this,u,c,d,!0)},a.prototype.removeListener=function(u,c,d,h){var m=n?n+u:u;if(!this._events[m])return this;if(!c)return s(this,m),this;var g=this._events[m];if(g.fn)g.fn===c&&(!h||g.once)&&(!d||g.context===d)&&s(this,m);else{for(var b=0,v=[],w=g.length;b<w;b++)(g[b].fn!==c||h&&!g[b].once||d&&g[b].context!==d)&&v.push(g[b]);v.length?this._events[m]=v.length===1?v[0]:v:s(this,m)}return this},a.prototype.removeAllListeners=function(u){var c;return u?(c=n?n+u:u,this._events[c]&&s(this,c)):(this._events=new r,this._eventsCount=0),this},a.prototype.off=a.prototype.removeListener,a.prototype.addListener=a.prototype.on,a.prefixed=n,a.EventEmitter=a,e.exports=a})(UB)),UB.exports}var E$t=C$t();const T$t=cr(E$t);var VB=new T$t,WB="recharts.syncMouseEvents";function IT(e){"@babel/helpers - typeof";return IT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},IT(e)}function A$t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function O$t(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,tPe(r.key),r)}}function R$t(e,t,n){return t&&O$t(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function qB(e,t,n){return t=tPe(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function tPe(e){var t=M$t(e,"string");return IT(t)=="symbol"?t:t+""}function M$t(e,t){if(IT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(IT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var _$t=(function(){function e(){A$t(this,e),qB(this,"activeIndex",0),qB(this,"coordinateList",[]),qB(this,"layout","horizontal")}return R$t(e,[{key:"setDetails",value:function(n){var r,i=n.coordinateList,o=i===void 0?null:i,s=n.container,a=s===void 0?null:s,l=n.layout,u=l===void 0?null:l,c=n.offset,d=c===void 0?null:c,h=n.mouseHandlerCallback,m=h===void 0?null:h;this.coordinateList=(r=o??this.coordinateList)!==null&&r!==void 0?r:[],this.container=a??this.container,this.layout=u??this.layout,this.offset=d??this.offset,this.mouseHandlerCallback=m??this.mouseHandlerCallback,this.activeIndex=Math.min(Math.max(this.activeIndex,0),this.coordinateList.length-1)}},{key:"focus",value:function(){this.spoofMouse()}},{key:"keyboardEvent",value:function(n){if(this.coordinateList.length!==0)switch(n.key){case"ArrowRight":{if(this.layout!=="horizontal")return;this.activeIndex=Math.min(this.activeIndex+1,this.coordinateList.length-1),this.spoofMouse();break}case"ArrowLeft":{if(this.layout!=="horizontal")return;this.activeIndex=Math.max(this.activeIndex-1,0),this.spoofMouse();break}}}},{key:"setIndex",value:function(n){this.activeIndex=n}},{key:"spoofMouse",value:function(){var n,r;if(this.layout==="horizontal"&&this.coordinateList.length!==0){var i=this.container.getBoundingClientRect(),o=i.x,s=i.y,a=i.height,l=this.coordinateList[this.activeIndex].coordinate,u=((n=window)===null||n===void 0?void 0:n.scrollX)||0,c=((r=window)===null||r===void 0?void 0:r.scrollY)||0,d=o+l+u,h=s+this.offset.top+a/2+c;this.mouseHandlerCallback({pageX:d,pageY:h})}}}])})();function N$t(e,t,n){if(n==="number"&&t===!0&&Array.isArray(e)){var r=e==null?void 0:e[0],i=e==null?void 0:e[1];if(r&&i&&ft(r)&&ft(i))return!0}return!1}function L$t(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 nPe(e){var t=e.cx,n=e.cy,r=e.radius,i=e.startAngle,o=e.endAngle,s=ls(t,n,r,i),a=ls(t,n,r,o);return{points:[s,a],cx:t,cy:n,radius:r,startAngle:i,endAngle:o}}function I$t(e,t,n){var r,i,o,s;if(e==="horizontal")r=t.x,o=r,i=n.top,s=n.top+n.height;else if(e==="vertical")i=t.y,s=i,r=n.left,o=n.left+n.width;else if(t.cx!=null&&t.cy!=null)if(e==="centric"){var a=t.cx,l=t.cy,u=t.innerRadius,c=t.outerRadius,d=t.angle,h=ls(a,l,u,d),m=ls(a,l,c,d);r=h.x,i=h.y,o=m.x,s=m.y}else return nPe(t);return[{x:r,y:i},{x:o,y:s}]}function PT(e){"@babel/helpers - typeof";return PT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},PT(e)}function Zge(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 bM(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Zge(Object(n),!0).forEach(function(r){P$t(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Zge(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function P$t(e,t,n){return t=j$t(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function j$t(e){var t=D$t(e,"string");return PT(t)=="symbol"?t:t+""}function D$t(e,t){if(PT(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(PT(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function $$t(e){var t,n,r=e.element,i=e.tooltipEventType,o=e.isActive,s=e.activeCoordinate,a=e.activePayload,l=e.offset,u=e.activeTooltipIndex,c=e.tooltipAxisBandSize,d=e.layout,h=e.chartName,m=(t=r.props.cursor)!==null&&t!==void 0?t:(n=r.type.defaultProps)===null||n===void 0?void 0:n.cursor;if(!r||!m||!o||!s||h!=="ScatterChart"&&i!=="axis")return null;var g,b=q1;if(h==="ScatterChart")g=s,b=T5t;else if(h==="BarChart")g=L$t(d,s,l,c),b=fQ;else if(d==="radial"){var v=nPe(s),w=v.cx,S=v.cy,C=v.radius,E=v.startAngle,T=v.endAngle;g={cx:w,cy:S,startAngle:E,endAngle:T,innerRadius:C,outerRadius:C},b=lIe}else g={points:I$t(d,s,l)},b=q1;var O=bM(bM(bM(bM({stroke:"#ccc",pointerEvents:"none"},l),g),wn(m,!1)),{},{payload:a,payloadIndex:u,className:Hn("recharts-tooltip-cursor",m.className)});return A.isValidElement(m)?A.cloneElement(m,O):A.createElement(b,O)}var z$t=["item"],F$t=["children","className","width","height","style","compact","title","desc"];function Tw(e){"@babel/helpers - typeof";return Tw=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Tw(e)}function C1(){return C1=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},C1.apply(this,arguments)}function Jge(e,t){return U$t(e)||H$t(e,t)||iPe(e,t)||B$t()}function B$t(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
@@ -2939,7 +2939,7 @@ ${n.map(([o,s])=>{var l;const a=((l=s.theme)==null?void 0:l[r])||s.color;return
2939
2939
  `+ye[k].replace(" at new "," at ");return f.displayName&&ze.includes("<anonymous>")&&(ze=ze.replace("<anonymous>",f.displayName)),ze}while(1<=k&&0<=R);break}}}finally{gt=!1,Error.prepareStackTrace=x}return(x=f?f.displayName||f.name:"")?Ve(x):""}function xt(f,p){switch(f.tag){case 26:case 27:case 5:return Ve(f.type);case 16:return Ve("Lazy");case 13:return f.child!==p&&p!==null?Ve("Suspense Fallback"):Ve("Suspense");case 19:return Ve("SuspenseList");case 0:case 15:return rt(f.type,!1);case 11:return rt(f.type.render,!1);case 1:return rt(f.type,!0);case 31:return Ve("Activity");case 30:return Ve("ViewTransition");default:return""}}function $t(f){try{var p="",x=null;do p+=xt(f,x),x=f,f=f.return;while(f);return p}catch(k){return`
2940
2940
  Error generating stack: `+k.message+`
2941
2941
  `+k.stack}}var zt=Object.prototype.hasOwnProperty,vn=e.unstable_scheduleCallback,_n=e.unstable_cancelCallback,Vn=e.unstable_shouldYield,Ln=e.unstable_requestPaint,ln=e.unstable_now,mr=e.unstable_getCurrentPriorityLevel,Yn=e.unstable_ImmediatePriority,Yt=e.unstable_UserBlockingPriority,Ht=e.unstable_NormalPriority,on=e.unstable_LowPriority,Jt=e.unstable_IdlePriority,yt=e.log,pt=e.unstable_setDisableYieldValue,Fe=null,Qe=null;function ut(f){if(typeof yt=="function"&&pt(f),Qe&&typeof Qe.setStrictMode=="function")try{Qe.setStrictMode(Fe,f)}catch{}}var qt=Math.clz32?Math.clz32:sn,Vt=Math.log,it=Math.LN2;function sn(f){return f>>>=0,f===0?32:31-(Vt(f)/it|0)|0}var zn=256,er=262144,Qt=4194304;function tr(f){var p=f&42;if(p!==0)return p;switch(f&-f){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return f&-f;case 262144:case 524288:case 1048576:case 2097152:return f&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return f&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return f}}function cn(f,p,x){var k=f.pendingLanes;if(k===0)return 0;var R=0,L=f.suspendedLanes,V=f.pingedLanes;f=f.warmLanes;var oe=k&134217727;return oe!==0?(k=oe&~L,k!==0?R=tr(k):(V&=oe,V!==0?R=tr(V):x||(x=oe&~f,x!==0&&(R=tr(x))))):(oe=k&~L,oe!==0?R=tr(oe):V!==0?R=tr(V):x||(x=k&~f,x!==0&&(R=tr(x)))),R===0?0:p!==0&&p!==R&&(p&L)===0&&(L=R&-R,x=p&-p,L>=x||L===32&&(x&4194048)!==0)?p:R}function nr(f,p){return(f.pendingLanes&~(f.suspendedLanes&~f.pingedLanes)&p)===0}function bo(f,p){(p&8)!==0&&(p|=p&32);var x=f.entangledLanes;if(x!==0)for(f=f.entanglements,x&=p;0<x;){var k=31-qt(x),R=1<<k;p|=f[k],x&=~R}return p}function Mr(f,p){switch(f){case 1:case 2:case 4:case 8:case 64:return p+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return p+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function zi(){var f=Qt;return Qt<<=1,(Qt&62914560)===0&&(Qt=4194304),f}function Ms(f){for(var p=[],x=0;31>x;x++)p.push(f);return p}function Ri(f,p){f.pendingLanes|=p,p!==268435456&&(f.suspendedLanes=0,f.pingedLanes=0,f.warmLanes=0)}function La(f,p,x,k,R,L){var V=f.pendingLanes;f.pendingLanes=x,f.suspendedLanes=0,f.pingedLanes=0,f.warmLanes=0,f.expiredLanes&=x,f.entangledLanes&=x,f.errorRecoveryDisabledLanes&=x,f.shellSuspendCounter=0;var oe=f.entanglements,ye=f.expirationTimes,Ne=f.hiddenUpdates;for(x=V&~x;0<x;){var ze=31-qt(x),Ge=1<<ze;oe[ze]=0,ye[ze]=-1;var Re=Ne[ze];if(Re!==null)for(Ne[ze]=null,ze=0;ze<Re.length;ze++){var je=Re[ze];je!==null&&(je.lane&=-536870913)}x&=~Ge}k!==0&&Uo(f,k,0),L!==0&&R===0&&f.tag!==0&&(f.suspendedLanes|=L&~(V&~p))}function Uo(f,p,x){f.pendingLanes|=p,f.suspendedLanes&=~p;var k=31-qt(p);f.entangledLanes|=p,f.entanglements[k]=f.entanglements[k]|1073741824|x&261930}function vo(f,p){var x=f.entangledLanes|=p;for(f=f.entanglements;x;){var k=31-qt(x),R=1<<k;R&p|f[k]&p&&(f[k]|=p),x&=~R}}function kr(f,p){var x=p&-p;return x=(x&42)!==0?1:Ct(x),(x&(f.suspendedLanes|p))!==0?0:x}function Ct(f){switch(f){case 2:f=1;break;case 8:f=4;break;case 32:f=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:f=128;break;case 268435456:f=134217728;break;default:f=0}return f}function cs(f){return f&=-f,2<f?8<f?(f&134217727)!==0?32:268435456:8:2}function fc(){var f=se.p;return f!==0?f:(f=window.event,f===void 0?32:$te(f.type))}function pu(f,p){var x=se.p;try{return se.p=f,p()}finally{se.p=x}}var Fi=Math.random().toString(36).slice(2),Hr="__reactFiber$"+Fi,Te="__reactProps$"+Fi,Xe="__reactContainer$"+Fi,Ze="__reactEvents$"+Fi,Ft="__reactListeners$"+Fi,In="__reactHandles$"+Fi,_r="__reactResources$"+Fi,rr="__reactMarker$"+Fi,gi="__reactLoad$"+Fi;function hc(f){delete f[Hr],delete f[Te],delete f[Ft],delete f[In]}function ia(f){var p;if(p=f[Hr])return p;for(var x=f.parentNode;x;){if(p=x[Xe]||x[Hr]){if(x=p.alternate,p.child!==null||x!==null&&x.child!==null)for(f=bte(f);f!==null;){if(x=f[Hr])return x;f=bte(f)}return p}f=x,x=f.parentNode}return null}function ml(f){if(f=f[Hr]||f[Xe]){var p=f.tag;if(p===5||p===6||p===13||p===31||p===26||p===27||p===3)return f}return null}function mu(f){var p=f.tag;if(p===5||p===26||p===27||p===6)return f.stateNode;throw Error(r(33))}function ds(f){var p=f[_r];return p||(p=f[_r]={hoistableStyles:new Map,hoistableScripts:new Map}),p}function si(f){f[rr]=!0}function pc(f){f[gi]=void 0}var Ia=new Set,fs={};function ai(f,p){Pa(f,p),Pa(f+"Capture",p)}function Pa(f,p){for(fs[f]=p,f=0;f<p.length;f++)Ia.add(p[f])}var tp=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),mc={},ja={};function gu(f){return zt.call(ja,f)?!0:zt.call(mc,f)?!1:tp.test(f)?ja[f]=!0:(mc[f]=!0,!1)}var En=!1;function Gg(){var f=En;return En=!1,f}function np(f,p,x){if(gu(p))if(x===null)f.removeAttribute(p);else{switch(typeof x){case"undefined":case"function":case"symbol":f.removeAttribute(p);return;case"boolean":var k=p.toLowerCase().slice(0,5);if(k!=="data-"&&k!=="aria-"){f.removeAttribute(p);return}}f.setAttribute(p,x)}}function yu(f,p,x){if(x===null)f.removeAttribute(p);else{switch(typeof x){case"undefined":case"function":case"symbol":case"boolean":f.removeAttribute(p);return}f.setAttribute(p,x)}}function Da(f,p,x,k){if(k===null)f.removeAttribute(x);else{switch(typeof k){case"undefined":case"function":case"symbol":case"boolean":f.removeAttribute(x);return}f.setAttributeNS(p,x,k)}}function xo(f){switch(typeof f){case"bigint":case"boolean":case"number":case"string":case"undefined":return f;case"object":return f;default:return""}}function Kg(f){var p=f.type;return(f=f.nodeName)&&f.toLowerCase()==="input"&&(p==="checkbox"||p==="radio")}function vS(f,p,x){var k=Object.getOwnPropertyDescriptor(f.constructor.prototype,p);if(!f.hasOwnProperty(p)&&typeof k<"u"&&typeof k.get=="function"&&typeof k.set=="function"){var R=k.get,L=k.set;return Object.defineProperty(f,p,{configurable:!0,get:function(){return R.call(this)},set:function(V){x=""+V,L.call(this,V)}}),Object.defineProperty(f,p,{enumerable:k.enumerable}),{getValue:function(){return x},setValue:function(V){x=""+V},stopTracking:function(){f._valueTracker=null,delete f[p]}}}}function Yg(f){if(!f._valueTracker){var p=Kg(f)?"checked":"value";f._valueTracker=vS(f,p,""+f[p])}}function Xg(f){if(!f)return!1;var p=f._valueTracker;if(!p)return!0;var x=p.getValue(),k="";return f&&(k=Kg(f)?f.checked?"true":"false":f.value),f=k,f!==x?(p.setValue(f),!0):!1}var Vd=/[\n"\\]/g;function hs(f){return f.replace(Vd,function(p){return"\\"+p.charCodeAt(0).toString(16)+" "})}function rp(f,p,x,k,R,L,V,oe){f.name="",V!=null&&typeof V!="function"&&typeof V!="symbol"&&typeof V!="boolean"?f.type=V:f.removeAttribute("type"),p!=null?V==="number"?(p===0&&f.value===""||f.value!=p)&&(f.value=""+xo(p)):f.value!==""+xo(p)&&(f.value=""+xo(p)):V!=="submit"&&V!=="reset"||f.removeAttribute("value"),p!=null?V==="number"&&f.value==p?$a(f,xo(f.value)):$a(f,xo(p)):x!=null?$a(f,xo(x)):k!=null&&f.removeAttribute("value"),R==null&&L!=null&&(f.defaultChecked=!!L),R!=null&&(f.checked=R&&typeof R!="function"&&typeof R!="symbol"),oe!=null&&typeof oe!="function"&&typeof oe!="symbol"&&typeof oe!="boolean"?f.name=""+xo(oe):f.removeAttribute("name")}function Vb(f,p,x,k,R,L,V,oe){if(L!=null&&typeof L!="function"&&typeof L!="symbol"&&typeof L!="boolean"&&(f.type=L),p!=null||x!=null){if(!(L!=="submit"&&L!=="reset"||p!=null)){Yg(f);return}x=x!=null?""+xo(x):"",p=p!=null?""+xo(p):x,oe||p===f.value||(f.value=p),f.defaultValue=p}k=k??R,k=typeof k!="function"&&typeof k!="symbol"&&!!k,f.checked=oe?f.checked:!!k,f.defaultChecked=!!k,V!=null&&typeof V!="function"&&typeof V!="symbol"&&typeof V!="boolean"&&(f.name=V),Yg(f)}function $a(f,p){f.defaultValue!==""+p&&(f.defaultValue=""+p)}function gl(f,p,x,k){if(f=f.options,p){p={};for(var R=0;R<x.length;R++)p["$"+x[R]]=!0;for(x=0;x<f.length;x++)R=p.hasOwnProperty("$"+f[x].value),f[x].selected!==R&&(f[x].selected=R),R&&k&&(f[x].defaultSelected=!0)}else{for(x=""+xo(x),p=null,R=0;R<f.length;R++){if(f[R].value===x){f[R].selected=!0,k&&(f[R].defaultSelected=!0);return}p!==null||f[R].disabled||(p=f[R])}p!==null&&(p.selected=!0)}}function Wd(f,p,x){if(p!=null&&(p=""+xo(p),p!==f.value&&(f.value=p),x==null)){f.defaultValue!==p&&(f.defaultValue=p);return}f.defaultValue=x!=null?""+xo(x):""}function Qg(f,p,x,k){if(p==null){if(k!=null){if(x!=null)throw Error(r(92));if(he(k)){if(1<k.length)throw Error(r(93));k=k[0]}x=k}x==null&&(x=""),p=x}x=xo(p),f.defaultValue=x,k=f.textContent,k===x&&k!==""&&k!==null&&(f.value=k),Yg(f)}function za(f,p){if(p){var x=f.firstChild;if(x&&x===f.lastChild&&x.nodeType===3){x.nodeValue=p;return}}f.textContent=p}var Wb=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function qd(f,p,x){var k=p.indexOf("--")===0;x==null||typeof x=="boolean"||x===""?k?f.setProperty(p,""):p==="float"?f.cssFloat="":f[p]="":k?f.setProperty(p,x):typeof x!="number"||x===0||Wb.has(p)?p==="float"?f.cssFloat=x:f[p]=(""+x).trim():f[p]=x+"px"}function bu(f,p,x){if(p!=null&&typeof p!="object")throw Error(r(62));if(f=f.style,x!=null){for(var k in x)!x.hasOwnProperty(k)||p!=null&&p.hasOwnProperty(k)||(k.indexOf("--")===0?f.setProperty(k,""):k==="float"?f.cssFloat="":f[k]="",En=!0);for(var R in p)k=p[R],p.hasOwnProperty(R)&&x[R]!==k&&(qd(f,R,k),En=!0)}else for(var L in p)p.hasOwnProperty(L)&&qd(f,L,p[L])}function ip(f){if(f.indexOf("-")===-1)return!1;switch(f){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Zg=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["maskType","mask-type"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),qb=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Gd(f){return qb.test(""+f)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":f}function _s(){}var Jg=null;function e0(f){return f=f.target||f.srcElement||window,f.correspondingUseElement&&(f=f.correspondingUseElement),f.nodeType===3?f.parentNode:f}var gc=null,yc=null;function op(f){var p=ml(f);if(p&&(f=p.stateNode)){var x=f[Te]||null;e:switch(f=p.stateNode,p.type){case"input":if(rp(f,x.value,x.defaultValue,x.defaultValue,x.checked,x.defaultChecked,x.type,x.name),p=x.name,x.type==="radio"&&p!=null){for(x=f;x.parentNode;)x=x.parentNode;for(x=x.querySelectorAll('input[name="'+hs(""+p)+'"][type="radio"]'),p=0;p<x.length;p++){var k=x[p];if(k!==f&&k.form===f.form){var R=k[Te]||null;if(!R)throw Error(r(90));rp(k,R.value,R.defaultValue,R.defaultValue,R.checked,R.defaultChecked,R.type,R.name)}}for(p=0;p<x.length;p++)k=x[p],k.form===f.form&&Xg(k)}break e;case"textarea":Wd(f,x.value,x.defaultValue);break e;case"select":p=x.value,p!=null&&gl(f,!!x.multiple,p,!1)}}}var t0=!1;function n0(f,p,x){if(t0)return f(p,x);t0=!0;try{var k=f(p);return k}finally{if(t0=!1,(gc!==null||yc!==null)&&(OO(),gc&&(p=gc,f=yc,yc=gc=null,op(p),f)))for(p=0;p<f.length;p++)op(f[p])}}function Je(f,p){var x=f.stateNode;if(x===null)return null;var k=x[Te]||null;if(k===null)return null;x=k[p];e:switch(p){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(k=!k.disabled)||(f=f.type,k=!(f==="button"||f==="input"||f==="select"||f==="textarea")),f=!k;break e;default:f=!1}if(f)return null;if(x&&typeof x!="function")throw Error(r(231,p,typeof x));return x}var nt=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),en=!1;if(nt)try{var j={};Object.defineProperty(j,"passive",{get:function(){en=!0}}),window.addEventListener("test",j,j),window.removeEventListener("test",j,j)}catch{en=!1}var ee=null,ce=null,me=null;function xe(){if(me)return me;var f,p=ce,x=p.length,k,R="value"in ee?ee.value:ee.textContent,L=R.length;for(f=0;f<x&&p[f]===R[f];f++);var V=x-f;for(k=1;k<=V&&p[x-k]===R[L-k];k++);return me=R.slice(f,1<k?1-k:void 0)}function De(f){var p=f.keyCode;return"charCode"in f?(f=f.charCode,f===0&&p===13&&(f=13)):f=p,f===10&&(f=13),32<=f||f===13?f:0}function bt(){return!0}function an(){return!1}function mt(f){function p(x,k,R,L,V){this._reactName=x,this._targetInst=R,this.type=k,this.nativeEvent=L,this.target=V,this.currentTarget=null;for(var oe in f)f.hasOwnProperty(oe)&&(x=f[oe],this[oe]=x?x(L):L[oe]);return this.isDefaultPrevented=(L.defaultPrevented!=null?L.defaultPrevented:L.returnValue===!1)?bt:an,this.isPropagationStopped=an,this}return M(p.prototype,{preventDefault:function(){this.defaultPrevented=!0;var x=this.nativeEvent;x&&(x.preventDefault?x.preventDefault():typeof x.returnValue!="unknown"&&(x.returnValue=!1),this.isDefaultPrevented=bt)},stopPropagation:function(){var x=this.nativeEvent;x&&(x.stopPropagation?x.stopPropagation():typeof x.cancelBubble!="unknown"&&(x.cancelBubble=!0),this.isPropagationStopped=bt)},persist:function(){},isPersistent:bt}),p}var Zt={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(f){return f.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},gr=mt(Zt),Ur=M({},Zt,{view:0,detail:0}),oa=mt(Ur),yl,sp,Kd,r0=M({},Ur,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:KD,button:0,buttons:0,relatedTarget:function(f){return f.relatedTarget===void 0?f.fromElement===f.srcElement?f.toElement:f.fromElement:f.relatedTarget},movementX:function(f){return"movementX"in f?f.movementX:(f!==Kd&&(Kd&&f.type==="mousemove"?(yl=f.screenX-Kd.screenX,sp=f.screenY-Kd.screenY):sp=yl=0,Kd=f),yl)},movementY:function(f){return"movementY"in f?f.movementY:sp}}),LA=mt(r0),IDe=M({},r0,{dataTransfer:0}),PDe=mt(IDe),jDe=M({},Ur,{relatedTarget:0}),GD=mt(jDe),DDe=M({},Zt,{animationName:0,elapsedTime:0,pseudoElement:0}),$De=mt(DDe),zDe=M({},Zt,{clipboardData:function(f){return"clipboardData"in f?f.clipboardData:window.clipboardData}}),FDe=mt(zDe),BDe=M({},Zt,{data:0}),JQ=mt(BDe),HDe={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},UDe={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},VDe={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function WDe(f){var p=this.nativeEvent;return p.getModifierState?p.getModifierState(f):(f=VDe[f])?!!p[f]:!1}function KD(){return WDe}var qDe=M({},Ur,{key:function(f){if(f.key){var p=HDe[f.key]||f.key;if(p!=="Unidentified")return p}return f.type==="keypress"?(f=De(f),f===13?"Enter":String.fromCharCode(f)):f.type==="keydown"||f.type==="keyup"?UDe[f.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:KD,charCode:function(f){return f.type==="keypress"?De(f):0},keyCode:function(f){return f.type==="keydown"||f.type==="keyup"?f.keyCode:0},which:function(f){return f.type==="keypress"?De(f):f.type==="keydown"||f.type==="keyup"?f.keyCode:0}}),GDe=mt(qDe),KDe=M({},r0,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),eZ=mt(KDe),YDe=M({},Zt,{submitter:0}),XDe=mt(YDe),QDe=M({},Ur,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:KD}),ZDe=mt(QDe),JDe=M({},Zt,{propertyName:0,elapsedTime:0,pseudoElement:0}),e3e=mt(JDe),t3e=M({},r0,{deltaX:function(f){return"deltaX"in f?f.deltaX:"wheelDeltaX"in f?-f.wheelDeltaX:0},deltaY:function(f){return"deltaY"in f?f.deltaY:"wheelDeltaY"in f?-f.wheelDeltaY:"wheelDelta"in f?-f.wheelDelta:0},deltaZ:0,deltaMode:0}),n3e=mt(t3e),r3e=M({},Zt,{newState:0,oldState:0,source:0}),i3e=mt(r3e),o3e=[9,13,27,32],YD=nt&&"CompositionEvent"in window,xS=null;nt&&"documentMode"in document&&(xS=document.documentMode);var s3e=nt&&"TextEvent"in window&&!xS,tZ=nt&&(!YD||xS&&8<xS&&11>=xS),nZ=" ",rZ=!1;function iZ(f,p){switch(f){case"keyup":return o3e.indexOf(p.keyCode)!==-1;case"keydown":return p.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function oZ(f){return f=f.detail,typeof f=="object"&&"data"in f?f.data:null}var Gb=!1;function a3e(f,p){switch(f){case"compositionend":return oZ(p);case"keypress":return p.which!==32?null:(rZ=!0,nZ);case"textInput":return f=p.data,f===nZ&&rZ?null:f;default:return null}}function l3e(f,p){if(Gb)return f==="compositionend"||!YD&&iZ(f,p)?(f=xe(),me=ce=ee=null,Gb=!1,f):null;switch(f){case"paste":return null;case"keypress":if(!(p.ctrlKey||p.altKey||p.metaKey)||p.ctrlKey&&p.altKey){if(p.char&&1<p.char.length)return p.char;if(p.which)return String.fromCharCode(p.which)}return null;case"compositionend":return tZ&&p.locale!=="ko"?null:p.data;default:return null}}var u3e={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function sZ(f){var p=f&&f.nodeName&&f.nodeName.toLowerCase();return p==="input"?!!u3e[f.type]:p==="textarea"}function aZ(f,p,x,k){gc?yc?yc.push(k):yc=[k]:gc=k,p=IO(p,"onChange"),0<p.length&&(x=new gr("onChange","change",null,x,k),f.push({event:x,listeners:p}))}var wS=null,SS=null;function c3e(f){Kee(f,0)}function IA(f){var p=mu(f);if(Xg(p))return f}function lZ(f,p){if(f==="change")return p}var uZ=!1;if(nt){var XD;if(nt){var QD="oninput"in document;if(!QD){var cZ=document.createElement("div");cZ.setAttribute("oninput","return;"),QD=typeof cZ.oninput=="function"}XD=QD}else XD=!1;uZ=XD&&(!document.documentMode||9<document.documentMode)}function dZ(){wS&&(wS.detachEvent("onpropertychange",fZ),SS=wS=null)}function fZ(f){if(f.propertyName==="value"&&IA(SS)){var p=[];aZ(p,SS,f,e0(f)),n0(c3e,p)}}function d3e(f,p,x){f==="focusin"?(dZ(),wS=p,SS=x,wS.attachEvent("onpropertychange",fZ)):f==="focusout"&&dZ()}function f3e(f){if(f==="selectionchange"||f==="keyup"||f==="keydown")return IA(SS)}function h3e(f,p){if(f==="click")return IA(p)}function p3e(f,p){if(f==="input"||f==="change")return IA(p)}function m3e(f,p){return f===p&&(f!==0||1/f===1/p)||f!==f&&p!==p}var Fa=typeof Object.is=="function"?Object.is:m3e;function kS(f,p){if(Fa(f,p))return!0;if(typeof f!="object"||f===null||typeof p!="object"||p===null)return!1;var x=Object.keys(f),k=Object.keys(p);if(x.length!==k.length)return!1;for(k=0;k<x.length;k++){var R=x[k];if(!zt.call(p,R)||!Fa(f[R],p[R]))return!1}return!0}function ZD(f){if(f=f||(typeof document<"u"?document:void 0),typeof f>"u")return null;try{return f.activeElement||f.body}catch{return f.body}}function hZ(f){for(;f&&f.firstChild;)f=f.firstChild;return f}function pZ(f,p){var x=hZ(f);f=0;for(var k;x;){if(x.nodeType===3){if(k=f+x.textContent.length,f<=p&&k>=p)return{node:x,offset:p-f};f=k}e:{for(;x;){if(x.nextSibling){x=x.nextSibling;break e}x=x.parentNode}x=void 0}x=hZ(x)}}function mZ(f,p){return f&&p?f===p?!0:f&&f.nodeType===3?!1:p&&p.nodeType===3?mZ(f,p.parentNode):"contains"in f?f.contains(p):f.compareDocumentPosition?!!(f.compareDocumentPosition(p)&16):!1:!1}function gZ(f){f=f!=null&&f.ownerDocument!=null&&f.ownerDocument.defaultView!=null?f.ownerDocument.defaultView:window;for(var p=ZD(f.document);p instanceof f.HTMLIFrameElement;){try{var x=typeof p.contentWindow.location.href=="string"}catch{x=!1}if(x)f=p.contentWindow;else break;p=ZD(f.document)}return p}function JD(f){var p=f&&f.nodeName&&f.nodeName.toLowerCase();return p&&(p==="input"&&(f.type==="text"||f.type==="search"||f.type==="tel"||f.type==="url"||f.type==="password")||p==="textarea"||f.contentEditable==="true")}var g3e=nt&&"documentMode"in document&&11>=document.documentMode,Kb=null,e3=null,CS=null,t3=!1;function yZ(f,p,x){var k=x.window===x?x.document:x.nodeType===9?x:x.ownerDocument;t3||Kb==null||Kb!==ZD(k)||(k=Kb,"selectionStart"in k&&JD(k)?k={start:k.selectionStart,end:k.selectionEnd}:(k=(k.ownerDocument&&k.ownerDocument.defaultView||window).getSelection(),k={anchorNode:k.anchorNode,anchorOffset:k.anchorOffset,focusNode:k.focusNode,focusOffset:k.focusOffset}),CS&&kS(CS,k)||(CS=k,k=IO(e3,"onSelect"),0<k.length&&(p=new gr("onSelect","select",null,p,x),f.push({event:p,listeners:k}),p.target=Kb)))}function i0(f,p){var x={};return x[f.toLowerCase()]=p.toLowerCase(),x["Webkit"+f]="webkit"+p,x["Moz"+f]="moz"+p,x}var Yb={animationend:i0("Animation","AnimationEnd"),animationiteration:i0("Animation","AnimationIteration"),animationstart:i0("Animation","AnimationStart"),transitionrun:i0("Transition","TransitionRun"),transitionstart:i0("Transition","TransitionStart"),transitioncancel:i0("Transition","TransitionCancel"),transitionend:i0("Transition","TransitionEnd")},n3={},bZ={};nt&&(bZ=document.createElement("div").style,"AnimationEvent"in window||(delete Yb.animationend.animation,delete Yb.animationiteration.animation,delete Yb.animationstart.animation),"TransitionEvent"in window||delete Yb.transitionend.transition);function o0(f){if(n3[f])return n3[f];if(!Yb[f])return f;var p=Yb[f],x;for(x in p)if(p.hasOwnProperty(x)&&x in bZ)return n3[f]=p[x];return f}var vZ=o0("animationend"),xZ=o0("animationiteration"),wZ=o0("animationstart"),y3e=o0("transitionrun"),b3e=o0("transitionstart"),v3e=o0("transitioncancel"),SZ=o0("transitionend"),kZ=new Map,r3="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error fullscreenChange fullscreenError gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");r3.push("scrollEnd");function vu(f,p){kZ.set(f,p),ai(p,[f])}var x3e=0;function Yd(f,p){if(f.name!=null&&f.name!=="auto")return f.name;if(p.autoName!==null)return p.autoName;f=ku.identifierPrefix;var x=x3e++;return f="_"+f+"t_"+x.toString(32)+"_",p.autoName=f}function CZ(f){if(f==null||typeof f=="string")return f;var p=null,x=mv;if(x!==null)for(var k=0;k<x.length;k++){var R=f[x[k]];if(R!=null){if(R==="none")return"none";p=p==null?R:p+(" "+R)}}return p??f.default}function Xd(f,p){return f=CZ(f),p=CZ(p),p==null?f==="auto"?null:f:p==="auto"?null:p}var PA=typeof reportError=="function"?reportError:function(f){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var p=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof f=="object"&&f!==null&&typeof f.message=="string"?String(f.message):String(f),error:f});if(!window.dispatchEvent(p))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",f);return}console.error(f)},bl=[],Xb=0,i3=0;function jA(){for(var f=Xb,p=i3=Xb=0;p<f;){var x=bl[p];bl[p++]=null;var k=bl[p];bl[p++]=null;var R=bl[p];bl[p++]=null;var L=bl[p];if(bl[p++]=null,k!==null&&R!==null){var V=k.pending;V===null?R.next=R:(R.next=V.next,V.next=R),k.pending=R}L!==0&&EZ(x,R,L)}}function DA(f,p,x,k){bl[Xb++]=f,bl[Xb++]=p,bl[Xb++]=x,bl[Xb++]=k,i3|=k,f.lanes|=k,f=f.alternate,f!==null&&(f.lanes|=k)}function o3(f,p,x,k){return DA(f,p,x,k),$A(f)}function s0(f,p){return DA(f,null,null,p),$A(f)}function EZ(f,p,x){f.lanes|=x;var k=f.alternate;k!==null&&(k.lanes|=x);for(var R=!1,L=f.return;L!==null;)L.childLanes|=x,k=L.alternate,k!==null&&(k.childLanes|=x),L.tag===22&&(f=L.stateNode,f===null||f._visibility&1||(R=!0)),f=L,L=L.return;return f.tag===3?(L=f.stateNode,R&&p!==null&&(R=31-qt(x),f=L.hiddenUpdates,k=f[R],k===null?f[R]=[p]:k.push(p),p.lane=x|536870912),L):null}function $A(f){if(50<qS)throw qS=0,AO=null,Error(r(185));for(var p=f.return;p!==null;)f=p,p=f.return;return f.tag===3?f.stateNode:null}var Qb={};function w3e(f,p,x,k){this.tag=f,this.key=x,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=p,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=k,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function sa(f,p,x,k){return new w3e(f,p,x,k)}function s3(f){return f=f.prototype,!(!f||!f.isReactComponent)}function Qd(f,p){var x=f.alternate;return x===null?(x=sa(f.tag,p,f.key,f.mode),x.elementType=f.elementType,x.type=f.type,x.stateNode=f.stateNode,x.alternate=f,f.alternate=x):(x.pendingProps=p,x.type=f.type,x.flags=0,x.subtreeFlags=0,x.deletions=null),x.flags=f.flags&1206910976,x.childLanes=f.childLanes,x.lanes=f.lanes,x.child=f.child,x.memoizedProps=f.memoizedProps,x.memoizedState=f.memoizedState,x.updateQueue=f.updateQueue,p=f.dependencies,x.dependencies=p===null?null:{lanes:p.lanes,firstContext:p.firstContext},x.sibling=f.sibling,x.index=f.index,x.ref=f.ref,x.refCleanup=f.refCleanup,x}function TZ(f,p){f.flags&=1206910978;var x=f.alternate;return x===null?(f.childLanes=0,f.lanes=p,f.child=null,f.subtreeFlags=0,f.memoizedProps=null,f.memoizedState=null,f.updateQueue=null,f.dependencies=null,f.stateNode=null):(f.childLanes=x.childLanes,f.lanes=x.lanes,f.child=x.child,f.subtreeFlags=0,f.deletions=null,f.memoizedProps=x.memoizedProps,f.memoizedState=x.memoizedState,f.updateQueue=x.updateQueue,f.type=x.type,p=x.dependencies,f.dependencies=p===null?null:{lanes:p.lanes,firstContext:p.firstContext}),f}function zA(f,p,x,k,R,L){var V=0;if(k=f,typeof k=="function")s3(k)&&(V=1);else if(typeof k=="string")V=Y5e(f,x,Oe.current)?26:f==="html"||f==="head"||f==="body"?27:5;else e:switch(k){case Q:return f=sa(31,x,p,R),f.elementType=Q,f.lanes=L,f;case P:return a0(x.children,R,L,p);case F:V=8,R|=24;break;case z:return f=sa(12,x,p,R|2),f.elementType=z,f.lanes=L,f;case U:return f=sa(13,x,p,R),f.elementType=U,f.lanes=L,f;case W:return f=sa(19,x,p,R),f.elementType=W,f.lanes=L,f;case G:case K:return f=R|32,f=sa(30,x,p,f),f.elementType=K,f.lanes=L,f.stateNode={autoName:null,paired:null,clones:null,ref:null},f;default:if(typeof k=="object"&&k!==null)switch(k.$$typeof){case B:V=10;break e;case $:V=9;break e;case H:V=11;break e;case q:V=14;break e;case Y:V=16,k=null;break e}V=29,x=Error(r(130,f===null?"null":typeof f,"")),k=null}return p=sa(V,x,p,R),p.elementType=f,p.type=k,p.lanes=L,p}function a0(f,p,x,k){return f=sa(7,f,k,p),f.lanes=x,f}function a3(f,p,x){return f=sa(6,f,null,p),f.lanes=x,f}function AZ(f){var p=sa(18,null,null,0);return p.stateNode=f,p}function l3(f,p,x){return p=sa(4,f.children!==null?f.children:[],f.key,p),p.lanes=x,p.stateNode={containerInfo:f.containerInfo,pendingChildren:null,implementation:f.implementation},p}var OZ=new WeakMap;function vl(f,p){if(typeof f=="object"&&f!==null){var x=OZ.get(f);return x!==void 0?x:(p={value:f,source:p,stack:$t(p)},OZ.set(f,p),p)}return{value:f,source:p,stack:$t(p)}}var Zb=[],Jb=0,FA=null,ES=0,xl=[],wl=0,ap=null,bc=1,vc="";function Zd(f,p){Zb[Jb++]=ES,Zb[Jb++]=FA,FA=f,ES=p}function RZ(f,p,x){xl[wl++]=bc,xl[wl++]=vc,xl[wl++]=ap,ap=f;var k=bc;f=vc;var R=32-qt(k)-1;k&=~(1<<R),x+=1;var L=32-qt(p)+R;if(30<L){var V=R-R%5;L=(k&(1<<V)-1).toString(32),k>>=V,R-=V,bc=1<<32-qt(p)+R|x<<R|k,vc=L+f}else bc=1<<L|x<<R|k,vc=f}function BA(f){f.return!==null&&(Zd(f,1),RZ(f,1,0))}function u3(f){for(;f===FA;)FA=Zb[--Jb],Zb[Jb]=null,ES=Zb[--Jb],Zb[Jb]=null;for(;f===ap;)ap=xl[--wl],xl[wl]=null,vc=xl[--wl],xl[wl]=null,bc=xl[--wl],xl[wl]=null}function MZ(f,p){xl[wl++]=bc,xl[wl++]=vc,xl[wl++]=ap,bc=p.id,vc=p.overflow,ap=f}var wo=null,Vr=null,Tn=!1,lp=null,Sl=!1,c3=Error(r(519));function up(f){var p=Error(r(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw TS(vl(p,f)),c3}function _Z(f){var p=f.stateNode,x=f.type,k=f.memoizedProps;switch(p[Hr]=f,p[Te]=k,x){case"dialog":jn("cancel",p),jn("close",p);break;case"iframe":case"object":case"embed":jn("load",p);break;case"video":case"audio":for(x=0;x<KS.length;x++)jn(KS[x],p);break;case"source":jn("error",p);break;case"img":case"image":case"link":jn("error",p),jn("load",p);break;case"details":jn("toggle",p);break;case"input":jn("invalid",p),Vb(p,k.value,k.defaultValue,k.checked,k.defaultChecked,k.type,k.name,!0);break;case"select":jn("invalid",p);break;case"textarea":jn("invalid",p),Qg(p,k.value,k.defaultValue,k.children)}x=k.children,typeof x!="string"&&typeof x!="number"&&typeof x!="bigint"||p.textContent===""+x||k.suppressHydrationWarning===!0||Zee(p.textContent,x)?(k.popover!=null&&(jn("beforetoggle",p),jn("toggle",p)),k.onScroll!=null&&jn("scroll",p),k.onScrollEnd!=null&&jn("scrollend",p),k.onClick!=null&&(p.onclick=_s),p=!0):p=!1,p||up(f,!0)}function HA(f){for(wo=f.return;wo;)switch(wo.tag){case 5:case 31:case 13:Sl=!1;return;case 27:case 3:Sl=!0;return;default:wo=wo.return}}function ev(f){if(f!==wo)return!1;if(!Tn)return HA(f),Tn=!0,!1;var p=f.tag,x;if((x=p!==3&&p!==27)&&((x=p===5)&&(x=f.type,x=!(x!=="form"&&x!=="button")||F5(f.type,f.memoizedProps)),x=!x),x&&Vr&&up(f),HA(f),p===13){if(f=f.memoizedState,f=f!==null?f.dehydrated:null,!f)throw Error(r(317));Vr=yte(f)}else if(p===31){if(f=f.memoizedState,f=f!==null?f.dehydrated:null,!f)throw Error(r(317));Vr=yte(f)}else p===27?(p=Vr,Ep(f.type)?(f=Y5,Y5=null,Vr=f):Vr=p):Vr=wo?Cl(f.stateNode.nextSibling):null;return!0}function l0(){Vr=wo=null,Tn=!1}function d3(){var f=lp;return f!==null&&(ua===null?ua=f:ua.push.apply(ua,f),lp=null),f}function TS(f){lp===null?lp=[f]:lp.push(f)}var f3=ke(null),u0=null,Jd=null;function cp(f,p,x){Be(f3,p._currentValue),p._currentValue=x}function ef(f){f._currentValue=f3.current,Ie(f3)}function UA(f,p,x){for(;f!==null;){var k=f.alternate;if((f.childLanes&p)!==p?(f.childLanes|=p,k!==null&&(k.childLanes|=p)):k!==null&&(k.childLanes&p)!==p&&(k.childLanes|=p),f===x)break;f=f.return}}function h3(f,p,x,k){var R=f.child;for(R!==null&&(R.return=f);R!==null;){var L=R.dependencies;if(L!==null){var V=R.child;L=L.firstContext;e:for(;L!==null;){var oe=L;L=R;for(var ye=0;ye<p.length;ye++)if(oe.context===p[ye]){L.lanes|=x,oe=L.alternate,oe!==null&&(oe.lanes|=x),UA(L.return,x,f),k||(V=null);break e}L=oe.next}}else if(R.tag===18){if(V=R.return,V===null)throw Error(r(341));V.lanes|=x,L=V.alternate,L!==null&&(L.lanes|=x),UA(V,x,f),V=null}else R.tag===13&&R.memoizedState!==null&&R.memoizedState.dehydrated===null?(R.lanes|=x,V=R.alternate,V!==null&&(V.lanes|=x),UA(R.return,x,f),V=R.child,V=V!==null?V.sibling:null):V=R.child;if(V!==null)V.return=R;else for(V=R;V!==null;){if(V===f){V=null;break}if(R=V.sibling,R!==null){R.return=V.return,V=R;break}V=V.return}R=V}}function c0(f,p,x,k){f=null;for(var R=p,L=!1;R!==null;){if(!L){if((R.flags&524288)!==0)L=!0;else if((R.flags&262144)!==0)break}if(R.tag===10){var V=R.alternate;if(V===null)throw Error(r(387));if(V=V.memoizedProps,V!==null){var oe=R.type;Fa(R.pendingProps.value,V.value)||(f!==null?f.push(oe):f=[oe])}}else if(R===$e.current){if(V=R.alternate,V===null)throw Error(r(387));V.memoizedState.memoizedState!==R.memoizedState.memoizedState&&(f!==null?f.push(Ev):f=[Ev])}R=R.return}return f!==null&&h3(p,f,x,k),p.flags|=262144,f!==null}function VA(f){for(f=f.firstContext;f!==null;){if(!Fa(f.context._currentValue,f.memoizedValue))return!0;f=f.next}return!1}function d0(f){u0=f,Jd=null,f=f.dependencies,f!==null&&(f.firstContext=null)}function Vo(f){return NZ(u0,f)}function WA(f,p){return u0===null&&d0(f),NZ(f,p)}function NZ(f,p){var x=p._currentValue;if(p={context:p,memoizedValue:x,next:null},Jd===null){if(f===null)throw Error(r(308));Jd=p,f.dependencies={lanes:0,firstContext:p},f.flags|=524288}else Jd=Jd.next=p;return x}var S3e=typeof AbortController<"u"?AbortController:function(){var f=[],p=this.signal={aborted:!1,addEventListener:function(x,k){f.push(k)}};this.abort=function(){p.aborted=!0,f.forEach(function(x){return x()})}},k3e=e.unstable_scheduleCallback,C3e=e.unstable_NormalPriority,Bi={$$typeof:B,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function p3(){return{controller:new S3e,data:new Map,refCount:0}}function AS(f){f.refCount--,f.refCount===0&&k3e(C3e,function(){f.controller.abort()})}function LZ(f,p){if((f.pendingLanes&4194048)!==0){var x=f.transitionTypes;for(x===null&&(x=f.transitionTypes=[]),f=0;f<p.length;f++){var k=p[f];x.indexOf(k)===-1&&x.push(k)}}}var OS=null;function E3e(f){var p=f.transitionTypes;return f.transitionTypes=null,p}var RS=null,m3=0,f0=0,tv=null;function T3e(f,p){if(RS===null){var x=RS=[];m3=0,f0=_5(),tv={status:"pending",value:void 0,then:function(k){x.push(k)}}}return m3++,p.then(IZ,IZ),p}function IZ(){if(--m3===0&&(OS=null,RS!==null)){tv!==null&&(tv.status="fulfilled");var f=RS;RS=null,f0=0,tv=null;for(var p=0;p<f.length;p++)(0,f[p])()}}function A3e(f,p){var x=[],k={status:"pending",value:null,reason:null,then:function(R){x.push(R)}};return f.then(function(){k.status="fulfilled",k.value=p;for(var R=0;R<x.length;R++)(0,x[R])(p)},function(R){for(k.status="rejected",k.reason=R,R=0;R<x.length;R++)(0,x[R])(void 0)}),k}var PZ=fe.S;fe.S=function(f,p){if(Aee=ln(),typeof p=="object"&&p!==null&&typeof p.then=="function"&&T3e(f,p),OS!==null)for(var x=vv;x!==null;)LZ(x,OS),x=x.next;if(x=f.types,x!==null){for(var k=vv;k!==null;)LZ(k,x),k=k.next;if(f0!==0){k=OS,k===null&&(k=OS=[]);for(var R=0;R<x.length;R++){var L=x[R];k.indexOf(L)===-1&&k.push(L)}}}PZ!==null&&PZ(f,p)};var h0=ke(null);function g3(){var f=h0.current;return f!==null?f:$r.pooledCache}function qA(f,p){p===null?Be(h0,h0.current):Be(h0,p.pool)}function jZ(){var f=g3();return f===null?null:{parent:Bi._currentValue,pool:f}}var nv=Error(r(460)),y3=Error(r(474)),GA=Error(r(542)),KA={then:function(){}};function DZ(f){return f=f.status,f==="fulfilled"||f==="rejected"}function $Z(f,p,x){switch(x=f[x],x===void 0?f.push(p):x!==p&&(p.then(_s,_s),p=x),p.status){case"fulfilled":return p.value;case"rejected":throw f=p.reason,FZ(f),f===void 0&&!("reason"in p)?Error(r(600)):f;default:if(typeof p.status=="string")p.then(_s,_s);else{if(f=$r,f!==null&&100<f.shellSuspendCounter)throw Error(r(482));f=p,f.status="pending",f.then(function(k){if(p.status==="pending"){var R=p;R.status="fulfilled",R.value=k}},function(k){if(p.status==="pending"){var R=p;R.status="rejected",R.reason=k}})}switch(p.status){case"fulfilled":return p.value;case"rejected":throw f=p.reason,FZ(f),f}throw m0=p,nv}}function p0(f){try{var p=f._init;return p(f._payload)}catch(x){throw x!==null&&typeof x=="object"&&typeof x.then=="function"?(m0=x,nv):x}}var m0=null;function zZ(){if(m0===null)throw Error(r(459));var f=m0;return m0=null,f}function FZ(f){if(f===nv||f===GA)throw Error(r(483))}var rv=null,MS=0;function YA(f){var p=MS;return MS+=1,rv===null&&(rv=[]),$Z(rv,f,p)}function dp(f,p){p=p.props.ref,f.ref=p!==void 0?p:null}function XA(f,p){throw p.$$typeof===N?Error(r(525)):(f=Object.prototype.toString.call(p),Error(r(31,f==="[object Object]"?"object with keys {"+Object.keys(p).join(", ")+"}":f)))}function BZ(f){function p(Me,Ce){if(f){var Pe=Me.deletions;Pe===null?(Me.deletions=[Ce],Me.flags|=16):Pe.push(Ce)}}function x(Me,Ce){if(!f)return null;for(;Ce!==null;)p(Me,Ce),Ce=Ce.sibling;return null}function k(Me){for(var Ce=new Map;Me!==null;)Me.key===null?Ce.set(Me.index,Me):Ce.set(Me.key,Me),Me=Me.sibling;return Ce}function R(Me,Ce){return Me=Qd(Me,Ce),Me.index=0,Me.sibling=null,Me}function L(Me,Ce,Pe){return Me.index=Pe,f?(Pe=Me.alternate,Pe!==null?(Pe=Pe.index,Pe<Ce?(Me.flags|=2,Ce):Pe):(Me.flags|=134217730,Ce)):(Me.flags|=1048576,Ce)}function V(Me){return f&&Me.alternate===null&&(Me.flags|=134217730),Me}function oe(Me,Ce,Pe,qe){return Ce===null||Ce.tag!==6?(Ce=a3(Pe,Me.mode,qe),Ce.return=Me,Ce):(Ce=R(Ce,Pe),Ce.return=Me,Ce)}function ye(Me,Ce,Pe,qe){var Tt=Pe.type;return Tt===P?(Me=ze(Me,Ce,Pe.props.children,qe,Pe.key),dp(Me,Pe),Me):Ce!==null&&(Ce.elementType===Tt||typeof Tt=="object"&&Tt!==null&&Tt.$$typeof===Y&&p0(Tt)===Ce.type)?(Ce=R(Ce,Pe.props),dp(Ce,Pe),Ce.return=Me,Ce):(Ce=zA(Pe.type,Pe.key,Pe.props,null,Me.mode,qe),dp(Ce,Pe),Ce.return=Me,Ce)}function Ne(Me,Ce,Pe,qe){return Ce===null||Ce.tag!==4||Ce.stateNode.containerInfo!==Pe.containerInfo||Ce.stateNode.implementation!==Pe.implementation?(Ce=l3(Pe,Me.mode,qe),Ce.return=Me,Ce):(Ce=R(Ce,Pe.children||[]),Ce.return=Me,Ce)}function ze(Me,Ce,Pe,qe,Tt){return Ce===null||Ce.tag!==7?(Ce=a0(Pe,Me.mode,qe,Tt),Ce.return=Me,Ce):(Ce=R(Ce,Pe),Ce.return=Me,Ce)}function Ge(Me,Ce,Pe){if(typeof Ce=="string"&&Ce!==""||typeof Ce=="number"||typeof Ce=="bigint")return Ce=a3(""+Ce,Me.mode,Pe),Ce.return=Me,Ce;if(typeof Ce=="object"&&Ce!==null){switch(Ce.$$typeof){case I:return Pe=zA(Ce.type,Ce.key,Ce.props,null,Me.mode,Pe),dp(Pe,Ce),Pe.return=Me,Pe;case D:return Ce=l3(Ce,Me.mode,Pe),Ce.return=Me,Ce;case Y:return Ce=p0(Ce),Ge(Me,Ce,Pe)}if(he(Ce)||ue(Ce))return Ce=a0(Ce,Me.mode,Pe,null),Ce.return=Me,Ce;if(typeof Ce.then=="function")return Ge(Me,YA(Ce),Pe);if(Ce.$$typeof===B)return Ge(Me,WA(Me,Ce),Pe);XA(Me,Ce)}return null}function Re(Me,Ce,Pe,qe){var Tt=Ce!==null?Ce.key:null;if(typeof Pe=="string"&&Pe!==""||typeof Pe=="number"||typeof Pe=="bigint")return Tt!==null?null:oe(Me,Ce,""+Pe,qe);if(typeof Pe=="object"&&Pe!==null){switch(Pe.$$typeof){case I:return Pe.key===Tt?ye(Me,Ce,Pe,qe):null;case D:return Pe.key===Tt?Ne(Me,Ce,Pe,qe):null;case Y:return Pe=p0(Pe),Re(Me,Ce,Pe,qe)}if(he(Pe)||ue(Pe))return Tt!==null?null:ze(Me,Ce,Pe,qe,null);if(typeof Pe.then=="function")return Re(Me,Ce,YA(Pe),qe);if(Pe.$$typeof===B)return Re(Me,Ce,WA(Me,Pe),qe);XA(Me,Pe)}return null}function je(Me,Ce,Pe,qe,Tt){if(typeof qe=="string"&&qe!==""||typeof qe=="number"||typeof qe=="bigint")return Me=Me.get(Pe)||null,oe(Ce,Me,""+qe,Tt);if(typeof qe=="object"&&qe!==null){switch(qe.$$typeof){case I:return Me=Me.get(qe.key===null?Pe:qe.key)||null,ye(Ce,Me,qe,Tt);case D:return Me=Me.get(qe.key===null?Pe:qe.key)||null,Ne(Ce,Me,qe,Tt);case Y:return qe=p0(qe),je(Me,Ce,Pe,qe,Tt)}if(he(qe)||ue(qe))return Me=Me.get(Pe)||null,ze(Ce,Me,qe,Tt,null);if(typeof qe.then=="function")return je(Me,Ce,Pe,YA(qe),Tt);if(qe.$$typeof===B)return je(Me,Ce,Pe,WA(Ce,qe),Tt);XA(Ce,qe)}return null}function vt(Me,Ce,Pe,qe){for(var Tt=null,Bn=null,Gt=Ce,tn=Ce=0,Vi=null;Gt!==null&&tn<Pe.length;tn++){Gt.index>tn?(Vi=Gt,Gt=null):Vi=Gt.sibling;var Xn=Re(Me,Gt,Pe[tn],qe);if(Xn===null){Gt===null&&(Gt=Vi);break}f&&Gt&&Xn.alternate===null&&p(Me,Gt),Ce=L(Xn,Ce,tn),Bn===null?Tt=Xn:Bn.sibling=Xn,Bn=Xn,Gt=Vi}if(tn===Pe.length)return x(Me,Gt),Tn&&Zd(Me,tn),Tt;if(Gt===null){for(;tn<Pe.length;tn++)Gt=Ge(Me,Pe[tn],qe),Gt!==null&&(Ce=L(Gt,Ce,tn),Bn===null?Tt=Gt:Bn.sibling=Gt,Bn=Gt);return Tn&&Zd(Me,tn),Tt}for(Gt=k(Gt);tn<Pe.length;tn++)Vi=je(Gt,Me,tn,Pe[tn],qe),Vi!==null&&(f&&(Xn=Vi.alternate,Xn!==null&&Gt.delete(Xn.key===null?tn:Xn.key)),Ce=L(Vi,Ce,tn),Bn===null?Tt=Vi:Bn.sibling=Vi,Bn=Vi);return f&&Gt.forEach(function(Mp){return p(Me,Mp)}),Tn&&Zd(Me,tn),Tt}function jt(Me,Ce,Pe,qe){if(Pe==null)throw Error(r(151));for(var Tt=null,Bn=null,Gt=Ce,tn=Ce=0,Vi=null,Xn=Pe.next();Gt!==null&&!Xn.done;tn++,Xn=Pe.next()){Gt.index>tn?(Vi=Gt,Gt=null):Vi=Gt.sibling;var Mp=Re(Me,Gt,Xn.value,qe);if(Mp===null){Gt===null&&(Gt=Vi);break}f&&Gt&&Mp.alternate===null&&p(Me,Gt),Ce=L(Mp,Ce,tn),Bn===null?Tt=Mp:Bn.sibling=Mp,Bn=Mp,Gt=Vi}if(Xn.done)return x(Me,Gt),Tn&&Zd(Me,tn),Tt;if(Gt===null){for(;!Xn.done;tn++,Xn=Pe.next())Xn=Ge(Me,Xn.value,qe),Xn!==null&&(Ce=L(Xn,Ce,tn),Bn===null?Tt=Xn:Bn.sibling=Xn,Bn=Xn);return Tn&&Zd(Me,tn),Tt}for(Gt=k(Gt);!Xn.done;tn++,Xn=Pe.next())Xn=je(Gt,Me,tn,Xn.value,qe),Xn!==null&&(f&&(Vi=Xn.alternate,Vi!==null&&Gt.delete(Vi.key===null?tn:Vi.key)),Ce=L(Xn,Ce,tn),Bn===null?Tt=Xn:Bn.sibling=Xn,Bn=Xn);return f&&Gt.forEach(function(a6e){return p(Me,a6e)}),Tn&&Zd(Me,tn),Tt}function gn(Me,Ce,Pe,qe){if(typeof Pe=="object"&&Pe!==null&&Pe.type===P&&Pe.key===null&&Pe.props.ref===void 0&&(Pe=Pe.props.children),typeof Pe=="object"&&Pe!==null){switch(Pe.$$typeof){case I:e:{for(var Tt=Pe.key;Ce!==null;){if(Ce.key===Tt){if(Tt=Pe.type,Tt===P){if(Ce.tag===7){x(Me,Ce.sibling),qe=R(Ce,Pe.props.children),dp(qe,Pe),qe.return=Me,Me=qe;break e}}else if(Ce.elementType===Tt||typeof Tt=="object"&&Tt!==null&&Tt.$$typeof===Y&&p0(Tt)===Ce.type){x(Me,Ce.sibling),qe=R(Ce,Pe.props),dp(qe,Pe),qe.return=Me,Me=qe;break e}x(Me,Ce);break}else p(Me,Ce);Ce=Ce.sibling}Pe.type===P?(qe=a0(Pe.props.children,Me.mode,qe,Pe.key),dp(qe,Pe),qe.return=Me,Me=qe):(qe=zA(Pe.type,Pe.key,Pe.props,null,Me.mode,qe),dp(qe,Pe),qe.return=Me,Me=qe)}return V(Me);case D:e:{for(Tt=Pe.key;Ce!==null;){if(Ce.key===Tt)if(Ce.tag===4&&Ce.stateNode.containerInfo===Pe.containerInfo&&Ce.stateNode.implementation===Pe.implementation){x(Me,Ce.sibling),qe=R(Ce,Pe.children||[]),qe.return=Me,Me=qe;break e}else{x(Me,Ce);break}else p(Me,Ce);Ce=Ce.sibling}qe=l3(Pe,Me.mode,qe),qe.return=Me,Me=qe}return V(Me);case Y:return Pe=p0(Pe),gn(Me,Ce,Pe,qe)}if(he(Pe))return vt(Me,Ce,Pe,qe);if(ue(Pe)){if(Tt=ue(Pe),typeof Tt!="function")throw Error(r(150));return Pe=Tt.call(Pe),jt(Me,Ce,Pe,qe)}if(typeof Pe.then=="function")return gn(Me,Ce,YA(Pe),qe);if(Pe.$$typeof===B)return gn(Me,Ce,WA(Me,Pe),qe);XA(Me,Pe)}return typeof Pe=="string"&&Pe!==""||typeof Pe=="number"||typeof Pe=="bigint"?(Pe=""+Pe,Ce!==null&&Ce.tag===6?(x(Me,Ce.sibling),qe=R(Ce,Pe),qe.return=Me,Me=qe):(x(Me,Ce),qe=a3(Pe,Me.mode,qe),qe.return=Me,Me=qe),V(Me)):x(Me,Ce)}return function(Me,Ce,Pe,qe){try{MS=0;var Tt=gn(Me,Ce,Pe,qe);return rv=null,Tt}catch(Gt){if(Gt===nv||Gt===GA)throw Gt;var Bn=sa(29,Gt,null,Me.mode);return Bn.lanes=qe,Bn.return=Me,Bn}finally{}}}var g0=BZ(!0),HZ=BZ(!1),fp=!1;function b3(f){f.updateQueue={baseState:f.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function v3(f,p){f=f.updateQueue,p.updateQueue===f&&(p.updateQueue={baseState:f.baseState,firstBaseUpdate:f.firstBaseUpdate,lastBaseUpdate:f.lastBaseUpdate,shared:f.shared,callbacks:null})}function hp(f){return{lane:f,tag:0,payload:null,callback:null,next:null}}function pp(f,p,x){var k=f.updateQueue;if(k===null)return null;if(k=k.shared,(dr&2)!==0){var R=k.pending;return R===null?p.next=p:(p.next=R.next,R.next=p),k.pending=p,p=$A(f),EZ(f,null,x),p}return DA(f,k,p,x),$A(f)}function _S(f,p,x){if(p=p.updateQueue,p!==null&&(p=p.shared,(x&4194048)!==0)){var k=p.lanes;k&=f.pendingLanes,x|=k,p.lanes=x,vo(f,x)}}function x3(f,p){var x=f.updateQueue,k=f.alternate;if(k!==null&&(k=k.updateQueue,x===k)){var R=null,L=null;if(x=x.firstBaseUpdate,x!==null){do{var V={lane:x.lane,tag:x.tag,payload:x.payload,callback:null,next:null};L===null?R=L=V:L=L.next=V,x=x.next}while(x!==null);L===null?R=L=p:L=L.next=p}else R=L=p;x={baseState:k.baseState,firstBaseUpdate:R,lastBaseUpdate:L,shared:k.shared,callbacks:k.callbacks},f.updateQueue=x;return}f=x.lastBaseUpdate,f===null?x.firstBaseUpdate=p:f.next=p,x.lastBaseUpdate=p}var w3=!1;function NS(){if(w3){var f=tv;if(f!==null)throw f}}function LS(f,p,x,k){w3=!1;var R=f.updateQueue;fp=!1;var L=R.firstBaseUpdate,V=R.lastBaseUpdate,oe=R.shared.pending;if(oe!==null){R.shared.pending=null;var ye=oe,Ne=ye.next;ye.next=null,V===null?L=Ne:V.next=Ne,V=ye;var ze=f.alternate;ze!==null&&(ze=ze.updateQueue,oe=ze.lastBaseUpdate,oe!==V&&(oe===null?ze.firstBaseUpdate=Ne:oe.next=Ne,ze.lastBaseUpdate=ye))}if(L!==null){var Ge=R.baseState;V=0,ze=Ne=ye=null,oe=L;do{var Re=oe.lane&-536870913,je=Re!==oe.lane;if(je?(Fn&Re)===Re:(k&Re)===Re){Re!==0&&Re===f0&&(w3=!0),ze!==null&&(ze=ze.next={lane:0,tag:oe.tag,payload:oe.payload,callback:null,next:null});e:{var vt=f,jt=oe;Re=p;var gn=x;switch(jt.tag){case 1:if(vt=jt.payload,typeof vt=="function"){Ge=vt.call(gn,Ge,Re);break e}Ge=vt;break e;case 3:vt.flags=vt.flags&-65537|128;case 0:if(vt=jt.payload,Re=typeof vt=="function"?vt.call(gn,Ge,Re):vt,Re==null)break e;Ge=M({},Ge,Re);break e;case 2:fp=!0}}Re=oe.callback,Re!==null&&(f.flags|=64,je&&(f.flags|=8192),je=R.callbacks,je===null?R.callbacks=[Re]:je.push(Re))}else je={lane:Re,tag:oe.tag,payload:oe.payload,callback:oe.callback,next:null},ze===null?(Ne=ze=je,ye=Ge):ze=ze.next=je,V|=Re;if(oe=oe.next,oe===null){if(oe=R.shared.pending,oe===null)break;je=oe,oe=je.next,je.next=null,R.lastBaseUpdate=je,R.shared.pending=null}}while(!0);ze===null&&(ye=Ge),R.baseState=ye,R.firstBaseUpdate=Ne,R.lastBaseUpdate=ze,L===null&&(R.shared.lanes=0),wp|=V,f.lanes=V,f.memoizedState=Ge}}function UZ(f,p){if(typeof f!="function")throw Error(r(191,f));f.call(p)}function VZ(f,p){var x=f.callbacks;if(x!==null)for(f.callbacks=null,f=0;f<x.length;f++)UZ(x[f],p)}var mp=ke(null),QA=ke(0);function WZ(f,p){f=sf,Be(QA,f),Be(mp,p),sf=f|p.baseLanes}function S3(){Be(QA,sf),Be(mp,mp.current)}function k3(){sf=QA.current,Ie(mp),Ie(QA)}var Wo=ke(null),ps=null;function gp(f){var p=f.alternate;Be(qo,qo.current&1),Be(Wo,f),ps===null&&(p===null||mp.current!==null||p.memoizedState!==null)&&(ps=f)}function C3(f){Be(qo,qo.current),Be(Wo,f),ps===null&&(ps=f)}function qZ(f){f.tag===22?(Be(qo,qo.current),Be(Wo,f),ps===null&&(ps=f)):yp()}function yp(){Be(qo,qo.current),Be(Wo,Wo.current)}function Ba(f){Ie(Wo),ps===f&&(ps=null),Ie(qo)}var qo=ke(0);function IS(f,p){Be(Wo,Wo.current),Be(qo,p)}function E3(f){Ie(qo),Ie(Wo),ps===f&&(ps=null)}function ZA(f){for(var p=f;p!==null;){if(p.tag===13){var x=p.memoizedState;if(x!==null&&(x=x.dehydrated,x===null||G5(x)||K5(x)))return p}else if(p.tag===19&&p.memoizedProps.revealOrder!=="independent"){if((p.flags&128)!==0)return p}else if(p.child!==null){p.child.return=p,p=p.child;continue}if(p===f)break;for(;p.sibling===null;){if(p.return===null||p.return===f)return null;p=p.return}p.sibling.return=p.return,p=p.sibling}return null}var tf=0,mn=null,Nr=null,Hi=null,JA=!1,iv=!1,y0=!1,eO=0,PS=0,ov=null,O3e=0;function yi(){throw Error(r(321))}function T3(f,p){if(p===null)return!1;for(var x=0;x<p.length&&x<f.length;x++)if(!Fa(f[x],p[x]))return!1;return!0}function A3(f,p,x,k,R,L){return tf=L,mn=p,p.memoizedState=null,p.updateQueue=null,p.lanes=0,fe.H=f===null||f.memoizedState===null?RJ:MJ,y0=!1,L=x(k,R),y0=!1,iv&&(L=KZ(p,x,k,R)),GZ(f),L}function GZ(f){fe.H=aO;var p=Nr!==null&&Nr.next!==null;if(tf=0,Hi=Nr=mn=null,JA=!1,PS=0,ov=null,p)throw Error(r(300));f===null||Ui||(f=f.dependencies,f!==null&&VA(f)&&(Ui=!0))}function KZ(f,p,x,k){mn=f;var R=0;do{if(iv&&(ov=null),PS=0,iv=!1,25<=R)throw Error(r(301));if(R+=1,Hi=Nr=null,f.updateQueue!=null){var L=f.updateQueue;L.lastEffect=null,L.events=null,L.stores=null,L.memoCache!=null&&(L.memoCache.index=0)}fe.H=j3e,L=p(x,k)}while(iv);return L}function R3e(){var f=fe.H,p=f.useState()[0];return p=typeof p.then=="function"?jS(p):p,f=f.useState()[0],(Nr!==null?Nr.memoizedState:null)!==f&&(mn.flags|=1024),p}function O3(){var f=eO!==0;return eO=0,f}function R3(f,p,x){p.updateQueue=f.updateQueue,p.flags&=-2053,f.lanes&=~x}function M3(f){if(JA){for(f=f.memoizedState;f!==null;){var p=f.queue;p!==null&&(p.pending=null),f=f.next}JA=!1}tf=0,Hi=Nr=mn=null,iv=!1,PS=eO=0,ov=null}function Ns(){var f={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Hi===null?mn.memoizedState=Hi=f:Hi=Hi.next=f,Hi}function Mi(){if(Nr===null){var f=mn.alternate;f=f!==null?f.memoizedState:null}else f=Nr.next;var p=Hi===null?mn.memoizedState:Hi.next;if(p!==null)Hi=p,Nr=f;else{if(f===null)throw mn.alternate===null?Error(r(467)):Error(r(310));Nr=f,f={memoizedState:Nr.memoizedState,baseState:Nr.baseState,baseQueue:Nr.baseQueue,queue:Nr.queue,next:null},Hi===null?mn.memoizedState=Hi=f:Hi=Hi.next=f}return Hi}function tO(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function jS(f){var p=PS;return PS+=1,ov===null&&(ov=[]),f=$Z(ov,f,p),p=mn,(Hi===null?p.memoizedState:Hi.next)===null&&(p=p.alternate,fe.H=p===null||p.memoizedState===null?RJ:MJ),f}function nO(f){if(f!==null&&typeof f=="object"){if(typeof f.then=="function")return jS(f);if(f.$$typeof===te)return;if(f.$$typeof===B)return Vo(f)}throw Error(r(438,String(f)))}function _3(f){var p=null,x=mn.updateQueue;if(x!==null&&(p=x.memoCache),p==null){var k=mn.alternate;k!==null&&(k=k.updateQueue,k!==null&&(k=k.memoCache,k!=null&&(p={data:k.data.map(function(R){return R.slice()}),index:0})))}if(p==null&&(p={data:[],index:0}),x===null&&(x=tO(),mn.updateQueue=x),x.memoCache=p,x=p.data[p.index],x===void 0)for(x=p.data[p.index]=Array(f),k=0;k<f;k++)x[k]=le;return p.index++,x}function nf(f,p){return typeof p=="function"?p(f):p}function rO(f){var p=Mi();return N3(p,Nr,f)}function N3(f,p,x){var k=f.queue;if(k===null)throw Error(r(311));k.lastRenderedReducer=x;var R=f.baseQueue,L=k.pending;if(L!==null){if(R!==null){var V=R.next;R.next=L.next,L.next=V}p.baseQueue=R=L,k.pending=null}if(L=f.baseState,R===null)f.memoizedState=L;else{p=R.next;var oe=V=null,ye=null,Ne=p,ze=!1;do{var Ge=Ne.lane&-536870913;if(Ge!==Ne.lane?(Fn&Ge)===Ge:(tf&Ge)===Ge){var Re=Ne.revertLane;if(Re===0)ye!==null&&(ye=ye.next={lane:0,revertLane:0,gesture:null,action:Ne.action,hasEagerState:Ne.hasEagerState,eagerState:Ne.eagerState,next:null}),Ge===f0&&(ze=!0);else if((tf&Re)===Re){Ne=Ne.next,Re===f0&&(ze=!0);continue}else Ge={lane:0,revertLane:Ne.revertLane,gesture:null,action:Ne.action,hasEagerState:Ne.hasEagerState,eagerState:Ne.eagerState,next:null},ye===null?(oe=ye=Ge,V=L):ye=ye.next=Ge,mn.lanes|=Re,wp|=Re;Ge=Ne.action,y0&&x(L,Ge),L=Ne.hasEagerState?Ne.eagerState:x(L,Ge)}else Re={lane:Ge,revertLane:Ne.revertLane,gesture:Ne.gesture,action:Ne.action,hasEagerState:Ne.hasEagerState,eagerState:Ne.eagerState,next:null},ye===null?(oe=ye=Re,V=L):ye=ye.next=Re,mn.lanes|=Ge,wp|=Ge;Ne=Ne.next}while(Ne!==null&&Ne!==p);if(ye===null?V=L:ye.next=oe,!Fa(L,f.memoizedState)&&(Ui=!0,ze&&(x=tv,x!==null)))throw x;f.memoizedState=L,f.baseState=V,f.baseQueue=ye,k.lastRenderedState=L}return R===null&&(k.lanes=0),[f.memoizedState,k.dispatch]}function L3(f){var p=Mi(),x=p.queue;if(x===null)throw Error(r(311));x.lastRenderedReducer=f;var k=x.dispatch,R=x.pending,L=p.memoizedState;if(R!==null){x.pending=null;var V=R=R.next;do L=f(L,V.action),V=V.next;while(V!==R);Fa(L,p.memoizedState)||(Ui=!0),p.memoizedState=L,p.baseQueue===null&&(p.baseState=L),x.lastRenderedState=L}return[L,k]}function YZ(f,p,x){var k=mn,R=Mi(),L=Tn;if(L){if(x===void 0)throw Error(r(407));x=x()}else x=p();var V=!Fa((Nr||R).memoizedState,x);if(V&&(R.memoizedState=x,Ui=!0),R=R.queue,j3(ZZ.bind(null,k,R,f),[f]),f=R.getSnapshot!==p||V||Hi!==null&&(Hi.memoizedState.tag&1)!==0,sv(f?9:8,{destroy:void 0},QZ.bind(null,k,R,x,p),null),f){if(k.flags|=2048,$r===null)throw Error(r(349));L||(tf&127)!==0||XZ(k,p,x)}return x}function XZ(f,p,x){f.flags|=16384,f={getSnapshot:p,value:x},p=mn.updateQueue,p===null?(p=tO(),mn.updateQueue=p,p.stores=[f]):(x=p.stores,x===null?p.stores=[f]:x.push(f))}function QZ(f,p,x,k){p.value=x,p.getSnapshot=k,JZ(p)&&eJ(f)}function ZZ(f,p,x){return x(function(){JZ(p)&&eJ(f)})}function JZ(f){var p=f.getSnapshot;f=f.value;try{var x=p();return!Fa(f,x)}catch{return!0}}function eJ(f){var p=s0(f,2);p!==null&&ca(p,f,2)}function I3(f){var p=Ns();if(typeof f=="function"){var x=f;if(f=x(),y0){ut(!0);try{x()}finally{ut(!1)}}}return p.memoizedState=p.baseState=f,p.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:nf,lastRenderedState:f},p}function tJ(f,p,x,k){return f.baseState=x,N3(f,Nr,typeof k=="function"?k:nf)}function M3e(f,p,x,k,R){if(sO(f))throw Error(r(485));if(f=p.action,f!==null){var L={payload:R,action:f,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(V){L.listeners.push(V)}};fe.T!==null?x(!0):L.isTransition=!1,k(L),x=p.pending,x===null?(L.next=p.pending=L,nJ(p,L)):(L.next=x.next,p.pending=x.next=L)}}function nJ(f,p){var x=p.action,k=p.payload,R=f.state;if(p.isTransition){var L=fe.T,V={};V.types=L!==null?L.types:null,fe.T=V;try{var oe=x(R,k),ye=fe.S;ye!==null&&ye(V,oe),rJ(f,p,oe)}catch(Ne){P3(f,p,Ne)}finally{L!==null&&V.types!==null&&(L.types=V.types),fe.T=L}}else try{L=x(R,k),rJ(f,p,L)}catch(Ne){P3(f,p,Ne)}}function rJ(f,p,x){x!==null&&typeof x=="object"&&typeof x.then=="function"?x.then(function(k){iJ(f,p,k)},function(k){return P3(f,p,k)}):iJ(f,p,x)}function iJ(f,p,x){p.status="fulfilled",p.value=x,oJ(p),f.state=x,p=f.pending,p!==null&&(x=p.next,x===p?f.pending=null:(x=x.next,p.next=x,nJ(f,x)))}function P3(f,p,x){var k=f.pending;if(f.pending=null,k!==null){k=k.next;do p.status="rejected",p.reason=x,oJ(p),p=p.next;while(p!==k)}f.action=null}function oJ(f){f=f.listeners;for(var p=0;p<f.length;p++)(0,f[p])()}function sJ(f,p){return p}function aJ(f,p){if(Tn){var x=$r.formState;if(x!==null){e:{var k=mn;if(Tn){if(Vr){t:{for(var R=Vr,L=Sl;R.nodeType!==8;){if(!L){R=null;break t}if(R=Cl(R.nextSibling),R===null){R=null;break t}}L=R.data,R=L==="F!"||L==="F"?R:null}if(R){Vr=Cl(R.nextSibling),k=R.data==="F!";break e}}up(k)}k=!1}k&&(p=x[0])}}return x=Ns(),x.memoizedState=x.baseState=p,k={pending:null,lanes:0,dispatch:null,lastRenderedReducer:sJ,lastRenderedState:p},x.queue=k,x=TJ.bind(null,mn,k),k.dispatch=x,k=I3(!1),L=B3.bind(null,mn,!1,k.queue),k=Ns(),R={state:p,dispatch:null,action:f,pending:null},k.queue=R,x=M3e.bind(null,mn,R,L,x),R.dispatch=x,k.memoizedState=f,[p,x,!1]}function lJ(f){var p=Mi();return uJ(p,Nr,f)}function uJ(f,p,x){if(p=N3(f,p,sJ)[0],f=rO(nf)[0],typeof p=="object"&&p!==null&&typeof p.then=="function")try{var k=jS(p)}catch(V){throw V===nv?GA:V}else k=p;p=Mi();var R=p.queue,L=R.dispatch;return x!==p.memoizedState&&(mn.flags|=2048,sv(9,{destroy:void 0},_3e.bind(null,R,x),null)),[k,L,f]}function _3e(f,p){f.action=p}function cJ(f){var p=Mi(),x=Nr;if(x!==null)return uJ(p,x,f);Mi(),p=p.memoizedState,x=Mi();var k=x.queue.dispatch;return x.memoizedState=f,[p,k,!1]}function sv(f,p,x,k){return f={tag:f,create:x,deps:k,inst:p,next:null},p=mn.updateQueue,p===null&&(p=tO(),mn.updateQueue=p),x=p.lastEffect,x===null?p.lastEffect=f.next=f:(k=x.next,x.next=f,f.next=k,p.lastEffect=f),f}function dJ(){return Mi().memoizedState}function iO(f,p,x,k){var R=Ns();mn.flags|=f,R.memoizedState=sv(1|p,{destroy:void 0},x,k===void 0?null:k)}function oO(f,p,x,k){var R=Mi();k=k===void 0?null:k;var L=R.memoizedState.inst;Nr!==null&&k!==null&&T3(k,Nr.memoizedState.deps)?R.memoizedState=sv(p,L,x,k):(mn.flags|=f,R.memoizedState=sv(1|p,L,x,k))}function fJ(f,p){iO(8390656,8,f,p)}function j3(f,p){oO(2048,8,f,p)}function N3e(f){mn.flags|=4;var p=mn.updateQueue;if(p===null)p=tO(),mn.updateQueue=p,p.events=[f];else{var x=p.events;x===null?p.events=[f]:x.push(f)}}function hJ(f){var p=Mi().memoizedState;return N3e({ref:p,nextImpl:f}),function(){if((dr&2)!==0)throw Error(r(440));return p.impl.apply(void 0,arguments)}}function pJ(f,p){return oO(4,2,f,p)}function mJ(f,p){return oO(4,4,f,p)}function gJ(f,p){if(typeof p=="function"){f=f();var x=p(f);return function(){typeof x=="function"?x():p(null)}}if(p!=null)return f=f(),p.current=f,function(){p.current=null}}function yJ(f,p,x){x=x!=null?x.concat([f]):null,oO(4,4,gJ.bind(null,p,f),x)}function D3(){}function bJ(f,p){var x=Mi();p=p===void 0?null:p;var k=x.memoizedState;return p!==null&&T3(p,k[1])?k[0]:(x.memoizedState=[f,p],f)}function vJ(f,p){var x=Mi();p=p===void 0?null:p;var k=x.memoizedState;if(p!==null&&T3(p,k[1]))return k[0];if(k=f(),y0){ut(!0);try{f()}finally{ut(!1)}}return x.memoizedState=[k,p],k}function $3(f,p,x){return x===void 0||(tf&1073741824)!==0&&(Fn&261930)===0?f.memoizedState=p:(f.memoizedState=x,f=Ree(),mn.lanes|=f,wp|=f,x)}function xJ(f,p,x,k){return Fa(x,p)?x:mp.current!==null?(f=$3(f,x,k),Fa(f,p)||(Ui=!0),f):(tf&106)===0||(tf&1073741824)!==0&&(Fn&261930)===0?(Ui=!0,f.memoizedState=x):(f=Ree(),mn.lanes|=f,wp|=f,p)}function wJ(f,p,x,k,R){var L=se.p;se.p=L!==0&&8>L?L:8;var V=fe.T,oe={};oe.types=V!==null?V.types:null,fe.T=oe,B3(f,!1,p,x);try{var ye=R(),Ne=fe.S;if(Ne!==null&&Ne(oe,ye),ye!==null&&typeof ye=="object"&&typeof ye.then=="function"){var ze=A3e(ye,k);DS(f,p,ze,Wa(f))}else DS(f,p,k,Wa(f))}catch(Ge){DS(f,p,{then:function(){},status:"rejected",reason:Ge},Wa())}finally{se.p=L,V!==null&&oe.types!==null&&(V.types=oe.types),fe.T=V}}function L3e(){}function z3(f,p,x,k){if(f.tag!==5)throw Error(r(476));var R=SJ(f).queue;wJ(f,R,p,Se,x===null?L3e:function(){return kJ(f),x(k)})}function SJ(f){var p=f.memoizedState;if(p!==null)return p;p={memoizedState:Se,baseState:Se,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:nf,lastRenderedState:Se},next:null};var x={};return p.next={memoizedState:x,baseState:x,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:nf,lastRenderedState:x},next:null},f.memoizedState=p,f=f.alternate,f!==null&&(f.memoizedState=p),p}function kJ(f){var p=SJ(f);p.next===null&&(p=f.alternate.memoizedState),DS(f,p.next.queue,{},Wa())}function F3(){return Vo(Ev)}function CJ(){return Mi().memoizedState}function EJ(){return Mi().memoizedState}function I3e(f){for(var p=f.return;p!==null;){switch(p.tag){case 24:case 3:var x=Wa();f=hp(x);var k=pp(p,f,x);k!==null&&(ca(k,p,x),_S(k,p,x)),p={cache:p3()},f.payload=p;return}p=p.return}}function P3e(f,p,x){var k=Wa();x={lane:k,revertLane:0,gesture:null,action:x,hasEagerState:!1,eagerState:null,next:null},sO(f)?AJ(p,x):(x=o3(f,p,x,k),x!==null&&(ca(x,f,k),OJ(x,p,k)))}function TJ(f,p,x){var k=Wa();DS(f,p,x,k)}function DS(f,p,x,k){var R={lane:k,revertLane:0,gesture:null,action:x,hasEagerState:!1,eagerState:null,next:null};if(sO(f))AJ(p,R);else{var L=f.alternate;if(f.lanes===0&&(L===null||L.lanes===0)&&(L=p.lastRenderedReducer,L!==null))try{var V=p.lastRenderedState,oe=L(V,x);if(R.hasEagerState=!0,R.eagerState=oe,Fa(oe,V))return DA(f,p,R,0),$r===null&&jA(),!1}catch{}finally{}if(x=o3(f,p,R,k),x!==null)return ca(x,f,k),OJ(x,p,k),!0}return!1}function B3(f,p,x,k){if(k={lane:2,revertLane:_5(),gesture:null,action:k,hasEagerState:!1,eagerState:null,next:null},sO(f)){if(p)throw Error(r(479))}else p=o3(f,x,k,2),p!==null&&ca(p,f,2)}function sO(f){var p=f.alternate;return f===mn||p!==null&&p===mn}function AJ(f,p){iv=JA=!0;var x=f.pending;x===null?p.next=p:(p.next=x.next,x.next=p),f.pending=p}function OJ(f,p,x){if((x&4194048)!==0){var k=p.lanes;k&=f.pendingLanes,x|=k,p.lanes=x,vo(f,x)}}var aO={readContext:Vo,use:nO,useCallback:yi,useContext:yi,useEffect:yi,useImperativeHandle:yi,useLayoutEffect:yi,useInsertionEffect:yi,useMemo:yi,useReducer:yi,useRef:yi,useState:yi,useDebugValue:yi,useDeferredValue:yi,useTransition:yi,useSyncExternalStore:yi,useId:yi,useHostTransitionStatus:yi,useFormState:yi,useActionState:yi,useOptimistic:yi,useMemoCache:yi,useCacheRefresh:yi,useEffectEvent:yi},RJ={readContext:Vo,use:nO,useCallback:function(f,p){return Ns().memoizedState=[f,p===void 0?null:p],f},useContext:Vo,useEffect:fJ,useImperativeHandle:function(f,p,x){x=x!=null?x.concat([f]):null,iO(4194308,4,gJ.bind(null,p,f),x)},useLayoutEffect:function(f,p){return iO(4194308,4,f,p)},useInsertionEffect:function(f,p){iO(4,2,f,p)},useMemo:function(f,p){var x=Ns();p=p===void 0?null:p;var k=f();if(y0){ut(!0);try{f()}finally{ut(!1)}}return x.memoizedState=[k,p],k},useReducer:function(f,p,x){var k=Ns();if(x!==void 0){var R=x(p);if(y0){ut(!0);try{x(p)}finally{ut(!1)}}}else R=p;return k.memoizedState=k.baseState=R,f={pending:null,lanes:0,dispatch:null,lastRenderedReducer:f,lastRenderedState:R},k.queue=f,f=f.dispatch=P3e.bind(null,mn,f),[k.memoizedState,f]},useRef:function(f){var p=Ns();return f={current:f},p.memoizedState=f},useState:function(f){f=I3(f);var p=f.queue,x=TJ.bind(null,mn,p);return p.dispatch=x,[f.memoizedState,x]},useDebugValue:D3,useDeferredValue:function(f,p){var x=Ns();return $3(x,f,p)},useTransition:function(){var f=I3(!1);return f=wJ.bind(null,mn,f.queue,!0,!1),Ns().memoizedState=f,[!1,f]},useSyncExternalStore:function(f,p,x){var k=mn,R=Ns();if(Tn){if(x===void 0)throw Error(r(407));x=x()}else{if(x=p(),$r===null)throw Error(r(349));(Fn&127)!==0||XZ(k,p,x)}R.memoizedState=x;var L={value:x,getSnapshot:p};return R.queue=L,fJ(ZZ.bind(null,k,L,f),[f]),k.flags|=2048,sv(9,{destroy:void 0},QZ.bind(null,k,L,x,p),null),x},useId:function(){var f=Ns(),p=$r.identifierPrefix;if(Tn){var x=vc,k=bc;x=(k&~(1<<32-qt(k)-1)).toString(32)+x,p="_"+p+"R_"+x,x=eO++,0<x&&(p+="H"+x.toString(32)),p+="_"}else x=O3e++,p="_"+p+"r_"+x.toString(32)+"_";return f.memoizedState=p},useHostTransitionStatus:F3,useFormState:aJ,useActionState:aJ,useOptimistic:function(f){var p=Ns();p.memoizedState=p.baseState=f;var x={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return p.queue=x,p=B3.bind(null,mn,!0,x),x.dispatch=p,[f,p]},useMemoCache:_3,useCacheRefresh:function(){return Ns().memoizedState=I3e.bind(null,mn)},useEffectEvent:function(f){var p=Ns(),x={impl:f};return p.memoizedState=x,function(){if((dr&2)!==0)throw Error(r(440));return x.impl.apply(void 0,arguments)}}},MJ={readContext:Vo,use:nO,useCallback:bJ,useContext:Vo,useEffect:j3,useImperativeHandle:yJ,useInsertionEffect:pJ,useLayoutEffect:mJ,useMemo:vJ,useReducer:rO,useRef:dJ,useState:function(){return rO(nf)},useDebugValue:D3,useDeferredValue:function(f,p){var x=Mi();return xJ(x,Nr.memoizedState,f,p)},useTransition:function(){var f=rO(nf)[0],p=Mi().memoizedState;return[typeof f=="boolean"?f:jS(f),p]},useSyncExternalStore:YZ,useId:CJ,useHostTransitionStatus:F3,useFormState:lJ,useActionState:lJ,useOptimistic:function(f,p){var x=Mi();return tJ(x,Nr,f,p)},useMemoCache:_3,useCacheRefresh:EJ,useEffectEvent:hJ},j3e={readContext:Vo,use:nO,useCallback:bJ,useContext:Vo,useEffect:j3,useImperativeHandle:yJ,useInsertionEffect:pJ,useLayoutEffect:mJ,useMemo:vJ,useReducer:L3,useRef:dJ,useState:function(){return L3(nf)},useDebugValue:D3,useDeferredValue:function(f,p){var x=Mi();return Nr===null?$3(x,f,p):xJ(x,Nr.memoizedState,f,p)},useTransition:function(){var f=L3(nf)[0],p=Mi().memoizedState;return[typeof f=="boolean"?f:jS(f),p]},useSyncExternalStore:YZ,useId:CJ,useHostTransitionStatus:F3,useFormState:cJ,useActionState:cJ,useOptimistic:function(f,p){var x=Mi();return Nr!==null?tJ(x,Nr,f,p):(x.baseState=f,[f,x.queue.dispatch])},useMemoCache:_3,useCacheRefresh:EJ,useEffectEvent:hJ};function H3(f,p,x,k){p=f.memoizedState,x=x(k,p),x=x==null?p:M({},p,x),f.memoizedState=x,f.lanes===0&&(f.updateQueue.baseState=x)}var U3={enqueueSetState:function(f,p,x){f=f._reactInternals;var k=Wa(),R=hp(k);R.payload=p,x!=null&&(R.callback=x),p=pp(f,R,k),p!==null&&(ca(p,f,k),_S(p,f,k))},enqueueReplaceState:function(f,p,x){f=f._reactInternals;var k=Wa(),R=hp(k);R.tag=1,R.payload=p,x!=null&&(R.callback=x),p=pp(f,R,k),p!==null&&(ca(p,f,k),_S(p,f,k))},enqueueForceUpdate:function(f,p){f=f._reactInternals;var x=Wa(),k=hp(x);k.tag=2,p!=null&&(k.callback=p),p=pp(f,k,x),p!==null&&(ca(p,f,x),_S(p,f,x))}};function _J(f,p,x,k,R,L,V){return f=f.stateNode,typeof f.shouldComponentUpdate=="function"?f.shouldComponentUpdate(k,L,V):p.prototype&&p.prototype.isPureReactComponent?!kS(x,k)||!kS(R,L):!0}function NJ(f,p,x,k){f=p.state,typeof p.componentWillReceiveProps=="function"&&p.componentWillReceiveProps(x,k),typeof p.UNSAFE_componentWillReceiveProps=="function"&&p.UNSAFE_componentWillReceiveProps(x,k),p.state!==f&&U3.enqueueReplaceState(p,p.state,null)}function b0(f,p){var x=p;if("ref"in p){x={};for(var k in p)k!=="ref"&&(x[k]=p[k])}if(f=f.defaultProps){x===p&&(x=M({},x));for(var R in f)x[R]===void 0&&(x[R]=f[R])}return x}function LJ(f){PA(f)}function IJ(f){console.error(f)}function PJ(f){PA(f)}function lO(f,p){try{var x=f.onUncaughtError;x(p.value,{componentStack:p.stack})}catch(k){setTimeout(function(){throw k})}}function jJ(f,p,x){try{var k=f.onCaughtError;k(x.value,{componentStack:x.stack,errorBoundary:p.tag===1?p.stateNode:null})}catch(R){setTimeout(function(){throw R})}}function V3(f,p,x){return x=hp(x),x.tag=3,x.payload={element:null},x.callback=function(){lO(f,p)},x}function DJ(f){return f=hp(f),f.tag=3,f}function $J(f,p,x,k){var R=x.type.getDerivedStateFromError;if(typeof R=="function"){var L=k.value;f.payload=function(){return R(L)},f.callback=function(){jJ(p,x,k)}}var V=x.stateNode;V!==null&&typeof V.componentDidCatch=="function"&&(f.callback=function(){jJ(p,x,k),typeof R!="function"&&(Sp===null?Sp=new Set([this]):Sp.add(this));var oe=k.stack;this.componentDidCatch(k.value,{componentStack:oe!==null?oe:""})})}function D3e(f,p,x,k,R){if(x.flags|=32768,k!==null&&typeof k=="object"&&typeof k.then=="function"){if(p=x.alternate,p!==null&&c0(p,x,R,!0),x=Wo.current,x!==null){switch(x.tag){case 31:case 13:case 19:return ps===null?RO():x.alternate===null&&bi===0&&(bi=3),x.flags&=-257,x.flags|=65536,x.lanes=R,k===KA?x.flags|=16384:(p=x.updateQueue,p===null?x.updateQueue=new Set([k]):p.add(k),O5(f,k,R)),!1;case 22:return x.flags|=65536,k===KA?x.flags|=16384:(p=x.updateQueue,p===null?(p={transitions:null,markerInstances:null,retryQueue:new Set([k])},x.updateQueue=p):(x=p.retryQueue,x===null?p.retryQueue=new Set([k]):x.add(k)),O5(f,k,R)),!1}throw Error(r(435,x.tag))}return O5(f,k,R),RO(),!1}if(Tn)return p=Wo.current,p!==null?((p.flags&65536)===0&&(p.flags|=256),p.flags|=65536,p.lanes=R,k!==c3&&(f=Error(r(422),{cause:k}),TS(vl(f,x)))):(k!==c3&&(p=Error(r(423),{cause:k}),TS(vl(p,x))),f=f.current.alternate,f.flags|=65536,R&=-R,f.lanes|=R,k=vl(k,x),R=V3(f.stateNode,k,R),x3(f,R),bi!==4&&(bi=2)),!1;var L=Error(r(520),{cause:k});if(L=vl(L,x),WS===null?WS=[L]:WS.push(L),bi!==4&&(bi=2),p===null)return!0;k=vl(k,x),x=p;do{switch(x.tag){case 3:return x.flags|=65536,f=R&-R,x.lanes|=f,f=V3(x.stateNode,k,f),x3(x,f),!1;case 1:if(p=x.type,L=x.stateNode,(x.flags&128)===0&&(typeof p.getDerivedStateFromError=="function"||L!==null&&typeof L.componentDidCatch=="function"&&(Sp===null||!Sp.has(L))))return x.flags|=65536,R&=-R,x.lanes|=R,R=DJ(R),$J(R,f,x,k),x3(x,R),!1;break;case 22:if(x.memoizedState!==null)return x.flags|=65536,!1}x=x.return}while(x!==null);return!1}var W3=Error(r(461)),Ui=!1;function Ji(f,p,x,k){p.child=f===null?HZ(p,null,x,k):g0(p,f.child,x,k)}function zJ(f,p,x,k,R){x=x.render;var L=p.ref;if("ref"in k){var V={};for(var oe in k)oe!=="ref"&&(V[oe]=k[oe])}else V=k;return d0(p),k=A3(f,p,x,V,L,R),oe=O3(),f!==null&&!Ui?(R3(f,p,R),rf(f,p,R)):(Tn&&oe&&BA(p),p.flags|=1,Ji(f,p,k,R),p.child)}function FJ(f,p,x,k,R){if(f===null){var L=x.type;return typeof L=="function"&&!s3(L)&&L.defaultProps===void 0&&x.compare===null?(p.tag=15,p.type=L,BJ(f,p,L,k,R)):(f=zA(x.type,null,k,p,p.mode,R),f.ref=p.ref,f.return=p,p.child=f)}if(L=f.child,!J3(f,R)){var V=L.memoizedProps;if(x=x.compare,x=x!==null?x:kS,x(V,k)&&f.ref===p.ref)return rf(f,p,R)}return p.flags|=1,f=Qd(L,k),f.ref=p.ref,f.return=p,p.child=f}function BJ(f,p,x,k,R){if(f!==null){var L=f.memoizedProps;if(kS(L,k)&&f.ref===p.ref)if(Ui=!1,p.pendingProps=k=L,J3(f,R))(f.flags&131072)!==0&&(Ui=!0);else return p.lanes=f.lanes,rf(f,p,R)}return q3(f,p,x,k,R)}function HJ(f,p,x,k){var R=k.children,L=f!==null?f.memoizedState:null;if(f===null&&p.stateNode===null&&(p.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),k.mode==="hidden"){if((p.flags&128)!==0){if(L=L!==null?L.baseLanes|x:x,f!==null){for(k=p.child=f.child,R=0;k!==null;)R=R|k.lanes|k.childLanes,k=k.sibling;k=R&~L}else k=0,p.child=null;return UJ(f,p,L,x,k)}if((x&536870912)!==0)p.memoizedState={baseLanes:0,cachePool:null},f!==null&&qA(p,L!==null?L.cachePool:null),L!==null?WZ(p,L):S3(),qZ(p);else return k=p.lanes=536870912,UJ(f,p,L!==null?L.baseLanes|x:x,x,k)}else L!==null?(qA(p,L.cachePool),WZ(p,L),yp(),p.memoizedState=null):(f!==null&&qA(p,null),S3(),yp());return Ji(f,p,R,x),p.child}function $S(f,p){return f!==null&&f.tag===22||p.stateNode!==null||(p.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),p.sibling}function UJ(f,p,x,k,R){var L=g3();return L=L===null?null:{parent:Bi._currentValue,pool:L},p.memoizedState={baseLanes:x,cachePool:L},f!==null&&qA(p,null),S3(),qZ(p),f!==null&&c0(f,p,k,!0),p.childLanes=R,null}function uO(f,p){return p=cO({mode:p.mode,children:p.children},f.mode),p.ref=f.ref,f.child=p,p.return=f,p}function VJ(f,p,x){return g0(p,f.child,null,x),f=uO(p,p.pendingProps),f.flags|=2,Ba(p),p.memoizedState=null,f}function $3e(f,p,x){var k=p.pendingProps,R=(p.flags&128)!==0;if(p.flags&=-129,f===null){if(Tn){if(k.mode==="hidden")return f=uO(p,k),p.lanes=536870912,f.memoizedState={baseLanes:0,cachePool:null},$S(null,f);if(C3(p),(f=Vr)?(f=gte(f,Sl),f=f!==null&&f.data==="&"?f:null,f!==null&&(p.memoizedState={dehydrated:f,treeContext:ap!==null?{id:bc,overflow:vc}:null,retryLane:536870912,hydrationErrors:null},x=AZ(f),x.return=p,p.child=x,wo=p,Vr=null)):f=null,f===null)throw up(p);return p.lanes=536870912,null}return uO(p,k)}var L=f.memoizedState;if(L!==null){var V=L.dehydrated;if(C3(p),R)if(p.flags&256)p.flags&=-257,p=VJ(f,p,x);else if(p.memoizedState!==null)p.child=f.child,p.flags|=128,p=null;else throw Error(r(558));else if(Ui||c0(f,p,x,!1),R=(x&f.childLanes)!==0,Ui||R){if(mp.current===null){if(k=$r,k!==null&&(V=kr(k,x),V!==0&&V!==L.retryLane))throw L.retryLane=V,s0(f,V),ca(k,f,V),W3;RO()}p=VJ(f,p,x)}else f=L.treeContext,Vr=Cl(V.nextSibling),wo=p,Tn=!0,lp=null,Sl=!1,f!==null&&MZ(p,f),p=uO(p,k),p.flags|=134221824;return p}return f=Qd(f.child,{mode:k.mode,children:k.children}),f.ref=p.ref,p.child=f,f.return=p,f}function av(f,p){var x=p.ref;if(x===null)f!==null&&f.ref!==null&&(p.flags|=4194816);else{if(typeof x!="function"&&typeof x!="object")throw Error(r(284));(f===null||f.ref!==x)&&(p.flags|=4194816)}}function q3(f,p,x,k,R){return d0(p),x=A3(f,p,x,k,void 0,R),k=O3(),f!==null&&!Ui?(R3(f,p,R),rf(f,p,R)):(Tn&&k&&BA(p),p.flags|=1,Ji(f,p,x,R),p.child)}function WJ(f,p,x,k,R,L){return d0(p),p.updateQueue=null,x=KZ(p,k,x,R),GZ(f),k=O3(),f!==null&&!Ui?(R3(f,p,L),rf(f,p,L)):(Tn&&k&&BA(p),p.flags|=1,Ji(f,p,x,L),p.child)}function qJ(f,p,x,k,R){if(d0(p),p.stateNode===null){var L=Qb,V=x.contextType;typeof V=="object"&&V!==null&&(L=Vo(V)),L=new x(k,L),p.memoizedState=L.state!==null&&L.state!==void 0?L.state:null,L.updater=U3,p.stateNode=L,L._reactInternals=p,L=p.stateNode,L.props=k,L.state=p.memoizedState,L.refs={},b3(p),V=x.contextType,L.context=typeof V=="object"&&V!==null?Vo(V):Qb,L.state=p.memoizedState,V=x.getDerivedStateFromProps,typeof V=="function"&&(H3(p,x,V,k),L.state=p.memoizedState),typeof x.getDerivedStateFromProps=="function"||typeof L.getSnapshotBeforeUpdate=="function"||typeof L.UNSAFE_componentWillMount!="function"&&typeof L.componentWillMount!="function"||(V=L.state,typeof L.componentWillMount=="function"&&L.componentWillMount(),typeof L.UNSAFE_componentWillMount=="function"&&L.UNSAFE_componentWillMount(),V!==L.state&&U3.enqueueReplaceState(L,L.state,null),LS(p,k,L,R),NS(),L.state=p.memoizedState),typeof L.componentDidMount=="function"&&(p.flags|=4194308),k=!0}else if(f===null){L=p.stateNode;var oe=p.memoizedProps,ye=b0(x,oe);L.props=ye;var Ne=L.context,ze=x.contextType;V=Qb,typeof ze=="object"&&ze!==null&&(V=Vo(ze));var Ge=x.getDerivedStateFromProps;ze=typeof Ge=="function"||typeof L.getSnapshotBeforeUpdate=="function",oe=p.pendingProps!==oe,ze||typeof L.UNSAFE_componentWillReceiveProps!="function"&&typeof L.componentWillReceiveProps!="function"||(oe||Ne!==V)&&NJ(p,L,k,V),fp=!1;var Re=p.memoizedState;L.state=Re,LS(p,k,L,R),NS(),Ne=p.memoizedState,oe||Re!==Ne||fp?(typeof Ge=="function"&&(H3(p,x,Ge,k),Ne=p.memoizedState),(ye=fp||_J(p,x,ye,k,Re,Ne,V))?(ze||typeof L.UNSAFE_componentWillMount!="function"&&typeof L.componentWillMount!="function"||(typeof L.componentWillMount=="function"&&L.componentWillMount(),typeof L.UNSAFE_componentWillMount=="function"&&L.UNSAFE_componentWillMount()),typeof L.componentDidMount=="function"&&(p.flags|=4194308)):(typeof L.componentDidMount=="function"&&(p.flags|=4194308),p.memoizedProps=k,p.memoizedState=Ne),L.props=k,L.state=Ne,L.context=V,k=ye):(typeof L.componentDidMount=="function"&&(p.flags|=4194308),k=!1)}else{L=p.stateNode,v3(f,p),V=p.memoizedProps,ze=b0(x,V),L.props=ze,Ge=p.pendingProps,Re=L.context,Ne=x.contextType,ye=Qb,typeof Ne=="object"&&Ne!==null&&(ye=Vo(Ne)),oe=x.getDerivedStateFromProps,(Ne=typeof oe=="function"||typeof L.getSnapshotBeforeUpdate=="function")||typeof L.UNSAFE_componentWillReceiveProps!="function"&&typeof L.componentWillReceiveProps!="function"||(V!==Ge||Re!==ye)&&NJ(p,L,k,ye),fp=!1,Re=p.memoizedState,L.state=Re,LS(p,k,L,R),NS();var je=p.memoizedState;V!==Ge||Re!==je||fp||f!==null&&f.dependencies!==null&&VA(f.dependencies)?(typeof oe=="function"&&(H3(p,x,oe,k),je=p.memoizedState),(ze=fp||_J(p,x,ze,k,Re,je,ye)||f!==null&&f.dependencies!==null&&VA(f.dependencies))?(Ne||typeof L.UNSAFE_componentWillUpdate!="function"&&typeof L.componentWillUpdate!="function"||(typeof L.componentWillUpdate=="function"&&L.componentWillUpdate(k,je,ye),typeof L.UNSAFE_componentWillUpdate=="function"&&L.UNSAFE_componentWillUpdate(k,je,ye)),typeof L.componentDidUpdate=="function"&&(p.flags|=4),typeof L.getSnapshotBeforeUpdate=="function"&&(p.flags|=1024)):(typeof L.componentDidUpdate!="function"||V===f.memoizedProps&&Re===f.memoizedState||(p.flags|=4),typeof L.getSnapshotBeforeUpdate!="function"||V===f.memoizedProps&&Re===f.memoizedState||(p.flags|=1024),p.memoizedProps=k,p.memoizedState=je),L.props=k,L.state=je,L.context=ye,k=ze):(typeof L.componentDidUpdate!="function"||V===f.memoizedProps&&Re===f.memoizedState||(p.flags|=4),typeof L.getSnapshotBeforeUpdate!="function"||V===f.memoizedProps&&Re===f.memoizedState||(p.flags|=1024),k=!1)}return L=k,av(f,p),k=(p.flags&128)!==0,L||k?(L=p.stateNode,x=k&&typeof x.getDerivedStateFromError!="function"?null:L.render(),p.flags|=1,f!==null&&k?(p.child=g0(p,f.child,null,R),p.child=g0(p,null,x,R)):Ji(f,p,x,R),p.memoizedState=L.state,f=p.child):f=rf(f,p,R),f}function GJ(f,p,x,k){return l0(),p.flags|=256,Ji(f,p,x,k),p.child}var G3={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function K3(f){return{baseLanes:f,cachePool:jZ()}}function Y3(f,p,x){return f=f!==null?f.childLanes&~x:0,p&&(f|=Va),f}function KJ(f,p,x){var k=p.pendingProps,R=!1,L=(p.flags&128)!==0,V;if((V=L)||(V=f!==null&&f.memoizedState===null?!1:(qo.current&2)!==0),V&&(R=!0,p.flags&=-129),V=(p.flags&32)!==0,p.flags&=-33,f===null){if(Tn){if(R?gp(p):yp(),(f=Vr)?(f=gte(f,Sl),f=f!==null&&f.data!=="&"?f:null,f!==null&&(p.memoizedState={dehydrated:f,treeContext:ap!==null?{id:bc,overflow:vc}:null,retryLane:536870912,hydrationErrors:null},x=AZ(f),x.return=p,p.child=x,wo=p,Vr=null)):f=null,f===null)throw up(p);return K5(f)?p.lanes=32:p.lanes=536870912,null}return L=k.children,k=k.fallback,R?(yp(),R=p.mode,L=cO({mode:"hidden",children:L},R),k=a0(k,R,x,null),L.return=p,k.return=p,L.sibling=k,p.child=L,k=p.child,k.memoizedState=K3(x),k.childLanes=Y3(f,V,x),p.memoizedState=G3,$S(null,k)):(gp(p),X3(p,L))}var oe=f.memoizedState;if(oe!==null){var ye=oe.dehydrated;if(ye!==null)return z3e(f,p,L,V,k,ye,oe,x)}return R?(yp(),R=k.fallback,L=p.mode,oe=f.child,ye=oe.sibling,k=Qd(oe,{mode:"hidden",children:k.children}),k.subtreeFlags=oe.subtreeFlags&1206910976,ye!==null?R=Qd(ye,R):(R=a0(R,L,x,null),R.flags|=2),R.return=p,k.return=p,k.sibling=R,p.child=k,$S(null,k),k=p.child,R=f.child.memoizedState,R===null?R=K3(x):(L=R.cachePool,L!==null?(oe=Bi._currentValue,L=L.parent!==oe?{parent:oe,pool:oe}:L):L=jZ(),R={baseLanes:R.baseLanes|x,cachePool:L}),k.memoizedState=R,k.childLanes=Y3(f,V,x),p.memoizedState=G3,$S(f.child,k)):(gp(p),x=f.child,f=x.sibling,x=Qd(x,{mode:"visible",children:k.children}),x.return=p,x.sibling=null,f!==null&&(V=p.deletions,V===null?(p.deletions=[f],p.flags|=16):V.push(f)),p.child=x,p.memoizedState=null,x)}function X3(f,p){return p=cO({mode:"visible",children:p},f.mode),p.return=f,f.child=p}function cO(f,p){return f=sa(22,f,null,p),f.lanes=0,f}function dO(f,p,x){return g0(p,f.child,null,x),f=X3(p,p.pendingProps.children),f.flags|=2,p.memoizedState=null,f}function z3e(f,p,x,k,R,L,V,oe){if(x)return p.flags&256?(gp(p),p.flags&=-257,dO(f,p,oe)):p.memoizedState!==null?(yp(),p.child=f.child,p.flags|=128,null):(yp(),L=R.fallback,V=p.mode,R=cO({mode:"visible",children:R.children},V),L=a0(L,V,oe,null),L.flags|=2,R.return=p,L.return=p,R.sibling=L,p.child=R,g0(p,f.child,null,oe),R=p.child,R.memoizedState=K3(oe),R.childLanes=Y3(f,k,oe),p.memoizedState=G3,$S(null,R));if(gp(p),K5(L)){if(k=L.nextSibling&&L.nextSibling.dataset,k)var ye=k.dgst;return k=ye,k!==""&&(R=Error(r(419)),R.stack="",R.digest=k,TS({value:R,source:null,stack:null})),dO(f,p,oe)}if(Ui||c0(f,p,oe,!1),k=(oe&f.childLanes)!==0,Ui||k){if(mp.current!==null)return dO(f,p,oe);if(k=$r,k!==null&&(R=kr(k,oe),R!==0&&R!==V.retryLane))throw V.retryLane=R,s0(f,R),ca(k,f,R),W3;return G5(L)||RO(),dO(f,p,oe)}return G5(L)?(p.flags|=192,p.child=f.child,null):(f=V.treeContext,Vr=Cl(L.nextSibling),wo=p,Tn=!0,lp=null,Sl=!1,f!==null&&MZ(p,f),p=X3(p,R.children),p.flags|=134221824,p)}function YJ(f,p,x){f.lanes|=p;var k=f.alternate;k!==null&&(k.lanes|=p),UA(f.return,p,x)}function XJ(f){for(var p=null;f!==null;){var x=f.alternate;x!==null&&ZA(x)===null&&(p=f),f=f.sibling}return p}function fO(f,p,x,k,R,L){var V=f.memoizedState;V===null?f.memoizedState={isBackwards:p,rendering:null,renderingStartTime:0,last:k,tail:x,tailMode:R,treeForkCount:L}:(V.isBackwards=p,V.rendering=null,V.renderingStartTime=0,V.last=k,V.tail=x,V.tailMode=R,V.treeForkCount=L)}function Q3(f){var p=f.child;for(f.child=null;p!==null;){var x=p.sibling;p.sibling=f.child,f.child=p,p=x}}function Z3(f,p,x){var k=p.pendingProps,R=k.revealOrder,L=k.tail;k=k.children;var V=qo.current;if(p.flags&128)return IS(p,V),null;var oe=(V&2)!==0;if(oe?(V=V&1|2,p.flags|=128):V&=1,IS(p,V),R==="backwards"&&f!==null?(Q3(f),Ji(f,p,k,x),Q3(f)):Ji(f,p,k,x),k=Tn?ES:0,!oe&&f!==null&&(f.flags&128)!==0)e:for(f=p.child;f!==null;){if(f.tag===13)f.memoizedState!==null&&YJ(f,x,p);else if(f.tag===19)YJ(f,x,p);else if(f.child!==null){f.child.return=f,f=f.child;continue}if(f===p)break e;for(;f.sibling===null;){if(f.return===null||f.return===p)break e;f=f.return}f.sibling.return=f.return,f=f.sibling}switch(R){case"backwards":x=XJ(p.child),x===null?(R=p.child,p.child=null):(R=x.sibling,x.sibling=null,Q3(p)),fO(p,!0,R,null,L,k);break;case"unstable_legacy-backwards":for(x=null,R=p.child,p.child=null;R!==null;){if(f=R.alternate,f!==null&&ZA(f)===null){p.child=R;break}f=R.sibling,R.sibling=x,x=R,R=f}fO(p,!0,x,null,L,k);break;case"together":fO(p,!1,null,null,void 0,k);break;case"independent":p.memoizedState=null;break;default:x=XJ(p.child),x===null?(R=p.child,p.child=null):(R=x.sibling,x.sibling=null),fO(p,!1,R,x,L,k)}return p.child}function QJ(f,p,x){var k=p.pendingProps;return cp(p,p.type,k.value),Ji(f,p,k.children,x),p.child}function rf(f,p,x){if(f!==null&&(p.dependencies=f.dependencies),wp|=p.lanes,(x&p.childLanes)===0)if(f!==null){if(c0(f,p,x,!1),(x&p.childLanes)===0)return null}else return null;if(f!==null&&p.child!==f.child)throw Error(r(153));if(p.child!==null){for(f=p.child,x=Qd(f,f.pendingProps),p.child=x,x.return=p;f.sibling!==null;)f=f.sibling,x=x.sibling=Qd(f,f.pendingProps),x.return=p;x.sibling=null}return p.child}function J3(f,p){return(f.lanes&p)!==0?!0:(f=f.dependencies,!!(f!==null&&VA(f)))}function F3e(f,p,x){switch(p.tag){case 3:Ye(p,p.stateNode.containerInfo),cp(p,Bi,f.memoizedState.cache),l0();break;case 27:case 5:Ae(p);break;case 4:Ye(p,p.stateNode.containerInfo);break;case 10:cp(p,p.type,p.memoizedProps.value);break;case 31:if(p.memoizedState!==null)return p.flags|=128,C3(p),null;break;case 13:var k=p.memoizedState;if(k!==null){if(k.dehydrated!==null)return gp(p),p.flags|=128,null;k=c0(f,p,x,!1);var R=p.child.childLanes;return k||(x&R)!==0?KJ(f,p,x):(gp(p),f=rf(f,p,x),f!==null?f.sibling:null)}gp(p);break;case 19:if(p.flags&128)return Z3(f,p,x);if(R=(f.flags&128)!==0,k=(x&p.childLanes)!==0,k||(c0(f,p,x,!1),k=(x&p.childLanes)!==0),R){if(k)return Z3(f,p,x);p.flags|=128}if(R=p.memoizedState,R!==null&&(R.rendering=null,R.tail=null,R.lastEffect=null),IS(p,qo.current),k)break;return null;case 22:return p.lanes=0,HJ(f,p,x,p.pendingProps);case 24:cp(p,Bi,f.memoizedState.cache)}return rf(f,p,x)}function ZJ(f,p,x){if(f!==null)if(f.memoizedProps!==p.pendingProps)Ui=!0;else{if(!J3(f,x)&&(p.flags&128)===0)return Ui=!1,F3e(f,p,x);Ui=(f.flags&131072)!==0}else Ui=!1,Tn&&(p.flags&1048576)!==0&&RZ(p,ES,p.index);switch(p.lanes=0,p.tag){case 16:e:{var k=p.pendingProps;if(f=p0(p.elementType),p.type=f,typeof f=="function")s3(f)?(k=b0(f,k),p.tag=1,p=qJ(null,p,f,k,x)):(p.tag=0,p=q3(null,p,f,k,x));else{if(f!=null){var R=f.$$typeof;if(R===H){p.tag=11,p=zJ(null,p,f,k,x);break e}else if(R===q){p.tag=14,p=FJ(null,p,f,k,x);break e}else if(R===B){p.tag=10,p.type=f,p=QJ(null,p,x);break e}}throw p=ie(f)||f,Error(r(306,p,""))}}return p;case 0:return q3(f,p,p.type,p.pendingProps,x);case 1:return k=p.type,R=b0(k,p.pendingProps),qJ(f,p,k,R,x);case 3:e:{if(Ye(p,p.stateNode.containerInfo),f===null)throw Error(r(387));k=p.pendingProps;var L=p.memoizedState;R=L.element,v3(f,p),LS(p,k,null,x);var V=p.memoizedState;if(k=V.cache,cp(p,Bi,k),k!==L.cache&&h3(p,[Bi],x,!0),NS(),k=V.element,L.isDehydrated)if(L={element:k,isDehydrated:!1,cache:V.cache},p.updateQueue.baseState=L,p.memoizedState=L,p.flags&256){p=GJ(f,p,k,x);break e}else if(k!==R){R=vl(Error(r(424)),p),TS(R),p=GJ(f,p,k,x);break e}else{switch(f=p.stateNode.containerInfo,f.nodeType){case 9:f=f.body;break;default:f=f.nodeName==="HTML"?f.ownerDocument.body:f}for(Vr=Cl(f.firstChild),wo=p,Tn=!0,lp=null,Sl=!0,x=HZ(p,null,k,x),p.child=x;x;)x.flags=x.flags&-3|134221824,x=x.sibling}else{if(l0(),k===R){p=rf(f,p,x);break e}Ji(f,p,k,x)}p=p.child}return p;case 26:return av(f,p),f===null?(x=kte(p.type,null,p.pendingProps,null))?p.memoizedState=x:Tn||(p.stateNode=nte(p.type,p.pendingProps,ge.current,p)):p.memoizedState=kte(p.type,f.memoizedProps,p.pendingProps,f.memoizedState),null;case 27:return Ae(p),f===null&&Tn&&(k=p.stateNode=vte(p.type,p.pendingProps,ge.current),wo=p,Sl=!0,R=Vr,Ep(p.type)?(Y5=R,Vr=Cl(k.firstChild)):Vr=R),Ji(f,p,p.pendingProps.children,x),av(f,p),f===null&&(p.flags|=4194304),p.child;case 5:return f===null&&Tn&&((R=k=Vr)&&(k=I5e(k,p.type,p.pendingProps,Sl),k!==null?(p.stateNode=k,wo=p,Vr=Cl(k.firstChild),Sl=!1,R=!0):R=!1),R||up(p)),Ae(p),R=p.type,L=p.pendingProps,V=f!==null?f.memoizedProps:null,k=L.children,F5(R,L)?k=null:V!==null&&F5(R,V)&&(p.flags|=32),p.memoizedState!==null&&(R=A3(f,p,R3e,null,null,x),Ev._currentValue=R),av(f,p),Ji(f,p,k,x),p.child;case 6:return f===null&&Tn&&((f=x=Vr)&&(x=P5e(x,p.pendingProps,Sl),x!==null?(p.stateNode=x,wo=p,Vr=null,f=!0):f=!1),f||up(p)),null;case 13:return KJ(f,p,x);case 4:return Ye(p,p.stateNode.containerInfo),k=p.pendingProps,f===null?p.child=g0(p,null,k,x):Ji(f,p,k,x),p.child;case 11:return zJ(f,p,p.type,p.pendingProps,x);case 7:return k=p.pendingProps,av(f,p),Ji(f,p,k,x),p.child;case 8:return Ji(f,p,p.pendingProps.children,x),p.child;case 12:return Ji(f,p,p.pendingProps.children,x),p.child;case 10:return QJ(f,p,x);case 9:return R=p.type._context,k=p.pendingProps.children,d0(p),R=Vo(R),k=k(R),p.flags|=1,Ji(f,p,k,x),p.child;case 14:return FJ(f,p,p.type,p.pendingProps,x);case 15:return BJ(f,p,p.type,p.pendingProps,x);case 19:return Z3(f,p,x);case 31:return $3e(f,p,x);case 22:return HJ(f,p,x,p.pendingProps);case 24:return d0(p),k=Vo(Bi),f===null?(R=g3(),R===null&&(R=$r,L=p3(),R.pooledCache=L,L.refCount++,L!==null&&(R.pooledCacheLanes|=x),R=L),p.memoizedState={parent:k,cache:R},b3(p),cp(p,Bi,R)):((f.lanes&x)!==0&&(v3(f,p),LS(p,null,null,x),NS()),R=f.memoizedState,L=p.memoizedState,R.parent!==k?(R={parent:k,cache:k},p.memoizedState=R,p.lanes===0&&(p.memoizedState=p.updateQueue.baseState=R),cp(p,Bi,k)):(k=L.cache,cp(p,Bi,k),k!==R.cache&&h3(p,[Bi],x,!0))),Ji(f,p,p.pendingProps.children,x),p.child;case 30:return p.stateNode===null&&(p.stateNode={autoName:null,paired:null,clones:null,ref:null}),k=p.pendingProps,k.name!=null&&k.name!=="auto"?p.flags|=f===null?18882560:18874368:Tn&&BA(p),f!==null&&f.memoizedProps.name!==k.name?p.flags|=4194816:av(f,p),Ji(f,p,k.children,x),p.child;case 29:throw p.pendingProps}throw Error(r(156,p.tag))}function of(f){f.flags|=4}function e5(f,p,x,k,R){var L;if((L=(f.mode&32)!==0)&&(L=x===null?Ate(p,k):Ate(p,k)&&(k.src!==x.src||k.srcSet!==x.srcSet)),L){if(f.flags|=16777216,(R&335544128)===R)if(f.stateNode.complete)f.flags|=8192;else if(Lee())f.flags|=8192;else throw m0=KA,y3}else f.flags&=-16777217}function JJ(f,p){if(p.type!=="stylesheet"||(p.state.loading&4)!==0)f.flags&=-16777217;else if(f.flags|=16777216,!Ote(p))if(Lee())f.flags|=8192;else throw m0=KA,y3}function hO(f,p){p!==null&&(f.flags|=4),f.flags&16384&&(p=f.tag!==22?zi():536870912,f.lanes|=p,fv|=p)}function zS(f,p){if(!Tn)switch(f.tailMode){case"visible":break;case"collapsed":for(var x=f.tail,k=null;x!==null;)x.alternate!==null&&(k=x),x=x.sibling;k===null?p||f.tail===null?f.tail=null:f.tail.sibling=null:k.sibling=null;break;default:for(p=f.tail,x=null;p!==null;)p.alternate!==null&&(x=p),p=p.sibling;x===null?f.tail=null:x.sibling=null}}function Wr(f){var p=f.alternate!==null&&f.alternate.child===f.child,x=0,k=0;if(p)for(var R=f.child;R!==null;)x|=R.lanes|R.childLanes,k|=R.subtreeFlags&1206910976,k|=R.flags&1206910976,R.return=f,R=R.sibling;else for(R=f.child;R!==null;)x|=R.lanes|R.childLanes,k|=R.subtreeFlags,k|=R.flags,R.return=f,R=R.sibling;return f.subtreeFlags|=k,f.childLanes=x,p}function B3e(f,p,x){var k=p.pendingProps;switch(u3(p),p.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Wr(p),null;case 1:return Wr(p),null;case 3:return x=p.stateNode,k=null,f!==null&&(k=f.memoizedState.cache),p.memoizedState.cache!==k&&(p.flags|=2048),ef(Bi),tt(),x.pendingContext&&(x.context=x.pendingContext,x.pendingContext=null),(f===null||f.child===null)&&(ev(p)?of(p):f===null||f.memoizedState.isDehydrated&&(p.flags&256)===0||(p.flags|=1024,d3())),Wr(p),null;case 26:var R=p.type,L=p.memoizedState;return f===null?(of(p),L!==null?(Wr(p),JJ(p,L)):(Wr(p),e5(p,R,null,k,x))):L?L!==f.memoizedState?(of(p),Wr(p),JJ(p,L)):(Wr(p),p.flags&=-16777217):(f=f.memoizedProps,f!==k&&of(p),Wr(p),e5(p,R,f,k,x)),null;case 27:if(_e(p),x=ge.current,R=p.type,f!==null&&p.stateNode!=null)f.memoizedProps!==k&&of(p);else{if(!k){if(p.stateNode===null)throw Error(r(166));return Wr(p),p.subtreeFlags&=-33554433,null}f=Oe.current,ev(p)?_Z(p):(f=vte(R,k,x),p.stateNode=f,of(p))}return Wr(p),p.subtreeFlags&=-33554433,null;case 5:if(_e(p),R=p.type,f!==null&&p.stateNode!=null)f.memoizedProps!==k&&of(p);else{if(!k){if(p.stateNode===null)throw Error(r(166));return Wr(p),p.subtreeFlags&=-33554433,null}if(L=Oe.current,ev(p))_Z(p);else{var V=XS(ge.current);switch(L){case 1:L=V.createElementNS("http://www.w3.org/2000/svg",R);break;case 2:L=V.createElementNS("http://www.w3.org/1998/Math/MathML",R);break;default:switch(R){case"svg":L=V.createElementNS("http://www.w3.org/2000/svg",R);break;case"math":L=V.createElementNS("http://www.w3.org/1998/Math/MathML",R);break;case"script":L=V.createElement("div"),L.innerHTML="<script><\/script>",L=L.removeChild(L.firstChild);break;case"select":L=typeof k.is=="string"?V.createElement("select",{is:k.is}):V.createElement("select"),k.multiple?L.multiple=!0:k.size&&(L.size=k.size);break;default:L=typeof k.is=="string"?V.createElement(R,{is:k.is}):V.createElement(R)}}L[Hr]=p,L[Te]=k;e:for(V=p.child;V!==null;){if(V.tag===5||V.tag===6)L.appendChild(V.stateNode);else if(V.tag!==4&&V.tag!==27&&V.child!==null){V.child.return=V,V=V.child;continue}if(V===p)break e;for(;V.sibling===null;){if(V.return===null||V.return===p)break e;V=V.return}V.sibling.return=V.return,V=V.sibling}p.stateNode=L;e:switch(Ko(L,R,k),R){case"button":case"input":case"select":case"textarea":k=!!k.autoFocus;break e;case"img":k=!0;break e;default:k=!1}k&&of(p)}}return Wr(p),p.subtreeFlags&=-33554433,e5(p,p.type,f===null?null:f.memoizedProps,p.pendingProps,x),null;case 6:if(f&&p.stateNode!=null)f.memoizedProps!==k&&of(p);else{if(typeof k!="string"&&p.stateNode===null)throw Error(r(166));if(f=ge.current,ev(p)){if(f=p.stateNode,x=p.memoizedProps,k=null,R=wo,R!==null)switch(R.tag){case 27:case 5:k=R.memoizedProps}f[Hr]=p,f=!!(f.nodeValue===x||k!==null&&k.suppressHydrationWarning===!0||Zee(f.nodeValue,x)),f||up(p,!0)}else f=XS(f).createTextNode(k),f[Hr]=p,p.stateNode=f}return Wr(p),null;case 31:if(x=p.memoizedState,f===null||f.memoizedState!==null){if(k=ev(p),x!==null){if(f===null){if(!k)throw Error(r(318));if(f=p.memoizedState,f=f!==null?f.dehydrated:null,!f)throw Error(r(557));f[Hr]=p}else l0(),(p.flags&128)===0&&(p.memoizedState=null),p.flags|=4;Wr(p),f=!1}else x=d3(),f!==null&&f.memoizedState!==null&&(f.memoizedState.hydrationErrors=x),f=!0;if(!f)return p.flags&256?(Ba(p),p):(Ba(p),null);if((p.flags&128)!==0)throw Error(r(558))}return Wr(p),null;case 13:if(k=p.memoizedState,f===null||f.memoizedState!==null&&f.memoizedState.dehydrated!==null){if(R=ev(p),k!==null&&k.dehydrated!==null){if(f===null){if(!R)throw Error(r(318));if(R=p.memoizedState,R=R!==null?R.dehydrated:null,!R)throw Error(r(317));R[Hr]=p}else l0(),(p.flags&128)===0&&(p.memoizedState=null),p.flags|=4;Wr(p),R=!1}else R=d3(),f!==null&&f.memoizedState!==null&&(f.memoizedState.hydrationErrors=R),R=!0;if(!R)return p.flags&256?(Ba(p),p):(Ba(p),null)}return Ba(p),(p.flags&128)!==0?(p.lanes=x,p):(x=k!==null,f=f!==null&&f.memoizedState!==null,x&&(k=p.child,R=null,k.alternate!==null&&k.alternate.memoizedState!==null&&k.alternate.memoizedState.cachePool!==null&&(R=k.alternate.memoizedState.cachePool.pool),L=null,k.memoizedState!==null&&k.memoizedState.cachePool!==null&&(L=k.memoizedState.cachePool.pool),L!==R&&(k.flags|=2048)),x!==f&&x&&(p.child.flags|=8192),hO(p,p.updateQueue),Wr(p),null);case 4:return tt(),f===null&&P5(p.stateNode.containerInfo),p.flags|=67108864,Wr(p),null;case 10:return ef(p.type),Wr(p),null;case 19:if(E3(p),k=p.memoizedState,k===null)return Wr(p),null;if(R=(p.flags&128)!==0,L=k.rendering,L===null)if(R)zS(k,!1);else{if(bi!==0||f!==null&&(f.flags&128)!==0)for(f=p.child;f!==null;){if(L=ZA(f),L!==null){for(p.flags|=128,zS(k,!1),f=L.updateQueue,p.updateQueue=f,hO(p,f),p.subtreeFlags=0,f=x,x=p.child;x!==null;)TZ(x,f),x=x.sibling;return IS(p,qo.current&1|2),Tn&&Zd(p,k.treeForkCount),p.child}f=f.sibling}k.tail!==null&&ln()>EO&&(p.flags|=128,R=!0,zS(k,!1),p.lanes=4194304)}else{if(!R)if(f=ZA(L),f!==null){if(p.flags|=128,R=!0,f=f.updateQueue,p.updateQueue=f,hO(p,f),zS(k,!0),k.tail===null&&k.tailMode!=="collapsed"&&k.tailMode!=="visible"&&!L.alternate&&!Tn)return Wr(p),null}else 2*ln()-k.renderingStartTime>EO&&x!==536870912&&(p.flags|=128,R=!0,zS(k,!1),p.lanes=4194304);k.isBackwards?(L.sibling=p.child,p.child=L):(f=k.last,f!==null?f.sibling=L:p.child=L,k.last=L)}if(k.tail!==null){f=k.tail;e:{for(x=f;x!==null;){if(x.alternate!==null){x=!1;break e}x=x.sibling}x=!0}return k.rendering=f,k.tail=f.sibling,k.renderingStartTime=ln(),f.sibling=null,L=qo.current,L=R?L&1|2:L&1,k.tailMode==="visible"||k.tailMode==="collapsed"||!x||Tn?IS(p,L):(x=L,Be(Wo,p),Be(qo,x),ps===null&&(ps=p)),Tn&&Zd(p,k.treeForkCount),f}return Wr(p),null;case 22:case 23:return Ba(p),k3(),k=p.memoizedState!==null,f!==null?f.memoizedState!==null!==k&&(p.flags|=8192):k&&(p.flags|=8192),k?(x&536870912)!==0&&(p.flags&128)===0&&(Wr(p),p.subtreeFlags&6&&(p.flags|=8192)):Wr(p),x=p.updateQueue,x!==null&&hO(p,x.retryQueue),x=null,f!==null&&f.memoizedState!==null&&f.memoizedState.cachePool!==null&&(x=f.memoizedState.cachePool.pool),k=null,p.memoizedState!==null&&p.memoizedState.cachePool!==null&&(k=p.memoizedState.cachePool.pool),k!==x&&(p.flags|=2048),f!==null&&Ie(h0),null;case 24:return x=null,f!==null&&(x=f.memoizedState.cache),p.memoizedState.cache!==x&&(p.flags|=2048),ef(Bi),Wr(p),null;case 25:return null;case 30:return p.flags|=33554432,Wr(p),null}throw Error(r(156,p.tag))}function H3e(f,p){switch(u3(p),p.tag){case 1:return f=p.flags,f&65536?(p.flags=f&-65537|128,p):null;case 3:return ef(Bi),tt(),f=p.flags,(f&65536)!==0&&(f&128)===0?(p.flags=f&-65537|128,p):null;case 26:case 27:case 5:return _e(p),null;case 31:if(p.memoizedState!==null){if(Ba(p),p.alternate===null)throw Error(r(340));l0()}return f=p.flags,f&65536?(p.flags=f&-65537|128,p):null;case 13:if(Ba(p),f=p.memoizedState,f!==null&&f.dehydrated!==null){if(p.alternate===null)throw Error(r(340));l0()}return f=p.flags,f&65536?(p.flags=f&-65537|128,p):null;case 19:return E3(p),f=p.flags,f&65536?(p.flags=f&-65537|128,f=p.memoizedState,f!==null&&(f.rendering=null,f.tail=null),p.flags|=4,p):null;case 4:return tt(),null;case 10:return ef(p.type),null;case 22:case 23:return Ba(p),k3(),f!==null&&Ie(h0),f=p.flags,f&65536?(p.flags=f&-65537|128,p):null;case 24:return ef(Bi),null;case 25:return null;default:return null}}function eee(f,p){switch(u3(p),p.tag){case 3:ef(Bi),tt();break;case 26:case 27:case 5:_e(p);break;case 4:tt();break;case 31:p.memoizedState!==null&&Ba(p);break;case 13:Ba(p);break;case 19:E3(p);break;case 10:ef(p.type);break;case 22:case 23:Ba(p),k3(),f!==null&&Ie(h0);break;case 24:ef(Bi)}}function FS(f,p){try{var x=p.updateQueue,k=x!==null?x.lastEffect:null;if(k!==null){var R=k.next;x=R;do{if((x.tag&f)===f){k=void 0;var L=x.create,V=x.inst;k=L(),V.destroy=k}x=x.next}while(x!==R)}}catch(oe){Er(p,p.return,oe)}}function bp(f,p,x){try{var k=p.updateQueue,R=k!==null?k.lastEffect:null;if(R!==null){var L=R.next;k=L;do{if((k.tag&f)===f){var V=k.inst,oe=V.destroy;if(oe!==void 0){V.destroy=void 0,R=p;var ye=x,Ne=oe;try{Ne()}catch(ze){Er(R,ye,ze)}}}k=k.next}while(k!==L)}}catch(ze){Er(p,p.return,ze)}}function tee(f){var p=f.updateQueue;if(p!==null){var x=f.stateNode;try{VZ(p,x)}catch(k){Er(f,f.return,k)}}}function nee(f,p,x){x.props=b0(f.type,f.memoizedProps),x.state=f.memoizedState;try{x.componentWillUnmount()}catch(k){Er(f,p,k)}}function xc(f,p){try{var x=f.ref;if(x!==null){switch(f.tag){case 26:case 27:case 5:var k=f.stateNode;break;case 30:var R=f.stateNode,L=Yd(f.memoizedProps,R);(R.ref===null||R.ref.name!==L)&&(R.ref=ute(L)),k=R.ref;break;case 7:if(f.stateNode===null){var V=new qa(f);d(f.child,!1,N5e,V,void 0,void 0),f.stateNode=V}k=f.stateNode;break;default:k=f.stateNode}typeof x=="function"?f.refCleanup=x(k):x.current=k}}catch(oe){Er(f,p,oe)}}function Go(f,p){var x=f.ref,k=f.refCleanup;if(x!==null)if(typeof k=="function")try{k()}catch(R){Er(f,p,R)}finally{f.refCleanup=null,f=f.alternate,f!=null&&(f.refCleanup=null)}else if(typeof x=="function")try{x(null)}catch(R){Er(f,p,R)}else x.current=null}function pO(f,p){if((f.tag===5||f.tag===27||f.tag===6)&&f.alternate===null&&p!==null)for(var x=0;x<p.length;x++)mte(f.stateNode,p[x])}function ree(f){for(var p=f.return;p!==null&&(n5(p)&&mte(f.stateNode,p.stateNode),!t5(p));)p=p.return}function BS(f){for(var p=f.return;p!==null&&(n5(p)&&L5e(f.stateNode,p.stateNode),!t5(p));)p=p.return}function t5(f){return f.tag===5||f.tag===3||f.tag===27}function n5(f){return f&&f.tag===7&&f.stateNode!==null}function r5(f){var p=f.type,x=f.memoizedProps,k=f.stateNode;try{e:switch(p){case"button":case"input":case"select":case"textarea":x.autoFocus&&k.focus();break e;case"img":x.src?k.src=x.src:x.srcSet&&(k.srcset=x.srcSet)}}catch(R){Er(f,f.return,R)}}function i5(f,p,x){try{var k=f.stateNode;p5e(k,f.type,x,p),k[Te]=p}catch(R){Er(f,f.return,R)}}function iee(f){return f.tag===5||f.tag===3||f.tag===26||f.tag===27&&Ep(f.type)||f.tag===4}function o5(f){e:for(;;){for(;f.sibling===null;){if(f.return===null||iee(f.return))return null;f=f.return}for(f.sibling.return=f.return,f=f.sibling;f.tag!==5&&f.tag!==6&&f.tag!==18;){if(f.tag===27&&Ep(f.type)||f.flags&2||f.child===null||f.tag===4)continue e;f.child.return=f,f=f.child}if(!(f.flags&2))return f.stateNode}}function s5(f,p,x,k){var R=f.tag;if(R===5||R===6)R=f.stateNode,p?(x.nodeType===9?x.body:x.nodeName==="HTML"?x.ownerDocument.body:x).insertBefore(R,p):(p=x.nodeType===9?x.body:x.nodeName==="HTML"?x.ownerDocument.body:x,p.appendChild(R),x=x._reactRootContainer,x!=null||p.onclick!==null||(p.onclick=_s)),pO(f,k),En=!0;else if(R!==4&&(R===27&&(pO(f,k),k=null,Ep(f.type)&&(x=f.stateNode,p=null)),f=f.child,f!==null))for(s5(f,p,x,k),f=f.sibling;f!==null;)s5(f,p,x,k),f=f.sibling}function mO(f,p,x,k){var R=f.tag;if(R===5||R===6)R=f.stateNode,p?x.insertBefore(R,p):x.appendChild(R),pO(f,k),En=!0;else if(R!==4&&(R===27&&(pO(f,k),k=null,Ep(f.type)&&(x=f.stateNode)),f=f.child,f!==null))for(mO(f,p,x,k),f=f.sibling;f!==null;)mO(f,p,x,k),f=f.sibling}function oee(f){var p=f.stateNode,x=f.memoizedProps;try{for(var k=f.type,R=p.attributes;R.length;)p.removeAttributeNode(R[0]);Ko(p,k,x),p[Hr]=f,p[Te]=x}catch(L){Er(f,f.return,L)}}var gO=!1,Ha=null;function see(f){(f.tag===30||(f.subtreeFlags&33554432)!==0)&&(gO=!0)}var wc=null;function aee(){var f=wc;return wc=null,f}var aa=0;function lv(f,p,x,k,R){return aa=0,lee(f.child,p,x,k,R)}function lee(f,p,x,k,R){for(var L=!1;f!==null;){if(f.tag===5){var V=f.stateNode;if(k!==null){var oe=U5(V);k.push(oe),oe.view&&(L=!0)}else L||U5(V).view&&(L=!0);gO=!0,ate(V,aa===0?p:p+"_"+aa,x),aa++}else(f.tag!==22||f.memoizedState===null)&&(f.tag===30&&R||lee(f.child,p,x,k,R)&&(L=!0));f=f.sibling}return L}function Sc(f,p){for(;f!==null;)f.tag===5?lte(f.stateNode,f.memoizedProps):(f.tag!==22||f.memoizedState===null)&&(f.tag===30&&p||Sc(f.child,p)),f=f.sibling}function yO(f){if((f.subtreeFlags&18874368)!==0)for(f=f.child;f!==null;){if((f.tag!==22||f.memoizedState===null)&&(yO(f),f.tag===30&&(f.flags&18874368)!==0&&f.stateNode.paired)){var p=f.memoizedProps;if(p.name==null||p.name==="auto")throw Error(r(544));var x=p.name;p=Xd(p.default,p.share),p!=="none"&&(lv(f,x,p,null,!1)||Sc(f.child,!1))}f=f.sibling}}function a5(f,p){if(f.tag===30){var x=f.stateNode,k=f.memoizedProps,R=Yd(k,x),L=Xd(k.default,x.paired?k.share:k.enter);L!=="none"?lv(f,R,L,null,!1)?(yO(f),x.paired||p||gv(f,k.onEnter)):Sc(f.child,!1):yO(f)}else if((f.subtreeFlags&33554432)!==0)for(f=f.child;f!==null;)a5(f,p),f=f.sibling;else yO(f)}function l5(f){if(Ha!==null&&Ha.size!==0){var p=Ha;if((f.subtreeFlags&18874368)!==0)for(f=f.child;f!==null;){if(f.tag!==22||f.memoizedState===null){if(f.tag===30&&(f.flags&18874368)!==0){var x=f.memoizedProps,k=x.name;if(k!=null&&k!=="auto"){var R=p.get(k);if(R!==void 0){var L=Xd(x.default,x.share);if(L!=="none"&&(lv(f,k,L,null,!1)?(L=f.stateNode,R.paired=L,L.paired=R,gv(f,x.onShare)):Sc(f.child,!1)),p.delete(k),p.size===0)break}}}l5(f)}f=f.sibling}}}function u5(f){if(f.tag===30){var p=f.memoizedProps,x=Yd(p,f.stateNode),k=Ha!==null?Ha.get(x):void 0,R=Xd(p.default,k!==void 0?p.share:p.exit);R!=="none"&&(lv(f,x,R,null,!1)?k!==void 0?(R=f.stateNode,k.paired=R,R.paired=k,Ha.delete(x),gv(f,p.onShare)):gv(f,p.onExit):Sc(f.child,!1)),Ha!==null&&l5(f)}else if((f.subtreeFlags&33554432)!==0)for(f=f.child;f!==null;)u5(f),f=f.sibling;else Ha!==null&&l5(f)}function uee(f){for(f=f.child;f!==null;){if(f.tag===30){var p=f.memoizedProps,x=Yd(p,f.stateNode);p=Xd(p.default,p.update),f.flags&=-5,p!=="none"&&lv(f,x,p,f.memoizedState=[],!1)}else(f.subtreeFlags&33554432)!==0&&uee(f);f=f.sibling}}function c5(f){if((f.subtreeFlags&18874368)!==0)for(f=f.child;f!==null;){if(f.tag!==22||f.memoizedState===null){if(f.tag===30&&(f.flags&18874368)!==0){var p=f.stateNode;p.paired!==null&&(p.paired=null,Sc(f.child,!1))}c5(f)}f=f.sibling}}function bO(f){if(f.tag===30)f.stateNode.paired=null,Sc(f.child,!1),c5(f);else if((f.subtreeFlags&33554432)!==0)for(f=f.child;f!==null;)bO(f),f=f.sibling;else c5(f)}function cee(f){for(f=f.child;f!==null;)f.tag===30?Sc(f.child,!1):(f.subtreeFlags&33554432)!==0&&cee(f),f=f.sibling}function d5(f,p,x,k,R,L,V){for(var oe=!1;p!==null;){if(p.tag===5){var ye=p.stateNode;if(L!==null&&aa<L.length){var Ne=L[aa],ze=U5(ye);(Ne.view||ze.view)&&(oe=!0);var Ge;if(Ge=(f.flags&4)===0)if(ze.clip)Ge=!0;else{Ge=Ne.rect;var Re=ze.rect;Ge=Ge.y!==Re.y||Ge.x!==Re.x||Ge.height!==Re.height||Ge.width!==Re.width}Ge&&(f.flags|=4),ze.abs?ze=!Ne.abs:(Ne=Ne.rect,ze=ze.rect,ze=Ne.height!==ze.height||Ne.width!==ze.width),ze&&(f.flags|=32)}else f.flags|=32;(f.flags&4)!==0&&ate(ye,aa===0?x:x+"_"+aa,R),oe&&(f.flags&4)!==0||(wc===null&&(wc=[]),wc.push(ye,aa===0?k:k+"_"+aa,p.memoizedProps)),aa++}else(p.tag!==22||p.memoizedState===null)&&(p.tag===30&&V?f.flags|=p.flags&32:d5(f,p.child,x,k,R,L,V)&&(oe=!0));p=p.sibling}return oe}function dee(f,p){for(f=f.child;f!==null;){if(f.tag===30){var x=f.memoizedProps,k=f.stateNode,R=Yd(x,k),L=Xd(x.default,x.update),V;V=f.memoizedState,f.memoizedState=null,k=f;var oe=f.child;aa=0,R=d5(k,oe,R,R,L,V,!1),(f.flags&4)!==0&&R&&gv(f,x.onUpdate)}else(f.subtreeFlags&33554432)!==0&&dee(f);f=f.sibling}}var So=!1,yr=!1,kc=!1,f5=!1,fee=typeof WeakSet=="function"?WeakSet:Set,ko=null,Cc=!1,HS=!1,vO=!1,h5=!1;function U3e(f,p,x){if(f=f.containerInfo,$5=Tv,f=gZ(f),JD(f)){if("selectionStart"in f)var k={start:f.selectionStart,end:f.selectionEnd};else e:{k=(k=f.ownerDocument)&&k.defaultView||window;var R=k.getSelection&&k.getSelection();if(R&&R.rangeCount!==0){k=R.anchorNode;var L=R.anchorOffset,V=R.focusNode;R=R.focusOffset;try{k.nodeType,V.nodeType}catch{k=null;break e}var oe=0,ye=-1,Ne=-1,ze=0,Ge=0,Re=f,je=null;t:for(;;){for(var vt;Re!==k||L!==0&&Re.nodeType!==3||(ye=oe+L),Re!==V||R!==0&&Re.nodeType!==3||(Ne=oe+R),Re.nodeType===3&&(oe+=Re.nodeValue.length),(vt=Re.firstChild)!==null;)je=Re,Re=vt;for(;;){if(Re===f)break t;if(je===k&&++ze===L&&(ye=oe),je===V&&++Ge===R&&(Ne=oe),(vt=Re.nextSibling)!==null)break;Re=je,je=Re.parentNode}Re=vt}k=ye===-1||Ne===-1?null:{start:ye,end:Ne}}else k=null}k=k||{start:0,end:0}}else k=null;for(z5={focusedElem:f,selectionRange:k},Tv=!1,x=(x&335544064)===x,ko=p,p=x?9270:1024;ko!==null;){if(f=ko,x&&(k=f.deletions,k!==null))for(L=0;L<k.length;L++)x&&u5(k[L]);if(f.alternate===null&&(f.flags&2)!==0)x&&see(f),xO(x);else{if(f.tag===22){if(k=f.alternate,f.memoizedState!==null){k!==null&&k.memoizedState===null&&x&&u5(k),xO(x);continue}else if(k!==null&&k.memoizedState!==null){x&&see(f),xO(x);continue}}k=f.child,(f.subtreeFlags&p)!==0&&k!==null?(k.return=f,ko=k):(x&&uee(f),xO(x))}}Ha=null}function xO(f){for(;ko!==null;){var p=ko,x=f,k=p.alternate,R=p.flags;switch(p.tag){case 0:case 11:case 15:break;case 1:if((R&1024)!==0&&k!==null){x=void 0,R=k.memoizedProps,k=k.memoizedState;var L=p.stateNode;try{var V=b0(p.type,R);x=L.getSnapshotBeforeUpdate(V,k),L.__reactInternalSnapshotBeforeUpdate=x}catch(oe){Er(p,p.return,oe)}}break;case 3:if((R&1024)!==0){if(k=p.stateNode.containerInfo,x=k.nodeType,x===9)q5(k);else if(x===1)switch(k.nodeName){case"HEAD":case"HTML":case"BODY":q5(k);break;default:k.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;case 30:x&&k!==null&&(x=Yd(k.memoizedProps,k.stateNode),R=p.memoizedProps,R=Xd(R.default,R.update),R!=="none"&&lv(k,x,R,k.memoizedState=[],!0));break;default:if((R&1024)!==0)throw Error(r(163))}if(k=p.sibling,k!==null){k.return=p.return,ko=k;break}ko=p.return}}function hee(f,p,x){var k=x.flags;switch(x.tag){case 0:case 11:case 15:Ec(f,x),k&4&&FS(5,x);break;case 1:if(Ec(f,x),k&4)if(f=x.stateNode,p===null)try{f.componentDidMount()}catch(V){Er(x,x.return,V)}else{var R=b0(x.type,p.memoizedProps);p=p.memoizedState;try{f.componentDidUpdate(R,p,f.__reactInternalSnapshotBeforeUpdate)}catch(V){Er(x,x.return,V)}}k&64&&tee(x),k&512&&xc(x,x.return);break;case 3:if(Ec(f,x),k&64&&(f=x.updateQueue,f!==null)){if(p=null,x.child!==null)switch(x.child.tag){case 27:case 5:p=x.child.stateNode;break;case 1:p=x.child.stateNode}try{VZ(f,p)}catch(V){Er(x,x.return,V)}}break;case 27:p===null&&k&4&&oee(x);case 26:case 5:Ec(f,x),p===null&&k&4&&r5(x),k&512&&xc(x,x.return);break;case 12:Ec(f,x);break;case 31:Ec(f,x),k&4&&yee(f,x);break;case 13:Ec(f,x),k&4&&bee(f,x),k&64&&(f=x.memoizedState,f!==null&&(f=f.dehydrated,f!==null&&(x=t5e.bind(null,x),j5e(f,x))));break;case 22:if(k=x.memoizedState!==null||So,!k){var L=p!==null&&p.memoizedState!==null||yr;p=So,R=yr,So=k,(yr=L)&&!R?(k=2,(x.subtreeFlags&8772)!==0&&(k|=1),Su(f,x,k)):Ec(f,x),So=p,yr=R}break;case 30:Ec(f,x),k&512&&xc(x,x.return);break;case 7:k&512&&xc(x,x.return);default:Ec(f,x)}}function p5(f,p){for(f=f.child;f!==null;)pee(f,p),f=f.sibling}function pee(f,p){switch(f.tag){case 5:case 26:try{var x=f.stateNode;if(p){var k=x.style;typeof k.setProperty=="function"?k.setProperty("display","none","important"):k.display="none"}else{var R=f.stateNode,L=f.memoizedProps.style,V=L!=null&&L.hasOwnProperty("display")?L.display:null;R.style.display=V==null||typeof V=="boolean"?"":(""+V).trim()}}catch(ye){Er(f,f.return,ye)}m5(f,p);break;case 6:try{f.stateNode.nodeValue=p?"":f.memoizedProps,En=!0}catch(ye){Er(f,f.return,ye)}break;case 18:try{var oe=f.stateNode;p?ste(oe,!0):ste(f.stateNode,!1)}catch(ye){Er(f,f.return,ye)}break;case 22:case 23:f.memoizedState===null&&p5(f,p);break;default:p5(f,p)}}function m5(f,p){if(f.subtreeFlags&67108864)for(f=f.child;f!==null;){e:{var x=f,k=p;switch(x.tag){case 4:pee(x,k);break e;case 22:x.memoizedState===null&&m5(x,k);break e;default:m5(x,k)}}f=f.sibling}}function mee(f){var p=f.alternate;p!==null&&(f.alternate=null,mee(p)),f.child=null,f.deletions=null,f.sibling=null,f.tag===5&&(p=f.stateNode,p!==null&&hc(p)),f.stateNode=null,f.return=null,f.dependencies=null,f.memoizedProps=null,f.memoizedState=null,f.pendingProps=null,f.stateNode=null,f.updateQueue=null}var li=null,la=!1;function xu(f,p,x){for(x=x.child;x!==null;)gee(f,p,x),x=x.sibling}function gee(f,p,x){if(Qe&&typeof Qe.onCommitFiberUnmount=="function")try{Qe.onCommitFiberUnmount(Fe,x)}catch{}switch(x.tag){case 26:yr||Go(x,p),xu(f,p,x),x.memoizedState?x.memoizedState.count--:x.stateNode&&!yr&&(x=x.stateNode,x.parentNode.removeChild(x));break;case 27:yr||Go(x,p),BS(x);var k=li,R=la;Ep(x.type)&&(li=x.stateNode,la=!1),xu(f,p,x),xte(x.stateNode,x.type,x.memoizedProps),li=k,la=R;break;case 5:yr||Go(x,p),BS(x);case 6:if(x.tag===6&&BS(x),k=li,R=la,li=null,xu(f,p,x),li=k,la=R,li!==null)if(la)try{(li.nodeType===9?li.body:li.nodeName==="HTML"?li.ownerDocument.body:li).removeChild(x.stateNode),En=!0}catch(L){Er(x,p,L)}else try{li.removeChild(x.stateNode),En=!0}catch(L){Er(x,p,L)}break;case 18:li!==null&&(la?(f=li,ote(f.nodeType===9?f.body:f.nodeName==="HTML"?f.ownerDocument.body:f,x.stateNode),Av(f)):ote(li,x.stateNode));break;case 4:k=li,R=la,li=x.stateNode.containerInfo,la=!0,xu(f,p,x),li=k,la=R;break;case 0:case 11:case 14:case 15:bp(2,x,p),yr||bp(4,x,p),xu(f,p,x);break;case 1:yr||(Go(x,p),k=x.stateNode,typeof k.componentWillUnmount=="function"&&nee(x,p,k)),xu(f,p,x);break;case 21:xu(f,p,x);break;case 22:yr=(k=yr)||x.memoizedState!==null,xu(f,p,x),yr=k;break;case 30:Go(x,p),xu(f,p,x);break;case 7:yr||Go(x,p),xu(f,p,x);break;default:xu(f,p,x)}}function yee(f,p){if(p.memoizedState===null&&(f=p.alternate,f!==null&&(f=f.memoizedState,f!==null))){f=f.dehydrated;try{Av(f)}catch(x){Er(p,p.return,x)}}}function bee(f,p){if(p.memoizedState===null&&(f=p.alternate,f!==null&&(f=f.memoizedState,f!==null&&(f=f.dehydrated,f!==null))))try{Av(f)}catch(x){Er(p,p.return,x)}}function V3e(f){switch(f.tag){case 31:case 13:case 19:var p=f.stateNode;return p===null&&(p=f.stateNode=new fee),p;case 22:return f=f.stateNode,p=f._retryCache,p===null&&(p=f._retryCache=new fee),p;default:throw Error(r(435,f.tag))}}function wO(f,p){var x=V3e(f);p.forEach(function(k){if(!x.has(k)){x.add(k);var R=n5e.bind(null,f,k);k.then(R,R)}})}function Ls(f,p,x){var k=p.deletions;if(k!==null)for(var R=0;R<k.length;R++){var L=k[R],V=f,oe=p,ye=oe;e:for(;ye!==null;){switch(ye.tag){case 27:if(Ep(ye.type)){li=ye.stateNode,la=!1;break e}break;case 5:li=ye.stateNode,la=!1;break e;case 3:case 4:li=ye.stateNode.containerInfo,la=!0;break e}ye=ye.return}if(li===null)throw Error(r(160));gee(V,oe,L),li=null,la=!1,V=L.alternate,V!==null&&(V.return=null),L.return=null}if(p.subtreeFlags&13886)for(p=p.child;p!==null;)vee(p,f,x),p=p.sibling}var wu=null;function vee(f,p,x){var k=f.alternate,R=f.flags;switch(f.tag){case 0:case 11:case 14:case 15:if(R&4&&(k=f.updateQueue,k=k!==null?k.events:null,k!==null))for(var L=0;L<k.length;L++){var V=k[L];V.ref.impl=V.nextImpl}Ls(p,f,x),Is(f),R&4&&(bp(3,f,f.return),FS(3,f),bp(5,f,f.return));break;case 1:Ls(p,f,x),Is(f),R&512&&(yr||k===null||Go(k,k.return)),R&64&&So&&(f=f.updateQueue,f!==null&&(p=f.callbacks,p!==null&&(x=f.shared.hiddenCallbacks,f.shared.hiddenCallbacks=x===null?p:x.concat(p))));break;case 26:if(L=wu,Ls(p,f,x),Is(f),R&512&&(yr||k===null||Go(k,k.return)),R&4)if(R=k!==null?k.memoizedState:null,x=f.memoizedState,k===null)if(x===null)if(f.stateNode===null)if(So)f.stateNode=nte(f.type,f.memoizedProps,p.containerInfo,f);else{e:{p=f.type,x=f.memoizedProps,R=L.ownerDocument||L;t:switch(p){case"title":k=R.getElementsByTagName("title")[0],(!k||k[rr]||k[Hr]||k.namespaceURI==="http://www.w3.org/2000/svg"||k.hasAttribute("itemprop"))&&(k=R.createElement(p),R.head.insertBefore(k,R.querySelector("head > title"))),Ko(k,p,x),k[Hr]=f,si(k),p=k;break e;case"link":if(L=Tte("link","href",R).get(p+(x.href||""))){for(V=0;V<L.length;V++)if(k=L[V],k.getAttribute("href")===(x.href==null||x.href===""?null:x.href)&&k.getAttribute("rel")===(x.rel==null?null:x.rel)&&k.getAttribute("title")===(x.title==null?null:x.title)&&k.getAttribute("crossorigin")===(x.crossOrigin==null?null:x.crossOrigin)){L.splice(V,1);break t}}k=R.createElement(p),Ko(k,p,x),R.head.appendChild(k);break;case"meta":if(L=Tte("meta","content",R).get(p+(x.content||""))){for(V=0;V<L.length;V++)if(k=L[V],k.getAttribute("content")===(x.content==null?null:""+x.content)&&k.getAttribute("name")===(x.name==null?null:x.name)&&k.getAttribute("property")===(x.property==null?null:x.property)&&k.getAttribute("http-equiv")===(x.httpEquiv==null?null:x.httpEquiv)&&k.getAttribute("charset")===(x.charSet==null?null:x.charSet)){L.splice(V,1);break t}}k=R.createElement(p),Ko(k,p,x),R.head.appendChild(k);break;default:throw Error(r(468,p))}k[Hr]=f,si(k),p=k}f.stateNode=p}else So||J5(L,f.type,f.stateNode);else f.stateNode=Ete(L,x,f.memoizedProps);else R!==x?(R===null?(p=k.stateNode,p===null||yr||p.parentNode.removeChild(p)):R.count--,x===null?So||J5(L,f.type,f.stateNode):Ete(L,x,f.memoizedProps)):x===null&&f.stateNode!==null&&i5(f,f.memoizedProps,k.memoizedProps);break;case 27:Ls(p,f,x),Is(f),R&512&&(yr||k===null||Go(k,k.return)),k!==null&&R&4&&i5(f,f.memoizedProps,k.memoizedProps);break;case 5:if(L=kc,kc=!1,Ls(p,f,x),kc=L,Is(f),R&512&&(yr||k===null||Go(k,k.return)),f.flags&32){p=f.stateNode;try{za(p,""),En=!0}catch(ze){Er(f,f.return,ze)}}R&4&&f.stateNode!=null&&(p=f.memoizedProps,i5(f,p,k!==null?k.memoizedProps:p)),R&1024&&(f5=!0);break;case 6:if(Ls(p,f,x),Is(f),R&4){if(f.stateNode===null)throw Error(r(162));p=f.memoizedProps,x=f.stateNode;try{x.nodeValue=p,En=!0}catch(ze){Er(f,f.return,ze)}}break;case 3:if(En=!1,jO=null,L=wu,wu=QS(p.containerInfo),Ls(p,f,x),wu=L,Is(f),R&4&&k!==null&&k.memoizedState.isDehydrated)try{Av(p.containerInfo)}catch(ze){Er(f,f.return,ze)}f5&&(f5=!1,xee(f)),En=!1;break;case 4:R=kc,kc=So,k=Gg(),L=wu,wu=QS(f.stateNode.containerInfo),Ls(p,f,x),Is(f),wu=L,En&&HS&&(vO=!0),En=k,kc=R;break;case 12:Ls(p,f,x),Is(f);break;case 31:Ls(p,f,x),Is(f),R&4&&(p=f.updateQueue,p!==null&&(f.updateQueue=null,wO(f,p)));break;case 13:Ls(p,f,x),Is(f),f.child.flags&8192&&f.memoizedState!==null!=(k!==null&&k.memoizedState!==null)&&(CO=ln()),R&4&&(p=f.updateQueue,p!==null&&(f.updateQueue=null,wO(f,p)));break;case 22:L=f.memoizedState!==null,V=k!==null&&k.memoizedState!==null;var oe=So,ye=yr,Ne=kc;So=oe||L,kc=Ne||L,yr=ye||V,Ls(p,f,x),yr=ye,kc=Ne,So=oe,Is(f),R&8192&&(p=f.stateNode,p._visibility=L?p._visibility&-2:p._visibility|1,!L||k===null||V||So||yr||(p=V||yr,x=So,k=yr,So=L||So,yr=p,vp(f,2),So=x,yr=k),!L&&kc||p5(f,L)),R&4&&(p=f.updateQueue,p!==null&&(x=p.retryQueue,x!==null&&(p.retryQueue=null,wO(f,x))));break;case 19:Ls(p,f,x),Is(f),R&4&&(p=f.updateQueue,p!==null&&(f.updateQueue=null,wO(f,p)));break;case 30:R&512&&(yr||k===null||Go(k,k.return)),R=Gg(),L=HS,V=(x&335544064)===x,oe=f.memoizedProps,HS=V&&Xd(oe.default,oe.update)!=="none",Ls(p,f,x),Is(f),V&&k!==null&&En&&(f.flags|=4),HS=L,En=R;break;case 21:break;case 7:R&512&&(yr||k===null||Go(k,k.return)),k&&k.stateNode!==null&&(k.stateNode._fragmentFiber=f);default:Ls(p,f,x),Is(f)}}function Is(f){var p=f.flags;if(p&2){try{for(var x,k=f.return;k!==null;){if(iee(k)){x=k;break}k=k.return}k=null;for(var R=f.return;R!==null;){if(n5(R)){var L=R.stateNode;k===null?k=[L]:k.push(L)}if(t5(R))break;R=R.return}var V=k;if(x==null)throw Error(r(160));switch(x.tag){case 27:var oe=x.stateNode,ye=o5(f);mO(f,ye,oe,V);break;case 5:var Ne=x.stateNode;x.flags&32&&(za(Ne,""),x.flags&=-33);var ze=o5(f);mO(f,ze,Ne,V);break;case 3:case 4:var Ge=x.stateNode.containerInfo,Re=o5(f);s5(f,Re,Ge,V);break;default:throw Error(r(161))}}catch(je){Er(f,f.return,je)}f.flags&=-3}p&4096&&(f.flags&=-4097)}function xee(f){if(f.subtreeFlags&1024)for(f=f.child;f!==null;){var p=f;xee(p),p.tag===5&&p.flags&1024&&(p=p.stateNode,Tv=!0,p.reset(),Tv=!1),f=f.sibling}}function uv(f,p){if(p.subtreeFlags&9270)for(p=p.child;p!==null;)wee(p,f),p=p.sibling;else dee(p)}function wee(f,p){var x=f.alternate;if(x===null)a5(f,!1);else switch(f.tag){case 3:if(h5=Cc=!1,aee(),uv(p,f),!Cc&&!vO){if(f=wc,f!==null)for(var k=0;k<f.length;k+=3){x=f[k];var R=f[k+1];lte(x,f[k+2]),x=x.ownerDocument.documentElement,x!==null&&x.animate({opacity:[0,0],pointerEvents:["none","none"]},{duration:0,fill:"forwards",pseudoElement:"::view-transition-group("+R+")"})}f=p.containerInfo,f=f.nodeType===9?f.documentElement:f.ownerDocument.documentElement,f!==null&&f.style.viewTransitionName===""&&(f.style.viewTransitionName="none",f.animate({opacity:[0,0],pointerEvents:["none","none"]},{duration:0,fill:"forwards",pseudoElement:"::view-transition-group(root)"}),f.animate({width:[0,0],height:[0,0]},{duration:0,fill:"forwards",pseudoElement:"::view-transition"})),h5=!0}wc=null;break;case 5:uv(p,f);break;case 4:k=Cc,Cc=!1,uv(p,f),Cc&&(vO=!0),Cc=k;break;case 22:f.memoizedState===null&&(x.memoizedState!==null?a5(f,!1):uv(p,f));break;case 30:k=Cc,R=aee(),Cc=!1,uv(p,f),Cc&&(f.flags|=4);var L=f.memoizedProps,V=f.stateNode;p=Yd(L,V),V=Yd(x.memoizedProps,V);var oe=Xd(L.default,L.update);oe==="none"?p=!1:(L=x.memoizedState,x.memoizedState=null,x=f.child,aa=0,p=d5(f,x,p,V,oe,L,!0),aa!==(L===null?0:L.length)&&(f.flags|=32)),(f.flags&4)!==0&&p?(gv(f,f.memoizedProps.onUpdate),wc=R):R!==null&&(R.push.apply(R,wc),wc=R),Cc=(f.flags&32)!==0?!0:k;break;default:uv(p,f)}}function Ec(f,p){if(p.subtreeFlags&8772)for(p=p.child;p!==null;)hee(f,p.alternate,p),p=p.sibling}function vp(f,p){for(f=f.child;f!==null;){var x=f,k=p;switch(x.tag){case 0:case 11:case 14:case 15:bp(4,x,x.return),vp(x,k);break;case 1:Go(x,x.return);var R=x.stateNode;typeof R.componentWillUnmount=="function"&&nee(x,x.return,R),vp(x,k);break;case 27:(k&2)!==0&&xte(x.stateNode,x.type,x.memoizedProps);case 5:Go(x,x.return),x.tag!==5&&x.tag!==27||BS(x),vp(x,k);break;case 6:BS(x);break;case 26:Go(x,x.return),R=x.stateNode,x.memoizedState!==null||R===null||yr||R.parentNode.removeChild(R),vp(x,k);break;case 22:x.memoizedState===null&&vp(x,k);break;case 30:Go(x,x.return),vp(x,k);break;case 7:Go(x,x.return);default:vp(x,k)}f=f.sibling}}function Su(f,p,x){for(x=(p.subtreeFlags&8772)!==0?x:x&-2,p=p.child;p!==null;){var k=p.alternate,R=f,L=p,V=L.flags,oe=(x&1)!==0;switch(L.tag){case 0:case 11:case 15:Su(R,L,x),FS(4,L);break;case 1:if(Su(R,L,x),k=L,R=k.stateNode,typeof R.componentDidMount=="function")try{R.componentDidMount()}catch(ze){Er(k,k.return,ze)}if(k=L,R=k.updateQueue,R!==null){var ye=k.stateNode;try{var Ne=R.shared.hiddenCallbacks;if(Ne!==null)for(R.shared.hiddenCallbacks=null,R=0;R<Ne.length;R++)UZ(Ne[R],ye)}catch(ze){Er(k,k.return,ze)}}oe&&V&64&&tee(L),xc(L,L.return);break;case 27:(x&2)!==0&&oee(L);case 5:L.tag!==5&&L.tag!==27||ree(L),Su(R,L,x),oe&&k===null&&V&4&&r5(L),xc(L,L.return);break;case 6:ree(L);break;case 26:ye=L.stateNode,L.memoizedState!==null||ye===null||So||J5(QS(ye.ownerDocument),L.type,ye),Su(R,L,x),oe&&k===null&&V&4&&r5(L),xc(L,L.return);break;case 12:Su(R,L,x);break;case 31:Su(R,L,x),oe&&V&4&&yee(R,L);break;case 13:Su(R,L,x),oe&&V&4&&bee(R,L);break;case 22:L.memoizedState===null&&Su(R,L,x),xc(L,L.return);break;case 30:Su(R,L,x),xc(L,L.return);break;case 7:xc(L,L.return);default:Su(R,L,x)}p=p.sibling}}function g5(f,p){var x=null;f!==null&&f.memoizedState!==null&&f.memoizedState.cachePool!==null&&(x=f.memoizedState.cachePool.pool),f=null,p.memoizedState!==null&&p.memoizedState.cachePool!==null&&(f=p.memoizedState.cachePool.pool),f!==x&&(f!=null&&f.refCount++,x!=null&&AS(x))}function y5(f,p){f=null,p.alternate!==null&&(f=p.alternate.memoizedState.cache),p=p.memoizedState.cache,p!==f&&(p.refCount++,f!=null&&AS(f))}function kl(f,p,x,k){var R=(x&335544064)===x;if(p.subtreeFlags&(R?10262:10256))for(p=p.child;p!==null;)See(f,p,x,k),p=p.sibling;else R&&cee(p)}function See(f,p,x,k){var R=(x&335544064)===x;R&&p.alternate===null&&p.return!==null&&p.return.alternate!==null&&bO(p);var L=p.flags;switch(p.tag){case 0:case 11:case 15:kl(f,p,x,k),L&2048&&FS(9,p);break;case 1:kl(f,p,x,k);break;case 3:kl(f,p,x,k),R&&h5&&(f=f.containerInfo,f=f.nodeType===9?f.body:f.nodeName==="HTML"?f.ownerDocument.body:f,f.style.viewTransitionName==="root"&&(f.style.viewTransitionName=""),f=f.ownerDocument.documentElement,f!==null&&f.style.viewTransitionName==="none"&&(f.style.viewTransitionName="")),L&2048&&(L=null,p.alternate!==null&&(L=p.alternate.memoizedState.cache),p=p.memoizedState.cache,p!==L&&(p.refCount++,L!=null&&AS(L)));break;case 12:if(L&2048){kl(f,p,x,k),L=p.stateNode;try{var V=p.memoizedProps,oe=V.id,ye=V.onPostCommit;typeof ye=="function"&&ye(oe,p.alternate===null?"mount":"update",L.passiveEffectDuration,-0)}catch(Ne){Er(p,p.return,Ne)}}else kl(f,p,x,k);break;case 31:kl(f,p,x,k);break;case 13:kl(f,p,x,k);break;case 23:break;case 22:V=p.stateNode,oe=p.alternate,p.memoizedState!==null?(R&&oe!==null&&oe.memoizedState===null&&bO(oe),V._visibility&2?kl(f,p,x,k):US(f,p)):(R&&oe!==null&&oe.memoizedState!==null&&bO(p),V._visibility&2?kl(f,p,x,k):(V._visibility|=2,cv(f,p,x,k,(p.subtreeFlags&10256)!==0||!1))),L&2048&&g5(oe,p);break;case 24:kl(f,p,x,k),L&2048&&y5(p.alternate,p);break;case 30:R&&(L=p.alternate,L!==null&&(Sc(L.child,!0),Sc(p.child,!0))),kl(f,p,x,k);break;default:kl(f,p,x,k)}}function cv(f,p,x,k,R){for(R=R&&((p.subtreeFlags&10256)!==0||!1),p=p.child;p!==null;){var L=f,V=p,oe=x,ye=k,Ne=V.flags;switch(V.tag){case 0:case 11:case 15:cv(L,V,oe,ye,R),FS(8,V);break;case 23:break;case 22:var ze=V.stateNode;V.memoizedState!==null?ze._visibility&2?cv(L,V,oe,ye,R):US(L,V):(ze._visibility|=2,cv(L,V,oe,ye,R)),R&&Ne&2048&&g5(V.alternate,V);break;case 24:cv(L,V,oe,ye,R),R&&Ne&2048&&y5(V.alternate,V);break;default:cv(L,V,oe,ye,R)}p=p.sibling}}function US(f,p){if(p.subtreeFlags&10256)for(p=p.child;p!==null;){var x=f,k=p,R=k.flags;switch(k.tag){case 22:US(x,k),R&2048&&g5(k.alternate,k);break;case 24:US(x,k),R&2048&&y5(k.alternate,k);break;default:US(x,k)}p=p.sibling}}var v0=8192;function x0(f,p,x){if(f.subtreeFlags&v0)for(f=f.child;f!==null;)kee(f,p,x),f=f.sibling}function kee(f,p,x){switch(f.tag){case 26:x0(f,p,x),f.flags&v0&&(f.memoizedState!==null?X5e(x,wu,f.memoizedState,f.memoizedProps):(f=f.stateNode,(p&335544128)===p&&Mte(x,f)));break;case 5:x0(f,p,x),f.flags&v0&&(f=f.stateNode,(p&335544128)===p&&Mte(x,f));break;case 3:case 4:var k=wu;wu=QS(f.stateNode.containerInfo),x0(f,p,x),wu=k;break;case 22:f.memoizedState===null&&(k=f.alternate,k!==null&&k.memoizedState!==null?(k=v0,v0=16777216,x0(f,p,x),v0=k):x0(f,p,x));break;case 30:if((f.flags&v0)!==0&&(k=f.memoizedProps.name,k!=null&&k!=="auto")){var R=f.stateNode;R.paired=null,Ha===null&&(Ha=new Map),Ha.set(k,R)}x0(f,p,x);break;default:x0(f,p,x)}}function Cee(f){var p=f.alternate;if(p!==null&&(f=p.child,f!==null)){p.child=null;do p=f.sibling,f.sibling=null,f=p;while(f!==null)}}function VS(f){var p=f.deletions;if((f.flags&16)!==0){if(p!==null)for(var x=0;x<p.length;x++){var k=p[x];ko=k,Tee(k,f)}Cee(f)}if(f.subtreeFlags&10256)for(f=f.child;f!==null;)Eee(f),f=f.sibling}function Eee(f){switch(f.tag){case 0:case 11:case 15:VS(f),f.flags&2048&&bp(9,f,f.return);break;case 3:VS(f);break;case 12:VS(f);break;case 22:var p=f.stateNode;f.memoizedState!==null&&p._visibility&2&&(f.return===null||f.return.tag!==13)?(p._visibility&=-3,SO(f)):VS(f);break;default:VS(f)}}function SO(f){var p=f.deletions;if((f.flags&16)!==0){if(p!==null)for(var x=0;x<p.length;x++){var k=p[x];ko=k,Tee(k,f)}Cee(f)}for(f=f.child;f!==null;){switch(p=f,p.tag){case 0:case 11:case 15:bp(8,p,p.return),SO(p);break;case 22:x=p.stateNode,x._visibility&2&&(x._visibility&=-3,SO(p));break;default:SO(p)}f=f.sibling}}function Tee(f,p){for(;ko!==null;){var x=ko;switch(x.tag){case 0:case 11:case 15:bp(8,x,p);break;case 23:case 22:if(x.memoizedState!==null&&x.memoizedState.cachePool!==null){var k=x.memoizedState.cachePool.pool;k!=null&&k.refCount++}break;case 24:AS(x.memoizedState.cache)}if(k=x.child,k!==null)k.return=x,ko=k;else e:for(x=f;ko!==null;){k=ko;var R=k.sibling,L=k.return;if(mee(k),k===x){ko=null;break e}if(R!==null){R.return=L,ko=R;break e}ko=L}}}var W3e={getCacheForType:function(f){var p=Vo(Bi),x=p.data.get(f);return x===void 0&&(x=f(),p.data.set(f,x)),x},cacheSignal:function(){return Vo(Bi).controller.signal}},q3e=typeof WeakMap=="function"?WeakMap:Map,dr=0,$r=null,Pn=null,Fn=0,Cr=0,Ua=null,xp=!1,dv=!1,b5=!1,sf=0,bi=0,wp=0,w0=0,kO=0,Va=0,fv=0,WS=null,ua=null,v5=!1,CO=0,Aee=0,EO=1/0,TO=null,Sp=null,fi=0,ku=null,S0=null,Tc=0,x5=0,w5=null,Oee=null,hv=null,pv=null,mv=null,qS=0,AO=null;function Wa(){return(dr&2)!==0&&Fn!==0?Fn&-Fn:fe.T!==null?_5():fc()}function Ree(){if(Va===0)if((Fn&536870912)===0||Tn){var f=er;er<<=1,(er&3932160)===0&&(er=262144),Va=f}else Va=536870912;return f=Wo.current,f!==null&&(f.flags|=32),Va}function gv(f,p){if(p!=null){var x=f.stateNode,k=x.ref;k===null&&(k=x.ref=ute(Yd(f.memoizedProps,x))),pv===null&&(pv=[]),pv.push(p.bind(null,k))}}function ca(f,p,x){(f===$r&&(Cr===2||Cr===9)||f.cancelPendingCommit!==null)&&(yv(f,0),kp(f,Fn,Va,!1)),Ri(f,x),((dr&2)===0||f!==$r)&&(f===$r&&((dr&2)===0&&(w0|=x),bi===4&&kp(f,Fn,Va,!1)),Ac(f))}function Mee(f,p,x){if((dr&6)!==0)throw Error(r(327));var k=!x&&(p&127)===0&&(p&f.expiredLanes)===0||nr(f,p),R=k?Y3e(f,p):k5(f,p,!0),L=k;do{if(R===0){dv&&!k&&kp(f,p,0,!1);break}else{if(x=f.current.alternate,L&&!G3e(x)){R=k5(f,p,!1),L=!1;continue}if(R===2){if(L=p,f.errorRecoveryDisabledLanes&L)var V=0;else V=f.pendingLanes&-536870913,V=V!==0?V:V&536870912?536870912:0;if(V!==0){p=V;e:{var oe=f;R=WS;var ye=oe.current.memoizedState.isDehydrated;if(ye&&(yv(oe,V).flags|=256),V=k5(oe,V,!1),V!==2&&V!==6){if(b5&&!ye){oe.errorRecoveryDisabledLanes|=L,w0|=L,R=4;break e}L=ua,ua=R,L!==null&&(ua===null?ua=L:ua.push.apply(ua,L))}R=V}if(L=!1,R!==2)continue}}if(R===1){yv(f,0),kp(f,p,0,!0);break}e:{switch(k=f,L=R,L){case 0:case 1:throw Error(r(345));case 4:if((p&4194048)!==p&&(p&62914560)!==p)break;case 6:kp(k,p,Va,!xp);break e;case 2:ua=null;break;case 3:case 5:break;default:throw Error(r(329))}if((p&62914560)===p&&(R=CO+300-ln(),10<R)){if(kp(k,p,Va,!xp),cn(k,0,!0)!==0)break e;Tc=p,k.timeoutHandle=H5(_ee.bind(null,k,x,ua,TO,v5,p,Va,w0,fv,xp,L,"Throttled",-0,0),R);break e}_ee(k,x,ua,TO,v5,p,Va,w0,fv,xp,L,null,-0,0)}}break}while(!0);Ac(f)}function _ee(f,p,x,k,R,L,V,oe,ye,Ne,ze,Ge,Re,je){f.timeoutHandle=-1;var vt=p.subtreeFlags,jt=(L&335544064)===L;if(Ge=null,(jt||vt&8192||(vt&16785408)===16785408)&&(Ge={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:_s},Ha=null,kee(p,L,Ge),jt&&(vt=Ge,jt=f.containerInfo,jt=(jt.nodeType===9?jt:jt.ownerDocument).__reactViewTransition,jt!=null&&(vt.count++,vt.waitingForViewTransition=!0,vt=ek.bind(vt),jt.finished.then(vt,vt))),vt=(L&62914560)===L?CO-ln():(L&4194048)===L?Aee-ln():0,vt=Q5e(Ge,vt),vt!==null)){Tc=L,f.cancelPendingCommit=vt(zee.bind(null,f,p,L,x,k,R,V,oe,ye,Ne,ze,Ge,null,Re,je)),kp(f,L,V,!Ne);return}zee(f,p,L,x,k,R,V,oe,ye,Ne,ze,Ge)}function G3e(f){for(var p=f;;){var x=p.tag;if((x===0||x===11||x===15)&&p.flags&16384&&(x=p.updateQueue,x!==null&&(x=x.stores,x!==null)))for(var k=0;k<x.length;k++){var R=x[k],L=R.getSnapshot;R=R.value;try{if(!Fa(L(),R))return!1}catch{return!1}}if(x=p.child,p.subtreeFlags&16384&&x!==null)x.return=p,p=x;else{if(p===f)break;for(;p.sibling===null;){if(p.return===null||p.return===f)return!0;p=p.return}p.sibling.return=p.return,p=p.sibling}}return!0}function kp(f,p,x,k){p=bo(f,p),p&=~kO,p&=~w0,f.suspendedLanes|=p,f.pingedLanes&=~p,k&&(f.warmLanes|=p),k=f.expirationTimes;for(var R=p;0<R;){var L=31-qt(R),V=1<<L;k[L]=-1,R&=~V}x!==0&&Uo(f,x,p)}function OO(){return(dr&6)===0?(GS(0),!1):!0}function S5(){if(Pn!==null){if(Cr===0)var f=Pn.return;else f=Pn,Jd=u0=null,M3(f),rv=null,MS=0,f=Pn;for(;f!==null;)eee(f.alternate,f),f=f.return;Pn=null}}function yv(f,p){var x=f.timeoutHandle;return x!==-1&&(f.timeoutHandle=-1,y5e(x)),x=f.cancelPendingCommit,x!==null&&(f.cancelPendingCommit=null,x()),Tc=0,S5(),$r=f,Pn=x=Qd(f.current,null),Fn=p,Cr=0,Ua=null,xp=!1,dv=nr(f,p),b5=!1,fv=Va=kO=w0=wp=bi=0,ua=WS=null,v5=!1,sf=bo(f,p),jA(),x}function Nee(f,p){mn=null,fe.H=aO,p===nv||p===GA?(p=zZ(),Cr=3):p===y3?(p=zZ(),Cr=4):Cr=p===W3?8:p!==null&&typeof p=="object"&&typeof p.then=="function"?6:1,Ua=p,Pn===null&&(bi=1,lO(f,vl(p,f.current)))}function Lee(){var f=Wo.current;return f===null?!0:(Fn&4194048)===Fn?ps===null:(Fn&62914560)===Fn||(Fn&536870912)!==0?f===ps:!1}function Iee(){var f=fe.H;return fe.H=aO,f===null?aO:f}function Pee(){var f=fe.A;return fe.A=W3e,f}function RO(){bi=4,xp||(Fn&4194048)!==Fn&&Wo.current!==null||(dv=!0),(wp&134217727)===0&&(w0&134217727)===0||$r===null||kp($r,Fn,Va,!1)}function k5(f,p,x){var k=dr;dr|=2;var R=Iee(),L=Pee();($r!==f||Fn!==p)&&(TO=null,yv(f,p)),p=!1;var V=bi;e:do try{if(Cr!==0&&Pn!==null){var oe=Pn,ye=Ua;switch(Cr){case 8:S5(),V=6;break e;case 3:case 2:case 9:case 6:Wo.current===null&&(p=!0);var Ne=Cr;if(Cr=0,Ua=null,bv(f,oe,ye,Ne),x&&dv){V=0;break e}break;default:Ne=Cr,Cr=0,Ua=null,bv(f,oe,ye,Ne)}}K3e(),V=bi;break}catch(ze){Nee(f,ze)}while(!0);return p&&f.shellSuspendCounter++,Jd=u0=null,dr=k,fe.H=R,fe.A=L,Pn===null&&($r=null,Fn=0,jA()),V}function K3e(){for(;Pn!==null;)jee(Pn)}function Y3e(f,p){var x=dr;dr|=2;var k=Iee(),R=Pee();$r!==f||Fn!==p?(TO=null,EO=ln()+500,yv(f,p)):dv=nr(f,p);e:do try{if(Cr!==0&&Pn!==null){p=Pn;var L=Ua;t:switch(Cr){case 1:Cr=0,Ua=null,bv(f,p,L,1);break;case 2:case 9:if(DZ(L)){Cr=0,Ua=null,Dee(p);break}p=function(){Cr!==2&&Cr!==9||$r!==f||(Cr=7),Ac(f)},L.then(p,p);break e;case 3:Cr=7;break e;case 4:Cr=5;break e;case 7:DZ(L)?(Cr=0,Ua=null,Dee(p)):(Cr=0,Ua=null,bv(f,p,L,7));break;case 5:var V=null;switch(Pn.tag){case 26:V=Pn.memoizedState;case 5:case 27:var oe=Pn;if(V?Ote(V):oe.stateNode.complete){Cr=0,Ua=null;var ye=oe.sibling;if(ye!==null)Pn=ye;else{var Ne=oe.return;Ne!==null?(Pn=Ne,MO(Ne)):Pn=null}break t}}Cr=0,Ua=null,bv(f,p,L,5);break;case 6:Cr=0,Ua=null,bv(f,p,L,6);break;case 8:S5(),bi=6;break e;default:throw Error(r(462))}}X3e();break}catch(ze){Nee(f,ze)}while(!0);return Jd=u0=null,fe.H=k,fe.A=R,dr=x,Pn!==null?0:($r=null,Fn=0,jA(),bi)}function X3e(){for(;Pn!==null&&!Vn();)jee(Pn)}function jee(f){var p=ZJ(f.alternate,f,sf);f.memoizedProps=f.pendingProps,p===null?MO(f):Pn=p}function Dee(f){var p=f,x=p.alternate;switch(p.tag){case 15:case 0:p=WJ(x,p,p.pendingProps,p.type,void 0,Fn);break;case 11:p=WJ(x,p,p.pendingProps,p.type.render,p.ref,Fn);break;case 5:M3(p);var k=p;k===wo&&(Tn?(HA(k),k.tag===5&&k.stateNode!=null&&(Vr=k.stateNode)):(HA(k),Tn=!0));default:eee(x,p),p=Pn=TZ(p,sf),p=ZJ(x,p,sf)}f.memoizedProps=f.pendingProps,p===null?MO(f):Pn=p}function bv(f,p,x,k){Jd=u0=null,M3(p),rv=null,MS=0;var R=p.return;try{if(D3e(f,R,p,x,Fn)){bi=1,lO(f,vl(x,f.current)),Pn=null;return}}catch(L){if(R!==null)throw Pn=R,L;bi=1,lO(f,vl(x,f.current)),Pn=null;return}p.flags&32768?(Tn||k===1?f=!0:dv||(Fn&536870912)!==0?f=!1:(xp=f=!0,(k===2||k===9||k===3||k===6)&&(k=Wo.current,k!==null&&k.tag===13&&(k.flags|=16384))),$ee(p,f)):MO(p)}function MO(f){var p=f;do{if((p.flags&32768)!==0){$ee(p,xp);return}f=p.return;var x=B3e(p.alternate,p,sf);if(x!==null){Pn=x;return}if(p=p.sibling,p!==null){Pn=p;return}Pn=p=f}while(p!==null);bi===0&&(bi=5)}function $ee(f,p){do{var x=H3e(f.alternate,f);if(x!==null){x.flags&=32767,Pn=x;return}if(x=f.return,x!==null&&(x.flags|=32768,x.subtreeFlags=0,x.deletions=null),!p&&(f=f.sibling,f!==null)){Pn=f;return}Pn=f=x}while(f!==null);bi=6,Pn=null}function zee(f,p,x,k,R,L,V,oe,ye,Ne,ze,Ge){f.cancelPendingCommit=null;do _O();while(fi!==0);if((dr&6)!==0)throw Error(r(327));if(p!==null){if(p===f.current)throw Error(r(177));f===$r&&(Pn=$r=null,Fn=0),S0=p,ku=f,Tc=x,w5=R,Oee=k,Q3e(f,p,x,V,oe,ye,Ge)}}function Q3e(f,p,x,k,R,L,V){var oe=p.lanes|p.childLanes;if(x5=oe,oe|=i3,La(f,x,oe,k,R,L),pv=null,(x&335544064)===x?(mv=E3e(f),k=10262):(mv=null,k=10256),(p.subtreeFlags&k)!==0||(p.flags&k)!==0?(f.callbackNode=null,f.callbackPriority=0,r5e(Ht,function(){return A5(),null})):(f.callbackNode=null,f.callbackPriority=0),gO=!1,k=(p.flags&13878)!==0,(p.subtreeFlags&13878)!==0||k){k=fe.T,fe.T=null,R=se.p,se.p=2,L=dr,dr|=4;try{U3e(f,p,x)}finally{dr=L,se.p=R,fe.T=k}}fi=1,gO?hv=k5e(V,f.containerInfo,mv,C5,E5,J3e,T5,A5,Z3e):(C5(),E5(),T5())}function Z3e(f){if(fi!==0){var p=ku.onRecoverableError;p(f,{componentStack:null})}}function J3e(){fi===3&&(fi=0,wee(S0,ku),fi=4)}function C5(){if(fi===1){fi=0;var f=ku,p=S0,x=Tc,k=(p.flags&13878)!==0;if((p.subtreeFlags&13878)!==0||k){k=fe.T,fe.T=null;var R=se.p;se.p=2;var L=dr;dr|=4;try{HS=vO=!1,vee(p,f,x),x=z5;var V=gZ(f.containerInfo),oe=x.focusedElem,ye=x.selectionRange;if(V!==oe&&oe&&oe.ownerDocument&&mZ(oe.ownerDocument.documentElement,oe)){if(ye!==null&&JD(oe)){var Ne=ye.start,ze=ye.end;if(ze===void 0&&(ze=Ne),"selectionStart"in oe)oe.selectionStart=Ne,oe.selectionEnd=Math.min(ze,oe.value.length);else{var Ge=oe.ownerDocument||document,Re=Ge&&Ge.defaultView||window;if(Re.getSelection){var je=Re.getSelection(),vt=oe.textContent.length,jt=Math.min(ye.start,vt),gn=ye.end===void 0?jt:Math.min(ye.end,vt);!je.extend&&jt>gn&&(V=gn,gn=jt,jt=V);var Me=pZ(oe,jt),Ce=pZ(oe,gn);if(Me&&Ce&&(je.rangeCount!==1||je.anchorNode!==Me.node||je.anchorOffset!==Me.offset||je.focusNode!==Ce.node||je.focusOffset!==Ce.offset)){var Pe=Ge.createRange();Pe.setStart(Me.node,Me.offset),je.removeAllRanges(),jt>gn?(je.addRange(Pe),je.extend(Ce.node,Ce.offset)):(Pe.setEnd(Ce.node,Ce.offset),je.addRange(Pe))}}}}for(Ge=[],je=oe;je=je.parentNode;)je.nodeType===1&&Ge.push({element:je,left:je.scrollLeft,top:je.scrollTop});for(typeof oe.focus=="function"&&oe.focus(),oe=0;oe<Ge.length;oe++){var qe=Ge[oe];qe.element.scrollLeft=qe.left,qe.element.scrollTop=qe.top}}Tv=!!$5,z5=$5=null}finally{dr=L,se.p=R,fe.T=k}}f.current=p,fi=2}}function E5(){if(fi===2){fi=0;var f=ku,p=S0,x=(p.flags&8772)!==0;if((p.subtreeFlags&8772)!==0||x){x=fe.T,fe.T=null;var k=se.p;se.p=2;var R=dr;dr|=4;try{hee(f,p.alternate,p)}finally{dr=R,se.p=k,fe.T=x}}fi=3}}function T5(){if(fi===4||fi===3){fi=0;var f=hv;hv=null,Ln();var p=ku,x=S0,k=Tc,R=Oee,L=(k&335544064)===k?10262:10256;if((x.subtreeFlags&L)!==0||(x.flags&L)!==0?fi=5:(fi=0,S0=ku=null,Fee(p,p.pendingLanes)),L=p.pendingLanes,L===0&&(Sp=null),cs(k),x=x.stateNode,Qe&&typeof Qe.onCommitFiberRoot=="function")try{Qe.onCommitFiberRoot(Fe,x,void 0,(x.current.flags&128)===128)}catch{}if(R!==null){x=fe.T,L=se.p,se.p=2,fe.T=null;try{for(var V=p.onRecoverableError,oe=0;oe<R.length;oe++){var ye=R[oe];V(ye.value,{componentStack:ye.stack})}}finally{fe.T=x,se.p=L}}if(R=pv,V=mv,mv=null,R!==null&&(pv=null,V===null&&(V=[]),f!==null))for(ye=0;ye<R.length;ye++)x=(0,R[ye])(V),x!==void 0&&f.finished.finally(x);(Tc&3)!==0&&_O(),Ac(p),L=p.pendingLanes,(k&261930)!==0&&(L&42)!==0?p===AO?qS++:(qS=0,AO=p):(qS=0,AO=null),GS(0)}}function Fee(f,p){(f.pooledCacheLanes&=p)===0&&(p=f.pooledCache,p!=null&&(f.pooledCache=null,AS(p)))}function _O(){return hv!==null&&(hv.skipTransition(),hv=null),C5(),E5(),T5(),A5()}function A5(){if(fi!==5)return!1;var f=ku,p=x5;x5=0;var x=cs(Tc),k=fe.T,R=se.p;try{se.p=32>x?32:x,fe.T=null,x=w5,w5=null;var L=ku,V=Tc;if(fi=0,S0=ku=null,Tc=0,(dr&6)!==0)throw Error(r(331));var oe=dr;if(dr|=4,Eee(L.current),See(L,L.current,V,x),dr=oe,GS(0,!1),Qe&&typeof Qe.onPostCommitFiberRoot=="function")try{Qe.onPostCommitFiberRoot(Fe,L)}catch{}return!0}finally{se.p=R,fe.T=k,Fee(f,p)}}function Bee(f,p,x){p=vl(x,p),p=V3(f.stateNode,p,2),f=pp(f,p,2),f!==null&&(Ri(f,2),Ac(f))}function Er(f,p,x){if(f.tag===3)Bee(f,f,x);else for(;p!==null;){if(p.tag===3){Bee(p,f,x);break}else if(p.tag===1){var k=p.stateNode;if(typeof p.type.getDerivedStateFromError=="function"||typeof k.componentDidCatch=="function"&&(Sp===null||!Sp.has(k))){f=vl(x,f),x=DJ(2),k=pp(p,x,2),k!==null&&($J(x,k,p,f),Ri(k,2),Ac(k));break}}p=p.return}}function O5(f,p,x){var k=f.pingCache;if(k===null){k=f.pingCache=new q3e;var R=new Set;k.set(p,R)}else R=k.get(p),R===void 0&&(R=new Set,k.set(p,R));R.has(x)||(b5=!0,R.add(x),f=e5e.bind(null,f,p,x),p.then(f,f))}function e5e(f,p,x){var k=f.pingCache;k!==null&&k.delete(p),f.pingedLanes|=f.suspendedLanes&x,f.warmLanes&=~x,$r===f&&(Fn&x)===x&&((bi===4||bi===3&&(Fn&62914560)===Fn&&300>ln()-CO)&&(dr&2)===0?yv(f,0):kO|=x,fv===Fn&&(fv=0)),Ac(f)}function Hee(f,p){p===0&&(p=zi()),f=s0(f,p),f!==null&&(Ri(f,p),Ac(f))}function t5e(f){var p=f.memoizedState,x=0;p!==null&&(x=p.retryLane),Hee(f,x)}function n5e(f,p){var x=0;switch(f.tag){case 31:case 13:var k=f.stateNode,R=f.memoizedState;R!==null&&(x=R.retryLane);break;case 19:k=f.stateNode;break;case 22:k=f.stateNode._retryCache;break;default:throw Error(r(314))}k!==null&&k.delete(p),Hee(f,x)}function r5e(f,p){return vn(f,p)}var vv=null,xv=null,R5=!1,NO=!1,M5=!1,Cp=0;function Ac(f){f!==xv&&f.next===null&&(xv===null?vv=xv=f:xv=xv.next=f),NO=!0,R5||(R5=!0,o5e())}function GS(f,p){if(!M5&&NO){M5=!0;do for(var x=!1,k=vv;k!==null;){if(f!==0){var R=k.pendingLanes;if(R===0)var L=0;else{var V=k.suspendedLanes,oe=k.pingedLanes;L=(1<<31-qt(42|f)+1)-1,L&=R&~(V&~oe),L=L&201326741?L&201326741|1:L?L|2:0}L!==0&&(x=!0,qee(k,L))}else L=Fn,L=cn(k,k===$r?L:0,k.cancelPendingCommit!==null||k.timeoutHandle!==-1),(L&3)===0||nr(k,L)||(x=!0,qee(k,L));k=k.next}while(x);M5=!1}}function i5e(){Uee()}function Uee(){NO=R5=!1;var f=0;Cp!==0&&g5e()&&(f=Cp);for(var p=ln(),x=null,k=vv;k!==null;){var R=k.next,L=Vee(k,p);L===0?(k.next=null,x===null?vv=R:x.next=R,R===null&&(xv=x)):(x=k,(f!==0||(L&3)!==0)&&(NO=!0)),k=R}fi!==0&&fi!==5||GS(f),Cp!==0&&(Cp=0)}function Vee(f,p){for(var x=f.suspendedLanes,k=f.pingedLanes,R=f.expirationTimes,L=f.pendingLanes&-62914561;0<L;){var V=31-qt(L),oe=1<<V,ye=R[V];ye===-1?((oe&x)===0||(oe&k)!==0)&&(R[V]=Mr(oe,p)):ye<=p&&(f.expiredLanes|=oe),L&=~oe}if(p=$r,x=Fn,x=cn(f,f===p?x:0,f.cancelPendingCommit!==null||f.timeoutHandle!==-1),k=f.callbackNode,x===0||f===p&&(Cr===2||Cr===9)||f.cancelPendingCommit!==null)return k!==null&&k!==null&&_n(k),f.callbackNode=null,f.callbackPriority=0;if((x&3)===0||nr(f,x)){if(p=x&-x,p===f.callbackPriority)return p;switch(k!==null&&_n(k),cs(x)){case 2:case 8:x=Yt;break;case 32:x=Ht;break;case 268435456:x=Jt;break;default:x=Ht}return k=Wee.bind(null,f),x=vn(x,k),f.callbackPriority=p,f.callbackNode=x,p}return k!==null&&k!==null&&_n(k),f.callbackPriority=2,f.callbackNode=null,2}function Wee(f,p){if(fi!==0&&fi!==5)return f.callbackNode=null,f.callbackPriority=0,null;var x=f.callbackNode;if(_O()&&f.callbackNode!==x)return null;var k=Fn;return k=cn(f,f===$r?k:0,f.cancelPendingCommit!==null||f.timeoutHandle!==-1),k===0?null:(Mee(f,k,p),Vee(f,ln()),f.callbackNode!=null&&f.callbackNode===x?Wee.bind(null,f):null)}function qee(f,p){if(_O())return null;Mee(f,p,!0)}function o5e(){b5e(function(){(dr&6)!==0?vn(Yn,i5e):Uee()})}function _5(){if(Cp===0){var f=f0;f===0&&(f=zn,zn<<=1,(zn&261888)===0&&(zn=256)),Cp=f}return Cp}function Gee(f){return f==null||typeof f=="symbol"||typeof f=="boolean"?null:typeof f=="function"?f:Gd(f)}function s5e(f,p,x,k,R){if(p==="submit"&&x&&x.stateNode===R){var L=Gee((R[Te]||null).action),V=k.submitter;V&&(p=(p=V[Te]||null)?Gee(p.formAction):V.getAttribute("formAction"),p!==null&&(L=p,V=null));var oe=new gr("action","action",null,k,R);f.push({event:oe,listeners:[{instance:null,listener:function(){if(k.defaultPrevented){if(Cp!==0){var ye=new FormData(R,V);z3(x,{pending:!0,data:ye,method:R.method,action:L},null,ye)}}else typeof L=="function"&&(oe.preventDefault(),ye=new FormData(R,V),z3(x,{pending:!0,data:ye,method:R.method,action:L},L,ye))},currentTarget:R}]})}}for(var N5=0;N5<r3.length;N5++){var L5=r3[N5],a5e=L5.toLowerCase(),l5e=L5[0].toUpperCase()+L5.slice(1);vu(a5e,"on"+l5e)}vu(vZ,"onAnimationEnd"),vu(xZ,"onAnimationIteration"),vu(wZ,"onAnimationStart"),vu("dblclick","onDoubleClick"),vu("focusin","onFocus"),vu("focusout","onBlur"),vu(y3e,"onTransitionRun"),vu(b3e,"onTransitionStart"),vu(v3e,"onTransitionCancel"),vu(SZ,"onTransitionEnd"),Pa("onMouseEnter",["mouseout","mouseover"]),Pa("onMouseLeave",["mouseout","mouseover"]),Pa("onPointerEnter",["pointerout","pointerover"]),Pa("onPointerLeave",["pointerout","pointerover"]),ai("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),ai("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),ai("onBeforeInput",["compositionend","keypress","textInput","paste"]),ai("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),ai("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),ai("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var KS="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),u5e=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(KS));function Kee(f,p){p=(p&4)!==0;for(var x=0;x<f.length;x++){var k=f[x],R=k.event;k=k.listeners;e:{var L=void 0;if(p)for(var V=k.length-1;0<=V;V--){var oe=k[V],ye=oe.instance,Ne=oe.currentTarget;if(oe=oe.listener,ye!==L&&R.isPropagationStopped())break e;L=oe,R.currentTarget=Ne;try{L(R)}catch(ze){PA(ze)}R.currentTarget=null,L=ye}else for(V=0;V<k.length;V++){if(oe=k[V],ye=oe.instance,Ne=oe.currentTarget,oe=oe.listener,ye!==L&&R.isPropagationStopped())break e;L=oe,R.currentTarget=Ne;try{L(R)}catch(ze){PA(ze)}R.currentTarget=null,L=ye}}}}function jn(f,p){var x=p[Ze];x===void 0&&(x=p[Ze]=new Set);var k=f+"__bubble";x.has(k)||(Yee(p,f,2,!1),x.add(k))}function I5(f,p,x){var k=0;p&&(k|=4),Yee(x,f,k,p)}var LO="_reactListening"+Math.random().toString(36).slice(2);function P5(f){if(!f[LO]){f[LO]=!0,Ia.forEach(function(x){x!=="selectionchange"&&(u5e.has(x)||I5(x,!1,f),I5(x,!0,f))});var p=f.nodeType===9?f:f.ownerDocument;p===null||p[LO]||(p[LO]=!0,I5("selectionchange",!1,p))}}function Yee(f,p,x,k){switch($te(p)){case 2:var R=t6e;break;case 8:R=n6e;break;default:R=t6}x=R.bind(null,p,x,f),R=void 0,!en||p!=="touchstart"&&p!=="touchmove"&&p!=="wheel"||(R=!0),k?R!==void 0?f.addEventListener(p,x,{capture:!0,passive:R}):f.addEventListener(p,x,!0):R!==void 0?f.addEventListener(p,x,{passive:R}):f.addEventListener(p,x,!1)}function j5(f,p,x,k,R){var L=k;if((p&1)===0&&(p&2)===0&&k!==null)e:for(;;){if(k===null)return;var V=k.tag;if(V===3||V===4){var oe=k.stateNode.containerInfo;if(oe===R)break;if(V===4)for(V=k.return;V!==null;){var ye=V.tag;if((ye===3||ye===4)&&V.stateNode.containerInfo===R)return;V=V.return}for(;oe!==null;){if(V=ia(oe),V===null)return;if(ye=V.tag,ye===5||ye===6||ye===26||ye===27){k=L=V;continue e}oe=oe.parentNode}}k=k.return}n0(function(){var Ne=L,ze=e0(x),Ge=[];e:{var Re=kZ.get(f);if(Re!==void 0){var je=gr,vt=f;switch(f){case"keypress":if(De(x)===0)break e;case"keydown":case"keyup":je=GDe;break;case"focusin":vt="focus",je=GD;break;case"focusout":vt="blur",je=GD;break;case"beforeblur":case"afterblur":je=GD;break;case"click":if(x.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":je=LA;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":je=PDe;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":je=ZDe;break;case vZ:case xZ:case wZ:je=$De;break;case SZ:je=e3e;break;case"scroll":case"scrollend":je=oa;break;case"wheel":je=n3e;break;case"copy":case"cut":case"paste":je=FDe;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":je=eZ;break;case"submit":je=XDe;break;case"toggle":case"beforetoggle":je=i3e}var jt=(p&4)!==0,gn=!jt&&(f==="scroll"||f==="scrollend"),Me=jt?Re!==null?Re+"Capture":null:Re;jt=[];for(var Ce=Ne,Pe;Ce!==null;){var qe=Ce;if(Pe=qe.stateNode,qe=qe.tag,qe!==5&&qe!==26&&qe!==27||Pe===null||Me===null||(qe=Je(Ce,Me),qe!=null&&jt.push(YS(Ce,qe,Pe))),gn)break;Ce=Ce.return}0<jt.length&&(Re=new je(Re,vt,null,x,ze),Ge.push({event:Re,listeners:jt}))}}if((p&7)===0){e:{if(je=f==="mouseover"||f==="pointerover",Re=f==="mouseout"||f==="pointerout",je&&x!==Jg&&(vt=x.relatedTarget||x.fromElement)&&(ia(vt)||vt[Xe]))break e;(Re||je)&&(vt=ze.window===ze?ze:(je=ze.ownerDocument)?je.defaultView||je.parentWindow:window,Re?(je=x.relatedTarget||x.toElement,Re=Ne,je=je?ia(je):null,je!==null&&(gn=o(je),jt=je.tag,je!==gn||jt!==5&&jt!==27&&jt!==6)&&(je=null)):(Re=null,je=Ne),Re!==je&&(jt=LA,qe="onMouseLeave",Me="onMouseEnter",Ce="mouse",(f==="pointerout"||f==="pointerover")&&(jt=eZ,qe="onPointerLeave",Me="onPointerEnter",Ce="pointer"),gn=Re==null?vt:mu(Re),Pe=je==null?vt:mu(je),vt=new jt(qe,Ce+"leave",Re,x,ze),vt.target=gn,vt.relatedTarget=Pe,qe=null,ia(ze)===Ne&&(jt=new jt(Me,Ce+"enter",je,x,ze),jt.target=Pe,jt.relatedTarget=gn,qe=jt),gn=qe,jt=Re&&je?O(Re,je,c5e):null,Re!==null&&Xee(Ge,vt,Re,jt,!1),je!==null&&gn!==null&&Xee(Ge,gn,je,jt,!0)))}e:{if(Re=Ne?mu(Ne):window,je=Re.nodeName&&Re.nodeName.toLowerCase(),je==="select"||je==="input"&&Re.type==="file")var Tt=lZ;else if(sZ(Re))if(uZ)Tt=p3e;else{Tt=f3e;var Bn=d3e}else je=Re.nodeName,!je||je.toLowerCase()!=="input"||Re.type!=="checkbox"&&Re.type!=="radio"?Ne&&ip(Ne.elementType)&&(Tt=lZ):Tt=h3e;if(Tt&&(Tt=Tt(f,Ne))){aZ(Ge,Tt,x,ze);break e}Bn&&Bn(f,Re,Ne)}switch(Bn=Ne?mu(Ne):window,f){case"focusin":(sZ(Bn)||Bn.contentEditable==="true")&&(Kb=Bn,e3=Ne,CS=null);break;case"focusout":CS=e3=Kb=null;break;case"mousedown":t3=!0;break;case"contextmenu":case"mouseup":case"dragend":t3=!1,yZ(Ge,x,ze);break;case"selectionchange":if(g3e)break;case"keydown":case"keyup":yZ(Ge,x,ze)}var Gt;if(YD)e:{switch(f){case"compositionstart":var tn="onCompositionStart";break e;case"compositionend":tn="onCompositionEnd";break e;case"compositionupdate":tn="onCompositionUpdate";break e}tn=void 0}else Gb?iZ(f,x)&&(tn="onCompositionEnd"):f==="keydown"&&x.keyCode===229&&(tn="onCompositionStart");tn&&(tZ&&x.locale!=="ko"&&(Gb||tn!=="onCompositionStart"?tn==="onCompositionEnd"&&Gb&&(Gt=xe()):(ee=ze,ce="value"in ee?ee.value:ee.textContent,Gb=!0)),Bn=IO(Ne,tn),0<Bn.length&&(tn=new JQ(tn,f,null,x,ze),Ge.push({event:tn,listeners:Bn}),Gt?tn.data=Gt:(Gt=oZ(x),Gt!==null&&(tn.data=Gt)))),(Gt=s3e?a3e(f,x):l3e(f,x))&&(tn=IO(Ne,"onBeforeInput"),0<tn.length&&(Bn=new JQ("onBeforeInput","beforeinput",null,x,ze),Ge.push({event:Bn,listeners:tn}),Bn.data=Gt)),s5e(Ge,f,Ne,x,ze)}Kee(Ge,p)})}function YS(f,p,x){return{instance:f,listener:p,currentTarget:x}}function IO(f,p){for(var x=p+"Capture",k=[];f!==null;){var R=f,L=R.stateNode;if(R=R.tag,R!==5&&R!==26&&R!==27||L===null||(R=Je(f,x),R!=null&&k.unshift(YS(f,R,L)),R=Je(f,p),R!=null&&k.push(YS(f,R,L))),f.tag===3)return k;f=f.return}return[]}function c5e(f){if(f===null)return null;do f=f.return;while(f&&f.tag!==5&&f.tag!==27);return f||null}function Xee(f,p,x,k,R){for(var L=p._reactName,V=[];x!==null&&x!==k;){var oe=x,ye=oe.alternate,Ne=oe.stateNode;if(oe=oe.tag,ye!==null&&ye===k)break;oe!==5&&oe!==26&&oe!==27||Ne===null||(ye=Ne,R?(Ne=Je(x,L),Ne!=null&&V.unshift(YS(x,Ne,ye))):R||(Ne=Je(x,L),Ne!=null&&V.push(YS(x,Ne,ye)))),x=x.return}V.length!==0&&f.push({event:p,listeners:V})}var d5e=/\r\n?/g,f5e=/\u0000|\uFFFD/g;function Qee(f){return(typeof f=="string"?f:""+f).replace(d5e,`
2942
- `).replace(f5e,"")}function Zee(f,p){return p=Qee(p),Qee(f)===p}function Tr(f,p,x,k,R,L){switch(x){case"children":if(typeof k=="string")p==="body"||p==="textarea"&&k===""||za(f,k);else if(typeof k=="number"||typeof k=="bigint")p!=="body"&&za(f,""+k);else return;break;case"className":yu(f,"class",k);break;case"tabIndex":yu(f,"tabindex",k);break;case"dir":case"role":case"viewBox":case"width":case"height":yu(f,x,k);break;case"style":bu(f,k,L);return;case"data":if(p!=="object"){yu(f,"data",k);break}case"src":case"href":if(k===""&&(p!=="a"||x!=="href")){f.removeAttribute(x);break}if(k==null||typeof k=="function"||typeof k=="symbol"||typeof k=="boolean"){f.removeAttribute(x);break}k=Gd(k),f.setAttribute(x,k);break;case"action":case"formAction":if(typeof k=="function"){f.setAttribute(x,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof L=="function"&&(x==="formAction"?(p!=="input"&&Tr(f,p,"name",R.name,R,null),Tr(f,p,"formEncType",R.formEncType,R,null),Tr(f,p,"formMethod",R.formMethod,R,null),Tr(f,p,"formTarget",R.formTarget,R,null)):(Tr(f,p,"encType",R.encType,R,null),Tr(f,p,"method",R.method,R,null),Tr(f,p,"target",R.target,R,null)));if(k==null||typeof k=="symbol"||typeof k=="boolean"){f.removeAttribute(x);break}k=Gd(k),f.setAttribute(x,k);break;case"onClick":k!=null&&(f.onclick=_s);return;case"onScroll":k!=null&&jn("scroll",f);return;case"onScrollEnd":k!=null&&jn("scrollend",f);return;case"dangerouslySetInnerHTML":if(k!=null){if(typeof k!="object"||!("__html"in k))throw Error(r(61));if(x=k.__html,x!=null){if(R.children!=null)throw Error(r(60));(L!=null?L.__html:void 0)!==x&&(f.innerHTML=x)}}break;case"multiple":f.multiple=k&&typeof k!="function"&&typeof k!="symbol";break;case"muted":f.muted=k&&typeof k!="function"&&typeof k!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(k==null||typeof k=="function"||typeof k=="boolean"||typeof k=="symbol"){f.removeAttribute("xlink:href");break}x=Gd(k),f.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",x);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":k!=null&&typeof k!="function"&&typeof k!="symbol"?f.setAttribute(x,k):f.removeAttribute(x);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"credentialless":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":k&&typeof k!="function"&&typeof k!="symbol"?f.setAttribute(x,""):f.removeAttribute(x);break;case"capture":case"download":k===!0?f.setAttribute(x,""):k!==!1&&k!=null&&typeof k!="function"&&typeof k!="symbol"?f.setAttribute(x,k):f.removeAttribute(x);break;case"cols":case"rows":case"size":case"span":k!=null&&typeof k!="function"&&typeof k!="symbol"&&!isNaN(k)&&1<=k?f.setAttribute(x,k):f.removeAttribute(x);break;case"rowSpan":case"start":k==null||typeof k=="function"||typeof k=="symbol"||isNaN(k)?f.removeAttribute(x):f.setAttribute(x,k);break;case"popover":jn("beforetoggle",f),jn("toggle",f),np(f,"popover",k);break;case"xlinkActuate":Da(f,"http://www.w3.org/1999/xlink","xlink:actuate",k);break;case"xlinkArcrole":Da(f,"http://www.w3.org/1999/xlink","xlink:arcrole",k);break;case"xlinkRole":Da(f,"http://www.w3.org/1999/xlink","xlink:role",k);break;case"xlinkShow":Da(f,"http://www.w3.org/1999/xlink","xlink:show",k);break;case"xlinkTitle":Da(f,"http://www.w3.org/1999/xlink","xlink:title",k);break;case"xlinkType":Da(f,"http://www.w3.org/1999/xlink","xlink:type",k);break;case"xmlBase":Da(f,"http://www.w3.org/XML/1998/namespace","xml:base",k);break;case"xmlLang":Da(f,"http://www.w3.org/XML/1998/namespace","xml:lang",k);break;case"xmlSpace":Da(f,"http://www.w3.org/XML/1998/namespace","xml:space",k);break;case"is":np(f,"is",k);break;case"innerText":case"textContent":return;default:if(!(2<x.length)||x[0]!=="o"&&x[0]!=="O"||x[1]!=="n"&&x[1]!=="N")x=Zg.get(x)||x,np(f,x,k);else return}En=!0}function D5(f,p,x,k,R,L){switch(x){case"style":bu(f,k,L);return;case"dangerouslySetInnerHTML":if(k!=null){if(typeof k!="object"||!("__html"in k))throw Error(r(61));if(x=k.__html,x!=null){if(R.children!=null)throw Error(r(60));(L!=null?L.__html:void 0)!==x&&(f.innerHTML=x)}}break;case"children":if(typeof k=="string")za(f,k);else if(typeof k=="number"||typeof k=="bigint")za(f,""+k);else return;break;case"onScroll":k!=null&&jn("scroll",f);return;case"onScrollEnd":k!=null&&jn("scrollend",f);return;case"onClick":k!=null&&(f.onclick=_s);return;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":return;case"innerText":case"textContent":return;default:if(!fs.hasOwnProperty(x))e:{if(x[0]==="o"&&x[1]==="n"&&(R=x.endsWith("Capture"),L=x.slice(2,R?x.length-7:void 0),p=f[Te]||null,p=p!=null?p[x]:null,typeof p=="function"&&f.removeEventListener(L,p,R),typeof k=="function")){typeof p!="function"&&p!==null&&(x in f?f[x]=null:f.hasAttribute(x)&&f.removeAttribute(x)),f.addEventListener(L,k,R);break e}En=!0,x in f?f[x]=k:k===!0?f.setAttribute(x,""):np(f,x,k)}return}En=!0}function Ko(f,p,x){switch(p){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":jn("error",f),jn("load",f);var k=!1,R=!1,L;for(L in x)if(x.hasOwnProperty(L)){var V=x[L];if(V!=null)switch(L){case"src":k=!0;break;case"srcSet":R=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(r(137,p));default:Tr(f,p,L,V,x,null)}}R&&Tr(f,p,"srcSet",x.srcSet,x,null),k&&Tr(f,p,"src",x.src,x,null);return;case"input":jn("invalid",f);var oe=L=V=R=null,ye=null,Ne=null;for(k in x)if(x.hasOwnProperty(k)){var ze=x[k];if(ze!=null)switch(k){case"name":R=ze;break;case"type":V=ze;break;case"checked":ye=ze;break;case"defaultChecked":Ne=ze;break;case"value":L=ze;break;case"defaultValue":oe=ze;break;case"children":case"dangerouslySetInnerHTML":if(ze!=null)throw Error(r(137,p));break;default:Tr(f,p,k,ze,x,null)}}Vb(f,L,oe,ye,Ne,V,R,!1);return;case"select":jn("invalid",f),k=V=L=null;for(R in x)if(x.hasOwnProperty(R)&&(oe=x[R],oe!=null))switch(R){case"value":L=oe;break;case"defaultValue":V=oe;break;case"multiple":k=oe;default:Tr(f,p,R,oe,x,null)}p=L,x=V,f.multiple=!!k,p!=null?gl(f,!!k,p,!1):x!=null&&gl(f,!!k,x,!0);return;case"textarea":jn("invalid",f),L=R=k=null;for(V in x)if(x.hasOwnProperty(V)&&(oe=x[V],oe!=null))switch(V){case"value":k=oe;break;case"defaultValue":R=oe;break;case"children":L=oe;break;case"dangerouslySetInnerHTML":if(oe!=null)throw Error(r(91));break;default:Tr(f,p,V,oe,x,null)}Qg(f,k,R,L);return;case"option":for(ye in x)if(x.hasOwnProperty(ye)&&(k=x[ye],k!=null))switch(ye){case"selected":f.selected=k&&typeof k!="function"&&typeof k!="symbol";break;default:Tr(f,p,ye,k,x,null)}return;case"dialog":jn("beforetoggle",f),jn("toggle",f),jn("cancel",f),jn("close",f);break;case"iframe":case"object":jn("load",f);break;case"video":case"audio":for(k=0;k<KS.length;k++)jn(KS[k],f);break;case"image":jn("error",f),jn("load",f);break;case"details":jn("toggle",f);break;case"embed":case"source":case"link":jn("error",f),jn("load",f);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(Ne in x)if(x.hasOwnProperty(Ne)&&(k=x[Ne],k!=null))switch(Ne){case"children":case"dangerouslySetInnerHTML":throw Error(r(137,p));default:Tr(f,p,Ne,k,x,null)}return;default:if(ip(p)){for(ze in x)x.hasOwnProperty(ze)&&(k=x[ze],k!==void 0&&D5(f,p,ze,k,x,void 0));return}}for(oe in x)x.hasOwnProperty(oe)&&(k=x[oe],k!=null&&Tr(f,p,oe,k,x,null))}var h5e={};function p5e(f,p,x,k){switch(p){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var R=null,L=null,V=null,oe=null,ye=null,Ne=null,ze=null;for(je in x){var Ge=x[je];if(x.hasOwnProperty(je)&&Ge!=null)switch(je){case"checked":break;case"value":break;case"defaultValue":ye=Ge;default:k.hasOwnProperty(je)||Tr(f,p,je,null,k,Ge)}}for(var Re in k){var je=k[Re];if(Ge=x[Re],k.hasOwnProperty(Re)&&(je!=null||Ge!=null))switch(Re){case"type":je!==Ge&&(En=!0),L=je;break;case"name":je!==Ge&&(En=!0),R=je;break;case"checked":je!==Ge&&(En=!0),Ne=je;break;case"defaultChecked":je!==Ge&&(En=!0),ze=je;break;case"value":je!==Ge&&(En=!0),V=je;break;case"defaultValue":je!==Ge&&(En=!0),oe=je;break;case"children":case"dangerouslySetInnerHTML":if(je!=null)throw Error(r(137,p));break;default:je!==Ge&&Tr(f,p,Re,je,k,Ge)}}rp(f,V,oe,ye,Ne,ze,L,R);return;case"select":je=V=oe=Re=null;for(L in x)if(ye=x[L],x.hasOwnProperty(L)&&ye!=null)switch(L){case"value":break;case"multiple":je=ye;default:k.hasOwnProperty(L)||Tr(f,p,L,null,k,ye)}for(R in k)if(L=k[R],ye=x[R],k.hasOwnProperty(R)&&(L!=null||ye!=null))switch(R){case"value":L!==ye&&(En=!0),Re=L;break;case"defaultValue":L!==ye&&(En=!0),oe=L;break;case"multiple":L!==ye&&(En=!0),V=L;default:L!==ye&&Tr(f,p,R,L,k,ye)}p=oe,x=V,k=je,Re!=null?gl(f,!!x,Re,!1):!!k!=!!x&&(p!=null?gl(f,!!x,p,!0):gl(f,!!x,x?[]:"",!1));return;case"textarea":je=Re=null;for(oe in x)if(R=x[oe],x.hasOwnProperty(oe)&&R!=null&&!k.hasOwnProperty(oe))switch(oe){case"value":break;case"children":break;default:Tr(f,p,oe,null,k,R)}for(V in k)if(R=k[V],L=x[V],k.hasOwnProperty(V)&&(R!=null||L!=null))switch(V){case"value":R!==L&&(En=!0),Re=R;break;case"defaultValue":R!==L&&(En=!0),je=R;break;case"children":break;case"dangerouslySetInnerHTML":if(R!=null)throw Error(r(91));break;default:R!==L&&Tr(f,p,V,R,k,L)}Wd(f,Re,je);return;case"option":for(var vt in x)if(Re=x[vt],x.hasOwnProperty(vt)&&Re!=null&&!k.hasOwnProperty(vt))switch(vt){case"selected":f.selected=!1;break;default:Tr(f,p,vt,null,k,Re)}for(ye in k)if(Re=k[ye],je=x[ye],k.hasOwnProperty(ye)&&Re!==je&&(Re!=null||je!=null))switch(ye){case"selected":Re!==je&&(En=!0),f.selected=Re&&typeof Re!="function"&&typeof Re!="symbol";break;default:Tr(f,p,ye,Re,k,je)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var jt in x)Re=x[jt],x.hasOwnProperty(jt)&&Re!=null&&!k.hasOwnProperty(jt)&&Tr(f,p,jt,null,k,Re);for(Ne in k)if(Re=k[Ne],je=x[Ne],k.hasOwnProperty(Ne)&&Re!==je&&(Re!=null||je!=null))switch(Ne){case"children":case"dangerouslySetInnerHTML":if(Re!=null)throw Error(r(137,p));break;default:Tr(f,p,Ne,Re,k,je)}return;default:if(ip(p)){for(var gn in x)Re=x[gn],x.hasOwnProperty(gn)&&Re!==void 0&&!k.hasOwnProperty(gn)&&D5(f,p,gn,void 0,k,Re);for(ze in k)Re=k[ze],je=x[ze],!k.hasOwnProperty(ze)||Re===je||Re===void 0&&je===void 0||D5(f,p,ze,Re,k,je);return}}for(var Me in x)Re=x[Me],x.hasOwnProperty(Me)&&Re!=null&&!k.hasOwnProperty(Me)&&Tr(f,p,Me,null,k,Re);for(Ge in k)Re=k[Ge],je=x[Ge],!k.hasOwnProperty(Ge)||Re===je||Re==null&&je==null||Tr(f,p,Ge,Re,k,je)}function Jee(f){switch(f){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function m5e(){if(typeof performance.getEntriesByType=="function"){for(var f=0,p=0,x=performance.getEntriesByType("resource"),k=0;k<x.length;k++){var R=x[k],L=R.transferSize,V=R.initiatorType,oe=R.duration;if(L&&oe&&Jee(V)){for(V=0,oe=R.responseEnd,k+=1;k<x.length;k++){var ye=x[k],Ne=ye.startTime;if(Ne>oe)break;var ze=ye.transferSize,Ge=ye.initiatorType;ze&&Jee(Ge)&&(ye=ye.responseEnd,V+=ze*(ye<oe?1:(oe-Ne)/(ye-Ne)))}if(--k,p+=8*(L+V)/(R.duration/1e3),f++,10<f)break}}if(0<f)return p/f/1e6}return navigator.connection&&(f=navigator.connection.downlink,typeof f=="number")?f:5}var $5=null,z5=null;function XS(f){return f.nodeType===9?f:f.ownerDocument}function ete(f){switch(f){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function tte(f,p){if(f===0)switch(p){case"svg":return 1;case"math":return 2;default:return 0}return f===1&&p==="foreignObject"?0:f}function nte(f,p,x,k){return x=XS(x).createElement(f),x[Hr]=k,x[Te]=p,Ko(x,f,p),si(x),x}function F5(f,p){return f==="textarea"||f==="noscript"||typeof p.children=="string"||typeof p.children=="number"||typeof p.children=="bigint"||typeof p.dangerouslySetInnerHTML=="object"&&p.dangerouslySetInnerHTML!==null&&p.dangerouslySetInnerHTML.__html!=null}var B5=null;function g5e(){var f=window.event;return f&&f.type==="popstate"?f===B5?!1:(B5=f,!0):(B5=null,!1)}var H5=typeof setTimeout=="function"?setTimeout:void 0,y5e=typeof clearTimeout=="function"?clearTimeout:void 0,rte=typeof Promise=="function"?Promise:void 0,ite=typeof requestAnimationFrame=="function"?requestAnimationFrame:H5,b5e=typeof queueMicrotask=="function"?queueMicrotask:typeof rte<"u"?function(f){return rte.resolve(null).then(f).catch(v5e)}:H5;function v5e(f){setTimeout(function(){throw f})}function Ep(f){return f==="head"}function ote(f,p){var x=p,k=0;do{var R=x.nextSibling;if(f.removeChild(x),R&&R.nodeType===8)if(x=R.data,x==="/$"||x==="/&"){if(k===0){f.removeChild(R),Av(p);return}k--}else if(x==="$"||x==="$?"||x==="$~"||x==="$!"||x==="&")k++;else if(x==="html")X5(f.ownerDocument.documentElement);else if(x==="head"){x=f.ownerDocument.head,X5(x);for(var L=x.firstChild;L;){var V=L.nextSibling,oe=L.nodeName;L[rr]||oe==="SCRIPT"||oe==="STYLE"||oe==="LINK"&&L.rel.toLowerCase()==="stylesheet"||x.removeChild(L),L=V}}else x==="body"&&X5(f.ownerDocument.body);x=R}while(x);Av(p)}function ste(f,p){var x=f;f=0;do{var k=x.nextSibling;if(x.nodeType===1?p?(x._stashedDisplay=x.style.display,x.style.display="none"):(x.style.display=x._stashedDisplay||"",x.getAttribute("style")===""&&x.removeAttribute("style")):x.nodeType===3&&(p?(x._stashedText=x.nodeValue,x.nodeValue=""):x.nodeValue=x._stashedText||""),k&&k.nodeType===8)if(x=k.data,x==="/$"){if(f===0)break;f--}else x!=="$"&&x!=="$?"&&x!=="$~"&&x!=="$!"||f++;x=k}while(x)}function ate(f,p,x){if(p=CSS.escape(p)!==p?"r-"+btoa(p).replace(/=/g,""):p,f.style.viewTransitionName=p,x!=null&&(f.style.viewTransitionClass=x),x=getComputedStyle(f),x.display==="inline"){if(p=f.getClientRects(),p.length===1)var k=1;else for(var R=k=0;R<p.length;R++){var L=p[R];0<L.width&&0<L.height&&k++}k===1&&(f=f.style,f.display=p.length===1?"inline-block":"block",f.marginTop="-"+x.paddingTop,f.marginBottom="-"+x.paddingBottom)}}function lte(f,p){f=f.style,p=p.style;var x=p!=null?p.hasOwnProperty("viewTransitionName")?p.viewTransitionName:p.hasOwnProperty("view-transition-name")?p["view-transition-name"]:null:null;f.viewTransitionName=x==null||typeof x=="boolean"?"":(""+x).trim(),x=p!=null?p.hasOwnProperty("viewTransitionClass")?p.viewTransitionClass:p.hasOwnProperty("view-transition-class")?p["view-transition-class"]:null:null,f.viewTransitionClass=x==null||typeof x=="boolean"?"":(""+x).trim(),f.display==="inline-block"&&(p==null?f.display=f.margin="":(x=p.display,f.display=x==null||typeof x=="boolean"?"":x,x=p.margin,x!=null?f.margin=x:(x=p.hasOwnProperty("marginTop")?p.marginTop:p["margin-top"],f.marginTop=x==null||typeof x=="boolean"?"":x,p=p.hasOwnProperty("marginBottom")?p.marginBottom:p["margin-bottom"],f.marginBottom=p==null||typeof p=="boolean"?"":p)))}function x5e(f,p,x){return x=x.ownerDocument.defaultView,{rect:f,abs:p.position==="absolute"||p.position==="fixed",clip:p.clipPath!=="none"||p.overflow!=="visible"||p.filter!=="none"||p.mask!=="none"||p.mask!=="none"||p.borderRadius!=="0px",view:0<=f.bottom&&0<=f.right&&f.top<=x.innerHeight&&f.left<=x.innerWidth}}function U5(f){var p=f.getBoundingClientRect(),x=getComputedStyle(f);return x5e(p,x,f)}function w5e(f){return f.documentElement.clientHeight}function S5e(f){this.addEventListener("load",f),this.addEventListener("error",f)}function k5e(f,p,x,k,R,L,V,oe,ye){var Ne=p.nodeType===9?p:p.ownerDocument;try{var ze=Ne.startViewTransition({update:function(){var Re=Ne.defaultView,je=Re.navigation&&Re.navigation.transition,vt=Ne.fonts.status;k();var jt=[];if(vt==="loaded"&&(w5e(Ne),Ne.fonts.status==="loading"&&jt.push(Ne.fonts.ready)),vt=jt.length,f!==null)for(var gn=f.suspenseyImages,Me=0,Ce=0;Ce<gn.length;Ce++){var Pe=gn[Ce];if(!Pe.complete){var qe=Pe.getBoundingClientRect();if(0<qe.bottom&&0<qe.right&&qe.top<Re.innerHeight&&qe.left<Re.innerWidth){if(Me+=Rte(Pe),Me>DO){jt.length=vt;break}Pe=new Promise(S5e.bind(Pe)),jt.push(Pe)}}}if(0<jt.length)return Re=Promise.race([Promise.all(jt),new Promise(function(Tt){return setTimeout(Tt,500)})]).then(R,R),(je?Promise.allSettled([je.finished,Re]):Re).then(L,L);if(R(),je)return je.finished.then(L,L);L()},types:x});Ne.__reactViewTransition=ze;var Ge=[];return ze.ready.then(function(){for(var Re=Ne.documentElement.getAnimations({subtree:!0}),je=0;je<Re.length;je++){var vt=Re[je],jt=vt.effect,gn=jt.pseudoElement;if(gn!=null&&gn.startsWith("::view-transition")){Ge.push(vt),vt=jt.getKeyframes();for(var Me=gn=void 0,Ce=!0,Pe=0;Pe<vt.length;Pe++){var qe=vt[Pe],Tt=qe.width;if(gn===void 0)gn=Tt;else if(gn!==Tt){Ce=!1;break}if(Tt=qe.height,Me===void 0)Me=Tt;else if(Me!==Tt){Ce=!1;break}delete qe.width,delete qe.height,qe.transform==="none"&&delete qe.transform}Ce&&gn!==void 0&&Me!==void 0&&(jt.setKeyframes(vt),Ce=getComputedStyle(jt.target,jt.pseudoElement),Ce.width!==gn||Ce.height!==Me)&&(Ce=vt[0],Ce.width=gn,Ce.height=Me,Ce=vt[vt.length-1],Ce.width=gn,Ce.height=Me,jt.setKeyframes(vt))}}V()},function(Re){Ne.__reactViewTransition===ze&&(Ne.__reactViewTransition=null);try{if(typeof Re=="object"&&Re!==null)switch(Re.name){case"InvalidStateError":(Re.message==="View transition was skipped because document visibility state is hidden."||Re.message==="Skipping view transition because document visibility state has become hidden."||Re.message==="Skipping view transition because viewport size changed."||Re.message==="Transition was aborted because of invalid state")&&(Re=null)}Re!==null&&ye(Re)}finally{k(),R(),V()}}),ze.finished.finally(function(){for(var Re=0;Re<Ge.length;Re++)Ge[Re].cancel();Ne.__reactViewTransition===ze&&(Ne.__reactViewTransition=null),oe()}),ze}catch{return k(),R(),V(),null}}function k0(f,p){this._scope=document.documentElement,this._selector="::view-transition-"+f+"("+p+")"}k0.prototype.animate=function(f,p){return p=typeof p=="number"?{duration:p}:M({},p),p.pseudoElement=this._selector,this._scope.animate(f,p)},k0.prototype.getAnimations=function(){for(var f=this._scope,p=this._selector,x=f.getAnimations({subtree:!0}),k=[],R=0;R<x.length;R++){var L=x[R].effect;L!==null&&L.target===f&&L.pseudoElement===p&&k.push(x[R])}return k},k0.prototype.getComputedStyle=function(){return getComputedStyle(this._scope,this._selector)};function ute(f){return{name:f,group:new k0("group",f),imagePair:new k0("image-pair",f),old:new k0("old",f),new:new k0("new",f)}}function qa(f){this._fragmentFiber=f,this._observers=this._eventListeners=null}qa.prototype.addEventListener=function(f,p,x){var k=null,R=null;if(!(x!=null&&typeof x!="boolean"&&(k=x.signal||null,k!==null&&k.aborted))){this._eventListeners===null&&(this._eventListeners=[]);var L=this._eventListeners;if(dte(L,f,p,x)===-1){var V=this,oe=p;x!=null&&typeof x!="boolean"&&x.once===!0&&(oe=function(ye){V.removeEventListener(f,p,x),typeof p=="function"?p.call(this,ye):p.handleEvent(ye)}),k!==null&&(R=V.removeEventListener.bind(V,f,p,x),k.addEventListener("abort",R,{once:!0}),R=k.removeEventListener.bind(k,"abort",R)),k=wv(x),L.push({type:f,listener:p,optionsOrUseCapture:x,attachedListener:oe,cleanup:R}),d(this._fragmentFiber.child,!1,C5e,f,oe,k)}this._eventListeners=L}};function C5e(f,p,x,k){return v(f).addEventListener(p,x,k),!1}qa.prototype.removeEventListener=function(f,p,x){var k=this._eventListeners;if(k!==null&&(p=dte(k,f,p,x),p!==-1)){var R=k[p];x=R.attachedListener;var L=R.cleanup;R=wv(R.optionsOrUseCapture),d(this._fragmentFiber.child,!1,E5e,f,x,R),k.splice(p,1),L!==null&&L()}};function E5e(f,p,x,k){return v(f).removeEventListener(p,x,k),!1}function wv(f){return f!=null&&typeof f!="boolean"&&(f.once===!0||f.signal instanceof AbortSignal)?{capture:f.capture,passive:f.passive}:f}function cte(f){return f==null?"c=0":typeof f=="boolean"?"c="+(f?"1":"0"):"c="+(f.capture?"1":"0")}function dte(f,p,x,k){if(f.length===0)return-1;k=cte(k);for(var R=0;R<f.length;R++){var L=f[R];if(L.type===p&&L.listener===x&&cte(L.optionsOrUseCapture)===k)return R}return-1}qa.prototype.dispatchEvent=function(f){var p=h(this._fragmentFiber);if(p===null)return!0;p=v(p);var x=this._eventListeners;if(x!==null&&0<x.length||!f.bubbles){var k=p.nodeType===9?p.createComment(""):document.createTextNode("");if(x)for(var R=0;R<x.length;R++){var L=x[R];k.addEventListener(L.type,L.attachedListener,wv(L.optionsOrUseCapture))}if(p.appendChild(k),f=k.dispatchEvent(f),x)for(R=0;R<x.length;R++)L=x[R],k.removeEventListener(L.type,L.attachedListener,wv(L.optionsOrUseCapture));return p.removeChild(k),f}return p.dispatchEvent(f)},qa.prototype.focus=function(f){d(this._fragmentFiber.child,!0,fte,f,void 0,void 0)};function fte(f,p){return f.tag===6?!1:(f=v(f),D5e(f,p))}qa.prototype.focusLast=function(f){var p=[];d(this._fragmentFiber.child,!0,V5,p,void 0,void 0);for(var x=p.length-1;0<=x&&!fte(p[x],f);x--);};function V5(f,p){return p.push(f),!1}qa.prototype.blur=function(){var f=h(this._fragmentFiber);f!==null&&(f=v(f),f=XS(f).activeElement,f!==null&&d(this._fragmentFiber.child,!1,T5e,f,void 0,void 0))};function T5e(f,p){return f.tag===6?!1:(f=v(f),f===p||f.contains(p)?(p.blur(),!0):!1)}qa.prototype.observeUsing=function(f){this._observers===null&&(this._observers=new Set),this._observers.add(f),d(this._fragmentFiber.child,!1,A5e,f,void 0,void 0)};function A5e(f,p){return f.tag===6||(f=v(f),p.observe(f)),!1}qa.prototype.unobserveUsing=function(f){var p=this._observers;if(p!==null&&p.has(f)){p.delete(f),d(this._fragmentFiber.child,!1,O5e,f,void 0,void 0);for(var x=p=0;x<Cu.length;x++){var k=Cu[x];k.fragmentInstance===this&&k.observer===f?f.unobserve(k.instance):Cu[p++]=k}Cu.length=p}};function O5e(f,p){return f.tag===6||(f=v(f),p.unobserve(f)),!1}var Cu=[],W5=!1;function R5e(f,p,x){Cu.push({fragmentInstance:f,observer:p,instance:x}),W5||(W5=!0,$5e(function(){W5=!1;var k=Cu;Cu=[];for(var R=0;R<k.length;R++){var L=k[R];L.observer.unobserve(L.instance)}}))}qa.prototype.getClientRects=function(){var f=[];return d(this._fragmentFiber.child,!1,M5e,f,void 0,void 0),f};function M5e(f,p){if(f.tag===6){f=f.stateNode;var x=f.ownerDocument.createRange();x.selectNodeContents(f),p.push.apply(p,x.getClientRects())}else f=v(f),p.push.apply(p,f.getClientRects());return!1}qa.prototype.getRootNode=function(f){var p=h(this._fragmentFiber);return p===null?this:v(p).getRootNode(f)},qa.prototype.compareDocumentPosition=function(f){var p=h(this._fragmentFiber);if(p===null)return Node.DOCUMENT_POSITION_DISCONNECTED;var x=[];d(this._fragmentFiber.child,!1,V5,x,void 0,void 0);var k=v(p);if(x.length===0){if(x=k,m(this._fragmentFiber)){e:{for(p=this._fragmentFiber.return;p!==null;){if(p.tag===4){p=p.stateNode.containerInfo;break e}if(p.tag===3||p.tag===5||p.tag===27)break;p=p.return}p=null}p!=null&&(x=p)}p=this._fragmentFiber;var R=k=x.compareDocumentPosition(f);return x===f?R=Node.DOCUMENT_POSITION_CONTAINS:k&Node.DOCUMENT_POSITION_CONTAINED_BY&&(x=g(p)[1],x===null?R=Node.DOCUMENT_POSITION_PRECEDING:(f=v(x).compareDocumentPosition(f),R=f===0||f&Node.DOCUMENT_POSITION_FOLLOWING?Node.DOCUMENT_POSITION_FOLLOWING:Node.DOCUMENT_POSITION_PRECEDING)),R|=Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC}p=v(x[0]),R=v(x[x.length-1]);var L=m(this._fragmentFiber)?p.parentElement:k;if(L==null)return Node.DOCUMENT_POSITION_DISCONNECTED;k=L.compareDocumentPosition(p)&Node.DOCUMENT_POSITION_CONTAINED_BY,L=L.compareDocumentPosition(R)&Node.DOCUMENT_POSITION_CONTAINED_BY;var V=p.compareDocumentPosition(f),oe=R.compareDocumentPosition(f),ye=V&Node.DOCUMENT_POSITION_CONTAINED_BY||oe&Node.DOCUMENT_POSITION_CONTAINED_BY;return oe=k&&L&&V&Node.DOCUMENT_POSITION_FOLLOWING&&oe&Node.DOCUMENT_POSITION_PRECEDING,p=k&&p===f||L&&R===f||ye||oe?Node.DOCUMENT_POSITION_CONTAINED_BY:!k&&p===f||!L&&R===f?Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC:V,p&Node.DOCUMENT_POSITION_DISCONNECTED||p&Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC||_5e(p,this._fragmentFiber,x[0],x[x.length-1],f)?p:Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC};function _5e(f,p,x,k,R){var L=ia(R);if(f&Node.DOCUMENT_POSITION_CONTAINED_BY){if(x=!!L)e:{for(;L!==null;){if(L.tag===7&&(L===p||L.alternate===p)){x=!0;break e}L=L.return}x=!1}return x}if(f&Node.DOCUMENT_POSITION_CONTAINS){if(L===null)return L=R.ownerDocument,R===L||R===L.documentElement||R===L.body;e:{for(L=p,p=h(p);L!==null;){if(!(L.tag!==5&&L.tag!==3&&L.tag!==27||L!==p&&L.alternate!==p)){L=!0;break e}L=L.return}L=!1}return L}return f&Node.DOCUMENT_POSITION_PRECEDING?((p=!!L)&&!(p=L===x)&&(p=O(x,L,T),p===null?p=!1:(d(p,!0,C,L,x),L=w,w=null,p=L!==null)),p):f&Node.DOCUMENT_POSITION_FOLLOWING?((p=!!L)&&!(p=L===k)&&(p=O(k,L,T),p===null?p=!1:(d(p,!0,E,L,k),L=w,S=w=null,p=L!==null)),p):!1}function hte(f,p){var x=f.ownerDocument.createRange();x.selectNodeContents(f),f=x.getBoundingClientRect(),window.scrollTo(window.scrollX+f.left,p?window.scrollY+f.top:window.scrollY+f.bottom-window.innerHeight)}qa.prototype.scrollIntoView=function(f){if(typeof f=="object")throw Error(r(566));var p=[];d(this._fragmentFiber.child,!1,V5,p,void 0,void 0);var x=f!==!1;if(p.length===0){var k=g(this._fragmentFiber);if(k=x?k[1]||k[0]||h(this._fragmentFiber):k[0]||k[1],k===null)return;if(k.tag===6){f=v(k),hte(f,x);return}if(k=v(k),k.nodeType!==9){if(k.nodeType===11){x="host"in k?k.host:null,x!==null&&x.scrollIntoView(f);return}k.scrollIntoView(f)}}for(k=x?p.length-1:0;k!==(x?-1:p.length);){var R=p[k];R.tag===6?(R=v(R),hte(R,x)):v(R).scrollIntoView(f),k+=x?-1:1}};function N5e(f,p){return f=v(f),pte(f,p),!1}function pte(f,p){f.reactFragments==null&&(f.reactFragments=new Set),f.reactFragments.add(p)}function mte(f,p){var x=p._eventListeners;if(x!==null)for(var k=0;k<x.length;k++){var R=x[k];f.addEventListener(R.type,R.attachedListener,wv(R.optionsOrUseCapture))}f.nodeType!==3&&(x=p._observers,x!==null&&x.forEach(function(L){for(var V=0,oe=0;oe<Cu.length;oe++){var ye=Cu[oe];(ye.fragmentInstance!==p||ye.observer!==L||ye.instance!==f)&&(Cu[V++]=ye)}Cu.length=V,L.observe(f)}),pte(f,p))}function L5e(f,p){var x=p._eventListeners;if(x!==null)for(var k=0;k<x.length;k++){var R=x[k];f.removeEventListener(R.type,R.attachedListener,wv(R.optionsOrUseCapture))}f.nodeType!==3&&(x=p._observers,x!==null&&x.forEach(function(L){typeof L.rootMargin=="string"?R5e(p,L,f):L.unobserve(f)}),f.reactFragments!=null&&f.reactFragments.delete(p))}function q5(f){var p=f.firstChild;for(p&&p.nodeType===10&&(p=p.nextSibling);p;){var x=p;switch(p=p.nextSibling,x.nodeName){case"HTML":case"HEAD":case"BODY":q5(x),hc(x);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(x.rel.toLowerCase()==="stylesheet")continue}f.removeChild(x)}}function I5e(f,p,x,k){for(;f.nodeType===1;){var R=x;if(f.nodeName.toLowerCase()!==p.toLowerCase()){if(!k&&(f.nodeName!=="INPUT"||f.type!=="hidden"))break}else if(k){if(!f[rr])switch(p){case"meta":if(!f.hasAttribute("itemprop"))break;return f;case"link":if(L=f.getAttribute("rel"),L==="stylesheet"&&f.hasAttribute("data-precedence"))break;if(L!==R.rel||f.getAttribute("href")!==(R.href==null||R.href===""?null:R.href)||f.getAttribute("crossorigin")!==(R.crossOrigin==null?null:R.crossOrigin)||f.getAttribute("title")!==(R.title==null?null:R.title))break;return f;case"style":if(f.hasAttribute("data-precedence"))break;return f;case"script":if(L=f.getAttribute("src"),(L!==(R.src==null?null:R.src)||f.getAttribute("type")!==(R.type==null?null:R.type)||f.getAttribute("crossorigin")!==(R.crossOrigin==null?null:R.crossOrigin))&&L&&f.hasAttribute("async")&&!f.hasAttribute("itemprop"))break;return f;default:return f}}else if(p==="input"&&f.type==="hidden"){var L=R.name==null?null:""+R.name;if(R.type==="hidden"&&f.getAttribute("name")===L)return f}else return f;if(f=Cl(f.nextSibling),f===null)break}return null}function P5e(f,p,x){if(p==="")return null;for(;f.nodeType!==3;)if((f.nodeType!==1||f.nodeName!=="INPUT"||f.type!=="hidden")&&!x||(f=Cl(f.nextSibling),f===null))return null;return f}function gte(f,p){for(;f.nodeType!==8;)if((f.nodeType!==1||f.nodeName!=="INPUT"||f.type!=="hidden")&&!p||(f=Cl(f.nextSibling),f===null))return null;return f}function G5(f){return f.data==="$?"||f.data==="$~"}function K5(f){return f.data==="$!"||f.data==="$?"&&f.ownerDocument.readyState!=="loading"}function j5e(f,p){var x=f.ownerDocument;if(f.data==="$~")f._reactRetry=p;else if(f.data!=="$?"||x.readyState!=="loading")p();else{var k=function(){p(),x.removeEventListener("DOMContentLoaded",k)};x.addEventListener("DOMContentLoaded",k),f._reactRetry=k}}function Cl(f){for(;f!=null;f=f.nextSibling){var p=f.nodeType;if(p===1||p===3)break;if(p===8){if(p=f.data,p==="$"||p==="$!"||p==="$?"||p==="$~"||p==="&"||p==="F!"||p==="F")break;if(p==="/$"||p==="/&")return null}}return f}var Y5=null;function yte(f){f=f.nextSibling;for(var p=0;f;){if(f.nodeType===8){var x=f.data;if(x==="/$"||x==="/&"){if(p===0)return Cl(f.nextSibling);p--}else x!=="$"&&x!=="$!"&&x!=="$?"&&x!=="$~"&&x!=="&"||p++}f=f.nextSibling}return null}function bte(f){f=f.previousSibling;for(var p=0;f;){if(f.nodeType===8){var x=f.data;if(x==="$"||x==="$!"||x==="$?"||x==="$~"||x==="&"){if(p===0)return f;p--}else x!=="/$"&&x!=="/&"||p++}f=f.previousSibling}return null}function D5e(f,p){function x(){k=!0}if(f.ownerDocument.activeElement===f)return!0;var k=!1;try{f.ownerDocument.addEventListener("focus",x,!0),(f.focus||HTMLElement.prototype.focus).call(f,p)}finally{f.ownerDocument.removeEventListener("focus",x,!0)}return k}function $5e(f){ite(function(){ite(function(p){return f(p)})})}function vte(f,p,x){switch(p=XS(x),f){case"html":if(f=p.documentElement,!f)throw Error(r(452));return f;case"head":if(f=p.head,!f)throw Error(r(453));return f;case"body":if(f=p.body,!f)throw Error(r(454));return f;default:throw Error(r(451))}}function xte(f,p,x){for(var k in x){var R=x[k];x.hasOwnProperty(k)&&R!=null&&Tr(f,p,k,null,h5e,R)}x.dangerouslySetInnerHTML!=null&&(f.textContent=""),f.onclick===_s&&(f.onclick=null),hc(f)}function X5(f){for(var p=f.attributes;p.length;)f.removeAttributeNode(p[0]);hc(f)}var El=new Map,wte=new Set;function QS(f){if(typeof f.getRootNode=="function"){var p=f.getRootNode();if(p.nodeType===9||p.nodeType===11)return p}return f.nodeType===9?f:f.ownerDocument}var af=se.d;se.d={f:z5e,r:F5e,D:B5e,C:H5e,L:U5e,m:V5e,X:q5e,S:W5e,M:G5e};function z5e(){var f=af.f(),p=OO();return f||p}function F5e(f){var p=ml(f);p!==null&&p.tag===5&&p.type==="form"?kJ(p):af.r(f)}var Sv=typeof document>"u"?null:document;function Ste(f,p,x){var k=Sv;if(k&&typeof p=="string"&&p){var R=hs(p);R='link[rel="'+f+'"][href="'+R+'"]',typeof x=="string"&&(R+='[crossorigin="'+x+'"]'),wte.has(R)||(wte.add(R),f={rel:f,crossOrigin:x,href:p},k.querySelector(R)===null&&(p=k.createElement("link"),Ko(p,"link",f),si(p),k.head.appendChild(p)))}}function B5e(f){af.D(f),Ste("dns-prefetch",f,null)}function H5e(f,p){af.C(f,p),Ste("preconnect",f,p)}function U5e(f,p,x){af.L(f,p,x);var k=Sv;if(k&&f&&p){var R='link[rel="preload"][as="'+hs(p)+'"]';p==="image"&&x&&x.imageSrcSet?(R+='[imagesrcset="'+hs(x.imageSrcSet)+'"]',typeof x.imageSizes=="string"&&(R+='[imagesizes="'+hs(x.imageSizes)+'"]')):R+='[href="'+hs(f)+'"]';var L=R;switch(p){case"style":L=kv(f);break;case"script":L=Cv(f)}if(!(El.has(L)||(f=M({rel:"preload",href:p==="image"&&x&&x.imageSrcSet?void 0:f,as:p},x),El.set(L,f),k.querySelector(R)!==null||p==="style"&&k.querySelector(ZS(L))||p==="script"&&k.querySelector(JS(L))))){var V=k.createElement("link");Ko(V,"link",f),p==="style"&&(V[gi]=!0,V.onload=V.onerror=function(){pc(V)}),si(V),k.head.appendChild(V)}}}function V5e(f,p){af.m(f,p);var x=Sv;if(x&&f){var k=p&&typeof p.as=="string"?p.as:"script",R='link[rel="modulepreload"][as="'+hs(k)+'"][href="'+hs(f)+'"]',L=R;switch(k){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":L=Cv(f)}if(!El.has(L)&&(f=M({rel:"modulepreload",href:f},p),El.set(L,f),x.querySelector(R)===null)){switch(k){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(x.querySelector(JS(L)))return}k=x.createElement("link"),Ko(k,"link",f),si(k),x.head.appendChild(k)}}}function W5e(f,p,x){af.S(f,p,x);var k=Sv;if(k&&f){var R=ds(k).hoistableStyles,L=kv(f);p=p||"default";var V=R.get(L);if(!V){var oe={loading:0,preload:null};if(V=k.querySelector(ZS(L)))oe.loading=5;else{f=M({rel:"stylesheet",href:f,"data-precedence":p},x),(x=El.get(L))&&Q5(f,x);var ye=V=k.createElement("link");si(ye),Ko(ye,"link",f),ye._p=new Promise(function(Ne,ze){ye.onload=Ne,ye.onerror=ze}),ye.addEventListener("load",function(){oe.loading|=1}),ye.addEventListener("error",function(){oe.loading|=2}),oe.loading|=4,PO(V,p,k)}V={type:"stylesheet",instance:V,count:1,state:oe},R.set(L,V)}}}function q5e(f,p){af.X(f,p);var x=Sv;if(x&&f){var k=ds(x).hoistableScripts,R=Cv(f),L=k.get(R);L||(L=x.querySelector(JS(R)),L||(f=M({src:f,async:!0},p),(p=El.get(R))&&Z5(f,p),L=x.createElement("script"),si(L),Ko(L,"link",f),x.head.appendChild(L)),L={type:"script",instance:L,count:1,state:null},k.set(R,L))}}function G5e(f,p){af.M(f,p);var x=Sv;if(x&&f){var k=ds(x).hoistableScripts,R=Cv(f),L=k.get(R);L||(L=x.querySelector(JS(R)),L||(f=M({src:f,async:!0,type:"module"},p),(p=El.get(R))&&Z5(f,p),L=x.createElement("script"),si(L),Ko(L,"link",f),x.head.appendChild(L)),L={type:"script",instance:L,count:1,state:null},k.set(R,L))}}function kte(f,p,x,k){var R=(R=ge.current)?QS(R):null;if(!R)throw Error(r(446));switch(f){case"meta":case"title":return null;case"style":return typeof x.precedence=="string"&&typeof x.href=="string"?(x=kv(x.href),p=ds(R).hoistableStyles,k=p.get(x),k||(k={type:"style",instance:null,count:0,state:null},p.set(x,k)),k):{type:"void",instance:null,count:0,state:null};case"link":if(x.rel==="stylesheet"&&typeof x.href=="string"&&typeof x.precedence=="string"){f=kv(x.href);var L=ds(R).hoistableStyles,V=L.get(f);if(V||(R=R.ownerDocument||R,V={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},L.set(f,V),(L=R.querySelector(ZS(f)))?L._p||(V.instance=L,V.state.loading=5):(L=El.get(f),L||(L={rel:"preload",as:"style",href:x.href,crossOrigin:x.crossOrigin,integrity:x.integrity,media:x.media,hrefLang:x.hrefLang,referrerPolicy:x.referrerPolicy},El.set(f,L)),K5e(R,f,L,V.state))),p&&k===null)throw Error(r(528,""));return V}if(p&&k!==null)throw Error(r(529,""));return null;case"script":return p=x.async,x=x.src,typeof x=="string"&&p&&typeof p!="function"&&typeof p!="symbol"?(x=Cv(x),p=ds(R).hoistableScripts,k=p.get(x),k||(k={type:"script",instance:null,count:0,state:null},p.set(x,k)),k):{type:"void",instance:null,count:0,state:null};default:throw Error(r(444,f))}}function kv(f){return'href="'+hs(f)+'"'}function ZS(f){return'link[rel="stylesheet"]['+f+"]"}function Cte(f){return M({},f,{"data-precedence":f.precedence,precedence:null})}function K5e(f,p,x,k){if(p=f.querySelector('link[rel="preload"][as="style"]['+p+"]")){if(p[gi]!==!0){k.loading=1;return}}else p=f.createElement("link"),p[gi]=!0,p.onload=p.onerror=pc.bind(null,p),Ko(p,"link",x),si(p),f.head.appendChild(p);k.preload=p,p.addEventListener("load",function(){return k.loading|=1}),p.addEventListener("error",function(){return k.loading|=2})}function Cv(f){return'[src="'+hs(f)+'"]'}function JS(f){return"script[async]"+f}function Ete(f,p,x){if(p.count++,p.instance===null)switch(p.type){case"style":var k=f.querySelector('style[data-href~="'+hs(x.href)+'"]');if(k)return p.instance=k,si(k),k;var R=M({},x,{"data-href":x.href,"data-precedence":x.precedence,href:null,precedence:null});return k=(f.ownerDocument||f).createElement("style"),si(k),Ko(k,"style",R),PO(k,x.precedence,f),p.instance=k;case"stylesheet":R=kv(x.href);var L=f.querySelector(ZS(R));if(L)return p.state.loading|=4,p.instance=L,si(L),L;k=Cte(x),(R=El.get(R))&&Q5(k,R),L=(f.ownerDocument||f).createElement("link"),si(L);var V=L;return V._p=new Promise(function(oe,ye){V.onload=oe,V.onerror=ye}),Ko(L,"link",k),p.state.loading|=4,PO(L,x.precedence,f),p.instance=L;case"script":return L=Cv(x.src),(R=f.querySelector(JS(L)))?(p.instance=R,si(R),R):(k=x,(R=El.get(L))&&(k=M({},x),Z5(k,R)),f=f.ownerDocument||f,R=f.createElement("script"),si(R),Ko(R,"link",k),f.head.appendChild(R),p.instance=R);case"void":return null;default:throw Error(r(443,p.type))}else p.type==="stylesheet"&&(p.state.loading&4)===0&&(k=p.instance,p.state.loading|=4,PO(k,x.precedence,f));return p.instance}function PO(f,p,x){for(var k=x.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),R=k.length?k[k.length-1]:null,L=R,V=0;V<k.length;V++){var oe=k[V];if(oe.dataset.precedence===p)L=oe;else if(L!==R)break}L?L.parentNode.insertBefore(f,L.nextSibling):(p=x.nodeType===9?x.head:x,p.insertBefore(f,p.firstChild))}function Q5(f,p){f.crossOrigin==null&&(f.crossOrigin=p.crossOrigin),f.referrerPolicy==null&&(f.referrerPolicy=p.referrerPolicy),f.title==null&&(f.title=p.title)}function Z5(f,p){f.crossOrigin==null&&(f.crossOrigin=p.crossOrigin),f.referrerPolicy==null&&(f.referrerPolicy=p.referrerPolicy),f.integrity==null&&(f.integrity=p.integrity)}var jO=null;function Tte(f,p,x){if(jO===null){var k=new Map,R=jO=new Map;R.set(x,k)}else R=jO,k=R.get(x),k||(k=new Map,R.set(x,k));if(k.has(f))return k;for(k.set(f,null),x=x.getElementsByTagName(f),R=0;R<x.length;R++){var L=x[R];if(!(L[rr]||L[Hr]||f==="link"&&L.getAttribute("rel")==="stylesheet")&&L.namespaceURI!=="http://www.w3.org/2000/svg"){var V=L.getAttribute(p)||"";V=f+V;var oe=k.get(V);oe?oe.push(L):k.set(V,[L])}}return k}function J5(f,p,x){f=f.ownerDocument||f,f.head.insertBefore(x,p==="title"?f.querySelector("head > title"):null)}function Y5e(f,p,x){if(x===1||p.itemProp!=null)return!1;switch(f){case"meta":case"title":return!0;case"style":if(typeof p.precedence!="string"||typeof p.href!="string"||p.href==="")break;return!0;case"link":if(typeof p.rel!="string"||typeof p.href!="string"||p.href===""||p.onLoad||p.onError)break;switch(p.rel){case"stylesheet":return f=p.disabled,typeof p.precedence=="string"&&f==null;default:return!0}case"script":if(p.async&&typeof p.async!="function"&&typeof p.async!="symbol"&&!p.onLoad&&!p.onError&&p.src&&typeof p.src=="string")return!0}return!1}function Ate(f,p){return f==="img"&&p.src!=null&&p.src!==""&&p.onLoad==null&&p.loading!=="lazy"}function Ote(f){return!(f.type==="stylesheet"&&(f.state.loading&3)===0)}function Rte(f){return(f.width||100)*(f.height||100)*(typeof devicePixelRatio=="number"?devicePixelRatio:1)*.25}function Mte(f,p){typeof p.decode=="function"&&(f.imgCount++,p.complete||(f.imgBytes+=Rte(p),f.suspenseyImages.push(p)),f=Z5e.bind(f),p.decode().then(f,f))}function X5e(f,p,x,k){if(x.type==="stylesheet"&&(typeof k.media!="string"||matchMedia(k.media).matches!==!1)&&(x.state.loading&4)===0){if(x.instance===null){var R=kv(k.href),L=p.querySelector(ZS(R));if(L){p=L._p,p!==null&&typeof p=="object"&&typeof p.then=="function"&&(f.count++,f=ek.bind(f),p.then(f,f)),x.state.loading|=4,x.instance=L,si(L);return}L=p.ownerDocument||p,k=Cte(k),(R=El.get(R))&&Q5(k,R),L=L.createElement("link"),si(L);var V=L;V._p=new Promise(function(oe,ye){V.onload=oe,V.onerror=ye}),Ko(L,"link",k),x.instance=L}f.stylesheets===null&&(f.stylesheets=new Map),f.stylesheets.set(x,p),(p=x.state.preload)&&(x.state.loading&3)===0&&(f.count++,x=ek.bind(f),p.addEventListener("load",x),p.addEventListener("error",x))}}var DO=0;function Q5e(f,p){return f.stylesheets&&f.count===0&&zO(f,f.stylesheets),0<f.count||0<f.imgCount?function(x){var k=setTimeout(function(){if(f.stylesheets&&zO(f,f.stylesheets),f.unsuspend){var L=f.unsuspend;f.unsuspend=null,L()}},6e4+p);0<f.imgBytes&&DO===0&&(DO=62500*m5e());var R=setTimeout(function(){if(f.waitingForImages=!1,f.count===0&&(f.stylesheets&&zO(f,f.stylesheets),f.unsuspend)){var L=f.unsuspend;f.unsuspend=null,L()}},(f.imgBytes>DO?50:800)+p);return f.unsuspend=x,function(){f.unsuspend=null,clearTimeout(k),clearTimeout(R)}}:null}function _te(f){if(f.count===0&&(f.imgCount===0||!f.waitingForImages)){if(f.stylesheets)zO(f,f.stylesheets);else if(f.unsuspend){var p=f.unsuspend;f.unsuspend=null,p()}}}function ek(){this.count--,_te(this)}function Z5e(){this.imgCount--,_te(this)}var $O=null;function zO(f,p){f.stylesheets=null,f.unsuspend!==null&&(f.count++,$O=new Map,p.forEach(J5e,f),$O=null,ek.call(f))}function J5e(f,p){if(!(p.state.loading&4)){var x=$O.get(f);if(x)var k=x.get(null);else{x=new Map,$O.set(f,x);for(var R=f.querySelectorAll("link[data-precedence],style[data-precedence]"),L=0;L<R.length;L++){var V=R[L];(V.nodeName==="LINK"||V.getAttribute("media")!=="not all")&&(x.set(V.dataset.precedence,V),k=V)}k&&x.set(null,k)}R=p.instance,V=R.getAttribute("data-precedence"),L=x.get(V)||k,L===k&&x.set(null,R),x.set(V,R),this.count++,k=ek.bind(this),R.addEventListener("load",k),R.addEventListener("error",k),L?L.parentNode.insertBefore(R,L.nextSibling):(f=f.nodeType===9?f.head:f,f.insertBefore(R,f.firstChild)),p.state.loading|=4}}var Ev={$$typeof:B,Provider:null,Consumer:null,_currentValue:Se,_currentValue2:Se,_threadCount:0};function e6e(f,p,x,k,R,L,V,oe,ye){this.tag=1,this.containerInfo=f,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Ms(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ms(0),this.hiddenUpdates=Ms(null),this.identifierPrefix=k,this.onUncaughtError=R,this.onCaughtError=L,this.onRecoverableError=V,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=ye,this.transitionTypes=null,this.incompleteTransitions=new Map}function Nte(f,p,x,k,R,L,V,oe,ye,Ne,ze,Ge){return f=new e6e(f,p,x,V,ye,Ne,ze,Ge,oe),p=1,L===!0&&(p|=24),L=sa(3,null,null,p),f.current=L,L.stateNode=f,p=p3(),p.refCount++,f.pooledCache=p,p.refCount++,L.memoizedState={element:k,isDehydrated:x,cache:p},b3(L),f}function Lte(f){return f?(f=Qb,f):Qb}function Ite(f,p,x,k,R,L){R=Lte(R),k.context===null?k.context=R:k.pendingContext=R,k=hp(p),k.payload={element:x},L=L===void 0?null:L,L!==null&&(k.callback=L),x=pp(f,k,p),x!==null&&(ca(x,f,p),_S(x,f,p))}function Pte(f,p){if(f=f.memoizedState,f!==null&&f.dehydrated!==null){var x=f.retryLane;f.retryLane=x!==0&&x<p?x:p}}function e6(f,p){Pte(f,p),(f=f.alternate)&&Pte(f,p)}function jte(f){if(f.tag===13||f.tag===31){var p=s0(f,67108864);p!==null&&ca(p,f,67108864),e6(f,67108864)}}function Dte(f){if(f.tag===13||f.tag===31){var p=Wa();p=Ct(p);var x=s0(f,p);x!==null&&ca(x,f,p),e6(f,p)}}var Tv=!0;function t6e(f,p,x,k){var R=fe.T;fe.T=null;var L=se.p;try{se.p=2,t6(f,p,x,k)}finally{se.p=L,fe.T=R}}function n6e(f,p,x,k){var R=fe.T;fe.T=null;var L=se.p;try{se.p=8,t6(f,p,x,k)}finally{se.p=L,fe.T=R}}function t6(f,p,x,k){if(Tv){var R=n6(k);if(R===null)j5(f,p,k,FO,x),zte(f,k);else if(i6e(R,f,p,x,k))k.stopPropagation();else if(zte(f,k),p&4&&-1<r6e.indexOf(f)){for(;R!==null;){var L=ml(R);if(L!==null)switch(L.tag){case 3:if(L=L.stateNode,L.current.memoizedState.isDehydrated){var V=tr(L.pendingLanes);if(V!==0){var oe=L;for(oe.pendingLanes|=2,oe.entangledLanes|=2;V;){var ye=1<<31-qt(V);oe.entanglements[1]|=ye,V&=~ye}Ac(L),(dr&6)===0&&(EO=ln()+500,GS(0))}}break;case 31:case 13:oe=s0(L,2),oe!==null&&ca(oe,L,2),OO(),e6(L,2)}if(L=n6(k),L===null&&j5(f,p,k,FO,x),L===R)break;R=L}R!==null&&k.stopPropagation()}else j5(f,p,k,null,x)}}function n6(f){return f=e0(f),r6(f)}var FO=null;function r6(f){if(FO=null,f=ia(f),f!==null){var p=o(f);if(p===null)f=null;else{var x=p.tag;if(x===13){if(f=s(p),f!==null)return f;f=null}else if(x===31){if(f=a(p),f!==null)return f;f=null}else if(x===3){if(p.stateNode.current.memoizedState.isDehydrated)return p.tag===3?p.stateNode.containerInfo:null;f=null}else p!==f&&(f=null)}}return FO=f,null}function $te(f){switch(f){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"fullscreenerror":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"resize":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(mr()){case Yn:return 2;case Yt:return 8;case Ht:case on:return 32;case Jt:return 268435456;default:return 32}default:return 32}}var i6=!1,Tp=null,Ap=null,Op=null,tk=new Map,nk=new Map,Rp=[],r6e="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function zte(f,p){switch(f){case"focusin":case"focusout":Tp=null;break;case"dragenter":case"dragleave":Ap=null;break;case"mouseover":case"mouseout":Op=null;break;case"pointerover":case"pointerout":tk.delete(p.pointerId);break;case"gotpointercapture":case"lostpointercapture":nk.delete(p.pointerId)}}function rk(f,p,x,k,R,L){return f===null||f.nativeEvent!==L?(f={blockedOn:p,domEventName:x,eventSystemFlags:k,nativeEvent:L,targetContainers:[R]},p!==null&&(p=ml(p),p!==null&&jte(p)),f):(f.eventSystemFlags|=k,p=f.targetContainers,R!==null&&p.indexOf(R)===-1&&p.push(R),f)}function i6e(f,p,x,k,R){switch(p){case"focusin":return Tp=rk(Tp,f,p,x,k,R),!0;case"dragenter":return Ap=rk(Ap,f,p,x,k,R),!0;case"mouseover":return Op=rk(Op,f,p,x,k,R),!0;case"pointerover":var L=R.pointerId;return tk.set(L,rk(tk.get(L)||null,f,p,x,k,R)),!0;case"gotpointercapture":return L=R.pointerId,nk.set(L,rk(nk.get(L)||null,f,p,x,k,R)),!0}return!1}function Fte(f){var p=ia(f.target);if(p!==null){var x=o(p);if(x!==null){if(p=x.tag,p===13){if(p=s(x),p!==null){f.blockedOn=p,pu(f.priority,function(){Dte(x)});return}}else if(p===31){if(p=a(x),p!==null){f.blockedOn=p,pu(f.priority,function(){Dte(x)});return}}else if(p===3&&x.stateNode.current.memoizedState.isDehydrated){f.blockedOn=x.tag===3?x.stateNode.containerInfo:null;return}}}f.blockedOn=null}function BO(f){if(f.blockedOn!==null)return!1;for(var p=f.targetContainers;0<p.length;){var x=n6(f.nativeEvent);if(x===null){x=f.nativeEvent;var k=new x.constructor(x.type,x);Jg=k,x.target.dispatchEvent(k),Jg=null}else return p=ml(x),p!==null&&jte(p),f.blockedOn=x,!1;p.shift()}return!0}function Bte(f,p,x){BO(f)&&x.delete(p)}function o6e(){i6=!1,Tp!==null&&BO(Tp)&&(Tp=null),Ap!==null&&BO(Ap)&&(Ap=null),Op!==null&&BO(Op)&&(Op=null),tk.forEach(Bte),nk.forEach(Bte)}function HO(f,p){f.blockedOn===p&&(f.blockedOn=null,i6||(i6=!0,e.unstable_scheduleCallback(e.unstable_NormalPriority,o6e)))}var UO=null;function Hte(f){UO!==f&&(UO=f,e.unstable_scheduleCallback(e.unstable_NormalPriority,function(){UO===f&&(UO=null);for(var p=0;p<f.length;p+=3){var x=f[p],k=f[p+1],R=f[p+2];if(typeof k!="function"){if(r6(k||x)===null)continue;break}var L=ml(x);L!==null&&(f.splice(p,3),p-=3,z3(L,{pending:!0,data:R,method:x.method,action:k},k,R))}}))}function Av(f){function p(ye){return HO(ye,f)}Tp!==null&&HO(Tp,f),Ap!==null&&HO(Ap,f),Op!==null&&HO(Op,f),tk.forEach(p),nk.forEach(p);for(var x=0;x<Rp.length;x++){var k=Rp[x];k.blockedOn===f&&(k.blockedOn=null)}for(;0<Rp.length&&(x=Rp[0],x.blockedOn===null);)Fte(x),x.blockedOn===null&&Rp.shift();if(x=(f.ownerDocument||f).$$reactFormReplay,x!=null)for(k=0;k<x.length;k+=3){var R=x[k],L=x[k+1],V=R[Te]||null;if(typeof L=="function")V||Hte(x);else if(V){var oe=null;if(L&&L.hasAttribute("formAction")){if(R=L,V=L[Te]||null)oe=V.formAction;else if(r6(R)!==null)continue}else oe=V.action;typeof oe=="function"?x[k+1]=oe:(x.splice(k,3),k-=3),Hte(x)}}}function Ute(){function f(L){L.canIntercept&&L.info==="react-transition"&&L.intercept({handler:function(){return new Promise(function(V){return R=V})},focusReset:"manual",scroll:"manual"})}function p(){R!==null&&(R(),R=null),k||setTimeout(x,20)}function x(){if(!k&&!navigation.transition){var L=navigation.currentEntry;L&&L.url!=null&&navigation.navigate(L.url,{state:L.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var k=!1,R=null;return navigation.addEventListener("navigate",f),navigation.addEventListener("navigatesuccess",p),navigation.addEventListener("navigateerror",p),setTimeout(x,100),function(){k=!0,navigation.removeEventListener("navigate",f),navigation.removeEventListener("navigatesuccess",p),navigation.removeEventListener("navigateerror",p),R!==null&&(R(),R=null)}}}function o6(f){this._internalRoot=f}VO.prototype.render=o6.prototype.render=function(f){var p=this._internalRoot;if(p===null)throw Error(r(409));var x=p.current,k=Wa();Ite(x,k,f,p,null,null)},VO.prototype.unmount=o6.prototype.unmount=function(){var f=this._internalRoot;if(f!==null){this._internalRoot=null;var p=f.containerInfo;Ite(f.current,2,null,f,null,null),OO(),p[Xe]=null}};function VO(f){this._internalRoot=f}VO.prototype.unstable_scheduleHydration=function(f){if(f){var p=fc();f={blockedOn:null,target:f,priority:p};for(var x=0;x<Rp.length&&p!==0&&p<Rp[x].priority;x++);Rp.splice(x,0,f),x===0&&Fte(f)}};var Vte=t.version;if(Vte!=="19.3.1")throw Error(r(527,Vte,"19.3.1"));se.findDOMNode=function(f){var p=f._reactInternals;if(p===void 0)throw typeof f.render=="function"?Error(r(188)):(f=Object.keys(f).join(","),Error(r(268,f)));return f=u(p),f=f!==null?c(f):null,f=f===null?null:f.stateNode,f};var s6e={bundleType:0,version:"19.3.1",rendererPackageName:"react-dom",currentDispatcherRef:fe,reconcilerVersion:"19.3.1"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var WO=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!WO.isDisabled&&WO.supportsFiber)try{Fe=WO.inject(s6e),Qe=WO}catch{}}return Mk.createRoot=function(f,p){if(!i(f))throw Error(r(299));var x=!1,k="",R=LJ,L=IJ,V=PJ;return p!=null&&(p.unstable_strictMode===!0&&(x=!0),p.identifierPrefix!==void 0&&(k=p.identifierPrefix),p.onUncaughtError!==void 0&&(R=p.onUncaughtError),p.onCaughtError!==void 0&&(L=p.onCaughtError),p.onRecoverableError!==void 0&&(V=p.onRecoverableError)),p=Nte(f,1,!1,null,null,x,k,null,R,L,V,Ute),f[Xe]=p.current,P5(f),new o6(p)},Mk.hydrateRoot=function(f,p,x){if(!i(f))throw Error(r(299));var k=!1,R="",L=LJ,V=IJ,oe=PJ,ye=null;return x!=null&&(x.unstable_strictMode===!0&&(k=!0),x.identifierPrefix!==void 0&&(R=x.identifierPrefix),x.onUncaughtError!==void 0&&(L=x.onUncaughtError),x.onCaughtError!==void 0&&(V=x.onCaughtError),x.onRecoverableError!==void 0&&(oe=x.onRecoverableError),x.formState!==void 0&&(ye=x.formState)),p=Nte(f,1,!0,p,x??null,k,R,ye,L,V,oe,Ute),p.context=Lte(null),x=p.current,k=Wa(),k=Ct(k),R=hp(k),R.callback=null,pp(x,R,k),x=k,p.current.lanes=x,Ri(p,x),Ac(p),f[Xe]=p.current,P5(f),new VO(p)},Mk.version="19.3.1",Mk}var l0e;function Ezt(){if(l0e)return ZB.exports;l0e=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),ZB.exports=Czt(),ZB.exports}var Tzt=Ezt();function $i(e){if(typeof e=="string"||typeof e=="number")return""+e;let t="";if(Array.isArray(e))for(let n=0,r;n<e.length;n++)(r=$i(e[n]))!==""&&(t+=(t&&" ")+r);else for(let n in e)e[n]&&(t+=(t&&" ")+n);return t}var Azt={value:()=>{}};function PD(){for(var e=0,t=arguments.length,n={},r;e<t;++e){if(!(r=arguments[e]+"")||r in n||/[\s.]/.test(r))throw new Error("illegal type: "+r);n[r]=[]}return new D_(n)}function D_(e){this._=e}function Ozt(e,t){return e.trim().split(/^|\s+/).map(function(n){var r="",i=n.indexOf(".");if(i>=0&&(r=n.slice(i+1),n=n.slice(0,i)),n&&!t.hasOwnProperty(n))throw new Error("unknown type: "+n);return{type:n,name:r}})}D_.prototype=PD.prototype={constructor:D_,on:function(e,t){var n=this._,r=Ozt(e+"",n),i,o=-1,s=r.length;if(arguments.length<2){for(;++o<s;)if((i=(e=r[o]).type)&&(i=Rzt(n[i],e.name)))return i;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++o<s;)if(i=(e=r[o]).type)n[i]=u0e(n[i],e.name,t);else if(t==null)for(i in n)n[i]=u0e(n[i],e.name,null);return this},copy:function(){var e={},t=this._;for(var n in t)e[n]=t[n].slice();return new D_(e)},call:function(e,t){if((i=arguments.length-2)>0)for(var n=new Array(i),r=0,i,o;r<i;++r)n[r]=arguments[r+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(o=this._[e],r=0,i=o.length;r<i;++r)o[r].value.apply(t,n)},apply:function(e,t,n){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var r=this._[e],i=0,o=r.length;i<o;++i)r[i].value.apply(t,n)}};function Rzt(e,t){for(var n=0,r=e.length,i;n<r;++n)if((i=e[n]).name===t)return i.value}function u0e(e,t,n){for(var r=0,i=e.length;r<i;++r)if(e[r].name===t){e[r]=Azt,e=e.slice(0,r).concat(e.slice(r+1));break}return n!=null&&e.push({name:t,value:n}),e}var qW="http://www.w3.org/1999/xhtml";const c0e={svg:"http://www.w3.org/2000/svg",xhtml:qW,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function jD(e){var t=e+="",n=t.indexOf(":");return n>=0&&(t=e.slice(0,n))!=="xmlns"&&(e=e.slice(n+1)),c0e.hasOwnProperty(t)?{space:c0e[t],local:e}:e}function Mzt(e){return function(){var t=this.ownerDocument,n=this.namespaceURI;return n===qW&&t.documentElement.namespaceURI===qW?t.createElement(e):t.createElementNS(n,e)}}function _zt(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function cPe(e){var t=jD(e);return(t.local?_zt:Mzt)(t)}function Nzt(){}function EQ(e){return e==null?Nzt:function(){return this.querySelector(e)}}function Lzt(e){typeof e!="function"&&(e=EQ(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var o=t[i],s=o.length,a=r[i]=new Array(s),l,u,c=0;c<s;++c)(l=o[c])&&(u=e.call(l,l.__data__,c,o))&&("__data__"in l&&(u.__data__=l.__data__),a[c]=u);return new hl(r,this._parents)}function Izt(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function Pzt(){return[]}function dPe(e){return e==null?Pzt:function(){return this.querySelectorAll(e)}}function jzt(e){return function(){return Izt(e.apply(this,arguments))}}function Dzt(e){typeof e=="function"?e=jzt(e):e=dPe(e);for(var t=this._groups,n=t.length,r=[],i=[],o=0;o<n;++o)for(var s=t[o],a=s.length,l,u=0;u<a;++u)(l=s[u])&&(r.push(e.call(l,l.__data__,u,s)),i.push(l));return new hl(r,i)}function fPe(e){return function(){return this.matches(e)}}function hPe(e){return function(t){return t.matches(e)}}var $zt=Array.prototype.find;function zzt(e){return function(){return $zt.call(this.children,e)}}function Fzt(){return this.firstElementChild}function Bzt(e){return this.select(e==null?Fzt:zzt(typeof e=="function"?e:hPe(e)))}var Hzt=Array.prototype.filter;function Uzt(){return Array.from(this.children)}function Vzt(e){return function(){return Hzt.call(this.children,e)}}function Wzt(e){return this.selectAll(e==null?Uzt:Vzt(typeof e=="function"?e:hPe(e)))}function qzt(e){typeof e!="function"&&(e=fPe(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var o=t[i],s=o.length,a=r[i]=[],l,u=0;u<s;++u)(l=o[u])&&e.call(l,l.__data__,u,o)&&a.push(l);return new hl(r,this._parents)}function pPe(e){return new Array(e.length)}function Gzt(){return new hl(this._enter||this._groups.map(pPe),this._parents)}function KI(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}KI.prototype={constructor:KI,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function Kzt(e){return function(){return e}}function Yzt(e,t,n,r,i,o){for(var s=0,a,l=t.length,u=o.length;s<u;++s)(a=t[s])?(a.__data__=o[s],r[s]=a):n[s]=new KI(e,o[s]);for(;s<l;++s)(a=t[s])&&(i[s]=a)}function Xzt(e,t,n,r,i,o,s){var a,l,u=new Map,c=t.length,d=o.length,h=new Array(c),m;for(a=0;a<c;++a)(l=t[a])&&(h[a]=m=s.call(l,l.__data__,a,t)+"",u.has(m)?i[a]=l:u.set(m,l));for(a=0;a<d;++a)m=s.call(e,o[a],a,o)+"",(l=u.get(m))?(r[a]=l,l.__data__=o[a],u.delete(m)):n[a]=new KI(e,o[a]);for(a=0;a<c;++a)(l=t[a])&&u.get(h[a])===l&&(i[a]=l)}function Qzt(e){return e.__data__}function Zzt(e,t){if(!arguments.length)return Array.from(this,Qzt);var n=t?Xzt:Yzt,r=this._parents,i=this._groups;typeof e!="function"&&(e=Kzt(e));for(var o=i.length,s=new Array(o),a=new Array(o),l=new Array(o),u=0;u<o;++u){var c=r[u],d=i[u],h=d.length,m=Jzt(e.call(c,c&&c.__data__,u,r)),g=m.length,b=a[u]=new Array(g),v=s[u]=new Array(g),w=l[u]=new Array(h);n(c,d,b,v,w,m,t);for(var S=0,C=0,E,T;S<g;++S)if(E=b[S]){for(S>=C&&(C=S+1);!(T=v[C])&&++C<g;);E._next=T||null}}return s=new hl(s,r),s._enter=a,s._exit=l,s}function Jzt(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function eFt(){return new hl(this._exit||this._groups.map(pPe),this._parents)}function tFt(e,t,n){var r=this.enter(),i=this,o=this.exit();return typeof e=="function"?(r=e(r),r&&(r=r.selection())):r=r.append(e+""),t!=null&&(i=t(i),i&&(i=i.selection())),n==null?o.remove():n(o),r&&i?r.merge(i).order():i}function nFt(e){for(var t=e.selection?e.selection():e,n=this._groups,r=t._groups,i=n.length,o=r.length,s=Math.min(i,o),a=new Array(i),l=0;l<s;++l)for(var u=n[l],c=r[l],d=u.length,h=a[l]=new Array(d),m,g=0;g<d;++g)(m=u[g]||c[g])&&(h[g]=m);for(;l<i;++l)a[l]=n[l];return new hl(a,this._parents)}function rFt(){for(var e=this._groups,t=-1,n=e.length;++t<n;)for(var r=e[t],i=r.length-1,o=r[i],s;--i>=0;)(s=r[i])&&(o&&s.compareDocumentPosition(o)^4&&o.parentNode.insertBefore(s,o),o=s);return this}function iFt(e){e||(e=oFt);function t(d,h){return d&&h?e(d.__data__,h.__data__):!d-!h}for(var n=this._groups,r=n.length,i=new Array(r),o=0;o<r;++o){for(var s=n[o],a=s.length,l=i[o]=new Array(a),u,c=0;c<a;++c)(u=s[c])&&(l[c]=u);l.sort(t)}return new hl(i,this._parents).order()}function oFt(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function sFt(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function aFt(){return Array.from(this)}function lFt(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var r=e[t],i=0,o=r.length;i<o;++i){var s=r[i];if(s)return s}return null}function uFt(){let e=0;for(const t of this)++e;return e}function cFt(){return!this.node()}function dFt(e){for(var t=this._groups,n=0,r=t.length;n<r;++n)for(var i=t[n],o=0,s=i.length,a;o<s;++o)(a=i[o])&&e.call(a,a.__data__,o,i);return this}function fFt(e){return function(){this.removeAttribute(e)}}function hFt(e){return function(){this.removeAttributeNS(e.space,e.local)}}function pFt(e,t){return function(){this.setAttribute(e,t)}}function mFt(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function gFt(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttribute(e):this.setAttribute(e,n)}}function yFt(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,n)}}function bFt(e,t){var n=jD(e);if(arguments.length<2){var r=this.node();return n.local?r.getAttributeNS(n.space,n.local):r.getAttribute(n)}return this.each((t==null?n.local?hFt:fFt:typeof t=="function"?n.local?yFt:gFt:n.local?mFt:pFt)(n,t))}function mPe(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function vFt(e){return function(){this.style.removeProperty(e)}}function xFt(e,t,n){return function(){this.style.setProperty(e,t,n)}}function wFt(e,t,n){return function(){var r=t.apply(this,arguments);r==null?this.style.removeProperty(e):this.style.setProperty(e,r,n)}}function SFt(e,t,n){return arguments.length>1?this.each((t==null?vFt:typeof t=="function"?wFt:xFt)(e,t,n??"")):Ow(this.node(),e)}function Ow(e,t){return e.style.getPropertyValue(t)||mPe(e).getComputedStyle(e,null).getPropertyValue(t)}function kFt(e){return function(){delete this[e]}}function CFt(e,t){return function(){this[e]=t}}function EFt(e,t){return function(){var n=t.apply(this,arguments);n==null?delete this[e]:this[e]=n}}function TFt(e,t){return arguments.length>1?this.each((t==null?kFt:typeof t=="function"?EFt:CFt)(e,t)):this.node()[e]}function gPe(e){return e.trim().split(/^|\s+/)}function TQ(e){return e.classList||new yPe(e)}function yPe(e){this._node=e,this._names=gPe(e.getAttribute("class")||"")}yPe.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function bPe(e,t){for(var n=TQ(e),r=-1,i=t.length;++r<i;)n.add(t[r])}function vPe(e,t){for(var n=TQ(e),r=-1,i=t.length;++r<i;)n.remove(t[r])}function AFt(e){return function(){bPe(this,e)}}function OFt(e){return function(){vPe(this,e)}}function RFt(e,t){return function(){(t.apply(this,arguments)?bPe:vPe)(this,e)}}function MFt(e,t){var n=gPe(e+"");if(arguments.length<2){for(var r=TQ(this.node()),i=-1,o=n.length;++i<o;)if(!r.contains(n[i]))return!1;return!0}return this.each((typeof t=="function"?RFt:t?AFt:OFt)(n,t))}function _Ft(){this.textContent=""}function NFt(e){return function(){this.textContent=e}}function LFt(e){return function(){var t=e.apply(this,arguments);this.textContent=t??""}}function IFt(e){return arguments.length?this.each(e==null?_Ft:(typeof e=="function"?LFt:NFt)(e)):this.node().textContent}function PFt(){this.innerHTML=""}function jFt(e){return function(){this.innerHTML=e}}function DFt(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t??""}}function $Ft(e){return arguments.length?this.each(e==null?PFt:(typeof e=="function"?DFt:jFt)(e)):this.node().innerHTML}function zFt(){this.nextSibling&&this.parentNode.appendChild(this)}function FFt(){return this.each(zFt)}function BFt(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function HFt(){return this.each(BFt)}function UFt(e){var t=typeof e=="function"?e:cPe(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function VFt(){return null}function WFt(e,t){var n=typeof e=="function"?e:cPe(e),r=t==null?VFt:typeof t=="function"?t:EQ(t);return this.select(function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)})}function qFt(){var e=this.parentNode;e&&e.removeChild(this)}function GFt(){return this.each(qFt)}function KFt(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function YFt(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function XFt(e){return this.select(e?YFt:KFt)}function QFt(e){return arguments.length?this.property("__data__",e):this.node().__data__}function ZFt(e){return function(t){e.call(this,t,this.__data__)}}function JFt(e){return e.trim().split(/^|\s+/).map(function(t){var n="",r=t.indexOf(".");return r>=0&&(n=t.slice(r+1),t=t.slice(0,r)),{type:t,name:n}})}function eBt(e){return function(){var t=this.__on;if(t){for(var n=0,r=-1,i=t.length,o;n<i;++n)o=t[n],(!e.type||o.type===e.type)&&o.name===e.name?this.removeEventListener(o.type,o.listener,o.options):t[++r]=o;++r?t.length=r:delete this.__on}}}function tBt(e,t,n){return function(){var r=this.__on,i,o=ZFt(t);if(r){for(var s=0,a=r.length;s<a;++s)if((i=r[s]).type===e.type&&i.name===e.name){this.removeEventListener(i.type,i.listener,i.options),this.addEventListener(i.type,i.listener=o,i.options=n),i.value=t;return}}this.addEventListener(e.type,o,n),i={type:e.type,name:e.name,value:t,listener:o,options:n},r?r.push(i):this.__on=[i]}}function nBt(e,t,n){var r=JFt(e+""),i,o=r.length,s;if(arguments.length<2){var a=this.node().__on;if(a){for(var l=0,u=a.length,c;l<u;++l)for(i=0,c=a[l];i<o;++i)if((s=r[i]).type===c.type&&s.name===c.name)return c.value}return}for(a=t?tBt:eBt,i=0;i<o;++i)this.each(a(r[i],t,n));return this}function xPe(e,t,n){var r=mPe(e),i=r.CustomEvent;typeof i=="function"?i=new i(t,n):(i=r.document.createEvent("Event"),n?(i.initEvent(t,n.bubbles,n.cancelable),i.detail=n.detail):i.initEvent(t,!1,!1)),e.dispatchEvent(i)}function rBt(e,t){return function(){return xPe(this,e,t)}}function iBt(e,t){return function(){return xPe(this,e,t.apply(this,arguments))}}function oBt(e,t){return this.each((typeof t=="function"?iBt:rBt)(e,t))}function*sBt(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var r=e[t],i=0,o=r.length,s;i<o;++i)(s=r[i])&&(yield s)}var wPe=[null];function hl(e,t){this._groups=e,this._parents=t}function AA(){return new hl([[document.documentElement]],wPe)}function aBt(){return this}hl.prototype=AA.prototype={constructor:hl,select:Lzt,selectAll:Dzt,selectChild:Bzt,selectChildren:Wzt,filter:qzt,data:Zzt,enter:Gzt,exit:eFt,join:tFt,merge:nFt,selection:aBt,order:rFt,sort:iFt,call:sFt,nodes:aFt,node:lFt,size:uFt,empty:cFt,each:dFt,attr:bFt,style:SFt,property:TFt,classed:MFt,text:IFt,html:$Ft,raise:FFt,lower:HFt,append:UFt,insert:WFt,remove:GFt,clone:XFt,datum:QFt,on:nBt,dispatch:oBt,[Symbol.iterator]:sBt};function al(e){return typeof e=="string"?new hl([[document.querySelector(e)]],[document.documentElement]):new hl([[e]],wPe)}function lBt(e){let t;for(;t=e.sourceEvent;)e=t;return e}function Fu(e,t){if(e=lBt(e),t===void 0&&(t=e.currentTarget),t){var n=t.ownerSVGElement||t;if(n.createSVGPoint){var r=n.createSVGPoint();return r.x=e.clientX,r.y=e.clientY,r=r.matrixTransform(t.getScreenCTM().inverse()),[r.x,r.y]}if(t.getBoundingClientRect){var i=t.getBoundingClientRect();return[e.clientX-i.left-t.clientLeft,e.clientY-i.top-t.clientTop]}}return[e.pageX,e.pageY]}const uBt={passive:!1},jT={capture:!0,passive:!1};function t7(e){e.stopImmediatePropagation()}function G1(e){e.preventDefault(),e.stopImmediatePropagation()}function SPe(e){var t=e.document.documentElement,n=al(e).on("dragstart.drag",G1,jT);"onselectstart"in t?n.on("selectstart.drag",G1,jT):(t.__noselect=t.style.MozUserSelect,t.style.MozUserSelect="none")}function kPe(e,t){var n=e.document.documentElement,r=al(e).on("dragstart.drag",null);t&&(r.on("click.drag",G1,jT),setTimeout(function(){r.on("click.drag",null)},0)),"onselectstart"in n?r.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}const xM=e=>()=>e;function GW(e,{sourceEvent:t,subject:n,target:r,identifier:i,active:o,x:s,y:a,dx:l,dy:u,dispatch:c}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},subject:{value:n,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},identifier:{value:i,enumerable:!0,configurable:!0},active:{value:o,enumerable:!0,configurable:!0},x:{value:s,enumerable:!0,configurable:!0},y:{value:a,enumerable:!0,configurable:!0},dx:{value:l,enumerable:!0,configurable:!0},dy:{value:u,enumerable:!0,configurable:!0},_:{value:c}})}GW.prototype.on=function(){var e=this._.on.apply(this._,arguments);return e===this._?this:e};function cBt(e){return!e.ctrlKey&&!e.button}function dBt(){return this.parentNode}function fBt(e,t){return t??{x:e.x,y:e.y}}function hBt(){return navigator.maxTouchPoints||"ontouchstart"in this}function CPe(){var e=cBt,t=dBt,n=fBt,r=hBt,i={},o=PD("start","drag","end"),s=0,a,l,u,c,d=0;function h(E){E.on("mousedown.drag",m).filter(r).on("touchstart.drag",v).on("touchmove.drag",w,uBt).on("touchend.drag touchcancel.drag",S).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function m(E,T){if(!(c||!e.call(this,E,T))){var O=C(this,t.call(this,E,T),E,T,"mouse");O&&(al(E.view).on("mousemove.drag",g,jT).on("mouseup.drag",b,jT),SPe(E.view),t7(E),u=!1,a=E.clientX,l=E.clientY,O("start",E))}}function g(E){if(G1(E),!u){var T=E.clientX-a,O=E.clientY-l;u=T*T+O*O>d}i.mouse("drag",E)}function b(E){al(E.view).on("mousemove.drag mouseup.drag",null),kPe(E.view,u),G1(E),i.mouse("end",E)}function v(E,T){if(e.call(this,E,T)){var O=E.changedTouches,M=t.call(this,E,T),N=O.length,I,D;for(I=0;I<N;++I)(D=C(this,M,E,T,O[I].identifier,O[I]))&&(t7(E),D("start",E,O[I]))}}function w(E){var T=E.changedTouches,O=T.length,M,N;for(M=0;M<O;++M)(N=i[T[M].identifier])&&(G1(E),N("drag",E,T[M]))}function S(E){var T=E.changedTouches,O=T.length,M,N;for(c&&clearTimeout(c),c=setTimeout(function(){c=null},500),M=0;M<O;++M)(N=i[T[M].identifier])&&(t7(E),N("end",E,T[M]))}function C(E,T,O,M,N,I){var D=o.copy(),P=Fu(I||O,T),F,z,$;if(($=n.call(E,new GW("beforestart",{sourceEvent:O,target:h,identifier:N,active:s,x:P[0],y:P[1],dx:0,dy:0,dispatch:D}),M))!=null)return F=$.x-P[0]||0,z=$.y-P[1]||0,function B(H,U,W){var q=P,Y;switch(H){case"start":i[N]=B,Y=s++;break;case"end":delete i[N],--s;case"drag":P=Fu(W||U,T),Y=s;break}D.call(H,E,new GW(H,{sourceEvent:U,subject:$,target:h,identifier:N,active:Y,x:P[0]+F,y:P[1]+z,dx:P[0]-q[0],dy:P[1]-q[1],dispatch:D}),M)}}return h.filter=function(E){return arguments.length?(e=typeof E=="function"?E:xM(!!E),h):e},h.container=function(E){return arguments.length?(t=typeof E=="function"?E:xM(E),h):t},h.subject=function(E){return arguments.length?(n=typeof E=="function"?E:xM(E),h):n},h.touchable=function(E){return arguments.length?(r=typeof E=="function"?E:xM(!!E),h):r},h.on=function(){var E=o.on.apply(o,arguments);return E===o?h:E},h.clickDistance=function(E){return arguments.length?(d=(E=+E)*E,h):Math.sqrt(d)},h}var Rw=0,gC=0,_k=0,EPe=1e3,YI,yC,XI=0,Cb=0,DD=0,DT=typeof performance=="object"&&performance.now?performance:Date,TPe=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function AQ(){return Cb||(TPe(pBt),Cb=DT.now()+DD)}function pBt(){Cb=0}function QI(){this._call=this._time=this._next=null}QI.prototype=APe.prototype={constructor:QI,restart:function(e,t,n){if(typeof e!="function")throw new TypeError("callback is not a function");n=(n==null?AQ():+n)+(t==null?0:+t),!this._next&&yC!==this&&(yC?yC._next=this:YI=this,yC=this),this._call=e,this._time=n,KW()},stop:function(){this._call&&(this._call=null,this._time=1/0,KW())}};function APe(e,t,n){var r=new QI;return r.restart(e,t,n),r}function mBt(){AQ(),++Rw;for(var e=YI,t;e;)(t=Cb-e._time)>=0&&e._call.call(void 0,t),e=e._next;--Rw}function d0e(){Cb=(XI=DT.now())+DD,Rw=gC=0;try{mBt()}finally{Rw=0,yBt(),Cb=0}}function gBt(){var e=DT.now(),t=e-XI;t>EPe&&(DD-=t,XI=e)}function yBt(){for(var e,t=YI,n,r=1/0;t;)t._call?(r>t._time&&(r=t._time),e=t,t=t._next):(n=t._next,t._next=null,t=e?e._next=n:YI=n);yC=e,KW(r)}function KW(e){if(!Rw){gC&&(gC=clearTimeout(gC));var t=e-Cb;t>24?(e<1/0&&(gC=setTimeout(d0e,e-DT.now()-DD)),_k&&(_k=clearInterval(_k))):(_k||(XI=DT.now(),_k=setInterval(gBt,EPe)),Rw=1,TPe(d0e))}}function f0e(e,t,n){var r=new QI;return t=t==null?0:+t,r.restart(i=>{r.stop(),e(i+t)},t,n),r}var bBt=PD("start","end","cancel","interrupt"),vBt=[],OPe=0,h0e=1,YW=2,$_=3,p0e=4,XW=5,z_=6;function $D(e,t,n,r,i,o){var s=e.__transition;if(!s)e.__transition={};else if(n in s)return;xBt(e,n,{name:t,index:r,group:i,on:bBt,tween:vBt,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:OPe})}function OQ(e,t){var n=cc(e,t);if(n.state>OPe)throw new Error("too late; already scheduled");return n}function Ud(e,t){var n=cc(e,t);if(n.state>$_)throw new Error("too late; already running");return n}function cc(e,t){var n=e.__transition;if(!n||!(n=n[t]))throw new Error("transition not found");return n}function xBt(e,t,n){var r=e.__transition,i;r[t]=n,n.timer=APe(o,0,n.time);function o(u){n.state=h0e,n.timer.restart(s,n.delay,n.time),n.delay<=u&&s(u-n.delay)}function s(u){var c,d,h,m;if(n.state!==h0e)return l();for(c in r)if(m=r[c],m.name===n.name){if(m.state===$_)return f0e(s);m.state===p0e?(m.state=z_,m.timer.stop(),m.on.call("interrupt",e,e.__data__,m.index,m.group),delete r[c]):+c<t&&(m.state=z_,m.timer.stop(),m.on.call("cancel",e,e.__data__,m.index,m.group),delete r[c])}if(f0e(function(){n.state===$_&&(n.state=p0e,n.timer.restart(a,n.delay,n.time),a(u))}),n.state=YW,n.on.call("start",e,e.__data__,n.index,n.group),n.state===YW){for(n.state=$_,i=new Array(h=n.tween.length),c=0,d=-1;c<h;++c)(m=n.tween[c].value.call(e,e.__data__,n.index,n.group))&&(i[++d]=m);i.length=d+1}}function a(u){for(var c=u<n.duration?n.ease.call(null,u/n.duration):(n.timer.restart(l),n.state=XW,1),d=-1,h=i.length;++d<h;)i[d].call(e,c);n.state===XW&&(n.on.call("end",e,e.__data__,n.index,n.group),l())}function l(){n.state=z_,n.timer.stop(),delete r[t];for(var u in r)return;delete e.__transition}}function F_(e,t){var n=e.__transition,r,i,o=!0,s;if(n){t=t==null?null:t+"";for(s in n){if((r=n[s]).name!==t){o=!1;continue}i=r.state>YW&&r.state<XW,r.state=z_,r.timer.stop(),r.on.call(i?"interrupt":"cancel",e,e.__data__,r.index,r.group),delete n[s]}o&&delete e.__transition}}function wBt(e){return this.each(function(){F_(this,e)})}function SBt(e,t){var n,r;return function(){var i=Ud(this,e),o=i.tween;if(o!==n){r=n=o;for(var s=0,a=r.length;s<a;++s)if(r[s].name===t){r=r.slice(),r.splice(s,1);break}}i.tween=r}}function kBt(e,t,n){var r,i;if(typeof n!="function")throw new Error;return function(){var o=Ud(this,e),s=o.tween;if(s!==r){i=(r=s).slice();for(var a={name:t,value:n},l=0,u=i.length;l<u;++l)if(i[l].name===t){i[l]=a;break}l===u&&i.push(a)}o.tween=i}}function CBt(e,t){var n=this._id;if(e+="",arguments.length<2){for(var r=cc(this.node(),n).tween,i=0,o=r.length,s;i<o;++i)if((s=r[i]).name===e)return s.value;return null}return this.each((t==null?SBt:kBt)(n,e,t))}function RQ(e,t,n){var r=e._id;return e.each(function(){var i=Ud(this,r);(i.value||(i.value={}))[t]=n.apply(this,arguments)}),function(i){return cc(i,r).value[t]}}function RPe(e,t){var n;return(typeof t=="number"?Uu:t instanceof yb?XE:(n=yb(t))?(t=n,XE):ARe)(e,t)}function EBt(e){return function(){this.removeAttribute(e)}}function TBt(e){return function(){this.removeAttributeNS(e.space,e.local)}}function ABt(e,t,n){var r,i=n+"",o;return function(){var s=this.getAttribute(e);return s===i?null:s===r?o:o=t(r=s,n)}}function OBt(e,t,n){var r,i=n+"",o;return function(){var s=this.getAttributeNS(e.space,e.local);return s===i?null:s===r?o:o=t(r=s,n)}}function RBt(e,t,n){var r,i,o;return function(){var s,a=n(this),l;return a==null?void this.removeAttribute(e):(s=this.getAttribute(e),l=a+"",s===l?null:s===r&&l===i?o:(i=l,o=t(r=s,a)))}}function MBt(e,t,n){var r,i,o;return function(){var s,a=n(this),l;return a==null?void this.removeAttributeNS(e.space,e.local):(s=this.getAttributeNS(e.space,e.local),l=a+"",s===l?null:s===r&&l===i?o:(i=l,o=t(r=s,a)))}}function _Bt(e,t){var n=jD(e),r=n==="transform"?xwt:RPe;return this.attrTween(e,typeof t=="function"?(n.local?MBt:RBt)(n,r,RQ(this,"attr."+e,t)):t==null?(n.local?TBt:EBt)(n):(n.local?OBt:ABt)(n,r,t))}function NBt(e,t){return function(n){this.setAttribute(e,t.call(this,n))}}function LBt(e,t){return function(n){this.setAttributeNS(e.space,e.local,t.call(this,n))}}function IBt(e,t){var n,r;function i(){var o=t.apply(this,arguments);return o!==r&&(n=(r=o)&&LBt(e,o)),n}return i._value=t,i}function PBt(e,t){var n,r;function i(){var o=t.apply(this,arguments);return o!==r&&(n=(r=o)&&NBt(e,o)),n}return i._value=t,i}function jBt(e,t){var n="attr."+e;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(t==null)return this.tween(n,null);if(typeof t!="function")throw new Error;var r=jD(e);return this.tween(n,(r.local?IBt:PBt)(r,t))}function DBt(e,t){return function(){OQ(this,e).delay=+t.apply(this,arguments)}}function $Bt(e,t){return t=+t,function(){OQ(this,e).delay=t}}function zBt(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?DBt:$Bt)(t,e)):cc(this.node(),t).delay}function FBt(e,t){return function(){Ud(this,e).duration=+t.apply(this,arguments)}}function BBt(e,t){return t=+t,function(){Ud(this,e).duration=t}}function HBt(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?FBt:BBt)(t,e)):cc(this.node(),t).duration}function UBt(e,t){if(typeof t!="function")throw new Error;return function(){Ud(this,e).ease=t}}function VBt(e){var t=this._id;return arguments.length?this.each(UBt(t,e)):cc(this.node(),t).ease}function WBt(e,t){return function(){var n=t.apply(this,arguments);if(typeof n!="function")throw new Error;Ud(this,e).ease=n}}function qBt(e){if(typeof e!="function")throw new Error;return this.each(WBt(this._id,e))}function GBt(e){typeof e!="function"&&(e=fPe(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var o=t[i],s=o.length,a=r[i]=[],l,u=0;u<s;++u)(l=o[u])&&e.call(l,l.__data__,u,o)&&a.push(l);return new Vh(r,this._parents,this._name,this._id)}function KBt(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,n=e._groups,r=t.length,i=n.length,o=Math.min(r,i),s=new Array(r),a=0;a<o;++a)for(var l=t[a],u=n[a],c=l.length,d=s[a]=new Array(c),h,m=0;m<c;++m)(h=l[m]||u[m])&&(d[m]=h);for(;a<r;++a)s[a]=t[a];return new Vh(s,this._parents,this._name,this._id)}function YBt(e){return(e+"").trim().split(/^|\s+/).every(function(t){var n=t.indexOf(".");return n>=0&&(t=t.slice(0,n)),!t||t==="start"})}function XBt(e,t,n){var r,i,o=YBt(t)?OQ:Ud;return function(){var s=o(this,e),a=s.on;a!==r&&(i=(r=a).copy()).on(t,n),s.on=i}}function QBt(e,t){var n=this._id;return arguments.length<2?cc(this.node(),n).on.on(e):this.each(XBt(n,e,t))}function ZBt(e){return function(){var t=this.parentNode;for(var n in this.__transition)if(+n!==e)return;t&&t.removeChild(this)}}function JBt(){return this.on("end.remove",ZBt(this._id))}function e7t(e){var t=this._name,n=this._id;typeof e!="function"&&(e=EQ(e));for(var r=this._groups,i=r.length,o=new Array(i),s=0;s<i;++s)for(var a=r[s],l=a.length,u=o[s]=new Array(l),c,d,h=0;h<l;++h)(c=a[h])&&(d=e.call(c,c.__data__,h,a))&&("__data__"in c&&(d.__data__=c.__data__),u[h]=d,$D(u[h],t,n,h,u,cc(c,n)));return new Vh(o,this._parents,t,n)}function t7t(e){var t=this._name,n=this._id;typeof e!="function"&&(e=dPe(e));for(var r=this._groups,i=r.length,o=[],s=[],a=0;a<i;++a)for(var l=r[a],u=l.length,c,d=0;d<u;++d)if(c=l[d]){for(var h=e.call(c,c.__data__,d,l),m,g=cc(c,n),b=0,v=h.length;b<v;++b)(m=h[b])&&$D(m,t,n,b,h,g);o.push(h),s.push(c)}return new Vh(o,s,t,n)}var n7t=AA.prototype.constructor;function r7t(){return new n7t(this._groups,this._parents)}function i7t(e,t){var n,r,i;return function(){var o=Ow(this,e),s=(this.style.removeProperty(e),Ow(this,e));return o===s?null:o===n&&s===r?i:i=t(n=o,r=s)}}function MPe(e){return function(){this.style.removeProperty(e)}}function o7t(e,t,n){var r,i=n+"",o;return function(){var s=Ow(this,e);return s===i?null:s===r?o:o=t(r=s,n)}}function s7t(e,t,n){var r,i,o;return function(){var s=Ow(this,e),a=n(this),l=a+"";return a==null&&(l=a=(this.style.removeProperty(e),Ow(this,e))),s===l?null:s===r&&l===i?o:(i=l,o=t(r=s,a))}}function a7t(e,t){var n,r,i,o="style."+t,s="end."+o,a;return function(){var l=Ud(this,e),u=l.on,c=l.value[o]==null?a||(a=MPe(t)):void 0;(u!==n||i!==c)&&(r=(n=u).copy()).on(s,i=c),l.on=r}}function l7t(e,t,n){var r=(e+="")=="transform"?vwt:RPe;return t==null?this.styleTween(e,i7t(e,r)).on("end.style."+e,MPe(e)):typeof t=="function"?this.styleTween(e,s7t(e,r,RQ(this,"style."+e,t))).each(a7t(this._id,e)):this.styleTween(e,o7t(e,r,t),n).on("end.style."+e,null)}function u7t(e,t,n){return function(r){this.style.setProperty(e,t.call(this,r),n)}}function c7t(e,t,n){var r,i;function o(){var s=t.apply(this,arguments);return s!==i&&(r=(i=s)&&u7t(e,s,n)),r}return o._value=t,o}function d7t(e,t,n){var r="style."+(e+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(t==null)return this.tween(r,null);if(typeof t!="function")throw new Error;return this.tween(r,c7t(e,t,n??""))}function f7t(e){return function(){this.textContent=e}}function h7t(e){return function(){var t=e(this);this.textContent=t??""}}function p7t(e){return this.tween("text",typeof e=="function"?h7t(RQ(this,"text",e)):f7t(e==null?"":e+""))}function m7t(e){return function(t){this.textContent=e.call(this,t)}}function g7t(e){var t,n;function r(){var i=e.apply(this,arguments);return i!==n&&(t=(n=i)&&m7t(i)),t}return r._value=e,r}function y7t(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(e==null)return this.tween(t,null);if(typeof e!="function")throw new Error;return this.tween(t,g7t(e))}function b7t(){for(var e=this._name,t=this._id,n=_Pe(),r=this._groups,i=r.length,o=0;o<i;++o)for(var s=r[o],a=s.length,l,u=0;u<a;++u)if(l=s[u]){var c=cc(l,t);$D(l,e,n,u,s,{time:c.time+c.delay+c.duration,delay:0,duration:c.duration,ease:c.ease})}return new Vh(r,this._parents,e,n)}function v7t(){var e,t,n=this,r=n._id,i=n.size();return new Promise(function(o,s){var a={value:s},l={value:function(){--i===0&&o()}};n.each(function(){var u=Ud(this,r),c=u.on;c!==e&&(t=(e=c).copy(),t._.cancel.push(a),t._.interrupt.push(a),t._.end.push(l)),u.on=t}),i===0&&o()})}var x7t=0;function Vh(e,t,n,r){this._groups=e,this._parents=t,this._name=n,this._id=r}function _Pe(){return++x7t}var vf=AA.prototype;Vh.prototype={constructor:Vh,select:e7t,selectAll:t7t,selectChild:vf.selectChild,selectChildren:vf.selectChildren,filter:GBt,merge:KBt,selection:r7t,transition:b7t,call:vf.call,nodes:vf.nodes,node:vf.node,size:vf.size,empty:vf.empty,each:vf.each,on:QBt,attr:_Bt,attrTween:jBt,style:l7t,styleTween:d7t,text:p7t,textTween:y7t,remove:JBt,tween:CBt,delay:zBt,duration:HBt,ease:VBt,easeVarying:qBt,end:v7t,[Symbol.iterator]:vf[Symbol.iterator]};function w7t(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var S7t={time:null,delay:0,duration:250,ease:w7t};function k7t(e,t){for(var n;!(n=e.__transition)||!(n=n[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return n}function C7t(e){var t,n;e instanceof Vh?(t=e._id,e=e._name):(t=_Pe(),(n=S7t).time=AQ(),e=e==null?null:e+"");for(var r=this._groups,i=r.length,o=0;o<i;++o)for(var s=r[o],a=s.length,l,u=0;u<a;++u)(l=s[u])&&$D(l,e,t,u,s,n||k7t(l,t));return new Vh(r,this._parents,e,t)}AA.prototype.interrupt=wBt;AA.prototype.transition=C7t;const wM=e=>()=>e;function E7t(e,{sourceEvent:t,target:n,transform:r,dispatch:i}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},transform:{value:r,enumerable:!0,configurable:!0},_:{value:i}})}function yh(e,t,n){this.k=e,this.x=t,this.y=n}yh.prototype={constructor:yh,scale:function(e){return e===1?this:new yh(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new yh(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var zD=new yh(1,0,0);NPe.prototype=yh.prototype;function NPe(e){for(;!e.__zoom;)if(!(e=e.parentNode))return zD;return e.__zoom}function n7(e){e.stopImmediatePropagation()}function Nk(e){e.preventDefault(),e.stopImmediatePropagation()}function T7t(e){return(!e.ctrlKey||e.type==="wheel")&&!e.button}function A7t(){var e=this;return e instanceof SVGElement?(e=e.ownerSVGElement||e,e.hasAttribute("viewBox")?(e=e.viewBox.baseVal,[[e.x,e.y],[e.x+e.width,e.y+e.height]]):[[0,0],[e.width.baseVal.value,e.height.baseVal.value]]):[[0,0],[e.clientWidth,e.clientHeight]]}function m0e(){return this.__zoom||zD}function O7t(e){return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*(e.ctrlKey?10:1)}function R7t(){return navigator.maxTouchPoints||"ontouchstart"in this}function M7t(e,t,n){var r=e.invertX(t[0][0])-n[0][0],i=e.invertX(t[1][0])-n[1][0],o=e.invertY(t[0][1])-n[0][1],s=e.invertY(t[1][1])-n[1][1];return e.translate(i>r?(r+i)/2:Math.min(0,r)||Math.max(0,i),s>o?(o+s)/2:Math.min(0,o)||Math.max(0,s))}function LPe(){var e=T7t,t=A7t,n=M7t,r=O7t,i=R7t,o=[0,1/0],s=[[-1/0,-1/0],[1/0,1/0]],a=250,l=k_,u=PD("start","zoom","end"),c,d,h,m=500,g=150,b=0,v=10;function w($){$.property("__zoom",m0e).on("wheel.zoom",N,{passive:!1}).on("mousedown.zoom",I).on("dblclick.zoom",D).filter(i).on("touchstart.zoom",P).on("touchmove.zoom",F).on("touchend.zoom touchcancel.zoom",z).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}w.transform=function($,B,H,U){var W=$.selection?$.selection():$;W.property("__zoom",m0e),$!==W?T($,B,H,U):W.interrupt().each(function(){O(this,arguments).event(U).start().zoom(null,typeof B=="function"?B.apply(this,arguments):B).end()})},w.scaleBy=function($,B,H,U){w.scaleTo($,function(){var W=this.__zoom.k,q=typeof B=="function"?B.apply(this,arguments):B;return W*q},H,U)},w.scaleTo=function($,B,H,U){w.transform($,function(){var W=t.apply(this,arguments),q=this.__zoom,Y=H==null?E(W):typeof H=="function"?H.apply(this,arguments):H,Q=q.invert(Y),G=typeof B=="function"?B.apply(this,arguments):B;return n(C(S(q,G),Y,Q),W,s)},H,U)},w.translateBy=function($,B,H,U){w.transform($,function(){return n(this.__zoom.translate(typeof B=="function"?B.apply(this,arguments):B,typeof H=="function"?H.apply(this,arguments):H),t.apply(this,arguments),s)},null,U)},w.translateTo=function($,B,H,U,W){w.transform($,function(){var q=t.apply(this,arguments),Y=this.__zoom,Q=U==null?E(q):typeof U=="function"?U.apply(this,arguments):U;return n(zD.translate(Q[0],Q[1]).scale(Y.k).translate(typeof B=="function"?-B.apply(this,arguments):-B,typeof H=="function"?-H.apply(this,arguments):-H),q,s)},U,W)};function S($,B){return B=Math.max(o[0],Math.min(o[1],B)),B===$.k?$:new yh(B,$.x,$.y)}function C($,B,H){var U=B[0]-H[0]*$.k,W=B[1]-H[1]*$.k;return U===$.x&&W===$.y?$:new yh($.k,U,W)}function E($){return[(+$[0][0]+ +$[1][0])/2,(+$[0][1]+ +$[1][1])/2]}function T($,B,H,U){$.on("start.zoom",function(){O(this,arguments).event(U).start()}).on("interrupt.zoom end.zoom",function(){O(this,arguments).event(U).end()}).tween("zoom",function(){var W=this,q=arguments,Y=O(W,q).event(U),Q=t.apply(W,q),G=H==null?E(Q):typeof H=="function"?H.apply(W,q):H,le=Math.max(Q[1][0]-Q[0][0],Q[1][1]-Q[0][1]),K=W.__zoom,te=typeof B=="function"?B.apply(W,q):B,de=l(K.invert(G).concat(le/K.k),te.invert(G).concat(le/te.k));return function(ue){if(ue===1)ue=te;else{var ae=de(ue),ie=le/ae[2];ue=new yh(ie,G[0]-ae[0]*ie,G[1]-ae[1]*ie)}Y.zoom(null,ue)}})}function O($,B,H){return!H&&$.__zooming||new M($,B)}function M($,B){this.that=$,this.args=B,this.active=0,this.sourceEvent=null,this.extent=t.apply($,B),this.taps=0}M.prototype={event:function($){return $&&(this.sourceEvent=$),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function($,B){return this.mouse&&$!=="mouse"&&(this.mouse[1]=B.invert(this.mouse[0])),this.touch0&&$!=="touch"&&(this.touch0[1]=B.invert(this.touch0[0])),this.touch1&&$!=="touch"&&(this.touch1[1]=B.invert(this.touch1[0])),this.that.__zoom=B,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function($){var B=al(this.that).datum();u.call($,this.that,new E7t($,{sourceEvent:this.sourceEvent,target:w,transform:this.that.__zoom,dispatch:u}),B)}};function N($,...B){if(!e.apply(this,arguments))return;var H=O(this,B).event($),U=this.__zoom,W=Math.max(o[0],Math.min(o[1],U.k*Math.pow(2,r.apply(this,arguments)))),q=Fu($);if(H.wheel)(H.mouse[0][0]!==q[0]||H.mouse[0][1]!==q[1])&&(H.mouse[1]=U.invert(H.mouse[0]=q)),clearTimeout(H.wheel);else{if(U.k===W)return;H.mouse=[q,U.invert(q)],F_(this),H.start()}Nk($),H.wheel=setTimeout(Y,g),H.zoom("mouse",n(C(S(U,W),H.mouse[0],H.mouse[1]),H.extent,s));function Y(){H.wheel=null,H.end()}}function I($,...B){if(h||!e.apply(this,arguments))return;var H=$.currentTarget,U=O(this,B,!0).event($),W=al($.view).on("mousemove.zoom",G,!0).on("mouseup.zoom",le,!0),q=Fu($,H),Y=$.clientX,Q=$.clientY;SPe($.view),n7($),U.mouse=[q,this.__zoom.invert(q)],F_(this),U.start();function G(K){if(Nk(K),!U.moved){var te=K.clientX-Y,de=K.clientY-Q;U.moved=te*te+de*de>b}U.event(K).zoom("mouse",n(C(U.that.__zoom,U.mouse[0]=Fu(K,H),U.mouse[1]),U.extent,s))}function le(K){W.on("mousemove.zoom mouseup.zoom",null),kPe(K.view,U.moved),Nk(K),U.event(K).end()}}function D($,...B){if(e.apply(this,arguments)){var H=this.__zoom,U=Fu($.changedTouches?$.changedTouches[0]:$,this),W=H.invert(U),q=H.k*($.shiftKey?.5:2),Y=n(C(S(H,q),U,W),t.apply(this,B),s);Nk($),a>0?al(this).transition().duration(a).call(T,Y,U,$):al(this).call(w.transform,Y,U,$)}}function P($,...B){if(e.apply(this,arguments)){var H=$.touches,U=H.length,W=O(this,B,$.changedTouches.length===U).event($),q,Y,Q,G;for(n7($),Y=0;Y<U;++Y)Q=H[Y],G=Fu(Q,this),G=[G,this.__zoom.invert(G),Q.identifier],W.touch0?!W.touch1&&W.touch0[2]!==G[2]&&(W.touch1=G,W.taps=0):(W.touch0=G,q=!0,W.taps=1+!!c);c&&(c=clearTimeout(c)),q&&(W.taps<2&&(d=G[0],c=setTimeout(function(){c=null},m)),F_(this),W.start())}}function F($,...B){if(this.__zooming){var H=O(this,B).event($),U=$.changedTouches,W=U.length,q,Y,Q,G;for(Nk($),q=0;q<W;++q)Y=U[q],Q=Fu(Y,this),H.touch0&&H.touch0[2]===Y.identifier?H.touch0[0]=Q:H.touch1&&H.touch1[2]===Y.identifier&&(H.touch1[0]=Q);if(Y=H.that.__zoom,H.touch1){var le=H.touch0[0],K=H.touch0[1],te=H.touch1[0],de=H.touch1[1],ue=(ue=te[0]-le[0])*ue+(ue=te[1]-le[1])*ue,ae=(ae=de[0]-K[0])*ae+(ae=de[1]-K[1])*ae;Y=S(Y,Math.sqrt(ue/ae)),Q=[(le[0]+te[0])/2,(le[1]+te[1])/2],G=[(K[0]+de[0])/2,(K[1]+de[1])/2]}else if(H.touch0)Q=H.touch0[0],G=H.touch0[1];else return;H.zoom("touch",n(C(Y,Q,G),H.extent,s))}}function z($,...B){if(this.__zooming){var H=O(this,B).event($),U=$.changedTouches,W=U.length,q,Y;for(n7($),h&&clearTimeout(h),h=setTimeout(function(){h=null},m),q=0;q<W;++q)Y=U[q],H.touch0&&H.touch0[2]===Y.identifier?delete H.touch0:H.touch1&&H.touch1[2]===Y.identifier&&delete H.touch1;if(H.touch1&&!H.touch0&&(H.touch0=H.touch1,delete H.touch1),H.touch0)H.touch0[1]=this.__zoom.invert(H.touch0[0]);else if(H.end(),H.taps===2&&(Y=Fu(Y,this),Math.hypot(d[0]-Y[0],d[1]-Y[1])<v)){var Q=al(this).on("dblclick.zoom");Q&&Q.apply(this,arguments)}}}return w.wheelDelta=function($){return arguments.length?(r=typeof $=="function"?$:wM(+$),w):r},w.filter=function($){return arguments.length?(e=typeof $=="function"?$:wM(!!$),w):e},w.touchable=function($){return arguments.length?(i=typeof $=="function"?$:wM(!!$),w):i},w.extent=function($){return arguments.length?(t=typeof $=="function"?$:wM([[+$[0][0],+$[0][1]],[+$[1][0],+$[1][1]]]),w):t},w.scaleExtent=function($){return arguments.length?(o[0]=+$[0],o[1]=+$[1],w):[o[0],o[1]]},w.translateExtent=function($){return arguments.length?(s[0][0]=+$[0][0],s[1][0]=+$[1][0],s[0][1]=+$[0][1],s[1][1]=+$[1][1],w):[[s[0][0],s[0][1]],[s[1][0],s[1][1]]]},w.constrain=function($){return arguments.length?(n=$,w):n},w.duration=function($){return arguments.length?(a=+$,w):a},w.interpolate=function($){return arguments.length?(l=$,w):l},w.on=function(){var $=u.on.apply(u,arguments);return $===u?w:$},w.clickDistance=function($){return arguments.length?(b=($=+$)*$,w):Math.sqrt(b)},w.tapDistance=function($){return arguments.length?(v=+$,w):v},w}const oc={error001:(e="react")=>`Seems like you have not used ${e==="svelte"?"SvelteFlowProvider":"ReactFlowProvider"} as an ancestor. Help: https://${e}flow.dev/error#001`,error002:()=>"It looks like you've created a new nodeTypes or edgeTypes object. If this wasn't on purpose please define the nodeTypes/edgeTypes outside of the component or memoize them.",error003:e=>`Node type "${e}" not found. Using fallback type "default".`,error004:()=>"The parent container needs a width and a height to render the graph.",error005:()=>"Only child nodes can use a parent extent.",error006:()=>"Can't create edge. An edge needs a source and a target.",error007:e=>`The old edge with id=${e} does not exist.`,error009:e=>`Marker type "${e}" doesn't exist.`,error008:(e,{id:t,sourceHandle:n,targetHandle:r})=>`Couldn't create edge for ${e} handle id: "${e==="source"?n:r}", edge id: ${t}.`,error010:()=>"Handle: No node id found. Make sure to only use a Handle inside a custom Node.",error011:e=>`Edge type "${e}" not found. Using fallback type "default".`,error012:e=>`Node with id "${e}" does not exist, it may have been removed. This can happen when a node is deleted before the "onNodeClick" handler is called.`,error013:(e="react")=>`It seems that you haven't loaded the styles. Please import '@xyflow/${e}/dist/style.css' or base.css to make sure everything is working properly.`,error014:()=>"useNodeConnections: No node ID found. Call useNodeConnections inside a custom Node or provide a node ID.",error015:()=>"It seems that you are trying to drag a node that is not initialized. Please use onNodesChange as explained in the docs.",error016:e=>`Edge with id "${e}" does not exist, it may have been removed. This can happen when an edge is deleted before the "onEdgeClick" handler is called.`},$T=[[Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY],[Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY]],IPe=["Enter"," ","Escape"],PPe={"node.a11yDescription.default":"Press enter or space to select a node. Press delete to remove it and escape to cancel.","node.a11yDescription.keyboardDisabled":"Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.","node.a11yDescription.ariaLiveMessage":({direction:e,x:t,y:n})=>`Moved selected node ${e}. New position, x: ${t}, y: ${n}`,"edge.a11yDescription.default":"Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.","controls.ariaLabel":"Control Panel","controls.zoomIn.ariaLabel":"Zoom In","controls.zoomOut.ariaLabel":"Zoom Out","controls.fitView.ariaLabel":"Fit View","controls.interactive.ariaLabel":"Toggle Interactivity","minimap.ariaLabel":"Mini Map","handle.ariaLabel":"Handle"};var Mw;(function(e){e.Strict="strict",e.Loose="loose"})(Mw||(Mw={}));var rb;(function(e){e.Free="free",e.Vertical="vertical",e.Horizontal="horizontal"})(rb||(rb={}));var zT;(function(e){e.Partial="partial",e.Full="full"})(zT||(zT={}));const jPe={inProgress:!1,isValid:null,from:null,fromHandle:null,fromPosition:null,fromNode:null,to:null,toHandle:null,toPosition:null,toNode:null,pointer:null};var nh;(function(e){e.Bezier="default",e.Straight="straight",e.Step="step",e.SmoothStep="smoothstep",e.SimpleBezier="simplebezier"})(nh||(nh={}));var FT;(function(e){e.Arrow="arrow",e.ArrowClosed="arrowclosed"})(FT||(FT={}));var Bt;(function(e){e.Left="left",e.Top="top",e.Right="right",e.Bottom="bottom"})(Bt||(Bt={}));const g0e={[Bt.Left]:Bt.Right,[Bt.Right]:Bt.Left,[Bt.Top]:Bt.Bottom,[Bt.Bottom]:Bt.Top},DPe=e=>!!e&&typeof e=="object"&&"id"in e&&"source"in e&&"target"in e,_7t=e=>!!e&&typeof e=="object"&&"id"in e&&"position"in e&&!("source"in e)&&!("target"in e),MQ=e=>!!e&&typeof e=="object"&&"id"in e&&"internals"in e&&!("source"in e)&&!("target"in e),OA=(e,t=[0,0])=>{const{width:n,height:r}=dc(e),i=e.origin??t,o=n*i[0],s=r*i[1];return{x:e.position.x-o,y:e.position.y-s}},N7t=(e,t={nodeOrigin:[0,0]})=>{if(e.length===0)return{x:0,y:0,width:0,height:0};let n=!1;const r=e.reduce((i,o)=>{const s=typeof o=="string";let a=!t.nodeLookup&&!s?o:void 0;return t.nodeLookup&&(a=s?t.nodeLookup.get(o):MQ(o)?o:t.nodeLookup.get(o.id)),a?(n=!0,FD(i,ZI(a,t.nodeOrigin))):i},{x:1/0,y:1/0,x2:-1/0,y2:-1/0});return n?BD(r):{x:0,y:0,width:0,height:0}},yS=(e,t={})=>{let n={x:1/0,y:1/0,x2:-1/0,y2:-1/0},r=!1;return e.forEach(i=>{(t.filter===void 0||t.filter(i))&&(n=FD(n,ZI(i)),r=!0)}),r?BD(n):{x:0,y:0,width:0,height:0}},_Q=(e,t,[n,r,i]=[0,0,1],o=!1,s=!1)=>{const a=(t.x-n)/i,l=(t.y-r)/i,u=t.width/i,c=t.height/i,d=[];for(const h of e.values()){const{measured:m,selectable:g=!0,hidden:b=!1}=h;if(s&&!g||b)continue;const v=m.width??h.width??h.initialWidth??0,w=m.height??h.height??h.initialHeight??0,{x:S,y:C}=h.internals.positionAbsolute,E=BPe(a,l,u,c,S,C,v,w),T=v*w,O=o&&E>0;(!h.internals.handleBounds||O||E>=T||h.dragging)&&d.push(h)}return d},L7t=(e,t)=>{const n=new Set;return e.forEach(r=>{n.add(r.id)}),t.filter(r=>n.has(r.source)||n.has(r.target))};function I7t(e,t){const n=new Map,r=t!=null&&t.nodes?new Set(t.nodes.map(i=>i.id)):null;return e.forEach(i=>{let o;if(t!=null&&t.includeHiddenNodes){const{width:s,height:a}=dc(i);o=s>0&&a>0}else o=!!(i.measured.width&&i.measured.height&&!i.hidden);o&&(!r||r.has(i.id))&&n.set(i.id,i)}),n}async function P7t({nodes:e,width:t,height:n,panZoom:r,minZoom:i,maxZoom:o},s){if(e.size===0)return!0;const a=I7t(e,s),l=yS(a),u=LQ(l,t,n,(s==null?void 0:s.minZoom)??i,(s==null?void 0:s.maxZoom)??o,(s==null?void 0:s.padding)??.1);return await r.setViewport(u,{duration:s==null?void 0:s.duration,ease:s==null?void 0:s.ease,interpolate:s==null?void 0:s.interpolate}),!0}function $Pe({nodeId:e,nextPosition:t,nodeLookup:n,nodeOrigin:r=[0,0],nodeExtent:i,onError:o}){const s=n.get(e),a=s.parentId?n.get(s.parentId):void 0,{x:l,y:u}=a?a.internals.positionAbsolute:{x:0,y:0},c=s.origin??r;let d=s.extent||i;if(s.extent==="parent"&&!s.expandParent)if(!a)o==null||o("005",oc.error005());else{const{width:m,height:g}=dc(a);m&&g&&(d=[[l,u],[l+m,u+g]])}else a&&Tb(s.extent)&&(d=[[s.extent[0][0]+l,s.extent[0][1]+u],[s.extent[1][0]+l,s.extent[1][1]+u]]);const h=Tb(d)?Eb(t,d,s.measured):t;return(s.measured.width===void 0||s.measured.height===void 0)&&(o==null||o("015",oc.error015())),{position:{x:h.x-l+(s.measured.width??0)*c[0],y:h.y-u+(s.measured.height??0)*c[1]},positionAbsolute:h}}async function j7t({nodesToRemove:e=[],edgesToRemove:t=[],nodes:n,edges:r,onBeforeDelete:i}){const o=new Set(e.map(h=>h.id)),s=[];for(const h of n){if(h.deletable===!1)continue;const m=o.has(h.id),g=!m&&h.parentId&&s.find(b=>b.id===h.parentId);(m||g)&&s.push(h)}const a=new Set(t.map(h=>h.id)),l=r.filter(h=>h.deletable!==!1),c=L7t(s,l);for(const h of l)a.has(h.id)&&!c.find(g=>g.id===h.id)&&c.push(h);if(!i)return{edges:c,nodes:s};const d=await i({nodes:s,edges:c});return typeof d=="boolean"?d?{edges:c,nodes:s}:{edges:[],nodes:[]}:d}const _w=(e,t=0,n=1)=>Math.min(Math.max(e,t),n),Eb=(e={x:0,y:0},t,n)=>({x:_w(e.x,t[0][0],t[1][0]-((n==null?void 0:n.width)??0)),y:_w(e.y,t[0][1],t[1][1]-((n==null?void 0:n.height)??0))});function zPe(e,t,n){const{width:r,height:i}=dc(n),{x:o,y:s}=n.internals.positionAbsolute;return Eb(e,[[o,s],[o+r,s+i]],t)}const y0e=(e,t,n)=>e<t?_w(Math.abs(e-t),1,t)/t:e>n?-_w(Math.abs(e-n),1,t)/t:0,NQ=(e,t,n=15,r=40)=>{const i=y0e(e.x,r,t.width-r)*n,o=y0e(e.y,r,t.height-r)*n;return[i,o]},FD=(e,t)=>({x:Math.min(e.x,t.x),y:Math.min(e.y,t.y),x2:Math.max(e.x2,t.x2),y2:Math.max(e.y2,t.y2)}),QW=({x:e,y:t,width:n,height:r})=>({x:e,y:t,x2:e+n,y2:t+r}),BD=({x:e,y:t,x2:n,y2:r})=>({x:e,y:t,width:n-e,height:r-t}),BT=(e,t=[0,0])=>{var i,o;const{x:n,y:r}=MQ(e)?e.internals.positionAbsolute:OA(e,t);return{x:n,y:r,width:((i=e.measured)==null?void 0:i.width)??e.width??e.initialWidth??0,height:((o=e.measured)==null?void 0:o.height)??e.height??e.initialHeight??0}},ZI=(e,t=[0,0])=>{var i,o;const{x:n,y:r}=MQ(e)?e.internals.positionAbsolute:OA(e,t);return{x:n,y:r,x2:n+(((i=e.measured)==null?void 0:i.width)??e.width??e.initialWidth??0),y2:r+(((o=e.measured)==null?void 0:o.height)??e.height??e.initialHeight??0)}},FPe=(e,t)=>BD(FD(QW(e),QW(t))),BPe=(e,t,n,r,i,o,s,a)=>{const l=Math.max(0,Math.min(e+n,i+s)-Math.max(e,i)),u=Math.max(0,Math.min(t+r,o+a)-Math.max(t,o));return Math.ceil(l*u)},JI=(e,t)=>BPe(e.x,e.y,e.width,e.height,t.x,t.y,t.width,t.height),b0e=e=>Qu(e.width)&&Qu(e.height)&&Qu(e.x)&&Qu(e.y),Qu=e=>!isNaN(e)&&isFinite(e),HPe=(e,t)=>(n,r)=>{},RA=(e,t=[1,1])=>({x:t[0]*Math.round(e.x/t[0]),y:t[1]*Math.round(e.y/t[1])}),MA=({x:e,y:t},[n,r,i],o=!1,s=[1,1])=>{const a={x:(e-n)/i,y:(t-r)/i};return o?RA(a,s):a},Nw=({x:e,y:t},[n,r,i])=>({x:e*i+n,y:t*i+r});function Uv(e,t){if(typeof e=="number")return Math.floor((t-t/(1+e))*.5);if(typeof e=="string"&&e.endsWith("px")){const n=parseFloat(e);if(!Number.isNaN(n))return Math.floor(n)}if(typeof e=="string"&&e.endsWith("%")){const n=parseFloat(e);if(!Number.isNaN(n))return Math.floor(t*n*.01)}return console.error(`The padding value "${e}" is invalid. Please provide a number or a string with a valid unit (px or %).`),0}function D7t(e,t,n){if(typeof e=="string"||typeof e=="number"){const r=Uv(e,n),i=Uv(e,t);return{top:r,right:i,bottom:r,left:i,x:i*2,y:r*2}}if(typeof e=="object"){const r=Uv(e.top??e.y??0,n),i=Uv(e.bottom??e.y??0,n),o=Uv(e.left??e.x??0,t),s=Uv(e.right??e.x??0,t);return{top:r,right:s,bottom:i,left:o,x:o+s,y:r+i}}return{top:0,right:0,bottom:0,left:0,x:0,y:0}}function $7t(e,t,n,r,i,o){const{x:s,y:a}=Nw(e,[t,n,r]),{x:l,y:u}=Nw({x:e.x+e.width,y:e.y+e.height},[t,n,r]),c=i-l,d=o-u;return{left:Math.floor(s),top:Math.floor(a),right:Math.floor(c),bottom:Math.floor(d)}}const LQ=(e,t,n,r,i,o)=>{const s=D7t(o,t,n),a=(t-s.x)/e.width,l=(n-s.y)/e.height,u=Math.min(a,l),c=_w(u,r,i),d=e.x+e.width/2,h=e.y+e.height/2,m=t/2-d*c,g=n/2-h*c,b=$7t(e,m,g,c,t,n),v={left:Math.min(b.left-s.left,0),top:Math.min(b.top-s.top,0),right:Math.min(b.right-s.right,0),bottom:Math.min(b.bottom-s.bottom,0)};return{x:m-v.left+v.right,y:g-v.top+v.bottom,zoom:c}},HT=()=>{var e;return typeof navigator<"u"&&((e=navigator==null?void 0:navigator.userAgent)==null?void 0:e.indexOf("Mac"))>=0};function Tb(e){return e!=null&&e!=="parent"}function dc(e){var t,n;return{width:((t=e.measured)==null?void 0:t.width)??e.width??e.initialWidth??0,height:((n=e.measured)==null?void 0:n.height)??e.height??e.initialHeight??0}}function UPe(e){var t,n;return(((t=e.measured)==null?void 0:t.width)??e.width??e.initialWidth)!==void 0&&(((n=e.measured)==null?void 0:n.height)??e.height??e.initialHeight)!==void 0}function VPe(e,t={width:0,height:0},n,r,i){const o={...e},s=r.get(n);if(s){const a=s.origin||i;o.x+=s.internals.positionAbsolute.x-(t.width??0)*a[0],o.y+=s.internals.positionAbsolute.y-(t.height??0)*a[1]}return o}function v0e(e,t){if(e.size!==t.size)return!1;for(const n of e)if(!t.has(n))return!1;return!0}function z7t(){let e,t;return{promise:new Promise((r,i)=>{e=r,t=i}),resolve:e,reject:t}}function F7t(e){return{...PPe,...e||{}}}function WPe(e){return e===null?null:e?"valid":"invalid"}function iE(e,{snapGrid:t=[0,0],snapToGrid:n=!1,transform:r,containerBounds:i}){const{x:o,y:s}=Zu(e),a=MA({x:o-((i==null?void 0:i.left)??0),y:s-((i==null?void 0:i.top)??0)},r),{x:l,y:u}=n?RA(a,t):a;return{xSnapped:l,ySnapped:u,...a}}const IQ=e=>({width:e.offsetWidth,height:e.offsetHeight}),qPe=e=>{var t;return((t=e==null?void 0:e.getRootNode)==null?void 0:t.call(e))||(window==null?void 0:window.document)},B7t=["INPUT","SELECT","TEXTAREA"];function GPe(e){var r,i;const t=((i=(r=e.composedPath)==null?void 0:r.call(e))==null?void 0:i[0])||e.target;return(t==null?void 0:t.nodeType)!==1?!1:B7t.includes(t.nodeName)||t.hasAttribute("contenteditable")||!!t.closest(".nokey")}const KPe=e=>"clientX"in e,Zu=(e,t)=>{var o,s;const n=KPe(e),r=n?e.clientX:(o=e.touches)==null?void 0:o[0].clientX,i=n?e.clientY:(s=e.touches)==null?void 0:s[0].clientY;return{x:r-((t==null?void 0:t.left)??0),y:i-((t==null?void 0:t.top)??0)}},x0e=(e,t,n,r,i)=>{const o=t.querySelectorAll(`.${e}`);return!o||!o.length?null:Array.from(o).map(s=>{const a=s.getBoundingClientRect();return{id:s.getAttribute("data-handleid"),type:e,nodeId:i,position:s.getAttribute("data-handlepos"),x:(a.left-n.left)/r,y:(a.top-n.top)/r,...IQ(s)}})};function YPe({sourceX:e,sourceY:t,targetX:n,targetY:r,sourceControlX:i,sourceControlY:o,targetControlX:s,targetControlY:a}){const l=e*.125+i*.375+s*.375+n*.125,u=t*.125+o*.375+a*.375+r*.125,c=Math.abs(l-e),d=Math.abs(u-t);return[l,u,c,d]}function SM(e,t){return e>=0?.5*e:t*25*Math.sqrt(-e)}function w0e({pos:e,x1:t,y1:n,x2:r,y2:i,c:o}){switch(e){case Bt.Left:return[t-SM(t-r,o),n];case Bt.Right:return[t+SM(r-t,o),n];case Bt.Top:return[t,n-SM(n-i,o)];case Bt.Bottom:return[t,n+SM(i-n,o)]}}function XPe({sourceX:e,sourceY:t,sourcePosition:n=Bt.Bottom,targetX:r,targetY:i,targetPosition:o=Bt.Top,curvature:s=.25}){const[a,l]=w0e({pos:n,x1:e,y1:t,x2:r,y2:i,c:s}),[u,c]=w0e({pos:o,x1:r,y1:i,x2:e,y2:t,c:s}),[d,h,m,g]=YPe({sourceX:e,sourceY:t,targetX:r,targetY:i,sourceControlX:a,sourceControlY:l,targetControlX:u,targetControlY:c});return[`M${e},${t} C${a},${l} ${u},${c} ${r},${i}`,d,h,m,g]}function QPe({sourceX:e,sourceY:t,targetX:n,targetY:r}){const i=Math.abs(n-e)/2,o=n<e?n+i:n-i,s=Math.abs(r-t)/2,a=r<t?r+s:r-s;return[o,a,i,s]}function H7t({sourceNode:e,targetNode:t,selected:n=!1,zIndex:r=0,elevateOnSelect:i=!1,zIndexMode:o="basic"}){if(o==="manual")return r;const s=i&&n?r+1e3:r,a=Math.max(e.parentId||i&&e.selected?e.internals.z:0,t.parentId||i&&t.selected?t.internals.z:0);return s+a}function U7t({sourceNode:e,targetNode:t,width:n,height:r,transform:i}){const o=FD(ZI(e),ZI(t));o.x===o.x2&&(o.x2+=1),o.y===o.y2&&(o.y2+=1);const s={x:-i[0]/i[2],y:-i[1]/i[2],width:n/i[2],height:r/i[2]};return JI(s,BD(o))>0}const V7t=({source:e,sourceHandle:t,target:n,targetHandle:r})=>`xy-edge__${e}${t||""}-${n}${r||""}`,W7t=(e,t)=>t.some(n=>n.source===e.source&&n.target===e.target&&(n.sourceHandle===e.sourceHandle||!n.sourceHandle&&!e.sourceHandle)&&(n.targetHandle===e.targetHandle||!n.targetHandle&&!e.targetHandle)),q7t=(e,t,n={})=>{var o;if(!e.source||!e.target)return(o=n.onError)==null||o.call(n,"006",oc.error006()),t;const r=n.getEdgeId||V7t;let i;return DPe(e)?i={...e}:i={...e,id:r(e)},W7t(i,t)?t:(i.sourceHandle===null&&delete i.sourceHandle,i.targetHandle===null&&delete i.targetHandle,t.concat(i))};function ZPe({sourceX:e,sourceY:t,targetX:n,targetY:r}){const[i,o,s,a]=QPe({sourceX:e,sourceY:t,targetX:n,targetY:r});return[`M ${e},${t}L ${n},${r}`,i,o,s,a]}const S0e={[Bt.Left]:{x:-1,y:0},[Bt.Right]:{x:1,y:0},[Bt.Top]:{x:0,y:-1},[Bt.Bottom]:{x:0,y:1}},G7t=({source:e,sourcePosition:t=Bt.Bottom,target:n})=>t===Bt.Left||t===Bt.Right?e.x<n.x?{x:1,y:0}:{x:-1,y:0}:e.y<n.y?{x:0,y:1}:{x:0,y:-1},k0e=(e,t)=>Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2));function K7t({source:e,sourcePosition:t=Bt.Bottom,target:n,targetPosition:r=Bt.Top,center:i,offset:o,stepPosition:s}){const a=S0e[t],l=S0e[r],u={x:e.x+a.x*o,y:e.y+a.y*o},c={x:n.x+l.x*o,y:n.y+l.y*o},d=G7t({source:u,sourcePosition:t,target:c}),h=d.x!==0?"x":"y",m=d[h];let g=[],b,v;const w={x:0,y:0},S={x:0,y:0},[,,C,E]=QPe({sourceX:e.x,sourceY:e.y,targetX:n.x,targetY:n.y});if(a[h]*l[h]===-1){h==="x"?(b=i.x??u.x+(c.x-u.x)*s,v=i.y??(u.y+c.y)/2):(b=i.x??(u.x+c.x)/2,v=i.y??u.y+(c.y-u.y)*s);const N=[{x:b,y:u.y},{x:b,y:c.y}],I=[{x:u.x,y:v},{x:c.x,y:v}];a[h]===m?g=h==="x"?N:I:g=h==="x"?I:N}else{const N=[{x:u.x,y:c.y}],I=[{x:c.x,y:u.y}];if(h==="x"?g=a.x===m?I:N:g=a.y===m?N:I,t===r){const $=Math.abs(e[h]-n[h]);if($<=o){const B=Math.min(o-1,o-$);a[h]===m?w[h]=(u[h]>e[h]?-1:1)*B:S[h]=(c[h]>n[h]?-1:1)*B}}if(t!==r){const $=h==="x"?"y":"x",B=a[h]===l[$],H=u[$]>c[$],U=u[$]<c[$];(a[h]===1&&(!B&&H||B&&U)||a[h]!==1&&(!B&&U||B&&H))&&(g=h==="x"?N:I)}const D={x:u.x+w.x,y:u.y+w.y},P={x:c.x+S.x,y:c.y+S.y},F=Math.max(Math.abs(D.x-g[0].x),Math.abs(P.x-g[0].x)),z=Math.max(Math.abs(D.y-g[0].y),Math.abs(P.y-g[0].y));F>=z?(b=(D.x+P.x)/2,v=g[0].y):(b=g[0].x,v=(D.y+P.y)/2)}const T={x:u.x+w.x,y:u.y+w.y},O={x:c.x+S.x,y:c.y+S.y};return[[e,...T.x!==g[0].x||T.y!==g[0].y?[T]:[],...g,...O.x!==g[g.length-1].x||O.y!==g[g.length-1].y?[O]:[],n],b,v,C,E]}function Y7t(e,t,n,r){const i=Math.min(k0e(e,t)/2,k0e(t,n)/2,r),{x:o,y:s}=t;if(e.x===o&&o===n.x||e.y===s&&s===n.y)return`L${o} ${s}`;if(e.y===s){const u=e.x<n.x?-1:1,c=e.y<n.y?1:-1;return`L ${o+i*u},${s}Q ${o},${s} ${o},${s+i*c}`}const a=e.x<n.x?1:-1,l=e.y<n.y?-1:1;return`L ${o},${s+i*l}Q ${o},${s} ${o+i*a},${s}`}function UT({sourceX:e,sourceY:t,sourcePosition:n=Bt.Bottom,targetX:r,targetY:i,targetPosition:o=Bt.Top,borderRadius:s=5,centerX:a,centerY:l,offset:u=20,stepPosition:c=.5}){const[d,h,m,g,b]=K7t({source:{x:e,y:t},sourcePosition:n,target:{x:r,y:i},targetPosition:o,center:{x:a,y:l},offset:u,stepPosition:c});let v=`M${d[0].x} ${d[0].y}`;for(let w=1;w<d.length-1;w++)v+=Y7t(d[w-1],d[w],d[w+1],s);return v+=`L${d[d.length-1].x} ${d[d.length-1].y}`,[v,h,m,g,b]}function C0e(e){var t;return e&&!!(e.internals.handleBounds||(t=e.handles)!=null&&t.length)&&!!(e.measured.width||e.width||e.initialWidth)}function X7t(e){var d;const{sourceNode:t,targetNode:n}=e;if(!C0e(t)||!C0e(n))return null;const r=t.internals.handleBounds||E0e(t.handles),i=n.internals.handleBounds||E0e(n.handles),o=T0e((r==null?void 0:r.source)??[],e.sourceHandle),s=T0e(e.connectionMode===Mw.Strict?(i==null?void 0:i.target)??[]:((i==null?void 0:i.target)??[]).concat((i==null?void 0:i.source)??[]),e.targetHandle);if(!o||!s)return(d=e.onError)==null||d.call(e,"008",oc.error008(o?"target":"source",{id:e.id,sourceHandle:e.sourceHandle,targetHandle:e.targetHandle})),null;const a=(o==null?void 0:o.position)||Bt.Bottom,l=(s==null?void 0:s.position)||Bt.Top,u=Ab(t,o,a),c=Ab(n,s,l);return{sourceX:u.x,sourceY:u.y,targetX:c.x,targetY:c.y,sourcePosition:a,targetPosition:l}}function E0e(e){if(!e)return null;const t=[],n=[];for(const r of e)r.width=r.width??1,r.height=r.height??1,r.type==="source"?t.push(r):r.type==="target"&&n.push(r);return{source:t,target:n}}function Ab(e,t,n=Bt.Left,r=!1){const i=((t==null?void 0:t.x)??0)+e.internals.positionAbsolute.x,o=((t==null?void 0:t.y)??0)+e.internals.positionAbsolute.y,{width:s,height:a}=t??dc(e);if(r)return{x:i+s/2,y:o+a/2};switch((t==null?void 0:t.position)??n){case Bt.Top:return{x:i+s/2,y:o};case Bt.Right:return{x:i+s,y:o+a/2};case Bt.Bottom:return{x:i+s/2,y:o+a};case Bt.Left:return{x:i,y:o+a/2}}}function T0e(e,t){return e&&(t?e.find(n=>n.id===t):e[0])||null}function ZW(e,t){return e?typeof e=="string"?e:`${t?`${t}__`:""}${Object.keys(e).sort().map(r=>`${r}=${e[r]}`).join("&")}`:""}function Q7t(e,{id:t,defaultColor:n,defaultMarkerStart:r,defaultMarkerEnd:i}){const o=new Set;return e.reduce((s,a)=>([a.markerStart||r,a.markerEnd||i].forEach(l=>{if(l&&typeof l=="object"){const u=ZW(l,t);o.has(u)||(s.push({id:u,color:l.color||n,...l}),o.add(u))}}),s),[]).sort((s,a)=>s.id.localeCompare(a.id))}function Z7t(e,t,n,r,i){let o=.5;i==="start"?o=0:i==="end"&&(o=1);let s=[(e.x+e.width*o)*t.zoom+t.x,e.y*t.zoom+t.y-r],a=[-100*o,-100];switch(n){case Bt.Right:s=[(e.x+e.width)*t.zoom+t.x+r,(e.y+e.height*o)*t.zoom+t.y],a=[0,-100*o];break;case Bt.Bottom:s[1]=(e.y+e.height)*t.zoom+t.y+r,a[1]=0;break;case Bt.Left:s=[e.x*t.zoom+t.x-r,(e.y+e.height*o)*t.zoom+t.y],a=[-100,-100*o];break}return`translate(${s[0]}px, ${s[1]}px) translate(${a[0]}%, ${a[1]}%)`}const JPe=1e3,J7t=10,PQ={nodeOrigin:[0,0],nodeExtent:$T,elevateNodesOnSelect:!0,zIndexMode:"basic",defaults:{}},e9t={...PQ,checkEquality:!0};function jQ(e,t){const n={...e};for(const r in t)t[r]!==void 0&&(n[r]=t[r]);return n}function t9t(e,t,n){const r=jQ(PQ,n);for(const i of e.values())if(i.parentId)$Q(i,e,t,r);else{const o=OA(i,r.nodeOrigin),s=Tb(i.extent)?i.extent:r.nodeExtent,a=Eb(o,s,dc(i));i.internals.positionAbsolute=a}}function n9t(e,t){if(!e.handles)return e.measured?t==null?void 0:t.internals.handleBounds:void 0;const n=[],r=[];for(const i of e.handles){const o={id:i.id,width:i.width??1,height:i.height??1,nodeId:e.id,x:i.x,y:i.y,position:i.position,type:i.type};i.type==="source"?n.push(o):i.type==="target"&&r.push(o)}return{source:n,target:r}}function DQ(e){return e==="manual"}function JW(e,t,n,r={}){var c,d;const i=jQ(e9t,r),o={i:0},s=new Map(t),a=i!=null&&i.elevateNodesOnSelect&&!DQ(i.zIndexMode)?JPe:0;let l=e.length>0,u=!1;t.clear(),n.clear();for(const h of e){let m=s.get(h.id);if(i.checkEquality&&h===(m==null?void 0:m.internals.userNode))t.set(h.id,m);else{const g=OA(h,i.nodeOrigin),b=Tb(h.extent)?h.extent:i.nodeExtent,v=Eb(g,b,dc(h));m={...i.defaults,...h,measured:{width:(c=h.measured)==null?void 0:c.width,height:(d=h.measured)==null?void 0:d.height},internals:{positionAbsolute:v,handleBounds:n9t(h,m),z:eje(h,a,i.zIndexMode),userNode:h}},t.set(h.id,m)}(m.measured===void 0||m.measured.width===void 0||m.measured.height===void 0)&&!m.hidden&&(l=!1),h.parentId&&$Q(m,t,n,r,o),u||(u=h.selected??!1)}return{nodesInitialized:l,hasSelectedNodes:u}}function r9t(e,t){if(!e.parentId)return;const n=t.get(e.parentId);n?n.set(e.id,e):t.set(e.parentId,new Map([[e.id,e]]))}function $Q(e,t,n,r,i){const{elevateNodesOnSelect:o,nodeOrigin:s,nodeExtent:a,zIndexMode:l}=jQ(PQ,r),u=e.parentId,c=t.get(u);if(!c){console.warn(`Parent node ${u} not found. Please make sure that parent nodes are in front of their child nodes in the nodes array.`);return}r9t(e,n),i&&!c.parentId&&c.internals.rootParentIndex===void 0&&l==="auto"&&(c.internals.rootParentIndex=++i.i,c.internals.z=c.internals.z+i.i*J7t),i&&c.internals.rootParentIndex!==void 0&&(i.i=c.internals.rootParentIndex);const d=o&&!DQ(l)?JPe:0,{x:h,y:m,z:g}=i9t(e,c,s,a,d,l),{positionAbsolute:b}=e.internals,v=h!==b.x||m!==b.y;(v||g!==e.internals.z)&&t.set(e.id,{...e,internals:{...e.internals,positionAbsolute:v?{x:h,y:m}:b,z:g}})}function eje(e,t,n){const r=Qu(e.zIndex)?e.zIndex:0;return DQ(n)?r:r+(e.selected?t:0)}function i9t(e,t,n,r,i,o){const{x:s,y:a}=t.internals.positionAbsolute,l=dc(e),u=OA(e,n),c=Tb(e.extent)?Eb(u,e.extent,l):u;let d=Eb({x:s+c.x,y:a+c.y},r,l);e.extent==="parent"&&(d=zPe(d,l,t));const h=eje(e,i,o),m=t.internals.z??0;return{x:d.x,y:d.y,z:m>=h?m+1:h}}function zQ(e,t,n,r=[0,0]){var s;const i=[],o=new Map;for(const a of e){const l=t.get(a.parentId);if(!l)continue;const u=((s=o.get(a.parentId))==null?void 0:s.expandedRect)??BT(l),c=FPe(u,a.rect);o.set(a.parentId,{expandedRect:c,parent:l})}return o.size>0&&o.forEach(({expandedRect:a,parent:l},u)=>{var C;const c=l.internals.positionAbsolute,d=dc(l),h=l.origin??r,m=a.x<c.x?Math.round(Math.abs(c.x-a.x)):0,g=a.y<c.y?Math.round(Math.abs(c.y-a.y)):0,b=Math.max(d.width,Math.round(a.width)),v=Math.max(d.height,Math.round(a.height)),w=(b-d.width)*h[0],S=(v-d.height)*h[1];(m>0||g>0||w||S)&&(i.push({id:u,type:"position",position:{x:l.position.x-m+w,y:l.position.y-g+S}}),(C=n.get(u))==null||C.forEach(E=>{e.some(T=>T.id===E.id)||i.push({id:E.id,type:"position",position:{x:E.position.x+m,y:E.position.y+g}})})),(d.width<a.width||d.height<a.height||m||g)&&i.push({id:u,type:"dimensions",setAttributes:!0,dimensions:{width:b+(m?h[0]*m-w:0),height:v+(g?h[1]*g-S:0)}})}),i}function o9t(e,t,n,r,i,o,s){const a=r==null?void 0:r.querySelector(".xyflow__viewport");let l=!1;if(!a)return{changes:[],updatedInternals:l};const u=[],c=window.getComputedStyle(a),{m22:d}=new window.DOMMatrixReadOnly(c.transform),h=[];for(const m of e.values()){const g=t.get(m.id);if(!g)continue;if(g.hidden){t.set(g.id,{...g,internals:{...g.internals,handleBounds:void 0}}),l=!0;continue}const b=IQ(m.nodeElement),v=g.measured.width!==b.width||g.measured.height!==b.height;if(!!(b.width&&b.height&&(v||!g.internals.handleBounds||m.force))){const S=m.nodeElement.getBoundingClientRect(),C=Tb(g.extent)?g.extent:o;let{positionAbsolute:E}=g.internals;if(g.parentId&&g.extent==="parent"){const O=t.get(g.parentId);O&&(E=zPe(E,b,O))}else C&&(E=Eb(E,C,b));const T={...g,measured:b,internals:{...g.internals,positionAbsolute:E,handleBounds:{source:x0e("source",m.nodeElement,S,d,g.id),target:x0e("target",m.nodeElement,S,d,g.id)}}};t.set(g.id,T),g.parentId&&$Q(T,t,n,{nodeOrigin:i,zIndexMode:s}),l=!0,v&&(u.push({id:g.id,type:"dimensions",dimensions:b}),g.expandParent&&g.parentId&&h.push({id:g.id,parentId:g.parentId,rect:BT(T,i)}))}}if(h.length>0){const m=zQ(h,t,n,i);u.push(...m)}return{changes:u,updatedInternals:l}}async function s9t({delta:e,panZoom:t,transform:n,translateExtent:r,width:i,height:o}){if(!t||!e.x&&!e.y)return!1;const s=await t.setViewportConstrained({x:n[0]+e.x,y:n[1]+e.y,zoom:n[2]},[[0,0],[i,o]],r);return!!s&&(s.x!==n[0]||s.y!==n[1]||s.k!==n[2])}function A0e(e,t,n,r,i,o){let s=i;const a=r.get(s)||new Map;r.set(s,a.set(n,t)),s=`${i}-${e}`;const l=r.get(s)||new Map;if(r.set(s,l.set(n,t)),o){s=`${i}-${e}-${o}`;const u=r.get(s)||new Map;r.set(s,u.set(n,t))}}function tje(e,t,n){e.clear(),t.clear();for(const r of n){const{source:i,target:o,sourceHandle:s=null,targetHandle:a=null}=r,l={edgeId:r.id,source:i,target:o,sourceHandle:s,targetHandle:a},u=`${i}-${s}--${o}-${a}`,c=`${o}-${a}--${i}-${s}`;A0e("source",l,c,e,i,s),A0e("target",l,u,e,o,a),t.set(r.id,r)}}function nje(e,t){if(!e.parentId)return!1;const n=t.get(e.parentId);return n?n.selected?!0:nje(n,t):!1}function O0e(e,t,n){var i;let r=e;do{if((i=r==null?void 0:r.matches)!=null&&i.call(r,t))return!0;if(r===n)return!1;r=r==null?void 0:r.parentElement}while(r);return!1}function a9t(e,t,n,r){const i=new Map;for(const[o,s]of e)if((s.selected||s.id===r)&&(!s.parentId||!nje(s,e))&&(s.draggable||t&&typeof s.draggable>"u")){const a=e.get(o);a&&i.set(o,{id:o,position:a.position||{x:0,y:0},distance:{x:n.x-a.internals.positionAbsolute.x,y:n.y-a.internals.positionAbsolute.y},extent:a.extent,parentId:a.parentId,origin:a.origin,expandParent:a.expandParent,internals:{positionAbsolute:a.internals.positionAbsolute||{x:0,y:0}},measured:{width:a.measured.width??0,height:a.measured.height??0}})}return i}function r7({nodeId:e,dragItems:t,nodeLookup:n,dragging:r=!0}){var s,a,l;const i=[];for(const[u,c]of t){const d=(s=n.get(u))==null?void 0:s.internals.userNode;d&&i.push({...d,position:c.position,dragging:r})}if(!e)return[i[0],i];const o=(a=n.get(e))==null?void 0:a.internals.userNode;return[o?{...o,position:((l=t.get(e))==null?void 0:l.position)||o.position,dragging:r}:i[0],i]}function l9t({dragItems:e,snapGrid:t,x:n,y:r}){const i=e.values().next().value;if(!i)return null;const o={x:n-i.distance.x,y:r-i.distance.y},s=RA(o,t);return{x:s.x-o.x,y:s.y-o.y}}function u9t({onNodeMouseDown:e,getStoreItems:t,onDragStart:n,onDrag:r,onDragStop:i}){let o={x:null,y:null},s=0,a=new Map,l=!1,u={x:0,y:0},c=null,d=!1,h=null,m=!1,g=!1,b=null;function v({noDragClassName:S,handleSelector:C,domNode:E,isSelectable:T,nodeId:O,nodeClickDistance:M=0}){h=al(E);function N({x:F,y:z}){const{nodeLookup:$,nodeExtent:B,snapGrid:H,snapToGrid:U,nodeOrigin:W,onNodeDrag:q,onSelectionDrag:Y,onError:Q,updateNodePositions:G}=t();o={x:F,y:z};let le=!1;const K=a.size>1,te=K&&B?QW(yS(a)):null,de=K&&U?l9t({dragItems:a,snapGrid:H,x:F,y:z}):null;for(const[ue,ae]of a){if(!$.has(ue))continue;let ie={x:F-ae.distance.x,y:z-ae.distance.y};U&&(ie=de?{x:Math.round(ie.x+de.x),y:Math.round(ie.y+de.y)}:RA(ie,H));let he=null;if(K&&B&&!ae.extent&&te){const{positionAbsolute:Se}=ae.internals,pe=Se.x-te.x+B[0][0],Ee=Se.x+ae.measured.width-te.x2+B[1][0],ke=Se.y-te.y+B[0][1],Ie=Se.y+ae.measured.height-te.y2+B[1][1];he=[[pe,ke],[Ee,Ie]]}const{position:fe,positionAbsolute:se}=$Pe({nodeId:ue,nextPosition:ie,nodeLookup:$,nodeExtent:he||B,nodeOrigin:W,onError:Q});le=le||ae.position.x!==fe.x||ae.position.y!==fe.y,ae.position=fe,ae.internals.positionAbsolute=se}if(g=g||le,!!le&&(G(a,!0),b&&(r||q||!O&&Y))){const[ue,ae]=r7({nodeId:O,dragItems:a,nodeLookup:$});r==null||r(b,a,ue,ae),q==null||q(b,ue,ae),O||Y==null||Y(b,ae)}}async function I(){if(!c)return;const{transform:F,panBy:z,autoPanSpeed:$,autoPanOnNodeDrag:B}=t();if(!B){l=!1,cancelAnimationFrame(s);return}const[H,U]=NQ(u,c,$);(H!==0||U!==0)&&(o.x=(o.x??0)-H/F[2],o.y=(o.y??0)-U/F[2],await z({x:H,y:U})&&N(o)),s=requestAnimationFrame(I)}function D(F){var K;const{nodeLookup:z,multiSelectionActive:$,nodesDraggable:B,transform:H,snapGrid:U,snapToGrid:W,selectNodesOnDrag:q,onNodeDragStart:Y,onSelectionDragStart:Q,unselectNodesAndEdges:G}=t();d=!0,(!q||!T)&&!$&&O&&((K=z.get(O))!=null&&K.selected||G()),T&&q&&O&&(e==null||e(O));const le=iE(F.sourceEvent,{transform:H,snapGrid:U,snapToGrid:W,containerBounds:c});if(o=le,a=a9t(z,B,le,O),a.size>0&&(n||Y||!O&&Q)){const[te,de]=r7({nodeId:O,dragItems:a,nodeLookup:z});n==null||n(F.sourceEvent,a,te,de),Y==null||Y(F.sourceEvent,te,de),O||Q==null||Q(F.sourceEvent,de)}}const P=CPe().clickDistance(M).on("start",F=>{const{domNode:z,nodeDragThreshold:$,transform:B,snapGrid:H,snapToGrid:U}=t();c=(z==null?void 0:z.getBoundingClientRect())||null,m=!1,g=!1,b=F.sourceEvent,$===0&&D(F),o=iE(F.sourceEvent,{transform:B,snapGrid:H,snapToGrid:U,containerBounds:c}),u=Zu(F.sourceEvent,c)}).on("drag",F=>{const{autoPanOnNodeDrag:z,transform:$,snapGrid:B,snapToGrid:H,nodeDragThreshold:U,nodeLookup:W}=t(),q=iE(F.sourceEvent,{transform:$,snapGrid:B,snapToGrid:H,containerBounds:c});if(b=F.sourceEvent,(F.sourceEvent.type==="touchmove"&&F.sourceEvent.touches.length>1||O&&!W.has(O))&&(m=!0),!m){if(!l&&z&&d&&(l=!0,I()),!d){const Y=Zu(F.sourceEvent,c),Q=Y.x-u.x,G=Y.y-u.y;Math.sqrt(Q*Q+G*G)>U&&D(F)}(o.x!==q.xSnapped||o.y!==q.ySnapped)&&a&&d&&(u=Zu(F.sourceEvent,c),N(q))}}).on("end",F=>{if(!d||m){m&&a.size>0&&t().updateNodePositions(a,!1);return}if(l=!1,d=!1,cancelAnimationFrame(s),a.size>0){const{nodeLookup:z,updateNodePositions:$,onNodeDragStop:B,onSelectionDragStop:H}=t();if(g&&($(a,!1),g=!1),i||B||!O&&H){const[U,W]=r7({nodeId:O,dragItems:a,nodeLookup:z,dragging:!1});i==null||i(F.sourceEvent,a,U,W),B==null||B(F.sourceEvent,U,W),O||H==null||H(F.sourceEvent,W)}}}).filter(F=>{const z=F.target;return!F.button&&(!S||!O0e(z,`.${S}`,E))&&(!C||O0e(z,C,E))});h.call(P)}function w(){h==null||h.on(".drag",null)}return{update:v,destroy:w}}function c9t(e,t,n){const r=[],i={x:e.x-n,y:e.y-n,width:n*2,height:n*2};for(const o of t.values())JI(i,BT(o))>0&&r.push(o);return r}const d9t=250;function f9t(e,t,n,r){var a,l;let i=[],o=1/0;const s=c9t(e,n,t+d9t);for(const u of s){const c=[...((a=u.internals.handleBounds)==null?void 0:a.source)??[],...((l=u.internals.handleBounds)==null?void 0:l.target)??[]];for(const d of c){if(r.nodeId===d.nodeId&&r.type===d.type&&r.id===d.id)continue;const{x:h,y:m}=Ab(u,d,d.position,!0),g=Math.sqrt(Math.pow(h-e.x,2)+Math.pow(m-e.y,2));g>t||(g<o?(i=[{...d,x:h,y:m}],o=g):g===o&&i.push({...d,x:h,y:m}))}}if(!i.length)return null;if(i.length>1){const u=r.type==="source"?"target":"source";return i.find(c=>c.type===u)??i[0]}return i[0]}function rje(e,t,n,r,i,o=!1){var u,c,d;const s=r.get(e);if(!s)return null;const a=i==="strict"?(u=s.internals.handleBounds)==null?void 0:u[t]:[...((c=s.internals.handleBounds)==null?void 0:c.source)??[],...((d=s.internals.handleBounds)==null?void 0:d.target)??[]],l=(n?a==null?void 0:a.find(h=>h.id===n):a==null?void 0:a[0])??null;return l&&o?{...l,...Ab(s,l,l.position,!0)}:l}function ije(e,t){return e||(t!=null&&t.classList.contains("target")?"target":t!=null&&t.classList.contains("source")?"source":null)}function h9t(e,t){let n=null;return t?n=!0:e&&!t&&(n=!1),n}const oje=()=>!0;function p9t(e,{connectionMode:t,connectionRadius:n,handleId:r,nodeId:i,edgeUpdaterType:o,isTarget:s,domNode:a,nodeLookup:l,lib:u,autoPanOnConnect:c,flowId:d,panBy:h,cancelConnection:m,onConnectStart:g,onConnect:b,onConnectEnd:v,isValidConnection:w=oje,onReconnectEnd:S,updateConnection:C,getTransform:E,getFromHandle:T,autoPanSpeed:O,dragThreshold:M=1,handleDomNode:N}){const I=qPe(e.target);let D=0,P;const{x:F,y:z}=Zu(e),$=ije(o,N),B=a==null?void 0:a.getBoundingClientRect();let H=!1;if(!B||!$)return;const U=rje(i,$,r,l,t);if(!U)return;let W=Zu(e,B),q=!1,Y=null,Q=!1,G=null;function le(){if(!c||!B)return;const[fe,se]=NQ(W,B,O);h({x:fe,y:se}),D=requestAnimationFrame(le)}const K={...U,nodeId:i,type:$,position:U.position},te=l.get(i);let ue={inProgress:!0,isValid:null,from:Ab(te,K,Bt.Left,!0),fromHandle:K,fromPosition:K.position,fromNode:te,to:W,toHandle:null,toPosition:g0e[K.position],toNode:null,pointer:W};function ae(){H=!0,C(ue),g==null||g(e,{nodeId:i,handleId:r,handleType:$})}M===0&&ae();function ie(fe){if(!H){const{x:Ie,y:Be}=Zu(fe),Oe=Ie-F,Le=Be-z;if(!(Oe*Oe+Le*Le>M*M))return;ae()}if(!T()||!K){he(fe);return}const se=E();W=Zu(fe,B),P=f9t(MA(W,se,!1,[1,1]),n,l,K),q||(le(),q=!0);const Se=sje(fe,{handle:P,connectionMode:t,fromNodeId:i,fromHandleId:r,fromType:s?"target":"source",isValidConnection:w,doc:I,lib:u,flowId:d,nodeLookup:l});G=Se.handleDomNode,Y=Se.connection,Q=h9t(!!P,Se.isValid);const pe=l.get(i),Ee=pe?Ab(pe,K,Bt.Left,!0):ue.from,ke={...ue,from:Ee,isValid:Q,to:Se.toHandle&&Q?Nw({x:Se.toHandle.x,y:Se.toHandle.y},se):W,toHandle:Se.toHandle,toPosition:Q&&Se.toHandle?Se.toHandle.position:g0e[K.position],toNode:Se.toHandle?l.get(Se.toHandle.nodeId):null,pointer:W};C(ke),ue=ke}function he(fe){if(!("touches"in fe&&fe.touches.length>0)){if(H){(P||G)&&Y&&Q&&(b==null||b(Y));const{inProgress:se,...Se}=ue,pe={...Se,toPosition:ue.toHandle?ue.toPosition:null};v==null||v(fe,pe),o&&(S==null||S(fe,pe))}m(),cancelAnimationFrame(D),q=!1,Q=!1,Y=null,G=null,I.removeEventListener("mousemove",ie),I.removeEventListener("mouseup",he),I.removeEventListener("touchmove",ie),I.removeEventListener("touchend",he)}}I.addEventListener("mousemove",ie),I.addEventListener("mouseup",he),I.addEventListener("touchmove",ie),I.addEventListener("touchend",he)}function sje(e,{handle:t,connectionMode:n,fromNodeId:r,fromHandleId:i,fromType:o,doc:s,lib:a,flowId:l,isValidConnection:u=oje,nodeLookup:c}){const d=o==="target",h=t?s.querySelector(`.${a}-flow__handle[data-id="${l}-${t==null?void 0:t.nodeId}-${t==null?void 0:t.id}-${t==null?void 0:t.type}"]`):null,{x:m,y:g}=Zu(e),b=s.elementFromPoint(m,g),v=b!=null&&b.classList.contains(`${a}-flow__handle`)?b:h,w={handleDomNode:v,isValid:!1,connection:null,toHandle:null};if(v){const S=ije(void 0,v),C=v.getAttribute("data-nodeid"),E=v.getAttribute("data-handleid"),T=v.classList.contains("connectable"),O=v.classList.contains("connectableend");if(!C||!S)return w;const M={source:d?C:r,sourceHandle:d?E:i,target:d?r:C,targetHandle:d?i:E};w.connection=M;const I=T&&O&&(n===Mw.Strict?d&&S==="source"||!d&&S==="target":C!==r||E!==i);w.isValid=I&&u(M),w.toHandle=rje(C,S,E,c,n,!0)}return w}const eq={onPointerDown:p9t,isValid:sje};function m9t({domNode:e,panZoom:t,getTransform:n,getViewScale:r}){const i=al(e);function o({translateExtent:a,width:l,height:u,zoomStep:c=1,pannable:d=!0,zoomable:h=!0,inversePan:m=!1}){const g=C=>{if(C.sourceEvent.type!=="wheel"||!t)return;const E=n(),T=C.sourceEvent.ctrlKey&&HT()?10:1,O=-C.sourceEvent.deltaY*(C.sourceEvent.deltaMode===1?.05:C.sourceEvent.deltaMode?1:.002)*c,M=E[2]*Math.pow(2,O*T);t.scaleTo(M)};let b=[0,0];const v=C=>{(C.sourceEvent.type==="mousedown"||C.sourceEvent.type==="touchstart")&&(b=[C.sourceEvent.clientX??C.sourceEvent.touches[0].clientX,C.sourceEvent.clientY??C.sourceEvent.touches[0].clientY])},w=C=>{const E=n();if(C.sourceEvent.type!=="mousemove"&&C.sourceEvent.type!=="touchmove"||!t)return;const T=[C.sourceEvent.clientX??C.sourceEvent.touches[0].clientX,C.sourceEvent.clientY??C.sourceEvent.touches[0].clientY],O=[T[0]-b[0],T[1]-b[1]];b=T;const M=r()*Math.max(E[2],Math.log(E[2]))*(m?-1:1),N={x:E[0]-O[0]*M,y:E[1]-O[1]*M},I=[[0,0],[l,u]];t.setViewportConstrained({x:N.x,y:N.y,zoom:E[2]},I,a)},S=LPe().on("start",v).on("zoom",d?w:null).on("zoom.wheel",h?g:null);i.call(S,{})}function s(){i.on("zoom",null)}return{update:o,destroy:s,pointer:Fu}}const HD=e=>({x:e.x,y:e.y,zoom:e.k}),i7=({x:e,y:t,zoom:n})=>zD.translate(e,t).scale(n),om=(e,t)=>e.target.closest(`.${t}`),aje=(e,t)=>t===2&&Array.isArray(e)&&e.includes(2),g9t=e=>((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2,o7=(e,t=0,n=g9t,r=()=>{})=>{const i=typeof t=="number"&&t>0;return i||r(),i?e.transition().duration(t).ease(n).on("end",r):e},lje=e=>{const t=e.ctrlKey&&HT()?10:1;return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*t};function y9t({zoomPanValues:e,noWheelClassName:t,d3Selection:n,d3Zoom:r,panOnScrollMode:i,panOnScrollSpeed:o,zoomOnPinch:s,onPanZoomStart:a,onPanZoom:l,onPanZoomEnd:u}){return c=>{if(om(c,t))return c.ctrlKey&&c.preventDefault(),!1;c.preventDefault(),c.stopImmediatePropagation();const d=n.property("__zoom").k||1;if(c.ctrlKey&&s){const v=Fu(c),w=lje(c),S=d*Math.pow(2,w);r.scaleTo(n,S,v,c);return}const h=c.deltaMode===1?20:1;let m=i===rb.Vertical?0:c.deltaX*h,g=i===rb.Horizontal?0:c.deltaY*h;!HT()&&c.shiftKey&&i!==rb.Vertical&&(m=c.deltaY*h,g=0),r.translateBy(n,-(m/d)*o,-(g/d)*o,{internal:!0});const b=HD(n.property("__zoom"));clearTimeout(e.panScrollTimeout),e.isPanScrolling?l==null||l(c,b):(e.isPanScrolling=!0,a==null||a(c,b)),e.panScrollTimeout=setTimeout(()=>{u==null||u(c,b),e.isPanScrolling=!1},150)}}function b9t({noWheelClassName:e,preventScrolling:t,d3ZoomHandler:n}){return function(r,i){const o=r.type==="wheel",s=!t&&o&&!r.ctrlKey,a=om(r,e);if(r.ctrlKey&&o&&a&&r.preventDefault(),s||a)return null;r.preventDefault(),n.call(this,r,i)}}function v9t({zoomPanValues:e,onDraggingChange:t,onPanZoomStart:n}){return r=>{var o,s,a;if((o=r.sourceEvent)!=null&&o.internal)return;const i=HD(r.transform);e.mouseButton=((s=r.sourceEvent)==null?void 0:s.button)||0,e.isZoomingOrPanning=!0,e.prevViewport=i,((a=r.sourceEvent)==null?void 0:a.type)==="mousedown"&&t(!0),n&&(n==null||n(r.sourceEvent,i))}}function x9t({zoomPanValues:e,panOnDrag:t,onPaneContextMenu:n,onTransformChange:r,onPanZoom:i}){return o=>{var s,a;e.usedRightMouseButton=!!(n&&aje(t,e.mouseButton??0)),(s=o.sourceEvent)!=null&&s.sync||r([o.transform.x,o.transform.y,o.transform.k]),i&&!((a=o.sourceEvent)!=null&&a.internal)&&(i==null||i(o.sourceEvent,HD(o.transform)))}}function w9t({zoomPanValues:e,panOnDrag:t,panOnScroll:n,onDraggingChange:r,onPanZoomEnd:i,onPaneContextMenu:o}){return s=>{var a;if(!((a=s.sourceEvent)!=null&&a.internal)&&(e.isZoomingOrPanning=!1,o&&aje(t,e.mouseButton??0)&&!e.usedRightMouseButton&&s.sourceEvent&&o(s.sourceEvent),e.usedRightMouseButton=!1,r(!1),i)){const l=HD(s.transform);e.prevViewport=l,clearTimeout(e.timerId),e.timerId=setTimeout(()=>{i==null||i(s.sourceEvent,l)},n?150:0)}}}function S9t({panActivationKeyPressed:e,zoomActivationKeyPressed:t,zoomOnScroll:n,zoomOnPinch:r,panOnDrag:i,panOnScroll:o,zoomOnDoubleClick:s,userSelectionActive:a,noWheelClassName:l,noPanClassName:u,lib:c,connectionInProgress:d}){return h=>{var w;const m=t||n,g=r&&h.ctrlKey,b=h.type==="wheel";if(h.button===1&&h.type==="mousedown"&&(om(h,`${c}-flow__node`)||om(h,`${c}-flow__edge`)||om(h,`${c}-flow__selection`)||om(h,`${c}-flow__nodesselection`)))return!0;if(!i&&!m&&!o&&!s&&!r||a||d&&!b||om(h,l)&&b||om(h,u)&&(!b||o&&b&&!t)||!r&&h.ctrlKey&&b)return!1;if(!r&&h.type==="touchstart"&&((w=h.touches)==null?void 0:w.length)>1)return h.preventDefault(),!1;if(!m&&!o&&!g&&b||!i&&(h.type==="mousedown"||h.type==="touchstart")||Array.isArray(i)&&!i.includes(h.button)&&h.type==="mousedown")return!1;const v=Array.isArray(i)&&i.includes(h.button)||!h.button||h.button<=1;return(!h.ctrlKey||b||e)&&v}}function k9t({domNode:e,minZoom:t,maxZoom:n,translateExtent:r,viewport:i,onPanZoom:o,onPanZoomStart:s,onPanZoomEnd:a,onDraggingChange:l}){const u={isZoomingOrPanning:!1,usedRightMouseButton:!1,prevViewport:{},mouseButton:0,timerId:void 0,panScrollTimeout:void 0,isPanScrolling:!1},c=e.getBoundingClientRect();let d=[[0,0],[c.width,c.height]];const h=typeof ResizeObserver<"u"?new ResizeObserver(z=>{const $=z[0];$&&(d=[[0,0],[$.contentRect.width,$.contentRect.height]])}):null;h==null||h.observe(e);const m=LPe().extent(()=>d).scaleExtent([t,n]).translateExtent(r),g=al(e).call(m);E({x:i.x,y:i.y,zoom:_w(i.zoom,t,n)},[[0,0],[c.width,c.height]],r);const b=g.on("wheel.zoom"),v=g.on("dblclick.zoom");m.wheelDelta(lje);async function w(z,$){return g?new Promise(B=>{m==null||m.interpolate(($==null?void 0:$.interpolate)==="linear"?Ah:k_).transform(o7(g,$==null?void 0:$.duration,$==null?void 0:$.ease,()=>B(!0)),z)}):!1}function S({noWheelClassName:z,noPanClassName:$,onPaneContextMenu:B,userSelectionActive:H,panOnScroll:U,panOnDrag:W,panOnScrollMode:q,panOnScrollSpeed:Y,preventScrolling:Q,zoomOnPinch:G,zoomOnScroll:le,zoomOnDoubleClick:K,panActivationKeyPressed:te=!1,zoomActivationKeyPressed:de,lib:ue,onTransformChange:ae,connectionInProgress:ie,paneClickDistance:he,selectionOnDrag:fe}){H&&!u.isZoomingOrPanning&&C();const se=U&&!de&&!H;m.clickDistance(fe?1/0:!Qu(he)||he<0?0:he);const Se=se?y9t({zoomPanValues:u,noWheelClassName:z,d3Selection:g,d3Zoom:m,panOnScrollMode:q,panOnScrollSpeed:Y,zoomOnPinch:G,onPanZoomStart:s,onPanZoom:o,onPanZoomEnd:a}):b9t({noWheelClassName:z,preventScrolling:Q,d3ZoomHandler:b});g.on("wheel.zoom",Se,{passive:!1});const pe=v9t({zoomPanValues:u,onDraggingChange:l,onPanZoomStart:s});m.on("start",pe);const Ee=x9t({zoomPanValues:u,panOnDrag:W,onPaneContextMenu:!!B,onPanZoom:o,onTransformChange:ae});m.on("zoom",Ee);const ke=w9t({zoomPanValues:u,panOnDrag:W,panOnScroll:U,onPaneContextMenu:B,onPanZoomEnd:a,onDraggingChange:l});m.on("end",ke);const Ie=S9t({panActivationKeyPressed:te,zoomActivationKeyPressed:de,panOnDrag:W,zoomOnScroll:le,panOnScroll:U,zoomOnDoubleClick:K,zoomOnPinch:G,userSelectionActive:H,noPanClassName:$,noWheelClassName:z,lib:ue,connectionInProgress:ie});m.filter(Ie),K?g.on("dblclick.zoom",v):g.on("dblclick.zoom",null)}function C(){m.on("zoom",null)}async function E(z,$,B){const H=i7(z),U=m==null?void 0:m.constrain()(H,$,B);return U&&await w(U),U}async function T(z,$){const B=i7(z);return await w(B,$),B}function O(z){if(g){const $=i7(z),B=g.property("__zoom");(B.k!==z.zoom||B.x!==z.x||B.y!==z.y)&&(m==null||m.transform(g,$,null,{sync:!0}))}}function M(){const z=g?NPe(g.node()):{x:0,y:0,k:1};return{x:z.x,y:z.y,zoom:z.k}}async function N(z,$){return g?new Promise(B=>{m==null||m.interpolate(($==null?void 0:$.interpolate)==="linear"?Ah:k_).scaleTo(o7(g,$==null?void 0:$.duration,$==null?void 0:$.ease,()=>B(!0)),z)}):!1}async function I(z,$){return g?new Promise(B=>{m==null||m.interpolate(($==null?void 0:$.interpolate)==="linear"?Ah:k_).scaleBy(o7(g,$==null?void 0:$.duration,$==null?void 0:$.ease,()=>B(!0)),z)}):!1}function D(z){m==null||m.scaleExtent(z)}function P(z){m==null||m.translateExtent(z)}function F(z){const $=!Qu(z)||z<0?0:z;m==null||m.clickDistance($)}return{update:S,destroy:C,setViewport:T,setViewportConstrained:E,getViewport:M,scaleTo:N,scaleBy:I,setScaleExtent:D,setTranslateExtent:P,syncViewport:O,setClickDistance:F}}var Lw;(function(e){e.Line="line",e.Handle="handle"})(Lw||(Lw={}));function C9t({width:e,prevWidth:t,height:n,prevHeight:r,affectsX:i,affectsY:o}){const s=e-t,a=n-r,l=[s>0?1:s<0?-1:0,a>0?1:a<0?-1:0];return s&&i&&(l[0]=l[0]*-1),a&&o&&(l[1]=l[1]*-1),l}function R0e(e){const t=e.includes("right")||e.includes("left"),n=e.includes("bottom")||e.includes("top"),r=e.includes("left"),i=e.includes("top");return{isHorizontal:t,isVertical:n,affectsX:r,affectsY:i}}function Dp(e,t){return Math.max(0,t-e)}function $p(e,t){return Math.max(0,e-t)}function kM(e,t,n){return Math.max(0,t-e,e-n)}function M0e(e,t){return e?!t:t}function E9t(e,t,n,r,i,o,s,a){let{affectsX:l,affectsY:u}=t;const{isHorizontal:c,isVertical:d}=t,h=c&&d,{xSnapped:m,ySnapped:g}=n,{minWidth:b,maxWidth:v,minHeight:w,maxHeight:S}=r,{x:C,y:E,width:T,height:O,aspectRatio:M}=e;let N=Math.floor(c?m-e.pointerX:0),I=Math.floor(d?g-e.pointerY:0);const D=T+(l?-N:N),P=O+(u?-I:I),F=-o[0]*T,z=-o[1]*O;let $=kM(D,b,v),B=kM(P,w,S);if(s){let W=0,q=0;l&&N<0?W=Dp(C+N+F,s[0][0]):!l&&N>0&&(W=$p(C+D+F,s[1][0])),u&&I<0?q=Dp(E+I+z,s[0][1]):!u&&I>0&&(q=$p(E+P+z,s[1][1])),$=Math.max($,W),B=Math.max(B,q)}if(a){let W=0,q=0;l&&N>0?W=$p(C+N,a[0][0]):!l&&N<0&&(W=Dp(C+D,a[1][0])),u&&I>0?q=$p(E+I,a[0][1]):!u&&I<0&&(q=Dp(E+P,a[1][1])),$=Math.max($,W),B=Math.max(B,q)}if(i){if(c){const W=kM(D/M,w,S)*M;if($=Math.max($,W),s){let q=0;!l&&!u||l&&!u&&h?q=$p(E+z+D/M,s[1][1])*M:q=Dp(E+z+(l?N:-N)/M,s[0][1])*M,$=Math.max($,q)}if(a){let q=0;!l&&!u||l&&!u&&h?q=Dp(E+D/M,a[1][1])*M:q=$p(E+(l?N:-N)/M,a[0][1])*M,$=Math.max($,q)}}if(d){const W=kM(P*M,b,v)/M;if(B=Math.max(B,W),s){let q=0;!l&&!u||u&&!l&&h?q=$p(C+P*M+F,s[1][0])/M:q=Dp(C+(u?I:-I)*M+F,s[0][0])/M,B=Math.max(B,q)}if(a){let q=0;!l&&!u||u&&!l&&h?q=Dp(C+P*M,a[1][0])/M:q=$p(C+(u?I:-I)*M,a[0][0])/M,B=Math.max(B,q)}}}I=I+(I<0?B:-B),N=N+(N<0?$:-$),i&&(h?D>P*M?I=(M0e(l,u)?-N:N)/M:N=(M0e(l,u)?-I:I)*M:c?(I=N/M,u=l):(N=I*M,l=u));const H=l?C+N:C,U=u?E+I:E;return{width:T+(l?-N:N),height:O+(u?-I:I),x:o[0]*N*(l?-1:1)+H,y:o[1]*I*(u?-1:1)+U}}const uje={width:0,height:0,x:0,y:0},T9t={...uje,pointerX:0,pointerY:0,aspectRatio:1};function A9t(e,t,n){const r=t.position.x+e.position.x,i=t.position.y+e.position.y,o=e.measured.width??0,s=e.measured.height??0,a=n[0]*o,l=n[1]*s;return[[r-a,i-l],[r+o-a,i+s-l]]}function O9t({domNode:e,nodeId:t,getStoreItems:n,onChange:r,onEnd:i}){const o=al(e);let s={controlDirection:R0e("bottom-right"),boundaries:{minWidth:0,minHeight:0,maxWidth:Number.MAX_VALUE,maxHeight:Number.MAX_VALUE},resizeDirection:void 0,keepAspectRatio:!1};function a({controlPosition:u,boundaries:c,keepAspectRatio:d,resizeDirection:h,onResizeStart:m,onResize:g,onResizeEnd:b,shouldResize:v}){let w={...uje},S={...T9t};s={boundaries:c,resizeDirection:h,keepAspectRatio:d,controlDirection:R0e(u)};let C,E=null,T=[],O,M,N,I=!1;const D=CPe().on("start",P=>{const{nodeLookup:F,transform:z,snapGrid:$,snapToGrid:B,nodeOrigin:H,paneDomNode:U}=n();if(C=F.get(t),!C)return;E=(U==null?void 0:U.getBoundingClientRect())??null;const{xSnapped:W,ySnapped:q}=iE(P.sourceEvent,{transform:z,snapGrid:$,snapToGrid:B,containerBounds:E});w={width:C.measured.width??0,height:C.measured.height??0,x:C.position.x??0,y:C.position.y??0},S={...w,pointerX:W,pointerY:q,aspectRatio:w.width/w.height},O=void 0,M=Tb(C.extent)?C.extent:void 0,C.parentId&&(C.extent==="parent"||C.expandParent)&&(O=F.get(C.parentId)),O&&C.extent==="parent"&&(M=[[0,0],[O.measured.width,O.measured.height]]),T=[],N=void 0;for(const[Y,Q]of F)if(Q.parentId===t&&(T.push({id:Y,position:{...Q.position},extent:Q.extent}),Q.extent==="parent"||Q.expandParent)){const G=A9t(Q,C,Q.origin??H);N?N=[[Math.min(G[0][0],N[0][0]),Math.min(G[0][1],N[0][1])],[Math.max(G[1][0],N[1][0]),Math.max(G[1][1],N[1][1])]]:N=G}m==null||m(P,{...w})}).on("drag",P=>{const{transform:F,snapGrid:z,snapToGrid:$,nodeOrigin:B}=n(),H=iE(P.sourceEvent,{transform:F,snapGrid:z,snapToGrid:$,containerBounds:E}),U=[];if(!C)return;const{x:W,y:q,width:Y,height:Q}=w,G={},le=C.origin??B,{width:K,height:te,x:de,y:ue}=E9t(S,s.controlDirection,H,s.boundaries,s.keepAspectRatio,le,M,N),ae=K!==Y,ie=te!==Q,he=de!==W&&ae,fe=ue!==q&&ie;if(!he&&!fe&&!ae&&!ie)return;if((he||fe||le[0]===1||le[1]===1)&&(G.x=he?de:w.x,G.y=fe?ue:w.y,w.x=G.x,w.y=G.y,T.length>0)){const Ee=de-W,ke=ue-q;for(const Ie of T)Ie.position={x:Ie.position.x-Ee+le[0]*(K-Y),y:Ie.position.y-ke+le[1]*(te-Q)},U.push(Ie)}if((ae||ie)&&(G.width=ae&&(!s.resizeDirection||s.resizeDirection==="horizontal")?K:w.width,G.height=ie&&(!s.resizeDirection||s.resizeDirection==="vertical")?te:w.height,w.width=G.width,w.height=G.height),O&&C.expandParent){const Ee=le[0]*(G.width??0);G.x&&G.x<Ee&&(w.x=Ee,S.x=S.x-(G.x-Ee));const ke=le[1]*(G.height??0);G.y&&G.y<ke&&(w.y=ke,S.y=S.y-(G.y-ke))}const se=C9t({width:w.width,prevWidth:Y,height:w.height,prevHeight:Q,affectsX:s.controlDirection.affectsX,affectsY:s.controlDirection.affectsY}),Se={...w,direction:se};(v==null?void 0:v(P,Se))!==!1&&(I=!0,g==null||g(P,Se),r(G,U))}).on("end",P=>{I&&(b==null||b(P,{...w}),i==null||i({...w}),I=!1)});o.call(D)}function l(){o.on(".drag",null)}return{update:a,destroy:l}}const R9t={},_0e=e=>{let t;const n=new Set,r=(c,d)=>{const h=typeof c=="function"?c(t):c;if(!Object.is(h,t)){const m=t;t=d??(typeof h!="object"||h===null)?h:Object.assign({},t,h),n.forEach(g=>g(t,m))}},i=()=>t,l={setState:r,getState:i,getInitialState:()=>u,subscribe:c=>(n.add(c),()=>n.delete(c)),destroy:()=>{(R9t?"production":void 0)!=="production"&&console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),n.clear()}},u=t=e(r,i,l);return l},M9t=e=>e?_0e(e):_0e,{useDebugValue:_9t}=we,{useSyncExternalStoreWithSelector:N9t}=Fze,L9t=e=>e;function cje(e,t=L9t,n){const r=N9t(e.subscribe,e.getState,e.getServerState||e.getInitialState,t,n);return _9t(r),r}const N0e=(e,t)=>{const n=M9t(e),r=(i,o=t)=>cje(n,i,o);return Object.assign(r,n),r},I9t=(e,t)=>e?N0e(e,t):N0e;function ri(e,t){if(Object.is(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(const[r,i]of e)if(!Object.is(i,t.get(r)))return!1;return!0}if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(const r of e)if(!t.has(r))return!1;return!0}const n=Object.keys(e);if(n.length!==Object.keys(t).length)return!1;for(const r of n)if(!Object.prototype.hasOwnProperty.call(t,r)||!Object.is(e[r],t[r]))return!1;return!0}const UD=A.createContext(null),P9t=UD.Provider,dje=oc.error001("react");function Mn(e,t){const n=A.useContext(UD);if(n===null)throw new Error(dje);return cje(n,e,t)}function oi(){const e=A.useContext(UD);if(e===null)throw new Error(dje);return A.useMemo(()=>({getState:e.getState,setState:e.setState,subscribe:e.subscribe}),[e])}const L0e={display:"none"},j9t={position:"absolute",width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0px, 0px, 0px, 0px)",clipPath:"inset(100%)"},fje="react-flow__node-desc",hje="react-flow__edge-desc",D9t="react-flow__aria-live",$9t=e=>e.ariaLiveMessage,z9t=e=>e.ariaLabelConfig;function F9t({rfId:e}){const t=Mn($9t);return y.jsx("div",{id:`${D9t}-${e}`,"aria-live":"assertive","aria-atomic":"true",style:j9t,children:t})}function B9t({rfId:e,disableKeyboardA11y:t}){const n=Mn(z9t);return y.jsxs(y.Fragment,{children:[y.jsx("div",{id:`${fje}-${e}`,style:L0e,children:t?n["node.a11yDescription.default"]:n["node.a11yDescription.keyboardDisabled"]}),y.jsx("div",{id:`${hje}-${e}`,style:L0e,children:n["edge.a11yDescription.default"]}),!t&&y.jsx(F9t,{rfId:e})]})}const bS=A.forwardRef(({position:e="top-left",children:t,className:n,style:r,...i},o)=>{const s=`${e}`.split("-");return y.jsx("div",{className:$i(["react-flow__panel",n,...s]),style:r,ref:o,...i,children:t})});bS.displayName="Panel";const I0e="https://reactflow.dev?utm_source=attribution";function H9t({proOptions:e,position:t="bottom-right"}){return A.useEffect(()=>{},[]),e!=null&&e.hideAttribution?null:y.jsx(bS,{position:t,className:"react-flow__attribution","data-message":`Please only hide this attribution when you are subscribed to React Flow Pro: ${I0e}`,children:y.jsx("a",{href:I0e,target:"_blank",rel:"noopener noreferrer","aria-label":"React Flow attribution",children:"React Flow"})})}const U9t=e=>{const t=[],n=[];for(const[,r]of e.nodeLookup)r.selected&&t.push(r.internals.userNode);for(const[,r]of e.edgeLookup)r.selected&&n.push(r);return{selectedNodes:t,selectedEdges:n}},CM=e=>e.id;function V9t(e,t){return ri(e.selectedNodes.map(CM),t.selectedNodes.map(CM))&&ri(e.selectedEdges.map(CM),t.selectedEdges.map(CM))}function W9t({onSelectionChange:e}){const t=oi(),{selectedNodes:n,selectedEdges:r}=Mn(U9t,V9t);return A.useEffect(()=>{const i={nodes:n,edges:r};e==null||e(i),t.getState().onSelectionChangeHandlers.forEach(o=>o(i))},[n,r,e]),null}const q9t=e=>!!e.onSelectionChangeHandlers;function G9t({onSelectionChange:e}){const t=Mn(q9t);return e||t?y.jsx(W9t,{onSelectionChange:e}):null}const pje=[0,0],K9t={x:0,y:0,zoom:1},Y9t=["nodes","edges","defaultNodes","defaultEdges","onConnect","onConnectStart","onConnectEnd","onClickConnectStart","onClickConnectEnd","nodesDraggable","autoPanOnNodeFocus","nodesConnectable","nodesFocusable","edgesFocusable","edgesReconnectable","elevateNodesOnSelect","elevateEdgesOnSelect","minZoom","maxZoom","nodeExtent","onNodesChange","onEdgesChange","elementsSelectable","connectionMode","snapGrid","snapToGrid","translateExtent","connectOnClick","defaultEdgeOptions","fitView","fitViewOptions","onNodesDelete","onEdgesDelete","onDelete","onNodeDrag","onNodeDragStart","onNodeDragStop","onSelectionDrag","onSelectionDragStart","onSelectionDragStop","onMoveStart","onMove","onMoveEnd","noPanClassName","nodeOrigin","autoPanOnConnect","autoPanOnNodeDrag","onError","connectionRadius","isValidConnection","selectNodesOnDrag","nodeDragThreshold","connectionDragThreshold","onBeforeDelete","debug","autoPanSpeed","ariaLabelConfig","zIndexMode"],P0e=[...Y9t,"rfId"],X9t=e=>({setNodes:e.setNodes,setEdges:e.setEdges,setMinZoom:e.setMinZoom,setMaxZoom:e.setMaxZoom,setTranslateExtent:e.setTranslateExtent,setNodeExtent:e.setNodeExtent,reset:e.reset,setDefaultNodesAndEdges:e.setDefaultNodesAndEdges}),j0e={translateExtent:$T,nodeOrigin:pje,minZoom:.5,maxZoom:2,elementsSelectable:!0,noPanClassName:"nopan",rfId:"1"};function Q9t(e){const{setNodes:t,setEdges:n,setMinZoom:r,setMaxZoom:i,setTranslateExtent:o,setNodeExtent:s,reset:a,setDefaultNodesAndEdges:l}=Mn(X9t,ri),u=oi();A.useEffect(()=>(l(e.defaultNodes,e.defaultEdges),()=>{c.current=j0e,a()}),[]);const c=A.useRef(j0e);return A.useEffect(()=>{for(const d of P0e){const h=e[d],m=c.current[d];h!==m&&(typeof e[d]>"u"||(d==="nodes"?t(h):d==="edges"?n(h):d==="minZoom"?r(h):d==="maxZoom"?i(h):d==="translateExtent"?o(h):d==="nodeExtent"?s(h):d==="ariaLabelConfig"?u.setState({ariaLabelConfig:F7t(h)}):d==="fitView"?u.setState({fitViewQueued:h}):d==="fitViewOptions"?u.setState({fitViewOptions:h}):u.setState({[d]:h})))}c.current=e},P0e.map(d=>e[d])),null}function D0e(){return typeof window>"u"||!window.matchMedia?null:window.matchMedia("(prefers-color-scheme: dark)")}function Z9t(e){var r;const[t,n]=A.useState(e==="system"?null:e);return A.useEffect(()=>{if(e!=="system"){n(e);return}const i=D0e(),o=()=>n(i!=null&&i.matches?"dark":"light");return o(),i==null||i.addEventListener("change",o),()=>{i==null||i.removeEventListener("change",o)}},[e]),t!==null?t:(r=D0e())!=null&&r.matches?"dark":"light"}const $0e=typeof document<"u"?document:null;function VT(e=null,t={target:$0e,actInsideInputWithModifier:!0}){const[n,r]=A.useState(!1),i=A.useRef(!1),o=A.useRef(new Set([])),[s,a]=A.useMemo(()=>{if(e!==null){const u=(Array.isArray(e)?e:[e]).filter(d=>typeof d=="string").map(d=>d.replace(/\+/g,`
2942
+ `).replace(f5e,"")}function Zee(f,p){return p=Qee(p),Qee(f)===p}function Tr(f,p,x,k,R,L){switch(x){case"children":if(typeof k=="string")p==="body"||p==="textarea"&&k===""||za(f,k);else if(typeof k=="number"||typeof k=="bigint")p!=="body"&&za(f,""+k);else return;break;case"className":yu(f,"class",k);break;case"tabIndex":yu(f,"tabindex",k);break;case"dir":case"role":case"viewBox":case"width":case"height":yu(f,x,k);break;case"style":bu(f,k,L);return;case"data":if(p!=="object"){yu(f,"data",k);break}case"src":case"href":if(k===""&&(p!=="a"||x!=="href")){f.removeAttribute(x);break}if(k==null||typeof k=="function"||typeof k=="symbol"||typeof k=="boolean"){f.removeAttribute(x);break}k=Gd(k),f.setAttribute(x,k);break;case"action":case"formAction":if(typeof k=="function"){f.setAttribute(x,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof L=="function"&&(x==="formAction"?(p!=="input"&&Tr(f,p,"name",R.name,R,null),Tr(f,p,"formEncType",R.formEncType,R,null),Tr(f,p,"formMethod",R.formMethod,R,null),Tr(f,p,"formTarget",R.formTarget,R,null)):(Tr(f,p,"encType",R.encType,R,null),Tr(f,p,"method",R.method,R,null),Tr(f,p,"target",R.target,R,null)));if(k==null||typeof k=="symbol"||typeof k=="boolean"){f.removeAttribute(x);break}k=Gd(k),f.setAttribute(x,k);break;case"onClick":k!=null&&(f.onclick=_s);return;case"onScroll":k!=null&&jn("scroll",f);return;case"onScrollEnd":k!=null&&jn("scrollend",f);return;case"dangerouslySetInnerHTML":if(k!=null){if(typeof k!="object"||!("__html"in k))throw Error(r(61));if(x=k.__html,x!=null){if(R.children!=null)throw Error(r(60));(L!=null?L.__html:void 0)!==x&&(f.innerHTML=x)}}break;case"multiple":f.multiple=k&&typeof k!="function"&&typeof k!="symbol";break;case"muted":f.muted=k&&typeof k!="function"&&typeof k!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(k==null||typeof k=="function"||typeof k=="boolean"||typeof k=="symbol"){f.removeAttribute("xlink:href");break}x=Gd(k),f.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",x);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":k!=null&&typeof k!="function"&&typeof k!="symbol"?f.setAttribute(x,k):f.removeAttribute(x);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"credentialless":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":k&&typeof k!="function"&&typeof k!="symbol"?f.setAttribute(x,""):f.removeAttribute(x);break;case"capture":case"download":k===!0?f.setAttribute(x,""):k!==!1&&k!=null&&typeof k!="function"&&typeof k!="symbol"?f.setAttribute(x,k):f.removeAttribute(x);break;case"cols":case"rows":case"size":case"span":k!=null&&typeof k!="function"&&typeof k!="symbol"&&!isNaN(k)&&1<=k?f.setAttribute(x,k):f.removeAttribute(x);break;case"rowSpan":case"start":k==null||typeof k=="function"||typeof k=="symbol"||isNaN(k)?f.removeAttribute(x):f.setAttribute(x,k);break;case"popover":jn("beforetoggle",f),jn("toggle",f),np(f,"popover",k);break;case"xlinkActuate":Da(f,"http://www.w3.org/1999/xlink","xlink:actuate",k);break;case"xlinkArcrole":Da(f,"http://www.w3.org/1999/xlink","xlink:arcrole",k);break;case"xlinkRole":Da(f,"http://www.w3.org/1999/xlink","xlink:role",k);break;case"xlinkShow":Da(f,"http://www.w3.org/1999/xlink","xlink:show",k);break;case"xlinkTitle":Da(f,"http://www.w3.org/1999/xlink","xlink:title",k);break;case"xlinkType":Da(f,"http://www.w3.org/1999/xlink","xlink:type",k);break;case"xmlBase":Da(f,"http://www.w3.org/XML/1998/namespace","xml:base",k);break;case"xmlLang":Da(f,"http://www.w3.org/XML/1998/namespace","xml:lang",k);break;case"xmlSpace":Da(f,"http://www.w3.org/XML/1998/namespace","xml:space",k);break;case"is":np(f,"is",k);break;case"innerText":case"textContent":return;default:if(!(2<x.length)||x[0]!=="o"&&x[0]!=="O"||x[1]!=="n"&&x[1]!=="N")x=Zg.get(x)||x,np(f,x,k);else return}En=!0}function D5(f,p,x,k,R,L){switch(x){case"style":bu(f,k,L);return;case"dangerouslySetInnerHTML":if(k!=null){if(typeof k!="object"||!("__html"in k))throw Error(r(61));if(x=k.__html,x!=null){if(R.children!=null)throw Error(r(60));(L!=null?L.__html:void 0)!==x&&(f.innerHTML=x)}}break;case"children":if(typeof k=="string")za(f,k);else if(typeof k=="number"||typeof k=="bigint")za(f,""+k);else return;break;case"onScroll":k!=null&&jn("scroll",f);return;case"onScrollEnd":k!=null&&jn("scrollend",f);return;case"onClick":k!=null&&(f.onclick=_s);return;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":return;case"innerText":case"textContent":return;default:if(!fs.hasOwnProperty(x))e:{if(x[0]==="o"&&x[1]==="n"&&(R=x.endsWith("Capture"),L=x.slice(2,R?x.length-7:void 0),p=f[Te]||null,p=p!=null?p[x]:null,typeof p=="function"&&f.removeEventListener(L,p,R),typeof k=="function")){typeof p!="function"&&p!==null&&(x in f?f[x]=null:f.hasAttribute(x)&&f.removeAttribute(x)),f.addEventListener(L,k,R);break e}En=!0,x in f?f[x]=k:k===!0?f.setAttribute(x,""):np(f,x,k)}return}En=!0}function Ko(f,p,x){switch(p){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":jn("error",f),jn("load",f);var k=!1,R=!1,L;for(L in x)if(x.hasOwnProperty(L)){var V=x[L];if(V!=null)switch(L){case"src":k=!0;break;case"srcSet":R=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(r(137,p));default:Tr(f,p,L,V,x,null)}}R&&Tr(f,p,"srcSet",x.srcSet,x,null),k&&Tr(f,p,"src",x.src,x,null);return;case"input":jn("invalid",f);var oe=L=V=R=null,ye=null,Ne=null;for(k in x)if(x.hasOwnProperty(k)){var ze=x[k];if(ze!=null)switch(k){case"name":R=ze;break;case"type":V=ze;break;case"checked":ye=ze;break;case"defaultChecked":Ne=ze;break;case"value":L=ze;break;case"defaultValue":oe=ze;break;case"children":case"dangerouslySetInnerHTML":if(ze!=null)throw Error(r(137,p));break;default:Tr(f,p,k,ze,x,null)}}Vb(f,L,oe,ye,Ne,V,R,!1);return;case"select":jn("invalid",f),k=V=L=null;for(R in x)if(x.hasOwnProperty(R)&&(oe=x[R],oe!=null))switch(R){case"value":L=oe;break;case"defaultValue":V=oe;break;case"multiple":k=oe;default:Tr(f,p,R,oe,x,null)}p=L,x=V,f.multiple=!!k,p!=null?gl(f,!!k,p,!1):x!=null&&gl(f,!!k,x,!0);return;case"textarea":jn("invalid",f),L=R=k=null;for(V in x)if(x.hasOwnProperty(V)&&(oe=x[V],oe!=null))switch(V){case"value":k=oe;break;case"defaultValue":R=oe;break;case"children":L=oe;break;case"dangerouslySetInnerHTML":if(oe!=null)throw Error(r(91));break;default:Tr(f,p,V,oe,x,null)}Qg(f,k,R,L);return;case"option":for(ye in x)if(x.hasOwnProperty(ye)&&(k=x[ye],k!=null))switch(ye){case"selected":f.selected=k&&typeof k!="function"&&typeof k!="symbol";break;default:Tr(f,p,ye,k,x,null)}return;case"dialog":jn("beforetoggle",f),jn("toggle",f),jn("cancel",f),jn("close",f);break;case"iframe":case"object":jn("load",f);break;case"video":case"audio":for(k=0;k<KS.length;k++)jn(KS[k],f);break;case"image":jn("error",f),jn("load",f);break;case"details":jn("toggle",f);break;case"embed":case"source":case"link":jn("error",f),jn("load",f);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(Ne in x)if(x.hasOwnProperty(Ne)&&(k=x[Ne],k!=null))switch(Ne){case"children":case"dangerouslySetInnerHTML":throw Error(r(137,p));default:Tr(f,p,Ne,k,x,null)}return;default:if(ip(p)){for(ze in x)x.hasOwnProperty(ze)&&(k=x[ze],k!==void 0&&D5(f,p,ze,k,x,void 0));return}}for(oe in x)x.hasOwnProperty(oe)&&(k=x[oe],k!=null&&Tr(f,p,oe,k,x,null))}var h5e={};function p5e(f,p,x,k){switch(p){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var R=null,L=null,V=null,oe=null,ye=null,Ne=null,ze=null;for(je in x){var Ge=x[je];if(x.hasOwnProperty(je)&&Ge!=null)switch(je){case"checked":break;case"value":break;case"defaultValue":ye=Ge;default:k.hasOwnProperty(je)||Tr(f,p,je,null,k,Ge)}}for(var Re in k){var je=k[Re];if(Ge=x[Re],k.hasOwnProperty(Re)&&(je!=null||Ge!=null))switch(Re){case"type":je!==Ge&&(En=!0),L=je;break;case"name":je!==Ge&&(En=!0),R=je;break;case"checked":je!==Ge&&(En=!0),Ne=je;break;case"defaultChecked":je!==Ge&&(En=!0),ze=je;break;case"value":je!==Ge&&(En=!0),V=je;break;case"defaultValue":je!==Ge&&(En=!0),oe=je;break;case"children":case"dangerouslySetInnerHTML":if(je!=null)throw Error(r(137,p));break;default:je!==Ge&&Tr(f,p,Re,je,k,Ge)}}rp(f,V,oe,ye,Ne,ze,L,R);return;case"select":je=V=oe=Re=null;for(L in x)if(ye=x[L],x.hasOwnProperty(L)&&ye!=null)switch(L){case"value":break;case"multiple":je=ye;default:k.hasOwnProperty(L)||Tr(f,p,L,null,k,ye)}for(R in k)if(L=k[R],ye=x[R],k.hasOwnProperty(R)&&(L!=null||ye!=null))switch(R){case"value":L!==ye&&(En=!0),Re=L;break;case"defaultValue":L!==ye&&(En=!0),oe=L;break;case"multiple":L!==ye&&(En=!0),V=L;default:L!==ye&&Tr(f,p,R,L,k,ye)}p=oe,x=V,k=je,Re!=null?gl(f,!!x,Re,!1):!!k!=!!x&&(p!=null?gl(f,!!x,p,!0):gl(f,!!x,x?[]:"",!1));return;case"textarea":je=Re=null;for(oe in x)if(R=x[oe],x.hasOwnProperty(oe)&&R!=null&&!k.hasOwnProperty(oe))switch(oe){case"value":break;case"children":break;default:Tr(f,p,oe,null,k,R)}for(V in k)if(R=k[V],L=x[V],k.hasOwnProperty(V)&&(R!=null||L!=null))switch(V){case"value":R!==L&&(En=!0),Re=R;break;case"defaultValue":R!==L&&(En=!0),je=R;break;case"children":break;case"dangerouslySetInnerHTML":if(R!=null)throw Error(r(91));break;default:R!==L&&Tr(f,p,V,R,k,L)}Wd(f,Re,je);return;case"option":for(var vt in x)if(Re=x[vt],x.hasOwnProperty(vt)&&Re!=null&&!k.hasOwnProperty(vt))switch(vt){case"selected":f.selected=!1;break;default:Tr(f,p,vt,null,k,Re)}for(ye in k)if(Re=k[ye],je=x[ye],k.hasOwnProperty(ye)&&Re!==je&&(Re!=null||je!=null))switch(ye){case"selected":Re!==je&&(En=!0),f.selected=Re&&typeof Re!="function"&&typeof Re!="symbol";break;default:Tr(f,p,ye,Re,k,je)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var jt in x)Re=x[jt],x.hasOwnProperty(jt)&&Re!=null&&!k.hasOwnProperty(jt)&&Tr(f,p,jt,null,k,Re);for(Ne in k)if(Re=k[Ne],je=x[Ne],k.hasOwnProperty(Ne)&&Re!==je&&(Re!=null||je!=null))switch(Ne){case"children":case"dangerouslySetInnerHTML":if(Re!=null)throw Error(r(137,p));break;default:Tr(f,p,Ne,Re,k,je)}return;default:if(ip(p)){for(var gn in x)Re=x[gn],x.hasOwnProperty(gn)&&Re!==void 0&&!k.hasOwnProperty(gn)&&D5(f,p,gn,void 0,k,Re);for(ze in k)Re=k[ze],je=x[ze],!k.hasOwnProperty(ze)||Re===je||Re===void 0&&je===void 0||D5(f,p,ze,Re,k,je);return}}for(var Me in x)Re=x[Me],x.hasOwnProperty(Me)&&Re!=null&&!k.hasOwnProperty(Me)&&Tr(f,p,Me,null,k,Re);for(Ge in k)Re=k[Ge],je=x[Ge],!k.hasOwnProperty(Ge)||Re===je||Re==null&&je==null||Tr(f,p,Ge,Re,k,je)}function Jee(f){switch(f){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function m5e(){if(typeof performance.getEntriesByType=="function"){for(var f=0,p=0,x=performance.getEntriesByType("resource"),k=0;k<x.length;k++){var R=x[k],L=R.transferSize,V=R.initiatorType,oe=R.duration;if(L&&oe&&Jee(V)){for(V=0,oe=R.responseEnd,k+=1;k<x.length;k++){var ye=x[k],Ne=ye.startTime;if(Ne>oe)break;var ze=ye.transferSize,Ge=ye.initiatorType;ze&&Jee(Ge)&&(ye=ye.responseEnd,V+=ze*(ye<oe?1:(oe-Ne)/(ye-Ne)))}if(--k,p+=8*(L+V)/(R.duration/1e3),f++,10<f)break}}if(0<f)return p/f/1e6}return navigator.connection&&(f=navigator.connection.downlink,typeof f=="number")?f:5}var $5=null,z5=null;function XS(f){return f.nodeType===9?f:f.ownerDocument}function ete(f){switch(f){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function tte(f,p){if(f===0)switch(p){case"svg":return 1;case"math":return 2;default:return 0}return f===1&&p==="foreignObject"?0:f}function nte(f,p,x,k){return x=XS(x).createElement(f),x[Hr]=k,x[Te]=p,Ko(x,f,p),si(x),x}function F5(f,p){return f==="textarea"||f==="noscript"||typeof p.children=="string"||typeof p.children=="number"||typeof p.children=="bigint"||typeof p.dangerouslySetInnerHTML=="object"&&p.dangerouslySetInnerHTML!==null&&p.dangerouslySetInnerHTML.__html!=null}var B5=null;function g5e(){var f=window.event;return f&&f.type==="popstate"?f===B5?!1:(B5=f,!0):(B5=null,!1)}var H5=typeof setTimeout=="function"?setTimeout:void 0,y5e=typeof clearTimeout=="function"?clearTimeout:void 0,rte=typeof Promise=="function"?Promise:void 0,ite=typeof requestAnimationFrame=="function"?requestAnimationFrame:H5,b5e=typeof queueMicrotask=="function"?queueMicrotask:typeof rte<"u"?function(f){return rte.resolve(null).then(f).catch(v5e)}:H5;function v5e(f){setTimeout(function(){throw f})}function Ep(f){return f==="head"}function ote(f,p){var x=p,k=0;do{var R=x.nextSibling;if(f.removeChild(x),R&&R.nodeType===8)if(x=R.data,x==="/$"||x==="/&"){if(k===0){f.removeChild(R),Av(p);return}k--}else if(x==="$"||x==="$?"||x==="$~"||x==="$!"||x==="&")k++;else if(x==="html")X5(f.ownerDocument.documentElement);else if(x==="head"){x=f.ownerDocument.head,X5(x);for(var L=x.firstChild;L;){var V=L.nextSibling,oe=L.nodeName;L[rr]||oe==="SCRIPT"||oe==="STYLE"||oe==="LINK"&&L.rel.toLowerCase()==="stylesheet"||x.removeChild(L),L=V}}else x==="body"&&X5(f.ownerDocument.body);x=R}while(x);Av(p)}function ste(f,p){var x=f;f=0;do{var k=x.nextSibling;if(x.nodeType===1?p?(x._stashedDisplay=x.style.display,x.style.display="none"):(x.style.display=x._stashedDisplay||"",x.getAttribute("style")===""&&x.removeAttribute("style")):x.nodeType===3&&(p?(x._stashedText=x.nodeValue,x.nodeValue=""):x.nodeValue=x._stashedText||""),k&&k.nodeType===8)if(x=k.data,x==="/$"){if(f===0)break;f--}else x!=="$"&&x!=="$?"&&x!=="$~"&&x!=="$!"||f++;x=k}while(x)}function ate(f,p,x){if(p=CSS.escape(p)!==p?"r-"+btoa(p).replace(/=/g,""):p,f.style.viewTransitionName=p,x!=null&&(f.style.viewTransitionClass=x),x=getComputedStyle(f),x.display==="inline"){if(p=f.getClientRects(),p.length===1)var k=1;else for(var R=k=0;R<p.length;R++){var L=p[R];0<L.width&&0<L.height&&k++}k===1&&(f=f.style,f.display=p.length===1?"inline-block":"block",f.marginTop="-"+x.paddingTop,f.marginBottom="-"+x.paddingBottom)}}function lte(f,p){f=f.style,p=p.style;var x=p!=null?p.hasOwnProperty("viewTransitionName")?p.viewTransitionName:p.hasOwnProperty("view-transition-name")?p["view-transition-name"]:null:null;f.viewTransitionName=x==null||typeof x=="boolean"?"":(""+x).trim(),x=p!=null?p.hasOwnProperty("viewTransitionClass")?p.viewTransitionClass:p.hasOwnProperty("view-transition-class")?p["view-transition-class"]:null:null,f.viewTransitionClass=x==null||typeof x=="boolean"?"":(""+x).trim(),f.display==="inline-block"&&(p==null?f.display=f.margin="":(x=p.display,f.display=x==null||typeof x=="boolean"?"":x,x=p.margin,x!=null?f.margin=x:(x=p.hasOwnProperty("marginTop")?p.marginTop:p["margin-top"],f.marginTop=x==null||typeof x=="boolean"?"":x,p=p.hasOwnProperty("marginBottom")?p.marginBottom:p["margin-bottom"],f.marginBottom=p==null||typeof p=="boolean"?"":p)))}function x5e(f,p,x){return x=x.ownerDocument.defaultView,{rect:f,abs:p.position==="absolute"||p.position==="fixed",clip:p.clipPath!=="none"||p.overflow!=="visible"||p.filter!=="none"||p.mask!=="none"||p.mask!=="none"||p.borderRadius!=="0px",view:0<=f.bottom&&0<=f.right&&f.top<=x.innerHeight&&f.left<=x.innerWidth}}function U5(f){var p=f.getBoundingClientRect(),x=getComputedStyle(f);return x5e(p,x,f)}function w5e(f){return f.documentElement.clientHeight}function S5e(f){this.addEventListener("load",f),this.addEventListener("error",f)}function k5e(f,p,x,k,R,L,V,oe,ye){var Ne=p.nodeType===9?p:p.ownerDocument;try{var ze=Ne.startViewTransition({update:function(){var Re=Ne.defaultView,je=Re.navigation&&Re.navigation.transition,vt=Ne.fonts.status;k();var jt=[];if(vt==="loaded"&&(w5e(Ne),Ne.fonts.status==="loading"&&jt.push(Ne.fonts.ready)),vt=jt.length,f!==null)for(var gn=f.suspenseyImages,Me=0,Ce=0;Ce<gn.length;Ce++){var Pe=gn[Ce];if(!Pe.complete){var qe=Pe.getBoundingClientRect();if(0<qe.bottom&&0<qe.right&&qe.top<Re.innerHeight&&qe.left<Re.innerWidth){if(Me+=Rte(Pe),Me>DO){jt.length=vt;break}Pe=new Promise(S5e.bind(Pe)),jt.push(Pe)}}}if(0<jt.length)return Re=Promise.race([Promise.all(jt),new Promise(function(Tt){return setTimeout(Tt,500)})]).then(R,R),(je?Promise.allSettled([je.finished,Re]):Re).then(L,L);if(R(),je)return je.finished.then(L,L);L()},types:x});Ne.__reactViewTransition=ze;var Ge=[];return ze.ready.then(function(){for(var Re=Ne.documentElement.getAnimations({subtree:!0}),je=0;je<Re.length;je++){var vt=Re[je],jt=vt.effect,gn=jt.pseudoElement;if(gn!=null&&gn.startsWith("::view-transition")){Ge.push(vt),vt=jt.getKeyframes();for(var Me=gn=void 0,Ce=!0,Pe=0;Pe<vt.length;Pe++){var qe=vt[Pe],Tt=qe.width;if(gn===void 0)gn=Tt;else if(gn!==Tt){Ce=!1;break}if(Tt=qe.height,Me===void 0)Me=Tt;else if(Me!==Tt){Ce=!1;break}delete qe.width,delete qe.height,qe.transform==="none"&&delete qe.transform}Ce&&gn!==void 0&&Me!==void 0&&(jt.setKeyframes(vt),Ce=getComputedStyle(jt.target,jt.pseudoElement),Ce.width!==gn||Ce.height!==Me)&&(Ce=vt[0],Ce.width=gn,Ce.height=Me,Ce=vt[vt.length-1],Ce.width=gn,Ce.height=Me,jt.setKeyframes(vt))}}V()},function(Re){Ne.__reactViewTransition===ze&&(Ne.__reactViewTransition=null);try{if(typeof Re=="object"&&Re!==null)switch(Re.name){case"InvalidStateError":(Re.message==="View transition was skipped because document visibility state is hidden."||Re.message==="Skipping view transition because document visibility state has become hidden."||Re.message==="Skipping view transition because viewport size changed."||Re.message==="Transition was aborted because of invalid state")&&(Re=null)}Re!==null&&ye(Re)}finally{k(),R(),V()}}),ze.finished.finally(function(){for(var Re=0;Re<Ge.length;Re++)Ge[Re].cancel();Ne.__reactViewTransition===ze&&(Ne.__reactViewTransition=null),oe()}),ze}catch{return k(),R(),V(),null}}function k0(f,p){this._scope=document.documentElement,this._selector="::view-transition-"+f+"("+p+")"}k0.prototype.animate=function(f,p){return p=typeof p=="number"?{duration:p}:M({},p),p.pseudoElement=this._selector,this._scope.animate(f,p)},k0.prototype.getAnimations=function(){for(var f=this._scope,p=this._selector,x=f.getAnimations({subtree:!0}),k=[],R=0;R<x.length;R++){var L=x[R].effect;L!==null&&L.target===f&&L.pseudoElement===p&&k.push(x[R])}return k},k0.prototype.getComputedStyle=function(){return getComputedStyle(this._scope,this._selector)};function ute(f){return{name:f,group:new k0("group",f),imagePair:new k0("image-pair",f),old:new k0("old",f),new:new k0("new",f)}}function qa(f){this._fragmentFiber=f,this._observers=this._eventListeners=null}qa.prototype.addEventListener=function(f,p,x){var k=null,R=null;if(!(x!=null&&typeof x!="boolean"&&(k=x.signal||null,k!==null&&k.aborted))){this._eventListeners===null&&(this._eventListeners=[]);var L=this._eventListeners;if(dte(L,f,p,x)===-1){var V=this,oe=p;x!=null&&typeof x!="boolean"&&x.once===!0&&(oe=function(ye){V.removeEventListener(f,p,x),typeof p=="function"?p.call(this,ye):p.handleEvent(ye)}),k!==null&&(R=V.removeEventListener.bind(V,f,p,x),k.addEventListener("abort",R,{once:!0}),R=k.removeEventListener.bind(k,"abort",R)),k=wv(x),L.push({type:f,listener:p,optionsOrUseCapture:x,attachedListener:oe,cleanup:R}),d(this._fragmentFiber.child,!1,C5e,f,oe,k)}this._eventListeners=L}};function C5e(f,p,x,k){return v(f).addEventListener(p,x,k),!1}qa.prototype.removeEventListener=function(f,p,x){var k=this._eventListeners;if(k!==null&&(p=dte(k,f,p,x),p!==-1)){var R=k[p];x=R.attachedListener;var L=R.cleanup;R=wv(R.optionsOrUseCapture),d(this._fragmentFiber.child,!1,E5e,f,x,R),k.splice(p,1),L!==null&&L()}};function E5e(f,p,x,k){return v(f).removeEventListener(p,x,k),!1}function wv(f){return f!=null&&typeof f!="boolean"&&(f.once===!0||f.signal instanceof AbortSignal)?{capture:f.capture,passive:f.passive}:f}function cte(f){return f==null?"c=0":typeof f=="boolean"?"c="+(f?"1":"0"):"c="+(f.capture?"1":"0")}function dte(f,p,x,k){if(f.length===0)return-1;k=cte(k);for(var R=0;R<f.length;R++){var L=f[R];if(L.type===p&&L.listener===x&&cte(L.optionsOrUseCapture)===k)return R}return-1}qa.prototype.dispatchEvent=function(f){var p=h(this._fragmentFiber);if(p===null)return!0;p=v(p);var x=this._eventListeners;if(x!==null&&0<x.length||!f.bubbles){var k=p.nodeType===9?p.createComment(""):document.createTextNode("");if(x)for(var R=0;R<x.length;R++){var L=x[R];k.addEventListener(L.type,L.attachedListener,wv(L.optionsOrUseCapture))}if(p.appendChild(k),f=k.dispatchEvent(f),x)for(R=0;R<x.length;R++)L=x[R],k.removeEventListener(L.type,L.attachedListener,wv(L.optionsOrUseCapture));return p.removeChild(k),f}return p.dispatchEvent(f)},qa.prototype.focus=function(f){d(this._fragmentFiber.child,!0,fte,f,void 0,void 0)};function fte(f,p){return f.tag===6?!1:(f=v(f),D5e(f,p))}qa.prototype.focusLast=function(f){var p=[];d(this._fragmentFiber.child,!0,V5,p,void 0,void 0);for(var x=p.length-1;0<=x&&!fte(p[x],f);x--);};function V5(f,p){return p.push(f),!1}qa.prototype.blur=function(){var f=h(this._fragmentFiber);f!==null&&(f=v(f),f=XS(f).activeElement,f!==null&&d(this._fragmentFiber.child,!1,T5e,f,void 0,void 0))};function T5e(f,p){return f.tag===6?!1:(f=v(f),f===p||f.contains(p)?(p.blur(),!0):!1)}qa.prototype.observeUsing=function(f){this._observers===null&&(this._observers=new Set),this._observers.add(f),d(this._fragmentFiber.child,!1,A5e,f,void 0,void 0)};function A5e(f,p){return f.tag===6||(f=v(f),p.observe(f)),!1}qa.prototype.unobserveUsing=function(f){var p=this._observers;if(p!==null&&p.has(f)){p.delete(f),d(this._fragmentFiber.child,!1,O5e,f,void 0,void 0);for(var x=p=0;x<Cu.length;x++){var k=Cu[x];k.fragmentInstance===this&&k.observer===f?f.unobserve(k.instance):Cu[p++]=k}Cu.length=p}};function O5e(f,p){return f.tag===6||(f=v(f),p.unobserve(f)),!1}var Cu=[],W5=!1;function R5e(f,p,x){Cu.push({fragmentInstance:f,observer:p,instance:x}),W5||(W5=!0,$5e(function(){W5=!1;var k=Cu;Cu=[];for(var R=0;R<k.length;R++){var L=k[R];L.observer.unobserve(L.instance)}}))}qa.prototype.getClientRects=function(){var f=[];return d(this._fragmentFiber.child,!1,M5e,f,void 0,void 0),f};function M5e(f,p){if(f.tag===6){f=f.stateNode;var x=f.ownerDocument.createRange();x.selectNodeContents(f),p.push.apply(p,x.getClientRects())}else f=v(f),p.push.apply(p,f.getClientRects());return!1}qa.prototype.getRootNode=function(f){var p=h(this._fragmentFiber);return p===null?this:v(p).getRootNode(f)},qa.prototype.compareDocumentPosition=function(f){var p=h(this._fragmentFiber);if(p===null)return Node.DOCUMENT_POSITION_DISCONNECTED;var x=[];d(this._fragmentFiber.child,!1,V5,x,void 0,void 0);var k=v(p);if(x.length===0){if(x=k,m(this._fragmentFiber)){e:{for(p=this._fragmentFiber.return;p!==null;){if(p.tag===4){p=p.stateNode.containerInfo;break e}if(p.tag===3||p.tag===5||p.tag===27)break;p=p.return}p=null}p!=null&&(x=p)}p=this._fragmentFiber;var R=k=x.compareDocumentPosition(f);return x===f?R=Node.DOCUMENT_POSITION_CONTAINS:k&Node.DOCUMENT_POSITION_CONTAINED_BY&&(x=g(p)[1],x===null?R=Node.DOCUMENT_POSITION_PRECEDING:(f=v(x).compareDocumentPosition(f),R=f===0||f&Node.DOCUMENT_POSITION_FOLLOWING?Node.DOCUMENT_POSITION_FOLLOWING:Node.DOCUMENT_POSITION_PRECEDING)),R|=Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC}p=v(x[0]),R=v(x[x.length-1]);var L=m(this._fragmentFiber)?p.parentElement:k;if(L==null)return Node.DOCUMENT_POSITION_DISCONNECTED;k=L.compareDocumentPosition(p)&Node.DOCUMENT_POSITION_CONTAINED_BY,L=L.compareDocumentPosition(R)&Node.DOCUMENT_POSITION_CONTAINED_BY;var V=p.compareDocumentPosition(f),oe=R.compareDocumentPosition(f),ye=V&Node.DOCUMENT_POSITION_CONTAINED_BY||oe&Node.DOCUMENT_POSITION_CONTAINED_BY;return oe=k&&L&&V&Node.DOCUMENT_POSITION_FOLLOWING&&oe&Node.DOCUMENT_POSITION_PRECEDING,p=k&&p===f||L&&R===f||ye||oe?Node.DOCUMENT_POSITION_CONTAINED_BY:!k&&p===f||!L&&R===f?Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC:V,p&Node.DOCUMENT_POSITION_DISCONNECTED||p&Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC||_5e(p,this._fragmentFiber,x[0],x[x.length-1],f)?p:Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC};function _5e(f,p,x,k,R){var L=ia(R);if(f&Node.DOCUMENT_POSITION_CONTAINED_BY){if(x=!!L)e:{for(;L!==null;){if(L.tag===7&&(L===p||L.alternate===p)){x=!0;break e}L=L.return}x=!1}return x}if(f&Node.DOCUMENT_POSITION_CONTAINS){if(L===null)return L=R.ownerDocument,R===L||R===L.documentElement||R===L.body;e:{for(L=p,p=h(p);L!==null;){if(!(L.tag!==5&&L.tag!==3&&L.tag!==27||L!==p&&L.alternate!==p)){L=!0;break e}L=L.return}L=!1}return L}return f&Node.DOCUMENT_POSITION_PRECEDING?((p=!!L)&&!(p=L===x)&&(p=O(x,L,T),p===null?p=!1:(d(p,!0,C,L,x),L=w,w=null,p=L!==null)),p):f&Node.DOCUMENT_POSITION_FOLLOWING?((p=!!L)&&!(p=L===k)&&(p=O(k,L,T),p===null?p=!1:(d(p,!0,E,L,k),L=w,S=w=null,p=L!==null)),p):!1}function hte(f,p){var x=f.ownerDocument.createRange();x.selectNodeContents(f),f=x.getBoundingClientRect(),window.scrollTo(window.scrollX+f.left,p?window.scrollY+f.top:window.scrollY+f.bottom-window.innerHeight)}qa.prototype.scrollIntoView=function(f){if(typeof f=="object")throw Error(r(566));var p=[];d(this._fragmentFiber.child,!1,V5,p,void 0,void 0);var x=f!==!1;if(p.length===0){var k=g(this._fragmentFiber);if(k=x?k[1]||k[0]||h(this._fragmentFiber):k[0]||k[1],k===null)return;if(k.tag===6){f=v(k),hte(f,x);return}if(k=v(k),k.nodeType!==9){if(k.nodeType===11){x="host"in k?k.host:null,x!==null&&x.scrollIntoView(f);return}k.scrollIntoView(f)}}for(k=x?p.length-1:0;k!==(x?-1:p.length);){var R=p[k];R.tag===6?(R=v(R),hte(R,x)):v(R).scrollIntoView(f),k+=x?-1:1}};function N5e(f,p){return f=v(f),pte(f,p),!1}function pte(f,p){f.reactFragments==null&&(f.reactFragments=new Set),f.reactFragments.add(p)}function mte(f,p){var x=p._eventListeners;if(x!==null)for(var k=0;k<x.length;k++){var R=x[k];f.addEventListener(R.type,R.attachedListener,wv(R.optionsOrUseCapture))}f.nodeType!==3&&(x=p._observers,x!==null&&x.forEach(function(L){for(var V=0,oe=0;oe<Cu.length;oe++){var ye=Cu[oe];(ye.fragmentInstance!==p||ye.observer!==L||ye.instance!==f)&&(Cu[V++]=ye)}Cu.length=V,L.observe(f)}),pte(f,p))}function L5e(f,p){var x=p._eventListeners;if(x!==null)for(var k=0;k<x.length;k++){var R=x[k];f.removeEventListener(R.type,R.attachedListener,wv(R.optionsOrUseCapture))}f.nodeType!==3&&(x=p._observers,x!==null&&x.forEach(function(L){typeof L.rootMargin=="string"?R5e(p,L,f):L.unobserve(f)}),f.reactFragments!=null&&f.reactFragments.delete(p))}function q5(f){var p=f.firstChild;for(p&&p.nodeType===10&&(p=p.nextSibling);p;){var x=p;switch(p=p.nextSibling,x.nodeName){case"HTML":case"HEAD":case"BODY":q5(x),hc(x);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(x.rel.toLowerCase()==="stylesheet")continue}f.removeChild(x)}}function I5e(f,p,x,k){for(;f.nodeType===1;){var R=x;if(f.nodeName.toLowerCase()!==p.toLowerCase()){if(!k&&(f.nodeName!=="INPUT"||f.type!=="hidden"))break}else if(k){if(!f[rr])switch(p){case"meta":if(!f.hasAttribute("itemprop"))break;return f;case"link":if(L=f.getAttribute("rel"),L==="stylesheet"&&f.hasAttribute("data-precedence"))break;if(L!==R.rel||f.getAttribute("href")!==(R.href==null||R.href===""?null:R.href)||f.getAttribute("crossorigin")!==(R.crossOrigin==null?null:R.crossOrigin)||f.getAttribute("title")!==(R.title==null?null:R.title))break;return f;case"style":if(f.hasAttribute("data-precedence"))break;return f;case"script":if(L=f.getAttribute("src"),(L!==(R.src==null?null:R.src)||f.getAttribute("type")!==(R.type==null?null:R.type)||f.getAttribute("crossorigin")!==(R.crossOrigin==null?null:R.crossOrigin))&&L&&f.hasAttribute("async")&&!f.hasAttribute("itemprop"))break;return f;default:return f}}else if(p==="input"&&f.type==="hidden"){var L=R.name==null?null:""+R.name;if(R.type==="hidden"&&f.getAttribute("name")===L)return f}else return f;if(f=Cl(f.nextSibling),f===null)break}return null}function P5e(f,p,x){if(p==="")return null;for(;f.nodeType!==3;)if((f.nodeType!==1||f.nodeName!=="INPUT"||f.type!=="hidden")&&!x||(f=Cl(f.nextSibling),f===null))return null;return f}function gte(f,p){for(;f.nodeType!==8;)if((f.nodeType!==1||f.nodeName!=="INPUT"||f.type!=="hidden")&&!p||(f=Cl(f.nextSibling),f===null))return null;return f}function G5(f){return f.data==="$?"||f.data==="$~"}function K5(f){return f.data==="$!"||f.data==="$?"&&f.ownerDocument.readyState!=="loading"}function j5e(f,p){var x=f.ownerDocument;if(f.data==="$~")f._reactRetry=p;else if(f.data!=="$?"||x.readyState!=="loading")p();else{var k=function(){p(),x.removeEventListener("DOMContentLoaded",k)};x.addEventListener("DOMContentLoaded",k),f._reactRetry=k}}function Cl(f){for(;f!=null;f=f.nextSibling){var p=f.nodeType;if(p===1||p===3)break;if(p===8){if(p=f.data,p==="$"||p==="$!"||p==="$?"||p==="$~"||p==="&"||p==="F!"||p==="F")break;if(p==="/$"||p==="/&")return null}}return f}var Y5=null;function yte(f){f=f.nextSibling;for(var p=0;f;){if(f.nodeType===8){var x=f.data;if(x==="/$"||x==="/&"){if(p===0)return Cl(f.nextSibling);p--}else x!=="$"&&x!=="$!"&&x!=="$?"&&x!=="$~"&&x!=="&"||p++}f=f.nextSibling}return null}function bte(f){f=f.previousSibling;for(var p=0;f;){if(f.nodeType===8){var x=f.data;if(x==="$"||x==="$!"||x==="$?"||x==="$~"||x==="&"){if(p===0)return f;p--}else x!=="/$"&&x!=="/&"||p++}f=f.previousSibling}return null}function D5e(f,p){function x(){k=!0}if(f.ownerDocument.activeElement===f)return!0;var k=!1;try{f.ownerDocument.addEventListener("focus",x,!0),(f.focus||HTMLElement.prototype.focus).call(f,p)}finally{f.ownerDocument.removeEventListener("focus",x,!0)}return k}function $5e(f){ite(function(){ite(function(p){return f(p)})})}function vte(f,p,x){switch(p=XS(x),f){case"html":if(f=p.documentElement,!f)throw Error(r(452));return f;case"head":if(f=p.head,!f)throw Error(r(453));return f;case"body":if(f=p.body,!f)throw Error(r(454));return f;default:throw Error(r(451))}}function xte(f,p,x){for(var k in x){var R=x[k];x.hasOwnProperty(k)&&R!=null&&Tr(f,p,k,null,h5e,R)}x.dangerouslySetInnerHTML!=null&&(f.textContent=""),f.onclick===_s&&(f.onclick=null),hc(f)}function X5(f){for(var p=f.attributes;p.length;)f.removeAttributeNode(p[0]);hc(f)}var El=new Map,wte=new Set;function QS(f){if(typeof f.getRootNode=="function"){var p=f.getRootNode();if(p.nodeType===9||p.nodeType===11)return p}return f.nodeType===9?f:f.ownerDocument}var af=se.d;se.d={f:z5e,r:F5e,D:B5e,C:H5e,L:U5e,m:V5e,X:q5e,S:W5e,M:G5e};function z5e(){var f=af.f(),p=OO();return f||p}function F5e(f){var p=ml(f);p!==null&&p.tag===5&&p.type==="form"?kJ(p):af.r(f)}var Sv=typeof document>"u"?null:document;function Ste(f,p,x){var k=Sv;if(k&&typeof p=="string"&&p){var R=hs(p);R='link[rel="'+f+'"][href="'+R+'"]',typeof x=="string"&&(R+='[crossorigin="'+x+'"]'),wte.has(R)||(wte.add(R),f={rel:f,crossOrigin:x,href:p},k.querySelector(R)===null&&(p=k.createElement("link"),Ko(p,"link",f),si(p),k.head.appendChild(p)))}}function B5e(f){af.D(f),Ste("dns-prefetch",f,null)}function H5e(f,p){af.C(f,p),Ste("preconnect",f,p)}function U5e(f,p,x){af.L(f,p,x);var k=Sv;if(k&&f&&p){var R='link[rel="preload"][as="'+hs(p)+'"]';p==="image"&&x&&x.imageSrcSet?(R+='[imagesrcset="'+hs(x.imageSrcSet)+'"]',typeof x.imageSizes=="string"&&(R+='[imagesizes="'+hs(x.imageSizes)+'"]')):R+='[href="'+hs(f)+'"]';var L=R;switch(p){case"style":L=kv(f);break;case"script":L=Cv(f)}if(!(El.has(L)||(f=M({rel:"preload",href:p==="image"&&x&&x.imageSrcSet?void 0:f,as:p},x),El.set(L,f),k.querySelector(R)!==null||p==="style"&&k.querySelector(ZS(L))||p==="script"&&k.querySelector(JS(L))))){var V=k.createElement("link");Ko(V,"link",f),p==="style"&&(V[gi]=!0,V.onload=V.onerror=function(){pc(V)}),si(V),k.head.appendChild(V)}}}function V5e(f,p){af.m(f,p);var x=Sv;if(x&&f){var k=p&&typeof p.as=="string"?p.as:"script",R='link[rel="modulepreload"][as="'+hs(k)+'"][href="'+hs(f)+'"]',L=R;switch(k){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":L=Cv(f)}if(!El.has(L)&&(f=M({rel:"modulepreload",href:f},p),El.set(L,f),x.querySelector(R)===null)){switch(k){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(x.querySelector(JS(L)))return}k=x.createElement("link"),Ko(k,"link",f),si(k),x.head.appendChild(k)}}}function W5e(f,p,x){af.S(f,p,x);var k=Sv;if(k&&f){var R=ds(k).hoistableStyles,L=kv(f);p=p||"default";var V=R.get(L);if(!V){var oe={loading:0,preload:null};if(V=k.querySelector(ZS(L)))oe.loading=5;else{f=M({rel:"stylesheet",href:f,"data-precedence":p},x),(x=El.get(L))&&Q5(f,x);var ye=V=k.createElement("link");si(ye),Ko(ye,"link",f),ye._p=new Promise(function(Ne,ze){ye.onload=Ne,ye.onerror=ze}),ye.addEventListener("load",function(){oe.loading|=1}),ye.addEventListener("error",function(){oe.loading|=2}),oe.loading|=4,PO(V,p,k)}V={type:"stylesheet",instance:V,count:1,state:oe},R.set(L,V)}}}function q5e(f,p){af.X(f,p);var x=Sv;if(x&&f){var k=ds(x).hoistableScripts,R=Cv(f),L=k.get(R);L||(L=x.querySelector(JS(R)),L||(f=M({src:f,async:!0},p),(p=El.get(R))&&Z5(f,p),L=x.createElement("script"),si(L),Ko(L,"link",f),x.head.appendChild(L)),L={type:"script",instance:L,count:1,state:null},k.set(R,L))}}function G5e(f,p){af.M(f,p);var x=Sv;if(x&&f){var k=ds(x).hoistableScripts,R=Cv(f),L=k.get(R);L||(L=x.querySelector(JS(R)),L||(f=M({src:f,async:!0,type:"module"},p),(p=El.get(R))&&Z5(f,p),L=x.createElement("script"),si(L),Ko(L,"link",f),x.head.appendChild(L)),L={type:"script",instance:L,count:1,state:null},k.set(R,L))}}function kte(f,p,x,k){var R=(R=ge.current)?QS(R):null;if(!R)throw Error(r(446));switch(f){case"meta":case"title":return null;case"style":return typeof x.precedence=="string"&&typeof x.href=="string"?(x=kv(x.href),p=ds(R).hoistableStyles,k=p.get(x),k||(k={type:"style",instance:null,count:0,state:null},p.set(x,k)),k):{type:"void",instance:null,count:0,state:null};case"link":if(x.rel==="stylesheet"&&typeof x.href=="string"&&typeof x.precedence=="string"){f=kv(x.href);var L=ds(R).hoistableStyles,V=L.get(f);if(V||(R=R.ownerDocument||R,V={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},L.set(f,V),(L=R.querySelector(ZS(f)))?L._p||(V.instance=L,V.state.loading=5):(L=El.get(f),L||(L={rel:"preload",as:"style",href:x.href,crossOrigin:x.crossOrigin,integrity:x.integrity,media:x.media,hrefLang:x.hrefLang,referrerPolicy:x.referrerPolicy},El.set(f,L)),K5e(R,f,L,V.state))),p&&k===null)throw Error(r(528,""));return V}if(p&&k!==null)throw Error(r(529,""));return null;case"script":return p=x.async,x=x.src,typeof x=="string"&&p&&typeof p!="function"&&typeof p!="symbol"?(x=Cv(x),p=ds(R).hoistableScripts,k=p.get(x),k||(k={type:"script",instance:null,count:0,state:null},p.set(x,k)),k):{type:"void",instance:null,count:0,state:null};default:throw Error(r(444,f))}}function kv(f){return'href="'+hs(f)+'"'}function ZS(f){return'link[rel="stylesheet"]['+f+"]"}function Cte(f){return M({},f,{"data-precedence":f.precedence,precedence:null})}function K5e(f,p,x,k){if(p=f.querySelector('link[rel="preload"][as="style"]['+p+"]")){if(p[gi]!==!0){k.loading=1;return}}else p=f.createElement("link"),p[gi]=!0,p.onload=p.onerror=pc.bind(null,p),Ko(p,"link",x),si(p),f.head.appendChild(p);k.preload=p,p.addEventListener("load",function(){return k.loading|=1}),p.addEventListener("error",function(){return k.loading|=2})}function Cv(f){return'[src="'+hs(f)+'"]'}function JS(f){return"script[async]"+f}function Ete(f,p,x){if(p.count++,p.instance===null)switch(p.type){case"style":var k=f.querySelector('style[data-href~="'+hs(x.href)+'"]');if(k)return p.instance=k,si(k),k;var R=M({},x,{"data-href":x.href,"data-precedence":x.precedence,href:null,precedence:null});return k=(f.ownerDocument||f).createElement("style"),si(k),Ko(k,"style",R),PO(k,x.precedence,f),p.instance=k;case"stylesheet":R=kv(x.href);var L=f.querySelector(ZS(R));if(L)return p.state.loading|=4,p.instance=L,si(L),L;k=Cte(x),(R=El.get(R))&&Q5(k,R),L=(f.ownerDocument||f).createElement("link"),si(L);var V=L;return V._p=new Promise(function(oe,ye){V.onload=oe,V.onerror=ye}),Ko(L,"link",k),p.state.loading|=4,PO(L,x.precedence,f),p.instance=L;case"script":return L=Cv(x.src),(R=f.querySelector(JS(L)))?(p.instance=R,si(R),R):(k=x,(R=El.get(L))&&(k=M({},x),Z5(k,R)),f=f.ownerDocument||f,R=f.createElement("script"),si(R),Ko(R,"link",k),f.head.appendChild(R),p.instance=R);case"void":return null;default:throw Error(r(443,p.type))}else p.type==="stylesheet"&&(p.state.loading&4)===0&&(k=p.instance,p.state.loading|=4,PO(k,x.precedence,f));return p.instance}function PO(f,p,x){for(var k=x.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),R=k.length?k[k.length-1]:null,L=R,V=0;V<k.length;V++){var oe=k[V];if(oe.dataset.precedence===p)L=oe;else if(L!==R)break}L?L.parentNode.insertBefore(f,L.nextSibling):(p=x.nodeType===9?x.head:x,p.insertBefore(f,p.firstChild))}function Q5(f,p){f.crossOrigin==null&&(f.crossOrigin=p.crossOrigin),f.referrerPolicy==null&&(f.referrerPolicy=p.referrerPolicy),f.title==null&&(f.title=p.title)}function Z5(f,p){f.crossOrigin==null&&(f.crossOrigin=p.crossOrigin),f.referrerPolicy==null&&(f.referrerPolicy=p.referrerPolicy),f.integrity==null&&(f.integrity=p.integrity)}var jO=null;function Tte(f,p,x){if(jO===null){var k=new Map,R=jO=new Map;R.set(x,k)}else R=jO,k=R.get(x),k||(k=new Map,R.set(x,k));if(k.has(f))return k;for(k.set(f,null),x=x.getElementsByTagName(f),R=0;R<x.length;R++){var L=x[R];if(!(L[rr]||L[Hr]||f==="link"&&L.getAttribute("rel")==="stylesheet")&&L.namespaceURI!=="http://www.w3.org/2000/svg"){var V=L.getAttribute(p)||"";V=f+V;var oe=k.get(V);oe?oe.push(L):k.set(V,[L])}}return k}function J5(f,p,x){f=f.ownerDocument||f,f.head.insertBefore(x,p==="title"?f.querySelector("head > title"):null)}function Y5e(f,p,x){if(x===1||p.itemProp!=null)return!1;switch(f){case"meta":case"title":return!0;case"style":if(typeof p.precedence!="string"||typeof p.href!="string"||p.href==="")break;return!0;case"link":if(typeof p.rel!="string"||typeof p.href!="string"||p.href===""||p.onLoad||p.onError)break;switch(p.rel){case"stylesheet":return f=p.disabled,typeof p.precedence=="string"&&f==null;default:return!0}case"script":if(p.async&&typeof p.async!="function"&&typeof p.async!="symbol"&&!p.onLoad&&!p.onError&&p.src&&typeof p.src=="string")return!0}return!1}function Ate(f,p){return f==="img"&&p.src!=null&&p.src!==""&&p.onLoad==null&&p.loading!=="lazy"}function Ote(f){return!(f.type==="stylesheet"&&(f.state.loading&3)===0)}function Rte(f){return(f.width||100)*(f.height||100)*(typeof devicePixelRatio=="number"?devicePixelRatio:1)*.25}function Mte(f,p){typeof p.decode=="function"&&(f.imgCount++,p.complete||(f.imgBytes+=Rte(p),f.suspenseyImages.push(p)),f=Z5e.bind(f),p.decode().then(f,f))}function X5e(f,p,x,k){if(x.type==="stylesheet"&&(typeof k.media!="string"||matchMedia(k.media).matches!==!1)&&(x.state.loading&4)===0){if(x.instance===null){var R=kv(k.href),L=p.querySelector(ZS(R));if(L){p=L._p,p!==null&&typeof p=="object"&&typeof p.then=="function"&&(f.count++,f=ek.bind(f),p.then(f,f)),x.state.loading|=4,x.instance=L,si(L);return}L=p.ownerDocument||p,k=Cte(k),(R=El.get(R))&&Q5(k,R),L=L.createElement("link"),si(L);var V=L;V._p=new Promise(function(oe,ye){V.onload=oe,V.onerror=ye}),Ko(L,"link",k),x.instance=L}f.stylesheets===null&&(f.stylesheets=new Map),f.stylesheets.set(x,p),(p=x.state.preload)&&(x.state.loading&3)===0&&(f.count++,x=ek.bind(f),p.addEventListener("load",x),p.addEventListener("error",x))}}var DO=0;function Q5e(f,p){return f.stylesheets&&f.count===0&&zO(f,f.stylesheets),0<f.count||0<f.imgCount?function(x){var k=setTimeout(function(){if(f.stylesheets&&zO(f,f.stylesheets),f.unsuspend){var L=f.unsuspend;f.unsuspend=null,L()}},6e4+p);0<f.imgBytes&&DO===0&&(DO=62500*m5e());var R=setTimeout(function(){if(f.waitingForImages=!1,f.count===0&&(f.stylesheets&&zO(f,f.stylesheets),f.unsuspend)){var L=f.unsuspend;f.unsuspend=null,L()}},(f.imgBytes>DO?50:800)+p);return f.unsuspend=x,function(){f.unsuspend=null,clearTimeout(k),clearTimeout(R)}}:null}function _te(f){if(f.count===0&&(f.imgCount===0||!f.waitingForImages)){if(f.stylesheets)zO(f,f.stylesheets);else if(f.unsuspend){var p=f.unsuspend;f.unsuspend=null,p()}}}function ek(){this.count--,_te(this)}function Z5e(){this.imgCount--,_te(this)}var $O=null;function zO(f,p){f.stylesheets=null,f.unsuspend!==null&&(f.count++,$O=new Map,p.forEach(J5e,f),$O=null,ek.call(f))}function J5e(f,p){if(!(p.state.loading&4)){var x=$O.get(f);if(x)var k=x.get(null);else{x=new Map,$O.set(f,x);for(var R=f.querySelectorAll("link[data-precedence],style[data-precedence]"),L=0;L<R.length;L++){var V=R[L];(V.nodeName==="LINK"||V.getAttribute("media")!=="not all")&&(x.set(V.dataset.precedence,V),k=V)}k&&x.set(null,k)}R=p.instance,V=R.getAttribute("data-precedence"),L=x.get(V)||k,L===k&&x.set(null,R),x.set(V,R),this.count++,k=ek.bind(this),R.addEventListener("load",k),R.addEventListener("error",k),L?L.parentNode.insertBefore(R,L.nextSibling):(f=f.nodeType===9?f.head:f,f.insertBefore(R,f.firstChild)),p.state.loading|=4}}var Ev={$$typeof:B,Provider:null,Consumer:null,_currentValue:Se,_currentValue2:Se,_threadCount:0};function e6e(f,p,x,k,R,L,V,oe,ye){this.tag=1,this.containerInfo=f,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Ms(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ms(0),this.hiddenUpdates=Ms(null),this.identifierPrefix=k,this.onUncaughtError=R,this.onCaughtError=L,this.onRecoverableError=V,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=ye,this.transitionTypes=null,this.incompleteTransitions=new Map}function Nte(f,p,x,k,R,L,V,oe,ye,Ne,ze,Ge){return f=new e6e(f,p,x,V,ye,Ne,ze,Ge,oe),p=1,L===!0&&(p|=24),L=sa(3,null,null,p),f.current=L,L.stateNode=f,p=p3(),p.refCount++,f.pooledCache=p,p.refCount++,L.memoizedState={element:k,isDehydrated:x,cache:p},b3(L),f}function Lte(f){return f?(f=Qb,f):Qb}function Ite(f,p,x,k,R,L){R=Lte(R),k.context===null?k.context=R:k.pendingContext=R,k=hp(p),k.payload={element:x},L=L===void 0?null:L,L!==null&&(k.callback=L),x=pp(f,k,p),x!==null&&(ca(x,f,p),_S(x,f,p))}function Pte(f,p){if(f=f.memoizedState,f!==null&&f.dehydrated!==null){var x=f.retryLane;f.retryLane=x!==0&&x<p?x:p}}function e6(f,p){Pte(f,p),(f=f.alternate)&&Pte(f,p)}function jte(f){if(f.tag===13||f.tag===31){var p=s0(f,67108864);p!==null&&ca(p,f,67108864),e6(f,67108864)}}function Dte(f){if(f.tag===13||f.tag===31){var p=Wa();p=Ct(p);var x=s0(f,p);x!==null&&ca(x,f,p),e6(f,p)}}var Tv=!0;function t6e(f,p,x,k){var R=fe.T;fe.T=null;var L=se.p;try{se.p=2,t6(f,p,x,k)}finally{se.p=L,fe.T=R}}function n6e(f,p,x,k){var R=fe.T;fe.T=null;var L=se.p;try{se.p=8,t6(f,p,x,k)}finally{se.p=L,fe.T=R}}function t6(f,p,x,k){if(Tv){var R=n6(k);if(R===null)j5(f,p,k,FO,x),zte(f,k);else if(i6e(R,f,p,x,k))k.stopPropagation();else if(zte(f,k),p&4&&-1<r6e.indexOf(f)){for(;R!==null;){var L=ml(R);if(L!==null)switch(L.tag){case 3:if(L=L.stateNode,L.current.memoizedState.isDehydrated){var V=tr(L.pendingLanes);if(V!==0){var oe=L;for(oe.pendingLanes|=2,oe.entangledLanes|=2;V;){var ye=1<<31-qt(V);oe.entanglements[1]|=ye,V&=~ye}Ac(L),(dr&6)===0&&(EO=ln()+500,GS(0))}}break;case 31:case 13:oe=s0(L,2),oe!==null&&ca(oe,L,2),OO(),e6(L,2)}if(L=n6(k),L===null&&j5(f,p,k,FO,x),L===R)break;R=L}R!==null&&k.stopPropagation()}else j5(f,p,k,null,x)}}function n6(f){return f=e0(f),r6(f)}var FO=null;function r6(f){if(FO=null,f=ia(f),f!==null){var p=o(f);if(p===null)f=null;else{var x=p.tag;if(x===13){if(f=s(p),f!==null)return f;f=null}else if(x===31){if(f=a(p),f!==null)return f;f=null}else if(x===3){if(p.stateNode.current.memoizedState.isDehydrated)return p.tag===3?p.stateNode.containerInfo:null;f=null}else p!==f&&(f=null)}}return FO=f,null}function $te(f){switch(f){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"fullscreenerror":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"resize":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(mr()){case Yn:return 2;case Yt:return 8;case Ht:case on:return 32;case Jt:return 268435456;default:return 32}default:return 32}}var i6=!1,Tp=null,Ap=null,Op=null,tk=new Map,nk=new Map,Rp=[],r6e="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function zte(f,p){switch(f){case"focusin":case"focusout":Tp=null;break;case"dragenter":case"dragleave":Ap=null;break;case"mouseover":case"mouseout":Op=null;break;case"pointerover":case"pointerout":tk.delete(p.pointerId);break;case"gotpointercapture":case"lostpointercapture":nk.delete(p.pointerId)}}function rk(f,p,x,k,R,L){return f===null||f.nativeEvent!==L?(f={blockedOn:p,domEventName:x,eventSystemFlags:k,nativeEvent:L,targetContainers:[R]},p!==null&&(p=ml(p),p!==null&&jte(p)),f):(f.eventSystemFlags|=k,p=f.targetContainers,R!==null&&p.indexOf(R)===-1&&p.push(R),f)}function i6e(f,p,x,k,R){switch(p){case"focusin":return Tp=rk(Tp,f,p,x,k,R),!0;case"dragenter":return Ap=rk(Ap,f,p,x,k,R),!0;case"mouseover":return Op=rk(Op,f,p,x,k,R),!0;case"pointerover":var L=R.pointerId;return tk.set(L,rk(tk.get(L)||null,f,p,x,k,R)),!0;case"gotpointercapture":return L=R.pointerId,nk.set(L,rk(nk.get(L)||null,f,p,x,k,R)),!0}return!1}function Fte(f){var p=ia(f.target);if(p!==null){var x=o(p);if(x!==null){if(p=x.tag,p===13){if(p=s(x),p!==null){f.blockedOn=p,pu(f.priority,function(){Dte(x)});return}}else if(p===31){if(p=a(x),p!==null){f.blockedOn=p,pu(f.priority,function(){Dte(x)});return}}else if(p===3&&x.stateNode.current.memoizedState.isDehydrated){f.blockedOn=x.tag===3?x.stateNode.containerInfo:null;return}}}f.blockedOn=null}function BO(f){if(f.blockedOn!==null)return!1;for(var p=f.targetContainers;0<p.length;){var x=n6(f.nativeEvent);if(x===null){x=f.nativeEvent;var k=new x.constructor(x.type,x);Jg=k,x.target.dispatchEvent(k),Jg=null}else return p=ml(x),p!==null&&jte(p),f.blockedOn=x,!1;p.shift()}return!0}function Bte(f,p,x){BO(f)&&x.delete(p)}function o6e(){i6=!1,Tp!==null&&BO(Tp)&&(Tp=null),Ap!==null&&BO(Ap)&&(Ap=null),Op!==null&&BO(Op)&&(Op=null),tk.forEach(Bte),nk.forEach(Bte)}function HO(f,p){f.blockedOn===p&&(f.blockedOn=null,i6||(i6=!0,e.unstable_scheduleCallback(e.unstable_NormalPriority,o6e)))}var UO=null;function Hte(f){UO!==f&&(UO=f,e.unstable_scheduleCallback(e.unstable_NormalPriority,function(){UO===f&&(UO=null);for(var p=0;p<f.length;p+=3){var x=f[p],k=f[p+1],R=f[p+2];if(typeof k!="function"){if(r6(k||x)===null)continue;break}var L=ml(x);L!==null&&(f.splice(p,3),p-=3,z3(L,{pending:!0,data:R,method:x.method,action:k},k,R))}}))}function Av(f){function p(ye){return HO(ye,f)}Tp!==null&&HO(Tp,f),Ap!==null&&HO(Ap,f),Op!==null&&HO(Op,f),tk.forEach(p),nk.forEach(p);for(var x=0;x<Rp.length;x++){var k=Rp[x];k.blockedOn===f&&(k.blockedOn=null)}for(;0<Rp.length&&(x=Rp[0],x.blockedOn===null);)Fte(x),x.blockedOn===null&&Rp.shift();if(x=(f.ownerDocument||f).$$reactFormReplay,x!=null)for(k=0;k<x.length;k+=3){var R=x[k],L=x[k+1],V=R[Te]||null;if(typeof L=="function")V||Hte(x);else if(V){var oe=null;if(L&&L.hasAttribute("formAction")){if(R=L,V=L[Te]||null)oe=V.formAction;else if(r6(R)!==null)continue}else oe=V.action;typeof oe=="function"?x[k+1]=oe:(x.splice(k,3),k-=3),Hte(x)}}}function Ute(){function f(L){L.canIntercept&&L.info==="react-transition"&&L.intercept({handler:function(){return new Promise(function(V){return R=V})},focusReset:"manual",scroll:"manual"})}function p(){R!==null&&(R(),R=null),k||setTimeout(x,20)}function x(){if(!k&&!navigation.transition){var L=navigation.currentEntry;L&&L.url!=null&&navigation.navigate(L.url,{state:L.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var k=!1,R=null;return navigation.addEventListener("navigate",f),navigation.addEventListener("navigatesuccess",p),navigation.addEventListener("navigateerror",p),setTimeout(x,100),function(){k=!0,navigation.removeEventListener("navigate",f),navigation.removeEventListener("navigatesuccess",p),navigation.removeEventListener("navigateerror",p),R!==null&&(R(),R=null)}}}function o6(f){this._internalRoot=f}VO.prototype.render=o6.prototype.render=function(f){var p=this._internalRoot;if(p===null)throw Error(r(409));var x=p.current,k=Wa();Ite(x,k,f,p,null,null)},VO.prototype.unmount=o6.prototype.unmount=function(){var f=this._internalRoot;if(f!==null){this._internalRoot=null;var p=f.containerInfo;Ite(f.current,2,null,f,null,null),OO(),p[Xe]=null}};function VO(f){this._internalRoot=f}VO.prototype.unstable_scheduleHydration=function(f){if(f){var p=fc();f={blockedOn:null,target:f,priority:p};for(var x=0;x<Rp.length&&p!==0&&p<Rp[x].priority;x++);Rp.splice(x,0,f),x===0&&Fte(f)}};var Vte=t.version;if(Vte!=="19.3.1")throw Error(r(527,Vte,"19.3.1"));se.findDOMNode=function(f){var p=f._reactInternals;if(p===void 0)throw typeof f.render=="function"?Error(r(188)):(f=Object.keys(f).join(","),Error(r(268,f)));return f=u(p),f=f!==null?c(f):null,f=f===null?null:f.stateNode,f};var s6e={bundleType:0,version:"19.3.1",rendererPackageName:"react-dom",currentDispatcherRef:fe,reconcilerVersion:"19.3.1"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var WO=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!WO.isDisabled&&WO.supportsFiber)try{Fe=WO.inject(s6e),Qe=WO}catch{}}return Mk.createRoot=function(f,p){if(!i(f))throw Error(r(299));var x=!1,k="",R=LJ,L=IJ,V=PJ;return p!=null&&(p.unstable_strictMode===!0&&(x=!0),p.identifierPrefix!==void 0&&(k=p.identifierPrefix),p.onUncaughtError!==void 0&&(R=p.onUncaughtError),p.onCaughtError!==void 0&&(L=p.onCaughtError),p.onRecoverableError!==void 0&&(V=p.onRecoverableError)),p=Nte(f,1,!1,null,null,x,k,null,R,L,V,Ute),f[Xe]=p.current,P5(f),new o6(p)},Mk.hydrateRoot=function(f,p,x){if(!i(f))throw Error(r(299));var k=!1,R="",L=LJ,V=IJ,oe=PJ,ye=null;return x!=null&&(x.unstable_strictMode===!0&&(k=!0),x.identifierPrefix!==void 0&&(R=x.identifierPrefix),x.onUncaughtError!==void 0&&(L=x.onUncaughtError),x.onCaughtError!==void 0&&(V=x.onCaughtError),x.onRecoverableError!==void 0&&(oe=x.onRecoverableError),x.formState!==void 0&&(ye=x.formState)),p=Nte(f,1,!0,p,x??null,k,R,ye,L,V,oe,Ute),p.context=Lte(null),x=p.current,k=Wa(),k=Ct(k),R=hp(k),R.callback=null,pp(x,R,k),x=k,p.current.lanes=x,Ri(p,x),Ac(p),f[Xe]=p.current,P5(f),new VO(p)},Mk.version="19.3.1",Mk}var l0e;function Ezt(){if(l0e)return ZB.exports;l0e=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),ZB.exports=Czt(),ZB.exports}var Tzt=Ezt();function $i(e){if(typeof e=="string"||typeof e=="number")return""+e;let t="";if(Array.isArray(e))for(let n=0,r;n<e.length;n++)(r=$i(e[n]))!==""&&(t+=(t&&" ")+r);else for(let n in e)e[n]&&(t+=(t&&" ")+n);return t}var Azt={value:()=>{}};function PD(){for(var e=0,t=arguments.length,n={},r;e<t;++e){if(!(r=arguments[e]+"")||r in n||/[\s.]/.test(r))throw new Error("illegal type: "+r);n[r]=[]}return new D_(n)}function D_(e){this._=e}function Ozt(e,t){return e.trim().split(/^|\s+/).map(function(n){var r="",i=n.indexOf(".");if(i>=0&&(r=n.slice(i+1),n=n.slice(0,i)),n&&!t.hasOwnProperty(n))throw new Error("unknown type: "+n);return{type:n,name:r}})}D_.prototype=PD.prototype={constructor:D_,on:function(e,t){var n=this._,r=Ozt(e+"",n),i,o=-1,s=r.length;if(arguments.length<2){for(;++o<s;)if((i=(e=r[o]).type)&&(i=Rzt(n[i],e.name)))return i;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++o<s;)if(i=(e=r[o]).type)n[i]=u0e(n[i],e.name,t);else if(t==null)for(i in n)n[i]=u0e(n[i],e.name,null);return this},copy:function(){var e={},t=this._;for(var n in t)e[n]=t[n].slice();return new D_(e)},call:function(e,t){if((i=arguments.length-2)>0)for(var n=new Array(i),r=0,i,o;r<i;++r)n[r]=arguments[r+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(o=this._[e],r=0,i=o.length;r<i;++r)o[r].value.apply(t,n)},apply:function(e,t,n){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var r=this._[e],i=0,o=r.length;i<o;++i)r[i].value.apply(t,n)}};function Rzt(e,t){for(var n=0,r=e.length,i;n<r;++n)if((i=e[n]).name===t)return i.value}function u0e(e,t,n){for(var r=0,i=e.length;r<i;++r)if(e[r].name===t){e[r]=Azt,e=e.slice(0,r).concat(e.slice(r+1));break}return n!=null&&e.push({name:t,value:n}),e}var qW="http://www.w3.org/1999/xhtml";const c0e={svg:"http://www.w3.org/2000/svg",xhtml:qW,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function jD(e){var t=e+="",n=t.indexOf(":");return n>=0&&(t=e.slice(0,n))!=="xmlns"&&(e=e.slice(n+1)),c0e.hasOwnProperty(t)?{space:c0e[t],local:e}:e}function Mzt(e){return function(){var t=this.ownerDocument,n=this.namespaceURI;return n===qW&&t.documentElement.namespaceURI===qW?t.createElement(e):t.createElementNS(n,e)}}function _zt(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function cPe(e){var t=jD(e);return(t.local?_zt:Mzt)(t)}function Nzt(){}function EQ(e){return e==null?Nzt:function(){return this.querySelector(e)}}function Lzt(e){typeof e!="function"&&(e=EQ(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var o=t[i],s=o.length,a=r[i]=new Array(s),l,u,c=0;c<s;++c)(l=o[c])&&(u=e.call(l,l.__data__,c,o))&&("__data__"in l&&(u.__data__=l.__data__),a[c]=u);return new hl(r,this._parents)}function Izt(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function Pzt(){return[]}function dPe(e){return e==null?Pzt:function(){return this.querySelectorAll(e)}}function jzt(e){return function(){return Izt(e.apply(this,arguments))}}function Dzt(e){typeof e=="function"?e=jzt(e):e=dPe(e);for(var t=this._groups,n=t.length,r=[],i=[],o=0;o<n;++o)for(var s=t[o],a=s.length,l,u=0;u<a;++u)(l=s[u])&&(r.push(e.call(l,l.__data__,u,s)),i.push(l));return new hl(r,i)}function fPe(e){return function(){return this.matches(e)}}function hPe(e){return function(t){return t.matches(e)}}var $zt=Array.prototype.find;function zzt(e){return function(){return $zt.call(this.children,e)}}function Fzt(){return this.firstElementChild}function Bzt(e){return this.select(e==null?Fzt:zzt(typeof e=="function"?e:hPe(e)))}var Hzt=Array.prototype.filter;function Uzt(){return Array.from(this.children)}function Vzt(e){return function(){return Hzt.call(this.children,e)}}function Wzt(e){return this.selectAll(e==null?Uzt:Vzt(typeof e=="function"?e:hPe(e)))}function qzt(e){typeof e!="function"&&(e=fPe(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var o=t[i],s=o.length,a=r[i]=[],l,u=0;u<s;++u)(l=o[u])&&e.call(l,l.__data__,u,o)&&a.push(l);return new hl(r,this._parents)}function pPe(e){return new Array(e.length)}function Gzt(){return new hl(this._enter||this._groups.map(pPe),this._parents)}function KI(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}KI.prototype={constructor:KI,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function Kzt(e){return function(){return e}}function Yzt(e,t,n,r,i,o){for(var s=0,a,l=t.length,u=o.length;s<u;++s)(a=t[s])?(a.__data__=o[s],r[s]=a):n[s]=new KI(e,o[s]);for(;s<l;++s)(a=t[s])&&(i[s]=a)}function Xzt(e,t,n,r,i,o,s){var a,l,u=new Map,c=t.length,d=o.length,h=new Array(c),m;for(a=0;a<c;++a)(l=t[a])&&(h[a]=m=s.call(l,l.__data__,a,t)+"",u.has(m)?i[a]=l:u.set(m,l));for(a=0;a<d;++a)m=s.call(e,o[a],a,o)+"",(l=u.get(m))?(r[a]=l,l.__data__=o[a],u.delete(m)):n[a]=new KI(e,o[a]);for(a=0;a<c;++a)(l=t[a])&&u.get(h[a])===l&&(i[a]=l)}function Qzt(e){return e.__data__}function Zzt(e,t){if(!arguments.length)return Array.from(this,Qzt);var n=t?Xzt:Yzt,r=this._parents,i=this._groups;typeof e!="function"&&(e=Kzt(e));for(var o=i.length,s=new Array(o),a=new Array(o),l=new Array(o),u=0;u<o;++u){var c=r[u],d=i[u],h=d.length,m=Jzt(e.call(c,c&&c.__data__,u,r)),g=m.length,b=a[u]=new Array(g),v=s[u]=new Array(g),w=l[u]=new Array(h);n(c,d,b,v,w,m,t);for(var S=0,C=0,E,T;S<g;++S)if(E=b[S]){for(S>=C&&(C=S+1);!(T=v[C])&&++C<g;);E._next=T||null}}return s=new hl(s,r),s._enter=a,s._exit=l,s}function Jzt(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function eFt(){return new hl(this._exit||this._groups.map(pPe),this._parents)}function tFt(e,t,n){var r=this.enter(),i=this,o=this.exit();return typeof e=="function"?(r=e(r),r&&(r=r.selection())):r=r.append(e+""),t!=null&&(i=t(i),i&&(i=i.selection())),n==null?o.remove():n(o),r&&i?r.merge(i).order():i}function nFt(e){for(var t=e.selection?e.selection():e,n=this._groups,r=t._groups,i=n.length,o=r.length,s=Math.min(i,o),a=new Array(i),l=0;l<s;++l)for(var u=n[l],c=r[l],d=u.length,h=a[l]=new Array(d),m,g=0;g<d;++g)(m=u[g]||c[g])&&(h[g]=m);for(;l<i;++l)a[l]=n[l];return new hl(a,this._parents)}function rFt(){for(var e=this._groups,t=-1,n=e.length;++t<n;)for(var r=e[t],i=r.length-1,o=r[i],s;--i>=0;)(s=r[i])&&(o&&s.compareDocumentPosition(o)^4&&o.parentNode.insertBefore(s,o),o=s);return this}function iFt(e){e||(e=oFt);function t(d,h){return d&&h?e(d.__data__,h.__data__):!d-!h}for(var n=this._groups,r=n.length,i=new Array(r),o=0;o<r;++o){for(var s=n[o],a=s.length,l=i[o]=new Array(a),u,c=0;c<a;++c)(u=s[c])&&(l[c]=u);l.sort(t)}return new hl(i,this._parents).order()}function oFt(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function sFt(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function aFt(){return Array.from(this)}function lFt(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var r=e[t],i=0,o=r.length;i<o;++i){var s=r[i];if(s)return s}return null}function uFt(){let e=0;for(const t of this)++e;return e}function cFt(){return!this.node()}function dFt(e){for(var t=this._groups,n=0,r=t.length;n<r;++n)for(var i=t[n],o=0,s=i.length,a;o<s;++o)(a=i[o])&&e.call(a,a.__data__,o,i);return this}function fFt(e){return function(){this.removeAttribute(e)}}function hFt(e){return function(){this.removeAttributeNS(e.space,e.local)}}function pFt(e,t){return function(){this.setAttribute(e,t)}}function mFt(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function gFt(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttribute(e):this.setAttribute(e,n)}}function yFt(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,n)}}function bFt(e,t){var n=jD(e);if(arguments.length<2){var r=this.node();return n.local?r.getAttributeNS(n.space,n.local):r.getAttribute(n)}return this.each((t==null?n.local?hFt:fFt:typeof t=="function"?n.local?yFt:gFt:n.local?mFt:pFt)(n,t))}function mPe(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function vFt(e){return function(){this.style.removeProperty(e)}}function xFt(e,t,n){return function(){this.style.setProperty(e,t,n)}}function wFt(e,t,n){return function(){var r=t.apply(this,arguments);r==null?this.style.removeProperty(e):this.style.setProperty(e,r,n)}}function SFt(e,t,n){return arguments.length>1?this.each((t==null?vFt:typeof t=="function"?wFt:xFt)(e,t,n??"")):Ow(this.node(),e)}function Ow(e,t){return e.style.getPropertyValue(t)||mPe(e).getComputedStyle(e,null).getPropertyValue(t)}function kFt(e){return function(){delete this[e]}}function CFt(e,t){return function(){this[e]=t}}function EFt(e,t){return function(){var n=t.apply(this,arguments);n==null?delete this[e]:this[e]=n}}function TFt(e,t){return arguments.length>1?this.each((t==null?kFt:typeof t=="function"?EFt:CFt)(e,t)):this.node()[e]}function gPe(e){return e.trim().split(/^|\s+/)}function TQ(e){return e.classList||new yPe(e)}function yPe(e){this._node=e,this._names=gPe(e.getAttribute("class")||"")}yPe.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function bPe(e,t){for(var n=TQ(e),r=-1,i=t.length;++r<i;)n.add(t[r])}function vPe(e,t){for(var n=TQ(e),r=-1,i=t.length;++r<i;)n.remove(t[r])}function AFt(e){return function(){bPe(this,e)}}function OFt(e){return function(){vPe(this,e)}}function RFt(e,t){return function(){(t.apply(this,arguments)?bPe:vPe)(this,e)}}function MFt(e,t){var n=gPe(e+"");if(arguments.length<2){for(var r=TQ(this.node()),i=-1,o=n.length;++i<o;)if(!r.contains(n[i]))return!1;return!0}return this.each((typeof t=="function"?RFt:t?AFt:OFt)(n,t))}function _Ft(){this.textContent=""}function NFt(e){return function(){this.textContent=e}}function LFt(e){return function(){var t=e.apply(this,arguments);this.textContent=t??""}}function IFt(e){return arguments.length?this.each(e==null?_Ft:(typeof e=="function"?LFt:NFt)(e)):this.node().textContent}function PFt(){this.innerHTML=""}function jFt(e){return function(){this.innerHTML=e}}function DFt(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t??""}}function $Ft(e){return arguments.length?this.each(e==null?PFt:(typeof e=="function"?DFt:jFt)(e)):this.node().innerHTML}function zFt(){this.nextSibling&&this.parentNode.appendChild(this)}function FFt(){return this.each(zFt)}function BFt(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function HFt(){return this.each(BFt)}function UFt(e){var t=typeof e=="function"?e:cPe(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function VFt(){return null}function WFt(e,t){var n=typeof e=="function"?e:cPe(e),r=t==null?VFt:typeof t=="function"?t:EQ(t);return this.select(function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)})}function qFt(){var e=this.parentNode;e&&e.removeChild(this)}function GFt(){return this.each(qFt)}function KFt(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function YFt(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function XFt(e){return this.select(e?YFt:KFt)}function QFt(e){return arguments.length?this.property("__data__",e):this.node().__data__}function ZFt(e){return function(t){e.call(this,t,this.__data__)}}function JFt(e){return e.trim().split(/^|\s+/).map(function(t){var n="",r=t.indexOf(".");return r>=0&&(n=t.slice(r+1),t=t.slice(0,r)),{type:t,name:n}})}function eBt(e){return function(){var t=this.__on;if(t){for(var n=0,r=-1,i=t.length,o;n<i;++n)o=t[n],(!e.type||o.type===e.type)&&o.name===e.name?this.removeEventListener(o.type,o.listener,o.options):t[++r]=o;++r?t.length=r:delete this.__on}}}function tBt(e,t,n){return function(){var r=this.__on,i,o=ZFt(t);if(r){for(var s=0,a=r.length;s<a;++s)if((i=r[s]).type===e.type&&i.name===e.name){this.removeEventListener(i.type,i.listener,i.options),this.addEventListener(i.type,i.listener=o,i.options=n),i.value=t;return}}this.addEventListener(e.type,o,n),i={type:e.type,name:e.name,value:t,listener:o,options:n},r?r.push(i):this.__on=[i]}}function nBt(e,t,n){var r=JFt(e+""),i,o=r.length,s;if(arguments.length<2){var a=this.node().__on;if(a){for(var l=0,u=a.length,c;l<u;++l)for(i=0,c=a[l];i<o;++i)if((s=r[i]).type===c.type&&s.name===c.name)return c.value}return}for(a=t?tBt:eBt,i=0;i<o;++i)this.each(a(r[i],t,n));return this}function xPe(e,t,n){var r=mPe(e),i=r.CustomEvent;typeof i=="function"?i=new i(t,n):(i=r.document.createEvent("Event"),n?(i.initEvent(t,n.bubbles,n.cancelable),i.detail=n.detail):i.initEvent(t,!1,!1)),e.dispatchEvent(i)}function rBt(e,t){return function(){return xPe(this,e,t)}}function iBt(e,t){return function(){return xPe(this,e,t.apply(this,arguments))}}function oBt(e,t){return this.each((typeof t=="function"?iBt:rBt)(e,t))}function*sBt(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var r=e[t],i=0,o=r.length,s;i<o;++i)(s=r[i])&&(yield s)}var wPe=[null];function hl(e,t){this._groups=e,this._parents=t}function AA(){return new hl([[document.documentElement]],wPe)}function aBt(){return this}hl.prototype=AA.prototype={constructor:hl,select:Lzt,selectAll:Dzt,selectChild:Bzt,selectChildren:Wzt,filter:qzt,data:Zzt,enter:Gzt,exit:eFt,join:tFt,merge:nFt,selection:aBt,order:rFt,sort:iFt,call:sFt,nodes:aFt,node:lFt,size:uFt,empty:cFt,each:dFt,attr:bFt,style:SFt,property:TFt,classed:MFt,text:IFt,html:$Ft,raise:FFt,lower:HFt,append:UFt,insert:WFt,remove:GFt,clone:XFt,datum:QFt,on:nBt,dispatch:oBt,[Symbol.iterator]:sBt};function al(e){return typeof e=="string"?new hl([[document.querySelector(e)]],[document.documentElement]):new hl([[e]],wPe)}function lBt(e){let t;for(;t=e.sourceEvent;)e=t;return e}function Fu(e,t){if(e=lBt(e),t===void 0&&(t=e.currentTarget),t){var n=t.ownerSVGElement||t;if(n.createSVGPoint){var r=n.createSVGPoint();return r.x=e.clientX,r.y=e.clientY,r=r.matrixTransform(t.getScreenCTM().inverse()),[r.x,r.y]}if(t.getBoundingClientRect){var i=t.getBoundingClientRect();return[e.clientX-i.left-t.clientLeft,e.clientY-i.top-t.clientTop]}}return[e.pageX,e.pageY]}const uBt={passive:!1},jT={capture:!0,passive:!1};function t7(e){e.stopImmediatePropagation()}function G1(e){e.preventDefault(),e.stopImmediatePropagation()}function SPe(e){var t=e.document.documentElement,n=al(e).on("dragstart.drag",G1,jT);"onselectstart"in t?n.on("selectstart.drag",G1,jT):(t.__noselect=t.style.MozUserSelect,t.style.MozUserSelect="none")}function kPe(e,t){var n=e.document.documentElement,r=al(e).on("dragstart.drag",null);t&&(r.on("click.drag",G1,jT),setTimeout(function(){r.on("click.drag",null)},0)),"onselectstart"in n?r.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}const xM=e=>()=>e;function GW(e,{sourceEvent:t,subject:n,target:r,identifier:i,active:o,x:s,y:a,dx:l,dy:u,dispatch:c}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},subject:{value:n,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},identifier:{value:i,enumerable:!0,configurable:!0},active:{value:o,enumerable:!0,configurable:!0},x:{value:s,enumerable:!0,configurable:!0},y:{value:a,enumerable:!0,configurable:!0},dx:{value:l,enumerable:!0,configurable:!0},dy:{value:u,enumerable:!0,configurable:!0},_:{value:c}})}GW.prototype.on=function(){var e=this._.on.apply(this._,arguments);return e===this._?this:e};function cBt(e){return!e.ctrlKey&&!e.button}function dBt(){return this.parentNode}function fBt(e,t){return t??{x:e.x,y:e.y}}function hBt(){return navigator.maxTouchPoints||"ontouchstart"in this}function CPe(){var e=cBt,t=dBt,n=fBt,r=hBt,i={},o=PD("start","drag","end"),s=0,a,l,u,c,d=0;function h(E){E.on("mousedown.drag",m).filter(r).on("touchstart.drag",v).on("touchmove.drag",w,uBt).on("touchend.drag touchcancel.drag",S).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function m(E,T){if(!(c||!e.call(this,E,T))){var O=C(this,t.call(this,E,T),E,T,"mouse");O&&(al(E.view).on("mousemove.drag",g,jT).on("mouseup.drag",b,jT),SPe(E.view),t7(E),u=!1,a=E.clientX,l=E.clientY,O("start",E))}}function g(E){if(G1(E),!u){var T=E.clientX-a,O=E.clientY-l;u=T*T+O*O>d}i.mouse("drag",E)}function b(E){al(E.view).on("mousemove.drag mouseup.drag",null),kPe(E.view,u),G1(E),i.mouse("end",E)}function v(E,T){if(e.call(this,E,T)){var O=E.changedTouches,M=t.call(this,E,T),N=O.length,I,D;for(I=0;I<N;++I)(D=C(this,M,E,T,O[I].identifier,O[I]))&&(t7(E),D("start",E,O[I]))}}function w(E){var T=E.changedTouches,O=T.length,M,N;for(M=0;M<O;++M)(N=i[T[M].identifier])&&(G1(E),N("drag",E,T[M]))}function S(E){var T=E.changedTouches,O=T.length,M,N;for(c&&clearTimeout(c),c=setTimeout(function(){c=null},500),M=0;M<O;++M)(N=i[T[M].identifier])&&(t7(E),N("end",E,T[M]))}function C(E,T,O,M,N,I){var D=o.copy(),P=Fu(I||O,T),F,z,$;if(($=n.call(E,new GW("beforestart",{sourceEvent:O,target:h,identifier:N,active:s,x:P[0],y:P[1],dx:0,dy:0,dispatch:D}),M))!=null)return F=$.x-P[0]||0,z=$.y-P[1]||0,function B(H,U,W){var q=P,Y;switch(H){case"start":i[N]=B,Y=s++;break;case"end":delete i[N],--s;case"drag":P=Fu(W||U,T),Y=s;break}D.call(H,E,new GW(H,{sourceEvent:U,subject:$,target:h,identifier:N,active:Y,x:P[0]+F,y:P[1]+z,dx:P[0]-q[0],dy:P[1]-q[1],dispatch:D}),M)}}return h.filter=function(E){return arguments.length?(e=typeof E=="function"?E:xM(!!E),h):e},h.container=function(E){return arguments.length?(t=typeof E=="function"?E:xM(E),h):t},h.subject=function(E){return arguments.length?(n=typeof E=="function"?E:xM(E),h):n},h.touchable=function(E){return arguments.length?(r=typeof E=="function"?E:xM(!!E),h):r},h.on=function(){var E=o.on.apply(o,arguments);return E===o?h:E},h.clickDistance=function(E){return arguments.length?(d=(E=+E)*E,h):Math.sqrt(d)},h}var Rw=0,gC=0,_k=0,EPe=1e3,YI,yC,XI=0,Cb=0,DD=0,DT=typeof performance=="object"&&performance.now?performance:Date,TPe=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function AQ(){return Cb||(TPe(pBt),Cb=DT.now()+DD)}function pBt(){Cb=0}function QI(){this._call=this._time=this._next=null}QI.prototype=APe.prototype={constructor:QI,restart:function(e,t,n){if(typeof e!="function")throw new TypeError("callback is not a function");n=(n==null?AQ():+n)+(t==null?0:+t),!this._next&&yC!==this&&(yC?yC._next=this:YI=this,yC=this),this._call=e,this._time=n,KW()},stop:function(){this._call&&(this._call=null,this._time=1/0,KW())}};function APe(e,t,n){var r=new QI;return r.restart(e,t,n),r}function mBt(){AQ(),++Rw;for(var e=YI,t;e;)(t=Cb-e._time)>=0&&e._call.call(void 0,t),e=e._next;--Rw}function d0e(){Cb=(XI=DT.now())+DD,Rw=gC=0;try{mBt()}finally{Rw=0,yBt(),Cb=0}}function gBt(){var e=DT.now(),t=e-XI;t>EPe&&(DD-=t,XI=e)}function yBt(){for(var e,t=YI,n,r=1/0;t;)t._call?(r>t._time&&(r=t._time),e=t,t=t._next):(n=t._next,t._next=null,t=e?e._next=n:YI=n);yC=e,KW(r)}function KW(e){if(!Rw){gC&&(gC=clearTimeout(gC));var t=e-Cb;t>24?(e<1/0&&(gC=setTimeout(d0e,e-DT.now()-DD)),_k&&(_k=clearInterval(_k))):(_k||(XI=DT.now(),_k=setInterval(gBt,EPe)),Rw=1,TPe(d0e))}}function f0e(e,t,n){var r=new QI;return t=t==null?0:+t,r.restart(i=>{r.stop(),e(i+t)},t,n),r}var bBt=PD("start","end","cancel","interrupt"),vBt=[],OPe=0,h0e=1,YW=2,$_=3,p0e=4,XW=5,z_=6;function $D(e,t,n,r,i,o){var s=e.__transition;if(!s)e.__transition={};else if(n in s)return;xBt(e,n,{name:t,index:r,group:i,on:bBt,tween:vBt,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:OPe})}function OQ(e,t){var n=cc(e,t);if(n.state>OPe)throw new Error("too late; already scheduled");return n}function Ud(e,t){var n=cc(e,t);if(n.state>$_)throw new Error("too late; already running");return n}function cc(e,t){var n=e.__transition;if(!n||!(n=n[t]))throw new Error("transition not found");return n}function xBt(e,t,n){var r=e.__transition,i;r[t]=n,n.timer=APe(o,0,n.time);function o(u){n.state=h0e,n.timer.restart(s,n.delay,n.time),n.delay<=u&&s(u-n.delay)}function s(u){var c,d,h,m;if(n.state!==h0e)return l();for(c in r)if(m=r[c],m.name===n.name){if(m.state===$_)return f0e(s);m.state===p0e?(m.state=z_,m.timer.stop(),m.on.call("interrupt",e,e.__data__,m.index,m.group),delete r[c]):+c<t&&(m.state=z_,m.timer.stop(),m.on.call("cancel",e,e.__data__,m.index,m.group),delete r[c])}if(f0e(function(){n.state===$_&&(n.state=p0e,n.timer.restart(a,n.delay,n.time),a(u))}),n.state=YW,n.on.call("start",e,e.__data__,n.index,n.group),n.state===YW){for(n.state=$_,i=new Array(h=n.tween.length),c=0,d=-1;c<h;++c)(m=n.tween[c].value.call(e,e.__data__,n.index,n.group))&&(i[++d]=m);i.length=d+1}}function a(u){for(var c=u<n.duration?n.ease.call(null,u/n.duration):(n.timer.restart(l),n.state=XW,1),d=-1,h=i.length;++d<h;)i[d].call(e,c);n.state===XW&&(n.on.call("end",e,e.__data__,n.index,n.group),l())}function l(){n.state=z_,n.timer.stop(),delete r[t];for(var u in r)return;delete e.__transition}}function F_(e,t){var n=e.__transition,r,i,o=!0,s;if(n){t=t==null?null:t+"";for(s in n){if((r=n[s]).name!==t){o=!1;continue}i=r.state>YW&&r.state<XW,r.state=z_,r.timer.stop(),r.on.call(i?"interrupt":"cancel",e,e.__data__,r.index,r.group),delete n[s]}o&&delete e.__transition}}function wBt(e){return this.each(function(){F_(this,e)})}function SBt(e,t){var n,r;return function(){var i=Ud(this,e),o=i.tween;if(o!==n){r=n=o;for(var s=0,a=r.length;s<a;++s)if(r[s].name===t){r=r.slice(),r.splice(s,1);break}}i.tween=r}}function kBt(e,t,n){var r,i;if(typeof n!="function")throw new Error;return function(){var o=Ud(this,e),s=o.tween;if(s!==r){i=(r=s).slice();for(var a={name:t,value:n},l=0,u=i.length;l<u;++l)if(i[l].name===t){i[l]=a;break}l===u&&i.push(a)}o.tween=i}}function CBt(e,t){var n=this._id;if(e+="",arguments.length<2){for(var r=cc(this.node(),n).tween,i=0,o=r.length,s;i<o;++i)if((s=r[i]).name===e)return s.value;return null}return this.each((t==null?SBt:kBt)(n,e,t))}function RQ(e,t,n){var r=e._id;return e.each(function(){var i=Ud(this,r);(i.value||(i.value={}))[t]=n.apply(this,arguments)}),function(i){return cc(i,r).value[t]}}function RPe(e,t){var n;return(typeof t=="number"?Uu:t instanceof yb?XE:(n=yb(t))?(t=n,XE):MRe)(e,t)}function EBt(e){return function(){this.removeAttribute(e)}}function TBt(e){return function(){this.removeAttributeNS(e.space,e.local)}}function ABt(e,t,n){var r,i=n+"",o;return function(){var s=this.getAttribute(e);return s===i?null:s===r?o:o=t(r=s,n)}}function OBt(e,t,n){var r,i=n+"",o;return function(){var s=this.getAttributeNS(e.space,e.local);return s===i?null:s===r?o:o=t(r=s,n)}}function RBt(e,t,n){var r,i,o;return function(){var s,a=n(this),l;return a==null?void this.removeAttribute(e):(s=this.getAttribute(e),l=a+"",s===l?null:s===r&&l===i?o:(i=l,o=t(r=s,a)))}}function MBt(e,t,n){var r,i,o;return function(){var s,a=n(this),l;return a==null?void this.removeAttributeNS(e.space,e.local):(s=this.getAttributeNS(e.space,e.local),l=a+"",s===l?null:s===r&&l===i?o:(i=l,o=t(r=s,a)))}}function _Bt(e,t){var n=jD(e),r=n==="transform"?Mwt:RPe;return this.attrTween(e,typeof t=="function"?(n.local?MBt:RBt)(n,r,RQ(this,"attr."+e,t)):t==null?(n.local?TBt:EBt)(n):(n.local?OBt:ABt)(n,r,t))}function NBt(e,t){return function(n){this.setAttribute(e,t.call(this,n))}}function LBt(e,t){return function(n){this.setAttributeNS(e.space,e.local,t.call(this,n))}}function IBt(e,t){var n,r;function i(){var o=t.apply(this,arguments);return o!==r&&(n=(r=o)&&LBt(e,o)),n}return i._value=t,i}function PBt(e,t){var n,r;function i(){var o=t.apply(this,arguments);return o!==r&&(n=(r=o)&&NBt(e,o)),n}return i._value=t,i}function jBt(e,t){var n="attr."+e;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(t==null)return this.tween(n,null);if(typeof t!="function")throw new Error;var r=jD(e);return this.tween(n,(r.local?IBt:PBt)(r,t))}function DBt(e,t){return function(){OQ(this,e).delay=+t.apply(this,arguments)}}function $Bt(e,t){return t=+t,function(){OQ(this,e).delay=t}}function zBt(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?DBt:$Bt)(t,e)):cc(this.node(),t).delay}function FBt(e,t){return function(){Ud(this,e).duration=+t.apply(this,arguments)}}function BBt(e,t){return t=+t,function(){Ud(this,e).duration=t}}function HBt(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?FBt:BBt)(t,e)):cc(this.node(),t).duration}function UBt(e,t){if(typeof t!="function")throw new Error;return function(){Ud(this,e).ease=t}}function VBt(e){var t=this._id;return arguments.length?this.each(UBt(t,e)):cc(this.node(),t).ease}function WBt(e,t){return function(){var n=t.apply(this,arguments);if(typeof n!="function")throw new Error;Ud(this,e).ease=n}}function qBt(e){if(typeof e!="function")throw new Error;return this.each(WBt(this._id,e))}function GBt(e){typeof e!="function"&&(e=fPe(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var o=t[i],s=o.length,a=r[i]=[],l,u=0;u<s;++u)(l=o[u])&&e.call(l,l.__data__,u,o)&&a.push(l);return new Vh(r,this._parents,this._name,this._id)}function KBt(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,n=e._groups,r=t.length,i=n.length,o=Math.min(r,i),s=new Array(r),a=0;a<o;++a)for(var l=t[a],u=n[a],c=l.length,d=s[a]=new Array(c),h,m=0;m<c;++m)(h=l[m]||u[m])&&(d[m]=h);for(;a<r;++a)s[a]=t[a];return new Vh(s,this._parents,this._name,this._id)}function YBt(e){return(e+"").trim().split(/^|\s+/).every(function(t){var n=t.indexOf(".");return n>=0&&(t=t.slice(0,n)),!t||t==="start"})}function XBt(e,t,n){var r,i,o=YBt(t)?OQ:Ud;return function(){var s=o(this,e),a=s.on;a!==r&&(i=(r=a).copy()).on(t,n),s.on=i}}function QBt(e,t){var n=this._id;return arguments.length<2?cc(this.node(),n).on.on(e):this.each(XBt(n,e,t))}function ZBt(e){return function(){var t=this.parentNode;for(var n in this.__transition)if(+n!==e)return;t&&t.removeChild(this)}}function JBt(){return this.on("end.remove",ZBt(this._id))}function e7t(e){var t=this._name,n=this._id;typeof e!="function"&&(e=EQ(e));for(var r=this._groups,i=r.length,o=new Array(i),s=0;s<i;++s)for(var a=r[s],l=a.length,u=o[s]=new Array(l),c,d,h=0;h<l;++h)(c=a[h])&&(d=e.call(c,c.__data__,h,a))&&("__data__"in c&&(d.__data__=c.__data__),u[h]=d,$D(u[h],t,n,h,u,cc(c,n)));return new Vh(o,this._parents,t,n)}function t7t(e){var t=this._name,n=this._id;typeof e!="function"&&(e=dPe(e));for(var r=this._groups,i=r.length,o=[],s=[],a=0;a<i;++a)for(var l=r[a],u=l.length,c,d=0;d<u;++d)if(c=l[d]){for(var h=e.call(c,c.__data__,d,l),m,g=cc(c,n),b=0,v=h.length;b<v;++b)(m=h[b])&&$D(m,t,n,b,h,g);o.push(h),s.push(c)}return new Vh(o,s,t,n)}var n7t=AA.prototype.constructor;function r7t(){return new n7t(this._groups,this._parents)}function i7t(e,t){var n,r,i;return function(){var o=Ow(this,e),s=(this.style.removeProperty(e),Ow(this,e));return o===s?null:o===n&&s===r?i:i=t(n=o,r=s)}}function MPe(e){return function(){this.style.removeProperty(e)}}function o7t(e,t,n){var r,i=n+"",o;return function(){var s=Ow(this,e);return s===i?null:s===r?o:o=t(r=s,n)}}function s7t(e,t,n){var r,i,o;return function(){var s=Ow(this,e),a=n(this),l=a+"";return a==null&&(l=a=(this.style.removeProperty(e),Ow(this,e))),s===l?null:s===r&&l===i?o:(i=l,o=t(r=s,a))}}function a7t(e,t){var n,r,i,o="style."+t,s="end."+o,a;return function(){var l=Ud(this,e),u=l.on,c=l.value[o]==null?a||(a=MPe(t)):void 0;(u!==n||i!==c)&&(r=(n=u).copy()).on(s,i=c),l.on=r}}function l7t(e,t,n){var r=(e+="")=="transform"?Rwt:RPe;return t==null?this.styleTween(e,i7t(e,r)).on("end.style."+e,MPe(e)):typeof t=="function"?this.styleTween(e,s7t(e,r,RQ(this,"style."+e,t))).each(a7t(this._id,e)):this.styleTween(e,o7t(e,r,t),n).on("end.style."+e,null)}function u7t(e,t,n){return function(r){this.style.setProperty(e,t.call(this,r),n)}}function c7t(e,t,n){var r,i;function o(){var s=t.apply(this,arguments);return s!==i&&(r=(i=s)&&u7t(e,s,n)),r}return o._value=t,o}function d7t(e,t,n){var r="style."+(e+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(t==null)return this.tween(r,null);if(typeof t!="function")throw new Error;return this.tween(r,c7t(e,t,n??""))}function f7t(e){return function(){this.textContent=e}}function h7t(e){return function(){var t=e(this);this.textContent=t??""}}function p7t(e){return this.tween("text",typeof e=="function"?h7t(RQ(this,"text",e)):f7t(e==null?"":e+""))}function m7t(e){return function(t){this.textContent=e.call(this,t)}}function g7t(e){var t,n;function r(){var i=e.apply(this,arguments);return i!==n&&(t=(n=i)&&m7t(i)),t}return r._value=e,r}function y7t(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(e==null)return this.tween(t,null);if(typeof e!="function")throw new Error;return this.tween(t,g7t(e))}function b7t(){for(var e=this._name,t=this._id,n=_Pe(),r=this._groups,i=r.length,o=0;o<i;++o)for(var s=r[o],a=s.length,l,u=0;u<a;++u)if(l=s[u]){var c=cc(l,t);$D(l,e,n,u,s,{time:c.time+c.delay+c.duration,delay:0,duration:c.duration,ease:c.ease})}return new Vh(r,this._parents,e,n)}function v7t(){var e,t,n=this,r=n._id,i=n.size();return new Promise(function(o,s){var a={value:s},l={value:function(){--i===0&&o()}};n.each(function(){var u=Ud(this,r),c=u.on;c!==e&&(t=(e=c).copy(),t._.cancel.push(a),t._.interrupt.push(a),t._.end.push(l)),u.on=t}),i===0&&o()})}var x7t=0;function Vh(e,t,n,r){this._groups=e,this._parents=t,this._name=n,this._id=r}function _Pe(){return++x7t}var vf=AA.prototype;Vh.prototype={constructor:Vh,select:e7t,selectAll:t7t,selectChild:vf.selectChild,selectChildren:vf.selectChildren,filter:GBt,merge:KBt,selection:r7t,transition:b7t,call:vf.call,nodes:vf.nodes,node:vf.node,size:vf.size,empty:vf.empty,each:vf.each,on:QBt,attr:_Bt,attrTween:jBt,style:l7t,styleTween:d7t,text:p7t,textTween:y7t,remove:JBt,tween:CBt,delay:zBt,duration:HBt,ease:VBt,easeVarying:qBt,end:v7t,[Symbol.iterator]:vf[Symbol.iterator]};function w7t(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var S7t={time:null,delay:0,duration:250,ease:w7t};function k7t(e,t){for(var n;!(n=e.__transition)||!(n=n[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return n}function C7t(e){var t,n;e instanceof Vh?(t=e._id,e=e._name):(t=_Pe(),(n=S7t).time=AQ(),e=e==null?null:e+"");for(var r=this._groups,i=r.length,o=0;o<i;++o)for(var s=r[o],a=s.length,l,u=0;u<a;++u)(l=s[u])&&$D(l,e,t,u,s,n||k7t(l,t));return new Vh(r,this._parents,e,t)}AA.prototype.interrupt=wBt;AA.prototype.transition=C7t;const wM=e=>()=>e;function E7t(e,{sourceEvent:t,target:n,transform:r,dispatch:i}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},transform:{value:r,enumerable:!0,configurable:!0},_:{value:i}})}function yh(e,t,n){this.k=e,this.x=t,this.y=n}yh.prototype={constructor:yh,scale:function(e){return e===1?this:new yh(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new yh(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var zD=new yh(1,0,0);NPe.prototype=yh.prototype;function NPe(e){for(;!e.__zoom;)if(!(e=e.parentNode))return zD;return e.__zoom}function n7(e){e.stopImmediatePropagation()}function Nk(e){e.preventDefault(),e.stopImmediatePropagation()}function T7t(e){return(!e.ctrlKey||e.type==="wheel")&&!e.button}function A7t(){var e=this;return e instanceof SVGElement?(e=e.ownerSVGElement||e,e.hasAttribute("viewBox")?(e=e.viewBox.baseVal,[[e.x,e.y],[e.x+e.width,e.y+e.height]]):[[0,0],[e.width.baseVal.value,e.height.baseVal.value]]):[[0,0],[e.clientWidth,e.clientHeight]]}function m0e(){return this.__zoom||zD}function O7t(e){return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*(e.ctrlKey?10:1)}function R7t(){return navigator.maxTouchPoints||"ontouchstart"in this}function M7t(e,t,n){var r=e.invertX(t[0][0])-n[0][0],i=e.invertX(t[1][0])-n[1][0],o=e.invertY(t[0][1])-n[0][1],s=e.invertY(t[1][1])-n[1][1];return e.translate(i>r?(r+i)/2:Math.min(0,r)||Math.max(0,i),s>o?(o+s)/2:Math.min(0,o)||Math.max(0,s))}function LPe(){var e=T7t,t=A7t,n=M7t,r=O7t,i=R7t,o=[0,1/0],s=[[-1/0,-1/0],[1/0,1/0]],a=250,l=k_,u=PD("start","zoom","end"),c,d,h,m=500,g=150,b=0,v=10;function w($){$.property("__zoom",m0e).on("wheel.zoom",N,{passive:!1}).on("mousedown.zoom",I).on("dblclick.zoom",D).filter(i).on("touchstart.zoom",P).on("touchmove.zoom",F).on("touchend.zoom touchcancel.zoom",z).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}w.transform=function($,B,H,U){var W=$.selection?$.selection():$;W.property("__zoom",m0e),$!==W?T($,B,H,U):W.interrupt().each(function(){O(this,arguments).event(U).start().zoom(null,typeof B=="function"?B.apply(this,arguments):B).end()})},w.scaleBy=function($,B,H,U){w.scaleTo($,function(){var W=this.__zoom.k,q=typeof B=="function"?B.apply(this,arguments):B;return W*q},H,U)},w.scaleTo=function($,B,H,U){w.transform($,function(){var W=t.apply(this,arguments),q=this.__zoom,Y=H==null?E(W):typeof H=="function"?H.apply(this,arguments):H,Q=q.invert(Y),G=typeof B=="function"?B.apply(this,arguments):B;return n(C(S(q,G),Y,Q),W,s)},H,U)},w.translateBy=function($,B,H,U){w.transform($,function(){return n(this.__zoom.translate(typeof B=="function"?B.apply(this,arguments):B,typeof H=="function"?H.apply(this,arguments):H),t.apply(this,arguments),s)},null,U)},w.translateTo=function($,B,H,U,W){w.transform($,function(){var q=t.apply(this,arguments),Y=this.__zoom,Q=U==null?E(q):typeof U=="function"?U.apply(this,arguments):U;return n(zD.translate(Q[0],Q[1]).scale(Y.k).translate(typeof B=="function"?-B.apply(this,arguments):-B,typeof H=="function"?-H.apply(this,arguments):-H),q,s)},U,W)};function S($,B){return B=Math.max(o[0],Math.min(o[1],B)),B===$.k?$:new yh(B,$.x,$.y)}function C($,B,H){var U=B[0]-H[0]*$.k,W=B[1]-H[1]*$.k;return U===$.x&&W===$.y?$:new yh($.k,U,W)}function E($){return[(+$[0][0]+ +$[1][0])/2,(+$[0][1]+ +$[1][1])/2]}function T($,B,H,U){$.on("start.zoom",function(){O(this,arguments).event(U).start()}).on("interrupt.zoom end.zoom",function(){O(this,arguments).event(U).end()}).tween("zoom",function(){var W=this,q=arguments,Y=O(W,q).event(U),Q=t.apply(W,q),G=H==null?E(Q):typeof H=="function"?H.apply(W,q):H,le=Math.max(Q[1][0]-Q[0][0],Q[1][1]-Q[0][1]),K=W.__zoom,te=typeof B=="function"?B.apply(W,q):B,de=l(K.invert(G).concat(le/K.k),te.invert(G).concat(le/te.k));return function(ue){if(ue===1)ue=te;else{var ae=de(ue),ie=le/ae[2];ue=new yh(ie,G[0]-ae[0]*ie,G[1]-ae[1]*ie)}Y.zoom(null,ue)}})}function O($,B,H){return!H&&$.__zooming||new M($,B)}function M($,B){this.that=$,this.args=B,this.active=0,this.sourceEvent=null,this.extent=t.apply($,B),this.taps=0}M.prototype={event:function($){return $&&(this.sourceEvent=$),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function($,B){return this.mouse&&$!=="mouse"&&(this.mouse[1]=B.invert(this.mouse[0])),this.touch0&&$!=="touch"&&(this.touch0[1]=B.invert(this.touch0[0])),this.touch1&&$!=="touch"&&(this.touch1[1]=B.invert(this.touch1[0])),this.that.__zoom=B,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function($){var B=al(this.that).datum();u.call($,this.that,new E7t($,{sourceEvent:this.sourceEvent,target:w,transform:this.that.__zoom,dispatch:u}),B)}};function N($,...B){if(!e.apply(this,arguments))return;var H=O(this,B).event($),U=this.__zoom,W=Math.max(o[0],Math.min(o[1],U.k*Math.pow(2,r.apply(this,arguments)))),q=Fu($);if(H.wheel)(H.mouse[0][0]!==q[0]||H.mouse[0][1]!==q[1])&&(H.mouse[1]=U.invert(H.mouse[0]=q)),clearTimeout(H.wheel);else{if(U.k===W)return;H.mouse=[q,U.invert(q)],F_(this),H.start()}Nk($),H.wheel=setTimeout(Y,g),H.zoom("mouse",n(C(S(U,W),H.mouse[0],H.mouse[1]),H.extent,s));function Y(){H.wheel=null,H.end()}}function I($,...B){if(h||!e.apply(this,arguments))return;var H=$.currentTarget,U=O(this,B,!0).event($),W=al($.view).on("mousemove.zoom",G,!0).on("mouseup.zoom",le,!0),q=Fu($,H),Y=$.clientX,Q=$.clientY;SPe($.view),n7($),U.mouse=[q,this.__zoom.invert(q)],F_(this),U.start();function G(K){if(Nk(K),!U.moved){var te=K.clientX-Y,de=K.clientY-Q;U.moved=te*te+de*de>b}U.event(K).zoom("mouse",n(C(U.that.__zoom,U.mouse[0]=Fu(K,H),U.mouse[1]),U.extent,s))}function le(K){W.on("mousemove.zoom mouseup.zoom",null),kPe(K.view,U.moved),Nk(K),U.event(K).end()}}function D($,...B){if(e.apply(this,arguments)){var H=this.__zoom,U=Fu($.changedTouches?$.changedTouches[0]:$,this),W=H.invert(U),q=H.k*($.shiftKey?.5:2),Y=n(C(S(H,q),U,W),t.apply(this,B),s);Nk($),a>0?al(this).transition().duration(a).call(T,Y,U,$):al(this).call(w.transform,Y,U,$)}}function P($,...B){if(e.apply(this,arguments)){var H=$.touches,U=H.length,W=O(this,B,$.changedTouches.length===U).event($),q,Y,Q,G;for(n7($),Y=0;Y<U;++Y)Q=H[Y],G=Fu(Q,this),G=[G,this.__zoom.invert(G),Q.identifier],W.touch0?!W.touch1&&W.touch0[2]!==G[2]&&(W.touch1=G,W.taps=0):(W.touch0=G,q=!0,W.taps=1+!!c);c&&(c=clearTimeout(c)),q&&(W.taps<2&&(d=G[0],c=setTimeout(function(){c=null},m)),F_(this),W.start())}}function F($,...B){if(this.__zooming){var H=O(this,B).event($),U=$.changedTouches,W=U.length,q,Y,Q,G;for(Nk($),q=0;q<W;++q)Y=U[q],Q=Fu(Y,this),H.touch0&&H.touch0[2]===Y.identifier?H.touch0[0]=Q:H.touch1&&H.touch1[2]===Y.identifier&&(H.touch1[0]=Q);if(Y=H.that.__zoom,H.touch1){var le=H.touch0[0],K=H.touch0[1],te=H.touch1[0],de=H.touch1[1],ue=(ue=te[0]-le[0])*ue+(ue=te[1]-le[1])*ue,ae=(ae=de[0]-K[0])*ae+(ae=de[1]-K[1])*ae;Y=S(Y,Math.sqrt(ue/ae)),Q=[(le[0]+te[0])/2,(le[1]+te[1])/2],G=[(K[0]+de[0])/2,(K[1]+de[1])/2]}else if(H.touch0)Q=H.touch0[0],G=H.touch0[1];else return;H.zoom("touch",n(C(Y,Q,G),H.extent,s))}}function z($,...B){if(this.__zooming){var H=O(this,B).event($),U=$.changedTouches,W=U.length,q,Y;for(n7($),h&&clearTimeout(h),h=setTimeout(function(){h=null},m),q=0;q<W;++q)Y=U[q],H.touch0&&H.touch0[2]===Y.identifier?delete H.touch0:H.touch1&&H.touch1[2]===Y.identifier&&delete H.touch1;if(H.touch1&&!H.touch0&&(H.touch0=H.touch1,delete H.touch1),H.touch0)H.touch0[1]=this.__zoom.invert(H.touch0[0]);else if(H.end(),H.taps===2&&(Y=Fu(Y,this),Math.hypot(d[0]-Y[0],d[1]-Y[1])<v)){var Q=al(this).on("dblclick.zoom");Q&&Q.apply(this,arguments)}}}return w.wheelDelta=function($){return arguments.length?(r=typeof $=="function"?$:wM(+$),w):r},w.filter=function($){return arguments.length?(e=typeof $=="function"?$:wM(!!$),w):e},w.touchable=function($){return arguments.length?(i=typeof $=="function"?$:wM(!!$),w):i},w.extent=function($){return arguments.length?(t=typeof $=="function"?$:wM([[+$[0][0],+$[0][1]],[+$[1][0],+$[1][1]]]),w):t},w.scaleExtent=function($){return arguments.length?(o[0]=+$[0],o[1]=+$[1],w):[o[0],o[1]]},w.translateExtent=function($){return arguments.length?(s[0][0]=+$[0][0],s[1][0]=+$[1][0],s[0][1]=+$[0][1],s[1][1]=+$[1][1],w):[[s[0][0],s[0][1]],[s[1][0],s[1][1]]]},w.constrain=function($){return arguments.length?(n=$,w):n},w.duration=function($){return arguments.length?(a=+$,w):a},w.interpolate=function($){return arguments.length?(l=$,w):l},w.on=function(){var $=u.on.apply(u,arguments);return $===u?w:$},w.clickDistance=function($){return arguments.length?(b=($=+$)*$,w):Math.sqrt(b)},w.tapDistance=function($){return arguments.length?(v=+$,w):v},w}const oc={error001:(e="react")=>`Seems like you have not used ${e==="svelte"?"SvelteFlowProvider":"ReactFlowProvider"} as an ancestor. Help: https://${e}flow.dev/error#001`,error002:()=>"It looks like you've created a new nodeTypes or edgeTypes object. If this wasn't on purpose please define the nodeTypes/edgeTypes outside of the component or memoize them.",error003:e=>`Node type "${e}" not found. Using fallback type "default".`,error004:()=>"The parent container needs a width and a height to render the graph.",error005:()=>"Only child nodes can use a parent extent.",error006:()=>"Can't create edge. An edge needs a source and a target.",error007:e=>`The old edge with id=${e} does not exist.`,error009:e=>`Marker type "${e}" doesn't exist.`,error008:(e,{id:t,sourceHandle:n,targetHandle:r})=>`Couldn't create edge for ${e} handle id: "${e==="source"?n:r}", edge id: ${t}.`,error010:()=>"Handle: No node id found. Make sure to only use a Handle inside a custom Node.",error011:e=>`Edge type "${e}" not found. Using fallback type "default".`,error012:e=>`Node with id "${e}" does not exist, it may have been removed. This can happen when a node is deleted before the "onNodeClick" handler is called.`,error013:(e="react")=>`It seems that you haven't loaded the styles. Please import '@xyflow/${e}/dist/style.css' or base.css to make sure everything is working properly.`,error014:()=>"useNodeConnections: No node ID found. Call useNodeConnections inside a custom Node or provide a node ID.",error015:()=>"It seems that you are trying to drag a node that is not initialized. Please use onNodesChange as explained in the docs.",error016:e=>`Edge with id "${e}" does not exist, it may have been removed. This can happen when an edge is deleted before the "onEdgeClick" handler is called.`},$T=[[Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY],[Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY]],IPe=["Enter"," ","Escape"],PPe={"node.a11yDescription.default":"Press enter or space to select a node. Press delete to remove it and escape to cancel.","node.a11yDescription.keyboardDisabled":"Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.","node.a11yDescription.ariaLiveMessage":({direction:e,x:t,y:n})=>`Moved selected node ${e}. New position, x: ${t}, y: ${n}`,"edge.a11yDescription.default":"Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.","controls.ariaLabel":"Control Panel","controls.zoomIn.ariaLabel":"Zoom In","controls.zoomOut.ariaLabel":"Zoom Out","controls.fitView.ariaLabel":"Fit View","controls.interactive.ariaLabel":"Toggle Interactivity","minimap.ariaLabel":"Mini Map","handle.ariaLabel":"Handle"};var Mw;(function(e){e.Strict="strict",e.Loose="loose"})(Mw||(Mw={}));var rb;(function(e){e.Free="free",e.Vertical="vertical",e.Horizontal="horizontal"})(rb||(rb={}));var zT;(function(e){e.Partial="partial",e.Full="full"})(zT||(zT={}));const jPe={inProgress:!1,isValid:null,from:null,fromHandle:null,fromPosition:null,fromNode:null,to:null,toHandle:null,toPosition:null,toNode:null,pointer:null};var nh;(function(e){e.Bezier="default",e.Straight="straight",e.Step="step",e.SmoothStep="smoothstep",e.SimpleBezier="simplebezier"})(nh||(nh={}));var FT;(function(e){e.Arrow="arrow",e.ArrowClosed="arrowclosed"})(FT||(FT={}));var Bt;(function(e){e.Left="left",e.Top="top",e.Right="right",e.Bottom="bottom"})(Bt||(Bt={}));const g0e={[Bt.Left]:Bt.Right,[Bt.Right]:Bt.Left,[Bt.Top]:Bt.Bottom,[Bt.Bottom]:Bt.Top},DPe=e=>!!e&&typeof e=="object"&&"id"in e&&"source"in e&&"target"in e,_7t=e=>!!e&&typeof e=="object"&&"id"in e&&"position"in e&&!("source"in e)&&!("target"in e),MQ=e=>!!e&&typeof e=="object"&&"id"in e&&"internals"in e&&!("source"in e)&&!("target"in e),OA=(e,t=[0,0])=>{const{width:n,height:r}=dc(e),i=e.origin??t,o=n*i[0],s=r*i[1];return{x:e.position.x-o,y:e.position.y-s}},N7t=(e,t={nodeOrigin:[0,0]})=>{if(e.length===0)return{x:0,y:0,width:0,height:0};let n=!1;const r=e.reduce((i,o)=>{const s=typeof o=="string";let a=!t.nodeLookup&&!s?o:void 0;return t.nodeLookup&&(a=s?t.nodeLookup.get(o):MQ(o)?o:t.nodeLookup.get(o.id)),a?(n=!0,FD(i,ZI(a,t.nodeOrigin))):i},{x:1/0,y:1/0,x2:-1/0,y2:-1/0});return n?BD(r):{x:0,y:0,width:0,height:0}},yS=(e,t={})=>{let n={x:1/0,y:1/0,x2:-1/0,y2:-1/0},r=!1;return e.forEach(i=>{(t.filter===void 0||t.filter(i))&&(n=FD(n,ZI(i)),r=!0)}),r?BD(n):{x:0,y:0,width:0,height:0}},_Q=(e,t,[n,r,i]=[0,0,1],o=!1,s=!1)=>{const a=(t.x-n)/i,l=(t.y-r)/i,u=t.width/i,c=t.height/i,d=[];for(const h of e.values()){const{measured:m,selectable:g=!0,hidden:b=!1}=h;if(s&&!g||b)continue;const v=m.width??h.width??h.initialWidth??0,w=m.height??h.height??h.initialHeight??0,{x:S,y:C}=h.internals.positionAbsolute,E=BPe(a,l,u,c,S,C,v,w),T=v*w,O=o&&E>0;(!h.internals.handleBounds||O||E>=T||h.dragging)&&d.push(h)}return d},L7t=(e,t)=>{const n=new Set;return e.forEach(r=>{n.add(r.id)}),t.filter(r=>n.has(r.source)||n.has(r.target))};function I7t(e,t){const n=new Map,r=t!=null&&t.nodes?new Set(t.nodes.map(i=>i.id)):null;return e.forEach(i=>{let o;if(t!=null&&t.includeHiddenNodes){const{width:s,height:a}=dc(i);o=s>0&&a>0}else o=!!(i.measured.width&&i.measured.height&&!i.hidden);o&&(!r||r.has(i.id))&&n.set(i.id,i)}),n}async function P7t({nodes:e,width:t,height:n,panZoom:r,minZoom:i,maxZoom:o},s){if(e.size===0)return!0;const a=I7t(e,s),l=yS(a),u=LQ(l,t,n,(s==null?void 0:s.minZoom)??i,(s==null?void 0:s.maxZoom)??o,(s==null?void 0:s.padding)??.1);return await r.setViewport(u,{duration:s==null?void 0:s.duration,ease:s==null?void 0:s.ease,interpolate:s==null?void 0:s.interpolate}),!0}function $Pe({nodeId:e,nextPosition:t,nodeLookup:n,nodeOrigin:r=[0,0],nodeExtent:i,onError:o}){const s=n.get(e),a=s.parentId?n.get(s.parentId):void 0,{x:l,y:u}=a?a.internals.positionAbsolute:{x:0,y:0},c=s.origin??r;let d=s.extent||i;if(s.extent==="parent"&&!s.expandParent)if(!a)o==null||o("005",oc.error005());else{const{width:m,height:g}=dc(a);m&&g&&(d=[[l,u],[l+m,u+g]])}else a&&Tb(s.extent)&&(d=[[s.extent[0][0]+l,s.extent[0][1]+u],[s.extent[1][0]+l,s.extent[1][1]+u]]);const h=Tb(d)?Eb(t,d,s.measured):t;return(s.measured.width===void 0||s.measured.height===void 0)&&(o==null||o("015",oc.error015())),{position:{x:h.x-l+(s.measured.width??0)*c[0],y:h.y-u+(s.measured.height??0)*c[1]},positionAbsolute:h}}async function j7t({nodesToRemove:e=[],edgesToRemove:t=[],nodes:n,edges:r,onBeforeDelete:i}){const o=new Set(e.map(h=>h.id)),s=[];for(const h of n){if(h.deletable===!1)continue;const m=o.has(h.id),g=!m&&h.parentId&&s.find(b=>b.id===h.parentId);(m||g)&&s.push(h)}const a=new Set(t.map(h=>h.id)),l=r.filter(h=>h.deletable!==!1),c=L7t(s,l);for(const h of l)a.has(h.id)&&!c.find(g=>g.id===h.id)&&c.push(h);if(!i)return{edges:c,nodes:s};const d=await i({nodes:s,edges:c});return typeof d=="boolean"?d?{edges:c,nodes:s}:{edges:[],nodes:[]}:d}const _w=(e,t=0,n=1)=>Math.min(Math.max(e,t),n),Eb=(e={x:0,y:0},t,n)=>({x:_w(e.x,t[0][0],t[1][0]-((n==null?void 0:n.width)??0)),y:_w(e.y,t[0][1],t[1][1]-((n==null?void 0:n.height)??0))});function zPe(e,t,n){const{width:r,height:i}=dc(n),{x:o,y:s}=n.internals.positionAbsolute;return Eb(e,[[o,s],[o+r,s+i]],t)}const y0e=(e,t,n)=>e<t?_w(Math.abs(e-t),1,t)/t:e>n?-_w(Math.abs(e-n),1,t)/t:0,NQ=(e,t,n=15,r=40)=>{const i=y0e(e.x,r,t.width-r)*n,o=y0e(e.y,r,t.height-r)*n;return[i,o]},FD=(e,t)=>({x:Math.min(e.x,t.x),y:Math.min(e.y,t.y),x2:Math.max(e.x2,t.x2),y2:Math.max(e.y2,t.y2)}),QW=({x:e,y:t,width:n,height:r})=>({x:e,y:t,x2:e+n,y2:t+r}),BD=({x:e,y:t,x2:n,y2:r})=>({x:e,y:t,width:n-e,height:r-t}),BT=(e,t=[0,0])=>{var i,o;const{x:n,y:r}=MQ(e)?e.internals.positionAbsolute:OA(e,t);return{x:n,y:r,width:((i=e.measured)==null?void 0:i.width)??e.width??e.initialWidth??0,height:((o=e.measured)==null?void 0:o.height)??e.height??e.initialHeight??0}},ZI=(e,t=[0,0])=>{var i,o;const{x:n,y:r}=MQ(e)?e.internals.positionAbsolute:OA(e,t);return{x:n,y:r,x2:n+(((i=e.measured)==null?void 0:i.width)??e.width??e.initialWidth??0),y2:r+(((o=e.measured)==null?void 0:o.height)??e.height??e.initialHeight??0)}},FPe=(e,t)=>BD(FD(QW(e),QW(t))),BPe=(e,t,n,r,i,o,s,a)=>{const l=Math.max(0,Math.min(e+n,i+s)-Math.max(e,i)),u=Math.max(0,Math.min(t+r,o+a)-Math.max(t,o));return Math.ceil(l*u)},JI=(e,t)=>BPe(e.x,e.y,e.width,e.height,t.x,t.y,t.width,t.height),b0e=e=>Qu(e.width)&&Qu(e.height)&&Qu(e.x)&&Qu(e.y),Qu=e=>!isNaN(e)&&isFinite(e),HPe=(e,t)=>(n,r)=>{},RA=(e,t=[1,1])=>({x:t[0]*Math.round(e.x/t[0]),y:t[1]*Math.round(e.y/t[1])}),MA=({x:e,y:t},[n,r,i],o=!1,s=[1,1])=>{const a={x:(e-n)/i,y:(t-r)/i};return o?RA(a,s):a},Nw=({x:e,y:t},[n,r,i])=>({x:e*i+n,y:t*i+r});function Uv(e,t){if(typeof e=="number")return Math.floor((t-t/(1+e))*.5);if(typeof e=="string"&&e.endsWith("px")){const n=parseFloat(e);if(!Number.isNaN(n))return Math.floor(n)}if(typeof e=="string"&&e.endsWith("%")){const n=parseFloat(e);if(!Number.isNaN(n))return Math.floor(t*n*.01)}return console.error(`The padding value "${e}" is invalid. Please provide a number or a string with a valid unit (px or %).`),0}function D7t(e,t,n){if(typeof e=="string"||typeof e=="number"){const r=Uv(e,n),i=Uv(e,t);return{top:r,right:i,bottom:r,left:i,x:i*2,y:r*2}}if(typeof e=="object"){const r=Uv(e.top??e.y??0,n),i=Uv(e.bottom??e.y??0,n),o=Uv(e.left??e.x??0,t),s=Uv(e.right??e.x??0,t);return{top:r,right:s,bottom:i,left:o,x:o+s,y:r+i}}return{top:0,right:0,bottom:0,left:0,x:0,y:0}}function $7t(e,t,n,r,i,o){const{x:s,y:a}=Nw(e,[t,n,r]),{x:l,y:u}=Nw({x:e.x+e.width,y:e.y+e.height},[t,n,r]),c=i-l,d=o-u;return{left:Math.floor(s),top:Math.floor(a),right:Math.floor(c),bottom:Math.floor(d)}}const LQ=(e,t,n,r,i,o)=>{const s=D7t(o,t,n),a=(t-s.x)/e.width,l=(n-s.y)/e.height,u=Math.min(a,l),c=_w(u,r,i),d=e.x+e.width/2,h=e.y+e.height/2,m=t/2-d*c,g=n/2-h*c,b=$7t(e,m,g,c,t,n),v={left:Math.min(b.left-s.left,0),top:Math.min(b.top-s.top,0),right:Math.min(b.right-s.right,0),bottom:Math.min(b.bottom-s.bottom,0)};return{x:m-v.left+v.right,y:g-v.top+v.bottom,zoom:c}},HT=()=>{var e;return typeof navigator<"u"&&((e=navigator==null?void 0:navigator.userAgent)==null?void 0:e.indexOf("Mac"))>=0};function Tb(e){return e!=null&&e!=="parent"}function dc(e){var t,n;return{width:((t=e.measured)==null?void 0:t.width)??e.width??e.initialWidth??0,height:((n=e.measured)==null?void 0:n.height)??e.height??e.initialHeight??0}}function UPe(e){var t,n;return(((t=e.measured)==null?void 0:t.width)??e.width??e.initialWidth)!==void 0&&(((n=e.measured)==null?void 0:n.height)??e.height??e.initialHeight)!==void 0}function VPe(e,t={width:0,height:0},n,r,i){const o={...e},s=r.get(n);if(s){const a=s.origin||i;o.x+=s.internals.positionAbsolute.x-(t.width??0)*a[0],o.y+=s.internals.positionAbsolute.y-(t.height??0)*a[1]}return o}function v0e(e,t){if(e.size!==t.size)return!1;for(const n of e)if(!t.has(n))return!1;return!0}function z7t(){let e,t;return{promise:new Promise((r,i)=>{e=r,t=i}),resolve:e,reject:t}}function F7t(e){return{...PPe,...e||{}}}function WPe(e){return e===null?null:e?"valid":"invalid"}function iE(e,{snapGrid:t=[0,0],snapToGrid:n=!1,transform:r,containerBounds:i}){const{x:o,y:s}=Zu(e),a=MA({x:o-((i==null?void 0:i.left)??0),y:s-((i==null?void 0:i.top)??0)},r),{x:l,y:u}=n?RA(a,t):a;return{xSnapped:l,ySnapped:u,...a}}const IQ=e=>({width:e.offsetWidth,height:e.offsetHeight}),qPe=e=>{var t;return((t=e==null?void 0:e.getRootNode)==null?void 0:t.call(e))||(window==null?void 0:window.document)},B7t=["INPUT","SELECT","TEXTAREA"];function GPe(e){var r,i;const t=((i=(r=e.composedPath)==null?void 0:r.call(e))==null?void 0:i[0])||e.target;return(t==null?void 0:t.nodeType)!==1?!1:B7t.includes(t.nodeName)||t.hasAttribute("contenteditable")||!!t.closest(".nokey")}const KPe=e=>"clientX"in e,Zu=(e,t)=>{var o,s;const n=KPe(e),r=n?e.clientX:(o=e.touches)==null?void 0:o[0].clientX,i=n?e.clientY:(s=e.touches)==null?void 0:s[0].clientY;return{x:r-((t==null?void 0:t.left)??0),y:i-((t==null?void 0:t.top)??0)}},x0e=(e,t,n,r,i)=>{const o=t.querySelectorAll(`.${e}`);return!o||!o.length?null:Array.from(o).map(s=>{const a=s.getBoundingClientRect();return{id:s.getAttribute("data-handleid"),type:e,nodeId:i,position:s.getAttribute("data-handlepos"),x:(a.left-n.left)/r,y:(a.top-n.top)/r,...IQ(s)}})};function YPe({sourceX:e,sourceY:t,targetX:n,targetY:r,sourceControlX:i,sourceControlY:o,targetControlX:s,targetControlY:a}){const l=e*.125+i*.375+s*.375+n*.125,u=t*.125+o*.375+a*.375+r*.125,c=Math.abs(l-e),d=Math.abs(u-t);return[l,u,c,d]}function SM(e,t){return e>=0?.5*e:t*25*Math.sqrt(-e)}function w0e({pos:e,x1:t,y1:n,x2:r,y2:i,c:o}){switch(e){case Bt.Left:return[t-SM(t-r,o),n];case Bt.Right:return[t+SM(r-t,o),n];case Bt.Top:return[t,n-SM(n-i,o)];case Bt.Bottom:return[t,n+SM(i-n,o)]}}function XPe({sourceX:e,sourceY:t,sourcePosition:n=Bt.Bottom,targetX:r,targetY:i,targetPosition:o=Bt.Top,curvature:s=.25}){const[a,l]=w0e({pos:n,x1:e,y1:t,x2:r,y2:i,c:s}),[u,c]=w0e({pos:o,x1:r,y1:i,x2:e,y2:t,c:s}),[d,h,m,g]=YPe({sourceX:e,sourceY:t,targetX:r,targetY:i,sourceControlX:a,sourceControlY:l,targetControlX:u,targetControlY:c});return[`M${e},${t} C${a},${l} ${u},${c} ${r},${i}`,d,h,m,g]}function QPe({sourceX:e,sourceY:t,targetX:n,targetY:r}){const i=Math.abs(n-e)/2,o=n<e?n+i:n-i,s=Math.abs(r-t)/2,a=r<t?r+s:r-s;return[o,a,i,s]}function H7t({sourceNode:e,targetNode:t,selected:n=!1,zIndex:r=0,elevateOnSelect:i=!1,zIndexMode:o="basic"}){if(o==="manual")return r;const s=i&&n?r+1e3:r,a=Math.max(e.parentId||i&&e.selected?e.internals.z:0,t.parentId||i&&t.selected?t.internals.z:0);return s+a}function U7t({sourceNode:e,targetNode:t,width:n,height:r,transform:i}){const o=FD(ZI(e),ZI(t));o.x===o.x2&&(o.x2+=1),o.y===o.y2&&(o.y2+=1);const s={x:-i[0]/i[2],y:-i[1]/i[2],width:n/i[2],height:r/i[2]};return JI(s,BD(o))>0}const V7t=({source:e,sourceHandle:t,target:n,targetHandle:r})=>`xy-edge__${e}${t||""}-${n}${r||""}`,W7t=(e,t)=>t.some(n=>n.source===e.source&&n.target===e.target&&(n.sourceHandle===e.sourceHandle||!n.sourceHandle&&!e.sourceHandle)&&(n.targetHandle===e.targetHandle||!n.targetHandle&&!e.targetHandle)),q7t=(e,t,n={})=>{var o;if(!e.source||!e.target)return(o=n.onError)==null||o.call(n,"006",oc.error006()),t;const r=n.getEdgeId||V7t;let i;return DPe(e)?i={...e}:i={...e,id:r(e)},W7t(i,t)?t:(i.sourceHandle===null&&delete i.sourceHandle,i.targetHandle===null&&delete i.targetHandle,t.concat(i))};function ZPe({sourceX:e,sourceY:t,targetX:n,targetY:r}){const[i,o,s,a]=QPe({sourceX:e,sourceY:t,targetX:n,targetY:r});return[`M ${e},${t}L ${n},${r}`,i,o,s,a]}const S0e={[Bt.Left]:{x:-1,y:0},[Bt.Right]:{x:1,y:0},[Bt.Top]:{x:0,y:-1},[Bt.Bottom]:{x:0,y:1}},G7t=({source:e,sourcePosition:t=Bt.Bottom,target:n})=>t===Bt.Left||t===Bt.Right?e.x<n.x?{x:1,y:0}:{x:-1,y:0}:e.y<n.y?{x:0,y:1}:{x:0,y:-1},k0e=(e,t)=>Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2));function K7t({source:e,sourcePosition:t=Bt.Bottom,target:n,targetPosition:r=Bt.Top,center:i,offset:o,stepPosition:s}){const a=S0e[t],l=S0e[r],u={x:e.x+a.x*o,y:e.y+a.y*o},c={x:n.x+l.x*o,y:n.y+l.y*o},d=G7t({source:u,sourcePosition:t,target:c}),h=d.x!==0?"x":"y",m=d[h];let g=[],b,v;const w={x:0,y:0},S={x:0,y:0},[,,C,E]=QPe({sourceX:e.x,sourceY:e.y,targetX:n.x,targetY:n.y});if(a[h]*l[h]===-1){h==="x"?(b=i.x??u.x+(c.x-u.x)*s,v=i.y??(u.y+c.y)/2):(b=i.x??(u.x+c.x)/2,v=i.y??u.y+(c.y-u.y)*s);const N=[{x:b,y:u.y},{x:b,y:c.y}],I=[{x:u.x,y:v},{x:c.x,y:v}];a[h]===m?g=h==="x"?N:I:g=h==="x"?I:N}else{const N=[{x:u.x,y:c.y}],I=[{x:c.x,y:u.y}];if(h==="x"?g=a.x===m?I:N:g=a.y===m?N:I,t===r){const $=Math.abs(e[h]-n[h]);if($<=o){const B=Math.min(o-1,o-$);a[h]===m?w[h]=(u[h]>e[h]?-1:1)*B:S[h]=(c[h]>n[h]?-1:1)*B}}if(t!==r){const $=h==="x"?"y":"x",B=a[h]===l[$],H=u[$]>c[$],U=u[$]<c[$];(a[h]===1&&(!B&&H||B&&U)||a[h]!==1&&(!B&&U||B&&H))&&(g=h==="x"?N:I)}const D={x:u.x+w.x,y:u.y+w.y},P={x:c.x+S.x,y:c.y+S.y},F=Math.max(Math.abs(D.x-g[0].x),Math.abs(P.x-g[0].x)),z=Math.max(Math.abs(D.y-g[0].y),Math.abs(P.y-g[0].y));F>=z?(b=(D.x+P.x)/2,v=g[0].y):(b=g[0].x,v=(D.y+P.y)/2)}const T={x:u.x+w.x,y:u.y+w.y},O={x:c.x+S.x,y:c.y+S.y};return[[e,...T.x!==g[0].x||T.y!==g[0].y?[T]:[],...g,...O.x!==g[g.length-1].x||O.y!==g[g.length-1].y?[O]:[],n],b,v,C,E]}function Y7t(e,t,n,r){const i=Math.min(k0e(e,t)/2,k0e(t,n)/2,r),{x:o,y:s}=t;if(e.x===o&&o===n.x||e.y===s&&s===n.y)return`L${o} ${s}`;if(e.y===s){const u=e.x<n.x?-1:1,c=e.y<n.y?1:-1;return`L ${o+i*u},${s}Q ${o},${s} ${o},${s+i*c}`}const a=e.x<n.x?1:-1,l=e.y<n.y?-1:1;return`L ${o},${s+i*l}Q ${o},${s} ${o+i*a},${s}`}function UT({sourceX:e,sourceY:t,sourcePosition:n=Bt.Bottom,targetX:r,targetY:i,targetPosition:o=Bt.Top,borderRadius:s=5,centerX:a,centerY:l,offset:u=20,stepPosition:c=.5}){const[d,h,m,g,b]=K7t({source:{x:e,y:t},sourcePosition:n,target:{x:r,y:i},targetPosition:o,center:{x:a,y:l},offset:u,stepPosition:c});let v=`M${d[0].x} ${d[0].y}`;for(let w=1;w<d.length-1;w++)v+=Y7t(d[w-1],d[w],d[w+1],s);return v+=`L${d[d.length-1].x} ${d[d.length-1].y}`,[v,h,m,g,b]}function C0e(e){var t;return e&&!!(e.internals.handleBounds||(t=e.handles)!=null&&t.length)&&!!(e.measured.width||e.width||e.initialWidth)}function X7t(e){var d;const{sourceNode:t,targetNode:n}=e;if(!C0e(t)||!C0e(n))return null;const r=t.internals.handleBounds||E0e(t.handles),i=n.internals.handleBounds||E0e(n.handles),o=T0e((r==null?void 0:r.source)??[],e.sourceHandle),s=T0e(e.connectionMode===Mw.Strict?(i==null?void 0:i.target)??[]:((i==null?void 0:i.target)??[]).concat((i==null?void 0:i.source)??[]),e.targetHandle);if(!o||!s)return(d=e.onError)==null||d.call(e,"008",oc.error008(o?"target":"source",{id:e.id,sourceHandle:e.sourceHandle,targetHandle:e.targetHandle})),null;const a=(o==null?void 0:o.position)||Bt.Bottom,l=(s==null?void 0:s.position)||Bt.Top,u=Ab(t,o,a),c=Ab(n,s,l);return{sourceX:u.x,sourceY:u.y,targetX:c.x,targetY:c.y,sourcePosition:a,targetPosition:l}}function E0e(e){if(!e)return null;const t=[],n=[];for(const r of e)r.width=r.width??1,r.height=r.height??1,r.type==="source"?t.push(r):r.type==="target"&&n.push(r);return{source:t,target:n}}function Ab(e,t,n=Bt.Left,r=!1){const i=((t==null?void 0:t.x)??0)+e.internals.positionAbsolute.x,o=((t==null?void 0:t.y)??0)+e.internals.positionAbsolute.y,{width:s,height:a}=t??dc(e);if(r)return{x:i+s/2,y:o+a/2};switch((t==null?void 0:t.position)??n){case Bt.Top:return{x:i+s/2,y:o};case Bt.Right:return{x:i+s,y:o+a/2};case Bt.Bottom:return{x:i+s/2,y:o+a};case Bt.Left:return{x:i,y:o+a/2}}}function T0e(e,t){return e&&(t?e.find(n=>n.id===t):e[0])||null}function ZW(e,t){return e?typeof e=="string"?e:`${t?`${t}__`:""}${Object.keys(e).sort().map(r=>`${r}=${e[r]}`).join("&")}`:""}function Q7t(e,{id:t,defaultColor:n,defaultMarkerStart:r,defaultMarkerEnd:i}){const o=new Set;return e.reduce((s,a)=>([a.markerStart||r,a.markerEnd||i].forEach(l=>{if(l&&typeof l=="object"){const u=ZW(l,t);o.has(u)||(s.push({id:u,color:l.color||n,...l}),o.add(u))}}),s),[]).sort((s,a)=>s.id.localeCompare(a.id))}function Z7t(e,t,n,r,i){let o=.5;i==="start"?o=0:i==="end"&&(o=1);let s=[(e.x+e.width*o)*t.zoom+t.x,e.y*t.zoom+t.y-r],a=[-100*o,-100];switch(n){case Bt.Right:s=[(e.x+e.width)*t.zoom+t.x+r,(e.y+e.height*o)*t.zoom+t.y],a=[0,-100*o];break;case Bt.Bottom:s[1]=(e.y+e.height)*t.zoom+t.y+r,a[1]=0;break;case Bt.Left:s=[e.x*t.zoom+t.x-r,(e.y+e.height*o)*t.zoom+t.y],a=[-100,-100*o];break}return`translate(${s[0]}px, ${s[1]}px) translate(${a[0]}%, ${a[1]}%)`}const JPe=1e3,J7t=10,PQ={nodeOrigin:[0,0],nodeExtent:$T,elevateNodesOnSelect:!0,zIndexMode:"basic",defaults:{}},e9t={...PQ,checkEquality:!0};function jQ(e,t){const n={...e};for(const r in t)t[r]!==void 0&&(n[r]=t[r]);return n}function t9t(e,t,n){const r=jQ(PQ,n);for(const i of e.values())if(i.parentId)$Q(i,e,t,r);else{const o=OA(i,r.nodeOrigin),s=Tb(i.extent)?i.extent:r.nodeExtent,a=Eb(o,s,dc(i));i.internals.positionAbsolute=a}}function n9t(e,t){if(!e.handles)return e.measured?t==null?void 0:t.internals.handleBounds:void 0;const n=[],r=[];for(const i of e.handles){const o={id:i.id,width:i.width??1,height:i.height??1,nodeId:e.id,x:i.x,y:i.y,position:i.position,type:i.type};i.type==="source"?n.push(o):i.type==="target"&&r.push(o)}return{source:n,target:r}}function DQ(e){return e==="manual"}function JW(e,t,n,r={}){var c,d;const i=jQ(e9t,r),o={i:0},s=new Map(t),a=i!=null&&i.elevateNodesOnSelect&&!DQ(i.zIndexMode)?JPe:0;let l=e.length>0,u=!1;t.clear(),n.clear();for(const h of e){let m=s.get(h.id);if(i.checkEquality&&h===(m==null?void 0:m.internals.userNode))t.set(h.id,m);else{const g=OA(h,i.nodeOrigin),b=Tb(h.extent)?h.extent:i.nodeExtent,v=Eb(g,b,dc(h));m={...i.defaults,...h,measured:{width:(c=h.measured)==null?void 0:c.width,height:(d=h.measured)==null?void 0:d.height},internals:{positionAbsolute:v,handleBounds:n9t(h,m),z:eje(h,a,i.zIndexMode),userNode:h}},t.set(h.id,m)}(m.measured===void 0||m.measured.width===void 0||m.measured.height===void 0)&&!m.hidden&&(l=!1),h.parentId&&$Q(m,t,n,r,o),u||(u=h.selected??!1)}return{nodesInitialized:l,hasSelectedNodes:u}}function r9t(e,t){if(!e.parentId)return;const n=t.get(e.parentId);n?n.set(e.id,e):t.set(e.parentId,new Map([[e.id,e]]))}function $Q(e,t,n,r,i){const{elevateNodesOnSelect:o,nodeOrigin:s,nodeExtent:a,zIndexMode:l}=jQ(PQ,r),u=e.parentId,c=t.get(u);if(!c){console.warn(`Parent node ${u} not found. Please make sure that parent nodes are in front of their child nodes in the nodes array.`);return}r9t(e,n),i&&!c.parentId&&c.internals.rootParentIndex===void 0&&l==="auto"&&(c.internals.rootParentIndex=++i.i,c.internals.z=c.internals.z+i.i*J7t),i&&c.internals.rootParentIndex!==void 0&&(i.i=c.internals.rootParentIndex);const d=o&&!DQ(l)?JPe:0,{x:h,y:m,z:g}=i9t(e,c,s,a,d,l),{positionAbsolute:b}=e.internals,v=h!==b.x||m!==b.y;(v||g!==e.internals.z)&&t.set(e.id,{...e,internals:{...e.internals,positionAbsolute:v?{x:h,y:m}:b,z:g}})}function eje(e,t,n){const r=Qu(e.zIndex)?e.zIndex:0;return DQ(n)?r:r+(e.selected?t:0)}function i9t(e,t,n,r,i,o){const{x:s,y:a}=t.internals.positionAbsolute,l=dc(e),u=OA(e,n),c=Tb(e.extent)?Eb(u,e.extent,l):u;let d=Eb({x:s+c.x,y:a+c.y},r,l);e.extent==="parent"&&(d=zPe(d,l,t));const h=eje(e,i,o),m=t.internals.z??0;return{x:d.x,y:d.y,z:m>=h?m+1:h}}function zQ(e,t,n,r=[0,0]){var s;const i=[],o=new Map;for(const a of e){const l=t.get(a.parentId);if(!l)continue;const u=((s=o.get(a.parentId))==null?void 0:s.expandedRect)??BT(l),c=FPe(u,a.rect);o.set(a.parentId,{expandedRect:c,parent:l})}return o.size>0&&o.forEach(({expandedRect:a,parent:l},u)=>{var C;const c=l.internals.positionAbsolute,d=dc(l),h=l.origin??r,m=a.x<c.x?Math.round(Math.abs(c.x-a.x)):0,g=a.y<c.y?Math.round(Math.abs(c.y-a.y)):0,b=Math.max(d.width,Math.round(a.width)),v=Math.max(d.height,Math.round(a.height)),w=(b-d.width)*h[0],S=(v-d.height)*h[1];(m>0||g>0||w||S)&&(i.push({id:u,type:"position",position:{x:l.position.x-m+w,y:l.position.y-g+S}}),(C=n.get(u))==null||C.forEach(E=>{e.some(T=>T.id===E.id)||i.push({id:E.id,type:"position",position:{x:E.position.x+m,y:E.position.y+g}})})),(d.width<a.width||d.height<a.height||m||g)&&i.push({id:u,type:"dimensions",setAttributes:!0,dimensions:{width:b+(m?h[0]*m-w:0),height:v+(g?h[1]*g-S:0)}})}),i}function o9t(e,t,n,r,i,o,s){const a=r==null?void 0:r.querySelector(".xyflow__viewport");let l=!1;if(!a)return{changes:[],updatedInternals:l};const u=[],c=window.getComputedStyle(a),{m22:d}=new window.DOMMatrixReadOnly(c.transform),h=[];for(const m of e.values()){const g=t.get(m.id);if(!g)continue;if(g.hidden){t.set(g.id,{...g,internals:{...g.internals,handleBounds:void 0}}),l=!0;continue}const b=IQ(m.nodeElement),v=g.measured.width!==b.width||g.measured.height!==b.height;if(!!(b.width&&b.height&&(v||!g.internals.handleBounds||m.force))){const S=m.nodeElement.getBoundingClientRect(),C=Tb(g.extent)?g.extent:o;let{positionAbsolute:E}=g.internals;if(g.parentId&&g.extent==="parent"){const O=t.get(g.parentId);O&&(E=zPe(E,b,O))}else C&&(E=Eb(E,C,b));const T={...g,measured:b,internals:{...g.internals,positionAbsolute:E,handleBounds:{source:x0e("source",m.nodeElement,S,d,g.id),target:x0e("target",m.nodeElement,S,d,g.id)}}};t.set(g.id,T),g.parentId&&$Q(T,t,n,{nodeOrigin:i,zIndexMode:s}),l=!0,v&&(u.push({id:g.id,type:"dimensions",dimensions:b}),g.expandParent&&g.parentId&&h.push({id:g.id,parentId:g.parentId,rect:BT(T,i)}))}}if(h.length>0){const m=zQ(h,t,n,i);u.push(...m)}return{changes:u,updatedInternals:l}}async function s9t({delta:e,panZoom:t,transform:n,translateExtent:r,width:i,height:o}){if(!t||!e.x&&!e.y)return!1;const s=await t.setViewportConstrained({x:n[0]+e.x,y:n[1]+e.y,zoom:n[2]},[[0,0],[i,o]],r);return!!s&&(s.x!==n[0]||s.y!==n[1]||s.k!==n[2])}function A0e(e,t,n,r,i,o){let s=i;const a=r.get(s)||new Map;r.set(s,a.set(n,t)),s=`${i}-${e}`;const l=r.get(s)||new Map;if(r.set(s,l.set(n,t)),o){s=`${i}-${e}-${o}`;const u=r.get(s)||new Map;r.set(s,u.set(n,t))}}function tje(e,t,n){e.clear(),t.clear();for(const r of n){const{source:i,target:o,sourceHandle:s=null,targetHandle:a=null}=r,l={edgeId:r.id,source:i,target:o,sourceHandle:s,targetHandle:a},u=`${i}-${s}--${o}-${a}`,c=`${o}-${a}--${i}-${s}`;A0e("source",l,c,e,i,s),A0e("target",l,u,e,o,a),t.set(r.id,r)}}function nje(e,t){if(!e.parentId)return!1;const n=t.get(e.parentId);return n?n.selected?!0:nje(n,t):!1}function O0e(e,t,n){var i;let r=e;do{if((i=r==null?void 0:r.matches)!=null&&i.call(r,t))return!0;if(r===n)return!1;r=r==null?void 0:r.parentElement}while(r);return!1}function a9t(e,t,n,r){const i=new Map;for(const[o,s]of e)if((s.selected||s.id===r)&&(!s.parentId||!nje(s,e))&&(s.draggable||t&&typeof s.draggable>"u")){const a=e.get(o);a&&i.set(o,{id:o,position:a.position||{x:0,y:0},distance:{x:n.x-a.internals.positionAbsolute.x,y:n.y-a.internals.positionAbsolute.y},extent:a.extent,parentId:a.parentId,origin:a.origin,expandParent:a.expandParent,internals:{positionAbsolute:a.internals.positionAbsolute||{x:0,y:0}},measured:{width:a.measured.width??0,height:a.measured.height??0}})}return i}function r7({nodeId:e,dragItems:t,nodeLookup:n,dragging:r=!0}){var s,a,l;const i=[];for(const[u,c]of t){const d=(s=n.get(u))==null?void 0:s.internals.userNode;d&&i.push({...d,position:c.position,dragging:r})}if(!e)return[i[0],i];const o=(a=n.get(e))==null?void 0:a.internals.userNode;return[o?{...o,position:((l=t.get(e))==null?void 0:l.position)||o.position,dragging:r}:i[0],i]}function l9t({dragItems:e,snapGrid:t,x:n,y:r}){const i=e.values().next().value;if(!i)return null;const o={x:n-i.distance.x,y:r-i.distance.y},s=RA(o,t);return{x:s.x-o.x,y:s.y-o.y}}function u9t({onNodeMouseDown:e,getStoreItems:t,onDragStart:n,onDrag:r,onDragStop:i}){let o={x:null,y:null},s=0,a=new Map,l=!1,u={x:0,y:0},c=null,d=!1,h=null,m=!1,g=!1,b=null;function v({noDragClassName:S,handleSelector:C,domNode:E,isSelectable:T,nodeId:O,nodeClickDistance:M=0}){h=al(E);function N({x:F,y:z}){const{nodeLookup:$,nodeExtent:B,snapGrid:H,snapToGrid:U,nodeOrigin:W,onNodeDrag:q,onSelectionDrag:Y,onError:Q,updateNodePositions:G}=t();o={x:F,y:z};let le=!1;const K=a.size>1,te=K&&B?QW(yS(a)):null,de=K&&U?l9t({dragItems:a,snapGrid:H,x:F,y:z}):null;for(const[ue,ae]of a){if(!$.has(ue))continue;let ie={x:F-ae.distance.x,y:z-ae.distance.y};U&&(ie=de?{x:Math.round(ie.x+de.x),y:Math.round(ie.y+de.y)}:RA(ie,H));let he=null;if(K&&B&&!ae.extent&&te){const{positionAbsolute:Se}=ae.internals,pe=Se.x-te.x+B[0][0],Ee=Se.x+ae.measured.width-te.x2+B[1][0],ke=Se.y-te.y+B[0][1],Ie=Se.y+ae.measured.height-te.y2+B[1][1];he=[[pe,ke],[Ee,Ie]]}const{position:fe,positionAbsolute:se}=$Pe({nodeId:ue,nextPosition:ie,nodeLookup:$,nodeExtent:he||B,nodeOrigin:W,onError:Q});le=le||ae.position.x!==fe.x||ae.position.y!==fe.y,ae.position=fe,ae.internals.positionAbsolute=se}if(g=g||le,!!le&&(G(a,!0),b&&(r||q||!O&&Y))){const[ue,ae]=r7({nodeId:O,dragItems:a,nodeLookup:$});r==null||r(b,a,ue,ae),q==null||q(b,ue,ae),O||Y==null||Y(b,ae)}}async function I(){if(!c)return;const{transform:F,panBy:z,autoPanSpeed:$,autoPanOnNodeDrag:B}=t();if(!B){l=!1,cancelAnimationFrame(s);return}const[H,U]=NQ(u,c,$);(H!==0||U!==0)&&(o.x=(o.x??0)-H/F[2],o.y=(o.y??0)-U/F[2],await z({x:H,y:U})&&N(o)),s=requestAnimationFrame(I)}function D(F){var K;const{nodeLookup:z,multiSelectionActive:$,nodesDraggable:B,transform:H,snapGrid:U,snapToGrid:W,selectNodesOnDrag:q,onNodeDragStart:Y,onSelectionDragStart:Q,unselectNodesAndEdges:G}=t();d=!0,(!q||!T)&&!$&&O&&((K=z.get(O))!=null&&K.selected||G()),T&&q&&O&&(e==null||e(O));const le=iE(F.sourceEvent,{transform:H,snapGrid:U,snapToGrid:W,containerBounds:c});if(o=le,a=a9t(z,B,le,O),a.size>0&&(n||Y||!O&&Q)){const[te,de]=r7({nodeId:O,dragItems:a,nodeLookup:z});n==null||n(F.sourceEvent,a,te,de),Y==null||Y(F.sourceEvent,te,de),O||Q==null||Q(F.sourceEvent,de)}}const P=CPe().clickDistance(M).on("start",F=>{const{domNode:z,nodeDragThreshold:$,transform:B,snapGrid:H,snapToGrid:U}=t();c=(z==null?void 0:z.getBoundingClientRect())||null,m=!1,g=!1,b=F.sourceEvent,$===0&&D(F),o=iE(F.sourceEvent,{transform:B,snapGrid:H,snapToGrid:U,containerBounds:c}),u=Zu(F.sourceEvent,c)}).on("drag",F=>{const{autoPanOnNodeDrag:z,transform:$,snapGrid:B,snapToGrid:H,nodeDragThreshold:U,nodeLookup:W}=t(),q=iE(F.sourceEvent,{transform:$,snapGrid:B,snapToGrid:H,containerBounds:c});if(b=F.sourceEvent,(F.sourceEvent.type==="touchmove"&&F.sourceEvent.touches.length>1||O&&!W.has(O))&&(m=!0),!m){if(!l&&z&&d&&(l=!0,I()),!d){const Y=Zu(F.sourceEvent,c),Q=Y.x-u.x,G=Y.y-u.y;Math.sqrt(Q*Q+G*G)>U&&D(F)}(o.x!==q.xSnapped||o.y!==q.ySnapped)&&a&&d&&(u=Zu(F.sourceEvent,c),N(q))}}).on("end",F=>{if(!d||m){m&&a.size>0&&t().updateNodePositions(a,!1);return}if(l=!1,d=!1,cancelAnimationFrame(s),a.size>0){const{nodeLookup:z,updateNodePositions:$,onNodeDragStop:B,onSelectionDragStop:H}=t();if(g&&($(a,!1),g=!1),i||B||!O&&H){const[U,W]=r7({nodeId:O,dragItems:a,nodeLookup:z,dragging:!1});i==null||i(F.sourceEvent,a,U,W),B==null||B(F.sourceEvent,U,W),O||H==null||H(F.sourceEvent,W)}}}).filter(F=>{const z=F.target;return!F.button&&(!S||!O0e(z,`.${S}`,E))&&(!C||O0e(z,C,E))});h.call(P)}function w(){h==null||h.on(".drag",null)}return{update:v,destroy:w}}function c9t(e,t,n){const r=[],i={x:e.x-n,y:e.y-n,width:n*2,height:n*2};for(const o of t.values())JI(i,BT(o))>0&&r.push(o);return r}const d9t=250;function f9t(e,t,n,r){var a,l;let i=[],o=1/0;const s=c9t(e,n,t+d9t);for(const u of s){const c=[...((a=u.internals.handleBounds)==null?void 0:a.source)??[],...((l=u.internals.handleBounds)==null?void 0:l.target)??[]];for(const d of c){if(r.nodeId===d.nodeId&&r.type===d.type&&r.id===d.id)continue;const{x:h,y:m}=Ab(u,d,d.position,!0),g=Math.sqrt(Math.pow(h-e.x,2)+Math.pow(m-e.y,2));g>t||(g<o?(i=[{...d,x:h,y:m}],o=g):g===o&&i.push({...d,x:h,y:m}))}}if(!i.length)return null;if(i.length>1){const u=r.type==="source"?"target":"source";return i.find(c=>c.type===u)??i[0]}return i[0]}function rje(e,t,n,r,i,o=!1){var u,c,d;const s=r.get(e);if(!s)return null;const a=i==="strict"?(u=s.internals.handleBounds)==null?void 0:u[t]:[...((c=s.internals.handleBounds)==null?void 0:c.source)??[],...((d=s.internals.handleBounds)==null?void 0:d.target)??[]],l=(n?a==null?void 0:a.find(h=>h.id===n):a==null?void 0:a[0])??null;return l&&o?{...l,...Ab(s,l,l.position,!0)}:l}function ije(e,t){return e||(t!=null&&t.classList.contains("target")?"target":t!=null&&t.classList.contains("source")?"source":null)}function h9t(e,t){let n=null;return t?n=!0:e&&!t&&(n=!1),n}const oje=()=>!0;function p9t(e,{connectionMode:t,connectionRadius:n,handleId:r,nodeId:i,edgeUpdaterType:o,isTarget:s,domNode:a,nodeLookup:l,lib:u,autoPanOnConnect:c,flowId:d,panBy:h,cancelConnection:m,onConnectStart:g,onConnect:b,onConnectEnd:v,isValidConnection:w=oje,onReconnectEnd:S,updateConnection:C,getTransform:E,getFromHandle:T,autoPanSpeed:O,dragThreshold:M=1,handleDomNode:N}){const I=qPe(e.target);let D=0,P;const{x:F,y:z}=Zu(e),$=ije(o,N),B=a==null?void 0:a.getBoundingClientRect();let H=!1;if(!B||!$)return;const U=rje(i,$,r,l,t);if(!U)return;let W=Zu(e,B),q=!1,Y=null,Q=!1,G=null;function le(){if(!c||!B)return;const[fe,se]=NQ(W,B,O);h({x:fe,y:se}),D=requestAnimationFrame(le)}const K={...U,nodeId:i,type:$,position:U.position},te=l.get(i);let ue={inProgress:!0,isValid:null,from:Ab(te,K,Bt.Left,!0),fromHandle:K,fromPosition:K.position,fromNode:te,to:W,toHandle:null,toPosition:g0e[K.position],toNode:null,pointer:W};function ae(){H=!0,C(ue),g==null||g(e,{nodeId:i,handleId:r,handleType:$})}M===0&&ae();function ie(fe){if(!H){const{x:Ie,y:Be}=Zu(fe),Oe=Ie-F,Le=Be-z;if(!(Oe*Oe+Le*Le>M*M))return;ae()}if(!T()||!K){he(fe);return}const se=E();W=Zu(fe,B),P=f9t(MA(W,se,!1,[1,1]),n,l,K),q||(le(),q=!0);const Se=sje(fe,{handle:P,connectionMode:t,fromNodeId:i,fromHandleId:r,fromType:s?"target":"source",isValidConnection:w,doc:I,lib:u,flowId:d,nodeLookup:l});G=Se.handleDomNode,Y=Se.connection,Q=h9t(!!P,Se.isValid);const pe=l.get(i),Ee=pe?Ab(pe,K,Bt.Left,!0):ue.from,ke={...ue,from:Ee,isValid:Q,to:Se.toHandle&&Q?Nw({x:Se.toHandle.x,y:Se.toHandle.y},se):W,toHandle:Se.toHandle,toPosition:Q&&Se.toHandle?Se.toHandle.position:g0e[K.position],toNode:Se.toHandle?l.get(Se.toHandle.nodeId):null,pointer:W};C(ke),ue=ke}function he(fe){if(!("touches"in fe&&fe.touches.length>0)){if(H){(P||G)&&Y&&Q&&(b==null||b(Y));const{inProgress:se,...Se}=ue,pe={...Se,toPosition:ue.toHandle?ue.toPosition:null};v==null||v(fe,pe),o&&(S==null||S(fe,pe))}m(),cancelAnimationFrame(D),q=!1,Q=!1,Y=null,G=null,I.removeEventListener("mousemove",ie),I.removeEventListener("mouseup",he),I.removeEventListener("touchmove",ie),I.removeEventListener("touchend",he)}}I.addEventListener("mousemove",ie),I.addEventListener("mouseup",he),I.addEventListener("touchmove",ie),I.addEventListener("touchend",he)}function sje(e,{handle:t,connectionMode:n,fromNodeId:r,fromHandleId:i,fromType:o,doc:s,lib:a,flowId:l,isValidConnection:u=oje,nodeLookup:c}){const d=o==="target",h=t?s.querySelector(`.${a}-flow__handle[data-id="${l}-${t==null?void 0:t.nodeId}-${t==null?void 0:t.id}-${t==null?void 0:t.type}"]`):null,{x:m,y:g}=Zu(e),b=s.elementFromPoint(m,g),v=b!=null&&b.classList.contains(`${a}-flow__handle`)?b:h,w={handleDomNode:v,isValid:!1,connection:null,toHandle:null};if(v){const S=ije(void 0,v),C=v.getAttribute("data-nodeid"),E=v.getAttribute("data-handleid"),T=v.classList.contains("connectable"),O=v.classList.contains("connectableend");if(!C||!S)return w;const M={source:d?C:r,sourceHandle:d?E:i,target:d?r:C,targetHandle:d?i:E};w.connection=M;const I=T&&O&&(n===Mw.Strict?d&&S==="source"||!d&&S==="target":C!==r||E!==i);w.isValid=I&&u(M),w.toHandle=rje(C,S,E,c,n,!0)}return w}const eq={onPointerDown:p9t,isValid:sje};function m9t({domNode:e,panZoom:t,getTransform:n,getViewScale:r}){const i=al(e);function o({translateExtent:a,width:l,height:u,zoomStep:c=1,pannable:d=!0,zoomable:h=!0,inversePan:m=!1}){const g=C=>{if(C.sourceEvent.type!=="wheel"||!t)return;const E=n(),T=C.sourceEvent.ctrlKey&&HT()?10:1,O=-C.sourceEvent.deltaY*(C.sourceEvent.deltaMode===1?.05:C.sourceEvent.deltaMode?1:.002)*c,M=E[2]*Math.pow(2,O*T);t.scaleTo(M)};let b=[0,0];const v=C=>{(C.sourceEvent.type==="mousedown"||C.sourceEvent.type==="touchstart")&&(b=[C.sourceEvent.clientX??C.sourceEvent.touches[0].clientX,C.sourceEvent.clientY??C.sourceEvent.touches[0].clientY])},w=C=>{const E=n();if(C.sourceEvent.type!=="mousemove"&&C.sourceEvent.type!=="touchmove"||!t)return;const T=[C.sourceEvent.clientX??C.sourceEvent.touches[0].clientX,C.sourceEvent.clientY??C.sourceEvent.touches[0].clientY],O=[T[0]-b[0],T[1]-b[1]];b=T;const M=r()*Math.max(E[2],Math.log(E[2]))*(m?-1:1),N={x:E[0]-O[0]*M,y:E[1]-O[1]*M},I=[[0,0],[l,u]];t.setViewportConstrained({x:N.x,y:N.y,zoom:E[2]},I,a)},S=LPe().on("start",v).on("zoom",d?w:null).on("zoom.wheel",h?g:null);i.call(S,{})}function s(){i.on("zoom",null)}return{update:o,destroy:s,pointer:Fu}}const HD=e=>({x:e.x,y:e.y,zoom:e.k}),i7=({x:e,y:t,zoom:n})=>zD.translate(e,t).scale(n),om=(e,t)=>e.target.closest(`.${t}`),aje=(e,t)=>t===2&&Array.isArray(e)&&e.includes(2),g9t=e=>((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2,o7=(e,t=0,n=g9t,r=()=>{})=>{const i=typeof t=="number"&&t>0;return i||r(),i?e.transition().duration(t).ease(n).on("end",r):e},lje=e=>{const t=e.ctrlKey&&HT()?10:1;return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*t};function y9t({zoomPanValues:e,noWheelClassName:t,d3Selection:n,d3Zoom:r,panOnScrollMode:i,panOnScrollSpeed:o,zoomOnPinch:s,onPanZoomStart:a,onPanZoom:l,onPanZoomEnd:u}){return c=>{if(om(c,t))return c.ctrlKey&&c.preventDefault(),!1;c.preventDefault(),c.stopImmediatePropagation();const d=n.property("__zoom").k||1;if(c.ctrlKey&&s){const v=Fu(c),w=lje(c),S=d*Math.pow(2,w);r.scaleTo(n,S,v,c);return}const h=c.deltaMode===1?20:1;let m=i===rb.Vertical?0:c.deltaX*h,g=i===rb.Horizontal?0:c.deltaY*h;!HT()&&c.shiftKey&&i!==rb.Vertical&&(m=c.deltaY*h,g=0),r.translateBy(n,-(m/d)*o,-(g/d)*o,{internal:!0});const b=HD(n.property("__zoom"));clearTimeout(e.panScrollTimeout),e.isPanScrolling?l==null||l(c,b):(e.isPanScrolling=!0,a==null||a(c,b)),e.panScrollTimeout=setTimeout(()=>{u==null||u(c,b),e.isPanScrolling=!1},150)}}function b9t({noWheelClassName:e,preventScrolling:t,d3ZoomHandler:n}){return function(r,i){const o=r.type==="wheel",s=!t&&o&&!r.ctrlKey,a=om(r,e);if(r.ctrlKey&&o&&a&&r.preventDefault(),s||a)return null;r.preventDefault(),n.call(this,r,i)}}function v9t({zoomPanValues:e,onDraggingChange:t,onPanZoomStart:n}){return r=>{var o,s,a;if((o=r.sourceEvent)!=null&&o.internal)return;const i=HD(r.transform);e.mouseButton=((s=r.sourceEvent)==null?void 0:s.button)||0,e.isZoomingOrPanning=!0,e.prevViewport=i,((a=r.sourceEvent)==null?void 0:a.type)==="mousedown"&&t(!0),n&&(n==null||n(r.sourceEvent,i))}}function x9t({zoomPanValues:e,panOnDrag:t,onPaneContextMenu:n,onTransformChange:r,onPanZoom:i}){return o=>{var s,a;e.usedRightMouseButton=!!(n&&aje(t,e.mouseButton??0)),(s=o.sourceEvent)!=null&&s.sync||r([o.transform.x,o.transform.y,o.transform.k]),i&&!((a=o.sourceEvent)!=null&&a.internal)&&(i==null||i(o.sourceEvent,HD(o.transform)))}}function w9t({zoomPanValues:e,panOnDrag:t,panOnScroll:n,onDraggingChange:r,onPanZoomEnd:i,onPaneContextMenu:o}){return s=>{var a;if(!((a=s.sourceEvent)!=null&&a.internal)&&(e.isZoomingOrPanning=!1,o&&aje(t,e.mouseButton??0)&&!e.usedRightMouseButton&&s.sourceEvent&&o(s.sourceEvent),e.usedRightMouseButton=!1,r(!1),i)){const l=HD(s.transform);e.prevViewport=l,clearTimeout(e.timerId),e.timerId=setTimeout(()=>{i==null||i(s.sourceEvent,l)},n?150:0)}}}function S9t({panActivationKeyPressed:e,zoomActivationKeyPressed:t,zoomOnScroll:n,zoomOnPinch:r,panOnDrag:i,panOnScroll:o,zoomOnDoubleClick:s,userSelectionActive:a,noWheelClassName:l,noPanClassName:u,lib:c,connectionInProgress:d}){return h=>{var w;const m=t||n,g=r&&h.ctrlKey,b=h.type==="wheel";if(h.button===1&&h.type==="mousedown"&&(om(h,`${c}-flow__node`)||om(h,`${c}-flow__edge`)||om(h,`${c}-flow__selection`)||om(h,`${c}-flow__nodesselection`)))return!0;if(!i&&!m&&!o&&!s&&!r||a||d&&!b||om(h,l)&&b||om(h,u)&&(!b||o&&b&&!t)||!r&&h.ctrlKey&&b)return!1;if(!r&&h.type==="touchstart"&&((w=h.touches)==null?void 0:w.length)>1)return h.preventDefault(),!1;if(!m&&!o&&!g&&b||!i&&(h.type==="mousedown"||h.type==="touchstart")||Array.isArray(i)&&!i.includes(h.button)&&h.type==="mousedown")return!1;const v=Array.isArray(i)&&i.includes(h.button)||!h.button||h.button<=1;return(!h.ctrlKey||b||e)&&v}}function k9t({domNode:e,minZoom:t,maxZoom:n,translateExtent:r,viewport:i,onPanZoom:o,onPanZoomStart:s,onPanZoomEnd:a,onDraggingChange:l}){const u={isZoomingOrPanning:!1,usedRightMouseButton:!1,prevViewport:{},mouseButton:0,timerId:void 0,panScrollTimeout:void 0,isPanScrolling:!1},c=e.getBoundingClientRect();let d=[[0,0],[c.width,c.height]];const h=typeof ResizeObserver<"u"?new ResizeObserver(z=>{const $=z[0];$&&(d=[[0,0],[$.contentRect.width,$.contentRect.height]])}):null;h==null||h.observe(e);const m=LPe().extent(()=>d).scaleExtent([t,n]).translateExtent(r),g=al(e).call(m);E({x:i.x,y:i.y,zoom:_w(i.zoom,t,n)},[[0,0],[c.width,c.height]],r);const b=g.on("wheel.zoom"),v=g.on("dblclick.zoom");m.wheelDelta(lje);async function w(z,$){return g?new Promise(B=>{m==null||m.interpolate(($==null?void 0:$.interpolate)==="linear"?Ah:k_).transform(o7(g,$==null?void 0:$.duration,$==null?void 0:$.ease,()=>B(!0)),z)}):!1}function S({noWheelClassName:z,noPanClassName:$,onPaneContextMenu:B,userSelectionActive:H,panOnScroll:U,panOnDrag:W,panOnScrollMode:q,panOnScrollSpeed:Y,preventScrolling:Q,zoomOnPinch:G,zoomOnScroll:le,zoomOnDoubleClick:K,panActivationKeyPressed:te=!1,zoomActivationKeyPressed:de,lib:ue,onTransformChange:ae,connectionInProgress:ie,paneClickDistance:he,selectionOnDrag:fe}){H&&!u.isZoomingOrPanning&&C();const se=U&&!de&&!H;m.clickDistance(fe?1/0:!Qu(he)||he<0?0:he);const Se=se?y9t({zoomPanValues:u,noWheelClassName:z,d3Selection:g,d3Zoom:m,panOnScrollMode:q,panOnScrollSpeed:Y,zoomOnPinch:G,onPanZoomStart:s,onPanZoom:o,onPanZoomEnd:a}):b9t({noWheelClassName:z,preventScrolling:Q,d3ZoomHandler:b});g.on("wheel.zoom",Se,{passive:!1});const pe=v9t({zoomPanValues:u,onDraggingChange:l,onPanZoomStart:s});m.on("start",pe);const Ee=x9t({zoomPanValues:u,panOnDrag:W,onPaneContextMenu:!!B,onPanZoom:o,onTransformChange:ae});m.on("zoom",Ee);const ke=w9t({zoomPanValues:u,panOnDrag:W,panOnScroll:U,onPaneContextMenu:B,onPanZoomEnd:a,onDraggingChange:l});m.on("end",ke);const Ie=S9t({panActivationKeyPressed:te,zoomActivationKeyPressed:de,panOnDrag:W,zoomOnScroll:le,panOnScroll:U,zoomOnDoubleClick:K,zoomOnPinch:G,userSelectionActive:H,noPanClassName:$,noWheelClassName:z,lib:ue,connectionInProgress:ie});m.filter(Ie),K?g.on("dblclick.zoom",v):g.on("dblclick.zoom",null)}function C(){m.on("zoom",null)}async function E(z,$,B){const H=i7(z),U=m==null?void 0:m.constrain()(H,$,B);return U&&await w(U),U}async function T(z,$){const B=i7(z);return await w(B,$),B}function O(z){if(g){const $=i7(z),B=g.property("__zoom");(B.k!==z.zoom||B.x!==z.x||B.y!==z.y)&&(m==null||m.transform(g,$,null,{sync:!0}))}}function M(){const z=g?NPe(g.node()):{x:0,y:0,k:1};return{x:z.x,y:z.y,zoom:z.k}}async function N(z,$){return g?new Promise(B=>{m==null||m.interpolate(($==null?void 0:$.interpolate)==="linear"?Ah:k_).scaleTo(o7(g,$==null?void 0:$.duration,$==null?void 0:$.ease,()=>B(!0)),z)}):!1}async function I(z,$){return g?new Promise(B=>{m==null||m.interpolate(($==null?void 0:$.interpolate)==="linear"?Ah:k_).scaleBy(o7(g,$==null?void 0:$.duration,$==null?void 0:$.ease,()=>B(!0)),z)}):!1}function D(z){m==null||m.scaleExtent(z)}function P(z){m==null||m.translateExtent(z)}function F(z){const $=!Qu(z)||z<0?0:z;m==null||m.clickDistance($)}return{update:S,destroy:C,setViewport:T,setViewportConstrained:E,getViewport:M,scaleTo:N,scaleBy:I,setScaleExtent:D,setTranslateExtent:P,syncViewport:O,setClickDistance:F}}var Lw;(function(e){e.Line="line",e.Handle="handle"})(Lw||(Lw={}));function C9t({width:e,prevWidth:t,height:n,prevHeight:r,affectsX:i,affectsY:o}){const s=e-t,a=n-r,l=[s>0?1:s<0?-1:0,a>0?1:a<0?-1:0];return s&&i&&(l[0]=l[0]*-1),a&&o&&(l[1]=l[1]*-1),l}function R0e(e){const t=e.includes("right")||e.includes("left"),n=e.includes("bottom")||e.includes("top"),r=e.includes("left"),i=e.includes("top");return{isHorizontal:t,isVertical:n,affectsX:r,affectsY:i}}function Dp(e,t){return Math.max(0,t-e)}function $p(e,t){return Math.max(0,e-t)}function kM(e,t,n){return Math.max(0,t-e,e-n)}function M0e(e,t){return e?!t:t}function E9t(e,t,n,r,i,o,s,a){let{affectsX:l,affectsY:u}=t;const{isHorizontal:c,isVertical:d}=t,h=c&&d,{xSnapped:m,ySnapped:g}=n,{minWidth:b,maxWidth:v,minHeight:w,maxHeight:S}=r,{x:C,y:E,width:T,height:O,aspectRatio:M}=e;let N=Math.floor(c?m-e.pointerX:0),I=Math.floor(d?g-e.pointerY:0);const D=T+(l?-N:N),P=O+(u?-I:I),F=-o[0]*T,z=-o[1]*O;let $=kM(D,b,v),B=kM(P,w,S);if(s){let W=0,q=0;l&&N<0?W=Dp(C+N+F,s[0][0]):!l&&N>0&&(W=$p(C+D+F,s[1][0])),u&&I<0?q=Dp(E+I+z,s[0][1]):!u&&I>0&&(q=$p(E+P+z,s[1][1])),$=Math.max($,W),B=Math.max(B,q)}if(a){let W=0,q=0;l&&N>0?W=$p(C+N,a[0][0]):!l&&N<0&&(W=Dp(C+D,a[1][0])),u&&I>0?q=$p(E+I,a[0][1]):!u&&I<0&&(q=Dp(E+P,a[1][1])),$=Math.max($,W),B=Math.max(B,q)}if(i){if(c){const W=kM(D/M,w,S)*M;if($=Math.max($,W),s){let q=0;!l&&!u||l&&!u&&h?q=$p(E+z+D/M,s[1][1])*M:q=Dp(E+z+(l?N:-N)/M,s[0][1])*M,$=Math.max($,q)}if(a){let q=0;!l&&!u||l&&!u&&h?q=Dp(E+D/M,a[1][1])*M:q=$p(E+(l?N:-N)/M,a[0][1])*M,$=Math.max($,q)}}if(d){const W=kM(P*M,b,v)/M;if(B=Math.max(B,W),s){let q=0;!l&&!u||u&&!l&&h?q=$p(C+P*M+F,s[1][0])/M:q=Dp(C+(u?I:-I)*M+F,s[0][0])/M,B=Math.max(B,q)}if(a){let q=0;!l&&!u||u&&!l&&h?q=Dp(C+P*M,a[1][0])/M:q=$p(C+(u?I:-I)*M,a[0][0])/M,B=Math.max(B,q)}}}I=I+(I<0?B:-B),N=N+(N<0?$:-$),i&&(h?D>P*M?I=(M0e(l,u)?-N:N)/M:N=(M0e(l,u)?-I:I)*M:c?(I=N/M,u=l):(N=I*M,l=u));const H=l?C+N:C,U=u?E+I:E;return{width:T+(l?-N:N),height:O+(u?-I:I),x:o[0]*N*(l?-1:1)+H,y:o[1]*I*(u?-1:1)+U}}const uje={width:0,height:0,x:0,y:0},T9t={...uje,pointerX:0,pointerY:0,aspectRatio:1};function A9t(e,t,n){const r=t.position.x+e.position.x,i=t.position.y+e.position.y,o=e.measured.width??0,s=e.measured.height??0,a=n[0]*o,l=n[1]*s;return[[r-a,i-l],[r+o-a,i+s-l]]}function O9t({domNode:e,nodeId:t,getStoreItems:n,onChange:r,onEnd:i}){const o=al(e);let s={controlDirection:R0e("bottom-right"),boundaries:{minWidth:0,minHeight:0,maxWidth:Number.MAX_VALUE,maxHeight:Number.MAX_VALUE},resizeDirection:void 0,keepAspectRatio:!1};function a({controlPosition:u,boundaries:c,keepAspectRatio:d,resizeDirection:h,onResizeStart:m,onResize:g,onResizeEnd:b,shouldResize:v}){let w={...uje},S={...T9t};s={boundaries:c,resizeDirection:h,keepAspectRatio:d,controlDirection:R0e(u)};let C,E=null,T=[],O,M,N,I=!1;const D=CPe().on("start",P=>{const{nodeLookup:F,transform:z,snapGrid:$,snapToGrid:B,nodeOrigin:H,paneDomNode:U}=n();if(C=F.get(t),!C)return;E=(U==null?void 0:U.getBoundingClientRect())??null;const{xSnapped:W,ySnapped:q}=iE(P.sourceEvent,{transform:z,snapGrid:$,snapToGrid:B,containerBounds:E});w={width:C.measured.width??0,height:C.measured.height??0,x:C.position.x??0,y:C.position.y??0},S={...w,pointerX:W,pointerY:q,aspectRatio:w.width/w.height},O=void 0,M=Tb(C.extent)?C.extent:void 0,C.parentId&&(C.extent==="parent"||C.expandParent)&&(O=F.get(C.parentId)),O&&C.extent==="parent"&&(M=[[0,0],[O.measured.width,O.measured.height]]),T=[],N=void 0;for(const[Y,Q]of F)if(Q.parentId===t&&(T.push({id:Y,position:{...Q.position},extent:Q.extent}),Q.extent==="parent"||Q.expandParent)){const G=A9t(Q,C,Q.origin??H);N?N=[[Math.min(G[0][0],N[0][0]),Math.min(G[0][1],N[0][1])],[Math.max(G[1][0],N[1][0]),Math.max(G[1][1],N[1][1])]]:N=G}m==null||m(P,{...w})}).on("drag",P=>{const{transform:F,snapGrid:z,snapToGrid:$,nodeOrigin:B}=n(),H=iE(P.sourceEvent,{transform:F,snapGrid:z,snapToGrid:$,containerBounds:E}),U=[];if(!C)return;const{x:W,y:q,width:Y,height:Q}=w,G={},le=C.origin??B,{width:K,height:te,x:de,y:ue}=E9t(S,s.controlDirection,H,s.boundaries,s.keepAspectRatio,le,M,N),ae=K!==Y,ie=te!==Q,he=de!==W&&ae,fe=ue!==q&&ie;if(!he&&!fe&&!ae&&!ie)return;if((he||fe||le[0]===1||le[1]===1)&&(G.x=he?de:w.x,G.y=fe?ue:w.y,w.x=G.x,w.y=G.y,T.length>0)){const Ee=de-W,ke=ue-q;for(const Ie of T)Ie.position={x:Ie.position.x-Ee+le[0]*(K-Y),y:Ie.position.y-ke+le[1]*(te-Q)},U.push(Ie)}if((ae||ie)&&(G.width=ae&&(!s.resizeDirection||s.resizeDirection==="horizontal")?K:w.width,G.height=ie&&(!s.resizeDirection||s.resizeDirection==="vertical")?te:w.height,w.width=G.width,w.height=G.height),O&&C.expandParent){const Ee=le[0]*(G.width??0);G.x&&G.x<Ee&&(w.x=Ee,S.x=S.x-(G.x-Ee));const ke=le[1]*(G.height??0);G.y&&G.y<ke&&(w.y=ke,S.y=S.y-(G.y-ke))}const se=C9t({width:w.width,prevWidth:Y,height:w.height,prevHeight:Q,affectsX:s.controlDirection.affectsX,affectsY:s.controlDirection.affectsY}),Se={...w,direction:se};(v==null?void 0:v(P,Se))!==!1&&(I=!0,g==null||g(P,Se),r(G,U))}).on("end",P=>{I&&(b==null||b(P,{...w}),i==null||i({...w}),I=!1)});o.call(D)}function l(){o.on(".drag",null)}return{update:a,destroy:l}}const R9t={},_0e=e=>{let t;const n=new Set,r=(c,d)=>{const h=typeof c=="function"?c(t):c;if(!Object.is(h,t)){const m=t;t=d??(typeof h!="object"||h===null)?h:Object.assign({},t,h),n.forEach(g=>g(t,m))}},i=()=>t,l={setState:r,getState:i,getInitialState:()=>u,subscribe:c=>(n.add(c),()=>n.delete(c)),destroy:()=>{(R9t?"production":void 0)!=="production"&&console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),n.clear()}},u=t=e(r,i,l);return l},M9t=e=>e?_0e(e):_0e,{useDebugValue:_9t}=we,{useSyncExternalStoreWithSelector:N9t}=Fze,L9t=e=>e;function cje(e,t=L9t,n){const r=N9t(e.subscribe,e.getState,e.getServerState||e.getInitialState,t,n);return _9t(r),r}const N0e=(e,t)=>{const n=M9t(e),r=(i,o=t)=>cje(n,i,o);return Object.assign(r,n),r},I9t=(e,t)=>e?N0e(e,t):N0e;function ri(e,t){if(Object.is(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(const[r,i]of e)if(!Object.is(i,t.get(r)))return!1;return!0}if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(const r of e)if(!t.has(r))return!1;return!0}const n=Object.keys(e);if(n.length!==Object.keys(t).length)return!1;for(const r of n)if(!Object.prototype.hasOwnProperty.call(t,r)||!Object.is(e[r],t[r]))return!1;return!0}const UD=A.createContext(null),P9t=UD.Provider,dje=oc.error001("react");function Mn(e,t){const n=A.useContext(UD);if(n===null)throw new Error(dje);return cje(n,e,t)}function oi(){const e=A.useContext(UD);if(e===null)throw new Error(dje);return A.useMemo(()=>({getState:e.getState,setState:e.setState,subscribe:e.subscribe}),[e])}const L0e={display:"none"},j9t={position:"absolute",width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0px, 0px, 0px, 0px)",clipPath:"inset(100%)"},fje="react-flow__node-desc",hje="react-flow__edge-desc",D9t="react-flow__aria-live",$9t=e=>e.ariaLiveMessage,z9t=e=>e.ariaLabelConfig;function F9t({rfId:e}){const t=Mn($9t);return y.jsx("div",{id:`${D9t}-${e}`,"aria-live":"assertive","aria-atomic":"true",style:j9t,children:t})}function B9t({rfId:e,disableKeyboardA11y:t}){const n=Mn(z9t);return y.jsxs(y.Fragment,{children:[y.jsx("div",{id:`${fje}-${e}`,style:L0e,children:t?n["node.a11yDescription.default"]:n["node.a11yDescription.keyboardDisabled"]}),y.jsx("div",{id:`${hje}-${e}`,style:L0e,children:n["edge.a11yDescription.default"]}),!t&&y.jsx(F9t,{rfId:e})]})}const bS=A.forwardRef(({position:e="top-left",children:t,className:n,style:r,...i},o)=>{const s=`${e}`.split("-");return y.jsx("div",{className:$i(["react-flow__panel",n,...s]),style:r,ref:o,...i,children:t})});bS.displayName="Panel";const I0e="https://reactflow.dev?utm_source=attribution";function H9t({proOptions:e,position:t="bottom-right"}){return A.useEffect(()=>{},[]),e!=null&&e.hideAttribution?null:y.jsx(bS,{position:t,className:"react-flow__attribution","data-message":`Please only hide this attribution when you are subscribed to React Flow Pro: ${I0e}`,children:y.jsx("a",{href:I0e,target:"_blank",rel:"noopener noreferrer","aria-label":"React Flow attribution",children:"React Flow"})})}const U9t=e=>{const t=[],n=[];for(const[,r]of e.nodeLookup)r.selected&&t.push(r.internals.userNode);for(const[,r]of e.edgeLookup)r.selected&&n.push(r);return{selectedNodes:t,selectedEdges:n}},CM=e=>e.id;function V9t(e,t){return ri(e.selectedNodes.map(CM),t.selectedNodes.map(CM))&&ri(e.selectedEdges.map(CM),t.selectedEdges.map(CM))}function W9t({onSelectionChange:e}){const t=oi(),{selectedNodes:n,selectedEdges:r}=Mn(U9t,V9t);return A.useEffect(()=>{const i={nodes:n,edges:r};e==null||e(i),t.getState().onSelectionChangeHandlers.forEach(o=>o(i))},[n,r,e]),null}const q9t=e=>!!e.onSelectionChangeHandlers;function G9t({onSelectionChange:e}){const t=Mn(q9t);return e||t?y.jsx(W9t,{onSelectionChange:e}):null}const pje=[0,0],K9t={x:0,y:0,zoom:1},Y9t=["nodes","edges","defaultNodes","defaultEdges","onConnect","onConnectStart","onConnectEnd","onClickConnectStart","onClickConnectEnd","nodesDraggable","autoPanOnNodeFocus","nodesConnectable","nodesFocusable","edgesFocusable","edgesReconnectable","elevateNodesOnSelect","elevateEdgesOnSelect","minZoom","maxZoom","nodeExtent","onNodesChange","onEdgesChange","elementsSelectable","connectionMode","snapGrid","snapToGrid","translateExtent","connectOnClick","defaultEdgeOptions","fitView","fitViewOptions","onNodesDelete","onEdgesDelete","onDelete","onNodeDrag","onNodeDragStart","onNodeDragStop","onSelectionDrag","onSelectionDragStart","onSelectionDragStop","onMoveStart","onMove","onMoveEnd","noPanClassName","nodeOrigin","autoPanOnConnect","autoPanOnNodeDrag","onError","connectionRadius","isValidConnection","selectNodesOnDrag","nodeDragThreshold","connectionDragThreshold","onBeforeDelete","debug","autoPanSpeed","ariaLabelConfig","zIndexMode"],P0e=[...Y9t,"rfId"],X9t=e=>({setNodes:e.setNodes,setEdges:e.setEdges,setMinZoom:e.setMinZoom,setMaxZoom:e.setMaxZoom,setTranslateExtent:e.setTranslateExtent,setNodeExtent:e.setNodeExtent,reset:e.reset,setDefaultNodesAndEdges:e.setDefaultNodesAndEdges}),j0e={translateExtent:$T,nodeOrigin:pje,minZoom:.5,maxZoom:2,elementsSelectable:!0,noPanClassName:"nopan",rfId:"1"};function Q9t(e){const{setNodes:t,setEdges:n,setMinZoom:r,setMaxZoom:i,setTranslateExtent:o,setNodeExtent:s,reset:a,setDefaultNodesAndEdges:l}=Mn(X9t,ri),u=oi();A.useEffect(()=>(l(e.defaultNodes,e.defaultEdges),()=>{c.current=j0e,a()}),[]);const c=A.useRef(j0e);return A.useEffect(()=>{for(const d of P0e){const h=e[d],m=c.current[d];h!==m&&(typeof e[d]>"u"||(d==="nodes"?t(h):d==="edges"?n(h):d==="minZoom"?r(h):d==="maxZoom"?i(h):d==="translateExtent"?o(h):d==="nodeExtent"?s(h):d==="ariaLabelConfig"?u.setState({ariaLabelConfig:F7t(h)}):d==="fitView"?u.setState({fitViewQueued:h}):d==="fitViewOptions"?u.setState({fitViewOptions:h}):u.setState({[d]:h})))}c.current=e},P0e.map(d=>e[d])),null}function D0e(){return typeof window>"u"||!window.matchMedia?null:window.matchMedia("(prefers-color-scheme: dark)")}function Z9t(e){var r;const[t,n]=A.useState(e==="system"?null:e);return A.useEffect(()=>{if(e!=="system"){n(e);return}const i=D0e(),o=()=>n(i!=null&&i.matches?"dark":"light");return o(),i==null||i.addEventListener("change",o),()=>{i==null||i.removeEventListener("change",o)}},[e]),t!==null?t:(r=D0e())!=null&&r.matches?"dark":"light"}const $0e=typeof document<"u"?document:null;function VT(e=null,t={target:$0e,actInsideInputWithModifier:!0}){const[n,r]=A.useState(!1),i=A.useRef(!1),o=A.useRef(new Set([])),[s,a]=A.useMemo(()=>{if(e!==null){const u=(Array.isArray(e)?e:[e]).filter(d=>typeof d=="string").map(d=>d.replace(/\+/g,`
2943
2943
  `).replace(`
2944
2944
 
2945
2945
  `,`