@carbon/charts 1.16.4 → 1.16.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +18 -0
- package/dist/{_baseEach-DHzZsRNB.mjs → _baseEach-Bp7pBkX8.mjs} +2 -2
- package/dist/{_baseEach-DHzZsRNB.mjs.map → _baseEach-Bp7pBkX8.mjs.map} +1 -1
- package/dist/{angle-utils-D8sXyiIj.mjs → angle-utils-BCx3SRS2.mjs} +2 -2
- package/dist/{angle-utils-D8sXyiIj.mjs.map → angle-utils-BCx3SRS2.mjs.map} +1 -1
- package/dist/chart.d.ts +5 -0
- package/dist/charts/alluvial.d.ts +5 -0
- package/dist/charts/area-stacked.d.ts +5 -0
- package/dist/charts/area.d.ts +5 -0
- package/dist/charts/bar-grouped.d.ts +5 -0
- package/dist/charts/bar-simple.d.ts +5 -0
- package/dist/charts/bar-stacked.d.ts +5 -0
- package/dist/charts/boxplot.d.ts +5 -0
- package/dist/charts/bubble.d.ts +5 -0
- package/dist/charts/bullet.d.ts +5 -0
- package/dist/charts/choropleth.d.ts +5 -0
- package/dist/charts/circle-pack.d.ts +5 -0
- package/dist/charts/combo.d.ts +5 -0
- package/dist/charts/donut.d.ts +5 -0
- package/dist/charts/gauge.d.ts +5 -0
- package/dist/charts/heatmap.d.ts +5 -0
- package/dist/charts/histogram.d.ts +5 -0
- package/dist/charts/line.d.ts +5 -0
- package/dist/charts/lollipop.d.ts +5 -0
- package/dist/charts/meter.d.ts +5 -0
- package/dist/charts/pie.d.ts +5 -0
- package/dist/charts/radar.d.ts +5 -0
- package/dist/charts/scatter.d.ts +5 -0
- package/dist/charts/tree.d.ts +5 -0
- package/dist/charts/treemap.d.ts +5 -0
- package/dist/charts/wordcloud.d.ts +5 -0
- package/dist/{choropleth-ChNZz853.mjs → choropleth-B7eXF9sA.mjs} +60 -112
- package/dist/choropleth-B7eXF9sA.mjs.map +1 -0
- package/dist/{color-scale-utils-C93P4hee.mjs → color-scale-utils-BaTmNvWt.mjs} +7 -12
- package/dist/{color-scale-utils-C93P4hee.mjs.map → color-scale-utils-BaTmNvWt.mjs.map} +1 -1
- package/dist/components/essentials/title-meter.d.ts +0 -1
- package/dist/components/index.mjs +1 -1
- package/dist/demo/index.mjs +19 -20
- package/dist/demo/index.mjs.map +1 -1
- package/dist/index.mjs +138 -8
- package/dist/index.mjs.map +1 -1
- package/dist/interfaces/layout.d.ts +28 -3
- package/dist/interfaces/services.d.ts +39 -0
- package/dist/model/cartesian-charts.d.ts +7 -1
- package/dist/model/circle-pack.d.ts +6 -5
- package/dist/model/heatmap.d.ts +7 -1
- package/dist/model/index.mjs +1 -1
- package/dist/model/model.d.ts +15 -3
- package/dist/model/tree.d.ts +9 -2
- package/dist/services/index.mjs +3 -3
- package/dist/umd/bundle.umd.js +1 -1
- package/dist/umd/bundle.umd.js.map +1 -1
- package/dist/{wordcloud-KxSjz0Gg.mjs → wordcloud-BsEQRUwL.mjs} +50 -18
- package/dist/wordcloud-BsEQRUwL.mjs.map +1 -0
- package/dist/{zoom-B7KfNcH9.mjs → zoom-E2POxw6n.mjs} +8 -13
- package/dist/{zoom-B7KfNcH9.mjs.map → zoom-E2POxw6n.mjs.map} +1 -1
- package/package.json +5 -5
- package/dist/choropleth-ChNZz853.mjs.map +0 -1
- package/dist/wordcloud-KxSjz0Gg.mjs.map +0 -1
package/dist/umd/bundle.umd.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(W,ke){typeof exports=="object"&&typeof module<"u"?ke(exports):typeof define=="function"&&define.amd?define(["exports"],ke):(W=typeof globalThis<"u"?globalThis:W||self,ke(W.Charts={}))})(this,function(W){"use strict";function ke(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function E0(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function Mo(e){let t,n,r;e.length!==2?(t=ke,n=(o,l)=>ke(e(o),l),r=(o,l)=>e(o)-l):(t=e===ke||e===E0?e:x0,n=e,r=e);function i(o,l,c=0,u=o.length){if(c<u){if(t(l,l)!==0)return u;do{const d=c+u>>>1;n(o[d],l)<0?c=d+1:u=d}while(c<u)}return c}function s(o,l,c=0,u=o.length){if(c<u){if(t(l,l)!==0)return u;do{const d=c+u>>>1;n(o[d],l)<=0?c=d+1:u=d}while(c<u)}return c}function a(o,l,c=0,u=o.length){const d=i(o,l,c,u-1);return d>c&&r(o[d-1],l)>-r(o[d],l)?d-1:d}return{left:i,center:a,right:s}}function x0(){return 0}function b0(e){return e===null?NaN:+e}function*_0(e,t){for(let n of e)n!=null&&(n=+n)>=n&&(yield n)}const Ao=Mo(ke).right;Mo(b0).center;function S0(e,t){let n=0;for(let r of e)r!=null&&(r=+r)>=r&&++n;return n}function Pe(e,t){let n,r;if(t===void 0)for(const i of e)i!=null&&(n===void 0?i>=i&&(n=r=i):(n>i&&(n=i),r<i&&(r=i)));else{let i=-1;for(let s of e)(s=t(s,++i,e))!=null&&(n===void 0?s>=s&&(n=r=s):(n>s&&(n=s),r<s&&(r=s)))}return[n,r]}class Gn{constructor(){this._partials=new Float64Array(32),this._n=0}add(t){const n=this._partials;let r=0;for(let i=0;i<this._n&&i<32;i++){const s=n[i],a=t+s,o=Math.abs(t)<Math.abs(s)?t-(a-s):s-(a-t);o&&(n[r++]=o),t=a}return n[r]=t,this._n=r+1,this}valueOf(){const t=this._partials;let n=this._n,r,i,s,a=0;if(n>0){for(a=t[--n];n>0&&(r=a,i=t[--n],a=r+i,s=i-(a-r),!s););n>0&&(s<0&&t[n-1]<0||s>0&&t[n-1]>0)&&(i=s*2,r=a+i,i==r-a&&(a=r))}return a}}class sh extends Map{constructor(t,n=w0){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[r,i]of t)this.set(r,i)}get(t){return super.get(ah(this,t))}has(t){return super.has(ah(this,t))}set(t,n){return super.set(T0(this,t),n)}delete(t){return super.delete(O0(this,t))}}function ah({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function T0({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function O0({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function w0(e){return e!==null&&typeof e=="object"?e.valueOf():e}function M0(e){return e}function A0(e=ke){if(e===ke)return oh;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,n)=>{const r=e(t,n);return r||r===0?r:(e(n,n)===0)-(e(t,t)===0)}}function oh(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}var C0=Array.prototype,D0=C0.slice;function Co(e){return()=>e}const L0=Math.sqrt(50),R0=Math.sqrt(10),I0=Math.sqrt(2);function Os(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),s=r/Math.pow(10,i),a=s>=L0?10:s>=R0?5:s>=I0?2:1;let o,l,c;return i<0?(c=Math.pow(10,-i)/a,o=Math.round(e*c),l=Math.round(t*c),o/c<e&&++o,l/c>t&&--l,c=-c):(c=Math.pow(10,i)*a,o=Math.round(e/c),l=Math.round(t/c),o*c<e&&++o,l*c>t&&--l),l<o&&.5<=n&&n<2?Os(e,t,n*2):[o,l,c]}function ws(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[i,s,a]=r?Os(t,e,n):Os(e,t,n);if(!(s>=i))return[];const o=s-i+1,l=new Array(o);if(r)if(a<0)for(let c=0;c<o;++c)l[c]=(s-c)/-a;else for(let c=0;c<o;++c)l[c]=(s-c)*a;else if(a<0)for(let c=0;c<o;++c)l[c]=(i+c)/-a;else for(let c=0;c<o;++c)l[c]=(i+c)*a;return l}function gr(e,t,n){return t=+t,e=+e,n=+n,Os(e,t,n)[2]}function Do(e,t,n){t=+t,e=+e,n=+n;const r=t<e,i=r?gr(t,e,n):gr(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}function k0(e,t,n){let r;for(;;){const i=gr(e,t,n);if(i===r||i===0||!isFinite(i))return[e,t];i>0?(e=Math.floor(e/i)*i,t=Math.ceil(t/i)*i):i<0&&(e=Math.ceil(e*i)/i,t=Math.floor(t*i)/i),r=i}}function P0(e){return Math.max(1,Math.ceil(Math.log(S0(e))/Math.LN2)+1)}function N0(){var e=M0,t=Pe,n=P0;function r(i){Array.isArray(i)||(i=Array.from(i));var s,a=i.length,o,l,c=new Array(a);for(s=0;s<a;++s)c[s]=e(i[s],s,i);var u=t(c),d=u[0],h=u[1],f=n(c,d,h);if(!Array.isArray(f)){const y=h,b=+f;if(t===Pe&&([d,h]=k0(d,h,b)),f=ws(d,h,b),f[0]<=d&&(l=gr(d,h,b)),f[f.length-1]>=h)if(y>=h&&t===Pe){const S=gr(d,h,b);isFinite(S)&&(S>0?h=(Math.floor(h/S)+1)*S:S<0&&(h=(Math.ceil(h*-S)+1)/-S))}else f.pop()}for(var p=f.length,g=0,m=p;f[g]<=d;)++g;for(;f[m-1]>h;)--m;(g||m<p)&&(f=f.slice(g,m),p=m-g);var v=new Array(p+1),E;for(s=0;s<=p;++s)E=v[s]=[],E.x0=s>0?f[s-1]:d,E.x1=s<p?f[s]:h;if(isFinite(l)){if(l>0)for(s=0;s<a;++s)(o=c[s])!=null&&d<=o&&o<=h&&v[Math.min(p,Math.floor((o-d)/l))].push(i[s]);else if(l<0){for(s=0;s<a;++s)if((o=c[s])!=null&&d<=o&&o<=h){const y=Math.floor((d-o)*l);v[Math.min(p,y+(f[y]<=o))].push(i[s])}}}else for(s=0;s<a;++s)(o=c[s])!=null&&d<=o&&o<=h&&v[Ao(f,o,0,p)].push(i[s]);return v}return r.value=function(i){return arguments.length?(e=typeof i=="function"?i:Co(i),r):e},r.domain=function(i){return arguments.length?(t=typeof i=="function"?i:Co([i[0],i[1]]),r):t},r.thresholds=function(i){return arguments.length?(n=typeof i=="function"?i:Co(Array.isArray(i)?D0.call(i):i),r):n},r}function Vn(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n<i||n===void 0&&i>=i)&&(n=i)}return n}function Rn(e,t){let n;for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);return n}function lh(e,t,n=0,r=1/0,i){if(t=Math.floor(t),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(e.length-1,r)),!(n<=t&&t<=r))return e;for(i=i===void 0?oh:A0(i);r>n;){if(r-n>600){const l=r-n+1,c=t-n+1,u=Math.log(l),d=.5*Math.exp(2*u/3),h=.5*Math.sqrt(u*d*(l-d)/l)*(c-l/2<0?-1:1),f=Math.max(n,Math.floor(t-c*d/l+h)),p=Math.min(r,Math.floor(t+(l-c)*d/l+h));lh(e,t,f,p,i)}const s=e[t];let a=n,o=r;for(li(e,n,t),i(e[r],s)>0&&li(e,n,r);a<o;){for(li(e,a,o),++a,--o;i(e[a],s)<0;)++a;for(;i(e[o],s)>0;)--o}i(e[n],s)===0?li(e,n,o):(++o,li(e,o,r)),o<=t&&(n=o+1),t<=o&&(r=o-1)}return e}function li(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function Lo(e,t,n){if(e=Float64Array.from(_0(e)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return Rn(e);if(t>=1)return Vn(e);var r,i=(r-1)*t,s=Math.floor(i),a=Vn(lh(e,s).subarray(0,s+1)),o=Rn(e.subarray(s+1));return a+(o-a)*(i-s)}}function*$0(e){for(const t of e)yield*t}function ch(e){return Array.from($0(e))}function F0(e,t,n){e=+e,t=+t,n=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+n;for(var r=-1,i=Math.max(0,Math.ceil((t-e)/n))|0,s=new Array(i);++r<i;)s[r]=e+r*n;return s}function U0(e){return e}var Ms=1,As=2,Ro=3,ci=4,uh=1e-6;function B0(e){return"translate("+e+",0)"}function H0(e){return"translate(0,"+e+")"}function G0(e){return t=>+e(t)}function V0(e,t){return t=Math.max(0,e.bandwidth()-t*2)/2,e.round()&&(t=Math.round(t)),n=>+e(n)+t}function z0(){return!this.__axis}function Cs(e,t){var n=[],r=null,i=null,s=6,a=6,o=3,l=typeof window<"u"&&window.devicePixelRatio>1?0:.5,c=e===Ms||e===ci?-1:1,u=e===ci||e===As?"x":"y",d=e===Ms||e===Ro?B0:H0;function h(f){var p=r??(t.ticks?t.ticks.apply(t,n):t.domain()),g=i??(t.tickFormat?t.tickFormat.apply(t,n):U0),m=Math.max(s,0)+o,v=t.range(),E=+v[0]+l,y=+v[v.length-1]+l,b=(t.bandwidth?V0:G0)(t.copy(),l),S=f.selection?f.selection():f,_=S.selectAll(".domain").data([null]),A=S.selectAll(".tick").data(p,t).order(),R=A.exit(),B=A.enter().append("g").attr("class","tick"),D=A.select("line"),O=A.select("text");_=_.merge(_.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),A=A.merge(B),D=D.merge(B.append("line").attr("stroke","currentColor").attr(u+"2",c*s)),O=O.merge(B.append("text").attr("fill","currentColor").attr(u,c*m).attr("dy",e===Ms?"0em":e===Ro?"0.71em":"0.32em")),f!==S&&(_=_.transition(f),A=A.transition(f),D=D.transition(f),O=O.transition(f),R=R.transition(f).attr("opacity",uh).attr("transform",function(H){return isFinite(H=b(H))?d(H+l):this.getAttribute("transform")}),B.attr("opacity",uh).attr("transform",function(H){var P=this.parentNode.__axis;return d((P&&isFinite(P=P(H))?P:b(H))+l)})),R.remove(),_.attr("d",e===ci||e===As?a?"M"+c*a+","+E+"H"+l+"V"+y+"H"+c*a:"M"+l+","+E+"V"+y:a?"M"+E+","+c*a+"V"+l+"H"+y+"V"+c*a:"M"+E+","+l+"H"+y),A.attr("opacity",1).attr("transform",function(H){return d(b(H)+l)}),D.attr(u+"2",c*s),O.attr(u,c*m).text(g),S.filter(z0).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",e===As?"start":e===ci?"end":"middle"),S.each(function(){this.__axis=b})}return h.scale=function(f){return arguments.length?(t=f,h):t},h.ticks=function(){return n=Array.from(arguments),h},h.tickArguments=function(f){return arguments.length?(n=f==null?[]:Array.from(f),h):n.slice()},h.tickValues=function(f){return arguments.length?(r=f==null?null:Array.from(f),h):r&&r.slice()},h.tickFormat=function(f){return arguments.length?(i=f,h):i},h.tickSize=function(f){return arguments.length?(s=a=+f,h):s},h.tickSizeInner=function(f){return arguments.length?(s=+f,h):s},h.tickSizeOuter=function(f){return arguments.length?(a=+f,h):a},h.tickPadding=function(f){return arguments.length?(o=+f,h):o},h.offset=function(f){return arguments.length?(l=+f,h):l},h}function W0(e){return Cs(Ms,e)}function Y0(e){return Cs(As,e)}function Io(e){return Cs(Ro,e)}function hh(e){return Cs(ci,e)}var q0={value:()=>{}};function ko(){for(var e=0,t=arguments.length,n={},r;e<t;++e){if(!(r=arguments[e]+"")||r in n||/[\s.]/.test(r))throw new Error("illegal type: "+r);n[r]=[]}return new Ds(n)}function Ds(e){this._=e}function X0(e,t){return e.trim().split(/^|\s+/).map(function(n){var r="",i=n.indexOf(".");if(i>=0&&(r=n.slice(i+1),n=n.slice(0,i)),n&&!t.hasOwnProperty(n))throw new Error("unknown type: "+n);return{type:n,name:r}})}Ds.prototype=ko.prototype={constructor:Ds,on:function(e,t){var n=this._,r=X0(e+"",n),i,s=-1,a=r.length;if(arguments.length<2){for(;++s<a;)if((i=(e=r[s]).type)&&(i=j0(n[i],e.name)))return i;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++s<a;)if(i=(e=r[s]).type)n[i]=dh(n[i],e.name,t);else if(t==null)for(i in n)n[i]=dh(n[i],e.name,null);return this},copy:function(){var e={},t=this._;for(var n in t)e[n]=t[n].slice();return new Ds(e)},call:function(e,t){if((i=arguments.length-2)>0)for(var n=new Array(i),r=0,i,s;r<i;++r)n[r]=arguments[r+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(s=this._[e],r=0,i=s.length;r<i;++r)s[r].value.apply(t,n)},apply:function(e,t,n){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var r=this._[e],i=0,s=r.length;i<s;++i)r[i].value.apply(t,n)}};function j0(e,t){for(var n=0,r=e.length,i;n<r;++n)if((i=e[n]).name===t)return i.value}function dh(e,t,n){for(var r=0,i=e.length;r<i;++r)if(e[r].name===t){e[r]=q0,e=e.slice(0,r).concat(e.slice(r+1));break}return n!=null&&e.push({name:t,value:n}),e}var Po="http://www.w3.org/1999/xhtml";const fh={svg:"http://www.w3.org/2000/svg",xhtml:Po,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Ls(e){var t=e+="",n=t.indexOf(":");return n>=0&&(t=e.slice(0,n))!=="xmlns"&&(e=e.slice(n+1)),fh.hasOwnProperty(t)?{space:fh[t],local:e}:e}function Z0(e){return function(){var t=this.ownerDocument,n=this.namespaceURI;return n===Po&&t.documentElement.namespaceURI===Po?t.createElement(e):t.createElementNS(n,e)}}function K0(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function ph(e){var t=Ls(e);return(t.local?K0:Z0)(t)}function Q0(){}function No(e){return e==null?Q0:function(){return this.querySelector(e)}}function J0(e){typeof e!="function"&&(e=No(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var s=t[i],a=s.length,o=r[i]=new Array(a),l,c,u=0;u<a;++u)(l=s[u])&&(c=e.call(l,l.__data__,u,s))&&("__data__"in l&&(c.__data__=l.__data__),o[u]=c);return new ve(r,this._parents)}function ty(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function ey(){return[]}function gh(e){return e==null?ey:function(){return this.querySelectorAll(e)}}function ny(e){return function(){return ty(e.apply(this,arguments))}}function ry(e){typeof e=="function"?e=ny(e):e=gh(e);for(var t=this._groups,n=t.length,r=[],i=[],s=0;s<n;++s)for(var a=t[s],o=a.length,l,c=0;c<o;++c)(l=a[c])&&(r.push(e.call(l,l.__data__,c,a)),i.push(l));return new ve(r,i)}function mh(e){return function(){return this.matches(e)}}function vh(e){return function(t){return t.matches(e)}}var iy=Array.prototype.find;function sy(e){return function(){return iy.call(this.children,e)}}function ay(){return this.firstElementChild}function oy(e){return this.select(e==null?ay:sy(typeof e=="function"?e:vh(e)))}var ly=Array.prototype.filter;function cy(){return Array.from(this.children)}function uy(e){return function(){return ly.call(this.children,e)}}function hy(e){return this.selectAll(e==null?cy:uy(typeof e=="function"?e:vh(e)))}function dy(e){typeof e!="function"&&(e=mh(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var s=t[i],a=s.length,o=r[i]=[],l,c=0;c<a;++c)(l=s[c])&&e.call(l,l.__data__,c,s)&&o.push(l);return new ve(r,this._parents)}function yh(e){return new Array(e.length)}function fy(){return new ve(this._enter||this._groups.map(yh),this._parents)}function Rs(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}Rs.prototype={constructor:Rs,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function py(e){return function(){return e}}function gy(e,t,n,r,i,s){for(var a=0,o,l=t.length,c=s.length;a<c;++a)(o=t[a])?(o.__data__=s[a],r[a]=o):n[a]=new Rs(e,s[a]);for(;a<l;++a)(o=t[a])&&(i[a]=o)}function my(e,t,n,r,i,s,a){var o,l,c=new Map,u=t.length,d=s.length,h=new Array(u),f;for(o=0;o<u;++o)(l=t[o])&&(h[o]=f=a.call(l,l.__data__,o,t)+"",c.has(f)?i[o]=l:c.set(f,l));for(o=0;o<d;++o)f=a.call(e,s[o],o,s)+"",(l=c.get(f))?(r[o]=l,l.__data__=s[o],c.delete(f)):n[o]=new Rs(e,s[o]);for(o=0;o<u;++o)(l=t[o])&&c.get(h[o])===l&&(i[o]=l)}function vy(e){return e.__data__}function yy(e,t){if(!arguments.length)return Array.from(this,vy);var n=t?my:gy,r=this._parents,i=this._groups;typeof e!="function"&&(e=py(e));for(var s=i.length,a=new Array(s),o=new Array(s),l=new Array(s),c=0;c<s;++c){var u=r[c],d=i[c],h=d.length,f=Ey(e.call(u,u&&u.__data__,c,r)),p=f.length,g=o[c]=new Array(p),m=a[c]=new Array(p),v=l[c]=new Array(h);n(u,d,g,m,v,f,t);for(var E=0,y=0,b,S;E<p;++E)if(b=g[E]){for(E>=y&&(y=E+1);!(S=m[y])&&++y<p;);b._next=S||null}}return a=new ve(a,r),a._enter=o,a._exit=l,a}function Ey(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function xy(){return new ve(this._exit||this._groups.map(yh),this._parents)}function by(e,t,n){var r=this.enter(),i=this,s=this.exit();return typeof e=="function"?(r=e(r),r&&(r=r.selection())):r=r.append(e+""),t!=null&&(i=t(i),i&&(i=i.selection())),n==null?s.remove():n(s),r&&i?r.merge(i).order():i}function _y(e){for(var t=e.selection?e.selection():e,n=this._groups,r=t._groups,i=n.length,s=r.length,a=Math.min(i,s),o=new Array(i),l=0;l<a;++l)for(var c=n[l],u=r[l],d=c.length,h=o[l]=new Array(d),f,p=0;p<d;++p)(f=c[p]||u[p])&&(h[p]=f);for(;l<i;++l)o[l]=n[l];return new ve(o,this._parents)}function Sy(){for(var e=this._groups,t=-1,n=e.length;++t<n;)for(var r=e[t],i=r.length-1,s=r[i],a;--i>=0;)(a=r[i])&&(s&&a.compareDocumentPosition(s)^4&&s.parentNode.insertBefore(a,s),s=a);return this}function Ty(e){e||(e=Oy);function t(d,h){return d&&h?e(d.__data__,h.__data__):!d-!h}for(var n=this._groups,r=n.length,i=new Array(r),s=0;s<r;++s){for(var a=n[s],o=a.length,l=i[s]=new Array(o),c,u=0;u<o;++u)(c=a[u])&&(l[u]=c);l.sort(t)}return new ve(i,this._parents).order()}function Oy(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function wy(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function My(){return Array.from(this)}function Ay(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var r=e[t],i=0,s=r.length;i<s;++i){var a=r[i];if(a)return a}return null}function Cy(){let e=0;for(const t of this)++e;return e}function Dy(){return!this.node()}function Ly(e){for(var t=this._groups,n=0,r=t.length;n<r;++n)for(var i=t[n],s=0,a=i.length,o;s<a;++s)(o=i[s])&&e.call(o,o.__data__,s,i);return this}function Ry(e){return function(){this.removeAttribute(e)}}function Iy(e){return function(){this.removeAttributeNS(e.space,e.local)}}function ky(e,t){return function(){this.setAttribute(e,t)}}function Py(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function Ny(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttribute(e):this.setAttribute(e,n)}}function $y(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,n)}}function Fy(e,t){var n=Ls(e);if(arguments.length<2){var r=this.node();return n.local?r.getAttributeNS(n.space,n.local):r.getAttribute(n)}return this.each((t==null?n.local?Iy:Ry:typeof t=="function"?n.local?$y:Ny:n.local?Py:ky)(n,t))}function Eh(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function Uy(e){return function(){this.style.removeProperty(e)}}function By(e,t,n){return function(){this.style.setProperty(e,t,n)}}function Hy(e,t,n){return function(){var r=t.apply(this,arguments);r==null?this.style.removeProperty(e):this.style.setProperty(e,r,n)}}function Gy(e,t,n){return arguments.length>1?this.each((t==null?Uy:typeof t=="function"?Hy:By)(e,t,n??"")):mr(this.node(),e)}function mr(e,t){return e.style.getPropertyValue(t)||Eh(e).getComputedStyle(e,null).getPropertyValue(t)}function Vy(e){return function(){delete this[e]}}function zy(e,t){return function(){this[e]=t}}function Wy(e,t){return function(){var n=t.apply(this,arguments);n==null?delete this[e]:this[e]=n}}function Yy(e,t){return arguments.length>1?this.each((t==null?Vy:typeof t=="function"?Wy:zy)(e,t)):this.node()[e]}function xh(e){return e.trim().split(/^|\s+/)}function $o(e){return e.classList||new bh(e)}function bh(e){this._node=e,this._names=xh(e.getAttribute("class")||"")}bh.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function _h(e,t){for(var n=$o(e),r=-1,i=t.length;++r<i;)n.add(t[r])}function Sh(e,t){for(var n=$o(e),r=-1,i=t.length;++r<i;)n.remove(t[r])}function qy(e){return function(){_h(this,e)}}function Xy(e){return function(){Sh(this,e)}}function jy(e,t){return function(){(t.apply(this,arguments)?_h:Sh)(this,e)}}function Zy(e,t){var n=xh(e+"");if(arguments.length<2){for(var r=$o(this.node()),i=-1,s=n.length;++i<s;)if(!r.contains(n[i]))return!1;return!0}return this.each((typeof t=="function"?jy:t?qy:Xy)(n,t))}function Ky(){this.textContent=""}function Qy(e){return function(){this.textContent=e}}function Jy(e){return function(){var t=e.apply(this,arguments);this.textContent=t??""}}function t1(e){return arguments.length?this.each(e==null?Ky:(typeof e=="function"?Jy:Qy)(e)):this.node().textContent}function e1(){this.innerHTML=""}function n1(e){return function(){this.innerHTML=e}}function r1(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t??""}}function i1(e){return arguments.length?this.each(e==null?e1:(typeof e=="function"?r1:n1)(e)):this.node().innerHTML}function s1(){this.nextSibling&&this.parentNode.appendChild(this)}function a1(){return this.each(s1)}function o1(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function l1(){return this.each(o1)}function c1(e){var t=typeof e=="function"?e:ph(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function u1(){return null}function h1(e,t){var n=typeof e=="function"?e:ph(e),r=t==null?u1:typeof t=="function"?t:No(t);return this.select(function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)})}function d1(){var e=this.parentNode;e&&e.removeChild(this)}function f1(){return this.each(d1)}function p1(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function g1(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function m1(e){return this.select(e?g1:p1)}function v1(e){return arguments.length?this.property("__data__",e):this.node().__data__}function y1(e){return function(t){e.call(this,t,this.__data__)}}function E1(e){return e.trim().split(/^|\s+/).map(function(t){var n="",r=t.indexOf(".");return r>=0&&(n=t.slice(r+1),t=t.slice(0,r)),{type:t,name:n}})}function x1(e){return function(){var t=this.__on;if(t){for(var n=0,r=-1,i=t.length,s;n<i;++n)s=t[n],(!e.type||s.type===e.type)&&s.name===e.name?this.removeEventListener(s.type,s.listener,s.options):t[++r]=s;++r?t.length=r:delete this.__on}}}function b1(e,t,n){return function(){var r=this.__on,i,s=y1(t);if(r){for(var a=0,o=r.length;a<o;++a)if((i=r[a]).type===e.type&&i.name===e.name){this.removeEventListener(i.type,i.listener,i.options),this.addEventListener(i.type,i.listener=s,i.options=n),i.value=t;return}}this.addEventListener(e.type,s,n),i={type:e.type,name:e.name,value:t,listener:s,options:n},r?r.push(i):this.__on=[i]}}function _1(e,t,n){var r=E1(e+""),i,s=r.length,a;if(arguments.length<2){var o=this.node().__on;if(o){for(var l=0,c=o.length,u;l<c;++l)for(i=0,u=o[l];i<s;++i)if((a=r[i]).type===u.type&&a.name===u.name)return u.value}return}for(o=t?b1:x1,i=0;i<s;++i)this.each(o(r[i],t,n));return this}function Th(e,t,n){var r=Eh(e),i=r.CustomEvent;typeof i=="function"?i=new i(t,n):(i=r.document.createEvent("Event"),n?(i.initEvent(t,n.bubbles,n.cancelable),i.detail=n.detail):i.initEvent(t,!1,!1)),e.dispatchEvent(i)}function S1(e,t){return function(){return Th(this,e,t)}}function T1(e,t){return function(){return Th(this,e,t.apply(this,arguments))}}function O1(e,t){return this.each((typeof t=="function"?T1:S1)(e,t))}function*w1(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var r=e[t],i=0,s=r.length,a;i<s;++i)(a=r[i])&&(yield a)}var Oh=[null];function ve(e,t){this._groups=e,this._parents=t}function ui(){return new ve([[document.documentElement]],Oh)}function M1(){return this}ve.prototype=ui.prototype={constructor:ve,select:J0,selectAll:ry,selectChild:oy,selectChildren:hy,filter:dy,data:yy,enter:fy,exit:xy,join:by,merge:_y,selection:M1,order:Sy,sort:Ty,call:wy,nodes:My,node:Ay,size:Cy,empty:Dy,each:Ly,attr:Fy,style:Gy,property:Yy,classed:Zy,text:t1,html:i1,raise:a1,lower:l1,append:c1,insert:h1,remove:f1,clone:m1,datum:v1,on:_1,dispatch:O1,[Symbol.iterator]:w1};function k(e){return typeof e=="string"?new ve([[document.querySelector(e)]],[document.documentElement]):new ve([[e]],Oh)}function A1(e){let t;for(;t=e.sourceEvent;)e=t;return e}function zn(e,t){if(e=A1(e),t===void 0&&(t=e.currentTarget),t){var n=t.ownerSVGElement||t;if(n.createSVGPoint){var r=n.createSVGPoint();return r.x=e.clientX,r.y=e.clientY,r=r.matrixTransform(t.getScreenCTM().inverse()),[r.x,r.y]}if(t.getBoundingClientRect){var i=t.getBoundingClientRect();return[e.clientX-i.left-t.clientLeft,e.clientY-i.top-t.clientTop]}}return[e.pageX,e.pageY]}const Fo={capture:!0,passive:!1};function Uo(e){e.preventDefault(),e.stopImmediatePropagation()}function C1(e){var t=e.document.documentElement,n=k(e).on("dragstart.drag",Uo,Fo);"onselectstart"in t?n.on("selectstart.drag",Uo,Fo):(t.__noselect=t.style.MozUserSelect,t.style.MozUserSelect="none")}function D1(e,t){var n=e.document.documentElement,r=k(e).on("dragstart.drag",null);t&&(r.on("click.drag",Uo,Fo),setTimeout(function(){r.on("click.drag",null)},0)),"onselectstart"in n?r.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}function Bo(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function wh(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function hi(){}var di=.7,Is=1/di,vr="\\s*([+-]?\\d+)\\s*",fi="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",je="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",L1=/^#([0-9a-f]{3,8})$/,R1=new RegExp(`^rgb\\(${vr},${vr},${vr}\\)$`),I1=new RegExp(`^rgb\\(${je},${je},${je}\\)$`),k1=new RegExp(`^rgba\\(${vr},${vr},${vr},${fi}\\)$`),P1=new RegExp(`^rgba\\(${je},${je},${je},${fi}\\)$`),N1=new RegExp(`^hsl\\(${fi},${je},${je}\\)$`),$1=new RegExp(`^hsla\\(${fi},${je},${je},${fi}\\)$`),Mh={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Bo(hi,un,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Ah,formatHex:Ah,formatHex8:F1,formatHsl:U1,formatRgb:Ch,toString:Ch});function Ah(){return this.rgb().formatHex()}function F1(){return this.rgb().formatHex8()}function U1(){return kh(this).formatHsl()}function Ch(){return this.rgb().formatRgb()}function un(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=L1.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?Dh(t):n===3?new ue(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?ks(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?ks(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=R1.exec(e))?new ue(t[1],t[2],t[3],1):(t=I1.exec(e))?new ue(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=k1.exec(e))?ks(t[1],t[2],t[3],t[4]):(t=P1.exec(e))?ks(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=N1.exec(e))?Ih(t[1],t[2]/100,t[3]/100,1):(t=$1.exec(e))?Ih(t[1],t[2]/100,t[3]/100,t[4]):Mh.hasOwnProperty(e)?Dh(Mh[e]):e==="transparent"?new ue(NaN,NaN,NaN,0):null}function Dh(e){return new ue(e>>16&255,e>>8&255,e&255,1)}function ks(e,t,n,r){return r<=0&&(e=t=n=NaN),new ue(e,t,n,r)}function B1(e){return e instanceof hi||(e=un(e)),e?(e=e.rgb(),new ue(e.r,e.g,e.b,e.opacity)):new ue}function Ho(e,t,n,r){return arguments.length===1?B1(e):new ue(e,t,n,r??1)}function ue(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}Bo(ue,Ho,wh(hi,{brighter(e){return e=e==null?Is:Math.pow(Is,e),new ue(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?di:Math.pow(di,e),new ue(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new ue(Wn(this.r),Wn(this.g),Wn(this.b),Ps(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Lh,formatHex:Lh,formatHex8:H1,formatRgb:Rh,toString:Rh}));function Lh(){return`#${Yn(this.r)}${Yn(this.g)}${Yn(this.b)}`}function H1(){return`#${Yn(this.r)}${Yn(this.g)}${Yn(this.b)}${Yn((isNaN(this.opacity)?1:this.opacity)*255)}`}function Rh(){const e=Ps(this.opacity);return`${e===1?"rgb(":"rgba("}${Wn(this.r)}, ${Wn(this.g)}, ${Wn(this.b)}${e===1?")":`, ${e})`}`}function Ps(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Wn(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Yn(e){return e=Wn(e),(e<16?"0":"")+e.toString(16)}function Ih(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new Ne(e,t,n,r)}function kh(e){if(e instanceof Ne)return new Ne(e.h,e.s,e.l,e.opacity);if(e instanceof hi||(e=un(e)),!e)return new Ne;if(e instanceof Ne)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),s=Math.max(t,n,r),a=NaN,o=s-i,l=(s+i)/2;return o?(t===s?a=(n-r)/o+(n<r)*6:n===s?a=(r-t)/o+2:a=(t-n)/o+4,o/=l<.5?s+i:2-s-i,a*=60):o=l>0&&l<1?0:a,new Ne(a,o,l,e.opacity)}function Go(e,t,n,r){return arguments.length===1?kh(e):new Ne(e,t,n,r??1)}function Ne(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}Bo(Ne,Go,wh(hi,{brighter(e){return e=e==null?Is:Math.pow(Is,e),new Ne(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?di:Math.pow(di,e),new Ne(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new ue(Vo(e>=240?e-240:e+120,i,r),Vo(e,i,r),Vo(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new Ne(Ph(this.h),Ns(this.s),Ns(this.l),Ps(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=Ps(this.opacity);return`${e===1?"hsl(":"hsla("}${Ph(this.h)}, ${Ns(this.s)*100}%, ${Ns(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Ph(e){return e=(e||0)%360,e<0?e+360:e}function Ns(e){return Math.max(0,Math.min(1,e||0))}function Vo(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const zo=e=>()=>e;function G1(e,t){return function(n){return e+n*t}}function V1(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function z1(e){return(e=+e)==1?Nh:function(t,n){return n-t?V1(t,n,e):zo(isNaN(t)?n:t)}}function Nh(e,t){var n=t-e;return n?G1(e,n):zo(isNaN(e)?t:e)}const $s=function e(t){var n=z1(t);function r(i,s){var a=n((i=Ho(i)).r,(s=Ho(s)).r),o=n(i.g,s.g),l=n(i.b,s.b),c=Nh(i.opacity,s.opacity);return function(u){return i.r=a(u),i.g=o(u),i.b=l(u),i.opacity=c(u),i+""}}return r.gamma=e,r}(1);function W1(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(s){for(i=0;i<n;++i)r[i]=e[i]*(1-s)+t[i]*s;return r}}function Y1(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function q1(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=new Array(r),s=new Array(n),a;for(a=0;a<r;++a)i[a]=pi(e[a],t[a]);for(;a<n;++a)s[a]=t[a];return function(o){for(a=0;a<r;++a)s[a]=i[a](o);return s}}function X1(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function ye(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function j1(e,t){var n={},r={},i;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(i in t)i in e?n[i]=pi(e[i],t[i]):r[i]=t[i];return function(s){for(i in n)r[i]=n[i](s);return r}}var Wo=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Yo=new RegExp(Wo.source,"g");function Z1(e){return function(){return e}}function K1(e){return function(t){return e(t)+""}}function $h(e,t){var n=Wo.lastIndex=Yo.lastIndex=0,r,i,s,a=-1,o=[],l=[];for(e=e+"",t=t+"";(r=Wo.exec(e))&&(i=Yo.exec(t));)(s=i.index)>n&&(s=t.slice(n,s),o[a]?o[a]+=s:o[++a]=s),(r=r[0])===(i=i[0])?o[a]?o[a]+=i:o[++a]=i:(o[++a]=null,l.push({i:a,x:ye(r,i)})),n=Yo.lastIndex;return n<t.length&&(s=t.slice(n),o[a]?o[a]+=s:o[++a]=s),o.length<2?l[0]?K1(l[0].x):Z1(t):(t=l.length,function(c){for(var u=0,d;u<t;++u)o[(d=l[u]).i]=d.x(c);return o.join("")})}function pi(e,t){var n=typeof t,r;return t==null||n==="boolean"?zo(t):(n==="number"?ye:n==="string"?(r=un(t))?(t=r,$s):$h:t instanceof un?$s:t instanceof Date?X1:Y1(t)?W1:Array.isArray(t)?q1:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?j1:ye)(e,t)}function Fh(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}var Uh=180/Math.PI,qo={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Bh(e,t,n,r,i,s){var a,o,l;return(a=Math.sqrt(e*e+t*t))&&(e/=a,t/=a),(l=e*n+t*r)&&(n-=e*l,r-=t*l),(o=Math.sqrt(n*n+r*r))&&(n/=o,r/=o,l/=o),e*r<t*n&&(e=-e,t=-t,l=-l,a=-a),{translateX:i,translateY:s,rotate:Math.atan2(t,e)*Uh,skewX:Math.atan(l)*Uh,scaleX:a,scaleY:o}}var Fs;function Q1(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?qo:Bh(t.a,t.b,t.c,t.d,t.e,t.f)}function J1(e){return e==null||(Fs||(Fs=document.createElementNS("http://www.w3.org/2000/svg","g")),Fs.setAttribute("transform",e),!(e=Fs.transform.baseVal.consolidate()))?qo:(e=e.matrix,Bh(e.a,e.b,e.c,e.d,e.e,e.f))}function Hh(e,t,n,r){function i(c){return c.length?c.pop()+" ":""}function s(c,u,d,h,f,p){if(c!==d||u!==h){var g=f.push("translate(",null,t,null,n);p.push({i:g-4,x:ye(c,d)},{i:g-2,x:ye(u,h)})}else(d||h)&&f.push("translate("+d+t+h+n)}function a(c,u,d,h){c!==u?(c-u>180?u+=360:u-c>180&&(c+=360),h.push({i:d.push(i(d)+"rotate(",null,r)-2,x:ye(c,u)})):u&&d.push(i(d)+"rotate("+u+r)}function o(c,u,d,h){c!==u?h.push({i:d.push(i(d)+"skewX(",null,r)-2,x:ye(c,u)}):u&&d.push(i(d)+"skewX("+u+r)}function l(c,u,d,h,f,p){if(c!==d||u!==h){var g=f.push(i(f)+"scale(",null,",",null,")");p.push({i:g-4,x:ye(c,d)},{i:g-2,x:ye(u,h)})}else(d!==1||h!==1)&&f.push(i(f)+"scale("+d+","+h+")")}return function(c,u){var d=[],h=[];return c=e(c),u=e(u),s(c.translateX,c.translateY,u.translateX,u.translateY,d,h),a(c.rotate,u.rotate,d,h),o(c.skewX,u.skewX,d,h),l(c.scaleX,c.scaleY,u.scaleX,u.scaleY,d,h),c=u=null,function(f){for(var p=-1,g=h.length,m;++p<g;)d[(m=h[p]).i]=m.x(f);return d.join("")}}}var tE=Hh(Q1,"px, ","px)","deg)"),eE=Hh(J1,", ",")",")");function nE(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e(r/(t-1));return n}var yr=0,gi=0,mi=0,Gh=1e3,Us,vi,Bs=0,qn=0,Hs=0,yi=typeof performance=="object"&&performance.now?performance:Date,Vh=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function Xo(){return qn||(Vh(rE),qn=yi.now()+Hs)}function rE(){qn=0}function Gs(){this._call=this._time=this._next=null}Gs.prototype=zh.prototype={constructor:Gs,restart:function(e,t,n){if(typeof e!="function")throw new TypeError("callback is not a function");n=(n==null?Xo():+n)+(t==null?0:+t),!this._next&&vi!==this&&(vi?vi._next=this:Us=this,vi=this),this._call=e,this._time=n,jo()},stop:function(){this._call&&(this._call=null,this._time=1/0,jo())}};function zh(e,t,n){var r=new Gs;return r.restart(e,t,n),r}function iE(){Xo(),++yr;for(var e=Us,t;e;)(t=qn-e._time)>=0&&e._call.call(void 0,t),e=e._next;--yr}function Wh(){qn=(Bs=yi.now())+Hs,yr=gi=0;try{iE()}finally{yr=0,aE(),qn=0}}function sE(){var e=yi.now(),t=e-Bs;t>Gh&&(Hs-=t,Bs=e)}function aE(){for(var e,t=Us,n,r=1/0;t;)t._call?(r>t._time&&(r=t._time),e=t,t=t._next):(n=t._next,t._next=null,t=e?e._next=n:Us=n);vi=e,jo(r)}function jo(e){if(!yr){gi&&(gi=clearTimeout(gi));var t=e-qn;t>24?(e<1/0&&(gi=setTimeout(Wh,e-yi.now()-Hs)),mi&&(mi=clearInterval(mi))):(mi||(Bs=yi.now(),mi=setInterval(sE,Gh)),yr=1,Vh(Wh))}}function Yh(e,t,n){var r=new Gs;return t=t==null?0:+t,r.restart(i=>{r.stop(),e(i+t)},t,n),r}var oE=ko("start","end","cancel","interrupt"),lE=[],qh=0,Xh=1,Zo=2,Vs=3,jh=4,Ko=5,zs=6;function Ws(e,t,n,r,i,s){var a=e.__transition;if(!a)e.__transition={};else if(n in a)return;cE(e,n,{name:t,index:r,group:i,on:oE,tween:lE,time:s.time,delay:s.delay,duration:s.duration,ease:s.ease,timer:null,state:qh})}function Qo(e,t){var n=$e(e,t);if(n.state>qh)throw new Error("too late; already scheduled");return n}function Ze(e,t){var n=$e(e,t);if(n.state>Vs)throw new Error("too late; already running");return n}function $e(e,t){var n=e.__transition;if(!n||!(n=n[t]))throw new Error("transition not found");return n}function cE(e,t,n){var r=e.__transition,i;r[t]=n,n.timer=zh(s,0,n.time);function s(c){n.state=Xh,n.timer.restart(a,n.delay,n.time),n.delay<=c&&a(c-n.delay)}function a(c){var u,d,h,f;if(n.state!==Xh)return l();for(u in r)if(f=r[u],f.name===n.name){if(f.state===Vs)return Yh(a);f.state===jh?(f.state=zs,f.timer.stop(),f.on.call("interrupt",e,e.__data__,f.index,f.group),delete r[u]):+u<t&&(f.state=zs,f.timer.stop(),f.on.call("cancel",e,e.__data__,f.index,f.group),delete r[u])}if(Yh(function(){n.state===Vs&&(n.state=jh,n.timer.restart(o,n.delay,n.time),o(c))}),n.state=Zo,n.on.call("start",e,e.__data__,n.index,n.group),n.state===Zo){for(n.state=Vs,i=new Array(h=n.tween.length),u=0,d=-1;u<h;++u)(f=n.tween[u].value.call(e,e.__data__,n.index,n.group))&&(i[++d]=f);i.length=d+1}}function o(c){for(var u=c<n.duration?n.ease.call(null,c/n.duration):(n.timer.restart(l),n.state=Ko,1),d=-1,h=i.length;++d<h;)i[d].call(e,u);n.state===Ko&&(n.on.call("end",e,e.__data__,n.index,n.group),l())}function l(){n.state=zs,n.timer.stop(),delete r[t];for(var c in r)return;delete e.__transition}}function Jo(e,t){var n=e.__transition,r,i,s=!0,a;if(n){t=t==null?null:t+"";for(a in n){if((r=n[a]).name!==t){s=!1;continue}i=r.state>Zo&&r.state<Ko,r.state=zs,r.timer.stop(),r.on.call(i?"interrupt":"cancel",e,e.__data__,r.index,r.group),delete n[a]}s&&delete e.__transition}}function uE(e){return this.each(function(){Jo(this,e)})}function hE(e,t){var n,r;return function(){var i=Ze(this,e),s=i.tween;if(s!==n){r=n=s;for(var a=0,o=r.length;a<o;++a)if(r[a].name===t){r=r.slice(),r.splice(a,1);break}}i.tween=r}}function dE(e,t,n){var r,i;if(typeof n!="function")throw new Error;return function(){var s=Ze(this,e),a=s.tween;if(a!==r){i=(r=a).slice();for(var o={name:t,value:n},l=0,c=i.length;l<c;++l)if(i[l].name===t){i[l]=o;break}l===c&&i.push(o)}s.tween=i}}function fE(e,t){var n=this._id;if(e+="",arguments.length<2){for(var r=$e(this.node(),n).tween,i=0,s=r.length,a;i<s;++i)if((a=r[i]).name===e)return a.value;return null}return this.each((t==null?hE:dE)(n,e,t))}function tl(e,t,n){var r=e._id;return e.each(function(){var i=Ze(this,r);(i.value||(i.value={}))[t]=n.apply(this,arguments)}),function(i){return $e(i,r).value[t]}}function Zh(e,t){var n;return(typeof t=="number"?ye:t instanceof un?$s:(n=un(t))?(t=n,$s):$h)(e,t)}function pE(e){return function(){this.removeAttribute(e)}}function gE(e){return function(){this.removeAttributeNS(e.space,e.local)}}function mE(e,t,n){var r,i=n+"",s;return function(){var a=this.getAttribute(e);return a===i?null:a===r?s:s=t(r=a,n)}}function vE(e,t,n){var r,i=n+"",s;return function(){var a=this.getAttributeNS(e.space,e.local);return a===i?null:a===r?s:s=t(r=a,n)}}function yE(e,t,n){var r,i,s;return function(){var a,o=n(this),l;return o==null?void this.removeAttribute(e):(a=this.getAttribute(e),l=o+"",a===l?null:a===r&&l===i?s:(i=l,s=t(r=a,o)))}}function EE(e,t,n){var r,i,s;return function(){var a,o=n(this),l;return o==null?void this.removeAttributeNS(e.space,e.local):(a=this.getAttributeNS(e.space,e.local),l=o+"",a===l?null:a===r&&l===i?s:(i=l,s=t(r=a,o)))}}function xE(e,t){var n=Ls(e),r=n==="transform"?eE:Zh;return this.attrTween(e,typeof t=="function"?(n.local?EE:yE)(n,r,tl(this,"attr."+e,t)):t==null?(n.local?gE:pE)(n):(n.local?vE:mE)(n,r,t))}function bE(e,t){return function(n){this.setAttribute(e,t.call(this,n))}}function _E(e,t){return function(n){this.setAttributeNS(e.space,e.local,t.call(this,n))}}function SE(e,t){var n,r;function i(){var s=t.apply(this,arguments);return s!==r&&(n=(r=s)&&_E(e,s)),n}return i._value=t,i}function TE(e,t){var n,r;function i(){var s=t.apply(this,arguments);return s!==r&&(n=(r=s)&&bE(e,s)),n}return i._value=t,i}function OE(e,t){var n="attr."+e;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(t==null)return this.tween(n,null);if(typeof t!="function")throw new Error;var r=Ls(e);return this.tween(n,(r.local?SE:TE)(r,t))}function wE(e,t){return function(){Qo(this,e).delay=+t.apply(this,arguments)}}function ME(e,t){return t=+t,function(){Qo(this,e).delay=t}}function AE(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?wE:ME)(t,e)):$e(this.node(),t).delay}function CE(e,t){return function(){Ze(this,e).duration=+t.apply(this,arguments)}}function DE(e,t){return t=+t,function(){Ze(this,e).duration=t}}function LE(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?CE:DE)(t,e)):$e(this.node(),t).duration}function RE(e,t){if(typeof t!="function")throw new Error;return function(){Ze(this,e).ease=t}}function IE(e){var t=this._id;return arguments.length?this.each(RE(t,e)):$e(this.node(),t).ease}function kE(e,t){return function(){var n=t.apply(this,arguments);if(typeof n!="function")throw new Error;Ze(this,e).ease=n}}function PE(e){if(typeof e!="function")throw new Error;return this.each(kE(this._id,e))}function NE(e){typeof e!="function"&&(e=mh(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var s=t[i],a=s.length,o=r[i]=[],l,c=0;c<a;++c)(l=s[c])&&e.call(l,l.__data__,c,s)&&o.push(l);return new hn(r,this._parents,this._name,this._id)}function $E(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,n=e._groups,r=t.length,i=n.length,s=Math.min(r,i),a=new Array(r),o=0;o<s;++o)for(var l=t[o],c=n[o],u=l.length,d=a[o]=new Array(u),h,f=0;f<u;++f)(h=l[f]||c[f])&&(d[f]=h);for(;o<r;++o)a[o]=t[o];return new hn(a,this._parents,this._name,this._id)}function FE(e){return(e+"").trim().split(/^|\s+/).every(function(t){var n=t.indexOf(".");return n>=0&&(t=t.slice(0,n)),!t||t==="start"})}function UE(e,t,n){var r,i,s=FE(t)?Qo:Ze;return function(){var a=s(this,e),o=a.on;o!==r&&(i=(r=o).copy()).on(t,n),a.on=i}}function BE(e,t){var n=this._id;return arguments.length<2?$e(this.node(),n).on.on(e):this.each(UE(n,e,t))}function HE(e){return function(){var t=this.parentNode;for(var n in this.__transition)if(+n!==e)return;t&&t.removeChild(this)}}function GE(){return this.on("end.remove",HE(this._id))}function VE(e){var t=this._name,n=this._id;typeof e!="function"&&(e=No(e));for(var r=this._groups,i=r.length,s=new Array(i),a=0;a<i;++a)for(var o=r[a],l=o.length,c=s[a]=new Array(l),u,d,h=0;h<l;++h)(u=o[h])&&(d=e.call(u,u.__data__,h,o))&&("__data__"in u&&(d.__data__=u.__data__),c[h]=d,Ws(c[h],t,n,h,c,$e(u,n)));return new hn(s,this._parents,t,n)}function zE(e){var t=this._name,n=this._id;typeof e!="function"&&(e=gh(e));for(var r=this._groups,i=r.length,s=[],a=[],o=0;o<i;++o)for(var l=r[o],c=l.length,u,d=0;d<c;++d)if(u=l[d]){for(var h=e.call(u,u.__data__,d,l),f,p=$e(u,n),g=0,m=h.length;g<m;++g)(f=h[g])&&Ws(f,t,n,g,h,p);s.push(h),a.push(u)}return new hn(s,a,t,n)}var WE=ui.prototype.constructor;function YE(){return new WE(this._groups,this._parents)}function qE(e,t){var n,r,i;return function(){var s=mr(this,e),a=(this.style.removeProperty(e),mr(this,e));return s===a?null:s===n&&a===r?i:i=t(n=s,r=a)}}function Kh(e){return function(){this.style.removeProperty(e)}}function XE(e,t,n){var r,i=n+"",s;return function(){var a=mr(this,e);return a===i?null:a===r?s:s=t(r=a,n)}}function jE(e,t,n){var r,i,s;return function(){var a=mr(this,e),o=n(this),l=o+"";return o==null&&(l=o=(this.style.removeProperty(e),mr(this,e))),a===l?null:a===r&&l===i?s:(i=l,s=t(r=a,o))}}function ZE(e,t){var n,r,i,s="style."+t,a="end."+s,o;return function(){var l=Ze(this,e),c=l.on,u=l.value[s]==null?o||(o=Kh(t)):void 0;(c!==n||i!==u)&&(r=(n=c).copy()).on(a,i=u),l.on=r}}function KE(e,t,n){var r=(e+="")=="transform"?tE:Zh;return t==null?this.styleTween(e,qE(e,r)).on("end.style."+e,Kh(e)):typeof t=="function"?this.styleTween(e,jE(e,r,tl(this,"style."+e,t))).each(ZE(this._id,e)):this.styleTween(e,XE(e,r,t),n).on("end.style."+e,null)}function QE(e,t,n){return function(r){this.style.setProperty(e,t.call(this,r),n)}}function JE(e,t,n){var r,i;function s(){var a=t.apply(this,arguments);return a!==i&&(r=(i=a)&&QE(e,a,n)),r}return s._value=t,s}function tx(e,t,n){var r="style."+(e+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(t==null)return this.tween(r,null);if(typeof t!="function")throw new Error;return this.tween(r,JE(e,t,n??""))}function ex(e){return function(){this.textContent=e}}function nx(e){return function(){var t=e(this);this.textContent=t??""}}function rx(e){return this.tween("text",typeof e=="function"?nx(tl(this,"text",e)):ex(e==null?"":e+""))}function ix(e){return function(t){this.textContent=e.call(this,t)}}function sx(e){var t,n;function r(){var i=e.apply(this,arguments);return i!==n&&(t=(n=i)&&ix(i)),t}return r._value=e,r}function ax(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(e==null)return this.tween(t,null);if(typeof e!="function")throw new Error;return this.tween(t,sx(e))}function ox(){for(var e=this._name,t=this._id,n=Qh(),r=this._groups,i=r.length,s=0;s<i;++s)for(var a=r[s],o=a.length,l,c=0;c<o;++c)if(l=a[c]){var u=$e(l,t);Ws(l,e,n,c,a,{time:u.time+u.delay+u.duration,delay:0,duration:u.duration,ease:u.ease})}return new hn(r,this._parents,e,n)}function lx(){var e,t,n=this,r=n._id,i=n.size();return new Promise(function(s,a){var o={value:a},l={value:function(){--i===0&&s()}};n.each(function(){var c=Ze(this,r),u=c.on;u!==e&&(t=(e=u).copy(),t._.cancel.push(o),t._.interrupt.push(o),t._.end.push(l)),c.on=t}),i===0&&s()})}var cx=0;function hn(e,t,n,r){this._groups=e,this._parents=t,this._name=n,this._id=r}function Qh(){return++cx}var dn=ui.prototype;hn.prototype={constructor:hn,select:VE,selectAll:zE,selectChild:dn.selectChild,selectChildren:dn.selectChildren,filter:NE,merge:$E,selection:YE,transition:ox,call:dn.call,nodes:dn.nodes,node:dn.node,size:dn.size,empty:dn.empty,each:dn.each,on:BE,attr:xE,attrTween:OE,style:KE,styleTween:tx,text:rx,textTween:ax,remove:GE,tween:fE,delay:AE,duration:LE,ease:IE,easeVarying:PE,end:lx,[Symbol.iterator]:dn[Symbol.iterator]};const ux=e=>+e;function Jh(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var hx={time:null,delay:0,duration:250,ease:Jh};function dx(e,t){for(var n;!(n=e.__transition)||!(n=n[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return n}function fx(e){var t,n;e instanceof hn?(t=e._id,e=e._name):(t=Qh(),(n=hx).time=Xo(),e=e==null?null:e+"");for(var r=this._groups,i=r.length,s=0;s<i;++s)for(var a=r[s],o=a.length,l,c=0;c<o;++c)(l=a[c])&&Ws(l,e,t,c,a,n||dx(l,t));return new hn(r,this._parents,e,t)}ui.prototype.interrupt=uE,ui.prototype.transition=fx;const el=e=>()=>e;function px(e,{sourceEvent:t,target:n,selection:r,mode:i,dispatch:s}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},selection:{value:r,enumerable:!0,configurable:!0},mode:{value:i,enumerable:!0,configurable:!0},_:{value:s}})}function gx(e){e.stopImmediatePropagation()}function nl(e){e.preventDefault(),e.stopImmediatePropagation()}var td={name:"drag"},rl={name:"space"},Er={name:"handle"},xr={name:"center"};const{abs:ed,max:Kt,min:Qt}=Math;function nd(e){return[+e[0],+e[1]]}function rd(e){return[nd(e[0]),nd(e[1])]}var Ys={name:"x",handles:["w","e"].map(qs),input:function(e,t){return e==null?null:[[+e[0],t[0][1]],[+e[1],t[1][1]]]},output:function(e){return e&&[e[0][0],e[1][0]]}},il={name:"y",handles:["n","s"].map(qs),input:function(e,t){return e==null?null:[[t[0][0],+e[0]],[t[1][0],+e[1]]]},output:function(e){return e&&[e[0][1],e[1][1]]}},fn={overlay:"crosshair",selection:"move",n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},id={e:"w",w:"e",nw:"ne",ne:"nw",se:"sw",sw:"se"},sd={n:"s",s:"n",nw:"sw",ne:"se",se:"ne",sw:"nw"},mx={overlay:1,selection:1,n:null,e:1,s:null,w:-1,nw:-1,ne:1,se:1,sw:-1},vx={overlay:1,selection:1,n:-1,e:null,s:1,w:null,nw:-1,ne:-1,se:1,sw:1};function qs(e){return{type:e}}function yx(e){return!e.ctrlKey&&!e.button}function Ex(){var e=this.ownerSVGElement||this;return e.hasAttribute("viewBox")?(e=e.viewBox.baseVal,[[e.x,e.y],[e.x+e.width,e.y+e.height]]):[[0,0],[e.width.baseVal.value,e.height.baseVal.value]]}function xx(){return navigator.maxTouchPoints||"ontouchstart"in this}function sl(e){for(;!e.__brush;)if(!(e=e.parentNode))return;return e.__brush}function bx(e){return e[0][0]===e[1][0]||e[0][1]===e[1][1]}function ad(){return _x(Ys)}function _x(e){var t=Ex,n=yx,r=xx,i=!0,s=ko("start","brush","end"),a=6,o;function l(m){var v=m.property("__brush",g).selectAll(".overlay").data([qs("overlay")]);v.enter().append("rect").attr("class","overlay").attr("pointer-events","all").attr("cursor",fn.overlay).merge(v).each(function(){var y=sl(this).extent;k(this).attr("x",y[0][0]).attr("y",y[0][1]).attr("width",y[1][0]-y[0][0]).attr("height",y[1][1]-y[0][1])}),m.selectAll(".selection").data([qs("selection")]).enter().append("rect").attr("class","selection").attr("cursor",fn.selection).attr("fill","#777").attr("fill-opacity",.3).attr("stroke","#fff").attr("shape-rendering","crispEdges");var E=m.selectAll(".handle").data(e.handles,function(y){return y.type});E.exit().remove(),E.enter().append("rect").attr("class",function(y){return"handle handle--"+y.type}).attr("cursor",function(y){return fn[y.type]}),m.each(c).attr("fill","none").attr("pointer-events","all").on("mousedown.brush",h).filter(r).on("touchstart.brush",h).on("touchmove.brush",f).on("touchend.brush touchcancel.brush",p).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}l.move=function(m,v,E){m.tween?m.on("start.brush",function(y){u(this,arguments).beforestart().start(y)}).on("interrupt.brush end.brush",function(y){u(this,arguments).end(y)}).tween("brush",function(){var y=this,b=y.__brush,S=u(y,arguments),_=b.selection,A=e.input(typeof v=="function"?v.apply(this,arguments):v,b.extent),R=pi(_,A);function B(D){b.selection=D===1&&A===null?null:R(D),c.call(y),S.brush()}return _!==null&&A!==null?B:B(1)}):m.each(function(){var y=this,b=arguments,S=y.__brush,_=e.input(typeof v=="function"?v.apply(y,b):v,S.extent),A=u(y,b).beforestart();Jo(y),S.selection=_===null?null:_,c.call(y),A.start(E).brush(E).end(E)})},l.clear=function(m,v){l.move(m,null,v)};function c(){var m=k(this),v=sl(this).selection;v?(m.selectAll(".selection").style("display",null).attr("x",v[0][0]).attr("y",v[0][1]).attr("width",v[1][0]-v[0][0]).attr("height",v[1][1]-v[0][1]),m.selectAll(".handle").style("display",null).attr("x",function(E){return E.type[E.type.length-1]==="e"?v[1][0]-a/2:v[0][0]-a/2}).attr("y",function(E){return E.type[0]==="s"?v[1][1]-a/2:v[0][1]-a/2}).attr("width",function(E){return E.type==="n"||E.type==="s"?v[1][0]-v[0][0]+a:a}).attr("height",function(E){return E.type==="e"||E.type==="w"?v[1][1]-v[0][1]+a:a})):m.selectAll(".selection,.handle").style("display","none").attr("x",null).attr("y",null).attr("width",null).attr("height",null)}function u(m,v,E){var y=m.__brush.emitter;return y&&(!E||!y.clean)?y:new d(m,v,E)}function d(m,v,E){this.that=m,this.args=v,this.state=m.__brush,this.active=0,this.clean=E}d.prototype={beforestart:function(){return++this.active===1&&(this.state.emitter=this,this.starting=!0),this},start:function(m,v){return this.starting?(this.starting=!1,this.emit("start",m,v)):this.emit("brush",m),this},brush:function(m,v){return this.emit("brush",m,v),this},end:function(m,v){return--this.active===0&&(delete this.state.emitter,this.emit("end",m,v)),this},emit:function(m,v,E){var y=k(this.that).datum();s.call(m,this.that,new px(m,{sourceEvent:v,target:l,selection:e.output(this.state.selection),mode:E,dispatch:s}),y)}};function h(m){if(o&&!m.touches||!n.apply(this,arguments))return;var v=this,E=m.target.__data__.type,y=(i&&m.metaKey?E="overlay":E)==="selection"?td:i&&m.altKey?xr:Er,b=e===il?null:mx[E],S=e===Ys?null:vx[E],_=sl(v),A=_.extent,R=_.selection,B=A[0][0],D,O,H=A[0][1],P,M,w=A[1][0],U,$,N=A[1][1],F,Y,Z=0,K=0,dt,it=b&&S&&i&&m.shiftKey,ft,j,nt=Array.from(m.touches||[m],st=>{const Dt=st.identifier;return st=zn(st,v),st.point0=st.slice(),st.identifier=Dt,st});Jo(v);var vt=u(v,arguments,!0).beforestart();if(E==="overlay"){R&&(dt=!0);const st=[nt[0],nt[1]||nt[0]];_.selection=R=[[D=e===il?B:Qt(st[0][0],st[1][0]),P=e===Ys?H:Qt(st[0][1],st[1][1])],[U=e===il?w:Kt(st[0][0],st[1][0]),F=e===Ys?N:Kt(st[0][1],st[1][1])]],nt.length>1&&G(m)}else D=R[0][0],P=R[0][1],U=R[1][0],F=R[1][1];O=D,M=P,$=U,Y=F;var q=k(v).attr("pointer-events","none"),Q=q.selectAll(".overlay").attr("cursor",fn[E]);if(m.touches)vt.moved=C,vt.ended=z;else{var ot=k(m.view).on("mousemove.brush",C,!0).on("mouseup.brush",z,!0);i&&ot.on("keydown.brush",Ct,!0).on("keyup.brush",Ut,!0),C1(m.view)}c.call(v),vt.start(m,y.name);function C(st){for(const Dt of st.changedTouches||[st])for(const Hn of nt)Hn.identifier===Dt.identifier&&(Hn.cur=zn(Dt,v));if(it&&!ft&&!j&&nt.length===1){const Dt=nt[0];ed(Dt.cur[0]-Dt[0])>ed(Dt.cur[1]-Dt[1])?j=!0:ft=!0}for(const Dt of nt)Dt.cur&&(Dt[0]=Dt.cur[0],Dt[1]=Dt.cur[1]);dt=!0,nl(st),G(st)}function G(st){const Dt=nt[0],Hn=Dt.point0;var Xe;switch(Z=Dt[0]-Hn[0],K=Dt[1]-Hn[1],y){case rl:case td:{b&&(Z=Kt(B-D,Qt(w-U,Z)),O=D+Z,$=U+Z),S&&(K=Kt(H-P,Qt(N-F,K)),M=P+K,Y=F+K);break}case Er:{nt[1]?(b&&(O=Kt(B,Qt(w,nt[0][0])),$=Kt(B,Qt(w,nt[1][0])),b=1),S&&(M=Kt(H,Qt(N,nt[0][1])),Y=Kt(H,Qt(N,nt[1][1])),S=1)):(b<0?(Z=Kt(B-D,Qt(w-D,Z)),O=D+Z,$=U):b>0&&(Z=Kt(B-U,Qt(w-U,Z)),O=D,$=U+Z),S<0?(K=Kt(H-P,Qt(N-P,K)),M=P+K,Y=F):S>0&&(K=Kt(H-F,Qt(N-F,K)),M=P,Y=F+K));break}case xr:{b&&(O=Kt(B,Qt(w,D-Z*b)),$=Kt(B,Qt(w,U+Z*b))),S&&(M=Kt(H,Qt(N,P-K*S)),Y=Kt(H,Qt(N,F+K*S)));break}}$<O&&(b*=-1,Xe=D,D=U,U=Xe,Xe=O,O=$,$=Xe,E in id&&Q.attr("cursor",fn[E=id[E]])),Y<M&&(S*=-1,Xe=P,P=F,F=Xe,Xe=M,M=Y,Y=Xe,E in sd&&Q.attr("cursor",fn[E=sd[E]])),_.selection&&(R=_.selection),ft&&(O=R[0][0],$=R[1][0]),j&&(M=R[0][1],Y=R[1][1]),(R[0][0]!==O||R[0][1]!==M||R[1][0]!==$||R[1][1]!==Y)&&(_.selection=[[O,M],[$,Y]],c.call(v),vt.brush(st,y.name))}function z(st){if(gx(st),st.touches){if(st.touches.length)return;o&&clearTimeout(o),o=setTimeout(function(){o=null},500)}else D1(st.view,dt),ot.on("keydown.brush keyup.brush mousemove.brush mouseup.brush",null);q.attr("pointer-events","all"),Q.attr("cursor",fn.overlay),_.selection&&(R=_.selection),bx(R)&&(_.selection=null,c.call(v)),vt.end(st,y.name)}function Ct(st){switch(st.keyCode){case 16:{it=b&&S;break}case 18:{y===Er&&(b&&(U=$-Z*b,D=O+Z*b),S&&(F=Y-K*S,P=M+K*S),y=xr,G(st));break}case 32:{(y===Er||y===xr)&&(b<0?U=$-Z:b>0&&(D=O-Z),S<0?F=Y-K:S>0&&(P=M-K),y=rl,Q.attr("cursor",fn.selection),G(st));break}default:return}nl(st)}function Ut(st){switch(st.keyCode){case 16:{it&&(ft=j=it=!1,G(st));break}case 18:{y===xr&&(b<0?U=$:b>0&&(D=O),S<0?F=Y:S>0&&(P=M),y=Er,G(st));break}case 32:{y===rl&&(st.altKey?(b&&(U=$-Z*b,D=O+Z*b),S&&(F=Y-K*S,P=M+K*S),y=xr):(b<0?U=$:b>0&&(D=O),S<0?F=Y:S>0&&(P=M),y=Er),Q.attr("cursor",fn[E]),G(st));break}default:return}nl(st)}}function f(m){u(this,arguments).moved(m)}function p(m){u(this,arguments).ended(m)}function g(){var m=this.__brush||{selection:null};return m.extent=rd(t.apply(this,arguments)),m.dim=e,m}return l.extent=function(m){return arguments.length?(t=typeof m=="function"?m:el(rd(m)),l):t},l.filter=function(m){return arguments.length?(n=typeof m=="function"?m:el(!!m),l):n},l.touchable=function(m){return arguments.length?(r=typeof m=="function"?m:el(!!m),l):r},l.handleSize=function(m){return arguments.length?(a=+m,l):a},l.keyModifiers=function(m){return arguments.length?(i=!!m,l):i},l.on=function(){var m=s.on.apply(s,arguments);return m===s?l:m},l}const al=Math.PI,ol=2*al,Xn=1e-6,Sx=ol-Xn;function od(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function Tx(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return od;const n=10**t;return function(r){this._+=r[0];for(let i=1,s=r.length;i<s;++i)this._+=Math.round(arguments[i]*n)/n+r[i]}}let Ox=class{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?od:Tx(t)}moveTo(t,n){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,n){this._append`L${this._x1=+t},${this._y1=+n}`}quadraticCurveTo(t,n,r,i){this._append`Q${+t},${+n},${this._x1=+r},${this._y1=+i}`}bezierCurveTo(t,n,r,i,s,a){this._append`C${+t},${+n},${+r},${+i},${this._x1=+s},${this._y1=+a}`}arcTo(t,n,r,i,s){if(t=+t,n=+n,r=+r,i=+i,s=+s,s<0)throw new Error(`negative radius: ${s}`);let a=this._x1,o=this._y1,l=r-t,c=i-n,u=a-t,d=o-n,h=u*u+d*d;if(this._x1===null)this._append`M${this._x1=t},${this._y1=n}`;else if(h>Xn)if(!(Math.abs(d*l-c*u)>Xn)||!s)this._append`L${this._x1=t},${this._y1=n}`;else{let f=r-a,p=i-o,g=l*l+c*c,m=f*f+p*p,v=Math.sqrt(g),E=Math.sqrt(h),y=s*Math.tan((al-Math.acos((g+h-m)/(2*v*E)))/2),b=y/E,S=y/v;Math.abs(b-1)>Xn&&this._append`L${t+b*u},${n+b*d}`,this._append`A${s},${s},0,0,${+(d*f>u*p)},${this._x1=t+S*l},${this._y1=n+S*c}`}}arc(t,n,r,i,s,a){if(t=+t,n=+n,r=+r,a=!!a,r<0)throw new Error(`negative radius: ${r}`);let o=r*Math.cos(i),l=r*Math.sin(i),c=t+o,u=n+l,d=1^a,h=a?i-s:s-i;this._x1===null?this._append`M${c},${u}`:(Math.abs(this._x1-c)>Xn||Math.abs(this._y1-u)>Xn)&&this._append`L${c},${u}`,r&&(h<0&&(h=h%ol+ol),h>Sx?this._append`A${r},${r},0,1,${d},${t-o},${n-l}A${r},${r},0,1,${d},${this._x1=c},${this._y1=u}`:h>Xn&&this._append`A${r},${r},0,${+(h>=al)},${d},${this._x1=t+r*Math.cos(s)},${this._y1=n+r*Math.sin(s)}`)}rect(t,n,r,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${r=+r}v${+i}h${-r}Z`}toString(){return this._}};function wx(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Xs(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 br(e){return e=Xs(Math.abs(e)),e?e[1]:NaN}function Mx(e,t){return function(n,r){for(var i=n.length,s=[],a=0,o=e[0],l=0;i>0&&o>0&&(l+o+1>r&&(o=Math.max(1,r-l)),s.push(n.substring(i-=o,i+o)),!((l+=o+1)>r));)o=e[a=(a+1)%e.length];return s.reverse().join(t)}}function Ax(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var Cx=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Ei(e){if(!(t=Cx.exec(e)))throw new Error("invalid format: "+e);var t;return new ll({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]})}Ei.prototype=ll.prototype;function ll(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}ll.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function Dx(e){t:for(var t=e.length,n=1,r=-1,i;n<t;++n)switch(e[n]){case".":r=i=n;break;case"0":r===0&&(r=n),i=n;break;default:if(!+e[n])break t;r>0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(i+1):e}var ld;function Lx(e,t){var n=Xs(e,t);if(!n)return e+"";var r=n[0],i=n[1],s=i-(ld=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,a=r.length;return s===a?r:s>a?r+new Array(s-a+1).join("0"):s>0?r.slice(0,s)+"."+r.slice(s):"0."+new Array(1-s).join("0")+Xs(e,Math.max(0,t+s-1))[0]}function cd(e,t){var n=Xs(e,t);if(!n)return e+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}const ud={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:wx,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)=>cd(e*100,t),r:cd,s:Lx,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function hd(e){return e}var dd=Array.prototype.map,fd=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function Rx(e){var t=e.grouping===void 0||e.thousands===void 0?hd:Mx(dd.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",s=e.numerals===void 0?hd:Ax(dd.call(e.numerals,String)),a=e.percent===void 0?"%":e.percent+"",o=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function c(d){d=Ei(d);var h=d.fill,f=d.align,p=d.sign,g=d.symbol,m=d.zero,v=d.width,E=d.comma,y=d.precision,b=d.trim,S=d.type;S==="n"?(E=!0,S="g"):ud[S]||(y===void 0&&(y=12),b=!0,S="g"),(m||h==="0"&&f==="=")&&(m=!0,h="0",f="=");var _=g==="$"?n:g==="#"&&/[boxX]/.test(S)?"0"+S.toLowerCase():"",A=g==="$"?r:/[%p]/.test(S)?a:"",R=ud[S],B=/[defgprs%]/.test(S);y=y===void 0?6:/[gprs]/.test(S)?Math.max(1,Math.min(21,y)):Math.max(0,Math.min(20,y));function D(O){var H=_,P=A,M,w,U;if(S==="c")P=R(O)+P,O="";else{O=+O;var $=O<0||1/O<0;if(O=isNaN(O)?l:R(Math.abs(O),y),b&&(O=Dx(O)),$&&+O==0&&p!=="+"&&($=!1),H=($?p==="("?p:o:p==="-"||p==="("?"":p)+H,P=(S==="s"?fd[8+ld/3]:"")+P+($&&p==="("?")":""),B){for(M=-1,w=O.length;++M<w;)if(U=O.charCodeAt(M),48>U||U>57){P=(U===46?i+O.slice(M+1):O.slice(M))+P,O=O.slice(0,M);break}}}E&&!m&&(O=t(O,1/0));var N=H.length+O.length+P.length,F=N<v?new Array(v-N+1).join(h):"";switch(E&&m&&(O=t(F+O,F.length?v-P.length:1/0),F=""),f){case"<":O=H+O+P+F;break;case"=":O=H+F+O+P;break;case"^":O=F.slice(0,N=F.length>>1)+H+O+P+F.slice(N);break;default:O=F+H+O+P;break}return s(O)}return D.toString=function(){return d+""},D}function u(d,h){var f=c((d=Ei(d),d.type="f",d)),p=Math.max(-8,Math.min(8,Math.floor(br(h)/3)))*3,g=Math.pow(10,-p),m=fd[8+p/3];return function(v){return f(g*v)+m}}return{format:c,formatPrefix:u}}var js,cl,pd;Ix({thousands:",",grouping:[3],currency:["$",""]});function Ix(e){return js=Rx(e),cl=js.format,pd=js.formatPrefix,js}function kx(e){return Math.max(0,-br(Math.abs(e)))}function Px(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(br(t)/3)))*3-br(Math.abs(e)))}function Nx(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,br(t)-br(e))+1}var St=1e-6,gd=1e-12,pt=Math.PI,he=pt/2,md=pt/4,Ee=pt*2,re=180/pt,$t=pt/180,Tt=Math.abs,vd=Math.atan,jn=Math.atan2,wt=Math.cos,$x=Math.exp,Fx=Math.log,bt=Math.sin,In=Math.sign||function(e){return e>0?1:e<0?-1:0},Fe=Math.sqrt,Ux=Math.tan;function Bx(e){return e>1?0:e<-1?pt:Math.acos(e)}function pn(e){return e>1?he:e<-1?-he:Math.asin(e)}function Oe(){}function Zs(e,t){e&&Ed.hasOwnProperty(e.type)&&Ed[e.type](e,t)}var yd={Feature:function(e,t){Zs(e.geometry,t)},FeatureCollection:function(e,t){for(var n=e.features,r=-1,i=n.length;++r<i;)Zs(n[r].geometry,t)}},Ed={Sphere:function(e,t){t.sphere()},Point:function(e,t){e=e.coordinates,t.point(e[0],e[1],e[2])},MultiPoint:function(e,t){for(var n=e.coordinates,r=-1,i=n.length;++r<i;)e=n[r],t.point(e[0],e[1],e[2])},LineString:function(e,t){ul(e.coordinates,t,0)},MultiLineString:function(e,t){for(var n=e.coordinates,r=-1,i=n.length;++r<i;)ul(n[r],t,0)},Polygon:function(e,t){xd(e.coordinates,t)},MultiPolygon:function(e,t){for(var n=e.coordinates,r=-1,i=n.length;++r<i;)xd(n[r],t)},GeometryCollection:function(e,t){for(var n=e.geometries,r=-1,i=n.length;++r<i;)Zs(n[r],t)}};function ul(e,t,n){var r=-1,i=e.length-n,s;for(t.lineStart();++r<i;)s=e[r],t.point(s[0],s[1],s[2]);t.lineEnd()}function xd(e,t){var n=-1,r=e.length;for(t.polygonStart();++n<r;)ul(e[n],t,1);t.polygonEnd()}function _r(e,t){e&&yd.hasOwnProperty(e.type)?yd[e.type](e,t):Zs(e,t)}function hl(e){return[jn(e[1],e[0]),pn(e[2])]}function Sr(e){var t=e[0],n=e[1],r=wt(n);return[r*wt(t),r*bt(t),bt(n)]}function Ks(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}function Qs(e,t){return[e[1]*t[2]-e[2]*t[1],e[2]*t[0]-e[0]*t[2],e[0]*t[1]-e[1]*t[0]]}function dl(e,t){e[0]+=t[0],e[1]+=t[1],e[2]+=t[2]}function Js(e,t){return[e[0]*t,e[1]*t,e[2]*t]}function fl(e){var t=Fe(e[0]*e[0]+e[1]*e[1]+e[2]*e[2]);e[0]/=t,e[1]/=t,e[2]/=t}function pl(e,t){function n(r,i){return r=e(r,i),t(r[0],r[1])}return e.invert&&t.invert&&(n.invert=function(r,i){return r=t.invert(r,i),r&&e.invert(r[0],r[1])}),n}function gl(e,t){return Tt(e)>pt&&(e-=Math.round(e/Ee)*Ee),[e,t]}gl.invert=gl;function bd(e,t,n){return(e%=Ee)?t||n?pl(Sd(e),Td(t,n)):Sd(e):t||n?Td(t,n):gl}function _d(e){return function(t,n){return t+=e,Tt(t)>pt&&(t-=Math.round(t/Ee)*Ee),[t,n]}}function Sd(e){var t=_d(e);return t.invert=_d(-e),t}function Td(e,t){var n=wt(e),r=bt(e),i=wt(t),s=bt(t);function a(o,l){var c=wt(l),u=wt(o)*c,d=bt(o)*c,h=bt(l),f=h*n+u*r;return[jn(d*i-f*s,u*n-h*r),pn(f*i+d*s)]}return a.invert=function(o,l){var c=wt(l),u=wt(o)*c,d=bt(o)*c,h=bt(l),f=h*i-d*s;return[jn(d*i+h*s,u*n+f*r),pn(f*n-u*r)]},a}function Hx(e){e=bd(e[0]*$t,e[1]*$t,e.length>2?e[2]*$t:0);function t(n){return n=e(n[0]*$t,n[1]*$t),n[0]*=re,n[1]*=re,n}return t.invert=function(n){return n=e.invert(n[0]*$t,n[1]*$t),n[0]*=re,n[1]*=re,n},t}function Gx(e,t,n,r,i,s){if(n){var a=wt(t),o=bt(t),l=r*n;i==null?(i=t+r*Ee,s=t-l/2):(i=Od(a,i),s=Od(a,s),(r>0?i<s:i>s)&&(i+=r*Ee));for(var c,u=i;r>0?u>s:u<s;u-=l)c=hl([a,-o*wt(u),-o*bt(u)]),e.point(c[0],c[1])}}function Od(e,t){t=Sr(t),t[0]-=e,fl(t);var n=Bx(-t[1]);return((-t[2]<0?-n:n)+Ee-St)%Ee}function wd(){var e=[],t;return{point:function(n,r,i){t.push([n,r,i])},lineStart:function(){e.push(t=[])},lineEnd:Oe,rejoin:function(){e.length>1&&e.push(e.pop().concat(e.shift()))},result:function(){var n=e;return e=[],t=null,n}}}function ta(e,t){return Tt(e[0]-t[0])<St&&Tt(e[1]-t[1])<St}function ea(e,t,n,r){this.x=e,this.z=t,this.o=n,this.e=r,this.v=!1,this.n=this.p=null}function Md(e,t,n,r,i){var s=[],a=[],o,l;if(e.forEach(function(p){if(!((g=p.length-1)<=0)){var g,m=p[0],v=p[g],E;if(ta(m,v)){if(!m[2]&&!v[2]){for(i.lineStart(),o=0;o<g;++o)i.point((m=p[o])[0],m[1]);i.lineEnd();return}v[0]+=2*St}s.push(E=new ea(m,p,null,!0)),a.push(E.o=new ea(m,null,E,!1)),s.push(E=new ea(v,p,null,!1)),a.push(E.o=new ea(v,null,E,!0))}}),!!s.length){for(a.sort(t),Ad(s),Ad(a),o=0,l=a.length;o<l;++o)a[o].e=n=!n;for(var c=s[0],u,d;;){for(var h=c,f=!0;h.v;)if((h=h.n)===c)return;u=h.z,i.lineStart();do{if(h.v=h.o.v=!0,h.e){if(f)for(o=0,l=u.length;o<l;++o)i.point((d=u[o])[0],d[1]);else r(h.x,h.n.x,1,i);h=h.n}else{if(f)for(u=h.p.z,o=u.length-1;o>=0;--o)i.point((d=u[o])[0],d[1]);else r(h.x,h.p.x,-1,i);h=h.p}h=h.o,u=h.z,f=!f}while(!h.v);i.lineEnd()}}}function Ad(e){if(t=e.length){for(var t,n=0,r=e[0],i;++n<t;)r.n=i=e[n],i.p=r,r=i;r.n=i=e[0],i.p=r}}function ml(e){return Tt(e[0])<=pt?e[0]:In(e[0])*((Tt(e[0])+pt)%Ee-pt)}function Vx(e,t){var n=ml(t),r=t[1],i=bt(r),s=[bt(n),-wt(n),0],a=0,o=0,l=new Gn;i===1?r=he+St:i===-1&&(r=-he-St);for(var c=0,u=e.length;c<u;++c)if(h=(d=e[c]).length)for(var d,h,f=d[h-1],p=ml(f),g=f[1]/2+md,m=bt(g),v=wt(g),E=0;E<h;++E,p=b,m=_,v=A,f=y){var y=d[E],b=ml(y),S=y[1]/2+md,_=bt(S),A=wt(S),R=b-p,B=R>=0?1:-1,D=B*R,O=D>pt,H=m*_;if(l.add(jn(H*B*bt(D),v*A+H*wt(D))),a+=O?R+B*Ee:R,O^p>=n^b>=n){var P=Qs(Sr(f),Sr(y));fl(P);var M=Qs(s,P);fl(M);var w=(O^R>=0?-1:1)*pn(M[2]);(r>w||r===w&&(P[0]||P[1]))&&(o+=O^R>=0?1:-1)}}return(a<-St||a<St&&l<-gd)^o&1}function Cd(e,t,n,r){return function(i){var s=t(i),a=wd(),o=t(a),l=!1,c,u,d,h={point:f,lineStart:g,lineEnd:m,polygonStart:function(){h.point=v,h.lineStart=E,h.lineEnd=y,u=[],c=[]},polygonEnd:function(){h.point=f,h.lineStart=g,h.lineEnd=m,u=ch(u);var b=Vx(c,r);u.length?(l||(i.polygonStart(),l=!0),Md(u,Wx,b,n,i)):b&&(l||(i.polygonStart(),l=!0),i.lineStart(),n(null,null,1,i),i.lineEnd()),l&&(i.polygonEnd(),l=!1),u=c=null},sphere:function(){i.polygonStart(),i.lineStart(),n(null,null,1,i),i.lineEnd(),i.polygonEnd()}};function f(b,S){e(b,S)&&i.point(b,S)}function p(b,S){s.point(b,S)}function g(){h.point=p,s.lineStart()}function m(){h.point=f,s.lineEnd()}function v(b,S){d.push([b,S]),o.point(b,S)}function E(){o.lineStart(),d=[]}function y(){v(d[0][0],d[0][1]),o.lineEnd();var b=o.clean(),S=a.result(),_,A=S.length,R,B,D;if(d.pop(),c.push(d),d=null,!!A){if(b&1){if(B=S[0],(R=B.length-1)>0){for(l||(i.polygonStart(),l=!0),i.lineStart(),_=0;_<R;++_)i.point((D=B[_])[0],D[1]);i.lineEnd()}return}A>1&&b&2&&S.push(S.pop().concat(S.shift())),u.push(S.filter(zx))}}return h}}function zx(e){return e.length>1}function Wx(e,t){return((e=e.x)[0]<0?e[1]-he-St:he-e[1])-((t=t.x)[0]<0?t[1]-he-St:he-t[1])}const Dd=Cd(function(){return!0},Yx,Xx,[-pt,-he]);function Yx(e){var t=NaN,n=NaN,r=NaN,i;return{lineStart:function(){e.lineStart(),i=1},point:function(s,a){var o=s>0?pt:-pt,l=Tt(s-t);Tt(l-pt)<St?(e.point(t,n=(n+a)/2>0?he:-he),e.point(r,n),e.lineEnd(),e.lineStart(),e.point(o,n),e.point(s,n),i=0):r!==o&&l>=pt&&(Tt(t-r)<St&&(t-=r*St),Tt(s-o)<St&&(s-=o*St),n=qx(t,n,s,a),e.point(r,n),e.lineEnd(),e.lineStart(),e.point(o,n),i=0),e.point(t=s,n=a),r=o},lineEnd:function(){e.lineEnd(),t=n=NaN},clean:function(){return 2-i}}}function qx(e,t,n,r){var i,s,a=bt(e-n);return Tt(a)>St?vd((bt(t)*(s=wt(r))*bt(n)-bt(r)*(i=wt(t))*bt(e))/(i*s*a)):(t+r)/2}function Xx(e,t,n,r){var i;if(e==null)i=n*he,r.point(-pt,i),r.point(0,i),r.point(pt,i),r.point(pt,0),r.point(pt,-i),r.point(0,-i),r.point(-pt,-i),r.point(-pt,0),r.point(-pt,i);else if(Tt(e[0]-t[0])>St){var s=e[0]<t[0]?pt:-pt;i=n*s/2,r.point(-s,i),r.point(0,i),r.point(s,i)}else r.point(t[0],t[1])}function jx(e){var t=wt(e),n=2*$t,r=t>0,i=Tt(t)>St;function s(u,d,h,f){Gx(f,e,n,h,u,d)}function a(u,d){return wt(u)*wt(d)>t}function o(u){var d,h,f,p,g;return{lineStart:function(){p=f=!1,g=1},point:function(m,v){var E=[m,v],y,b=a(m,v),S=r?b?0:c(m,v):b?c(m+(m<0?pt:-pt),v):0;if(!d&&(p=f=b)&&u.lineStart(),b!==f&&(y=l(d,E),(!y||ta(d,y)||ta(E,y))&&(E[2]=1)),b!==f)g=0,b?(u.lineStart(),y=l(E,d),u.point(y[0],y[1])):(y=l(d,E),u.point(y[0],y[1],2),u.lineEnd()),d=y;else if(i&&d&&r^b){var _;!(S&h)&&(_=l(E,d,!0))&&(g=0,r?(u.lineStart(),u.point(_[0][0],_[0][1]),u.point(_[1][0],_[1][1]),u.lineEnd()):(u.point(_[1][0],_[1][1]),u.lineEnd(),u.lineStart(),u.point(_[0][0],_[0][1],3)))}b&&(!d||!ta(d,E))&&u.point(E[0],E[1]),d=E,f=b,h=S},lineEnd:function(){f&&u.lineEnd(),d=null},clean:function(){return g|(p&&f)<<1}}}function l(u,d,h){var f=Sr(u),p=Sr(d),g=[1,0,0],m=Qs(f,p),v=Ks(m,m),E=m[0],y=v-E*E;if(!y)return!h&&u;var b=t*v/y,S=-t*E/y,_=Qs(g,m),A=Js(g,b),R=Js(m,S);dl(A,R);var B=_,D=Ks(A,B),O=Ks(B,B),H=D*D-O*(Ks(A,A)-1);if(!(H<0)){var P=Fe(H),M=Js(B,(-D-P)/O);if(dl(M,A),M=hl(M),!h)return M;var w=u[0],U=d[0],$=u[1],N=d[1],F;U<w&&(F=w,w=U,U=F);var Y=U-w,Z=Tt(Y-pt)<St,K=Z||Y<St;if(!Z&&N<$&&(F=$,$=N,N=F),K?Z?$+N>0^M[1]<(Tt(M[0]-w)<St?$:N):$<=M[1]&&M[1]<=N:Y>pt^(w<=M[0]&&M[0]<=U)){var dt=Js(B,(-D+P)/O);return dl(dt,A),[M,hl(dt)]}}}function c(u,d){var h=r?e:pt-e,f=0;return u<-h?f|=1:u>h&&(f|=2),d<-h?f|=4:d>h&&(f|=8),f}return Cd(a,o,s,r?[0,-e]:[-pt,e-pt])}function Zx(e,t,n,r,i,s){var a=e[0],o=e[1],l=t[0],c=t[1],u=0,d=1,h=l-a,f=c-o,p;if(p=n-a,!(!h&&p>0)){if(p/=h,h<0){if(p<u)return;p<d&&(d=p)}else if(h>0){if(p>d)return;p>u&&(u=p)}if(p=i-a,!(!h&&p<0)){if(p/=h,h<0){if(p>d)return;p>u&&(u=p)}else if(h>0){if(p<u)return;p<d&&(d=p)}if(p=r-o,!(!f&&p>0)){if(p/=f,f<0){if(p<u)return;p<d&&(d=p)}else if(f>0){if(p>d)return;p>u&&(u=p)}if(p=s-o,!(!f&&p<0)){if(p/=f,f<0){if(p>d)return;p>u&&(u=p)}else if(f>0){if(p<u)return;p<d&&(d=p)}return u>0&&(e[0]=a+u*h,e[1]=o+u*f),d<1&&(t[0]=a+d*h,t[1]=o+d*f),!0}}}}}var xi=1e9,na=-xi;function Kx(e,t,n,r){function i(c,u){return e<=c&&c<=n&&t<=u&&u<=r}function s(c,u,d,h){var f=0,p=0;if(c==null||(f=a(c,d))!==(p=a(u,d))||l(c,u)<0^d>0)do h.point(f===0||f===3?e:n,f>1?r:t);while((f=(f+d+4)%4)!==p);else h.point(u[0],u[1])}function a(c,u){return Tt(c[0]-e)<St?u>0?0:3:Tt(c[0]-n)<St?u>0?2:1:Tt(c[1]-t)<St?u>0?1:0:u>0?3:2}function o(c,u){return l(c.x,u.x)}function l(c,u){var d=a(c,1),h=a(u,1);return d!==h?d-h:d===0?u[1]-c[1]:d===1?c[0]-u[0]:d===2?c[1]-u[1]:u[0]-c[0]}return function(c){var u=c,d=wd(),h,f,p,g,m,v,E,y,b,S,_,A={point:R,lineStart:H,lineEnd:P,polygonStart:D,polygonEnd:O};function R(w,U){i(w,U)&&u.point(w,U)}function B(){for(var w=0,U=0,$=f.length;U<$;++U)for(var N=f[U],F=1,Y=N.length,Z=N[0],K,dt,it=Z[0],ft=Z[1];F<Y;++F)K=it,dt=ft,Z=N[F],it=Z[0],ft=Z[1],dt<=r?ft>r&&(it-K)*(r-dt)>(ft-dt)*(e-K)&&++w:ft<=r&&(it-K)*(r-dt)<(ft-dt)*(e-K)&&--w;return w}function D(){u=d,h=[],f=[],_=!0}function O(){var w=B(),U=_&&w,$=(h=ch(h)).length;(U||$)&&(c.polygonStart(),U&&(c.lineStart(),s(null,null,1,c),c.lineEnd()),$&&Md(h,o,w,s,c),c.polygonEnd()),u=c,h=f=p=null}function H(){A.point=M,f&&f.push(p=[]),S=!0,b=!1,E=y=NaN}function P(){h&&(M(g,m),v&&b&&d.rejoin(),h.push(d.result())),A.point=R,b&&u.lineEnd()}function M(w,U){var $=i(w,U);if(f&&p.push([w,U]),S)g=w,m=U,v=$,S=!1,$&&(u.lineStart(),u.point(w,U));else if($&&b)u.point(w,U);else{var N=[E=Math.max(na,Math.min(xi,E)),y=Math.max(na,Math.min(xi,y))],F=[w=Math.max(na,Math.min(xi,w)),U=Math.max(na,Math.min(xi,U))];Zx(N,F,e,t,n,r)?(b||(u.lineStart(),u.point(N[0],N[1])),u.point(F[0],F[1]),$||u.lineEnd(),_=!1):$&&(u.lineStart(),u.point(w,U),_=!1)}E=w,y=U,b=$}return A}}const vl=e=>e;var yl=new Gn,El=new Gn,Ld,Rd,xl,bl,gn={point:Oe,lineStart:Oe,lineEnd:Oe,polygonStart:function(){gn.lineStart=Qx,gn.lineEnd=tb},polygonEnd:function(){gn.lineStart=gn.lineEnd=gn.point=Oe,yl.add(Tt(El)),El=new Gn},result:function(){var e=yl/2;return yl=new Gn,e}};function Qx(){gn.point=Jx}function Jx(e,t){gn.point=Id,Ld=xl=e,Rd=bl=t}function Id(e,t){El.add(bl*e-xl*t),xl=e,bl=t}function tb(){Id(Ld,Rd)}var Tr=1/0,ra=Tr,bi=-Tr,ia=bi,sa={point:eb,lineStart:Oe,lineEnd:Oe,polygonStart:Oe,polygonEnd:Oe,result:function(){var e=[[Tr,ra],[bi,ia]];return bi=ia=-(ra=Tr=1/0),e}};function eb(e,t){e<Tr&&(Tr=e),e>bi&&(bi=e),t<ra&&(ra=t),t>ia&&(ia=t)}var _l=0,Sl=0,_i=0,aa=0,oa=0,Or=0,Tl=0,Ol=0,Si=0,kd,Pd,Ke,Qe,we={point:Zn,lineStart:Nd,lineEnd:$d,polygonStart:function(){we.lineStart=ib,we.lineEnd=sb},polygonEnd:function(){we.point=Zn,we.lineStart=Nd,we.lineEnd=$d},result:function(){var e=Si?[Tl/Si,Ol/Si]:Or?[aa/Or,oa/Or]:_i?[_l/_i,Sl/_i]:[NaN,NaN];return _l=Sl=_i=aa=oa=Or=Tl=Ol=Si=0,e}};function Zn(e,t){_l+=e,Sl+=t,++_i}function Nd(){we.point=nb}function nb(e,t){we.point=rb,Zn(Ke=e,Qe=t)}function rb(e,t){var n=e-Ke,r=t-Qe,i=Fe(n*n+r*r);aa+=i*(Ke+e)/2,oa+=i*(Qe+t)/2,Or+=i,Zn(Ke=e,Qe=t)}function $d(){we.point=Zn}function ib(){we.point=ab}function sb(){Fd(kd,Pd)}function ab(e,t){we.point=Fd,Zn(kd=Ke=e,Pd=Qe=t)}function Fd(e,t){var n=e-Ke,r=t-Qe,i=Fe(n*n+r*r);aa+=i*(Ke+e)/2,oa+=i*(Qe+t)/2,Or+=i,i=Qe*e-Ke*t,Tl+=i*(Ke+e),Ol+=i*(Qe+t),Si+=i*3,Zn(Ke=e,Qe=t)}function Ud(e){this._context=e}Ud.prototype={_radius:4.5,pointRadius:function(e){return this._radius=e,this},polygonStart:function(){this._line=0},polygonEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){this._line===0&&this._context.closePath(),this._point=NaN},point:function(e,t){switch(this._point){case 0:{this._context.moveTo(e,t),this._point=1;break}case 1:{this._context.lineTo(e,t);break}default:{this._context.moveTo(e+this._radius,t),this._context.arc(e,t,this._radius,0,Ee);break}}},result:Oe};var wl=new Gn,Ml,Bd,Hd,Ti,Oi,wi={point:Oe,lineStart:function(){wi.point=ob},lineEnd:function(){Ml&&Gd(Bd,Hd),wi.point=Oe},polygonStart:function(){Ml=!0},polygonEnd:function(){Ml=null},result:function(){var e=+wl;return wl=new Gn,e}};function ob(e,t){wi.point=Gd,Bd=Ti=e,Hd=Oi=t}function Gd(e,t){Ti-=e,Oi-=t,wl.add(Fe(Ti*Ti+Oi*Oi)),Ti=e,Oi=t}let Vd,la,zd,Wd;class Yd{constructor(t){this._append=t==null?qd:lb(t),this._radius=4.5,this._=""}pointRadius(t){return this._radius=+t,this}polygonStart(){this._line=0}polygonEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){this._line===0&&(this._+="Z"),this._point=NaN}point(t,n){switch(this._point){case 0:{this._append`M${t},${n}`,this._point=1;break}case 1:{this._append`L${t},${n}`;break}default:{if(this._append`M${t},${n}`,this._radius!==zd||this._append!==la){const r=this._radius,i=this._;this._="",this._append`m0,${r}a${r},${r} 0 1,1 0,${-2*r}a${r},${r} 0 1,1 0,${2*r}z`,zd=r,la=this._append,Wd=this._,this._=i}this._+=Wd;break}}}result(){const t=this._;return this._="",t.length?t:null}}function qd(e){let t=1;this._+=e[0];for(const n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function lb(e){const t=Math.floor(e);if(!(t>=0))throw new RangeError(`invalid digits: ${e}`);if(t>15)return qd;if(t!==Vd){const n=10**t;Vd=t,la=function(i){let s=1;this._+=i[0];for(const a=i.length;s<a;++s)this._+=Math.round(arguments[s]*n)/n+i[s]}}return la}function cb(e,t){let n=3,r=4.5,i,s;function a(o){return o&&(typeof r=="function"&&s.pointRadius(+r.apply(this,arguments)),_r(o,i(s))),s.result()}return a.area=function(o){return _r(o,i(gn)),gn.result()},a.measure=function(o){return _r(o,i(wi)),wi.result()},a.bounds=function(o){return _r(o,i(sa)),sa.result()},a.centroid=function(o){return _r(o,i(we)),we.result()},a.projection=function(o){return arguments.length?(i=o==null?(e=null,vl):(e=o).stream,a):e},a.context=function(o){return arguments.length?(s=o==null?(t=null,new Yd(n)):new Ud(t=o),typeof r!="function"&&s.pointRadius(r),a):t},a.pointRadius=function(o){return arguments.length?(r=typeof o=="function"?o:(s.pointRadius(+o),+o),a):r},a.digits=function(o){if(!arguments.length)return n;if(o==null)n=null;else{const l=Math.floor(o);if(!(l>=0))throw new RangeError(`invalid digits: ${o}`);n=l}return t===null&&(s=new Yd(n)),a},a.projection(e).digits(n).context(t)}function Al(e){return function(t){var n=new Cl;for(var r in e)n[r]=e[r];return n.stream=t,n}}function Cl(){}Cl.prototype={constructor:Cl,point:function(e,t){this.stream.point(e,t)},sphere:function(){this.stream.sphere()},lineStart:function(){this.stream.lineStart()},lineEnd:function(){this.stream.lineEnd()},polygonStart:function(){this.stream.polygonStart()},polygonEnd:function(){this.stream.polygonEnd()}};function Dl(e,t,n){var r=e.clipExtent&&e.clipExtent();return e.scale(150).translate([0,0]),r!=null&&e.clipExtent(null),_r(n,e.stream(sa)),t(sa.result()),r!=null&&e.clipExtent(r),e}function Xd(e,t,n){return Dl(e,function(r){var i=t[1][0]-t[0][0],s=t[1][1]-t[0][1],a=Math.min(i/(r[1][0]-r[0][0]),s/(r[1][1]-r[0][1])),o=+t[0][0]+(i-a*(r[1][0]+r[0][0]))/2,l=+t[0][1]+(s-a*(r[1][1]+r[0][1]))/2;e.scale(150*a).translate([o,l])},n)}function ub(e,t,n){return Xd(e,[[0,0],t],n)}function hb(e,t,n){return Dl(e,function(r){var i=+t,s=i/(r[1][0]-r[0][0]),a=(i-s*(r[1][0]+r[0][0]))/2,o=-s*r[0][1];e.scale(150*s).translate([a,o])},n)}function db(e,t,n){return Dl(e,function(r){var i=+t,s=i/(r[1][1]-r[0][1]),a=-s*r[0][0],o=(i-s*(r[1][1]+r[0][1]))/2;e.scale(150*s).translate([a,o])},n)}var jd=16,fb=wt(30*$t);function Zd(e,t){return+t?gb(e,t):pb(e)}function pb(e){return Al({point:function(t,n){t=e(t,n),this.stream.point(t[0],t[1])}})}function gb(e,t){function n(r,i,s,a,o,l,c,u,d,h,f,p,g,m){var v=c-r,E=u-i,y=v*v+E*E;if(y>4*t&&g--){var b=a+h,S=o+f,_=l+p,A=Fe(b*b+S*S+_*_),R=pn(_/=A),B=Tt(Tt(_)-1)<St||Tt(s-d)<St?(s+d)/2:jn(S,b),D=e(B,R),O=D[0],H=D[1],P=O-r,M=H-i,w=E*P-v*M;(w*w/y>t||Tt((v*P+E*M)/y-.5)>.3||a*h+o*f+l*p<fb)&&(n(r,i,s,a,o,l,O,H,B,b/=A,S/=A,_,g,m),m.point(O,H),n(O,H,B,b,S,_,c,u,d,h,f,p,g,m))}}return function(r){var i,s,a,o,l,c,u,d,h,f,p,g,m={point:v,lineStart:E,lineEnd:b,polygonStart:function(){r.polygonStart(),m.lineStart=S},polygonEnd:function(){r.polygonEnd(),m.lineStart=E}};function v(R,B){R=e(R,B),r.point(R[0],R[1])}function E(){d=NaN,m.point=y,r.lineStart()}function y(R,B){var D=Sr([R,B]),O=e(R,B);n(d,h,u,f,p,g,d=O[0],h=O[1],u=R,f=D[0],p=D[1],g=D[2],jd,r),r.point(d,h)}function b(){m.point=v,r.lineEnd()}function S(){E(),m.point=_,m.lineEnd=A}function _(R,B){y(i=R,B),s=d,a=h,o=f,l=p,c=g,m.point=y}function A(){n(d,h,u,f,p,g,s,a,i,o,l,c,jd,r),m.lineEnd=b,b()}return m}}var mb=Al({point:function(e,t){this.stream.point(e*$t,t*$t)}});function vb(e){return Al({point:function(t,n){var r=e(t,n);return this.stream.point(r[0],r[1])}})}function yb(e,t,n,r,i){function s(a,o){return a*=r,o*=i,[t+e*a,n-e*o]}return s.invert=function(a,o){return[(a-t)/e*r,(n-o)/e*i]},s}function Kd(e,t,n,r,i,s){if(!s)return yb(e,t,n,r,i);var a=wt(s),o=bt(s),l=a*e,c=o*e,u=a/e,d=o/e,h=(o*n-a*t)/e,f=(o*t+a*n)/e;function p(g,m){return g*=r,m*=i,[l*g-c*m+t,n-c*g-l*m]}return p.invert=function(g,m){return[r*(u*g-d*m+h),i*(f-d*g-u*m)]},p}function ca(e){return Qd(function(){return e})()}function Qd(e){var t,n=150,r=480,i=250,s=0,a=0,o=0,l=0,c=0,u,d=0,h=1,f=1,p=null,g=Dd,m=null,v,E,y,b=vl,S=.5,_,A,R,B,D;function O(w){return R(w[0]*$t,w[1]*$t)}function H(w){return w=R.invert(w[0],w[1]),w&&[w[0]*re,w[1]*re]}O.stream=function(w){return B&&D===w?B:B=mb(vb(u)(g(_(b(D=w)))))},O.preclip=function(w){return arguments.length?(g=w,p=void 0,M()):g},O.postclip=function(w){return arguments.length?(b=w,m=v=E=y=null,M()):b},O.clipAngle=function(w){return arguments.length?(g=+w?jx(p=w*$t):(p=null,Dd),M()):p*re},O.clipExtent=function(w){return arguments.length?(b=w==null?(m=v=E=y=null,vl):Kx(m=+w[0][0],v=+w[0][1],E=+w[1][0],y=+w[1][1]),M()):m==null?null:[[m,v],[E,y]]},O.scale=function(w){return arguments.length?(n=+w,P()):n},O.translate=function(w){return arguments.length?(r=+w[0],i=+w[1],P()):[r,i]},O.center=function(w){return arguments.length?(s=w[0]%360*$t,a=w[1]%360*$t,P()):[s*re,a*re]},O.rotate=function(w){return arguments.length?(o=w[0]%360*$t,l=w[1]%360*$t,c=w.length>2?w[2]%360*$t:0,P()):[o*re,l*re,c*re]},O.angle=function(w){return arguments.length?(d=w%360*$t,P()):d*re},O.reflectX=function(w){return arguments.length?(h=w?-1:1,P()):h<0},O.reflectY=function(w){return arguments.length?(f=w?-1:1,P()):f<0},O.precision=function(w){return arguments.length?(_=Zd(A,S=w*w),M()):Fe(S)},O.fitExtent=function(w,U){return Xd(O,w,U)},O.fitSize=function(w,U){return ub(O,w,U)},O.fitWidth=function(w,U){return hb(O,w,U)},O.fitHeight=function(w,U){return db(O,w,U)};function P(){var w=Kd(n,0,0,h,f,d).apply(null,t(s,a)),U=Kd(n,r-w[0],i-w[1],h,f,d);return u=bd(o,l,c),A=pl(t,U),R=pl(u,A),_=Zd(A,S),M()}function M(){return B=D=null,O}return function(){return t=e.apply(this,arguments),O.invert=t.invert&&H,P()}}function Jd(e){var t=0,n=pt/3,r=Qd(e),i=r(t,n);return i.parallels=function(s){return arguments.length?r(t=s[0]*$t,n=s[1]*$t):[t*re,n*re]},i}function Eb(e){var t=wt(e);function n(r,i){return[r*t,bt(i)/t]}return n.invert=function(r,i){return[r/t,pn(i*t)]},n}function xb(e,t){var n=bt(e),r=(n+bt(t))/2;if(Tt(r)<St)return Eb(e);var i=1+n*(2*r-n),s=Fe(i)/r;function a(o,l){var c=Fe(i-2*r*bt(l))/r;return[c*bt(o*=r),s-c*wt(o)]}return a.invert=function(o,l){var c=s-l,u=jn(o,Tt(c))*In(c);return c*r<0&&(u-=pt*In(o)*In(c)),[u/r,pn((i-(o*o+c*c)*r*r)/(2*r))]},a}function tf(){return Jd(xb).scale(155.424).center([0,33.6442])}function bb(){return tf().parallels([29.5,45.5]).scale(1070).translate([480,250]).rotate([96,0]).center([-.6,38.7])}function Ll(e,t){return[e,Fx(Ux((he+t)/2))]}Ll.invert=function(e,t){return[e,2*vd($x(t))-he]};function _b(){return Sb(Ll).scale(961/Ee)}function Sb(e){var t=ca(e),n=t.center,r=t.scale,i=t.translate,s=t.clipExtent,a=null,o,l,c;t.scale=function(d){return arguments.length?(r(d),u()):r()},t.translate=function(d){return arguments.length?(i(d),u()):i()},t.center=function(d){return arguments.length?(n(d),u()):n()},t.clipExtent=function(d){return arguments.length?(d==null?a=o=l=c=null:(a=+d[0][0],o=+d[0][1],l=+d[1][0],c=+d[1][1]),u()):a==null?null:[[a,o],[l,c]]};function u(){var d=pt*r(),h=t(Hx(t.rotate()).invert([0,0]));return s(a==null?[[h[0]-d,h[1]-d],[h[0]+d,h[1]+d]]:e===Ll?[[Math.max(h[0]-d,a),o],[Math.min(h[0]+d,l),c]]:[[a,Math.max(h[1]-d,o)],[l,Math.min(h[1]+d,c)]])}return u()}function ua(e,t){return[e,t]}ua.invert=ua;function Tb(){return ca(ua).scale(152.63)}function Ob(e,t){var n=wt(e),r=e===t?bt(e):(n-wt(t))/(t-e),i=n/r+e;if(Tt(r)<St)return ua;function s(a,o){var l=i-o,c=r*a;return[l*bt(c),i-l*wt(c)]}return s.invert=function(a,o){var l=i-o,c=jn(a,Tt(l))*In(l);return l*r<0&&(c-=pt*In(a)*In(l)),[c/r,i-In(r)*Fe(a*a+l*l)]},s}function wb(){return Jd(Ob).scale(131.154).center([0,13.9389])}var Mi=1.340264,Ai=-.081106,Ci=893e-6,Di=.003796,ha=Fe(3)/2,Mb=12;function ef(e,t){var n=pn(ha*bt(t)),r=n*n,i=r*r*r;return[e*wt(n)/(ha*(Mi+3*Ai*r+i*(7*Ci+9*Di*r))),n*(Mi+Ai*r+i*(Ci+Di*r))]}ef.invert=function(e,t){for(var n=t,r=n*n,i=r*r*r,s=0,a,o,l;s<Mb&&(o=n*(Mi+Ai*r+i*(Ci+Di*r))-t,l=Mi+3*Ai*r+i*(7*Ci+9*Di*r),n-=a=o/l,r=n*n,i=r*r*r,!(Tt(a)<gd));++s);return[ha*e*(Mi+3*Ai*r+i*(7*Ci+9*Di*r))/wt(n),pn(bt(n)/ha)]};function Ab(){return ca(ef).scale(177.158)}function nf(e,t){var n=t*t,r=n*n;return[e*(.8707-.131979*n+r*(-.013791+r*(.003971*n-.001529*r))),t*(1.007226+n*(.015085+r*(-.044475+.028874*n-.005916*r)))]}nf.invert=function(e,t){var n=t,r=25,i;do{var s=n*n,a=s*s;n-=i=(n*(1.007226+s*(.015085+a*(-.044475+.028874*s-.005916*a)))-t)/(1.007226+s*(.015085*3+a*(-.044475*7+.028874*9*s-.005916*11*a)))}while(Tt(i)>St&&--r>0);return[e/(.8707+(s=n*n)*(-.131979+s*(-.013791+s*s*s*(.003971-.001529*s)))),n]};function Cb(){return ca(nf).scale(175.295)}function Db(e,t){return e.parent===t.parent?1:2}function Lb(e){return e.reduce(Rb,0)/e.length}function Rb(e,t){return e+t.x}function Ib(e){return 1+e.reduce(kb,0)}function kb(e,t){return Math.max(e,t.y)}function Pb(e){for(var t;t=e.children;)e=t[0];return e}function Nb(e){for(var t;t=e.children;)e=t[t.length-1];return e}function $b(){var e=Db,t=1,n=1,r=!1;function i(s){var a,o=0;s.eachAfter(function(h){var f=h.children;f?(h.x=Lb(f),h.y=Ib(f)):(h.x=a?o+=e(h,a):0,h.y=0,a=h)});var l=Pb(s),c=Nb(s),u=l.x-e(l,c)/2,d=c.x+e(c,l)/2;return s.eachAfter(r?function(h){h.x=(h.x-s.x)*t,h.y=(s.y-h.y)*n}:function(h){h.x=(h.x-u)/(d-u)*t,h.y=(1-(s.y?h.y/s.y:1))*n})}return i.separation=function(s){return arguments.length?(e=s,i):e},i.size=function(s){return arguments.length?(r=!1,t=+s[0],n=+s[1],i):r?null:[t,n]},i.nodeSize=function(s){return arguments.length?(r=!0,t=+s[0],n=+s[1],i):r?[t,n]:null},i}function Fb(e){var t=0,n=e.children,r=n&&n.length;if(!r)t=1;else for(;--r>=0;)t+=n[r].value;e.value=t}function Ub(){return this.eachAfter(Fb)}function Bb(e,t){let n=-1;for(const r of this)e.call(t,r,++n,this);return this}function Hb(e,t){for(var n=this,r=[n],i,s,a=-1;n=r.pop();)if(e.call(t,n,++a,this),i=n.children)for(s=i.length-1;s>=0;--s)r.push(i[s]);return this}function Gb(e,t){for(var n=this,r=[n],i=[],s,a,o,l=-1;n=r.pop();)if(i.push(n),s=n.children)for(a=0,o=s.length;a<o;++a)r.push(s[a]);for(;n=i.pop();)e.call(t,n,++l,this);return this}function Vb(e,t){let n=-1;for(const r of this)if(e.call(t,r,++n,this))return r}function zb(e){return this.eachAfter(function(t){for(var n=+e(t.data)||0,r=t.children,i=r&&r.length;--i>=0;)n+=r[i].value;t.value=n})}function Wb(e){return this.eachBefore(function(t){t.children&&t.children.sort(e)})}function Yb(e){for(var t=this,n=qb(t,e),r=[t];t!==n;)t=t.parent,r.push(t);for(var i=r.length;e!==n;)r.splice(i,0,e),e=e.parent;return r}function qb(e,t){if(e===t)return e;var n=e.ancestors(),r=t.ancestors(),i=null;for(e=n.pop(),t=r.pop();e===t;)i=e,e=n.pop(),t=r.pop();return i}function Xb(){for(var e=this,t=[e];e=e.parent;)t.push(e);return t}function jb(){return Array.from(this)}function Zb(){var e=[];return this.eachBefore(function(t){t.children||e.push(t)}),e}function Kb(){var e=this,t=[];return e.each(function(n){n!==e&&t.push({source:n.parent,target:n})}),t}function*Qb(){var e=this,t,n=[e],r,i,s;do for(t=n.reverse(),n=[];e=t.pop();)if(yield e,r=e.children)for(i=0,s=r.length;i<s;++i)n.push(r[i]);while(n.length)}function Li(e,t){e instanceof Map?(e=[void 0,e],t===void 0&&(t=e_)):t===void 0&&(t=t_);for(var n=new Ri(e),r,i=[n],s,a,o,l;r=i.pop();)if((a=t(r.data))&&(l=(a=Array.from(a)).length))for(r.children=a,o=l-1;o>=0;--o)i.push(s=a[o]=new Ri(a[o])),s.parent=r,s.depth=r.depth+1;return n.eachBefore(r_)}function Jb(){return Li(this).eachBefore(n_)}function t_(e){return e.children}function e_(e){return Array.isArray(e)?e[1]:null}function n_(e){e.data.value!==void 0&&(e.value=e.data.value),e.data=e.data.data}function r_(e){var t=0;do e.height=t;while((e=e.parent)&&e.height<++t)}function Ri(e){this.data=e,this.depth=this.height=0,this.parent=null}Ri.prototype=Li.prototype={constructor:Ri,count:Ub,each:Bb,eachAfter:Gb,eachBefore:Hb,find:Vb,sum:zb,sort:Wb,path:Yb,ancestors:Xb,descendants:jb,leaves:Zb,links:Kb,copy:Jb,[Symbol.iterator]:Qb};function i_(e){return e==null?null:rf(e)}function rf(e){if(typeof e!="function")throw new Error;return e}function Kn(){return 0}function wr(e){return function(){return e}}const s_=1664525,a_=1013904223,sf=4294967296;function o_(){let e=1;return()=>(e=(s_*e+a_)%sf)/sf}function l_(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function c_(e,t){let n=e.length,r,i;for(;n;)i=t()*n--|0,r=e[n],e[n]=e[i],e[i]=r;return e}function u_(e,t){for(var n=0,r=(e=c_(Array.from(e),t)).length,i=[],s,a;n<r;)s=e[n],a&&af(a,s)?++n:(a=d_(i=h_(i,s)),n=0);return a}function h_(e,t){var n,r;if(Rl(t,e))return[t];for(n=0;n<e.length;++n)if(da(t,e[n])&&Rl(Ii(e[n],t),e))return[e[n],t];for(n=0;n<e.length-1;++n)for(r=n+1;r<e.length;++r)if(da(Ii(e[n],e[r]),t)&&da(Ii(e[n],t),e[r])&&da(Ii(e[r],t),e[n])&&Rl(of(e[n],e[r],t),e))return[e[n],e[r],t];throw new Error}function da(e,t){var n=e.r-t.r,r=t.x-e.x,i=t.y-e.y;return n<0||n*n<r*r+i*i}function af(e,t){var n=e.r-t.r+Math.max(e.r,t.r,1)*1e-9,r=t.x-e.x,i=t.y-e.y;return n>0&&n*n>r*r+i*i}function Rl(e,t){for(var n=0;n<t.length;++n)if(!af(e,t[n]))return!1;return!0}function d_(e){switch(e.length){case 1:return f_(e[0]);case 2:return Ii(e[0],e[1]);case 3:return of(e[0],e[1],e[2])}}function f_(e){return{x:e.x,y:e.y,r:e.r}}function Ii(e,t){var n=e.x,r=e.y,i=e.r,s=t.x,a=t.y,o=t.r,l=s-n,c=a-r,u=o-i,d=Math.sqrt(l*l+c*c);return{x:(n+s+l/d*u)/2,y:(r+a+c/d*u)/2,r:(d+i+o)/2}}function of(e,t,n){var r=e.x,i=e.y,s=e.r,a=t.x,o=t.y,l=t.r,c=n.x,u=n.y,d=n.r,h=r-a,f=r-c,p=i-o,g=i-u,m=l-s,v=d-s,E=r*r+i*i-s*s,y=E-a*a-o*o+l*l,b=E-c*c-u*u+d*d,S=f*p-h*g,_=(p*b-g*y)/(S*2)-r,A=(g*m-p*v)/S,R=(f*y-h*b)/(S*2)-i,B=(h*v-f*m)/S,D=A*A+B*B-1,O=2*(s+_*A+R*B),H=_*_+R*R-s*s,P=-(Math.abs(D)>1e-6?(O+Math.sqrt(O*O-4*D*H))/(2*D):H/O);return{x:r+_+A*P,y:i+R+B*P,r:P}}function lf(e,t,n){var r=e.x-t.x,i,s,a=e.y-t.y,o,l,c=r*r+a*a;c?(s=t.r+n.r,s*=s,l=e.r+n.r,l*=l,s>l?(i=(c+l-s)/(2*c),o=Math.sqrt(Math.max(0,l/c-i*i)),n.x=e.x-i*r-o*a,n.y=e.y-i*a+o*r):(i=(c+s-l)/(2*c),o=Math.sqrt(Math.max(0,s/c-i*i)),n.x=t.x+i*r-o*a,n.y=t.y+i*a+o*r)):(n.x=t.x+n.r,n.y=t.y)}function cf(e,t){var n=e.r+t.r-1e-6,r=t.x-e.x,i=t.y-e.y;return n>0&&n*n>r*r+i*i}function uf(e){var t=e._,n=e.next._,r=t.r+n.r,i=(t.x*n.r+n.x*t.r)/r,s=(t.y*n.r+n.y*t.r)/r;return i*i+s*s}function fa(e){this._=e,this.next=null,this.previous=null}function p_(e,t){if(!(s=(e=l_(e)).length))return 0;var n,r,i,s,a,o,l,c,u,d,h;if(n=e[0],n.x=0,n.y=0,!(s>1))return n.r;if(r=e[1],n.x=-r.r,r.x=n.r,r.y=0,!(s>2))return n.r+r.r;lf(r,n,i=e[2]),n=new fa(n),r=new fa(r),i=new fa(i),n.next=i.previous=r,r.next=n.previous=i,i.next=r.previous=n;t:for(l=3;l<s;++l){lf(n._,r._,i=e[l]),i=new fa(i),c=r.next,u=n.previous,d=r._.r,h=n._.r;do if(d<=h){if(cf(c._,i._)){r=c,n.next=r,r.previous=n,--l;continue t}d+=c._.r,c=c.next}else{if(cf(u._,i._)){n=u,n.next=r,r.previous=n,--l;continue t}h+=u._.r,u=u.previous}while(c!==u.next);for(i.previous=n,i.next=r,n.next=r.previous=r=i,a=uf(n);(i=i.next)!==r;)(o=uf(i))<a&&(n=i,a=o);r=n.next}for(n=[r._],i=r;(i=i.next)!==r;)n.push(i._);for(i=u_(n,t),l=0;l<s;++l)n=e[l],n.x-=i.x,n.y-=i.y;return i.r}function g_(e){return Math.sqrt(e.value)}function m_(){var e=null,t=1,n=1,r=Kn;function i(s){const a=o_();return s.x=t/2,s.y=n/2,e?s.eachBefore(hf(e)).eachAfter(Il(r,.5,a)).eachBefore(df(1)):s.eachBefore(hf(g_)).eachAfter(Il(Kn,1,a)).eachAfter(Il(r,s.r/Math.min(t,n),a)).eachBefore(df(Math.min(t,n)/(2*s.r))),s}return i.radius=function(s){return arguments.length?(e=i_(s),i):e},i.size=function(s){return arguments.length?(t=+s[0],n=+s[1],i):[t,n]},i.padding=function(s){return arguments.length?(r=typeof s=="function"?s:wr(+s),i):r},i}function hf(e){return function(t){t.children||(t.r=Math.max(0,+e(t)||0))}}function Il(e,t,n){return function(r){if(i=r.children){var i,s,a=i.length,o=e(r)*t||0,l;if(o)for(s=0;s<a;++s)i[s].r+=o;if(l=p_(i,n),o)for(s=0;s<a;++s)i[s].r-=o;r.r=l+o}}}function df(e){return function(t){var n=t.parent;t.r*=e,n&&(t.x=n.x+e*t.x,t.y=n.y+e*t.y)}}function v_(e){e.x0=Math.round(e.x0),e.y0=Math.round(e.y0),e.x1=Math.round(e.x1),e.y1=Math.round(e.y1)}function y_(e,t,n,r,i){for(var s=e.children,a,o=-1,l=s.length,c=e.value&&(r-t)/e.value;++o<l;)a=s[o],a.y0=n,a.y1=i,a.x0=t,a.x1=t+=a.value*c}function E_(e,t){return e.parent===t.parent?1:2}function kl(e){var t=e.children;return t?t[0]:e.t}function Pl(e){var t=e.children;return t?t[t.length-1]:e.t}function x_(e,t,n){var r=n/(t.i-e.i);t.c-=r,t.s+=n,e.c+=r,t.z+=n,t.m+=n}function b_(e){for(var t=0,n=0,r=e.children,i=r.length,s;--i>=0;)s=r[i],s.z+=t,s.m+=t,t+=s.s+(n+=s.c)}function __(e,t,n){return e.a.parent===t.parent?e.a:n}function pa(e,t){this._=e,this.parent=null,this.children=null,this.A=null,this.a=this,this.z=0,this.m=0,this.c=0,this.s=0,this.t=null,this.i=t}pa.prototype=Object.create(Ri.prototype);function S_(e){for(var t=new pa(e,0),n,r=[t],i,s,a,o;n=r.pop();)if(s=n._.children)for(n.children=new Array(o=s.length),a=o-1;a>=0;--a)r.push(i=n.children[a]=new pa(s[a],a)),i.parent=n;return(t.parent=new pa(null,0)).children=[t],t}function T_(){var e=E_,t=1,n=1,r=null;function i(c){var u=S_(c);if(u.eachAfter(s),u.parent.m=-u.z,u.eachBefore(a),r)c.eachBefore(l);else{var d=c,h=c,f=c;c.eachBefore(function(E){E.x<d.x&&(d=E),E.x>h.x&&(h=E),E.depth>f.depth&&(f=E)});var p=d===h?1:e(d,h)/2,g=p-d.x,m=t/(h.x+p+g),v=n/(f.depth||1);c.eachBefore(function(E){E.x=(E.x+g)*m,E.y=E.depth*v})}return c}function s(c){var u=c.children,d=c.parent.children,h=c.i?d[c.i-1]:null;if(u){b_(c);var f=(u[0].z+u[u.length-1].z)/2;h?(c.z=h.z+e(c._,h._),c.m=c.z-f):c.z=f}else h&&(c.z=h.z+e(c._,h._));c.parent.A=o(c,h,c.parent.A||d[0])}function a(c){c._.x=c.z+c.parent.m,c.m+=c.parent.m}function o(c,u,d){if(u){for(var h=c,f=c,p=u,g=h.parent.children[0],m=h.m,v=f.m,E=p.m,y=g.m,b;p=Pl(p),h=kl(h),p&&h;)g=kl(g),f=Pl(f),f.a=c,b=p.z+E-h.z-m+e(p._,h._),b>0&&(x_(__(p,c,d),c,b),m+=b,v+=b),E+=p.m,m+=h.m,y+=g.m,v+=f.m;p&&!Pl(f)&&(f.t=p,f.m+=E-v),h&&!kl(g)&&(g.t=h,g.m+=m-y,d=c)}return d}function l(c){c.x*=t,c.y=c.depth*n}return i.separation=function(c){return arguments.length?(e=c,i):e},i.size=function(c){return arguments.length?(r=!1,t=+c[0],n=+c[1],i):r?null:[t,n]},i.nodeSize=function(c){return arguments.length?(r=!0,t=+c[0],n=+c[1],i):r?[t,n]:null},i}function O_(e,t,n,r,i){for(var s=e.children,a,o=-1,l=s.length,c=e.value&&(i-n)/e.value;++o<l;)a=s[o],a.x0=t,a.x1=r,a.y0=n,a.y1=n+=a.value*c}var w_=(1+Math.sqrt(5))/2;function M_(e,t,n,r,i,s){for(var a=[],o=t.children,l,c,u=0,d=0,h=o.length,f,p,g=t.value,m,v,E,y,b,S,_;u<h;){f=i-n,p=s-r;do m=o[d++].value;while(!m&&d<h);for(v=E=m,S=Math.max(p/f,f/p)/(g*e),_=m*m*S,b=Math.max(E/_,_/v);d<h;++d){if(m+=c=o[d].value,c<v&&(v=c),c>E&&(E=c),_=m*m*S,y=Math.max(E/_,_/v),y>b){m-=c;break}b=y}a.push(l={value:m,dice:f<p,children:o.slice(u,d)}),l.dice?y_(l,n,r,i,g?r+=p*m/g:s):O_(l,n,r,g?n+=f*m/g:i,s),g-=m,u=d}return a}const A_=function e(t){function n(r,i,s,a,o){M_(t,r,i,s,a,o)}return n.ratio=function(r){return e((r=+r)>1?r:1)},n}(w_);function C_(){var e=A_,t=!1,n=1,r=1,i=[0],s=Kn,a=Kn,o=Kn,l=Kn,c=Kn;function u(h){return h.x0=h.y0=0,h.x1=n,h.y1=r,h.eachBefore(d),i=[0],t&&h.eachBefore(v_),h}function d(h){var f=i[h.depth],p=h.x0+f,g=h.y0+f,m=h.x1-f,v=h.y1-f;m<p&&(p=m=(p+m)/2),v<g&&(g=v=(g+v)/2),h.x0=p,h.y0=g,h.x1=m,h.y1=v,h.children&&(f=i[h.depth+1]=s(h)/2,p+=c(h)-f,g+=a(h)-f,m-=o(h)-f,v-=l(h)-f,m<p&&(p=m=(p+m)/2),v<g&&(g=v=(g+v)/2),e(h,p,g,m,v))}return u.round=function(h){return arguments.length?(t=!!h,u):t},u.size=function(h){return arguments.length?(n=+h[0],r=+h[1],u):[n,r]},u.tile=function(h){return arguments.length?(e=rf(h),u):e},u.padding=function(h){return arguments.length?u.paddingInner(h).paddingOuter(h):u.paddingInner()},u.paddingInner=function(h){return arguments.length?(s=typeof h=="function"?h:wr(+h),u):s},u.paddingOuter=function(h){return arguments.length?u.paddingTop(h).paddingRight(h).paddingBottom(h).paddingLeft(h):u.paddingTop()},u.paddingTop=function(h){return arguments.length?(a=typeof h=="function"?h:wr(+h),u):a},u.paddingRight=function(h){return arguments.length?(o=typeof h=="function"?h:wr(+h),u):o},u.paddingBottom=function(h){return arguments.length?(l=typeof h=="function"?h:wr(+h),u):l},u.paddingLeft=function(h){return arguments.length?(c=typeof h=="function"?h:wr(+h),u):c},u}function Mr(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}const ff=Symbol("implicit");function ga(){var e=new sh,t=[],n=[],r=ff;function i(s){let a=e.get(s);if(a===void 0){if(r!==ff)return r;e.set(s,a=t.push(s)-1)}return n[a%n.length]}return i.domain=function(s){if(!arguments.length)return t.slice();t=[],e=new sh;for(const a of s)e.has(a)||e.set(a,t.push(a)-1);return i},i.range=function(s){return arguments.length?(n=Array.from(s),i):n.slice()},i.unknown=function(s){return arguments.length?(r=s,i):r},i.copy=function(){return ga(t,n).unknown(r)},Mr.apply(i,arguments),i}function ki(){var e=ga().unknown(void 0),t=e.domain,n=e.range,r=0,i=1,s,a,o=!1,l=0,c=0,u=.5;delete e.unknown;function d(){var h=t().length,f=i<r,p=f?i:r,g=f?r:i;s=(g-p)/Math.max(1,h-l+c*2),o&&(s=Math.floor(s)),p+=(g-p-s*(h-l))*u,a=s*(1-l),o&&(p=Math.round(p),a=Math.round(a));var m=F0(h).map(function(v){return p+s*v});return n(f?m.reverse():m)}return e.domain=function(h){return arguments.length?(t(h),d()):t()},e.range=function(h){return arguments.length?([r,i]=h,r=+r,i=+i,d()):[r,i]},e.rangeRound=function(h){return[r,i]=h,r=+r,i=+i,o=!0,d()},e.bandwidth=function(){return a},e.step=function(){return s},e.round=function(h){return arguments.length?(o=!!h,d()):o},e.padding=function(h){return arguments.length?(l=Math.min(1,c=+h),d()):l},e.paddingInner=function(h){return arguments.length?(l=Math.min(1,h),d()):l},e.paddingOuter=function(h){return arguments.length?(c=+h,d()):c},e.align=function(h){return arguments.length?(u=Math.max(0,Math.min(1,h)),d()):u},e.copy=function(){return ki(t(),[r,i]).round(o).paddingInner(l).paddingOuter(c).align(u)},Mr.apply(d(),arguments)}function D_(e){return function(){return e}}function L_(e){return+e}var pf=[0,1];function Ar(e){return e}function Nl(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:D_(isNaN(t)?NaN:.5)}function R_(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function I_(e,t,n){var r=e[0],i=e[1],s=t[0],a=t[1];return i<r?(r=Nl(i,r),s=n(a,s)):(r=Nl(r,i),s=n(s,a)),function(o){return s(r(o))}}function k_(e,t,n){var r=Math.min(e.length,t.length)-1,i=new Array(r),s=new Array(r),a=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++a<r;)i[a]=Nl(e[a],e[a+1]),s[a]=n(t[a],t[a+1]);return function(o){var l=Ao(e,o,1,r)-1;return s[l](i[l](o))}}function $l(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function gf(){var e=pf,t=pf,n=pi,r,i,s,a=Ar,o,l,c;function u(){var h=Math.min(e.length,t.length);return a!==Ar&&(a=R_(e[0],e[h-1])),o=h>2?k_:I_,l=c=null,d}function d(h){return h==null||isNaN(h=+h)?s:(l||(l=o(e.map(r),t,n)))(r(a(h)))}return d.invert=function(h){return a(i((c||(c=o(t,e.map(r),ye)))(h)))},d.domain=function(h){return arguments.length?(e=Array.from(h,L_),u()):e.slice()},d.range=function(h){return arguments.length?(t=Array.from(h),u()):t.slice()},d.rangeRound=function(h){return t=Array.from(h),n=Fh,u()},d.clamp=function(h){return arguments.length?(a=h?!0:Ar,u()):a!==Ar},d.interpolate=function(h){return arguments.length?(n=h,u()):n},d.unknown=function(h){return arguments.length?(s=h,d):s},function(h,f){return r=h,i=f,u()}}function mf(){return gf()(Ar,Ar)}function P_(e,t,n,r){var i=Do(e,t,n),s;switch(r=Ei(r??",f"),r.type){case"s":{var a=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(s=Px(i,a))&&(r.precision=s),pd(r,a)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(s=Nx(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=s-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(s=kx(i))&&(r.precision=s-(r.type==="%")*2);break}}return cl(r)}function vf(e){var t=e.domain;return e.ticks=function(n){var r=t();return ws(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var i=t();return P_(i[0],i[i.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),i=0,s=r.length-1,a=r[i],o=r[s],l,c,u=10;for(o<a&&(c=a,a=o,o=c,c=i,i=s,s=c);u-- >0;){if(c=gr(a,o,n),c===l)return r[i]=a,r[s]=o,t(r);if(c>0)a=Math.floor(a/c)*c,o=Math.ceil(o/c)*c;else if(c<0)a=Math.ceil(a*c)/c,o=Math.floor(o*c)/c;else break;l=c}return e},e}function Ue(){var e=mf();return e.copy=function(){return $l(e,Ue())},Mr.apply(e,arguments),vf(e)}function yf(e,t){e=e.slice();var n=0,r=e.length-1,i=e[n],s=e[r],a;return s<i&&(a=n,n=r,r=a,a=i,i=s,s=a),e[n]=t.floor(i),e[r]=t.ceil(s),e}function Ef(e){return Math.log(e)}function xf(e){return Math.exp(e)}function N_(e){return-Math.log(-e)}function $_(e){return-Math.exp(-e)}function F_(e){return isFinite(e)?+("1e"+e):e<0?0:e}function U_(e){return e===10?F_:e===Math.E?Math.exp:t=>Math.pow(e,t)}function B_(e){return e===Math.E?Math.log:e===10&&Math.log10||e===2&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}function bf(e){return(t,n)=>-e(-t,n)}function H_(e){const t=e(Ef,xf),n=t.domain;let r=10,i,s;function a(){return i=B_(r),s=U_(r),n()[0]<0?(i=bf(i),s=bf(s),e(N_,$_)):e(Ef,xf),t}return t.base=function(o){return arguments.length?(r=+o,a()):r},t.domain=function(o){return arguments.length?(n(o),a()):n()},t.ticks=o=>{const l=n();let c=l[0],u=l[l.length-1];const d=u<c;d&&([c,u]=[u,c]);let h=i(c),f=i(u),p,g;const m=o==null?10:+o;let v=[];if(!(r%1)&&f-h<m){if(h=Math.floor(h),f=Math.ceil(f),c>0){for(;h<=f;++h)for(p=1;p<r;++p)if(g=h<0?p/s(-h):p*s(h),!(g<c)){if(g>u)break;v.push(g)}}else for(;h<=f;++h)for(p=r-1;p>=1;--p)if(g=h>0?p/s(-h):p*s(h),!(g<c)){if(g>u)break;v.push(g)}v.length*2<m&&(v=ws(c,u,m))}else v=ws(h,f,Math.min(f-h,m)).map(s);return d?v.reverse():v},t.tickFormat=(o,l)=>{if(o==null&&(o=10),l==null&&(l=r===10?"s":","),typeof l!="function"&&(!(r%1)&&(l=Ei(l)).precision==null&&(l.trim=!0),l=cl(l)),o===1/0)return l;const c=Math.max(1,r*o/t.ticks().length);return u=>{let d=u/s(Math.round(i(u)));return d*r<r-.5&&(d*=r),d<=c?l(u):""}},t.nice=()=>n(yf(n(),{floor:o=>s(Math.floor(i(o))),ceil:o=>s(Math.ceil(i(o)))})),t}function _f(){const e=H_(gf()).domain([1,10]);return e.copy=()=>$l(e,_f()).base(e.base()),Mr.apply(e,arguments),e}function Fl(){var e=0,t=1,n=1,r=[.5],i=[0,1],s;function a(l){return l!=null&&l<=l?i[Ao(r,l,0,n)]:s}function o(){var l=-1;for(r=new Array(n);++l<n;)r[l]=((l+1)*t-(l-n)*e)/(n+1);return a}return a.domain=function(l){return arguments.length?([e,t]=l,e=+e,t=+t,o()):[e,t]},a.range=function(l){return arguments.length?(n=(i=Array.from(l)).length-1,o()):i.slice()},a.invertExtent=function(l){var c=i.indexOf(l);return c<0?[NaN,NaN]:c<1?[e,r[0]]:c>=n?[r[n-1],t]:[r[c-1],r[c]]},a.unknown=function(l){return arguments.length&&(s=l),a},a.thresholds=function(){return r.slice()},a.copy=function(){return Fl().domain([e,t]).range(i).unknown(s)},Mr.apply(vf(a),arguments)}const Ul=new Date,Bl=new Date;function Wt(e,t,n,r){function i(s){return e(s=arguments.length===0?new Date:new Date(+s)),s}return i.floor=s=>(e(s=new Date(+s)),s),i.ceil=s=>(e(s=new Date(s-1)),t(s,1),e(s),s),i.round=s=>{const a=i(s),o=i.ceil(s);return s-a<o-s?a:o},i.offset=(s,a)=>(t(s=new Date(+s),a==null?1:Math.floor(a)),s),i.range=(s,a,o)=>{const l=[];if(s=i.ceil(s),o=o==null?1:Math.floor(o),!(s<a)||!(o>0))return l;let c;do l.push(c=new Date(+s)),t(s,o),e(s);while(c<s&&s<a);return l},i.filter=s=>Wt(a=>{if(a>=a)for(;e(a),!s(a);)a.setTime(a-1)},(a,o)=>{if(a>=a)if(o<0)for(;++o<=0;)for(;t(a,-1),!s(a););else for(;--o>=0;)for(;t(a,1),!s(a););}),n&&(i.count=(s,a)=>(Ul.setTime(+s),Bl.setTime(+a),e(Ul),e(Bl),Math.floor(n(Ul,Bl))),i.every=s=>(s=Math.floor(s),!isFinite(s)||!(s>0)?null:s>1?i.filter(r?a=>r(a)%s===0:a=>i.count(0,a)%s===0):i)),i}const ma=Wt(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);ma.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?Wt(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):ma),ma.range;const mn=1e3,Me=mn*60,vn=Me*60,yn=vn*24,Hl=yn*7,Sf=yn*30,Gl=yn*365,Cr=Wt(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*mn)},(e,t)=>(t-e)/mn,e=>e.getUTCSeconds());Cr.range;const Vl=Wt(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*mn)},(e,t)=>{e.setTime(+e+t*Me)},(e,t)=>(t-e)/Me,e=>e.getMinutes());Vl.range,Wt(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Me)},(e,t)=>(t-e)/Me,e=>e.getUTCMinutes()).range;const zl=Wt(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*mn-e.getMinutes()*Me)},(e,t)=>{e.setTime(+e+t*vn)},(e,t)=>(t-e)/vn,e=>e.getHours());zl.range,Wt(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*vn)},(e,t)=>(t-e)/vn,e=>e.getUTCHours()).range;const Pi=Wt(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Me)/yn,e=>e.getDate()-1);Pi.range;const Wl=Wt(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/yn,e=>e.getUTCDate()-1);Wl.range,Wt(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/yn,e=>Math.floor(e/yn)).range;function Qn(e){return Wt(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,n)=>{t.setDate(t.getDate()+n*7)},(t,n)=>(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*Me)/Hl)}const va=Qn(0),ya=Qn(1),G_=Qn(2),V_=Qn(3),Dr=Qn(4),z_=Qn(5),W_=Qn(6);va.range,ya.range,G_.range,V_.range,Dr.range,z_.range,W_.range;function Jn(e){return Wt(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n*7)},(t,n)=>(n-t)/Hl)}const Tf=Jn(0),Ea=Jn(1),Y_=Jn(2),q_=Jn(3),Lr=Jn(4),X_=Jn(5),j_=Jn(6);Tf.range,Ea.range,Y_.range,q_.range,Lr.range,X_.range,j_.range;const Yl=Wt(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());Yl.range,Wt(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth()).range;const En=Wt(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());En.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Wt(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)}),En.range;const tr=Wt(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());tr.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Wt(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)}),tr.range;function Z_(e,t,n,r,i,s){const a=[[Cr,1,mn],[Cr,5,5*mn],[Cr,15,15*mn],[Cr,30,30*mn],[s,1,Me],[s,5,5*Me],[s,15,15*Me],[s,30,30*Me],[i,1,vn],[i,3,3*vn],[i,6,6*vn],[i,12,12*vn],[r,1,yn],[r,2,2*yn],[n,1,Hl],[t,1,Sf],[t,3,3*Sf],[e,1,Gl]];function o(c,u,d){const h=u<c;h&&([c,u]=[u,c]);const f=d&&typeof d.range=="function"?d:l(c,u,d),p=f?f.range(c,+u+1):[];return h?p.reverse():p}function l(c,u,d){const h=Math.abs(u-c)/d,f=Mo(([,,m])=>m).right(a,h);if(f===a.length)return e.every(Do(c/Gl,u/Gl,d));if(f===0)return ma.every(Math.max(Do(c,u,d),1));const[p,g]=a[h/a[f-1][2]<a[f][2]/h?f-1:f];return p.every(g)}return[o,l]}const[K_,Q_]=Z_(En,Yl,va,Pi,zl,Vl);function ql(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 Xl(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 Ni(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function J_(e){var t=e.dateTime,n=e.date,r=e.time,i=e.periods,s=e.days,a=e.shortDays,o=e.months,l=e.shortMonths,c=$i(i),u=Fi(i),d=$i(s),h=Fi(s),f=$i(a),p=Fi(a),g=$i(o),m=Fi(o),v=$i(l),E=Fi(l),y={a:$,A:N,b:F,B:Y,c:null,d:Df,e:Df,f:_S,g:RS,G:kS,H:ES,I:xS,j:bS,L:Lf,m:SS,M:TS,p:Z,q:K,Q:$f,s:Ff,S:OS,u:wS,U:MS,V:AS,w:CS,W:DS,x:null,X:null,y:LS,Y:IS,Z:PS,"%":Nf},b={a:dt,A:it,b:ft,B:j,c:null,d:If,e:If,f:US,g:jS,G:KS,H:NS,I:$S,j:FS,L:kf,m:BS,M:HS,p:nt,q:vt,Q:$f,s:Ff,S:GS,u:VS,U:zS,V:WS,w:YS,W:qS,x:null,X:null,y:XS,Y:ZS,Z:QS,"%":Nf},S={a:D,A:O,b:H,B:P,c:M,d:Af,e:Af,f:gS,g:Mf,G:wf,H:Cf,I:Cf,j:hS,L:pS,m:uS,M:dS,p:B,q:cS,Q:vS,s:yS,S:fS,u:iS,U:sS,V:aS,w:rS,W:oS,x:w,X:U,y:Mf,Y:wf,Z:lS,"%":mS};y.x=_(n,y),y.X=_(r,y),y.c=_(t,y),b.x=_(n,b),b.X=_(r,b),b.c=_(t,b);function _(q,Q){return function(ot){var C=[],G=-1,z=0,Ct=q.length,Ut,st,Dt;for(ot instanceof Date||(ot=new Date(+ot));++G<Ct;)q.charCodeAt(G)===37&&(C.push(q.slice(z,G)),(st=Of[Ut=q.charAt(++G)])!=null?Ut=q.charAt(++G):st=Ut==="e"?" ":"0",(Dt=Q[Ut])&&(Ut=Dt(ot,st)),C.push(Ut),z=G+1);return C.push(q.slice(z,G)),C.join("")}}function A(q,Q){return function(ot){var C=Ni(1900,void 0,1),G=R(C,q,ot+="",0),z,Ct;if(G!=ot.length)return null;if("Q"in C)return new Date(C.Q);if("s"in C)return new Date(C.s*1e3+("L"in C?C.L:0));if(Q&&!("Z"in C)&&(C.Z=0),"p"in C&&(C.H=C.H%12+C.p*12),C.m===void 0&&(C.m="q"in C?C.q:0),"V"in C){if(C.V<1||C.V>53)return null;"w"in C||(C.w=1),"Z"in C?(z=Xl(Ni(C.y,0,1)),Ct=z.getUTCDay(),z=Ct>4||Ct===0?Ea.ceil(z):Ea(z),z=Wl.offset(z,(C.V-1)*7),C.y=z.getUTCFullYear(),C.m=z.getUTCMonth(),C.d=z.getUTCDate()+(C.w+6)%7):(z=ql(Ni(C.y,0,1)),Ct=z.getDay(),z=Ct>4||Ct===0?ya.ceil(z):ya(z),z=Pi.offset(z,(C.V-1)*7),C.y=z.getFullYear(),C.m=z.getMonth(),C.d=z.getDate()+(C.w+6)%7)}else("W"in C||"U"in C)&&("w"in C||(C.w="u"in C?C.u%7:"W"in C?1:0),Ct="Z"in C?Xl(Ni(C.y,0,1)).getUTCDay():ql(Ni(C.y,0,1)).getDay(),C.m=0,C.d="W"in C?(C.w+6)%7+C.W*7-(Ct+5)%7:C.w+C.U*7-(Ct+6)%7);return"Z"in C?(C.H+=C.Z/100|0,C.M+=C.Z%100,Xl(C)):ql(C)}}function R(q,Q,ot,C){for(var G=0,z=Q.length,Ct=ot.length,Ut,st;G<z;){if(C>=Ct)return-1;if(Ut=Q.charCodeAt(G++),Ut===37){if(Ut=Q.charAt(G++),st=S[Ut in Of?Q.charAt(G++):Ut],!st||(C=st(q,ot,C))<0)return-1}else if(Ut!=ot.charCodeAt(C++))return-1}return C}function B(q,Q,ot){var C=c.exec(Q.slice(ot));return C?(q.p=u.get(C[0].toLowerCase()),ot+C[0].length):-1}function D(q,Q,ot){var C=f.exec(Q.slice(ot));return C?(q.w=p.get(C[0].toLowerCase()),ot+C[0].length):-1}function O(q,Q,ot){var C=d.exec(Q.slice(ot));return C?(q.w=h.get(C[0].toLowerCase()),ot+C[0].length):-1}function H(q,Q,ot){var C=v.exec(Q.slice(ot));return C?(q.m=E.get(C[0].toLowerCase()),ot+C[0].length):-1}function P(q,Q,ot){var C=g.exec(Q.slice(ot));return C?(q.m=m.get(C[0].toLowerCase()),ot+C[0].length):-1}function M(q,Q,ot){return R(q,t,Q,ot)}function w(q,Q,ot){return R(q,n,Q,ot)}function U(q,Q,ot){return R(q,r,Q,ot)}function $(q){return a[q.getDay()]}function N(q){return s[q.getDay()]}function F(q){return l[q.getMonth()]}function Y(q){return o[q.getMonth()]}function Z(q){return i[+(q.getHours()>=12)]}function K(q){return 1+~~(q.getMonth()/3)}function dt(q){return a[q.getUTCDay()]}function it(q){return s[q.getUTCDay()]}function ft(q){return l[q.getUTCMonth()]}function j(q){return o[q.getUTCMonth()]}function nt(q){return i[+(q.getUTCHours()>=12)]}function vt(q){return 1+~~(q.getUTCMonth()/3)}return{format:function(q){var Q=_(q+="",y);return Q.toString=function(){return q},Q},parse:function(q){var Q=A(q+="",!1);return Q.toString=function(){return q},Q},utcFormat:function(q){var Q=_(q+="",b);return Q.toString=function(){return q},Q},utcParse:function(q){var Q=A(q+="",!0);return Q.toString=function(){return q},Q}}}var Of={"-":"",_:" ",0:"0"},Yt=/^\s*\d+/,tS=/^%/,eS=/[\\^$*+?|[\]().{}]/g;function Et(e,t,n){var r=e<0?"-":"",i=(r?-e:e)+"",s=i.length;return r+(s<n?new Array(n-s+1).join(t)+i:i)}function nS(e){return e.replace(eS,"\\$&")}function $i(e){return new RegExp("^(?:"+e.map(nS).join("|")+")","i")}function Fi(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function rS(e,t,n){var r=Yt.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function iS(e,t,n){var r=Yt.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function sS(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function aS(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function oS(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function wf(e,t,n){var r=Yt.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function Mf(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function lS(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 cS(e,t,n){var r=Yt.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function uS(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function Af(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function hS(e,t,n){var r=Yt.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function Cf(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function dS(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function fS(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function pS(e,t,n){var r=Yt.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function gS(e,t,n){var r=Yt.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function mS(e,t,n){var r=tS.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function vS(e,t,n){var r=Yt.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function yS(e,t,n){var r=Yt.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function Df(e,t){return Et(e.getDate(),t,2)}function ES(e,t){return Et(e.getHours(),t,2)}function xS(e,t){return Et(e.getHours()%12||12,t,2)}function bS(e,t){return Et(1+Pi.count(En(e),e),t,3)}function Lf(e,t){return Et(e.getMilliseconds(),t,3)}function _S(e,t){return Lf(e,t)+"000"}function SS(e,t){return Et(e.getMonth()+1,t,2)}function TS(e,t){return Et(e.getMinutes(),t,2)}function OS(e,t){return Et(e.getSeconds(),t,2)}function wS(e){var t=e.getDay();return t===0?7:t}function MS(e,t){return Et(va.count(En(e)-1,e),t,2)}function Rf(e){var t=e.getDay();return t>=4||t===0?Dr(e):Dr.ceil(e)}function AS(e,t){return e=Rf(e),Et(Dr.count(En(e),e)+(En(e).getDay()===4),t,2)}function CS(e){return e.getDay()}function DS(e,t){return Et(ya.count(En(e)-1,e),t,2)}function LS(e,t){return Et(e.getFullYear()%100,t,2)}function RS(e,t){return e=Rf(e),Et(e.getFullYear()%100,t,2)}function IS(e,t){return Et(e.getFullYear()%1e4,t,4)}function kS(e,t){var n=e.getDay();return e=n>=4||n===0?Dr(e):Dr.ceil(e),Et(e.getFullYear()%1e4,t,4)}function PS(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Et(t/60|0,"0",2)+Et(t%60,"0",2)}function If(e,t){return Et(e.getUTCDate(),t,2)}function NS(e,t){return Et(e.getUTCHours(),t,2)}function $S(e,t){return Et(e.getUTCHours()%12||12,t,2)}function FS(e,t){return Et(1+Wl.count(tr(e),e),t,3)}function kf(e,t){return Et(e.getUTCMilliseconds(),t,3)}function US(e,t){return kf(e,t)+"000"}function BS(e,t){return Et(e.getUTCMonth()+1,t,2)}function HS(e,t){return Et(e.getUTCMinutes(),t,2)}function GS(e,t){return Et(e.getUTCSeconds(),t,2)}function VS(e){var t=e.getUTCDay();return t===0?7:t}function zS(e,t){return Et(Tf.count(tr(e)-1,e),t,2)}function Pf(e){var t=e.getUTCDay();return t>=4||t===0?Lr(e):Lr.ceil(e)}function WS(e,t){return e=Pf(e),Et(Lr.count(tr(e),e)+(tr(e).getUTCDay()===4),t,2)}function YS(e){return e.getUTCDay()}function qS(e,t){return Et(Ea.count(tr(e)-1,e),t,2)}function XS(e,t){return Et(e.getUTCFullYear()%100,t,2)}function jS(e,t){return e=Pf(e),Et(e.getUTCFullYear()%100,t,2)}function ZS(e,t){return Et(e.getUTCFullYear()%1e4,t,4)}function KS(e,t){var n=e.getUTCDay();return e=n>=4||n===0?Lr(e):Lr.ceil(e),Et(e.getUTCFullYear()%1e4,t,4)}function QS(){return"+0000"}function Nf(){return"%"}function $f(e){return+e}function Ff(e){return Math.floor(+e/1e3)}var Rr,Uf;JS({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function JS(e){return Rr=J_(e),Uf=Rr.format,Rr.parse,Rr.utcFormat,Rr.utcParse,Rr}function tT(e){return new Date(e)}function eT(e){return e instanceof Date?+e:+new Date(+e)}function Bf(e,t,n,r,i,s,a,o,l,c){var u=mf(),d=u.invert,h=u.domain,f=c(".%L"),p=c(":%S"),g=c("%I:%M"),m=c("%I %p"),v=c("%a %d"),E=c("%b %d"),y=c("%B"),b=c("%Y");function S(_){return(l(_)<_?f:o(_)<_?p:a(_)<_?g:s(_)<_?m:r(_)<_?i(_)<_?v:E:n(_)<_?y:b)(_)}return u.invert=function(_){return new Date(d(_))},u.domain=function(_){return arguments.length?h(Array.from(_,eT)):h().map(tT)},u.ticks=function(_){var A=h();return e(A[0],A[A.length-1],_??10)},u.tickFormat=function(_,A){return A==null?S:c(A)},u.nice=function(_){var A=h();return(!_||typeof _.range!="function")&&(_=t(A[0],A[A.length-1],_??10)),_?h(yf(A,_)):u},u.copy=function(){return $l(u,Bf(e,t,n,r,i,s,a,o,l,c))},u}function Hf(){return Mr.apply(Bf(K_,Q_,En,Yl,va,Pi,zl,Vl,Cr,Uf).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function ht(e){return function(){return e}}const Gf=Math.abs,Jt=Math.atan2,er=Math.cos,nT=Math.max,jl=Math.min,Je=Math.sin,Ir=Math.sqrt,te=1e-12,Ui=Math.PI,xa=Ui/2,ba=2*Ui;function rT(e){return e>1?0:e<-1?Ui:Math.acos(e)}function Vf(e){return e>=1?xa:e<=-1?-xa:Math.asin(e)}function _a(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{const r=Math.floor(n);if(!(r>=0))throw new RangeError(`invalid digits: ${n}`);t=r}return e},()=>new Ox(t)}function iT(e){return e.innerRadius}function sT(e){return e.outerRadius}function aT(e){return e.startAngle}function oT(e){return e.endAngle}function lT(e){return e&&e.padAngle}function cT(e,t,n,r,i,s,a,o){var l=n-e,c=r-t,u=a-i,d=o-s,h=d*l-u*c;if(!(h*h<te))return h=(u*(t-s)-d*(e-i))/h,[e+h*l,t+h*c]}function Sa(e,t,n,r,i,s,a){var o=e-n,l=t-r,c=(a?s:-s)/Ir(o*o+l*l),u=c*l,d=-c*o,h=e+u,f=t+d,p=n+u,g=r+d,m=(h+p)/2,v=(f+g)/2,E=p-h,y=g-f,b=E*E+y*y,S=i-s,_=h*g-p*f,A=(y<0?-1:1)*Ir(nT(0,S*S*b-_*_)),R=(_*y-E*A)/b,B=(-_*E-y*A)/b,D=(_*y+E*A)/b,O=(-_*E+y*A)/b,H=R-m,P=B-v,M=D-m,w=O-v;return H*H+P*P>M*M+w*w&&(R=D,B=O),{cx:R,cy:B,x01:-u,y01:-d,x11:R*(i/S-1),y11:B*(i/S-1)}}function Bi(){var e=iT,t=sT,n=ht(0),r=null,i=aT,s=oT,a=lT,o=null,l=_a(c);function c(){var u,d,h=+e.apply(this,arguments),f=+t.apply(this,arguments),p=i.apply(this,arguments)-xa,g=s.apply(this,arguments)-xa,m=Gf(g-p),v=g>p;if(o||(o=u=l()),f<h&&(d=f,f=h,h=d),!(f>te))o.moveTo(0,0);else if(m>ba-te)o.moveTo(f*er(p),f*Je(p)),o.arc(0,0,f,p,g,!v),h>te&&(o.moveTo(h*er(g),h*Je(g)),o.arc(0,0,h,g,p,v));else{var E=p,y=g,b=p,S=g,_=m,A=m,R=a.apply(this,arguments)/2,B=R>te&&(r?+r.apply(this,arguments):Ir(h*h+f*f)),D=jl(Gf(f-h)/2,+n.apply(this,arguments)),O=D,H=D,P,M;if(B>te){var w=Vf(B/h*Je(R)),U=Vf(B/f*Je(R));(_-=w*2)>te?(w*=v?1:-1,b+=w,S-=w):(_=0,b=S=(p+g)/2),(A-=U*2)>te?(U*=v?1:-1,E+=U,y-=U):(A=0,E=y=(p+g)/2)}var $=f*er(E),N=f*Je(E),F=h*er(S),Y=h*Je(S);if(D>te){var Z=f*er(y),K=f*Je(y),dt=h*er(b),it=h*Je(b),ft;if(m<Ui)if(ft=cT($,N,dt,it,Z,K,F,Y)){var j=$-ft[0],nt=N-ft[1],vt=Z-ft[0],q=K-ft[1],Q=1/Je(rT((j*vt+nt*q)/(Ir(j*j+nt*nt)*Ir(vt*vt+q*q)))/2),ot=Ir(ft[0]*ft[0]+ft[1]*ft[1]);O=jl(D,(h-ot)/(Q-1)),H=jl(D,(f-ot)/(Q+1))}else O=H=0}A>te?H>te?(P=Sa(dt,it,$,N,f,H,v),M=Sa(Z,K,F,Y,f,H,v),o.moveTo(P.cx+P.x01,P.cy+P.y01),H<D?o.arc(P.cx,P.cy,H,Jt(P.y01,P.x01),Jt(M.y01,M.x01),!v):(o.arc(P.cx,P.cy,H,Jt(P.y01,P.x01),Jt(P.y11,P.x11),!v),o.arc(0,0,f,Jt(P.cy+P.y11,P.cx+P.x11),Jt(M.cy+M.y11,M.cx+M.x11),!v),o.arc(M.cx,M.cy,H,Jt(M.y11,M.x11),Jt(M.y01,M.x01),!v))):(o.moveTo($,N),o.arc(0,0,f,E,y,!v)):o.moveTo($,N),!(h>te)||!(_>te)?o.lineTo(F,Y):O>te?(P=Sa(F,Y,Z,K,h,-O,v),M=Sa($,N,dt,it,h,-O,v),o.lineTo(P.cx+P.x01,P.cy+P.y01),O<D?o.arc(P.cx,P.cy,O,Jt(P.y01,P.x01),Jt(M.y01,M.x01),!v):(o.arc(P.cx,P.cy,O,Jt(P.y01,P.x01),Jt(P.y11,P.x11),!v),o.arc(0,0,h,Jt(P.cy+P.y11,P.cx+P.x11),Jt(M.cy+M.y11,M.cx+M.x11),v),o.arc(M.cx,M.cy,O,Jt(M.y11,M.x11),Jt(M.y01,M.x01),!v))):o.arc(0,0,h,S,b,v)}if(o.closePath(),u)return o=null,u+""||null}return c.centroid=function(){var u=(+e.apply(this,arguments)+ +t.apply(this,arguments))/2,d=(+i.apply(this,arguments)+ +s.apply(this,arguments))/2-Ui/2;return[er(d)*u,Je(d)*u]},c.innerRadius=function(u){return arguments.length?(e=typeof u=="function"?u:ht(+u),c):e},c.outerRadius=function(u){return arguments.length?(t=typeof u=="function"?u:ht(+u),c):t},c.cornerRadius=function(u){return arguments.length?(n=typeof u=="function"?u:ht(+u),c):n},c.padRadius=function(u){return arguments.length?(r=u==null?null:typeof u=="function"?u:ht(+u),c):r},c.startAngle=function(u){return arguments.length?(i=typeof u=="function"?u:ht(+u),c):i},c.endAngle=function(u){return arguments.length?(s=typeof u=="function"?u:ht(+u),c):s},c.padAngle=function(u){return arguments.length?(a=typeof u=="function"?u:ht(+u),c):a},c.context=function(u){return arguments.length?(o=u??null,c):o},c}var uT=Array.prototype.slice;function Ta(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function zf(e){this._context=e}zf.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function Oa(e){return new zf(e)}function Zl(e){return e[0]}function Kl(e){return e[1]}function Hi(e,t){var n=ht(!0),r=null,i=Oa,s=null,a=_a(o);e=typeof e=="function"?e:e===void 0?Zl:ht(e),t=typeof t=="function"?t:t===void 0?Kl:ht(t);function o(l){var c,u=(l=Ta(l)).length,d,h=!1,f;for(r==null&&(s=i(f=a())),c=0;c<=u;++c)!(c<u&&n(d=l[c],c,l))===h&&((h=!h)?s.lineStart():s.lineEnd()),h&&s.point(+e(d,c,l),+t(d,c,l));if(f)return s=null,f+""||null}return o.x=function(l){return arguments.length?(e=typeof l=="function"?l:ht(+l),o):e},o.y=function(l){return arguments.length?(t=typeof l=="function"?l:ht(+l),o):t},o.defined=function(l){return arguments.length?(n=typeof l=="function"?l:ht(!!l),o):n},o.curve=function(l){return arguments.length?(i=l,r!=null&&(s=i(r)),o):i},o.context=function(l){return arguments.length?(l==null?r=s=null:s=i(r=l),o):r},o}function Ql(e,t,n){var r=null,i=ht(!0),s=null,a=Oa,o=null,l=_a(c);e=typeof e=="function"?e:e===void 0?Zl:ht(+e),t=typeof t=="function"?t:ht(t===void 0?0:+t),n=typeof n=="function"?n:n===void 0?Kl:ht(+n);function c(d){var h,f,p,g=(d=Ta(d)).length,m,v=!1,E,y=new Array(g),b=new Array(g);for(s==null&&(o=a(E=l())),h=0;h<=g;++h){if(!(h<g&&i(m=d[h],h,d))===v)if(v=!v)f=h,o.areaStart(),o.lineStart();else{for(o.lineEnd(),o.lineStart(),p=h-1;p>=f;--p)o.point(y[p],b[p]);o.lineEnd(),o.areaEnd()}v&&(y[h]=+e(m,h,d),b[h]=+t(m,h,d),o.point(r?+r(m,h,d):y[h],n?+n(m,h,d):b[h]))}if(E)return o=null,E+""||null}function u(){return Hi().defined(i).curve(a).context(s)}return c.x=function(d){return arguments.length?(e=typeof d=="function"?d:ht(+d),r=null,c):e},c.x0=function(d){return arguments.length?(e=typeof d=="function"?d:ht(+d),c):e},c.x1=function(d){return arguments.length?(r=d==null?null:typeof d=="function"?d:ht(+d),c):r},c.y=function(d){return arguments.length?(t=typeof d=="function"?d:ht(+d),n=null,c):t},c.y0=function(d){return arguments.length?(t=typeof d=="function"?d:ht(+d),c):t},c.y1=function(d){return arguments.length?(n=d==null?null:typeof d=="function"?d:ht(+d),c):n},c.lineX0=c.lineY0=function(){return u().x(e).y(t)},c.lineY1=function(){return u().x(e).y(n)},c.lineX1=function(){return u().x(r).y(t)},c.defined=function(d){return arguments.length?(i=typeof d=="function"?d:ht(!!d),c):i},c.curve=function(d){return arguments.length?(a=d,s!=null&&(o=a(s)),c):a},c.context=function(d){return arguments.length?(d==null?s=o=null:o=a(s=d),c):s},c}function hT(e,t){return t<e?-1:t>e?1:t>=e?0:NaN}function dT(e){return e}function fT(){var e=dT,t=hT,n=null,r=ht(0),i=ht(ba),s=ht(0);function a(o){var l,c=(o=Ta(o)).length,u,d,h=0,f=new Array(c),p=new Array(c),g=+r.apply(this,arguments),m=Math.min(ba,Math.max(-ba,i.apply(this,arguments)-g)),v,E=Math.min(Math.abs(m)/c,s.apply(this,arguments)),y=E*(m<0?-1:1),b;for(l=0;l<c;++l)(b=p[f[l]=l]=+e(o[l],l,o))>0&&(h+=b);for(t!=null?f.sort(function(S,_){return t(p[S],p[_])}):n!=null&&f.sort(function(S,_){return n(o[S],o[_])}),l=0,d=h?(m-c*y)/h:0;l<c;++l,g=v)u=f[l],b=p[u],v=g+(b>0?b*d:0)+y,p[u]={data:o[u],index:l,value:b,startAngle:g,endAngle:v,padAngle:E};return p}return a.value=function(o){return arguments.length?(e=typeof o=="function"?o:ht(+o),a):e},a.sortValues=function(o){return arguments.length?(t=o,n=null,a):t},a.sort=function(o){return arguments.length?(n=o,t=null,a):n},a.startAngle=function(o){return arguments.length?(r=typeof o=="function"?o:ht(+o),a):r},a.endAngle=function(o){return arguments.length?(i=typeof o=="function"?o:ht(+o),a):i},a.padAngle=function(o){return arguments.length?(s=typeof o=="function"?o:ht(+o),a):s},a}var pT=Yf(Oa);function Wf(e){this._curve=e}Wf.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(e,t){this._curve.point(t*Math.sin(e),t*-Math.cos(e))}};function Yf(e){function t(n){return new Wf(e(n))}return t._curve=e,t}function gT(e){var t=e.curve;return e.angle=e.x,delete e.x,e.radius=e.y,delete e.y,e.curve=function(n){return arguments.length?t(Yf(n)):t()._curve},e}function mT(){return gT(Hi().curve(pT))}class vT{constructor(t,n){this._context=t,this._x=n}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(t,n){switch(t=+t,n=+n,this._point){case 0:{this._point=1,this._line?this._context.lineTo(t,n):this._context.moveTo(t,n);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,n,t,n):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+n)/2,t,this._y0,t,n);break}}this._x0=t,this._y0=n}}function yT(e){return new vT(e,!0)}function ET(e){return e.source}function xT(e){return e.target}function bT(e){let t=ET,n=xT,r=Zl,i=Kl,s=null,a=null,o=_a(l);function l(){let c;const u=uT.call(arguments),d=t.apply(this,u),h=n.apply(this,u);if(s==null&&(a=e(c=o())),a.lineStart(),u[0]=d,a.point(+r.apply(this,u),+i.apply(this,u)),u[0]=h,a.point(+r.apply(this,u),+i.apply(this,u)),a.lineEnd(),c)return a=null,c+""||null}return l.source=function(c){return arguments.length?(t=c,l):t},l.target=function(c){return arguments.length?(n=c,l):n},l.x=function(c){return arguments.length?(r=typeof c=="function"?c:ht(+c),l):r},l.y=function(c){return arguments.length?(i=typeof c=="function"?c:ht(+c),l):i},l.context=function(c){return arguments.length?(c==null?s=a=null:a=e(s=c),l):s},l}function _T(){return bT(yT)}function kn(){}function wa(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 Ma(e){this._context=e}Ma.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:wa(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:wa(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function ST(e){return new Ma(e)}function qf(e){this._context=e}qf.prototype={areaStart:kn,areaEnd:kn,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:wa(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function TT(e){return new qf(e)}function Xf(e){this._context=e}Xf.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:wa(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function OT(e){return new Xf(e)}function jf(e,t){this._basis=new Ma(e),this._beta=t}jf.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=e[0],i=t[0],s=e[n]-r,a=t[n]-i,o=-1,l;++o<=n;)l=o/n,this._basis.point(this._beta*e[o]+(1-this._beta)*(r+l*s),this._beta*t[o]+(1-this._beta)*(i+l*a));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};const wT=function e(t){function n(r){return t===1?new Ma(r):new jf(r,t)}return n.beta=function(r){return e(+r)},n}(.85);function Aa(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 Jl(e,t){this._context=e,this._k=(1-t)/6}Jl.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:Aa(this,this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2,this._x1=e,this._y1=t;break;case 2:this._point=3;default:Aa(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const MT=function e(t){function n(r){return new Jl(r,t)}return n.tension=function(r){return e(+r)},n}(0);function tc(e,t){this._context=e,this._k=(1-t)/6}tc.prototype={areaStart:kn,areaEnd:kn,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);break}}},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:Aa(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const AT=function e(t){function n(r){return new tc(r,t)}return n.tension=function(r){return e(+r)},n}(0);function ec(e,t){this._context=e,this._k=(1-t)/6}ec.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||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:Aa(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const CT=function e(t){function n(r){return new ec(r,t)}return n.tension=function(r){return e(+r)},n}(0);function nc(e,t,n){var r=e._x1,i=e._y1,s=e._x2,a=e._y2;if(e._l01_a>te){var o=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*o-e._x0*e._l12_2a+e._x2*e._l01_2a)/l,i=(i*o-e._y0*e._l12_2a+e._y2*e._l01_2a)/l}if(e._l23_a>te){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);s=(s*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,s,a,e._x2,e._y2)}function Zf(e,t){this._context=e,this._alpha=t}Zf.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);break}(this._line||this._line!==0&&this._point===1)&&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:nc(this,e,t);break}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 DT=function e(t){function n(r){return t?new Zf(r,t):new Jl(r,0)}return n.alpha=function(r){return e(+r)},n}(.5);function Kf(e,t){this._context=e,this._alpha=t}Kf.prototype={areaStart:kn,areaEnd:kn,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);break}}},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:nc(this,e,t);break}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 LT=function e(t){function n(r){return t?new Kf(r,t):new tc(r,0)}return n.alpha=function(r){return e(+r)},n}(.5);function Qf(e,t){this._context=e,this._alpha=t}Qf.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||this._line!==0&&this._point===3)&&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:nc(this,e,t);break}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 RT=function e(t){function n(r){return t?new Qf(r,t):new ec(r,0)}return n.alpha=function(r){return e(+r)},n}(.5);function Jf(e){this._context=e}Jf.prototype={areaStart:kn,areaEnd:kn,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function tp(e){return new Jf(e)}function ep(e){return e<0?-1:1}function np(e,t,n){var r=e._x1-e._x0,i=t-e._x1,s=(e._y1-e._y0)/(r||i<0&&-0),a=(n-e._y1)/(i||r<0&&-0),o=(s*i+a*r)/(r+i);return(ep(s)+ep(a))*Math.min(Math.abs(s),Math.abs(a),.5*Math.abs(o))||0}function rp(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function rc(e,t,n){var r=e._x0,i=e._y0,s=e._x1,a=e._y1,o=(s-r)/3;e._context.bezierCurveTo(r+o,i+o*t,s-o,a-o*n,s,a)}function Ca(e){this._context=e}Ca.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:rc(this,this._t0,rp(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var n=NaN;if(e=+e,t=+t,!(e===this._x1&&t===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,rc(this,rp(this,n=np(this,e,t)),n);break;default:rc(this,this._t0,n=np(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function ip(e){this._context=new sp(e)}(ip.prototype=Object.create(Ca.prototype)).point=function(e,t){Ca.prototype.point.call(this,t,e)};function sp(e){this._context=e}sp.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,n,r,i,s){this._context.bezierCurveTo(t,e,r,n,s,i)}};function IT(e){return new Ca(e)}function kT(e){return new ip(e)}function ap(e){this._context=e}ap.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,n=e.length;if(n)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),n===2)this._context.lineTo(e[1],t[1]);else for(var r=op(e),i=op(t),s=0,a=1;a<n;++s,++a)this._context.bezierCurveTo(r[0][s],i[0][s],r[1][s],i[1][s],e[a],t[a]);(this._line||this._line!==0&&n===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}};function op(e){var t,n=e.length-1,r,i=new Array(n),s=new Array(n),a=new Array(n);for(i[0]=0,s[0]=2,a[0]=e[0]+2*e[1],t=1;t<n-1;++t)i[t]=1,s[t]=4,a[t]=4*e[t]+2*e[t+1];for(i[n-1]=2,s[n-1]=7,a[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)r=i[t]/s[t-1],s[t]-=r,a[t]-=r*a[t-1];for(i[n-1]=a[n-1]/s[n-1],t=n-2;t>=0;--t)i[t]=(a[t]-i[t+1])/s[t];for(s[n-1]=(e[n]+i[n-1])/2,t=0;t<n-1;++t)s[t]=2*e[t+1]-i[t+1];return[i,s]}function PT(e){return new ap(e)}function Da(e,t){this._context=e,this._t=t}Da.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}break}}this._x=e,this._y=t}};function NT(e){return new Da(e,.5)}function $T(e){return new Da(e,0)}function FT(e){return new Da(e,1)}function lp(e,t){if((a=e.length)>1)for(var n=1,r,i,s=e[t[0]],a,o=s.length;n<a;++n)for(i=s,s=e[t[n]],r=0;r<o;++r)s[r][1]+=s[r][0]=isNaN(i[r][1])?i[r][0]:i[r][1]}function cp(e){for(var t=e.length,n=new Array(t);--t>=0;)n[t]=t;return n}function UT(e,t){return e[t]}function BT(e){const t=[];return t.key=e,t}function ic(){var e=ht([]),t=cp,n=lp,r=UT;function i(s){var a=Array.from(e.apply(this,arguments),BT),o,l=a.length,c=-1,u;for(const d of s)for(o=0,++c;o<l;++o)(a[o][c]=[0,+r(d,a[o].key,c,s)]).data=d;for(o=0,u=Ta(t(a));o<l;++o)a[u[o]].index=o;return n(a,u),a}return i.keys=function(s){return arguments.length?(e=typeof s=="function"?s:ht(Array.from(s)),i):e},i.value=function(s){return arguments.length?(r=typeof s=="function"?s:ht(+s),i):r},i.order=function(s){return arguments.length?(t=s==null?cp:typeof s=="function"?s:ht(Array.from(s)),i):t},i.offset=function(s){return arguments.length?(n=s??lp,i):n},i}function HT(e,t){if((l=e.length)>0)for(var n,r=0,i,s,a,o,l,c=e[t[0]].length;r<c;++r)for(a=o=0,n=0;n<l;++n)(s=(i=e[t[n]][r])[1]-i[0])>0?(i[0]=a,i[1]=a+=s):s<0?(i[1]=o,i[0]=o+=s):(i[0]=0,i[1]=s)}function Gi(e,t,n){this.k=e,this.x=t,this.y=n}Gi.prototype={constructor:Gi,scale:function(e){return e===1?this:new Gi(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new Gi(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}},Gi.prototype;var up=typeof global=="object"&&global&&global.Object===Object&&global,GT=typeof self=="object"&&self&&self.Object===Object&&self,Be=up||GT||Function("return this")(),Ae=Be.Symbol,hp=Object.prototype,VT=hp.hasOwnProperty,zT=hp.toString,Vi=Ae?Ae.toStringTag:void 0;function WT(e){var t=VT.call(e,Vi),n=e[Vi];try{e[Vi]=void 0;var r=!0}catch{}var i=zT.call(e);return r&&(t?e[Vi]=n:delete e[Vi]),i}var YT=Object.prototype,qT=YT.toString;function XT(e){return qT.call(e)}var jT="[object Null]",ZT="[object Undefined]",dp=Ae?Ae.toStringTag:void 0;function nr(e){return e==null?e===void 0?ZT:jT:dp&&dp in Object(e)?WT(e):XT(e)}function tn(e){return e!=null&&typeof e=="object"}var KT="[object Symbol]";function La(e){return typeof e=="symbol"||tn(e)&&nr(e)==KT}function sc(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}var Xt=Array.isArray,QT=1/0,fp=Ae?Ae.prototype:void 0,pp=fp?fp.toString:void 0;function gp(e){if(typeof e=="string")return e;if(Xt(e))return sc(e,gp)+"";if(La(e))return pp?pp.call(e):"";var t=e+"";return t=="0"&&1/e==-QT?"-0":t}var JT=/\s/;function tO(e){for(var t=e.length;t--&&JT.test(e.charAt(t)););return t}var eO=/^\s+/;function nO(e){return e&&e.slice(0,tO(e)+1).replace(eO,"")}function Ce(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var mp=NaN,rO=/^[-+]0x[0-9a-f]+$/i,iO=/^0b[01]+$/i,sO=/^0o[0-7]+$/i,aO=parseInt;function kr(e){if(typeof e=="number")return e;if(La(e))return mp;if(Ce(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Ce(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=nO(e);var n=iO.test(e);return n||sO.test(e)?aO(e.slice(2),n?2:8):rO.test(e)?mp:+e}function ac(e){return e}var oO="[object AsyncFunction]",lO="[object Function]",cO="[object GeneratorFunction]",uO="[object Proxy]";function oc(e){if(!Ce(e))return!1;var t=nr(e);return t==lO||t==cO||t==oO||t==uO}var lc=Be["__core-js_shared__"],vp=function(){var e=/[^.]+$/.exec(lc&&lc.keys&&lc.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function hO(e){return!!vp&&vp in e}var dO=Function.prototype,fO=dO.toString;function rr(e){if(e!=null){try{return fO.call(e)}catch{}try{return e+""}catch{}}return""}var pO=/[\\^$.*+?()[\]{}|]/g,gO=/^\[object .+?Constructor\]$/,mO=Function.prototype,vO=Object.prototype,yO=mO.toString,EO=vO.hasOwnProperty,xO=RegExp("^"+yO.call(EO).replace(pO,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function bO(e){if(!Ce(e)||hO(e))return!1;var t=oc(e)?xO:gO;return t.test(rr(e))}function _O(e,t){return e==null?void 0:e[t]}function ir(e,t){var n=_O(e,t);return bO(n)?n:void 0}var cc=ir(Be,"WeakMap"),yp=Object.create,SO=function(){function e(){}return function(t){if(!Ce(t))return{};if(yp)return yp(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function TO(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function OO(){}function Ep(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}var wO=800,MO=16,AO=Date.now;function CO(e){var t=0,n=0;return function(){var r=AO(),i=MO-(r-n);if(n=r,i>0){if(++t>=wO)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function DO(e){return function(){return e}}var Ra=function(){try{var e=ir(Object,"defineProperty");return e({},"",{}),e}catch{}}(),LO=Ra?function(e,t){return Ra(e,"toString",{configurable:!0,enumerable:!1,value:DO(t),writable:!0})}:ac,xp=CO(LO);function RO(e,t){for(var n=-1,r=e==null?0:e.length;++n<r&&t(e[n],n,e)!==!1;);return e}function IO(e,t,n,r){for(var i=e.length,s=n+-1;++s<i;)if(t(e[s],s,e))return s;return-1}function kO(e){return e!==e}function PO(e,t,n){for(var r=n-1,i=e.length;++r<i;)if(e[r]===t)return r;return-1}function NO(e,t,n){return t===t?PO(e,t,n):IO(e,kO,n)}function $O(e,t){var n=e==null?0:e.length;return!!n&&NO(e,t,0)>-1}var FO=9007199254740991,UO=/^(?:0|[1-9]\d*)$/;function uc(e,t){var n=typeof e;return t=t??FO,!!t&&(n=="number"||n!="symbol"&&UO.test(e))&&e>-1&&e%1==0&&e<t}function Ia(e,t,n){t=="__proto__"&&Ra?Ra(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function zi(e,t){return e===t||e!==e&&t!==t}var BO=Object.prototype,HO=BO.hasOwnProperty;function bp(e,t,n){var r=e[t];(!(HO.call(e,t)&&zi(r,n))||n===void 0&&!(t in e))&&Ia(e,t,n)}function Pr(e,t,n,r){var i=!n;n||(n={});for(var s=-1,a=t.length;++s<a;){var o=t[s],l=void 0;l===void 0&&(l=e[o]),i?Ia(n,o,l):bp(n,o,l)}return n}var _p=Math.max;function Sp(e,t,n){return t=_p(t===void 0?e.length-1:t,0),function(){for(var r=arguments,i=-1,s=_p(r.length-t,0),a=Array(s);++i<s;)a[i]=r[t+i];i=-1;for(var o=Array(t+1);++i<t;)o[i]=r[i];return o[t]=n(a),TO(e,this,o)}}function hc(e,t){return xp(Sp(e,t,ac),e+"")}var GO=9007199254740991;function dc(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=GO}function sr(e){return e!=null&&dc(e.length)&&!oc(e)}function VO(e,t,n){if(!Ce(n))return!1;var r=typeof t;return(r=="number"?sr(n)&&uc(t,n.length):r=="string"&&t in n)?zi(n[t],e):!1}function zO(e){return hc(function(t,n){var r=-1,i=n.length,s=i>1?n[i-1]:void 0,a=i>2?n[2]:void 0;for(s=e.length>3&&typeof s=="function"?(i--,s):void 0,a&&VO(n[0],n[1],a)&&(s=i<3?void 0:s,i=1),t=Object(t);++r<i;){var o=n[r];o&&e(t,o,r,s)}return t})}var WO=Object.prototype;function ka(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||WO;return e===n}function YO(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}var qO="[object Arguments]";function Tp(e){return tn(e)&&nr(e)==qO}var Op=Object.prototype,XO=Op.hasOwnProperty,jO=Op.propertyIsEnumerable,Nr=Tp(function(){return arguments}())?Tp:function(e){return tn(e)&&XO.call(e,"callee")&&!jO.call(e,"callee")};function ZO(){return!1}var wp=typeof W=="object"&&W&&!W.nodeType&&W,Mp=wp&&typeof module=="object"&&module&&!module.nodeType&&module,KO=Mp&&Mp.exports===wp,Ap=KO?Be.Buffer:void 0,QO=Ap?Ap.isBuffer:void 0,$r=QO||ZO,JO="[object Arguments]",tw="[object Array]",ew="[object Boolean]",nw="[object Date]",rw="[object Error]",iw="[object Function]",sw="[object Map]",aw="[object Number]",ow="[object Object]",lw="[object RegExp]",cw="[object Set]",uw="[object String]",hw="[object WeakMap]",dw="[object ArrayBuffer]",fw="[object DataView]",pw="[object Float32Array]",gw="[object Float64Array]",mw="[object Int8Array]",vw="[object Int16Array]",yw="[object Int32Array]",Ew="[object Uint8Array]",xw="[object Uint8ClampedArray]",bw="[object Uint16Array]",_w="[object Uint32Array]",kt={};kt[pw]=kt[gw]=kt[mw]=kt[vw]=kt[yw]=kt[Ew]=kt[xw]=kt[bw]=kt[_w]=!0,kt[JO]=kt[tw]=kt[dw]=kt[ew]=kt[fw]=kt[nw]=kt[rw]=kt[iw]=kt[sw]=kt[aw]=kt[ow]=kt[lw]=kt[cw]=kt[uw]=kt[hw]=!1;function Sw(e){return tn(e)&&dc(e.length)&&!!kt[nr(e)]}function fc(e){return function(t){return e(t)}}var Cp=typeof W=="object"&&W&&!W.nodeType&&W,Wi=Cp&&typeof module=="object"&&module&&!module.nodeType&&module,Tw=Wi&&Wi.exports===Cp,pc=Tw&&up.process,Fr=function(){try{var e=Wi&&Wi.require&&Wi.require("util").types;return e||pc&&pc.binding&&pc.binding("util")}catch{}}(),Dp=Fr&&Fr.isTypedArray,Pa=Dp?fc(Dp):Sw,Ow=Object.prototype,ww=Ow.hasOwnProperty;function Lp(e,t){var n=Xt(e),r=!n&&Nr(e),i=!n&&!r&&$r(e),s=!n&&!r&&!i&&Pa(e),a=n||r||i||s,o=a?YO(e.length,String):[],l=o.length;for(var c in e)(t||ww.call(e,c))&&!(a&&(c=="length"||i&&(c=="offset"||c=="parent")||s&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||uc(c,l)))&&o.push(c);return o}function Rp(e,t){return function(n){return e(t(n))}}var Mw=Rp(Object.keys,Object),Aw=Object.prototype,Cw=Aw.hasOwnProperty;function Ip(e){if(!ka(e))return Mw(e);var t=[];for(var n in Object(e))Cw.call(e,n)&&n!="constructor"&&t.push(n);return t}function Yi(e){return sr(e)?Lp(e):Ip(e)}function Dw(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var Lw=Object.prototype,Rw=Lw.hasOwnProperty;function Iw(e){if(!Ce(e))return Dw(e);var t=ka(e),n=[];for(var r in e)r=="constructor"&&(t||!Rw.call(e,r))||n.push(r);return n}function qi(e){return sr(e)?Lp(e,!0):Iw(e)}var kw=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Pw=/^\w*$/;function gc(e,t){if(Xt(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||La(e)?!0:Pw.test(e)||!kw.test(e)||t!=null&&e in Object(t)}var Xi=ir(Object,"create");function Nw(){this.__data__=Xi?Xi(null):{},this.size=0}function $w(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var Fw="__lodash_hash_undefined__",Uw=Object.prototype,Bw=Uw.hasOwnProperty;function Hw(e){var t=this.__data__;if(Xi){var n=t[e];return n===Fw?void 0:n}return Bw.call(t,e)?t[e]:void 0}var Gw=Object.prototype,Vw=Gw.hasOwnProperty;function zw(e){var t=this.__data__;return Xi?t[e]!==void 0:Vw.call(t,e)}var Ww="__lodash_hash_undefined__";function Yw(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=Xi&&t===void 0?Ww:t,this}function ar(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}ar.prototype.clear=Nw,ar.prototype.delete=$w,ar.prototype.get=Hw,ar.prototype.has=zw,ar.prototype.set=Yw;function qw(){this.__data__=[],this.size=0}function Na(e,t){for(var n=e.length;n--;)if(zi(e[n][0],t))return n;return-1}var Xw=Array.prototype,jw=Xw.splice;function Zw(e){var t=this.__data__,n=Na(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():jw.call(t,n,1),--this.size,!0}function Kw(e){var t=this.__data__,n=Na(t,e);return n<0?void 0:t[n][1]}function Qw(e){return Na(this.__data__,e)>-1}function Jw(e,t){var n=this.__data__,r=Na(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function xn(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}xn.prototype.clear=qw,xn.prototype.delete=Zw,xn.prototype.get=Kw,xn.prototype.has=Qw,xn.prototype.set=Jw;var ji=ir(Be,"Map");function tM(){this.size=0,this.__data__={hash:new ar,map:new(ji||xn),string:new ar}}function eM(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function $a(e,t){var n=e.__data__;return eM(t)?n[typeof t=="string"?"string":"hash"]:n.map}function nM(e){var t=$a(this,e).delete(e);return this.size-=t?1:0,t}function rM(e){return $a(this,e).get(e)}function iM(e){return $a(this,e).has(e)}function sM(e,t){var n=$a(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}function bn(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}bn.prototype.clear=tM,bn.prototype.delete=nM,bn.prototype.get=rM,bn.prototype.has=iM,bn.prototype.set=sM;var aM="Expected a function";function mc(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(aM);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],s=n.cache;if(s.has(i))return s.get(i);var a=e.apply(this,r);return n.cache=s.set(i,a)||s,a};return n.cache=new(mc.Cache||bn),n}mc.Cache=bn;var oM=500;function lM(e){var t=mc(e,function(r){return n.size===oM&&n.clear(),r}),n=t.cache;return t}var cM=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,uM=/\\(\\)?/g,hM=lM(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(cM,function(n,r,i,s){t.push(i?s.replace(uM,"$1"):r||n)}),t});function Zi(e){return e==null?"":gp(e)}function Fa(e,t){return Xt(e)?e:gc(e,t)?[e]:hM(Zi(e))}var dM=1/0;function Ki(e){if(typeof e=="string"||La(e))return e;var t=e+"";return t=="0"&&1/e==-dM?"-0":t}function vc(e,t){t=Fa(t,e);for(var n=0,r=t.length;e!=null&&n<r;)e=e[Ki(t[n++])];return n&&n==r?e:void 0}function yt(e,t,n){var r=e==null?void 0:vc(e,t);return r===void 0?n:r}function yc(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}var kp=Ae?Ae.isConcatSpreadable:void 0;function fM(e){return Xt(e)||Nr(e)||!!(kp&&e&&e[kp])}function Ua(e,t,n,r,i){var s=-1,a=e.length;for(n||(n=fM),i||(i=[]);++s<a;){var o=e[s];t>0&&n(o)?t>1?Ua(o,t-1,n,r,i):yc(i,o):r||(i[i.length]=o)}return i}function Ec(e){var t=e==null?0:e.length;return t?Ua(e,1):[]}function pM(e){return xp(Sp(e,void 0,Ec),e+"")}var xc=Rp(Object.getPrototypeOf,Object),gM="[object Object]",mM=Function.prototype,vM=Object.prototype,Pp=mM.toString,yM=vM.hasOwnProperty,EM=Pp.call(Object);function Np(e){if(!tn(e)||nr(e)!=gM)return!1;var t=xc(e);if(t===null)return!0;var n=yM.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&Pp.call(n)==EM}function $p(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var s=Array(i);++r<i;)s[r]=e[r+t];return s}function xM(e,t,n){var r=e.length;return n=n===void 0?r:n,!t&&n>=r?e:$p(e,t,n)}var bM="\\ud800-\\udfff",_M="\\u0300-\\u036f",SM="\\ufe20-\\ufe2f",TM="\\u20d0-\\u20ff",OM=_M+SM+TM,wM="\\ufe0e\\ufe0f",MM="\\u200d",AM=RegExp("["+MM+bM+OM+wM+"]");function Fp(e){return AM.test(e)}function CM(e){return e.split("")}var Up="\\ud800-\\udfff",DM="\\u0300-\\u036f",LM="\\ufe20-\\ufe2f",RM="\\u20d0-\\u20ff",IM=DM+LM+RM,kM="\\ufe0e\\ufe0f",PM="["+Up+"]",bc="["+IM+"]",_c="\\ud83c[\\udffb-\\udfff]",NM="(?:"+bc+"|"+_c+")",Bp="[^"+Up+"]",Hp="(?:\\ud83c[\\udde6-\\uddff]){2}",Gp="[\\ud800-\\udbff][\\udc00-\\udfff]",$M="\\u200d",Vp=NM+"?",zp="["+kM+"]?",FM="(?:"+$M+"(?:"+[Bp,Hp,Gp].join("|")+")"+zp+Vp+")*",UM=zp+Vp+FM,BM="(?:"+[Bp+bc+"?",bc,Hp,Gp,PM].join("|")+")",HM=RegExp(_c+"(?="+_c+")|"+BM+UM,"g");function GM(e){return e.match(HM)||[]}function VM(e){return Fp(e)?GM(e):CM(e)}function zM(e){return function(t){t=Zi(t);var n=Fp(t)?VM(t):void 0,r=n?n[0]:t.charAt(0),i=n?xM(n,1).join(""):t.slice(1);return r[e]()+i}}var WM=zM("toUpperCase");function YM(e){return WM(Zi(e).toLowerCase())}function qM(e,t,n,r){for(var i=-1,s=e==null?0:e.length;++i<s;)n=t(n,e[i],i,e);return n}function XM(e){return function(t){return e==null?void 0:e[t]}}var jM={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},ZM=XM(jM),KM=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,QM="\\u0300-\\u036f",JM="\\ufe20-\\ufe2f",tA="\\u20d0-\\u20ff",eA=QM+JM+tA,nA="["+eA+"]",rA=RegExp(nA,"g");function iA(e){return e=Zi(e),e&&e.replace(KM,ZM).replace(rA,"")}var sA=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function aA(e){return e.match(sA)||[]}var oA=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function lA(e){return oA.test(e)}var Wp="\\ud800-\\udfff",cA="\\u0300-\\u036f",uA="\\ufe20-\\ufe2f",hA="\\u20d0-\\u20ff",dA=cA+uA+hA,Yp="\\u2700-\\u27bf",qp="a-z\\xdf-\\xf6\\xf8-\\xff",fA="\\xac\\xb1\\xd7\\xf7",pA="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",gA="\\u2000-\\u206f",mA=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Xp="A-Z\\xc0-\\xd6\\xd8-\\xde",vA="\\ufe0e\\ufe0f",jp=fA+pA+gA+mA,Zp="['’]",Kp="["+jp+"]",yA="["+dA+"]",Qp="\\d+",EA="["+Yp+"]",Jp="["+qp+"]",tg="[^"+Wp+jp+Qp+Yp+qp+Xp+"]",xA="\\ud83c[\\udffb-\\udfff]",bA="(?:"+yA+"|"+xA+")",_A="[^"+Wp+"]",eg="(?:\\ud83c[\\udde6-\\uddff]){2}",ng="[\\ud800-\\udbff][\\udc00-\\udfff]",Ur="["+Xp+"]",SA="\\u200d",rg="(?:"+Jp+"|"+tg+")",TA="(?:"+Ur+"|"+tg+")",ig="(?:"+Zp+"(?:d|ll|m|re|s|t|ve))?",sg="(?:"+Zp+"(?:D|LL|M|RE|S|T|VE))?",ag=bA+"?",og="["+vA+"]?",OA="(?:"+SA+"(?:"+[_A,eg,ng].join("|")+")"+og+ag+")*",wA="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",MA="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",AA=og+ag+OA,CA="(?:"+[EA,eg,ng].join("|")+")"+AA,DA=RegExp([Ur+"?"+Jp+"+"+ig+"(?="+[Kp,Ur,"$"].join("|")+")",TA+"+"+sg+"(?="+[Kp,Ur+rg,"$"].join("|")+")",Ur+"?"+rg+"+"+ig,Ur+"+"+sg,MA,wA,Qp,CA].join("|"),"g");function LA(e){return e.match(DA)||[]}function RA(e,t,n){return e=Zi(e),t=t,t===void 0?lA(e)?LA(e):aA(e):e.match(t)||[]}var IA="['’]",kA=RegExp(IA,"g");function lg(e){return function(t){return qM(RA(iA(t).replace(kA,"")),e,"")}}var PA=lg(function(e,t,n){return t=t.toLowerCase(),e+(n?YM(t):t)});function NA(e,t,n){return e===e&&(n!==void 0&&(e=e<=n?e:n),t!==void 0&&(e=e>=t?e:t)),e}function cg(e,t,n){return n===void 0&&(n=t,t=void 0),n!==void 0&&(n=kr(n),n=n===n?n:0),t!==void 0&&(t=kr(t),t=t===t?t:0),NA(kr(e),t,n)}function $A(){this.__data__=new xn,this.size=0}function FA(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function UA(e){return this.__data__.get(e)}function BA(e){return this.__data__.has(e)}var HA=200;function GA(e,t){var n=this.__data__;if(n instanceof xn){var r=n.__data__;if(!ji||r.length<HA-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new bn(r)}return n.set(e,t),this.size=n.size,this}function He(e){var t=this.__data__=new xn(e);this.size=t.size}He.prototype.clear=$A,He.prototype.delete=FA,He.prototype.get=UA,He.prototype.has=BA,He.prototype.set=GA;function VA(e,t){return e&&Pr(t,Yi(t),e)}function zA(e,t){return e&&Pr(t,qi(t),e)}var ug=typeof W=="object"&&W&&!W.nodeType&&W,hg=ug&&typeof module=="object"&&module&&!module.nodeType&&module,WA=hg&&hg.exports===ug,dg=WA?Be.Buffer:void 0,fg=dg?dg.allocUnsafe:void 0;function pg(e,t){if(t)return e.slice();var n=e.length,r=fg?fg(n):new e.constructor(n);return e.copy(r),r}function YA(e,t){for(var n=-1,r=e==null?0:e.length,i=0,s=[];++n<r;){var a=e[n];t(a,n,e)&&(s[i++]=a)}return s}function gg(){return[]}var qA=Object.prototype,XA=qA.propertyIsEnumerable,mg=Object.getOwnPropertySymbols,Sc=mg?function(e){return e==null?[]:(e=Object(e),YA(mg(e),function(t){return XA.call(e,t)}))}:gg;function jA(e,t){return Pr(e,Sc(e),t)}var ZA=Object.getOwnPropertySymbols,vg=ZA?function(e){for(var t=[];e;)yc(t,Sc(e)),e=xc(e);return t}:gg;function KA(e,t){return Pr(e,vg(e),t)}function yg(e,t,n){var r=t(e);return Xt(e)?r:yc(r,n(e))}function Tc(e){return yg(e,Yi,Sc)}function Eg(e){return yg(e,qi,vg)}var Oc=ir(Be,"DataView"),wc=ir(Be,"Promise"),Br=ir(Be,"Set"),xg="[object Map]",QA="[object Object]",bg="[object Promise]",_g="[object Set]",Sg="[object WeakMap]",Tg="[object DataView]",JA=rr(Oc),tC=rr(ji),eC=rr(wc),nC=rr(Br),rC=rr(cc),De=nr;(Oc&&De(new Oc(new ArrayBuffer(1)))!=Tg||ji&&De(new ji)!=xg||wc&&De(wc.resolve())!=bg||Br&&De(new Br)!=_g||cc&&De(new cc)!=Sg)&&(De=function(e){var t=nr(e),n=t==QA?e.constructor:void 0,r=n?rr(n):"";if(r)switch(r){case JA:return Tg;case tC:return xg;case eC:return bg;case nC:return _g;case rC:return Sg}return t});var iC=Object.prototype,sC=iC.hasOwnProperty;function aC(e){var t=e.length,n=new e.constructor(t);return t&&typeof e[0]=="string"&&sC.call(e,"index")&&(n.index=e.index,n.input=e.input),n}var Ba=Be.Uint8Array;function Mc(e){var t=new e.constructor(e.byteLength);return new Ba(t).set(new Ba(e)),t}function oC(e,t){var n=t?Mc(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}var lC=/\w*$/;function cC(e){var t=new e.constructor(e.source,lC.exec(e));return t.lastIndex=e.lastIndex,t}var Og=Ae?Ae.prototype:void 0,wg=Og?Og.valueOf:void 0;function uC(e){return wg?Object(wg.call(e)):{}}function Mg(e,t){var n=t?Mc(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var hC="[object Boolean]",dC="[object Date]",fC="[object Map]",pC="[object Number]",gC="[object RegExp]",mC="[object Set]",vC="[object String]",yC="[object Symbol]",EC="[object ArrayBuffer]",xC="[object DataView]",bC="[object Float32Array]",_C="[object Float64Array]",SC="[object Int8Array]",TC="[object Int16Array]",OC="[object Int32Array]",wC="[object Uint8Array]",MC="[object Uint8ClampedArray]",AC="[object Uint16Array]",CC="[object Uint32Array]";function DC(e,t,n){var r=e.constructor;switch(t){case EC:return Mc(e);case hC:case dC:return new r(+e);case xC:return oC(e,n);case bC:case _C:case SC:case TC:case OC:case wC:case MC:case AC:case CC:return Mg(e,n);case fC:return new r;case pC:case vC:return new r(e);case gC:return cC(e);case mC:return new r;case yC:return uC(e)}}function Ag(e){return typeof e.constructor=="function"&&!ka(e)?SO(xc(e)):{}}var LC="[object Map]";function RC(e){return tn(e)&&De(e)==LC}var Cg=Fr&&Fr.isMap,IC=Cg?fc(Cg):RC,kC="[object Set]";function PC(e){return tn(e)&&De(e)==kC}var Dg=Fr&&Fr.isSet,NC=Dg?fc(Dg):PC,$C=1,FC=2,UC=4,Lg="[object Arguments]",BC="[object Array]",HC="[object Boolean]",GC="[object Date]",VC="[object Error]",Rg="[object Function]",zC="[object GeneratorFunction]",WC="[object Map]",YC="[object Number]",Ig="[object Object]",qC="[object RegExp]",XC="[object Set]",jC="[object String]",ZC="[object Symbol]",KC="[object WeakMap]",QC="[object ArrayBuffer]",JC="[object DataView]",tD="[object Float32Array]",eD="[object Float64Array]",nD="[object Int8Array]",rD="[object Int16Array]",iD="[object Int32Array]",sD="[object Uint8Array]",aD="[object Uint8ClampedArray]",oD="[object Uint16Array]",lD="[object Uint32Array]",Lt={};Lt[Lg]=Lt[BC]=Lt[QC]=Lt[JC]=Lt[HC]=Lt[GC]=Lt[tD]=Lt[eD]=Lt[nD]=Lt[rD]=Lt[iD]=Lt[WC]=Lt[YC]=Lt[Ig]=Lt[qC]=Lt[XC]=Lt[jC]=Lt[ZC]=Lt[sD]=Lt[aD]=Lt[oD]=Lt[lD]=!0,Lt[VC]=Lt[Rg]=Lt[KC]=!1;function Qi(e,t,n,r,i,s){var a,o=t&$C,l=t&FC,c=t&UC;if(n&&(a=i?n(e,r,i,s):n(e)),a!==void 0)return a;if(!Ce(e))return e;var u=Xt(e);if(u){if(a=aC(e),!o)return Ep(e,a)}else{var d=De(e),h=d==Rg||d==zC;if($r(e))return pg(e,o);if(d==Ig||d==Lg||h&&!i){if(a=l||h?{}:Ag(e),!o)return l?KA(e,zA(a,e)):jA(e,VA(a,e))}else{if(!Lt[d])return i?e:{};a=DC(e,d,o)}}s||(s=new He);var f=s.get(e);if(f)return f;s.set(e,a),NC(e)?e.forEach(function(m){a.add(Qi(m,t,n,m,e,s))}):IC(e)&&e.forEach(function(m,v){a.set(v,Qi(m,t,n,v,e,s))});var p=c?l?Eg:Tc:l?qi:Yi,g=u?void 0:p(e);return RO(g||e,function(m,v){g&&(v=m,m=e[v]),bp(a,v,Qi(m,t,n,v,e,s))}),a}var cD=1,uD=4;function _n(e){return Qi(e,cD|uD)}var hD="__lodash_hash_undefined__";function dD(e){return this.__data__.set(e,hD),this}function fD(e){return this.__data__.has(e)}function Ji(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new bn;++t<n;)this.add(e[t])}Ji.prototype.add=Ji.prototype.push=dD,Ji.prototype.has=fD;function kg(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}function Pg(e,t){return e.has(t)}var pD=1,gD=2;function Ng(e,t,n,r,i,s){var a=n&pD,o=e.length,l=t.length;if(o!=l&&!(a&&l>o))return!1;var c=s.get(e),u=s.get(t);if(c&&u)return c==t&&u==e;var d=-1,h=!0,f=n&gD?new Ji:void 0;for(s.set(e,t),s.set(t,e);++d<o;){var p=e[d],g=t[d];if(r)var m=a?r(g,p,d,t,e,s):r(p,g,d,e,t,s);if(m!==void 0){if(m)continue;h=!1;break}if(f){if(!kg(t,function(v,E){if(!Pg(f,E)&&(p===v||i(p,v,n,r,s)))return f.push(E)})){h=!1;break}}else if(!(p===g||i(p,g,n,r,s))){h=!1;break}}return s.delete(e),s.delete(t),h}function mD(e){var t=-1,n=Array(e.size);return e.forEach(function(r,i){n[++t]=[i,r]}),n}function Ac(e){var t=-1,n=Array(e.size);return e.forEach(function(r){n[++t]=r}),n}var vD=1,yD=2,ED="[object Boolean]",xD="[object Date]",bD="[object Error]",_D="[object Map]",SD="[object Number]",TD="[object RegExp]",OD="[object Set]",wD="[object String]",MD="[object Symbol]",AD="[object ArrayBuffer]",CD="[object DataView]",$g=Ae?Ae.prototype:void 0,Cc=$g?$g.valueOf:void 0;function DD(e,t,n,r,i,s,a){switch(n){case CD:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case AD:return!(e.byteLength!=t.byteLength||!s(new Ba(e),new Ba(t)));case ED:case xD:case SD:return zi(+e,+t);case bD:return e.name==t.name&&e.message==t.message;case TD:case wD:return e==t+"";case _D:var o=mD;case OD:var l=r&vD;if(o||(o=Ac),e.size!=t.size&&!l)return!1;var c=a.get(e);if(c)return c==t;r|=yD,a.set(e,t);var u=Ng(o(e),o(t),r,i,s,a);return a.delete(e),u;case MD:if(Cc)return Cc.call(e)==Cc.call(t)}return!1}var LD=1,RD=Object.prototype,ID=RD.hasOwnProperty;function kD(e,t,n,r,i,s){var a=n&LD,o=Tc(e),l=o.length,c=Tc(t),u=c.length;if(l!=u&&!a)return!1;for(var d=l;d--;){var h=o[d];if(!(a?h in t:ID.call(t,h)))return!1}var f=s.get(e),p=s.get(t);if(f&&p)return f==t&&p==e;var g=!0;s.set(e,t),s.set(t,e);for(var m=a;++d<l;){h=o[d];var v=e[h],E=t[h];if(r)var y=a?r(E,v,h,t,e,s):r(v,E,h,e,t,s);if(!(y===void 0?v===E||i(v,E,n,r,s):y)){g=!1;break}m||(m=h=="constructor")}if(g&&!m){var b=e.constructor,S=t.constructor;b!=S&&"constructor"in e&&"constructor"in t&&!(typeof b=="function"&&b instanceof b&&typeof S=="function"&&S instanceof S)&&(g=!1)}return s.delete(e),s.delete(t),g}var PD=1,Fg="[object Arguments]",Ug="[object Array]",Ha="[object Object]",ND=Object.prototype,Bg=ND.hasOwnProperty;function $D(e,t,n,r,i,s){var a=Xt(e),o=Xt(t),l=a?Ug:De(e),c=o?Ug:De(t);l=l==Fg?Ha:l,c=c==Fg?Ha:c;var u=l==Ha,d=c==Ha,h=l==c;if(h&&$r(e)){if(!$r(t))return!1;a=!0,u=!1}if(h&&!u)return s||(s=new He),a||Pa(e)?Ng(e,t,n,r,i,s):DD(e,t,l,n,r,i,s);if(!(n&PD)){var f=u&&Bg.call(e,"__wrapped__"),p=d&&Bg.call(t,"__wrapped__");if(f||p){var g=f?e.value():e,m=p?t.value():t;return s||(s=new He),i(g,m,n,r,s)}}return h?(s||(s=new He),kD(e,t,n,r,i,s)):!1}function Ga(e,t,n,r,i){return e===t?!0:e==null||t==null||!tn(e)&&!tn(t)?e!==e&&t!==t:$D(e,t,n,r,Ga,i)}var FD=1,UD=2;function BD(e,t,n,r){var i=n.length,s=i;if(e==null)return!s;for(e=Object(e);i--;){var a=n[i];if(a[2]?a[1]!==e[a[0]]:!(a[0]in e))return!1}for(;++i<s;){a=n[i];var o=a[0],l=e[o],c=a[1];if(a[2]){if(l===void 0&&!(o in e))return!1}else{var u=new He,d;if(!(d===void 0?Ga(c,l,FD|UD,r,u):d))return!1}}return!0}function Hg(e){return e===e&&!Ce(e)}function HD(e){for(var t=Yi(e),n=t.length;n--;){var r=t[n],i=e[r];t[n]=[r,i,Hg(i)]}return t}function Gg(e,t){return function(n){return n==null?!1:n[e]===t&&(t!==void 0||e in Object(n))}}function GD(e){var t=HD(e);return t.length==1&&t[0][2]?Gg(t[0][0],t[0][1]):function(n){return n===e||BD(n,e,t)}}function VD(e,t){return e!=null&&t in Object(e)}function zD(e,t,n){t=Fa(t,e);for(var r=-1,i=t.length,s=!1;++r<i;){var a=Ki(t[r]);if(!(s=e!=null&&n(e,a)))break;e=e[a]}return s||++r!=i?s:(i=e==null?0:e.length,!!i&&dc(i)&&uc(a,i)&&(Xt(e)||Nr(e)))}function WD(e,t){return e!=null&&zD(e,t,VD)}var YD=1,qD=2;function XD(e,t){return gc(e)&&Hg(t)?Gg(Ki(e),t):function(n){var r=yt(n,e);return r===void 0&&r===t?WD(n,e):Ga(t,r,YD|qD)}}function jD(e){return function(t){return t==null?void 0:t[e]}}function ZD(e){return function(t){return vc(t,e)}}function KD(e){return gc(e)?jD(Ki(e)):ZD(e)}function Va(e){return typeof e=="function"?e:e==null?ac:typeof e=="object"?Xt(e)?XD(e[0],e[1]):GD(e):KD(e)}function QD(e,t,n,r){for(var i=-1,s=e==null?0:e.length;++i<s;){var a=e[i];t(r,a,n(a),e)}return r}function JD(e){return function(t,n,r){for(var i=-1,s=Object(t),a=r(t),o=a.length;o--;){var l=a[++i];if(n(s[l],l,s)===!1)break}return t}}var Vg=JD();function tL(e,t){return e&&Vg(e,t,Yi)}function eL(e,t){return function(n,r){if(n==null)return n;if(!sr(n))return e(n,r);for(var i=n.length,s=-1,a=Object(n);++s<i&&r(a[s],s,a)!==!1;);return n}}var Dc=eL(tL);function nL(e,t,n,r){return Dc(e,function(i,s,a){t(r,i,n(i),a)}),r}function rL(e,t){return function(n,r){var i=Xt(n)?QD:nL,s={};return i(n,e,Va(r),s)}}var Lc=function(){return Be.Date.now()},iL="Expected a function",sL=Math.max,aL=Math.min;function za(e,t,n){var r,i,s,a,o,l,c=0,u=!1,d=!1,h=!0;if(typeof e!="function")throw new TypeError(iL);t=kr(t)||0,Ce(n)&&(u=!!n.leading,d="maxWait"in n,s=d?sL(kr(n.maxWait)||0,t):s,h="trailing"in n?!!n.trailing:h);function f(_){var A=r,R=i;return r=i=void 0,c=_,a=e.apply(R,A),a}function p(_){return c=_,o=setTimeout(v,t),u?f(_):a}function g(_){var A=_-l,R=_-c,B=t-A;return d?aL(B,s-R):B}function m(_){var A=_-l,R=_-c;return l===void 0||A>=t||A<0||d&&R>=s}function v(){var _=Lc();if(m(_))return E(_);o=setTimeout(v,g(_))}function E(_){return o=void 0,h&&r?f(_):(r=i=void 0,a)}function y(){o!==void 0&&clearTimeout(o),c=0,r=l=i=o=void 0}function b(){return o===void 0?a:E(Lc())}function S(){var _=Lc(),A=m(_);if(r=arguments,i=this,l=_,A){if(o===void 0)return p(l);if(d)return clearTimeout(o),o=setTimeout(v,t),f(l)}return o===void 0&&(o=setTimeout(v,t)),a}return S.cancel=y,S.flush=b,S}function Rc(e,t,n){(n!==void 0&&!zi(e[t],n)||n===void 0&&!(t in e))&&Ia(e,t,n)}function Ic(e){return tn(e)&&sr(e)}function kc(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}function oL(e){return Pr(e,qi(e))}function lL(e,t,n,r,i,s,a){var o=kc(e,n),l=kc(t,n),c=a.get(l);if(c){Rc(e,n,c);return}var u=s?s(o,l,n+"",e,t,a):void 0,d=u===void 0;if(d){var h=Xt(l),f=!h&&$r(l),p=!h&&!f&&Pa(l);u=l,h||f||p?Xt(o)?u=o:Ic(o)?u=Ep(o):f?(d=!1,u=pg(l,!0)):p?(d=!1,u=Mg(l,!0)):u=[]:Np(l)||Nr(l)?(u=o,Nr(o)?u=oL(o):(!Ce(o)||oc(o))&&(u=Ag(l))):d=!1}d&&(a.set(l,u),i(u,l,r,s,a),a.delete(l)),Rc(e,n,u)}function zg(e,t,n,r,i){e!==t&&Vg(t,function(s,a){if(i||(i=new He),Ce(s))lL(e,t,a,n,zg,r,i);else{var o=r?r(kc(e,a),s,a+"",e,t,i):void 0;o===void 0&&(o=s),Rc(e,a,o)}},qi)}var cL="Expected a function";function uL(e,t,n){if(typeof e!="function")throw new TypeError(cL);return setTimeout(function(){e.apply(void 0,n)},t)}var hL=hc(function(e,t,n){return uL(e,kr(t)||0,n)});function Wg(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}function dL(e,t){var n=-1,r=sr(e)?Array(e.length):[];return Dc(e,function(i,s,a){r[++n]=t(i,s,a)}),r}function fL(e,t){var n=Xt(e)?sc:dL;return n(e,Va(t))}var pL=1/0;function gL(e,t){return Ua(fL(e,t),pL)}function mL(e){for(var t=-1,n=e==null?0:e.length,r={};++t<n;){var i=e[t];r[i[0]]=i[1]}return r}var vL=Object.prototype,yL=vL.hasOwnProperty,EL=rL(function(e,t,n){yL.call(e,n)?e[n].push(t):Ia(e,n,[t])});function xL(e,t){return t.length<2?e:vc(e,$p(t,0,-1))}var bL="[object Map]",_L="[object Set]",SL=Object.prototype,TL=SL.hasOwnProperty;function Ge(e){if(e==null)return!0;if(sr(e)&&(Xt(e)||typeof e=="string"||typeof e.splice=="function"||$r(e)||Pa(e)||Nr(e)))return!e.length;var t=De(e);if(t==bL||t==_L)return!e.size;if(ka(e))return!Ip(e).length;for(var n in e)if(TL.call(e,n))return!1;return!0}function Yg(e,t){return Ga(e,t)}var Hr=lg(function(e,t,n){return e+(n?"-":"")+t.toLowerCase()}),lt=zO(function(e,t,n){zg(e,t,n)});function OL(e,t){return t=Fa(t,e),e=xL(e,t),e==null||delete e[Ki(Wg(t))]}function wL(e){return Np(e)?void 0:e}var ML=1,AL=2,CL=4,DL=pM(function(e,t){var n={};if(e==null)return n;var r=!1;t=sc(t,function(s){return s=Fa(s,e),r||(r=s.length>1),s}),Pr(e,Eg(e),n),r&&(n=Qi(n,ML|AL|CL,wL));for(var i=t.length;i--;)OL(n,t[i]);return n});function LL(e,t){var n;return Dc(e,function(r,i,s){return n=t(r,i,s),!n}),!!n}function RL(e,t,n){var r=Xt(e)?kg:LL;return r(e,Va(t))}var IL=1/0,kL=Br&&1/Ac(new Br([,-0]))[1]==IL?function(e){return new Br(e)}:OO,PL=200;function qg(e,t,n){var r=-1,i=$O,s=e.length,a=!0,o=[],l=o;if(s>=PL){var c=t?null:kL(e);if(c)return Ac(c);a=!1,i=Pg,l=new Ji}else l=t?[]:o;t:for(;++r<s;){var u=e[r],d=t?t(u):u;if(u=u!==0?u:0,a&&d===d){for(var h=l.length;h--;)if(l[h]===d)continue t;t&&l.push(d),o.push(u)}else i(l,d,n)||(l!==o&&l.push(d),o.push(u))}return o}var NL=hc(function(e){var t=Wg(e);return Ic(t)&&(t=void 0),qg(Ua(e,1,Ic,!0),Va(t))});function ts(e){return e&&e.length?qg(e):[]}var Pc=(e=>(e.RENDER_FINISHED="render-finished",e.RESIZE="chart-resize",e.MOUSEOVER="chart-mouseover",e.MOUSEOUT="chart-mouseout",e))(Pc||{}),Nc=(e=>(e.SHOW="show-modal",e.HIDE="hide-modal",e))(Nc||{}),$c=(e=>(e.UPDATE="model-update",e))($c||{}),Xg=(e=>(e.SHOW_OVERFLOW_MENU="show-toolbar-overflow-menu",e.HIDE_OVERFLOW_MENU="hide-toolbar-overflow-menu",e.BUTTON_CLICK="toolbar-button-click",e.SHOW_TOOLTIP="toolbar-show-tooltip",e.HIDE_TOOLTIP="toolbar-hide-tooltip",e))(Xg||{}),Fc=(e=>(e.UPDATE="zoom-bar-update",e.SELECTION_START="zoom-bar-selection-start",e.SELECTION_IN_PROGRESS="zoom-bar-selection-in-progress",e.SELECTION_END="zoom-bar-selection-end",e))(Fc||{}),Uc=(e=>(e.CHANGE="zoom-domain-change",e))(Uc||{}),Bc=(e=>(e.CANVAS_ZOOM_IN="canvas-zoom-in",e.CANVAS_ZOOM_OUT="canvas-zoom-out",e))(Bc||{}),Hc=(e=>(e.LABEL_MOUSEOVER="axis-label-mouseover",e.LABEL_MOUSEMOVE="axis-label-mousemove",e.LABEL_CLICK="axis-label-click",e.LABEL_MOUSEOUT="axis-label-mouseout",e.LABEL_FOCUS="axis-label-focus",e.LABEL_BLUR="axis-label-blur",e.RENDER_COMPLETE="axis-render-complete",e))(Hc||{}),Gc=(e=>(e.POINT_MOUSEOVER="scatter-mouseover",e.POINT_MOUSEMOVE="scatter-mousemove",e.POINT_CLICK="scatter-click",e.POINT_MOUSEOUT="scatter-mouseout",e))(Gc||{}),Vc=(e=>(e.WORD_MOUSEOVER="wordcloud-word-mouseover",e.WORD_MOUSEMOVE="wordcloud-word-mousemove",e.WORD_CLICK="wordcloud-word-click",e.WORD_MOUSEOUT="wordcloud-word-mouseout",e))(Vc||{}),zc=(e=>(e.SLICE_MOUSEOVER="pie-slice-mouseover",e.SLICE_MOUSEMOVE="pie-slice-mousemove",e.SLICE_CLICK="pie-slice-click",e.SLICE_MOUSEOUT="pie-slice-mouseout",e))(zc||{}),Wc=(e=>(e.ARC_MOUSEOVER="gauge-arc-mouseover",e.ARC_MOUSEMOVE="gauge-arc-mousemove",e.ARC_CLICK="gauge-arc-click",e.ARC_MOUSEOUT="gauge-arc-mouseout",e))(Wc||{}),Yc=(e=>(e.BAR_MOUSEOVER="bar-mouseover",e.BAR_MOUSEMOVE="bar-mousemove",e.BAR_CLICK="bar-click",e.BAR_MOUSEOUT="bar-mouseout",e))(Yc||{}),qc=(e=>(e.BOX_MOUSEOVER="box-mouseover",e.BOX_MOUSEMOVE="box-mousemove",e.BOX_CLICK="box-click",e.BOX_MOUSEOUT="box-mouseout",e.OUTLIER_MOUSEOVER="outlier-mouseover",e.OUTLIER_MOUSEMOVE="outlier-mousemove",e.OUTLIER_CLICK="outlier-click",e.OUTLIER_MOUSEOUT="outlier-mouseout",e))(qc||{}),Xc=(e=>(e.SCATTER_MOUSEOVER="scatter-mouseover",e.SCATTER_MOUSEMOVE="scatter-mousemove",e.SCATTER_CLICK="scatter-click",e.SCATTER_MOUSEOUT="scatter-mouseout",e))(Xc||{}),jc=(e=>(e.POINT_MOUSEOVER="scatter-mouseover",e.POINT_MOUSEMOVE="scatter-mousemove",e.POINT_CLICK="scatter-click",e.POINT_MOUSEOUT="scatter-mouseout",e))(jc||{}),Zc=(e=>(e.X_AXIS_MOUSEOVER="radar-x-axis-mouseover",e.X_AXIS_MOUSEMOVE="radar-x-axis-mousemove",e.X_AXIS_CLICK="radar-x-axis-click",e.X_AXIS_MOUSEOUT="radar-x-axis-mouseout",e))(Zc||{}),Kc=(e=>(e.NODE_MOUSEOVER="tree-node-mouseover",e.NODE_CLICK="tree-node-click",e.NODE_MOUSEOUT="tree-node-mouseout",e))(Kc||{}),Qc=(e=>(e.LEAF_MOUSEOVER="leaf-mouseover",e.LEAF_MOUSEMOVE="leaf-mousemove",e.LEAF_CLICK="leaf-click",e.LEAF_MOUSEOUT="leaf-mouseout",e))(Qc||{}),Gr=(e=>(e.SHOW="show-tooltip",e.MOVE="move-tooltip",e.HIDE="hide-tooltip",e))(Gr||{}),Jc=(e=>(e.SHOW="show-threshold",e.HIDE="hide-threshold",e))(Jc||{}),jg=(e=>(e.ITEM_HOVER="legend-item-onhover",e.ITEM_CLICK="legend-item-onclick",e.ITEM_MOUSEOUT="legend-item-onmouseout",e.ITEMS_UPDATE="legend-items-update",e))(jg||{}),Zg=(e=>(e.CIRCLE_MOUSEOVER="circle-leaf-mouseover",e.CIRCLE_CLICK="circle-leaf-click",e.CIRCLE_MOUSEOUT="circle-leaf-mouseout",e.CIRCLE_MOUSEMOVE="circle-leaf-mousemove",e))(Zg||{}),Kg=(e=>(e.NODE_MOUSEOVER="alluvial-node-mouseover",e.NODE_CLICK="alluvial-node-click",e.NODE_MOUSEOUT="alluvial-node-mouseout",e.NODE_MOUSEMOVE="alluvial-node-mousemove",e.LINE_MOUSEOVER="alluvial-line-mouseover",e.LINE_CLICK="alluvial-line-click",e.LINE_MOUSEOUT="alluvial-line-mouseout",e.LINE_MOUSEMOVE="alluvial-line-mousemove",e))(Kg||{}),Qg=(e=>(e.METER_MOUSEOVER="meter-mouseover",e.METER_CLICK="meter-click",e.METER_MOUSEOUT="meter-mouseout",e.METER_MOUSEMOVE="meter-mousemove",e))(Qg||{}),Jg=(e=>(e.HEATMAP_MOUSEOVER="heatmap-mouseover",e.HEATMAP_CLICK="heatmap-click",e.HEATMAP_MOUSEOUT="heatmap-mouseout",e.HEATMAP_MOUSEMOVE="hetmap-mousemove",e))(Jg||{}),Vr=(e=>(e.CHOROPLETH_MOUSEOVER="choropleth-mouseover",e.CHOROPLETH_CLICK="choropleth-click",e.CHOROPLETH_MOUSEOUT="choropleth-mouseout",e.CHOROPLETH_MOUSEMOVE="choropleth-mousemove",e))(Vr||{});const T=Object.freeze(Object.defineProperty({__proto__:null,Alluvial:Kg,Area:Gc,Axis:Hc,Bar:Yc,Boxplot:qc,CanvasZoom:Bc,Chart:Pc,Choropleth:Vr,CirclePack:Zg,Gauge:Wc,Heatmap:Jg,Legend:jg,Line:jc,Meter:Qg,Modal:Nc,Model:$c,Pie:zc,Radar:Zc,Scatter:Xc,Threshold:Jc,Toolbar:Xg,Tooltip:Gr,Tree:Kc,Treemap:Qc,WordCloud:Vc,ZoomBar:Fc,ZoomDomain:Uc},Symbol.toStringTag,{value:"Module"}));var et=(e=>(e.HTML="html",e.SVG="svg",e))(et||{}),tu=(e=>(e.WHITE="white",e.G100="g100",e.G90="g90",e.G10="g10",e))(tu||{}),at=(e=>(e.BACKGROUND="background",e.FILL="fill",e.STROKE="stroke",e.TOOLTIP="tooltip",e))(at||{}),V=(e=>(e.LEFT="left",e.RIGHT="right",e.TOP="top",e.BOTTOM="bottom",e))(V||{}),Ve=(e=>(e.GRAPH_VIEW="graph_view",e.SLIDER_VIEW="slider_view",e))(Ve||{}),Le=(e=>(e.END_LINE="end_line",e.MID_LINE="mid_line",e.FRONT_LINE="front_line",e.NONE="none",e))(Le||{}),Ht=(e=>(e.VERTICAL="vertical",e.HORIZONTAL="horizontal",e))(Ht||{}),J=(e=>(e.TIME="time",e.LINEAR="linear",e.LOG="log",e.LABELS="labels",e.LABELS_RATIO="labels-ratio",e))(J||{}),zr=(e=>(e.RIGHT="right",e.LEFT="left",e.TOP="top",e.BOTTOM="bottom",e))(zr||{}),Gt=(e=>(e.LEFT="left",e.CENTER="center",e.RIGHT="right",e))(Gt||{}),Wr=(e=>(e.HORIZONTAL="horizontal",e.VERTICAL="vertical",e))(Wr||{}),Wa=(e=>(e.TREE="tree",e.DENDROGRAM="dendrogram",e))(Wa||{}),Mt=(e=>(e.ROW="row",e.COLUMN="column",e.ROW_REVERSE="row-reverse",e.COLUMN_REVERSE="column-reverse",e))(Mt||{}),ct=(e=>(e.FIXED="fixed",e.PREFERRED="preferred",e.STRETCH="stretch",e))(ct||{}),or=(e=>(e.CENTER="center",e))(or||{}),es=(e=>(e.LEFT="left",e.RIGHT="right",e))(es||{}),Vt=(e=>(e.GRID="grid",e.VERT_OR_HORIZ="vertOrHoriz",e.PIE="pie",e.DONUT="donut",e))(Vt||{}),en=(e=>(e.START="start",e.MIDDLE="middle",e.END="end",e))(en||{}),nn=(e=>(e.BASELINE="baseline",e.MIDDLE="middle",e.HANGING="hanging",e))(nn||{}),lr=(e=>(e.SEMI="semi",e.FULL="full",e))(lr||{}),Ya=(e=>(e.UP="up",e.DOWN="down",e))(Ya||{}),ns=(e=>(e.SUCCESS="success",e.WARNING="warning",e.DANGER="danger",e))(ns||{}),rs=(e=>(e.ALWAYS="always",e.AUTO="auto",e.NEVER="never",e))(rs||{}),xe=(e=>(e.SCATTER="scatter",e.LINE="line",e.SIMPLE_BAR="simple-bar",e.STACKED_BAR="stacked-bar",e.GROUPED_BAR="grouped-bar",e.AREA="area",e.STACKED_AREA="stacked-area",e))(xe||{}),_t=(e=>(e.EXPORT_CSV="Export as CSV",e.EXPORT_PNG="Export as PNG",e.EXPORT_JPG="Export as JPG",e.ZOOM_IN="Zoom in",e.ZOOM_OUT="Zoom out",e.RESET_ZOOM="Reset zoom",e.MAKE_FULLSCREEN="Make fullscreen",e.EXIT_FULLSCREEN="Exit fullscreen",e.SHOW_AS_DATATABLE="Show as data-table",e.CUSTOM="Custom",e))(_t||{}),qa=(e=>(e.LEFT="left",e.RIGHT="right",e))(qa||{}),zt=(e=>(e.CHECKBOX="checkbox",e.RADIUS="radius",e.AREA="area",e.SIZE="size",e.LINE="line",e.QUARTILE="quartile",e.ZOOM="zoom",e))(zt||{}),is=(e=>(e.LINEAR="linear",e.QUANTIZE="quantize",e))(is||{}),Yr=(e=>(e.ON="on",e.AUTO="auto",e.OFF="off",e))(Yr||{}),ss=(e=>(e.DEFAULT="default",e.HOVERABLE="hoverable",e))(ss||{}),rn=(e=>(e.geoEqualEarth="geoEqualEarth",e.geoAlbers="geoAlbers",e.geoConicEqualArea="geoConicEqualArea",e.geoConicEquidistant="geoConicEquidistant",e.geoEquirectangular="geoEquirectangular",e.geoMercator="geoMercator",e.geoNaturalEarth1="geoNaturalEarth1",e))(rn||{});const de="cds",Sn={opacity:{unselected:.05,selected:.4}},Pn={ticks:{number:7,rotateIfSmallerThan:30,verticalSpaceRatio:2.5,horizontalSpaceRatio:3.5},ratio:{reference:"value",compareTo:"marker"},paddingRatio:.1,hover:{rectanglePadding:4}},qr={duration:1e3,ease:Jh,zoomLevel:3},Xr={circles:{fillOpacity:.3,hover:{stroke:"#FFF"}},padding:{mainGroup:4,children:2},hierarchyLevel:2},tm={pairingOptions:{"1-color":4,"2-color":5,"3-color":5,"4-color":3,"5-color":2,"14-color":1}},Re={circle:{radius:4,opacity:{hovered:1,default:.3}},box:{opacity:{hovered:.5,default:.3}},strokeWidth:{default:1,thicker:2}},$L={defaultBins:10},Nt={items:{status:{ACTIVE:1,DISABLED:0},horizontalSpace:12,verticalSpace:24,textYOffset:8,spaceAfter:4},checkbox:{radius:6.5},radius:{iconData:[{cx:7,cy:7,r:6.5},{cx:7,cy:10,r:3.5}],fill:null,stroke:"#8c8c8c"},line:{yPosition:6,width:24,strokeWidth:1.4,fill:null,stroke:"#999999"},area:{width:24,height:14,fill:"#6f6f6f",stroke:null},size:{iconData:[{width:23,height:12},{width:13,height:6}],fill:null,stroke:"#8D8D8D"},quartile:{iconData:[{x:0,y:0,width:24,height:13},{x:11,y:4,width:1,height:4}]},zoom:{iconData:[{x:0,y:0,width:12,height:12}],color:"#8D8D8D"},color:{barWidth:300,barHeight:8,axisYTranslation:10}},Tn={opacity:{unselected:.3,selected:1},weight:{selected:2,unselected:1}},jt={statusBar:{paddingRight:5},status:{indicatorSize:16,paddingLeft:15},total:{paddingLeft:36,paddingRight:24},height:{default:8,proportional:16},dividerWidth:2},Rt={radiusOffset:-15,innerRadius:2,padAngle:.007,hoverArc:{outerRadiusOffset:3},xOffset:30,yOffset:20,yOffsetCallout:10,callout:{minSliceDegree:5,offsetX:15,offsetY:12,horizontalLineLength:8,textMargin:2}},cr={opacity:{unselected:.1,selected:.3},xLabelPadding:10,yLabelPadding:8,yTicksNumber:4,minRange:10,xAxisRectHeight:50,dotsRadius:5},ze={nodeWidth:4,nodeHoveredWidth:8,minNodePadding:24,opacity:{unfocus:.3,default:.8,selected:1}},em={minCellDividerDimension:16,chartPadding:.5},nm={default:{size:24}},FL={defaultOffset:4,horizontalOffset:10},rm={default:{duration:300},pie_slice_mouseover:{duration:100},pie_slice_mouseout:{duration:100},pie_chart_titles:{duration:375},graph_element_mouseover_fill_update:{duration:100},graph_element_mouseout_fill_update:{duration:100}},be={height:{[Ve.GRAPH_VIEW]:32,[Ve.SLIDER_VIEW]:10},spacerHeight:8,handleWidth:5,handleBarWidth:1,handleBarHeight:12},UL=[{type:zt.RADIUS,name:"Radius"},{type:zt.AREA,name:"Poor area"},{type:zt.AREA,name:"Satisfactory area"},{type:zt.AREA,name:"Great area"},{type:zt.QUARTILE,name:"Quartiles"}];function BL(e,t,n){let r=null;return function(...i){const s=this;s.mousePosition=zn(i[0],n),clearTimeout(r),r=setTimeout(function(){e.apply(s,i)},t)}}function Pt(e,t){var i;const n=_n(e),r=Object.keys(t.axes||{});(i=t==null?void 0:t.toolbar)!=null&&i.controls&&delete n.toolbar.controls,r.length===0&&delete n.axes;for(const s in n.axes)if(r.includes(s)){const a=t.axes[s];(a.primary||a.secondary)&&console.warn("`primary` & `secondary` are no longer needed for axis configurations. Read more here https://charts.carbondesignsystem.com/?path=/story/docs-tutorials--tabular-data-format");const o=a.mapsTo;if(o==null){const l=a.scaleType;l==null?a.mapsTo="value":l===J.TIME?a.mapsTo="date":l===J.LABELS&&(a.mapsTo="key")}}else delete n.axes[s];return nu(n,t),lt(n,t)}function On(e){if(!e)return;const t=/translate\([0-9]+\.?[0-9]*,[0-9]+\.?[0-9]*\)/,n=e.getAttribute("transform").match(t);if(!n)return null;if(n[0]){const r=n[0].replace(/translate\(/,"").replace(/\)/,"").split(",");return{tx:r[0],ty:r[1]}}return null}function as(e){const n=/\(([^)]+)\)/.exec(e);if(n&&n.length>1){const r=n[1].split(",");if(r.length>1)return{x:parseFloat(r[0]),y:parseFloat(r[1])}}return{x:0,y:0}}function eu(e,t,n="value",r=!1){const i=e/t.reduce((s,a)=>s+a[n],0)*100;return r?i:i%1!==0?parseFloat(i.toFixed(1)):i}function os(e,t,n){if(n>e.length)return e;if(t===Le.MID_LINE)return e.substr(0,n/2)+"..."+e.substr(-n/2);if(t===Le.FRONT_LINE)return"..."+e.substr(-n);if(t===Le.END_LINE)return e.substr(0,n)+"..."}function nu(e,t){const n=x(e,"legend","additionalItems"),r=x(t,"legend","additionalItems");if(n&&r){const i=r.map(o=>o.type),s=n.map(o=>o.type),a=UL.filter(o=>s.includes(o.type)&&!i.includes(o.type));e.legend.additionalItems=a,t.legend.additionalItems=NL(a,r,"name")}}const x=(e,...t)=>{let n=e;if(n){for(const r of t)if(n[r]!==null&&n[r]!==void 0)n=n[r];else return null;return n}return null},im=(e,t)=>t===Ht.HORIZONTAL?{y0:e.x0,y1:e.x1,x0:e.y0,x1:e.y1}:e,ie=(e,t)=>{const{x0:n,x1:r,y0:i,y1:s}=im(e,t);return`M${n},${i}L${n},${s}L${r},${s}L${r},${i}L${n},${i}`};function wn(e,t,n){return n===Ht.VERTICAL?[e,t]:[t,e]}function ru(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}function ls(e){return(t,n)=>{const r=n!=null&&n.context?String(n.context):"standalone";let i;if(r==="formatting"&&e.formattingValues){const a=e.defaultFormattingWidth||e.defaultWidth,o=n!=null&&n.width?String(n.width):a;i=e.formattingValues[o]||e.formattingValues[a]}else{const a=e.defaultWidth,o=n!=null&&n.width?String(n.width):e.defaultWidth;i=e.values[o]||e.values[a]}const s=e.argumentCallback?e.argumentCallback(t):t;return i[s]}}function cs(e){return(t,n={})=>{const r=n.width,i=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],s=t.match(i);if(!s)return null;const a=s[0],o=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],l=Array.isArray(o)?GL(o,d=>d.test(a)):HL(o,d=>d.test(a));let c;c=e.valueCallback?e.valueCallback(l):l,c=n.valueCallback?n.valueCallback(c):c;const u=t.slice(a.length);return{value:c,rest:u}}}function HL(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function GL(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function VL(e){return(t,n={})=>{const r=t.match(e.matchPattern);if(!r)return null;const i=r[0],s=t.match(e.parsePattern);if(!s)return null;let a=e.valueCallback?e.valueCallback(s[0]):s[0];a=n.valueCallback?n.valueCallback(a):a;const o=t.slice(i.length);return{value:a,rest:o}}}function xt(e){const t=Object.prototype.toString.call(e);return e instanceof Date||typeof e=="object"&&t==="[object Date]"?new e.constructor(+e):typeof e=="number"||t==="[object Number]"||typeof e=="string"||t==="[object String]"?new Date(e):new Date(NaN)}let zL={};function Xa(){return zL}function us(e,t){var o,l,c,u;const n=Xa(),r=(t==null?void 0:t.weekStartsOn)??((l=(o=t==null?void 0:t.locale)==null?void 0:o.options)==null?void 0:l.weekStartsOn)??n.weekStartsOn??((u=(c=n.locale)==null?void 0:c.options)==null?void 0:u.weekStartsOn)??0,i=xt(e),s=i.getDay(),a=(s<r?7:0)+s-r;return i.setDate(i.getDate()-a),i.setHours(0,0,0,0),i}const WL={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},YL=(e,t,n)=>{let r;const i=WL[e];return typeof i=="string"?r=i:t===1?r=i.one:r=i.other.replace("{{count}}",t.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r},qL={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},XL=(e,t,n,r)=>qL[e],jL={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},ZL={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},KL={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},QL={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},JL={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},tR={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},eR={ordinalNumber:(e,t)=>{const n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},era:ls({values:jL,defaultWidth:"wide"}),quarter:ls({values:ZL,defaultWidth:"wide",argumentCallback:e=>e-1}),month:ls({values:KL,defaultWidth:"wide"}),day:ls({values:QL,defaultWidth:"wide"}),dayPeriod:ls({values:JL,defaultWidth:"wide",formattingValues:tR,defaultFormattingWidth:"wide"})},nR=/^(\d+)(th|st|nd|rd)?/i,rR=/\d+/i,iR={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},sR={any:[/^b/i,/^(a|c)/i]},aR={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},oR={any:[/1/i,/2/i,/3/i,/4/i]},lR={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},cR={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},uR={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},hR={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},dR={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},fR={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},pR={ordinalNumber:VL({matchPattern:nR,parsePattern:rR,valueCallback:e=>parseInt(e,10)}),era:cs({matchPatterns:iR,defaultMatchWidth:"wide",parsePatterns:sR,defaultParseWidth:"any"}),quarter:cs({matchPatterns:aR,defaultMatchWidth:"wide",parsePatterns:oR,defaultParseWidth:"any",valueCallback:e=>e+1}),month:cs({matchPatterns:lR,defaultMatchWidth:"wide",parsePatterns:cR,defaultParseWidth:"any"}),day:cs({matchPatterns:uR,defaultMatchWidth:"wide",parsePatterns:hR,defaultParseWidth:"any"}),dayPeriod:cs({matchPatterns:dR,defaultMatchWidth:"any",parsePatterns:fR,defaultParseWidth:"any"})},gR={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},mR={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},vR={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},yR={date:ru({formats:gR,defaultWidth:"full"}),time:ru({formats:mR,defaultWidth:"full"}),dateTime:ru({formats:vR,defaultWidth:"full"})},sm={code:"en-US",formatDistance:YL,formatLong:yR,formatRelative:XL,localize:eR,match:pR,options:{weekStartsOn:0,firstWeekContainsDate:1}},jr={type:Le.END_LINE,threshold:16,numCharacter:14},ER={code:typeof navigator<"u"&&(navigator==null?void 0:navigator.language)||"en-US",number:(e,t=(navigator==null?void 0:navigator.language)||"en-US")=>e.toLocaleString(t),date:(e,t=(navigator==null?void 0:navigator.language)||"en-US",n={},r=null)=>r||e.toLocaleDateString(t,n),time:(e,t=(navigator==null?void 0:navigator.language)||"en-US",n={},r=null)=>r||e.toLocaleTimeString(t,n),optionsObject:{"15seconds":{primary:{"MMM d, pp":{month:"short",day:"numeric",hour:"numeric",minute:"2-digit",second:"2-digit",hourCycle:"h12"},"MMM d, h:mm:ss.SSS a":{month:"short",day:"numeric",hour:"numeric",minute:"2-digit",fractionalSecondDigits:3,hourCycle:"h12"}},secondary:{pp:{hour:"numeric",minute:"2-digit",second:"2-digit",hourCycle:"h12"},"h:mm:ss.SSS a":{hour:"numeric",minute:"2-digit",fractionalSecondDigits:3,hourCycle:"h12"}},type:"time"},minute:{primary:{"MMM d, p":{month:"short",day:"numeric",hour:"numeric",minute:"2-digit",hourCycle:"h12"}},secondary:{p:{hour:"numeric",minute:"2-digit",hourCycle:"h12"}},type:"time"},"30minutes":{primary:{"MMM d, p":{month:"short",day:"numeric",hour:"numeric",minute:"2-digit",hourCycle:"h12"}},secondary:{p:{hour:"numeric",minute:"2-digit",hourCycle:"h12"}},type:"time"},hourly:{primary:{"MMM d, hh a":{month:"short",day:"numeric",hour:"2-digit",hourCycle:"h12"}},secondary:{"hh a":{hour:"2-digit",hourCycle:"h12"}},type:"time"},daily:{primary:{"MMM d":{month:"short",day:"numeric"}},secondary:{d:{day:"numeric"}},type:"date"},weekly:{primary:{"eee, MMM d":{weekday:"short",month:"short",day:"numeric"}},secondary:{eee:{weekday:"short"}},type:"date"},monthly:{primary:{"MMM yyyy":{month:"short",year:"numeric"}},secondary:{MMM:{month:"short"}},type:"date"},quarterly:{primary:{},secondary:{},type:"date"},yearly:{primary:{yyyy:{year:"numeric"}},secondary:{yyyy:{year:"numeric"}},type:"date"}},translations:{group:"Group",total:"Total",meter:{title:""},tabularRep:{title:"Tabular representation",downloadAsCSV:"Download as CSV"},toolbar:{exportAsCSV:"Export to CSV",exportAsJPG:"Export to JPG",exportAsPNG:"Export to PNG",zoomIn:"Zoom in",zoomOut:"Zoom out",resetZoom:"Reset zoom",moreOptions:"More options",makeFullScreen:"Make fullscreen",exitFullScreen:"Exit fullscreen",showAsTable:"Show as table"}}},xR={enabled:!0,position:zr.BOTTOM,clickable:!0,truncation:jr,alignment:Gt.LEFT,order:null,additionalItems:[]},bR={x:{enabled:!0,numberOfTicks:15,alignWithAxisTicks:!1},y:{enabled:!0,numberOfTicks:5,alignWithAxisTicks:!1}},_R={enabled:!0},am={enabled:!0,showTotal:!0,truncation:jr,groupLabel:"Group"},om={top:{visible:!0,includeZero:!0,truncation:jr},bottom:{visible:!0,includeZero:!0,truncation:jr},left:{visible:!0,includeZero:!0,truncation:jr},right:{visible:!0,includeZero:!0,truncation:jr}},ja={addSpaceOnEdges:1,showDayName:!1,localeObject:sm,timeIntervalFormats:{"15seconds":{primary:"MMM d, pp",secondary:"pp"},minute:{primary:"MMM d, p",secondary:"p"},"30minutes":{primary:"MMM d, p",secondary:"p"},hourly:{primary:"MMM d, hh a",secondary:"hh a"},daily:{primary:"MMM d",secondary:"d"},weekly:{primary:"eee, MMM d",secondary:"eee"},monthly:{primary:"MMM yyyy",secondary:"MMM"},quarterly:{primary:"QQQ ''yy",secondary:"QQQ"},yearly:{primary:"yyyy",secondary:"yyyy"}}};let lm=!1;try{lm=typeof document<"u"&&(document.fullscreenEnabled||document.webkitFullscreenEnabled||document.mozFullScreenEnabled||document.msFullscreenEnabled)}catch(e){console.warn("Fullscreen capabilities check failed: ",e.message)}const ee={width:null,height:null,resizable:!0,theme:tu.WHITE,tooltip:am,legend:xR,locale:ER,style:{prefix:"cc"},data:{groupMapsTo:"group",loading:!1,selectedGroups:[]},color:{scale:null,pairing:{numberOfVariants:null,option:1},gradient:{enabled:!1}},toolbar:{enabled:!0,numberOfIcons:3,controls:[{type:_t.SHOW_AS_DATATABLE},...lm?[{type:_t.MAKE_FULLSCREEN}]:[],{type:_t.EXPORT_CSV},{type:_t.EXPORT_PNG},{type:_t.EXPORT_JPG}]}},cm=lt({},ee,{thematic:{projection:rn.geoNaturalEarth1}}),hs=lt({},ee,{axes:om,timeScale:ja,grid:bR,ruler:_R,zoomBar:{zoomRatio:.4,minZoomRatio:.01,top:{enabled:!1,type:Ve.GRAPH_VIEW}}}),ur=lt({},hs,{bars:{maxWidth:16,spacingFactor:.25},timeScale:lt(ja,{addSpaceOnEdges:1})}),SR=lt({},ur,{}),TR=lt({},ur,{}),OR=lt({},ur,{bars:lt({},ur.bars,{dividerSize:1.5})}),wR=lt({},ur,{}),iu=lt({},hs,{points:{radius:4,fillOpacity:.3,filled:!0,enabled:!0}}),MR=iu,um=lt({},iu,{points:{radius:3,filled:!1,enabled:!0}}),hm=lt({},um,{timeScale:lt(ja,{addSpaceOnEdges:0})}),AR=hm,CR=lt({},hs,{bubble:{radiusMapsTo:"radius",radiusLabel:"Radius",radiusRange:e=>{const t=Math.min(e.width,e.height);return[t*3/400,t*25/400]},fillOpacity:.2,enabled:!0},points:{filled:!0},legend:{additionalItems:[{type:zt.RADIUS,name:"Radius"}]}}),DR=lt({},hs,{bullet:{performanceAreaTitles:["Poor","Satisfactory","Great"]},grid:{x:{enabled:!1},y:{enabled:!1}},legend:{additionalItems:[{type:zt.AREA,name:"Poor area"},{type:zt.AREA,name:"Satisfactory area"},{type:zt.AREA,name:"Great area"},{type:zt.QUARTILE,name:"Quartiles"}]}}),LR=lt({},ur,{bars:{dividerSize:1.5},timeScale:lt(ja,{addSpaceOnEdges:0})}),RR=lt({},ee,{tooltip:lt({},am,{wordLabel:"Word",valueLabel:"Value"}),wordCloud:{fontSizeMapsTo:"value",fontSizeRange:e=>{const t=Math.min(e.width,e.height);return[t*20/400,t*75/400]},wordMapsTo:"word"}}),dm=lt({},ee,{pie:{labels:{formatter:null,enabled:!0},alignment:Gt.LEFT,sortFunction:null,valueMapsTo:"value"}}),IR=lt({},ee,{legend:{enabled:!1},gauge:{type:lr.SEMI,arcWidth:16,deltaArrow:{size:e=>e/8,enabled:!0},showPercentageSymbol:!0,status:null,numberSpacing:10,deltaFontSize:e=>e/8,valueFontSize:e=>e/2.5,alignment:Gt.LEFT}}),kR=lt({},dm,{donut:{center:{numberFontSize:e=>`${Math.min(e/100*24,24)}px`,titleFontSize:e=>`${Math.min(e/100*15,15)}px`,titleYPosition:e=>Math.min(e/80*20,20)},alignment:Gt.LEFT}}),fm=lt({},ee,{legend:{enabled:!1,clickable:!1},meter:{showLabels:!0,proportional:null,statusBar:{percentageIndicator:{enabled:!0}}}}),PR=lt({},fm,{legend:{enabled:!0}}),NR=lt({},ee,{radar:{axes:{angle:"key",value:"value"},alignment:Gt.LEFT},tooltip:{gridline:{enabled:!0}}}),$R=lt({},ur,{comboChartTypes:[]}),FR=lt({tree:{type:Wa.TREE}},ee,{}),UR=lt({},ee,{data:lt(ee.data,{groupMapsTo:"name"})}),BR=lt({},ee,Xr,{data:lt(ee.data,{groupMapsTo:"name"})}),HR=lt({},ee,{alluvial:{data:lt(ee.data,{groupMapsTo:"source"}),nodeAlignment:Gt.CENTER,nodePadding:24,monochrome:!1,nodes:[]}}),GR=lt({},ee,{axes:om,heatmap:{divider:{state:Yr.AUTO},colorLegend:{type:"linear"}}}),VR=lt({},cm,{choropleth:{colorLegend:{type:"linear"}}}),At={alluvialChart:HR,areaChart:hm,axisChart:hs,boxplotChart:wR,bubbleChart:CR,bulletChart:DR,chart:ee,circlePackChart:BR,choroplethChart:VR,comboChart:$R,donutChart:kR,gaugeChart:IR,groupedBarChart:TR,heatmapChart:GR,histogramChart:LR,lineChart:um,lollipopChart:MR,meterChart:fm,pieChart:dm,proportionalMeterChart:PR,radarChart:NR,scatterChart:iu,simpleBarChart:SR,stackedAreaChart:AR,stackedBarChart:OR,thematicChart:cm,treeChart:FR,treemapChart:UR,wordCloudChart:RR},pm=6048e5,zR=864e5,gm=6e4,mm=36e5;function vm(e){const t=xt(e);return t.setHours(0,0,0,0),t}function ym(e){const t=xt(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+e-+n}function Em(e,t){const n=vm(e),r=vm(t),i=+n-ym(n),s=+r-ym(r);return Math.round((i-s)/zR)}function We(e,t){return e instanceof Date?new e.constructor(t):new Date(t)}function WR(e){const t=xt(e),n=We(e,0);return n.setFullYear(t.getFullYear(),0,1),n.setHours(0,0,0,0),n}function YR(e){const t=xt(e);return Em(t,WR(t))+1}function Za(e){return us(e,{weekStartsOn:1})}function xm(e){const t=xt(e),n=t.getFullYear(),r=We(e,0);r.setFullYear(n+1,0,4),r.setHours(0,0,0,0);const i=Za(r),s=We(e,0);s.setFullYear(n,0,4),s.setHours(0,0,0,0);const a=Za(s);return t.getTime()>=i.getTime()?n+1:t.getTime()>=a.getTime()?n:n-1}function qR(e){const t=xm(e),n=We(e,0);return n.setFullYear(t,0,4),n.setHours(0,0,0,0),Za(n)}function XR(e){const t=xt(e),n=+Za(t)-+qR(t);return Math.round(n/pm)+1}function bm(e,t){var u,d,h,f;const n=xt(e),r=n.getFullYear(),i=Xa(),s=(t==null?void 0:t.firstWeekContainsDate)??((d=(u=t==null?void 0:t.locale)==null?void 0:u.options)==null?void 0:d.firstWeekContainsDate)??i.firstWeekContainsDate??((f=(h=i.locale)==null?void 0:h.options)==null?void 0:f.firstWeekContainsDate)??1,a=We(e,0);a.setFullYear(r+1,0,s),a.setHours(0,0,0,0);const o=us(a,t),l=We(e,0);l.setFullYear(r,0,s),l.setHours(0,0,0,0);const c=us(l,t);return n.getTime()>=o.getTime()?r+1:n.getTime()>=c.getTime()?r:r-1}function jR(e,t){var o,l,c,u;const n=Xa(),r=(t==null?void 0:t.firstWeekContainsDate)??((l=(o=t==null?void 0:t.locale)==null?void 0:o.options)==null?void 0:l.firstWeekContainsDate)??n.firstWeekContainsDate??((u=(c=n.locale)==null?void 0:c.options)==null?void 0:u.firstWeekContainsDate)??1,i=bm(e,t),s=We(e,0);return s.setFullYear(i,0,r),s.setHours(0,0,0,0),us(s,t)}function ZR(e,t){const n=xt(e),r=+us(n,t)-+jR(n,t);return Math.round(r/pm)+1}function Ot(e,t){const n=e<0?"-":"",r=Math.abs(e).toString().padStart(t,"0");return n+r}const Nn={y(e,t){const n=e.getFullYear(),r=n>0?n:1-n;return Ot(t==="yy"?r%100:r,t.length)},M(e,t){const n=e.getMonth();return t==="M"?String(n+1):Ot(n+1,2)},d(e,t){return Ot(e.getDate(),t.length)},a(e,t){const n=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];case"aaaa":default:return n==="am"?"a.m.":"p.m."}},h(e,t){return Ot(e.getHours()%12||12,t.length)},H(e,t){return Ot(e.getHours(),t.length)},m(e,t){return Ot(e.getMinutes(),t.length)},s(e,t){return Ot(e.getSeconds(),t.length)},S(e,t){const n=t.length,r=e.getMilliseconds(),i=Math.trunc(r*Math.pow(10,n-3));return Ot(i,t.length)}},Zr={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},_m={G:function(e,t,n){const r=e.getFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});case"GGGG":default:return n.era(r,{width:"wide"})}},y:function(e,t,n){if(t==="yo"){const r=e.getFullYear(),i=r>0?r:1-r;return n.ordinalNumber(i,{unit:"year"})}return Nn.y(e,t)},Y:function(e,t,n,r){const i=bm(e,r),s=i>0?i:1-i;if(t==="YY"){const a=s%100;return Ot(a,2)}return t==="Yo"?n.ordinalNumber(s,{unit:"year"}):Ot(s,t.length)},R:function(e,t){const n=xm(e);return Ot(n,t.length)},u:function(e,t){const n=e.getFullYear();return Ot(n,t.length)},Q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"Q":return String(r);case"QQ":return Ot(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"q":return String(r);case"qq":return Ot(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(e,t,n){const r=e.getMonth();switch(t){case"M":case"MM":return Nn.M(e,t);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(e,t,n){const r=e.getMonth();switch(t){case"L":return String(r+1);case"LL":return Ot(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(e,t,n,r){const i=ZR(e,r);return t==="wo"?n.ordinalNumber(i,{unit:"week"}):Ot(i,t.length)},I:function(e,t,n){const r=XR(e);return t==="Io"?n.ordinalNumber(r,{unit:"week"}):Ot(r,t.length)},d:function(e,t,n){return t==="do"?n.ordinalNumber(e.getDate(),{unit:"date"}):Nn.d(e,t)},D:function(e,t,n){const r=YR(e);return t==="Do"?n.ordinalNumber(r,{unit:"dayOfYear"}):Ot(r,t.length)},E:function(e,t,n){const r=e.getDay();switch(t){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});case"EEEE":default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(e,t,n,r){const i=e.getDay(),s=(i-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(s);case"ee":return Ot(s,2);case"eo":return n.ordinalNumber(s,{unit:"day"});case"eee":return n.day(i,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(i,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(i,{width:"short",context:"formatting"});case"eeee":default:return n.day(i,{width:"wide",context:"formatting"})}},c:function(e,t,n,r){const i=e.getDay(),s=(i-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(s);case"cc":return Ot(s,t.length);case"co":return n.ordinalNumber(s,{unit:"day"});case"ccc":return n.day(i,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(i,{width:"narrow",context:"standalone"});case"cccccc":return n.day(i,{width:"short",context:"standalone"});case"cccc":default:return n.day(i,{width:"wide",context:"standalone"})}},i:function(e,t,n){const r=e.getDay(),i=r===0?7:r;switch(t){case"i":return String(i);case"ii":return Ot(i,t.length);case"io":return n.ordinalNumber(i,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});case"iiii":default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(e,t,n){const i=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},b:function(e,t,n){const r=e.getHours();let i;switch(r===12?i=Zr.noon:r===0?i=Zr.midnight:i=r/12>=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(i,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},B:function(e,t,n){const r=e.getHours();let i;switch(r>=17?i=Zr.evening:r>=12?i=Zr.afternoon:r>=4?i=Zr.morning:i=Zr.night,t){case"B":case"BB":case"BBB":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(i,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},h:function(e,t,n){if(t==="ho"){let r=e.getHours()%12;return r===0&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return Nn.h(e,t)},H:function(e,t,n){return t==="Ho"?n.ordinalNumber(e.getHours(),{unit:"hour"}):Nn.H(e,t)},K:function(e,t,n){const r=e.getHours()%12;return t==="Ko"?n.ordinalNumber(r,{unit:"hour"}):Ot(r,t.length)},k:function(e,t,n){let r=e.getHours();return r===0&&(r=24),t==="ko"?n.ordinalNumber(r,{unit:"hour"}):Ot(r,t.length)},m:function(e,t,n){return t==="mo"?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):Nn.m(e,t)},s:function(e,t,n){return t==="so"?n.ordinalNumber(e.getSeconds(),{unit:"second"}):Nn.s(e,t)},S:function(e,t){return Nn.S(e,t)},X:function(e,t,n){const r=e.getTimezoneOffset();if(r===0)return"Z";switch(t){case"X":return Tm(r);case"XXXX":case"XX":return hr(r);case"XXXXX":case"XXX":default:return hr(r,":")}},x:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"x":return Tm(r);case"xxxx":case"xx":return hr(r);case"xxxxx":case"xxx":default:return hr(r,":")}},O:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+Sm(r,":");case"OOOO":default:return"GMT"+hr(r,":")}},z:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+Sm(r,":");case"zzzz":default:return"GMT"+hr(r,":")}},t:function(e,t,n){const r=Math.trunc(e.getTime()/1e3);return Ot(r,t.length)},T:function(e,t,n){const r=e.getTime();return Ot(r,t.length)}};function Sm(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),i=Math.trunc(r/60),s=r%60;return s===0?n+String(i):n+String(i)+t+Ot(s,2)}function Tm(e,t){return e%60===0?(e>0?"-":"+")+Ot(Math.abs(e)/60,2):hr(e,t)}function hr(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),i=Ot(Math.trunc(r/60),2),s=Ot(r%60,2);return n+i+t+s}const Om=(e,t)=>{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},wm=(e,t)=>{switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},KR={p:wm,P:(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],r=n[1],i=n[2];if(!i)return Om(e,t);let s;switch(r){case"P":s=t.dateTime({width:"short"});break;case"PP":s=t.dateTime({width:"medium"});break;case"PPP":s=t.dateTime({width:"long"});break;case"PPPP":default:s=t.dateTime({width:"full"});break}return s.replace("{{date}}",Om(r,t)).replace("{{time}}",wm(i,t))}},QR=/^D+$/,JR=/^Y+$/,tI=["D","DD","YY","YYYY"];function eI(e){return QR.test(e)}function nI(e){return JR.test(e)}function rI(e,t,n){const r=iI(e,t,n);if(console.warn(r),tI.includes(e))throw new RangeError(r)}function iI(e,t,n){const r=e[0]==="Y"?"years":"days of the month";return`Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${t}\`) for formatting ${r} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}function sI(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function aI(e){if(!sI(e)&&typeof e!="number")return!1;const t=xt(e);return!isNaN(Number(t))}const oI=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,lI=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,cI=/^'([^]*?)'?$/,uI=/''/g,hI=/[a-zA-Z]/;function su(e,t,n){var u,d,h,f,p,g,m,v;const r=Xa(),i=(n==null?void 0:n.locale)??r.locale??sm,s=(n==null?void 0:n.firstWeekContainsDate)??((d=(u=n==null?void 0:n.locale)==null?void 0:u.options)==null?void 0:d.firstWeekContainsDate)??r.firstWeekContainsDate??((f=(h=r.locale)==null?void 0:h.options)==null?void 0:f.firstWeekContainsDate)??1,a=(n==null?void 0:n.weekStartsOn)??((g=(p=n==null?void 0:n.locale)==null?void 0:p.options)==null?void 0:g.weekStartsOn)??r.weekStartsOn??((v=(m=r.locale)==null?void 0:m.options)==null?void 0:v.weekStartsOn)??0,o=xt(e);if(!aI(o))throw new RangeError("Invalid time value");let l=t.match(lI).map(E=>{const y=E[0];if(y==="p"||y==="P"){const b=KR[y];return b(E,i.formatLong)}return E}).join("").match(oI).map(E=>{if(E==="''")return{isToken:!1,value:"'"};const y=E[0];if(y==="'")return{isToken:!1,value:dI(E)};if(_m[y])return{isToken:!0,value:E};if(y.match(hI))throw new RangeError("Format string contains an unescaped latin alphabet character `"+y+"`");return{isToken:!1,value:E}});i.localize.preprocessor&&(l=i.localize.preprocessor(o,l));const c={firstWeekContainsDate:s,weekStartsOn:a,locale:i};return l.map(E=>{if(!E.isToken)return E.value;const y=E.value;(!(n!=null&&n.useAdditionalWeekYearTokens)&&nI(y)||!(n!=null&&n.useAdditionalDayOfYearTokens)&&eI(y))&&rI(y,t,String(e));const b=_m[y[0]];return b(o,y,i.localize,c)}).join("")}function dI(e){const t=e.match(cI);return t?t[1].replace(uI,"'"):e}var Mm=(e=>(e["15seconds"]="15seconds",e.minute="minute",e["30minutes"]="30minutes",e.hourly="hourly",e.daily="daily",e.weekly="weekly",e.monthly="monthly",e.quarterly="quarterly",e.yearly="yearly",e))(Mm||{});const au=[["15seconds",15*1e3],["minute",60*1e3],["30minutes",30*60*1e3],["hourly",60*60*1e3],["daily",24*60*60*1e3],["monthly",30*24*60*60*1e3],["quarterly",3*30*24*60*60*1e3],["yearly",12*30*24*60*60*1e3]];function Am(e,t,n,r,i){const s=t===0,a=Number(su(new Date(e),"c"))===2,o=Number(su(new Date(e),"q"))===1,l=t!==0?n[t-1]:null;switch(r){case"15seconds":return s||Qa(e)||ds(e,l)||$n(e);case"minute":return s||Qa(e)||ds(e,l)||$n(e);case"30minutes":return s||Qa(e)||ds(e,l)||$n(e);case"hourly":return s||Qa(e)||ds(e,l)||$n(e);case"daily":return i?s||a||$n(e):s||ds(e,l)||$n(e);case"weekly":return s||a||$n(e);case"monthly":return s||$n(e);case"quarterly":return s||o;case"yearly":return!1;default:throw new Error(`${r} is not a valid time interval.`)}}function ou(e,t,n,r,i,s){const a=i.showDayName,o=r==="daily"&&a?"weekly":r,l=new Date(e),c=x(i,"timeIntervalFormats")[o],u=x(c,"primary"),d=x(c,"secondary"),h=Am(e,t,n,r,a);let f=h?u:d;r==="15seconds"&&l.getMilliseconds()!==0&&(f=f.replace("pp","h:mm:ss.SSS a"));const p=i.localeObject,{code:g,optionsObject:m}=s,v=m[r].type,E=m[r][h?"primary":"secondary"][f];if(r==="quarterly"||!E){const b=su(l,f,{locale:p}).split("").map(S=>{let _=Number(S);return S!==" "&&!Number.isNaN(_)?_.toLocaleString(g):S});return s[v](l,g,{},b.join(""))}else return s[v](l,g,E)}function Ka(e){const t=new Date(e);return{M:t.getMonth()+1,d:t.getDate(),H:t.getHours(),m:t.getMinutes(),s:t.getSeconds()}}function fI(e){if(e)return e.slice(1).map((t,n)=>t-e[n])}function pI(e){const t=au.reduce((n,[,r],i)=>{const s=au[n][1],a=Math.abs(s-e),o=Math.abs(r-e);return a<o?n:i},0);return au[t][0]}function lu(e,t){if(Mm[t])return t;if(e.length===1)return"15seconds";const n=fI(e),r=Rn(n);return pI(r)}function Qa(e){const{s:t,m:n,H:r}=Ka(e);return r===0&&n===0&&t===0}function ds(e,t){const n=Ka(e).M,r=Ka(t).M;return n!==r}function $n(e){const{M:t,d:n,s:r,m:i,H:s}=Ka(e);return t===1&&n===1&&s===0&&i===0&&r===0}function Cm(e){return e===void 0?"":e.toISOString()}function gI(e){const t=e.trim();return["=","+","-","@"," ","\r"].includes(t.charAt(0))?` ${t}`:/[,\"\n]/.test(t)?`"${t}"`:t}class sn{constructor(t){this.state={options:{}},this.colorScale={},this.colorClassNames={},this.services=t}formatTable({headers:t,cells:n}){const r=this.getOptions(),{code:i,date:s,number:a}=x(r,"locale"),o=x(r,"tabularRepModal","tableHeadingFormatter"),l=x(r,"tabularRepModal","tableCellFormatter"),{cartesianScales:c}=this.services,u=c==null?void 0:c.getDomainAxisScaleType();let d;return u===J.TIME&&(d=f=>s(f,i,{month:"short",day:"numeric",year:"numeric"})),[typeof o=="function"?o(t):t,...typeof l=="function"?l(n):n.map(f=>{d&&(f[1]=d(f[1]));for(let p in f){let g=f[p];typeof g=="number"&&(f[p]=a(g,i))}return f})]}getAllDataFromDomain(t){if(!this.getData())return null;const n=this.getOptions();let r=this.getData();const i=this.getDataGroups(),{groupMapsTo:s}=x(n,"data"),a=x(n,"axes");return t&&(r=r.filter(o=>t.includes(o[s]))),a&&Object.keys(a).forEach(o=>{const l=a[o].mapsTo,c=a[o].scaleType;if((c===J.LINEAR||c===J.LOG)&&(r=r.map(u=>({...u,[l]:u[l]===null?u[l]:Number(u[l])}))),l&&a[o].domain)if(c===J.LABELS)r=r.filter(u=>a[o].domain.includes(u[l]));else{const[u,d]=a[o].domain;r=r.filter(h=>!(l in h)||h[l]>=u&&h[l]<=d)}}),r.filter(o=>i.find(l=>l.name===o[s]))}getDisplayData(t){if(!this.get("data"))return null;const{ACTIVE:n}=Nt.items.status,r=this.getDataGroups(t),{groupMapsTo:i}=this.getOptions().data;return this.getAllDataFromDomain(t).filter(a=>r.find(o=>o.name===a[i]&&o.status===n))}getData(){return this.get("data")}isDataEmpty(){return!this.getData().length}setData(t){const n=this.sanitize(_n(t)),r=this.generateDataGroups(n);return this.set({data:n,dataGroups:r}),n}getDataGroups(t){return x(this.getOptions(),"data","loading")?[]:t?this.get("dataGroups").filter(r=>t.includes(r.name)):this.get("dataGroups")}getActiveDataGroups(t){const{ACTIVE:n}=Nt.items.status;return this.getDataGroups(t).filter(r=>r.status===n)}getDataGroupNames(t){return this.getDataGroups(t).map(r=>r.name)}getActiveDataGroupNames(t){return this.getActiveDataGroups(t).map(r=>r.name)}aggregateBinDataByGroup(t){return EL(t,"group")}getBinConfigurations(){const t=this.getDisplayData(),n=this.getOptions(),r=this.services.cartesianScales.getMainXAxisPosition(),i=this.services.cartesianScales.getDomainIdentifier(),s=n.axes[r],{groupMapsTo:a}=n.data,{bins:o=$L.defaultBins}=s,l=Array.isArray(o),c=N0().value(f=>f[i]).thresholds(o)(t);if(l)c[c.length-1].x1=o[o.length-1];else{const f=c[0].x1-c[0].x0;c[c.length-1].x1=+c[c.length-1].x0+f}const u=l?[o[0],o[o.length-1]]:[c[0].x0,c[c.length-1].x1],d=Array.from(new Set(t.map(f=>f[a]))),h=[];return c.forEach(f=>{const p=`${f.x0}-${f.x1}`,g=this.aggregateBinDataByGroup(f);d.forEach(m=>{h.push({group:m,key:p,value:g[m]||0,bin:f.x0})})}),{bins:c,binsDomain:u}}getBinnedStackedData(){const t=this.getOptions(),{groupMapsTo:n}=t.data,r=this.getActiveDataGroupNames(),{bins:i}=this.getBinConfigurations(),s=this.getDataValuesGroupedByKeys({bins:i});return ic().keys(r)(s).map((a,o)=>Object.keys(a).filter(l=>!isNaN(l)).map(l=>{const c=a[l];return c[n]=r[o],c}))}getGroupedData(t){const n=this.getDisplayData(t),r={},{groupMapsTo:i}=this.getOptions().data;return n.map(s=>{const a=s[i];r[a]!==null&&r[a]!==void 0?r[a].push(s):r[a]=[s]}),Object.keys(r).map(s=>({name:s,data:r[s]}))}getStackKeys({bins:t=null,groups:n=null}={bins:null,groups:null}){const r=this.getOptions(),i=this.getDisplayData(n);let s;t?s=t.map(l=>`${l.x0}:${l.x1}`):s=ts(i.map(l=>{const c=this.services.cartesianScales.getDomainIdentifier(l);return l[c]instanceof Date?Cm(l[c]):l[c]&&typeof l[c].toString=="function"?l[c].toString():l[c]}));const a=this.services.cartesianScales.domainAxisPosition,o=r.axes[a].scaleType;return o===J.TIME?s.sort((l,c)=>{const u=new Date(l),d=new Date(c);return u-d}):(o===J.LOG||o===J.LINEAR)&&s.sort((l,c)=>l-c),s}getDataValuesGroupedByKeys({bins:t=null,groups:n=null}){const r=this.getOptions(),{groupMapsTo:i}=r.data,s=this.getDisplayData(n),a=this.getDataGroupNames(),o=this.getStackKeys({bins:t,groups:n});return t?o.map(l=>{const[c,u]=l.split(":"),d={x0:c,x1:u},h=t.find(f=>f.x0.toString()===c.toString());return a.forEach(f=>{d[f]=h.filter(p=>p[i]===f).length}),d}):o.map(l=>{const c={sharedStackKey:l};return a.forEach(u=>{const d=s.find(f=>{const p=this.services.cartesianScales.getDomainIdentifier(f);return f[i]===u&&Object.prototype.hasOwnProperty.call(f,p)&&(f[p]instanceof Date?Cm(f[p])===l:f[p].toString()===l)}),h=this.services.cartesianScales.getRangeIdentifier(c);c[u]=d?d[h]:null}),c})}getStackedData({percentage:t=!1,groups:n=null,divergent:r=!1}){const i=this.getOptions(),{groupMapsTo:s}=i.data,a=this.getActiveDataGroupNames(n),o=this.getDataValuesGroupedByKeys({groups:n});if(t){const c=mL(o.map(u=>[u.sharedStackKey,0]));o.forEach(u=>{a.forEach(d=>{c[u.sharedStackKey]+=u[d]})}),o.forEach(u=>{a.forEach(d=>{const h=c[u.sharedStackKey];c[u.sharedStackKey]?u[d]=u[d]/h*100:u[d]=0})})}return(r?ic().offset(HT):ic()).keys(a)(o).map((c,u)=>Object.keys(c).filter(d=>!isNaN(d)).map(d=>{const h=c[d];return h[s]=a[u],h}))}getOptions(){return this.state.options}set(t,n){this.state=Object.assign({},this.state,t);const r=Object.assign({skipUpdate:!1,animate:!0},n);r.skipUpdate||this.update(r.animate)}get(t){return t?this.state[t]:this.state}setOptions(t){const n=this.getOptions();nu(n,t),this.set({options:lt(n,t)})}update(t=!0){this.getDisplayData()&&(this.updateAllDataGroups(),this.setCustomColorScale(),this.setColorClassNames(),this.services.events.dispatchEvent(T.Model.UPDATE,{animate:t}))}toggleDataLabel(t){const{ACTIVE:n,DISABLED:r}=Nt.items.status,i=this.getDataGroups(),s=i.some(u=>u.status===r),a=i.filter(u=>u.status===n);if(s)if(a.length===1&&a[0].name===t)i.forEach((u,d)=>{i[d].status=n});else{const u=i.findIndex(d=>d.name===t);i[u].status=i[u].status===r?n:r}else i.forEach((u,d)=>{i[d].status=u.name===t?n:r});const o=i.filter(u=>u.status===n),l=this.getOptions();i.some(u=>u.status===r)?l.data.selectedGroups=o.map(u=>u.name):l.data.selectedGroups=[],this.services.events.dispatchEvent(T.Legend.ITEMS_UPDATE,{dataGroups:i}),this.set({dataGroups:i})}getIsFilled(t,n,r,i){const s=this.getOptions();return s.getIsFilled?s.getIsFilled(t,n,r,i):i}getFillColor(t,n,r){const i=this.getOptions(),s=x(this.colorScale,t);return i.getFillColor?i.getFillColor(t,n,r,s):s}getStrokeColor(t,n,r){const i=this.getOptions(),s=x(this.colorScale,t);return i.getStrokeColor?i.getStrokeColor(t,n,r,s):s}isUserProvidedColorScaleValid(){const t=x(this.getOptions(),"color","scale"),n=this.getDataGroups();return t==null||Object.keys(t).length==0?!1:n.some(r=>Object.keys(t).includes(r.name))}getColorClassName(t){const n=this.colorClassNames(t.dataGroupName);let r=t.originalClassName;return t.classNameTypes.forEach(i=>r=t.originalClassName?`${r} ${i}-${n}`:`${i}-${n}`),r||""}getStatus(){return null}getAllDataGroupsNames(){return this.allDataGroups}transformToTabularData(t){console.warn("We've updated the charting data format to be tabular by default. The current format you're using is deprecated and will be removed in v1.0, read more here https://charts.carbondesignsystem.com/?path=/story/docs-tutorials--tabular-data-format");const n=[],{datasets:r,labels:i}=t;return r.forEach(s=>{s.data.forEach((a,o)=>{let l;const c=x(s,"label");if(c===null){const d=x(i,o);d?l=d:l="Ungrouped"}else l=c;const u={group:l,key:i[o]};isNaN(a)?(u.value=a.value,u.date=a.date):u.value=a,n.push(u)})}),n}getTabularDataArray(){return[]}exportToCSV(){const n=this.getTabularDataArray().map(a=>a.map(o=>`"${(o==="–"?"–":o).split(/[,;'"`]/).map(u=>gI(u)).join("")}"`)).map(a=>a.join(",")).join(`
|
|
1
|
+
(function(W,ke){typeof exports=="object"&&typeof module<"u"?ke(exports):typeof define=="function"&&define.amd?define(["exports"],ke):(W=typeof globalThis<"u"?globalThis:W||self,ke(W.Charts={}))})(this,function(W){"use strict";function ke(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function E0(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function Mo(e){let t,n,r;e.length!==2?(t=ke,n=(o,l)=>ke(e(o),l),r=(o,l)=>e(o)-l):(t=e===ke||e===E0?e:x0,n=e,r=e);function i(o,l,c=0,u=o.length){if(c<u){if(t(l,l)!==0)return u;do{const d=c+u>>>1;n(o[d],l)<0?c=d+1:u=d}while(c<u)}return c}function s(o,l,c=0,u=o.length){if(c<u){if(t(l,l)!==0)return u;do{const d=c+u>>>1;n(o[d],l)<=0?c=d+1:u=d}while(c<u)}return c}function a(o,l,c=0,u=o.length){const d=i(o,l,c,u-1);return d>c&&r(o[d-1],l)>-r(o[d],l)?d-1:d}return{left:i,center:a,right:s}}function x0(){return 0}function b0(e){return e===null?NaN:+e}function*_0(e,t){for(let n of e)n!=null&&(n=+n)>=n&&(yield n)}const Ao=Mo(ke).right;Mo(b0).center;function S0(e,t){let n=0;for(let r of e)r!=null&&(r=+r)>=r&&++n;return n}function Pe(e,t){let n,r;if(t===void 0)for(const i of e)i!=null&&(n===void 0?i>=i&&(n=r=i):(n>i&&(n=i),r<i&&(r=i)));else{let i=-1;for(let s of e)(s=t(s,++i,e))!=null&&(n===void 0?s>=s&&(n=r=s):(n>s&&(n=s),r<s&&(r=s)))}return[n,r]}class Gn{constructor(){this._partials=new Float64Array(32),this._n=0}add(t){const n=this._partials;let r=0;for(let i=0;i<this._n&&i<32;i++){const s=n[i],a=t+s,o=Math.abs(t)<Math.abs(s)?t-(a-s):s-(a-t);o&&(n[r++]=o),t=a}return n[r]=t,this._n=r+1,this}valueOf(){const t=this._partials;let n=this._n,r,i,s,a=0;if(n>0){for(a=t[--n];n>0&&(r=a,i=t[--n],a=r+i,s=i-(a-r),!s););n>0&&(s<0&&t[n-1]<0||s>0&&t[n-1]>0)&&(i=s*2,r=a+i,i==r-a&&(a=r))}return a}}class sh extends Map{constructor(t,n=w0){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[r,i]of t)this.set(r,i)}get(t){return super.get(ah(this,t))}has(t){return super.has(ah(this,t))}set(t,n){return super.set(T0(this,t),n)}delete(t){return super.delete(O0(this,t))}}function ah({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function T0({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function O0({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function w0(e){return e!==null&&typeof e=="object"?e.valueOf():e}function M0(e){return e}function A0(e=ke){if(e===ke)return oh;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,n)=>{const r=e(t,n);return r||r===0?r:(e(n,n)===0)-(e(t,t)===0)}}function oh(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}var C0=Array.prototype,D0=C0.slice;function Co(e){return()=>e}const L0=Math.sqrt(50),R0=Math.sqrt(10),I0=Math.sqrt(2);function Os(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),s=r/Math.pow(10,i),a=s>=L0?10:s>=R0?5:s>=I0?2:1;let o,l,c;return i<0?(c=Math.pow(10,-i)/a,o=Math.round(e*c),l=Math.round(t*c),o/c<e&&++o,l/c>t&&--l,c=-c):(c=Math.pow(10,i)*a,o=Math.round(e/c),l=Math.round(t/c),o*c<e&&++o,l*c>t&&--l),l<o&&.5<=n&&n<2?Os(e,t,n*2):[o,l,c]}function ws(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[i,s,a]=r?Os(t,e,n):Os(e,t,n);if(!(s>=i))return[];const o=s-i+1,l=new Array(o);if(r)if(a<0)for(let c=0;c<o;++c)l[c]=(s-c)/-a;else for(let c=0;c<o;++c)l[c]=(s-c)*a;else if(a<0)for(let c=0;c<o;++c)l[c]=(i+c)/-a;else for(let c=0;c<o;++c)l[c]=(i+c)*a;return l}function gr(e,t,n){return t=+t,e=+e,n=+n,Os(e,t,n)[2]}function Do(e,t,n){t=+t,e=+e,n=+n;const r=t<e,i=r?gr(t,e,n):gr(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}function k0(e,t,n){let r;for(;;){const i=gr(e,t,n);if(i===r||i===0||!isFinite(i))return[e,t];i>0?(e=Math.floor(e/i)*i,t=Math.ceil(t/i)*i):i<0&&(e=Math.ceil(e*i)/i,t=Math.floor(t*i)/i),r=i}}function P0(e){return Math.max(1,Math.ceil(Math.log(S0(e))/Math.LN2)+1)}function N0(){var e=M0,t=Pe,n=P0;function r(i){Array.isArray(i)||(i=Array.from(i));var s,a=i.length,o,l,c=new Array(a);for(s=0;s<a;++s)c[s]=e(i[s],s,i);var u=t(c),d=u[0],h=u[1],f=n(c,d,h);if(!Array.isArray(f)){const y=h,b=+f;if(t===Pe&&([d,h]=k0(d,h,b)),f=ws(d,h,b),f[0]<=d&&(l=gr(d,h,b)),f[f.length-1]>=h)if(y>=h&&t===Pe){const S=gr(d,h,b);isFinite(S)&&(S>0?h=(Math.floor(h/S)+1)*S:S<0&&(h=(Math.ceil(h*-S)+1)/-S))}else f.pop()}for(var p=f.length,g=0,m=p;f[g]<=d;)++g;for(;f[m-1]>h;)--m;(g||m<p)&&(f=f.slice(g,m),p=m-g);var v=new Array(p+1),E;for(s=0;s<=p;++s)E=v[s]=[],E.x0=s>0?f[s-1]:d,E.x1=s<p?f[s]:h;if(isFinite(l)){if(l>0)for(s=0;s<a;++s)(o=c[s])!=null&&d<=o&&o<=h&&v[Math.min(p,Math.floor((o-d)/l))].push(i[s]);else if(l<0){for(s=0;s<a;++s)if((o=c[s])!=null&&d<=o&&o<=h){const y=Math.floor((d-o)*l);v[Math.min(p,y+(f[y]<=o))].push(i[s])}}}else for(s=0;s<a;++s)(o=c[s])!=null&&d<=o&&o<=h&&v[Ao(f,o,0,p)].push(i[s]);return v}return r.value=function(i){return arguments.length?(e=typeof i=="function"?i:Co(i),r):e},r.domain=function(i){return arguments.length?(t=typeof i=="function"?i:Co([i[0],i[1]]),r):t},r.thresholds=function(i){return arguments.length?(n=typeof i=="function"?i:Co(Array.isArray(i)?D0.call(i):i),r):n},r}function Vn(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n<i||n===void 0&&i>=i)&&(n=i)}return n}function Rn(e,t){let n;for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);return n}function lh(e,t,n=0,r=1/0,i){if(t=Math.floor(t),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(e.length-1,r)),!(n<=t&&t<=r))return e;for(i=i===void 0?oh:A0(i);r>n;){if(r-n>600){const l=r-n+1,c=t-n+1,u=Math.log(l),d=.5*Math.exp(2*u/3),h=.5*Math.sqrt(u*d*(l-d)/l)*(c-l/2<0?-1:1),f=Math.max(n,Math.floor(t-c*d/l+h)),p=Math.min(r,Math.floor(t+(l-c)*d/l+h));lh(e,t,f,p,i)}const s=e[t];let a=n,o=r;for(li(e,n,t),i(e[r],s)>0&&li(e,n,r);a<o;){for(li(e,a,o),++a,--o;i(e[a],s)<0;)++a;for(;i(e[o],s)>0;)--o}i(e[n],s)===0?li(e,n,o):(++o,li(e,o,r)),o<=t&&(n=o+1),t<=o&&(r=o-1)}return e}function li(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function Lo(e,t,n){if(e=Float64Array.from(_0(e)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return Rn(e);if(t>=1)return Vn(e);var r,i=(r-1)*t,s=Math.floor(i),a=Vn(lh(e,s).subarray(0,s+1)),o=Rn(e.subarray(s+1));return a+(o-a)*(i-s)}}function*$0(e){for(const t of e)yield*t}function ch(e){return Array.from($0(e))}function F0(e,t,n){e=+e,t=+t,n=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+n;for(var r=-1,i=Math.max(0,Math.ceil((t-e)/n))|0,s=new Array(i);++r<i;)s[r]=e+r*n;return s}function U0(e){return e}var Ms=1,As=2,Ro=3,ci=4,uh=1e-6;function B0(e){return"translate("+e+",0)"}function H0(e){return"translate(0,"+e+")"}function G0(e){return t=>+e(t)}function V0(e,t){return t=Math.max(0,e.bandwidth()-t*2)/2,e.round()&&(t=Math.round(t)),n=>+e(n)+t}function z0(){return!this.__axis}function Cs(e,t){var n=[],r=null,i=null,s=6,a=6,o=3,l=typeof window<"u"&&window.devicePixelRatio>1?0:.5,c=e===Ms||e===ci?-1:1,u=e===ci||e===As?"x":"y",d=e===Ms||e===Ro?B0:H0;function h(f){var p=r??(t.ticks?t.ticks.apply(t,n):t.domain()),g=i??(t.tickFormat?t.tickFormat.apply(t,n):U0),m=Math.max(s,0)+o,v=t.range(),E=+v[0]+l,y=+v[v.length-1]+l,b=(t.bandwidth?V0:G0)(t.copy(),l),S=f.selection?f.selection():f,_=S.selectAll(".domain").data([null]),A=S.selectAll(".tick").data(p,t).order(),R=A.exit(),B=A.enter().append("g").attr("class","tick"),D=A.select("line"),O=A.select("text");_=_.merge(_.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),A=A.merge(B),D=D.merge(B.append("line").attr("stroke","currentColor").attr(u+"2",c*s)),O=O.merge(B.append("text").attr("fill","currentColor").attr(u,c*m).attr("dy",e===Ms?"0em":e===Ro?"0.71em":"0.32em")),f!==S&&(_=_.transition(f),A=A.transition(f),D=D.transition(f),O=O.transition(f),R=R.transition(f).attr("opacity",uh).attr("transform",function(H){return isFinite(H=b(H))?d(H+l):this.getAttribute("transform")}),B.attr("opacity",uh).attr("transform",function(H){var P=this.parentNode.__axis;return d((P&&isFinite(P=P(H))?P:b(H))+l)})),R.remove(),_.attr("d",e===ci||e===As?a?"M"+c*a+","+E+"H"+l+"V"+y+"H"+c*a:"M"+l+","+E+"V"+y:a?"M"+E+","+c*a+"V"+l+"H"+y+"V"+c*a:"M"+E+","+l+"H"+y),A.attr("opacity",1).attr("transform",function(H){return d(b(H)+l)}),D.attr(u+"2",c*s),O.attr(u,c*m).text(g),S.filter(z0).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",e===As?"start":e===ci?"end":"middle"),S.each(function(){this.__axis=b})}return h.scale=function(f){return arguments.length?(t=f,h):t},h.ticks=function(){return n=Array.from(arguments),h},h.tickArguments=function(f){return arguments.length?(n=f==null?[]:Array.from(f),h):n.slice()},h.tickValues=function(f){return arguments.length?(r=f==null?null:Array.from(f),h):r&&r.slice()},h.tickFormat=function(f){return arguments.length?(i=f,h):i},h.tickSize=function(f){return arguments.length?(s=a=+f,h):s},h.tickSizeInner=function(f){return arguments.length?(s=+f,h):s},h.tickSizeOuter=function(f){return arguments.length?(a=+f,h):a},h.tickPadding=function(f){return arguments.length?(o=+f,h):o},h.offset=function(f){return arguments.length?(l=+f,h):l},h}function W0(e){return Cs(Ms,e)}function Y0(e){return Cs(As,e)}function Io(e){return Cs(Ro,e)}function hh(e){return Cs(ci,e)}var q0={value:()=>{}};function ko(){for(var e=0,t=arguments.length,n={},r;e<t;++e){if(!(r=arguments[e]+"")||r in n||/[\s.]/.test(r))throw new Error("illegal type: "+r);n[r]=[]}return new Ds(n)}function Ds(e){this._=e}function X0(e,t){return e.trim().split(/^|\s+/).map(function(n){var r="",i=n.indexOf(".");if(i>=0&&(r=n.slice(i+1),n=n.slice(0,i)),n&&!t.hasOwnProperty(n))throw new Error("unknown type: "+n);return{type:n,name:r}})}Ds.prototype=ko.prototype={constructor:Ds,on:function(e,t){var n=this._,r=X0(e+"",n),i,s=-1,a=r.length;if(arguments.length<2){for(;++s<a;)if((i=(e=r[s]).type)&&(i=j0(n[i],e.name)))return i;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++s<a;)if(i=(e=r[s]).type)n[i]=dh(n[i],e.name,t);else if(t==null)for(i in n)n[i]=dh(n[i],e.name,null);return this},copy:function(){var e={},t=this._;for(var n in t)e[n]=t[n].slice();return new Ds(e)},call:function(e,t){if((i=arguments.length-2)>0)for(var n=new Array(i),r=0,i,s;r<i;++r)n[r]=arguments[r+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(s=this._[e],r=0,i=s.length;r<i;++r)s[r].value.apply(t,n)},apply:function(e,t,n){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var r=this._[e],i=0,s=r.length;i<s;++i)r[i].value.apply(t,n)}};function j0(e,t){for(var n=0,r=e.length,i;n<r;++n)if((i=e[n]).name===t)return i.value}function dh(e,t,n){for(var r=0,i=e.length;r<i;++r)if(e[r].name===t){e[r]=q0,e=e.slice(0,r).concat(e.slice(r+1));break}return n!=null&&e.push({name:t,value:n}),e}var Po="http://www.w3.org/1999/xhtml";const fh={svg:"http://www.w3.org/2000/svg",xhtml:Po,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Ls(e){var t=e+="",n=t.indexOf(":");return n>=0&&(t=e.slice(0,n))!=="xmlns"&&(e=e.slice(n+1)),fh.hasOwnProperty(t)?{space:fh[t],local:e}:e}function Z0(e){return function(){var t=this.ownerDocument,n=this.namespaceURI;return n===Po&&t.documentElement.namespaceURI===Po?t.createElement(e):t.createElementNS(n,e)}}function K0(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function ph(e){var t=Ls(e);return(t.local?K0:Z0)(t)}function Q0(){}function No(e){return e==null?Q0:function(){return this.querySelector(e)}}function J0(e){typeof e!="function"&&(e=No(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var s=t[i],a=s.length,o=r[i]=new Array(a),l,c,u=0;u<a;++u)(l=s[u])&&(c=e.call(l,l.__data__,u,s))&&("__data__"in l&&(c.__data__=l.__data__),o[u]=c);return new ve(r,this._parents)}function ty(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function ey(){return[]}function gh(e){return e==null?ey:function(){return this.querySelectorAll(e)}}function ny(e){return function(){return ty(e.apply(this,arguments))}}function ry(e){typeof e=="function"?e=ny(e):e=gh(e);for(var t=this._groups,n=t.length,r=[],i=[],s=0;s<n;++s)for(var a=t[s],o=a.length,l,c=0;c<o;++c)(l=a[c])&&(r.push(e.call(l,l.__data__,c,a)),i.push(l));return new ve(r,i)}function mh(e){return function(){return this.matches(e)}}function vh(e){return function(t){return t.matches(e)}}var iy=Array.prototype.find;function sy(e){return function(){return iy.call(this.children,e)}}function ay(){return this.firstElementChild}function oy(e){return this.select(e==null?ay:sy(typeof e=="function"?e:vh(e)))}var ly=Array.prototype.filter;function cy(){return Array.from(this.children)}function uy(e){return function(){return ly.call(this.children,e)}}function hy(e){return this.selectAll(e==null?cy:uy(typeof e=="function"?e:vh(e)))}function dy(e){typeof e!="function"&&(e=mh(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var s=t[i],a=s.length,o=r[i]=[],l,c=0;c<a;++c)(l=s[c])&&e.call(l,l.__data__,c,s)&&o.push(l);return new ve(r,this._parents)}function yh(e){return new Array(e.length)}function fy(){return new ve(this._enter||this._groups.map(yh),this._parents)}function Rs(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}Rs.prototype={constructor:Rs,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function py(e){return function(){return e}}function gy(e,t,n,r,i,s){for(var a=0,o,l=t.length,c=s.length;a<c;++a)(o=t[a])?(o.__data__=s[a],r[a]=o):n[a]=new Rs(e,s[a]);for(;a<l;++a)(o=t[a])&&(i[a]=o)}function my(e,t,n,r,i,s,a){var o,l,c=new Map,u=t.length,d=s.length,h=new Array(u),f;for(o=0;o<u;++o)(l=t[o])&&(h[o]=f=a.call(l,l.__data__,o,t)+"",c.has(f)?i[o]=l:c.set(f,l));for(o=0;o<d;++o)f=a.call(e,s[o],o,s)+"",(l=c.get(f))?(r[o]=l,l.__data__=s[o],c.delete(f)):n[o]=new Rs(e,s[o]);for(o=0;o<u;++o)(l=t[o])&&c.get(h[o])===l&&(i[o]=l)}function vy(e){return e.__data__}function yy(e,t){if(!arguments.length)return Array.from(this,vy);var n=t?my:gy,r=this._parents,i=this._groups;typeof e!="function"&&(e=py(e));for(var s=i.length,a=new Array(s),o=new Array(s),l=new Array(s),c=0;c<s;++c){var u=r[c],d=i[c],h=d.length,f=Ey(e.call(u,u&&u.__data__,c,r)),p=f.length,g=o[c]=new Array(p),m=a[c]=new Array(p),v=l[c]=new Array(h);n(u,d,g,m,v,f,t);for(var E=0,y=0,b,S;E<p;++E)if(b=g[E]){for(E>=y&&(y=E+1);!(S=m[y])&&++y<p;);b._next=S||null}}return a=new ve(a,r),a._enter=o,a._exit=l,a}function Ey(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function xy(){return new ve(this._exit||this._groups.map(yh),this._parents)}function by(e,t,n){var r=this.enter(),i=this,s=this.exit();return typeof e=="function"?(r=e(r),r&&(r=r.selection())):r=r.append(e+""),t!=null&&(i=t(i),i&&(i=i.selection())),n==null?s.remove():n(s),r&&i?r.merge(i).order():i}function _y(e){for(var t=e.selection?e.selection():e,n=this._groups,r=t._groups,i=n.length,s=r.length,a=Math.min(i,s),o=new Array(i),l=0;l<a;++l)for(var c=n[l],u=r[l],d=c.length,h=o[l]=new Array(d),f,p=0;p<d;++p)(f=c[p]||u[p])&&(h[p]=f);for(;l<i;++l)o[l]=n[l];return new ve(o,this._parents)}function Sy(){for(var e=this._groups,t=-1,n=e.length;++t<n;)for(var r=e[t],i=r.length-1,s=r[i],a;--i>=0;)(a=r[i])&&(s&&a.compareDocumentPosition(s)^4&&s.parentNode.insertBefore(a,s),s=a);return this}function Ty(e){e||(e=Oy);function t(d,h){return d&&h?e(d.__data__,h.__data__):!d-!h}for(var n=this._groups,r=n.length,i=new Array(r),s=0;s<r;++s){for(var a=n[s],o=a.length,l=i[s]=new Array(o),c,u=0;u<o;++u)(c=a[u])&&(l[u]=c);l.sort(t)}return new ve(i,this._parents).order()}function Oy(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function wy(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function My(){return Array.from(this)}function Ay(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var r=e[t],i=0,s=r.length;i<s;++i){var a=r[i];if(a)return a}return null}function Cy(){let e=0;for(const t of this)++e;return e}function Dy(){return!this.node()}function Ly(e){for(var t=this._groups,n=0,r=t.length;n<r;++n)for(var i=t[n],s=0,a=i.length,o;s<a;++s)(o=i[s])&&e.call(o,o.__data__,s,i);return this}function Ry(e){return function(){this.removeAttribute(e)}}function Iy(e){return function(){this.removeAttributeNS(e.space,e.local)}}function ky(e,t){return function(){this.setAttribute(e,t)}}function Py(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function Ny(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttribute(e):this.setAttribute(e,n)}}function $y(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,n)}}function Fy(e,t){var n=Ls(e);if(arguments.length<2){var r=this.node();return n.local?r.getAttributeNS(n.space,n.local):r.getAttribute(n)}return this.each((t==null?n.local?Iy:Ry:typeof t=="function"?n.local?$y:Ny:n.local?Py:ky)(n,t))}function Eh(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function Uy(e){return function(){this.style.removeProperty(e)}}function By(e,t,n){return function(){this.style.setProperty(e,t,n)}}function Hy(e,t,n){return function(){var r=t.apply(this,arguments);r==null?this.style.removeProperty(e):this.style.setProperty(e,r,n)}}function Gy(e,t,n){return arguments.length>1?this.each((t==null?Uy:typeof t=="function"?Hy:By)(e,t,n??"")):mr(this.node(),e)}function mr(e,t){return e.style.getPropertyValue(t)||Eh(e).getComputedStyle(e,null).getPropertyValue(t)}function Vy(e){return function(){delete this[e]}}function zy(e,t){return function(){this[e]=t}}function Wy(e,t){return function(){var n=t.apply(this,arguments);n==null?delete this[e]:this[e]=n}}function Yy(e,t){return arguments.length>1?this.each((t==null?Vy:typeof t=="function"?Wy:zy)(e,t)):this.node()[e]}function xh(e){return e.trim().split(/^|\s+/)}function $o(e){return e.classList||new bh(e)}function bh(e){this._node=e,this._names=xh(e.getAttribute("class")||"")}bh.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function _h(e,t){for(var n=$o(e),r=-1,i=t.length;++r<i;)n.add(t[r])}function Sh(e,t){for(var n=$o(e),r=-1,i=t.length;++r<i;)n.remove(t[r])}function qy(e){return function(){_h(this,e)}}function Xy(e){return function(){Sh(this,e)}}function jy(e,t){return function(){(t.apply(this,arguments)?_h:Sh)(this,e)}}function Zy(e,t){var n=xh(e+"");if(arguments.length<2){for(var r=$o(this.node()),i=-1,s=n.length;++i<s;)if(!r.contains(n[i]))return!1;return!0}return this.each((typeof t=="function"?jy:t?qy:Xy)(n,t))}function Ky(){this.textContent=""}function Qy(e){return function(){this.textContent=e}}function Jy(e){return function(){var t=e.apply(this,arguments);this.textContent=t??""}}function t1(e){return arguments.length?this.each(e==null?Ky:(typeof e=="function"?Jy:Qy)(e)):this.node().textContent}function e1(){this.innerHTML=""}function n1(e){return function(){this.innerHTML=e}}function r1(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t??""}}function i1(e){return arguments.length?this.each(e==null?e1:(typeof e=="function"?r1:n1)(e)):this.node().innerHTML}function s1(){this.nextSibling&&this.parentNode.appendChild(this)}function a1(){return this.each(s1)}function o1(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function l1(){return this.each(o1)}function c1(e){var t=typeof e=="function"?e:ph(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function u1(){return null}function h1(e,t){var n=typeof e=="function"?e:ph(e),r=t==null?u1:typeof t=="function"?t:No(t);return this.select(function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)})}function d1(){var e=this.parentNode;e&&e.removeChild(this)}function f1(){return this.each(d1)}function p1(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function g1(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function m1(e){return this.select(e?g1:p1)}function v1(e){return arguments.length?this.property("__data__",e):this.node().__data__}function y1(e){return function(t){e.call(this,t,this.__data__)}}function E1(e){return e.trim().split(/^|\s+/).map(function(t){var n="",r=t.indexOf(".");return r>=0&&(n=t.slice(r+1),t=t.slice(0,r)),{type:t,name:n}})}function x1(e){return function(){var t=this.__on;if(t){for(var n=0,r=-1,i=t.length,s;n<i;++n)s=t[n],(!e.type||s.type===e.type)&&s.name===e.name?this.removeEventListener(s.type,s.listener,s.options):t[++r]=s;++r?t.length=r:delete this.__on}}}function b1(e,t,n){return function(){var r=this.__on,i,s=y1(t);if(r){for(var a=0,o=r.length;a<o;++a)if((i=r[a]).type===e.type&&i.name===e.name){this.removeEventListener(i.type,i.listener,i.options),this.addEventListener(i.type,i.listener=s,i.options=n),i.value=t;return}}this.addEventListener(e.type,s,n),i={type:e.type,name:e.name,value:t,listener:s,options:n},r?r.push(i):this.__on=[i]}}function _1(e,t,n){var r=E1(e+""),i,s=r.length,a;if(arguments.length<2){var o=this.node().__on;if(o){for(var l=0,c=o.length,u;l<c;++l)for(i=0,u=o[l];i<s;++i)if((a=r[i]).type===u.type&&a.name===u.name)return u.value}return}for(o=t?b1:x1,i=0;i<s;++i)this.each(o(r[i],t,n));return this}function Th(e,t,n){var r=Eh(e),i=r.CustomEvent;typeof i=="function"?i=new i(t,n):(i=r.document.createEvent("Event"),n?(i.initEvent(t,n.bubbles,n.cancelable),i.detail=n.detail):i.initEvent(t,!1,!1)),e.dispatchEvent(i)}function S1(e,t){return function(){return Th(this,e,t)}}function T1(e,t){return function(){return Th(this,e,t.apply(this,arguments))}}function O1(e,t){return this.each((typeof t=="function"?T1:S1)(e,t))}function*w1(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var r=e[t],i=0,s=r.length,a;i<s;++i)(a=r[i])&&(yield a)}var Oh=[null];function ve(e,t){this._groups=e,this._parents=t}function ui(){return new ve([[document.documentElement]],Oh)}function M1(){return this}ve.prototype=ui.prototype={constructor:ve,select:J0,selectAll:ry,selectChild:oy,selectChildren:hy,filter:dy,data:yy,enter:fy,exit:xy,join:by,merge:_y,selection:M1,order:Sy,sort:Ty,call:wy,nodes:My,node:Ay,size:Cy,empty:Dy,each:Ly,attr:Fy,style:Gy,property:Yy,classed:Zy,text:t1,html:i1,raise:a1,lower:l1,append:c1,insert:h1,remove:f1,clone:m1,datum:v1,on:_1,dispatch:O1,[Symbol.iterator]:w1};function k(e){return typeof e=="string"?new ve([[document.querySelector(e)]],[document.documentElement]):new ve([[e]],Oh)}function A1(e){let t;for(;t=e.sourceEvent;)e=t;return e}function zn(e,t){if(e=A1(e),t===void 0&&(t=e.currentTarget),t){var n=t.ownerSVGElement||t;if(n.createSVGPoint){var r=n.createSVGPoint();return r.x=e.clientX,r.y=e.clientY,r=r.matrixTransform(t.getScreenCTM().inverse()),[r.x,r.y]}if(t.getBoundingClientRect){var i=t.getBoundingClientRect();return[e.clientX-i.left-t.clientLeft,e.clientY-i.top-t.clientTop]}}return[e.pageX,e.pageY]}const Fo={capture:!0,passive:!1};function Uo(e){e.preventDefault(),e.stopImmediatePropagation()}function C1(e){var t=e.document.documentElement,n=k(e).on("dragstart.drag",Uo,Fo);"onselectstart"in t?n.on("selectstart.drag",Uo,Fo):(t.__noselect=t.style.MozUserSelect,t.style.MozUserSelect="none")}function D1(e,t){var n=e.document.documentElement,r=k(e).on("dragstart.drag",null);t&&(r.on("click.drag",Uo,Fo),setTimeout(function(){r.on("click.drag",null)},0)),"onselectstart"in n?r.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}function Bo(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function wh(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function hi(){}var di=.7,Is=1/di,vr="\\s*([+-]?\\d+)\\s*",fi="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",je="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",L1=/^#([0-9a-f]{3,8})$/,R1=new RegExp(`^rgb\\(${vr},${vr},${vr}\\)$`),I1=new RegExp(`^rgb\\(${je},${je},${je}\\)$`),k1=new RegExp(`^rgba\\(${vr},${vr},${vr},${fi}\\)$`),P1=new RegExp(`^rgba\\(${je},${je},${je},${fi}\\)$`),N1=new RegExp(`^hsl\\(${fi},${je},${je}\\)$`),$1=new RegExp(`^hsla\\(${fi},${je},${je},${fi}\\)$`),Mh={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Bo(hi,un,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Ah,formatHex:Ah,formatHex8:F1,formatHsl:U1,formatRgb:Ch,toString:Ch});function Ah(){return this.rgb().formatHex()}function F1(){return this.rgb().formatHex8()}function U1(){return kh(this).formatHsl()}function Ch(){return this.rgb().formatRgb()}function un(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=L1.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?Dh(t):n===3?new ue(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?ks(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?ks(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=R1.exec(e))?new ue(t[1],t[2],t[3],1):(t=I1.exec(e))?new ue(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=k1.exec(e))?ks(t[1],t[2],t[3],t[4]):(t=P1.exec(e))?ks(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=N1.exec(e))?Ih(t[1],t[2]/100,t[3]/100,1):(t=$1.exec(e))?Ih(t[1],t[2]/100,t[3]/100,t[4]):Mh.hasOwnProperty(e)?Dh(Mh[e]):e==="transparent"?new ue(NaN,NaN,NaN,0):null}function Dh(e){return new ue(e>>16&255,e>>8&255,e&255,1)}function ks(e,t,n,r){return r<=0&&(e=t=n=NaN),new ue(e,t,n,r)}function B1(e){return e instanceof hi||(e=un(e)),e?(e=e.rgb(),new ue(e.r,e.g,e.b,e.opacity)):new ue}function Ho(e,t,n,r){return arguments.length===1?B1(e):new ue(e,t,n,r??1)}function ue(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}Bo(ue,Ho,wh(hi,{brighter(e){return e=e==null?Is:Math.pow(Is,e),new ue(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?di:Math.pow(di,e),new ue(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new ue(Wn(this.r),Wn(this.g),Wn(this.b),Ps(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Lh,formatHex:Lh,formatHex8:H1,formatRgb:Rh,toString:Rh}));function Lh(){return`#${Yn(this.r)}${Yn(this.g)}${Yn(this.b)}`}function H1(){return`#${Yn(this.r)}${Yn(this.g)}${Yn(this.b)}${Yn((isNaN(this.opacity)?1:this.opacity)*255)}`}function Rh(){const e=Ps(this.opacity);return`${e===1?"rgb(":"rgba("}${Wn(this.r)}, ${Wn(this.g)}, ${Wn(this.b)}${e===1?")":`, ${e})`}`}function Ps(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Wn(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Yn(e){return e=Wn(e),(e<16?"0":"")+e.toString(16)}function Ih(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new Ne(e,t,n,r)}function kh(e){if(e instanceof Ne)return new Ne(e.h,e.s,e.l,e.opacity);if(e instanceof hi||(e=un(e)),!e)return new Ne;if(e instanceof Ne)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),s=Math.max(t,n,r),a=NaN,o=s-i,l=(s+i)/2;return o?(t===s?a=(n-r)/o+(n<r)*6:n===s?a=(r-t)/o+2:a=(t-n)/o+4,o/=l<.5?s+i:2-s-i,a*=60):o=l>0&&l<1?0:a,new Ne(a,o,l,e.opacity)}function Go(e,t,n,r){return arguments.length===1?kh(e):new Ne(e,t,n,r??1)}function Ne(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}Bo(Ne,Go,wh(hi,{brighter(e){return e=e==null?Is:Math.pow(Is,e),new Ne(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?di:Math.pow(di,e),new Ne(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new ue(Vo(e>=240?e-240:e+120,i,r),Vo(e,i,r),Vo(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new Ne(Ph(this.h),Ns(this.s),Ns(this.l),Ps(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=Ps(this.opacity);return`${e===1?"hsl(":"hsla("}${Ph(this.h)}, ${Ns(this.s)*100}%, ${Ns(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Ph(e){return e=(e||0)%360,e<0?e+360:e}function Ns(e){return Math.max(0,Math.min(1,e||0))}function Vo(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const zo=e=>()=>e;function G1(e,t){return function(n){return e+n*t}}function V1(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function z1(e){return(e=+e)==1?Nh:function(t,n){return n-t?V1(t,n,e):zo(isNaN(t)?n:t)}}function Nh(e,t){var n=t-e;return n?G1(e,n):zo(isNaN(e)?t:e)}const $s=function e(t){var n=z1(t);function r(i,s){var a=n((i=Ho(i)).r,(s=Ho(s)).r),o=n(i.g,s.g),l=n(i.b,s.b),c=Nh(i.opacity,s.opacity);return function(u){return i.r=a(u),i.g=o(u),i.b=l(u),i.opacity=c(u),i+""}}return r.gamma=e,r}(1);function W1(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(s){for(i=0;i<n;++i)r[i]=e[i]*(1-s)+t[i]*s;return r}}function Y1(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function q1(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=new Array(r),s=new Array(n),a;for(a=0;a<r;++a)i[a]=pi(e[a],t[a]);for(;a<n;++a)s[a]=t[a];return function(o){for(a=0;a<r;++a)s[a]=i[a](o);return s}}function X1(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function ye(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function j1(e,t){var n={},r={},i;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(i in t)i in e?n[i]=pi(e[i],t[i]):r[i]=t[i];return function(s){for(i in n)r[i]=n[i](s);return r}}var Wo=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Yo=new RegExp(Wo.source,"g");function Z1(e){return function(){return e}}function K1(e){return function(t){return e(t)+""}}function $h(e,t){var n=Wo.lastIndex=Yo.lastIndex=0,r,i,s,a=-1,o=[],l=[];for(e=e+"",t=t+"";(r=Wo.exec(e))&&(i=Yo.exec(t));)(s=i.index)>n&&(s=t.slice(n,s),o[a]?o[a]+=s:o[++a]=s),(r=r[0])===(i=i[0])?o[a]?o[a]+=i:o[++a]=i:(o[++a]=null,l.push({i:a,x:ye(r,i)})),n=Yo.lastIndex;return n<t.length&&(s=t.slice(n),o[a]?o[a]+=s:o[++a]=s),o.length<2?l[0]?K1(l[0].x):Z1(t):(t=l.length,function(c){for(var u=0,d;u<t;++u)o[(d=l[u]).i]=d.x(c);return o.join("")})}function pi(e,t){var n=typeof t,r;return t==null||n==="boolean"?zo(t):(n==="number"?ye:n==="string"?(r=un(t))?(t=r,$s):$h:t instanceof un?$s:t instanceof Date?X1:Y1(t)?W1:Array.isArray(t)?q1:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?j1:ye)(e,t)}function Fh(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}var Uh=180/Math.PI,qo={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Bh(e,t,n,r,i,s){var a,o,l;return(a=Math.sqrt(e*e+t*t))&&(e/=a,t/=a),(l=e*n+t*r)&&(n-=e*l,r-=t*l),(o=Math.sqrt(n*n+r*r))&&(n/=o,r/=o,l/=o),e*r<t*n&&(e=-e,t=-t,l=-l,a=-a),{translateX:i,translateY:s,rotate:Math.atan2(t,e)*Uh,skewX:Math.atan(l)*Uh,scaleX:a,scaleY:o}}var Fs;function Q1(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?qo:Bh(t.a,t.b,t.c,t.d,t.e,t.f)}function J1(e){return e==null||(Fs||(Fs=document.createElementNS("http://www.w3.org/2000/svg","g")),Fs.setAttribute("transform",e),!(e=Fs.transform.baseVal.consolidate()))?qo:(e=e.matrix,Bh(e.a,e.b,e.c,e.d,e.e,e.f))}function Hh(e,t,n,r){function i(c){return c.length?c.pop()+" ":""}function s(c,u,d,h,f,p){if(c!==d||u!==h){var g=f.push("translate(",null,t,null,n);p.push({i:g-4,x:ye(c,d)},{i:g-2,x:ye(u,h)})}else(d||h)&&f.push("translate("+d+t+h+n)}function a(c,u,d,h){c!==u?(c-u>180?u+=360:u-c>180&&(c+=360),h.push({i:d.push(i(d)+"rotate(",null,r)-2,x:ye(c,u)})):u&&d.push(i(d)+"rotate("+u+r)}function o(c,u,d,h){c!==u?h.push({i:d.push(i(d)+"skewX(",null,r)-2,x:ye(c,u)}):u&&d.push(i(d)+"skewX("+u+r)}function l(c,u,d,h,f,p){if(c!==d||u!==h){var g=f.push(i(f)+"scale(",null,",",null,")");p.push({i:g-4,x:ye(c,d)},{i:g-2,x:ye(u,h)})}else(d!==1||h!==1)&&f.push(i(f)+"scale("+d+","+h+")")}return function(c,u){var d=[],h=[];return c=e(c),u=e(u),s(c.translateX,c.translateY,u.translateX,u.translateY,d,h),a(c.rotate,u.rotate,d,h),o(c.skewX,u.skewX,d,h),l(c.scaleX,c.scaleY,u.scaleX,u.scaleY,d,h),c=u=null,function(f){for(var p=-1,g=h.length,m;++p<g;)d[(m=h[p]).i]=m.x(f);return d.join("")}}}var tE=Hh(Q1,"px, ","px)","deg)"),eE=Hh(J1,", ",")",")");function nE(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e(r/(t-1));return n}var yr=0,gi=0,mi=0,Gh=1e3,Us,vi,Bs=0,qn=0,Hs=0,yi=typeof performance=="object"&&performance.now?performance:Date,Vh=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function Xo(){return qn||(Vh(rE),qn=yi.now()+Hs)}function rE(){qn=0}function Gs(){this._call=this._time=this._next=null}Gs.prototype=zh.prototype={constructor:Gs,restart:function(e,t,n){if(typeof e!="function")throw new TypeError("callback is not a function");n=(n==null?Xo():+n)+(t==null?0:+t),!this._next&&vi!==this&&(vi?vi._next=this:Us=this,vi=this),this._call=e,this._time=n,jo()},stop:function(){this._call&&(this._call=null,this._time=1/0,jo())}};function zh(e,t,n){var r=new Gs;return r.restart(e,t,n),r}function iE(){Xo(),++yr;for(var e=Us,t;e;)(t=qn-e._time)>=0&&e._call.call(void 0,t),e=e._next;--yr}function Wh(){qn=(Bs=yi.now())+Hs,yr=gi=0;try{iE()}finally{yr=0,aE(),qn=0}}function sE(){var e=yi.now(),t=e-Bs;t>Gh&&(Hs-=t,Bs=e)}function aE(){for(var e,t=Us,n,r=1/0;t;)t._call?(r>t._time&&(r=t._time),e=t,t=t._next):(n=t._next,t._next=null,t=e?e._next=n:Us=n);vi=e,jo(r)}function jo(e){if(!yr){gi&&(gi=clearTimeout(gi));var t=e-qn;t>24?(e<1/0&&(gi=setTimeout(Wh,e-yi.now()-Hs)),mi&&(mi=clearInterval(mi))):(mi||(Bs=yi.now(),mi=setInterval(sE,Gh)),yr=1,Vh(Wh))}}function Yh(e,t,n){var r=new Gs;return t=t==null?0:+t,r.restart(i=>{r.stop(),e(i+t)},t,n),r}var oE=ko("start","end","cancel","interrupt"),lE=[],qh=0,Xh=1,Zo=2,Vs=3,jh=4,Ko=5,zs=6;function Ws(e,t,n,r,i,s){var a=e.__transition;if(!a)e.__transition={};else if(n in a)return;cE(e,n,{name:t,index:r,group:i,on:oE,tween:lE,time:s.time,delay:s.delay,duration:s.duration,ease:s.ease,timer:null,state:qh})}function Qo(e,t){var n=$e(e,t);if(n.state>qh)throw new Error("too late; already scheduled");return n}function Ze(e,t){var n=$e(e,t);if(n.state>Vs)throw new Error("too late; already running");return n}function $e(e,t){var n=e.__transition;if(!n||!(n=n[t]))throw new Error("transition not found");return n}function cE(e,t,n){var r=e.__transition,i;r[t]=n,n.timer=zh(s,0,n.time);function s(c){n.state=Xh,n.timer.restart(a,n.delay,n.time),n.delay<=c&&a(c-n.delay)}function a(c){var u,d,h,f;if(n.state!==Xh)return l();for(u in r)if(f=r[u],f.name===n.name){if(f.state===Vs)return Yh(a);f.state===jh?(f.state=zs,f.timer.stop(),f.on.call("interrupt",e,e.__data__,f.index,f.group),delete r[u]):+u<t&&(f.state=zs,f.timer.stop(),f.on.call("cancel",e,e.__data__,f.index,f.group),delete r[u])}if(Yh(function(){n.state===Vs&&(n.state=jh,n.timer.restart(o,n.delay,n.time),o(c))}),n.state=Zo,n.on.call("start",e,e.__data__,n.index,n.group),n.state===Zo){for(n.state=Vs,i=new Array(h=n.tween.length),u=0,d=-1;u<h;++u)(f=n.tween[u].value.call(e,e.__data__,n.index,n.group))&&(i[++d]=f);i.length=d+1}}function o(c){for(var u=c<n.duration?n.ease.call(null,c/n.duration):(n.timer.restart(l),n.state=Ko,1),d=-1,h=i.length;++d<h;)i[d].call(e,u);n.state===Ko&&(n.on.call("end",e,e.__data__,n.index,n.group),l())}function l(){n.state=zs,n.timer.stop(),delete r[t];for(var c in r)return;delete e.__transition}}function Jo(e,t){var n=e.__transition,r,i,s=!0,a;if(n){t=t==null?null:t+"";for(a in n){if((r=n[a]).name!==t){s=!1;continue}i=r.state>Zo&&r.state<Ko,r.state=zs,r.timer.stop(),r.on.call(i?"interrupt":"cancel",e,e.__data__,r.index,r.group),delete n[a]}s&&delete e.__transition}}function uE(e){return this.each(function(){Jo(this,e)})}function hE(e,t){var n,r;return function(){var i=Ze(this,e),s=i.tween;if(s!==n){r=n=s;for(var a=0,o=r.length;a<o;++a)if(r[a].name===t){r=r.slice(),r.splice(a,1);break}}i.tween=r}}function dE(e,t,n){var r,i;if(typeof n!="function")throw new Error;return function(){var s=Ze(this,e),a=s.tween;if(a!==r){i=(r=a).slice();for(var o={name:t,value:n},l=0,c=i.length;l<c;++l)if(i[l].name===t){i[l]=o;break}l===c&&i.push(o)}s.tween=i}}function fE(e,t){var n=this._id;if(e+="",arguments.length<2){for(var r=$e(this.node(),n).tween,i=0,s=r.length,a;i<s;++i)if((a=r[i]).name===e)return a.value;return null}return this.each((t==null?hE:dE)(n,e,t))}function tl(e,t,n){var r=e._id;return e.each(function(){var i=Ze(this,r);(i.value||(i.value={}))[t]=n.apply(this,arguments)}),function(i){return $e(i,r).value[t]}}function Zh(e,t){var n;return(typeof t=="number"?ye:t instanceof un?$s:(n=un(t))?(t=n,$s):$h)(e,t)}function pE(e){return function(){this.removeAttribute(e)}}function gE(e){return function(){this.removeAttributeNS(e.space,e.local)}}function mE(e,t,n){var r,i=n+"",s;return function(){var a=this.getAttribute(e);return a===i?null:a===r?s:s=t(r=a,n)}}function vE(e,t,n){var r,i=n+"",s;return function(){var a=this.getAttributeNS(e.space,e.local);return a===i?null:a===r?s:s=t(r=a,n)}}function yE(e,t,n){var r,i,s;return function(){var a,o=n(this),l;return o==null?void this.removeAttribute(e):(a=this.getAttribute(e),l=o+"",a===l?null:a===r&&l===i?s:(i=l,s=t(r=a,o)))}}function EE(e,t,n){var r,i,s;return function(){var a,o=n(this),l;return o==null?void this.removeAttributeNS(e.space,e.local):(a=this.getAttributeNS(e.space,e.local),l=o+"",a===l?null:a===r&&l===i?s:(i=l,s=t(r=a,o)))}}function xE(e,t){var n=Ls(e),r=n==="transform"?eE:Zh;return this.attrTween(e,typeof t=="function"?(n.local?EE:yE)(n,r,tl(this,"attr."+e,t)):t==null?(n.local?gE:pE)(n):(n.local?vE:mE)(n,r,t))}function bE(e,t){return function(n){this.setAttribute(e,t.call(this,n))}}function _E(e,t){return function(n){this.setAttributeNS(e.space,e.local,t.call(this,n))}}function SE(e,t){var n,r;function i(){var s=t.apply(this,arguments);return s!==r&&(n=(r=s)&&_E(e,s)),n}return i._value=t,i}function TE(e,t){var n,r;function i(){var s=t.apply(this,arguments);return s!==r&&(n=(r=s)&&bE(e,s)),n}return i._value=t,i}function OE(e,t){var n="attr."+e;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(t==null)return this.tween(n,null);if(typeof t!="function")throw new Error;var r=Ls(e);return this.tween(n,(r.local?SE:TE)(r,t))}function wE(e,t){return function(){Qo(this,e).delay=+t.apply(this,arguments)}}function ME(e,t){return t=+t,function(){Qo(this,e).delay=t}}function AE(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?wE:ME)(t,e)):$e(this.node(),t).delay}function CE(e,t){return function(){Ze(this,e).duration=+t.apply(this,arguments)}}function DE(e,t){return t=+t,function(){Ze(this,e).duration=t}}function LE(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?CE:DE)(t,e)):$e(this.node(),t).duration}function RE(e,t){if(typeof t!="function")throw new Error;return function(){Ze(this,e).ease=t}}function IE(e){var t=this._id;return arguments.length?this.each(RE(t,e)):$e(this.node(),t).ease}function kE(e,t){return function(){var n=t.apply(this,arguments);if(typeof n!="function")throw new Error;Ze(this,e).ease=n}}function PE(e){if(typeof e!="function")throw new Error;return this.each(kE(this._id,e))}function NE(e){typeof e!="function"&&(e=mh(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var s=t[i],a=s.length,o=r[i]=[],l,c=0;c<a;++c)(l=s[c])&&e.call(l,l.__data__,c,s)&&o.push(l);return new hn(r,this._parents,this._name,this._id)}function $E(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,n=e._groups,r=t.length,i=n.length,s=Math.min(r,i),a=new Array(r),o=0;o<s;++o)for(var l=t[o],c=n[o],u=l.length,d=a[o]=new Array(u),h,f=0;f<u;++f)(h=l[f]||c[f])&&(d[f]=h);for(;o<r;++o)a[o]=t[o];return new hn(a,this._parents,this._name,this._id)}function FE(e){return(e+"").trim().split(/^|\s+/).every(function(t){var n=t.indexOf(".");return n>=0&&(t=t.slice(0,n)),!t||t==="start"})}function UE(e,t,n){var r,i,s=FE(t)?Qo:Ze;return function(){var a=s(this,e),o=a.on;o!==r&&(i=(r=o).copy()).on(t,n),a.on=i}}function BE(e,t){var n=this._id;return arguments.length<2?$e(this.node(),n).on.on(e):this.each(UE(n,e,t))}function HE(e){return function(){var t=this.parentNode;for(var n in this.__transition)if(+n!==e)return;t&&t.removeChild(this)}}function GE(){return this.on("end.remove",HE(this._id))}function VE(e){var t=this._name,n=this._id;typeof e!="function"&&(e=No(e));for(var r=this._groups,i=r.length,s=new Array(i),a=0;a<i;++a)for(var o=r[a],l=o.length,c=s[a]=new Array(l),u,d,h=0;h<l;++h)(u=o[h])&&(d=e.call(u,u.__data__,h,o))&&("__data__"in u&&(d.__data__=u.__data__),c[h]=d,Ws(c[h],t,n,h,c,$e(u,n)));return new hn(s,this._parents,t,n)}function zE(e){var t=this._name,n=this._id;typeof e!="function"&&(e=gh(e));for(var r=this._groups,i=r.length,s=[],a=[],o=0;o<i;++o)for(var l=r[o],c=l.length,u,d=0;d<c;++d)if(u=l[d]){for(var h=e.call(u,u.__data__,d,l),f,p=$e(u,n),g=0,m=h.length;g<m;++g)(f=h[g])&&Ws(f,t,n,g,h,p);s.push(h),a.push(u)}return new hn(s,a,t,n)}var WE=ui.prototype.constructor;function YE(){return new WE(this._groups,this._parents)}function qE(e,t){var n,r,i;return function(){var s=mr(this,e),a=(this.style.removeProperty(e),mr(this,e));return s===a?null:s===n&&a===r?i:i=t(n=s,r=a)}}function Kh(e){return function(){this.style.removeProperty(e)}}function XE(e,t,n){var r,i=n+"",s;return function(){var a=mr(this,e);return a===i?null:a===r?s:s=t(r=a,n)}}function jE(e,t,n){var r,i,s;return function(){var a=mr(this,e),o=n(this),l=o+"";return o==null&&(l=o=(this.style.removeProperty(e),mr(this,e))),a===l?null:a===r&&l===i?s:(i=l,s=t(r=a,o))}}function ZE(e,t){var n,r,i,s="style."+t,a="end."+s,o;return function(){var l=Ze(this,e),c=l.on,u=l.value[s]==null?o||(o=Kh(t)):void 0;(c!==n||i!==u)&&(r=(n=c).copy()).on(a,i=u),l.on=r}}function KE(e,t,n){var r=(e+="")=="transform"?tE:Zh;return t==null?this.styleTween(e,qE(e,r)).on("end.style."+e,Kh(e)):typeof t=="function"?this.styleTween(e,jE(e,r,tl(this,"style."+e,t))).each(ZE(this._id,e)):this.styleTween(e,XE(e,r,t),n).on("end.style."+e,null)}function QE(e,t,n){return function(r){this.style.setProperty(e,t.call(this,r),n)}}function JE(e,t,n){var r,i;function s(){var a=t.apply(this,arguments);return a!==i&&(r=(i=a)&&QE(e,a,n)),r}return s._value=t,s}function tx(e,t,n){var r="style."+(e+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(t==null)return this.tween(r,null);if(typeof t!="function")throw new Error;return this.tween(r,JE(e,t,n??""))}function ex(e){return function(){this.textContent=e}}function nx(e){return function(){var t=e(this);this.textContent=t??""}}function rx(e){return this.tween("text",typeof e=="function"?nx(tl(this,"text",e)):ex(e==null?"":e+""))}function ix(e){return function(t){this.textContent=e.call(this,t)}}function sx(e){var t,n;function r(){var i=e.apply(this,arguments);return i!==n&&(t=(n=i)&&ix(i)),t}return r._value=e,r}function ax(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(e==null)return this.tween(t,null);if(typeof e!="function")throw new Error;return this.tween(t,sx(e))}function ox(){for(var e=this._name,t=this._id,n=Qh(),r=this._groups,i=r.length,s=0;s<i;++s)for(var a=r[s],o=a.length,l,c=0;c<o;++c)if(l=a[c]){var u=$e(l,t);Ws(l,e,n,c,a,{time:u.time+u.delay+u.duration,delay:0,duration:u.duration,ease:u.ease})}return new hn(r,this._parents,e,n)}function lx(){var e,t,n=this,r=n._id,i=n.size();return new Promise(function(s,a){var o={value:a},l={value:function(){--i===0&&s()}};n.each(function(){var c=Ze(this,r),u=c.on;u!==e&&(t=(e=u).copy(),t._.cancel.push(o),t._.interrupt.push(o),t._.end.push(l)),c.on=t}),i===0&&s()})}var cx=0;function hn(e,t,n,r){this._groups=e,this._parents=t,this._name=n,this._id=r}function Qh(){return++cx}var dn=ui.prototype;hn.prototype={constructor:hn,select:VE,selectAll:zE,selectChild:dn.selectChild,selectChildren:dn.selectChildren,filter:NE,merge:$E,selection:YE,transition:ox,call:dn.call,nodes:dn.nodes,node:dn.node,size:dn.size,empty:dn.empty,each:dn.each,on:BE,attr:xE,attrTween:OE,style:KE,styleTween:tx,text:rx,textTween:ax,remove:GE,tween:fE,delay:AE,duration:LE,ease:IE,easeVarying:PE,end:lx,[Symbol.iterator]:dn[Symbol.iterator]};const ux=e=>+e;function Jh(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var hx={time:null,delay:0,duration:250,ease:Jh};function dx(e,t){for(var n;!(n=e.__transition)||!(n=n[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return n}function fx(e){var t,n;e instanceof hn?(t=e._id,e=e._name):(t=Qh(),(n=hx).time=Xo(),e=e==null?null:e+"");for(var r=this._groups,i=r.length,s=0;s<i;++s)for(var a=r[s],o=a.length,l,c=0;c<o;++c)(l=a[c])&&Ws(l,e,t,c,a,n||dx(l,t));return new hn(r,this._parents,e,t)}ui.prototype.interrupt=uE,ui.prototype.transition=fx;const el=e=>()=>e;function px(e,{sourceEvent:t,target:n,selection:r,mode:i,dispatch:s}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},selection:{value:r,enumerable:!0,configurable:!0},mode:{value:i,enumerable:!0,configurable:!0},_:{value:s}})}function gx(e){e.stopImmediatePropagation()}function nl(e){e.preventDefault(),e.stopImmediatePropagation()}var td={name:"drag"},rl={name:"space"},Er={name:"handle"},xr={name:"center"};const{abs:ed,max:Kt,min:Qt}=Math;function nd(e){return[+e[0],+e[1]]}function rd(e){return[nd(e[0]),nd(e[1])]}var Ys={name:"x",handles:["w","e"].map(qs),input:function(e,t){return e==null?null:[[+e[0],t[0][1]],[+e[1],t[1][1]]]},output:function(e){return e&&[e[0][0],e[1][0]]}},il={name:"y",handles:["n","s"].map(qs),input:function(e,t){return e==null?null:[[t[0][0],+e[0]],[t[1][0],+e[1]]]},output:function(e){return e&&[e[0][1],e[1][1]]}},fn={overlay:"crosshair",selection:"move",n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},id={e:"w",w:"e",nw:"ne",ne:"nw",se:"sw",sw:"se"},sd={n:"s",s:"n",nw:"sw",ne:"se",se:"ne",sw:"nw"},mx={overlay:1,selection:1,n:null,e:1,s:null,w:-1,nw:-1,ne:1,se:1,sw:-1},vx={overlay:1,selection:1,n:-1,e:null,s:1,w:null,nw:-1,ne:-1,se:1,sw:1};function qs(e){return{type:e}}function yx(e){return!e.ctrlKey&&!e.button}function Ex(){var e=this.ownerSVGElement||this;return e.hasAttribute("viewBox")?(e=e.viewBox.baseVal,[[e.x,e.y],[e.x+e.width,e.y+e.height]]):[[0,0],[e.width.baseVal.value,e.height.baseVal.value]]}function xx(){return navigator.maxTouchPoints||"ontouchstart"in this}function sl(e){for(;!e.__brush;)if(!(e=e.parentNode))return;return e.__brush}function bx(e){return e[0][0]===e[1][0]||e[0][1]===e[1][1]}function ad(){return _x(Ys)}function _x(e){var t=Ex,n=yx,r=xx,i=!0,s=ko("start","brush","end"),a=6,o;function l(m){var v=m.property("__brush",g).selectAll(".overlay").data([qs("overlay")]);v.enter().append("rect").attr("class","overlay").attr("pointer-events","all").attr("cursor",fn.overlay).merge(v).each(function(){var y=sl(this).extent;k(this).attr("x",y[0][0]).attr("y",y[0][1]).attr("width",y[1][0]-y[0][0]).attr("height",y[1][1]-y[0][1])}),m.selectAll(".selection").data([qs("selection")]).enter().append("rect").attr("class","selection").attr("cursor",fn.selection).attr("fill","#777").attr("fill-opacity",.3).attr("stroke","#fff").attr("shape-rendering","crispEdges");var E=m.selectAll(".handle").data(e.handles,function(y){return y.type});E.exit().remove(),E.enter().append("rect").attr("class",function(y){return"handle handle--"+y.type}).attr("cursor",function(y){return fn[y.type]}),m.each(c).attr("fill","none").attr("pointer-events","all").on("mousedown.brush",h).filter(r).on("touchstart.brush",h).on("touchmove.brush",f).on("touchend.brush touchcancel.brush",p).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}l.move=function(m,v,E){m.tween?m.on("start.brush",function(y){u(this,arguments).beforestart().start(y)}).on("interrupt.brush end.brush",function(y){u(this,arguments).end(y)}).tween("brush",function(){var y=this,b=y.__brush,S=u(y,arguments),_=b.selection,A=e.input(typeof v=="function"?v.apply(this,arguments):v,b.extent),R=pi(_,A);function B(D){b.selection=D===1&&A===null?null:R(D),c.call(y),S.brush()}return _!==null&&A!==null?B:B(1)}):m.each(function(){var y=this,b=arguments,S=y.__brush,_=e.input(typeof v=="function"?v.apply(y,b):v,S.extent),A=u(y,b).beforestart();Jo(y),S.selection=_===null?null:_,c.call(y),A.start(E).brush(E).end(E)})},l.clear=function(m,v){l.move(m,null,v)};function c(){var m=k(this),v=sl(this).selection;v?(m.selectAll(".selection").style("display",null).attr("x",v[0][0]).attr("y",v[0][1]).attr("width",v[1][0]-v[0][0]).attr("height",v[1][1]-v[0][1]),m.selectAll(".handle").style("display",null).attr("x",function(E){return E.type[E.type.length-1]==="e"?v[1][0]-a/2:v[0][0]-a/2}).attr("y",function(E){return E.type[0]==="s"?v[1][1]-a/2:v[0][1]-a/2}).attr("width",function(E){return E.type==="n"||E.type==="s"?v[1][0]-v[0][0]+a:a}).attr("height",function(E){return E.type==="e"||E.type==="w"?v[1][1]-v[0][1]+a:a})):m.selectAll(".selection,.handle").style("display","none").attr("x",null).attr("y",null).attr("width",null).attr("height",null)}function u(m,v,E){var y=m.__brush.emitter;return y&&(!E||!y.clean)?y:new d(m,v,E)}function d(m,v,E){this.that=m,this.args=v,this.state=m.__brush,this.active=0,this.clean=E}d.prototype={beforestart:function(){return++this.active===1&&(this.state.emitter=this,this.starting=!0),this},start:function(m,v){return this.starting?(this.starting=!1,this.emit("start",m,v)):this.emit("brush",m),this},brush:function(m,v){return this.emit("brush",m,v),this},end:function(m,v){return--this.active===0&&(delete this.state.emitter,this.emit("end",m,v)),this},emit:function(m,v,E){var y=k(this.that).datum();s.call(m,this.that,new px(m,{sourceEvent:v,target:l,selection:e.output(this.state.selection),mode:E,dispatch:s}),y)}};function h(m){if(o&&!m.touches||!n.apply(this,arguments))return;var v=this,E=m.target.__data__.type,y=(i&&m.metaKey?E="overlay":E)==="selection"?td:i&&m.altKey?xr:Er,b=e===il?null:mx[E],S=e===Ys?null:vx[E],_=sl(v),A=_.extent,R=_.selection,B=A[0][0],D,O,H=A[0][1],P,M,w=A[1][0],U,$,N=A[1][1],F,Y,Z=0,K=0,dt,it=b&&S&&i&&m.shiftKey,ft,j,nt=Array.from(m.touches||[m],st=>{const Dt=st.identifier;return st=zn(st,v),st.point0=st.slice(),st.identifier=Dt,st});Jo(v);var vt=u(v,arguments,!0).beforestart();if(E==="overlay"){R&&(dt=!0);const st=[nt[0],nt[1]||nt[0]];_.selection=R=[[D=e===il?B:Qt(st[0][0],st[1][0]),P=e===Ys?H:Qt(st[0][1],st[1][1])],[U=e===il?w:Kt(st[0][0],st[1][0]),F=e===Ys?N:Kt(st[0][1],st[1][1])]],nt.length>1&&G(m)}else D=R[0][0],P=R[0][1],U=R[1][0],F=R[1][1];O=D,M=P,$=U,Y=F;var q=k(v).attr("pointer-events","none"),Q=q.selectAll(".overlay").attr("cursor",fn[E]);if(m.touches)vt.moved=C,vt.ended=z;else{var ot=k(m.view).on("mousemove.brush",C,!0).on("mouseup.brush",z,!0);i&&ot.on("keydown.brush",Ct,!0).on("keyup.brush",Ut,!0),C1(m.view)}c.call(v),vt.start(m,y.name);function C(st){for(const Dt of st.changedTouches||[st])for(const Hn of nt)Hn.identifier===Dt.identifier&&(Hn.cur=zn(Dt,v));if(it&&!ft&&!j&&nt.length===1){const Dt=nt[0];ed(Dt.cur[0]-Dt[0])>ed(Dt.cur[1]-Dt[1])?j=!0:ft=!0}for(const Dt of nt)Dt.cur&&(Dt[0]=Dt.cur[0],Dt[1]=Dt.cur[1]);dt=!0,nl(st),G(st)}function G(st){const Dt=nt[0],Hn=Dt.point0;var Xe;switch(Z=Dt[0]-Hn[0],K=Dt[1]-Hn[1],y){case rl:case td:{b&&(Z=Kt(B-D,Qt(w-U,Z)),O=D+Z,$=U+Z),S&&(K=Kt(H-P,Qt(N-F,K)),M=P+K,Y=F+K);break}case Er:{nt[1]?(b&&(O=Kt(B,Qt(w,nt[0][0])),$=Kt(B,Qt(w,nt[1][0])),b=1),S&&(M=Kt(H,Qt(N,nt[0][1])),Y=Kt(H,Qt(N,nt[1][1])),S=1)):(b<0?(Z=Kt(B-D,Qt(w-D,Z)),O=D+Z,$=U):b>0&&(Z=Kt(B-U,Qt(w-U,Z)),O=D,$=U+Z),S<0?(K=Kt(H-P,Qt(N-P,K)),M=P+K,Y=F):S>0&&(K=Kt(H-F,Qt(N-F,K)),M=P,Y=F+K));break}case xr:{b&&(O=Kt(B,Qt(w,D-Z*b)),$=Kt(B,Qt(w,U+Z*b))),S&&(M=Kt(H,Qt(N,P-K*S)),Y=Kt(H,Qt(N,F+K*S)));break}}$<O&&(b*=-1,Xe=D,D=U,U=Xe,Xe=O,O=$,$=Xe,E in id&&Q.attr("cursor",fn[E=id[E]])),Y<M&&(S*=-1,Xe=P,P=F,F=Xe,Xe=M,M=Y,Y=Xe,E in sd&&Q.attr("cursor",fn[E=sd[E]])),_.selection&&(R=_.selection),ft&&(O=R[0][0],$=R[1][0]),j&&(M=R[0][1],Y=R[1][1]),(R[0][0]!==O||R[0][1]!==M||R[1][0]!==$||R[1][1]!==Y)&&(_.selection=[[O,M],[$,Y]],c.call(v),vt.brush(st,y.name))}function z(st){if(gx(st),st.touches){if(st.touches.length)return;o&&clearTimeout(o),o=setTimeout(function(){o=null},500)}else D1(st.view,dt),ot.on("keydown.brush keyup.brush mousemove.brush mouseup.brush",null);q.attr("pointer-events","all"),Q.attr("cursor",fn.overlay),_.selection&&(R=_.selection),bx(R)&&(_.selection=null,c.call(v)),vt.end(st,y.name)}function Ct(st){switch(st.keyCode){case 16:{it=b&&S;break}case 18:{y===Er&&(b&&(U=$-Z*b,D=O+Z*b),S&&(F=Y-K*S,P=M+K*S),y=xr,G(st));break}case 32:{(y===Er||y===xr)&&(b<0?U=$-Z:b>0&&(D=O-Z),S<0?F=Y-K:S>0&&(P=M-K),y=rl,Q.attr("cursor",fn.selection),G(st));break}default:return}nl(st)}function Ut(st){switch(st.keyCode){case 16:{it&&(ft=j=it=!1,G(st));break}case 18:{y===xr&&(b<0?U=$:b>0&&(D=O),S<0?F=Y:S>0&&(P=M),y=Er,G(st));break}case 32:{y===rl&&(st.altKey?(b&&(U=$-Z*b,D=O+Z*b),S&&(F=Y-K*S,P=M+K*S),y=xr):(b<0?U=$:b>0&&(D=O),S<0?F=Y:S>0&&(P=M),y=Er),Q.attr("cursor",fn[E]),G(st));break}default:return}nl(st)}}function f(m){u(this,arguments).moved(m)}function p(m){u(this,arguments).ended(m)}function g(){var m=this.__brush||{selection:null};return m.extent=rd(t.apply(this,arguments)),m.dim=e,m}return l.extent=function(m){return arguments.length?(t=typeof m=="function"?m:el(rd(m)),l):t},l.filter=function(m){return arguments.length?(n=typeof m=="function"?m:el(!!m),l):n},l.touchable=function(m){return arguments.length?(r=typeof m=="function"?m:el(!!m),l):r},l.handleSize=function(m){return arguments.length?(a=+m,l):a},l.keyModifiers=function(m){return arguments.length?(i=!!m,l):i},l.on=function(){var m=s.on.apply(s,arguments);return m===s?l:m},l}const al=Math.PI,ol=2*al,Xn=1e-6,Sx=ol-Xn;function od(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function Tx(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return od;const n=10**t;return function(r){this._+=r[0];for(let i=1,s=r.length;i<s;++i)this._+=Math.round(arguments[i]*n)/n+r[i]}}let Ox=class{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?od:Tx(t)}moveTo(t,n){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,n){this._append`L${this._x1=+t},${this._y1=+n}`}quadraticCurveTo(t,n,r,i){this._append`Q${+t},${+n},${this._x1=+r},${this._y1=+i}`}bezierCurveTo(t,n,r,i,s,a){this._append`C${+t},${+n},${+r},${+i},${this._x1=+s},${this._y1=+a}`}arcTo(t,n,r,i,s){if(t=+t,n=+n,r=+r,i=+i,s=+s,s<0)throw new Error(`negative radius: ${s}`);let a=this._x1,o=this._y1,l=r-t,c=i-n,u=a-t,d=o-n,h=u*u+d*d;if(this._x1===null)this._append`M${this._x1=t},${this._y1=n}`;else if(h>Xn)if(!(Math.abs(d*l-c*u)>Xn)||!s)this._append`L${this._x1=t},${this._y1=n}`;else{let f=r-a,p=i-o,g=l*l+c*c,m=f*f+p*p,v=Math.sqrt(g),E=Math.sqrt(h),y=s*Math.tan((al-Math.acos((g+h-m)/(2*v*E)))/2),b=y/E,S=y/v;Math.abs(b-1)>Xn&&this._append`L${t+b*u},${n+b*d}`,this._append`A${s},${s},0,0,${+(d*f>u*p)},${this._x1=t+S*l},${this._y1=n+S*c}`}}arc(t,n,r,i,s,a){if(t=+t,n=+n,r=+r,a=!!a,r<0)throw new Error(`negative radius: ${r}`);let o=r*Math.cos(i),l=r*Math.sin(i),c=t+o,u=n+l,d=1^a,h=a?i-s:s-i;this._x1===null?this._append`M${c},${u}`:(Math.abs(this._x1-c)>Xn||Math.abs(this._y1-u)>Xn)&&this._append`L${c},${u}`,r&&(h<0&&(h=h%ol+ol),h>Sx?this._append`A${r},${r},0,1,${d},${t-o},${n-l}A${r},${r},0,1,${d},${this._x1=c},${this._y1=u}`:h>Xn&&this._append`A${r},${r},0,${+(h>=al)},${d},${this._x1=t+r*Math.cos(s)},${this._y1=n+r*Math.sin(s)}`)}rect(t,n,r,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${r=+r}v${+i}h${-r}Z`}toString(){return this._}};function wx(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Xs(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 br(e){return e=Xs(Math.abs(e)),e?e[1]:NaN}function Mx(e,t){return function(n,r){for(var i=n.length,s=[],a=0,o=e[0],l=0;i>0&&o>0&&(l+o+1>r&&(o=Math.max(1,r-l)),s.push(n.substring(i-=o,i+o)),!((l+=o+1)>r));)o=e[a=(a+1)%e.length];return s.reverse().join(t)}}function Ax(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var Cx=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Ei(e){if(!(t=Cx.exec(e)))throw new Error("invalid format: "+e);var t;return new ll({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]})}Ei.prototype=ll.prototype;function ll(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}ll.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function Dx(e){t:for(var t=e.length,n=1,r=-1,i;n<t;++n)switch(e[n]){case".":r=i=n;break;case"0":r===0&&(r=n),i=n;break;default:if(!+e[n])break t;r>0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(i+1):e}var ld;function Lx(e,t){var n=Xs(e,t);if(!n)return e+"";var r=n[0],i=n[1],s=i-(ld=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,a=r.length;return s===a?r:s>a?r+new Array(s-a+1).join("0"):s>0?r.slice(0,s)+"."+r.slice(s):"0."+new Array(1-s).join("0")+Xs(e,Math.max(0,t+s-1))[0]}function cd(e,t){var n=Xs(e,t);if(!n)return e+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}const ud={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:wx,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)=>cd(e*100,t),r:cd,s:Lx,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function hd(e){return e}var dd=Array.prototype.map,fd=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function Rx(e){var t=e.grouping===void 0||e.thousands===void 0?hd:Mx(dd.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",s=e.numerals===void 0?hd:Ax(dd.call(e.numerals,String)),a=e.percent===void 0?"%":e.percent+"",o=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function c(d){d=Ei(d);var h=d.fill,f=d.align,p=d.sign,g=d.symbol,m=d.zero,v=d.width,E=d.comma,y=d.precision,b=d.trim,S=d.type;S==="n"?(E=!0,S="g"):ud[S]||(y===void 0&&(y=12),b=!0,S="g"),(m||h==="0"&&f==="=")&&(m=!0,h="0",f="=");var _=g==="$"?n:g==="#"&&/[boxX]/.test(S)?"0"+S.toLowerCase():"",A=g==="$"?r:/[%p]/.test(S)?a:"",R=ud[S],B=/[defgprs%]/.test(S);y=y===void 0?6:/[gprs]/.test(S)?Math.max(1,Math.min(21,y)):Math.max(0,Math.min(20,y));function D(O){var H=_,P=A,M,w,U;if(S==="c")P=R(O)+P,O="";else{O=+O;var $=O<0||1/O<0;if(O=isNaN(O)?l:R(Math.abs(O),y),b&&(O=Dx(O)),$&&+O==0&&p!=="+"&&($=!1),H=($?p==="("?p:o:p==="-"||p==="("?"":p)+H,P=(S==="s"?fd[8+ld/3]:"")+P+($&&p==="("?")":""),B){for(M=-1,w=O.length;++M<w;)if(U=O.charCodeAt(M),48>U||U>57){P=(U===46?i+O.slice(M+1):O.slice(M))+P,O=O.slice(0,M);break}}}E&&!m&&(O=t(O,1/0));var N=H.length+O.length+P.length,F=N<v?new Array(v-N+1).join(h):"";switch(E&&m&&(O=t(F+O,F.length?v-P.length:1/0),F=""),f){case"<":O=H+O+P+F;break;case"=":O=H+F+O+P;break;case"^":O=F.slice(0,N=F.length>>1)+H+O+P+F.slice(N);break;default:O=F+H+O+P;break}return s(O)}return D.toString=function(){return d+""},D}function u(d,h){var f=c((d=Ei(d),d.type="f",d)),p=Math.max(-8,Math.min(8,Math.floor(br(h)/3)))*3,g=Math.pow(10,-p),m=fd[8+p/3];return function(v){return f(g*v)+m}}return{format:c,formatPrefix:u}}var js,cl,pd;Ix({thousands:",",grouping:[3],currency:["$",""]});function Ix(e){return js=Rx(e),cl=js.format,pd=js.formatPrefix,js}function kx(e){return Math.max(0,-br(Math.abs(e)))}function Px(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(br(t)/3)))*3-br(Math.abs(e)))}function Nx(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,br(t)-br(e))+1}var St=1e-6,gd=1e-12,pt=Math.PI,he=pt/2,md=pt/4,Ee=pt*2,re=180/pt,$t=pt/180,Tt=Math.abs,vd=Math.atan,jn=Math.atan2,wt=Math.cos,$x=Math.exp,Fx=Math.log,bt=Math.sin,In=Math.sign||function(e){return e>0?1:e<0?-1:0},Fe=Math.sqrt,Ux=Math.tan;function Bx(e){return e>1?0:e<-1?pt:Math.acos(e)}function pn(e){return e>1?he:e<-1?-he:Math.asin(e)}function Oe(){}function Zs(e,t){e&&Ed.hasOwnProperty(e.type)&&Ed[e.type](e,t)}var yd={Feature:function(e,t){Zs(e.geometry,t)},FeatureCollection:function(e,t){for(var n=e.features,r=-1,i=n.length;++r<i;)Zs(n[r].geometry,t)}},Ed={Sphere:function(e,t){t.sphere()},Point:function(e,t){e=e.coordinates,t.point(e[0],e[1],e[2])},MultiPoint:function(e,t){for(var n=e.coordinates,r=-1,i=n.length;++r<i;)e=n[r],t.point(e[0],e[1],e[2])},LineString:function(e,t){ul(e.coordinates,t,0)},MultiLineString:function(e,t){for(var n=e.coordinates,r=-1,i=n.length;++r<i;)ul(n[r],t,0)},Polygon:function(e,t){xd(e.coordinates,t)},MultiPolygon:function(e,t){for(var n=e.coordinates,r=-1,i=n.length;++r<i;)xd(n[r],t)},GeometryCollection:function(e,t){for(var n=e.geometries,r=-1,i=n.length;++r<i;)Zs(n[r],t)}};function ul(e,t,n){var r=-1,i=e.length-n,s;for(t.lineStart();++r<i;)s=e[r],t.point(s[0],s[1],s[2]);t.lineEnd()}function xd(e,t){var n=-1,r=e.length;for(t.polygonStart();++n<r;)ul(e[n],t,1);t.polygonEnd()}function _r(e,t){e&&yd.hasOwnProperty(e.type)?yd[e.type](e,t):Zs(e,t)}function hl(e){return[jn(e[1],e[0]),pn(e[2])]}function Sr(e){var t=e[0],n=e[1],r=wt(n);return[r*wt(t),r*bt(t),bt(n)]}function Ks(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}function Qs(e,t){return[e[1]*t[2]-e[2]*t[1],e[2]*t[0]-e[0]*t[2],e[0]*t[1]-e[1]*t[0]]}function dl(e,t){e[0]+=t[0],e[1]+=t[1],e[2]+=t[2]}function Js(e,t){return[e[0]*t,e[1]*t,e[2]*t]}function fl(e){var t=Fe(e[0]*e[0]+e[1]*e[1]+e[2]*e[2]);e[0]/=t,e[1]/=t,e[2]/=t}function pl(e,t){function n(r,i){return r=e(r,i),t(r[0],r[1])}return e.invert&&t.invert&&(n.invert=function(r,i){return r=t.invert(r,i),r&&e.invert(r[0],r[1])}),n}function gl(e,t){return Tt(e)>pt&&(e-=Math.round(e/Ee)*Ee),[e,t]}gl.invert=gl;function bd(e,t,n){return(e%=Ee)?t||n?pl(Sd(e),Td(t,n)):Sd(e):t||n?Td(t,n):gl}function _d(e){return function(t,n){return t+=e,Tt(t)>pt&&(t-=Math.round(t/Ee)*Ee),[t,n]}}function Sd(e){var t=_d(e);return t.invert=_d(-e),t}function Td(e,t){var n=wt(e),r=bt(e),i=wt(t),s=bt(t);function a(o,l){var c=wt(l),u=wt(o)*c,d=bt(o)*c,h=bt(l),f=h*n+u*r;return[jn(d*i-f*s,u*n-h*r),pn(f*i+d*s)]}return a.invert=function(o,l){var c=wt(l),u=wt(o)*c,d=bt(o)*c,h=bt(l),f=h*i-d*s;return[jn(d*i+h*s,u*n+f*r),pn(f*n-u*r)]},a}function Hx(e){e=bd(e[0]*$t,e[1]*$t,e.length>2?e[2]*$t:0);function t(n){return n=e(n[0]*$t,n[1]*$t),n[0]*=re,n[1]*=re,n}return t.invert=function(n){return n=e.invert(n[0]*$t,n[1]*$t),n[0]*=re,n[1]*=re,n},t}function Gx(e,t,n,r,i,s){if(n){var a=wt(t),o=bt(t),l=r*n;i==null?(i=t+r*Ee,s=t-l/2):(i=Od(a,i),s=Od(a,s),(r>0?i<s:i>s)&&(i+=r*Ee));for(var c,u=i;r>0?u>s:u<s;u-=l)c=hl([a,-o*wt(u),-o*bt(u)]),e.point(c[0],c[1])}}function Od(e,t){t=Sr(t),t[0]-=e,fl(t);var n=Bx(-t[1]);return((-t[2]<0?-n:n)+Ee-St)%Ee}function wd(){var e=[],t;return{point:function(n,r,i){t.push([n,r,i])},lineStart:function(){e.push(t=[])},lineEnd:Oe,rejoin:function(){e.length>1&&e.push(e.pop().concat(e.shift()))},result:function(){var n=e;return e=[],t=null,n}}}function ta(e,t){return Tt(e[0]-t[0])<St&&Tt(e[1]-t[1])<St}function ea(e,t,n,r){this.x=e,this.z=t,this.o=n,this.e=r,this.v=!1,this.n=this.p=null}function Md(e,t,n,r,i){var s=[],a=[],o,l;if(e.forEach(function(p){if(!((g=p.length-1)<=0)){var g,m=p[0],v=p[g],E;if(ta(m,v)){if(!m[2]&&!v[2]){for(i.lineStart(),o=0;o<g;++o)i.point((m=p[o])[0],m[1]);i.lineEnd();return}v[0]+=2*St}s.push(E=new ea(m,p,null,!0)),a.push(E.o=new ea(m,null,E,!1)),s.push(E=new ea(v,p,null,!1)),a.push(E.o=new ea(v,null,E,!0))}}),!!s.length){for(a.sort(t),Ad(s),Ad(a),o=0,l=a.length;o<l;++o)a[o].e=n=!n;for(var c=s[0],u,d;;){for(var h=c,f=!0;h.v;)if((h=h.n)===c)return;u=h.z,i.lineStart();do{if(h.v=h.o.v=!0,h.e){if(f)for(o=0,l=u.length;o<l;++o)i.point((d=u[o])[0],d[1]);else r(h.x,h.n.x,1,i);h=h.n}else{if(f)for(u=h.p.z,o=u.length-1;o>=0;--o)i.point((d=u[o])[0],d[1]);else r(h.x,h.p.x,-1,i);h=h.p}h=h.o,u=h.z,f=!f}while(!h.v);i.lineEnd()}}}function Ad(e){if(t=e.length){for(var t,n=0,r=e[0],i;++n<t;)r.n=i=e[n],i.p=r,r=i;r.n=i=e[0],i.p=r}}function ml(e){return Tt(e[0])<=pt?e[0]:In(e[0])*((Tt(e[0])+pt)%Ee-pt)}function Vx(e,t){var n=ml(t),r=t[1],i=bt(r),s=[bt(n),-wt(n),0],a=0,o=0,l=new Gn;i===1?r=he+St:i===-1&&(r=-he-St);for(var c=0,u=e.length;c<u;++c)if(h=(d=e[c]).length)for(var d,h,f=d[h-1],p=ml(f),g=f[1]/2+md,m=bt(g),v=wt(g),E=0;E<h;++E,p=b,m=_,v=A,f=y){var y=d[E],b=ml(y),S=y[1]/2+md,_=bt(S),A=wt(S),R=b-p,B=R>=0?1:-1,D=B*R,O=D>pt,H=m*_;if(l.add(jn(H*B*bt(D),v*A+H*wt(D))),a+=O?R+B*Ee:R,O^p>=n^b>=n){var P=Qs(Sr(f),Sr(y));fl(P);var M=Qs(s,P);fl(M);var w=(O^R>=0?-1:1)*pn(M[2]);(r>w||r===w&&(P[0]||P[1]))&&(o+=O^R>=0?1:-1)}}return(a<-St||a<St&&l<-gd)^o&1}function Cd(e,t,n,r){return function(i){var s=t(i),a=wd(),o=t(a),l=!1,c,u,d,h={point:f,lineStart:g,lineEnd:m,polygonStart:function(){h.point=v,h.lineStart=E,h.lineEnd=y,u=[],c=[]},polygonEnd:function(){h.point=f,h.lineStart=g,h.lineEnd=m,u=ch(u);var b=Vx(c,r);u.length?(l||(i.polygonStart(),l=!0),Md(u,Wx,b,n,i)):b&&(l||(i.polygonStart(),l=!0),i.lineStart(),n(null,null,1,i),i.lineEnd()),l&&(i.polygonEnd(),l=!1),u=c=null},sphere:function(){i.polygonStart(),i.lineStart(),n(null,null,1,i),i.lineEnd(),i.polygonEnd()}};function f(b,S){e(b,S)&&i.point(b,S)}function p(b,S){s.point(b,S)}function g(){h.point=p,s.lineStart()}function m(){h.point=f,s.lineEnd()}function v(b,S){d.push([b,S]),o.point(b,S)}function E(){o.lineStart(),d=[]}function y(){v(d[0][0],d[0][1]),o.lineEnd();var b=o.clean(),S=a.result(),_,A=S.length,R,B,D;if(d.pop(),c.push(d),d=null,!!A){if(b&1){if(B=S[0],(R=B.length-1)>0){for(l||(i.polygonStart(),l=!0),i.lineStart(),_=0;_<R;++_)i.point((D=B[_])[0],D[1]);i.lineEnd()}return}A>1&&b&2&&S.push(S.pop().concat(S.shift())),u.push(S.filter(zx))}}return h}}function zx(e){return e.length>1}function Wx(e,t){return((e=e.x)[0]<0?e[1]-he-St:he-e[1])-((t=t.x)[0]<0?t[1]-he-St:he-t[1])}const Dd=Cd(function(){return!0},Yx,Xx,[-pt,-he]);function Yx(e){var t=NaN,n=NaN,r=NaN,i;return{lineStart:function(){e.lineStart(),i=1},point:function(s,a){var o=s>0?pt:-pt,l=Tt(s-t);Tt(l-pt)<St?(e.point(t,n=(n+a)/2>0?he:-he),e.point(r,n),e.lineEnd(),e.lineStart(),e.point(o,n),e.point(s,n),i=0):r!==o&&l>=pt&&(Tt(t-r)<St&&(t-=r*St),Tt(s-o)<St&&(s-=o*St),n=qx(t,n,s,a),e.point(r,n),e.lineEnd(),e.lineStart(),e.point(o,n),i=0),e.point(t=s,n=a),r=o},lineEnd:function(){e.lineEnd(),t=n=NaN},clean:function(){return 2-i}}}function qx(e,t,n,r){var i,s,a=bt(e-n);return Tt(a)>St?vd((bt(t)*(s=wt(r))*bt(n)-bt(r)*(i=wt(t))*bt(e))/(i*s*a)):(t+r)/2}function Xx(e,t,n,r){var i;if(e==null)i=n*he,r.point(-pt,i),r.point(0,i),r.point(pt,i),r.point(pt,0),r.point(pt,-i),r.point(0,-i),r.point(-pt,-i),r.point(-pt,0),r.point(-pt,i);else if(Tt(e[0]-t[0])>St){var s=e[0]<t[0]?pt:-pt;i=n*s/2,r.point(-s,i),r.point(0,i),r.point(s,i)}else r.point(t[0],t[1])}function jx(e){var t=wt(e),n=2*$t,r=t>0,i=Tt(t)>St;function s(u,d,h,f){Gx(f,e,n,h,u,d)}function a(u,d){return wt(u)*wt(d)>t}function o(u){var d,h,f,p,g;return{lineStart:function(){p=f=!1,g=1},point:function(m,v){var E=[m,v],y,b=a(m,v),S=r?b?0:c(m,v):b?c(m+(m<0?pt:-pt),v):0;if(!d&&(p=f=b)&&u.lineStart(),b!==f&&(y=l(d,E),(!y||ta(d,y)||ta(E,y))&&(E[2]=1)),b!==f)g=0,b?(u.lineStart(),y=l(E,d),u.point(y[0],y[1])):(y=l(d,E),u.point(y[0],y[1],2),u.lineEnd()),d=y;else if(i&&d&&r^b){var _;!(S&h)&&(_=l(E,d,!0))&&(g=0,r?(u.lineStart(),u.point(_[0][0],_[0][1]),u.point(_[1][0],_[1][1]),u.lineEnd()):(u.point(_[1][0],_[1][1]),u.lineEnd(),u.lineStart(),u.point(_[0][0],_[0][1],3)))}b&&(!d||!ta(d,E))&&u.point(E[0],E[1]),d=E,f=b,h=S},lineEnd:function(){f&&u.lineEnd(),d=null},clean:function(){return g|(p&&f)<<1}}}function l(u,d,h){var f=Sr(u),p=Sr(d),g=[1,0,0],m=Qs(f,p),v=Ks(m,m),E=m[0],y=v-E*E;if(!y)return!h&&u;var b=t*v/y,S=-t*E/y,_=Qs(g,m),A=Js(g,b),R=Js(m,S);dl(A,R);var B=_,D=Ks(A,B),O=Ks(B,B),H=D*D-O*(Ks(A,A)-1);if(!(H<0)){var P=Fe(H),M=Js(B,(-D-P)/O);if(dl(M,A),M=hl(M),!h)return M;var w=u[0],U=d[0],$=u[1],N=d[1],F;U<w&&(F=w,w=U,U=F);var Y=U-w,Z=Tt(Y-pt)<St,K=Z||Y<St;if(!Z&&N<$&&(F=$,$=N,N=F),K?Z?$+N>0^M[1]<(Tt(M[0]-w)<St?$:N):$<=M[1]&&M[1]<=N:Y>pt^(w<=M[0]&&M[0]<=U)){var dt=Js(B,(-D+P)/O);return dl(dt,A),[M,hl(dt)]}}}function c(u,d){var h=r?e:pt-e,f=0;return u<-h?f|=1:u>h&&(f|=2),d<-h?f|=4:d>h&&(f|=8),f}return Cd(a,o,s,r?[0,-e]:[-pt,e-pt])}function Zx(e,t,n,r,i,s){var a=e[0],o=e[1],l=t[0],c=t[1],u=0,d=1,h=l-a,f=c-o,p;if(p=n-a,!(!h&&p>0)){if(p/=h,h<0){if(p<u)return;p<d&&(d=p)}else if(h>0){if(p>d)return;p>u&&(u=p)}if(p=i-a,!(!h&&p<0)){if(p/=h,h<0){if(p>d)return;p>u&&(u=p)}else if(h>0){if(p<u)return;p<d&&(d=p)}if(p=r-o,!(!f&&p>0)){if(p/=f,f<0){if(p<u)return;p<d&&(d=p)}else if(f>0){if(p>d)return;p>u&&(u=p)}if(p=s-o,!(!f&&p<0)){if(p/=f,f<0){if(p>d)return;p>u&&(u=p)}else if(f>0){if(p<u)return;p<d&&(d=p)}return u>0&&(e[0]=a+u*h,e[1]=o+u*f),d<1&&(t[0]=a+d*h,t[1]=o+d*f),!0}}}}}var xi=1e9,na=-xi;function Kx(e,t,n,r){function i(c,u){return e<=c&&c<=n&&t<=u&&u<=r}function s(c,u,d,h){var f=0,p=0;if(c==null||(f=a(c,d))!==(p=a(u,d))||l(c,u)<0^d>0)do h.point(f===0||f===3?e:n,f>1?r:t);while((f=(f+d+4)%4)!==p);else h.point(u[0],u[1])}function a(c,u){return Tt(c[0]-e)<St?u>0?0:3:Tt(c[0]-n)<St?u>0?2:1:Tt(c[1]-t)<St?u>0?1:0:u>0?3:2}function o(c,u){return l(c.x,u.x)}function l(c,u){var d=a(c,1),h=a(u,1);return d!==h?d-h:d===0?u[1]-c[1]:d===1?c[0]-u[0]:d===2?c[1]-u[1]:u[0]-c[0]}return function(c){var u=c,d=wd(),h,f,p,g,m,v,E,y,b,S,_,A={point:R,lineStart:H,lineEnd:P,polygonStart:D,polygonEnd:O};function R(w,U){i(w,U)&&u.point(w,U)}function B(){for(var w=0,U=0,$=f.length;U<$;++U)for(var N=f[U],F=1,Y=N.length,Z=N[0],K,dt,it=Z[0],ft=Z[1];F<Y;++F)K=it,dt=ft,Z=N[F],it=Z[0],ft=Z[1],dt<=r?ft>r&&(it-K)*(r-dt)>(ft-dt)*(e-K)&&++w:ft<=r&&(it-K)*(r-dt)<(ft-dt)*(e-K)&&--w;return w}function D(){u=d,h=[],f=[],_=!0}function O(){var w=B(),U=_&&w,$=(h=ch(h)).length;(U||$)&&(c.polygonStart(),U&&(c.lineStart(),s(null,null,1,c),c.lineEnd()),$&&Md(h,o,w,s,c),c.polygonEnd()),u=c,h=f=p=null}function H(){A.point=M,f&&f.push(p=[]),S=!0,b=!1,E=y=NaN}function P(){h&&(M(g,m),v&&b&&d.rejoin(),h.push(d.result())),A.point=R,b&&u.lineEnd()}function M(w,U){var $=i(w,U);if(f&&p.push([w,U]),S)g=w,m=U,v=$,S=!1,$&&(u.lineStart(),u.point(w,U));else if($&&b)u.point(w,U);else{var N=[E=Math.max(na,Math.min(xi,E)),y=Math.max(na,Math.min(xi,y))],F=[w=Math.max(na,Math.min(xi,w)),U=Math.max(na,Math.min(xi,U))];Zx(N,F,e,t,n,r)?(b||(u.lineStart(),u.point(N[0],N[1])),u.point(F[0],F[1]),$||u.lineEnd(),_=!1):$&&(u.lineStart(),u.point(w,U),_=!1)}E=w,y=U,b=$}return A}}const vl=e=>e;var yl=new Gn,El=new Gn,Ld,Rd,xl,bl,gn={point:Oe,lineStart:Oe,lineEnd:Oe,polygonStart:function(){gn.lineStart=Qx,gn.lineEnd=tb},polygonEnd:function(){gn.lineStart=gn.lineEnd=gn.point=Oe,yl.add(Tt(El)),El=new Gn},result:function(){var e=yl/2;return yl=new Gn,e}};function Qx(){gn.point=Jx}function Jx(e,t){gn.point=Id,Ld=xl=e,Rd=bl=t}function Id(e,t){El.add(bl*e-xl*t),xl=e,bl=t}function tb(){Id(Ld,Rd)}var Tr=1/0,ra=Tr,bi=-Tr,ia=bi,sa={point:eb,lineStart:Oe,lineEnd:Oe,polygonStart:Oe,polygonEnd:Oe,result:function(){var e=[[Tr,ra],[bi,ia]];return bi=ia=-(ra=Tr=1/0),e}};function eb(e,t){e<Tr&&(Tr=e),e>bi&&(bi=e),t<ra&&(ra=t),t>ia&&(ia=t)}var _l=0,Sl=0,_i=0,aa=0,oa=0,Or=0,Tl=0,Ol=0,Si=0,kd,Pd,Ke,Qe,we={point:Zn,lineStart:Nd,lineEnd:$d,polygonStart:function(){we.lineStart=ib,we.lineEnd=sb},polygonEnd:function(){we.point=Zn,we.lineStart=Nd,we.lineEnd=$d},result:function(){var e=Si?[Tl/Si,Ol/Si]:Or?[aa/Or,oa/Or]:_i?[_l/_i,Sl/_i]:[NaN,NaN];return _l=Sl=_i=aa=oa=Or=Tl=Ol=Si=0,e}};function Zn(e,t){_l+=e,Sl+=t,++_i}function Nd(){we.point=nb}function nb(e,t){we.point=rb,Zn(Ke=e,Qe=t)}function rb(e,t){var n=e-Ke,r=t-Qe,i=Fe(n*n+r*r);aa+=i*(Ke+e)/2,oa+=i*(Qe+t)/2,Or+=i,Zn(Ke=e,Qe=t)}function $d(){we.point=Zn}function ib(){we.point=ab}function sb(){Fd(kd,Pd)}function ab(e,t){we.point=Fd,Zn(kd=Ke=e,Pd=Qe=t)}function Fd(e,t){var n=e-Ke,r=t-Qe,i=Fe(n*n+r*r);aa+=i*(Ke+e)/2,oa+=i*(Qe+t)/2,Or+=i,i=Qe*e-Ke*t,Tl+=i*(Ke+e),Ol+=i*(Qe+t),Si+=i*3,Zn(Ke=e,Qe=t)}function Ud(e){this._context=e}Ud.prototype={_radius:4.5,pointRadius:function(e){return this._radius=e,this},polygonStart:function(){this._line=0},polygonEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){this._line===0&&this._context.closePath(),this._point=NaN},point:function(e,t){switch(this._point){case 0:{this._context.moveTo(e,t),this._point=1;break}case 1:{this._context.lineTo(e,t);break}default:{this._context.moveTo(e+this._radius,t),this._context.arc(e,t,this._radius,0,Ee);break}}},result:Oe};var wl=new Gn,Ml,Bd,Hd,Ti,Oi,wi={point:Oe,lineStart:function(){wi.point=ob},lineEnd:function(){Ml&&Gd(Bd,Hd),wi.point=Oe},polygonStart:function(){Ml=!0},polygonEnd:function(){Ml=null},result:function(){var e=+wl;return wl=new Gn,e}};function ob(e,t){wi.point=Gd,Bd=Ti=e,Hd=Oi=t}function Gd(e,t){Ti-=e,Oi-=t,wl.add(Fe(Ti*Ti+Oi*Oi)),Ti=e,Oi=t}let Vd,la,zd,Wd;class Yd{constructor(t){this._append=t==null?qd:lb(t),this._radius=4.5,this._=""}pointRadius(t){return this._radius=+t,this}polygonStart(){this._line=0}polygonEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){this._line===0&&(this._+="Z"),this._point=NaN}point(t,n){switch(this._point){case 0:{this._append`M${t},${n}`,this._point=1;break}case 1:{this._append`L${t},${n}`;break}default:{if(this._append`M${t},${n}`,this._radius!==zd||this._append!==la){const r=this._radius,i=this._;this._="",this._append`m0,${r}a${r},${r} 0 1,1 0,${-2*r}a${r},${r} 0 1,1 0,${2*r}z`,zd=r,la=this._append,Wd=this._,this._=i}this._+=Wd;break}}}result(){const t=this._;return this._="",t.length?t:null}}function qd(e){let t=1;this._+=e[0];for(const n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function lb(e){const t=Math.floor(e);if(!(t>=0))throw new RangeError(`invalid digits: ${e}`);if(t>15)return qd;if(t!==Vd){const n=10**t;Vd=t,la=function(i){let s=1;this._+=i[0];for(const a=i.length;s<a;++s)this._+=Math.round(arguments[s]*n)/n+i[s]}}return la}function cb(e,t){let n=3,r=4.5,i,s;function a(o){return o&&(typeof r=="function"&&s.pointRadius(+r.apply(this,arguments)),_r(o,i(s))),s.result()}return a.area=function(o){return _r(o,i(gn)),gn.result()},a.measure=function(o){return _r(o,i(wi)),wi.result()},a.bounds=function(o){return _r(o,i(sa)),sa.result()},a.centroid=function(o){return _r(o,i(we)),we.result()},a.projection=function(o){return arguments.length?(i=o==null?(e=null,vl):(e=o).stream,a):e},a.context=function(o){return arguments.length?(s=o==null?(t=null,new Yd(n)):new Ud(t=o),typeof r!="function"&&s.pointRadius(r),a):t},a.pointRadius=function(o){return arguments.length?(r=typeof o=="function"?o:(s.pointRadius(+o),+o),a):r},a.digits=function(o){if(!arguments.length)return n;if(o==null)n=null;else{const l=Math.floor(o);if(!(l>=0))throw new RangeError(`invalid digits: ${o}`);n=l}return t===null&&(s=new Yd(n)),a},a.projection(e).digits(n).context(t)}function Al(e){return function(t){var n=new Cl;for(var r in e)n[r]=e[r];return n.stream=t,n}}function Cl(){}Cl.prototype={constructor:Cl,point:function(e,t){this.stream.point(e,t)},sphere:function(){this.stream.sphere()},lineStart:function(){this.stream.lineStart()},lineEnd:function(){this.stream.lineEnd()},polygonStart:function(){this.stream.polygonStart()},polygonEnd:function(){this.stream.polygonEnd()}};function Dl(e,t,n){var r=e.clipExtent&&e.clipExtent();return e.scale(150).translate([0,0]),r!=null&&e.clipExtent(null),_r(n,e.stream(sa)),t(sa.result()),r!=null&&e.clipExtent(r),e}function Xd(e,t,n){return Dl(e,function(r){var i=t[1][0]-t[0][0],s=t[1][1]-t[0][1],a=Math.min(i/(r[1][0]-r[0][0]),s/(r[1][1]-r[0][1])),o=+t[0][0]+(i-a*(r[1][0]+r[0][0]))/2,l=+t[0][1]+(s-a*(r[1][1]+r[0][1]))/2;e.scale(150*a).translate([o,l])},n)}function ub(e,t,n){return Xd(e,[[0,0],t],n)}function hb(e,t,n){return Dl(e,function(r){var i=+t,s=i/(r[1][0]-r[0][0]),a=(i-s*(r[1][0]+r[0][0]))/2,o=-s*r[0][1];e.scale(150*s).translate([a,o])},n)}function db(e,t,n){return Dl(e,function(r){var i=+t,s=i/(r[1][1]-r[0][1]),a=-s*r[0][0],o=(i-s*(r[1][1]+r[0][1]))/2;e.scale(150*s).translate([a,o])},n)}var jd=16,fb=wt(30*$t);function Zd(e,t){return+t?gb(e,t):pb(e)}function pb(e){return Al({point:function(t,n){t=e(t,n),this.stream.point(t[0],t[1])}})}function gb(e,t){function n(r,i,s,a,o,l,c,u,d,h,f,p,g,m){var v=c-r,E=u-i,y=v*v+E*E;if(y>4*t&&g--){var b=a+h,S=o+f,_=l+p,A=Fe(b*b+S*S+_*_),R=pn(_/=A),B=Tt(Tt(_)-1)<St||Tt(s-d)<St?(s+d)/2:jn(S,b),D=e(B,R),O=D[0],H=D[1],P=O-r,M=H-i,w=E*P-v*M;(w*w/y>t||Tt((v*P+E*M)/y-.5)>.3||a*h+o*f+l*p<fb)&&(n(r,i,s,a,o,l,O,H,B,b/=A,S/=A,_,g,m),m.point(O,H),n(O,H,B,b,S,_,c,u,d,h,f,p,g,m))}}return function(r){var i,s,a,o,l,c,u,d,h,f,p,g,m={point:v,lineStart:E,lineEnd:b,polygonStart:function(){r.polygonStart(),m.lineStart=S},polygonEnd:function(){r.polygonEnd(),m.lineStart=E}};function v(R,B){R=e(R,B),r.point(R[0],R[1])}function E(){d=NaN,m.point=y,r.lineStart()}function y(R,B){var D=Sr([R,B]),O=e(R,B);n(d,h,u,f,p,g,d=O[0],h=O[1],u=R,f=D[0],p=D[1],g=D[2],jd,r),r.point(d,h)}function b(){m.point=v,r.lineEnd()}function S(){E(),m.point=_,m.lineEnd=A}function _(R,B){y(i=R,B),s=d,a=h,o=f,l=p,c=g,m.point=y}function A(){n(d,h,u,f,p,g,s,a,i,o,l,c,jd,r),m.lineEnd=b,b()}return m}}var mb=Al({point:function(e,t){this.stream.point(e*$t,t*$t)}});function vb(e){return Al({point:function(t,n){var r=e(t,n);return this.stream.point(r[0],r[1])}})}function yb(e,t,n,r,i){function s(a,o){return a*=r,o*=i,[t+e*a,n-e*o]}return s.invert=function(a,o){return[(a-t)/e*r,(n-o)/e*i]},s}function Kd(e,t,n,r,i,s){if(!s)return yb(e,t,n,r,i);var a=wt(s),o=bt(s),l=a*e,c=o*e,u=a/e,d=o/e,h=(o*n-a*t)/e,f=(o*t+a*n)/e;function p(g,m){return g*=r,m*=i,[l*g-c*m+t,n-c*g-l*m]}return p.invert=function(g,m){return[r*(u*g-d*m+h),i*(f-d*g-u*m)]},p}function ca(e){return Qd(function(){return e})()}function Qd(e){var t,n=150,r=480,i=250,s=0,a=0,o=0,l=0,c=0,u,d=0,h=1,f=1,p=null,g=Dd,m=null,v,E,y,b=vl,S=.5,_,A,R,B,D;function O(w){return R(w[0]*$t,w[1]*$t)}function H(w){return w=R.invert(w[0],w[1]),w&&[w[0]*re,w[1]*re]}O.stream=function(w){return B&&D===w?B:B=mb(vb(u)(g(_(b(D=w)))))},O.preclip=function(w){return arguments.length?(g=w,p=void 0,M()):g},O.postclip=function(w){return arguments.length?(b=w,m=v=E=y=null,M()):b},O.clipAngle=function(w){return arguments.length?(g=+w?jx(p=w*$t):(p=null,Dd),M()):p*re},O.clipExtent=function(w){return arguments.length?(b=w==null?(m=v=E=y=null,vl):Kx(m=+w[0][0],v=+w[0][1],E=+w[1][0],y=+w[1][1]),M()):m==null?null:[[m,v],[E,y]]},O.scale=function(w){return arguments.length?(n=+w,P()):n},O.translate=function(w){return arguments.length?(r=+w[0],i=+w[1],P()):[r,i]},O.center=function(w){return arguments.length?(s=w[0]%360*$t,a=w[1]%360*$t,P()):[s*re,a*re]},O.rotate=function(w){return arguments.length?(o=w[0]%360*$t,l=w[1]%360*$t,c=w.length>2?w[2]%360*$t:0,P()):[o*re,l*re,c*re]},O.angle=function(w){return arguments.length?(d=w%360*$t,P()):d*re},O.reflectX=function(w){return arguments.length?(h=w?-1:1,P()):h<0},O.reflectY=function(w){return arguments.length?(f=w?-1:1,P()):f<0},O.precision=function(w){return arguments.length?(_=Zd(A,S=w*w),M()):Fe(S)},O.fitExtent=function(w,U){return Xd(O,w,U)},O.fitSize=function(w,U){return ub(O,w,U)},O.fitWidth=function(w,U){return hb(O,w,U)},O.fitHeight=function(w,U){return db(O,w,U)};function P(){var w=Kd(n,0,0,h,f,d).apply(null,t(s,a)),U=Kd(n,r-w[0],i-w[1],h,f,d);return u=bd(o,l,c),A=pl(t,U),R=pl(u,A),_=Zd(A,S),M()}function M(){return B=D=null,O}return function(){return t=e.apply(this,arguments),O.invert=t.invert&&H,P()}}function Jd(e){var t=0,n=pt/3,r=Qd(e),i=r(t,n);return i.parallels=function(s){return arguments.length?r(t=s[0]*$t,n=s[1]*$t):[t*re,n*re]},i}function Eb(e){var t=wt(e);function n(r,i){return[r*t,bt(i)/t]}return n.invert=function(r,i){return[r/t,pn(i*t)]},n}function xb(e,t){var n=bt(e),r=(n+bt(t))/2;if(Tt(r)<St)return Eb(e);var i=1+n*(2*r-n),s=Fe(i)/r;function a(o,l){var c=Fe(i-2*r*bt(l))/r;return[c*bt(o*=r),s-c*wt(o)]}return a.invert=function(o,l){var c=s-l,u=jn(o,Tt(c))*In(c);return c*r<0&&(u-=pt*In(o)*In(c)),[u/r,pn((i-(o*o+c*c)*r*r)/(2*r))]},a}function tf(){return Jd(xb).scale(155.424).center([0,33.6442])}function bb(){return tf().parallels([29.5,45.5]).scale(1070).translate([480,250]).rotate([96,0]).center([-.6,38.7])}function Ll(e,t){return[e,Fx(Ux((he+t)/2))]}Ll.invert=function(e,t){return[e,2*vd($x(t))-he]};function _b(){return Sb(Ll).scale(961/Ee)}function Sb(e){var t=ca(e),n=t.center,r=t.scale,i=t.translate,s=t.clipExtent,a=null,o,l,c;t.scale=function(d){return arguments.length?(r(d),u()):r()},t.translate=function(d){return arguments.length?(i(d),u()):i()},t.center=function(d){return arguments.length?(n(d),u()):n()},t.clipExtent=function(d){return arguments.length?(d==null?a=o=l=c=null:(a=+d[0][0],o=+d[0][1],l=+d[1][0],c=+d[1][1]),u()):a==null?null:[[a,o],[l,c]]};function u(){var d=pt*r(),h=t(Hx(t.rotate()).invert([0,0]));return s(a==null?[[h[0]-d,h[1]-d],[h[0]+d,h[1]+d]]:e===Ll?[[Math.max(h[0]-d,a),o],[Math.min(h[0]+d,l),c]]:[[a,Math.max(h[1]-d,o)],[l,Math.min(h[1]+d,c)]])}return u()}function ua(e,t){return[e,t]}ua.invert=ua;function Tb(){return ca(ua).scale(152.63)}function Ob(e,t){var n=wt(e),r=e===t?bt(e):(n-wt(t))/(t-e),i=n/r+e;if(Tt(r)<St)return ua;function s(a,o){var l=i-o,c=r*a;return[l*bt(c),i-l*wt(c)]}return s.invert=function(a,o){var l=i-o,c=jn(a,Tt(l))*In(l);return l*r<0&&(c-=pt*In(a)*In(l)),[c/r,i-In(r)*Fe(a*a+l*l)]},s}function wb(){return Jd(Ob).scale(131.154).center([0,13.9389])}var Mi=1.340264,Ai=-.081106,Ci=893e-6,Di=.003796,ha=Fe(3)/2,Mb=12;function ef(e,t){var n=pn(ha*bt(t)),r=n*n,i=r*r*r;return[e*wt(n)/(ha*(Mi+3*Ai*r+i*(7*Ci+9*Di*r))),n*(Mi+Ai*r+i*(Ci+Di*r))]}ef.invert=function(e,t){for(var n=t,r=n*n,i=r*r*r,s=0,a,o,l;s<Mb&&(o=n*(Mi+Ai*r+i*(Ci+Di*r))-t,l=Mi+3*Ai*r+i*(7*Ci+9*Di*r),n-=a=o/l,r=n*n,i=r*r*r,!(Tt(a)<gd));++s);return[ha*e*(Mi+3*Ai*r+i*(7*Ci+9*Di*r))/wt(n),pn(bt(n)/ha)]};function Ab(){return ca(ef).scale(177.158)}function nf(e,t){var n=t*t,r=n*n;return[e*(.8707-.131979*n+r*(-.013791+r*(.003971*n-.001529*r))),t*(1.007226+n*(.015085+r*(-.044475+.028874*n-.005916*r)))]}nf.invert=function(e,t){var n=t,r=25,i;do{var s=n*n,a=s*s;n-=i=(n*(1.007226+s*(.015085+a*(-.044475+.028874*s-.005916*a)))-t)/(1.007226+s*(.015085*3+a*(-.044475*7+.028874*9*s-.005916*11*a)))}while(Tt(i)>St&&--r>0);return[e/(.8707+(s=n*n)*(-.131979+s*(-.013791+s*s*s*(.003971-.001529*s)))),n]};function Cb(){return ca(nf).scale(175.295)}function Db(e,t){return e.parent===t.parent?1:2}function Lb(e){return e.reduce(Rb,0)/e.length}function Rb(e,t){return e+t.x}function Ib(e){return 1+e.reduce(kb,0)}function kb(e,t){return Math.max(e,t.y)}function Pb(e){for(var t;t=e.children;)e=t[0];return e}function Nb(e){for(var t;t=e.children;)e=t[t.length-1];return e}function $b(){var e=Db,t=1,n=1,r=!1;function i(s){var a,o=0;s.eachAfter(function(h){var f=h.children;f?(h.x=Lb(f),h.y=Ib(f)):(h.x=a?o+=e(h,a):0,h.y=0,a=h)});var l=Pb(s),c=Nb(s),u=l.x-e(l,c)/2,d=c.x+e(c,l)/2;return s.eachAfter(r?function(h){h.x=(h.x-s.x)*t,h.y=(s.y-h.y)*n}:function(h){h.x=(h.x-u)/(d-u)*t,h.y=(1-(s.y?h.y/s.y:1))*n})}return i.separation=function(s){return arguments.length?(e=s,i):e},i.size=function(s){return arguments.length?(r=!1,t=+s[0],n=+s[1],i):r?null:[t,n]},i.nodeSize=function(s){return arguments.length?(r=!0,t=+s[0],n=+s[1],i):r?[t,n]:null},i}function Fb(e){var t=0,n=e.children,r=n&&n.length;if(!r)t=1;else for(;--r>=0;)t+=n[r].value;e.value=t}function Ub(){return this.eachAfter(Fb)}function Bb(e,t){let n=-1;for(const r of this)e.call(t,r,++n,this);return this}function Hb(e,t){for(var n=this,r=[n],i,s,a=-1;n=r.pop();)if(e.call(t,n,++a,this),i=n.children)for(s=i.length-1;s>=0;--s)r.push(i[s]);return this}function Gb(e,t){for(var n=this,r=[n],i=[],s,a,o,l=-1;n=r.pop();)if(i.push(n),s=n.children)for(a=0,o=s.length;a<o;++a)r.push(s[a]);for(;n=i.pop();)e.call(t,n,++l,this);return this}function Vb(e,t){let n=-1;for(const r of this)if(e.call(t,r,++n,this))return r}function zb(e){return this.eachAfter(function(t){for(var n=+e(t.data)||0,r=t.children,i=r&&r.length;--i>=0;)n+=r[i].value;t.value=n})}function Wb(e){return this.eachBefore(function(t){t.children&&t.children.sort(e)})}function Yb(e){for(var t=this,n=qb(t,e),r=[t];t!==n;)t=t.parent,r.push(t);for(var i=r.length;e!==n;)r.splice(i,0,e),e=e.parent;return r}function qb(e,t){if(e===t)return e;var n=e.ancestors(),r=t.ancestors(),i=null;for(e=n.pop(),t=r.pop();e===t;)i=e,e=n.pop(),t=r.pop();return i}function Xb(){for(var e=this,t=[e];e=e.parent;)t.push(e);return t}function jb(){return Array.from(this)}function Zb(){var e=[];return this.eachBefore(function(t){t.children||e.push(t)}),e}function Kb(){var e=this,t=[];return e.each(function(n){n!==e&&t.push({source:n.parent,target:n})}),t}function*Qb(){var e=this,t,n=[e],r,i,s;do for(t=n.reverse(),n=[];e=t.pop();)if(yield e,r=e.children)for(i=0,s=r.length;i<s;++i)n.push(r[i]);while(n.length)}function Li(e,t){e instanceof Map?(e=[void 0,e],t===void 0&&(t=e_)):t===void 0&&(t=t_);for(var n=new Ri(e),r,i=[n],s,a,o,l;r=i.pop();)if((a=t(r.data))&&(l=(a=Array.from(a)).length))for(r.children=a,o=l-1;o>=0;--o)i.push(s=a[o]=new Ri(a[o])),s.parent=r,s.depth=r.depth+1;return n.eachBefore(r_)}function Jb(){return Li(this).eachBefore(n_)}function t_(e){return e.children}function e_(e){return Array.isArray(e)?e[1]:null}function n_(e){e.data.value!==void 0&&(e.value=e.data.value),e.data=e.data.data}function r_(e){var t=0;do e.height=t;while((e=e.parent)&&e.height<++t)}function Ri(e){this.data=e,this.depth=this.height=0,this.parent=null}Ri.prototype=Li.prototype={constructor:Ri,count:Ub,each:Bb,eachAfter:Gb,eachBefore:Hb,find:Vb,sum:zb,sort:Wb,path:Yb,ancestors:Xb,descendants:jb,leaves:Zb,links:Kb,copy:Jb,[Symbol.iterator]:Qb};function i_(e){return e==null?null:rf(e)}function rf(e){if(typeof e!="function")throw new Error;return e}function Kn(){return 0}function wr(e){return function(){return e}}const s_=1664525,a_=1013904223,sf=4294967296;function o_(){let e=1;return()=>(e=(s_*e+a_)%sf)/sf}function l_(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function c_(e,t){let n=e.length,r,i;for(;n;)i=t()*n--|0,r=e[n],e[n]=e[i],e[i]=r;return e}function u_(e,t){for(var n=0,r=(e=c_(Array.from(e),t)).length,i=[],s,a;n<r;)s=e[n],a&&af(a,s)?++n:(a=d_(i=h_(i,s)),n=0);return a}function h_(e,t){var n,r;if(Rl(t,e))return[t];for(n=0;n<e.length;++n)if(da(t,e[n])&&Rl(Ii(e[n],t),e))return[e[n],t];for(n=0;n<e.length-1;++n)for(r=n+1;r<e.length;++r)if(da(Ii(e[n],e[r]),t)&&da(Ii(e[n],t),e[r])&&da(Ii(e[r],t),e[n])&&Rl(of(e[n],e[r],t),e))return[e[n],e[r],t];throw new Error}function da(e,t){var n=e.r-t.r,r=t.x-e.x,i=t.y-e.y;return n<0||n*n<r*r+i*i}function af(e,t){var n=e.r-t.r+Math.max(e.r,t.r,1)*1e-9,r=t.x-e.x,i=t.y-e.y;return n>0&&n*n>r*r+i*i}function Rl(e,t){for(var n=0;n<t.length;++n)if(!af(e,t[n]))return!1;return!0}function d_(e){switch(e.length){case 1:return f_(e[0]);case 2:return Ii(e[0],e[1]);case 3:return of(e[0],e[1],e[2])}}function f_(e){return{x:e.x,y:e.y,r:e.r}}function Ii(e,t){var n=e.x,r=e.y,i=e.r,s=t.x,a=t.y,o=t.r,l=s-n,c=a-r,u=o-i,d=Math.sqrt(l*l+c*c);return{x:(n+s+l/d*u)/2,y:(r+a+c/d*u)/2,r:(d+i+o)/2}}function of(e,t,n){var r=e.x,i=e.y,s=e.r,a=t.x,o=t.y,l=t.r,c=n.x,u=n.y,d=n.r,h=r-a,f=r-c,p=i-o,g=i-u,m=l-s,v=d-s,E=r*r+i*i-s*s,y=E-a*a-o*o+l*l,b=E-c*c-u*u+d*d,S=f*p-h*g,_=(p*b-g*y)/(S*2)-r,A=(g*m-p*v)/S,R=(f*y-h*b)/(S*2)-i,B=(h*v-f*m)/S,D=A*A+B*B-1,O=2*(s+_*A+R*B),H=_*_+R*R-s*s,P=-(Math.abs(D)>1e-6?(O+Math.sqrt(O*O-4*D*H))/(2*D):H/O);return{x:r+_+A*P,y:i+R+B*P,r:P}}function lf(e,t,n){var r=e.x-t.x,i,s,a=e.y-t.y,o,l,c=r*r+a*a;c?(s=t.r+n.r,s*=s,l=e.r+n.r,l*=l,s>l?(i=(c+l-s)/(2*c),o=Math.sqrt(Math.max(0,l/c-i*i)),n.x=e.x-i*r-o*a,n.y=e.y-i*a+o*r):(i=(c+s-l)/(2*c),o=Math.sqrt(Math.max(0,s/c-i*i)),n.x=t.x+i*r-o*a,n.y=t.y+i*a+o*r)):(n.x=t.x+n.r,n.y=t.y)}function cf(e,t){var n=e.r+t.r-1e-6,r=t.x-e.x,i=t.y-e.y;return n>0&&n*n>r*r+i*i}function uf(e){var t=e._,n=e.next._,r=t.r+n.r,i=(t.x*n.r+n.x*t.r)/r,s=(t.y*n.r+n.y*t.r)/r;return i*i+s*s}function fa(e){this._=e,this.next=null,this.previous=null}function p_(e,t){if(!(s=(e=l_(e)).length))return 0;var n,r,i,s,a,o,l,c,u,d,h;if(n=e[0],n.x=0,n.y=0,!(s>1))return n.r;if(r=e[1],n.x=-r.r,r.x=n.r,r.y=0,!(s>2))return n.r+r.r;lf(r,n,i=e[2]),n=new fa(n),r=new fa(r),i=new fa(i),n.next=i.previous=r,r.next=n.previous=i,i.next=r.previous=n;t:for(l=3;l<s;++l){lf(n._,r._,i=e[l]),i=new fa(i),c=r.next,u=n.previous,d=r._.r,h=n._.r;do if(d<=h){if(cf(c._,i._)){r=c,n.next=r,r.previous=n,--l;continue t}d+=c._.r,c=c.next}else{if(cf(u._,i._)){n=u,n.next=r,r.previous=n,--l;continue t}h+=u._.r,u=u.previous}while(c!==u.next);for(i.previous=n,i.next=r,n.next=r.previous=r=i,a=uf(n);(i=i.next)!==r;)(o=uf(i))<a&&(n=i,a=o);r=n.next}for(n=[r._],i=r;(i=i.next)!==r;)n.push(i._);for(i=u_(n,t),l=0;l<s;++l)n=e[l],n.x-=i.x,n.y-=i.y;return i.r}function g_(e){return Math.sqrt(e.value)}function m_(){var e=null,t=1,n=1,r=Kn;function i(s){const a=o_();return s.x=t/2,s.y=n/2,e?s.eachBefore(hf(e)).eachAfter(Il(r,.5,a)).eachBefore(df(1)):s.eachBefore(hf(g_)).eachAfter(Il(Kn,1,a)).eachAfter(Il(r,s.r/Math.min(t,n),a)).eachBefore(df(Math.min(t,n)/(2*s.r))),s}return i.radius=function(s){return arguments.length?(e=i_(s),i):e},i.size=function(s){return arguments.length?(t=+s[0],n=+s[1],i):[t,n]},i.padding=function(s){return arguments.length?(r=typeof s=="function"?s:wr(+s),i):r},i}function hf(e){return function(t){t.children||(t.r=Math.max(0,+e(t)||0))}}function Il(e,t,n){return function(r){if(i=r.children){var i,s,a=i.length,o=e(r)*t||0,l;if(o)for(s=0;s<a;++s)i[s].r+=o;if(l=p_(i,n),o)for(s=0;s<a;++s)i[s].r-=o;r.r=l+o}}}function df(e){return function(t){var n=t.parent;t.r*=e,n&&(t.x=n.x+e*t.x,t.y=n.y+e*t.y)}}function v_(e){e.x0=Math.round(e.x0),e.y0=Math.round(e.y0),e.x1=Math.round(e.x1),e.y1=Math.round(e.y1)}function y_(e,t,n,r,i){for(var s=e.children,a,o=-1,l=s.length,c=e.value&&(r-t)/e.value;++o<l;)a=s[o],a.y0=n,a.y1=i,a.x0=t,a.x1=t+=a.value*c}function E_(e,t){return e.parent===t.parent?1:2}function kl(e){var t=e.children;return t?t[0]:e.t}function Pl(e){var t=e.children;return t?t[t.length-1]:e.t}function x_(e,t,n){var r=n/(t.i-e.i);t.c-=r,t.s+=n,e.c+=r,t.z+=n,t.m+=n}function b_(e){for(var t=0,n=0,r=e.children,i=r.length,s;--i>=0;)s=r[i],s.z+=t,s.m+=t,t+=s.s+(n+=s.c)}function __(e,t,n){return e.a.parent===t.parent?e.a:n}function pa(e,t){this._=e,this.parent=null,this.children=null,this.A=null,this.a=this,this.z=0,this.m=0,this.c=0,this.s=0,this.t=null,this.i=t}pa.prototype=Object.create(Ri.prototype);function S_(e){for(var t=new pa(e,0),n,r=[t],i,s,a,o;n=r.pop();)if(s=n._.children)for(n.children=new Array(o=s.length),a=o-1;a>=0;--a)r.push(i=n.children[a]=new pa(s[a],a)),i.parent=n;return(t.parent=new pa(null,0)).children=[t],t}function T_(){var e=E_,t=1,n=1,r=null;function i(c){var u=S_(c);if(u.eachAfter(s),u.parent.m=-u.z,u.eachBefore(a),r)c.eachBefore(l);else{var d=c,h=c,f=c;c.eachBefore(function(E){E.x<d.x&&(d=E),E.x>h.x&&(h=E),E.depth>f.depth&&(f=E)});var p=d===h?1:e(d,h)/2,g=p-d.x,m=t/(h.x+p+g),v=n/(f.depth||1);c.eachBefore(function(E){E.x=(E.x+g)*m,E.y=E.depth*v})}return c}function s(c){var u=c.children,d=c.parent.children,h=c.i?d[c.i-1]:null;if(u){b_(c);var f=(u[0].z+u[u.length-1].z)/2;h?(c.z=h.z+e(c._,h._),c.m=c.z-f):c.z=f}else h&&(c.z=h.z+e(c._,h._));c.parent.A=o(c,h,c.parent.A||d[0])}function a(c){c._.x=c.z+c.parent.m,c.m+=c.parent.m}function o(c,u,d){if(u){for(var h=c,f=c,p=u,g=h.parent.children[0],m=h.m,v=f.m,E=p.m,y=g.m,b;p=Pl(p),h=kl(h),p&&h;)g=kl(g),f=Pl(f),f.a=c,b=p.z+E-h.z-m+e(p._,h._),b>0&&(x_(__(p,c,d),c,b),m+=b,v+=b),E+=p.m,m+=h.m,y+=g.m,v+=f.m;p&&!Pl(f)&&(f.t=p,f.m+=E-v),h&&!kl(g)&&(g.t=h,g.m+=m-y,d=c)}return d}function l(c){c.x*=t,c.y=c.depth*n}return i.separation=function(c){return arguments.length?(e=c,i):e},i.size=function(c){return arguments.length?(r=!1,t=+c[0],n=+c[1],i):r?null:[t,n]},i.nodeSize=function(c){return arguments.length?(r=!0,t=+c[0],n=+c[1],i):r?[t,n]:null},i}function O_(e,t,n,r,i){for(var s=e.children,a,o=-1,l=s.length,c=e.value&&(i-n)/e.value;++o<l;)a=s[o],a.x0=t,a.x1=r,a.y0=n,a.y1=n+=a.value*c}var w_=(1+Math.sqrt(5))/2;function M_(e,t,n,r,i,s){for(var a=[],o=t.children,l,c,u=0,d=0,h=o.length,f,p,g=t.value,m,v,E,y,b,S,_;u<h;){f=i-n,p=s-r;do m=o[d++].value;while(!m&&d<h);for(v=E=m,S=Math.max(p/f,f/p)/(g*e),_=m*m*S,b=Math.max(E/_,_/v);d<h;++d){if(m+=c=o[d].value,c<v&&(v=c),c>E&&(E=c),_=m*m*S,y=Math.max(E/_,_/v),y>b){m-=c;break}b=y}a.push(l={value:m,dice:f<p,children:o.slice(u,d)}),l.dice?y_(l,n,r,i,g?r+=p*m/g:s):O_(l,n,r,g?n+=f*m/g:i,s),g-=m,u=d}return a}const A_=function e(t){function n(r,i,s,a,o){M_(t,r,i,s,a,o)}return n.ratio=function(r){return e((r=+r)>1?r:1)},n}(w_);function C_(){var e=A_,t=!1,n=1,r=1,i=[0],s=Kn,a=Kn,o=Kn,l=Kn,c=Kn;function u(h){return h.x0=h.y0=0,h.x1=n,h.y1=r,h.eachBefore(d),i=[0],t&&h.eachBefore(v_),h}function d(h){var f=i[h.depth],p=h.x0+f,g=h.y0+f,m=h.x1-f,v=h.y1-f;m<p&&(p=m=(p+m)/2),v<g&&(g=v=(g+v)/2),h.x0=p,h.y0=g,h.x1=m,h.y1=v,h.children&&(f=i[h.depth+1]=s(h)/2,p+=c(h)-f,g+=a(h)-f,m-=o(h)-f,v-=l(h)-f,m<p&&(p=m=(p+m)/2),v<g&&(g=v=(g+v)/2),e(h,p,g,m,v))}return u.round=function(h){return arguments.length?(t=!!h,u):t},u.size=function(h){return arguments.length?(n=+h[0],r=+h[1],u):[n,r]},u.tile=function(h){return arguments.length?(e=rf(h),u):e},u.padding=function(h){return arguments.length?u.paddingInner(h).paddingOuter(h):u.paddingInner()},u.paddingInner=function(h){return arguments.length?(s=typeof h=="function"?h:wr(+h),u):s},u.paddingOuter=function(h){return arguments.length?u.paddingTop(h).paddingRight(h).paddingBottom(h).paddingLeft(h):u.paddingTop()},u.paddingTop=function(h){return arguments.length?(a=typeof h=="function"?h:wr(+h),u):a},u.paddingRight=function(h){return arguments.length?(o=typeof h=="function"?h:wr(+h),u):o},u.paddingBottom=function(h){return arguments.length?(l=typeof h=="function"?h:wr(+h),u):l},u.paddingLeft=function(h){return arguments.length?(c=typeof h=="function"?h:wr(+h),u):c},u}function Mr(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}const ff=Symbol("implicit");function ga(){var e=new sh,t=[],n=[],r=ff;function i(s){let a=e.get(s);if(a===void 0){if(r!==ff)return r;e.set(s,a=t.push(s)-1)}return n[a%n.length]}return i.domain=function(s){if(!arguments.length)return t.slice();t=[],e=new sh;for(const a of s)e.has(a)||e.set(a,t.push(a)-1);return i},i.range=function(s){return arguments.length?(n=Array.from(s),i):n.slice()},i.unknown=function(s){return arguments.length?(r=s,i):r},i.copy=function(){return ga(t,n).unknown(r)},Mr.apply(i,arguments),i}function ki(){var e=ga().unknown(void 0),t=e.domain,n=e.range,r=0,i=1,s,a,o=!1,l=0,c=0,u=.5;delete e.unknown;function d(){var h=t().length,f=i<r,p=f?i:r,g=f?r:i;s=(g-p)/Math.max(1,h-l+c*2),o&&(s=Math.floor(s)),p+=(g-p-s*(h-l))*u,a=s*(1-l),o&&(p=Math.round(p),a=Math.round(a));var m=F0(h).map(function(v){return p+s*v});return n(f?m.reverse():m)}return e.domain=function(h){return arguments.length?(t(h),d()):t()},e.range=function(h){return arguments.length?([r,i]=h,r=+r,i=+i,d()):[r,i]},e.rangeRound=function(h){return[r,i]=h,r=+r,i=+i,o=!0,d()},e.bandwidth=function(){return a},e.step=function(){return s},e.round=function(h){return arguments.length?(o=!!h,d()):o},e.padding=function(h){return arguments.length?(l=Math.min(1,c=+h),d()):l},e.paddingInner=function(h){return arguments.length?(l=Math.min(1,h),d()):l},e.paddingOuter=function(h){return arguments.length?(c=+h,d()):c},e.align=function(h){return arguments.length?(u=Math.max(0,Math.min(1,h)),d()):u},e.copy=function(){return ki(t(),[r,i]).round(o).paddingInner(l).paddingOuter(c).align(u)},Mr.apply(d(),arguments)}function D_(e){return function(){return e}}function L_(e){return+e}var pf=[0,1];function Ar(e){return e}function Nl(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:D_(isNaN(t)?NaN:.5)}function R_(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function I_(e,t,n){var r=e[0],i=e[1],s=t[0],a=t[1];return i<r?(r=Nl(i,r),s=n(a,s)):(r=Nl(r,i),s=n(s,a)),function(o){return s(r(o))}}function k_(e,t,n){var r=Math.min(e.length,t.length)-1,i=new Array(r),s=new Array(r),a=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++a<r;)i[a]=Nl(e[a],e[a+1]),s[a]=n(t[a],t[a+1]);return function(o){var l=Ao(e,o,1,r)-1;return s[l](i[l](o))}}function $l(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function gf(){var e=pf,t=pf,n=pi,r,i,s,a=Ar,o,l,c;function u(){var h=Math.min(e.length,t.length);return a!==Ar&&(a=R_(e[0],e[h-1])),o=h>2?k_:I_,l=c=null,d}function d(h){return h==null||isNaN(h=+h)?s:(l||(l=o(e.map(r),t,n)))(r(a(h)))}return d.invert=function(h){return a(i((c||(c=o(t,e.map(r),ye)))(h)))},d.domain=function(h){return arguments.length?(e=Array.from(h,L_),u()):e.slice()},d.range=function(h){return arguments.length?(t=Array.from(h),u()):t.slice()},d.rangeRound=function(h){return t=Array.from(h),n=Fh,u()},d.clamp=function(h){return arguments.length?(a=h?!0:Ar,u()):a!==Ar},d.interpolate=function(h){return arguments.length?(n=h,u()):n},d.unknown=function(h){return arguments.length?(s=h,d):s},function(h,f){return r=h,i=f,u()}}function mf(){return gf()(Ar,Ar)}function P_(e,t,n,r){var i=Do(e,t,n),s;switch(r=Ei(r??",f"),r.type){case"s":{var a=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(s=Px(i,a))&&(r.precision=s),pd(r,a)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(s=Nx(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=s-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(s=kx(i))&&(r.precision=s-(r.type==="%")*2);break}}return cl(r)}function vf(e){var t=e.domain;return e.ticks=function(n){var r=t();return ws(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var i=t();return P_(i[0],i[i.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),i=0,s=r.length-1,a=r[i],o=r[s],l,c,u=10;for(o<a&&(c=a,a=o,o=c,c=i,i=s,s=c);u-- >0;){if(c=gr(a,o,n),c===l)return r[i]=a,r[s]=o,t(r);if(c>0)a=Math.floor(a/c)*c,o=Math.ceil(o/c)*c;else if(c<0)a=Math.ceil(a*c)/c,o=Math.floor(o*c)/c;else break;l=c}return e},e}function Ue(){var e=mf();return e.copy=function(){return $l(e,Ue())},Mr.apply(e,arguments),vf(e)}function yf(e,t){e=e.slice();var n=0,r=e.length-1,i=e[n],s=e[r],a;return s<i&&(a=n,n=r,r=a,a=i,i=s,s=a),e[n]=t.floor(i),e[r]=t.ceil(s),e}function Ef(e){return Math.log(e)}function xf(e){return Math.exp(e)}function N_(e){return-Math.log(-e)}function $_(e){return-Math.exp(-e)}function F_(e){return isFinite(e)?+("1e"+e):e<0?0:e}function U_(e){return e===10?F_:e===Math.E?Math.exp:t=>Math.pow(e,t)}function B_(e){return e===Math.E?Math.log:e===10&&Math.log10||e===2&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}function bf(e){return(t,n)=>-e(-t,n)}function H_(e){const t=e(Ef,xf),n=t.domain;let r=10,i,s;function a(){return i=B_(r),s=U_(r),n()[0]<0?(i=bf(i),s=bf(s),e(N_,$_)):e(Ef,xf),t}return t.base=function(o){return arguments.length?(r=+o,a()):r},t.domain=function(o){return arguments.length?(n(o),a()):n()},t.ticks=o=>{const l=n();let c=l[0],u=l[l.length-1];const d=u<c;d&&([c,u]=[u,c]);let h=i(c),f=i(u),p,g;const m=o==null?10:+o;let v=[];if(!(r%1)&&f-h<m){if(h=Math.floor(h),f=Math.ceil(f),c>0){for(;h<=f;++h)for(p=1;p<r;++p)if(g=h<0?p/s(-h):p*s(h),!(g<c)){if(g>u)break;v.push(g)}}else for(;h<=f;++h)for(p=r-1;p>=1;--p)if(g=h>0?p/s(-h):p*s(h),!(g<c)){if(g>u)break;v.push(g)}v.length*2<m&&(v=ws(c,u,m))}else v=ws(h,f,Math.min(f-h,m)).map(s);return d?v.reverse():v},t.tickFormat=(o,l)=>{if(o==null&&(o=10),l==null&&(l=r===10?"s":","),typeof l!="function"&&(!(r%1)&&(l=Ei(l)).precision==null&&(l.trim=!0),l=cl(l)),o===1/0)return l;const c=Math.max(1,r*o/t.ticks().length);return u=>{let d=u/s(Math.round(i(u)));return d*r<r-.5&&(d*=r),d<=c?l(u):""}},t.nice=()=>n(yf(n(),{floor:o=>s(Math.floor(i(o))),ceil:o=>s(Math.ceil(i(o)))})),t}function _f(){const e=H_(gf()).domain([1,10]);return e.copy=()=>$l(e,_f()).base(e.base()),Mr.apply(e,arguments),e}function Fl(){var e=0,t=1,n=1,r=[.5],i=[0,1],s;function a(l){return l!=null&&l<=l?i[Ao(r,l,0,n)]:s}function o(){var l=-1;for(r=new Array(n);++l<n;)r[l]=((l+1)*t-(l-n)*e)/(n+1);return a}return a.domain=function(l){return arguments.length?([e,t]=l,e=+e,t=+t,o()):[e,t]},a.range=function(l){return arguments.length?(n=(i=Array.from(l)).length-1,o()):i.slice()},a.invertExtent=function(l){var c=i.indexOf(l);return c<0?[NaN,NaN]:c<1?[e,r[0]]:c>=n?[r[n-1],t]:[r[c-1],r[c]]},a.unknown=function(l){return arguments.length&&(s=l),a},a.thresholds=function(){return r.slice()},a.copy=function(){return Fl().domain([e,t]).range(i).unknown(s)},Mr.apply(vf(a),arguments)}const Ul=new Date,Bl=new Date;function Wt(e,t,n,r){function i(s){return e(s=arguments.length===0?new Date:new Date(+s)),s}return i.floor=s=>(e(s=new Date(+s)),s),i.ceil=s=>(e(s=new Date(s-1)),t(s,1),e(s),s),i.round=s=>{const a=i(s),o=i.ceil(s);return s-a<o-s?a:o},i.offset=(s,a)=>(t(s=new Date(+s),a==null?1:Math.floor(a)),s),i.range=(s,a,o)=>{const l=[];if(s=i.ceil(s),o=o==null?1:Math.floor(o),!(s<a)||!(o>0))return l;let c;do l.push(c=new Date(+s)),t(s,o),e(s);while(c<s&&s<a);return l},i.filter=s=>Wt(a=>{if(a>=a)for(;e(a),!s(a);)a.setTime(a-1)},(a,o)=>{if(a>=a)if(o<0)for(;++o<=0;)for(;t(a,-1),!s(a););else for(;--o>=0;)for(;t(a,1),!s(a););}),n&&(i.count=(s,a)=>(Ul.setTime(+s),Bl.setTime(+a),e(Ul),e(Bl),Math.floor(n(Ul,Bl))),i.every=s=>(s=Math.floor(s),!isFinite(s)||!(s>0)?null:s>1?i.filter(r?a=>r(a)%s===0:a=>i.count(0,a)%s===0):i)),i}const ma=Wt(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);ma.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?Wt(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):ma),ma.range;const mn=1e3,Me=mn*60,vn=Me*60,yn=vn*24,Hl=yn*7,Sf=yn*30,Gl=yn*365,Cr=Wt(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*mn)},(e,t)=>(t-e)/mn,e=>e.getUTCSeconds());Cr.range;const Vl=Wt(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*mn)},(e,t)=>{e.setTime(+e+t*Me)},(e,t)=>(t-e)/Me,e=>e.getMinutes());Vl.range,Wt(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Me)},(e,t)=>(t-e)/Me,e=>e.getUTCMinutes()).range;const zl=Wt(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*mn-e.getMinutes()*Me)},(e,t)=>{e.setTime(+e+t*vn)},(e,t)=>(t-e)/vn,e=>e.getHours());zl.range,Wt(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*vn)},(e,t)=>(t-e)/vn,e=>e.getUTCHours()).range;const Pi=Wt(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Me)/yn,e=>e.getDate()-1);Pi.range;const Wl=Wt(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/yn,e=>e.getUTCDate()-1);Wl.range,Wt(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/yn,e=>Math.floor(e/yn)).range;function Qn(e){return Wt(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,n)=>{t.setDate(t.getDate()+n*7)},(t,n)=>(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*Me)/Hl)}const va=Qn(0),ya=Qn(1),G_=Qn(2),V_=Qn(3),Dr=Qn(4),z_=Qn(5),W_=Qn(6);va.range,ya.range,G_.range,V_.range,Dr.range,z_.range,W_.range;function Jn(e){return Wt(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n*7)},(t,n)=>(n-t)/Hl)}const Tf=Jn(0),Ea=Jn(1),Y_=Jn(2),q_=Jn(3),Lr=Jn(4),X_=Jn(5),j_=Jn(6);Tf.range,Ea.range,Y_.range,q_.range,Lr.range,X_.range,j_.range;const Yl=Wt(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());Yl.range,Wt(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth()).range;const En=Wt(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());En.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Wt(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)}),En.range;const tr=Wt(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());tr.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Wt(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)}),tr.range;function Z_(e,t,n,r,i,s){const a=[[Cr,1,mn],[Cr,5,5*mn],[Cr,15,15*mn],[Cr,30,30*mn],[s,1,Me],[s,5,5*Me],[s,15,15*Me],[s,30,30*Me],[i,1,vn],[i,3,3*vn],[i,6,6*vn],[i,12,12*vn],[r,1,yn],[r,2,2*yn],[n,1,Hl],[t,1,Sf],[t,3,3*Sf],[e,1,Gl]];function o(c,u,d){const h=u<c;h&&([c,u]=[u,c]);const f=d&&typeof d.range=="function"?d:l(c,u,d),p=f?f.range(c,+u+1):[];return h?p.reverse():p}function l(c,u,d){const h=Math.abs(u-c)/d,f=Mo(([,,m])=>m).right(a,h);if(f===a.length)return e.every(Do(c/Gl,u/Gl,d));if(f===0)return ma.every(Math.max(Do(c,u,d),1));const[p,g]=a[h/a[f-1][2]<a[f][2]/h?f-1:f];return p.every(g)}return[o,l]}const[K_,Q_]=Z_(En,Yl,va,Pi,zl,Vl);function ql(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 Xl(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 Ni(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function J_(e){var t=e.dateTime,n=e.date,r=e.time,i=e.periods,s=e.days,a=e.shortDays,o=e.months,l=e.shortMonths,c=$i(i),u=Fi(i),d=$i(s),h=Fi(s),f=$i(a),p=Fi(a),g=$i(o),m=Fi(o),v=$i(l),E=Fi(l),y={a:$,A:N,b:F,B:Y,c:null,d:Df,e:Df,f:_S,g:RS,G:kS,H:ES,I:xS,j:bS,L:Lf,m:SS,M:TS,p:Z,q:K,Q:$f,s:Ff,S:OS,u:wS,U:MS,V:AS,w:CS,W:DS,x:null,X:null,y:LS,Y:IS,Z:PS,"%":Nf},b={a:dt,A:it,b:ft,B:j,c:null,d:If,e:If,f:US,g:jS,G:KS,H:NS,I:$S,j:FS,L:kf,m:BS,M:HS,p:nt,q:vt,Q:$f,s:Ff,S:GS,u:VS,U:zS,V:WS,w:YS,W:qS,x:null,X:null,y:XS,Y:ZS,Z:QS,"%":Nf},S={a:D,A:O,b:H,B:P,c:M,d:Af,e:Af,f:gS,g:Mf,G:wf,H:Cf,I:Cf,j:hS,L:pS,m:uS,M:dS,p:B,q:cS,Q:vS,s:yS,S:fS,u:iS,U:sS,V:aS,w:rS,W:oS,x:w,X:U,y:Mf,Y:wf,Z:lS,"%":mS};y.x=_(n,y),y.X=_(r,y),y.c=_(t,y),b.x=_(n,b),b.X=_(r,b),b.c=_(t,b);function _(q,Q){return function(ot){var C=[],G=-1,z=0,Ct=q.length,Ut,st,Dt;for(ot instanceof Date||(ot=new Date(+ot));++G<Ct;)q.charCodeAt(G)===37&&(C.push(q.slice(z,G)),(st=Of[Ut=q.charAt(++G)])!=null?Ut=q.charAt(++G):st=Ut==="e"?" ":"0",(Dt=Q[Ut])&&(Ut=Dt(ot,st)),C.push(Ut),z=G+1);return C.push(q.slice(z,G)),C.join("")}}function A(q,Q){return function(ot){var C=Ni(1900,void 0,1),G=R(C,q,ot+="",0),z,Ct;if(G!=ot.length)return null;if("Q"in C)return new Date(C.Q);if("s"in C)return new Date(C.s*1e3+("L"in C?C.L:0));if(Q&&!("Z"in C)&&(C.Z=0),"p"in C&&(C.H=C.H%12+C.p*12),C.m===void 0&&(C.m="q"in C?C.q:0),"V"in C){if(C.V<1||C.V>53)return null;"w"in C||(C.w=1),"Z"in C?(z=Xl(Ni(C.y,0,1)),Ct=z.getUTCDay(),z=Ct>4||Ct===0?Ea.ceil(z):Ea(z),z=Wl.offset(z,(C.V-1)*7),C.y=z.getUTCFullYear(),C.m=z.getUTCMonth(),C.d=z.getUTCDate()+(C.w+6)%7):(z=ql(Ni(C.y,0,1)),Ct=z.getDay(),z=Ct>4||Ct===0?ya.ceil(z):ya(z),z=Pi.offset(z,(C.V-1)*7),C.y=z.getFullYear(),C.m=z.getMonth(),C.d=z.getDate()+(C.w+6)%7)}else("W"in C||"U"in C)&&("w"in C||(C.w="u"in C?C.u%7:"W"in C?1:0),Ct="Z"in C?Xl(Ni(C.y,0,1)).getUTCDay():ql(Ni(C.y,0,1)).getDay(),C.m=0,C.d="W"in C?(C.w+6)%7+C.W*7-(Ct+5)%7:C.w+C.U*7-(Ct+6)%7);return"Z"in C?(C.H+=C.Z/100|0,C.M+=C.Z%100,Xl(C)):ql(C)}}function R(q,Q,ot,C){for(var G=0,z=Q.length,Ct=ot.length,Ut,st;G<z;){if(C>=Ct)return-1;if(Ut=Q.charCodeAt(G++),Ut===37){if(Ut=Q.charAt(G++),st=S[Ut in Of?Q.charAt(G++):Ut],!st||(C=st(q,ot,C))<0)return-1}else if(Ut!=ot.charCodeAt(C++))return-1}return C}function B(q,Q,ot){var C=c.exec(Q.slice(ot));return C?(q.p=u.get(C[0].toLowerCase()),ot+C[0].length):-1}function D(q,Q,ot){var C=f.exec(Q.slice(ot));return C?(q.w=p.get(C[0].toLowerCase()),ot+C[0].length):-1}function O(q,Q,ot){var C=d.exec(Q.slice(ot));return C?(q.w=h.get(C[0].toLowerCase()),ot+C[0].length):-1}function H(q,Q,ot){var C=v.exec(Q.slice(ot));return C?(q.m=E.get(C[0].toLowerCase()),ot+C[0].length):-1}function P(q,Q,ot){var C=g.exec(Q.slice(ot));return C?(q.m=m.get(C[0].toLowerCase()),ot+C[0].length):-1}function M(q,Q,ot){return R(q,t,Q,ot)}function w(q,Q,ot){return R(q,n,Q,ot)}function U(q,Q,ot){return R(q,r,Q,ot)}function $(q){return a[q.getDay()]}function N(q){return s[q.getDay()]}function F(q){return l[q.getMonth()]}function Y(q){return o[q.getMonth()]}function Z(q){return i[+(q.getHours()>=12)]}function K(q){return 1+~~(q.getMonth()/3)}function dt(q){return a[q.getUTCDay()]}function it(q){return s[q.getUTCDay()]}function ft(q){return l[q.getUTCMonth()]}function j(q){return o[q.getUTCMonth()]}function nt(q){return i[+(q.getUTCHours()>=12)]}function vt(q){return 1+~~(q.getUTCMonth()/3)}return{format:function(q){var Q=_(q+="",y);return Q.toString=function(){return q},Q},parse:function(q){var Q=A(q+="",!1);return Q.toString=function(){return q},Q},utcFormat:function(q){var Q=_(q+="",b);return Q.toString=function(){return q},Q},utcParse:function(q){var Q=A(q+="",!0);return Q.toString=function(){return q},Q}}}var Of={"-":"",_:" ",0:"0"},Yt=/^\s*\d+/,tS=/^%/,eS=/[\\^$*+?|[\]().{}]/g;function Et(e,t,n){var r=e<0?"-":"",i=(r?-e:e)+"",s=i.length;return r+(s<n?new Array(n-s+1).join(t)+i:i)}function nS(e){return e.replace(eS,"\\$&")}function $i(e){return new RegExp("^(?:"+e.map(nS).join("|")+")","i")}function Fi(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function rS(e,t,n){var r=Yt.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function iS(e,t,n){var r=Yt.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function sS(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function aS(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function oS(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function wf(e,t,n){var r=Yt.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function Mf(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function lS(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 cS(e,t,n){var r=Yt.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function uS(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function Af(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function hS(e,t,n){var r=Yt.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function Cf(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function dS(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function fS(e,t,n){var r=Yt.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function pS(e,t,n){var r=Yt.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function gS(e,t,n){var r=Yt.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function mS(e,t,n){var r=tS.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function vS(e,t,n){var r=Yt.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function yS(e,t,n){var r=Yt.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function Df(e,t){return Et(e.getDate(),t,2)}function ES(e,t){return Et(e.getHours(),t,2)}function xS(e,t){return Et(e.getHours()%12||12,t,2)}function bS(e,t){return Et(1+Pi.count(En(e),e),t,3)}function Lf(e,t){return Et(e.getMilliseconds(),t,3)}function _S(e,t){return Lf(e,t)+"000"}function SS(e,t){return Et(e.getMonth()+1,t,2)}function TS(e,t){return Et(e.getMinutes(),t,2)}function OS(e,t){return Et(e.getSeconds(),t,2)}function wS(e){var t=e.getDay();return t===0?7:t}function MS(e,t){return Et(va.count(En(e)-1,e),t,2)}function Rf(e){var t=e.getDay();return t>=4||t===0?Dr(e):Dr.ceil(e)}function AS(e,t){return e=Rf(e),Et(Dr.count(En(e),e)+(En(e).getDay()===4),t,2)}function CS(e){return e.getDay()}function DS(e,t){return Et(ya.count(En(e)-1,e),t,2)}function LS(e,t){return Et(e.getFullYear()%100,t,2)}function RS(e,t){return e=Rf(e),Et(e.getFullYear()%100,t,2)}function IS(e,t){return Et(e.getFullYear()%1e4,t,4)}function kS(e,t){var n=e.getDay();return e=n>=4||n===0?Dr(e):Dr.ceil(e),Et(e.getFullYear()%1e4,t,4)}function PS(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Et(t/60|0,"0",2)+Et(t%60,"0",2)}function If(e,t){return Et(e.getUTCDate(),t,2)}function NS(e,t){return Et(e.getUTCHours(),t,2)}function $S(e,t){return Et(e.getUTCHours()%12||12,t,2)}function FS(e,t){return Et(1+Wl.count(tr(e),e),t,3)}function kf(e,t){return Et(e.getUTCMilliseconds(),t,3)}function US(e,t){return kf(e,t)+"000"}function BS(e,t){return Et(e.getUTCMonth()+1,t,2)}function HS(e,t){return Et(e.getUTCMinutes(),t,2)}function GS(e,t){return Et(e.getUTCSeconds(),t,2)}function VS(e){var t=e.getUTCDay();return t===0?7:t}function zS(e,t){return Et(Tf.count(tr(e)-1,e),t,2)}function Pf(e){var t=e.getUTCDay();return t>=4||t===0?Lr(e):Lr.ceil(e)}function WS(e,t){return e=Pf(e),Et(Lr.count(tr(e),e)+(tr(e).getUTCDay()===4),t,2)}function YS(e){return e.getUTCDay()}function qS(e,t){return Et(Ea.count(tr(e)-1,e),t,2)}function XS(e,t){return Et(e.getUTCFullYear()%100,t,2)}function jS(e,t){return e=Pf(e),Et(e.getUTCFullYear()%100,t,2)}function ZS(e,t){return Et(e.getUTCFullYear()%1e4,t,4)}function KS(e,t){var n=e.getUTCDay();return e=n>=4||n===0?Lr(e):Lr.ceil(e),Et(e.getUTCFullYear()%1e4,t,4)}function QS(){return"+0000"}function Nf(){return"%"}function $f(e){return+e}function Ff(e){return Math.floor(+e/1e3)}var Rr,Uf;JS({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function JS(e){return Rr=J_(e),Uf=Rr.format,Rr.parse,Rr.utcFormat,Rr.utcParse,Rr}function tT(e){return new Date(e)}function eT(e){return e instanceof Date?+e:+new Date(+e)}function Bf(e,t,n,r,i,s,a,o,l,c){var u=mf(),d=u.invert,h=u.domain,f=c(".%L"),p=c(":%S"),g=c("%I:%M"),m=c("%I %p"),v=c("%a %d"),E=c("%b %d"),y=c("%B"),b=c("%Y");function S(_){return(l(_)<_?f:o(_)<_?p:a(_)<_?g:s(_)<_?m:r(_)<_?i(_)<_?v:E:n(_)<_?y:b)(_)}return u.invert=function(_){return new Date(d(_))},u.domain=function(_){return arguments.length?h(Array.from(_,eT)):h().map(tT)},u.ticks=function(_){var A=h();return e(A[0],A[A.length-1],_??10)},u.tickFormat=function(_,A){return A==null?S:c(A)},u.nice=function(_){var A=h();return(!_||typeof _.range!="function")&&(_=t(A[0],A[A.length-1],_??10)),_?h(yf(A,_)):u},u.copy=function(){return $l(u,Bf(e,t,n,r,i,s,a,o,l,c))},u}function Hf(){return Mr.apply(Bf(K_,Q_,En,Yl,va,Pi,zl,Vl,Cr,Uf).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function ht(e){return function(){return e}}const Gf=Math.abs,Jt=Math.atan2,er=Math.cos,nT=Math.max,jl=Math.min,Je=Math.sin,Ir=Math.sqrt,te=1e-12,Ui=Math.PI,xa=Ui/2,ba=2*Ui;function rT(e){return e>1?0:e<-1?Ui:Math.acos(e)}function Vf(e){return e>=1?xa:e<=-1?-xa:Math.asin(e)}function _a(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{const r=Math.floor(n);if(!(r>=0))throw new RangeError(`invalid digits: ${n}`);t=r}return e},()=>new Ox(t)}function iT(e){return e.innerRadius}function sT(e){return e.outerRadius}function aT(e){return e.startAngle}function oT(e){return e.endAngle}function lT(e){return e&&e.padAngle}function cT(e,t,n,r,i,s,a,o){var l=n-e,c=r-t,u=a-i,d=o-s,h=d*l-u*c;if(!(h*h<te))return h=(u*(t-s)-d*(e-i))/h,[e+h*l,t+h*c]}function Sa(e,t,n,r,i,s,a){var o=e-n,l=t-r,c=(a?s:-s)/Ir(o*o+l*l),u=c*l,d=-c*o,h=e+u,f=t+d,p=n+u,g=r+d,m=(h+p)/2,v=(f+g)/2,E=p-h,y=g-f,b=E*E+y*y,S=i-s,_=h*g-p*f,A=(y<0?-1:1)*Ir(nT(0,S*S*b-_*_)),R=(_*y-E*A)/b,B=(-_*E-y*A)/b,D=(_*y+E*A)/b,O=(-_*E+y*A)/b,H=R-m,P=B-v,M=D-m,w=O-v;return H*H+P*P>M*M+w*w&&(R=D,B=O),{cx:R,cy:B,x01:-u,y01:-d,x11:R*(i/S-1),y11:B*(i/S-1)}}function Bi(){var e=iT,t=sT,n=ht(0),r=null,i=aT,s=oT,a=lT,o=null,l=_a(c);function c(){var u,d,h=+e.apply(this,arguments),f=+t.apply(this,arguments),p=i.apply(this,arguments)-xa,g=s.apply(this,arguments)-xa,m=Gf(g-p),v=g>p;if(o||(o=u=l()),f<h&&(d=f,f=h,h=d),!(f>te))o.moveTo(0,0);else if(m>ba-te)o.moveTo(f*er(p),f*Je(p)),o.arc(0,0,f,p,g,!v),h>te&&(o.moveTo(h*er(g),h*Je(g)),o.arc(0,0,h,g,p,v));else{var E=p,y=g,b=p,S=g,_=m,A=m,R=a.apply(this,arguments)/2,B=R>te&&(r?+r.apply(this,arguments):Ir(h*h+f*f)),D=jl(Gf(f-h)/2,+n.apply(this,arguments)),O=D,H=D,P,M;if(B>te){var w=Vf(B/h*Je(R)),U=Vf(B/f*Je(R));(_-=w*2)>te?(w*=v?1:-1,b+=w,S-=w):(_=0,b=S=(p+g)/2),(A-=U*2)>te?(U*=v?1:-1,E+=U,y-=U):(A=0,E=y=(p+g)/2)}var $=f*er(E),N=f*Je(E),F=h*er(S),Y=h*Je(S);if(D>te){var Z=f*er(y),K=f*Je(y),dt=h*er(b),it=h*Je(b),ft;if(m<Ui)if(ft=cT($,N,dt,it,Z,K,F,Y)){var j=$-ft[0],nt=N-ft[1],vt=Z-ft[0],q=K-ft[1],Q=1/Je(rT((j*vt+nt*q)/(Ir(j*j+nt*nt)*Ir(vt*vt+q*q)))/2),ot=Ir(ft[0]*ft[0]+ft[1]*ft[1]);O=jl(D,(h-ot)/(Q-1)),H=jl(D,(f-ot)/(Q+1))}else O=H=0}A>te?H>te?(P=Sa(dt,it,$,N,f,H,v),M=Sa(Z,K,F,Y,f,H,v),o.moveTo(P.cx+P.x01,P.cy+P.y01),H<D?o.arc(P.cx,P.cy,H,Jt(P.y01,P.x01),Jt(M.y01,M.x01),!v):(o.arc(P.cx,P.cy,H,Jt(P.y01,P.x01),Jt(P.y11,P.x11),!v),o.arc(0,0,f,Jt(P.cy+P.y11,P.cx+P.x11),Jt(M.cy+M.y11,M.cx+M.x11),!v),o.arc(M.cx,M.cy,H,Jt(M.y11,M.x11),Jt(M.y01,M.x01),!v))):(o.moveTo($,N),o.arc(0,0,f,E,y,!v)):o.moveTo($,N),!(h>te)||!(_>te)?o.lineTo(F,Y):O>te?(P=Sa(F,Y,Z,K,h,-O,v),M=Sa($,N,dt,it,h,-O,v),o.lineTo(P.cx+P.x01,P.cy+P.y01),O<D?o.arc(P.cx,P.cy,O,Jt(P.y01,P.x01),Jt(M.y01,M.x01),!v):(o.arc(P.cx,P.cy,O,Jt(P.y01,P.x01),Jt(P.y11,P.x11),!v),o.arc(0,0,h,Jt(P.cy+P.y11,P.cx+P.x11),Jt(M.cy+M.y11,M.cx+M.x11),v),o.arc(M.cx,M.cy,O,Jt(M.y11,M.x11),Jt(M.y01,M.x01),!v))):o.arc(0,0,h,S,b,v)}if(o.closePath(),u)return o=null,u+""||null}return c.centroid=function(){var u=(+e.apply(this,arguments)+ +t.apply(this,arguments))/2,d=(+i.apply(this,arguments)+ +s.apply(this,arguments))/2-Ui/2;return[er(d)*u,Je(d)*u]},c.innerRadius=function(u){return arguments.length?(e=typeof u=="function"?u:ht(+u),c):e},c.outerRadius=function(u){return arguments.length?(t=typeof u=="function"?u:ht(+u),c):t},c.cornerRadius=function(u){return arguments.length?(n=typeof u=="function"?u:ht(+u),c):n},c.padRadius=function(u){return arguments.length?(r=u==null?null:typeof u=="function"?u:ht(+u),c):r},c.startAngle=function(u){return arguments.length?(i=typeof u=="function"?u:ht(+u),c):i},c.endAngle=function(u){return arguments.length?(s=typeof u=="function"?u:ht(+u),c):s},c.padAngle=function(u){return arguments.length?(a=typeof u=="function"?u:ht(+u),c):a},c.context=function(u){return arguments.length?(o=u??null,c):o},c}var uT=Array.prototype.slice;function Ta(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function zf(e){this._context=e}zf.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function Oa(e){return new zf(e)}function Zl(e){return e[0]}function Kl(e){return e[1]}function Hi(e,t){var n=ht(!0),r=null,i=Oa,s=null,a=_a(o);e=typeof e=="function"?e:e===void 0?Zl:ht(e),t=typeof t=="function"?t:t===void 0?Kl:ht(t);function o(l){var c,u=(l=Ta(l)).length,d,h=!1,f;for(r==null&&(s=i(f=a())),c=0;c<=u;++c)!(c<u&&n(d=l[c],c,l))===h&&((h=!h)?s.lineStart():s.lineEnd()),h&&s.point(+e(d,c,l),+t(d,c,l));if(f)return s=null,f+""||null}return o.x=function(l){return arguments.length?(e=typeof l=="function"?l:ht(+l),o):e},o.y=function(l){return arguments.length?(t=typeof l=="function"?l:ht(+l),o):t},o.defined=function(l){return arguments.length?(n=typeof l=="function"?l:ht(!!l),o):n},o.curve=function(l){return arguments.length?(i=l,r!=null&&(s=i(r)),o):i},o.context=function(l){return arguments.length?(l==null?r=s=null:s=i(r=l),o):r},o}function Ql(e,t,n){var r=null,i=ht(!0),s=null,a=Oa,o=null,l=_a(c);e=typeof e=="function"?e:e===void 0?Zl:ht(+e),t=typeof t=="function"?t:ht(t===void 0?0:+t),n=typeof n=="function"?n:n===void 0?Kl:ht(+n);function c(d){var h,f,p,g=(d=Ta(d)).length,m,v=!1,E,y=new Array(g),b=new Array(g);for(s==null&&(o=a(E=l())),h=0;h<=g;++h){if(!(h<g&&i(m=d[h],h,d))===v)if(v=!v)f=h,o.areaStart(),o.lineStart();else{for(o.lineEnd(),o.lineStart(),p=h-1;p>=f;--p)o.point(y[p],b[p]);o.lineEnd(),o.areaEnd()}v&&(y[h]=+e(m,h,d),b[h]=+t(m,h,d),o.point(r?+r(m,h,d):y[h],n?+n(m,h,d):b[h]))}if(E)return o=null,E+""||null}function u(){return Hi().defined(i).curve(a).context(s)}return c.x=function(d){return arguments.length?(e=typeof d=="function"?d:ht(+d),r=null,c):e},c.x0=function(d){return arguments.length?(e=typeof d=="function"?d:ht(+d),c):e},c.x1=function(d){return arguments.length?(r=d==null?null:typeof d=="function"?d:ht(+d),c):r},c.y=function(d){return arguments.length?(t=typeof d=="function"?d:ht(+d),n=null,c):t},c.y0=function(d){return arguments.length?(t=typeof d=="function"?d:ht(+d),c):t},c.y1=function(d){return arguments.length?(n=d==null?null:typeof d=="function"?d:ht(+d),c):n},c.lineX0=c.lineY0=function(){return u().x(e).y(t)},c.lineY1=function(){return u().x(e).y(n)},c.lineX1=function(){return u().x(r).y(t)},c.defined=function(d){return arguments.length?(i=typeof d=="function"?d:ht(!!d),c):i},c.curve=function(d){return arguments.length?(a=d,s!=null&&(o=a(s)),c):a},c.context=function(d){return arguments.length?(d==null?s=o=null:o=a(s=d),c):s},c}function hT(e,t){return t<e?-1:t>e?1:t>=e?0:NaN}function dT(e){return e}function fT(){var e=dT,t=hT,n=null,r=ht(0),i=ht(ba),s=ht(0);function a(o){var l,c=(o=Ta(o)).length,u,d,h=0,f=new Array(c),p=new Array(c),g=+r.apply(this,arguments),m=Math.min(ba,Math.max(-ba,i.apply(this,arguments)-g)),v,E=Math.min(Math.abs(m)/c,s.apply(this,arguments)),y=E*(m<0?-1:1),b;for(l=0;l<c;++l)(b=p[f[l]=l]=+e(o[l],l,o))>0&&(h+=b);for(t!=null?f.sort(function(S,_){return t(p[S],p[_])}):n!=null&&f.sort(function(S,_){return n(o[S],o[_])}),l=0,d=h?(m-c*y)/h:0;l<c;++l,g=v)u=f[l],b=p[u],v=g+(b>0?b*d:0)+y,p[u]={data:o[u],index:l,value:b,startAngle:g,endAngle:v,padAngle:E};return p}return a.value=function(o){return arguments.length?(e=typeof o=="function"?o:ht(+o),a):e},a.sortValues=function(o){return arguments.length?(t=o,n=null,a):t},a.sort=function(o){return arguments.length?(n=o,t=null,a):n},a.startAngle=function(o){return arguments.length?(r=typeof o=="function"?o:ht(+o),a):r},a.endAngle=function(o){return arguments.length?(i=typeof o=="function"?o:ht(+o),a):i},a.padAngle=function(o){return arguments.length?(s=typeof o=="function"?o:ht(+o),a):s},a}var pT=Yf(Oa);function Wf(e){this._curve=e}Wf.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(e,t){this._curve.point(t*Math.sin(e),t*-Math.cos(e))}};function Yf(e){function t(n){return new Wf(e(n))}return t._curve=e,t}function gT(e){var t=e.curve;return e.angle=e.x,delete e.x,e.radius=e.y,delete e.y,e.curve=function(n){return arguments.length?t(Yf(n)):t()._curve},e}function mT(){return gT(Hi().curve(pT))}class vT{constructor(t,n){this._context=t,this._x=n}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(t,n){switch(t=+t,n=+n,this._point){case 0:{this._point=1,this._line?this._context.lineTo(t,n):this._context.moveTo(t,n);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,n,t,n):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+n)/2,t,this._y0,t,n);break}}this._x0=t,this._y0=n}}function yT(e){return new vT(e,!0)}function ET(e){return e.source}function xT(e){return e.target}function bT(e){let t=ET,n=xT,r=Zl,i=Kl,s=null,a=null,o=_a(l);function l(){let c;const u=uT.call(arguments),d=t.apply(this,u),h=n.apply(this,u);if(s==null&&(a=e(c=o())),a.lineStart(),u[0]=d,a.point(+r.apply(this,u),+i.apply(this,u)),u[0]=h,a.point(+r.apply(this,u),+i.apply(this,u)),a.lineEnd(),c)return a=null,c+""||null}return l.source=function(c){return arguments.length?(t=c,l):t},l.target=function(c){return arguments.length?(n=c,l):n},l.x=function(c){return arguments.length?(r=typeof c=="function"?c:ht(+c),l):r},l.y=function(c){return arguments.length?(i=typeof c=="function"?c:ht(+c),l):i},l.context=function(c){return arguments.length?(c==null?s=a=null:a=e(s=c),l):s},l}function _T(){return bT(yT)}function kn(){}function wa(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 Ma(e){this._context=e}Ma.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:wa(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:wa(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function ST(e){return new Ma(e)}function qf(e){this._context=e}qf.prototype={areaStart:kn,areaEnd:kn,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:wa(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function TT(e){return new qf(e)}function Xf(e){this._context=e}Xf.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:wa(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function OT(e){return new Xf(e)}function jf(e,t){this._basis=new Ma(e),this._beta=t}jf.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=e[0],i=t[0],s=e[n]-r,a=t[n]-i,o=-1,l;++o<=n;)l=o/n,this._basis.point(this._beta*e[o]+(1-this._beta)*(r+l*s),this._beta*t[o]+(1-this._beta)*(i+l*a));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};const wT=function e(t){function n(r){return t===1?new Ma(r):new jf(r,t)}return n.beta=function(r){return e(+r)},n}(.85);function Aa(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 Jl(e,t){this._context=e,this._k=(1-t)/6}Jl.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:Aa(this,this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2,this._x1=e,this._y1=t;break;case 2:this._point=3;default:Aa(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const MT=function e(t){function n(r){return new Jl(r,t)}return n.tension=function(r){return e(+r)},n}(0);function tc(e,t){this._context=e,this._k=(1-t)/6}tc.prototype={areaStart:kn,areaEnd:kn,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);break}}},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:Aa(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const AT=function e(t){function n(r){return new tc(r,t)}return n.tension=function(r){return e(+r)},n}(0);function ec(e,t){this._context=e,this._k=(1-t)/6}ec.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||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:Aa(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const CT=function e(t){function n(r){return new ec(r,t)}return n.tension=function(r){return e(+r)},n}(0);function nc(e,t,n){var r=e._x1,i=e._y1,s=e._x2,a=e._y2;if(e._l01_a>te){var o=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*o-e._x0*e._l12_2a+e._x2*e._l01_2a)/l,i=(i*o-e._y0*e._l12_2a+e._y2*e._l01_2a)/l}if(e._l23_a>te){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);s=(s*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,s,a,e._x2,e._y2)}function Zf(e,t){this._context=e,this._alpha=t}Zf.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);break}(this._line||this._line!==0&&this._point===1)&&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:nc(this,e,t);break}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 DT=function e(t){function n(r){return t?new Zf(r,t):new Jl(r,0)}return n.alpha=function(r){return e(+r)},n}(.5);function Kf(e,t){this._context=e,this._alpha=t}Kf.prototype={areaStart:kn,areaEnd:kn,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);break}}},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:nc(this,e,t);break}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 LT=function e(t){function n(r){return t?new Kf(r,t):new tc(r,0)}return n.alpha=function(r){return e(+r)},n}(.5);function Qf(e,t){this._context=e,this._alpha=t}Qf.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||this._line!==0&&this._point===3)&&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:nc(this,e,t);break}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 RT=function e(t){function n(r){return t?new Qf(r,t):new ec(r,0)}return n.alpha=function(r){return e(+r)},n}(.5);function Jf(e){this._context=e}Jf.prototype={areaStart:kn,areaEnd:kn,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function tp(e){return new Jf(e)}function ep(e){return e<0?-1:1}function np(e,t,n){var r=e._x1-e._x0,i=t-e._x1,s=(e._y1-e._y0)/(r||i<0&&-0),a=(n-e._y1)/(i||r<0&&-0),o=(s*i+a*r)/(r+i);return(ep(s)+ep(a))*Math.min(Math.abs(s),Math.abs(a),.5*Math.abs(o))||0}function rp(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function rc(e,t,n){var r=e._x0,i=e._y0,s=e._x1,a=e._y1,o=(s-r)/3;e._context.bezierCurveTo(r+o,i+o*t,s-o,a-o*n,s,a)}function Ca(e){this._context=e}Ca.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:rc(this,this._t0,rp(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var n=NaN;if(e=+e,t=+t,!(e===this._x1&&t===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,rc(this,rp(this,n=np(this,e,t)),n);break;default:rc(this,this._t0,n=np(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function ip(e){this._context=new sp(e)}(ip.prototype=Object.create(Ca.prototype)).point=function(e,t){Ca.prototype.point.call(this,t,e)};function sp(e){this._context=e}sp.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,n,r,i,s){this._context.bezierCurveTo(t,e,r,n,s,i)}};function IT(e){return new Ca(e)}function kT(e){return new ip(e)}function ap(e){this._context=e}ap.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,n=e.length;if(n)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),n===2)this._context.lineTo(e[1],t[1]);else for(var r=op(e),i=op(t),s=0,a=1;a<n;++s,++a)this._context.bezierCurveTo(r[0][s],i[0][s],r[1][s],i[1][s],e[a],t[a]);(this._line||this._line!==0&&n===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}};function op(e){var t,n=e.length-1,r,i=new Array(n),s=new Array(n),a=new Array(n);for(i[0]=0,s[0]=2,a[0]=e[0]+2*e[1],t=1;t<n-1;++t)i[t]=1,s[t]=4,a[t]=4*e[t]+2*e[t+1];for(i[n-1]=2,s[n-1]=7,a[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)r=i[t]/s[t-1],s[t]-=r,a[t]-=r*a[t-1];for(i[n-1]=a[n-1]/s[n-1],t=n-2;t>=0;--t)i[t]=(a[t]-i[t+1])/s[t];for(s[n-1]=(e[n]+i[n-1])/2,t=0;t<n-1;++t)s[t]=2*e[t+1]-i[t+1];return[i,s]}function PT(e){return new ap(e)}function Da(e,t){this._context=e,this._t=t}Da.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}break}}this._x=e,this._y=t}};function NT(e){return new Da(e,.5)}function $T(e){return new Da(e,0)}function FT(e){return new Da(e,1)}function lp(e,t){if((a=e.length)>1)for(var n=1,r,i,s=e[t[0]],a,o=s.length;n<a;++n)for(i=s,s=e[t[n]],r=0;r<o;++r)s[r][1]+=s[r][0]=isNaN(i[r][1])?i[r][0]:i[r][1]}function cp(e){for(var t=e.length,n=new Array(t);--t>=0;)n[t]=t;return n}function UT(e,t){return e[t]}function BT(e){const t=[];return t.key=e,t}function ic(){var e=ht([]),t=cp,n=lp,r=UT;function i(s){var a=Array.from(e.apply(this,arguments),BT),o,l=a.length,c=-1,u;for(const d of s)for(o=0,++c;o<l;++o)(a[o][c]=[0,+r(d,a[o].key,c,s)]).data=d;for(o=0,u=Ta(t(a));o<l;++o)a[u[o]].index=o;return n(a,u),a}return i.keys=function(s){return arguments.length?(e=typeof s=="function"?s:ht(Array.from(s)),i):e},i.value=function(s){return arguments.length?(r=typeof s=="function"?s:ht(+s),i):r},i.order=function(s){return arguments.length?(t=s==null?cp:typeof s=="function"?s:ht(Array.from(s)),i):t},i.offset=function(s){return arguments.length?(n=s??lp,i):n},i}function HT(e,t){if((l=e.length)>0)for(var n,r=0,i,s,a,o,l,c=e[t[0]].length;r<c;++r)for(a=o=0,n=0;n<l;++n)(s=(i=e[t[n]][r])[1]-i[0])>0?(i[0]=a,i[1]=a+=s):s<0?(i[1]=o,i[0]=o+=s):(i[0]=0,i[1]=s)}function Gi(e,t,n){this.k=e,this.x=t,this.y=n}Gi.prototype={constructor:Gi,scale:function(e){return e===1?this:new Gi(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new Gi(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}},Gi.prototype;var up=typeof global=="object"&&global&&global.Object===Object&&global,GT=typeof self=="object"&&self&&self.Object===Object&&self,Be=up||GT||Function("return this")(),Ae=Be.Symbol,hp=Object.prototype,VT=hp.hasOwnProperty,zT=hp.toString,Vi=Ae?Ae.toStringTag:void 0;function WT(e){var t=VT.call(e,Vi),n=e[Vi];try{e[Vi]=void 0;var r=!0}catch{}var i=zT.call(e);return r&&(t?e[Vi]=n:delete e[Vi]),i}var YT=Object.prototype,qT=YT.toString;function XT(e){return qT.call(e)}var jT="[object Null]",ZT="[object Undefined]",dp=Ae?Ae.toStringTag:void 0;function nr(e){return e==null?e===void 0?ZT:jT:dp&&dp in Object(e)?WT(e):XT(e)}function tn(e){return e!=null&&typeof e=="object"}var KT="[object Symbol]";function La(e){return typeof e=="symbol"||tn(e)&&nr(e)==KT}function sc(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}var Xt=Array.isArray,QT=1/0,fp=Ae?Ae.prototype:void 0,pp=fp?fp.toString:void 0;function gp(e){if(typeof e=="string")return e;if(Xt(e))return sc(e,gp)+"";if(La(e))return pp?pp.call(e):"";var t=e+"";return t=="0"&&1/e==-QT?"-0":t}var JT=/\s/;function tO(e){for(var t=e.length;t--&&JT.test(e.charAt(t)););return t}var eO=/^\s+/;function nO(e){return e&&e.slice(0,tO(e)+1).replace(eO,"")}function Ce(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var mp=NaN,rO=/^[-+]0x[0-9a-f]+$/i,iO=/^0b[01]+$/i,sO=/^0o[0-7]+$/i,aO=parseInt;function kr(e){if(typeof e=="number")return e;if(La(e))return mp;if(Ce(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Ce(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=nO(e);var n=iO.test(e);return n||sO.test(e)?aO(e.slice(2),n?2:8):rO.test(e)?mp:+e}function ac(e){return e}var oO="[object AsyncFunction]",lO="[object Function]",cO="[object GeneratorFunction]",uO="[object Proxy]";function oc(e){if(!Ce(e))return!1;var t=nr(e);return t==lO||t==cO||t==oO||t==uO}var lc=Be["__core-js_shared__"],vp=function(){var e=/[^.]+$/.exec(lc&&lc.keys&&lc.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function hO(e){return!!vp&&vp in e}var dO=Function.prototype,fO=dO.toString;function rr(e){if(e!=null){try{return fO.call(e)}catch{}try{return e+""}catch{}}return""}var pO=/[\\^$.*+?()[\]{}|]/g,gO=/^\[object .+?Constructor\]$/,mO=Function.prototype,vO=Object.prototype,yO=mO.toString,EO=vO.hasOwnProperty,xO=RegExp("^"+yO.call(EO).replace(pO,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function bO(e){if(!Ce(e)||hO(e))return!1;var t=oc(e)?xO:gO;return t.test(rr(e))}function _O(e,t){return e==null?void 0:e[t]}function ir(e,t){var n=_O(e,t);return bO(n)?n:void 0}var cc=ir(Be,"WeakMap"),yp=Object.create,SO=function(){function e(){}return function(t){if(!Ce(t))return{};if(yp)return yp(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function TO(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function OO(){}function Ep(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}var wO=800,MO=16,AO=Date.now;function CO(e){var t=0,n=0;return function(){var r=AO(),i=MO-(r-n);if(n=r,i>0){if(++t>=wO)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function DO(e){return function(){return e}}var Ra=function(){try{var e=ir(Object,"defineProperty");return e({},"",{}),e}catch{}}(),LO=Ra?function(e,t){return Ra(e,"toString",{configurable:!0,enumerable:!1,value:DO(t),writable:!0})}:ac,xp=CO(LO);function RO(e,t){for(var n=-1,r=e==null?0:e.length;++n<r&&t(e[n],n,e)!==!1;);return e}function IO(e,t,n,r){for(var i=e.length,s=n+-1;++s<i;)if(t(e[s],s,e))return s;return-1}function kO(e){return e!==e}function PO(e,t,n){for(var r=n-1,i=e.length;++r<i;)if(e[r]===t)return r;return-1}function NO(e,t,n){return t===t?PO(e,t,n):IO(e,kO,n)}function $O(e,t){var n=e==null?0:e.length;return!!n&&NO(e,t,0)>-1}var FO=9007199254740991,UO=/^(?:0|[1-9]\d*)$/;function uc(e,t){var n=typeof e;return t=t??FO,!!t&&(n=="number"||n!="symbol"&&UO.test(e))&&e>-1&&e%1==0&&e<t}function Ia(e,t,n){t=="__proto__"&&Ra?Ra(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function zi(e,t){return e===t||e!==e&&t!==t}var BO=Object.prototype,HO=BO.hasOwnProperty;function bp(e,t,n){var r=e[t];(!(HO.call(e,t)&&zi(r,n))||n===void 0&&!(t in e))&&Ia(e,t,n)}function Pr(e,t,n,r){var i=!n;n||(n={});for(var s=-1,a=t.length;++s<a;){var o=t[s],l=void 0;l===void 0&&(l=e[o]),i?Ia(n,o,l):bp(n,o,l)}return n}var _p=Math.max;function Sp(e,t,n){return t=_p(t===void 0?e.length-1:t,0),function(){for(var r=arguments,i=-1,s=_p(r.length-t,0),a=Array(s);++i<s;)a[i]=r[t+i];i=-1;for(var o=Array(t+1);++i<t;)o[i]=r[i];return o[t]=n(a),TO(e,this,o)}}function hc(e,t){return xp(Sp(e,t,ac),e+"")}var GO=9007199254740991;function dc(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=GO}function sr(e){return e!=null&&dc(e.length)&&!oc(e)}function VO(e,t,n){if(!Ce(n))return!1;var r=typeof t;return(r=="number"?sr(n)&&uc(t,n.length):r=="string"&&t in n)?zi(n[t],e):!1}function zO(e){return hc(function(t,n){var r=-1,i=n.length,s=i>1?n[i-1]:void 0,a=i>2?n[2]:void 0;for(s=e.length>3&&typeof s=="function"?(i--,s):void 0,a&&VO(n[0],n[1],a)&&(s=i<3?void 0:s,i=1),t=Object(t);++r<i;){var o=n[r];o&&e(t,o,r,s)}return t})}var WO=Object.prototype;function ka(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||WO;return e===n}function YO(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}var qO="[object Arguments]";function Tp(e){return tn(e)&&nr(e)==qO}var Op=Object.prototype,XO=Op.hasOwnProperty,jO=Op.propertyIsEnumerable,Nr=Tp(function(){return arguments}())?Tp:function(e){return tn(e)&&XO.call(e,"callee")&&!jO.call(e,"callee")};function ZO(){return!1}var wp=typeof W=="object"&&W&&!W.nodeType&&W,Mp=wp&&typeof module=="object"&&module&&!module.nodeType&&module,KO=Mp&&Mp.exports===wp,Ap=KO?Be.Buffer:void 0,QO=Ap?Ap.isBuffer:void 0,$r=QO||ZO,JO="[object Arguments]",tw="[object Array]",ew="[object Boolean]",nw="[object Date]",rw="[object Error]",iw="[object Function]",sw="[object Map]",aw="[object Number]",ow="[object Object]",lw="[object RegExp]",cw="[object Set]",uw="[object String]",hw="[object WeakMap]",dw="[object ArrayBuffer]",fw="[object DataView]",pw="[object Float32Array]",gw="[object Float64Array]",mw="[object Int8Array]",vw="[object Int16Array]",yw="[object Int32Array]",Ew="[object Uint8Array]",xw="[object Uint8ClampedArray]",bw="[object Uint16Array]",_w="[object Uint32Array]",kt={};kt[pw]=kt[gw]=kt[mw]=kt[vw]=kt[yw]=kt[Ew]=kt[xw]=kt[bw]=kt[_w]=!0,kt[JO]=kt[tw]=kt[dw]=kt[ew]=kt[fw]=kt[nw]=kt[rw]=kt[iw]=kt[sw]=kt[aw]=kt[ow]=kt[lw]=kt[cw]=kt[uw]=kt[hw]=!1;function Sw(e){return tn(e)&&dc(e.length)&&!!kt[nr(e)]}function fc(e){return function(t){return e(t)}}var Cp=typeof W=="object"&&W&&!W.nodeType&&W,Wi=Cp&&typeof module=="object"&&module&&!module.nodeType&&module,Tw=Wi&&Wi.exports===Cp,pc=Tw&&up.process,Fr=function(){try{var e=Wi&&Wi.require&&Wi.require("util").types;return e||pc&&pc.binding&&pc.binding("util")}catch{}}(),Dp=Fr&&Fr.isTypedArray,Pa=Dp?fc(Dp):Sw,Ow=Object.prototype,ww=Ow.hasOwnProperty;function Lp(e,t){var n=Xt(e),r=!n&&Nr(e),i=!n&&!r&&$r(e),s=!n&&!r&&!i&&Pa(e),a=n||r||i||s,o=a?YO(e.length,String):[],l=o.length;for(var c in e)(t||ww.call(e,c))&&!(a&&(c=="length"||i&&(c=="offset"||c=="parent")||s&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||uc(c,l)))&&o.push(c);return o}function Rp(e,t){return function(n){return e(t(n))}}var Mw=Rp(Object.keys,Object),Aw=Object.prototype,Cw=Aw.hasOwnProperty;function Ip(e){if(!ka(e))return Mw(e);var t=[];for(var n in Object(e))Cw.call(e,n)&&n!="constructor"&&t.push(n);return t}function Yi(e){return sr(e)?Lp(e):Ip(e)}function Dw(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var Lw=Object.prototype,Rw=Lw.hasOwnProperty;function Iw(e){if(!Ce(e))return Dw(e);var t=ka(e),n=[];for(var r in e)r=="constructor"&&(t||!Rw.call(e,r))||n.push(r);return n}function qi(e){return sr(e)?Lp(e,!0):Iw(e)}var kw=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Pw=/^\w*$/;function gc(e,t){if(Xt(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||La(e)?!0:Pw.test(e)||!kw.test(e)||t!=null&&e in Object(t)}var Xi=ir(Object,"create");function Nw(){this.__data__=Xi?Xi(null):{},this.size=0}function $w(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var Fw="__lodash_hash_undefined__",Uw=Object.prototype,Bw=Uw.hasOwnProperty;function Hw(e){var t=this.__data__;if(Xi){var n=t[e];return n===Fw?void 0:n}return Bw.call(t,e)?t[e]:void 0}var Gw=Object.prototype,Vw=Gw.hasOwnProperty;function zw(e){var t=this.__data__;return Xi?t[e]!==void 0:Vw.call(t,e)}var Ww="__lodash_hash_undefined__";function Yw(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=Xi&&t===void 0?Ww:t,this}function ar(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}ar.prototype.clear=Nw,ar.prototype.delete=$w,ar.prototype.get=Hw,ar.prototype.has=zw,ar.prototype.set=Yw;function qw(){this.__data__=[],this.size=0}function Na(e,t){for(var n=e.length;n--;)if(zi(e[n][0],t))return n;return-1}var Xw=Array.prototype,jw=Xw.splice;function Zw(e){var t=this.__data__,n=Na(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():jw.call(t,n,1),--this.size,!0}function Kw(e){var t=this.__data__,n=Na(t,e);return n<0?void 0:t[n][1]}function Qw(e){return Na(this.__data__,e)>-1}function Jw(e,t){var n=this.__data__,r=Na(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function xn(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}xn.prototype.clear=qw,xn.prototype.delete=Zw,xn.prototype.get=Kw,xn.prototype.has=Qw,xn.prototype.set=Jw;var ji=ir(Be,"Map");function tM(){this.size=0,this.__data__={hash:new ar,map:new(ji||xn),string:new ar}}function eM(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function $a(e,t){var n=e.__data__;return eM(t)?n[typeof t=="string"?"string":"hash"]:n.map}function nM(e){var t=$a(this,e).delete(e);return this.size-=t?1:0,t}function rM(e){return $a(this,e).get(e)}function iM(e){return $a(this,e).has(e)}function sM(e,t){var n=$a(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}function bn(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}bn.prototype.clear=tM,bn.prototype.delete=nM,bn.prototype.get=rM,bn.prototype.has=iM,bn.prototype.set=sM;var aM="Expected a function";function mc(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(aM);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],s=n.cache;if(s.has(i))return s.get(i);var a=e.apply(this,r);return n.cache=s.set(i,a)||s,a};return n.cache=new(mc.Cache||bn),n}mc.Cache=bn;var oM=500;function lM(e){var t=mc(e,function(r){return n.size===oM&&n.clear(),r}),n=t.cache;return t}var cM=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,uM=/\\(\\)?/g,hM=lM(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(cM,function(n,r,i,s){t.push(i?s.replace(uM,"$1"):r||n)}),t});function Zi(e){return e==null?"":gp(e)}function Fa(e,t){return Xt(e)?e:gc(e,t)?[e]:hM(Zi(e))}var dM=1/0;function Ki(e){if(typeof e=="string"||La(e))return e;var t=e+"";return t=="0"&&1/e==-dM?"-0":t}function vc(e,t){t=Fa(t,e);for(var n=0,r=t.length;e!=null&&n<r;)e=e[Ki(t[n++])];return n&&n==r?e:void 0}function yt(e,t,n){var r=e==null?void 0:vc(e,t);return r===void 0?n:r}function yc(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}var kp=Ae?Ae.isConcatSpreadable:void 0;function fM(e){return Xt(e)||Nr(e)||!!(kp&&e&&e[kp])}function Ua(e,t,n,r,i){var s=-1,a=e.length;for(n||(n=fM),i||(i=[]);++s<a;){var o=e[s];t>0&&n(o)?t>1?Ua(o,t-1,n,r,i):yc(i,o):r||(i[i.length]=o)}return i}function Ec(e){var t=e==null?0:e.length;return t?Ua(e,1):[]}function pM(e){return xp(Sp(e,void 0,Ec),e+"")}var xc=Rp(Object.getPrototypeOf,Object),gM="[object Object]",mM=Function.prototype,vM=Object.prototype,Pp=mM.toString,yM=vM.hasOwnProperty,EM=Pp.call(Object);function Np(e){if(!tn(e)||nr(e)!=gM)return!1;var t=xc(e);if(t===null)return!0;var n=yM.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&Pp.call(n)==EM}function $p(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var s=Array(i);++r<i;)s[r]=e[r+t];return s}function xM(e,t,n){var r=e.length;return n=n===void 0?r:n,!t&&n>=r?e:$p(e,t,n)}var bM="\\ud800-\\udfff",_M="\\u0300-\\u036f",SM="\\ufe20-\\ufe2f",TM="\\u20d0-\\u20ff",OM=_M+SM+TM,wM="\\ufe0e\\ufe0f",MM="\\u200d",AM=RegExp("["+MM+bM+OM+wM+"]");function Fp(e){return AM.test(e)}function CM(e){return e.split("")}var Up="\\ud800-\\udfff",DM="\\u0300-\\u036f",LM="\\ufe20-\\ufe2f",RM="\\u20d0-\\u20ff",IM=DM+LM+RM,kM="\\ufe0e\\ufe0f",PM="["+Up+"]",bc="["+IM+"]",_c="\\ud83c[\\udffb-\\udfff]",NM="(?:"+bc+"|"+_c+")",Bp="[^"+Up+"]",Hp="(?:\\ud83c[\\udde6-\\uddff]){2}",Gp="[\\ud800-\\udbff][\\udc00-\\udfff]",$M="\\u200d",Vp=NM+"?",zp="["+kM+"]?",FM="(?:"+$M+"(?:"+[Bp,Hp,Gp].join("|")+")"+zp+Vp+")*",UM=zp+Vp+FM,BM="(?:"+[Bp+bc+"?",bc,Hp,Gp,PM].join("|")+")",HM=RegExp(_c+"(?="+_c+")|"+BM+UM,"g");function GM(e){return e.match(HM)||[]}function VM(e){return Fp(e)?GM(e):CM(e)}function zM(e){return function(t){t=Zi(t);var n=Fp(t)?VM(t):void 0,r=n?n[0]:t.charAt(0),i=n?xM(n,1).join(""):t.slice(1);return r[e]()+i}}var WM=zM("toUpperCase");function YM(e){return WM(Zi(e).toLowerCase())}function qM(e,t,n,r){for(var i=-1,s=e==null?0:e.length;++i<s;)n=t(n,e[i],i,e);return n}function XM(e){return function(t){return e==null?void 0:e[t]}}var jM={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},ZM=XM(jM),KM=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,QM="\\u0300-\\u036f",JM="\\ufe20-\\ufe2f",tA="\\u20d0-\\u20ff",eA=QM+JM+tA,nA="["+eA+"]",rA=RegExp(nA,"g");function iA(e){return e=Zi(e),e&&e.replace(KM,ZM).replace(rA,"")}var sA=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function aA(e){return e.match(sA)||[]}var oA=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function lA(e){return oA.test(e)}var Wp="\\ud800-\\udfff",cA="\\u0300-\\u036f",uA="\\ufe20-\\ufe2f",hA="\\u20d0-\\u20ff",dA=cA+uA+hA,Yp="\\u2700-\\u27bf",qp="a-z\\xdf-\\xf6\\xf8-\\xff",fA="\\xac\\xb1\\xd7\\xf7",pA="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",gA="\\u2000-\\u206f",mA=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Xp="A-Z\\xc0-\\xd6\\xd8-\\xde",vA="\\ufe0e\\ufe0f",jp=fA+pA+gA+mA,Zp="['’]",Kp="["+jp+"]",yA="["+dA+"]",Qp="\\d+",EA="["+Yp+"]",Jp="["+qp+"]",tg="[^"+Wp+jp+Qp+Yp+qp+Xp+"]",xA="\\ud83c[\\udffb-\\udfff]",bA="(?:"+yA+"|"+xA+")",_A="[^"+Wp+"]",eg="(?:\\ud83c[\\udde6-\\uddff]){2}",ng="[\\ud800-\\udbff][\\udc00-\\udfff]",Ur="["+Xp+"]",SA="\\u200d",rg="(?:"+Jp+"|"+tg+")",TA="(?:"+Ur+"|"+tg+")",ig="(?:"+Zp+"(?:d|ll|m|re|s|t|ve))?",sg="(?:"+Zp+"(?:D|LL|M|RE|S|T|VE))?",ag=bA+"?",og="["+vA+"]?",OA="(?:"+SA+"(?:"+[_A,eg,ng].join("|")+")"+og+ag+")*",wA="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",MA="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",AA=og+ag+OA,CA="(?:"+[EA,eg,ng].join("|")+")"+AA,DA=RegExp([Ur+"?"+Jp+"+"+ig+"(?="+[Kp,Ur,"$"].join("|")+")",TA+"+"+sg+"(?="+[Kp,Ur+rg,"$"].join("|")+")",Ur+"?"+rg+"+"+ig,Ur+"+"+sg,MA,wA,Qp,CA].join("|"),"g");function LA(e){return e.match(DA)||[]}function RA(e,t,n){return e=Zi(e),t=t,t===void 0?lA(e)?LA(e):aA(e):e.match(t)||[]}var IA="['’]",kA=RegExp(IA,"g");function lg(e){return function(t){return qM(RA(iA(t).replace(kA,"")),e,"")}}var PA=lg(function(e,t,n){return t=t.toLowerCase(),e+(n?YM(t):t)});function NA(e,t,n){return e===e&&(n!==void 0&&(e=e<=n?e:n),t!==void 0&&(e=e>=t?e:t)),e}function cg(e,t,n){return n===void 0&&(n=t,t=void 0),n!==void 0&&(n=kr(n),n=n===n?n:0),t!==void 0&&(t=kr(t),t=t===t?t:0),NA(kr(e),t,n)}function $A(){this.__data__=new xn,this.size=0}function FA(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function UA(e){return this.__data__.get(e)}function BA(e){return this.__data__.has(e)}var HA=200;function GA(e,t){var n=this.__data__;if(n instanceof xn){var r=n.__data__;if(!ji||r.length<HA-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new bn(r)}return n.set(e,t),this.size=n.size,this}function He(e){var t=this.__data__=new xn(e);this.size=t.size}He.prototype.clear=$A,He.prototype.delete=FA,He.prototype.get=UA,He.prototype.has=BA,He.prototype.set=GA;function VA(e,t){return e&&Pr(t,Yi(t),e)}function zA(e,t){return e&&Pr(t,qi(t),e)}var ug=typeof W=="object"&&W&&!W.nodeType&&W,hg=ug&&typeof module=="object"&&module&&!module.nodeType&&module,WA=hg&&hg.exports===ug,dg=WA?Be.Buffer:void 0,fg=dg?dg.allocUnsafe:void 0;function pg(e,t){if(t)return e.slice();var n=e.length,r=fg?fg(n):new e.constructor(n);return e.copy(r),r}function YA(e,t){for(var n=-1,r=e==null?0:e.length,i=0,s=[];++n<r;){var a=e[n];t(a,n,e)&&(s[i++]=a)}return s}function gg(){return[]}var qA=Object.prototype,XA=qA.propertyIsEnumerable,mg=Object.getOwnPropertySymbols,Sc=mg?function(e){return e==null?[]:(e=Object(e),YA(mg(e),function(t){return XA.call(e,t)}))}:gg;function jA(e,t){return Pr(e,Sc(e),t)}var ZA=Object.getOwnPropertySymbols,vg=ZA?function(e){for(var t=[];e;)yc(t,Sc(e)),e=xc(e);return t}:gg;function KA(e,t){return Pr(e,vg(e),t)}function yg(e,t,n){var r=t(e);return Xt(e)?r:yc(r,n(e))}function Tc(e){return yg(e,Yi,Sc)}function Eg(e){return yg(e,qi,vg)}var Oc=ir(Be,"DataView"),wc=ir(Be,"Promise"),Br=ir(Be,"Set"),xg="[object Map]",QA="[object Object]",bg="[object Promise]",_g="[object Set]",Sg="[object WeakMap]",Tg="[object DataView]",JA=rr(Oc),tC=rr(ji),eC=rr(wc),nC=rr(Br),rC=rr(cc),De=nr;(Oc&&De(new Oc(new ArrayBuffer(1)))!=Tg||ji&&De(new ji)!=xg||wc&&De(wc.resolve())!=bg||Br&&De(new Br)!=_g||cc&&De(new cc)!=Sg)&&(De=function(e){var t=nr(e),n=t==QA?e.constructor:void 0,r=n?rr(n):"";if(r)switch(r){case JA:return Tg;case tC:return xg;case eC:return bg;case nC:return _g;case rC:return Sg}return t});var iC=Object.prototype,sC=iC.hasOwnProperty;function aC(e){var t=e.length,n=new e.constructor(t);return t&&typeof e[0]=="string"&&sC.call(e,"index")&&(n.index=e.index,n.input=e.input),n}var Ba=Be.Uint8Array;function Mc(e){var t=new e.constructor(e.byteLength);return new Ba(t).set(new Ba(e)),t}function oC(e,t){var n=t?Mc(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}var lC=/\w*$/;function cC(e){var t=new e.constructor(e.source,lC.exec(e));return t.lastIndex=e.lastIndex,t}var Og=Ae?Ae.prototype:void 0,wg=Og?Og.valueOf:void 0;function uC(e){return wg?Object(wg.call(e)):{}}function Mg(e,t){var n=t?Mc(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var hC="[object Boolean]",dC="[object Date]",fC="[object Map]",pC="[object Number]",gC="[object RegExp]",mC="[object Set]",vC="[object String]",yC="[object Symbol]",EC="[object ArrayBuffer]",xC="[object DataView]",bC="[object Float32Array]",_C="[object Float64Array]",SC="[object Int8Array]",TC="[object Int16Array]",OC="[object Int32Array]",wC="[object Uint8Array]",MC="[object Uint8ClampedArray]",AC="[object Uint16Array]",CC="[object Uint32Array]";function DC(e,t,n){var r=e.constructor;switch(t){case EC:return Mc(e);case hC:case dC:return new r(+e);case xC:return oC(e,n);case bC:case _C:case SC:case TC:case OC:case wC:case MC:case AC:case CC:return Mg(e,n);case fC:return new r;case pC:case vC:return new r(e);case gC:return cC(e);case mC:return new r;case yC:return uC(e)}}function Ag(e){return typeof e.constructor=="function"&&!ka(e)?SO(xc(e)):{}}var LC="[object Map]";function RC(e){return tn(e)&&De(e)==LC}var Cg=Fr&&Fr.isMap,IC=Cg?fc(Cg):RC,kC="[object Set]";function PC(e){return tn(e)&&De(e)==kC}var Dg=Fr&&Fr.isSet,NC=Dg?fc(Dg):PC,$C=1,FC=2,UC=4,Lg="[object Arguments]",BC="[object Array]",HC="[object Boolean]",GC="[object Date]",VC="[object Error]",Rg="[object Function]",zC="[object GeneratorFunction]",WC="[object Map]",YC="[object Number]",Ig="[object Object]",qC="[object RegExp]",XC="[object Set]",jC="[object String]",ZC="[object Symbol]",KC="[object WeakMap]",QC="[object ArrayBuffer]",JC="[object DataView]",tD="[object Float32Array]",eD="[object Float64Array]",nD="[object Int8Array]",rD="[object Int16Array]",iD="[object Int32Array]",sD="[object Uint8Array]",aD="[object Uint8ClampedArray]",oD="[object Uint16Array]",lD="[object Uint32Array]",Lt={};Lt[Lg]=Lt[BC]=Lt[QC]=Lt[JC]=Lt[HC]=Lt[GC]=Lt[tD]=Lt[eD]=Lt[nD]=Lt[rD]=Lt[iD]=Lt[WC]=Lt[YC]=Lt[Ig]=Lt[qC]=Lt[XC]=Lt[jC]=Lt[ZC]=Lt[sD]=Lt[aD]=Lt[oD]=Lt[lD]=!0,Lt[VC]=Lt[Rg]=Lt[KC]=!1;function Qi(e,t,n,r,i,s){var a,o=t&$C,l=t&FC,c=t&UC;if(n&&(a=i?n(e,r,i,s):n(e)),a!==void 0)return a;if(!Ce(e))return e;var u=Xt(e);if(u){if(a=aC(e),!o)return Ep(e,a)}else{var d=De(e),h=d==Rg||d==zC;if($r(e))return pg(e,o);if(d==Ig||d==Lg||h&&!i){if(a=l||h?{}:Ag(e),!o)return l?KA(e,zA(a,e)):jA(e,VA(a,e))}else{if(!Lt[d])return i?e:{};a=DC(e,d,o)}}s||(s=new He);var f=s.get(e);if(f)return f;s.set(e,a),NC(e)?e.forEach(function(m){a.add(Qi(m,t,n,m,e,s))}):IC(e)&&e.forEach(function(m,v){a.set(v,Qi(m,t,n,v,e,s))});var p=c?l?Eg:Tc:l?qi:Yi,g=u?void 0:p(e);return RO(g||e,function(m,v){g&&(v=m,m=e[v]),bp(a,v,Qi(m,t,n,v,e,s))}),a}var cD=1,uD=4;function _n(e){return Qi(e,cD|uD)}var hD="__lodash_hash_undefined__";function dD(e){return this.__data__.set(e,hD),this}function fD(e){return this.__data__.has(e)}function Ji(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new bn;++t<n;)this.add(e[t])}Ji.prototype.add=Ji.prototype.push=dD,Ji.prototype.has=fD;function kg(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}function Pg(e,t){return e.has(t)}var pD=1,gD=2;function Ng(e,t,n,r,i,s){var a=n&pD,o=e.length,l=t.length;if(o!=l&&!(a&&l>o))return!1;var c=s.get(e),u=s.get(t);if(c&&u)return c==t&&u==e;var d=-1,h=!0,f=n&gD?new Ji:void 0;for(s.set(e,t),s.set(t,e);++d<o;){var p=e[d],g=t[d];if(r)var m=a?r(g,p,d,t,e,s):r(p,g,d,e,t,s);if(m!==void 0){if(m)continue;h=!1;break}if(f){if(!kg(t,function(v,E){if(!Pg(f,E)&&(p===v||i(p,v,n,r,s)))return f.push(E)})){h=!1;break}}else if(!(p===g||i(p,g,n,r,s))){h=!1;break}}return s.delete(e),s.delete(t),h}function mD(e){var t=-1,n=Array(e.size);return e.forEach(function(r,i){n[++t]=[i,r]}),n}function Ac(e){var t=-1,n=Array(e.size);return e.forEach(function(r){n[++t]=r}),n}var vD=1,yD=2,ED="[object Boolean]",xD="[object Date]",bD="[object Error]",_D="[object Map]",SD="[object Number]",TD="[object RegExp]",OD="[object Set]",wD="[object String]",MD="[object Symbol]",AD="[object ArrayBuffer]",CD="[object DataView]",$g=Ae?Ae.prototype:void 0,Cc=$g?$g.valueOf:void 0;function DD(e,t,n,r,i,s,a){switch(n){case CD:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case AD:return!(e.byteLength!=t.byteLength||!s(new Ba(e),new Ba(t)));case ED:case xD:case SD:return zi(+e,+t);case bD:return e.name==t.name&&e.message==t.message;case TD:case wD:return e==t+"";case _D:var o=mD;case OD:var l=r&vD;if(o||(o=Ac),e.size!=t.size&&!l)return!1;var c=a.get(e);if(c)return c==t;r|=yD,a.set(e,t);var u=Ng(o(e),o(t),r,i,s,a);return a.delete(e),u;case MD:if(Cc)return Cc.call(e)==Cc.call(t)}return!1}var LD=1,RD=Object.prototype,ID=RD.hasOwnProperty;function kD(e,t,n,r,i,s){var a=n&LD,o=Tc(e),l=o.length,c=Tc(t),u=c.length;if(l!=u&&!a)return!1;for(var d=l;d--;){var h=o[d];if(!(a?h in t:ID.call(t,h)))return!1}var f=s.get(e),p=s.get(t);if(f&&p)return f==t&&p==e;var g=!0;s.set(e,t),s.set(t,e);for(var m=a;++d<l;){h=o[d];var v=e[h],E=t[h];if(r)var y=a?r(E,v,h,t,e,s):r(v,E,h,e,t,s);if(!(y===void 0?v===E||i(v,E,n,r,s):y)){g=!1;break}m||(m=h=="constructor")}if(g&&!m){var b=e.constructor,S=t.constructor;b!=S&&"constructor"in e&&"constructor"in t&&!(typeof b=="function"&&b instanceof b&&typeof S=="function"&&S instanceof S)&&(g=!1)}return s.delete(e),s.delete(t),g}var PD=1,Fg="[object Arguments]",Ug="[object Array]",Ha="[object Object]",ND=Object.prototype,Bg=ND.hasOwnProperty;function $D(e,t,n,r,i,s){var a=Xt(e),o=Xt(t),l=a?Ug:De(e),c=o?Ug:De(t);l=l==Fg?Ha:l,c=c==Fg?Ha:c;var u=l==Ha,d=c==Ha,h=l==c;if(h&&$r(e)){if(!$r(t))return!1;a=!0,u=!1}if(h&&!u)return s||(s=new He),a||Pa(e)?Ng(e,t,n,r,i,s):DD(e,t,l,n,r,i,s);if(!(n&PD)){var f=u&&Bg.call(e,"__wrapped__"),p=d&&Bg.call(t,"__wrapped__");if(f||p){var g=f?e.value():e,m=p?t.value():t;return s||(s=new He),i(g,m,n,r,s)}}return h?(s||(s=new He),kD(e,t,n,r,i,s)):!1}function Ga(e,t,n,r,i){return e===t?!0:e==null||t==null||!tn(e)&&!tn(t)?e!==e&&t!==t:$D(e,t,n,r,Ga,i)}var FD=1,UD=2;function BD(e,t,n,r){var i=n.length,s=i;if(e==null)return!s;for(e=Object(e);i--;){var a=n[i];if(a[2]?a[1]!==e[a[0]]:!(a[0]in e))return!1}for(;++i<s;){a=n[i];var o=a[0],l=e[o],c=a[1];if(a[2]){if(l===void 0&&!(o in e))return!1}else{var u=new He,d;if(!(d===void 0?Ga(c,l,FD|UD,r,u):d))return!1}}return!0}function Hg(e){return e===e&&!Ce(e)}function HD(e){for(var t=Yi(e),n=t.length;n--;){var r=t[n],i=e[r];t[n]=[r,i,Hg(i)]}return t}function Gg(e,t){return function(n){return n==null?!1:n[e]===t&&(t!==void 0||e in Object(n))}}function GD(e){var t=HD(e);return t.length==1&&t[0][2]?Gg(t[0][0],t[0][1]):function(n){return n===e||BD(n,e,t)}}function VD(e,t){return e!=null&&t in Object(e)}function zD(e,t,n){t=Fa(t,e);for(var r=-1,i=t.length,s=!1;++r<i;){var a=Ki(t[r]);if(!(s=e!=null&&n(e,a)))break;e=e[a]}return s||++r!=i?s:(i=e==null?0:e.length,!!i&&dc(i)&&uc(a,i)&&(Xt(e)||Nr(e)))}function WD(e,t){return e!=null&&zD(e,t,VD)}var YD=1,qD=2;function XD(e,t){return gc(e)&&Hg(t)?Gg(Ki(e),t):function(n){var r=yt(n,e);return r===void 0&&r===t?WD(n,e):Ga(t,r,YD|qD)}}function jD(e){return function(t){return t==null?void 0:t[e]}}function ZD(e){return function(t){return vc(t,e)}}function KD(e){return gc(e)?jD(Ki(e)):ZD(e)}function Va(e){return typeof e=="function"?e:e==null?ac:typeof e=="object"?Xt(e)?XD(e[0],e[1]):GD(e):KD(e)}function QD(e,t,n,r){for(var i=-1,s=e==null?0:e.length;++i<s;){var a=e[i];t(r,a,n(a),e)}return r}function JD(e){return function(t,n,r){for(var i=-1,s=Object(t),a=r(t),o=a.length;o--;){var l=a[++i];if(n(s[l],l,s)===!1)break}return t}}var Vg=JD();function tL(e,t){return e&&Vg(e,t,Yi)}function eL(e,t){return function(n,r){if(n==null)return n;if(!sr(n))return e(n,r);for(var i=n.length,s=-1,a=Object(n);++s<i&&r(a[s],s,a)!==!1;);return n}}var Dc=eL(tL);function nL(e,t,n,r){return Dc(e,function(i,s,a){t(r,i,n(i),a)}),r}function rL(e,t){return function(n,r){var i=Xt(n)?QD:nL,s={};return i(n,e,Va(r),s)}}var Lc=function(){return Be.Date.now()},iL="Expected a function",sL=Math.max,aL=Math.min;function za(e,t,n){var r,i,s,a,o,l,c=0,u=!1,d=!1,h=!0;if(typeof e!="function")throw new TypeError(iL);t=kr(t)||0,Ce(n)&&(u=!!n.leading,d="maxWait"in n,s=d?sL(kr(n.maxWait)||0,t):s,h="trailing"in n?!!n.trailing:h);function f(_){var A=r,R=i;return r=i=void 0,c=_,a=e.apply(R,A),a}function p(_){return c=_,o=setTimeout(v,t),u?f(_):a}function g(_){var A=_-l,R=_-c,B=t-A;return d?aL(B,s-R):B}function m(_){var A=_-l,R=_-c;return l===void 0||A>=t||A<0||d&&R>=s}function v(){var _=Lc();if(m(_))return E(_);o=setTimeout(v,g(_))}function E(_){return o=void 0,h&&r?f(_):(r=i=void 0,a)}function y(){o!==void 0&&clearTimeout(o),c=0,r=l=i=o=void 0}function b(){return o===void 0?a:E(Lc())}function S(){var _=Lc(),A=m(_);if(r=arguments,i=this,l=_,A){if(o===void 0)return p(l);if(d)return clearTimeout(o),o=setTimeout(v,t),f(l)}return o===void 0&&(o=setTimeout(v,t)),a}return S.cancel=y,S.flush=b,S}function Rc(e,t,n){(n!==void 0&&!zi(e[t],n)||n===void 0&&!(t in e))&&Ia(e,t,n)}function Ic(e){return tn(e)&&sr(e)}function kc(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}function oL(e){return Pr(e,qi(e))}function lL(e,t,n,r,i,s,a){var o=kc(e,n),l=kc(t,n),c=a.get(l);if(c){Rc(e,n,c);return}var u=s?s(o,l,n+"",e,t,a):void 0,d=u===void 0;if(d){var h=Xt(l),f=!h&&$r(l),p=!h&&!f&&Pa(l);u=l,h||f||p?Xt(o)?u=o:Ic(o)?u=Ep(o):f?(d=!1,u=pg(l,!0)):p?(d=!1,u=Mg(l,!0)):u=[]:Np(l)||Nr(l)?(u=o,Nr(o)?u=oL(o):(!Ce(o)||oc(o))&&(u=Ag(l))):d=!1}d&&(a.set(l,u),i(u,l,r,s,a),a.delete(l)),Rc(e,n,u)}function zg(e,t,n,r,i){e!==t&&Vg(t,function(s,a){if(i||(i=new He),Ce(s))lL(e,t,a,n,zg,r,i);else{var o=r?r(kc(e,a),s,a+"",e,t,i):void 0;o===void 0&&(o=s),Rc(e,a,o)}},qi)}var cL="Expected a function";function uL(e,t,n){if(typeof e!="function")throw new TypeError(cL);return setTimeout(function(){e.apply(void 0,n)},t)}var hL=hc(function(e,t,n){return uL(e,kr(t)||0,n)});function Wg(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}function dL(e,t){var n=-1,r=sr(e)?Array(e.length):[];return Dc(e,function(i,s,a){r[++n]=t(i,s,a)}),r}function fL(e,t){var n=Xt(e)?sc:dL;return n(e,Va(t))}var pL=1/0;function gL(e,t){return Ua(fL(e,t),pL)}function mL(e){for(var t=-1,n=e==null?0:e.length,r={};++t<n;){var i=e[t];r[i[0]]=i[1]}return r}var vL=Object.prototype,yL=vL.hasOwnProperty,EL=rL(function(e,t,n){yL.call(e,n)?e[n].push(t):Ia(e,n,[t])});function xL(e,t){return t.length<2?e:vc(e,$p(t,0,-1))}var bL="[object Map]",_L="[object Set]",SL=Object.prototype,TL=SL.hasOwnProperty;function Ge(e){if(e==null)return!0;if(sr(e)&&(Xt(e)||typeof e=="string"||typeof e.splice=="function"||$r(e)||Pa(e)||Nr(e)))return!e.length;var t=De(e);if(t==bL||t==_L)return!e.size;if(ka(e))return!Ip(e).length;for(var n in e)if(TL.call(e,n))return!1;return!0}function Yg(e,t){return Ga(e,t)}var Hr=lg(function(e,t,n){return e+(n?"-":"")+t.toLowerCase()}),lt=zO(function(e,t,n){zg(e,t,n)});function OL(e,t){return t=Fa(t,e),e=xL(e,t),e==null||delete e[Ki(Wg(t))]}function wL(e){return Np(e)?void 0:e}var ML=1,AL=2,CL=4,DL=pM(function(e,t){var n={};if(e==null)return n;var r=!1;t=sc(t,function(s){return s=Fa(s,e),r||(r=s.length>1),s}),Pr(e,Eg(e),n),r&&(n=Qi(n,ML|AL|CL,wL));for(var i=t.length;i--;)OL(n,t[i]);return n});function LL(e,t){var n;return Dc(e,function(r,i,s){return n=t(r,i,s),!n}),!!n}function RL(e,t,n){var r=Xt(e)?kg:LL;return r(e,Va(t))}var IL=1/0,kL=Br&&1/Ac(new Br([,-0]))[1]==IL?function(e){return new Br(e)}:OO,PL=200;function qg(e,t,n){var r=-1,i=$O,s=e.length,a=!0,o=[],l=o;if(s>=PL){var c=t?null:kL(e);if(c)return Ac(c);a=!1,i=Pg,l=new Ji}else l=t?[]:o;t:for(;++r<s;){var u=e[r],d=t?t(u):u;if(u=u!==0?u:0,a&&d===d){for(var h=l.length;h--;)if(l[h]===d)continue t;t&&l.push(d),o.push(u)}else i(l,d,n)||(l!==o&&l.push(d),o.push(u))}return o}var NL=hc(function(e){var t=Wg(e);return Ic(t)&&(t=void 0),qg(Ua(e,1,Ic,!0),Va(t))});function ts(e){return e&&e.length?qg(e):[]}var Pc=(e=>(e.RENDER_FINISHED="render-finished",e.RESIZE="chart-resize",e.MOUSEOVER="chart-mouseover",e.MOUSEOUT="chart-mouseout",e))(Pc||{}),Nc=(e=>(e.SHOW="show-modal",e.HIDE="hide-modal",e))(Nc||{}),$c=(e=>(e.UPDATE="model-update",e))($c||{}),Xg=(e=>(e.SHOW_OVERFLOW_MENU="show-toolbar-overflow-menu",e.HIDE_OVERFLOW_MENU="hide-toolbar-overflow-menu",e.BUTTON_CLICK="toolbar-button-click",e.SHOW_TOOLTIP="toolbar-show-tooltip",e.HIDE_TOOLTIP="toolbar-hide-tooltip",e))(Xg||{}),Fc=(e=>(e.UPDATE="zoom-bar-update",e.SELECTION_START="zoom-bar-selection-start",e.SELECTION_IN_PROGRESS="zoom-bar-selection-in-progress",e.SELECTION_END="zoom-bar-selection-end",e))(Fc||{}),Uc=(e=>(e.CHANGE="zoom-domain-change",e))(Uc||{}),Bc=(e=>(e.CANVAS_ZOOM_IN="canvas-zoom-in",e.CANVAS_ZOOM_OUT="canvas-zoom-out",e))(Bc||{}),Hc=(e=>(e.LABEL_MOUSEOVER="axis-label-mouseover",e.LABEL_MOUSEMOVE="axis-label-mousemove",e.LABEL_CLICK="axis-label-click",e.LABEL_MOUSEOUT="axis-label-mouseout",e.LABEL_FOCUS="axis-label-focus",e.LABEL_BLUR="axis-label-blur",e.RENDER_COMPLETE="axis-render-complete",e))(Hc||{}),Gc=(e=>(e.POINT_MOUSEOVER="scatter-mouseover",e.POINT_MOUSEMOVE="scatter-mousemove",e.POINT_CLICK="scatter-click",e.POINT_MOUSEOUT="scatter-mouseout",e))(Gc||{}),Vc=(e=>(e.WORD_MOUSEOVER="wordcloud-word-mouseover",e.WORD_MOUSEMOVE="wordcloud-word-mousemove",e.WORD_CLICK="wordcloud-word-click",e.WORD_MOUSEOUT="wordcloud-word-mouseout",e))(Vc||{}),zc=(e=>(e.SLICE_MOUSEOVER="pie-slice-mouseover",e.SLICE_MOUSEMOVE="pie-slice-mousemove",e.SLICE_CLICK="pie-slice-click",e.SLICE_MOUSEOUT="pie-slice-mouseout",e))(zc||{}),Wc=(e=>(e.ARC_MOUSEOVER="gauge-arc-mouseover",e.ARC_MOUSEMOVE="gauge-arc-mousemove",e.ARC_CLICK="gauge-arc-click",e.ARC_MOUSEOUT="gauge-arc-mouseout",e))(Wc||{}),Yc=(e=>(e.BAR_MOUSEOVER="bar-mouseover",e.BAR_MOUSEMOVE="bar-mousemove",e.BAR_CLICK="bar-click",e.BAR_MOUSEOUT="bar-mouseout",e))(Yc||{}),qc=(e=>(e.BOX_MOUSEOVER="box-mouseover",e.BOX_MOUSEMOVE="box-mousemove",e.BOX_CLICK="box-click",e.BOX_MOUSEOUT="box-mouseout",e.OUTLIER_MOUSEOVER="outlier-mouseover",e.OUTLIER_MOUSEMOVE="outlier-mousemove",e.OUTLIER_CLICK="outlier-click",e.OUTLIER_MOUSEOUT="outlier-mouseout",e))(qc||{}),Xc=(e=>(e.SCATTER_MOUSEOVER="scatter-mouseover",e.SCATTER_MOUSEMOVE="scatter-mousemove",e.SCATTER_CLICK="scatter-click",e.SCATTER_MOUSEOUT="scatter-mouseout",e))(Xc||{}),jc=(e=>(e.POINT_MOUSEOVER="scatter-mouseover",e.POINT_MOUSEMOVE="scatter-mousemove",e.POINT_CLICK="scatter-click",e.POINT_MOUSEOUT="scatter-mouseout",e))(jc||{}),Zc=(e=>(e.X_AXIS_MOUSEOVER="radar-x-axis-mouseover",e.X_AXIS_MOUSEMOVE="radar-x-axis-mousemove",e.X_AXIS_CLICK="radar-x-axis-click",e.X_AXIS_MOUSEOUT="radar-x-axis-mouseout",e))(Zc||{}),Kc=(e=>(e.NODE_MOUSEOVER="tree-node-mouseover",e.NODE_CLICK="tree-node-click",e.NODE_MOUSEOUT="tree-node-mouseout",e))(Kc||{}),Qc=(e=>(e.LEAF_MOUSEOVER="leaf-mouseover",e.LEAF_MOUSEMOVE="leaf-mousemove",e.LEAF_CLICK="leaf-click",e.LEAF_MOUSEOUT="leaf-mouseout",e))(Qc||{}),Gr=(e=>(e.SHOW="show-tooltip",e.MOVE="move-tooltip",e.HIDE="hide-tooltip",e))(Gr||{}),Jc=(e=>(e.SHOW="show-threshold",e.HIDE="hide-threshold",e))(Jc||{}),jg=(e=>(e.ITEM_HOVER="legend-item-onhover",e.ITEM_CLICK="legend-item-onclick",e.ITEM_MOUSEOUT="legend-item-onmouseout",e.ITEMS_UPDATE="legend-items-update",e))(jg||{}),Zg=(e=>(e.CIRCLE_MOUSEOVER="circle-leaf-mouseover",e.CIRCLE_CLICK="circle-leaf-click",e.CIRCLE_MOUSEOUT="circle-leaf-mouseout",e.CIRCLE_MOUSEMOVE="circle-leaf-mousemove",e))(Zg||{}),Kg=(e=>(e.NODE_MOUSEOVER="alluvial-node-mouseover",e.NODE_CLICK="alluvial-node-click",e.NODE_MOUSEOUT="alluvial-node-mouseout",e.NODE_MOUSEMOVE="alluvial-node-mousemove",e.LINE_MOUSEOVER="alluvial-line-mouseover",e.LINE_CLICK="alluvial-line-click",e.LINE_MOUSEOUT="alluvial-line-mouseout",e.LINE_MOUSEMOVE="alluvial-line-mousemove",e))(Kg||{}),Qg=(e=>(e.METER_MOUSEOVER="meter-mouseover",e.METER_CLICK="meter-click",e.METER_MOUSEOUT="meter-mouseout",e.METER_MOUSEMOVE="meter-mousemove",e))(Qg||{}),Jg=(e=>(e.HEATMAP_MOUSEOVER="heatmap-mouseover",e.HEATMAP_CLICK="heatmap-click",e.HEATMAP_MOUSEOUT="heatmap-mouseout",e.HEATMAP_MOUSEMOVE="hetmap-mousemove",e))(Jg||{}),Vr=(e=>(e.CHOROPLETH_MOUSEOVER="choropleth-mouseover",e.CHOROPLETH_CLICK="choropleth-click",e.CHOROPLETH_MOUSEOUT="choropleth-mouseout",e.CHOROPLETH_MOUSEMOVE="choropleth-mousemove",e))(Vr||{});const T=Object.freeze(Object.defineProperty({__proto__:null,Alluvial:Kg,Area:Gc,Axis:Hc,Bar:Yc,Boxplot:qc,CanvasZoom:Bc,Chart:Pc,Choropleth:Vr,CirclePack:Zg,Gauge:Wc,Heatmap:Jg,Legend:jg,Line:jc,Meter:Qg,Modal:Nc,Model:$c,Pie:zc,Radar:Zc,Scatter:Xc,Threshold:Jc,Toolbar:Xg,Tooltip:Gr,Tree:Kc,Treemap:Qc,WordCloud:Vc,ZoomBar:Fc,ZoomDomain:Uc},Symbol.toStringTag,{value:"Module"}));var et=(e=>(e.HTML="html",e.SVG="svg",e))(et||{}),tu=(e=>(e.WHITE="white",e.G100="g100",e.G90="g90",e.G10="g10",e))(tu||{}),at=(e=>(e.BACKGROUND="background",e.FILL="fill",e.STROKE="stroke",e.TOOLTIP="tooltip",e))(at||{}),V=(e=>(e.LEFT="left",e.RIGHT="right",e.TOP="top",e.BOTTOM="bottom",e))(V||{}),Ve=(e=>(e.GRAPH_VIEW="graph_view",e.SLIDER_VIEW="slider_view",e))(Ve||{}),Le=(e=>(e.END_LINE="end_line",e.MID_LINE="mid_line",e.FRONT_LINE="front_line",e.NONE="none",e))(Le||{}),Ht=(e=>(e.VERTICAL="vertical",e.HORIZONTAL="horizontal",e))(Ht||{}),J=(e=>(e.TIME="time",e.LINEAR="linear",e.LOG="log",e.LABELS="labels",e.LABELS_RATIO="labels-ratio",e))(J||{}),zr=(e=>(e.RIGHT="right",e.LEFT="left",e.TOP="top",e.BOTTOM="bottom",e))(zr||{}),Gt=(e=>(e.LEFT="left",e.CENTER="center",e.RIGHT="right",e))(Gt||{}),Wr=(e=>(e.HORIZONTAL="horizontal",e.VERTICAL="vertical",e))(Wr||{}),Wa=(e=>(e.TREE="tree",e.DENDROGRAM="dendrogram",e))(Wa||{}),Mt=(e=>(e.ROW="row",e.COLUMN="column",e.ROW_REVERSE="row-reverse",e.COLUMN_REVERSE="column-reverse",e))(Mt||{}),ct=(e=>(e.FIXED="fixed",e.PREFERRED="preferred",e.STRETCH="stretch",e))(ct||{}),or=(e=>(e.CENTER="center",e))(or||{}),es=(e=>(e.LEFT="left",e.RIGHT="right",e))(es||{}),Vt=(e=>(e.GRID="grid",e.VERT_OR_HORIZ="vertOrHoriz",e.PIE="pie",e.DONUT="donut",e))(Vt||{}),en=(e=>(e.START="start",e.MIDDLE="middle",e.END="end",e))(en||{}),nn=(e=>(e.BASELINE="baseline",e.MIDDLE="middle",e.HANGING="hanging",e))(nn||{}),lr=(e=>(e.SEMI="semi",e.FULL="full",e))(lr||{}),Ya=(e=>(e.UP="up",e.DOWN="down",e))(Ya||{}),ns=(e=>(e.SUCCESS="success",e.WARNING="warning",e.DANGER="danger",e))(ns||{}),rs=(e=>(e.ALWAYS="always",e.AUTO="auto",e.NEVER="never",e))(rs||{}),xe=(e=>(e.SCATTER="scatter",e.LINE="line",e.SIMPLE_BAR="simple-bar",e.STACKED_BAR="stacked-bar",e.GROUPED_BAR="grouped-bar",e.AREA="area",e.STACKED_AREA="stacked-area",e))(xe||{}),_t=(e=>(e.EXPORT_CSV="Export as CSV",e.EXPORT_PNG="Export as PNG",e.EXPORT_JPG="Export as JPG",e.ZOOM_IN="Zoom in",e.ZOOM_OUT="Zoom out",e.RESET_ZOOM="Reset zoom",e.MAKE_FULLSCREEN="Make fullscreen",e.EXIT_FULLSCREEN="Exit fullscreen",e.SHOW_AS_DATATABLE="Show as data-table",e.CUSTOM="Custom",e))(_t||{}),qa=(e=>(e.LEFT="left",e.RIGHT="right",e))(qa||{}),zt=(e=>(e.CHECKBOX="checkbox",e.RADIUS="radius",e.AREA="area",e.SIZE="size",e.LINE="line",e.QUARTILE="quartile",e.ZOOM="zoom",e))(zt||{}),is=(e=>(e.LINEAR="linear",e.QUANTIZE="quantize",e))(is||{}),Yr=(e=>(e.ON="on",e.AUTO="auto",e.OFF="off",e))(Yr||{}),ss=(e=>(e.DEFAULT="default",e.HOVERABLE="hoverable",e))(ss||{}),rn=(e=>(e.geoEqualEarth="geoEqualEarth",e.geoAlbers="geoAlbers",e.geoConicEqualArea="geoConicEqualArea",e.geoConicEquidistant="geoConicEquidistant",e.geoEquirectangular="geoEquirectangular",e.geoMercator="geoMercator",e.geoNaturalEarth1="geoNaturalEarth1",e))(rn||{});const de="cds",Sn={opacity:{unselected:.05,selected:.4}},Pn={ticks:{number:7,rotateIfSmallerThan:30,verticalSpaceRatio:2.5,horizontalSpaceRatio:3.5},ratio:{reference:"value",compareTo:"marker"},paddingRatio:.1,hover:{rectanglePadding:4}},qr={duration:1e3,ease:Jh,zoomLevel:3},Xr={circles:{fillOpacity:.3,hover:{stroke:"#FFF"}},padding:{mainGroup:4,children:2},hierarchyLevel:2},tm={pairingOptions:{"1-color":4,"2-color":5,"3-color":5,"4-color":3,"5-color":2,"14-color":1}},Re={circle:{radius:4,opacity:{hovered:1,default:.3}},box:{opacity:{hovered:.5,default:.3}},strokeWidth:{default:1,thicker:2}},$L={defaultBins:10},Nt={items:{status:{ACTIVE:1,DISABLED:0},horizontalSpace:12,verticalSpace:24,textYOffset:8,spaceAfter:4},checkbox:{radius:6.5},radius:{iconData:[{cx:7,cy:7,r:6.5},{cx:7,cy:10,r:3.5}],fill:null,stroke:"#8c8c8c"},line:{yPosition:6,width:24,strokeWidth:1.4,fill:null,stroke:"#999999"},area:{width:24,height:14,fill:"#6f6f6f",stroke:null},size:{iconData:[{width:23,height:12},{width:13,height:6}],fill:null,stroke:"#8D8D8D"},quartile:{iconData:[{x:0,y:0,width:24,height:13},{x:11,y:4,width:1,height:4}]},zoom:{iconData:[{x:0,y:0,width:12,height:12}],color:"#8D8D8D"},color:{barWidth:300,barHeight:8,axisYTranslation:10}},Tn={opacity:{unselected:.3,selected:1},weight:{selected:2,unselected:1}},jt={statusBar:{paddingRight:5},status:{indicatorSize:16,paddingLeft:15},total:{paddingLeft:36,paddingRight:24},height:{default:8,proportional:16},dividerWidth:2},Rt={radiusOffset:-15,innerRadius:2,padAngle:.007,hoverArc:{outerRadiusOffset:3},xOffset:30,yOffset:20,yOffsetCallout:10,callout:{minSliceDegree:5,offsetX:15,offsetY:12,horizontalLineLength:8,textMargin:2}},cr={opacity:{unselected:.1,selected:.3},xLabelPadding:10,yLabelPadding:8,yTicksNumber:4,minRange:10,xAxisRectHeight:50,dotsRadius:5},ze={nodeWidth:4,nodeHoveredWidth:8,minNodePadding:24,opacity:{unfocus:.3,default:.8,selected:1}},em={minCellDividerDimension:16,chartPadding:.5},nm={default:{size:24}},FL={defaultOffset:4,horizontalOffset:10},rm={default:{duration:300},pie_slice_mouseover:{duration:100},pie_slice_mouseout:{duration:100},pie_chart_titles:{duration:375},graph_element_mouseover_fill_update:{duration:100},graph_element_mouseout_fill_update:{duration:100}},be={height:{[Ve.GRAPH_VIEW]:32,[Ve.SLIDER_VIEW]:10},spacerHeight:8,handleWidth:5,handleBarWidth:1,handleBarHeight:12},UL=[{type:zt.RADIUS,name:"Radius"},{type:zt.AREA,name:"Poor area"},{type:zt.AREA,name:"Satisfactory area"},{type:zt.AREA,name:"Great area"},{type:zt.QUARTILE,name:"Quartiles"}];function BL(e,t,n){let r=null;return function(...i){const s=this;s.mousePosition=zn(i[0],n),clearTimeout(r),r=setTimeout(function(){e.apply(s,i)},t)}}function Pt(e,t){var i;const n=_n(e),r=Object.keys(t.axes||{});(i=t==null?void 0:t.toolbar)!=null&&i.controls&&delete n.toolbar.controls,r.length===0&&delete n.axes;for(const s in n.axes)if(r.includes(s)){const a=t.axes[s];(a.primary||a.secondary)&&console.warn("`primary` & `secondary` are no longer needed for axis configurations. Read more here https://charts.carbondesignsystem.com/?path=/story/docs-tutorials--tabular-data-format");const o=a.mapsTo;if(o==null){const l=a.scaleType;l==null?a.mapsTo="value":l===J.TIME?a.mapsTo="date":l===J.LABELS&&(a.mapsTo="key")}}else delete n.axes[s];return nu(n,t),lt(n,t)}function On(e){if(!e)return;const t=/translate\([0-9]+\.?[0-9]*,[0-9]+\.?[0-9]*\)/,n=e.getAttribute("transform").match(t);if(!n)return null;if(n[0]){const r=n[0].replace(/translate\(/,"").replace(/\)/,"").split(",");return{tx:r[0],ty:r[1]}}return null}function as(e){const n=/\(([^)]+)\)/.exec(e);if(n&&n.length>1){const r=n[1].split(",");if(r.length>1)return{x:parseFloat(r[0]),y:parseFloat(r[1])}}return{x:0,y:0}}function eu(e,t,n="value",r=!1){const i=e/t.reduce((s,a)=>s+a[n],0)*100;return r?i:i%1!==0?parseFloat(i.toFixed(1)):i}function os(e,t,n){if(n>e.length)return e;if(t===Le.MID_LINE)return e.substr(0,n/2)+"..."+e.substr(-n/2);if(t===Le.FRONT_LINE)return"..."+e.substr(-n);if(t===Le.END_LINE)return e.substr(0,n)+"..."}function nu(e,t){const n=x(e,"legend","additionalItems"),r=x(t,"legend","additionalItems");if(n&&r){const i=r.map(o=>o.type),s=n.map(o=>o.type),a=UL.filter(o=>s.includes(o.type)&&!i.includes(o.type));e.legend.additionalItems=a,t.legend.additionalItems=NL(a,r,"name")}}const x=(e,...t)=>{let n=e;if(n){for(const r of t)if(n[r]!==null&&n[r]!==void 0)n=n[r];else return null;return n}return null},im=(e,t)=>t===Ht.HORIZONTAL?{y0:e.x0,y1:e.x1,x0:e.y0,x1:e.y1}:e,ie=(e,t)=>{const{x0:n,x1:r,y0:i,y1:s}=im(e,t);return`M${n},${i}L${n},${s}L${r},${s}L${r},${i}L${n},${i}`};function wn(e,t,n){return n===Ht.VERTICAL?[e,t]:[t,e]}function ru(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}function ls(e){return(t,n)=>{const r=n!=null&&n.context?String(n.context):"standalone";let i;if(r==="formatting"&&e.formattingValues){const a=e.defaultFormattingWidth||e.defaultWidth,o=n!=null&&n.width?String(n.width):a;i=e.formattingValues[o]||e.formattingValues[a]}else{const a=e.defaultWidth,o=n!=null&&n.width?String(n.width):e.defaultWidth;i=e.values[o]||e.values[a]}const s=e.argumentCallback?e.argumentCallback(t):t;return i[s]}}function cs(e){return(t,n={})=>{const r=n.width,i=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],s=t.match(i);if(!s)return null;const a=s[0],o=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],l=Array.isArray(o)?GL(o,d=>d.test(a)):HL(o,d=>d.test(a));let c;c=e.valueCallback?e.valueCallback(l):l,c=n.valueCallback?n.valueCallback(c):c;const u=t.slice(a.length);return{value:c,rest:u}}}function HL(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function GL(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function VL(e){return(t,n={})=>{const r=t.match(e.matchPattern);if(!r)return null;const i=r[0],s=t.match(e.parsePattern);if(!s)return null;let a=e.valueCallback?e.valueCallback(s[0]):s[0];a=n.valueCallback?n.valueCallback(a):a;const o=t.slice(i.length);return{value:a,rest:o}}}function xt(e){const t=Object.prototype.toString.call(e);return e instanceof Date||typeof e=="object"&&t==="[object Date]"?new e.constructor(+e):typeof e=="number"||t==="[object Number]"||typeof e=="string"||t==="[object String]"?new Date(e):new Date(NaN)}let zL={};function Xa(){return zL}function us(e,t){var o,l,c,u;const n=Xa(),r=(t==null?void 0:t.weekStartsOn)??((l=(o=t==null?void 0:t.locale)==null?void 0:o.options)==null?void 0:l.weekStartsOn)??n.weekStartsOn??((u=(c=n.locale)==null?void 0:c.options)==null?void 0:u.weekStartsOn)??0,i=xt(e),s=i.getDay(),a=(s<r?7:0)+s-r;return i.setDate(i.getDate()-a),i.setHours(0,0,0,0),i}const WL={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},YL=(e,t,n)=>{let r;const i=WL[e];return typeof i=="string"?r=i:t===1?r=i.one:r=i.other.replace("{{count}}",t.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r},qL={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},XL=(e,t,n,r)=>qL[e],jL={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},ZL={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},KL={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},QL={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},JL={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},tR={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},eR={ordinalNumber:(e,t)=>{const n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},era:ls({values:jL,defaultWidth:"wide"}),quarter:ls({values:ZL,defaultWidth:"wide",argumentCallback:e=>e-1}),month:ls({values:KL,defaultWidth:"wide"}),day:ls({values:QL,defaultWidth:"wide"}),dayPeriod:ls({values:JL,defaultWidth:"wide",formattingValues:tR,defaultFormattingWidth:"wide"})},nR=/^(\d+)(th|st|nd|rd)?/i,rR=/\d+/i,iR={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},sR={any:[/^b/i,/^(a|c)/i]},aR={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},oR={any:[/1/i,/2/i,/3/i,/4/i]},lR={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},cR={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},uR={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},hR={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},dR={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},fR={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},pR={ordinalNumber:VL({matchPattern:nR,parsePattern:rR,valueCallback:e=>parseInt(e,10)}),era:cs({matchPatterns:iR,defaultMatchWidth:"wide",parsePatterns:sR,defaultParseWidth:"any"}),quarter:cs({matchPatterns:aR,defaultMatchWidth:"wide",parsePatterns:oR,defaultParseWidth:"any",valueCallback:e=>e+1}),month:cs({matchPatterns:lR,defaultMatchWidth:"wide",parsePatterns:cR,defaultParseWidth:"any"}),day:cs({matchPatterns:uR,defaultMatchWidth:"wide",parsePatterns:hR,defaultParseWidth:"any"}),dayPeriod:cs({matchPatterns:dR,defaultMatchWidth:"any",parsePatterns:fR,defaultParseWidth:"any"})},gR={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},mR={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},vR={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},yR={date:ru({formats:gR,defaultWidth:"full"}),time:ru({formats:mR,defaultWidth:"full"}),dateTime:ru({formats:vR,defaultWidth:"full"})},sm={code:"en-US",formatDistance:YL,formatLong:yR,formatRelative:XL,localize:eR,match:pR,options:{weekStartsOn:0,firstWeekContainsDate:1}},jr={type:Le.END_LINE,threshold:16,numCharacter:14},ER={code:typeof navigator<"u"&&(navigator==null?void 0:navigator.language)||"en-US",number:(e,t=(navigator==null?void 0:navigator.language)||"en-US")=>e.toLocaleString(t),date:(e,t=(navigator==null?void 0:navigator.language)||"en-US",n={},r=null)=>r||e.toLocaleDateString(t,n),time:(e,t=(navigator==null?void 0:navigator.language)||"en-US",n={},r=null)=>r||e.toLocaleTimeString(t,n),optionsObject:{"15seconds":{primary:{"MMM d, pp":{month:"short",day:"numeric",hour:"numeric",minute:"2-digit",second:"2-digit",hourCycle:"h12"},"MMM d, h:mm:ss.SSS a":{month:"short",day:"numeric",hour:"numeric",minute:"2-digit",fractionalSecondDigits:3,hourCycle:"h12"}},secondary:{pp:{hour:"numeric",minute:"2-digit",second:"2-digit",hourCycle:"h12"},"h:mm:ss.SSS a":{hour:"numeric",minute:"2-digit",fractionalSecondDigits:3,hourCycle:"h12"}},type:"time"},minute:{primary:{"MMM d, p":{month:"short",day:"numeric",hour:"numeric",minute:"2-digit",hourCycle:"h12"}},secondary:{p:{hour:"numeric",minute:"2-digit",hourCycle:"h12"}},type:"time"},"30minutes":{primary:{"MMM d, p":{month:"short",day:"numeric",hour:"numeric",minute:"2-digit",hourCycle:"h12"}},secondary:{p:{hour:"numeric",minute:"2-digit",hourCycle:"h12"}},type:"time"},hourly:{primary:{"MMM d, hh a":{month:"short",day:"numeric",hour:"2-digit",hourCycle:"h12"}},secondary:{"hh a":{hour:"2-digit",hourCycle:"h12"}},type:"time"},daily:{primary:{"MMM d":{month:"short",day:"numeric"}},secondary:{d:{day:"numeric"}},type:"date"},weekly:{primary:{"eee, MMM d":{weekday:"short",month:"short",day:"numeric"}},secondary:{eee:{weekday:"short"}},type:"date"},monthly:{primary:{"MMM yyyy":{month:"short",year:"numeric"}},secondary:{MMM:{month:"short"}},type:"date"},quarterly:{primary:{},secondary:{},type:"date"},yearly:{primary:{yyyy:{year:"numeric"}},secondary:{yyyy:{year:"numeric"}},type:"date"}},translations:{group:"Group",total:"Total",meter:{title:""},tabularRep:{title:"Tabular representation",downloadAsCSV:"Download as CSV"},toolbar:{exportAsCSV:"Export to CSV",exportAsJPG:"Export to JPG",exportAsPNG:"Export to PNG",zoomIn:"Zoom in",zoomOut:"Zoom out",resetZoom:"Reset zoom",moreOptions:"More options",makeFullScreen:"Make fullscreen",exitFullScreen:"Exit fullscreen",showAsTable:"Show as table"}}},xR={enabled:!0,position:zr.BOTTOM,clickable:!0,truncation:jr,alignment:Gt.LEFT,order:null,additionalItems:[]},bR={x:{enabled:!0,numberOfTicks:15,alignWithAxisTicks:!1},y:{enabled:!0,numberOfTicks:5,alignWithAxisTicks:!1}},_R={enabled:!0},am={enabled:!0,showTotal:!0,truncation:jr,groupLabel:"Group"},om={top:{visible:!0,includeZero:!0,truncation:jr},bottom:{visible:!0,includeZero:!0,truncation:jr},left:{visible:!0,includeZero:!0,truncation:jr},right:{visible:!0,includeZero:!0,truncation:jr}},ja={addSpaceOnEdges:1,showDayName:!1,localeObject:sm,timeIntervalFormats:{"15seconds":{primary:"MMM d, pp",secondary:"pp"},minute:{primary:"MMM d, p",secondary:"p"},"30minutes":{primary:"MMM d, p",secondary:"p"},hourly:{primary:"MMM d, hh a",secondary:"hh a"},daily:{primary:"MMM d",secondary:"d"},weekly:{primary:"eee, MMM d",secondary:"eee"},monthly:{primary:"MMM yyyy",secondary:"MMM"},quarterly:{primary:"QQQ ''yy",secondary:"QQQ"},yearly:{primary:"yyyy",secondary:"yyyy"}}};let lm=!1;try{lm=typeof document<"u"&&(document.fullscreenEnabled||document.webkitFullscreenEnabled||document.mozFullScreenEnabled||document.msFullscreenEnabled)}catch(e){console.warn("Fullscreen capabilities check failed: ",e.message)}const ee={width:null,height:null,resizable:!0,theme:tu.WHITE,tooltip:am,legend:xR,locale:ER,style:{prefix:"cc"},data:{groupMapsTo:"group",loading:!1,selectedGroups:[]},color:{scale:null,pairing:{numberOfVariants:null,option:1},gradient:{enabled:!1}},toolbar:{enabled:!0,numberOfIcons:3,controls:[{type:_t.SHOW_AS_DATATABLE},...lm?[{type:_t.MAKE_FULLSCREEN}]:[],{type:_t.EXPORT_CSV},{type:_t.EXPORT_PNG},{type:_t.EXPORT_JPG}]}},cm=lt({},ee,{thematic:{projection:rn.geoNaturalEarth1}}),hs=lt({},ee,{axes:om,timeScale:ja,grid:bR,ruler:_R,zoomBar:{zoomRatio:.4,minZoomRatio:.01,top:{enabled:!1,type:Ve.GRAPH_VIEW}}}),ur=lt({},hs,{bars:{maxWidth:16,spacingFactor:.25},timeScale:lt(ja,{addSpaceOnEdges:1})}),SR=lt({},ur,{}),TR=lt({},ur,{}),OR=lt({},ur,{bars:lt({},ur.bars,{dividerSize:1.5})}),wR=lt({},ur,{}),iu=lt({},hs,{points:{radius:4,fillOpacity:.3,filled:!0,enabled:!0}}),MR=iu,um=lt({},iu,{points:{radius:3,filled:!1,enabled:!0}}),hm=lt({},um,{timeScale:lt(ja,{addSpaceOnEdges:0})}),AR=hm,CR=lt({},hs,{bubble:{radiusMapsTo:"radius",radiusLabel:"Radius",radiusRange:e=>{const t=Math.min(e.width,e.height);return[t*3/400,t*25/400]},fillOpacity:.2,enabled:!0},points:{filled:!0},legend:{additionalItems:[{type:zt.RADIUS,name:"Radius"}]}}),DR=lt({},hs,{bullet:{performanceAreaTitles:["Poor","Satisfactory","Great"]},grid:{x:{enabled:!1},y:{enabled:!1}},legend:{additionalItems:[{type:zt.AREA,name:"Poor area"},{type:zt.AREA,name:"Satisfactory area"},{type:zt.AREA,name:"Great area"},{type:zt.QUARTILE,name:"Quartiles"}]}}),LR=lt({},ur,{bars:{dividerSize:1.5},timeScale:lt(ja,{addSpaceOnEdges:0})}),RR=lt({},ee,{tooltip:lt({},am,{wordLabel:"Word",valueLabel:"Value"}),wordCloud:{fontSizeMapsTo:"value",fontSizeRange:e=>{const t=Math.min(e.width,e.height);return[t*20/400,t*75/400]},wordMapsTo:"word"}}),dm=lt({},ee,{pie:{labels:{formatter:null,enabled:!0},alignment:Gt.LEFT,sortFunction:null,valueMapsTo:"value"}}),IR=lt({},ee,{legend:{enabled:!1},gauge:{type:lr.SEMI,arcWidth:16,deltaArrow:{size:e=>e/8,enabled:!0},showPercentageSymbol:!0,status:null,numberSpacing:10,deltaFontSize:e=>e/8,valueFontSize:e=>e/2.5,alignment:Gt.LEFT}}),kR=lt({},dm,{donut:{center:{numberFontSize:e=>`${Math.min(e/100*24,24)}px`,titleFontSize:e=>`${Math.min(e/100*15,15)}px`,titleYPosition:e=>Math.min(e/80*20,20)},alignment:Gt.LEFT}}),fm=lt({},ee,{legend:{enabled:!1,clickable:!1},meter:{showLabels:!0,proportional:null,statusBar:{percentageIndicator:{enabled:!0}}}}),PR=lt({},fm,{legend:{enabled:!0}}),NR=lt({},ee,{radar:{axes:{angle:"key",value:"value"},alignment:Gt.LEFT},tooltip:{gridline:{enabled:!0}}}),$R=lt({},ur,{comboChartTypes:[]}),FR=lt({tree:{type:Wa.TREE}},ee,{}),UR=lt({},ee,{data:lt(ee.data,{groupMapsTo:"name"})}),BR=lt({},ee,Xr,{data:lt(ee.data,{groupMapsTo:"name"})}),HR=lt({},ee,{alluvial:{data:lt(ee.data,{groupMapsTo:"source"}),nodeAlignment:Gt.CENTER,nodePadding:24,monochrome:!1,nodes:[]}}),GR=lt({},ee,{axes:om,heatmap:{divider:{state:Yr.AUTO},colorLegend:{type:"linear"}}}),VR=lt({},cm,{choropleth:{colorLegend:{type:"linear"}}}),At={alluvialChart:HR,areaChart:hm,axisChart:hs,boxplotChart:wR,bubbleChart:CR,bulletChart:DR,chart:ee,circlePackChart:BR,choroplethChart:VR,comboChart:$R,donutChart:kR,gaugeChart:IR,groupedBarChart:TR,heatmapChart:GR,histogramChart:LR,lineChart:um,lollipopChart:MR,meterChart:fm,pieChart:dm,proportionalMeterChart:PR,radarChart:NR,scatterChart:iu,simpleBarChart:SR,stackedAreaChart:AR,stackedBarChart:OR,thematicChart:cm,treeChart:FR,treemapChart:UR,wordCloudChart:RR},pm=6048e5,zR=864e5,gm=6e4,mm=36e5;function vm(e){const t=xt(e);return t.setHours(0,0,0,0),t}function ym(e){const t=xt(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+e-+n}function Em(e,t){const n=vm(e),r=vm(t),i=+n-ym(n),s=+r-ym(r);return Math.round((i-s)/zR)}function We(e,t){return e instanceof Date?new e.constructor(t):new Date(t)}function WR(e){const t=xt(e),n=We(e,0);return n.setFullYear(t.getFullYear(),0,1),n.setHours(0,0,0,0),n}function YR(e){const t=xt(e);return Em(t,WR(t))+1}function Za(e){return us(e,{weekStartsOn:1})}function xm(e){const t=xt(e),n=t.getFullYear(),r=We(e,0);r.setFullYear(n+1,0,4),r.setHours(0,0,0,0);const i=Za(r),s=We(e,0);s.setFullYear(n,0,4),s.setHours(0,0,0,0);const a=Za(s);return t.getTime()>=i.getTime()?n+1:t.getTime()>=a.getTime()?n:n-1}function qR(e){const t=xm(e),n=We(e,0);return n.setFullYear(t,0,4),n.setHours(0,0,0,0),Za(n)}function XR(e){const t=xt(e),n=+Za(t)-+qR(t);return Math.round(n/pm)+1}function bm(e,t){var u,d,h,f;const n=xt(e),r=n.getFullYear(),i=Xa(),s=(t==null?void 0:t.firstWeekContainsDate)??((d=(u=t==null?void 0:t.locale)==null?void 0:u.options)==null?void 0:d.firstWeekContainsDate)??i.firstWeekContainsDate??((f=(h=i.locale)==null?void 0:h.options)==null?void 0:f.firstWeekContainsDate)??1,a=We(e,0);a.setFullYear(r+1,0,s),a.setHours(0,0,0,0);const o=us(a,t),l=We(e,0);l.setFullYear(r,0,s),l.setHours(0,0,0,0);const c=us(l,t);return n.getTime()>=o.getTime()?r+1:n.getTime()>=c.getTime()?r:r-1}function jR(e,t){var o,l,c,u;const n=Xa(),r=(t==null?void 0:t.firstWeekContainsDate)??((l=(o=t==null?void 0:t.locale)==null?void 0:o.options)==null?void 0:l.firstWeekContainsDate)??n.firstWeekContainsDate??((u=(c=n.locale)==null?void 0:c.options)==null?void 0:u.firstWeekContainsDate)??1,i=bm(e,t),s=We(e,0);return s.setFullYear(i,0,r),s.setHours(0,0,0,0),us(s,t)}function ZR(e,t){const n=xt(e),r=+us(n,t)-+jR(n,t);return Math.round(r/pm)+1}function Ot(e,t){const n=e<0?"-":"",r=Math.abs(e).toString().padStart(t,"0");return n+r}const Nn={y(e,t){const n=e.getFullYear(),r=n>0?n:1-n;return Ot(t==="yy"?r%100:r,t.length)},M(e,t){const n=e.getMonth();return t==="M"?String(n+1):Ot(n+1,2)},d(e,t){return Ot(e.getDate(),t.length)},a(e,t){const n=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];case"aaaa":default:return n==="am"?"a.m.":"p.m."}},h(e,t){return Ot(e.getHours()%12||12,t.length)},H(e,t){return Ot(e.getHours(),t.length)},m(e,t){return Ot(e.getMinutes(),t.length)},s(e,t){return Ot(e.getSeconds(),t.length)},S(e,t){const n=t.length,r=e.getMilliseconds(),i=Math.trunc(r*Math.pow(10,n-3));return Ot(i,t.length)}},Zr={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},_m={G:function(e,t,n){const r=e.getFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});case"GGGG":default:return n.era(r,{width:"wide"})}},y:function(e,t,n){if(t==="yo"){const r=e.getFullYear(),i=r>0?r:1-r;return n.ordinalNumber(i,{unit:"year"})}return Nn.y(e,t)},Y:function(e,t,n,r){const i=bm(e,r),s=i>0?i:1-i;if(t==="YY"){const a=s%100;return Ot(a,2)}return t==="Yo"?n.ordinalNumber(s,{unit:"year"}):Ot(s,t.length)},R:function(e,t){const n=xm(e);return Ot(n,t.length)},u:function(e,t){const n=e.getFullYear();return Ot(n,t.length)},Q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"Q":return String(r);case"QQ":return Ot(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"q":return String(r);case"qq":return Ot(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(e,t,n){const r=e.getMonth();switch(t){case"M":case"MM":return Nn.M(e,t);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(e,t,n){const r=e.getMonth();switch(t){case"L":return String(r+1);case"LL":return Ot(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(e,t,n,r){const i=ZR(e,r);return t==="wo"?n.ordinalNumber(i,{unit:"week"}):Ot(i,t.length)},I:function(e,t,n){const r=XR(e);return t==="Io"?n.ordinalNumber(r,{unit:"week"}):Ot(r,t.length)},d:function(e,t,n){return t==="do"?n.ordinalNumber(e.getDate(),{unit:"date"}):Nn.d(e,t)},D:function(e,t,n){const r=YR(e);return t==="Do"?n.ordinalNumber(r,{unit:"dayOfYear"}):Ot(r,t.length)},E:function(e,t,n){const r=e.getDay();switch(t){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});case"EEEE":default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(e,t,n,r){const i=e.getDay(),s=(i-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(s);case"ee":return Ot(s,2);case"eo":return n.ordinalNumber(s,{unit:"day"});case"eee":return n.day(i,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(i,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(i,{width:"short",context:"formatting"});case"eeee":default:return n.day(i,{width:"wide",context:"formatting"})}},c:function(e,t,n,r){const i=e.getDay(),s=(i-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(s);case"cc":return Ot(s,t.length);case"co":return n.ordinalNumber(s,{unit:"day"});case"ccc":return n.day(i,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(i,{width:"narrow",context:"standalone"});case"cccccc":return n.day(i,{width:"short",context:"standalone"});case"cccc":default:return n.day(i,{width:"wide",context:"standalone"})}},i:function(e,t,n){const r=e.getDay(),i=r===0?7:r;switch(t){case"i":return String(i);case"ii":return Ot(i,t.length);case"io":return n.ordinalNumber(i,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});case"iiii":default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(e,t,n){const i=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},b:function(e,t,n){const r=e.getHours();let i;switch(r===12?i=Zr.noon:r===0?i=Zr.midnight:i=r/12>=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(i,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},B:function(e,t,n){const r=e.getHours();let i;switch(r>=17?i=Zr.evening:r>=12?i=Zr.afternoon:r>=4?i=Zr.morning:i=Zr.night,t){case"B":case"BB":case"BBB":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(i,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},h:function(e,t,n){if(t==="ho"){let r=e.getHours()%12;return r===0&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return Nn.h(e,t)},H:function(e,t,n){return t==="Ho"?n.ordinalNumber(e.getHours(),{unit:"hour"}):Nn.H(e,t)},K:function(e,t,n){const r=e.getHours()%12;return t==="Ko"?n.ordinalNumber(r,{unit:"hour"}):Ot(r,t.length)},k:function(e,t,n){let r=e.getHours();return r===0&&(r=24),t==="ko"?n.ordinalNumber(r,{unit:"hour"}):Ot(r,t.length)},m:function(e,t,n){return t==="mo"?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):Nn.m(e,t)},s:function(e,t,n){return t==="so"?n.ordinalNumber(e.getSeconds(),{unit:"second"}):Nn.s(e,t)},S:function(e,t){return Nn.S(e,t)},X:function(e,t,n){const r=e.getTimezoneOffset();if(r===0)return"Z";switch(t){case"X":return Tm(r);case"XXXX":case"XX":return hr(r);case"XXXXX":case"XXX":default:return hr(r,":")}},x:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"x":return Tm(r);case"xxxx":case"xx":return hr(r);case"xxxxx":case"xxx":default:return hr(r,":")}},O:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+Sm(r,":");case"OOOO":default:return"GMT"+hr(r,":")}},z:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+Sm(r,":");case"zzzz":default:return"GMT"+hr(r,":")}},t:function(e,t,n){const r=Math.trunc(e.getTime()/1e3);return Ot(r,t.length)},T:function(e,t,n){const r=e.getTime();return Ot(r,t.length)}};function Sm(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),i=Math.trunc(r/60),s=r%60;return s===0?n+String(i):n+String(i)+t+Ot(s,2)}function Tm(e,t){return e%60===0?(e>0?"-":"+")+Ot(Math.abs(e)/60,2):hr(e,t)}function hr(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),i=Ot(Math.trunc(r/60),2),s=Ot(r%60,2);return n+i+t+s}const Om=(e,t)=>{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},wm=(e,t)=>{switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},KR={p:wm,P:(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],r=n[1],i=n[2];if(!i)return Om(e,t);let s;switch(r){case"P":s=t.dateTime({width:"short"});break;case"PP":s=t.dateTime({width:"medium"});break;case"PPP":s=t.dateTime({width:"long"});break;case"PPPP":default:s=t.dateTime({width:"full"});break}return s.replace("{{date}}",Om(r,t)).replace("{{time}}",wm(i,t))}},QR=/^D+$/,JR=/^Y+$/,tI=["D","DD","YY","YYYY"];function eI(e){return QR.test(e)}function nI(e){return JR.test(e)}function rI(e,t,n){const r=iI(e,t,n);if(console.warn(r),tI.includes(e))throw new RangeError(r)}function iI(e,t,n){const r=e[0]==="Y"?"years":"days of the month";return`Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${t}\`) for formatting ${r} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}function sI(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function aI(e){if(!sI(e)&&typeof e!="number")return!1;const t=xt(e);return!isNaN(Number(t))}const oI=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,lI=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,cI=/^'([^]*?)'?$/,uI=/''/g,hI=/[a-zA-Z]/;function su(e,t,n){var u,d,h,f,p,g,m,v;const r=Xa(),i=(n==null?void 0:n.locale)??r.locale??sm,s=(n==null?void 0:n.firstWeekContainsDate)??((d=(u=n==null?void 0:n.locale)==null?void 0:u.options)==null?void 0:d.firstWeekContainsDate)??r.firstWeekContainsDate??((f=(h=r.locale)==null?void 0:h.options)==null?void 0:f.firstWeekContainsDate)??1,a=(n==null?void 0:n.weekStartsOn)??((g=(p=n==null?void 0:n.locale)==null?void 0:p.options)==null?void 0:g.weekStartsOn)??r.weekStartsOn??((v=(m=r.locale)==null?void 0:m.options)==null?void 0:v.weekStartsOn)??0,o=xt(e);if(!aI(o))throw new RangeError("Invalid time value");let l=t.match(lI).map(E=>{const y=E[0];if(y==="p"||y==="P"){const b=KR[y];return b(E,i.formatLong)}return E}).join("").match(oI).map(E=>{if(E==="''")return{isToken:!1,value:"'"};const y=E[0];if(y==="'")return{isToken:!1,value:dI(E)};if(_m[y])return{isToken:!0,value:E};if(y.match(hI))throw new RangeError("Format string contains an unescaped latin alphabet character `"+y+"`");return{isToken:!1,value:E}});i.localize.preprocessor&&(l=i.localize.preprocessor(o,l));const c={firstWeekContainsDate:s,weekStartsOn:a,locale:i};return l.map(E=>{if(!E.isToken)return E.value;const y=E.value;(!(n!=null&&n.useAdditionalWeekYearTokens)&&nI(y)||!(n!=null&&n.useAdditionalDayOfYearTokens)&&eI(y))&&rI(y,t,String(e));const b=_m[y[0]];return b(o,y,i.localize,c)}).join("")}function dI(e){const t=e.match(cI);return t?t[1].replace(uI,"'"):e}var Mm=(e=>(e["15seconds"]="15seconds",e.minute="minute",e["30minutes"]="30minutes",e.hourly="hourly",e.daily="daily",e.weekly="weekly",e.monthly="monthly",e.quarterly="quarterly",e.yearly="yearly",e))(Mm||{});const au=[["15seconds",15*1e3],["minute",60*1e3],["30minutes",30*60*1e3],["hourly",60*60*1e3],["daily",24*60*60*1e3],["monthly",30*24*60*60*1e3],["quarterly",3*30*24*60*60*1e3],["yearly",12*30*24*60*60*1e3]];function Am(e,t,n,r,i){const s=t===0,a=Number(su(new Date(e),"c"))===2,o=Number(su(new Date(e),"q"))===1,l=t!==0?n[t-1]:null;switch(r){case"15seconds":return s||Qa(e)||ds(e,l)||$n(e);case"minute":return s||Qa(e)||ds(e,l)||$n(e);case"30minutes":return s||Qa(e)||ds(e,l)||$n(e);case"hourly":return s||Qa(e)||ds(e,l)||$n(e);case"daily":return i?s||a||$n(e):s||ds(e,l)||$n(e);case"weekly":return s||a||$n(e);case"monthly":return s||$n(e);case"quarterly":return s||o;case"yearly":return!1;default:throw new Error(`${r} is not a valid time interval.`)}}function ou(e,t,n,r,i,s){const a=i.showDayName,o=r==="daily"&&a?"weekly":r,l=new Date(e),c=x(i,"timeIntervalFormats")[o],u=x(c,"primary"),d=x(c,"secondary"),h=Am(e,t,n,r,a);let f=h?u:d;r==="15seconds"&&l.getMilliseconds()!==0&&(f=f.replace("pp","h:mm:ss.SSS a"));const p=i.localeObject,{code:g,optionsObject:m}=s,v=m[r].type,E=m[r][h?"primary":"secondary"][f];if(r==="quarterly"||!E){const b=su(l,f,{locale:p}).split("").map(S=>{const _=Number(S);return S!==" "&&!Number.isNaN(_)?_.toLocaleString(g):S});return s[v](l,g,{},b.join(""))}else return s[v](l,g,E)}function Ka(e){const t=new Date(e);return{M:t.getMonth()+1,d:t.getDate(),H:t.getHours(),m:t.getMinutes(),s:t.getSeconds()}}function fI(e){if(e)return e.slice(1).map((t,n)=>t-e[n])}function pI(e){const t=au.reduce((n,[,r],i)=>{const s=au[n][1],a=Math.abs(s-e),o=Math.abs(r-e);return a<o?n:i},0);return au[t][0]}function lu(e,t){if(Mm[t])return t;if(e.length===1)return"15seconds";const n=fI(e),r=Rn(n);return pI(r)}function Qa(e){const{s:t,m:n,H:r}=Ka(e);return r===0&&n===0&&t===0}function ds(e,t){const n=Ka(e).M,r=Ka(t).M;return n!==r}function $n(e){const{M:t,d:n,s:r,m:i,H:s}=Ka(e);return t===1&&n===1&&s===0&&i===0&&r===0}function Cm(e){return e===void 0?"":e.toISOString()}function gI(e){const t=e.trim();return["=","+","-","@"," ","\r"].includes(t.charAt(0))?` ${t}`:/[,\"\n]/.test(t)?`"${t}"`:t}class sn{constructor(t){this.state={options:{}},this.colorScale={},this.colorClassNames={},this.services=t}formatTable({headers:t,cells:n}){const r=this.getOptions(),{code:i,date:s,number:a}=x(r,"locale"),o=x(r,"tabularRepModal","tableHeadingFormatter"),l=x(r,"tabularRepModal","tableCellFormatter"),{cartesianScales:c}=this.services,u=c==null?void 0:c.getDomainAxisScaleType();let d;return u===J.TIME&&(d=f=>s(f,i,{month:"short",day:"numeric",year:"numeric"})),[typeof o=="function"?o(t):t,...typeof l=="function"?l(n):n.map(f=>{d&&(f[1]=d(f[1]));for(const p in f){const g=f[p];typeof g=="number"&&(f[p]=a(g,i))}return f})]}getAllDataFromDomain(t){if(!this.getData())return null;const n=this.getOptions();let r=this.getData();const i=this.getDataGroups(),{groupMapsTo:s}=x(n,"data"),a=x(n,"axes");return t&&(r=r.filter(o=>t.includes(o[s]))),a&&Object.keys(a).forEach(o=>{const l=a[o].mapsTo,c=a[o].scaleType;if((c===J.LINEAR||c===J.LOG)&&(r=r.map(u=>({...u,[l]:u[l]===null?u[l]:Number(u[l])}))),l&&a[o].domain)if(c===J.LABELS)r=r.filter(u=>a[o].domain.includes(u[l]));else{const[u,d]=a[o].domain;r=r.filter(h=>!(l in h)||h[l]>=u&&h[l]<=d)}}),r.filter(o=>i.find(l=>l.name===o[s]))}getDisplayData(t){if(!this.get("data"))return null;const{ACTIVE:n}=Nt.items.status,r=this.getDataGroups(t),{groupMapsTo:i}=this.getOptions().data;return this.getAllDataFromDomain(t).filter(a=>r.find(o=>o.name===a[i]&&o.status===n))}getData(){return this.get("data")}isDataEmpty(){return!this.getData().length}setData(t){const n=this.sanitize(_n(t)),r=this.generateDataGroups(n);return this.set({data:n,dataGroups:r}),n}getDataGroups(t){return x(this.getOptions(),"data","loading")?[]:t?this.get("dataGroups").filter(r=>t.includes(r.name)):this.get("dataGroups")}getActiveDataGroups(t){const{ACTIVE:n}=Nt.items.status;return this.getDataGroups(t).filter(r=>r.status===n)}getDataGroupNames(t){return this.getDataGroups(t).map(r=>r.name)}getActiveDataGroupNames(t){return this.getActiveDataGroups(t).map(r=>r.name)}aggregateBinDataByGroup(t){return EL(t,"group")}getBinConfigurations(){const t=this.getDisplayData(),n=this.getOptions(),r=this.services.cartesianScales.getMainXAxisPosition(),i=this.services.cartesianScales.getDomainIdentifier(),s=n.axes[r],{groupMapsTo:a}=n.data,{bins:o=$L.defaultBins}=s,l=Array.isArray(o),c=N0().value(f=>f[i]).thresholds(o)(t);if(l)c[c.length-1].x1=o[o.length-1];else{const f=c[0].x1-c[0].x0;c[c.length-1].x1=+c[c.length-1].x0+f}const u=l?[o[0],o[o.length-1]]:[c[0].x0,c[c.length-1].x1],d=Array.from(new Set(t.map(f=>f[a]))),h=[];return c.forEach(f=>{const p=`${f.x0}-${f.x1}`,g=this.aggregateBinDataByGroup(f);d.forEach(m=>{h.push({group:m,key:p,value:g[m]||0,bin:f.x0})})}),{bins:c,binsDomain:u}}getBinnedStackedData(){const t=this.getOptions(),{groupMapsTo:n}=t.data,r=this.getActiveDataGroupNames(),{bins:i}=this.getBinConfigurations(),s=this.getDataValuesGroupedByKeys({bins:i});return ic().keys(r)(s).map((a,o)=>Object.keys(a).filter(l=>!isNaN(l)).map(l=>{const c=a[l];return c[n]=r[o],c}))}getGroupedData(t){const n=this.getDisplayData(t),r={},{groupMapsTo:i}=this.getOptions().data;return n.map(s=>{const a=s[i];r[a]!==null&&r[a]!==void 0?r[a].push(s):r[a]=[s]}),Object.keys(r).map(s=>({name:s,data:r[s]}))}getStackKeys({bins:t=null,groups:n=null}={bins:null,groups:null}){const r=this.getOptions(),i=this.getDisplayData(n);let s;t?s=t.map(l=>`${l.x0}:${l.x1}`):s=ts(i.map(l=>{const c=this.services.cartesianScales.getDomainIdentifier(l);return l[c]instanceof Date?Cm(l[c]):l[c]&&typeof l[c].toString=="function"?l[c].toString():l[c]}));const a=this.services.cartesianScales.domainAxisPosition,o=r.axes[a].scaleType;return o===J.TIME?s.sort((l,c)=>{const u=new Date(l),d=new Date(c);return u-d}):(o===J.LOG||o===J.LINEAR)&&s.sort((l,c)=>l-c),s}getDataValuesGroupedByKeys({bins:t=null,groups:n=null}){const r=this.getOptions(),{groupMapsTo:i}=r.data,s=this.getDisplayData(n),a=this.getDataGroupNames(),o=this.getStackKeys({bins:t,groups:n});return t?o.map(l=>{const[c,u]=l.split(":"),d={x0:c,x1:u},h=t.find(f=>f.x0.toString()===c.toString());return a.forEach(f=>{d[f]=h.filter(p=>p[i]===f).length}),d}):o.map(l=>{const c={sharedStackKey:l};return a.forEach(u=>{const d=s.find(f=>{const p=this.services.cartesianScales.getDomainIdentifier(f);return f[i]===u&&Object.prototype.hasOwnProperty.call(f,p)&&(f[p]instanceof Date?Cm(f[p])===l:f[p].toString()===l)}),h=this.services.cartesianScales.getRangeIdentifier(c);c[u]=d?d[h]:null}),c})}getStackedData({percentage:t=!1,groups:n=null,divergent:r=!1}){const i=this.getOptions(),{groupMapsTo:s}=i.data,a=this.getActiveDataGroupNames(n),o=this.getDataValuesGroupedByKeys({groups:n});if(t){const c=mL(o.map(u=>[u.sharedStackKey,0]));o.forEach(u=>{a.forEach(d=>{c[u.sharedStackKey]+=u[d]})}),o.forEach(u=>{a.forEach(d=>{const h=c[u.sharedStackKey];c[u.sharedStackKey]?u[d]=u[d]/h*100:u[d]=0})})}return(r?ic().offset(HT):ic()).keys(a)(o).map((c,u)=>Object.keys(c).filter(d=>!isNaN(d)).map(d=>{const h=c[d];return h[s]=a[u],h}))}getOptions(){return this.state.options}set(t,n){this.state=Object.assign({},this.state,t);const r=Object.assign({skipUpdate:!1,animate:!0},n);r.skipUpdate||this.update(r.animate)}get(t){return t?this.state[t]:this.state}setOptions(t){const n=this.getOptions();nu(n,t),this.set({options:lt(n,t)})}update(t=!0){this.getDisplayData()&&(this.updateAllDataGroups(),this.setCustomColorScale(),this.setColorClassNames(),this.services.events.dispatchEvent(T.Model.UPDATE,{animate:t}))}toggleDataLabel(t){const{ACTIVE:n,DISABLED:r}=Nt.items.status,i=this.getDataGroups(),s=i.some(u=>u.status===r),a=i.filter(u=>u.status===n);if(s)if(a.length===1&&a[0].name===t)i.forEach((u,d)=>{i[d].status=n});else{const u=i.findIndex(d=>d.name===t);i[u].status=i[u].status===r?n:r}else i.forEach((u,d)=>{i[d].status=u.name===t?n:r});const o=i.filter(u=>u.status===n),l=this.getOptions();i.some(u=>u.status===r)?l.data.selectedGroups=o.map(u=>u.name):l.data.selectedGroups=[],this.services.events.dispatchEvent(T.Legend.ITEMS_UPDATE,{dataGroups:i}),this.set({dataGroups:i})}getIsFilled(t,n,r,i){const s=this.getOptions();return s.getIsFilled?s.getIsFilled(t,n,r,i):i}getFillColor(t,n,r){const i=this.getOptions(),s=x(this.colorScale,t);return i.getFillColor?i.getFillColor(t,n,r,s):s}getStrokeColor(t,n,r){const i=this.getOptions(),s=x(this.colorScale,t);return i.getStrokeColor?i.getStrokeColor(t,n,r,s):s}isUserProvidedColorScaleValid(){const t=x(this.getOptions(),"color","scale"),n=this.getDataGroups();return t==null||Object.keys(t).length==0?!1:n.some(r=>Object.keys(t).includes(r.name))}getColorClassName(t){const n=this.colorClassNames(t.dataGroupName);let r=t.originalClassName;return t.classNameTypes.forEach(i=>r=t.originalClassName?`${r} ${i}-${n}`:`${i}-${n}`),r||""}getStatus(){return null}getAllDataGroupsNames(){return this.allDataGroups}transformToTabularData(t){console.warn("We've updated the charting data format to be tabular by default. The current format you're using is deprecated and will be removed in v1.0, read more here https://charts.carbondesignsystem.com/");const n=[],{datasets:r,labels:i}=t;return r.forEach(s=>{s.data.forEach((a,o)=>{let l;const c=x(s,"label");if(c===null){const d=x(i,o);d?l=d:l="Ungrouped"}else l=c;const u={group:l,key:i[o]};isNaN(a)?(u.value=a.value,u.date=a.date):u.value=a,n.push(u)})}),n}getTabularDataArray(){return[]}exportToCSV(){const n=this.getTabularDataArray().map(a=>a.map(o=>`"${(o==="–"?"–":o).split(/[,;'"`]/).map(u=>gI(u)).join("")}"`)).map(a=>a.join(",")).join(`
|
|
2
2
|
`),r=this.getOptions();let i="myChart";const s=x(r,"fileDownload","fileName");typeof s=="function"?i=s("csv"):typeof s=="string"&&(i=s),this.services.files.downloadCSV(n,`${i}.csv`)}getTabularData(t){return Array.isArray(t)?t:this.transformToTabularData(t)}sanitize(t){return t=this.getTabularData(t),t}updateAllDataGroups(){this.allDataGroups?this.getDataGroupNames().forEach(t=>{this.allDataGroups.indexOf(t)===-1&&this.allDataGroups.push(t)}):this.allDataGroups=this.getDataGroupNames()}generateDataGroups(t){const{groupMapsTo:n}=this.getOptions().data,{ACTIVE:r,DISABLED:i}=Nt.items.status,s=this.getOptions(),a=ts(t.map(l=>l[n]));s.data.selectedGroups.length&&(s.data.selectedGroups.every(c=>a.includes(c))||(s.data.selectedGroups=[]));const o=l=>!s.data.selectedGroups.length||s.data.selectedGroups.includes(l)?r:i;return a.map(l=>({name:l,status:o(l)}))}setCustomColorScale(){if(!this.isUserProvidedColorScaleValid())return;const t=this.getOptions(),n=x(t,"color","scale");Object.keys(n).forEach(i=>{this.allDataGroups.includes(i)||console.warn(`"${i}" does not exist in data groups.`)}),this.allDataGroups.filter(i=>n[i]).forEach(i=>this.colorScale[i]=n[i])}setColorClassNames(){const t=x(this.getOptions(),"color","pairing");let n=x(t,"numberOfVariants");(!n||n<this.allDataGroups.length)&&(n=this.allDataGroups.length);let r=x(t,"option");const i=tm.pairingOptions,s=n>5?14:n,a=`${s}-color`;r=r<=i[a]?r:1;const o=this.allDataGroups.map((l,c)=>`${s}-${r}-${c%14+1}`);this.colorClassNames=ga().range(o).domain(this.allDataGroups)}}function mI(e,t){if(e.match(/^[a-z]+:\/\//i))return e;if(e.match(/^\/\//))return window.location.protocol+e;if(e.match(/^[a-z]+:/i))return e;const n=document.implementation.createHTMLDocument(),r=n.createElement("base"),i=n.createElement("a");return n.head.appendChild(r),n.body.appendChild(i),t&&(r.href=t),i.href=e,i.href}const vI=(()=>{let e=0;const t=()=>`0000${(Math.random()*36**4<<0).toString(36)}`.slice(-4);return()=>(e+=1,`u${t()}${e}`)})();function Mn(e){const t=[];for(let n=0,r=e.length;n<r;n++)t.push(e[n]);return t}function Ja(e,t){const r=(e.ownerDocument.defaultView||window).getComputedStyle(e).getPropertyValue(t);return r?parseFloat(r.replace("px","")):0}function yI(e){const t=Ja(e,"border-left-width"),n=Ja(e,"border-right-width");return e.clientWidth+t+n}function EI(e){const t=Ja(e,"border-top-width"),n=Ja(e,"border-bottom-width");return e.clientHeight+t+n}function Dm(e,t={}){const n=t.width||yI(e),r=t.height||EI(e);return{width:n,height:r}}function xI(){let e,t;try{t=process}catch{}const n=t&&t.env?t.env.devicePixelRatio:null;return n&&(e=parseInt(n,10),Number.isNaN(e)&&(e=1)),e||window.devicePixelRatio||1}const _e=16384;function bI(e){(e.width>_e||e.height>_e)&&(e.width>_e&&e.height>_e?e.width>e.height?(e.height*=_e/e.width,e.width=_e):(e.width*=_e/e.height,e.height=_e):e.width>_e?(e.height*=_e/e.width,e.width=_e):(e.width*=_e/e.height,e.height=_e))}function to(e){return new Promise((t,n)=>{const r=new Image;r.decode=()=>t(r),r.onload=()=>t(r),r.onerror=n,r.crossOrigin="anonymous",r.decoding="async",r.src=e})}async function _I(e){return Promise.resolve().then(()=>new XMLSerializer().serializeToString(e)).then(encodeURIComponent).then(t=>`data:image/svg+xml;charset=utf-8,${t}`)}async function SI(e,t,n){const r="http://www.w3.org/2000/svg",i=document.createElementNS(r,"svg"),s=document.createElementNS(r,"foreignObject");return i.setAttribute("width",`${t}`),i.setAttribute("height",`${n}`),i.setAttribute("viewBox",`0 0 ${t} ${n}`),s.setAttribute("width","100%"),s.setAttribute("height","100%"),s.setAttribute("x","0"),s.setAttribute("y","0"),s.setAttribute("externalResourcesRequired","true"),i.appendChild(s),s.appendChild(e),_I(i)}const fe=(e,t)=>{if(e instanceof t)return!0;const n=Object.getPrototypeOf(e);return n===null?!1:n.constructor.name===t.name||fe(n,t)};function TI(e){const t=e.getPropertyValue("content");return`${e.cssText} content: '${t.replace(/'|"/g,"")}';`}function OI(e){return Mn(e).map(t=>{const n=e.getPropertyValue(t),r=e.getPropertyPriority(t);return`${t}: ${n}${r?" !important":""};`}).join(" ")}function wI(e,t,n){const r=`.${e}:${t}`,i=n.cssText?TI(n):OI(n);return document.createTextNode(`${r}{${i}}`)}function Lm(e,t,n){const r=window.getComputedStyle(e,n),i=r.getPropertyValue("content");if(i===""||i==="none")return;const s=vI();try{t.className=`${t.className} ${s}`}catch{return}const a=document.createElement("style");a.appendChild(wI(s,n,r)),t.appendChild(a)}function MI(e,t){Lm(e,t,":before"),Lm(e,t,":after")}const Rm="application/font-woff",Im="image/jpeg",AI={woff:Rm,woff2:Rm,ttf:"application/font-truetype",eot:"application/vnd.ms-fontobject",png:"image/png",jpg:Im,jpeg:Im,gif:"image/gif",tiff:"image/tiff",svg:"image/svg+xml",webp:"image/webp"};function CI(e){const t=/\.([^./]*?)$/g.exec(e);return t?t[1]:""}function cu(e){const t=CI(e).toLowerCase();return AI[t]||""}function DI(e){return e.split(/,/)[1]}function uu(e){return e.search(/^(data:)/)!==-1}function LI(e,t){return`data:${t};base64,${e}`}async function km(e,t,n){const r=await fetch(e,t);if(r.status===404)throw new Error(`Resource "${r.url}" not found`);const i=await r.blob();return new Promise((s,a)=>{const o=new FileReader;o.onerror=a,o.onloadend=()=>{try{s(n({res:r,result:o.result}))}catch(l){a(l)}},o.readAsDataURL(i)})}const hu={};function RI(e,t,n){let r=e.replace(/\?.*/,"");return n&&(r=e),/ttf|otf|eot|woff2?/i.test(r)&&(r=r.replace(/.*\//,"")),t?`[${t}]${r}`:r}async function du(e,t,n){const r=RI(e,t,n.includeQueryParams);if(hu[r]!=null)return hu[r];n.cacheBust&&(e+=(/\?/.test(e)?"&":"?")+new Date().getTime());let i;try{const s=await km(e,n.fetchRequestInit,({res:a,result:o})=>(t||(t=a.headers.get("Content-Type")||""),DI(o)));i=LI(s,t)}catch(s){i=n.imagePlaceholder||"";let a=`Failed to fetch resource: ${e}`;s&&(a=typeof s=="string"?s:s.message),a&&console.warn(a)}return hu[r]=i,i}async function II(e){const t=e.toDataURL();return t==="data:,"?e.cloneNode(!1):to(t)}async function kI(e,t){if(e.currentSrc){const s=document.createElement("canvas"),a=s.getContext("2d");s.width=e.clientWidth,s.height=e.clientHeight,a==null||a.drawImage(e,0,0,s.width,s.height);const o=s.toDataURL();return to(o)}const n=e.poster,r=cu(n),i=await du(n,r,t);return to(i)}async function PI(e){var t;try{if(!((t=e==null?void 0:e.contentDocument)===null||t===void 0)&&t.body)return await eo(e.contentDocument.body,{},!0)}catch{}return e.cloneNode(!1)}async function NI(e,t){return fe(e,HTMLCanvasElement)?II(e):fe(e,HTMLVideoElement)?kI(e,t):fe(e,HTMLIFrameElement)?PI(e):e.cloneNode(!1)}const $I=e=>e.tagName!=null&&e.tagName.toUpperCase()==="SLOT";async function FI(e,t,n){var r,i;let s=[];return $I(e)&&e.assignedNodes?s=Mn(e.assignedNodes()):fe(e,HTMLIFrameElement)&&(!((r=e.contentDocument)===null||r===void 0)&&r.body)?s=Mn(e.contentDocument.body.childNodes):s=Mn(((i=e.shadowRoot)!==null&&i!==void 0?i:e).childNodes),s.length===0||fe(e,HTMLVideoElement)||await s.reduce((a,o)=>a.then(()=>eo(o,n)).then(l=>{l&&t.appendChild(l)}),Promise.resolve()),t}function UI(e,t){const n=t.style;if(!n)return;const r=window.getComputedStyle(e);r.cssText?(n.cssText=r.cssText,n.transformOrigin=r.transformOrigin):Mn(r).forEach(i=>{let s=r.getPropertyValue(i);i==="font-size"&&s.endsWith("px")&&(s=`${Math.floor(parseFloat(s.substring(0,s.length-2)))-.1}px`),fe(e,HTMLIFrameElement)&&i==="display"&&s==="inline"&&(s="block"),i==="d"&&t.getAttribute("d")&&(s=`path(${t.getAttribute("d")})`),n.setProperty(i,s,r.getPropertyPriority(i))})}function BI(e,t){fe(e,HTMLTextAreaElement)&&(t.innerHTML=e.value),fe(e,HTMLInputElement)&&t.setAttribute("value",e.value)}function HI(e,t){if(fe(e,HTMLSelectElement)){const n=t,r=Array.from(n.children).find(i=>e.value===i.getAttribute("value"));r&&r.setAttribute("selected","")}}function GI(e,t){return fe(t,Element)&&(UI(e,t),MI(e,t),BI(e,t),HI(e,t)),t}async function VI(e,t){const n=e.querySelectorAll?e.querySelectorAll("use"):[];if(n.length===0)return e;const r={};for(let s=0;s<n.length;s++){const o=n[s].getAttribute("xlink:href");if(o){const l=e.querySelector(o),c=document.querySelector(o);!l&&c&&!r[o]&&(r[o]=await eo(c,t,!0))}}const i=Object.values(r);if(i.length){const s="http://www.w3.org/1999/xhtml",a=document.createElementNS(s,"svg");a.setAttribute("xmlns",s),a.style.position="absolute",a.style.width="0",a.style.height="0",a.style.overflow="hidden",a.style.display="none";const o=document.createElementNS(s,"defs");a.appendChild(o);for(let l=0;l<i.length;l++)o.appendChild(i[l]);e.appendChild(a)}return e}async function eo(e,t,n){return!n&&t.filter&&!t.filter(e)?null:Promise.resolve(e).then(r=>NI(r,t)).then(r=>FI(e,r,t)).then(r=>GI(e,r)).then(r=>VI(r,t))}const Pm=/url\((['"]?)([^'"]+?)\1\)/g,zI=/url\([^)]+\)\s*format\((["']?)([^"']+)\1\)/g,WI=/src:\s*(?:url\([^)]+\)\s*format\([^)]+\)[,;]\s*)+/g;function YI(e){const t=e.replace(/([.*+?^${}()|\[\]\/\\])/g,"\\$1");return new RegExp(`(url\\(['"]?)(${t})(['"]?\\))`,"g")}function qI(e){const t=[];return e.replace(Pm,(n,r,i)=>(t.push(i),n)),t.filter(n=>!uu(n))}async function XI(e,t,n,r,i){try{const s=n?mI(t,n):t,a=cu(t);let o;return i||(o=await du(s,a,r)),e.replace(YI(t),`$1${o}$3`)}catch{}return e}function jI(e,{preferredFontFormat:t}){return t?e.replace(WI,n=>{for(;;){const[r,,i]=zI.exec(n)||[];if(!i)return"";if(i===t)return`src: ${r};`}}):e}function Nm(e){return e.search(Pm)!==-1}async function $m(e,t,n){if(!Nm(e))return e;const r=jI(e,n);return qI(r).reduce((s,a)=>s.then(o=>XI(o,a,t,n)),Promise.resolve(r))}async function no(e,t,n){var r;const i=(r=t.style)===null||r===void 0?void 0:r.getPropertyValue(e);if(i){const s=await $m(i,null,n);return t.style.setProperty(e,s,t.style.getPropertyPriority(e)),!0}return!1}async function ZI(e,t){await no("background",e,t)||await no("background-image",e,t),await no("mask",e,t)||await no("mask-image",e,t)}async function KI(e,t){const n=fe(e,HTMLImageElement);if(!(n&&!uu(e.src))&&!(fe(e,SVGImageElement)&&!uu(e.href.baseVal)))return;const r=n?e.src:e.href.baseVal,i=await du(r,cu(r),t);await new Promise((s,a)=>{e.onload=s,e.onerror=a;const o=e;o.decode&&(o.decode=s),o.loading==="lazy"&&(o.loading="eager"),n?(e.srcset="",e.src=i):e.href.baseVal=i})}async function QI(e,t){const r=Mn(e.childNodes).map(i=>Fm(i,t));await Promise.all(r).then(()=>e)}async function Fm(e,t){fe(e,Element)&&(await ZI(e,t),await KI(e,t),await QI(e,t))}function JI(e,t){const{style:n}=e;t.backgroundColor&&(n.backgroundColor=t.backgroundColor),t.width&&(n.width=`${t.width}px`),t.height&&(n.height=`${t.height}px`);const r=t.style;return r!=null&&Object.keys(r).forEach(i=>{n[i]=r[i]}),e}const Um={};async function Bm(e){let t=Um[e];if(t!=null)return t;const r=await(await fetch(e)).text();return t={url:e,cssText:r},Um[e]=t,t}async function Hm(e,t){let n=e.cssText;const r=/url\(["']?([^"')]+)["']?\)/g,s=(n.match(/url\([^)]+\)/g)||[]).map(async a=>{let o=a.replace(r,"$1");return o.startsWith("https://")||(o=new URL(o,e.url).href),km(o,t.fetchRequestInit,({result:l})=>(n=n.replace(a,`url(${l})`),[a,l]))});return Promise.all(s).then(()=>n)}function Gm(e){if(e==null)return[];const t=[],n=/(\/\*[\s\S]*?\*\/)/gi;let r=e.replace(n,"");const i=new RegExp("((@.*?keyframes [\\s\\S]*?){([\\s\\S]*?}\\s*?)})","gi");for(;;){const l=i.exec(r);if(l===null)break;t.push(l[0])}r=r.replace(i,"");const s=/@import[\s\S]*?url\([^)]*\)[\s\S]*?;/gi,a="((\\s*?(?:\\/\\*[\\s\\S]*?\\*\\/)?\\s*?@media[\\s\\S]*?){([\\s\\S]*?)}\\s*?})|(([\\s\\S]*?){([\\s\\S]*?)})",o=new RegExp(a,"gi");for(;;){let l=s.exec(r);if(l===null){if(l=o.exec(r),l===null)break;s.lastIndex=o.lastIndex}else o.lastIndex=s.lastIndex;t.push(l[0])}return t}async function tk(e,t){const n=[],r=[];return e.forEach(i=>{if("cssRules"in i)try{Mn(i.cssRules||[]).forEach((s,a)=>{if(s.type===CSSRule.IMPORT_RULE){let o=a+1;const l=s.href,c=Bm(l).then(u=>Hm(u,t)).then(u=>Gm(u).forEach(d=>{try{i.insertRule(d,d.startsWith("@import")?o+=1:i.cssRules.length)}catch(h){console.error("Error inserting rule from remote css",{rule:d,error:h})}})).catch(u=>{console.error("Error loading remote css",u.toString())});r.push(c)}})}catch(s){const a=e.find(o=>o.href==null)||document.styleSheets[0];i.href!=null&&r.push(Bm(i.href).then(o=>Hm(o,t)).then(o=>Gm(o).forEach(l=>{a.insertRule(l,i.cssRules.length)})).catch(o=>{console.error("Error loading remote stylesheet",o)})),console.error("Error inlining remote css file",s)}}),Promise.all(r).then(()=>(e.forEach(i=>{if("cssRules"in i)try{Mn(i.cssRules||[]).forEach(s=>{n.push(s)})}catch(s){console.error(`Error while reading CSS rules from ${i.href}`,s)}}),n))}function ek(e){return e.filter(t=>t.type===CSSRule.FONT_FACE_RULE).filter(t=>Nm(t.style.getPropertyValue("src")))}async function nk(e,t){if(e.ownerDocument==null)throw new Error("Provided element is not within a Document");const n=Mn(e.ownerDocument.styleSheets),r=await tk(n,t);return ek(r)}async function rk(e,t){const n=await nk(e,t);return(await Promise.all(n.map(i=>{const s=i.parentStyleSheet?i.parentStyleSheet.href:null;return $m(i.cssText,s,t)}))).join(`
|
|
3
3
|
`)}async function ik(e,t){const n=t.fontEmbedCSS!=null?t.fontEmbedCSS:t.skipFonts?null:await rk(e,t);if(n){const r=document.createElement("style"),i=document.createTextNode(n);r.appendChild(i),e.firstChild?e.insertBefore(r,e.firstChild):e.appendChild(r)}}async function sk(e,t={}){const{width:n,height:r}=Dm(e,t),i=await eo(e,t,!0);return await ik(i,t),await Fm(i,t),JI(i,t),await SI(i,n,r)}async function Vm(e,t={}){const{width:n,height:r}=Dm(e,t),i=await sk(e,t),s=await to(i),a=document.createElement("canvas"),o=a.getContext("2d"),l=t.pixelRatio||xI(),c=t.canvasWidth||n,u=t.canvasHeight||r;return a.width=c*l,a.height=u*l,t.skipAutoScale||bI(a),a.style.width=`${c}`,a.style.height=`${u}`,t.backgroundColor&&(o.fillStyle=t.backgroundColor,o.fillRect(0,0,a.width,a.height)),o.drawImage(s,0,0,a.width,a.height),a}async function ak(e,t={}){return(await Vm(e,t)).toDataURL()}async function ok(e,t={}){return(await Vm(e,t)).toDataURL("image/jpeg",t.quality||1)}class An{constructor(t,n){this.model=t,this.services=n,this.init()}init(){}update(){}setModel(t){this.model=t}setServices(t){this.services=t}}const lk="DONT_STYLE_ME_css_styles_verifier";class I extends An{constructor(t,n){super(t,n)}static getHTMLElementSize(t){return{width:t.clientWidth,height:t.clientHeight}}static getSVGElementSize(t,n={useAttrs:!1,useClientDimensions:!1,useBBox:!1,useBoundingRect:!1}){t.attr||(t=k(t));const r={width:0,height:0},i=h=>{h&&Object.keys(r).forEach(f=>{if(h[f]){const p=h[f],g=parseFloat(p);p&&g>r[f]&&(""+p).indexOf("%")===-1&&(r[f]=g)}})},s={width:t.attr("width"),height:t.attr("height")},a=t.node();let o,l,c,u;try{typeof a.getBBox=="function"&&(o=a.getBBox(),l={width:o.width,height:o.height})}catch(h){console.error(h)}try{typeof(a==null?void 0:a.getBoundingClientRect)=="function"&&(c=a.getBoundingClientRect(),u={width:c.width,height:c.height})}catch(h){console.error(h)}let d;if(a instanceof SVGSVGElement&&(d={width:a.clientWidth,height:a.clientHeight}),n){if(n.useAttrs&&(i(s),r.width>0&&r.height>0))return r;if(n.useClientDimensions&&(i(d),r.width>0&&r.height>0))return d;if(n.useBBox&&(i(l),r.width>0&&r.height>0))return l;if(n.useBoundingRect&&(i(u),r.width>0&&r.height>0))return u}try{const h={width:x(t.node(),"width","baseVal","value"),height:x(t.node(),"height","baseVal","value")};i(h)}catch{i(d),i(l),i(s)}return r}static appendOrSelect(t,n){const r=t.select(`${n}`);if(r.empty()){let i=n.split("#"),s,a;return i.length===2?(s=i[0],i=i[1].split("."),a=i[0]):(i=n.split("."),s=i[0]),t.append(s).attr("id",a).attr("class",i.slice(1).join(" "))}return r}init(){this.initializeID(),this.styleHolderElement(),this.addMainContainer(),this.model.getOptions().resizable&&this.addResizeListener(),this.addHolderListeners(),this.handleFullscreenChange()}getChartID(){return this.chartID}getElementOffset(t,n=!1){const r={left:0,top:0},i=t.getBoundingClientRect(),s=n?{left:0,top:0}:this.getHolder().getBoundingClientRect();try{r.left=i.left-s.left,r.top=i.top-s.top}catch(a){console.error(a)}return r}generateElementIDString(t){return`chart-${this.chartID}-${t}`}initializeID(){this.chartID=Math.floor((1+Math.random())*281474976710656).toString(16)}addMainContainer(){const t=this.model.getOptions(),n=x(t,"style","prefix"),r=k(this.getHolder()).append("div").classed(`${de}--${n}--chart-wrapper`,!0).attr("id",`chart-${this.getChartID()}`).style("height","100%").style("width","100%");r.append("g").attr("class",lk),this.mainContainer=r.node()}update(){this.styleHolderElement()}styleHolderElement(){const t=this.getHolder(),{width:n,height:r,theme:i}=this.model.getOptions();n!==this.width&&(t.style.width=n,this.width=n),r!==this.height&&(t.style.height=r,this.height=r),k(this.getHolder()).classed(`${de}--chart-holder`,!0).attr("data-carbon-theme",i)}getHolder(){return this.model.get("holder")}exportToJPG(){const t=this,n=this.model.getOptions(),r=this.getHolder(),i=k(r);i.classed("filled",!0),ok(this.getMainContainer(),{quality:1,filter:s=>!(s.classList&&s.classList.contains("cds--cc--toolbar"))}).then(function(s){var l;let a="myChart";const o=x(n,"fileDownload","fileName");typeof o=="function"?a=o("jpg"):typeof o=="string"&&(a=o),(l=t.services.files)==null||l.downloadImage(s,`${a}.jpg`),i.classed("filled",!1)})}exportToPNG(){const t=this,n=this.model.getOptions(),r=this.getHolder(),i=k(r);i.classed("filled",!0),ak(this.getMainContainer(),{quality:1,filter:s=>!(s.classList&&s.classList.contains("cds--cc--toolbar"))}).then(function(s){var l;let a="myChart";const o=x(n,"fileDownload","fileName");typeof o=="function"?a=o("png"):typeof o=="string"&&(a=o),(l=t.services.files)==null||l.downloadImage(s,`${a}.png`),i.classed("filled",!1)}).catch(function(s){console.error("oops, something went wrong!",s)})}isFullScreenMode(){return k(this.getHolder()).classed("fullscreen")}toggleFullscreen(){const t=this.getHolder();k(t).classed("fullscreen")&&(document.fullscreenElement||document.webkitFullscreenElement||document.mozFullScreenElement||document.msFullscreenElement)?document.exitFullscreen?document.exitFullscreen():document.webkitExitFullscreen?document.webkitExitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.msExitFullscreen&&document.msExitFullscreen():t.requestFullscreen?t.requestFullscreen():t.webkitRequestFullscreen?t.webkitRequestFullscreen():t.mozRequestFullScreen?t.mozRequestFullScreen():t.msRequestFullscreen&&t.msRequestFullscreen()}handleFullscreenChange(){document.addEventListener("fullscreenchange",()=>{const t=k(this.getHolder()),n=t.classed("fullscreen");t.classed("fullscreen",!n)})}setSVGMaxHeight(){if(!this.model.getOptions().height){const{height:t}=I.getSVGElementSize(k(this.mainContainer),{useBBox:!0}),n=k(this.mainContainer).attr("class"),r=k(this.mainContainer).selectAll(`.${n} > svg`);let i=0;r.nodes().forEach(function(s){i+=Number(I.getSVGElementSize(k(s),{useBBox:!0}).height)}),i<=t?k(this.mainContainer).attr("height",i):k(this.mainContainer).attr("height","100%")}}getMainContainer(){return this.mainContainer}addHolderListeners(){const t=this.getHolder();t&&k(t).on("mouseover",()=>{var n;(n=this.services.events)==null||n.dispatchEvent(T.Chart.MOUSEOVER)}).on("mouseout",()=>{var n;(n=this.services.events)==null||n.dispatchEvent(T.Chart.MOUSEOUT)})}addResizeListener(){const t=this.getHolder();if(!t)return;let n=t.clientWidth,r=t.clientHeight;const i=za(()=>{var a;t&&(Math.abs(n-t.clientWidth)>1||Math.abs(r-t.clientHeight)>1)&&(n=t.clientWidth,r=t.clientHeight,(a=this.services.events)==null||a.dispatchEvent(T.Chart.RESIZE))},12.5);new ResizeObserver(i).observe(t)}}class gt{constructor(t,n,r){if(this.type="",this.renderType=et.HTML,this.id="",this.parent=void 0,this.configs={},this.model=t,this.services=n,r&&(this.configs=r,this.configs.id)){const i=x(this.model.getOptions(),"style","prefix");this.id=`${i}--${this.configs.id}`}this.parent||this.setParent(k(this.services.domUtils.getMainContainer()))}init(){}render(t=!0){console.error("Error: Component did not provide the required render function.")}destroy(){}setModel(t){this.model=t}setServices(t){this.services=t}setParent(t){var r;const n=this.parent;if(this.parent=t,!(n&&n.node()===t.node())&&this.type){const i=x(this.model.getOptions(),"style","prefix");(r=this.parent)==null||r.classed(`${de}--${i}--${this.type}`,!0),n&&n.classed(`${de}--${i}--${this.type}`,!1)}}getParent(){return this.parent}getComponentContainer(t={withinChartClip:!1}){if(this.type){const n=x(this.model.getOptions(),"style","prefix"),r=this.id?`#${this.id}`:"",i=I.appendOrSelect(this.parent,`${this.renderType===et.SVG?"svg":"div"}${r}.${de}--${n}--${this.type}`);if(t.withinChartClip){const s=this.model.get("chartClipId");if(s){const o=k(`#${s}`).select("rect");o.size()!==0&&parseFloat(o.attr("height"))>0&&i.attr("clip-path",`url(#${s})`)}}return i.attr("width","100%").attr("height","100%")}return this.parent}getOptions(){return this.configs.options?lt({},this.model.getOptions(),this.configs.options):this.model.getOptions()}}/*! @license DOMPurify 3.1.5 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.1.5/LICENSE */const{entries:zm,setPrototypeOf:Wm,isFrozen:ck,getPrototypeOf:uk,getOwnPropertyDescriptor:hk}=Object;let{freeze:se,seal:Ie,create:Ym}=Object,{apply:fu,construct:pu}=typeof Reflect<"u"&&Reflect;se||(se=function(t){return t}),Ie||(Ie=function(t){return t}),fu||(fu=function(t,n,r){return t.apply(n,r)}),pu||(pu=function(t,n){return new t(...n)});const ro=Se(Array.prototype.forEach),qm=Se(Array.prototype.pop),fs=Se(Array.prototype.push),io=Se(String.prototype.toLowerCase),gu=Se(String.prototype.toString),Xm=Se(String.prototype.match),ps=Se(String.prototype.replace),dk=Se(String.prototype.indexOf),fk=Se(String.prototype.trim),Ye=Se(Object.prototype.hasOwnProperty),ae=Se(RegExp.prototype.test),gs=pk(TypeError);function Se(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return fu(e,t,r)}}function pk(e){return function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return pu(e,n)}}function mt(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:io;Wm&&Wm(e,null);let r=t.length;for(;r--;){let i=t[r];if(typeof i=="string"){const s=n(i);s!==i&&(ck(t)||(t[r]=s),i=s)}e[i]=!0}return e}function gk(e){for(let t=0;t<e.length;t++)Ye(e,t)||(e[t]=null);return e}function dr(e){const t=Ym(null);for(const[n,r]of zm(e))Ye(e,n)&&(Array.isArray(r)?t[n]=gk(r):r&&typeof r=="object"&&r.constructor===Object?t[n]=dr(r):t[n]=r);return t}function so(e,t){for(;e!==null;){const r=hk(e,t);if(r){if(r.get)return Se(r.get);if(typeof r.value=="function")return Se(r.value)}e=uk(e)}function n(){return null}return n}const jm=se(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),mu=se(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),vu=se(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),mk=se(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),yu=se(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),vk=se(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Zm=se(["#text"]),Km=se(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),Eu=se(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Qm=se(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),ao=se(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),yk=Ie(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Ek=Ie(/<%[\w\W]*|[\w\W]*%>/gm),xk=Ie(/\${[\w\W]*}/gm),bk=Ie(/^data-[\-\w.\u00B7-\uFFFF]/),_k=Ie(/^aria-[\-\w]+$/),Jm=Ie(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Sk=Ie(/^(?:\w+script|data):/i),Tk=Ie(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),tv=Ie(/^html$/i),Ok=Ie(/^[a-z][.\w]*(-[.\w]+)+$/i);var ev=Object.freeze({__proto__:null,MUSTACHE_EXPR:yk,ERB_EXPR:Ek,TMPLIT_EXPR:xk,DATA_ATTR:bk,ARIA_ATTR:_k,IS_ALLOWED_URI:Jm,IS_SCRIPT_OR_DATA:Sk,ATTR_WHITESPACE:Tk,DOCTYPE_NAME:tv,CUSTOM_ELEMENT:Ok});const ms={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,progressingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},wk=function(){return typeof window>"u"?null:window},Mk=function(t,n){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let r=null;const i="data-tt-policy-suffix";n&&n.hasAttribute(i)&&(r=n.getAttribute(i));const s="dompurify"+(r?"#"+r:"");try{return t.createPolicy(s,{createHTML(a){return a},createScriptURL(a){return a}})}catch{return console.warn("TrustedTypes policy "+s+" could not be created."),null}};function nv(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:wk();const t=rt=>nv(rt);if(t.version="3.1.5",t.removed=[],!e||!e.document||e.document.nodeType!==ms.document)return t.isSupported=!1,t;let{document:n}=e;const r=n,i=r.currentScript,{DocumentFragment:s,HTMLTemplateElement:a,Node:o,Element:l,NodeFilter:c,NamedNodeMap:u=e.NamedNodeMap||e.MozNamedAttrMap,HTMLFormElement:d,DOMParser:h,trustedTypes:f}=e,p=l.prototype,g=so(p,"cloneNode"),m=so(p,"nextSibling"),v=so(p,"childNodes"),E=so(p,"parentNode");if(typeof a=="function"){const rt=n.createElement("template");rt.content&&rt.content.ownerDocument&&(n=rt.content.ownerDocument)}let y,b="";const{implementation:S,createNodeIterator:_,createDocumentFragment:A,getElementsByTagName:R}=n,{importNode:B}=r;let D={};t.isSupported=typeof zm=="function"&&typeof E=="function"&&S&&S.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:O,ERB_EXPR:H,TMPLIT_EXPR:P,DATA_ATTR:M,ARIA_ATTR:w,IS_SCRIPT_OR_DATA:U,ATTR_WHITESPACE:$,CUSTOM_ELEMENT:N}=ev;let{IS_ALLOWED_URI:F}=ev,Y=null;const Z=mt({},[...jm,...mu,...vu,...yu,...Zm]);let K=null;const dt=mt({},[...Km,...Eu,...Qm,...ao]);let it=Object.seal(Ym(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),ft=null,j=null,nt=!0,vt=!0,q=!1,Q=!0,ot=!1,C=!0,G=!1,z=!1,Ct=!1,Ut=!1,st=!1,Dt=!1,Hn=!0,Xe=!1;const zU="user-content-";let th=!0,_s=!1,ii={},si=null;const t0=mt({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let e0=null;const n0=mt({},["audio","video","img","source","image","track"]);let eh=null;const r0=mt({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),To="http://www.w3.org/1998/Math/MathML",Oo="http://www.w3.org/2000/svg",Dn="http://www.w3.org/1999/xhtml";let ai=Dn,nh=!1,rh=null;const WU=mt({},[To,Oo,Dn],gu);let Ss=null;const YU=["application/xhtml+xml","text/html"],qU="text/html";let qt=null,oi=null;const XU=n.createElement("form"),i0=function(L){return L instanceof RegExp||L instanceof Function},ih=function(){let L=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(oi&&oi===L)){if((!L||typeof L!="object")&&(L={}),L=dr(L),Ss=YU.indexOf(L.PARSER_MEDIA_TYPE)===-1?qU:L.PARSER_MEDIA_TYPE,qt=Ss==="application/xhtml+xml"?gu:io,Y=Ye(L,"ALLOWED_TAGS")?mt({},L.ALLOWED_TAGS,qt):Z,K=Ye(L,"ALLOWED_ATTR")?mt({},L.ALLOWED_ATTR,qt):dt,rh=Ye(L,"ALLOWED_NAMESPACES")?mt({},L.ALLOWED_NAMESPACES,gu):WU,eh=Ye(L,"ADD_URI_SAFE_ATTR")?mt(dr(r0),L.ADD_URI_SAFE_ATTR,qt):r0,e0=Ye(L,"ADD_DATA_URI_TAGS")?mt(dr(n0),L.ADD_DATA_URI_TAGS,qt):n0,si=Ye(L,"FORBID_CONTENTS")?mt({},L.FORBID_CONTENTS,qt):t0,ft=Ye(L,"FORBID_TAGS")?mt({},L.FORBID_TAGS,qt):{},j=Ye(L,"FORBID_ATTR")?mt({},L.FORBID_ATTR,qt):{},ii=Ye(L,"USE_PROFILES")?L.USE_PROFILES:!1,nt=L.ALLOW_ARIA_ATTR!==!1,vt=L.ALLOW_DATA_ATTR!==!1,q=L.ALLOW_UNKNOWN_PROTOCOLS||!1,Q=L.ALLOW_SELF_CLOSE_IN_ATTR!==!1,ot=L.SAFE_FOR_TEMPLATES||!1,C=L.SAFE_FOR_XML!==!1,G=L.WHOLE_DOCUMENT||!1,Ut=L.RETURN_DOM||!1,st=L.RETURN_DOM_FRAGMENT||!1,Dt=L.RETURN_TRUSTED_TYPE||!1,Ct=L.FORCE_BODY||!1,Hn=L.SANITIZE_DOM!==!1,Xe=L.SANITIZE_NAMED_PROPS||!1,th=L.KEEP_CONTENT!==!1,_s=L.IN_PLACE||!1,F=L.ALLOWED_URI_REGEXP||Jm,ai=L.NAMESPACE||Dn,it=L.CUSTOM_ELEMENT_HANDLING||{},L.CUSTOM_ELEMENT_HANDLING&&i0(L.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(it.tagNameCheck=L.CUSTOM_ELEMENT_HANDLING.tagNameCheck),L.CUSTOM_ELEMENT_HANDLING&&i0(L.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(it.attributeNameCheck=L.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),L.CUSTOM_ELEMENT_HANDLING&&typeof L.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(it.allowCustomizedBuiltInElements=L.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),ot&&(vt=!1),st&&(Ut=!0),ii&&(Y=mt({},Zm),K=[],ii.html===!0&&(mt(Y,jm),mt(K,Km)),ii.svg===!0&&(mt(Y,mu),mt(K,Eu),mt(K,ao)),ii.svgFilters===!0&&(mt(Y,vu),mt(K,Eu),mt(K,ao)),ii.mathMl===!0&&(mt(Y,yu),mt(K,Qm),mt(K,ao))),L.ADD_TAGS&&(Y===Z&&(Y=dr(Y)),mt(Y,L.ADD_TAGS,qt)),L.ADD_ATTR&&(K===dt&&(K=dr(K)),mt(K,L.ADD_ATTR,qt)),L.ADD_URI_SAFE_ATTR&&mt(eh,L.ADD_URI_SAFE_ATTR,qt),L.FORBID_CONTENTS&&(si===t0&&(si=dr(si)),mt(si,L.FORBID_CONTENTS,qt)),th&&(Y["#text"]=!0),G&&mt(Y,["html","head","body"]),Y.table&&(mt(Y,["tbody"]),delete ft.tbody),L.TRUSTED_TYPES_POLICY){if(typeof L.TRUSTED_TYPES_POLICY.createHTML!="function")throw gs('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof L.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw gs('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');y=L.TRUSTED_TYPES_POLICY,b=y.createHTML("")}else y===void 0&&(y=Mk(f,i)),y!==null&&typeof b=="string"&&(b=y.createHTML(""));se&&se(L),oi=L}},s0=mt({},["mi","mo","mn","ms","mtext"]),a0=mt({},["foreignobject","annotation-xml"]),jU=mt({},["title","style","font","a","script"]),o0=mt({},[...mu,...vu,...mk]),l0=mt({},[...yu,...vk]),ZU=function(L){let X=E(L);(!X||!X.tagName)&&(X={namespaceURI:ai,tagName:"template"});const tt=io(L.tagName),It=io(X.tagName);return rh[L.namespaceURI]?L.namespaceURI===Oo?X.namespaceURI===Dn?tt==="svg":X.namespaceURI===To?tt==="svg"&&(It==="annotation-xml"||s0[It]):!!o0[tt]:L.namespaceURI===To?X.namespaceURI===Dn?tt==="math":X.namespaceURI===Oo?tt==="math"&&a0[It]:!!l0[tt]:L.namespaceURI===Dn?X.namespaceURI===Oo&&!a0[It]||X.namespaceURI===To&&!s0[It]?!1:!l0[tt]&&(jU[tt]||!o0[tt]):!!(Ss==="application/xhtml+xml"&&rh[L.namespaceURI]):!1},ln=function(L){fs(t.removed,{element:L});try{L.parentNode.removeChild(L)}catch{L.remove()}},wo=function(L,X){try{fs(t.removed,{attribute:X.getAttributeNode(L),from:X})}catch{fs(t.removed,{attribute:null,from:X})}if(X.removeAttribute(L),L==="is"&&!K[L])if(Ut||st)try{ln(X)}catch{}else try{X.setAttribute(L,"")}catch{}},c0=function(L){let X=null,tt=null;if(Ct)L="<remove></remove>"+L;else{const Zt=Xm(L,/^[\r\n\t ]+/);tt=Zt&&Zt[0]}Ss==="application/xhtml+xml"&&ai===Dn&&(L='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+L+"</body></html>");const It=y?y.createHTML(L):L;if(ai===Dn)try{X=new h().parseFromString(It,Ss)}catch{}if(!X||!X.documentElement){X=S.createDocument(ai,"template",null);try{X.documentElement.innerHTML=nh?b:It}catch{}}const ne=X.body||X.documentElement;return L&&tt&&ne.insertBefore(n.createTextNode(tt),ne.childNodes[0]||null),ai===Dn?R.call(X,G?"html":"body")[0]:G?X.documentElement:ne},u0=function(L){return _.call(L.ownerDocument||L,L,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT|c.SHOW_PROCESSING_INSTRUCTION|c.SHOW_CDATA_SECTION,null)},h0=function(L){return L instanceof d&&(typeof L.nodeName!="string"||typeof L.textContent!="string"||typeof L.removeChild!="function"||!(L.attributes instanceof u)||typeof L.removeAttribute!="function"||typeof L.setAttribute!="function"||typeof L.namespaceURI!="string"||typeof L.insertBefore!="function"||typeof L.hasChildNodes!="function")},d0=function(L){return typeof o=="function"&&L instanceof o},Ln=function(L,X,tt){D[L]&&ro(D[L],It=>{It.call(t,X,tt,oi)})},f0=function(L){let X=null;if(Ln("beforeSanitizeElements",L,null),h0(L))return ln(L),!0;const tt=qt(L.nodeName);if(Ln("uponSanitizeElement",L,{tagName:tt,allowedTags:Y}),L.hasChildNodes()&&!d0(L.firstElementChild)&&ae(/<[/\w]/g,L.innerHTML)&&ae(/<[/\w]/g,L.textContent)||L.nodeType===ms.progressingInstruction||C&&L.nodeType===ms.comment&&ae(/<[/\w]/g,L.data))return ln(L),!0;if(!Y[tt]||ft[tt]){if(!ft[tt]&&g0(tt)&&(it.tagNameCheck instanceof RegExp&&ae(it.tagNameCheck,tt)||it.tagNameCheck instanceof Function&&it.tagNameCheck(tt)))return!1;if(th&&!si[tt]){const It=E(L)||L.parentNode,ne=v(L)||L.childNodes;if(ne&&It){const Zt=ne.length;for(let me=Zt-1;me>=0;--me){const cn=g(ne[me],!0);cn.__removalCount=(L.__removalCount||0)+1,It.insertBefore(cn,m(L))}}}return ln(L),!0}return L instanceof l&&!ZU(L)||(tt==="noscript"||tt==="noembed"||tt==="noframes")&&ae(/<\/no(script|embed|frames)/i,L.innerHTML)?(ln(L),!0):(ot&&L.nodeType===ms.text&&(X=L.textContent,ro([O,H,P],It=>{X=ps(X,It," ")}),L.textContent!==X&&(fs(t.removed,{element:L.cloneNode()}),L.textContent=X)),Ln("afterSanitizeElements",L,null),!1)},p0=function(L,X,tt){if(Hn&&(X==="id"||X==="name")&&(tt in n||tt in XU))return!1;if(!(vt&&!j[X]&&ae(M,X))){if(!(nt&&ae(w,X))){if(!K[X]||j[X]){if(!(g0(L)&&(it.tagNameCheck instanceof RegExp&&ae(it.tagNameCheck,L)||it.tagNameCheck instanceof Function&&it.tagNameCheck(L))&&(it.attributeNameCheck instanceof RegExp&&ae(it.attributeNameCheck,X)||it.attributeNameCheck instanceof Function&&it.attributeNameCheck(X))||X==="is"&&it.allowCustomizedBuiltInElements&&(it.tagNameCheck instanceof RegExp&&ae(it.tagNameCheck,tt)||it.tagNameCheck instanceof Function&&it.tagNameCheck(tt))))return!1}else if(!eh[X]){if(!ae(F,ps(tt,$,""))){if(!((X==="src"||X==="xlink:href"||X==="href")&&L!=="script"&&dk(tt,"data:")===0&&e0[L])){if(!(q&&!ae(U,ps(tt,$,"")))){if(tt)return!1}}}}}}return!0},g0=function(L){return L!=="annotation-xml"&&Xm(L,N)},m0=function(L){Ln("beforeSanitizeAttributes",L,null);const{attributes:X}=L;if(!X)return;const tt={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:K};let It=X.length;for(;It--;){const ne=X[It],{name:Zt,namespaceURI:me,value:cn}=ne,Ts=qt(Zt);let ce=Zt==="value"?cn:fk(cn);if(tt.attrName=Ts,tt.attrValue=ce,tt.keepAttr=!0,tt.forceKeepAttr=void 0,Ln("uponSanitizeAttribute",L,tt),ce=tt.attrValue,tt.forceKeepAttr||(wo(Zt,L),!tt.keepAttr))continue;if(!Q&&ae(/\/>/i,ce)){wo(Zt,L);continue}if(C&&ae(/((--!?|])>)|<\/(style|title)/i,ce)){wo(Zt,L);continue}ot&&ro([O,H,P],y0=>{ce=ps(ce,y0," ")});const v0=qt(L.nodeName);if(p0(v0,Ts,ce)){if(Xe&&(Ts==="id"||Ts==="name")&&(wo(Zt,L),ce=zU+ce),y&&typeof f=="object"&&typeof f.getAttributeType=="function"&&!me)switch(f.getAttributeType(v0,Ts)){case"TrustedHTML":{ce=y.createHTML(ce);break}case"TrustedScriptURL":{ce=y.createScriptURL(ce);break}}try{me?L.setAttributeNS(me,Zt,ce):L.setAttribute(Zt,ce),h0(L)?ln(L):qm(t.removed)}catch{}}}Ln("afterSanitizeAttributes",L,null)},KU=function rt(L){let X=null;const tt=u0(L);for(Ln("beforeSanitizeShadowDOM",L,null);X=tt.nextNode();)Ln("uponSanitizeShadowNode",X,null),!f0(X)&&(X.content instanceof s&&rt(X.content),m0(X));Ln("afterSanitizeShadowDOM",L,null)};return t.sanitize=function(rt){let L=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},X=null,tt=null,It=null,ne=null;if(nh=!rt,nh&&(rt="<!-->"),typeof rt!="string"&&!d0(rt))if(typeof rt.toString=="function"){if(rt=rt.toString(),typeof rt!="string")throw gs("dirty is not a string, aborting")}else throw gs("toString is not a function");if(!t.isSupported)return rt;if(z||ih(L),t.removed=[],typeof rt=="string"&&(_s=!1),_s){if(rt.nodeName){const cn=qt(rt.nodeName);if(!Y[cn]||ft[cn])throw gs("root node is forbidden and cannot be sanitized in-place")}}else if(rt instanceof o)X=c0("<!---->"),tt=X.ownerDocument.importNode(rt,!0),tt.nodeType===ms.element&&tt.nodeName==="BODY"||tt.nodeName==="HTML"?X=tt:X.appendChild(tt);else{if(!Ut&&!ot&&!G&&rt.indexOf("<")===-1)return y&&Dt?y.createHTML(rt):rt;if(X=c0(rt),!X)return Ut?null:Dt?b:""}X&&Ct&&ln(X.firstChild);const Zt=u0(_s?rt:X);for(;It=Zt.nextNode();)f0(It)||(It.content instanceof s&&KU(It.content),m0(It));if(_s)return rt;if(Ut){if(st)for(ne=A.call(X.ownerDocument);X.firstChild;)ne.appendChild(X.firstChild);else ne=X;return(K.shadowroot||K.shadowrootmode)&&(ne=B.call(r,ne,!0)),ne}let me=G?X.outerHTML:X.innerHTML;return G&&Y["!doctype"]&&X.ownerDocument&&X.ownerDocument.doctype&&X.ownerDocument.doctype.name&&ae(tv,X.ownerDocument.doctype.name)&&(me="<!DOCTYPE "+X.ownerDocument.doctype.name+`>
|
|
4
4
|
`+me),ot&&ro([O,H,P],cn=>{me=ps(me,cn," ")}),y&&Dt?y.createHTML(me):me},t.setConfig=function(){let rt=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};ih(rt),z=!0},t.clearConfig=function(){oi=null,z=!1},t.isValidAttribute=function(rt,L,X){oi||ih({});const tt=qt(rt),It=qt(L);return p0(tt,It,X)},t.addHook=function(rt,L){typeof L=="function"&&(D[rt]=D[rt]||[],fs(D[rt],L))},t.removeHook=function(rt){if(D[rt])return qm(D[rt])},t.removeHooks=function(rt){D[rt]&&(D[rt]=[])},t.removeAllHooks=function(){D={}},t}var xu=nv();const oo=e=>xu.sanitize(e,{USE_PROFILES:{html:!0,svg:!0,svgFilters:!0}}),Ak=e=>xu.sanitize(e,{NAMESPACE:"http://www.w3.org/2000/svg",USE_PROFILES:{html:!0,svg:!0,svgFilters:!0}}),an=e=>xu.sanitize(e,{ALLOWED_TAGS:[]}),_o=class _o extends gt{constructor(){super(...arguments),this.type="toolbar",this.renderType=et.HTML}init(){const t=()=>this.updateOverflowMenu(!1);this.services.events.addEventListener(T.Toolbar.SHOW_OVERFLOW_MENU,()=>{this.renderOverflowMenu(),document.body.addEventListener("click",t)}),this.services.events.addEventListener(T.Toolbar.HIDE_OVERFLOW_MENU,()=>{document.body.removeEventListener("click",t)})}render(t=!0){const n=this.getComponentContainer().attr("role","toolbar").attr("aria-label","chart toolbar");if(x(this.getOptions(),"data","loading"))n.html(""),this.overflowMenu=null;else{this.overflowMenu||(this.overflowMenu=n.append("div").attr("class","cds--overflow-menu-options cds--overflow-menu--flip cds--overflow-menu-options cds--overflow-menu--flip").attr("tabindex",-1).html("<ul role='menu'></ul>"));const{buttonList:i,overflowMenuItemList:s}=this.getControlConfigs();s&&i.push(this.getOverflowButtonConfig());const a=n.selectAll("div.toolbar-control").data(i,c=>c.id);a.exit().remove();const o=a.enter().append("div").attr("class","toolbar-control cds--overflow-menu cds--overflow-menu"),l=this;o.merge(a).classed("disabled",c=>c.shouldBeDisabled()).attr("role","button").attr("aria-disabled",c=>c.shouldBeDisabled()).attr("aria-label",c=>c.title).html(c=>`
|