(()=>{"use strict";var e={d:(t,r)=>{for(var n in r)e.o(r,n)&&!e.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:r[n]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};e.r(t),e.d(t,{escapeAmpersand:()=>n,escapeAttribute:()=>u,escapeEditableHTML:()=>i,escapeHTML:()=>c,escapeLessThan:()=>o,escapeQuotationMark:()=>a,isValidAttributeName:()=>p});const r=/[\u007F-\u009F "'>/="\uFDD0-\uFDEF]/;function n(e){return e.replace(/&(?!([a-z0-9]+|#[0-9]+|#x[a-f0-9]+);)/gi,"&")}function a(e){return e.replace(/"/g,""")}function o(e){return e.replace(//g,">")}(a(n(e)))}function c(e){return o(n(e))}function i(e){return o(e.replace(/&/g,"&"))}function p(e){return!r.test(e)}(window.wp=window.wp||{}).escapeHtml=t})(); //# sourceMappingURL=index.min.js.map; (()=>{"use strict";var e={4470:(e,t,n)=>{var r=n(1850);t.s=r.createRoot,t.a=r.hydrateRoot},1850:e=>{e.exports=window.ReactDOM}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r](i,i.exports,n),i.exports}n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var r={};(()=>{n.r(r),n.d(r,{Children:()=>e.Children,Component:()=>e.Component,Fragment:()=>e.Fragment,Platform:()=>v,PureComponent:()=>e.PureComponent,RawHTML:()=>R,StrictMode:()=>e.StrictMode,Suspense:()=>e.Suspense,cloneElement:()=>e.cloneElement,concatChildren:()=>f,createContext:()=>e.createContext,createElement:()=>e.createElement,createInterpolateElement:()=>p,createPortal:()=>m.createPortal,createRef:()=>e.createRef,createRoot:()=>g.s,findDOMNode:()=>m.findDOMNode,flushSync:()=>m.flushSync,forwardRef:()=>e.forwardRef,hydrate:()=>m.hydrate,hydrateRoot:()=>g.a,isEmptyElement:()=>y,isValidElement:()=>e.isValidElement,lazy:()=>e.lazy,memo:()=>e.memo,render:()=>m.render,renderToString:()=>Y,startTransition:()=>e.startTransition,switchChildrenNodeName:()=>h,unmountComponentAtNode:()=>m.unmountComponentAtNode,useCallback:()=>e.useCallback,useContext:()=>e.useContext,useDebugValue:()=>e.useDebugValue,useDeferredValue:()=>e.useDeferredValue,useEffect:()=>e.useEffect,useId:()=>e.useId,useImperativeHandle:()=>e.useImperativeHandle,useInsertionEffect:()=>e.useInsertionEffect,useLayoutEffect:()=>e.useLayoutEffect,useMemo:()=>e.useMemo,useReducer:()=>e.useReducer,useRef:()=>e.useRef,useState:()=>e.useState,useSyncExternalStore:()=>e.useSyncExternalStore,useTransition:()=>e.useTransition});const e=window.React;let t,o,i,a;const s=/<(\/)?(\w+)\s*(\/)?>/g;function l(e,t,n,r,o){return{element:e,tokenStart:t,tokenLength:n,prevOffset:r,leadingTextStart:o,children:[]}}function c(n){const r=function(){const e=s.exec(t);if(null===e)return["no-more-tokens"];const n=e.index,[r,o,i,a]=e,l=r.length;return a?["self-closed",i,n,l]:o?["closer",i,n,l]:["opener",i,n,l]}(),[c,p,f,h]=r,m=a.length,g=f>o?o:null;if(!n[p])return u(),!1;switch(c){case"no-more-tokens":if(0!==m){const{leadingTextStart:e,tokenStart:n}=a.pop();i.push(t.substr(e,n))}return u(),!1;case"self-closed":return 0===m?(null!==g&&i.push(t.substr(g,f-g)),i.push(n[p]),o=f+h,!0):(d(l(n[p],f,h)),o=f+h,!0);case"opener":return a.push(l(n[p],f,h,f+h,g)),o=f+h,!0;case"closer":if(1===m)return function(n){const{element:r,leadingTextStart:o,prevOffset:s,tokenStart:l,children:c}=a.pop(),u=n?t.substr(s,n-s):t.substr(s);u&&c.push(u),null!==o&&i.push(t.substr(o,l-o)),i.push((0,e.cloneElement)(r,null,...c))}(f),o=f+h,!0;const r=a.pop(),s=t.substr(r.prevOffset,f-r.prevOffset);r.children.push(s),r.prevOffset=f+h;const c=l(r.element,r.tokenStart,r.tokenLength,f+h);return c.children=r.children,d(c),o=f+h,!0;default:return u(),!1}}function u(){const e=t.length-o;0!==e&&i.push(t.substr(o,e))}function d(n){const{element:r,tokenStart:o,tokenLength:i,prevOffset:s,children:l}=n,c=a[a.length-1],u=t.substr(c.prevOffset,o-c.prevOffset);u&&c.children.push(u),c.children.push((0,e.cloneElement)(r,null,...l)),c.prevOffset=s||o+i}const p=(n,r)=>{if(t=n,o=0,i=[],a=[],s.lastIndex=0,!(t=>{const n="object"==typeof t,r=n&&Object.values(t);return n&&r.length&&r.every((t=>(0,e.isValidElement)(t)))})(r))throw new TypeError("The conversionMap provided is not valid. It must be an object with values that are React Elements");do{}while(c(r));return(0,e.createElement)(e.Fragment,null,...i)};function f(...t){return t.reduce(((t,n,r)=>(e.Children.forEach(n,((n,o)=>{n&&"string"!=typeof n&&(n=(0,e.cloneElement)(n,{key:[r,o].join()})),t.push(n)})),t)),[])}function h(t,n){return t&&e.Children.map(t,((t,r)=>{if("string"==typeof t?.valueOf())return(0,e.createElement)(n,{key:r},t);const{children:o,...i}=t.props;return(0,e.createElement)(n,{key:r,...i},o)}))}var m=n(1850),g=n(4470);const y=e=>"number"!=typeof e&&("string"==typeof e?.valueOf()||Array.isArray(e)?!e.length:!e),v={OS:"web",select:e=>"web"in e?e.web:e.default,isWeb:!0};function b(e){return"[object Object]"===Object.prototype.toString.call(e)}var k=function(){return k=Object.assign||function(e){for(var t,n=1,r=arguments.length;n{"string"==typeof e&&""!==e.trim()&&(r+=e)})),(0,e.createElement)("div",{dangerouslySetInnerHTML:{__html:r},...n})}const{Provider:T,Consumer:A}=(0,e.createContext)(void 0),M=(0,e.forwardRef)((()=>null)),I=new Set(["string","boolean","number"]),L=new Set(["area","base","br","col","command","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"]),P=new Set(["allowfullscreen","allowpaymentrequest","allowusermedia","async","autofocus","autoplay","checked","controls","default","defer","disabled","download","formnovalidate","hidden","ismap","itemscope","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","selected","typemustmatch"]),j=new Set(["autocapitalize","autocomplete","charset","contenteditable","crossorigin","decoding","dir","draggable","enctype","formenctype","formmethod","http-equiv","inputmode","kind","method","preload","scope","shape","spellcheck","translate","type","wrap"]),H=new Set(["animation","animationIterationCount","baselineShift","borderImageOutset","borderImageSlice","borderImageWidth","columnCount","cx","cy","fillOpacity","flexGrow","flexShrink","floodOpacity","fontWeight","gridColumnEnd","gridColumnStart","gridRowEnd","gridRowStart","lineHeight","opacity","order","orphans","r","rx","ry","shapeImageThreshold","stopOpacity","strokeDasharray","strokeDashoffset","strokeMiterlimit","strokeOpacity","strokeWidth","tabSize","widows","x","y","zIndex","zoom"]);function z(e,t){return t.some((t=>0===e.indexOf(t)))}function D(e){return"key"===e||"children"===e}function V(e,t){return"style"===e?function(e){if(!1===b(t=e)||void 0!==(n=t.constructor)&&(!1===b(r=n.prototype)||!1===r.hasOwnProperty("isPrototypeOf")))return e;var t,n,r;let o;for(const t in e){const n=e[t];null!=n&&(o?o+=";":o="",o+=U(t)+":"+$(t,n))}return o}(t):t}const W=["accentHeight","alignmentBaseline","arabicForm","baselineShift","capHeight","clipPath","clipRule","colorInterpolation","colorInterpolationFilters","colorProfile","colorRendering","dominantBaseline","enableBackground","fillOpacity","fillRule","floodColor","floodOpacity","fontFamily","fontSize","fontSizeAdjust","fontStretch","fontStyle","fontVariant","fontWeight","glyphName","glyphOrientationHorizontal","glyphOrientationVertical","horizAdvX","horizOriginX","imageRendering","letterSpacing","lightingColor","markerEnd","markerMid","markerStart","overlinePosition","overlineThickness","paintOrder","panose1","pointerEvents","renderingIntent","shapeRendering","stopColor","stopOpacity","strikethroughPosition","strikethroughThickness","strokeDasharray","strokeDashoffset","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity","strokeWidth","textAnchor","textDecoration","textRendering","underlinePosition","underlineThickness","unicodeBidi","unicodeRange","unitsPerEm","vAlphabetic","vHanging","vIdeographic","vMathematical","vectorEffect","vertAdvY","vertOriginX","vertOriginY","wordSpacing","writingMode","xmlnsXlink","xHeight"].reduce(((e,t)=>(e[t.toLowerCase()]=t,e)),{}),_=["allowReorder","attributeName","attributeType","autoReverse","baseFrequency","baseProfile","calcMode","clipPathUnits","contentScriptType","contentStyleType","diffuseConstant","edgeMode","externalResourcesRequired","filterRes","filterUnits","glyphRef","gradientTransform","gradientUnits","kernelMatrix","kernelUnitLength","keyPoints","keySplines","keyTimes","lengthAdjust","limitingConeAngle","markerHeight","markerUnits","markerWidth","maskContentUnits","maskUnits","numOctaves","pathLength","patternContentUnits","patternTransform","patternUnits","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","refX","refY","repeatCount","repeatDur","requiredExtensions","requiredFeatures","specularConstant","specularExponent","spreadMethod","startOffset","stdDeviation","stitchTiles","suppressContentEditableWarning","suppressHydrationWarning","surfaceScale","systemLanguage","tableValues","targetX","targetY","textLength","viewBox","viewTarget","xChannelSelector","yChannelSelector"].reduce(((e,t)=>(e[t.toLowerCase()]=t,e)),{}),F=["xlink:actuate","xlink:arcrole","xlink:href","xlink:role","xlink:show","xlink:title","xlink:type","xml:base","xml:lang","xml:space","xmlns:xlink"].reduce(((e,t)=>(e[t.replace(":","").toLowerCase()]=t,e)),{});function N(e){switch(e){case"htmlFor":return"for";case"className":return"class"}const t=e.toLowerCase();return _[t]?_[t]:W[t]?C(W[t]):F[t]?F[t]:t}function U(e){return e.startsWith("--")?e:z(e,["ms","O","Moz","Webkit"])?"-"+C(e):C(e)}function $(e,t){return"number"!=typeof t||0===t||H.has(e)?t:t+"px"}function q(t,n,r={}){if(null==t||!1===t)return"";if(Array.isArray(t))return B(t,n,r);switch(typeof t){case"string":return(0,E.escapeHTML)(t);case"number":return t.toString()}const{type:o,props:i}=t;switch(o){case e.StrictMode:case e.Fragment:return B(i.children,n,r);case R:const{children:t,...o}=i;return X(Object.keys(o).length?"div":null,{...o,dangerouslySetInnerHTML:{__html:t}},n,r)}switch(typeof o){case"string":return X(o,i,n,r);case"function":return o.prototype&&"function"==typeof o.prototype.render?function(e,t,n,r={}){const o=new e(t,r);"function"==typeof o.getChildContext&&Object.assign(r,o.getChildContext());return q(o.render(),n,r)}(o,i,n,r):q(o(i,r),n,r)}switch(o&&o.$$typeof){case T.$$typeof:return B(i.children,i.value,r);case A.$$typeof:return q(i.children(n||o._currentValue),n,r);case M.$$typeof:return q(o.render(i),n,r)}return""}function X(e,t,n,r={}){let o="";if("textarea"===e&&t.hasOwnProperty("value")){o=B(t.value,n,r);const{value:e,...i}=t;t=i}else t.dangerouslySetInnerHTML&&"string"==typeof t.dangerouslySetInnerHTML.__html?o=t.dangerouslySetInnerHTML.__html:void 0!==t.children&&(o=B(t.children,n,r));if(!e)return o;const i=function(e){let t="";for(const n in e){const r=N(n);if(!(0,E.isValidAttributeName)(r))continue;let o=V(n,e[n]);if(!I.has(typeof o))continue;if(D(n))continue;const i=P.has(r);if(i&&!1===o)continue;const a=i||z(n,["data-","aria-"])||j.has(r);("boolean"!=typeof o||a)&&(t+=" "+r,i||("string"==typeof o&&(o=(0,E.escapeAttribute)(o)),t+='="'+o+'"'))}return t}(t);return L.has(e)?"<"+e+i+"/>":"<"+e+i+">"+o+""}function B(e,t,n={}){let r="";e=Array.isArray(e)?e:[e];for(let o=0;o{var e={3282:(e,t,n)=>{"use strict";t.Z=function(e){var t=e.from,n=void 0===t?{x:0,y:0}:t,a=e.to,l=void 0===a?{x:1,y:1}:a,c=e.fill,u=void 0===c?"transparent":c,h=e.className,f=e.innerRef,d=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r=0||(i[n]=e[n]);return i}(e,o),p=n.x===l.x||n.y===l.y;return r.default.createElement("line",s({ref:f,className:(0,i.default)("visx-line",h),x1:n.x,y1:n.y,x2:l.x,y2:l.y,fill:u,shapeRendering:p?"crispEdges":"auto"},d))};var r=a(n(9196)),i=a(n(4184)),o=["from","to","fill","className","innerRef"];function a(e){return e&&e.__esModule?e:{default:e}}function s(){return s=Object.assign?Object.assign.bind():function(e){for(var t=1;t{"use strict";function t(e,t,i){e instanceof RegExp&&(e=n(e,i)),t instanceof RegExp&&(t=n(t,i));var o=r(e,t,i);return o&&{start:o[0],end:o[1],pre:i.slice(0,o[0]),body:i.slice(o[0]+e.length,o[1]),post:i.slice(o[1]+t.length)}}function n(e,t){var n=t.match(e);return n?n[0]:null}function r(e,t,n){var r,i,o,a,s,l=n.indexOf(e),c=n.indexOf(t,l+1),u=l;if(l>=0&&c>0){if(e===t)return[l,c];for(r=[],o=n.length;u>=0&&!s;)u==l?(r.push(u),l=n.indexOf(e,u+1)):1==r.length?s=[r.pop(),c]:((i=r.pop())=0?l:c;r.length&&(s=[o,a])}return s}e.exports=t,t.range=r},4184:(e,t)=>{var n;!function(){"use strict";var r={}.hasOwnProperty;function i(){for(var e=[],t=0;ti&&(e.splice(r+1,0,u),n=!0)}var d;return n}}function s(e,t,n,r){var i=r-e*e,o=Math.abs(i)<1e-24?0:(n-e*t)/i;return[t-o*e,o]}function l(){var e,n=function(e){return e[0]},o=function(e){return e[1]};function a(a){var l=0,c=0,u=0,h=0,f=0,d=e?+e[0]:1/0,p=e?+e[1]:-1/0;r(a,n,o,(function(t,n){++l,c+=(t-c)/l,u+=(n-u)/l,h+=(t*n-h)/l,f+=(t*t-f)/l,e||(tp&&(p=t))}));var g=t(s(c,u,h,f),2),y=g[0],m=g[1],v=function(e){return m*e+y},x=[[d,v(d)],[p,v(p)]];return x.a=m,x.b=y,x.predict=v,x.rSquared=i(a,n,o,u,v),x}return a.domain=function(t){return arguments.length?(e=t,a):e},a.x=function(e){return arguments.length?(n=e,a):n},a.y=function(e){return arguments.length?(o=e,a):o},a}function c(e){e.sort((function(e,t){return e-t}));var t=e.length/2;return t%1==0?(e[t-1]+e[t])/2:e[Math.floor(t)]}function u(e){return(e=1-e*e*e)*e*e}function h(e,t,n){var r=e[t],i=n[0],o=n[1]+1;if(!(o>=e.length))for(;t>i&&e[o]-r<=r-e[i];)n[0]=++i,n[1]=o,++o}function f(){var e,o=function(e){return e[0]},s=function(e){return e[1]};function l(l){var c,u,h,f,d=t(n(l,o,s),4),p=d[0],g=d[1],y=d[2],m=d[3],v=p.length,x=0,b=0,_=0,w=0,k=0;for(c=0;cO&&(O=t))}));var C=_-x*x,T=x*C-b*b,A=(k*x-w*b)/T,N=(w*C-k*b)/T,P=-A*x,R=function(e){return A*(e-=y)*e+N*e+P+m},D=a(S,O,R);return D.a=A,D.b=N-2*A*y,D.c=P-N*y+A*y*y+m,D.predict=R,D.rSquared=i(l,o,s,E,R),D}return l.domain=function(t){return arguments.length?(e=t,l):e},l.x=function(e){return arguments.length?(o=e,l):o},l.y=function(e){return arguments.length?(s=e,l):s},l}e.regressionExp=function(){var e,n=function(e){return e[0]},o=function(e){return e[1]};function l(l){var c=0,u=0,h=0,f=0,d=0,p=0,g=e?+e[0]:1/0,y=e?+e[1]:-1/0;r(l,n,o,(function(t,n){var r=Math.log(n),i=t*n;++c,u+=(n-u)/c,f+=(i-f)/c,p+=(t*i-p)/c,h+=(n*r-h)/c,d+=(i*r-d)/c,e||(ty&&(y=t))}));var m=t(s(f/u,h/u,d/u,p/u),2),v=m[0],x=m[1];v=Math.exp(v);var b=function(e){return v*Math.exp(x*e)},_=a(g,y,b);return _.a=v,_.b=x,_.predict=b,_.rSquared=i(l,n,o,u,b),_}return l.domain=function(t){return arguments.length?(e=t,l):e},l.x=function(e){return arguments.length?(n=e,l):n},l.y=function(e){return arguments.length?(o=e,l):o},l},e.regressionLinear=l,e.regressionLoess=function(){var e=function(e){return e[0]},r=function(e){return e[1]},i=.3;function o(o){for(var a=t(n(o,e,r,!0),4),l=a[0],f=a[1],d=a[2],p=a[3],g=l.length,y=Math.max(2,~~(i*g)),m=new Float64Array(g),v=new Float64Array(g),x=new Float64Array(g).fill(1),b=-1;++b<=2;){for(var _=[0,y-1],w=0;wl[M]-k?E:M,O=0,C=0,T=0,A=0,N=0,P=1/Math.abs(l[S]-k||1),R=E;R<=M;++R){var D=l[R],j=f[R],L=u(Math.abs(k-D)*P)*x[R],F=D*L;O+=L,C+=F,T+=j*L,A+=j*F,N+=D*F}var $=t(s(C/O,T/O,A/O,N/O),2),z=$[0],I=$[1];m[w]=z+I*k,v[w]=Math.abs(f[w]-m[w]),h(l,w+1,_)}if(2===b)break;var W=c(v);if(Math.abs(W)<1e-12)break;for(var U,H,Y=0;Y=1?1e-12:(H=1-U*U)*H}return function(e,t,n,r){for(var i,o=e.length,a=[],s=0,l=0,c=[];sy&&(y=t))}));var v=t(s(h,f,d,p),2),x=v[0],b=v[1],_=function(e){return b*Math.log(e)/m+x},w=a(g,y,_);return w.a=b,w.b=x,w.predict=_,w.rSquared=i(c,n,o,f,_),w}return c.domain=function(t){return arguments.length?(e=t,c):e},c.x=function(e){return arguments.length?(n=e,c):n},c.y=function(e){return arguments.length?(o=e,c):o},c.base=function(e){return arguments.length?(l=e,c):l},c},e.regressionPoly=function(){var e,o=function(e){return e[0]},s=function(e){return e[1]},c=3;function u(u){if(1===c){var h=l().x(o).y(s).domain(e)(u);return h.coefficients=[h.b,h.a],delete h.a,delete h.b,h}if(2===c){var d=f().x(o).y(s).domain(e)(u);return d.coefficients=[d.c,d.b,d.a],delete d.a,delete d.b,delete d.c,d}var p,g,y,m,v,x=t(n(u,o,s),4),b=x[0],_=x[1],w=x[2],k=x[3],E=b.length,M=[],S=[],O=c+1,C=0,T=0,A=e?+e[0]:1/0,N=e?+e[1]:-1/0;for(r(u,o,s,(function(t,n){++T,C+=(n-C)/T,e||(tN&&(N=t))})),p=0;pMath.abs(e[t][i])&&(i=n);for(r=t;r=t;r--)e[r][n]-=e[r][t]*e[t][n]/e[t][t]}for(n=a-1;n>=0;--n){for(o=0,r=n+1;r=0;--i)for(a=t[i],s=1,l[i]+=a,o=1;o<=i;++o)s*=(i+1-o)/o,l[i-o]+=a*Math.pow(n,o)*s;return l[0]+=r,l}(O,P,-w,k),D.predict=R,D.rSquared=i(u,o,s,C,R),D}return u.domain=function(t){return arguments.length?(e=t,u):e},u.x=function(e){return arguments.length?(o=e,u):o},u.y=function(e){return arguments.length?(s=e,u):s},u.order=function(e){return arguments.length?(c=e,u):c},u},e.regressionPow=function(){var e,n=function(e){return e[0]},o=function(e){return e[1]};function l(l){var c=0,u=0,h=0,f=0,d=0,p=0,g=e?+e[0]:1/0,y=e?+e[1]:-1/0;r(l,n,o,(function(t,n){var r=Math.log(t),i=Math.log(n);++c,u+=(r-u)/c,h+=(i-h)/c,f+=(r*i-f)/c,d+=(r*r-d)/c,p+=(n-p)/c,e||(ty&&(y=t))}));var m=t(s(u,h,f,d),2),v=m[0],x=m[1];v=Math.exp(v);var b=function(e){return v*Math.pow(e,x)},_=a(g,y,b);return _.a=v,_.b=x,_.predict=b,_.rSquared=i(l,n,o,p,b),_}return l.domain=function(t){return arguments.length?(e=t,l):e},l.x=function(e){return arguments.length?(n=e,l):n},l.y=function(e){return arguments.length?(o=e,l):o},l},e.regressionQuad=f,Object.defineProperty(e,"__esModule",{value:!0})}(t)},8679:(e,t,n)=>{"use strict";var r=n(1296),i={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},o={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},s={};function l(e){return r.isMemo(e)?a:s[e.$$typeof]||i}s[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},s[r.Memo]=a;var c=Object.defineProperty,u=Object.getOwnPropertyNames,h=Object.getOwnPropertySymbols,f=Object.getOwnPropertyDescriptor,d=Object.getPrototypeOf,p=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(p){var i=d(n);i&&i!==p&&e(t,i,r)}var a=u(n);h&&(a=a.concat(h(n)));for(var s=l(t),g=l(n),y=0;y{"use strict";var n="function"==typeof Symbol&&Symbol.for,r=n?Symbol.for("react.element"):60103,i=n?Symbol.for("react.portal"):60106,o=n?Symbol.for("react.fragment"):60107,a=n?Symbol.for("react.strict_mode"):60108,s=n?Symbol.for("react.profiler"):60114,l=n?Symbol.for("react.provider"):60109,c=n?Symbol.for("react.context"):60110,u=n?Symbol.for("react.async_mode"):60111,h=n?Symbol.for("react.concurrent_mode"):60111,f=n?Symbol.for("react.forward_ref"):60112,d=n?Symbol.for("react.suspense"):60113,p=n?Symbol.for("react.suspense_list"):60120,g=n?Symbol.for("react.memo"):60115,y=n?Symbol.for("react.lazy"):60116,m=n?Symbol.for("react.block"):60121,v=n?Symbol.for("react.fundamental"):60117,x=n?Symbol.for("react.responder"):60118,b=n?Symbol.for("react.scope"):60119;function _(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case r:switch(e=e.type){case u:case h:case o:case s:case a:case d:return e;default:switch(e=e&&e.$$typeof){case c:case f:case y:case g:case l:return e;default:return t}}case i:return t}}}function w(e){return _(e)===h}t.AsyncMode=u,t.ConcurrentMode=h,t.ContextConsumer=c,t.ContextProvider=l,t.Element=r,t.ForwardRef=f,t.Fragment=o,t.Lazy=y,t.Memo=g,t.Portal=i,t.Profiler=s,t.StrictMode=a,t.Suspense=d,t.isAsyncMode=function(e){return w(e)||_(e)===u},t.isConcurrentMode=w,t.isContextConsumer=function(e){return _(e)===c},t.isContextProvider=function(e){return _(e)===l},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===r},t.isForwardRef=function(e){return _(e)===f},t.isFragment=function(e){return _(e)===o},t.isLazy=function(e){return _(e)===y},t.isMemo=function(e){return _(e)===g},t.isPortal=function(e){return _(e)===i},t.isProfiler=function(e){return _(e)===s},t.isStrictMode=function(e){return _(e)===a},t.isSuspense=function(e){return _(e)===d},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===o||e===h||e===s||e===a||e===d||e===p||"object"==typeof e&&null!==e&&(e.$$typeof===y||e.$$typeof===g||e.$$typeof===l||e.$$typeof===c||e.$$typeof===f||e.$$typeof===v||e.$$typeof===x||e.$$typeof===b||e.$$typeof===m)},t.typeOf=_},1296:(e,t,n)=>{"use strict";e.exports=n(6103)},1989:(e,t,n)=>{var r=n(1789),i=n(401),o=n(7667),a=n(1327),s=n(1866);function l(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t{var r=n(7040),i=n(4125),o=n(2117),a=n(7518),s=n(4705);function l(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t{var r=n(852)(n(5639),"Map");e.exports=r},3369:(e,t,n)=>{var r=n(4785),i=n(1285),o=n(6e3),a=n(9916),s=n(5265);function l(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t{var r=n(5639).Symbol;e.exports=r},8470:(e,t,n)=>{var r=n(7813);e.exports=function(e,t){for(var n=e.length;n--;)if(r(e[n][0],t))return n;return-1}},4239:(e,t,n)=>{var r=n(2705),i=n(9607),o=n(2333),a=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":a&&a in Object(e)?i(e):o(e)}},8458:(e,t,n)=>{var r=n(3560),i=n(5346),o=n(3218),a=n(346),s=/^\[object .+?Constructor\]$/,l=Function.prototype,c=Object.prototype,u=l.toString,h=c.hasOwnProperty,f=RegExp("^"+u.call(h).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(e){return!(!o(e)||i(e))&&(r(e)?f:s).test(a(e))}},4429:(e,t,n)=>{var r=n(5639)["__core-js_shared__"];e.exports=r},1957:(e,t,n)=>{var r="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g;e.exports=r},5050:(e,t,n)=>{var r=n(7019);e.exports=function(e,t){var n=e.__data__;return r(t)?n["string"==typeof t?"string":"hash"]:n.map}},852:(e,t,n)=>{var r=n(8458),i=n(7801);e.exports=function(e,t){var n=i(e,t);return r(n)?n:void 0}},9607:(e,t,n)=>{var r=n(2705),i=Object.prototype,o=i.hasOwnProperty,a=i.toString,s=r?r.toStringTag:void 0;e.exports=function(e){var t=o.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch(e){}var i=a.call(e);return r&&(t?e[s]=n:delete e[s]),i}},7801:e=>{e.exports=function(e,t){return null==e?void 0:e[t]}},1789:(e,t,n)=>{var r=n(4536);e.exports=function(){this.__data__=r?r(null):{},this.size=0}},401:e=>{e.exports=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}},7667:(e,t,n)=>{var r=n(4536),i=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;if(r){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return i.call(t,e)?t[e]:void 0}},1327:(e,t,n)=>{var r=n(4536),i=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;return r?void 0!==t[e]:i.call(t,e)}},1866:(e,t,n)=>{var r=n(4536);e.exports=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=r&&void 0===t?"__lodash_hash_undefined__":t,this}},7019:e=>{e.exports=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}},5346:(e,t,n)=>{var r,i=n(4429),o=(r=/[^.]+$/.exec(i&&i.keys&&i.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";e.exports=function(e){return!!o&&o in e}},7040:e=>{e.exports=function(){this.__data__=[],this.size=0}},4125:(e,t,n)=>{var r=n(8470),i=Array.prototype.splice;e.exports=function(e){var t=this.__data__,n=r(t,e);return!(n<0||(n==t.length-1?t.pop():i.call(t,n,1),--this.size,0))}},2117:(e,t,n)=>{var r=n(8470);e.exports=function(e){var t=this.__data__,n=r(t,e);return n<0?void 0:t[n][1]}},7518:(e,t,n)=>{var r=n(8470);e.exports=function(e){return r(this.__data__,e)>-1}},4705:(e,t,n)=>{var r=n(8470);e.exports=function(e,t){var n=this.__data__,i=r(n,e);return i<0?(++this.size,n.push([e,t])):n[i][1]=t,this}},4785:(e,t,n)=>{var r=n(1989),i=n(8407),o=n(7071);e.exports=function(){this.size=0,this.__data__={hash:new r,map:new(o||i),string:new r}}},1285:(e,t,n)=>{var r=n(5050);e.exports=function(e){var t=r(this,e).delete(e);return this.size-=t?1:0,t}},6e3:(e,t,n)=>{var r=n(5050);e.exports=function(e){return r(this,e).get(e)}},9916:(e,t,n)=>{var r=n(5050);e.exports=function(e){return r(this,e).has(e)}},5265:(e,t,n)=>{var r=n(5050);e.exports=function(e,t){var n=r(this,e),i=n.size;return n.set(e,t),this.size+=n.size==i?0:1,this}},4536:(e,t,n)=>{var r=n(852)(Object,"create");e.exports=r},2333:e=>{var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},5639:(e,t,n)=>{var r=n(1957),i="object"==typeof self&&self&&self.Object===Object&&self,o=r||i||Function("return this")();e.exports=o},346:e=>{var t=Function.prototype.toString;e.exports=function(e){if(null!=e){try{return t.call(e)}catch(e){}try{return e+""}catch(e){}}return""}},7813:e=>{e.exports=function(e,t){return e===t||e!=e&&t!=t}},3560:(e,t,n)=>{var r=n(4239),i=n(3218);e.exports=function(e){if(!i(e))return!1;var t=r(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},3218:e=>{e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},8306:(e,t,n)=>{var r=n(3369);function i(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=e.apply(this,r);return n.cache=o.set(i,a)||o,a};return n.cache=new(i.Cache||r),n}i.Cache=r,e.exports=i},2087:(e,t,n)=>{var r=n(8361);r.prototype.formulaEval=function(){"use strict";for(var e,t,n,r=[],i=this.value,o=0;o"+t.value+""+i[o].show+""+e.value+"",type:10}):r.push({value:(1!=t.type?"(":"")+t.value+(1!=t.type?")":"")+""+e.value+"",type:1})):2===i[o].type||9===i[o].type?(e=r.pop(),t=r.pop(),r.push({value:(1!=t.type?"(":"")+t.value+(1!=t.type?")":"")+i[o].show+(1!=e.type?"(":"")+e.value+(1!=e.type?")":""),type:i[o].type})):12===i[o].type&&(e=r.pop(),t=r.pop(),n=r.pop(),r.push({value:i[o].show+"("+n.value+","+t.value+","+e.value+")",type:12}));return r[0].value},e.exports=r},7735:(e,t,n)=>{"use strict";var r=n(3553);function i(e,t){for(var n=0;np.length-2?p.length-1:e.length-l;n>0;n--)if(void 0!==p[n])for(i=0;i0&&n{"use strict";var t=function(e){this.value=e};t.math={isDegree:!0,acos:function(e){return t.math.isDegree?180/Math.PI*Math.acos(e):Math.acos(e)},add:function(e,t){return e+t},asin:function(e){return t.math.isDegree?180/Math.PI*Math.asin(e):Math.asin(e)},atan:function(e){return t.math.isDegree?180/Math.PI*Math.atan(e):Math.atan(e)},acosh:function(e){return Math.log(e+Math.sqrt(e*e-1))},asinh:function(e){return Math.log(e+Math.sqrt(e*e+1))},atanh:function(e){return Math.log((1+e)/(1-e))},C:function(e,n){var r=1,i=e-n,o=n;o{var r=n(7735);r.prototype.toPostfix=function(){"use strict";for(var e,t,n,i,o,a=[],s=[{value:"(",type:4,pre:0}],l=this.value,c=1;cn)s.push(e);else{for(;n>=i&&!u||u&&i{var r=n(7186);r.prototype.postfixEval=function(e){"use strict";(e=e||{}).PI=Math.PI,e.E=Math.E;for(var t,n,i,o=[],a=this.value,s=void 0!==e.n,l=0;l1)throw new r.Exception("Uncaught Syntax error");return o[0].value>1e15?"Infinity":parseFloat(o[0].value.toFixed(15))},r.eval=function(e,t,n){return void 0===t?this.lex(e).toPostfix().postfixEval():void 0===n?void 0!==t.length?this.lex(e,t).toPostfix().postfixEval():this.lex(e).toPostfix().postfixEval(t):this.lex(e,t).toPostfix().postfixEval(n)},e.exports=r},3917:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=function(e,t){return e<>>32-t},n=function(e,t){var n,r,i,o,a;return i=2147483648&e,o=2147483648&t,a=(1073741823&e)+(1073741823&t),(n=1073741824&e)&(r=1073741824&t)?2147483648^a^i^o:n|r?1073741824&a?3221225472^a^i^o:1073741824^a^i^o:a^i^o},r=function(e,r,i,o,a,s,l){return e=n(e,n(n(function(e,t,n){return e&t|~e&n}(r,i,o),a),l)),n(t(e,s),r)},i=function(e,r,i,o,a,s,l){return e=n(e,n(n(function(e,t,n){return e&n|t&~n}(r,i,o),a),l)),n(t(e,s),r)},o=function(e,r,i,o,a,s,l){return e=n(e,n(n(function(e,t,n){return e^t^n}(r,i,o),a),l)),n(t(e,s),r)},a=function(e,r,i,o,a,s,l){return e=n(e,n(n(function(e,t,n){return t^(e|~n)}(r,i,o),a),l)),n(t(e,s),r)},s=function(e){var t="",n="",r=void 0;for(r=0;r<=3;r++)t+=(n="0"+(e>>>8*r&255).toString(16)).substr(n.length-2,2);return t},l=Array(),c=void 0,u=void 0,h=void 0,f=void 0,d=void 0,p=void 0,g=void 0,y=void 0,m=void 0;for(l=function(e){for(var t=void 0,n=e.length,r=n+8,i=16*((r-r%64)/64+1),o=Array(i-1),a=0,s=0;s>>29,o}(e=function(e){e=e.replace(/rn/g,"n");for(var t="",n=0;n127&&r<2048?(t+=String.fromCharCode(r>>6|192),t+=String.fromCharCode(63&r|128)):(t+=String.fromCharCode(r>>12|224),t+=String.fromCharCode(r>>6&63|128),t+=String.fromCharCode(63&r|128))}return t}(e)),p=1732584193,g=4023233417,y=2562383102,m=271733878,c=0;c{"use strict";var r=n(414);function i(){}function o(){}o.resetWarningCache=i,e.exports=function(){function e(e,t,n,i,o,a){if(a!==r){var s=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 s.name="Invariant Violation",s}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:o,resetWarningCache:i};return n.PropTypes=n,n}},5697:(e,t,n)=>{e.exports=n(2703)()},414:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},5800:function(e,t,n){!function(e,t){"use strict";function n(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}var r=n(t);function i(e,t){return i=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},i(e,t)}var o={error:null},a=function(e){function t(){for(var t,n=arguments.length,r=new Array(n),i=0;i{"use strict";var n,r=Symbol.for("react.element"),i=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),a=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),l=Symbol.for("react.provider"),c=Symbol.for("react.context"),u=Symbol.for("react.server_context"),h=Symbol.for("react.forward_ref"),f=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),g=Symbol.for("react.lazy"),y=Symbol.for("react.offscreen");n=Symbol.for("react.module.reference"),t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===o||e===s||e===a||e===f||e===d||e===y||"object"==typeof e&&null!==e&&(e.$$typeof===g||e.$$typeof===p||e.$$typeof===l||e.$$typeof===c||e.$$typeof===h||e.$$typeof===n||void 0!==e.getModuleId)},t.typeOf=function(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case r:switch(e=e.type){case o:case s:case a:case f:case d:return e;default:switch(e=e&&e.$$typeof){case u:case c:case h:case g:case p:case l:return e;default:return t}}case i:return t}}}},9864:(e,t,n)=>{"use strict";e.exports=n(9921)},6488:(e,t,n)=>{var r,i=n(6524),o=n(6913),a=n(2087),s=/(\+|\-|\*|\\|[^a-z]|)(\s*)(\()/g;e.exports=function(e,t){return r=0,t=Math.pow(10,void 0===t?5:t),e=e.replace(/\n+/g," "),o(e,/((?:\-[a-z]+\-)?calc)\(/,(function e(n,o,l){if(r++>100)throw r=0,new Error("Call stack overflow for "+l);if(""===n)throw new Error(o+"(): '"+l+"' must contain a non-whitespace string");n=function(t,n){for(var r,o="",a=t=t.replace(/((?:\-[a-z]+\-)?calc)/g,"");r=s.exec(a);){r[0].index>0&&(o+=a.substring(0,r[0].index));var l=i("(",")",a.substring([0].index));if(""===l.body)throw new Error("'"+t+"' must contain a non-whitespace string");var c=e(l.body,"",n);o+=l.pre+c,a=l.post}return o+a}(n,l);var c=function(e){for(var t=[],n=[],r=/[\.0-9]([%a-z]+)/gi,i=r.exec(e);i;)i&&i[1]&&(-1===n.indexOf(i[1].toLowerCase())&&(t.push(i[1]),n.push(i[1].toLowerCase())),i=r.exec(e));return t}(n);if(c.length>1||n.indexOf("var(")>-1)return o+"("+n+")";var u=c[0]||"";"%"===u&&(n=n.replace(/\b[0-9\.]+%/g,(function(e){return.01*parseFloat(e.slice(0,-1))})));var h,f=n.replace(new RegExp(u,"gi"),"");try{h=a.eval(f)}catch(e){return o+"("+n+")"}return"%"===u&&(h*=100),(o.length||"%"===u)&&(h=Math.round(h*t)/t),h+u}))}},6524:e=>{function t(e,t,i){e instanceof RegExp&&(e=n(e,i)),t instanceof RegExp&&(t=n(t,i));var o=r(e,t,i);return o&&{start:o[0],end:o[1],pre:i.slice(0,o[0]),body:i.slice(o[0]+e.length,o[1]),post:i.slice(o[1]+t.length)}}function n(e,t){var n=t.match(e);return n?n[0]:null}function r(e,t,n){var r,i,o,a,s,l=n.indexOf(e),c=n.indexOf(t,l+1),u=l;if(l>=0&&c>0){for(r=[],o=n.length;u>=0&&!s;)u==l?(r.push(u),l=n.indexOf(e,u+1)):1==r.length?s=[r.pop(),c]:((i=r.pop())=0?l:c;r.length&&(s=[o,a])}return s}e.exports=t,t.range=r},6913:(e,t,n)=>{var r=n(5623);e.exports=function e(t,n,i){var o=t;return function(e,t){var n=[],i="string"==typeof t?new RegExp("\\b("+t+")\\("):t;do{var o=i.exec(e);if(!o)return n;if(void 0===o[1])throw new Error("Missing the first couple of parenthesis to get the function identifier in "+t);var a=o[1],s=o.index,l=r("(",")",e.substring(s));if(!l||l.start!==o[0].length-1)throw new SyntaxError(a+"(): missing closing ')' in the value '"+e+"'");n.push({matches:l,functionIdentifier:a}),e=l.post}while(i.test(e));return n}(t,n).reduce((function(t,r){return t.replace(r.functionIdentifier+"("+r.matches.body+")",function(t,n,r,i,o){return r(e(t,o,r),n,i)}(r.matches.body,r.functionIdentifier,i,o,n))}),t)}},6774:e=>{e.exports=function(e,t,n,r){var i=n?n.call(r,e,t):void 0;if(void 0!==i)return!!i;if(e===t)return!0;if("object"!=typeof e||!e||"object"!=typeof t||!t)return!1;var o=Object.keys(e),a=Object.keys(t);if(o.length!==a.length)return!1;for(var s=Object.prototype.hasOwnProperty.bind(t),l=0;l{"use strict";e.exports=window.React}},t={};function n(r){var i=t[r];if(void 0!==i)return i.exports;var o=t[r]={exports:{}};return e[r].call(o.exports,o,o.exports,n),o.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nc=void 0,(()=>{"use strict";var e={};n.r(e),n.d(e,{curveBasis:()=>ah,curveBasisClosed:()=>ch,curveBasisOpen:()=>hh,curveBundle:()=>mh,curveCardinal:()=>wh,curveCardinalClosed:()=>Eh,curveCardinalOpen:()=>Sh,curveCatmullRom:()=>Th,curveCatmullRomClosed:()=>Nh,curveCatmullRomOpen:()=>Rh,curveLinear:()=>zu,curveLinearClosed:()=>xh,curveMonotoneX:()=>Wh,curveMonotoneY:()=>Uh,curveNatural:()=>Bh,curveStep:()=>dh,curveStepAfter:()=>gh,curveStepBefore:()=>ph});const t=window.wp.element;var r=n(9864),i=n(9196),o=n.n(i),a=n(6774),s=n.n(a);const l=function(e){function t(e,r,l,c,f){for(var d,p,g,y,b,w=0,k=0,E=0,M=0,S=0,P=0,D=g=d=0,L=0,F=0,$=0,z=0,I=l.length,W=I-1,U="",H="",Y="",B="";Ld)&&(z=(U=U.replace(" ",":")).length),0r&&(r=(t=t.trim()).charCodeAt(0)),r){case 38:return t.replace(y,"$1"+e.trim());case 58:return e.trim()+t.replace(y,"$1"+e.trim());default:if(0<1*n&&0l.charCodeAt(8))break;case 115:a=a.replace(l,"-webkit-"+l)+";"+a;break;case 207:case 102:a=a.replace(l,"-webkit-"+(102r.charCodeAt(0)&&(r=r.trim()),r=[r],01?t-1:0),r=1;r0?" Args: "+n.join(", "):""))}var O=function(){function e(e){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=e}var t=e.prototype;return t.indexOfGroup=function(e){for(var t=0,n=0;n=this.groupSizes.length){for(var n=this.groupSizes,r=n.length,i=r;e>=i;)(i<<=1)<0&&S(16,""+e);this.groupSizes=new Uint32Array(i),this.groupSizes.set(n),this.length=i;for(var o=r;o=this.length||0===this.groupSizes[e])return t;for(var n=this.groupSizes[e],r=this.indexOfGroup(e),i=r+n,o=r;o=A&&(A=t+1),C.set(e,t),T.set(t,e)},D="style["+k+'][data-styled-version="5.3.11"]',j=new RegExp("^"+k+'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)'),L=function(e,t,n){for(var r,i=n.split(","),o=0,a=i.length;o=0;n--){var r=t[n];if(r&&1===r.nodeType&&r.hasAttribute(k))return r}}(n),o=void 0!==i?i.nextSibling:null;r.setAttribute(k,"active"),r.setAttribute("data-styled-version","5.3.11");var a=$();return a&&r.setAttribute("nonce",a),n.insertBefore(r,o),r},I=function(){function e(e){var t=this.element=z(e);t.appendChild(document.createTextNode("")),this.sheet=function(e){if(e.sheet)return e.sheet;for(var t=document.styleSheets,n=0,r=t.length;n=0){var n=document.createTextNode(t),r=this.nodes[e];return this.element.insertBefore(n,r||null),this.length++,!0}return!1},t.deleteRule=function(e){this.element.removeChild(this.nodes[e]),this.length--},t.getRule=function(e){return e0&&(c+=e+",")})),r+=""+s+l+'{content:"'+c+'"}/*!sc*/\n'}}}return r}(this)},e}(),V=/(a)(d)/gi,q=function(e){return String.fromCharCode(e+(e>25?39:97))};function G(e){var t,n="";for(t=Math.abs(e);t>52;t=t/52|0)n=q(t%52)+n;return(q(t%52)+n).replace(V,"$1-$2")}var K=function(e,t){for(var n=t.length;n;)e=33*e^t.charCodeAt(--n);return e},X=function(e){return K(5381,e)};function Z(e){for(var t=0;t>>0);if(!t.hasNameForId(r,a)){var s=n(o,"."+a,void 0,r);t.insertRules(r,a,s)}i.push(a),this.staticRulesId=a}else{for(var l=this.rules.length,c=K(this.baseHash,n.hash),u="",h=0;h>>0);if(!t.hasNameForId(r,g)){var y=n(u,"."+g,void 0,r);t.insertRules(r,g,y)}i.push(g)}}return i.join(" ")},e}(),ee=/^\s*\/\/.*$/gm,te=[":","[",".","#"];function ne(e){var t,n,r,i,o=void 0===e?x:e,a=o.options,s=void 0===a?x:a,c=o.plugins,u=void 0===c?v:c,h=new l(s),f=[],d=function(e){function t(t){if(t)try{e(t+"}")}catch(e){}}return function(n,r,i,o,a,s,l,c,u,h){switch(n){case 1:if(0===u&&64===r.charCodeAt(0))return e(r+";"),"";break;case 2:if(0===c)return r+"/*|*/";break;case 3:switch(c){case 102:case 112:return e(i[0]+r),"";default:return r+(0===h?"/*|*/":"")}case-2:r.split("/*|*/}").forEach(t)}}}((function(e){f.push(e)})),p=function(e,r,o){return 0===r&&-1!==te.indexOf(o[n.length])||o.match(i)?e:"."+t};function g(e,o,a,s){void 0===s&&(s="&");var l=e.replace(ee,""),c=o&&a?a+" "+o+" { "+l+" }":l;return t=s,n=o,r=new RegExp("\\"+n+"\\b","g"),i=new RegExp("(\\"+n+"\\b){2,}"),h(a||!o?"":o,c)}return h.use([].concat(u,[function(e,t,i){2===e&&i.length&&i[0].lastIndexOf(n)>0&&(i[0]=i[0].replace(r,p))},d,function(e){if(-2===e){var t=f;return f=[],t}}])),g.hash=u.length?u.reduce((function(e,t){return t.name||S(15),K(e,t.name)}),5381).toString():"",g}var re=o().createContext(),ie=(re.Consumer,o().createContext()),oe=(ie.Consumer,new B),ae=ne();function se(){return(0,i.useContext)(re)||oe}function le(e){var t=(0,i.useState)(e.stylisPlugins),n=t[0],r=t[1],a=se(),l=(0,i.useMemo)((function(){var t=a;return e.sheet?t=e.sheet:e.target&&(t=t.reconstructWithOptions({target:e.target},!1)),e.disableCSSOMInjection&&(t=t.reconstructWithOptions({useCSSOMInjection:!1})),t}),[e.disableCSSOMInjection,e.sheet,e.target]),c=(0,i.useMemo)((function(){return ne({options:{prefix:!e.disableVendorPrefixes},plugins:n})}),[e.disableVendorPrefixes,n]);return(0,i.useEffect)((function(){s()(n,e.stylisPlugins)||r(e.stylisPlugins)}),[e.stylisPlugins]),o().createElement(re.Provider,{value:l},o().createElement(ie.Provider,{value:c},e.children))}var ce=function(){function e(e,t){var n=this;this.inject=function(e,t){void 0===t&&(t=ae);var r=n.name+t.hash;e.hasNameForId(n.id,r)||e.insertRules(n.id,r,t(n.rules,r,"@keyframes"))},this.toString=function(){return S(12,String(n.name))},this.name=e,this.id="sc-keyframes-"+e,this.rules=t}return e.prototype.getName=function(e){return void 0===e&&(e=ae),this.name+e.hash},e}(),ue=/([A-Z])/,he=/([A-Z])/g,fe=/^ms-/,de=function(e){return"-"+e.toLowerCase()};function pe(e){return ue.test(e)?e.replace(he,de).replace(fe,"-ms-"):e}var ge=function(e){return null==e||!1===e||""===e};function ye(e,t,n,r){if(Array.isArray(e)){for(var i,o=[],a=0,s=e.length;a1?t-1:0),r=1;r?@[\\\]^`{|}~-]+/g,be=/(^-|-$)/g;function _e(e){return e.replace(xe,"-").replace(be,"")}function we(e){return"string"==typeof e&&!0}var ke=function(e){return"function"==typeof e||"object"==typeof e&&null!==e&&!Array.isArray(e)},Ee=function(e){return"__proto__"!==e&&"constructor"!==e&&"prototype"!==e};function Me(e,t,n){var r=e[n];ke(t)&&ke(r)?Se(r,t):e[n]=t}function Se(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r>>0)}("5.3.11"+n+Ce[n]);return t?t+"-"+r:r}(t.displayName,t.parentComponentId):c,h=t.displayName,d=void 0===h?function(e){return we(e)?"styled."+e:"Styled("+_(e)+")"}(e):h,y=t.displayName&&t.componentId?_e(t.displayName)+"-"+t.componentId:t.componentId||u,m=r&&e.attrs?Array.prototype.concat(e.attrs,l).filter(Boolean):l,k=t.shouldForwardProp;r&&e.shouldForwardProp&&(k=t.shouldForwardProp?function(n,r,i){return e.shouldForwardProp(n,r,i)&&t.shouldForwardProp(n,r,i)}:e.shouldForwardProp);var E,M=new Q(n,y,r?e.componentStyle:void 0),S=M.isStatic&&0===l.length,O=function(e,t){return function(e,t,n,r){var o=e.attrs,a=e.componentStyle,s=e.defaultProps,l=e.foldedComponentIds,c=e.shouldForwardProp,u=e.styledComponentId,h=e.target,d=function(e,t,n){void 0===e&&(e=x);var r=g({},t,{theme:e}),i={};return n.forEach((function(e){var t,n,o,a=e;for(t in b(a)&&(a=a(r)),a)r[t]=i[t]="className"===t?(n=i[t],o=a[t],n&&o?n+" "+o:n||o):a[t]})),[r,i]}(function(e,t,n){return void 0===n&&(n=x),e.theme!==n.theme&&e.theme||t||n.theme}(t,(0,i.useContext)(Oe),s)||x,t,o),p=d[0],y=d[1],m=function(e,t,n,r){var o=se(),a=(0,i.useContext)(ie)||ae;return t?e.generateAndInjectStyles(x,o,a):e.generateAndInjectStyles(n,o,a)}(a,r,p),v=n,_=y.$as||t.$as||y.as||t.as||h,w=we(_),k=y!==t?g({},t,{},y):t,E={};for(var M in k)"$"!==M[0]&&"as"!==M&&("forwardedAs"===M?E.as=k[M]:(c?c(M,f,_):!w||f(M))&&(E[M]=k[M]));return t.style&&y.style!==t.style&&(E.style=g({},t.style,{},y.style)),E.className=Array.prototype.concat(l,u,m!==u?m:null,t.className,y.className).filter(Boolean).join(" "),E.ref=v,(0,i.createElement)(_,E)}(E,e,t,S)};return O.displayName=d,(E=o().forwardRef(O)).attrs=m,E.componentStyle=M,E.displayName=d,E.shouldForwardProp=k,E.foldedComponentIds=r?Array.prototype.concat(e.foldedComponentIds,e.styledComponentId):v,E.styledComponentId=y,E.target=r?e.target:e,E.withComponent=function(e){var r=t.componentId,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r=0||(i[n]=e[n]);return i}(t,["componentId"]),o=r&&r+"-"+(we(e)?e:_e(_(e)));return Te(e,g({},i,{attrs:m,componentId:o}),n)},Object.defineProperty(E,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(t){this._foldedDefaultProps=r?Se({},e.defaultProps,t):t}}),Object.defineProperty(E,"toString",{value:function(){return"."+E.styledComponentId}}),a&&p()(E,e,{attrs:!0,componentStyle:!0,displayName:!0,foldedComponentIds:!0,shouldForwardProp:!0,styledComponentId:!0,target:!0,withComponent:!0}),E}var Ae,Ne=function(e){return function e(t,n,i){if(void 0===i&&(i=x),!(0,r.isValidElementType)(n))return S(1,String(n));var o=function(){return t(n,i,ve.apply(void 0,arguments))};return o.withConfig=function(r){return e(t,n,g({},i,{},r))},o.attrs=function(r){return e(t,n,g({},i,{attrs:Array.prototype.concat(i.attrs,r).filter(Boolean)}))},o}(Te,e)};["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","textPath","tspan"].forEach((function(e){Ne[e]=Ne(e)})),(Ae=function(e,t){this.rules=e,this.componentId=t,this.isStatic=Z(e),B.registerId(this.componentId+1)}.prototype).createStyles=function(e,t,n,r){var i=r(ye(this.rules,t,n,r).join(""),""),o=this.componentId+e;n.insertRules(o,o,i)},Ae.removeStyles=function(e,t){t.clearRules(this.componentId+e)},Ae.renderStyles=function(e,t,n,r){e>2&&B.registerId(this.componentId+e),this.removeStyles(e,n),this.createStyles(e,t,n,r)},function(){var e=function(){var e=this;this._emitSheetCSS=function(){var t=e.instance.toString();if(!t)return"";var n=$();return""},this.getStyleTags=function(){return e.sealed?S(2):e._emitSheetCSS()},this.getStyleElement=function(){var t;if(e.sealed)return S(2);var n=((t={})[k]="",t["data-styled-version"]="5.3.11",t.dangerouslySetInnerHTML={__html:e.instance.toString()},t),r=$();return r&&(n.nonce=r),[o().createElement("style",g({},n,{key:"sc-0-0"}))]},this.seal=function(){e.sealed=!0},this.instance=new B({isServer:!0}),this.sealed=!1}.prototype;e.collectStyles=function(e){return this.sealed?S(2):o().createElement(le,{sheet:this.instance},e)},e.interleaveWithNodeStream=function(e){return S(3)}}();const Pe=Ne,Re={layout:{name:"wp-block-prc-block-chart-builder-controller",parentClass:void 0,type:"bar",orientation:"vertical",theme:"light",width:640,height:400,padding:{top:0,bottom:0,left:0,right:0},horizontalRules:!0},metadata:{active:!1,title:"",subtitle:"",note:"",source:"",tag:"PEW RESEARCH CENTER"},colors:["#436983","#bf3927","#756a7e","#ea9e2c","#bc7b2b","#eeece4"],plotBands:{active:!1,allowDrag:!1,allowResize:!1,dimension:"x",bands:[]},independentAxis:{active:!0,label:"",scale:"linear",dateFormat:"%-m/%Y",domain:[0,100],domainPadding:20,showZero:!1,padding:60,tickAngle:0,tickCount:5,tickValues:void 0,tickFormat:null,ticksToLocaleString:!1,abbreviateTicks:!1,abbreviateTicksDecimals:0,tickUnit:"",tickUnitPosition:"end",customTickFormat:null,tickLabels:{fontSize:12,padding:0,angle:0,dx:0,dy:0,textAnchor:"middle",verticalAnchor:"start",fill:"rgba(35, 31, 32,0.7)",fontFamily:"'franklin-gothic-urw', Verdana, Geneva, sans-serif",maxWidth:50},axisLabel:{fontSize:12,fill:"rgba(35, 31, 32,0.7)",padding:15,angle:0,dx:0,dy:0,textAnchor:"end",verticalAnchor:"middle",fontFamily:"'franklin-gothic-urw', Verdana, Geneva, sans-serif",maxWidth:200},axis:{stroke:"gray",strokeWidth:1},ticks:{stroke:"gray",size:5,strokeWidth:0},grid:{stroke:"#d3d3d3",strokeOpacity:1,strokeWidth:2,strokeDasharray:".3,6"}},dependentAxis:{active:!1,label:"",scale:"linear",padding:100,domain:[0,200],domainPadding:20,showZero:!0,tickCount:10,tickValues:void 0,tickFormat:null,ticksToLocaleString:!1,abbreviateTicks:!0,abbreviateTicksDecimals:0,tickUnit:"",tickUnitPosition:"end",customTickFormat:null,tickLabels:{fontSize:12,fill:"rgba(35, 31, 32,0.7)",padding:15,angle:0,dx:0,dy:0,textAnchor:"end",verticalAnchor:"middle",fontFamily:"'franklin-gothic-urw', Verdana, Geneva, sans-serif",maxWidth:50},axisLabel:{fontSize:12,fill:"rgba(35, 31, 32,0.7)",padding:50,angle:270,dx:0,dy:0,textAnchor:"end",verticalAnchor:"middle",fontFamily:"'franklin-gothic-urw', Verdana, Geneva, sans-serif",maxWidth:50},ticks:{stroke:"gray",size:5,strokeWidth:0},axis:{stroke:"#756f6a",strokeWidth:1},grid:{stroke:"#d3d3d3",strokeOpacity:1,strokeWidth:2,strokeDasharray:".3,6"}},dataRender:{x:"x",y:"y",x2:null,y2:null,sortKey:"y",sortOrder:"ascending",categories:["A","B","C","D","E","F","G","H","I","J"],xScale:"linear",yScale:"linear",xFormat:null,yFormat:null,numberFormat:"en-US",isHighlightedColor:"#ECDBAC"},animate:{active:!1,animationWhitelist:[],duration:2e3},tooltip:{active:!0,headerActive:!0,headerValue:"independentValue",format:"{{row}}: {{value}}",offsetX:10,offsetY:10,abbreviateValue:!1,absoluteValue:!1,toFixedDecimal:0,toLocaleString:!0,customFormat:null,rlsFormat:!1,dateFormat:"%-m/%Y",caretPosition:"bottom",deemphasizeSiblings:!1,deemphasizeOpacity:.5,style:{minWidth:50,maxWidth:150,maxHeight:400,minHeight:20,width:"100%",height:"auto",fontSize:"13px",fontFamily:"'franklin-gothic-urw', Verdana, Geneva, sans-serif",background:"white",border:"1px solid black",padding:"10px",borderRadius:"5px",color:"black"}},legend:{active:!1,orientation:"row",title:"",alignment:"center",offsetX:0,offsetY:0,markerStyle:"rect",borderStroke:"black",fill:"white",categories:[]},bar:{hasRectStroke:!1,rectStrokeColor:"white",rectStrokeWidth:1,barGroupPadding:.2,barPadding:.2},line:{interpolation:"curveLinear",strokeDasharray:"1",strokeWidth:3,showPoints:!1,showArea:!1,areaFillOpacity:.4},dotPlot:{connectPoints:!0,connectingLine:{stroke:"#e6e7e8",strokeWidth:6,strokeDasharray:"",strokeOpacity:1}},explodedBar:{columnGap:16},pie:{showCategoryLabels:!0,hasPathStroke:!0,pathStrokeColor:"white",pathStrokeWidth:1},nodes:{pointSize:3,pointFill:"inherit",pointStrokeWidth:1,pointStroke:"inherit",pointCustomSize:null},labels:{active:!1,showFirstLastPointsOnly:!1,color:"inherit",fontWeight:200,fontSize:12,fontFamily:"'franklin-gothic-urw', Verdana, Geneva, sans-serif",labelPositionBar:"inside",labelCutoff:5,labelCutoffMobile:10,labelPositionDX:-25,labelPositionDY:0,pieLabelRadius:60,abbreviateValue:!1,absoluteValue:!1,toLocaleString:!0,truncateDecimal:!0,toFixedDecimal:0,labelUnit:"",labelUnitPosition:"end",textAnchor:"middle",customLabelFormat:null},voronoi:{active:!1,fill:"#756a7e",stroke:"#ccc",strokeWidth:1,strokeOpacity:.5},regression:{active:!1,type:"linear",stroke:"#2a2a2a",strokeWidth:2,strokeDasharray:"1"},divergingBar:{positiveCategories:["y","y1"],negativeCategories:["y2","y3"],netPositiveCategory:"y4",netNegativeCategory:"y5",percentOfInnerWidth:.7,neutralBar:{active:!1,offsetX:-20,separator:!0,separatorOffsetX:-1,category:"y4"}},diffColumn:{active:!1,category:"",columnHeader:"Diff",dx:0,dy:0,style:{rectStrokeWidth:0,rectStrokeColor:"white",rectFill:"none",fontWeight:"normal",fontStyle:"normal",fontSize:"10px",headerFontSize:"12px",marginLeft:10,width:30,heightOffset:0}}},De=(0,t.createContext)({data:[((e,t,n)=>{let r=[];for(let e=0;e<2;e++){const e=Math.floor(10*Math.random());r.push({x:Math.floor(10*Math.random()),x2:Math.floor(10*Math.random()),y:e,y1:Math.floor(10*Math.random())+1,xLabel:`${e}`})}return r})()],config:Re}),je=(De.Consumer,De.Provider);function Le(e,n){const[r,i]=(0,t.useState)({width:void 0,height:void 0});return(0,t.useEffect)((()=>{function t(){const t=n.current?.closest(`.${e}`);if(t){const{width:e,height:n}=t.getBoundingClientRect();i({width:e,height:n})}else i({width:window.innerWidth,height:window.innerHeight})}return window.addEventListener("resize",t),document.querySelector(".wp-block-prc-block-tabs")?window.addEventListener("tabsReady",t):window.addEventListener("load",t),setTimeout((()=>{t()}),0),()=>{window.removeEventListener("load",t),window.removeEventListener("resize",t),window.removeEventListener("tabsReady",t)}}),[e,n]),r}const Fe=(e,t)=>{if(null===e)return"";if(0===e)return"0";if(isNaN(e))return e.toString();t=!t||t<0?0:t;var n=(e=Number(e)).toPrecision(2).split("e"),r=1===n.length?0:Math.floor(Math.min(parseInt(n[1].slice(1)),14)/3),i=r<1?e.toFixed(0+t):(e/Math.pow(10,3*r)).toFixed(1+t);return(Number(i)<0?i:Math.abs(Number(i)))+["","K","M","B","T"][r]},$e=e=>{e=e.toString().replace(/^#?([a-f\d])([a-f\d])([a-f\d])$/i,(function(e,t,n,r){return t+t+n+n+r+r}));const t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return t?[parseInt(t[1],16),parseInt(t[2],16),parseInt(t[3],16)]:"black"};function ze(e,t,n){var r=[e,t,n].map((function(e){return(e/=255)<=.03928?e/12.92:Math.pow((e+.055)/1.055,2.4)}));return.2126*r[0]+.7152*r[1]+.0722*r[2]}function Ie(){const e=$e(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"#000000");return Math.round((299*e[0]+587*e[1]+114*e[2])/1e3)>125?"black":"white"}const We=(e,t)=>{if(!t)return new Date(e);if("YYYY-MM-DD"===t){const t=e.split("-");return new Date(parseInt(t[0]),parseInt(t[1])-1,parseInt(t[2]))}if("YYYY-MM"===t){const t=e.split("-");return new Date(parseInt(t[0]),parseInt(t[1])-1,1)}if("MM-DD-YYYY"===t){const t=e.split("-");return new Date(parseInt(t[2]),parseInt(t[0])-1,parseInt(t[1]))}if("DD-MM-YYYY"===t){const t=e.split("-");return new Date(parseInt(t[2]),parseInt(t[1])-1,parseInt(t[0]))}if("MM-YYYY"===t){const t=e.split("-");return new Date(parseInt(t[1]),parseInt(t[0])-1,1)}if("YYYY"===t)return new Date(parseInt(e),0,1);if("MM/DD/YYYY"===t){const t=e.split("/");return new Date(parseInt(t[2]),parseInt(t[0])-1,parseInt(t[1]))}if("MM/YYYY"===t){const t=e.split("/");return new Date(parseInt(t[1]),parseInt(t[0])-1,1)}if("DD/MM/YYYY"===t){const t=e.split("/");return new Date(parseInt(t[2]),parseInt(t[1])-1,parseInt(t[0]))}if("MM/DD"===t){const t=e.split("/");return new Date((new Date).getFullYear(),parseInt(t[0])-1,parseInt(t[1]))}if("DD/MM"===t){const t=e.split("/");return new Date((new Date).getFullYear(),parseInt(t[1])-1,parseInt(t[0]))}return"MM"===t?new Date((new Date).getFullYear(),parseInt(e)-1,1):new Date(e)},Ue=(e,t,n)=>{if(e<=3)return e;const r=t/n;return r>1?e:Math.floor(e*r)},He=(e,t,n)=>{const r=n&&n.active?n.style.width+n.style.marginLeft:0;return{chartWidth:e.width&&0!==e.width&&e.width0))return s;do{s.push(a=new Date(+n)),t(n,o),e(n)}while(a=t)for(;e(t),!n(t);)t.setTime(t-1)}),(function(e,r){if(e>=e)if(r<0)for(;++r<=0;)for(;t(e,-1),!n(e););else for(;--r>=0;)for(;t(e,1),!n(e););}))},n&&(i.count=function(t,r){return Ye.setTime(+t),Be.setTime(+r),e(Ye),e(Be),Math.floor(n(Ye,Be))},i.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?i.filter(r?function(t){return r(t)%e==0}:function(t){return i.count(0,t)%e==0}):i:null}),i}const qe=1e3,Ge=6e4,Ke=36e5,Xe=864e5,Ze=6048e5,Je=31536e6;function Qe(e){return Ve((function(t){t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)}),(function(e,t){e.setUTCDate(e.getUTCDate()+7*t)}),(function(e,t){return(t-e)/Ze}))}var et=Qe(0),tt=Qe(1),nt=Qe(2),rt=Qe(3),it=Qe(4),ot=Qe(5),at=Qe(6),st=(et.range,tt.range,nt.range,rt.range,it.range,ot.range,at.range,Ve((function(e){e.setUTCHours(0,0,0,0)}),(function(e,t){e.setUTCDate(e.getUTCDate()+t)}),(function(e,t){return(t-e)/Xe}),(function(e){return e.getUTCDate()-1})));const lt=st;function ct(e){return Ve((function(t){t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)}),(function(e,t){e.setDate(e.getDate()+7*t)}),(function(e,t){return(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Ge)/Ze}))}st.range;var ut=ct(0),ht=ct(1),ft=ct(2),dt=ct(3),pt=ct(4),gt=ct(5),yt=ct(6),mt=(ut.range,ht.range,ft.range,dt.range,pt.range,gt.range,yt.range,Ve((e=>e.setHours(0,0,0,0)),((e,t)=>e.setDate(e.getDate()+t)),((e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Ge)/Xe),(e=>e.getDate()-1)));const vt=mt;mt.range;var xt=Ve((function(e){e.setMonth(0,1),e.setHours(0,0,0,0)}),(function(e,t){e.setFullYear(e.getFullYear()+t)}),(function(e,t){return t.getFullYear()-e.getFullYear()}),(function(e){return e.getFullYear()}));xt.every=function(e){return isFinite(e=Math.floor(e))&&e>0?Ve((function(t){t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)}),(function(t,n){t.setFullYear(t.getFullYear()+n*e)})):null};const bt=xt;xt.range;var _t=Ve((function(e){e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),(function(e,t){e.setUTCFullYear(e.getUTCFullYear()+t)}),(function(e,t){return t.getUTCFullYear()-e.getUTCFullYear()}),(function(e){return e.getUTCFullYear()}));_t.every=function(e){return isFinite(e=Math.floor(e))&&e>0?Ve((function(t){t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),(function(t,n){t.setUTCFullYear(t.getUTCFullYear()+n*e)})):null};const wt=_t;function kt(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 Et(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 Mt(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}_t.range;var St,Ot,Ct={"-":"",_:" ",0:"0"},Tt=/^\s*\d+/,At=/^%/,Nt=/[\\^$*+?|[\]().{}]/g;function Pt(e,t,n){var r=e<0?"-":"",i=(r?-e:e)+"",o=i.length;return r+(o[e.toLowerCase(),t])))}function Lt(e,t,n){var r=Tt.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function Ft(e,t,n){var r=Tt.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function $t(e,t,n){var r=Tt.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function zt(e,t,n){var r=Tt.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function It(e,t,n){var r=Tt.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function Wt(e,t,n){var r=Tt.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function Ut(e,t,n){var r=Tt.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function Ht(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 Yt(e,t,n){var r=Tt.exec(t.slice(n,n+1));return r?(e.q=3*r[0]-3,n+r[0].length):-1}function Bt(e,t,n){var r=Tt.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function Vt(e,t,n){var r=Tt.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function qt(e,t,n){var r=Tt.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function Gt(e,t,n){var r=Tt.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function Kt(e,t,n){var r=Tt.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function Xt(e,t,n){var r=Tt.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function Zt(e,t,n){var r=Tt.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function Jt(e,t,n){var r=Tt.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function Qt(e,t,n){var r=At.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function en(e,t,n){var r=Tt.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function tn(e,t,n){var r=Tt.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function nn(e,t){return Pt(e.getDate(),t,2)}function rn(e,t){return Pt(e.getHours(),t,2)}function on(e,t){return Pt(e.getHours()%12||12,t,2)}function an(e,t){return Pt(1+vt.count(bt(e),e),t,3)}function sn(e,t){return Pt(e.getMilliseconds(),t,3)}function ln(e,t){return sn(e,t)+"000"}function cn(e,t){return Pt(e.getMonth()+1,t,2)}function un(e,t){return Pt(e.getMinutes(),t,2)}function hn(e,t){return Pt(e.getSeconds(),t,2)}function fn(e){var t=e.getDay();return 0===t?7:t}function dn(e,t){return Pt(ut.count(bt(e)-1,e),t,2)}function pn(e){var t=e.getDay();return t>=4||0===t?pt(e):pt.ceil(e)}function gn(e,t){return e=pn(e),Pt(pt.count(bt(e),e)+(4===bt(e).getDay()),t,2)}function yn(e){return e.getDay()}function mn(e,t){return Pt(ht.count(bt(e)-1,e),t,2)}function vn(e,t){return Pt(e.getFullYear()%100,t,2)}function xn(e,t){return Pt((e=pn(e)).getFullYear()%100,t,2)}function bn(e,t){return Pt(e.getFullYear()%1e4,t,4)}function wn(e,t){var n=e.getDay();return Pt((e=n>=4||0===n?pt(e):pt.ceil(e)).getFullYear()%1e4,t,4)}function kn(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Pt(t/60|0,"0",2)+Pt(t%60,"0",2)}function En(e,t){return Pt(e.getUTCDate(),t,2)}function Mn(e,t){return Pt(e.getUTCHours(),t,2)}function Sn(e,t){return Pt(e.getUTCHours()%12||12,t,2)}function On(e,t){return Pt(1+lt.count(wt(e),e),t,3)}function Cn(e,t){return Pt(e.getUTCMilliseconds(),t,3)}function Tn(e,t){return Cn(e,t)+"000"}function An(e,t){return Pt(e.getUTCMonth()+1,t,2)}function Nn(e,t){return Pt(e.getUTCMinutes(),t,2)}function Pn(e,t){return Pt(e.getUTCSeconds(),t,2)}function Rn(e){var t=e.getUTCDay();return 0===t?7:t}function Dn(e,t){return Pt(et.count(wt(e)-1,e),t,2)}function jn(e){var t=e.getUTCDay();return t>=4||0===t?it(e):it.ceil(e)}function Ln(e,t){return e=jn(e),Pt(it.count(wt(e),e)+(4===wt(e).getUTCDay()),t,2)}function Fn(e){return e.getUTCDay()}function $n(e,t){return Pt(tt.count(wt(e)-1,e),t,2)}function zn(e,t){return Pt(e.getUTCFullYear()%100,t,2)}function In(e,t){return Pt((e=jn(e)).getUTCFullYear()%100,t,2)}function Wn(e,t){return Pt(e.getUTCFullYear()%1e4,t,4)}function Un(e,t){var n=e.getUTCDay();return Pt((e=n>=4||0===n?it(e):it.ceil(e)).getUTCFullYear()%1e4,t,4)}function Hn(){return"+0000"}function Yn(){return"%"}function Bn(e){return+e}function Vn(e){return Math.floor(+e/1e3)}St=function(e){var t=e.dateTime,n=e.date,r=e.time,i=e.periods,o=e.days,a=e.shortDays,s=e.months,l=e.shortMonths,c=Dt(i),u=jt(i),h=Dt(o),f=jt(o),d=Dt(a),p=jt(a),g=Dt(s),y=jt(s),m=Dt(l),v=jt(l),x={a:function(e){return a[e.getDay()]},A:function(e){return o[e.getDay()]},b:function(e){return l[e.getMonth()]},B:function(e){return s[e.getMonth()]},c:null,d:nn,e:nn,f:ln,g:xn,G:wn,H:rn,I:on,j:an,L:sn,m:cn,M:un,p:function(e){return i[+(e.getHours()>=12)]},q:function(e){return 1+~~(e.getMonth()/3)},Q:Bn,s:Vn,S:hn,u:fn,U:dn,V:gn,w:yn,W:mn,x:null,X:null,y:vn,Y:bn,Z:kn,"%":Yn},b={a:function(e){return a[e.getUTCDay()]},A:function(e){return o[e.getUTCDay()]},b:function(e){return l[e.getUTCMonth()]},B:function(e){return s[e.getUTCMonth()]},c:null,d:En,e:En,f:Tn,g:In,G:Un,H:Mn,I:Sn,j:On,L:Cn,m:An,M:Nn,p:function(e){return i[+(e.getUTCHours()>=12)]},q:function(e){return 1+~~(e.getUTCMonth()/3)},Q:Bn,s:Vn,S:Pn,u:Rn,U:Dn,V:Ln,w:Fn,W:$n,x:null,X:null,y:zn,Y:Wn,Z:Hn,"%":Yn},_={a:function(e,t,n){var r=d.exec(t.slice(n));return r?(e.w=p.get(r[0].toLowerCase()),n+r[0].length):-1},A:function(e,t,n){var r=h.exec(t.slice(n));return r?(e.w=f.get(r[0].toLowerCase()),n+r[0].length):-1},b:function(e,t,n){var r=m.exec(t.slice(n));return r?(e.m=v.get(r[0].toLowerCase()),n+r[0].length):-1},B:function(e,t,n){var r=g.exec(t.slice(n));return r?(e.m=y.get(r[0].toLowerCase()),n+r[0].length):-1},c:function(e,n,r){return E(e,t,n,r)},d:Vt,e:Vt,f:Jt,g:Ut,G:Wt,H:Gt,I:Gt,j:qt,L:Zt,m:Bt,M:Kt,p:function(e,t,n){var r=c.exec(t.slice(n));return r?(e.p=u.get(r[0].toLowerCase()),n+r[0].length):-1},q:Yt,Q:en,s:tn,S:Xt,u:Ft,U:$t,V:zt,w:Lt,W:It,x:function(e,t,r){return E(e,n,t,r)},X:function(e,t,n){return E(e,r,t,n)},y:Ut,Y:Wt,Z:Ht,"%":Qt};function w(e,t){return function(n){var r,i,o,a=[],s=-1,l=0,c=e.length;for(n instanceof Date||(n=new Date(+n));++s53)return null;"w"in o||(o.w=1),"Z"in o?(i=(r=Et(Mt(o.y,0,1))).getUTCDay(),r=i>4||0===i?tt.ceil(r):tt(r),r=lt.offset(r,7*(o.V-1)),o.y=r.getUTCFullYear(),o.m=r.getUTCMonth(),o.d=r.getUTCDate()+(o.w+6)%7):(i=(r=kt(Mt(o.y,0,1))).getDay(),r=i>4||0===i?ht.ceil(r):ht(r),r=vt.offset(r,7*(o.V-1)),o.y=r.getFullYear(),o.m=r.getMonth(),o.d=r.getDate()+(o.w+6)%7)}else("W"in o||"U"in o)&&("w"in o||(o.w="u"in o?o.u%7:"W"in o?1:0),i="Z"in o?Et(Mt(o.y,0,1)).getUTCDay():kt(Mt(o.y,0,1)).getDay(),o.m=0,o.d="W"in o?(o.w+6)%7+7*o.W-(i+5)%7:o.w+7*o.U-(i+6)%7);return"Z"in o?(o.H+=o.Z/100|0,o.M+=o.Z%100,Et(o)):kt(o)}}function E(e,t,n,r){for(var i,o,a=0,s=t.length,l=n.length;a=l)return-1;if(37===(i=t.charCodeAt(a++))){if(i=t.charAt(a++),!(o=_[i in Ct?t.charAt(a++):i])||(r=o(e,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}return x.x=w(n,x),x.X=w(r,x),x.c=w(t,x),b.x=w(n,b),b.X=w(r,b),b.c=w(t,b),{format:function(e){var t=w(e+="",x);return t.toString=function(){return e},t},parse:function(e){var t=k(e+="",!1);return t.toString=function(){return e},t},utcFormat:function(e){var t=w(e+="",b);return t.toString=function(){return e},t},utcParse:function(e){var t=k(e+="",!0);return t.toString=function(){return e},t}}}({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"]}),Ot=St.format,St.parse,St.utcFormat,St.utcParse;const qn=(e,t)=>"light"===t||function(e,t){const n=$e(e),r=$e("#1e1e1e");var i=ze(n[0],n[1],n[2]),o=ze(r[0],r[1],r[2]);return(Math.max(i,o)+.05)/(Math.min(i,o)+.05)}(e)>3?e:"#ccc",Gn=(e,t,n)=>{const{axis:r,ticks:i,axisLabel:o,tickLabels:a}=e;return{scale:t,hideAxisLine:!e.active,hideTicks:!e.active,stroke:qn(r.stroke,n),strokeWidth:r.strokeWidth,tickStroke:qn(r.stroke,n),tickLength:i.size,hideZero:!e.showZero,label:e.label?e.label:"",labelOffset:o.padding,numTicks:e.tickCount,tickValues:"time"===e.scale?e.tickValues?.map((e=>{var t=new Date(e);return t.setDate(t.getDate()+1),t})):e.tickValues,labelProps:{fill:qn(o.fill,n),fontSize:o.fontSize,textAnchor:o.textAnchor,dy:o.dy,dx:o.dx,fontFamily:o.fontFamily,verticalAnchor:o.verticalAnchor,angle:o.angle,width:o.maxWidth},tickFormat:t=>((e,t)=>{if(e.customTickFormat&&"function"==typeof e.customTickFormat)return e.customTickFormat(t);if("time"===e.scale){const n=Ot(e.dateFormat);return e.tickUnit?"end"===e.tickUnitPosition?`${n(t)}${e.tickUnit}`:`${e.tickUnit}${n(t)}`:n(t)}return e.abbreviateTicks?e.tickUnit?"end"===e.tickUnitPosition?`${Fe(t,e.abbreviateTicksDecimals)}${e.tickUnit}`:`${e.tickUnit}${Fe(t,e.abbreviateTicksDecimals)}`:Fe(t,e.abbreviateTicksDecimals):e.ticksToLocaleString?e.tickUnit?"end"===e.tickUnitPosition?`${t.toLocaleString()}${e.tickUnit}`:`${e.tickUnit}${t.toLocaleString()}`:t.toLocaleString():e.tickUnit?"end"===e.tickUnitPosition?`${t}${e.tickUnit}`:`${e.tickUnit}${t}`:`${t}`})(e,t),tickLabelProps:()=>({fill:qn(a.fill,n),fontSize:a.fontSize,textAnchor:a.textAnchor,dy:a.dy,dx:a.dx,fontFamily:a.fontFamily,verticalAnchor:a.verticalAnchor,angle:a.angle,width:a.maxWidth})}},Kn=(e,t,n,r)=>{const{stroke:i,strokeWidth:o,strokeOpacity:a,strokeDasharray:s}=e.grid;return{scale:t,width:n,height:r,stroke:i,strokeWidth:o,strokeOpacity:a,strokeDasharray:s,numTicks:e.tickCount,tickValues:"time"===e.scale?e.tickValues?.map((e=>{var t=new Date(e);return t.setDate(t.getDate()+1),t})):e.tickValues}},Xn=e=>({angle:e.labelAngle,textAnchor:e.textAnchor,style:{fontSize:e.fontSize,fontWeight:e.fontWeight,fontFamily:e.fontFamily}}),Zn=(e,t,n,r)=>{const i=n.absoluteValue?Math.abs(e):Number(e);if(n.customLabelFormat)return n.customLabelFormat(i,t);const o=n.truncateDecimal?Number(Number(i).toFixed(n.toFixedDecimal)):Number(i).toFixed(n.toFixedDecimal),a=n.truncateDecimal?Number(i.toFixed(n.toFixedDecimal)).toLocaleString("en-US"):i.toLocaleString("en-US",{minimumFractionDigits:n.toFixedDecimal,maximumFractionDigits:n.toFixedDecimal}),s=Fe(i,n.toFixedDecimal);return null===r||Number(o)>=r?n.labelUnit?"end"===n.labelUnitPosition?n.abbreviateValue?`${s}${n.labelUnit}`:n.toLocaleString?`${a}${n.labelUnit}`:`${o}${n.labelUnit}`:n.abbreviateValue?`${n.labelUnit}${s}`:n.toLocaleString?`${n.labelUnit}${a}`:`${n.labelUnit}${o}`:n.abbreviateValue?`${s}`:n.toLocaleString?`${a}`:`${o}`:""},Jn=(e,t,n,r,i)=>"horizontal"===r?((e,t,n,r)=>{const{x:i,y:o,width:a,height:s,value:l}=e,{labelPositionDX:c,labelPositionDY:u,labelPositionBar:h}=t;return l{const{x:i,y:o,width:a,height:s,value:l}=e,{labelPositionDX:c,labelPositionDY:u,labelPositionBar:h}=t;return Math.abs(l){const r=n.replace(/\.toLowerCase\(\)$/,""),i=t[r];return i?i.toString().toLowerCase():""})).replace(/{{\s*(\w+)\s*}}/g,((e,n)=>{const r=t[n];return r?r.toString():""}));return n}}const er=(e,t)=>{const n=Ot(t.dateFormat),r=e.x instanceof Date?n(e.x):e.x,i=e.category instanceof Date?n(e.category):e.category;return"categoryValue"===t.headerValue?i:r},tr=(e,t)=>{const n=Ot(t.dateFormat),r=e.x instanceof Date?n(e.x):e.x,i=e.category instanceof Date?n(e.category):e.category;let o=t.absoluteValue?Math.abs(e.y):Number(e.y);if(t.customFormat)return t.customFormat(o);if(t.toFixedDecimal&&(o=Number(Number(o).toFixed(t.toFixedDecimal))),t.abbreviateValue&&(o=Fe(o,t.toFixedDecimal)),t.toLocaleString&&(o=o.toLocaleString()),t.format&&t.format.length>0){const n=function(e,t){return e.replace(/{{(.*?)}}/g,((e,n)=>{let r,i,o;return n.indexOf(".isBold()")>-1&&(r=!0,n=n.replace(".isBold()","")),n.indexOf(".isColor()")>-1&&(i=!0,n=n.replace(".isColor()","")),n.indexOf(".toLowerCase()")>-1&&(o=!0,n=n.replace(".toLowerCase()","")),i||r||o?`{{${n}}}`:`{{${n}}}`}))}(t.format.replace(/%1\$s/g,"{{column}}").replace(/%2\$s/g,"{{value}}").replace(/%3\$s/g,"{{row}}"),e.color);return Qn(n,e.color)({column:i,value:o,row:r})}return Qn("{{row}}: {{value}}",e.color)({row:r,value:o})};var nr=n(4184),rr=n.n(nr),ir=n(5697),or=n.n(ir),ar=["top","left","transform","className","children","innerRef"];function sr(){return sr=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,ar);return o().createElement("g",sr({ref:c,className:rr()("visx-group",s),transform:a||"translate("+i+", "+n+")"},u),l)}lr.propTypes={top:or().number,left:or().number,transform:or().string,className:or().string,children:or().node,innerRef:or().oneOfType([or().string,or().func,or().object])};var cr=["className","innerRef"];function ur(){return ur=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,cr);return o().createElement("rect",ur({ref:n,className:rr()("visx-bar",t)},r))}function fr(e){if("bandwidth"in e)return e.bandwidth();var t=e.range(),n=e.domain();return Math.abs(t[t.length-1]-t[0])/n.length}var dr=["data","className","top","left","x","y0","y0Scale","y1Scale","xScale","color","keys","width","children"];function pr(){return pr=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,dr),y=fr(u),m=t.map((function(e,t){return{index:t,y0:c(l(e))||0,bars:d.map((function(t,n){var r=e[t];return{index:n,key:t,value:r,height:y,x:s(r)||0,y:u(t)||0,color:f(t,n),width:h(r)||0}}))}}));return p?o().createElement(o().Fragment,null,p(m)):o().createElement(lr,{className:rr()("visx-bar-group-horizontal",n),top:r,left:i},m.map((function(e){return o().createElement(lr,{key:"bar-group-"+e.index+"-"+e.y0,top:e.y0},e.bars.map((function(t){return o().createElement(hr,pr({key:"bar-group-bar-"+e.index+"-"+t.index+"-"+t.value+"-"+t.key,x:t.x,y:t.y,width:t.width,height:t.height,fill:t.color},g))})))})))}var yr=n(3282),mr=function(){function e(e){var t=e.x,n=void 0===t?0:t,r=e.y,i=void 0===r?0:r;this.x=0,this.y=0,this.x=n,this.y=i}var t=e.prototype;return t.value=function(){return{x:this.x,y:this.y}},t.toArray=function(){return[this.x,this.y]},e}();function vr(e,t){var n=e;return"ticks"in n?n.ticks(t):n.domain().filter((function(e,n,r){return null==t||r.length<=t||n%Math.round((r.length-1)/t)==0}))}function xr(e){if(("function"==typeof e||"object"==typeof e&&e)&&"valueOf"in e){var t=e.valueOf();if("number"==typeof t)return t}return e}function br(e){return"bandwidth"in e?e.bandwidth():0}var _r=["top","left","scale","height","stroke","strokeWidth","strokeDasharray","className","numTicks","lineStyle","offset","tickValues","children"];function wr(){return wr=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,_r),_=null!=v?v:vr(a,g),w=(null!=m?m:0)+br(a)/2,k=_.map((function(e,t){var n,r=(null!=(n=xr(a(e)))?n:0)+w;return{index:t,from:new mr({x:r,y:0}),to:new mr({x:r,y:s})}}));return o().createElement(lr,{className:rr()("visx-columns",d),top:n,left:i},x?x({lines:k}):k.map((function(e){var t=e.from,n=e.to,r=e.index;return o().createElement(yr.Z,wr({key:"column-line-"+r,from:t,to:n,stroke:c,strokeWidth:h,strokeDasharray:f,style:y},b))})))}kr.propTypes={tickValues:or().array,height:or().number.isRequired};var Er=["top","left","scale","width","stroke","strokeWidth","strokeDasharray","className","children","numTicks","lineStyle","offset","tickValues"];function Mr(){return Mr=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,Er),_=null!=x?x:vr(a,y),w=(null!=v?v:0)+br(a)/2,k=_.map((function(e,t){var n,r=(null!=(n=xr(a(e)))?n:0)+w;return{index:t,from:new mr({x:0,y:r}),to:new mr({x:s,y:r})}}));return o().createElement(lr,{className:rr()("visx-rows",d),top:n,left:i},p?p({lines:k}):k.map((function(e){var t=e.from,n=e.to,r=e.index;return o().createElement(yr.Z,Mr({key:"row-line-"+r,from:t,to:n,stroke:c,strokeWidth:h,strokeDasharray:f,style:m},b))})))}Sr.propTypes={tickValues:or().array,width:or().number.isRequired};var Or=["from","to","fill","className","innerRef"];function Cr(){return Cr=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,Or),h=n.x===i.x||n.y===i.y;return o().createElement("line",Cr({ref:c,className:rr()("visx-line",l),x1:n.x,y1:n.y,x2:i.x,y2:i.y,fill:s,shapeRendering:h?"crispEdges":"auto"},u))}var Ar=n(6488),Nr=n.n(Ar),Pr=n(8306),Rr="__react_svg_text_measurement_id";const Dr=n.n(Pr)()((function(e,t){try{var n=document.getElementById(Rr);if(!n){var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("aria-hidden","true"),r.style.width="0",r.style.height="0",r.style.position="absolute",r.style.top="-100%",r.style.left="-100%",(n=document.createElementNS("http://www.w3.org/2000/svg","text")).setAttribute("id",Rr),r.appendChild(n),document.body.appendChild(r)}return Object.assign(n.style,t),n.textContent=e,n.getComputedTextLength()}catch(e){return null}}),(function(e,t){return e+"_"+JSON.stringify(t)}));var jr=["verticalAnchor","scaleToFit","angle","width","lineHeight","capHeight","children","style"];function Lr(e){return"number"==typeof e}function Fr(e){return"number"==typeof e&&Number.isFinite(e)||"string"==typeof e}var $r=["dx","dy","textAnchor","innerRef","innerTextRef","verticalAnchor","angle","lineHeight","scaleToFit","capHeight","width"];function zr(){return zr=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,$r)),p=d.x,g=void 0===p?0:p,y=d.fontSize,m=function(e){var t=e.verticalAnchor,n=void 0===t?"end":t,r=e.scaleToFit,o=void 0!==r&&r,a=e.angle,s=e.width,l=e.lineHeight,c=void 0===l?"1em":l,u=e.capHeight,h=void 0===u?"0.71em":u,f=e.children,d=e.style,p=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r=0||(i[n]=e[n]);return i}(e,jr),g=p.x,y=void 0===g?0:g,m=p.y,v=void 0===m?0:m,x=!Fr(y)||!Fr(v),b=(0,i.useMemo)((function(){return{wordsWithWidth:(null==f?[]:f.toString().split(/(?:(?!\u00A0+)\s+)/)).map((function(e){return{word:e,wordWidth:Dr(e,d)||0}})),spaceWidth:Dr(" ",d)||0}}),[f,d]),_=b.wordsWithWidth,w=b.spaceWidth,k=(0,i.useMemo)((function(){return x?[]:s||o?_.reduce((function(e,t){var n=t.word,r=t.wordWidth,i=e[e.length-1];if(i&&(null==s||o||(i.width||0)+r+w0){var t=k[0].width||1,n="shrink-only"===o?Math.min(s/t,1):s/t,r=n,i=y-n*y,l=v-r*v;e.push("matrix("+n+", 0, 0, "+r+", "+i+", "+l+")")}return a&&e.push("rotate("+a+", "+y+", "+v+")"),e.length>0?e.join(" "):""}),[x,y,v,s,o,k,a]);return{wordsByLines:k,startDy:E,transform:M}}(e),v=m.wordsByLines,x=m.startDy,b=m.transform;return o().createElement("svg",{ref:c,x:n,y:a,fontSize:y,style:Ir},v.length>0?o().createElement("text",zr({ref:u,transform:b},d,{textAnchor:l}),v.map((function(e,t){return o().createElement("tspan",{key:t,x:g,dy:0===t?x:f},e.words.join(" "))}))):null)}const Ur={top:"top",left:"left",right:"right",bottom:"bottom"};function Hr(){return Hr=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,Jr),C=null!=_?_:function(e){return"tickFormat"in e?e.tickFormat():Gr}(b),T=m===Ur.left,A=m===Ur.top,N=A||m===Ur.bottom,P=function(e,t){void 0===t&&(t="center");var n=e;if("start"!==t&&"bandwidth"in n){var r=n.bandwidth();return"center"===t&&(r/=2),n.round()&&(r=Math.round(r)),function(e){var t=n(e);return"number"==typeof t?t+r:t}}return e}(b),R=T||A?-1:1,D=b.range(),j=(void 0===(t=x)&&(t=Zr),"number"==typeof t?{start:t,end:t}:Xr({start:Zr,end:Zr},t)),L=Kr({x:Number(D[0])+.5-j.start,y:0},N),F=Kr({x:Number(D[D.length-1])+.5+j.end,y:0},N),$=(null!=E?E:vr(b,g)).filter((function(e){return!h||0!==e&&"0"!==e})).map((function(e,t){return{value:e,index:t}})),z=$.map((function(e){var t=e.value,n=e.index,r=xr(P(t));return{value:t,index:n,from:Kr({x:r,y:0},N),to:Kr({x:r,y:k*R},N),formattedValue:C(t,n,$)}}));return o().createElement(lr,{className:rr()("visx-axis",i),top:S,left:d},r(Qr({},O,{axisFromPoint:L,axisToPoint:F,hideAxisLine:s,hideTicks:c,hideZero:h,horizontal:N,numTicks:g,orientation:m,rangePadding:x,scale:b,tickFormat:C,tickLength:k,tickPosition:P,tickSign:R,ticks:z})))}var ti=["axisClassName","labelOffset","tickLabelProps","tickLength"];function ni(){return ni=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,ti);return o().createElement(ei,ni({axisClassName:rr()("visx-axis-left",t),labelOffset:r,orientation:Ur.left,tickLabelProps:a,tickLength:l},c))}var oi=["axisClassName","labelOffset","tickLabelProps","tickLength"];function ai(){return ai=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,oi);return o().createElement(ei,ai({axisClassName:rr()("visx-axis-bottom",t),labelOffset:r,orientation:Ur.bottom,tickLabelProps:a,tickLength:l},c))}function ci(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e)}return this}const ui=Symbol("implicit");function hi(){var e=new Map,t=[],n=[],r=ui;function i(i){var o=i+"",a=e.get(o);if(!a){if(r!==ui)return r;e.set(o,a=t.push(i))}return n[(a-1)%n.length]}return i.domain=function(n){if(!arguments.length)return t.slice();t=[],e=new Map;for(const r of n){const n=r+"";e.has(n)||e.set(n,t.push(r))}return i},i.range=function(e){return arguments.length?(n=Array.from(e),i):n.slice()},i.unknown=function(e){return arguments.length?(r=e,i):r},i.copy=function(){return hi(t,n).unknown(r)},ci.apply(i,arguments),i}function fi(){var e,t,n=hi().unknown(void 0),r=n.domain,i=n.range,o=0,a=1,s=!1,l=0,c=0,u=.5;function h(){var n=r().length,h=a>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?ji(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?ji(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=Ei.exec(e))?new $i(t[1],t[2],t[3],1):(t=Mi.exec(e))?new $i(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=Si.exec(e))?ji(t[1],t[2],t[3],t[4]):(t=Oi.exec(e))?ji(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=Ci.exec(e))?Ui(t[1],t[2]/100,t[3]/100,1):(t=Ti.exec(e))?Ui(t[1],t[2]/100,t[3]/100,t[4]):Ai.hasOwnProperty(e)?Di(Ai[e]):"transparent"===e?new $i(NaN,NaN,NaN,0):null}function Di(e){return new $i(e>>16&255,e>>8&255,255&e,1)}function ji(e,t,n,r){return r<=0&&(e=t=n=NaN),new $i(e,t,n,r)}function Li(e){return e instanceof mi||(e=Ri(e)),e?new $i((e=e.rgb()).r,e.g,e.b,e.opacity):new $i}function Fi(e,t,n,r){return 1===arguments.length?Li(e):new $i(e,t,n,null==r?1:r)}function $i(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function zi(){return"#"+Wi(this.r)+Wi(this.g)+Wi(this.b)}function Ii(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===e?")":", "+e+")")}function Wi(e){return((e=Math.max(0,Math.min(255,Math.round(e)||0)))<16?"0":"")+e.toString(16)}function Ui(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new Bi(e,t,n,r)}function Hi(e){if(e instanceof Bi)return new Bi(e.h,e.s,e.l,e.opacity);if(e instanceof mi||(e=Ri(e)),!e)return new Bi;if(e instanceof Bi)return e;var t=(e=e.rgb()).r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),o=Math.max(t,n,r),a=NaN,s=o-i,l=(o+i)/2;return s?(a=t===o?(n-r)/s+6*(n0&&l<1?0:a,new Bi(a,s,l,e.opacity)}function Yi(e,t,n,r){return 1===arguments.length?Hi(e):new Bi(e,t,n,null==r?1:r)}function Bi(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function Vi(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}gi(mi,Ri,{copy:function(e){return Object.assign(new this.constructor,this,e)},displayable:function(){return this.rgb().displayable()},hex:Ni,formatHex:Ni,formatHsl:function(){return Hi(this).formatHsl()},formatRgb:Pi,toString:Pi}),gi($i,Fi,yi(mi,{brighter:function(e){return e=null==e?xi:Math.pow(xi,e),new $i(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=null==e?vi:Math.pow(vi,e),new $i(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},displayable:function(){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:zi,formatHex:zi,formatRgb:Ii,toString:Ii})),gi(Bi,Yi,yi(mi,{brighter:function(e){return e=null==e?xi:Math.pow(xi,e),new Bi(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?vi:Math.pow(vi,e),new Bi(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+360*(this.h<0),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 $i(Vi(e>=240?e-240:e+120,i,r),Vi(e,i,r),Vi(e<120?e+240:e-120,i,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===e?")":", "+e+")")}}));var qi=Math.PI/180,Gi=180/Math.PI,Ki=.96422,Xi=1,Zi=.82521,Ji=4/29,Qi=6/29,eo=3*Qi*Qi,to=.008856451679035631;function no(e){if(e instanceof io)return new io(e.l,e.a,e.b,e.opacity);if(e instanceof uo)return ho(e);e instanceof $i||(e=Li(e));var t,n,r=lo(e.r),i=lo(e.g),o=lo(e.b),a=oo((.2225045*r+.7168786*i+.0606169*o)/Xi);return r===i&&i===o?t=n=a:(t=oo((.4360747*r+.3850649*i+.1430804*o)/Ki),n=oo((.0139322*r+.0971045*i+.7141733*o)/Zi)),new io(116*a-16,500*(t-a),200*(a-n),e.opacity)}function ro(e,t,n,r){return 1===arguments.length?no(e):new io(e,t,n,null==r?1:r)}function io(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}function oo(e){return e>to?Math.pow(e,1/3):e/eo+Ji}function ao(e){return e>Qi?e*e*e:eo*(e-Ji)}function so(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function lo(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function co(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof uo)return new uo(e.h,e.c,e.l,e.opacity);if(e instanceof io||(e=no(e)),0===e.a&&0===e.b)return new uo(NaN,0180||n<-180?n-360*Math.round(n/360):n):fo(isNaN(e)?t:e)}function yo(e,t){var n=t-e;return n?po(e,n):fo(isNaN(e)?t:e)}function mo(e){return function(t,n){var r=e((t=co(t)).h,(n=co(n)).h),i=yo(t.c,n.c),o=yo(t.l,n.l),a=yo(t.opacity,n.opacity);return function(e){return t.h=r(e),t.c=i(e),t.l=o(e),t.opacity=a(e),t+""}}}gi(io,ro,yi(mi,{brighter:function(e){return new io(this.l+18*(null==e?1:e),this.a,this.b,this.opacity)},darker:function(e){return new io(this.l-18*(null==e?1:e),this.a,this.b,this.opacity)},rgb:function(){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 new $i(so(3.1338561*(t=Ki*ao(t))-1.6168667*(e=Xi*ao(e))-.4906146*(n=Zi*ao(n))),so(-.9787684*t+1.9161415*e+.033454*n),so(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}})),gi(uo,co,yi(mi,{brighter:function(e){return new uo(this.h,this.c,this.l+18*(null==e?1:e),this.opacity)},darker:function(e){return new uo(this.h,this.c,this.l-18*(null==e?1:e),this.opacity)},rgb:function(){return ho(this).rgb()}}));const vo=mo(go);var xo=mo(yo);function bo(e){return function(t,n){var r=e((t=Yi(t)).h,(n=Yi(n)).h),i=yo(t.s,n.s),o=yo(t.l,n.l),a=yo(t.opacity,n.opacity);return function(e){return t.h=r(e),t.s=i(e),t.l=o(e),t.opacity=a(e),t+""}}}const _o=bo(go);var wo=bo(yo),ko=-.14861,Eo=1.78277,Mo=-.29227,So=-.90649,Oo=1.97294,Co=Oo*So,To=Oo*Eo,Ao=Eo*Mo-So*ko;function No(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof Po)return new Po(e.h,e.s,e.l,e.opacity);e instanceof $i||(e=Li(e));var t=e.r/255,n=e.g/255,r=e.b/255,i=(Ao*r+Co*t-To*n)/(Ao+Co-To),o=r-i,a=(Oo*(n-i)-Mo*o)/So,s=Math.sqrt(a*a+o*o)/(Oo*i*(1-i)),l=s?Math.atan2(a,o)*Gi-120:NaN;return new Po(l<0?l+360:l,s,i,e.opacity)}(e):new Po(e,t,n,null==r?1:r)}function Po(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function Ro(e){return function t(n){function r(t,r){var i=e((t=No(t)).h,(r=No(r)).h),o=yo(t.s,r.s),a=yo(t.l,r.l),s=yo(t.opacity,r.opacity);return function(e){return t.h=i(e),t.s=o(e),t.l=a(Math.pow(e,n)),t.opacity=s(e),t+""}}return n=+n,r.gamma=t,r}(1)}gi(Po,No,yi(mi,{brighter:function(e){return e=null==e?xi:Math.pow(xi,e),new Po(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?vi:Math.pow(vi,e),new Po(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=isNaN(this.h)?0:(this.h+120)*qi,t=+this.l,n=isNaN(this.s)?0:this.s*t*(1-t),r=Math.cos(e),i=Math.sin(e);return new $i(255*(t+n*(ko*r+Eo*i)),255*(t+n*(Mo*r+So*i)),255*(t+n*(Oo*r)),this.opacity)}}));const Do=Ro(go);var jo=Ro(yo);function Lo(e,t,n,r,i){var o=e*e,a=o*e;return((1-3*e+3*o-a)*t+(4-6*o+3*a)*n+(1+3*e+3*o-3*a)*r+a*i)/6}const Fo=function e(t){var n=function(e){return 1==(e=+e)?yo:function(t,n){return n-t?function(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)}}(t,n,e):fo(isNaN(t)?n:t)}}(t);function r(e,t){var r=n((e=Fi(e)).r,(t=Fi(t)).r),i=n(e.g,t.g),o=n(e.b,t.b),a=yo(e.opacity,t.opacity);return function(t){return e.r=r(t),e.g=i(t),e.b=o(t),e.opacity=a(t),e+""}}return r.gamma=e,r}(1);function $o(e){return function(t){var n,r,i=t.length,o=new Array(i),a=new Array(i),s=new Array(i);for(n=0;n=1?(n=1,t-1):Math.floor(n*t),i=e[r],o=e[r+1],a=r>0?e[r-1]:2*i-o,s=r=0?(o>=ca?10:o>=ua?5:o>=ha?2:1)*Math.pow(10,i):-Math.pow(10,-i)/(o>=ca?10:o>=ua?5:o>=ha?2:1)}function da(e,t){return et?1:e>=t?0:NaN}function pa(e){let t=e,n=e;function r(e,t,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r>>1;n(e[o],t)<0?r=o+1:i=o}return r}return 1===e.length&&(t=(t,n)=>e(t)-n,n=function(e){return(t,n)=>da(e(t),n)}(e)),{left:r,center:function(e,n,i,o){null==i&&(i=0),null==o&&(o=e.length);const a=r(e,n,i,o-1);return a>i&&t(e[a-1],n)>-t(e[a],n)?a-1:a},right:function(e,t,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r>>1;n(e[o],t)>0?i=o:r=o+1}return r}}}const ga=pa(da),ya=ga.right,ma=(ga.left,pa((function(e){return null===e?NaN:+e})).center,ya);function va(e,t){var n,r=t?t.length:0,i=e?Math.min(r,e.length):0,o=new Array(i),a=new Array(r);for(n=0;no&&(i=t.slice(o,i),s[a]?s[a]+=i:s[++a]=i),(n=n[0])===(r=r[0])?s[a]?s[a]+=r:s[++a]=r:(s[++a]=null,l.push({i:a,x:ba(n,r)})),o=ka.lastIndex;return ot&&(n=e,e=t,t=n),function(n){return Math.max(e,Math.min(t,n))}}(a[0],a[e-1])),r=e>2?Pa:Na,i=o=null,h}function h(t){return null==t||isNaN(t=+t)?n:(i||(i=r(a.map(e),s,l)))(e(c(t)))}return h.invert=function(n){return c(t((o||(o=r(s,a.map(e),ba)))(n)))},h.domain=function(e){return arguments.length?(a=Array.from(e,Oa),u()):a.slice()},h.range=function(e){return arguments.length?(s=Array.from(e),u()):s.slice()},h.rangeRound=function(e){return s=Array.from(e),l=ra,u()},h.clamp=function(e){return arguments.length?(c=!!e||Ta,u()):c!==Ta},h.interpolate=function(e){return arguments.length?(l=e,u()):l},h.unknown=function(e){return arguments.length?(n=e,h):n},function(n,r){return e=n,t=r,u()}}()(Ta,Ta)}var ja,La=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Fa(e){if(!(t=La.exec(e)))throw new Error("invalid format: "+e);var t;return new $a({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]})}function $a(e){this.fill=void 0===e.fill?" ":e.fill+"",this.align=void 0===e.align?">":e.align+"",this.sign=void 0===e.sign?"-":e.sign+"",this.symbol=void 0===e.symbol?"":e.symbol+"",this.zero=!!e.zero,this.width=void 0===e.width?void 0:+e.width,this.comma=!!e.comma,this.precision=void 0===e.precision?void 0:+e.precision,this.trim=!!e.trim,this.type=void 0===e.type?"":e.type+""}function za(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 Ia(e){return(e=za(Math.abs(e)))?e[1]:NaN}function Wa(e,t){var n=za(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")}Fa.prototype=$a.prototype,$a.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};const Ua={"%":(e,t)=>(100*e).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:function(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)},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)=>Wa(100*e,t),r:Wa,s:function(e,t){var n=za(e,t);if(!n)return e+"";var r=n[0],i=n[1],o=i-(ja=3*Math.max(-8,Math.min(8,Math.floor(i/3))))+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+za(e,Math.max(0,t+o-1))[0]},X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function Ha(e){return e}var Ya,Ba,Va,qa=Array.prototype.map,Ga=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function Ka(e){var t=e.domain;return e.ticks=function(e){var n=t();return function(e,t,n){var r,i,o,a,s=-1;if(n=+n,(e=+e)==(t=+t)&&n>0)return[e];if((r=t0){let n=Math.round(e/a),r=Math.round(t/a);for(n*at&&--r,o=new Array(i=r-n+1);++st&&--r,o=new Array(i=r-n+1);++s=ca?i*=10:o>=ua?i*=5:o>=ha&&(i*=2),t0;){if((i=fa(l,c,n))===r)return o[a]=l,o[s]=c,t(o);if(i>0)l=Math.floor(l/i)*i,c=Math.ceil(c/i)*i;else{if(!(i<0))break;l=Math.ceil(l*i)/i,c=Math.floor(c*i)/i}r=i}return e},e}function Xa(){var e=Da();return e.copy=function(){return Ra(e,Xa())},ci.apply(e,arguments),Ka(e)}Ya=function(e){var t,n,r=void 0===e.grouping||void 0===e.thousands?Ha:(t=qa.call(e.grouping,Number),n=e.thousands+"",function(e,r){for(var i=e.length,o=[],a=0,s=t[0],l=0;i>0&&s>0&&(l+s+1>r&&(s=Math.max(1,r-l)),o.push(e.substring(i-=s,i+s)),!((l+=s+1)>r));)s=t[a=(a+1)%t.length];return o.reverse().join(n)}),i=void 0===e.currency?"":e.currency[0]+"",o=void 0===e.currency?"":e.currency[1]+"",a=void 0===e.decimal?".":e.decimal+"",s=void 0===e.numerals?Ha:function(e){return function(t){return t.replace(/[0-9]/g,(function(t){return e[+t]}))}}(qa.call(e.numerals,String)),l=void 0===e.percent?"%":e.percent+"",c=void 0===e.minus?"−":e.minus+"",u=void 0===e.nan?"NaN":e.nan+"";function h(e){var t=(e=Fa(e)).fill,n=e.align,h=e.sign,f=e.symbol,d=e.zero,p=e.width,g=e.comma,y=e.precision,m=e.trim,v=e.type;"n"===v?(g=!0,v="g"):Ua[v]||(void 0===y&&(y=12),m=!0,v="g"),(d||"0"===t&&"="===n)&&(d=!0,t="0",n="=");var x="$"===f?i:"#"===f&&/[boxX]/.test(v)?"0"+v.toLowerCase():"",b="$"===f?o:/[%p]/.test(v)?l:"",_=Ua[v],w=/[defgprs%]/.test(v);function k(e){var i,o,l,f=x,k=b;if("c"===v)k=_(e)+k,e="";else{var E=(e=+e)<0||1/e<0;if(e=isNaN(e)?u:_(Math.abs(e),y),m&&(e=function(e){e:for(var t,n=e.length,r=1,i=-1;r0&&(i=0)}return i>0?e.slice(0,i)+e.slice(t+1):e}(e)),E&&0==+e&&"+"!==h&&(E=!1),f=(E?"("===h?h:c:"-"===h||"("===h?"":h)+f,k=("s"===v?Ga[8+ja/3]:"")+k+(E&&"("===h?")":""),w)for(i=-1,o=e.length;++i(l=e.charCodeAt(i))||l>57){k=(46===l?a+e.slice(i+1):e.slice(i))+k,e=e.slice(0,i);break}}g&&!d&&(e=r(e,1/0));var M=f.length+e.length+k.length,S=M>1)+f+e+k+S.slice(M);break;default:e=S+f+e+k}return s(e)}return y=void 0===y?6:/[gprs]/.test(v)?Math.max(1,Math.min(21,y)):Math.max(0,Math.min(20,y)),k.toString=function(){return e+""},k}return{format:h,formatPrefix:function(e,t){var n=h(((e=Fa(e)).type="f",e)),r=3*Math.max(-8,Math.min(8,Math.floor(Ia(t)/3))),i=Math.pow(10,-r),o=Ga[8+r/3];return function(e){return n(i*e)+o}}}}({thousands:",",grouping:[3],currency:["$",""]}),Ba=Ya.format,Va=Ya.formatPrefix;var Za=aa("domain","range","reverse","clamp","interpolate","nice","round","zero");function Ja(e){return Za(Xa(),e)}var Qa=aa("domain","range","reverse","unknown");function es(e){return Qa(hi(),e)}var ts=["tooltipOpen"];function ns(){return ns=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(t,ts);return ns({},e(n),{tooltipOpen:!0})}:{tooltipOpen:!0,tooltipLeft:e.tooltipLeft,tooltipTop:e.tooltipTop,tooltipData:e.tooltipData})}),[r]),a=(0,i.useCallback)((function(){return r({tooltipOpen:!1,tooltipLeft:void 0,tooltipTop:void 0,tooltipData:void 0})}),[r]);return{tooltipOpen:n.tooltipOpen,tooltipLeft:n.tooltipLeft,tooltipTop:n.tooltipTop,tooltipData:n.tooltipData,updateTooltip:r,showTooltip:o,hideTooltip:a}}function is(){return is=Object.assign?Object.assign.bind():function(e){for(var t=1;t0?{x:e.changedTouches[0].clientX,y:e.changedTouches[0].clientY}:is({},os);if(function(e){return!!e&&"clientX"in e}(e))return{x:e.clientX,y:e.clientY};var t=null==e?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}:is({},os)}(t),i=(n=e)&&(n instanceof SVGElement||"ownerSVGElement"in n)?e.ownerSVGElement:e,o=function(e){return!!e&&"getScreenCTM"in e}(i)?i.getScreenCTM():null;if(function(e){return!!e&&"createSVGPoint"in e}(i)&&o){var a=i.createSVGPoint();return a.x=r.x,a.y=r.y,a=a.matrixTransform(o.inverse()),new mr({x:a.x,y:a.y})}var s=e.getBoundingClientRect();return new mr({x:r.x-s.left-e.clientLeft,y:r.y-s.top-e.clientTop})}function ss(e,t){if((n=e)&&n instanceof Element&&t)return as(e,t);var n;if(function(e){return!!e&&(e instanceof Event||"nativeEvent"in e&&e.nativeEvent instanceof Event)}(e)){var r=e,i=r.target;if(i)return as(i,r)}return null}function ls(e,t){return null==e||null==t?NaN:et?1:e>=t?0:NaN}function cs(e,t){return null==e||null==t?NaN:te?1:t>=e?0:NaN}var us=["flexDirection","alignItems","margin","display","children"];function hs(){return hs=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,us);return o().createElement("div",hs({className:"visx-legend-item",style:{display:c,alignItems:i,flexDirection:n,margin:s}},h),u)}fs.propTypes={alignItems:or().string,margin:or().oneOfType([or().string,or().number]),children:or().node,display:or().string};var ds=["flex","label","margin","align","children"];function ps(){return ps=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,ds);return o().createElement("div",ps({className:"visx-legend-label",style:{justifyContent:l,display:"flex",flex:n,margin:a}},u),c||r)}function ys(){return ys=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,Os),$=s||("domain"in i?i.domain():[]),z=g({scale:i,labelFormat:d}),I=$.map(z);return L?o().createElement(o().Fragment,null,L(I)):o().createElement("div",{className:rr()("visx-legend",t),style:Cs({},r,{flexDirection:P})},I.map((function(e,t){return o().createElement(fs,Cs({key:"legend-"+e.text+"-"+t,margin:A,flexDirection:D},F),o().createElement(ks,{shape:a,height:x,width:m,margin:_,item:$[t],itemIndex:t,label:e,fill:c,size:h,shapeStyle:w}),o().createElement(gs,Cs({label:e.text,flex:S,margin:C,align:E},j)))})))}function Ns(e){return o().createElement(As,e)}As.propTypes={children:or().func,className:or().string,domain:or().array,shapeWidth:or().oneOfType([or().string,or().number]),shapeHeight:or().oneOfType([or().string,or().number]),shapeMargin:or().oneOfType([or().string,or().number]),labelAlign:or().string,labelFlex:or().oneOfType([or().string,or().number]),labelMargin:or().oneOfType([or().string,or().number]),itemMargin:or().oneOfType([or().string,or().number]),fill:or().func,size:or().func,shapeStyle:or().func};const Ps=e=>{let{diffColumn:n,innerHeight:r,innerWidth:i,flattenedData:o,scale:a,dataRender:s,labels:l,layout:c}=e;return(0,t.createElement)("g",{x:i+n.style.marginLeft,y:0,width:n.style.width,height:r},(0,t.createElement)("rect",{x:i+n.style.marginLeft,y:-n.style.heightOffset,width:n.style.width,height:r+n.style.heightOffset,fill:n.style.rectFill||"#fff"}),(0,t.createElement)(Wr,{width:n.style.width,x:i+n.style.marginLeft+n.style.width/2,y:0,textAnchor:"middle",style:{fontSize:n.style.headerFontSize,fontWeight:n.style.fontWeight,fontStyle:n.style.fontStyle}},n.columnHeader),o?.map(((e,r)=>{const{dx:o,dy:u,style:h,category:f}=n,d="dot-plot"===c.type?a(e[s.x]):(a(e[s.x])??0)+l.labelPositionDY+12;return(0,t.createElement)("text",{style:{fontSize:l.fontSize,fontWeight:h.fontWeight,fontStyle:h.fontStyle},width:h.width,x:i+n.style.marginLeft+h.width/2,y:d,dx:o,dy:u,"dominant-baseline":"middle","text-anchor":"middle"},e[f])})))};function Rs(){return Rs=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{data:e,config:n}=(0,t.useContext)(De),{dependentAxis:r,independentAxis:i,layout:o,colors:a,dataRender:s,tooltip:l,labels:c,legend:u,bar:h,diffColumn:f}=n,d=(0,t.useRef)(null);let p=Le(o.parentClass,d);const{chartWidth:g,innerWidth:y,innerHeight:m}=He(p,o,f);let v=p.width&&p.width>=o.width?c.labelCutoff:c.labelCutoffMobile,x=(0,t.useMemo)((()=>Ue(r.tickCount||5,g,o.width)),[r.tickCount,g,o.width]);const b=e.reduce(((e,t)=>e.concat(t)),[]);b.sort(((e,t)=>"ascending"===s.sortOrder?ls(e[s.sortKey],t[s.sortKey]):"descending"===s.sortOrder?cs(e[s.sortKey],t[s.sortKey]):0));const _=e=>e[s.x].toString(),w=b.map(_),k=(0,t.useMemo)((()=>la({domain:w,padding:h.barGroupPadding})),[w,h.barGroupPadding]),E=(0,t.useMemo)((()=>la({domain:s.categories,padding:h.barPadding})),[s.categories,h.barPadding]),M=(0,t.useMemo)((()=>Ja({domain:r.domain,range:[0,y],nice:!0})),[y,r.domain]),S=(0,t.useMemo)((()=>es({domain:s.categories,range:a})),[s.categories,a]);M.rangeRound([0,y]),k.rangeRound([0,m]),E.rangeRound([0,k.bandwidth()]);const O=Gn(r,M,o.theme),C=Gn(i,k,o.theme),T=Kn(r,M,y,m),A=Kn(i,k,y,m),{tooltipData:N,tooltipLeft:P=0,tooltipTop:R=0,tooltipOpen:D,showTooltip:j,hideTooltip:L}=rs();let F;return(0,t.createElement)("div",{style:{position:"relative"}},(0,t.createElement)("svg",{width:g,height:o.height,ref:d},(0,t.createElement)(lr,{top:o.padding.top,left:o.padding.left},(0,t.createElement)(kr,T),(0,t.createElement)(Sr,A),(0,t.createElement)(gr,{data:b,keys:s.categories,height:m,width:y,y0:_,y0Scale:k,y1Scale:E,xScale:M,color:S},(e=>e.map(((e,n)=>{const r=w[n];return(0,t.createElement)(lr,{key:`bar-group-horizontal-${e.index}-${e.y0}`,top:e.y0},e.bars.map((i=>{const a=b[n].__labels?.[i.key]?b[n].__labels[i.key]:"",u=b[n].__tooltips?.[i.key]?b[n].__tooltips[i.key]:"",h=b[n].__isHighlighted?.[i.key];return(0,t.createElement)("g",{key:`${e.index}-${i.index}-${i.key}`},(0,t.createElement)(hr,{x:i.x,y:i.y,width:Math.abs(i.width),height:i.height,fill:h?s.isHighlightedColor:i.color,fillOpacity:N&&l.active&&l.deemphasizeSiblings&&(N?.x!==r||N?.y!==i.value||N?.key!==i.key)?l.deemphasizeOpacity:1,onMouseLeave:()=>{F=window.setTimeout((()=>{L()}),300)},onMouseMove:e=>{F&&clearTimeout(F);const t=ss(e)||{x:0,y:0};j({tooltipData:{x:r,y:i.value,key:i.key,customTooltip:u},tooltipTop:t.y,tooltipLeft:t.x})}}),i.value&&c.active&&(0,t.createElement)("text",Rs({key:`bar-group-horizontal-${e.index}-${e.y0}-label`},Jn(i,c,v,"horizontal","single"),Xn(c),{fill:"outside"===c.labelPositionBar||i.value<=v?"light"===o.theme?"black":"white":Ie(h?s.isHighlightedColor:i.color),fillOpacity:N&&l.active&&l.deemphasizeSiblings&&(N?.x!==r||N?.y!==i.value||N?.key!==i.key)?l.deemphasizeOpacity:1}),a||`${Zn(i.value,i.key,c,null)}`))})))})))),i.active&&(0,t.createElement)(ii,Rs({},C,{tickValues:w,numTicks:b.length,scale:k})),r.active&&(0,t.createElement)(li,Rs({},O,{top:m,scale:M,numTicks:x})),f.active&&f.category&&(0,t.createElement)(Ps,{diffColumn:f,innerHeight:m,innerWidth:y,flattenedData:b,scale:k,dataRender:s,labels:c,layout:o}))),u.active&&(0,t.createElement)(fl,{legend:u,theme:o.theme},(0,t.createElement)(Ns,{style:{display:"flex",flexFlow:`${u.orientation} wrap`},shape:u.markerStyle,shapeWidth:12,shapeHeight:12,scale:S,domain:u.categories.length>0?u.categories:S.domain(),direction:u.orientation,labelMargin:"0 15px 0 0"})),D&&N&&l.active&&(0,t.createElement)(Nl,{top:R,left:P,tooltip:l,theme:o.theme},(0,t.createElement)(t.Fragment,null,l.headerActive&&(0,t.createElement)("div",{style:{marginBottom:"10px"}},(0,t.createElement)("strong",null,er({x:N.x,category:N.key},l)))),(0,t.createElement)("div",{dangerouslySetInnerHTML:{__html:N.customTooltip?N.customTooltip:tr({x:N.x,y:N.y,category:N.key,color:S(N.key)},l)}})))};var js=["data","className","top","left","x0","x0Scale","x1Scale","yScale","color","keys","height","children"];function Ls(){return Ls=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,js),g=fr(l),y=t.map((function(e,t){return{index:t,x0:s(a(e)),bars:h.map((function(t,n){var r=e[t];return{index:n,key:t,value:r,width:g,x:l(t)||0,y:c(r)||0,color:u(t,n),height:f-(c(r)||0)}}))}}));return d?o().createElement(o().Fragment,null,d(y)):o().createElement(lr,{className:rr()("visx-bar-group",n),top:r,left:i},y.map((function(e){return o().createElement(lr,{key:"bar-group-"+e.index+"-"+e.x0,left:e.x0},e.bars.map((function(t){return o().createElement(hr,Ls({key:"bar-group-bar-"+e.index+"-"+t.index+"-"+t.value+"-"+t.key,x:t.x,y:t.y,width:t.width,height:t.height,fill:t.color},p))})))})))}function $s(){return $s=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{data:e,config:n}=(0,t.useContext)(De),{dependentAxis:r,independentAxis:i,layout:o,colors:a,dataRender:s,tooltip:l,labels:c,legend:u,bar:h}=n,f=(0,t.useRef)(null);let d=Le(o.parentClass,f);const{chartWidth:p,innerWidth:g,innerHeight:y}=He(d,o),m=e.reduce(((e,t)=>e.concat(t)),[]);m.sort(((e,t)=>"ascending"===s.sortOrder?cs(e[s.sortKey],t[s.sortKey]):"descending"===s.sortOrder?ls(e[s.sortKey],t[s.sortKey]):0));const v=e=>e[s.x].toString(),x=m.map(v),b=(0,t.useMemo)((()=>la({domain:x,padding:h.barGroupPadding})),[x,h.barGroupPadding]),_=(0,t.useMemo)((()=>la({domain:s.categories,padding:h.barPadding})),[s.categories,h.barPadding]),w=(0,t.useMemo)((()=>Ja({domain:r.domain,range:[y,0],nice:!0})),[y,r.domain]),k=(0,t.useMemo)((()=>es({domain:s.categories,range:a})),[s.categories,a]);w.rangeRound([y,0]),b.rangeRound([0,g]),_.rangeRound([0,b.bandwidth()]);const E=Gn(r,w,o.theme),M=Gn(i,b,o.theme),S=Kn(r,w,g,y-o.padding.top),O=Kn(i,b,g,y),{tooltipData:C,tooltipLeft:T=0,tooltipTop:A=0,tooltipOpen:N,showTooltip:P,hideTooltip:R}=rs();let D;return(0,t.createElement)("div",{style:{position:"relative"}},(0,t.createElement)("svg",{width:p,height:o.height,ref:f},(0,t.createElement)(lr,{top:o.padding.top,left:o.padding.left},(0,t.createElement)(Sr,S),(0,t.createElement)(kr,O),(0,t.createElement)(Fs,{data:m,keys:s.categories,height:y,width:g,x0:v,x0Scale:b,x1Scale:_,yScale:w,color:k},(e=>e.map(((e,n)=>{const r=x[n];return(0,t.createElement)(lr,{key:`bar-group-horizontal-${e.index}-${e.x0}`,left:e.x0},e.bars.map((i=>{const a=m[n].__labels?.[i.key]?m[n].__labels[i.key]:"",u=m[n].__tooltips?.[i.key]?m[n].__tooltips[i.key]:"",h=m[n].__isHighlighted?.[i.key];return(0,t.createElement)("g",{key:`${e.index}-${i.index}-${i.key}`},(0,t.createElement)(hr,{x:i.x,y:i.y,width:Math.abs(i.width),height:i.height,fill:h?s.isHighlightedColor:i.color,fillOpacity:C&&l.active&&l.deemphasizeSiblings&&(C?.x!==r||C?.y!==i.value||C?.key!==i.key)?l.deemphasizeOpacity:1,onMouseLeave:()=>{D=window.setTimeout((()=>{R()}),300)},onMouseMove:e=>{D&&clearTimeout(D);const t=ss(e)||{x:0,y:0};P({tooltipData:{x:r,y:i.value,key:i.key,customTooltip:u},tooltipTop:t.y,tooltipLeft:t.x})}}),i.value&&c.active&&(0,t.createElement)("text",$s({key:`bar-group-horizontal-${e.index}-${e.x0}-label`},Jn(i,c,c.labelCutoff,"vertical","single"),Xn(c),{fill:"outside"===c.labelPositionBar||i.value<=c.labelCutoff?"light"===o.theme?"black":"white":Ie(h?s.isHighlightedColor:i.color),fillOpacity:C&&l.active&&l.deemphasizeSiblings&&(C?.x!==r||C?.y!==i.value||C?.key!==i.key)?l.deemphasizeOpacity:1}),`${a||Zn(i.value,i.key,c,null)}`))})))})))),i.active&&(0,t.createElement)(li,$s({},M,{tickValues:x,scale:b,top:y,numTicks:m.length})),r.active&&(0,t.createElement)(ii,$s({},E,{scale:w,numTicks:void 0})))),u.active&&(0,t.createElement)(fl,{legend:u,theme:o.theme},(0,t.createElement)(Ns,{style:{display:"flex",flexFlow:`${u.orientation} wrap`},shape:u.markerStyle,shapeWidth:12,shapeHeight:12,scale:k,domain:u.categories.length>0?u.categories:k.domain(),direction:u.orientation,labelMargin:"0 15px 0 0"})),N&&C&&l.active&&(0,t.createElement)(Nl,{top:A,left:T,tooltip:l,theme:o.theme},(0,t.createElement)(t.Fragment,null,l.headerActive&&(0,t.createElement)("div",{style:{marginBottom:"10px"}},(0,t.createElement)("strong",null,er({x:C.x,category:C.key},l)))),(0,t.createElement)("div",{dangerouslySetInnerHTML:{__html:C.customTooltip?C.customTooltip:tr({x:C.x,y:C.y,category:C.key,color:k(C.key)},l)}})))};var Is=Array.prototype.slice;function Ws(e){return function(){return e}}function Us(e,t){if((i=e.length)>1)for(var n,r,i,o=1,a=e[t[0]],s=a.length;o=0;)n[t]=t;return n}function Ys(e,t){return e[t]}function Bs(){var e=Ws([]),t=Hs,n=Us,r=Ys;function i(i){var o,a,s=e.apply(this,arguments),l=i.length,c=s.length,u=new Array(c);for(o=0;oo&&(o=t,r=n);return r}var Js={ascending:Ks,descending:function(e){return Ks(e).reverse()},insideout:function(e){var t,n,r=e.length,i=e.map(Xs),o=function(e){var t=e.map(Zs);return Hs(e).sort((function(e,n){return t[e]-t[n]}))}(e),a=0,s=0,l=[],c=[];for(t=0;t0){for(var n,r,i,o=0,a=e[0].length;o0)for(var n,r,i,o,a,s,l=0,c=e[t[0]].length;l0?(r[0]=o,r[1]=o+=i):i<0?(r[1]=a,r[0]=a+=i):(r[0]=0,r[1]=i)},none:Us,silhouette:function(e,t){if((n=e.length)>0){for(var n,r=0,i=e[t[0]],o=i.length;r0&&(r=(n=e[t[0]]).length)>0){for(var n,r,i,o=0,a=1;a=0||(i[n]=e[n]);return i}(e,nl),b=Bs();p&&b.keys(p),g&&Gs(b.value,g),y&&b.order(Qs(y)),m&&b.offset(tl(m));var _=b(t),w=fr(f),k=_.map((function(e,t){var n=e.key;return{index:t,key:n,bars:e.map((function(t,r){var i=(h(u(t))||0)-(h(l(t))||0),o=h(l(t)),s="bandwidth"in f?f(a(t.data)):Math.max((f(a(t.data))||0)-i/2);return{bar:t,key:n,index:r,height:w,width:i,x:o||0,y:s||0,color:d(e.key,r)}}))}}));return v?o().createElement(o().Fragment,null,v(k)):o().createElement(lr,{className:rr()("visx-bar-stack-horizontal",n),top:r,left:i},k.map((function(e){return e.bars.map((function(t){return o().createElement(hr,rl({key:"bar-stack-"+e.index+"-"+t.index,x:t.x,y:t.y,height:t.height,width:t.width,fill:t.color},x))}))})))}function ol(){return ol=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{data:e,config:n}=(0,t.useContext)(De),{dependentAxis:r,independentAxis:i,layout:o,colors:a,dataRender:s,tooltip:l,labels:c,legend:u,divergingBar:h,bar:f,diffColumn:d}=n,p=(0,t.useRef)(null);let g=Le(o.parentClass,p);const{chartWidth:y,innerWidth:m,innerHeight:v}=He(g,o,d);let x=g.width&&g.width>=o.width?c.labelCutoff:c.labelCutoffMobile;const b=e.reduce(((e,t)=>e.concat(t)),[]).map((e=>Object.keys(e).reduce(((t,n)=>{const r=isNaN(e[n])?e[n]:parseFloat(e[n]);return{...t,[n]:h.negativeCategories.includes(n)?-r:r}}),{})));b.sort(((e,t)=>"ascending"===s.sortOrder?ls(e[s.sortKey],t[s.sortKey]):"descending"===s.sortOrder?cs(e[s.sortKey],t[s.sortKey]):0)),h.negativeCategories.includes(s.sortKey)||b.reverse();const _=(0,t.useCallback)((e=>e[s.x]),[s.x]),w=(0,t.useMemo)((()=>la({domain:b.map(_),padding:f.barPadding})),[b,_,f]),k=(0,t.useMemo)((()=>Ja({domain:r.domain,range:[0,m],nice:!0})),[m,r.domain]),E=(0,t.useMemo)((()=>es({domain:[...h.negativeCategories,...h.positiveCategories],range:a})),[h,a]);h.neutralBar.active?(k.rangeRound([0,m*h.percentOfInnerWidth]),E.domain([...h.negativeCategories,...h.positiveCategories,h.neutralBar.category])):k.rangeRound([0,m]),w.rangeRound([v,0]);const M=Gn(r,k,o.theme),S=Gn(i,w,o.theme),O=Kn(r,k,m,v),C=Kn(i,w,m,v-o.padding.top),T=Xn(c),{tooltipData:A,tooltipLeft:N=0,tooltipTop:P=0,tooltipOpen:R,showTooltip:D,hideTooltip:j}=rs();let L;return(0,t.createElement)("div",{style:{position:"relative"}},(0,t.createElement)("svg",{width:y,height:o.height,ref:p},(0,t.createElement)(lr,{top:o.padding.top,left:o.padding.left},(0,t.createElement)(Sr,C),(0,t.createElement)(kr,O),i.active&&(0,t.createElement)(ii,ol({},S,{tickValues:w.domain(),scale:w,numTicks:b.length})),r.active&&(0,t.createElement)(li,ol({},M,{top:v,scale:k})),(0,t.createElement)(il,{data:b,keys:[...h.negativeCategories,...h.positiveCategories],height:v,y:_,xScale:k,yScale:w,color:E,offset:"diverging",width:m*h.percentOfInnerWidth},(e=>e.map((e=>e.bars.map(((n,r)=>{const i=n.key,o=n.bar.data,a=o[i],s=o.__labels?.[i]?o.__labels?.[i]:"",u=o.__tooltips?.[i]?o.__tooltips?.[i]:"";return(0,t.createElement)("g",{key:`barstack-horizontal-${e.index}-${n.index}-g`},(0,t.createElement)("rect",{key:`barstack-horizontal-${e.index}-${n.index}`,x:n.x,y:n.y,width:a?Math.abs(n.width):0,height:n.height,fill:n.color,stroke:f.hasRectStroke?f.rectStrokeColor:"none",strokeWidth:f.hasRectStroke?f.rectStrokeWidth:"0",fillOpacity:A&&l.active&&l.deemphasizeSiblings&&(A?.x!==o.x||A?.y!==a||A?.category!==i)?l.deemphasizeOpacity:1,onMouseLeave:()=>{L=window.setTimeout((()=>{j()}),300)},onMouseMove:e=>{L&&clearTimeout(L);const t=ss(e)||{x:0,y:0};D({tooltipData:{x:o.x,y:a,category:i,tooltip:u},tooltipTop:t.y,tooltipLeft:t.x})}}),a&&c.active&&xe.map((e=>e.bars.map(((n,r)=>{const i=n.key,a=n.bar.data,s=a[i],u=a.__labels?.[i]?a.__labels?.[i]:"",h=a.__tooltips?.[i]?a.__tooltips?.[i]:"";return(0,t.createElement)("g",{key:`barstack-horizontal-neutral-${e.index}-${n.index}-g`},(0,t.createElement)("rect",{key:`barstack-horizontal-neutral-${e.index}-${n.index}`,x:n.x,y:n.y,width:s?Math.abs(n.width):0,height:n.height,fill:n.color,stroke:f.hasRectStroke?f.rectStrokeColor:"none",strokeWidth:f.hasRectStroke?f.rectStrokeWidth:"0",fillOpacity:A&&l.active&&l.deemphasizeSiblings&&(A?.x!==a.x||A?.y!==s||A?.category!==i)?l.deemphasizeOpacity:1,onMouseLeave:()=>{L=window.setTimeout((()=>{j()}),300)},onMouseMove:e=>{L&&clearTimeout(L);const t=ss(e)||{x:0,y:0};D({tooltipData:{x:a.x,y:s,category:i,tooltip:h},tooltipTop:t.y,tooltipLeft:t.x})}}),s&&c.active&&(0,t.createElement)("text",ol({key:`barstack-horizontal-neutral-label-${e.index}-${n.index}`},T,Jn({x:n.x,y:n.y,width:n.width,height:n.height,value:s},c,x,"horizontal","single"),{fill:"outside"===c.labelPositionBar||s0?u.categories:E.domain(),direction:u.orientation,labelMargin:"0 15px 0 0"})),R&&A&&l.active&&(0,t.createElement)(Nl,{top:P,left:N,tooltip:l,theme:o.theme},(0,t.createElement)(t.Fragment,null,l.headerActive&&(0,t.createElement)("div",{style:{marginBottom:"10px"}},(0,t.createElement)("strong",null,er({x:A.x,category:A.category},l)))),(0,t.createElement)("div",{dangerouslySetInnerHTML:{__html:A.tooltip?A.tooltip:tr({x:A.x,y:A.y,category:A.category,color:E(A.category||"")},l)}})))};var sl=["data","className","top","left","x","y0","y1","xScale","yScale","color","keys","value","order","offset","children"];function ll(){return ll=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,sl),b=Bs();p&&b.keys(p),g&&Gs(b.value,g),y&&b.order(Qs(y)),m&&b.offset(tl(m));var _=b(t),w=fr(h),k=_.map((function(e,t){var n=e.key;return{index:t,key:n,bars:e.map((function(t,r){var i=(f(l(t))||0)-(f(u(t))||0),o=f(u(t)),s="bandwidth"in h?h(a(t.data)):Math.max((h(a(t.data))||0)-w/2);return{bar:t,key:n,index:r,height:i,width:w,x:s||0,y:o||0,color:d(e.key,r)}}))}}));return v?o().createElement(o().Fragment,null,v(k)):o().createElement(lr,{className:rr()("visx-bar-stack",n),top:r,left:i},k.map((function(e){return e.bars.map((function(t){return o().createElement(hr,ll({key:"bar-stack-"+e.index+"-"+t.index,x:t.x,y:t.y,height:t.height,width:t.width,fill:t.color},x))}))})))}function ul(){return ul=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{data:e,config:n}=(0,t.useContext)(De),{dependentAxis:r,independentAxis:i,layout:o,colors:a,dataRender:s,tooltip:l,labels:c,legend:u,divergingBar:h,bar:f}=n,d=(0,t.useRef)(null);let p=Le(o.parentClass,d);const{chartWidth:g,innerWidth:y,innerHeight:m}=He(p,o);let v=p.width&&p.width>=o.width?c.labelCutoff:c.labelCutoffMobile;const x=e.reduce(((e,t)=>e.concat(t)),[]).map((e=>Object.keys(e).reduce(((t,n)=>{const r=e[n];return{...t,[n]:h.negativeCategories.includes(n)?-r:r}}),{})));x.sort(((e,t)=>"ascending"===s.sortOrder?cs(e[s.sortKey],t[s.sortKey]):ls(e[s.sortKey],t[s.sortKey])));const b=(0,t.useCallback)((e=>e[s.x]),[s.x]),_=(0,t.useMemo)((()=>la({domain:x.map(b),padding:.2})),[x,b]),w=(0,t.useMemo)((()=>Ja({domain:r.domain,range:[0,m],nice:!0})),[m,r.domain]),k=(0,t.useMemo)((()=>es({domain:[...h.negativeCategories,...h.positiveCategories],range:a})),[h,a]);_.rangeRound([0,y]),w.range([m,0]);const E=Gn(r,w,o.theme),M=Gn(i,_,o.theme),S=Xn(c),{tooltipOpen:O,tooltipLeft:C=0,tooltipTop:T=0,tooltipData:A,hideTooltip:N,showTooltip:P}=rs();let R;return g&&g<10?null:(0,t.createElement)("div",{style:{position:"relative"}},(0,t.createElement)("svg",{width:g,height:o.height,ref:d},(0,t.createElement)(lr,{top:o.padding.top,left:o.padding.left},n.dependentAxis.active&&(0,t.createElement)(ii,E),n.independentAxis.active&&(0,t.createElement)(li,ul({},M,{top:m})),(0,t.createElement)(cl,{data:x,keys:[...h.negativeCategories,...h.positiveCategories],height:m,x:b,xScale:_,yScale:w,color:k,offset:"diverging"},(e=>e.map((e=>e.bars.map((n=>{const r=n.key,i=n.bar.data,o=i[r],a=i.__labels?.[r]?i.__labels?.[r]:"",s=i.__tooltips?.[r]?i.__tooltips?.[r]:"";return(0,t.createElement)("g",{key:`barstack-vertical-${e.index}-${n.index}-g`},(0,t.createElement)("rect",{key:`barstack-vertical-${e.index}-${n.index}`,x:n.x,y:n.y,width:n.width,height:o?Math.abs(n.height):0,fill:n.color,fillOpacity:A&&l.active&&l.deemphasizeSiblings&&(A?.x!==i.x||A?.y!==o||A?.category!==r)?l.deemphasizeOpacity:1,stroke:f.hasRectStroke?f.rectStrokeColor:"none",strokeWidth:f.hasRectStroke?f.rectStrokeWidth:"0",onClick:e=>{e&&alert(`clicked: ${JSON.stringify(n)}`)},onMouseLeave:()=>{R=window.setTimeout((()=>{N()}),300)},onMouseMove:e=>{R&&clearTimeout(R);const t=ss(e)||{x:0,y:0};P({tooltipData:{x:i.x,y:o,category:r,tooltip:s},tooltipTop:t.y,tooltipLeft:t.x})}}),o&&c.active&&v0?u.categories:k.domain(),direction:"row",labelMargin:"0 15px 0 0"})),O&&A&&l.active&&(0,t.createElement)(Nl,{top:T,left:C,tooltip:l,theme:o.theme},(0,t.createElement)(t.Fragment,null,l.headerActive&&(0,t.createElement)("div",{style:{marginBottom:"10px"}},(0,t.createElement)("strong",null,er({x:A.x,category:A.category},l)))),(0,t.createElement)("div",{dangerouslySetInnerHTML:{__html:A.tooltip?A.tooltip:tr({x:A.x,y:A.y,category:A.category,color:k(A.category||"")},l)}})))},fl=e=>{let{children:n,legend:r,theme:i,chartWidth:o,layoutWidth:a}=e;const{offsetX:s,offsetY:l,title:c,alignment:u}=r,h=o&&a?o/a:1;return(0,t.createElement)("div",{style:{position:"absolute",top:l/2-10,left:s*h,width:"none"===u?"auto":"100%",display:"none"===u?"block":"flex",justifyContent:u,fontSize:"12px",fontFamily:"'franklin-gothic-urw', Verdana, Geneva, sans-serif"}},(0,t.createElement)("div",{className:"cb__legend__inner",style:{display:"flex",flexDirection:"column",alignItems:"center",backgroundColor:"light"===i?r.fill:"#1e1e1e",border:`1px solid ${"light"===i?r.borderStroke:"#fff"}`,padding:"10px"}},c&&(0,t.createElement)("div",{className:"cb__legend__title",style:{fontSize:"12px",fontWeight:400,marginBottom:"10px"}},c),n))},dl=window.ReactDOM;var pl=n.n(dl);function gl(){return gl=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,vl);return o().createElement("div",xl({ref:t,className:rr()("visx-tooltip",n),style:xl({top:null==r||null==c?r:r+c,left:null==i||null==s?i:i+s},y&&{position:"absolute"},!p&&h)},m),f)}));_l.propTypes={children:or().node,className:or().string,left:or().number,offsetLeft:or().number,offsetTop:or().number,top:or().number,applyPositionStyle:or().bool,unstyled:or().bool},_l.displayName="Tooltip";const wl=_l;var kl=(0,i.createContext)({isFlippedVertically:!1,isFlippedHorizontally:!1}),El=kl.Provider,Ml=(kl.Consumer,["children","getRects","left","offsetLeft","offsetTop","parentRect","rect","style","top","unstyled","nodeRef"]);function Sl(){return Sl=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,Ml),b=!1,_=!1;if(h&&u){var w=i,k=g;if(u.width){var E=w+s+h.width-u.width,M=h.width-w-s;b=E>0&&E>M}else{var S=w+s+h.width-window.innerWidth,O=h.width-w-s;b=S>0&&S>O}if(u.height){var C=k+c+h.height-u.height,T=h.height-k-c;_=C>0&&C>T}else _=k+c+h.height>window.innerHeight;w=b?w-h.width-s:w+s,k=_?k-h.height-c:k+c,t="translate("+(w=Math.round(w))+"px, "+(k=Math.round(k))+"px)"}return o().createElement(wl,Sl({ref:v,style:Sl({left:0,top:0,transform:t},!m&&d)},x),o().createElement(El,{value:{isFlippedVertically:!_,isFlippedHorizontally:!b}},n))}Ol.propTypes={nodeRef:or().oneOfType([or().string,or().func,or().object])};const Cl=(Tl=Ol,Al=function(e){var t,n;function r(t){var n;return(n=e.call(this,t)||this).state={rect:void 0,parentRect:void 0},n.nodeRef=o().createRef(),n.getRects=n.getRects.bind(function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(n)),n}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,yl(t,n);var i=r.prototype;return i.componentDidMount=function(){var e,t=this;this.node=null!=(e=this.nodeRef)&&e.current?this.nodeRef.current:pl().findDOMNode(this),this.setState((function(){return t.getRects()}))},i.getRects=function(){if(!this.node)return this.state;var e=this.node,t=e.parentNode;return{rect:e.getBoundingClientRect?e.getBoundingClientRect():ml,parentRect:null!=t&&t.getBoundingClientRect?t.getBoundingClientRect():ml}},i.render=function(){return o().createElement(Tl,gl({nodeRef:this.nodeRef,getRects:this.getRects},this.state,this.props))},r}(o().PureComponent),Al.displayName="withBoundingRects("+(Tl.displayName||"")+")",Al);var Tl,Al;const Nl=e=>{let{tooltip:n,top:r,left:i,children:o,theme:a}=e;const{minWidth:s,maxWidth:l,maxHeight:c,minHeight:u,width:h,background:f,border:d,padding:p,borderRadius:g,fontFamily:y,fontSize:m}=n.style;return(0,t.createElement)(Cl,{className:"tooltip with-bounds",top:r+n.offsetY,left:i+n.offsetX,style:{position:"absolute",pointerEvents:"none",width:h,minWidth:s,maxWidth:l,maxHeight:c,minHeight:u,overflow:"auto",background:"light"===a?f:"#1e1e1e",border:"light"===a?d:"1px solid #fff",padding:p,borderRadius:g,fontFamily:y,fontSize:m,lineHeight:"1.2em",boxShadow:"0px 0px 2px 0px #63646480"}},o)};var Pl=["className","innerRef"];function Rl(){return Rl=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,Pl);return o().createElement("circle",Rl({ref:n,className:rr()("visx-circle",t)},r))}var jl=aa("domain","range","reverse","align","padding","round");function Ll(e,t){let n;if(void 0===t)for(const t of e)null!=t&&(n=t)&&(n=t);else{let r=-1;for(let i of e)null!=(i=t(i,++r,e))&&(n=i)&&(n=i)}return n}function Fl(){return Fl=Object.assign?Object.assign.bind():function(e){for(var t=1;t0?Bl(tc,--Ql):0,Zl--,10===ec&&(Zl=1,Xl--),ec}function oc(){return ec=Ql2||cc(ec)>3?"":" "}function pc(e,t){for(;--t&&oc()&&!(ec<48||ec>102||ec>57&&ec<65||ec>70&&ec<97););return lc(e,sc()+(t<6&&32==ac()&&32==oc()))}function gc(e){for(;oc();)switch(ec){case e:return Ql;case 34:case 39:34!==e&&39!==e&&gc(ec);break;case 40:41===e&&gc(e);break;case 92:oc()}return Ql}function yc(e,t){for(;oc()&&e+ec!==57&&(e+ec!==84||47!==ac()););return"/*"+lc(t,Ql-1)+"*"+Il(47===e?e:oc())}function mc(e){for(;!cc(ac());)oc();return lc(e,Ql)}var vc="-ms-",xc="-moz-",bc="-webkit-",_c="comm",wc="rule",kc="decl",Ec="@keyframes";function Mc(e,t){for(var n="",r=Gl(e),i=0;i0&&ql(k)-h&&Kl(d>32?Nc(k+";",r,n,h-1):Nc(Hl(k," ","")+";",r,n,h-2),l);break;case 59:k+=";";default:if(Kl(w=Tc(k,t,n,c,u,i,s,x,b=[],_=[],h),o),123===v)if(0===u)Cc(k,t,w,w,b,o,h,s,_);else switch(99===f&&110===Bl(k,3)?100:f){case 100:case 108:case 109:case 115:Cc(e,w,w,r&&Kl(Tc(e,w,w,0,0,i,s,x,i,b=[],h),_),i,_,h,s,r?b:_);break;default:Cc(k,w,w,w,[""],_,0,s,_)}}c=u=d=0,g=m=1,x=k="",h=a;break;case 58:h=1+ql(k),d=p;default:if(g<1)if(123==v)--g;else if(125==v&&0==g++&&125==ic())continue;switch(k+=Il(v),v*g){case 38:m=u>0?1:(k+="\f",-1);break;case 44:s[c++]=(ql(k)-1)*m,m=1;break;case 64:45===ac()&&(k+=fc(oc())),f=ac(),u=h=ql(x=k+=mc(sc())),v++;break;case 45:45===p&&2==ql(k)&&(g=0)}}return o}function Tc(e,t,n,r,i,o,a,s,l,c,u){for(var h=i-1,f=0===i?o:[""],d=Gl(f),p=0,g=0,y=0;p0?f[m]+" "+v:Hl(v,/&\f/g,f[m])))&&(l[y++]=x);return nc(e,t,n,0===i?wc:s,l,c,u)}function Ac(e,t,n){return nc(e,t,n,_c,Il(ec),Vl(e,2,-2),0)}function Nc(e,t,n,r){return nc(e,t,n,kc,Vl(e,0,r),Vl(e,r+1,-1),r)}var Pc=function(e,t,n){for(var r=0,i=0;r=i,i=ac(),38===r&&12===i&&(t[n]=1),!cc(i);)oc();return lc(e,Ql)},Rc=new WeakMap,Dc=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,n=e.parent,r=e.column===n.column&&e.line===n.line;"rule"!==n.type;)if(!(n=n.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||Rc.get(n))&&!r){Rc.set(e,!0);for(var i=[],o=function(e,t){return hc(function(e,t){var n=-1,r=44;do{switch(cc(r)){case 0:38===r&&12===ac()&&(t[n]=1),e[n]+=Pc(Ql-1,t,n);break;case 2:e[n]+=fc(r);break;case 4:if(44===r){e[++n]=58===ac()?"&\f":"",t[n]=e[n].length;break}default:e[n]+=Il(r)}}while(r=oc());return e}(uc(e),t))}(t,i),a=n.props,s=0,l=0;s6)switch(Bl(e,t+1)){case 109:if(45!==Bl(e,t+4))break;case 102:return Hl(e,/(.+:)(.+)-([^]+)/,"$1"+bc+"$2-$3$1"+xc+(108==Bl(e,t+3)?"$3":"$2-$3"))+e;case 115:return~Yl(e,"stretch")?Lc(Hl(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(115!==Bl(e,t+1))break;case 6444:switch(Bl(e,ql(e)-3-(~Yl(e,"!important")&&10))){case 107:return Hl(e,":",":"+bc)+e;case 101:return Hl(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+bc+(45===Bl(e,14)?"inline-":"")+"box$3$1"+bc+"$2$3$1"+vc+"$2box$3")+e}break;case 5936:switch(Bl(e,t+11)){case 114:return bc+e+vc+Hl(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return bc+e+vc+Hl(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return bc+e+vc+Hl(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return bc+e+vc+e+e}return e}var Fc=[function(e,t,n,r){if(e.length>-1&&!e.return)switch(e.type){case kc:e.return=Lc(e.value,e.length);break;case Ec:return Mc([rc(e,{value:Hl(e.value,"@","@"+bc)})],r);case wc:if(e.length)return function(e,t){return e.map(t).join("")}(e.props,(function(t){switch(function(e,t){return(e=/(::plac\w+|:read-\w+)/.exec(e))?e[0]:e}(t)){case":read-only":case":read-write":return Mc([rc(e,{props:[Hl(t,/:(read-\w+)/,":-moz-$1")]})],r);case"::placeholder":return Mc([rc(e,{props:[Hl(t,/:(plac\w+)/,":"+bc+"input-$1")]}),rc(e,{props:[Hl(t,/:(plac\w+)/,":-moz-$1")]}),rc(e,{props:[Hl(t,/:(plac\w+)/,vc+"input-$1")]})],r)}return""}))}}],$c=function(e){var t=e.key;if("css"===t){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,(function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))}))}var r,i,o=e.stylisPlugins||Fc,a={},s=[];r=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),(function(e){for(var t=e.getAttribute("data-emotion").split(" "),n=1;n96?eu:tu},ru=function(e,t,n){var r;if(t){var i=t.shouldForwardProp;r=e.__emotion_forwardProp&&i?function(t){return e.__emotion_forwardProp(t)&&i(t)}:i}return"function"!=typeof r&&n&&(r=e.__emotion_forwardProp),r},iu=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return Qc(t,n,r),Xc((function(){return function(e,t,n){Qc(e,t,n);var r=e.key+"-"+t.name;if(void 0===e.inserted[t.name]){var i=t;do{e.insert(t===i?"."+r:"",i,e.sheet,!0),i=i.next}while(void 0!==i)}}(t,n,r)})),null},ou=function e(t,n){var r,o,a=t.__emotion_real===t,s=a&&t.__emotion_base||t;void 0!==n&&(r=n.label,o=n.target);var l=ru(t,n,a),c=l||nu(s),u=!c("as");return function(){var h=arguments,f=a&&void 0!==t.__emotion_styles?t.__emotion_styles.slice(0):[];if(void 0!==r&&f.push("label:"+r+";"),null==h[0]||void 0===h[0].raw)f.push.apply(f,h);else{f.push(h[0][0]);for(var d=h.length,p=1;p=4;++r,i-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),n=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(i){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&e.charCodeAt(r)))+(59797*(n>>>16)<<16)}return(((n=1540483477*(65535&(n^=n>>>13))+(59797*(n>>>16)<<16))^n>>>15)>>>0).toString(36)}(i)+l;return{name:c,styles:i,next:qc}}(f.concat(y),t.registered,m);g+=t.key+"-"+x.name,void 0!==o&&(g+=" "+o);var b=u&&void 0===l?nu(p):c,_={};for(var w in e)u&&"as"===w||b(w)&&(_[w]=e[w]);return _.className=g,_.ref=n,i.createElement(i.Fragment,null,i.createElement(iu,{cache:t,serialized:x,isStringTag:"string"==typeof p}),i.createElement(p,_))},(0,i.forwardRef)((function(e,t){var n=(0,i.useContext)(Zc);return g(e,n,t)})));return y.displayName=void 0!==r?r:"Styled("+("string"==typeof s?s:s.displayName||s.name||"Component")+")",y.defaultProps=t.defaultProps,y.__emotion_real=y,y.__emotion_base=s,y.__emotion_styles=f,y.__emotion_forwardProp=l,Object.defineProperty(y,"toString",{value:function(){return"."+o}}),y.withComponent=function(t,r){return e(t,Fl({},n,r,{shouldForwardProp:ru(y,r,!0)})).apply(void 0,f)},y}}.bind();function au(){return au=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{data:e,config:n}=(0,t.useContext)(De),{dependentAxis:r,independentAxis:i,layout:o,colors:a,nodes:s,dataRender:l,tooltip:c,dotPlot:u,labels:h,legend:f,diffColumn:d}=n,p=(0,t.useRef)(null);let g=Le(o.parentClass,p);const{chartWidth:y,innerWidth:m,innerHeight:v}=He(g,o,d),x=e.reduce(((e,t)=>e.concat(t)),[]).map((e=>Object.keys(e).reduce(((t,n)=>({...t,[n]:""===e[n]||isNaN(e[n])?e[n]:parseFloat(e[n])})),{})));x.sort(((e,t)=>"ascending"===l.sortOrder?ls(e[l.sortKey],t[l.sortKey]):"descending"===l.sortOrder?cs(e[l.sortKey],t[l.sortKey]):0)),x.reverse();const b=l.categories,_=(0,t.useCallback)((e=>e[l.x]),[l.x]),w=(0,t.useMemo)((()=>function(e){return jl(pi(),e)}({domain:x.map(_),padding:.5})),[x,_]),k=(0,t.useMemo)((()=>Ja({domain:r.domain,range:[0,m],nice:!0})),[m,r.domain]),E=es({domain:b,range:a});k.rangeRound([0,m]),w.rangeRound([v,0]);const M=Gn(r,k,o.theme),S=Gn(i,w,o.theme),O=Kn(r,k,m,v),C=Kn(i,w,m,v),T=Xn(h),{tooltipData:A,tooltipLeft:N=0,tooltipTop:P=0,tooltipOpen:R,showTooltip:D,hideTooltip:j}=rs();let L;return(0,t.createElement)("div",{style:{position:"relative"}},(0,t.createElement)("svg",{width:y,height:o.height,ref:p},(0,t.createElement)(lr,{top:o.padding.top,left:o.padding.left},(0,t.createElement)(Sr,C),(0,t.createElement)(kr,O),i.active&&(0,t.createElement)(ii,au({},S,{numTicks:x.length})),r.active&&(0,t.createElement)(li,au({},M,{top:v})),d.active&&d.category&&(0,t.createElement)(Ps,{diffColumn:d,innerHeight:v,innerWidth:m,flattenedData:x,scale:w,dataRender:l,labels:h,layout:o}),u.connectPoints&&(0,t.createElement)("g",null,x?.map(((e,n)=>{const r=b.map((t=>e[t])),i=function(e,t){let n;for(const t of e)null!=t&&(n>t||void 0===n&&t>=t)&&(n=t);return n}(r),o=Ll(r);if(i&&o)return(0,t.createElement)(Tr,{key:su.default(JSON.stringify(e)),from:{x:k(i),y:w(e[l.x])},to:{x:k(o),y:w(e[l.x])},stroke:u.connectingLine.stroke,strokeWidth:u.connectingLine.strokeWidth,strokeDasharray:u.connectingLine.strokeDasharray})}))),b.map(((e,n)=>{const r=x.filter((t=>t[e]||""!==t[e]));return(0,t.createElement)("g",{key:su.default(JSON.stringify(e))},r?.map(((i,o)=>{const l=r[o].__tooltips?.[e]?r[o].__tooltips?.[e]:"";return(0,t.createElement)(lu,{key:`dot-plot-node-${su.default(JSON.stringify(i))}`,r:s.pointSize,tabIndex:0,cy:w(_(i))||0,cx:k(r[o][e]),stroke:a[n],strokeOpacity:A&&c.active&&c.deemphasizeSiblings&&A.category!==e?c.deemphasizeOpacity:1,strokeWidth:s.pointStrokeWidth,fill:"inherit"===s.pointFill?a[n]:"white",fillOpacity:A&&c.active&&c.deemphasizeSiblings&&A.category!==e?c.deemphasizeOpacity:1,onMouseLeave:()=>{L=window.setTimeout((()=>{j()}),300)},onBlur:()=>{L=window.setTimeout((()=>{j()}),300)},onFocus:()=>{L&&clearTimeout(L),D({tooltipData:{x:i.x,y:i[e],category:e,tooltip:l},tooltipTop:w(_(i)),tooltipLeft:k(i[e])||0})},onMouseMove:()=>{L&&clearTimeout(L),D({tooltipData:{x:i.x,y:i[e],category:e,tooltip:l},tooltipTop:w(_(i)),tooltipLeft:k(i[e])||0})}})})),h.active&&r?.map(((i,o)=>{const s=r[o].__labels?.[e]?x[o].__labels?.[e]:"";return(0,t.createElement)("text",au({key:`dot-plot-label-${su.default(JSON.stringify(i))}`},T,{y:(w(_(i))||0)-10,x:k(r[o][e]),fill:"inherit"===h.color?a[n]:"black"}),s||`${Zn(i[e],e,h,null)}`)})))})),A&&c.active&&(0,t.createElement)("g",null,(0,t.createElement)(Dl,{cx:N,cy:P+1,r:s.pointSize+2,fill:"transparent",fillOpacity:.1,stroke:"black",strokeOpacity:.1,strokeWidth:2,pointerEvents:"none"}),(0,t.createElement)(Dl,{cx:N,cy:P,r:s.pointSize+1,fill:"transparent",stroke:"white",strokeWidth:2,pointerEvents:"none"})))),f.active&&(0,t.createElement)(fl,{legend:f,theme:o.theme},(0,t.createElement)(Ns,{style:{display:"flex",flexFlow:`${f.orientation} wrap`},shape:f.markerStyle,shapeWidth:12,shapeHeight:12,scale:E,domain:f.categories.length>0?f.categories:E.domain(),direction:f.orientation,labelMargin:"0 15px 0 0"})),R&&A&&c.active&&(0,t.createElement)(Nl,{top:P,left:N,tooltip:c,theme:o.theme},(0,t.createElement)(t.Fragment,null,c.headerActive&&(0,t.createElement)("div",{style:{marginBottom:"10px"}},(0,t.createElement)("strong",null,er({x:_(A),category:A.category},c)))),(0,t.createElement)("div",{dangerouslySetInnerHTML:{__html:A.tooltip?A.tooltip:tr({y:(F=A,F.y),x:_(A).toString(),category:A.category,color:E(A.category||"")},c)}})));var F};function uu(){return uu=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{data:e,config:n}=(0,t.useContext)(De),{dependentAxis:r,independentAxis:i,layout:o,colors:a,dataRender:s,tooltip:l,labels:c,legend:u,explodedBar:h,bar:f,diffColumn:d}=n,p=(0,t.useRef)(null);let g=Le(o.parentClass,p);const{chartWidth:y,innerWidth:m,innerHeight:v}=He(g,o,d);let x=g.width&&g.width>=o.width?c.labelCutoff:c.labelCutoffMobile,b=(0,t.useMemo)((()=>Ue(r.tickCount||5,y,o.width)),[r.tickCount,y,o.width]);const _=e.reduce(((e,t)=>e.concat(t)),[]);_.sort(((e,t)=>"ascending"===s.sortOrder?ls(e[s.sortKey],t[s.sortKey]):"descending"===s.sortOrder?cs(e[s.sortKey],t[s.sortKey]):0)),_.reverse();const w=(0,t.useCallback)((e=>e[s.x].toString()),[s.x]),k=(0,t.useMemo)((()=>la({domain:_.map(w),padding:f.barPadding})),[_,w,f.barPadding]),E=(0,t.useMemo)((()=>Ja({domain:r.domain,range:[0,m/s.categories.length-30],nice:!0})),[m,r.domain,s.categories]),M=(0,t.useMemo)((()=>es({domain:s.categories,range:a})),[s.categories,a]);E.rangeRound([0,m/s.categories.length-30]),k.rangeRound([v,0]);const S=Gn(r,E,o.theme),O=Gn(i,k,o.theme),C=Kn(r,E,m,v-o.padding.top),T=Kn(i,k,m,v),A=Xn(c),{tooltipData:N,tooltipLeft:P=0,tooltipTop:R=0,tooltipOpen:D,showTooltip:j,hideTooltip:L}=rs();let F;return(0,t.createElement)("div",{style:{position:"relative"}},(0,t.createElement)("svg",{width:y,height:o.height,ref:p},s.categories.map(((e,n)=>(0,t.createElement)(lr,{key:e,top:o.padding.top,left:o.padding.left+m*(n/s.categories.length)+(n>0?h.columnGap*n:0)},(0,t.createElement)(Sr,T),(0,t.createElement)(kr,C),(0,t.createElement)(il,{data:_,keys:[e],height:v,y:w,xScale:E,yScale:k,color:M},(e=>e.map((e=>e.bars.map(((n,r)=>{const i=n.key,a=n.bar.data,s=a[i],u=_[r].__labels?.[n.key]?_[r].__labels[n.key]:"",h=_[r].__tooltips?.[n.key]?_[r].__tooltips[n.key]:"";return(0,t.createElement)("g",{key:`barstack-horizontal-${e.index}-${n.index}-g`},(0,t.createElement)("rect",{key:`barstack-horizontal-${e.index}-${n.index}`,x:n.x,y:n.y,width:s?Math.abs(n.width):0,height:n.height,fill:n.color,fillOpacity:N&&l.active&&l.deemphasizeSiblings&&(N?.x!==a.x||N?.y!==s||N?.category!==i)?l.deemphasizeOpacity:1,onMouseLeave:()=>{F=window.setTimeout((()=>{L()}),300)},onMouseMove:e=>{F&&clearTimeout(F);const t=ss(e)||{x:0,y:0};j({tooltipData:{x:a.x,y:s,category:i,customTooltip:h},tooltipTop:t.y,tooltipLeft:t.x})}}),s&&c.active&&(0,t.createElement)("text",uu({key:`barstack-horizontal-label-${e.index}-${n.index}`},A,Jn({x:n.x,y:n.y,width:n.width,height:n.height,value:s},c,x,"horizontal","single"),{fill:"outside"===c.labelPositionBar||s0?u.categories:M.domain(),direction:u.orientation,labelMargin:"0 15px 0 0"})),D&&N&&l.active&&(0,t.createElement)(Nl,{top:R,left:P,tooltip:l,theme:o.theme},(0,t.createElement)(t.Fragment,null,l.headerActive&&(0,t.createElement)("div",{style:{marginBottom:"10px"}},(0,t.createElement)("strong",null,er({x:N.x,category:N.key},l)))),(0,t.createElement)("div",{dangerouslySetInnerHTML:{__html:N.tooltip?N.tooltip:tr({y:N.y,x:N.x,category:N.category,color:M(N.category||"")},l)}})))},fu=e=>{const{position:n,maxWidth:r}=e;return(0,t.createElement)("hr",{style:{margin:"top"===n?"0 0 10px 0":"10px 0 0 0",maxWidth:`${r}px`}})};var du=Math.PI,pu=2*du,gu=1e-6,yu=pu-gu;function mu(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function vu(){return new mu}mu.prototype=vu.prototype={constructor:mu,moveTo:function(e,t){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)},closePath:function(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(e,t){this._+="L"+(this._x1=+e)+","+(this._y1=+t)},quadraticCurveTo:function(e,t,n,r){this._+="Q"+ +e+","+ +t+","+(this._x1=+n)+","+(this._y1=+r)},bezierCurveTo:function(e,t,n,r,i,o){this._+="C"+ +e+","+ +t+","+ +n+","+ +r+","+(this._x1=+i)+","+(this._y1=+o)},arcTo:function(e,t,n,r,i){e=+e,t=+t,n=+n,r=+r,i=+i;var o=this._x1,a=this._y1,s=n-e,l=r-t,c=o-e,u=a-t,h=c*c+u*u;if(i<0)throw new Error("negative radius: "+i);if(null===this._x1)this._+="M"+(this._x1=e)+","+(this._y1=t);else if(h>gu)if(Math.abs(u*s-l*c)>gu&&i){var f=n-o,d=r-a,p=s*s+l*l,g=f*f+d*d,y=Math.sqrt(p),m=Math.sqrt(h),v=i*Math.tan((du-Math.acos((p+h-g)/(2*y*m)))/2),x=v/m,b=v/y;Math.abs(x-1)>gu&&(this._+="L"+(e+x*c)+","+(t+x*u)),this._+="A"+i+","+i+",0,0,"+ +(u*f>c*d)+","+(this._x1=e+b*s)+","+(this._y1=t+b*l)}else this._+="L"+(this._x1=e)+","+(this._y1=t)},arc:function(e,t,n,r,i,o){e=+e,t=+t,o=!!o;var a=(n=+n)*Math.cos(r),s=n*Math.sin(r),l=e+a,c=t+s,u=1^o,h=o?r-i:i-r;if(n<0)throw new Error("negative radius: "+n);null===this._x1?this._+="M"+l+","+c:(Math.abs(this._x1-l)>gu||Math.abs(this._y1-c)>gu)&&(this._+="L"+l+","+c),n&&(h<0&&(h=h%pu+pu),h>yu?this._+="A"+n+","+n+",0,1,"+u+","+(e-a)+","+(t-s)+"A"+n+","+n+",0,1,"+u+","+(this._x1=l)+","+(this._y1=c):h>gu&&(this._+="A"+n+","+n+",0,"+ +(h>=du)+","+u+","+(this._x1=e+n*Math.cos(i))+","+(this._y1=t+n*Math.sin(i))))},rect:function(e,t,n,r){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)+"h"+ +n+"v"+ +r+"h"+-n+"Z"},toString:function(){return this._}};const xu=vu;var bu=Math.abs,_u=Math.atan2,wu=Math.cos,ku=Math.max,Eu=Math.min,Mu=Math.sin,Su=Math.sqrt,Ou=1e-12,Cu=Math.PI,Tu=Cu/2,Au=2*Cu;function Nu(e){return e>=1?Tu:e<=-1?-Tu:Math.asin(e)}function Pu(e){return e.innerRadius}function Ru(e){return e.outerRadius}function Du(e){return e.startAngle}function ju(e){return e.endAngle}function Lu(e){return e&&e.padAngle}function Fu(e,t,n,r,i,o,a){var s=e-n,l=t-r,c=(a?o:-o)/Su(s*s+l*l),u=c*l,h=-c*s,f=e+u,d=t+h,p=n+u,g=r+h,y=(f+p)/2,m=(d+g)/2,v=p-f,x=g-d,b=v*v+x*x,_=i-o,w=f*g-p*d,k=(x<0?-1:1)*Su(ku(0,_*_*b-w*w)),E=(w*x-v*k)/b,M=(-w*v-x*k)/b,S=(w*x+v*k)/b,O=(-w*v+x*k)/b,C=E-y,T=M-m,A=S-y,N=O-m;return C*C+T*T>A*A+N*N&&(E=S,M=O),{cx:E,cy:M,x01:-u,y01:-h,x11:E*(i/_-1),y11:M*(i/_-1)}}function $u(e){this._context=e}function zu(e){return new $u(e)}function Iu(e){return e[0]}function Wu(e){return e[1]}function Uu(){var e=Iu,t=Wu,n=Ws(!0),r=null,i=zu,o=null;function a(a){var s,l,c,u=a.length,h=!1;for(null==r&&(o=i(c=xu())),s=0;s<=u;++s)!(se?1:t>=e?0:NaN}function Yu(e){return e}function Bu(e){var t=void 0===e?{}:e,n=t.x,r=t.x0,i=t.x1,o=t.y,a=t.y0,s=t.y1,l=t.defined,c=t.curve,u=function(){var e=Iu,t=null,n=Ws(0),r=Wu,i=Ws(!0),o=null,a=zu,s=null;function l(l){var c,u,h,f,d,p=l.length,g=!1,y=new Array(p),m=new Array(p);for(null==o&&(s=a(d=xu())),c=0;c<=p;++c){if(!(c=u;--h)s.point(y[h],m[h]);s.lineEnd(),s.areaEnd()}g&&(y[c]=+e(f,c,l),m[c]=+n(f,c,l),s.point(t?+t(f,c,l):y[c],r?+r(f,c,l):m[c]))}if(d)return s=null,d+""||null}function c(){return Uu().defined(i).curve(a).context(o)}return l.x=function(n){return arguments.length?(e="function"==typeof n?n:Ws(+n),t=null,l):e},l.x0=function(t){return arguments.length?(e="function"==typeof t?t:Ws(+t),l):e},l.x1=function(e){return arguments.length?(t=null==e?null:"function"==typeof e?e:Ws(+e),l):t},l.y=function(e){return arguments.length?(n="function"==typeof e?e:Ws(+e),r=null,l):n},l.y0=function(e){return arguments.length?(n="function"==typeof e?e:Ws(+e),l):n},l.y1=function(e){return arguments.length?(r=null==e?null:"function"==typeof e?e:Ws(+e),l):r},l.lineX0=l.lineY0=function(){return c().x(e).y(n)},l.lineY1=function(){return c().x(e).y(r)},l.lineX1=function(){return c().x(t).y(n)},l.defined=function(e){return arguments.length?(i="function"==typeof e?e:Ws(!!e),l):i},l.curve=function(e){return arguments.length?(a=e,null!=o&&(s=a(o)),l):a},l.context=function(e){return arguments.length?(null==e?o=s=null:s=a(o=e),l):o},l}();return n&&Gs(u.x,n),r&&Gs(u.x0,r),i&&Gs(u.x1,i),o&&Gs(u.y,o),a&&Gs(u.y0,a),s&&Gs(u.y1,s),l&&u.defined(l),c&&u.curve(c),u}$u.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&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)}}};var Vu=["className","top","left","data","centroid","innerRadius","outerRadius","cornerRadius","startAngle","endAngle","padAngle","padRadius","pieSort","pieSortValues","pieValue","children","fill"];function qu(){return qu=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,Vu),k=function(e){var t=void 0===e?{}:e,n=t.innerRadius,r=t.outerRadius,i=t.cornerRadius,o=t.startAngle,a=t.endAngle,s=t.padAngle,l=t.padRadius,c=function(){var e=Pu,t=Ru,n=Ws(0),r=null,i=Du,o=ju,a=Lu,s=null;function l(){var l,c,u=+e.apply(this,arguments),h=+t.apply(this,arguments),f=i.apply(this,arguments)-Tu,d=o.apply(this,arguments)-Tu,p=bu(d-f),g=d>f;if(s||(s=l=xu()),hOu)if(p>Au-Ou)s.moveTo(h*wu(f),h*Mu(f)),s.arc(0,0,h,f,d,!g),u>Ou&&(s.moveTo(u*wu(d),u*Mu(d)),s.arc(0,0,u,d,f,g));else{var y,m,v=f,x=d,b=f,_=d,w=p,k=p,E=a.apply(this,arguments)/2,M=E>Ou&&(r?+r.apply(this,arguments):Su(u*u+h*h)),S=Eu(bu(h-u)/2,+n.apply(this,arguments)),O=S,C=S;if(M>Ou){var T=Nu(M/u*Mu(E)),A=Nu(M/h*Mu(E));(w-=2*T)>Ou?(b+=T*=g?1:-1,_-=T):(w=0,b=_=(f+d)/2),(k-=2*A)>Ou?(v+=A*=g?1:-1,x-=A):(k=0,v=x=(f+d)/2)}var N=h*wu(v),P=h*Mu(v),R=u*wu(_),D=u*Mu(_);if(S>Ou){var j,L=h*wu(x),F=h*Mu(x),$=u*wu(b),z=u*Mu(b);if(p1?0:e<-1?Cu:Math.acos(e)}((I*U+W*H)/(Su(I*I+W*W)*Su(U*U+H*H)))/2),B=Su(j[0]*j[0]+j[1]*j[1]);O=Eu(S,(u-B)/(Y-1)),C=Eu(S,(h-B)/(Y+1))}}k>Ou?C>Ou?(y=Fu($,z,N,P,h,C,g),m=Fu(L,F,R,D,h,C,g),s.moveTo(y.cx+y.x01,y.cy+y.y01),COu&&w>Ou?O>Ou?(y=Fu(R,D,L,F,u,-O,g),m=Fu(N,P,$,z,u,-O,g),s.lineTo(y.cx+y.x01,y.cy+y.y01),O0&&(d+=h);for(null!=t?p.sort((function(e,n){return t(g[e],g[n])})):null!=n&&p.sort((function(e,t){return n(a[e],a[t])})),s=0,c=d?(m-f*x)/d:0;s0?h*c:0)+x,g[l]={data:a[l],index:s,value:h,startAngle:y,endAngle:u,padAngle:v};return g}return a.value=function(t){return arguments.length?(e="function"==typeof t?t:Ws(+t),a):e},a.sortValues=function(e){return arguments.length?(t=e,n=null,a):t},a.sort=function(e){return arguments.length?(n=e,t=null,a):n},a.startAngle=function(e){return arguments.length?(r="function"==typeof e?e:Ws(+e),a):r},a.endAngle=function(e){return arguments.length?(i="function"==typeof e?e:Ws(+e),a):i},a.padAngle=function(e){return arguments.length?(o="function"==typeof e?e:Ws(+e),a):o},a}();return(null===a||null!=a)&&l.sort(a),(null===s||null!=s)&&l.sortValues(s),null!=o&&l.value(o),null!=i&&Gs(l.padAngle,i),null!=n&&Gs(l.startAngle,n),null!=r&&Gs(l.endAngle,r),l}({startAngle:f,endAngle:d,padAngle:p,value:v,sort:y,sortValues:m}),M=E(a);return x?o().createElement(o().Fragment,null,x({arcs:M,path:k,pie:E})):o().createElement(lr,{className:"visx-pie-arcs-group",top:n,left:r},M.map((function(e,n){return o().createElement("g",{key:"pie-arc-"+n},o().createElement("path",qu({className:rr()("visx-pie-arc",t),d:k(e)||"",fill:null==_||"string"==typeof _?_:_(e)},w)),null==s?void 0:s(k.centroid(e),e))})))}function Ku(){return Ku=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{data:e,config:n}=(0,t.useContext)(De),{layout:r,labels:i,colors:o,tooltip:a,legend:s,dataRender:l,pie:c}=n,u=(0,t.useRef)(null);let h=Le(r.parentClass,u);const{chartWidth:f,innerWidth:d,innerHeight:p}=He(h,r),g=Math.min(d,p)/2,y=d/2,m=p/2+r.padding.top,v=y+r.padding.left,x=e.reduce(((e,t)=>e.concat(t)),[]);x.sort(((e,t)=>"ascending"===l.sortOrder?ls(e[l.sortKey],t[l.sortKey]):"descending"===l.sortOrder?cs(e[l.sortKey],t[l.sortKey]):0));const b=(e,t)=>"ascending"===l.sortOrder?e-t:"descending"===l.sortOrder?t-e:0,_=e=>e.x,w=e=>e[l.categories[0]],k=(0,t.useMemo)((()=>es({domain:x.map(_),range:o})),[x,o]),{tooltipOpen:E,tooltipLeft:M=0,tooltipTop:S=0,tooltipData:O,hideTooltip:C,showTooltip:T}=rs();let A;return(0,t.createElement)("div",{style:{position:"relative"}},(0,t.createElement)("svg",{width:f,height:r.height,ref:u},(0,t.createElement)(lr,{top:m,left:v},(0,t.createElement)(Gu,{data:x,pieValue:w,pieSortValues:b,outerRadius:g},(e=>e.arcs.map(((n,r)=>{const{x:s}=n.data,u=w(n.data),h=n.data.__labels?.[l.categories[0]]?n.data.__labels?.[l.categories[0]]:"",[f,d]=e.path.centroid(n),p=n.endAngle-n.startAngle>=.1,g=e.path(n)||"";return(0,t.createElement)("g",{key:`arc-${s}-${r}`},(0,t.createElement)("path",{d:g,fill:o[r],stroke:c.hasPathStroke?c.pathStrokeColor:"",strokeWidth:c.hasPathStroke?c.pathStrokeWidth:0,fillOpacity:O&&a.active&&a.deemphasizeSiblings&&n.data!==O?a.deemphasizeOpacity:1,onMouseLeave:()=>{A=window.setTimeout((()=>{C()}),300)},onMouseMove:e=>{A&&clearTimeout(A);const t=ss(e),i={...n.data,color:o[r]};T({tooltipData:i,tooltipTop:t.y,tooltipLeft:t.x})}}),p&&(0,t.createElement)("text",Ku({},Xn(i),{x:f,y:d,dy:".33em",fill:Ie(o[r]),fillOpacity:O&&a.active&&a.deemphasizeSiblings&&n.data!==O?a.deemphasizeOpacity:1}),h||`${Zn(u,s,i,null)}`))})))),c.showCategoryLabels&&(0,t.createElement)(Gu,{data:x,pieValue:w,pieSortValues:b,innerRadius:g+20,outerRadius:g+40},(e=>e.arcs.map(((n,r)=>{const{x:o}=n.data,s=_(n.data),[l,c]=e.path.centroid(n),u=n.endAngle-n.startAngle>=.1,h=e.path(n)||"";return(0,t.createElement)("g",{key:`arc-${o}-${r}`},(0,t.createElement)("path",{d:h,fill:"transparent",fillOpacity:O&&a.active&&a.deemphasizeSiblings&&n.data!==O?a.deemphasizeOpacity:1,onMouseLeave:()=>{A=window.setTimeout((()=>{C()}),300)},onMouseMove:e=>{A&&clearTimeout(A);const t=ss(e);T({tooltipData:n.data,tooltipTop:t.y,tooltipLeft:t.x})}}),u&&(0,t.createElement)("text",Ku({},Xn(i),{x:l,y:c,dy:".33em",fill:"#000",fillOpacity:O&&a.active&&a.deemphasizeSiblings&&n.data!==O?a.deemphasizeOpacity:1}),s),"// create a line from the text element to the inner radius of the arc")})))))),s.active&&(0,t.createElement)(fl,{legend:s,theme:r.theme},(0,t.createElement)(Ns,{style:{display:"flex",flexFlow:`${s.orientation} wrap`},shape:s.markerStyle,shapeWidth:12,shapeHeight:12,scale:k,domain:s.categories.length>0?s.categories:k.domain(),direction:s.orientation,labelMargin:"0 15px 0 0"})),E&&O&&a.active&&(0,t.createElement)(Nl,{top:S,left:M,tooltip:a,theme:r.theme},(0,t.createElement)(t.Fragment,null,a.headerActive&&(0,t.createElement)("div",{style:{marginBottom:"10px"}},(0,t.createElement)("strong",null,er({x:_(O),category:l.categories[0]},a)))),(0,t.createElement)("div",null),(0,t.createElement)("div",{dangerouslySetInnerHTML:{__html:O.__tooltips?.[l.categories[0]]?O.__tooltips?.[l.categories[0]]:tr({x:_(O),y:w(O),category:l.categories[0],color:O.color},a)}})))},Zu=e=>{const{fill:t,stroke:n,strokeWidth:r,strokeOpacity:i}=e;return{fill:t,stroke:n,strokeWidth:r,strokeOpacity:i}};var Ju=["x","x0","x1","y","y1","y0","yScale","data","defined","className","curve","innerRef","children"];function Qu(){return Qu=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,Ju),v=Bu({x:t,x0:n,x1:r,defined:f,curve:p});return null==s?v.y0(l.range()[0]):Gs(v.y0,s),i&&!a&&Gs(v.y1,i),a&&!i&&Gs(v.y1,a),y?o().createElement(o().Fragment,null,y({path:v})):o().createElement("path",Qu({ref:g,className:rr()("visx-area-closed",d),d:v(u)||""},m))}var th=["children","data","x","y","fill","className","curve","innerRef","defined"];function nh(){return nh=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,th),g=function(e){var t=void 0===e?{}:e,n=t.x,r=t.y,i=t.defined,o=t.curve,a=Uu();return n&&Gs(a.x,n),r&&Gs(a.y,r),i&&a.defined(i),o&&a.curve(o),a}({x:i,y:a,defined:d,curve:u});return t?o().createElement(o().Fragment,null,t({path:g})):o().createElement("path",nh({ref:h,className:rr()("visx-linepath",c),d:g(r)||"",fill:l,strokeLinecap:"round"},p))}function ih(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 oh(e){this._context=e}function ah(e){return new oh(e)}function sh(){}function lh(e){this._context=e}function ch(e){return new lh(e)}function uh(e){this._context=e}function hh(e){return new uh(e)}function fh(e,t){this._context=e,this._t=t}function dh(e){return new fh(e,.5)}function ph(e){return new fh(e,0)}function gh(e){return new fh(e,1)}function yh(e,t){this._basis=new oh(e),this._beta=t}oh.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:ih(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&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:ih(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}},lh.prototype={areaStart:sh,areaEnd:sh,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)}},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:ih(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}},uh.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||0!==this._line&&3===this._point)&&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:ih(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}},fh.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0=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)}}this._x=e,this._y=t}},yh.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,n=e.length-1;if(n>0)for(var r,i=e[0],o=t[0],a=e[n]-i,s=t[n]-o,l=-1;++l<=n;)r=l/n,this._basis.point(this._beta*e[l]+(1-this._beta)*(i+r*a),this._beta*t[l]+(1-this._beta)*(o+r*s));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};const mh=function e(t){function n(e){return 1===t?new oh(e):new yh(e,t)}return n.beta=function(t){return e(+t)},n}(.85);function vh(e){this._context=e}function xh(e){return new vh(e)}function bh(e,t,n){e._context.bezierCurveTo(e._x1+e._k*(e._x2-e._x0),e._y1+e._k*(e._y2-e._y0),e._x2+e._k*(e._x1-t),e._y2+e._k*(e._y1-n),e._x2,e._y2)}function _h(e,t){this._context=e,this._k=(1-t)/6}vh.prototype={areaStart:sh,areaEnd:sh,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))}},_h.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:bh(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&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,this._x1=e,this._y1=t;break;case 2:this._point=3;default:bh(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const wh=function e(t){function n(e){return new _h(e,t)}return n.tension=function(t){return e(+t)},n}(0);function kh(e,t){this._context=e,this._k=(1-t)/6}kh.prototype={areaStart:sh,areaEnd:sh,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:bh(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const Eh=function e(t){function n(e){return new kh(e,t)}return n.tension=function(t){return e(+t)},n}(0);function Mh(e,t){this._context=e,this._k=(1-t)/6}Mh.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&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,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:bh(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const Sh=function e(t){function n(e){return new Mh(e,t)}return n.tension=function(t){return e(+t)},n}(0);function Oh(e,t,n){var r=e._x1,i=e._y1,o=e._x2,a=e._y2;if(e._l01_a>Ou){var s=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,l=3*e._l01_a*(e._l01_a+e._l12_a);r=(r*s-e._x0*e._l12_2a+e._x2*e._l01_2a)/l,i=(i*s-e._y0*e._l12_2a+e._y2*e._l01_2a)/l}if(e._l23_a>Ou){var c=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,u=3*e._l23_a*(e._l23_a+e._l12_a);o=(o*c+e._x1*e._l23_2a-t*e._l12_2a)/u,a=(a*c+e._y1*e._l23_2a-n*e._l12_2a)/u}e._context.bezierCurveTo(r,i,o,a,e._x2,e._y2)}function Ch(e,t){this._context=e,this._alpha=t}Ch.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}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;default:Oh(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const Th=function e(t){function n(e){return t?new Ch(e,t):new _h(e,0)}return n.alpha=function(t){return e(+t)},n}(.5);function Ah(e,t){this._context=e,this._alpha=t}Ah.prototype={areaStart:sh,areaEnd:sh,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:Oh(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const Nh=function e(t){function n(e){return t?new Ah(e,t):new kh(e,0)}return n.alpha=function(t){return e(+t)},n}(.5);function Ph(e,t){this._context=e,this._alpha=t}Ph.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:Oh(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const Rh=function e(t){function n(e){return t?new Ph(e,t):new Mh(e,0)}return n.alpha=function(t){return e(+t)},n}(.5);function Dh(e){return e<0?-1:1}function jh(e,t,n){var r=e._x1-e._x0,i=t-e._x1,o=(e._y1-e._y0)/(r||i<0&&-0),a=(n-e._y1)/(i||r<0&&-0),s=(o*i+a*r)/(r+i);return(Dh(o)+Dh(a))*Math.min(Math.abs(o),Math.abs(a),.5*Math.abs(s))||0}function Lh(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function Fh(e,t,n){var r=e._x0,i=e._y0,o=e._x1,a=e._y1,s=(o-r)/3;e._context.bezierCurveTo(r+s,i+s*t,o-s,a-s*n,o,a)}function $h(e){this._context=e}function zh(e){this._context=new Ih(e)}function Ih(e){this._context=e}function Wh(e){return new $h(e)}function Uh(e){return new zh(e)}function Hh(e){this._context=e}function Yh(e){var t,n,r=e.length-1,i=new Array(r),o=new Array(r),a=new Array(r);for(i[0]=0,o[0]=2,a[0]=e[0]+2*e[1],t=1;t=0;--t)i[t]=(a[t]-i[t+1])/o[t];for(o[r-1]=(e[r]+i[r-1])/2,t=0;t=Vh?i*=10:o>=qh?i*=5:o>=Gh&&(i*=2),t0?e>1?Ve((function(t){t.setTime(Math.floor(t/e)*e)}),(function(t,n){t.setTime(+t+n*e)}),(function(t,n){return(n-t)/e})):Xh:null};const Zh=Xh;function Jh(e,t,n,r,i,o){const a=[[qo,1,qe],[qo,5,5e3],[qo,15,15e3],[qo,30,3e4],[o,1,Ge],[o,5,3e5],[o,15,9e5],[o,30,18e5],[i,1,Ke],[i,3,108e5],[i,6,216e5],[i,12,432e5],[r,1,Xe],[r,2,1728e5],[n,1,Ze],[t,1,2592e6],[t,3,7776e6],[e,1,Je]];function s(t,n,r){const i=Math.abs(n-t)/r,o=function(e){let t=e,n=e;function r(e,t,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r>>1;n(e[o],t)<0?r=o+1:i=o}return r}return 1===e.length&&(t=(t,n)=>e(t)-n,n=function(e){return(t,n)=>function(e,t){return et?1:e>=t?0:NaN}(e(t),n)}(e)),{left:r,center:function(e,n,i,o){null==i&&(i=0),null==o&&(o=e.length);const a=r(e,n,i,o-1);return a>i&&t(e[a-1],n)>-t(e[a],n)?a-1:a},right:function(e,t,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r>>1;n(e[o],t)>0?i=o:r=o+1}return r}}}((([,,e])=>e)).right(a,i);if(o===a.length)return e.every(Kh(t/Je,n/Je,r));if(0===o)return Zh.every(Math.max(Kh(t,n,r),1));const[s,l]=a[i/a[o-1][2][e.toLowerCase(),t])))}function mf(e,t,n){var r=uf.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function vf(e,t,n){var r=uf.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function xf(e,t,n){var r=uf.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function bf(e,t,n){var r=uf.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function _f(e,t,n){var r=uf.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function wf(e,t,n){var r=uf.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function kf(e,t,n){var r=uf.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function Ef(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 Mf(e,t,n){var r=uf.exec(t.slice(n,n+1));return r?(e.q=3*r[0]-3,n+r[0].length):-1}function Sf(e,t,n){var r=uf.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function Of(e,t,n){var r=uf.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function Cf(e,t,n){var r=uf.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function Tf(e,t,n){var r=uf.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function Af(e,t,n){var r=uf.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function Nf(e,t,n){var r=uf.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function Pf(e,t,n){var r=uf.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function Rf(e,t,n){var r=uf.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function Df(e,t,n){var r=hf.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function jf(e,t,n){var r=uf.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function Lf(e,t,n){var r=uf.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function Ff(e,t){return df(e.getDate(),t,2)}function $f(e,t){return df(e.getHours(),t,2)}function zf(e,t){return df(e.getHours()%12||12,t,2)}function If(e,t){return df(1+vt.count(bt(e),e),t,3)}function Wf(e,t){return df(e.getMilliseconds(),t,3)}function Uf(e,t){return Wf(e,t)+"000"}function Hf(e,t){return df(e.getMonth()+1,t,2)}function Yf(e,t){return df(e.getMinutes(),t,2)}function Bf(e,t){return df(e.getSeconds(),t,2)}function Vf(e){var t=e.getDay();return 0===t?7:t}function qf(e,t){return df(ut.count(bt(e)-1,e),t,2)}function Gf(e){var t=e.getDay();return t>=4||0===t?pt(e):pt.ceil(e)}function Kf(e,t){return e=Gf(e),df(pt.count(bt(e),e)+(4===bt(e).getDay()),t,2)}function Xf(e){return e.getDay()}function Zf(e,t){return df(ht.count(bt(e)-1,e),t,2)}function Jf(e,t){return df(e.getFullYear()%100,t,2)}function Qf(e,t){return df((e=Gf(e)).getFullYear()%100,t,2)}function ed(e,t){return df(e.getFullYear()%1e4,t,4)}function td(e,t){var n=e.getDay();return df((e=n>=4||0===n?pt(e):pt.ceil(e)).getFullYear()%1e4,t,4)}function nd(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+df(t/60|0,"0",2)+df(t%60,"0",2)}function rd(e,t){return df(e.getUTCDate(),t,2)}function id(e,t){return df(e.getUTCHours(),t,2)}function od(e,t){return df(e.getUTCHours()%12||12,t,2)}function ad(e,t){return df(1+lt.count(wt(e),e),t,3)}function sd(e,t){return df(e.getUTCMilliseconds(),t,3)}function ld(e,t){return sd(e,t)+"000"}function cd(e,t){return df(e.getUTCMonth()+1,t,2)}function ud(e,t){return df(e.getUTCMinutes(),t,2)}function hd(e,t){return df(e.getUTCSeconds(),t,2)}function fd(e){var t=e.getUTCDay();return 0===t?7:t}function dd(e,t){return df(et.count(wt(e)-1,e),t,2)}function pd(e){var t=e.getUTCDay();return t>=4||0===t?it(e):it.ceil(e)}function gd(e,t){return e=pd(e),df(it.count(wt(e),e)+(4===wt(e).getUTCDay()),t,2)}function yd(e){return e.getUTCDay()}function md(e,t){return df(tt.count(wt(e)-1,e),t,2)}function vd(e,t){return df(e.getUTCFullYear()%100,t,2)}function xd(e,t){return df((e=pd(e)).getUTCFullYear()%100,t,2)}function bd(e,t){return df(e.getUTCFullYear()%1e4,t,4)}function _d(e,t){var n=e.getUTCDay();return df((e=n>=4||0===n?it(e):it.ceil(e)).getUTCFullYear()%1e4,t,4)}function wd(){return"+0000"}function kd(){return"%"}function Ed(e){return+e}function Md(e){return Math.floor(+e/1e3)}function Sd(e){return new Date(e)}function Od(e){return e instanceof Date?+e:+new Date(+e)}function Cd(e,t,n,r,i,o,a,s,l,c){var u=Da(),h=u.invert,f=u.domain,d=c(".%L"),p=c(":%S"),g=c("%I:%M"),y=c("%I %p"),m=c("%a %d"),v=c("%b %d"),x=c("%B"),b=c("%Y");function _(e){return(l(e)=12)]},q:function(e){return 1+~~(e.getMonth()/3)},Q:Ed,s:Md,S:Bf,u:Vf,U:qf,V:Kf,w:Xf,W:Zf,x:null,X:null,y:Jf,Y:ed,Z:nd,"%":kd},b={a:function(e){return a[e.getUTCDay()]},A:function(e){return o[e.getUTCDay()]},b:function(e){return l[e.getUTCMonth()]},B:function(e){return s[e.getUTCMonth()]},c:null,d:rd,e:rd,f:ld,g:xd,G:_d,H:id,I:od,j:ad,L:sd,m:cd,M:ud,p:function(e){return i[+(e.getUTCHours()>=12)]},q:function(e){return 1+~~(e.getUTCMonth()/3)},Q:Ed,s:Md,S:hd,u:fd,U:dd,V:gd,w:yd,W:md,x:null,X:null,y:vd,Y:bd,Z:wd,"%":kd},_={a:function(e,t,n){var r=d.exec(t.slice(n));return r?(e.w=p.get(r[0].toLowerCase()),n+r[0].length):-1},A:function(e,t,n){var r=h.exec(t.slice(n));return r?(e.w=f.get(r[0].toLowerCase()),n+r[0].length):-1},b:function(e,t,n){var r=m.exec(t.slice(n));return r?(e.m=v.get(r[0].toLowerCase()),n+r[0].length):-1},B:function(e,t,n){var r=g.exec(t.slice(n));return r?(e.m=y.get(r[0].toLowerCase()),n+r[0].length):-1},c:function(e,n,r){return E(e,t,n,r)},d:Of,e:Of,f:Rf,g:kf,G:wf,H:Tf,I:Tf,j:Cf,L:Pf,m:Sf,M:Af,p:function(e,t,n){var r=c.exec(t.slice(n));return r?(e.p=u.get(r[0].toLowerCase()),n+r[0].length):-1},q:Mf,Q:jf,s:Lf,S:Nf,u:vf,U:xf,V:bf,w:mf,W:_f,x:function(e,t,r){return E(e,n,t,r)},X:function(e,t,n){return E(e,r,t,n)},y:kf,Y:wf,Z:Ef,"%":Df};function w(e,t){return function(n){var r,i,o,a=[],s=-1,l=0,c=e.length;for(n instanceof Date||(n=new Date(+n));++s53)return null;"w"in o||(o.w=1),"Z"in o?(i=(r=of(af(o.y,0,1))).getUTCDay(),r=i>4||0===i?tt.ceil(r):tt(r),r=lt.offset(r,7*(o.V-1)),o.y=r.getUTCFullYear(),o.m=r.getUTCMonth(),o.d=r.getUTCDate()+(o.w+6)%7):(i=(r=rf(af(o.y,0,1))).getDay(),r=i>4||0===i?ht.ceil(r):ht(r),r=vt.offset(r,7*(o.V-1)),o.y=r.getFullYear(),o.m=r.getMonth(),o.d=r.getDate()+(o.w+6)%7)}else("W"in o||"U"in o)&&("w"in o||(o.w="u"in o?o.u%7:"W"in o?1:0),i="Z"in o?of(af(o.y,0,1)).getUTCDay():rf(af(o.y,0,1)).getDay(),o.m=0,o.d="W"in o?(o.w+6)%7+7*o.W-(i+5)%7:o.w+7*o.U-(i+6)%7);return"Z"in o?(o.H+=o.Z/100|0,o.M+=o.Z%100,of(o)):rf(o)}}function E(e,t,n,r){for(var i,o,a=0,s=t.length,l=n.length;a=l)return-1;if(37===(i=t.charCodeAt(a++))){if(i=t.charAt(a++),!(o=_[i in cf?t.charAt(a++):i])||(r=o(e,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}return x.x=w(n,x),x.X=w(r,x),x.c=w(t,x),b.x=w(n,b),b.X=w(r,b),b.c=w(t,b),{format:function(e){var t=w(e+="",x);return t.toString=function(){return e},t},parse:function(e){var t=k(e+="",!1);return t.toString=function(){return e},t},utcFormat:function(e){var t=w(e+="",b);return t.toString=function(){return e},t},utcParse:function(e){var t=k(e+="",!0);return t.toString=function(){return e},t}}}({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"]}),lf=sf.format,sf.parse,sf.utcFormat,sf.utcParse;var Ad=aa("domain","range","reverse","clamp","interpolate","nice","round");function Nd(e){return Ad(Td(),e)}function Pd(e){return function(){return e}}function Rd(e){return e[0]}function Dd(e){return e[1]}function jd(){this._=null}function Ld(e){e.U=e.C=e.L=e.R=e.P=e.N=null}function Fd(e,t){var n=t,r=t.R,i=n.U;i?i.L===n?i.L=r:i.R=r:e._=r,r.U=i,n.U=r,n.R=r.L,n.R&&(n.R.U=n),r.L=n}function $d(e,t){var n=t,r=t.L,i=n.U;i?i.L===n?i.L=r:i.R=r:e._=r,r.U=i,n.U=r,n.L=r.R,n.L&&(n.L.U=n),r.R=n}function zd(e){for(;e.L;)e=e.L;return e}jd.prototype={constructor:jd,insert:function(e,t){var n,r,i;if(e){if(t.P=e,t.N=e.N,e.N&&(e.N.P=t),e.N=t,e.R){for(e=e.R;e.L;)e=e.L;e.L=t}else e.R=t;n=e}else this._?(e=zd(this._),t.P=null,t.N=e,e.P=e.L=t,n=e):(t.P=t.N=null,this._=t,n=null);for(t.L=t.R=null,t.U=n,t.C=!0,e=t;n&&n.C;)n===(r=n.U).L?(i=r.R)&&i.C?(n.C=i.C=!1,r.C=!0,e=r):(e===n.R&&(Fd(this,n),n=(e=n).U),n.C=!1,r.C=!0,$d(this,r)):(i=r.L)&&i.C?(n.C=i.C=!1,r.C=!0,e=r):(e===n.L&&($d(this,n),n=(e=n).U),n.C=!1,r.C=!0,Fd(this,r)),n=e.U;this._.C=!1},remove:function(e){e.N&&(e.N.P=e.P),e.P&&(e.P.N=e.N),e.N=e.P=null;var t,n,r,i=e.U,o=e.L,a=e.R;if(n=o?a?zd(a):o:a,i?i.L===e?i.L=n:i.R=n:this._=n,o&&a?(r=n.C,n.C=e.C,n.L=o,o.U=n,n!==a?(i=n.U,n.U=e.U,e=n.R,i.L=e,n.R=a,a.U=n):(n.U=i,i=n,e=n.R)):(r=e.C,e=n),e&&(e.U=i),!r)if(e&&e.C)e.C=!1;else{do{if(e===this._)break;if(e===i.L){if((t=i.R).C&&(t.C=!1,i.C=!0,Fd(this,i),t=i.R),t.L&&t.L.C||t.R&&t.R.C){t.R&&t.R.C||(t.L.C=!1,t.C=!0,$d(this,t),t=i.R),t.C=i.C,i.C=t.R.C=!1,Fd(this,i),e=this._;break}}else if((t=i.L).C&&(t.C=!1,i.C=!0,$d(this,i),t=i.L),t.L&&t.L.C||t.R&&t.R.C){t.L&&t.L.C||(t.R.C=!1,t.C=!0,Fd(this,t),t=i.L),t.C=i.C,i.C=t.L.C=!1,$d(this,i),e=this._;break}t.C=!0,e=i,i=i.U}while(!e.C);e&&(e.C=!1)}}};const Id=jd;function Wd(e,t,n,r){var i=[null,null],o=hp.push(i)-1;return i.left=e,i.right=t,n&&Hd(i,e,t,n),r&&Hd(i,t,e,r),cp[e.index].halfedges.push(o),cp[t.index].halfedges.push(o),i}function Ud(e,t,n){var r=[t,n];return r.left=e,r}function Hd(e,t,n,r){e[0]||e[1]?e.left===n?e[1]=r:e[0]=r:(e[0]=r,e.left=t,e.right=n)}function Yd(e,t,n,r,i){var o,a=e[0],s=e[1],l=a[0],c=a[1],u=0,h=1,f=s[0]-l,d=s[1]-c;if(o=t-l,f||!(o>0)){if(o/=f,f<0){if(o0){if(o>h)return;o>u&&(u=o)}if(o=r-l,f||!(o<0)){if(o/=f,f<0){if(o>h)return;o>u&&(u=o)}else if(f>0){if(o0)){if(o/=d,d<0){if(o0){if(o>h)return;o>u&&(u=o)}if(o=i-c,d||!(o<0)){if(o/=d,d<0){if(o>h)return;o>u&&(u=o)}else if(d>0){if(o0||h<1)||(u>0&&(e[0]=[l+u*f,c+u*d]),h<1&&(e[1]=[l+h*f,c+h*d]),!0)}}}}}function Bd(e,t,n,r,i){var o=e[1];if(o)return!0;var a,s,l=e[0],c=e.left,u=e.right,h=c[0],f=c[1],d=u[0],p=u[1],g=(h+d)/2,y=(f+p)/2;if(p===f){if(g=r)return;if(h>d){if(l){if(l[1]>=i)return}else l=[g,n];o=[g,i]}else{if(l){if(l[1]1)if(h>d){if(l){if(l[1]>=i)return}else l=[(n-s)/a,n];o=[(i-s)/a,i]}else{if(l){if(l[1]=r)return}else l=[t,a*t+s];o=[r,a*r+s]}else{if(l){if(l[0]=-dp)){var d=l*l+c*c,p=u*u+h*h,g=(h*d-c*p)/f,y=(l*p-u*d)/f,m=Xd.pop()||new Zd;m.arc=e,m.site=i,m.x=g+a,m.y=(m.cy=y+s)+Math.sqrt(g*g+y*y),e.circle=m;for(var v=null,x=up._;x;)if(m.yfp)s=s.L;else{if(!((i=o-sp(s,a))>fp)){r>-fp?(t=s.P,n=s):i>-fp?(t=s,n=s.N):t=n=s;break}if(!s.R){t=s;break}s=s.R}!function(e){cp[e.index]={site:e,halfedges:[]}}(e);var l=np(e);if(lp.insert(t,l),t||n){if(t===n)return Qd(t),n=np(t.site),lp.insert(l,n),l.edge=n.edge=Wd(t.site,l.site),Jd(t),void Jd(n);if(n){Qd(t),Qd(n);var c=t.site,u=c[0],h=c[1],f=e[0]-u,d=e[1]-h,p=n.site,g=p[0]-u,y=p[1]-h,m=2*(f*y-d*g),v=f*f+d*d,x=g*g+y*y,b=[(y*v-d*x)/m+u,(f*x-g*v)/m+h];Hd(n.edge,c,p,b),l.edge=Wd(c,e,null,b),n.edge=Wd(e,p,null,b),Jd(t),Jd(n)}else l.edge=Wd(t.site,l.site)}}function ap(e,t){var n=e.site,r=n[0],i=n[1],o=i-t;if(!o)return r;var a=e.P;if(!a)return-1/0;var s=(n=a.site)[0],l=n[1],c=l-t;if(!c)return s;var u=s-r,h=1/o-1/c,f=u/c;return h?(-f+Math.sqrt(f*f-2*h*(u*u/(-2*c)-l+c/2+i-o/2)))/h+r:(r+s)/2}function sp(e,t){var n=e.N;if(n)return ap(n,t);var r=e.site;return r[1]===t?r[0]:1/0}var lp,cp,up,hp,fp=1e-6,dp=1e-12;function pp(e,t,n){return(e[0]-n[0])*(t[1]-e[1])-(e[0]-t[0])*(n[1]-e[1])}function gp(e,t){return t[1]-e[1]||t[0]-e[0]}function yp(e,t){var n,r,i,o=e.sort(gp).pop();for(hp=[],cp=new Array(e.length),lp=new Id,up=new Id;;)if(i=Kd,o&&(!i||o[1]fp||Math.abs(i[0][1]-i[1][1])>fp)||delete hp[o]}(a,s,l,c),function(e,t,n,r){var i,o,a,s,l,c,u,h,f,d,p,g,y=cp.length,m=!0;for(i=0;ifp||Math.abs(g-f)>fp)&&(l.splice(s,0,hp.push(Ud(a,d,Math.abs(p-e)fp?[e,Math.abs(h-e)fp?[Math.abs(f-r)fp?[n,Math.abs(h-n)fp?[Math.abs(f-t)=s)return null;var l=e-i.site[0],c=t-i.site[1],u=l*l+c*c;do{i=o.cells[r=a],a=null,i.halfedges.forEach((function(n){var r=o.edges[n],s=r.left;if(s!==i.site&&s||(s=r.right)){var l=e-s[0],c=t-s[1],h=l*l+c*c;h=0||(i[n]=e[n]);return i}(e,vp);if(!t)return null;var a="M"+t.join("L")+"Z";return r?o().createElement(o().Fragment,null,r({path:a,polygon:t})):o().createElement("path",xp({className:rr()("visx-voronoi-polygon",n),d:a},i))}function _p(e,t){let n,r;if(void 0===t)for(const t of e)null!=t&&(void 0===n?t>=t&&(n=r=t):(n>t&&(n=t),r=o&&(n=r=o):(n>o&&(n=o),r{const{data:n,config:r}=(0,t.useContext)(De),{dependentAxis:i,independentAxis:o,line:a,layout:s,colors:l,nodes:c,dataRender:u,tooltip:h,labels:f,legend:d,plotBands:p,voronoi:g}=r,y=(0,t.useRef)(null);let m=Le(s.parentClass,y);const{chartWidth:v,innerWidth:x,innerHeight:b}=He(m,s);let _=(0,t.useMemo)((()=>Ue(o.tickCount||5,v,s.width)),[o.tickCount,v,s.width]);const w=(0,t.useMemo)((()=>n.reduce(((e,t)=>e.concat(t)),[])),[n]);w.sort(((e,t)=>"ascending"===u.sortOrder?"time"===o.scale?ls(We(e[u.x],u.xFormat),We(t[u.x],u.xFormat)):ls(e[u.sortKey],t[u.sortKey]):"descending"===u.sortOrder?cs(e[u.sortKey],t[u.sortKey]):0));const k=(0,t.useMemo)((()=>w.map((e=>u.categories.map(((t,n)=>{if(e[t])return{x:e.x,y:e[t],category:t,label:e.__labels?.[t]?e.__labels[t]:"",tooltip:e.__tooltips?.[t]?e.__tooltips[t]:"",color:l[n]}})))).flat().filter(Boolean)),[u,w]),E=(0,t.useCallback)((e=>"time"===o.scale?We(e[u.x],u.xFormat):e[u.x]),[u,o]),M=(0,t.useCallback)((e=>e[u.y]),[u]),S=(0,t.useMemo)((()=>Nd({domain:_p(w,E),range:[0,x]})),[x,w,E]),O=(0,t.useMemo)((()=>Ja({domain:o.domain?o.domain:[0,Ll(w,E)||0],range:[0,x]})),[x,o,w,E]),C="time"===o.scale?S:O,T=(0,t.useMemo)((()=>Ja({domain:i.domain?i.domain:[0,Ll(w,M)||0],range:[b,0],nice:!0})),[b,w,i,M]),A=(0,t.useMemo)((()=>es({domain:u.categories,range:l})),[u.categories,l]),N=(0,t.useMemo)((()=>mp({x:e=>C(E(e)),y:e=>T(M(e)),width:x,height:b})(k)),[x,b,C,T,k,E,M]),P=a.interpolation,R=Gn(i,T,s.theme),D=Gn(o,C,s.theme),j=Kn(i,T,x,b-s.padding.top),L=Kn(o,C,x,b),F=Zu(g),{tooltipData:$,tooltipLeft:z=0,tooltipTop:I=0,tooltipOpen:W,showTooltip:U,hideTooltip:H}=rs();let Y=0;const B=(0,t.useCallback)((e=>{if(Y&&clearTimeout(Y),!y.current)return;const t=ss(y.current,e);if(!t)return;const n=N.find(t.x-s.padding.left,t.y-s.padding.top);n&&U({tooltipLeft:C(E(n.data)),tooltipTop:T(M(n.data)),tooltipData:n.data})}),[C,T,U,N,M,E,s,Y]),V=(0,t.useCallback)((()=>{Y=window.setTimeout((()=>{H()}),300)}),[H]);return(0,t.createElement)("div",{style:{position:"relative"}},(0,t.createElement)("svg",{width:v,height:s.height,ref:y},(0,t.createElement)(lr,{top:s.padding.top,left:s.padding.left,onMouseMove:B,onMouseLeave:V},p.active&&(0,t.createElement)(Yp,{plotBands:p,independentScale:C,innerHeight:b}),(0,t.createElement)(Sr,j),(0,t.createElement)(kr,L),g.active&&N.polygons().map(((e,n)=>(0,t.createElement)(bp,wp({},F,{key:`polygon-${n}`,polygon:e,fillOpacity:$===e.data?.1:0})))),i.active&&(0,t.createElement)(ii,R),o.active&&(0,t.createElement)(li,wp({},D,{top:b,numTicks:_})),u.categories.map(((n,r)=>{const i=w.filter((e=>e[n]||""!==e[n]));return(0,t.createElement)("g",{key:`line-group-${r}`},a.showArea&&(0,t.createElement)(eh,{key:`area-${r}`,data:i,x:e=>C(E(e))??0,y:e=>T(e[n])??0,yScale:T,strokeWidth:0,fill:l[r],fillOpacity:a.areaFillOpacity,curve:e[P]}),(0,t.createElement)(rh,{key:`line-${r}`,data:i,x:e=>C(E(e)),y:e=>T(e[n]),strokeWidth:$&&h.active&&h.deemphasizeSiblings&&$.category===n?a.strokeWidth+1:a.strokeWidth,stroke:l[r],strokeOpacity:$&&h.active&&h.deemphasizeSiblings&&$.category!==n?h.deemphasizeOpacity:1,curve:e[P],strokeDasharray:a.strokeDasharray}),a.showPoints&&i?.map(((e,i)=>(0,t.createElement)(kp,{key:i,tabIndex:0,r:c.pointSize,cx:C(E(e)),cy:T(e[n]),stroke:l[r],fill:"inherit"===c.pointFill?l[r]:"white",fillOpacity:$&&h.active&&h.deemphasizeSiblings&&$.category!==n?h.deemphasizeOpacity:1,onBlur:()=>{Y=window.setTimeout((()=>{H()}),300)},onFocus:()=>{Y&&clearTimeout(Y),U({tooltipLeft:C(E(e)),tooltipTop:T(e[n]),tooltipData:{x:e.x,y:e[n],category:n,color:l[r]}})}}))),f.active&&i?.map(((e,o)=>{const a=e.__labels?.[n]?e.__labels[n]:"";return(0,t.createElement)("text",wp({key:`line-group-${o}-label`},Xn(f),{x:C(E(e)),y:T(e[n]),dy:f.labelPositionDY,dx:f.labelPositionDX,fill:"inherit"===f.color?l[r]:f.color}),a,a||!f.showFirstLastPointsOnly||0!==o&&o!==i.length-1?"":`${Zn(e[n],n,f,null)}`,!a&&!f.showFirstLastPointsOnly&&`${Zn(e[n],n,f,null)}`)})),$&&h.active&&(0,t.createElement)("g",null,(0,t.createElement)(Dl,{cx:z,cy:I,r:c.pointSize+2,fill:A($.category||""),fillOpacity:a.showPoints?.1:1,stroke:A($.category||""),strokeOpacity:.1,strokeWidth:2,pointerEvents:"none"}),(0,t.createElement)(Dl,{cx:z,cy:I,r:c.pointSize+1,fill:"transparent",stroke:"white",strokeWidth:2,pointerEvents:"none"})))})))),d.active&&(0,t.createElement)(fl,{legend:d,theme:s.theme,layoutWidth:s.width,chartWidth:v},(0,t.createElement)(Ns,{style:{display:"flex",flexFlow:`${d.orientation} wrap`},shape:d.markerStyle,shapeWidth:12,shapeHeight:12,scale:es({domain:u.categories,range:l}),domain:d.categories.length>0?d.categories:A.domain(),direction:d.orientation,labelMargin:"0 15px 0 0"})),W&&$&&h.active&&(0,t.createElement)(Nl,{top:I,left:z,tooltip:h,theme:s.theme},(0,t.createElement)(t.Fragment,null,h.headerActive&&(0,t.createElement)("div",{style:{marginBottom:"10px"}},(0,t.createElement)("strong",null,er({x:E($),category:$.category},h)))),(0,t.createElement)("div",{dangerouslySetInnerHTML:{__html:$.tooltip?$.tooltip:tr({x:E($),y:M($),category:$.category,color:A($.category||"")},h)}})))};function Mp(){return Mp=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{data:e,config:n}=(0,t.useContext)(De),{dependentAxis:r,independentAxis:i,layout:o,colors:a,nodes:s,dataRender:l,tooltip:c,labels:u,legend:h,voronoi:f,regression:d}=n,p=(0,t.useRef)(null);let g=Le(o.parentClass,p);const{chartWidth:y,innerWidth:m,innerHeight:v}=He(g,o);let x=(0,t.useMemo)((()=>Ue(i.tickCount||5,y,o.width)),[i.tickCount,y,o.width]);const b=(0,t.useMemo)((()=>e.reduce(((e,t)=>e.concat(t)),[])),[e]),_=Sp.regressionLinear().x((e=>e.x)).y((e=>e.y)),w=(0,t.useMemo)((()=>b.map((e=>l.categories.map((t=>{if(e[t])return{x:e.x,y:e[t],category:t,label:e.__labels?.[t]?e.__labels[t]:"",tooltip:e.__tooltips?.[t]?e.__tooltips[t]:""}})))).flat().filter(Boolean)),[l,b]),k=(0,t.useMemo)((()=>_(w)),[w,_]),E=(0,t.useCallback)((e=>"time"===i.scale?We(e[l.x],l.xFormat):e[l.x]),[l,i]),M=(0,t.useCallback)((e=>e[l.y]),[l.y]),S=(0,t.useMemo)((()=>Nd({domain:_p(b,E),range:[0,m]})),[m,b,E]),O=(0,t.useMemo)((()=>Ja({domain:i.domain?i.domain:[0,Ll(b,E)||0],range:[0,m]})),[m,i,b,E]),C="time"===i.scale?S:O,T=(0,t.useMemo)((()=>Ja({domain:r.domain?r.domain:[0,Ll(b,M)||0],range:[v,0],nice:!0})),[v,b,r,M]),A=(0,t.useMemo)((()=>es({domain:l.categories,range:a})),[l.categories,a]),N=(0,t.useMemo)((()=>mp({x:e=>C(E(e)),y:e=>T(M(e)),width:m,height:v})(w)),[m,v,C,T,w,E,M]),P=Gn(r,T,o.theme),R=Gn(i,C,o.theme),D=Kn(r,T,m,v-o.padding.top),j=Kn(i,C,m,v),L=Zu(f),{tooltipData:F,tooltipLeft:$=0,tooltipTop:z=0,tooltipOpen:I,showTooltip:W,hideTooltip:U}=rs();let H=0;const Y=(0,t.useCallback)((e=>{if(H&&clearTimeout(H),!p.current)return;const t=ss(p.current,e);if(!t)return;const n=N.find(t.x-o.padding.left,t.y-o.padding.top);n&&W({tooltipLeft:C(E(n.data)),tooltipTop:T(M(n.data)),tooltipData:n.data})}),[C,T,W,N,M,E,o,H]),B=(0,t.useCallback)((()=>{H=window.setTimeout((()=>{U()}),300)}),[U]);return(0,t.createElement)("div",{style:{position:"relative"}},(0,t.createElement)("svg",{width:y,height:o.height,ref:p},(0,t.createElement)(lr,{top:o.padding.top,left:o.padding.left,onMouseMove:Y,onMouseLeave:B},(0,t.createElement)(Sr,D),(0,t.createElement)(kr,j),f.active&&N.polygons().map(((e,n)=>(0,t.createElement)(bp,Mp({},L,{key:`polygon-${n}`,polygon:e,fillOpacity:F===e.data?.1:0})))),r.active&&(0,t.createElement)(ii,P),i.active&&(0,t.createElement)(li,Mp({},R,{top:v,numTicks:x})),l.categories.map(((e,n)=>{const r=b.filter((t=>t[e]||""!==t[e]));return(0,t.createElement)("g",{key:`scatter-category-${n}`},d.active&&(0,t.createElement)(rh,{className:"regression-line",data:k,x:e=>C("time"===i.scale?new Date(e[0]):e[0]),y:e=>T(e[1]),stroke:d.stroke,strokeWidth:d.strokeWidth,strokeDasharray:d.strokeDasharray}),r?.map(((r,i)=>(0,t.createElement)(Dl,{key:`scatter-category-${n}-node-${i}`,r:s.pointSize,cx:C(E(r)),cy:T(r[e]),stroke:a[n],strokeOpacity:F&&c.active&&c.deemphasizeSiblings&&F.category!==e?c.deemphasizeOpacity:1,fill:a[n],fillOpacity:F&&c.active&&c.deemphasizeSiblings&&F.category!==e?c.deemphasizeOpacity:1}))),u.active&&r?.map(((i,o)=>{const s=i.__labels?.[e]?i.__labels[e]:"";return(0,t.createElement)("text",Mp({key:`line-group-${o}-label`},Xn(u),{x:C(E(i)),y:T(i[e]),dy:u.labelPositionDY,dx:u.labelPositionDX,fill:"inherit"===u.color?a[n]:u.color}),s,s||!u.showFirstLastPointsOnly||0!==o&&o!==r.length-1?"":`${Zn(i[e],e,u,null)}`,!s&&!u.showFirstLastPointsOnly&&`${Zn(i[e],e,u,null)}`)})))})),F&&c.active&&(0,t.createElement)("g",null,(0,t.createElement)(Dl,{cx:$,cy:z+1,r:s.pointSize+2,fill:"transparent",fillOpacity:.1,stroke:"black",strokeOpacity:.1,strokeWidth:2,pointerEvents:"none"}),(0,t.createElement)(Dl,{cx:$,cy:z,r:s.pointSize+1,fill:"transparent",stroke:"white",strokeWidth:2,pointerEvents:"none"})))),h.active&&(0,t.createElement)(fl,{legend:h,theme:o.theme},(0,t.createElement)(Ns,{style:{display:"flex",flexFlow:`${h.orientation} wrap`},shape:h.markerStyle,shapeWidth:12,shapeHeight:12,scale:es({domain:l.categories,range:a}),domain:h.categories.length>0?h.categories:A.domain(),direction:h.orientation,labelMargin:"0 15px 0 0"})),I&&F&&c.active&&(0,t.createElement)(Nl,{top:z,left:$,tooltip:c,theme:o.theme},(0,t.createElement)(t.Fragment,null,c.headerActive&&(0,t.createElement)("div",{style:{marginBottom:"10px"}},(0,t.createElement)("strong",null,er({x:E(F),category:F.category},c)))),(0,t.createElement)("div",{dangerouslySetInnerHTML:{__html:F.tooltip?F.tooltip:tr({x:E(F),y:M(F),category:F.category,color:A(F.category||"")},c)}})))};var Cp=["className","top","left","keys","data","curve","defined","x","x0","x1","y0","y1","value","order","offset","color","children"];function Tp(){return Tp=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,Cp),b=function(e){var t=e.keys,n=e.value,r=e.order,i=e.offset,o=Bs();return t&&o.keys(t),n&&Gs(o.value,n),r&&o.order(Qs(r)),i&&o.offset(tl(i)),o}({keys:i,value:p,order:g,offset:y}),_=Bu({x:c,x0:u,x1:h,y0:f,y1:d,curve:s,defined:l}),w=b(a);return v?o().createElement(o().Fragment,null,v({stacks:w,path:_,stack:b})):o().createElement(lr,{top:n,left:r},w.map((function(e,n){return o().createElement("path",Tp({className:rr()("visx-stack",t),key:"stack-"+n+"-"+(e.key||""),d:_(e)||"",fill:null==m?void 0:m(e.key,n)},x))})))}var Np=["className","top","left","keys","data","curve","defined","x","x0","x1","y0","y1","value","order","offset","color","children"];function Pp(){return Pp=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,Np);return o().createElement(Ap,Pp({className:t,top:n,left:r,keys:i,data:a,curve:s,defined:l,x:c,x0:u,x1:h,y0:f,y1:d,value:p,order:g,offset:y,color:m},x),v||function(e){var n=e.stacks,r=e.path;return n.map((function(e,n){return o().createElement("path",Pp({className:rr()("visx-area-stack",t),key:"area-stack-"+n+"-"+(e.key||""),d:r(e)||"",fill:null==m?void 0:m(e.key,n)},x))}))})}function Dp(){return Dp=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{data:n,config:r}=(0,t.useContext)(De),{dependentAxis:i,independentAxis:o,line:a,layout:s,colors:l,nodes:c,dataRender:u,tooltip:h,labels:f,legend:d,plotBands:p,voronoi:g}=r,y=(0,t.useRef)(null);let m=Le(s.parentClass,y);const{chartWidth:v,innerWidth:x,innerHeight:b}=He(m,s);let _=(0,t.useMemo)((()=>Ue(o.tickCount||5,v,s.width)),[o.tickCount,v,s.width]);const w=(0,t.useMemo)((()=>n.reduce(((e,t)=>e.concat(t)),[])),[n]);w.sort(((e,t)=>"ascending"===u.sortOrder?"time"===o.scale?ls(We(e[u.x],u.xFormat),We(t[u.x],u.xFormat)):ls(e[u.sortKey],t[u.sortKey]):"descending"===u.sortOrder?cs(e[u.sortKey],t[u.sortKey]):0));const k=(0,t.useMemo)((()=>w.map((e=>u.categories.map(((t,n)=>{const r=u.categories.slice(0,n+1).reduce(((t,n)=>Number(t)+Number(e[n])),0);if(e[t])return{x:e.x,y:e[t],ySum:r,category:t,label:e.__labels?.[t]?e.__labels[t]:"",tooltip:e.__tooltips?.[t]?e.__tooltips[t]:"",color:l[n]}})))).flat().filter(Boolean)),[u,w]),E=(0,t.useCallback)((e=>"time"===o.scale?We(e[u.x],u.xFormat):e[u.x]),[u,o]),M=(0,t.useCallback)((e=>e[u.y]),[u]),S=(0,t.useMemo)((()=>Nd({domain:_p(w,E),range:[0,x]})),[x,w,E]),O=(0,t.useMemo)((()=>Ja({domain:o.domain?o.domain:[0,Ll(w,E)||0],range:[0,x]})),[x,o,w,E]),C="time"===o.scale?S:O,T=(0,t.useMemo)((()=>Ja({domain:i.domain,range:[b,0],nice:!0})),[b,w,i,M]),A=(0,t.useMemo)((()=>es({domain:u.categories,range:l})),[u.categories,l]),N=(0,t.useMemo)((()=>mp({x:e=>C(E(e)),y:e=>T(e.ySum),width:x,height:b})(k)),[x,b,C,T,k,E,M]),P=a.interpolation,R=Gn(i,T,s.theme),D=Gn(o,C,s.theme),j=Kn(i,T,x,b-s.padding.top),L=Kn(o,C,x,b),F=Zu(g),{tooltipData:$,tooltipLeft:z=0,tooltipTop:I=0,tooltipOpen:W,showTooltip:U,hideTooltip:H}=rs();let Y=0;const B=(0,t.useCallback)((e=>{if(Y&&clearTimeout(Y),!y.current)return;const t=ss(y.current,e);if(!t)return;const n=N.find(t.x-s.padding.left,t.y-s.padding.top);n&&U({tooltipLeft:C(E(n.data)),tooltipTop:T(n.data.ySum),tooltipData:n.data})}),[C,T,U,N,M,E,s,Y]),V=(0,t.useCallback)((()=>{Y=window.setTimeout((()=>{H()}),300)}),[H]);return(0,t.createElement)("div",{style:{position:"relative"}},(0,t.createElement)("svg",{width:v,height:s.height,ref:y},(0,t.createElement)(lr,{top:s.padding.top,left:s.padding.left,onMouseMove:B,onMouseLeave:V},p.active&&(0,t.createElement)(Yp,{plotBands:p,independentScale:C,innerHeight:b}),(0,t.createElement)(Sr,j),(0,t.createElement)(kr,L),g.active&&N.polygons().map(((e,n)=>(0,t.createElement)(bp,Dp({},F,{key:`polygon-${n}`,polygon:e,fillOpacity:$===e.data?.1:0})))),i.active&&(0,t.createElement)(ii,R),o.active&&(0,t.createElement)(li,Dp({},D,{top:b,numTicks:_})),(0,t.createElement)(Rp,{keys:u.categories,data:w,x:e=>C(E(e.data)),y0:e=>T(e[0]),y1:e=>T(e[1]),curve:e[P]},(n=>{let{stacks:r,path:i}=n;const o=r.map(((e,n)=>{const r=e.key,o=e.filter((e=>""!==e.data[r]||e.data[r]));return(0,t.createElement)("path",{key:`stack-${r}`,d:i(o)||"",strokeWidth:0,fill:l[n],fillOpacity:a.areaFillOpacity})})),s=r.map(((n,r)=>{const i=n.key,o=n.filter((e=>""!==e.data[i]||e.data[i]));return(0,t.createElement)(rh,{key:`line-${i}`,data:o,x:e=>C(E(e.data)),y:e=>T(e[1]),strokeWidth:$&&h.active&&h.deemphasizeSiblings&&$.category===i?a.strokeWidth+1:a.strokeWidth,stroke:l[r],strokeOpacity:$&&h.active&&h.deemphasizeSiblings&&$.category!==i?h.deemphasizeOpacity:1,curve:e[P],strokeDasharray:a.strokeDasharray})}));return(0,t.createElement)("g",null,o,s)})),f.active&&k?.map(((e,n)=>{const r=e.category||"",i=e.__labels?.[r]?e.__labels[r]:"";return(0,t.createElement)("text",Dp({key:`stacked-area-${n}-label`},Xn(f),{x:C(E(e)),y:T(Number(e.ySum)),dx:f.labelPositionDX,dy:f.labelPositionDY,pointerEvents:"none",fill:"inherit"===f.color?A(e.category||""):f.color}),i,i||!f.showFirstLastPointsOnly||0!==n&&n!==k.length-1?"":`${Zn(e.y,r,f,null)}`,!i&&!f.showFirstLastPointsOnly&&`${Zn(e.y,r,f,null)}`)})),a.showPoints&&k?.map(((e,n)=>(0,t.createElement)(Dl,{key:n,r:c.pointSize,cx:C(E(e)),cy:T(Number(e.ySum)),stroke:A(e.category||""),fill:"inherit"===c.pointFill?A(e.category||""):"white",fillOpacity:$&&h.active&&h.deemphasizeSiblings&&$.category!==e.category?h.deemphasizeOpacity:1}))),$&&h.active&&(0,t.createElement)("g",null,(0,t.createElement)(Dl,{cx:z,cy:I,r:c.pointSize+2,fill:A($.category||""),fillOpacity:a.showPoints?.1:1,stroke:A($.category||""),strokeOpacity:.1,strokeWidth:2,pointerEvents:"none"}),(0,t.createElement)(Dl,{cx:z,cy:I,r:c.pointSize+1,fill:"transparent",stroke:"white",strokeWidth:2,pointerEvents:"none"})))),d.active&&(0,t.createElement)(fl,{legend:d,theme:s.theme},(0,t.createElement)(Ns,{style:{display:"flex",flexFlow:`${d.orientation} wrap`},shape:d.markerStyle,shapeWidth:12,shapeHeight:12,scale:es({domain:u.categories,range:l}),direction:d.orientation,labelMargin:"0 15px 0 0"})),W&&$&&h.active&&(0,t.createElement)(Nl,{top:I,left:z,tooltip:h,theme:s.theme},(0,t.createElement)(t.Fragment,null,h.headerActive&&(0,t.createElement)("div",{style:{marginBottom:"10px"}},(0,t.createElement)("strong",null,er({x:E($),category:$.category},h)))),(0,t.createElement)("div",{dangerouslySetInnerHTML:{__html:$.tooltip?$.tooltip:tr({x:E($),y:M($),category:$.category,color:A($.category||"")},h)}})))};function Lp(){return Lp=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{data:e,config:n}=(0,t.useContext)(De),{dependentAxis:r,independentAxis:i,layout:o,colors:a,dataRender:s,tooltip:l,labels:c,legend:u,bar:h,diffColumn:f}=n,d=(0,t.useRef)(null);let p=Le(o.parentClass,d);const{chartWidth:g,innerWidth:y,innerHeight:m}=He(p,o,f);let v=p.width&&p.width>=o.width?c.labelCutoff:c.labelCutoffMobile,x=(0,t.useMemo)((()=>Ue(r.tickCount||5,g,o.width)),[r.tickCount,g,o.width]);const b=e.reduce(((e,t)=>e.concat(t)),[]).map((e=>Object.keys(e).reduce(((t,n)=>({...t,[n]:isNaN(e[n])?e[n]:parseFloat(e[n])})),{})));b.sort(((e,t)=>"ascending"===s.sortOrder?ls(e[s.sortKey],t[s.sortKey]):"descending"===s.sortOrder?cs(e[s.sortKey],t[s.sortKey]):0)).reverse();const _=(0,t.useCallback)((e=>e[s.x]),[s.x]),w=(0,t.useMemo)((()=>la({domain:b.map(_),padding:h.barPadding})),[b,_,h.barPadding]),k=(0,t.useMemo)((()=>Ja({domain:r.domain,range:[0,y],nice:!0})),[y,r.domain]),E=(0,t.useMemo)((()=>es({domain:s.categories,range:a})),[s.categories,a]);k.rangeRound([0,y]),w.rangeRound([m,0]);const M=Gn(r,k,o.theme),S=Gn(i,w,o.theme),O=Kn(r,k,y,m),C=Kn(i,w,y,m),T=Xn(c),{tooltipData:A,tooltipLeft:N=0,tooltipTop:P=0,tooltipOpen:R,showTooltip:D,hideTooltip:j}=rs();let L;return(0,t.createElement)("div",{style:{position:"relative"}},(0,t.createElement)("svg",{width:g,height:o.height,ref:d},(0,t.createElement)(lr,{top:o.padding.top,left:o.padding.left},(0,t.createElement)(kr,O),(0,t.createElement)(Sr,C),(0,t.createElement)(il,{data:b,keys:s.categories,height:m,y:_,xScale:k,yScale:w,color:E},(e=>e.map((e=>e.bars.map(((n,r)=>{const i=n.key,o=n.bar.data,a=o[i],s=o.__labels?.[i]?o.__labels?.[i]:"",u=o.__tooltips?.[i]?o.__tooltips?.[i]:"";return(0,t.createElement)("g",{key:`barstack-horizontal-${e.index}-${n.index}`},(0,t.createElement)("rect",{x:n.x,y:n.y,width:a?Math.abs(n.width):0,height:n.height,fill:n.color,tabIndex:0,stroke:h.hasRectStroke?h.rectStrokeColor:"none",strokeWidth:h.hasRectStroke?h.rectStrokeWidth:"0",fillOpacity:A&&l.active&&l.deemphasizeSiblings&&(A?.x!==o.x||A?.y!==a||A?.category!==i)?l.deemphasizeOpacity:1,onBlur:()=>{L=window.setTimeout((()=>{j()}),300)},onFocus:()=>{L&&clearTimeout(L),D({tooltipData:{x:o.x,y:a,category:i,tooltip:u},tooltipTop:n.y,tooltipLeft:n.x})},onMouseLeave:()=>{L=window.setTimeout((()=>{j()}),300)},onMouseMove:e=>{L&&clearTimeout(L);const t=ss(e)||{x:0,y:0};D({tooltipData:{x:o.x,y:a,category:i,tooltip:u},tooltipTop:t.y,tooltipLeft:t.x})}}),a&&c.active&&v0?u.categories:E.domain(),direction:u.orientation,labelMargin:"0 15px 0 0"})),R&&A&&l.active&&(0,t.createElement)(Nl,{top:P,left:N,tooltip:l,theme:o.theme},(0,t.createElement)(t.Fragment,null,l.headerActive&&(0,t.createElement)("div",{style:{marginBottom:"10px"}},(0,t.createElement)("strong",null,er({x:_(A),category:A.category},l)))),(0,t.createElement)("div",{dangerouslySetInnerHTML:{__html:A.tooltip?A.tooltip:tr({x:_(A),y:(F=A,F[s.y]),category:A.category,color:E(A.category||"")},l)}})));var F};function $p(){return $p=Object.assign?Object.assign.bind():function(e){for(var t=1;t{const{data:e,config:n}=(0,t.useContext)(De),{dependentAxis:r,independentAxis:i,layout:o,colors:a,dataRender:s,tooltip:l,labels:c,legend:u,bar:h}=n,f=(0,t.useRef)(null);let d=Le(o.parentClass,f);const{chartWidth:p,innerWidth:g,innerHeight:y}=He(d,o);let m=d.width&&d.width>=o.width?c.labelCutoff:c.labelCutoffMobile;const v=e.reduce(((e,t)=>e.concat(t)),[]);v.sort(((e,t)=>"ascending"===s.sortOrder?ls(e[s.sortKey],t[s.sortKey]):"descending"===s.sortOrder?cs(e[s.sortKey],t[s.sortKey]):0));const{tooltipOpen:x,tooltipLeft:b=0,tooltipTop:_=0,tooltipData:w,hideTooltip:k,showTooltip:E}=rs();let M;const S=(0,t.useCallback)((e=>e[s.x]),[s.x]),O=(0,t.useMemo)((()=>la({domain:v.map(S),padding:h.barPadding})),[v,S,h.barPadding]),C=(0,t.useMemo)((()=>Ja({domain:r.domain,range:[0,g],nice:!0})),[g,r.domain]),T=es({domain:s.categories,range:a}),A=Kn(r,C,g,y-o.padding.top),N=Kn(i,O,g,y),P=Gn(r,C,o.theme),R=Gn(i,O,o.theme),D=Xn(c);return O.rangeRound([0,g]),C.range([y,0]),p&&p<100?null:(0,t.createElement)("div",{style:{position:"relative"}},(0,t.createElement)("svg",{width:p,height:o.height,ref:f},(0,t.createElement)(lr,{top:o.padding.top,left:o.padding.left},(0,t.createElement)(Sr,A),(0,t.createElement)(kr,N),(0,t.createElement)(cl,{data:v,keys:s.categories,x:S,xScale:O,yScale:C,color:T},(e=>e.map((e=>e.bars.map((n=>{const r=n.key,i=n.bar.data,o=i[r],a=i.__labels?.[r]?i.__labels?.[r]:"",s=i.__tooltips?.[r]?i.__tooltips?.[r]:"";return(0,t.createElement)("g",{key:`barstack-vertical-${e.index}-${n.index}-g`},(0,t.createElement)("rect",{key:`barstack-vertical-${e.index}-${n.index}`,x:n.x,y:n.y,width:n.width,height:n.height,fill:n.color,stroke:h.hasRectStroke?h.rectStrokeColor:"none",strokeWidth:h.hasRectStroke?h.rectStrokeWidth:"0",fillOpacity:w&&l.active&&l.deemphasizeSiblings&&(w?.x!==i.x||w?.y!==o||w?.category!==r)?l.deemphasizeOpacity:1,onMouseLeave:()=>{M=window.setTimeout((()=>{k()}),300)},onMouseMove:e=>{M&&clearTimeout(M);const t=ss(e)||{x:0,y:0};E({tooltipData:{x:i.x,y:o,category:r,tooltip:s},tooltipTop:t.y,tooltipLeft:t.x})}}),o&&c.active&&m0?u.categories:T.domain(),direction:"row",labelMargin:"0 15px 0 0"})),x&&w&&l.active&&(0,t.createElement)(Nl,{top:_,left:b,tooltip:l,theme:o.theme},(0,t.createElement)(t.Fragment,null,l.headerActive&&(0,t.createElement)("div",{style:{marginBottom:"10px"}},(0,t.createElement)("strong",null,er({x:S(w),category:w.category},l)))),(0,t.createElement)("div",{dangerouslySetInnerHTML:{__html:w.tooltip?w.tooltip:tr({x:S(w),y:(j=w,j[s.y]),category:w.category,color:T(w.category||"")},l)}})));var j},Ip=e=>{const{title:n}=e;return n?(0,t.createElement)("div",{className:"cb__title",dangerouslySetInnerHTML:{__html:n||""}}):(0,t.createElement)(t.Fragment,null)},Wp=e=>{const{subtitle:n}=e;return n?(0,t.createElement)("div",{className:"cb__subtitle",dangerouslySetInnerHTML:{__html:n||""}}):(0,t.createElement)(t.Fragment,null)},Up=e=>{const{note:n}=e;return n?(0,t.createElement)("div",{className:"cb__note",dangerouslySetInnerHTML:{__html:n||""}}):(0,t.createElement)(t.Fragment,null)},Hp=e=>{const{tag:n}=e;return n?(0,t.createElement)("div",{className:"cb__tag",dangerouslySetInnerHTML:{__html:n||""}}):(0,t.createElement)(t.Fragment,null)},Yp=e=>{let{plotBands:n,independentScale:r,innerHeight:i}=e;return(0,t.createElement)(t.Fragment,null,n.bands.map(((e,n)=>{const{x:o,y:a,style:s,label:l}=e,{band:c,label:u}=s;return(0,t.createElement)("g",null,(0,t.createElement)("rect",{fill:c.fill,fillOpacity:c.fillOpacity,key:`plot-band-${n}`,x:r(new Date(o[0])),width:r(new Date(o[1]))-r(new Date(o[0])),height:i}),(0,t.createElement)("text",{x:r(new Date(o[0]))+u.dx,y:"top"===u.align?u.dy:i-u.dy,fill:u.fill,fontSize:u.fontSize,transform:"vertical"===u.orientation?`rotate(90, ${r(new Date(o[0]))}, 30)`:""},l))})))},Bp=Pe.div` max-width: ${e=>e.width}px; max-height: ${e=>e.height}px; `,Vp=()=>{const{config:e}=(0,t.useContext)(De),{type:n,orientation:r,width:i,height:o}=e.layout;switch(n){case"bar":return"vertical"===r?(0,t.createElement)(Bp,{className:"cb__chart cb__chart__bar--vertical",width:i,height:o},(0,t.createElement)(zs,null)):(0,t.createElement)(Bp,{className:"cb__chart cb__chart__bar--horizontal",width:i,height:o},(0,t.createElement)(Ds,null));case"pie":return(0,t.createElement)(Bp,{className:"cb__chart cb__chart__pie",width:i,height:o},(0,t.createElement)(Xu,null));case"stacked-bar":return"vertical"===r?(0,t.createElement)(Bp,{className:"cb__chart cb__chart__stacked-bar--vertical",width:i,height:o},(0,t.createElement)(zp,null)):(0,t.createElement)(Bp,{className:"cb__chart cb__chart__stacked-bar--horizontal",width:i,height:o},(0,t.createElement)(Fp,null));case"diverging-bar":return"vertical"===r?(0,t.createElement)(Bp,{className:"cb__chart cb__chart__diverging-bar--vertical",width:i,height:o},(0,t.createElement)(hl,null)):(0,t.createElement)(Bp,{className:"cb__chart cb__chart__diverging-bar--horizontal",width:i,height:o},(0,t.createElement)(al,null));case"exploded-bar":return(0,t.createElement)(Bp,{className:"cb__chart cb__chart__exploded-bar",width:i,height:o},(0,t.createElement)(hu,null));case"line":default:return(0,t.createElement)(Bp,{className:"cb__chart cb__chart__line",width:i,height:o},(0,t.createElement)(Ep,null));case"stacked-area":return(0,t.createElement)(Bp,{className:"cb__chart cb__chart__stacked-area",width:i,height:o},(0,t.createElement)(jp,null));case"dot-plot":return(0,t.createElement)(Bp,{className:"cb__chart cb__chart__dot-plot",width:i,height:o},(0,t.createElement)(cu,null));case"scatter":return(0,t.createElement)(Bp,{className:"cb__chart cb__chart__scatter",width:i,height:o},(0,t.createElement)(Op,null))}};var qp=n(5800);function Gp(e){let{error:n}=e;return console.log({"Error:":n.message}),(0,t.createElement)("div",{role:"alert"},(0,t.createElement)("p",null,"Something went wrong. Please try again later"))}function Kp(e,t){window.prcChartBuilder[e]||(window.prcChartBuilder[e]=t)}window.prcChartBuilder={},Kp("ChartBuilderWrapper",(e=>{let{data:n,config:r}=e;return(0,t.createElement)(je,{value:{data:n,config:r}},(0,t.createElement)(qp.ErrorBoundary,{FallbackComponent:Gp},(0,t.createElement)(Vp,null)))})),Kp("ChartBuilderTextWrapper",(e=>{const{children:n,horizontalRules:r,width:i,title:o,subtitle:a,note:s,source:l,tag:c,active:u}=e;return(0,t.createElement)(t.Fragment,null,u&&(0,t.createElement)("div",{className:"cb__text-wrapper",style:{maxWidth:i,width:"100%"}},r&&(0,t.createElement)(fu,{position:"top",maxWidth:i}),o&&(0,t.createElement)(Ip,{title:o}),a&&(0,t.createElement)(Wp,{subtitle:a}),n,s&&(0,t.createElement)(Up,{note:s}),l&&(0,t.createElement)(Up,{note:l}),c&&(0,t.createElement)(Hp,{tag:c}),r&&(0,t.createElement)(fu,{position:"bottom",maxWidth:i})),!u&&n)})),Kp("baseConfig",Re),console.log("Loading @prc/chart-builder...",window.prcChartBuilder)})()})();; (()=>{"use strict";var t={d:(e,n)=>{for(var r in n)t.o(n,r)&&!t.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:n[r]})},o:(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r:t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})}},e={};t.r(e),t.d(e,{actions:()=>S,addAction:()=>m,addFilter:()=>p,applyFilters:()=>k,createHooks:()=>h,currentAction:()=>w,currentFilter:()=>I,defaultHooks:()=>f,didAction:()=>O,didFilter:()=>j,doAction:()=>b,doingAction:()=>x,doingFilter:()=>T,filters:()=>z,hasAction:()=>v,hasFilter:()=>y,removeAction:()=>A,removeAllActions:()=>F,removeAllFilters:()=>g,removeFilter:()=>_});const n=function(t){return"string"!=typeof t||""===t?(console.error("The namespace must be a non-empty string."),!1):!!/^[a-zA-Z][a-zA-Z0-9_.\-\/]*$/.test(t)||(console.error("The namespace can only contain numbers, letters, dashes, periods, underscores and slashes."),!1)},r=function(t){return"string"!=typeof t||""===t?(console.error("The hook name must be a non-empty string."),!1):/^__/.test(t)?(console.error("The hook name cannot begin with `__`."),!1):!!/^[a-zA-Z][a-zA-Z0-9_.-]*$/.test(t)||(console.error("The hook name can only contain numbers, letters, dashes, periods and underscores."),!1)},o=function(t,e){return function(o,i,s,c=10){const l=t[e];if(!r(o))return;if(!n(i))return;if("function"!=typeof s)return void console.error("The hook callback must be a function.");if("number"!=typeof c)return void console.error("If specified, the hook priority must be a number.");const u={callback:s,priority:c,namespace:i};if(l[o]){const t=l[o].handlers;let e;for(e=t.length;e>0&&!(c>=t[e-1].priority);e--);e===t.length?t[e]=u:t.splice(e,0,u),l.__current.forEach((t=>{t.name===o&&t.currentIndex>=e&&t.currentIndex++}))}else l[o]={handlers:[u],runs:0};"hookAdded"!==o&&t.doAction("hookAdded",o,i,s,c)}},i=function(t,e,o=!1){return function(i,s){const c=t[e];if(!r(i))return;if(!o&&!n(s))return;if(!c[i])return 0;let l=0;if(o)l=c[i].handlers.length,c[i]={runs:c[i].runs,handlers:[]};else{const t=c[i].handlers;for(let e=t.length-1;e>=0;e--)t[e].namespace===s&&(t.splice(e,1),l++,c.__current.forEach((t=>{t.name===i&&t.currentIndex>=e&&t.currentIndex--})))}return"hookRemoved"!==i&&t.doAction("hookRemoved",i,s),l}},s=function(t,e){return function(n,r){const o=t[e];return void 0!==r?n in o&&o[n].handlers.some((t=>t.namespace===r)):n in o}},c=function(t,e,n=!1){return function(r,...o){const i=t[e];i[r]||(i[r]={handlers:[],runs:0}),i[r].runs++;const s=i[r].handlers;if(!s||!s.length)return n?o[0]:void 0;const c={name:r,currentIndex:0};for(i.__current.push(c);c.currentIndex