@carbon/charts 1.27.0 → 1.27.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  (function(q,$e){typeof exports=="object"&&typeof module<"u"?$e(exports):typeof define=="function"&&define.amd?define(["exports"],$e):(q=typeof globalThis<"u"?globalThis:q||self,$e(q.Charts={}))})(this,function(q){"use strict";function $e(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function Xv(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function bo(e){let t,n,i;e.length!==2?(t=$e,n=(o,l)=>$e(e(o),l),i=(o,l)=>e(o)-l):(t=e===$e||e===Xv?e:Zv,n=e,i=e);function r(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=r(o,l,c,u-1);return d>c&&i(o[d-1],l)>-i(o[d],l)?d-1:d}return{left:r,center:a,right:s}}function Zv(){return 0}function jv(e){return e===null?NaN:+e}function*Kv(e,t){for(let n of e)n!=null&&(n=+n)>=n&&(yield n)}const So=bo($e).right;bo(jv).center;function Qv(e,t){let n=0;for(let i of e)i!=null&&(i=+i)>=i&&++n;return n}function Fe(e,t){let n,i;if(t===void 0)for(const r of e)r!=null&&(n===void 0?r>=r&&(n=i=r):(n>r&&(n=r),i<r&&(i=r)));else{let r=-1;for(let s of e)(s=t(s,++r,e))!=null&&(n===void 0?s>=s&&(n=i=s):(n>s&&(n=s),i<s&&(i=s)))}return[n,i]}class Vn{constructor(){this._partials=new Float64Array(32),this._n=0}add(t){const n=this._partials;let i=0;for(let r=0;r<this._n&&r<32;r++){const s=n[r],a=t+s,o=Math.abs(t)<Math.abs(s)?t-(a-s):s-(a-t);o&&(n[i++]=o),t=a}return n[i]=t,this._n=i+1,this}valueOf(){const t=this._partials;let n=this._n,i,r,s,a=0;if(n>0){for(a=t[--n];n>0&&(i=a,r=t[--n],a=i+r,s=r-(a-i),!s););n>0&&(s<0&&t[n-1]<0||s>0&&t[n-1]>0)&&(r=s*2,i=a+r,r==i-a&&(a=i))}return a}}class Nu extends Map{constructor(t,n=e0){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[i,r]of t)this.set(i,r)}get(t){return super.get($u(this,t))}has(t){return super.has($u(this,t))}set(t,n){return super.set(Jv(this,t),n)}delete(t){return super.delete(t0(this,t))}}function $u({_intern:e,_key:t},n){const i=t(n);return e.has(i)?e.get(i):n}function Jv({_intern:e,_key:t},n){const i=t(n);return e.has(i)?e.get(i):(e.set(i,n),n)}function t0({_intern:e,_key:t},n){const i=t(n);return e.has(i)&&(n=e.get(i),e.delete(i)),n}function e0(e){return e!==null&&typeof e=="object"?e.valueOf():e}function n0(e){return e}function i0(e=$e){if(e===$e)return Fu;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,n)=>{const i=e(t,n);return i||i===0?i:(e(n,n)===0)-(e(t,t)===0)}}function Fu(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}var r0=Array.prototype,s0=r0.slice;function _o(e){return()=>e}const a0=Math.sqrt(50),o0=Math.sqrt(10),l0=Math.sqrt(2);function Ms(e,t,n){const i=(t-e)/Math.max(0,n),r=Math.floor(Math.log10(i)),s=i/Math.pow(10,r),a=s>=a0?10:s>=o0?5:s>=l0?2:1;let o,l,c;return r<0?(c=Math.pow(10,-r)/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,r)*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?Ms(e,t,n*2):[o,l,c]}function Cs(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const i=t<e,[r,s,a]=i?Ms(t,e,n):Ms(e,t,n);if(!(s>=r))return[];const o=s-r+1,l=new Array(o);if(i)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]=(r+c)/-a;else for(let c=0;c<o;++c)l[c]=(r+c)*a;return l}function vi(e,t,n){return t=+t,e=+e,n=+n,Ms(e,t,n)[2]}function To(e,t,n){t=+t,e=+e,n=+n;const i=t<e,r=i?vi(t,e,n):vi(e,t,n);return(i?-1:1)*(r<0?1/-r:r)}function c0(e,t,n){let i;for(;;){const r=vi(e,t,n);if(r===i||r===0||!isFinite(r))return[e,t];r>0?(e=Math.floor(e/r)*r,t=Math.ceil(t/r)*r):r<0&&(e=Math.ceil(e*r)/r,t=Math.floor(t*r)/r),i=r}}function u0(e){return Math.max(1,Math.ceil(Math.log(Qv(e))/Math.LN2)+1)}function h0(){var e=n0,t=Fe,n=u0;function i(r){Array.isArray(r)||(r=Array.from(r));var s,a=r.length,o,l,c=new Array(a);for(s=0;s<a;++s)c[s]=e(r[s],s,r);var u=t(c),d=u[0],h=u[1],f=n(c,d,h);if(!Array.isArray(f)){const E=h,b=+f;if(t===Fe&&([d,h]=c0(d,h,b)),f=Cs(d,h,b),f[0]<=d&&(l=vi(d,h,b)),f[f.length-1]>=h)if(E>=h&&t===Fe){const x=vi(d,h,b);isFinite(x)&&(x>0?h=(Math.floor(h/x)+1)*x:x<0&&(h=(Math.ceil(h*-x)+1)/-x))}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),S;for(s=0;s<=p;++s)S=v[s]=[],S.x0=s>0?f[s-1]:d,S.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(r[s]);else if(l<0){for(s=0;s<a;++s)if((o=c[s])!=null&&d<=o&&o<=h){const E=Math.floor((d-o)*l);v[Math.min(p,E+(f[E]<=o))].push(r[s])}}}else for(s=0;s<a;++s)(o=c[s])!=null&&d<=o&&o<=h&&v[So(f,o,0,p)].push(r[s]);return v}return i.value=function(r){return arguments.length?(e=typeof r=="function"?r:_o(r),i):e},i.domain=function(r){return arguments.length?(t=typeof r=="function"?r:_o([r[0],r[1]]),i):t},i.thresholds=function(r){return arguments.length?(n=typeof r=="function"?r:_o(Array.isArray(r)?s0.call(r):r),i):n},i}function zn(e,t){let n;if(t===void 0)for(const i of e)i!=null&&(n<i||n===void 0&&i>=i)&&(n=i);else{let i=-1;for(let r of e)(r=t(r,++i,e))!=null&&(n<r||n===void 0&&r>=r)&&(n=r)}return n}function Pn(e,t){let n;for(const i of e)i!=null&&(n>i||n===void 0&&i>=i)&&(n=i);return n}function Uu(e,t,n=0,i=1/0,r){if(t=Math.floor(t),n=Math.floor(Math.max(0,n)),i=Math.floor(Math.min(e.length-1,i)),!(n<=t&&t<=i))return e;for(r=r===void 0?Fu:i0(r);i>n;){if(i-n>600){const l=i-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(i,Math.floor(t+(l-c)*d/l+h));Uu(e,t,f,p,r)}const s=e[t];let a=n,o=i;for(hr(e,n,t),r(e[i],s)>0&&hr(e,n,i);a<o;){for(hr(e,a,o),++a,--o;r(e[a],s)<0;)++a;for(;r(e[o],s)>0;)--o}r(e[n],s)===0?hr(e,n,o):(++o,hr(e,o,i)),o<=t&&(n=o+1),t<=o&&(i=o-1)}return e}function hr(e,t,n){const i=e[t];e[t]=e[n],e[n]=i}function Oo(e,t,n){if(e=Float64Array.from(Kv(e)),!(!(i=e.length)||isNaN(t=+t))){if(t<=0||i<2)return Pn(e);if(t>=1)return zn(e);var i,r=(i-1)*t,s=Math.floor(r),a=zn(Uu(e,s).subarray(0,s+1)),o=Pn(e.subarray(s+1));return a+(o-a)*(r-s)}}function*d0(e){for(const t of e)yield*t}function Bu(e){return Array.from(d0(e))}function f0(e,t,n){e=+e,t=+t,n=(r=arguments.length)<2?(t=e,e=0,1):r<3?1:+n;for(var i=-1,r=Math.max(0,Math.ceil((t-e)/n))|0,s=new Array(r);++i<r;)s[i]=e+i*n;return s}function p0(e){return e}var As=1,Ds=2,wo=3,dr=4,Hu=1e-6;function g0(e){return"translate("+e+",0)"}function m0(e){return"translate(0,"+e+")"}function v0(e){return t=>+e(t)}function y0(e,t){return t=Math.max(0,e.bandwidth()-t*2)/2,e.round()&&(t=Math.round(t)),n=>+e(n)+t}function E0(){return!this.__axis}function Ls(e,t){var n=[],i=null,r=null,s=6,a=6,o=3,l=typeof window<"u"&&window.devicePixelRatio>1?0:.5,c=e===As||e===dr?-1:1,u=e===dr||e===Ds?"x":"y",d=e===As||e===wo?g0:m0;function h(f){var p=i??(t.ticks?t.ticks.apply(t,n):t.domain()),g=r??(t.tickFormat?t.tickFormat.apply(t,n):p0),m=Math.max(s,0)+o,v=t.range(),S=+v[0]+l,E=+v[v.length-1]+l,b=(t.bandwidth?y0:v0)(t.copy(),l),x=f.selection?f.selection():f,_=x.selectAll(".domain").data([null]),C=x.selectAll(".tick").data(p,t).order(),A=C.exit(),$=C.enter().append("g").attr("class","tick"),P=C.select("line"),w=C.select("text");_=_.merge(_.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),C=C.merge($),P=P.merge($.append("line").attr("stroke","currentColor").attr(u+"2",c*s)),w=w.merge($.append("text").attr("fill","currentColor").attr(u,c*m).attr("dy",e===As?"0em":e===wo?"0.71em":"0.32em")),f!==x&&(_=_.transition(f),C=C.transition(f),P=P.transition(f),w=w.transition(f),A=A.transition(f).attr("opacity",Hu).attr("transform",function(H){return isFinite(H=b(H))?d(H+l):this.getAttribute("transform")}),$.attr("opacity",Hu).attr("transform",function(H){var N=this.parentNode.__axis;return d((N&&isFinite(N=N(H))?N:b(H))+l)})),A.remove(),_.attr("d",e===dr||e===Ds?a?"M"+c*a+","+S+"H"+l+"V"+E+"H"+c*a:"M"+l+","+S+"V"+E:a?"M"+S+","+c*a+"V"+l+"H"+E+"V"+c*a:"M"+S+","+l+"H"+E),C.attr("opacity",1).attr("transform",function(H){return d(b(H)+l)}),P.attr(u+"2",c*s),w.attr(u,c*m).text(g),x.filter(E0).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",e===Ds?"start":e===dr?"end":"middle"),x.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?(i=f==null?null:Array.from(f),h):i&&i.slice()},h.tickFormat=function(f){return arguments.length?(r=f,h):r},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 x0(e){return Ls(As,e)}function b0(e){return Ls(Ds,e)}function Mo(e){return Ls(wo,e)}function Gu(e){return Ls(dr,e)}var S0={value:()=>{}};function Co(){for(var e=0,t=arguments.length,n={},i;e<t;++e){if(!(i=arguments[e]+"")||i in n||/[\s.]/.test(i))throw new Error("illegal type: "+i);n[i]=[]}return new Rs(n)}function Rs(e){this._=e}function _0(e,t){return e.trim().split(/^|\s+/).map(function(n){var i="",r=n.indexOf(".");if(r>=0&&(i=n.slice(r+1),n=n.slice(0,r)),n&&!t.hasOwnProperty(n))throw new Error("unknown type: "+n);return{type:n,name:i}})}Rs.prototype=Co.prototype={constructor:Rs,on:function(e,t){var n=this._,i=_0(e+"",n),r,s=-1,a=i.length;if(arguments.length<2){for(;++s<a;)if((r=(e=i[s]).type)&&(r=T0(n[r],e.name)))return r;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++s<a;)if(r=(e=i[s]).type)n[r]=Vu(n[r],e.name,t);else if(t==null)for(r in n)n[r]=Vu(n[r],e.name,null);return this},copy:function(){var e={},t=this._;for(var n in t)e[n]=t[n].slice();return new Rs(e)},call:function(e,t){if((r=arguments.length-2)>0)for(var n=new Array(r),i=0,r,s;i<r;++i)n[i]=arguments[i+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(s=this._[e],i=0,r=s.length;i<r;++i)s[i].value.apply(t,n)},apply:function(e,t,n){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var i=this._[e],r=0,s=i.length;r<s;++r)i[r].value.apply(t,n)}};function T0(e,t){for(var n=0,i=e.length,r;n<i;++n)if((r=e[n]).name===t)return r.value}function Vu(e,t,n){for(var i=0,r=e.length;i<r;++i)if(e[i].name===t){e[i]=S0,e=e.slice(0,i).concat(e.slice(i+1));break}return n!=null&&e.push({name:t,value:n}),e}var Ao="http://www.w3.org/1999/xhtml";const zu={svg:"http://www.w3.org/2000/svg",xhtml:Ao,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Is(e){var t=e+="",n=t.indexOf(":");return n>=0&&(t=e.slice(0,n))!=="xmlns"&&(e=e.slice(n+1)),zu.hasOwnProperty(t)?{space:zu[t],local:e}:e}function O0(e){return function(){var t=this.ownerDocument,n=this.namespaceURI;return n===Ao&&t.documentElement.namespaceURI===Ao?t.createElement(e):t.createElementNS(n,e)}}function w0(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function Wu(e){var t=Is(e);return(t.local?w0:O0)(t)}function M0(){}function Do(e){return e==null?M0:function(){return this.querySelector(e)}}function C0(e){typeof e!="function"&&(e=Do(e));for(var t=this._groups,n=t.length,i=new Array(n),r=0;r<n;++r)for(var s=t[r],a=s.length,o=i[r]=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 ye(i,this._parents)}function A0(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function D0(){return[]}function Yu(e){return e==null?D0:function(){return this.querySelectorAll(e)}}function L0(e){return function(){return A0(e.apply(this,arguments))}}function R0(e){typeof e=="function"?e=L0(e):e=Yu(e);for(var t=this._groups,n=t.length,i=[],r=[],s=0;s<n;++s)for(var a=t[s],o=a.length,l,c=0;c<o;++c)(l=a[c])&&(i.push(e.call(l,l.__data__,c,a)),r.push(l));return new ye(i,r)}function qu(e){return function(){return this.matches(e)}}function Xu(e){return function(t){return t.matches(e)}}var I0=Array.prototype.find;function k0(e){return function(){return I0.call(this.children,e)}}function P0(){return this.firstElementChild}function N0(e){return this.select(e==null?P0:k0(typeof e=="function"?e:Xu(e)))}var $0=Array.prototype.filter;function F0(){return Array.from(this.children)}function U0(e){return function(){return $0.call(this.children,e)}}function B0(e){return this.selectAll(e==null?F0:U0(typeof e=="function"?e:Xu(e)))}function H0(e){typeof e!="function"&&(e=qu(e));for(var t=this._groups,n=t.length,i=new Array(n),r=0;r<n;++r)for(var s=t[r],a=s.length,o=i[r]=[],l,c=0;c<a;++c)(l=s[c])&&e.call(l,l.__data__,c,s)&&o.push(l);return new ye(i,this._parents)}function Zu(e){return new Array(e.length)}function G0(){return new ye(this._enter||this._groups.map(Zu),this._parents)}function ks(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}ks.prototype={constructor:ks,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 V0(e){return function(){return e}}function z0(e,t,n,i,r,s){for(var a=0,o,l=t.length,c=s.length;a<c;++a)(o=t[a])?(o.__data__=s[a],i[a]=o):n[a]=new ks(e,s[a]);for(;a<l;++a)(o=t[a])&&(r[a]=o)}function W0(e,t,n,i,r,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)?r[o]=l:c.set(f,l));for(o=0;o<d;++o)f=a.call(e,s[o],o,s)+"",(l=c.get(f))?(i[o]=l,l.__data__=s[o],c.delete(f)):n[o]=new ks(e,s[o]);for(o=0;o<u;++o)(l=t[o])&&c.get(h[o])===l&&(r[o]=l)}function Y0(e){return e.__data__}function q0(e,t){if(!arguments.length)return Array.from(this,Y0);var n=t?W0:z0,i=this._parents,r=this._groups;typeof e!="function"&&(e=V0(e));for(var s=r.length,a=new Array(s),o=new Array(s),l=new Array(s),c=0;c<s;++c){var u=i[c],d=r[c],h=d.length,f=X0(e.call(u,u&&u.__data__,c,i)),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 S=0,E=0,b,x;S<p;++S)if(b=g[S]){for(S>=E&&(E=S+1);!(x=m[E])&&++E<p;);b._next=x||null}}return a=new ye(a,i),a._enter=o,a._exit=l,a}function X0(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function Z0(){return new ye(this._exit||this._groups.map(Zu),this._parents)}function j0(e,t,n){var i=this.enter(),r=this,s=this.exit();return typeof e=="function"?(i=e(i),i&&(i=i.selection())):i=i.append(e+""),t!=null&&(r=t(r),r&&(r=r.selection())),n==null?s.remove():n(s),i&&r?i.merge(r).order():r}function K0(e){for(var t=e.selection?e.selection():e,n=this._groups,i=t._groups,r=n.length,s=i.length,a=Math.min(r,s),o=new Array(r),l=0;l<a;++l)for(var c=n[l],u=i[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<r;++l)o[l]=n[l];return new ye(o,this._parents)}function Q0(){for(var e=this._groups,t=-1,n=e.length;++t<n;)for(var i=e[t],r=i.length-1,s=i[r],a;--r>=0;)(a=i[r])&&(s&&a.compareDocumentPosition(s)^4&&s.parentNode.insertBefore(a,s),s=a);return this}function J0(e){e||(e=ty);function t(d,h){return d&&h?e(d.__data__,h.__data__):!d-!h}for(var n=this._groups,i=n.length,r=new Array(i),s=0;s<i;++s){for(var a=n[s],o=a.length,l=r[s]=new Array(o),c,u=0;u<o;++u)(c=a[u])&&(l[u]=c);l.sort(t)}return new ye(r,this._parents).order()}function ty(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function ey(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function ny(){return Array.from(this)}function iy(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var i=e[t],r=0,s=i.length;r<s;++r){var a=i[r];if(a)return a}return null}function ry(){let e=0;for(const t of this)++e;return e}function sy(){return!this.node()}function ay(e){for(var t=this._groups,n=0,i=t.length;n<i;++n)for(var r=t[n],s=0,a=r.length,o;s<a;++s)(o=r[s])&&e.call(o,o.__data__,s,r);return this}function oy(e){return function(){this.removeAttribute(e)}}function ly(e){return function(){this.removeAttributeNS(e.space,e.local)}}function cy(e,t){return function(){this.setAttribute(e,t)}}function uy(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function hy(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttribute(e):this.setAttribute(e,n)}}function dy(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=Is(e);if(arguments.length<2){var i=this.node();return n.local?i.getAttributeNS(n.space,n.local):i.getAttribute(n)}return this.each((t==null?n.local?ly:oy:typeof t=="function"?n.local?dy:hy:n.local?uy:cy)(n,t))}function ju(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function py(e){return function(){this.style.removeProperty(e)}}function gy(e,t,n){return function(){this.style.setProperty(e,t,n)}}function my(e,t,n){return function(){var i=t.apply(this,arguments);i==null?this.style.removeProperty(e):this.style.setProperty(e,i,n)}}function vy(e,t,n){return arguments.length>1?this.each((t==null?py:typeof t=="function"?my:gy)(e,t,n??"")):yi(this.node(),e)}function yi(e,t){return e.style.getPropertyValue(t)||ju(e).getComputedStyle(e,null).getPropertyValue(t)}function yy(e){return function(){delete this[e]}}function Ey(e,t){return function(){this[e]=t}}function xy(e,t){return function(){var n=t.apply(this,arguments);n==null?delete this[e]:this[e]=n}}function by(e,t){return arguments.length>1?this.each((t==null?yy:typeof t=="function"?xy:Ey)(e,t)):this.node()[e]}function Ku(e){return e.trim().split(/^|\s+/)}function Lo(e){return e.classList||new Qu(e)}function Qu(e){this._node=e,this._names=Ku(e.getAttribute("class")||"")}Qu.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 Ju(e,t){for(var n=Lo(e),i=-1,r=t.length;++i<r;)n.add(t[i])}function th(e,t){for(var n=Lo(e),i=-1,r=t.length;++i<r;)n.remove(t[i])}function Sy(e){return function(){Ju(this,e)}}function _y(e){return function(){th(this,e)}}function Ty(e,t){return function(){(t.apply(this,arguments)?Ju:th)(this,e)}}function Oy(e,t){var n=Ku(e+"");if(arguments.length<2){for(var i=Lo(this.node()),r=-1,s=n.length;++r<s;)if(!i.contains(n[r]))return!1;return!0}return this.each((typeof t=="function"?Ty:t?Sy:_y)(n,t))}function wy(){this.textContent=""}function My(e){return function(){this.textContent=e}}function Cy(e){return function(){var t=e.apply(this,arguments);this.textContent=t??""}}function Ay(e){return arguments.length?this.each(e==null?wy:(typeof e=="function"?Cy:My)(e)):this.node().textContent}function Dy(){this.innerHTML=""}function Ly(e){return function(){this.innerHTML=e}}function Ry(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t??""}}function Iy(e){return arguments.length?this.each(e==null?Dy:(typeof e=="function"?Ry:Ly)(e)):this.node().innerHTML}function ky(){this.nextSibling&&this.parentNode.appendChild(this)}function Py(){return this.each(ky)}function Ny(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function $y(){return this.each(Ny)}function Fy(e){var t=typeof e=="function"?e:Wu(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function Uy(){return null}function By(e,t){var n=typeof e=="function"?e:Wu(e),i=t==null?Uy:typeof t=="function"?t:Do(t);return this.select(function(){return this.insertBefore(n.apply(this,arguments),i.apply(this,arguments)||null)})}function Hy(){var e=this.parentNode;e&&e.removeChild(this)}function Gy(){return this.each(Hy)}function Vy(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function zy(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function Wy(e){return this.select(e?zy:Vy)}function Yy(e){return arguments.length?this.property("__data__",e):this.node().__data__}function qy(e){return function(t){e.call(this,t,this.__data__)}}function Xy(e){return e.trim().split(/^|\s+/).map(function(t){var n="",i=t.indexOf(".");return i>=0&&(n=t.slice(i+1),t=t.slice(0,i)),{type:t,name:n}})}function Zy(e){return function(){var t=this.__on;if(t){for(var n=0,i=-1,r=t.length,s;n<r;++n)s=t[n],(!e.type||s.type===e.type)&&s.name===e.name?this.removeEventListener(s.type,s.listener,s.options):t[++i]=s;++i?t.length=i:delete this.__on}}}function jy(e,t,n){return function(){var i=this.__on,r,s=qy(t);if(i){for(var a=0,o=i.length;a<o;++a)if((r=i[a]).type===e.type&&r.name===e.name){this.removeEventListener(r.type,r.listener,r.options),this.addEventListener(r.type,r.listener=s,r.options=n),r.value=t;return}}this.addEventListener(e.type,s,n),r={type:e.type,name:e.name,value:t,listener:s,options:n},i?i.push(r):this.__on=[r]}}function Ky(e,t,n){var i=Xy(e+""),r,s=i.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(r=0,u=o[l];r<s;++r)if((a=i[r]).type===u.type&&a.name===u.name)return u.value}return}for(o=t?jy:Zy,r=0;r<s;++r)this.each(o(i[r],t,n));return this}function eh(e,t,n){var i=ju(e),r=i.CustomEvent;typeof r=="function"?r=new r(t,n):(r=i.document.createEvent("Event"),n?(r.initEvent(t,n.bubbles,n.cancelable),r.detail=n.detail):r.initEvent(t,!1,!1)),e.dispatchEvent(r)}function Qy(e,t){return function(){return eh(this,e,t)}}function Jy(e,t){return function(){return eh(this,e,t.apply(this,arguments))}}function t1(e,t){return this.each((typeof t=="function"?Jy:Qy)(e,t))}function*e1(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var i=e[t],r=0,s=i.length,a;r<s;++r)(a=i[r])&&(yield a)}var nh=[null];function ye(e,t){this._groups=e,this._parents=t}function fr(){return new ye([[document.documentElement]],nh)}function n1(){return this}ye.prototype=fr.prototype={constructor:ye,select:C0,selectAll:R0,selectChild:N0,selectChildren:B0,filter:H0,data:q0,enter:G0,exit:Z0,join:j0,merge:K0,selection:n1,order:Q0,sort:J0,call:ey,nodes:ny,node:iy,size:ry,empty:sy,each:ay,attr:fy,style:vy,property:by,classed:Oy,text:Ay,html:Iy,raise:Py,lower:$y,append:Fy,insert:By,remove:Gy,clone:Wy,datum:Yy,on:Ky,dispatch:t1,[Symbol.iterator]:e1};function I(e){return typeof e=="string"?new ye([[document.querySelector(e)]],[document.documentElement]):new ye([[e]],nh)}function i1(e){let t;for(;t=e.sourceEvent;)e=t;return e}function Wn(e,t){if(e=i1(e),t===void 0&&(t=e.currentTarget),t){var n=t.ownerSVGElement||t;if(n.createSVGPoint){var i=n.createSVGPoint();return i.x=e.clientX,i.y=e.clientY,i=i.matrixTransform(t.getScreenCTM().inverse()),[i.x,i.y]}if(t.getBoundingClientRect){var r=t.getBoundingClientRect();return[e.clientX-r.left-t.clientLeft,e.clientY-r.top-t.clientTop]}}return[e.pageX,e.pageY]}const Ro={capture:!0,passive:!1};function Io(e){e.preventDefault(),e.stopImmediatePropagation()}function r1(e){var t=e.document.documentElement,n=I(e).on("dragstart.drag",Io,Ro);"onselectstart"in t?n.on("selectstart.drag",Io,Ro):(t.__noselect=t.style.MozUserSelect,t.style.MozUserSelect="none")}function s1(e,t){var n=e.document.documentElement,i=I(e).on("dragstart.drag",null);t&&(i.on("click.drag",Io,Ro),setTimeout(function(){i.on("click.drag",null)},0)),"onselectstart"in n?i.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}function ko(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function ih(e,t){var n=Object.create(e.prototype);for(var i in t)n[i]=t[i];return n}function pr(){}var gr=.7,Ps=1/gr,Ei="\\s*([+-]?\\d+)\\s*",mr="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Ke="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",a1=/^#([0-9a-f]{3,8})$/,o1=new RegExp(`^rgb\\(${Ei},${Ei},${Ei}\\)$`),l1=new RegExp(`^rgb\\(${Ke},${Ke},${Ke}\\)$`),c1=new RegExp(`^rgba\\(${Ei},${Ei},${Ei},${mr}\\)$`),u1=new RegExp(`^rgba\\(${Ke},${Ke},${Ke},${mr}\\)$`),h1=new RegExp(`^hsl\\(${mr},${Ke},${Ke}\\)$`),d1=new RegExp(`^hsla\\(${mr},${Ke},${Ke},${mr}\\)$`),rh={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};ko(pr,hn,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:sh,formatHex:sh,formatHex8:f1,formatHsl:p1,formatRgb:ah,toString:ah});function sh(){return this.rgb().formatHex()}function f1(){return this.rgb().formatHex8()}function p1(){return hh(this).formatHsl()}function ah(){return this.rgb().formatRgb()}function hn(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=a1.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?oh(t):n===3?new he(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?Ns(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?Ns(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=o1.exec(e))?new he(t[1],t[2],t[3],1):(t=l1.exec(e))?new he(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=c1.exec(e))?Ns(t[1],t[2],t[3],t[4]):(t=u1.exec(e))?Ns(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=h1.exec(e))?uh(t[1],t[2]/100,t[3]/100,1):(t=d1.exec(e))?uh(t[1],t[2]/100,t[3]/100,t[4]):rh.hasOwnProperty(e)?oh(rh[e]):e==="transparent"?new he(NaN,NaN,NaN,0):null}function oh(e){return new he(e>>16&255,e>>8&255,e&255,1)}function Ns(e,t,n,i){return i<=0&&(e=t=n=NaN),new he(e,t,n,i)}function g1(e){return e instanceof pr||(e=hn(e)),e?(e=e.rgb(),new he(e.r,e.g,e.b,e.opacity)):new he}function Po(e,t,n,i){return arguments.length===1?g1(e):new he(e,t,n,i??1)}function he(e,t,n,i){this.r=+e,this.g=+t,this.b=+n,this.opacity=+i}ko(he,Po,ih(pr,{brighter(e){return e=e==null?Ps:Math.pow(Ps,e),new he(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?gr:Math.pow(gr,e),new he(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new he(Yn(this.r),Yn(this.g),Yn(this.b),$s(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:m1,formatRgb:ch,toString:ch}));function lh(){return`#${qn(this.r)}${qn(this.g)}${qn(this.b)}`}function m1(){return`#${qn(this.r)}${qn(this.g)}${qn(this.b)}${qn((isNaN(this.opacity)?1:this.opacity)*255)}`}function ch(){const e=$s(this.opacity);return`${e===1?"rgb(":"rgba("}${Yn(this.r)}, ${Yn(this.g)}, ${Yn(this.b)}${e===1?")":`, ${e})`}`}function $s(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Yn(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function qn(e){return e=Yn(e),(e<16?"0":"")+e.toString(16)}function uh(e,t,n,i){return i<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new Ue(e,t,n,i)}function hh(e){if(e instanceof Ue)return new Ue(e.h,e.s,e.l,e.opacity);if(e instanceof pr||(e=hn(e)),!e)return new Ue;if(e instanceof Ue)return e;e=e.rgb();var t=e.r/255,n=e.g/255,i=e.b/255,r=Math.min(t,n,i),s=Math.max(t,n,i),a=NaN,o=s-r,l=(s+r)/2;return o?(t===s?a=(n-i)/o+(n<i)*6:n===s?a=(i-t)/o+2:a=(t-n)/o+4,o/=l<.5?s+r:2-s-r,a*=60):o=l>0&&l<1?0:a,new Ue(a,o,l,e.opacity)}function dh(e,t,n,i){return arguments.length===1?hh(e):new Ue(e,t,n,i??1)}function Ue(e,t,n,i){this.h=+e,this.s=+t,this.l=+n,this.opacity=+i}ko(Ue,dh,ih(pr,{brighter(e){return e=e==null?Ps:Math.pow(Ps,e),new Ue(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?gr:Math.pow(gr,e),new Ue(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,i=n+(n<.5?n:1-n)*t,r=2*n-i;return new he(No(e>=240?e-240:e+120,r,i),No(e,r,i),No(e<120?e+240:e-120,r,i),this.opacity)},clamp(){return new Ue(fh(this.h),Fs(this.s),Fs(this.l),$s(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=$s(this.opacity);return`${e===1?"hsl(":"hsla("}${fh(this.h)}, ${Fs(this.s)*100}%, ${Fs(this.l)*100}%${e===1?")":`, ${e})`}`}}));function fh(e){return e=(e||0)%360,e<0?e+360:e}function Fs(e){return Math.max(0,Math.min(1,e||0))}function No(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 $o=e=>()=>e;function v1(e,t){return function(n){return e+n*t}}function y1(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(i){return Math.pow(e+i*t,n)}}function E1(e){return(e=+e)==1?ph:function(t,n){return n-t?y1(t,n,e):$o(isNaN(t)?n:t)}}function ph(e,t){var n=t-e;return n?v1(e,n):$o(isNaN(e)?t:e)}const Us=function e(t){var n=E1(t);function i(r,s){var a=n((r=Po(r)).r,(s=Po(s)).r),o=n(r.g,s.g),l=n(r.b,s.b),c=ph(r.opacity,s.opacity);return function(u){return r.r=a(u),r.g=o(u),r.b=l(u),r.opacity=c(u),r+""}}return i.gamma=e,i}(1);function x1(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,i=t.slice(),r;return function(s){for(r=0;r<n;++r)i[r]=e[r]*(1-s)+t[r]*s;return i}}function b1(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function S1(e,t){var n=t?t.length:0,i=e?Math.min(n,e.length):0,r=new Array(i),s=new Array(n),a;for(a=0;a<i;++a)r[a]=vr(e[a],t[a]);for(;a<n;++a)s[a]=t[a];return function(o){for(a=0;a<i;++a)s[a]=r[a](o);return s}}function _1(e,t){var n=new Date;return e=+e,t=+t,function(i){return n.setTime(e*(1-i)+t*i),n}}function Ee(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function T1(e,t){var n={},i={},r;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(r in t)r in e?n[r]=vr(e[r],t[r]):i[r]=t[r];return function(s){for(r in n)i[r]=n[r](s);return i}}var Fo=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Uo=new RegExp(Fo.source,"g");function O1(e){return function(){return e}}function w1(e){return function(t){return e(t)+""}}function gh(e,t){var n=Fo.lastIndex=Uo.lastIndex=0,i,r,s,a=-1,o=[],l=[];for(e=e+"",t=t+"";(i=Fo.exec(e))&&(r=Uo.exec(t));)(s=r.index)>n&&(s=t.slice(n,s),o[a]?o[a]+=s:o[++a]=s),(i=i[0])===(r=r[0])?o[a]?o[a]+=r:o[++a]=r:(o[++a]=null,l.push({i:a,x:Ee(i,r)})),n=Uo.lastIndex;return n<t.length&&(s=t.slice(n),o[a]?o[a]+=s:o[++a]=s),o.length<2?l[0]?w1(l[0].x):O1(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 vr(e,t){var n=typeof t,i;return t==null||n==="boolean"?$o(t):(n==="number"?Ee:n==="string"?(i=hn(t))?(t=i,Us):gh:t instanceof hn?Us:t instanceof Date?_1:b1(t)?x1:Array.isArray(t)?S1:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?T1:Ee)(e,t)}function mh(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}var vh=180/Math.PI,Bo={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function yh(e,t,n,i,r,s){var a,o,l;return(a=Math.sqrt(e*e+t*t))&&(e/=a,t/=a),(l=e*n+t*i)&&(n-=e*l,i-=t*l),(o=Math.sqrt(n*n+i*i))&&(n/=o,i/=o,l/=o),e*i<t*n&&(e=-e,t=-t,l=-l,a=-a),{translateX:r,translateY:s,rotate:Math.atan2(t,e)*vh,skewX:Math.atan(l)*vh,scaleX:a,scaleY:o}}var Bs;function M1(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?Bo:yh(t.a,t.b,t.c,t.d,t.e,t.f)}function C1(e){return e==null||(Bs||(Bs=document.createElementNS("http://www.w3.org/2000/svg","g")),Bs.setAttribute("transform",e),!(e=Bs.transform.baseVal.consolidate()))?Bo:(e=e.matrix,yh(e.a,e.b,e.c,e.d,e.e,e.f))}function Eh(e,t,n,i){function r(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:Ee(c,d)},{i:g-2,x:Ee(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(r(d)+"rotate(",null,i)-2,x:Ee(c,u)})):u&&d.push(r(d)+"rotate("+u+i)}function o(c,u,d,h){c!==u?h.push({i:d.push(r(d)+"skewX(",null,i)-2,x:Ee(c,u)}):u&&d.push(r(d)+"skewX("+u+i)}function l(c,u,d,h,f,p){if(c!==d||u!==h){var g=f.push(r(f)+"scale(",null,",",null,")");p.push({i:g-4,x:Ee(c,d)},{i:g-2,x:Ee(u,h)})}else(d!==1||h!==1)&&f.push(r(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 A1=Eh(M1,"px, ","px)","deg)"),D1=Eh(C1,", ",")",")");function L1(e,t){for(var n=new Array(t),i=0;i<t;++i)n[i]=e(i/(t-1));return n}var xi=0,yr=0,Er=0,xh=1e3,Hs,xr,Gs=0,Xn=0,Vs=0,br=typeof performance=="object"&&performance.now?performance:Date,bh=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function Ho(){return Xn||(bh(R1),Xn=br.now()+Vs)}function R1(){Xn=0}function zs(){this._call=this._time=this._next=null}zs.prototype=Sh.prototype={constructor:zs,restart:function(e,t,n){if(typeof e!="function")throw new TypeError("callback is not a function");n=(n==null?Ho():+n)+(t==null?0:+t),!this._next&&xr!==this&&(xr?xr._next=this:Hs=this,xr=this),this._call=e,this._time=n,Go()},stop:function(){this._call&&(this._call=null,this._time=1/0,Go())}};function Sh(e,t,n){var i=new zs;return i.restart(e,t,n),i}function I1(){Ho(),++xi;for(var e=Hs,t;e;)(t=Xn-e._time)>=0&&e._call.call(void 0,t),e=e._next;--xi}function _h(){Xn=(Gs=br.now())+Vs,xi=yr=0;try{I1()}finally{xi=0,P1(),Xn=0}}function k1(){var e=br.now(),t=e-Gs;t>xh&&(Vs-=t,Gs=e)}function P1(){for(var e,t=Hs,n,i=1/0;t;)t._call?(i>t._time&&(i=t._time),e=t,t=t._next):(n=t._next,t._next=null,t=e?e._next=n:Hs=n);xr=e,Go(i)}function Go(e){if(!xi){yr&&(yr=clearTimeout(yr));var t=e-Xn;t>24?(e<1/0&&(yr=setTimeout(_h,e-br.now()-Vs)),Er&&(Er=clearInterval(Er))):(Er||(Gs=br.now(),Er=setInterval(k1,xh)),xi=1,bh(_h))}}function Th(e,t,n){var i=new zs;return t=t==null?0:+t,i.restart(r=>{i.stop(),e(r+t)},t,n),i}var N1=Co("start","end","cancel","interrupt"),$1=[],Oh=0,wh=1,Vo=2,Ws=3,Mh=4,zo=5,Ys=6;function qs(e,t,n,i,r,s){var a=e.__transition;if(!a)e.__transition={};else if(n in a)return;F1(e,n,{name:t,index:i,group:r,on:N1,tween:$1,time:s.time,delay:s.delay,duration:s.duration,ease:s.ease,timer:null,state:Oh})}function Wo(e,t){var n=Be(e,t);if(n.state>Oh)throw new Error("too late; already scheduled");return n}function Qe(e,t){var n=Be(e,t);if(n.state>Ws)throw new Error("too late; already running");return n}function Be(e,t){var n=e.__transition;if(!n||!(n=n[t]))throw new Error("transition not found");return n}function F1(e,t,n){var i=e.__transition,r;i[t]=n,n.timer=Sh(s,0,n.time);function s(c){n.state=wh,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!==wh)return l();for(u in i)if(f=i[u],f.name===n.name){if(f.state===Ws)return Th(a);f.state===Mh?(f.state=Ys,f.timer.stop(),f.on.call("interrupt",e,e.__data__,f.index,f.group),delete i[u]):+u<t&&(f.state=Ys,f.timer.stop(),f.on.call("cancel",e,e.__data__,f.index,f.group),delete i[u])}if(Th(function(){n.state===Ws&&(n.state=Mh,n.timer.restart(o,n.delay,n.time),o(c))}),n.state=Vo,n.on.call("start",e,e.__data__,n.index,n.group),n.state===Vo){for(n.state=Ws,r=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))&&(r[++d]=f);r.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=zo,1),d=-1,h=r.length;++d<h;)r[d].call(e,u);n.state===zo&&(n.on.call("end",e,e.__data__,n.index,n.group),l())}function l(){n.state=Ys,n.timer.stop(),delete i[t];for(var c in i)return;delete e.__transition}}function Yo(e,t){var n=e.__transition,i,r,s=!0,a;if(n){t=t==null?null:t+"";for(a in n){if((i=n[a]).name!==t){s=!1;continue}r=i.state>Vo&&i.state<zo,i.state=Ys,i.timer.stop(),i.on.call(r?"interrupt":"cancel",e,e.__data__,i.index,i.group),delete n[a]}s&&delete e.__transition}}function U1(e){return this.each(function(){Yo(this,e)})}function B1(e,t){var n,i;return function(){var r=Qe(this,e),s=r.tween;if(s!==n){i=n=s;for(var a=0,o=i.length;a<o;++a)if(i[a].name===t){i=i.slice(),i.splice(a,1);break}}r.tween=i}}function H1(e,t,n){var i,r;if(typeof n!="function")throw new Error;return function(){var s=Qe(this,e),a=s.tween;if(a!==i){r=(i=a).slice();for(var o={name:t,value:n},l=0,c=r.length;l<c;++l)if(r[l].name===t){r[l]=o;break}l===c&&r.push(o)}s.tween=r}}function G1(e,t){var n=this._id;if(e+="",arguments.length<2){for(var i=Be(this.node(),n).tween,r=0,s=i.length,a;r<s;++r)if((a=i[r]).name===e)return a.value;return null}return this.each((t==null?B1:H1)(n,e,t))}function qo(e,t,n){var i=e._id;return e.each(function(){var r=Qe(this,i);(r.value||(r.value={}))[t]=n.apply(this,arguments)}),function(r){return Be(r,i).value[t]}}function Ch(e,t){var n;return(typeof t=="number"?Ee:t instanceof hn?Us:(n=hn(t))?(t=n,Us):gh)(e,t)}function V1(e){return function(){this.removeAttribute(e)}}function z1(e){return function(){this.removeAttributeNS(e.space,e.local)}}function W1(e,t,n){var i,r=n+"",s;return function(){var a=this.getAttribute(e);return a===r?null:a===i?s:s=t(i=a,n)}}function Y1(e,t,n){var i,r=n+"",s;return function(){var a=this.getAttributeNS(e.space,e.local);return a===r?null:a===i?s:s=t(i=a,n)}}function q1(e,t,n){var i,r,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===i&&l===r?s:(r=l,s=t(i=a,o)))}}function X1(e,t,n){var i,r,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===i&&l===r?s:(r=l,s=t(i=a,o)))}}function Z1(e,t){var n=Is(e),i=n==="transform"?D1:Ch;return this.attrTween(e,typeof t=="function"?(n.local?X1:q1)(n,i,qo(this,"attr."+e,t)):t==null?(n.local?z1:V1)(n):(n.local?Y1:W1)(n,i,t))}function j1(e,t){return function(n){this.setAttribute(e,t.call(this,n))}}function K1(e,t){return function(n){this.setAttributeNS(e.space,e.local,t.call(this,n))}}function Q1(e,t){var n,i;function r(){var s=t.apply(this,arguments);return s!==i&&(n=(i=s)&&K1(e,s)),n}return r._value=t,r}function J1(e,t){var n,i;function r(){var s=t.apply(this,arguments);return s!==i&&(n=(i=s)&&j1(e,s)),n}return r._value=t,r}function tE(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 i=Is(e);return this.tween(n,(i.local?Q1:J1)(i,t))}function eE(e,t){return function(){Wo(this,e).delay=+t.apply(this,arguments)}}function nE(e,t){return t=+t,function(){Wo(this,e).delay=t}}function iE(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?eE:nE)(t,e)):Be(this.node(),t).delay}function rE(e,t){return function(){Qe(this,e).duration=+t.apply(this,arguments)}}function sE(e,t){return t=+t,function(){Qe(this,e).duration=t}}function aE(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?rE:sE)(t,e)):Be(this.node(),t).duration}function oE(e,t){if(typeof t!="function")throw new Error;return function(){Qe(this,e).ease=t}}function lE(e){var t=this._id;return arguments.length?this.each(oE(t,e)):Be(this.node(),t).ease}function cE(e,t){return function(){var n=t.apply(this,arguments);if(typeof n!="function")throw new Error;Qe(this,e).ease=n}}function uE(e){if(typeof e!="function")throw new Error;return this.each(cE(this._id,e))}function hE(e){typeof e!="function"&&(e=qu(e));for(var t=this._groups,n=t.length,i=new Array(n),r=0;r<n;++r)for(var s=t[r],a=s.length,o=i[r]=[],l,c=0;c<a;++c)(l=s[c])&&e.call(l,l.__data__,c,s)&&o.push(l);return new dn(i,this._parents,this._name,this._id)}function dE(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,n=e._groups,i=t.length,r=n.length,s=Math.min(i,r),a=new Array(i),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<i;++o)a[o]=t[o];return new dn(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 pE(e,t,n){var i,r,s=fE(t)?Wo:Qe;return function(){var a=s(this,e),o=a.on;o!==i&&(r=(i=o).copy()).on(t,n),a.on=r}}function gE(e,t){var n=this._id;return arguments.length<2?Be(this.node(),n).on.on(e):this.each(pE(n,e,t))}function mE(e){return function(){var t=this.parentNode;for(var n in this.__transition)if(+n!==e)return;t&&t.removeChild(this)}}function vE(){return this.on("end.remove",mE(this._id))}function yE(e){var t=this._name,n=this._id;typeof e!="function"&&(e=Do(e));for(var i=this._groups,r=i.length,s=new Array(r),a=0;a<r;++a)for(var o=i[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,qs(c[h],t,n,h,c,Be(u,n)));return new dn(s,this._parents,t,n)}function EE(e){var t=this._name,n=this._id;typeof e!="function"&&(e=Yu(e));for(var i=this._groups,r=i.length,s=[],a=[],o=0;o<r;++o)for(var l=i[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=Be(u,n),g=0,m=h.length;g<m;++g)(f=h[g])&&qs(f,t,n,g,h,p);s.push(h),a.push(u)}return new dn(s,a,t,n)}var xE=fr.prototype.constructor;function bE(){return new xE(this._groups,this._parents)}function SE(e,t){var n,i,r;return function(){var s=yi(this,e),a=(this.style.removeProperty(e),yi(this,e));return s===a?null:s===n&&a===i?r:r=t(n=s,i=a)}}function Ah(e){return function(){this.style.removeProperty(e)}}function _E(e,t,n){var i,r=n+"",s;return function(){var a=yi(this,e);return a===r?null:a===i?s:s=t(i=a,n)}}function TE(e,t,n){var i,r,s;return function(){var a=yi(this,e),o=n(this),l=o+"";return o==null&&(l=o=(this.style.removeProperty(e),yi(this,e))),a===l?null:a===i&&l===r?s:(r=l,s=t(i=a,o))}}function OE(e,t){var n,i,r,s="style."+t,a="end."+s,o;return function(){var l=Qe(this,e),c=l.on,u=l.value[s]==null?o||(o=Ah(t)):void 0;(c!==n||r!==u)&&(i=(n=c).copy()).on(a,r=u),l.on=i}}function wE(e,t,n){var i=(e+="")=="transform"?A1:Ch;return t==null?this.styleTween(e,SE(e,i)).on("end.style."+e,Ah(e)):typeof t=="function"?this.styleTween(e,TE(e,i,qo(this,"style."+e,t))).each(OE(this._id,e)):this.styleTween(e,_E(e,i,t),n).on("end.style."+e,null)}function ME(e,t,n){return function(i){this.style.setProperty(e,t.call(this,i),n)}}function CE(e,t,n){var i,r;function s(){var a=t.apply(this,arguments);return a!==r&&(i=(r=a)&&ME(e,a,n)),i}return s._value=t,s}function AE(e,t,n){var i="style."+(e+="");if(arguments.length<2)return(i=this.tween(i))&&i._value;if(t==null)return this.tween(i,null);if(typeof t!="function")throw new Error;return this.tween(i,CE(e,t,n??""))}function DE(e){return function(){this.textContent=e}}function LE(e){return function(){var t=e(this);this.textContent=t??""}}function RE(e){return this.tween("text",typeof e=="function"?LE(qo(this,"text",e)):DE(e==null?"":e+""))}function IE(e){return function(t){this.textContent=e.call(this,t)}}function kE(e){var t,n;function i(){var r=e.apply(this,arguments);return r!==n&&(t=(n=r)&&IE(r)),t}return i._value=e,i}function PE(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,kE(e))}function NE(){for(var e=this._name,t=this._id,n=Dh(),i=this._groups,r=i.length,s=0;s<r;++s)for(var a=i[s],o=a.length,l,c=0;c<o;++c)if(l=a[c]){var u=Be(l,t);qs(l,e,n,c,a,{time:u.time+u.delay+u.duration,delay:0,duration:u.duration,ease:u.ease})}return new dn(i,this._parents,e,n)}function $E(){var e,t,n=this,i=n._id,r=n.size();return new Promise(function(s,a){var o={value:a},l={value:function(){--r===0&&s()}};n.each(function(){var c=Qe(this,i),u=c.on;u!==e&&(t=(e=u).copy(),t._.cancel.push(o),t._.interrupt.push(o),t._.end.push(l)),c.on=t}),r===0&&s()})}var FE=0;function dn(e,t,n,i){this._groups=e,this._parents=t,this._name=n,this._id=i}function Dh(){return++FE}var fn=fr.prototype;dn.prototype={constructor:dn,select:yE,selectAll:EE,selectChild:fn.selectChild,selectChildren:fn.selectChildren,filter:hE,merge:dE,selection:bE,transition:NE,call:fn.call,nodes:fn.nodes,node:fn.node,size:fn.size,empty:fn.empty,each:fn.each,on:gE,attr:Z1,attrTween:tE,style:wE,styleTween:AE,text:RE,textTween:PE,remove:vE,tween:G1,delay:iE,duration:aE,ease:lE,easeVarying:uE,end:$E,[Symbol.iterator]:fn[Symbol.iterator]};const UE=e=>+e;function Lh(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var BE={time:null,delay:0,duration:250,ease:Lh};function HE(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 GE(e){var t,n;e instanceof dn?(t=e._id,e=e._name):(t=Dh(),(n=BE).time=Ho(),e=e==null?null:e+"");for(var i=this._groups,r=i.length,s=0;s<r;++s)for(var a=i[s],o=a.length,l,c=0;c<o;++c)(l=a[c])&&qs(l,e,t,c,a,n||HE(l,t));return new dn(i,this._parents,e,t)}fr.prototype.interrupt=U1,fr.prototype.transition=GE;const Xo=e=>()=>e;function VE(e,{sourceEvent:t,target:n,selection:i,mode:r,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:i,enumerable:!0,configurable:!0},mode:{value:r,enumerable:!0,configurable:!0},_:{value:s}})}function zE(e){e.stopImmediatePropagation()}function Zo(e){e.preventDefault(),e.stopImmediatePropagation()}var Rh={name:"drag"},jo={name:"space"},bi={name:"handle"},Si={name:"center"};const{abs:Ih,max:Kt,min:Qt}=Math;function kh(e){return[+e[0],+e[1]]}function Ph(e){return[kh(e[0]),kh(e[1])]}var Xs={name:"x",handles:["w","e"].map(Qo),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]]}},Ko={},pn={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"},Nh={e:"w",w:"e",nw:"ne",ne:"nw",se:"sw",sw:"se"},$h={n:"s",s:"n",nw:"sw",ne:"se",se:"ne",sw:"nw"},WE={overlay:1,selection:1,n:null,e:1,s:null,w:-1,nw:-1,ne:1,se:1,sw:-1},YE={overlay:1,selection:1,n:-1,e:null,s:1,w:null,nw:-1,ne:-1,se:1,sw:1};function Qo(e){return{type:e}}function qE(e){return!e.ctrlKey&&!e.button}function XE(){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 ZE(){return navigator.maxTouchPoints||"ontouchstart"in this}function Jo(e){for(;!e.__brush;)if(!(e=e.parentNode))return;return e.__brush}function jE(e){return e[0][0]===e[1][0]||e[0][1]===e[1][1]}function Fh(){return KE(Xs)}function KE(e){var t=XE,n=qE,i=ZE,r=!0,s=Co("start","brush","end"),a=6,o;function l(m){var v=m.property("__brush",g).selectAll(".overlay").data([Qo("overlay")]);v.enter().append("rect").attr("class","overlay").attr("pointer-events","all").attr("cursor",pn.overlay).merge(v).each(function(){var E=Jo(this).extent;I(this).attr("x",E[0][0]).attr("y",E[0][1]).attr("width",E[1][0]-E[0][0]).attr("height",E[1][1]-E[0][1])}),m.selectAll(".selection").data([Qo("selection")]).enter().append("rect").attr("class","selection").attr("cursor",pn.selection).attr("fill","#777").attr("fill-opacity",.3).attr("stroke","#fff").attr("shape-rendering","crispEdges");var S=m.selectAll(".handle").data(e.handles,function(E){return E.type});S.exit().remove(),S.enter().append("rect").attr("class",function(E){return"handle handle--"+E.type}).attr("cursor",function(E){return pn[E.type]}),m.each(c).attr("fill","none").attr("pointer-events","all").on("mousedown.brush",h).filter(i).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,S){m.tween?m.on("start.brush",function(E){u(this,arguments).beforestart().start(E)}).on("interrupt.brush end.brush",function(E){u(this,arguments).end(E)}).tween("brush",function(){var E=this,b=E.__brush,x=u(E,arguments),_=b.selection,C=e.input(typeof v=="function"?v.apply(this,arguments):v,b.extent),A=vr(_,C);function $(P){b.selection=P===1&&C===null?null:A(P),c.call(E),x.brush()}return _!==null&&C!==null?$:$(1)}):m.each(function(){var E=this,b=arguments,x=E.__brush,_=e.input(typeof v=="function"?v.apply(E,b):v,x.extent),C=u(E,b).beforestart();Yo(E),x.selection=_===null?null:_,c.call(E),C.start(S).brush(S).end(S)})},l.clear=function(m,v){l.move(m,null,v)};function c(){var m=I(this),v=Jo(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(S){return S.type[S.type.length-1]==="e"?v[1][0]-a/2:v[0][0]-a/2}).attr("y",function(S){return S.type[0]==="s"?v[1][1]-a/2:v[0][1]-a/2}).attr("width",function(S){return S.type==="n"||S.type==="s"?v[1][0]-v[0][0]+a:a}).attr("height",function(S){return S.type==="e"||S.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,S){var E=m.__brush.emitter;return E&&(!S||!E.clean)?E:new d(m,v,S)}function d(m,v,S){this.that=m,this.args=v,this.state=m.__brush,this.active=0,this.clean=S}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,S){var E=I(this.that).datum();s.call(m,this.that,new VE(m,{sourceEvent:v,target:l,selection:e.output(this.state.selection),mode:S,dispatch:s}),E)}};function h(m){if(o&&!m.touches||!n.apply(this,arguments))return;var v=this,S=m.target.__data__.type,E=(r&&m.metaKey?S="overlay":S)==="selection"?Rh:r&&m.altKey?Si:bi,b=e===Ko?null:WE[S],x=e===Xs?null:YE[S],_=Jo(v),C=_.extent,A=_.selection,$=C[0][0],P,w,H=C[0][1],N,M,O=C[1][0],F,U,L=C[1][1],B,tt,X=0,Y=0,Q,ut=b&&x&&r&&m.shiftKey,et,K,nt=Array.from(m.touches||[m],st=>{const _t=st.identifier;return st=Wn(st,v),st.point0=st.slice(),st.identifier=_t,st});Yo(v);var ht=u(v,arguments,!0).beforestart();if(S==="overlay"){A&&(Q=!0);const st=[nt[0],nt[1]||nt[0]];_.selection=A=[[P=e===Ko?$:Qt(st[0][0],st[1][0]),N=e===Xs?H:Qt(st[0][1],st[1][1])],[F=e===Ko?O:Kt(st[0][0],st[1][0]),B=e===Xs?L:Kt(st[0][1],st[1][1])]],nt.length>1&&G(m)}else P=A[0][0],N=A[0][1],F=A[1][0],B=A[1][1];w=P,M=N,U=F,tt=B;var W=I(v).attr("pointer-events","none"),j=W.selectAll(".overlay").attr("cursor",pn[S]);if(m.touches)ht.moved=D,ht.ended=V;else{var J=I(m.view).on("mousemove.brush",D,!0).on("mouseup.brush",V,!0);r&&J.on("keydown.brush",xt,!0).on("keyup.brush",Ut,!0),r1(m.view)}c.call(v),ht.start(m,E.name);function D(st){for(const _t of st.changedTouches||[st])for(const Ne of nt)Ne.identifier===_t.identifier&&(Ne.cur=Wn(_t,v));if(ut&&!et&&!K&&nt.length===1){const _t=nt[0];Ih(_t.cur[0]-_t[0])>Ih(_t.cur[1]-_t[1])?K=!0:et=!0}for(const _t of nt)_t.cur&&(_t[0]=_t.cur[0],_t[1]=_t.cur[1]);Q=!0,Zo(st),G(st)}function G(st){const _t=nt[0],Ne=_t.point0;var Oe;switch(X=_t[0]-Ne[0],Y=_t[1]-Ne[1],E){case jo:case Rh:{b&&(X=Kt($-P,Qt(O-F,X)),w=P+X,U=F+X),x&&(Y=Kt(H-N,Qt(L-B,Y)),M=N+Y,tt=B+Y);break}case bi:{nt[1]?(b&&(w=Kt($,Qt(O,nt[0][0])),U=Kt($,Qt(O,nt[1][0])),b=1),x&&(M=Kt(H,Qt(L,nt[0][1])),tt=Kt(H,Qt(L,nt[1][1])),x=1)):(b<0?(X=Kt($-P,Qt(O-P,X)),w=P+X,U=F):b>0&&(X=Kt($-F,Qt(O-F,X)),w=P,U=F+X),x<0?(Y=Kt(H-N,Qt(L-N,Y)),M=N+Y,tt=B):x>0&&(Y=Kt(H-B,Qt(L-B,Y)),M=N,tt=B+Y));break}case Si:{b&&(w=Kt($,Qt(O,P-X*b)),U=Kt($,Qt(O,F+X*b))),x&&(M=Kt(H,Qt(L,N-Y*x)),tt=Kt(H,Qt(L,B+Y*x)));break}}U<w&&(b*=-1,Oe=P,P=F,F=Oe,Oe=w,w=U,U=Oe,S in Nh&&j.attr("cursor",pn[S=Nh[S]])),tt<M&&(x*=-1,Oe=N,N=B,B=Oe,Oe=M,M=tt,tt=Oe,S in $h&&j.attr("cursor",pn[S=$h[S]])),_.selection&&(A=_.selection),et&&(w=A[0][0],U=A[1][0]),K&&(M=A[0][1],tt=A[1][1]),(A[0][0]!==w||A[0][1]!==M||A[1][0]!==U||A[1][1]!==tt)&&(_.selection=[[w,M],[U,tt]],c.call(v),ht.brush(st,E.name))}function V(st){if(zE(st),st.touches){if(st.touches.length)return;o&&clearTimeout(o),o=setTimeout(function(){o=null},500)}else s1(st.view,Q),J.on("keydown.brush keyup.brush mousemove.brush mouseup.brush",null);W.attr("pointer-events","all"),j.attr("cursor",pn.overlay),_.selection&&(A=_.selection),jE(A)&&(_.selection=null,c.call(v)),ht.end(st,E.name)}function xt(st){switch(st.keyCode){case 16:{ut=b&&x;break}case 18:{E===bi&&(b&&(F=U-X*b,P=w+X*b),x&&(B=tt-Y*x,N=M+Y*x),E=Si,G(st));break}case 32:{(E===bi||E===Si)&&(b<0?F=U-X:b>0&&(P=w-X),x<0?B=tt-Y:x>0&&(N=M-Y),E=jo,j.attr("cursor",pn.selection),G(st));break}default:return}Zo(st)}function Ut(st){switch(st.keyCode){case 16:{ut&&(et=K=ut=!1,G(st));break}case 18:{E===Si&&(b<0?F=U:b>0&&(P=w),x<0?B=tt:x>0&&(N=M),E=bi,G(st));break}case 32:{E===jo&&(st.altKey?(b&&(F=U-X*b,P=w+X*b),x&&(B=tt-Y*x,N=M+Y*x),E=Si):(b<0?F=U:b>0&&(P=w),x<0?B=tt:x>0&&(N=M),E=bi),j.attr("cursor",pn[S]),G(st));break}default:return}Zo(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=Ph(t.apply(this,arguments)),m.dim=e,m}return l.extent=function(m){return arguments.length?(t=typeof m=="function"?m:Xo(Ph(m)),l):t},l.filter=function(m){return arguments.length?(n=typeof m=="function"?m:Xo(!!m),l):n},l.touchable=function(m){return arguments.length?(i=typeof m=="function"?m:Xo(!!m),l):i},l.handleSize=function(m){return arguments.length?(a=+m,l):a},l.keyModifiers=function(m){return arguments.length?(r=!!m,l):r},l.on=function(){var m=s.on.apply(s,arguments);return m===s?l:m},l}const tl=Math.PI,el=2*tl,Zn=1e-6,QE=el-Zn;function Uh(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function JE(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return Uh;const n=10**t;return function(i){this._+=i[0];for(let r=1,s=i.length;r<s;++r)this._+=Math.round(arguments[r]*n)/n+i[r]}}let tx=class{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?Uh:JE(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,i,r){this._append`Q${+t},${+n},${this._x1=+i},${this._y1=+r}`}bezierCurveTo(t,n,i,r,s,a){this._append`C${+t},${+n},${+i},${+r},${this._x1=+s},${this._y1=+a}`}arcTo(t,n,i,r,s){if(t=+t,n=+n,i=+i,r=+r,s=+s,s<0)throw new Error(`negative radius: ${s}`);let a=this._x1,o=this._y1,l=i-t,c=r-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>Zn)if(!(Math.abs(d*l-c*u)>Zn)||!s)this._append`L${this._x1=t},${this._y1=n}`;else{let f=i-a,p=r-o,g=l*l+c*c,m=f*f+p*p,v=Math.sqrt(g),S=Math.sqrt(h),E=s*Math.tan((tl-Math.acos((g+h-m)/(2*v*S)))/2),b=E/S,x=E/v;Math.abs(b-1)>Zn&&this._append`L${t+b*u},${n+b*d}`,this._append`A${s},${s},0,0,${+(d*f>u*p)},${this._x1=t+x*l},${this._y1=n+x*c}`}}arc(t,n,i,r,s,a){if(t=+t,n=+n,i=+i,a=!!a,i<0)throw new Error(`negative radius: ${i}`);let o=i*Math.cos(r),l=i*Math.sin(r),c=t+o,u=n+l,d=1^a,h=a?r-s:s-r;this._x1===null?this._append`M${c},${u}`:(Math.abs(this._x1-c)>Zn||Math.abs(this._y1-u)>Zn)&&this._append`L${c},${u}`,i&&(h<0&&(h=h%el+el),h>QE?this._append`A${i},${i},0,1,${d},${t-o},${n-l}A${i},${i},0,1,${d},${this._x1=c},${this._y1=u}`:h>Zn&&this._append`A${i},${i},0,${+(h>=tl)},${d},${this._x1=t+i*Math.cos(s)},${this._y1=n+i*Math.sin(s)}`)}rect(t,n,i,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${i=+i}v${+r}h${-i}Z`}toString(){return this._}};function ex(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Zs(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,i=e.slice(0,n);return[i.length>1?i[0]+i.slice(2):i,+e.slice(n+1)]}function _i(e){return e=Zs(Math.abs(e)),e?e[1]:NaN}function nx(e,t){return function(n,i){for(var r=n.length,s=[],a=0,o=e[0],l=0;r>0&&o>0&&(l+o+1>i&&(o=Math.max(1,i-l)),s.push(n.substring(r-=o,r+o)),!((l+=o+1)>i));)o=e[a=(a+1)%e.length];return s.reverse().join(t)}}function ix(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var rx=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Sr(e){if(!(t=rx.exec(e)))throw new Error("invalid format: "+e);var t;return new nl({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]})}Sr.prototype=nl.prototype;function nl(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+""}nl.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 sx(e){t:for(var t=e.length,n=1,i=-1,r;n<t;++n)switch(e[n]){case".":i=r=n;break;case"0":i===0&&(i=n),r=n;break;default:if(!+e[n])break t;i>0&&(i=0);break}return i>0?e.slice(0,i)+e.slice(r+1):e}var Bh;function ax(e,t){var n=Zs(e,t);if(!n)return e+"";var i=n[0],r=n[1],s=r-(Bh=Math.max(-8,Math.min(8,Math.floor(r/3)))*3)+1,a=i.length;return s===a?i:s>a?i+new Array(s-a+1).join("0"):s>0?i.slice(0,s)+"."+i.slice(s):"0."+new Array(1-s).join("0")+Zs(e,Math.max(0,t+s-1))[0]}function Hh(e,t){var n=Zs(e,t);if(!n)return e+"";var i=n[0],r=n[1];return r<0?"0."+new Array(-r).join("0")+i:i.length>r+1?i.slice(0,r+1)+"."+i.slice(r+1):i+new Array(r-i.length+2).join("0")}const Gh={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:ex,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)=>Hh(e*100,t),r:Hh,s:ax,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function Vh(e){return e}var zh=Array.prototype.map,Wh=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function ox(e){var t=e.grouping===void 0||e.thousands===void 0?Vh:nx(zh.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",i=e.currency===void 0?"":e.currency[1]+"",r=e.decimal===void 0?".":e.decimal+"",s=e.numerals===void 0?Vh:ix(zh.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=Sr(d);var h=d.fill,f=d.align,p=d.sign,g=d.symbol,m=d.zero,v=d.width,S=d.comma,E=d.precision,b=d.trim,x=d.type;x==="n"?(S=!0,x="g"):Gh[x]||(E===void 0&&(E=12),b=!0,x="g"),(m||h==="0"&&f==="=")&&(m=!0,h="0",f="=");var _=g==="$"?n:g==="#"&&/[boxX]/.test(x)?"0"+x.toLowerCase():"",C=g==="$"?i:/[%p]/.test(x)?a:"",A=Gh[x],$=/[defgprs%]/.test(x);E=E===void 0?6:/[gprs]/.test(x)?Math.max(1,Math.min(21,E)):Math.max(0,Math.min(20,E));function P(w){var H=_,N=C,M,O,F;if(x==="c")N=A(w)+N,w="";else{w=+w;var U=w<0||1/w<0;if(w=isNaN(w)?l:A(Math.abs(w),E),b&&(w=sx(w)),U&&+w==0&&p!=="+"&&(U=!1),H=(U?p==="("?p:o:p==="-"||p==="("?"":p)+H,N=(x==="s"?Wh[8+Bh/3]:"")+N+(U&&p==="("?")":""),$){for(M=-1,O=w.length;++M<O;)if(F=w.charCodeAt(M),48>F||F>57){N=(F===46?r+w.slice(M+1):w.slice(M))+N,w=w.slice(0,M);break}}}S&&!m&&(w=t(w,1/0));var L=H.length+w.length+N.length,B=L<v?new Array(v-L+1).join(h):"";switch(S&&m&&(w=t(B+w,B.length?v-N.length:1/0),B=""),f){case"<":w=H+w+N+B;break;case"=":w=H+B+w+N;break;case"^":w=B.slice(0,L=B.length>>1)+H+w+N+B.slice(L);break;default:w=B+H+w+N;break}return s(w)}return P.toString=function(){return d+""},P}function u(d,h){var f=c((d=Sr(d),d.type="f",d)),p=Math.max(-8,Math.min(8,Math.floor(_i(h)/3)))*3,g=Math.pow(10,-p),m=Wh[8+p/3];return function(v){return f(g*v)+m}}return{format:c,formatPrefix:u}}var js,il,Yh;lx({thousands:",",grouping:[3],currency:["$",""]});function lx(e){return js=ox(e),il=js.format,Yh=js.formatPrefix,js}function cx(e){return Math.max(0,-_i(Math.abs(e)))}function ux(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(_i(t)/3)))*3-_i(Math.abs(e)))}function hx(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,_i(t)-_i(e))+1}var Tt=1e-6,qh=1e-12,gt=Math.PI,de=gt/2,Xh=gt/4,xe=gt*2,re=180/gt,Nt=gt/180,Ot=Math.abs,Zh=Math.atan,jn=Math.atan2,Mt=Math.cos,dx=Math.exp,fx=Math.log,bt=Math.sin,Nn=Math.sign||function(e){return e>0?1:e<0?-1:0},He=Math.sqrt,px=Math.tan;function gx(e){return e>1?0:e<-1?gt:Math.acos(e)}function gn(e){return e>1?de:e<-1?-de:Math.asin(e)}function we(){}function Ks(e,t){e&&Kh.hasOwnProperty(e.type)&&Kh[e.type](e,t)}var jh={Feature:function(e,t){Ks(e.geometry,t)},FeatureCollection:function(e,t){for(var n=e.features,i=-1,r=n.length;++i<r;)Ks(n[i].geometry,t)}},Kh={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,i=-1,r=n.length;++i<r;)e=n[i],t.point(e[0],e[1],e[2])},LineString:function(e,t){rl(e.coordinates,t,0)},MultiLineString:function(e,t){for(var n=e.coordinates,i=-1,r=n.length;++i<r;)rl(n[i],t,0)},Polygon:function(e,t){Qh(e.coordinates,t)},MultiPolygon:function(e,t){for(var n=e.coordinates,i=-1,r=n.length;++i<r;)Qh(n[i],t)},GeometryCollection:function(e,t){for(var n=e.geometries,i=-1,r=n.length;++i<r;)Ks(n[i],t)}};function rl(e,t,n){var i=-1,r=e.length-n,s;for(t.lineStart();++i<r;)s=e[i],t.point(s[0],s[1],s[2]);t.lineEnd()}function Qh(e,t){var n=-1,i=e.length;for(t.polygonStart();++n<i;)rl(e[n],t,1);t.polygonEnd()}function Ti(e,t){e&&jh.hasOwnProperty(e.type)?jh[e.type](e,t):Ks(e,t)}function sl(e){return[jn(e[1],e[0]),gn(e[2])]}function Oi(e){var t=e[0],n=e[1],i=Mt(n);return[i*Mt(t),i*bt(t),bt(n)]}function Qs(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}function Js(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 al(e,t){e[0]+=t[0],e[1]+=t[1],e[2]+=t[2]}function ta(e,t){return[e[0]*t,e[1]*t,e[2]*t]}function ol(e){var t=He(e[0]*e[0]+e[1]*e[1]+e[2]*e[2]);e[0]/=t,e[1]/=t,e[2]/=t}function ll(e,t){function n(i,r){return i=e(i,r),t(i[0],i[1])}return e.invert&&t.invert&&(n.invert=function(i,r){return i=t.invert(i,r),i&&e.invert(i[0],i[1])}),n}function cl(e,t){return Ot(e)>gt&&(e-=Math.round(e/xe)*xe),[e,t]}cl.invert=cl;function Jh(e,t,n){return(e%=xe)?t||n?ll(ed(e),nd(t,n)):ed(e):t||n?nd(t,n):cl}function td(e){return function(t,n){return t+=e,Ot(t)>gt&&(t-=Math.round(t/xe)*xe),[t,n]}}function ed(e){var t=td(e);return t.invert=td(-e),t}function nd(e,t){var n=Mt(e),i=bt(e),r=Mt(t),s=bt(t);function a(o,l){var c=Mt(l),u=Mt(o)*c,d=bt(o)*c,h=bt(l),f=h*n+u*i;return[jn(d*r-f*s,u*n-h*i),gn(f*r+d*s)]}return a.invert=function(o,l){var c=Mt(l),u=Mt(o)*c,d=bt(o)*c,h=bt(l),f=h*r-d*s;return[jn(d*r+h*s,u*n+f*i),gn(f*n-u*i)]},a}function mx(e){e=Jh(e[0]*Nt,e[1]*Nt,e.length>2?e[2]*Nt:0);function t(n){return n=e(n[0]*Nt,n[1]*Nt),n[0]*=re,n[1]*=re,n}return t.invert=function(n){return n=e.invert(n[0]*Nt,n[1]*Nt),n[0]*=re,n[1]*=re,n},t}function vx(e,t,n,i,r,s){if(n){var a=Mt(t),o=bt(t),l=i*n;r==null?(r=t+i*xe,s=t-l/2):(r=id(a,r),s=id(a,s),(i>0?r<s:r>s)&&(r+=i*xe));for(var c,u=r;i>0?u>s:u<s;u-=l)c=sl([a,-o*Mt(u),-o*bt(u)]),e.point(c[0],c[1])}}function id(e,t){t=Oi(t),t[0]-=e,ol(t);var n=gx(-t[1]);return((-t[2]<0?-n:n)+xe-Tt)%xe}function rd(){var e=[],t;return{point:function(n,i,r){t.push([n,i,r])},lineStart:function(){e.push(t=[])},lineEnd:we,rejoin:function(){e.length>1&&e.push(e.pop().concat(e.shift()))},result:function(){var n=e;return e=[],t=null,n}}}function ea(e,t){return Ot(e[0]-t[0])<Tt&&Ot(e[1]-t[1])<Tt}function na(e,t,n,i){this.x=e,this.z=t,this.o=n,this.e=i,this.v=!1,this.n=this.p=null}function sd(e,t,n,i,r){var s=[],a=[],o,l;if(e.forEach(function(p){if(!((g=p.length-1)<=0)){var g,m=p[0],v=p[g],S;if(ea(m,v)){if(!m[2]&&!v[2]){for(r.lineStart(),o=0;o<g;++o)r.point((m=p[o])[0],m[1]);r.lineEnd();return}v[0]+=2*Tt}s.push(S=new na(m,p,null,!0)),a.push(S.o=new na(m,null,S,!1)),s.push(S=new na(v,p,null,!1)),a.push(S.o=new na(v,null,S,!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,r.lineStart();do{if(h.v=h.o.v=!0,h.e){if(f)for(o=0,l=u.length;o<l;++o)r.point((d=u[o])[0],d[1]);else i(h.x,h.n.x,1,r);h=h.n}else{if(f)for(u=h.p.z,o=u.length-1;o>=0;--o)r.point((d=u[o])[0],d[1]);else i(h.x,h.p.x,-1,r);h=h.p}h=h.o,u=h.z,f=!f}while(!h.v);r.lineEnd()}}}function ad(e){if(t=e.length){for(var t,n=0,i=e[0],r;++n<t;)i.n=r=e[n],r.p=i,i=r;i.n=r=e[0],r.p=i}}function ul(e){return Ot(e[0])<=gt?e[0]:Nn(e[0])*((Ot(e[0])+gt)%xe-gt)}function yx(e,t){var n=ul(t),i=t[1],r=bt(i),s=[bt(n),-Mt(n),0],a=0,o=0,l=new Vn;r===1?i=de+Tt:r===-1&&(i=-de-Tt);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=ul(f),g=f[1]/2+Xh,m=bt(g),v=Mt(g),S=0;S<h;++S,p=b,m=_,v=C,f=E){var E=d[S],b=ul(E),x=E[1]/2+Xh,_=bt(x),C=Mt(x),A=b-p,$=A>=0?1:-1,P=$*A,w=P>gt,H=m*_;if(l.add(jn(H*$*bt(P),v*C+H*Mt(P))),a+=w?A+$*xe:A,w^p>=n^b>=n){var N=Js(Oi(f),Oi(E));ol(N);var M=Js(s,N);ol(M);var O=(w^A>=0?-1:1)*gn(M[2]);(i>O||i===O&&(N[0]||N[1]))&&(o+=w^A>=0?1:-1)}}return(a<-Tt||a<Tt&&l<-qh)^o&1}function od(e,t,n,i){return function(r){var s=t(r),a=rd(),o=t(a),l=!1,c,u,d,h={point:f,lineStart:g,lineEnd:m,polygonStart:function(){h.point=v,h.lineStart=S,h.lineEnd=E,u=[],c=[]},polygonEnd:function(){h.point=f,h.lineStart=g,h.lineEnd=m,u=Bu(u);var b=yx(c,i);u.length?(l||(r.polygonStart(),l=!0),sd(u,xx,b,n,r)):b&&(l||(r.polygonStart(),l=!0),r.lineStart(),n(null,null,1,r),r.lineEnd()),l&&(r.polygonEnd(),l=!1),u=c=null},sphere:function(){r.polygonStart(),r.lineStart(),n(null,null,1,r),r.lineEnd(),r.polygonEnd()}};function f(b,x){e(b,x)&&r.point(b,x)}function p(b,x){s.point(b,x)}function g(){h.point=p,s.lineStart()}function m(){h.point=f,s.lineEnd()}function v(b,x){d.push([b,x]),o.point(b,x)}function S(){o.lineStart(),d=[]}function E(){v(d[0][0],d[0][1]),o.lineEnd();var b=o.clean(),x=a.result(),_,C=x.length,A,$,P;if(d.pop(),c.push(d),d=null,!!C){if(b&1){if($=x[0],(A=$.length-1)>0){for(l||(r.polygonStart(),l=!0),r.lineStart(),_=0;_<A;++_)r.point((P=$[_])[0],P[1]);r.lineEnd()}return}C>1&&b&2&&x.push(x.pop().concat(x.shift())),u.push(x.filter(Ex))}}return h}}function Ex(e){return e.length>1}function xx(e,t){return((e=e.x)[0]<0?e[1]-de-Tt:de-e[1])-((t=t.x)[0]<0?t[1]-de-Tt:de-t[1])}const ld=od(function(){return!0},bx,_x,[-gt,-de]);function bx(e){var t=NaN,n=NaN,i=NaN,r;return{lineStart:function(){e.lineStart(),r=1},point:function(s,a){var o=s>0?gt:-gt,l=Ot(s-t);Ot(l-gt)<Tt?(e.point(t,n=(n+a)/2>0?de:-de),e.point(i,n),e.lineEnd(),e.lineStart(),e.point(o,n),e.point(s,n),r=0):i!==o&&l>=gt&&(Ot(t-i)<Tt&&(t-=i*Tt),Ot(s-o)<Tt&&(s-=o*Tt),n=Sx(t,n,s,a),e.point(i,n),e.lineEnd(),e.lineStart(),e.point(o,n),r=0),e.point(t=s,n=a),i=o},lineEnd:function(){e.lineEnd(),t=n=NaN},clean:function(){return 2-r}}}function Sx(e,t,n,i){var r,s,a=bt(e-n);return Ot(a)>Tt?Zh((bt(t)*(s=Mt(i))*bt(n)-bt(i)*(r=Mt(t))*bt(e))/(r*s*a)):(t+i)/2}function _x(e,t,n,i){var r;if(e==null)r=n*de,i.point(-gt,r),i.point(0,r),i.point(gt,r),i.point(gt,0),i.point(gt,-r),i.point(0,-r),i.point(-gt,-r),i.point(-gt,0),i.point(-gt,r);else if(Ot(e[0]-t[0])>Tt){var s=e[0]<t[0]?gt:-gt;r=n*s/2,i.point(-s,r),i.point(0,r),i.point(s,r)}else i.point(t[0],t[1])}function Tx(e){var t=Mt(e),n=2*Nt,i=t>0,r=Ot(t)>Tt;function s(u,d,h,f){vx(f,e,n,h,u,d)}function a(u,d){return Mt(u)*Mt(d)>t}function o(u){var d,h,f,p,g;return{lineStart:function(){p=f=!1,g=1},point:function(m,v){var S=[m,v],E,b=a(m,v),x=i?b?0:c(m,v):b?c(m+(m<0?gt:-gt),v):0;if(!d&&(p=f=b)&&u.lineStart(),b!==f&&(E=l(d,S),(!E||ea(d,E)||ea(S,E))&&(S[2]=1)),b!==f)g=0,b?(u.lineStart(),E=l(S,d),u.point(E[0],E[1])):(E=l(d,S),u.point(E[0],E[1],2),u.lineEnd()),d=E;else if(r&&d&&i^b){var _;!(x&h)&&(_=l(S,d,!0))&&(g=0,i?(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||!ea(d,S))&&u.point(S[0],S[1]),d=S,f=b,h=x},lineEnd:function(){f&&u.lineEnd(),d=null},clean:function(){return g|(p&&f)<<1}}}function l(u,d,h){var f=Oi(u),p=Oi(d),g=[1,0,0],m=Js(f,p),v=Qs(m,m),S=m[0],E=v-S*S;if(!E)return!h&&u;var b=t*v/E,x=-t*S/E,_=Js(g,m),C=ta(g,b),A=ta(m,x);al(C,A);var $=_,P=Qs(C,$),w=Qs($,$),H=P*P-w*(Qs(C,C)-1);if(!(H<0)){var N=He(H),M=ta($,(-P-N)/w);if(al(M,C),M=sl(M),!h)return M;var O=u[0],F=d[0],U=u[1],L=d[1],B;F<O&&(B=O,O=F,F=B);var tt=F-O,X=Ot(tt-gt)<Tt,Y=X||tt<Tt;if(!X&&L<U&&(B=U,U=L,L=B),Y?X?U+L>0^M[1]<(Ot(M[0]-O)<Tt?U:L):U<=M[1]&&M[1]<=L:tt>gt^(O<=M[0]&&M[0]<=F)){var Q=ta($,(-P+N)/w);return al(Q,C),[M,sl(Q)]}}}function c(u,d){var h=i?e:gt-e,f=0;return u<-h?f|=1:u>h&&(f|=2),d<-h?f|=4:d>h&&(f|=8),f}return od(a,o,s,i?[0,-e]:[-gt,e-gt])}function Ox(e,t,n,i,r,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=r-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=i-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 _r=1e9,ia=-_r;function wx(e,t,n,i){function r(c,u){return e<=c&&c<=n&&t<=u&&u<=i}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?i:t);while((f=(f+d+4)%4)!==p);else h.point(u[0],u[1])}function a(c,u){return Ot(c[0]-e)<Tt?u>0?0:3:Ot(c[0]-n)<Tt?u>0?2:1:Ot(c[1]-t)<Tt?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=rd(),h,f,p,g,m,v,S,E,b,x,_,C={point:A,lineStart:H,lineEnd:N,polygonStart:P,polygonEnd:w};function A(O,F){r(O,F)&&u.point(O,F)}function $(){for(var O=0,F=0,U=f.length;F<U;++F)for(var L=f[F],B=1,tt=L.length,X=L[0],Y,Q,ut=X[0],et=X[1];B<tt;++B)Y=ut,Q=et,X=L[B],ut=X[0],et=X[1],Q<=i?et>i&&(ut-Y)*(i-Q)>(et-Q)*(e-Y)&&++O:et<=i&&(ut-Y)*(i-Q)<(et-Q)*(e-Y)&&--O;return O}function P(){u=d,h=[],f=[],_=!0}function w(){var O=$(),F=_&&O,U=(h=Bu(h)).length;(F||U)&&(c.polygonStart(),F&&(c.lineStart(),s(null,null,1,c),c.lineEnd()),U&&sd(h,o,O,s,c),c.polygonEnd()),u=c,h=f=p=null}function H(){C.point=M,f&&f.push(p=[]),x=!0,b=!1,S=E=NaN}function N(){h&&(M(g,m),v&&b&&d.rejoin(),h.push(d.result())),C.point=A,b&&u.lineEnd()}function M(O,F){var U=r(O,F);if(f&&p.push([O,F]),x)g=O,m=F,v=U,x=!1,U&&(u.lineStart(),u.point(O,F));else if(U&&b)u.point(O,F);else{var L=[S=Math.max(ia,Math.min(_r,S)),E=Math.max(ia,Math.min(_r,E))],B=[O=Math.max(ia,Math.min(_r,O)),F=Math.max(ia,Math.min(_r,F))];Ox(L,B,e,t,n,i)?(b||(u.lineStart(),u.point(L[0],L[1])),u.point(B[0],B[1]),U||u.lineEnd(),_=!1):U&&(u.lineStart(),u.point(O,F),_=!1)}S=O,E=F,b=U}return C}}const hl=e=>e;var dl=new Vn,fl=new Vn,cd,ud,pl,gl,mn={point:we,lineStart:we,lineEnd:we,polygonStart:function(){mn.lineStart=Mx,mn.lineEnd=Ax},polygonEnd:function(){mn.lineStart=mn.lineEnd=mn.point=we,dl.add(Ot(fl)),fl=new Vn},result:function(){var e=dl/2;return dl=new Vn,e}};function Mx(){mn.point=Cx}function Cx(e,t){mn.point=hd,cd=pl=e,ud=gl=t}function hd(e,t){fl.add(gl*e-pl*t),pl=e,gl=t}function Ax(){hd(cd,ud)}var wi=1/0,ra=wi,Tr=-wi,sa=Tr,aa={point:Dx,lineStart:we,lineEnd:we,polygonStart:we,polygonEnd:we,result:function(){var e=[[wi,ra],[Tr,sa]];return Tr=sa=-(ra=wi=1/0),e}};function Dx(e,t){e<wi&&(wi=e),e>Tr&&(Tr=e),t<ra&&(ra=t),t>sa&&(sa=t)}var ml=0,vl=0,Or=0,oa=0,la=0,Mi=0,yl=0,El=0,wr=0,dd,fd,Je,tn,Me={point:Kn,lineStart:pd,lineEnd:gd,polygonStart:function(){Me.lineStart=Ix,Me.lineEnd=kx},polygonEnd:function(){Me.point=Kn,Me.lineStart=pd,Me.lineEnd=gd},result:function(){var e=wr?[yl/wr,El/wr]:Mi?[oa/Mi,la/Mi]:Or?[ml/Or,vl/Or]:[NaN,NaN];return ml=vl=Or=oa=la=Mi=yl=El=wr=0,e}};function Kn(e,t){ml+=e,vl+=t,++Or}function pd(){Me.point=Lx}function Lx(e,t){Me.point=Rx,Kn(Je=e,tn=t)}function Rx(e,t){var n=e-Je,i=t-tn,r=He(n*n+i*i);oa+=r*(Je+e)/2,la+=r*(tn+t)/2,Mi+=r,Kn(Je=e,tn=t)}function gd(){Me.point=Kn}function Ix(){Me.point=Px}function kx(){md(dd,fd)}function Px(e,t){Me.point=md,Kn(dd=Je=e,fd=tn=t)}function md(e,t){var n=e-Je,i=t-tn,r=He(n*n+i*i);oa+=r*(Je+e)/2,la+=r*(tn+t)/2,Mi+=r,r=tn*e-Je*t,yl+=r*(Je+e),El+=r*(tn+t),wr+=r*3,Kn(Je=e,tn=t)}function vd(e){this._context=e}vd.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,xe);break}}},result:we};var xl=new Vn,bl,yd,Ed,Mr,Cr,Ar={point:we,lineStart:function(){Ar.point=Nx},lineEnd:function(){bl&&xd(yd,Ed),Ar.point=we},polygonStart:function(){bl=!0},polygonEnd:function(){bl=null},result:function(){var e=+xl;return xl=new Vn,e}};function Nx(e,t){Ar.point=xd,yd=Mr=e,Ed=Cr=t}function xd(e,t){Mr-=e,Cr-=t,xl.add(He(Mr*Mr+Cr*Cr)),Mr=e,Cr=t}let bd,ca,Sd,_d;class Td{constructor(t){this._append=t==null?Od:$x(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!==Sd||this._append!==ca){const i=this._radius,r=this._;this._="",this._append`m0,${i}a${i},${i} 0 1,1 0,${-2*i}a${i},${i} 0 1,1 0,${2*i}z`,Sd=i,ca=this._append,_d=this._,this._=r}this._+=_d;break}}}result(){const t=this._;return this._="",t.length?t:null}}function Od(e){let t=1;this._+=e[0];for(const n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function $x(e){const t=Math.floor(e);if(!(t>=0))throw new RangeError(`invalid digits: ${e}`);if(t>15)return Od;if(t!==bd){const n=10**t;bd=t,ca=function(r){let s=1;this._+=r[0];for(const a=r.length;s<a;++s)this._+=Math.round(arguments[s]*n)/n+r[s]}}return ca}function Fx(e,t){let n=3,i=4.5,r,s;function a(o){return o&&(typeof i=="function"&&s.pointRadius(+i.apply(this,arguments)),Ti(o,r(s))),s.result()}return a.area=function(o){return Ti(o,r(mn)),mn.result()},a.measure=function(o){return Ti(o,r(Ar)),Ar.result()},a.bounds=function(o){return Ti(o,r(aa)),aa.result()},a.centroid=function(o){return Ti(o,r(Me)),Me.result()},a.projection=function(o){return arguments.length?(r=o==null?(e=null,hl):(e=o).stream,a):e},a.context=function(o){return arguments.length?(s=o==null?(t=null,new Td(n)):new vd(t=o),typeof i!="function"&&s.pointRadius(i),a):t},a.pointRadius=function(o){return arguments.length?(i=typeof o=="function"?o:(s.pointRadius(+o),+o),a):i},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 Td(n)),a},a.projection(e).digits(n).context(t)}function Sl(e){return function(t){var n=new _l;for(var i in e)n[i]=e[i];return n.stream=t,n}}function _l(){}_l.prototype={constructor:_l,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 Tl(e,t,n){var i=e.clipExtent&&e.clipExtent();return e.scale(150).translate([0,0]),i!=null&&e.clipExtent(null),Ti(n,e.stream(aa)),t(aa.result()),i!=null&&e.clipExtent(i),e}function wd(e,t,n){return Tl(e,function(i){var r=t[1][0]-t[0][0],s=t[1][1]-t[0][1],a=Math.min(r/(i[1][0]-i[0][0]),s/(i[1][1]-i[0][1])),o=+t[0][0]+(r-a*(i[1][0]+i[0][0]))/2,l=+t[0][1]+(s-a*(i[1][1]+i[0][1]))/2;e.scale(150*a).translate([o,l])},n)}function Ux(e,t,n){return wd(e,[[0,0],t],n)}function Bx(e,t,n){return Tl(e,function(i){var r=+t,s=r/(i[1][0]-i[0][0]),a=(r-s*(i[1][0]+i[0][0]))/2,o=-s*i[0][1];e.scale(150*s).translate([a,o])},n)}function Hx(e,t,n){return Tl(e,function(i){var r=+t,s=r/(i[1][1]-i[0][1]),a=-s*i[0][0],o=(r-s*(i[1][1]+i[0][1]))/2;e.scale(150*s).translate([a,o])},n)}var Md=16,Gx=Mt(30*Nt);function Cd(e,t){return+t?zx(e,t):Vx(e)}function Vx(e){return Sl({point:function(t,n){t=e(t,n),this.stream.point(t[0],t[1])}})}function zx(e,t){function n(i,r,s,a,o,l,c,u,d,h,f,p,g,m){var v=c-i,S=u-r,E=v*v+S*S;if(E>4*t&&g--){var b=a+h,x=o+f,_=l+p,C=He(b*b+x*x+_*_),A=gn(_/=C),$=Ot(Ot(_)-1)<Tt||Ot(s-d)<Tt?(s+d)/2:jn(x,b),P=e($,A),w=P[0],H=P[1],N=w-i,M=H-r,O=S*N-v*M;(O*O/E>t||Ot((v*N+S*M)/E-.5)>.3||a*h+o*f+l*p<Gx)&&(n(i,r,s,a,o,l,w,H,$,b/=C,x/=C,_,g,m),m.point(w,H),n(w,H,$,b,x,_,c,u,d,h,f,p,g,m))}}return function(i){var r,s,a,o,l,c,u,d,h,f,p,g,m={point:v,lineStart:S,lineEnd:b,polygonStart:function(){i.polygonStart(),m.lineStart=x},polygonEnd:function(){i.polygonEnd(),m.lineStart=S}};function v(A,$){A=e(A,$),i.point(A[0],A[1])}function S(){d=NaN,m.point=E,i.lineStart()}function E(A,$){var P=Oi([A,$]),w=e(A,$);n(d,h,u,f,p,g,d=w[0],h=w[1],u=A,f=P[0],p=P[1],g=P[2],Md,i),i.point(d,h)}function b(){m.point=v,i.lineEnd()}function x(){S(),m.point=_,m.lineEnd=C}function _(A,$){E(r=A,$),s=d,a=h,o=f,l=p,c=g,m.point=E}function C(){n(d,h,u,f,p,g,s,a,r,o,l,c,Md,i),m.lineEnd=b,b()}return m}}var Wx=Sl({point:function(e,t){this.stream.point(e*Nt,t*Nt)}});function Yx(e){return Sl({point:function(t,n){var i=e(t,n);return this.stream.point(i[0],i[1])}})}function qx(e,t,n,i,r){function s(a,o){return a*=i,o*=r,[t+e*a,n-e*o]}return s.invert=function(a,o){return[(a-t)/e*i,(n-o)/e*r]},s}function Ad(e,t,n,i,r,s){if(!s)return qx(e,t,n,i,r);var a=Mt(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*=i,m*=r,[l*g-c*m+t,n-c*g-l*m]}return p.invert=function(g,m){return[i*(u*g-d*m+h),r*(f-d*g-u*m)]},p}function ua(e){return Dd(function(){return e})()}function Dd(e){var t,n=150,i=480,r=250,s=0,a=0,o=0,l=0,c=0,u,d=0,h=1,f=1,p=null,g=ld,m=null,v,S,E,b=hl,x=.5,_,C,A,$,P;function w(O){return A(O[0]*Nt,O[1]*Nt)}function H(O){return O=A.invert(O[0],O[1]),O&&[O[0]*re,O[1]*re]}w.stream=function(O){return $&&P===O?$:$=Wx(Yx(u)(g(_(b(P=O)))))},w.preclip=function(O){return arguments.length?(g=O,p=void 0,M()):g},w.postclip=function(O){return arguments.length?(b=O,m=v=S=E=null,M()):b},w.clipAngle=function(O){return arguments.length?(g=+O?Tx(p=O*Nt):(p=null,ld),M()):p*re},w.clipExtent=function(O){return arguments.length?(b=O==null?(m=v=S=E=null,hl):wx(m=+O[0][0],v=+O[0][1],S=+O[1][0],E=+O[1][1]),M()):m==null?null:[[m,v],[S,E]]},w.scale=function(O){return arguments.length?(n=+O,N()):n},w.translate=function(O){return arguments.length?(i=+O[0],r=+O[1],N()):[i,r]},w.center=function(O){return arguments.length?(s=O[0]%360*Nt,a=O[1]%360*Nt,N()):[s*re,a*re]},w.rotate=function(O){return arguments.length?(o=O[0]%360*Nt,l=O[1]%360*Nt,c=O.length>2?O[2]%360*Nt:0,N()):[o*re,l*re,c*re]},w.angle=function(O){return arguments.length?(d=O%360*Nt,N()):d*re},w.reflectX=function(O){return arguments.length?(h=O?-1:1,N()):h<0},w.reflectY=function(O){return arguments.length?(f=O?-1:1,N()):f<0},w.precision=function(O){return arguments.length?(_=Cd(C,x=O*O),M()):He(x)},w.fitExtent=function(O,F){return wd(w,O,F)},w.fitSize=function(O,F){return Ux(w,O,F)},w.fitWidth=function(O,F){return Bx(w,O,F)},w.fitHeight=function(O,F){return Hx(w,O,F)};function N(){var O=Ad(n,0,0,h,f,d).apply(null,t(s,a)),F=Ad(n,i-O[0],r-O[1],h,f,d);return u=Jh(o,l,c),C=ll(t,F),A=ll(u,C),_=Cd(C,x),M()}function M(){return $=P=null,w}return function(){return t=e.apply(this,arguments),w.invert=t.invert&&H,N()}}function Ld(e){var t=0,n=gt/3,i=Dd(e),r=i(t,n);return r.parallels=function(s){return arguments.length?i(t=s[0]*Nt,n=s[1]*Nt):[t*re,n*re]},r}function Xx(e){var t=Mt(e);function n(i,r){return[i*t,bt(r)/t]}return n.invert=function(i,r){return[i/t,gn(r*t)]},n}function Zx(e,t){var n=bt(e),i=(n+bt(t))/2;if(Ot(i)<Tt)return Xx(e);var r=1+n*(2*i-n),s=He(r)/i;function a(o,l){var c=He(r-2*i*bt(l))/i;return[c*bt(o*=i),s-c*Mt(o)]}return a.invert=function(o,l){var c=s-l,u=jn(o,Ot(c))*Nn(c);return c*i<0&&(u-=gt*Nn(o)*Nn(c)),[u/i,gn((r-(o*o+c*c)*i*i)/(2*i))]},a}function Rd(){return Ld(Zx).scale(155.424).center([0,33.6442])}function jx(){return Rd().parallels([29.5,45.5]).scale(1070).translate([480,250]).rotate([96,0]).center([-.6,38.7])}function Ol(e,t){return[e,fx(px((de+t)/2))]}Ol.invert=function(e,t){return[e,2*Zh(dx(t))-de]};function Kx(){return Qx(Ol).scale(961/xe)}function Qx(e){var t=ua(e),n=t.center,i=t.scale,r=t.translate,s=t.clipExtent,a=null,o,l,c;t.scale=function(d){return arguments.length?(i(d),u()):i()},t.translate=function(d){return arguments.length?(r(d),u()):r()},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=gt*i(),h=t(mx(t.rotate()).invert([0,0]));return s(a==null?[[h[0]-d,h[1]-d],[h[0]+d,h[1]+d]]:e===Ol?[[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 ha(e,t){return[e,t]}ha.invert=ha;function Jx(){return ua(ha).scale(152.63)}function tb(e,t){var n=Mt(e),i=e===t?bt(e):(n-Mt(t))/(t-e),r=n/i+e;if(Ot(i)<Tt)return ha;function s(a,o){var l=r-o,c=i*a;return[l*bt(c),r-l*Mt(c)]}return s.invert=function(a,o){var l=r-o,c=jn(a,Ot(l))*Nn(l);return l*i<0&&(c-=gt*Nn(a)*Nn(l)),[c/i,r-Nn(i)*He(a*a+l*l)]},s}function eb(){return Ld(tb).scale(131.154).center([0,13.9389])}var Dr=1.340264,Lr=-.081106,Rr=893e-6,Ir=.003796,da=He(3)/2,nb=12;function Id(e,t){var n=gn(da*bt(t)),i=n*n,r=i*i*i;return[e*Mt(n)/(da*(Dr+3*Lr*i+r*(7*Rr+9*Ir*i))),n*(Dr+Lr*i+r*(Rr+Ir*i))]}Id.invert=function(e,t){for(var n=t,i=n*n,r=i*i*i,s=0,a,o,l;s<nb&&(o=n*(Dr+Lr*i+r*(Rr+Ir*i))-t,l=Dr+3*Lr*i+r*(7*Rr+9*Ir*i),n-=a=o/l,i=n*n,r=i*i*i,!(Ot(a)<qh));++s);return[da*e*(Dr+3*Lr*i+r*(7*Rr+9*Ir*i))/Mt(n),gn(bt(n)/da)]};function ib(){return ua(Id).scale(177.158)}function kd(e,t){var n=t*t,i=n*n;return[e*(.8707-.131979*n+i*(-.013791+i*(.003971*n-.001529*i))),t*(1.007226+n*(.015085+i*(-.044475+.028874*n-.005916*i)))]}kd.invert=function(e,t){var n=t,i=25,r;do{var s=n*n,a=s*s;n-=r=(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(Ot(r)>Tt&&--i>0);return[e/(.8707+(s=n*n)*(-.131979+s*(-.013791+s*s*s*(.003971-.001529*s)))),n]};function rb(){return ua(kd).scale(175.295)}function sb(e,t){return e.parent===t.parent?1:2}function ab(e){return e.reduce(ob,0)/e.length}function ob(e,t){return e+t.x}function lb(e){return 1+e.reduce(cb,0)}function cb(e,t){return Math.max(e,t.y)}function ub(e){for(var t;t=e.children;)e=t[0];return e}function hb(e){for(var t;t=e.children;)e=t[t.length-1];return e}function db(){var e=sb,t=1,n=1,i=!1;function r(s){var a,o=0;s.eachAfter(function(h){var f=h.children;f?(h.x=ab(f),h.y=lb(f)):(h.x=a?o+=e(h,a):0,h.y=0,a=h)});var l=ub(s),c=hb(s),u=l.x-e(l,c)/2,d=c.x+e(c,l)/2;return s.eachAfter(i?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 r.separation=function(s){return arguments.length?(e=s,r):e},r.size=function(s){return arguments.length?(i=!1,t=+s[0],n=+s[1],r):i?null:[t,n]},r.nodeSize=function(s){return arguments.length?(i=!0,t=+s[0],n=+s[1],r):i?[t,n]:null},r}function fb(e){var t=0,n=e.children,i=n&&n.length;if(!i)t=1;else for(;--i>=0;)t+=n[i].value;e.value=t}function pb(){return this.eachAfter(fb)}function gb(e,t){let n=-1;for(const i of this)e.call(t,i,++n,this);return this}function mb(e,t){for(var n=this,i=[n],r,s,a=-1;n=i.pop();)if(e.call(t,n,++a,this),r=n.children)for(s=r.length-1;s>=0;--s)i.push(r[s]);return this}function vb(e,t){for(var n=this,i=[n],r=[],s,a,o,l=-1;n=i.pop();)if(r.push(n),s=n.children)for(a=0,o=s.length;a<o;++a)i.push(s[a]);for(;n=r.pop();)e.call(t,n,++l,this);return this}function yb(e,t){let n=-1;for(const i of this)if(e.call(t,i,++n,this))return i}function Eb(e){return this.eachAfter(function(t){for(var n=+e(t.data)||0,i=t.children,r=i&&i.length;--r>=0;)n+=i[r].value;t.value=n})}function xb(e){return this.eachBefore(function(t){t.children&&t.children.sort(e)})}function bb(e){for(var t=this,n=Sb(t,e),i=[t];t!==n;)t=t.parent,i.push(t);for(var r=i.length;e!==n;)i.splice(r,0,e),e=e.parent;return i}function Sb(e,t){if(e===t)return e;var n=e.ancestors(),i=t.ancestors(),r=null;for(e=n.pop(),t=i.pop();e===t;)r=e,e=n.pop(),t=i.pop();return r}function _b(){for(var e=this,t=[e];e=e.parent;)t.push(e);return t}function Tb(){return Array.from(this)}function Ob(){var e=[];return this.eachBefore(function(t){t.children||e.push(t)}),e}function wb(){var e=this,t=[];return e.each(function(n){n!==e&&t.push({source:n.parent,target:n})}),t}function*Mb(){var e=this,t,n=[e],i,r,s;do for(t=n.reverse(),n=[];e=t.pop();)if(yield e,i=e.children)for(r=0,s=i.length;r<s;++r)n.push(i[r]);while(n.length)}function kr(e,t){e instanceof Map?(e=[void 0,e],t===void 0&&(t=Db)):t===void 0&&(t=Ab);for(var n=new Pr(e),i,r=[n],s,a,o,l;i=r.pop();)if((a=t(i.data))&&(l=(a=Array.from(a)).length))for(i.children=a,o=l-1;o>=0;--o)r.push(s=a[o]=new Pr(a[o])),s.parent=i,s.depth=i.depth+1;return n.eachBefore(Rb)}function Cb(){return kr(this).eachBefore(Lb)}function Ab(e){return e.children}function Db(e){return Array.isArray(e)?e[1]:null}function Lb(e){e.data.value!==void 0&&(e.value=e.data.value),e.data=e.data.data}function Rb(e){var t=0;do e.height=t;while((e=e.parent)&&e.height<++t)}function Pr(e){this.data=e,this.depth=this.height=0,this.parent=null}Pr.prototype=kr.prototype={constructor:Pr,count:pb,each:gb,eachAfter:vb,eachBefore:mb,find:yb,sum:Eb,sort:xb,path:bb,ancestors:_b,descendants:Tb,leaves:Ob,links:wb,copy:Cb,[Symbol.iterator]:Mb};function Ib(e){return e==null?null:Pd(e)}function Pd(e){if(typeof e!="function")throw new Error;return e}function Qn(){return 0}function Ci(e){return function(){return e}}const kb=1664525,Pb=1013904223,Nd=4294967296;function Nb(){let e=1;return()=>(e=(kb*e+Pb)%Nd)/Nd}function $b(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function Fb(e,t){let n=e.length,i,r;for(;n;)r=t()*n--|0,i=e[n],e[n]=e[r],e[r]=i;return e}function Ub(e,t){for(var n=0,i=(e=Fb(Array.from(e),t)).length,r=[],s,a;n<i;)s=e[n],a&&$d(a,s)?++n:(a=Hb(r=Bb(r,s)),n=0);return a}function Bb(e,t){var n,i;if(wl(t,e))return[t];for(n=0;n<e.length;++n)if(fa(t,e[n])&&wl(Nr(e[n],t),e))return[e[n],t];for(n=0;n<e.length-1;++n)for(i=n+1;i<e.length;++i)if(fa(Nr(e[n],e[i]),t)&&fa(Nr(e[n],t),e[i])&&fa(Nr(e[i],t),e[n])&&wl(Fd(e[n],e[i],t),e))return[e[n],e[i],t];throw new Error}function fa(e,t){var n=e.r-t.r,i=t.x-e.x,r=t.y-e.y;return n<0||n*n<i*i+r*r}function $d(e,t){var n=e.r-t.r+Math.max(e.r,t.r,1)*1e-9,i=t.x-e.x,r=t.y-e.y;return n>0&&n*n>i*i+r*r}function wl(e,t){for(var n=0;n<t.length;++n)if(!$d(e,t[n]))return!1;return!0}function Hb(e){switch(e.length){case 1:return Gb(e[0]);case 2:return Nr(e[0],e[1]);case 3:return Fd(e[0],e[1],e[2])}}function Gb(e){return{x:e.x,y:e.y,r:e.r}}function Nr(e,t){var n=e.x,i=e.y,r=e.r,s=t.x,a=t.y,o=t.r,l=s-n,c=a-i,u=o-r,d=Math.sqrt(l*l+c*c);return{x:(n+s+l/d*u)/2,y:(i+a+c/d*u)/2,r:(d+r+o)/2}}function Fd(e,t,n){var i=e.x,r=e.y,s=e.r,a=t.x,o=t.y,l=t.r,c=n.x,u=n.y,d=n.r,h=i-a,f=i-c,p=r-o,g=r-u,m=l-s,v=d-s,S=i*i+r*r-s*s,E=S-a*a-o*o+l*l,b=S-c*c-u*u+d*d,x=f*p-h*g,_=(p*b-g*E)/(x*2)-i,C=(g*m-p*v)/x,A=(f*E-h*b)/(x*2)-r,$=(h*v-f*m)/x,P=C*C+$*$-1,w=2*(s+_*C+A*$),H=_*_+A*A-s*s,N=-(Math.abs(P)>1e-6?(w+Math.sqrt(w*w-4*P*H))/(2*P):H/w);return{x:i+_+C*N,y:r+A+$*N,r:N}}function Ud(e,t,n){var i=e.x-t.x,r,s,a=e.y-t.y,o,l,c=i*i+a*a;c?(s=t.r+n.r,s*=s,l=e.r+n.r,l*=l,s>l?(r=(c+l-s)/(2*c),o=Math.sqrt(Math.max(0,l/c-r*r)),n.x=e.x-r*i-o*a,n.y=e.y-r*a+o*i):(r=(c+s-l)/(2*c),o=Math.sqrt(Math.max(0,s/c-r*r)),n.x=t.x+r*i-o*a,n.y=t.y+r*a+o*i)):(n.x=t.x+n.r,n.y=t.y)}function Bd(e,t){var n=e.r+t.r-1e-6,i=t.x-e.x,r=t.y-e.y;return n>0&&n*n>i*i+r*r}function Hd(e){var t=e._,n=e.next._,i=t.r+n.r,r=(t.x*n.r+n.x*t.r)/i,s=(t.y*n.r+n.y*t.r)/i;return r*r+s*s}function pa(e){this._=e,this.next=null,this.previous=null}function Vb(e,t){if(!(s=(e=$b(e)).length))return 0;var n,i,r,s,a,o,l,c,u,d,h;if(n=e[0],n.x=0,n.y=0,!(s>1))return n.r;if(i=e[1],n.x=-i.r,i.x=n.r,i.y=0,!(s>2))return n.r+i.r;Ud(i,n,r=e[2]),n=new pa(n),i=new pa(i),r=new pa(r),n.next=r.previous=i,i.next=n.previous=r,r.next=i.previous=n;t:for(l=3;l<s;++l){Ud(n._,i._,r=e[l]),r=new pa(r),c=i.next,u=n.previous,d=i._.r,h=n._.r;do if(d<=h){if(Bd(c._,r._)){i=c,n.next=i,i.previous=n,--l;continue t}d+=c._.r,c=c.next}else{if(Bd(u._,r._)){n=u,n.next=i,i.previous=n,--l;continue t}h+=u._.r,u=u.previous}while(c!==u.next);for(r.previous=n,r.next=i,n.next=i.previous=i=r,a=Hd(n);(r=r.next)!==i;)(o=Hd(r))<a&&(n=r,a=o);i=n.next}for(n=[i._],r=i;(r=r.next)!==i;)n.push(r._);for(r=Ub(n,t),l=0;l<s;++l)n=e[l],n.x-=r.x,n.y-=r.y;return r.r}function zb(e){return Math.sqrt(e.value)}function Wb(){var e=null,t=1,n=1,i=Qn;function r(s){const a=Nb();return s.x=t/2,s.y=n/2,e?s.eachBefore(Gd(e)).eachAfter(Ml(i,.5,a)).eachBefore(Vd(1)):s.eachBefore(Gd(zb)).eachAfter(Ml(Qn,1,a)).eachAfter(Ml(i,s.r/Math.min(t,n),a)).eachBefore(Vd(Math.min(t,n)/(2*s.r))),s}return r.radius=function(s){return arguments.length?(e=Ib(s),r):e},r.size=function(s){return arguments.length?(t=+s[0],n=+s[1],r):[t,n]},r.padding=function(s){return arguments.length?(i=typeof s=="function"?s:Ci(+s),r):i},r}function Gd(e){return function(t){t.children||(t.r=Math.max(0,+e(t)||0))}}function Ml(e,t,n){return function(i){if(r=i.children){var r,s,a=r.length,o=e(i)*t||0,l;if(o)for(s=0;s<a;++s)r[s].r+=o;if(l=Vb(r,n),o)for(s=0;s<a;++s)r[s].r-=o;i.r=l+o}}}function Vd(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 Yb(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 qb(e,t,n,i,r){for(var s=e.children,a,o=-1,l=s.length,c=e.value&&(i-t)/e.value;++o<l;)a=s[o],a.y0=n,a.y1=r,a.x0=t,a.x1=t+=a.value*c}function Xb(e,t){return e.parent===t.parent?1:2}function Cl(e){var t=e.children;return t?t[0]:e.t}function Al(e){var t=e.children;return t?t[t.length-1]:e.t}function Zb(e,t,n){var i=n/(t.i-e.i);t.c-=i,t.s+=n,e.c+=i,t.z+=n,t.m+=n}function jb(e){for(var t=0,n=0,i=e.children,r=i.length,s;--r>=0;)s=i[r],s.z+=t,s.m+=t,t+=s.s+(n+=s.c)}function Kb(e,t,n){return e.a.parent===t.parent?e.a:n}function ga(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}ga.prototype=Object.create(Pr.prototype);function Qb(e){for(var t=new ga(e,0),n,i=[t],r,s,a,o;n=i.pop();)if(s=n._.children)for(n.children=new Array(o=s.length),a=o-1;a>=0;--a)i.push(r=n.children[a]=new ga(s[a],a)),r.parent=n;return(t.parent=new ga(null,0)).children=[t],t}function Jb(){var e=Xb,t=1,n=1,i=null;function r(c){var u=Qb(c);if(u.eachAfter(s),u.parent.m=-u.z,u.eachBefore(a),i)c.eachBefore(l);else{var d=c,h=c,f=c;c.eachBefore(function(S){S.x<d.x&&(d=S),S.x>h.x&&(h=S),S.depth>f.depth&&(f=S)});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(S){S.x=(S.x+g)*m,S.y=S.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){jb(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,S=p.m,E=g.m,b;p=Al(p),h=Cl(h),p&&h;)g=Cl(g),f=Al(f),f.a=c,b=p.z+S-h.z-m+e(p._,h._),b>0&&(Zb(Kb(p,c,d),c,b),m+=b,v+=b),S+=p.m,m+=h.m,E+=g.m,v+=f.m;p&&!Al(f)&&(f.t=p,f.m+=S-v),h&&!Cl(g)&&(g.t=h,g.m+=m-E,d=c)}return d}function l(c){c.x*=t,c.y=c.depth*n}return r.separation=function(c){return arguments.length?(e=c,r):e},r.size=function(c){return arguments.length?(i=!1,t=+c[0],n=+c[1],r):i?null:[t,n]},r.nodeSize=function(c){return arguments.length?(i=!0,t=+c[0],n=+c[1],r):i?[t,n]:null},r}function tS(e,t,n,i,r){for(var s=e.children,a,o=-1,l=s.length,c=e.value&&(r-n)/e.value;++o<l;)a=s[o],a.x0=t,a.x1=i,a.y0=n,a.y1=n+=a.value*c}var eS=(1+Math.sqrt(5))/2;function nS(e,t,n,i,r,s){for(var a=[],o=t.children,l,c,u=0,d=0,h=o.length,f,p,g=t.value,m,v,S,E,b,x,_;u<h;){f=r-n,p=s-i;do m=o[d++].value;while(!m&&d<h);for(v=S=m,x=Math.max(p/f,f/p)/(g*e),_=m*m*x,b=Math.max(S/_,_/v);d<h;++d){if(m+=c=o[d].value,c<v&&(v=c),c>S&&(S=c),_=m*m*x,E=Math.max(S/_,_/v),E>b){m-=c;break}b=E}a.push(l={value:m,dice:f<p,children:o.slice(u,d)}),l.dice?qb(l,n,i,r,g?i+=p*m/g:s):tS(l,n,i,g?n+=f*m/g:r,s),g-=m,u=d}return a}const iS=function e(t){function n(i,r,s,a,o){nS(t,i,r,s,a,o)}return n.ratio=function(i){return e((i=+i)>1?i:1)},n}(eS);function rS(){var e=iS,t=!1,n=1,i=1,r=[0],s=Qn,a=Qn,o=Qn,l=Qn,c=Qn;function u(h){return h.x0=h.y0=0,h.x1=n,h.y1=i,h.eachBefore(d),r=[0],t&&h.eachBefore(Yb),h}function d(h){var f=r[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=r[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],i=+h[1],u):[n,i]},u.tile=function(h){return arguments.length?(e=Pd(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:Ci(+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:Ci(+h),u):a},u.paddingRight=function(h){return arguments.length?(o=typeof h=="function"?h:Ci(+h),u):o},u.paddingBottom=function(h){return arguments.length?(l=typeof h=="function"?h:Ci(+h),u):l},u.paddingLeft=function(h){return arguments.length?(c=typeof h=="function"?h:Ci(+h),u):c},u}function Ai(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}const zd=Symbol("implicit");function ma(){var e=new Nu,t=[],n=[],i=zd;function r(s){let a=e.get(s);if(a===void 0){if(i!==zd)return i;e.set(s,a=t.push(s)-1)}return n[a%n.length]}return r.domain=function(s){if(!arguments.length)return t.slice();t=[],e=new Nu;for(const a of s)e.has(a)||e.set(a,t.push(a)-1);return r},r.range=function(s){return arguments.length?(n=Array.from(s),r):n.slice()},r.unknown=function(s){return arguments.length?(i=s,r):i},r.copy=function(){return ma(t,n).unknown(i)},Ai.apply(r,arguments),r}function Di(){var e=ma().unknown(void 0),t=e.domain,n=e.range,i=0,r=1,s,a,o=!1,l=0,c=0,u=.5;delete e.unknown;function d(){var h=t().length,f=r<i,p=f?r:i,g=f?i:r;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?([i,r]=h,i=+i,r=+r,d()):[i,r]},e.rangeRound=function(h){return[i,r]=h,i=+i,r=+r,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 Di(t(),[i,r]).round(o).paddingInner(l).paddingOuter(c).align(u)},Ai.apply(d(),arguments)}function sS(e){return function(){return e}}function aS(e){return+e}var Wd=[0,1];function Li(e){return e}function Dl(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:sS(isNaN(t)?NaN:.5)}function oS(e,t){var n;return e>t&&(n=e,e=t,t=n),function(i){return Math.max(e,Math.min(t,i))}}function lS(e,t,n){var i=e[0],r=e[1],s=t[0],a=t[1];return r<i?(i=Dl(r,i),s=n(a,s)):(i=Dl(i,r),s=n(s,a)),function(o){return s(i(o))}}function cS(e,t,n){var i=Math.min(e.length,t.length)-1,r=new Array(i),s=new Array(i),a=-1;for(e[i]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++a<i;)r[a]=Dl(e[a],e[a+1]),s[a]=n(t[a],t[a+1]);return function(o){var l=So(e,o,1,i)-1;return s[l](r[l](o))}}function Ll(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Yd(){var e=Wd,t=Wd,n=vr,i,r,s,a=Li,o,l,c;function u(){var h=Math.min(e.length,t.length);return a!==Li&&(a=oS(e[0],e[h-1])),o=h>2?cS:lS,l=c=null,d}function d(h){return h==null||isNaN(h=+h)?s:(l||(l=o(e.map(i),t,n)))(i(a(h)))}return d.invert=function(h){return a(r((c||(c=o(t,e.map(i),Ee)))(h)))},d.domain=function(h){return arguments.length?(e=Array.from(h,aS),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=mh,u()},d.clamp=function(h){return arguments.length?(a=h?!0:Li,u()):a!==Li},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 i=h,r=f,u()}}function qd(){return Yd()(Li,Li)}function uS(e,t,n,i){var r=To(e,t,n),s;switch(i=Sr(i??",f"),i.type){case"s":{var a=Math.max(Math.abs(e),Math.abs(t));return i.precision==null&&!isNaN(s=ux(r,a))&&(i.precision=s),Yh(i,a)}case"":case"e":case"g":case"p":case"r":{i.precision==null&&!isNaN(s=hx(r,Math.max(Math.abs(e),Math.abs(t))))&&(i.precision=s-(i.type==="e"));break}case"f":case"%":{i.precision==null&&!isNaN(s=cx(r))&&(i.precision=s-(i.type==="%")*2);break}}return il(i)}function Xd(e){var t=e.domain;return e.ticks=function(n){var i=t();return Cs(i[0],i[i.length-1],n??10)},e.tickFormat=function(n,i){var r=t();return uS(r[0],r[r.length-1],n??10,i)},e.nice=function(n){n==null&&(n=10);var i=t(),r=0,s=i.length-1,a=i[r],o=i[s],l,c,u=10;for(o<a&&(c=a,a=o,o=c,c=r,r=s,s=c);u-- >0;){if(c=vi(a,o,n),c===l)return i[r]=a,i[s]=o,t(i);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 Ge(){var e=qd();return e.copy=function(){return Ll(e,Ge())},Ai.apply(e,arguments),Xd(e)}function Zd(e,t){e=e.slice();var n=0,i=e.length-1,r=e[n],s=e[i],a;return s<r&&(a=n,n=i,i=a,a=r,r=s,s=a),e[n]=t.floor(r),e[i]=t.ceil(s),e}function jd(e){return Math.log(e)}function Kd(e){return Math.exp(e)}function hS(e){return-Math.log(-e)}function dS(e){return-Math.exp(-e)}function fS(e){return isFinite(e)?+("1e"+e):e<0?0:e}function pS(e){return e===10?fS:e===Math.E?Math.exp:t=>Math.pow(e,t)}function gS(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 Qd(e){return(t,n)=>-e(-t,n)}function mS(e){const t=e(jd,Kd),n=t.domain;let i=10,r,s;function a(){return r=gS(i),s=pS(i),n()[0]<0?(r=Qd(r),s=Qd(s),e(hS,dS)):e(jd,Kd),t}return t.base=function(o){return arguments.length?(i=+o,a()):i},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=r(c),f=r(u),p,g;const m=o==null?10:+o;let v=[];if(!(i%1)&&f-h<m){if(h=Math.floor(h),f=Math.ceil(f),c>0){for(;h<=f;++h)for(p=1;p<i;++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=i-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=Cs(c,u,m))}else v=Cs(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=i===10?"s":","),typeof l!="function"&&(!(i%1)&&(l=Sr(l)).precision==null&&(l.trim=!0),l=il(l)),o===1/0)return l;const c=Math.max(1,i*o/t.ticks().length);return u=>{let d=u/s(Math.round(r(u)));return d*i<i-.5&&(d*=i),d<=c?l(u):""}},t.nice=()=>n(Zd(n(),{floor:o=>s(Math.floor(r(o))),ceil:o=>s(Math.ceil(r(o)))})),t}function Jd(){const e=mS(Yd()).domain([1,10]);return e.copy=()=>Ll(e,Jd()).base(e.base()),Ai.apply(e,arguments),e}function Rl(){var e=0,t=1,n=1,i=[.5],r=[0,1],s;function a(l){return l!=null&&l<=l?r[So(i,l,0,n)]:s}function o(){var l=-1;for(i=new Array(n);++l<n;)i[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=(r=Array.from(l)).length-1,o()):r.slice()},a.invertExtent=function(l){var c=r.indexOf(l);return c<0?[NaN,NaN]:c<1?[e,i[0]]:c>=n?[i[n-1],t]:[i[c-1],i[c]]},a.unknown=function(l){return arguments.length&&(s=l),a},a.thresholds=function(){return i.slice()},a.copy=function(){return Rl().domain([e,t]).range(r).unknown(s)},Ai.apply(Xd(a),arguments)}const Il=new Date,kl=new Date;function Wt(e,t,n,i){function r(s){return e(s=arguments.length===0?new Date:new Date(+s)),s}return r.floor=s=>(e(s=new Date(+s)),s),r.ceil=s=>(e(s=new Date(s-1)),t(s,1),e(s),s),r.round=s=>{const a=r(s),o=r.ceil(s);return s-a<o-s?a:o},r.offset=(s,a)=>(t(s=new Date(+s),a==null?1:Math.floor(a)),s),r.range=(s,a,o)=>{const l=[];if(s=r.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},r.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&&(r.count=(s,a)=>(Il.setTime(+s),kl.setTime(+a),e(Il),e(kl),Math.floor(n(Il,kl))),r.every=s=>(s=Math.floor(s),!isFinite(s)||!(s>0)?null:s>1?r.filter(i?a=>i(a)%s===0:a=>r.count(0,a)%s===0):r)),r}const va=Wt(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);va.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):va),va.range;const vn=1e3,Ce=vn*60,yn=Ce*60,En=yn*24,Pl=En*7,tf=En*30,Nl=En*365,Ri=Wt(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*vn)},(e,t)=>(t-e)/vn,e=>e.getUTCSeconds());Ri.range;const $l=Wt(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*vn)},(e,t)=>{e.setTime(+e+t*Ce)},(e,t)=>(t-e)/Ce,e=>e.getMinutes());$l.range,Wt(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Ce)},(e,t)=>(t-e)/Ce,e=>e.getUTCMinutes()).range;const Fl=Wt(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*vn-e.getMinutes()*Ce)},(e,t)=>{e.setTime(+e+t*yn)},(e,t)=>(t-e)/yn,e=>e.getHours());Fl.range,Wt(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*yn)},(e,t)=>(t-e)/yn,e=>e.getUTCHours()).range;const $r=Wt(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Ce)/En,e=>e.getDate()-1);$r.range;const Ul=Wt(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/En,e=>e.getUTCDate()-1);Ul.range,Wt(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/En,e=>Math.floor(e/En)).range;function Jn(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())*Ce)/Pl)}const ya=Jn(0),Ea=Jn(1),vS=Jn(2),yS=Jn(3),Ii=Jn(4),ES=Jn(5),xS=Jn(6);ya.range,Ea.range,vS.range,yS.range,Ii.range,ES.range,xS.range;function ti(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)/Pl)}const ef=ti(0),xa=ti(1),bS=ti(2),SS=ti(3),ki=ti(4),_S=ti(5),TS=ti(6);ef.range,xa.range,bS.range,SS.range,ki.range,_S.range,TS.range;const Bl=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());Bl.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 xn=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());xn.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)}),xn.range;const ei=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());ei.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)}),ei.range;function OS(e,t,n,i,r,s){const a=[[Ri,1,vn],[Ri,5,5*vn],[Ri,15,15*vn],[Ri,30,30*vn],[s,1,Ce],[s,5,5*Ce],[s,15,15*Ce],[s,30,30*Ce],[r,1,yn],[r,3,3*yn],[r,6,6*yn],[r,12,12*yn],[i,1,En],[i,2,2*En],[n,1,Pl],[t,1,tf],[t,3,3*tf],[e,1,Nl]];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=bo(([,,m])=>m).right(a,h);if(f===a.length)return e.every(To(c/Nl,u/Nl,d));if(f===0)return va.every(Math.max(To(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[wS,MS]=OS(xn,Bl,ya,$r,Fl,$l);function Hl(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 Gl(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 Fr(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function CS(e){var t=e.dateTime,n=e.date,i=e.time,r=e.periods,s=e.days,a=e.shortDays,o=e.months,l=e.shortMonths,c=Ur(r),u=Br(r),d=Ur(s),h=Br(s),f=Ur(a),p=Br(a),g=Ur(o),m=Br(o),v=Ur(l),S=Br(l),E={a:U,A:L,b:B,B:tt,c:null,d:lf,e:lf,f:KS,g:o_,G:c_,H:XS,I:ZS,j:jS,L:cf,m:QS,M:JS,p:X,q:Y,Q:gf,s:mf,S:t_,u:e_,U:n_,V:i_,w:r_,W:s_,x:null,X:null,y:a_,Y:l_,Z:u_,"%":pf},b={a:Q,A:ut,b:et,B:K,c:null,d:hf,e:hf,f:p_,g:T_,G:w_,H:h_,I:d_,j:f_,L:df,m:g_,M:m_,p:nt,q:ht,Q:gf,s:mf,S:v_,u:y_,U:E_,V:x_,w:b_,W:S_,x:null,X:null,y:__,Y:O_,Z:M_,"%":pf},x={a:P,A:w,b:H,B:N,c:M,d:af,e:af,f:zS,g:sf,G:rf,H:of,I:of,j:BS,L:VS,m:US,M:HS,p:$,q:FS,Q:YS,s:qS,S:GS,u:IS,U:kS,V:PS,w:RS,W:NS,x:O,X:F,y:sf,Y:rf,Z:$S,"%":WS};E.x=_(n,E),E.X=_(i,E),E.c=_(t,E),b.x=_(n,b),b.X=_(i,b),b.c=_(t,b);function _(W,j){return function(J){var D=[],G=-1,V=0,xt=W.length,Ut,st,_t;for(J instanceof Date||(J=new Date(+J));++G<xt;)W.charCodeAt(G)===37&&(D.push(W.slice(V,G)),(st=nf[Ut=W.charAt(++G)])!=null?Ut=W.charAt(++G):st=Ut==="e"?" ":"0",(_t=j[Ut])&&(Ut=_t(J,st)),D.push(Ut),V=G+1);return D.push(W.slice(V,G)),D.join("")}}function C(W,j){return function(J){var D=Fr(1900,void 0,1),G=A(D,W,J+="",0),V,xt;if(G!=J.length)return null;if("Q"in D)return new Date(D.Q);if("s"in D)return new Date(D.s*1e3+("L"in D?D.L:0));if(j&&!("Z"in D)&&(D.Z=0),"p"in D&&(D.H=D.H%12+D.p*12),D.m===void 0&&(D.m="q"in D?D.q:0),"V"in D){if(D.V<1||D.V>53)return null;"w"in D||(D.w=1),"Z"in D?(V=Gl(Fr(D.y,0,1)),xt=V.getUTCDay(),V=xt>4||xt===0?xa.ceil(V):xa(V),V=Ul.offset(V,(D.V-1)*7),D.y=V.getUTCFullYear(),D.m=V.getUTCMonth(),D.d=V.getUTCDate()+(D.w+6)%7):(V=Hl(Fr(D.y,0,1)),xt=V.getDay(),V=xt>4||xt===0?Ea.ceil(V):Ea(V),V=$r.offset(V,(D.V-1)*7),D.y=V.getFullYear(),D.m=V.getMonth(),D.d=V.getDate()+(D.w+6)%7)}else("W"in D||"U"in D)&&("w"in D||(D.w="u"in D?D.u%7:"W"in D?1:0),xt="Z"in D?Gl(Fr(D.y,0,1)).getUTCDay():Hl(Fr(D.y,0,1)).getDay(),D.m=0,D.d="W"in D?(D.w+6)%7+D.W*7-(xt+5)%7:D.w+D.U*7-(xt+6)%7);return"Z"in D?(D.H+=D.Z/100|0,D.M+=D.Z%100,Gl(D)):Hl(D)}}function A(W,j,J,D){for(var G=0,V=j.length,xt=J.length,Ut,st;G<V;){if(D>=xt)return-1;if(Ut=j.charCodeAt(G++),Ut===37){if(Ut=j.charAt(G++),st=x[Ut in nf?j.charAt(G++):Ut],!st||(D=st(W,J,D))<0)return-1}else if(Ut!=J.charCodeAt(D++))return-1}return D}function $(W,j,J){var D=c.exec(j.slice(J));return D?(W.p=u.get(D[0].toLowerCase()),J+D[0].length):-1}function P(W,j,J){var D=f.exec(j.slice(J));return D?(W.w=p.get(D[0].toLowerCase()),J+D[0].length):-1}function w(W,j,J){var D=d.exec(j.slice(J));return D?(W.w=h.get(D[0].toLowerCase()),J+D[0].length):-1}function H(W,j,J){var D=v.exec(j.slice(J));return D?(W.m=S.get(D[0].toLowerCase()),J+D[0].length):-1}function N(W,j,J){var D=g.exec(j.slice(J));return D?(W.m=m.get(D[0].toLowerCase()),J+D[0].length):-1}function M(W,j,J){return A(W,t,j,J)}function O(W,j,J){return A(W,n,j,J)}function F(W,j,J){return A(W,i,j,J)}function U(W){return a[W.getDay()]}function L(W){return s[W.getDay()]}function B(W){return l[W.getMonth()]}function tt(W){return o[W.getMonth()]}function X(W){return r[+(W.getHours()>=12)]}function Y(W){return 1+~~(W.getMonth()/3)}function Q(W){return a[W.getUTCDay()]}function ut(W){return s[W.getUTCDay()]}function et(W){return l[W.getUTCMonth()]}function K(W){return o[W.getUTCMonth()]}function nt(W){return r[+(W.getUTCHours()>=12)]}function ht(W){return 1+~~(W.getUTCMonth()/3)}return{format:function(W){var j=_(W+="",E);return j.toString=function(){return W},j},parse:function(W){var j=C(W+="",!1);return j.toString=function(){return W},j},utcFormat:function(W){var j=_(W+="",b);return j.toString=function(){return W},j},utcParse:function(W){var j=C(W+="",!0);return j.toString=function(){return W},j}}}var nf={"-":"",_:" ",0:"0"},qt=/^\s*\d+/,AS=/^%/,DS=/[\\^$*+?|[\]().{}]/g;function Et(e,t,n){var i=e<0?"-":"",r=(i?-e:e)+"",s=r.length;return i+(s<n?new Array(n-s+1).join(t)+r:r)}function LS(e){return e.replace(DS,"\\$&")}function Ur(e){return new RegExp("^(?:"+e.map(LS).join("|")+")","i")}function Br(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function RS(e,t,n){var i=qt.exec(t.slice(n,n+1));return i?(e.w=+i[0],n+i[0].length):-1}function IS(e,t,n){var i=qt.exec(t.slice(n,n+1));return i?(e.u=+i[0],n+i[0].length):-1}function kS(e,t,n){var i=qt.exec(t.slice(n,n+2));return i?(e.U=+i[0],n+i[0].length):-1}function PS(e,t,n){var i=qt.exec(t.slice(n,n+2));return i?(e.V=+i[0],n+i[0].length):-1}function NS(e,t,n){var i=qt.exec(t.slice(n,n+2));return i?(e.W=+i[0],n+i[0].length):-1}function rf(e,t,n){var i=qt.exec(t.slice(n,n+4));return i?(e.y=+i[0],n+i[0].length):-1}function sf(e,t,n){var i=qt.exec(t.slice(n,n+2));return i?(e.y=+i[0]+(+i[0]>68?1900:2e3),n+i[0].length):-1}function $S(e,t,n){var i=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return i?(e.Z=i[1]?0:-(i[2]+(i[3]||"00")),n+i[0].length):-1}function FS(e,t,n){var i=qt.exec(t.slice(n,n+1));return i?(e.q=i[0]*3-3,n+i[0].length):-1}function US(e,t,n){var i=qt.exec(t.slice(n,n+2));return i?(e.m=i[0]-1,n+i[0].length):-1}function af(e,t,n){var i=qt.exec(t.slice(n,n+2));return i?(e.d=+i[0],n+i[0].length):-1}function BS(e,t,n){var i=qt.exec(t.slice(n,n+3));return i?(e.m=0,e.d=+i[0],n+i[0].length):-1}function of(e,t,n){var i=qt.exec(t.slice(n,n+2));return i?(e.H=+i[0],n+i[0].length):-1}function HS(e,t,n){var i=qt.exec(t.slice(n,n+2));return i?(e.M=+i[0],n+i[0].length):-1}function GS(e,t,n){var i=qt.exec(t.slice(n,n+2));return i?(e.S=+i[0],n+i[0].length):-1}function VS(e,t,n){var i=qt.exec(t.slice(n,n+3));return i?(e.L=+i[0],n+i[0].length):-1}function zS(e,t,n){var i=qt.exec(t.slice(n,n+6));return i?(e.L=Math.floor(i[0]/1e3),n+i[0].length):-1}function WS(e,t,n){var i=AS.exec(t.slice(n,n+1));return i?n+i[0].length:-1}function YS(e,t,n){var i=qt.exec(t.slice(n));return i?(e.Q=+i[0],n+i[0].length):-1}function qS(e,t,n){var i=qt.exec(t.slice(n));return i?(e.s=+i[0],n+i[0].length):-1}function lf(e,t){return Et(e.getDate(),t,2)}function XS(e,t){return Et(e.getHours(),t,2)}function ZS(e,t){return Et(e.getHours()%12||12,t,2)}function jS(e,t){return Et(1+$r.count(xn(e),e),t,3)}function cf(e,t){return Et(e.getMilliseconds(),t,3)}function KS(e,t){return cf(e,t)+"000"}function QS(e,t){return Et(e.getMonth()+1,t,2)}function JS(e,t){return Et(e.getMinutes(),t,2)}function t_(e,t){return Et(e.getSeconds(),t,2)}function e_(e){var t=e.getDay();return t===0?7:t}function n_(e,t){return Et(ya.count(xn(e)-1,e),t,2)}function uf(e){var t=e.getDay();return t>=4||t===0?Ii(e):Ii.ceil(e)}function i_(e,t){return e=uf(e),Et(Ii.count(xn(e),e)+(xn(e).getDay()===4),t,2)}function r_(e){return e.getDay()}function s_(e,t){return Et(Ea.count(xn(e)-1,e),t,2)}function a_(e,t){return Et(e.getFullYear()%100,t,2)}function o_(e,t){return e=uf(e),Et(e.getFullYear()%100,t,2)}function l_(e,t){return Et(e.getFullYear()%1e4,t,4)}function c_(e,t){var n=e.getDay();return e=n>=4||n===0?Ii(e):Ii.ceil(e),Et(e.getFullYear()%1e4,t,4)}function u_(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Et(t/60|0,"0",2)+Et(t%60,"0",2)}function hf(e,t){return Et(e.getUTCDate(),t,2)}function h_(e,t){return Et(e.getUTCHours(),t,2)}function d_(e,t){return Et(e.getUTCHours()%12||12,t,2)}function f_(e,t){return Et(1+Ul.count(ei(e),e),t,3)}function df(e,t){return Et(e.getUTCMilliseconds(),t,3)}function p_(e,t){return df(e,t)+"000"}function g_(e,t){return Et(e.getUTCMonth()+1,t,2)}function m_(e,t){return Et(e.getUTCMinutes(),t,2)}function v_(e,t){return Et(e.getUTCSeconds(),t,2)}function y_(e){var t=e.getUTCDay();return t===0?7:t}function E_(e,t){return Et(ef.count(ei(e)-1,e),t,2)}function ff(e){var t=e.getUTCDay();return t>=4||t===0?ki(e):ki.ceil(e)}function x_(e,t){return e=ff(e),Et(ki.count(ei(e),e)+(ei(e).getUTCDay()===4),t,2)}function b_(e){return e.getUTCDay()}function S_(e,t){return Et(xa.count(ei(e)-1,e),t,2)}function __(e,t){return Et(e.getUTCFullYear()%100,t,2)}function T_(e,t){return e=ff(e),Et(e.getUTCFullYear()%100,t,2)}function O_(e,t){return Et(e.getUTCFullYear()%1e4,t,4)}function w_(e,t){var n=e.getUTCDay();return e=n>=4||n===0?ki(e):ki.ceil(e),Et(e.getUTCFullYear()%1e4,t,4)}function M_(){return"+0000"}function pf(){return"%"}function gf(e){return+e}function mf(e){return Math.floor(+e/1e3)}var Pi,vf;C_({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 C_(e){return Pi=CS(e),vf=Pi.format,Pi.parse,Pi.utcFormat,Pi.utcParse,Pi}function A_(e){return new Date(e)}function D_(e){return e instanceof Date?+e:+new Date(+e)}function yf(e,t,n,i,r,s,a,o,l,c){var u=qd(),d=u.invert,h=u.domain,f=c(".%L"),p=c(":%S"),g=c("%I:%M"),m=c("%I %p"),v=c("%a %d"),S=c("%b %d"),E=c("%B"),b=c("%Y");function x(_){return(l(_)<_?f:o(_)<_?p:a(_)<_?g:s(_)<_?m:i(_)<_?r(_)<_?v:S:n(_)<_?E:b)(_)}return u.invert=function(_){return new Date(d(_))},u.domain=function(_){return arguments.length?h(Array.from(_,D_)):h().map(A_)},u.ticks=function(_){var C=h();return e(C[0],C[C.length-1],_??10)},u.tickFormat=function(_,C){return C==null?x:c(C)},u.nice=function(_){var C=h();return(!_||typeof _.range!="function")&&(_=t(C[0],C[C.length-1],_??10)),_?h(Zd(C,_)):u},u.copy=function(){return Ll(u,yf(e,t,n,i,r,s,a,o,l,c))},u}function Ef(){return Ai.apply(yf(wS,MS,xn,Bl,ya,$r,Fl,$l,Ri,vf).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function pt(e){return function(){return e}}const xf=Math.abs,Jt=Math.atan2,ni=Math.cos,L_=Math.max,Vl=Math.min,en=Math.sin,Ni=Math.sqrt,te=1e-12,Hr=Math.PI,ba=Hr/2,Sa=2*Hr;function R_(e){return e>1?0:e<-1?Hr:Math.acos(e)}function bf(e){return e>=1?ba:e<=-1?-ba: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 i=Math.floor(n);if(!(i>=0))throw new RangeError(`invalid digits: ${n}`);t=i}return e},()=>new tx(t)}function I_(e){return e.innerRadius}function k_(e){return e.outerRadius}function P_(e){return e.startAngle}function N_(e){return e.endAngle}function $_(e){return e&&e.padAngle}function F_(e,t,n,i,r,s,a,o){var l=n-e,c=i-t,u=a-r,d=o-s,h=d*l-u*c;if(!(h*h<te))return h=(u*(t-s)-d*(e-r))/h,[e+h*l,t+h*c]}function Ta(e,t,n,i,r,s,a){var o=e-n,l=t-i,c=(a?s:-s)/Ni(o*o+l*l),u=c*l,d=-c*o,h=e+u,f=t+d,p=n+u,g=i+d,m=(h+p)/2,v=(f+g)/2,S=p-h,E=g-f,b=S*S+E*E,x=r-s,_=h*g-p*f,C=(E<0?-1:1)*Ni(L_(0,x*x*b-_*_)),A=(_*E-S*C)/b,$=(-_*S-E*C)/b,P=(_*E+S*C)/b,w=(-_*S+E*C)/b,H=A-m,N=$-v,M=P-m,O=w-v;return H*H+N*N>M*M+O*O&&(A=P,$=w),{cx:A,cy:$,x01:-u,y01:-d,x11:A*(r/x-1),y11:$*(r/x-1)}}function Gr(){var e=I_,t=k_,n=pt(0),i=null,r=P_,s=N_,a=$_,o=null,l=_a(c);function c(){var u,d,h=+e.apply(this,arguments),f=+t.apply(this,arguments),p=r.apply(this,arguments)-ba,g=s.apply(this,arguments)-ba,m=xf(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>Sa-te)o.moveTo(f*ni(p),f*en(p)),o.arc(0,0,f,p,g,!v),h>te&&(o.moveTo(h*ni(g),h*en(g)),o.arc(0,0,h,g,p,v));else{var S=p,E=g,b=p,x=g,_=m,C=m,A=a.apply(this,arguments)/2,$=A>te&&(i?+i.apply(this,arguments):Ni(h*h+f*f)),P=Vl(xf(f-h)/2,+n.apply(this,arguments)),w=P,H=P,N,M;if($>te){var O=bf($/h*en(A)),F=bf($/f*en(A));(_-=O*2)>te?(O*=v?1:-1,b+=O,x-=O):(_=0,b=x=(p+g)/2),(C-=F*2)>te?(F*=v?1:-1,S+=F,E-=F):(C=0,S=E=(p+g)/2)}var U=f*ni(S),L=f*en(S),B=h*ni(x),tt=h*en(x);if(P>te){var X=f*ni(E),Y=f*en(E),Q=h*ni(b),ut=h*en(b),et;if(m<Hr)if(et=F_(U,L,Q,ut,X,Y,B,tt)){var K=U-et[0],nt=L-et[1],ht=X-et[0],W=Y-et[1],j=1/en(R_((K*ht+nt*W)/(Ni(K*K+nt*nt)*Ni(ht*ht+W*W)))/2),J=Ni(et[0]*et[0]+et[1]*et[1]);w=Vl(P,(h-J)/(j-1)),H=Vl(P,(f-J)/(j+1))}else w=H=0}C>te?H>te?(N=Ta(Q,ut,U,L,f,H,v),M=Ta(X,Y,B,tt,f,H,v),o.moveTo(N.cx+N.x01,N.cy+N.y01),H<P?o.arc(N.cx,N.cy,H,Jt(N.y01,N.x01),Jt(M.y01,M.x01),!v):(o.arc(N.cx,N.cy,H,Jt(N.y01,N.x01),Jt(N.y11,N.x11),!v),o.arc(0,0,f,Jt(N.cy+N.y11,N.cx+N.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(U,L),o.arc(0,0,f,S,E,!v)):o.moveTo(U,L),!(h>te)||!(_>te)?o.lineTo(B,tt):w>te?(N=Ta(B,tt,X,Y,h,-w,v),M=Ta(U,L,Q,ut,h,-w,v),o.lineTo(N.cx+N.x01,N.cy+N.y01),w<P?o.arc(N.cx,N.cy,w,Jt(N.y01,N.x01),Jt(M.y01,M.x01),!v):(o.arc(N.cx,N.cy,w,Jt(N.y01,N.x01),Jt(N.y11,N.x11),!v),o.arc(0,0,h,Jt(N.cy+N.y11,N.cx+N.x11),Jt(M.cy+M.y11,M.cx+M.x11),v),o.arc(M.cx,M.cy,w,Jt(M.y11,M.x11),Jt(M.y01,M.x01),!v))):o.arc(0,0,h,x,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=(+r.apply(this,arguments)+ +s.apply(this,arguments))/2-Hr/2;return[ni(d)*u,en(d)*u]},c.innerRadius=function(u){return arguments.length?(e=typeof u=="function"?u:pt(+u),c):e},c.outerRadius=function(u){return arguments.length?(t=typeof u=="function"?u:pt(+u),c):t},c.cornerRadius=function(u){return arguments.length?(n=typeof u=="function"?u:pt(+u),c):n},c.padRadius=function(u){return arguments.length?(i=u==null?null:typeof u=="function"?u:pt(+u),c):i},c.startAngle=function(u){return arguments.length?(r=typeof u=="function"?u:pt(+u),c):r},c.endAngle=function(u){return arguments.length?(s=typeof u=="function"?u:pt(+u),c):s},c.padAngle=function(u){return arguments.length?(a=typeof u=="function"?u:pt(+u),c):a},c.context=function(u){return arguments.length?(o=u??null,c):o},c}var U_=Array.prototype.slice;function Oa(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function Sf(e){this._context=e}Sf.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 wa(e){return new Sf(e)}function zl(e){return e[0]}function Wl(e){return e[1]}function Vr(e,t){var n=pt(!0),i=null,r=wa,s=null,a=_a(o);e=typeof e=="function"?e:e===void 0?zl:pt(e),t=typeof t=="function"?t:t===void 0?Wl:pt(t);function o(l){var c,u=(l=Oa(l)).length,d,h=!1,f;for(i==null&&(s=r(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:pt(+l),o):e},o.y=function(l){return arguments.length?(t=typeof l=="function"?l:pt(+l),o):t},o.defined=function(l){return arguments.length?(n=typeof l=="function"?l:pt(!!l),o):n},o.curve=function(l){return arguments.length?(r=l,i!=null&&(s=r(i)),o):r},o.context=function(l){return arguments.length?(l==null?i=s=null:s=r(i=l),o):i},o}function Yl(e,t,n){var i=null,r=pt(!0),s=null,a=wa,o=null,l=_a(c);e=typeof e=="function"?e:e===void 0?zl:pt(+e),t=typeof t=="function"?t:pt(t===void 0?0:+t),n=typeof n=="function"?n:n===void 0?Wl:pt(+n);function c(d){var h,f,p,g=(d=Oa(d)).length,m,v=!1,S,E=new Array(g),b=new Array(g);for(s==null&&(o=a(S=l())),h=0;h<=g;++h){if(!(h<g&&r(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(E[p],b[p]);o.lineEnd(),o.areaEnd()}v&&(E[h]=+e(m,h,d),b[h]=+t(m,h,d),o.point(i?+i(m,h,d):E[h],n?+n(m,h,d):b[h]))}if(S)return o=null,S+""||null}function u(){return Vr().defined(r).curve(a).context(s)}return c.x=function(d){return arguments.length?(e=typeof d=="function"?d:pt(+d),i=null,c):e},c.x0=function(d){return arguments.length?(e=typeof d=="function"?d:pt(+d),c):e},c.x1=function(d){return arguments.length?(i=d==null?null:typeof d=="function"?d:pt(+d),c):i},c.y=function(d){return arguments.length?(t=typeof d=="function"?d:pt(+d),n=null,c):t},c.y0=function(d){return arguments.length?(t=typeof d=="function"?d:pt(+d),c):t},c.y1=function(d){return arguments.length?(n=d==null?null:typeof d=="function"?d:pt(+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(i).y(t)},c.defined=function(d){return arguments.length?(r=typeof d=="function"?d:pt(!!d),c):r},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 B_(e,t){return t<e?-1:t>e?1:t>=e?0:NaN}function H_(e){return e}function G_(){var e=H_,t=B_,n=null,i=pt(0),r=pt(Sa),s=pt(0);function a(o){var l,c=(o=Oa(o)).length,u,d,h=0,f=new Array(c),p=new Array(c),g=+i.apply(this,arguments),m=Math.min(Sa,Math.max(-Sa,r.apply(this,arguments)-g)),v,S=Math.min(Math.abs(m)/c,s.apply(this,arguments)),E=S*(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(x,_){return t(p[x],p[_])}):n!=null&&f.sort(function(x,_){return n(o[x],o[_])}),l=0,d=h?(m-c*E)/h:0;l<c;++l,g=v)u=f[l],b=p[u],v=g+(b>0?b*d:0)+E,p[u]={data:o[u],index:l,value:b,startAngle:g,endAngle:v,padAngle:S};return p}return a.value=function(o){return arguments.length?(e=typeof o=="function"?o:pt(+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?(i=typeof o=="function"?o:pt(+o),a):i},a.endAngle=function(o){return arguments.length?(r=typeof o=="function"?o:pt(+o),a):r},a.padAngle=function(o){return arguments.length?(s=typeof o=="function"?o:pt(+o),a):s},a}var V_=Tf(wa);function _f(e){this._curve=e}_f.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 Tf(e){function t(n){return new _f(e(n))}return t._curve=e,t}function z_(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(Tf(n)):t()._curve},e}function W_(){return z_(Vr().curve(V_))}class Y_{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 q_(e){return new Y_(e,!0)}function X_(e){return e.source}function Z_(e){return e.target}function j_(e){let t=X_,n=Z_,i=zl,r=Wl,s=null,a=null,o=_a(l);function l(){let c;const u=U_.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(+i.apply(this,u),+r.apply(this,u)),u[0]=h,a.point(+i.apply(this,u),+r.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?(i=typeof c=="function"?c:pt(+c),l):i},l.y=function(c){return arguments.length?(r=typeof c=="function"?c:pt(+c),l):r},l.context=function(c){return arguments.length?(c==null?s=a=null:a=e(s=c),l):s},l}function K_(){return j_(q_)}function $n(){}function Ma(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 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=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:Ma(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:Ma(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function Q_(e){return new Ca(e)}function Of(e){this._context=e}Of.prototype={areaStart:$n,areaEnd:$n,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:Ma(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function J_(e){return new Of(e)}function wf(e){this._context=e}wf.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,i=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,i):this._context.moveTo(n,i);break;case 3:this._point=4;default:Ma(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function tT(e){return new wf(e)}function Mf(e,t){this._basis=new Ca(e),this._beta=t}Mf.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 i=e[0],r=t[0],s=e[n]-i,a=t[n]-r,o=-1,l;++o<=n;)l=o/n,this._basis.point(this._beta*e[o]+(1-this._beta)*(i+l*s),this._beta*t[o]+(1-this._beta)*(r+l*a));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};const eT=function e(t){function n(i){return t===1?new Ca(i):new Mf(i,t)}return n.beta=function(i){return e(+i)},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 ql(e,t){this._context=e,this._k=(1-t)/6}ql.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 nT=function e(t){function n(i){return new ql(i,t)}return n.tension=function(i){return e(+i)},n}(0);function Xl(e,t){this._context=e,this._k=(1-t)/6}Xl.prototype={areaStart:$n,areaEnd:$n,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 iT=function e(t){function n(i){return new Xl(i,t)}return n.tension=function(i){return e(+i)},n}(0);function Zl(e,t){this._context=e,this._k=(1-t)/6}Zl.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 rT=function e(t){function n(i){return new Zl(i,t)}return n.tension=function(i){return e(+i)},n}(0);function jl(e,t,n){var i=e._x1,r=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);i=(i*o-e._x0*e._l12_2a+e._x2*e._l01_2a)/l,r=(r*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(i,r,s,a,e._x2,e._y2)}function Cf(e,t){this._context=e,this._alpha=t}Cf.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,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+i*i,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:jl(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 sT=function e(t){function n(i){return t?new Cf(i,t):new ql(i,0)}return n.alpha=function(i){return e(+i)},n}(.5);function Af(e,t){this._context=e,this._alpha=t}Af.prototype={areaStart:$n,areaEnd:$n,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,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+i*i,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:jl(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 aT=function e(t){function n(i){return t?new Af(i,t):new Xl(i,0)}return n.alpha=function(i){return e(+i)},n}(.5);function Df(e,t){this._context=e,this._alpha=t}Df.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,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+i*i,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:jl(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 oT=function e(t){function n(i){return t?new Df(i,t):new Zl(i,0)}return n.alpha=function(i){return e(+i)},n}(.5);function Lf(e){this._context=e}Lf.prototype={areaStart:$n,areaEnd:$n,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 Rf(e){return new Lf(e)}function If(e){return e<0?-1:1}function kf(e,t,n){var i=e._x1-e._x0,r=t-e._x1,s=(e._y1-e._y0)/(i||r<0&&-0),a=(n-e._y1)/(r||i<0&&-0),o=(s*r+a*i)/(i+r);return(If(s)+If(a))*Math.min(Math.abs(s),Math.abs(a),.5*Math.abs(o))||0}function Pf(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function Kl(e,t,n){var i=e._x0,r=e._y0,s=e._x1,a=e._y1,o=(s-i)/3;e._context.bezierCurveTo(i+o,r+o*t,s-o,a-o*n,s,a)}function Da(e){this._context=e}Da.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:Kl(this,this._t0,Pf(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,Kl(this,Pf(this,n=kf(this,e,t)),n);break;default:Kl(this,this._t0,n=kf(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function Nf(e){this._context=new $f(e)}(Nf.prototype=Object.create(Da.prototype)).point=function(e,t){Da.prototype.point.call(this,t,e)};function $f(e){this._context=e}$f.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,i,r,s){this._context.bezierCurveTo(t,e,i,n,s,r)}};function lT(e){return new Da(e)}function cT(e){return new Nf(e)}function Ff(e){this._context=e}Ff.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 i=Uf(e),r=Uf(t),s=0,a=1;a<n;++s,++a)this._context.bezierCurveTo(i[0][s],r[0][s],i[1][s],r[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 Uf(e){var t,n=e.length-1,i,r=new Array(n),s=new Array(n),a=new Array(n);for(r[0]=0,s[0]=2,a[0]=e[0]+2*e[1],t=1;t<n-1;++t)r[t]=1,s[t]=4,a[t]=4*e[t]+2*e[t+1];for(r[n-1]=2,s[n-1]=7,a[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)i=r[t]/s[t-1],s[t]-=i,a[t]-=i*a[t-1];for(r[n-1]=a[n-1]/s[n-1],t=n-2;t>=0;--t)r[t]=(a[t]-r[t+1])/s[t];for(s[n-1]=(e[n]+r[n-1])/2,t=0;t<n-1;++t)s[t]=2*e[t+1]-r[t+1];return[r,s]}function uT(e){return new Ff(e)}function La(e,t){this._context=e,this._t=t}La.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 hT(e){return new La(e,.5)}function dT(e){return new La(e,0)}function fT(e){return new La(e,1)}function Bf(e,t){if((a=e.length)>1)for(var n=1,i,r,s=e[t[0]],a,o=s.length;n<a;++n)for(r=s,s=e[t[n]],i=0;i<o;++i)s[i][1]+=s[i][0]=isNaN(r[i][1])?r[i][0]:r[i][1]}function Hf(e){for(var t=e.length,n=new Array(t);--t>=0;)n[t]=t;return n}function pT(e,t){return e[t]}function gT(e){const t=[];return t.key=e,t}function Ql(){var e=pt([]),t=Hf,n=Bf,i=pT;function r(s){var a=Array.from(e.apply(this,arguments),gT),o,l=a.length,c=-1,u;for(const d of s)for(o=0,++c;o<l;++o)(a[o][c]=[0,+i(d,a[o].key,c,s)]).data=d;for(o=0,u=Oa(t(a));o<l;++o)a[u[o]].index=o;return n(a,u),a}return r.keys=function(s){return arguments.length?(e=typeof s=="function"?s:pt(Array.from(s)),r):e},r.value=function(s){return arguments.length?(i=typeof s=="function"?s:pt(+s),r):i},r.order=function(s){return arguments.length?(t=s==null?Hf:typeof s=="function"?s:pt(Array.from(s)),r):t},r.offset=function(s){return arguments.length?(n=s??Bf,r):n},r}function mT(e,t){if((l=e.length)>0)for(var n,i=0,r,s,a,o,l,c=e[t[0]].length;i<c;++i)for(a=o=0,n=0;n<l;++n)(s=(r=e[t[n]][i])[1]-r[0])>0?(r[0]=a,r[1]=a+=s):s<0?(r[1]=o,r[0]=o+=s):(r[0]=0,r[1]=s)}function zr(e,t,n){this.k=e,this.x=t,this.y=n}zr.prototype={constructor:zr,scale:function(e){return e===1?this:new zr(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new zr(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+")"}},zr.prototype;var Gf=typeof global=="object"&&global&&global.Object===Object&&global,vT=typeof self=="object"&&self&&self.Object===Object&&self,Ve=Gf||vT||Function("return this")(),Ae=Ve.Symbol,Vf=Object.prototype,yT=Vf.hasOwnProperty,ET=Vf.toString,Wr=Ae?Ae.toStringTag:void 0;function xT(e){var t=yT.call(e,Wr),n=e[Wr];try{e[Wr]=void 0;var i=!0}catch{}var r=ET.call(e);return i&&(t?e[Wr]=n:delete e[Wr]),r}var bT=Object.prototype,ST=bT.toString;function _T(e){return ST.call(e)}var TT="[object Null]",OT="[object Undefined]",zf=Ae?Ae.toStringTag:void 0;function ii(e){return e==null?e===void 0?OT:TT:zf&&zf in Object(e)?xT(e):_T(e)}function nn(e){return e!=null&&typeof e=="object"}var wT="[object Symbol]";function Ra(e){return typeof e=="symbol"||nn(e)&&ii(e)==wT}function Jl(e,t){for(var n=-1,i=e==null?0:e.length,r=Array(i);++n<i;)r[n]=t(e[n],n,e);return r}var Zt=Array.isArray,Wf=Ae?Ae.prototype:void 0,Yf=Wf?Wf.toString:void 0;function qf(e){if(typeof e=="string")return e;if(Zt(e))return Jl(e,qf)+"";if(Ra(e))return Yf?Yf.call(e):"";var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}var MT=/\s/;function CT(e){for(var t=e.length;t--&&MT.test(e.charAt(t)););return t}var AT=/^\s+/;function DT(e){return e&&e.slice(0,CT(e)+1).replace(AT,"")}function De(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Xf=NaN,LT=/^[-+]0x[0-9a-f]+$/i,RT=/^0b[01]+$/i,IT=/^0o[0-7]+$/i,kT=parseInt;function $i(e){if(typeof e=="number")return e;if(Ra(e))return Xf;if(De(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=De(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=DT(e);var n=RT.test(e);return n||IT.test(e)?kT(e.slice(2),n?2:8):LT.test(e)?Xf:+e}function tc(e){return e}var PT="[object AsyncFunction]",NT="[object Function]",$T="[object GeneratorFunction]",FT="[object Proxy]";function ec(e){if(!De(e))return!1;var t=ii(e);return t==NT||t==$T||t==PT||t==FT}var nc=Ve["__core-js_shared__"],Zf=function(){var e=/[^.]+$/.exec(nc&&nc.keys&&nc.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function UT(e){return!!Zf&&Zf in e}var BT=Function.prototype,HT=BT.toString;function ri(e){if(e!=null){try{return HT.call(e)}catch{}try{return e+""}catch{}}return""}var GT=/[\\^$.*+?()[\]{}|]/g,VT=/^\[object .+?Constructor\]$/,zT=Function.prototype,WT=Object.prototype,YT=zT.toString,qT=WT.hasOwnProperty,XT=RegExp("^"+YT.call(qT).replace(GT,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function ZT(e){if(!De(e)||UT(e))return!1;var t=ec(e)?XT:VT;return t.test(ri(e))}function jT(e,t){return e?.[t]}function si(e,t){var n=jT(e,t);return ZT(n)?n:void 0}var ic=si(Ve,"WeakMap"),jf=Object.create,KT=function(){function e(){}return function(t){if(!De(t))return{};if(jf)return jf(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function QT(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 JT(){}function Kf(e,t){var n=-1,i=e.length;for(t||(t=Array(i));++n<i;)t[n]=e[n];return t}var tO=800,eO=16,nO=Date.now;function iO(e){var t=0,n=0;return function(){var i=nO(),r=eO-(i-n);if(n=i,r>0){if(++t>=tO)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function rO(e){return function(){return e}}var Ia=function(){try{var e=si(Object,"defineProperty");return e({},"",{}),e}catch{}}(),sO=Ia?function(e,t){return Ia(e,"toString",{configurable:!0,enumerable:!1,value:rO(t),writable:!0})}:tc,Qf=iO(sO);function aO(e,t){for(var n=-1,i=e==null?0:e.length;++n<i&&t(e[n],n,e)!==!1;);return e}function oO(e,t,n,i){for(var r=e.length,s=n+-1;++s<r;)if(t(e[s],s,e))return s;return-1}function lO(e){return e!==e}function cO(e,t,n){for(var i=n-1,r=e.length;++i<r;)if(e[i]===t)return i;return-1}function uO(e,t,n){return t===t?cO(e,t,n):oO(e,lO,n)}function hO(e,t){var n=e==null?0:e.length;return!!n&&uO(e,t,0)>-1}var dO=9007199254740991,fO=/^(?:0|[1-9]\d*)$/;function rc(e,t){var n=typeof e;return t=t??dO,!!t&&(n=="number"||n!="symbol"&&fO.test(e))&&e>-1&&e%1==0&&e<t}function ka(e,t,n){t=="__proto__"&&Ia?Ia(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function Yr(e,t){return e===t||e!==e&&t!==t}var pO=Object.prototype,gO=pO.hasOwnProperty;function Jf(e,t,n){var i=e[t];(!(gO.call(e,t)&&Yr(i,n))||n===void 0&&!(t in e))&&ka(e,t,n)}function Fi(e,t,n,i){var r=!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]),r?ka(n,o,l):Jf(n,o,l)}return n}var tp=Math.max;function ep(e,t,n){return t=tp(t===void 0?e.length-1:t,0),function(){for(var i=arguments,r=-1,s=tp(i.length-t,0),a=Array(s);++r<s;)a[r]=i[t+r];r=-1;for(var o=Array(t+1);++r<t;)o[r]=i[r];return o[t]=n(a),QT(e,this,o)}}function sc(e,t){return Qf(ep(e,t,tc),e+"")}var mO=9007199254740991;function ac(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=mO}function ai(e){return e!=null&&ac(e.length)&&!ec(e)}function vO(e,t,n){if(!De(n))return!1;var i=typeof t;return(i=="number"?ai(n)&&rc(t,n.length):i=="string"&&t in n)?Yr(n[t],e):!1}function yO(e){return sc(function(t,n){var i=-1,r=n.length,s=r>1?n[r-1]:void 0,a=r>2?n[2]:void 0;for(s=e.length>3&&typeof s=="function"?(r--,s):void 0,a&&vO(n[0],n[1],a)&&(s=r<3?void 0:s,r=1),t=Object(t);++i<r;){var o=n[i];o&&e(t,o,i,s)}return t})}var EO=Object.prototype;function Pa(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||EO;return e===n}function xO(e,t){for(var n=-1,i=Array(e);++n<e;)i[n]=t(n);return i}var bO="[object Arguments]";function np(e){return nn(e)&&ii(e)==bO}var ip=Object.prototype,SO=ip.hasOwnProperty,_O=ip.propertyIsEnumerable,Ui=np(function(){return arguments}())?np:function(e){return nn(e)&&SO.call(e,"callee")&&!_O.call(e,"callee")};function TO(){return!1}var rp=typeof q=="object"&&q&&!q.nodeType&&q,sp=rp&&typeof module=="object"&&module&&!module.nodeType&&module,OO=sp&&sp.exports===rp,ap=OO?Ve.Buffer:void 0,wO=ap?ap.isBuffer:void 0,Bi=wO||TO,MO="[object Arguments]",CO="[object Array]",AO="[object Boolean]",DO="[object Date]",LO="[object Error]",RO="[object Function]",IO="[object Map]",kO="[object Number]",PO="[object Object]",NO="[object RegExp]",$O="[object Set]",FO="[object String]",UO="[object WeakMap]",BO="[object ArrayBuffer]",HO="[object DataView]",GO="[object Float32Array]",VO="[object Float64Array]",zO="[object Int8Array]",WO="[object Int16Array]",YO="[object Int32Array]",qO="[object Uint8Array]",XO="[object Uint8ClampedArray]",ZO="[object Uint16Array]",jO="[object Uint32Array]",Rt={};Rt[GO]=Rt[VO]=Rt[zO]=Rt[WO]=Rt[YO]=Rt[qO]=Rt[XO]=Rt[ZO]=Rt[jO]=!0,Rt[MO]=Rt[CO]=Rt[BO]=Rt[AO]=Rt[HO]=Rt[DO]=Rt[LO]=Rt[RO]=Rt[IO]=Rt[kO]=Rt[PO]=Rt[NO]=Rt[$O]=Rt[FO]=Rt[UO]=!1;function KO(e){return nn(e)&&ac(e.length)&&!!Rt[ii(e)]}function oc(e){return function(t){return e(t)}}var op=typeof q=="object"&&q&&!q.nodeType&&q,qr=op&&typeof module=="object"&&module&&!module.nodeType&&module,QO=qr&&qr.exports===op,lc=QO&&Gf.process,Hi=function(){try{var e=qr&&qr.require&&qr.require("util").types;return e||lc&&lc.binding&&lc.binding("util")}catch{}}(),lp=Hi&&Hi.isTypedArray,Na=lp?oc(lp):KO,JO=Object.prototype,tw=JO.hasOwnProperty;function cp(e,t){var n=Zt(e),i=!n&&Ui(e),r=!n&&!i&&Bi(e),s=!n&&!i&&!r&&Na(e),a=n||i||r||s,o=a?xO(e.length,String):[],l=o.length;for(var c in e)(t||tw.call(e,c))&&!(a&&(c=="length"||r&&(c=="offset"||c=="parent")||s&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||rc(c,l)))&&o.push(c);return o}function up(e,t){return function(n){return e(t(n))}}var ew=up(Object.keys,Object),nw=Object.prototype,iw=nw.hasOwnProperty;function hp(e){if(!Pa(e))return ew(e);var t=[];for(var n in Object(e))iw.call(e,n)&&n!="constructor"&&t.push(n);return t}function Xr(e){return ai(e)?cp(e):hp(e)}function rw(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var sw=Object.prototype,aw=sw.hasOwnProperty;function ow(e){if(!De(e))return rw(e);var t=Pa(e),n=[];for(var i in e)i=="constructor"&&(t||!aw.call(e,i))||n.push(i);return n}function Zr(e){return ai(e)?cp(e,!0):ow(e)}var lw=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,cw=/^\w*$/;function cc(e,t){if(Zt(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||Ra(e)?!0:cw.test(e)||!lw.test(e)||t!=null&&e in Object(t)}var jr=si(Object,"create");function uw(){this.__data__=jr?jr(null):{},this.size=0}function hw(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var dw="__lodash_hash_undefined__",fw=Object.prototype,pw=fw.hasOwnProperty;function gw(e){var t=this.__data__;if(jr){var n=t[e];return n===dw?void 0:n}return pw.call(t,e)?t[e]:void 0}var mw=Object.prototype,vw=mw.hasOwnProperty;function yw(e){var t=this.__data__;return jr?t[e]!==void 0:vw.call(t,e)}var Ew="__lodash_hash_undefined__";function xw(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=jr&&t===void 0?Ew:t,this}function oi(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var i=e[t];this.set(i[0],i[1])}}oi.prototype.clear=uw,oi.prototype.delete=hw,oi.prototype.get=gw,oi.prototype.has=yw,oi.prototype.set=xw;function bw(){this.__data__=[],this.size=0}function $a(e,t){for(var n=e.length;n--;)if(Yr(e[n][0],t))return n;return-1}var Sw=Array.prototype,_w=Sw.splice;function Tw(e){var t=this.__data__,n=$a(t,e);if(n<0)return!1;var i=t.length-1;return n==i?t.pop():_w.call(t,n,1),--this.size,!0}function Ow(e){var t=this.__data__,n=$a(t,e);return n<0?void 0:t[n][1]}function ww(e){return $a(this.__data__,e)>-1}function Mw(e,t){var n=this.__data__,i=$a(n,e);return i<0?(++this.size,n.push([e,t])):n[i][1]=t,this}function bn(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var i=e[t];this.set(i[0],i[1])}}bn.prototype.clear=bw,bn.prototype.delete=Tw,bn.prototype.get=Ow,bn.prototype.has=ww,bn.prototype.set=Mw;var Kr=si(Ve,"Map");function Cw(){this.size=0,this.__data__={hash:new oi,map:new(Kr||bn),string:new oi}}function Aw(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Fa(e,t){var n=e.__data__;return Aw(t)?n[typeof t=="string"?"string":"hash"]:n.map}function Dw(e){var t=Fa(this,e).delete(e);return this.size-=t?1:0,t}function Lw(e){return Fa(this,e).get(e)}function Rw(e){return Fa(this,e).has(e)}function Iw(e,t){var n=Fa(this,e),i=n.size;return n.set(e,t),this.size+=n.size==i?0:1,this}function Sn(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var i=e[t];this.set(i[0],i[1])}}Sn.prototype.clear=Cw,Sn.prototype.delete=Dw,Sn.prototype.get=Lw,Sn.prototype.has=Rw,Sn.prototype.set=Iw;var kw="Expected a function";function uc(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(kw);var n=function(){var i=arguments,r=t?t.apply(this,i):i[0],s=n.cache;if(s.has(r))return s.get(r);var a=e.apply(this,i);return n.cache=s.set(r,a)||s,a};return n.cache=new(uc.Cache||Sn),n}uc.Cache=Sn;var Pw=500;function Nw(e){var t=uc(e,function(i){return n.size===Pw&&n.clear(),i}),n=t.cache;return t}var $w=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Fw=/\\(\\)?/g,Uw=Nw(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace($w,function(n,i,r,s){t.push(r?s.replace(Fw,"$1"):i||n)}),t});function Qr(e){return e==null?"":qf(e)}function Ua(e,t){return Zt(e)?e:cc(e,t)?[e]:Uw(Qr(e))}function Jr(e){if(typeof e=="string"||Ra(e))return e;var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function hc(e,t){t=Ua(t,e);for(var n=0,i=t.length;e!=null&&n<i;)e=e[Jr(t[n++])];return n&&n==i?e:void 0}function yt(e,t,n){var i=e==null?void 0:hc(e,t);return i===void 0?n:i}function dc(e,t){for(var n=-1,i=t.length,r=e.length;++n<i;)e[r+n]=t[n];return e}var dp=Ae?Ae.isConcatSpreadable:void 0;function Bw(e){return Zt(e)||Ui(e)||!!(dp&&e&&e[dp])}function Ba(e,t,n,i,r){var s=-1,a=e.length;for(n||(n=Bw),r||(r=[]);++s<a;){var o=e[s];t>0&&n(o)?t>1?Ba(o,t-1,n,i,r):dc(r,o):i||(r[r.length]=o)}return r}function fc(e){var t=e==null?0:e.length;return t?Ba(e,1):[]}function Hw(e){return Qf(ep(e,void 0,fc),e+"")}var pc=up(Object.getPrototypeOf,Object),Gw="[object Object]",Vw=Function.prototype,zw=Object.prototype,fp=Vw.toString,Ww=zw.hasOwnProperty,Yw=fp.call(Object);function pp(e){if(!nn(e)||ii(e)!=Gw)return!1;var t=pc(e);if(t===null)return!0;var n=Ww.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&fp.call(n)==Yw}function gp(e,t,n){var i=-1,r=e.length;t<0&&(t=-t>r?0:r+t),n=n>r?r:n,n<0&&(n+=r),r=t>n?0:n-t>>>0,t>>>=0;for(var s=Array(r);++i<r;)s[i]=e[i+t];return s}function qw(e,t,n){var i=e.length;return n=n===void 0?i:n,!t&&n>=i?e:gp(e,t,n)}var Xw="\\ud800-\\udfff",Zw="\\u0300-\\u036f",jw="\\ufe20-\\ufe2f",Kw="\\u20d0-\\u20ff",Qw=Zw+jw+Kw,Jw="\\ufe0e\\ufe0f",tM="\\u200d",eM=RegExp("["+tM+Xw+Qw+Jw+"]");function mp(e){return eM.test(e)}function nM(e){return e.split("")}var vp="\\ud800-\\udfff",iM="\\u0300-\\u036f",rM="\\ufe20-\\ufe2f",sM="\\u20d0-\\u20ff",aM=iM+rM+sM,oM="\\ufe0e\\ufe0f",lM="["+vp+"]",gc="["+aM+"]",mc="\\ud83c[\\udffb-\\udfff]",cM="(?:"+gc+"|"+mc+")",yp="[^"+vp+"]",Ep="(?:\\ud83c[\\udde6-\\uddff]){2}",xp="[\\ud800-\\udbff][\\udc00-\\udfff]",uM="\\u200d",bp=cM+"?",Sp="["+oM+"]?",hM="(?:"+uM+"(?:"+[yp,Ep,xp].join("|")+")"+Sp+bp+")*",dM=Sp+bp+hM,fM="(?:"+[yp+gc+"?",gc,Ep,xp,lM].join("|")+")",pM=RegExp(mc+"(?="+mc+")|"+fM+dM,"g");function gM(e){return e.match(pM)||[]}function mM(e){return mp(e)?gM(e):nM(e)}function vM(e){return function(t){t=Qr(t);var n=mp(t)?mM(t):void 0,i=n?n[0]:t.charAt(0),r=n?qw(n,1).join(""):t.slice(1);return i[e]()+r}}var yM=vM("toUpperCase");function EM(e){return yM(Qr(e).toLowerCase())}function xM(e,t,n,i){for(var r=-1,s=e==null?0:e.length;++r<s;)n=t(n,e[r],r,e);return n}function bM(e){return function(t){return e?.[t]}}var SM={À:"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"},_M=bM(SM),TM=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,OM="\\u0300-\\u036f",wM="\\ufe20-\\ufe2f",MM="\\u20d0-\\u20ff",CM=OM+wM+MM,AM="["+CM+"]",DM=RegExp(AM,"g");function LM(e){return e=Qr(e),e&&e.replace(TM,_M).replace(DM,"")}var RM=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function IM(e){return e.match(RM)||[]}var kM=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function PM(e){return kM.test(e)}var _p="\\ud800-\\udfff",NM="\\u0300-\\u036f",$M="\\ufe20-\\ufe2f",FM="\\u20d0-\\u20ff",UM=NM+$M+FM,Tp="\\u2700-\\u27bf",Op="a-z\\xdf-\\xf6\\xf8-\\xff",BM="\\xac\\xb1\\xd7\\xf7",HM="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",GM="\\u2000-\\u206f",VM=" \\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",wp="A-Z\\xc0-\\xd6\\xd8-\\xde",zM="\\ufe0e\\ufe0f",Mp=BM+HM+GM+VM,Cp="['’]",Ap="["+Mp+"]",WM="["+UM+"]",Dp="\\d+",YM="["+Tp+"]",Lp="["+Op+"]",Rp="[^"+_p+Mp+Dp+Tp+Op+wp+"]",qM="\\ud83c[\\udffb-\\udfff]",XM="(?:"+WM+"|"+qM+")",ZM="[^"+_p+"]",Ip="(?:\\ud83c[\\udde6-\\uddff]){2}",kp="[\\ud800-\\udbff][\\udc00-\\udfff]",Gi="["+wp+"]",jM="\\u200d",Pp="(?:"+Lp+"|"+Rp+")",KM="(?:"+Gi+"|"+Rp+")",Np="(?:"+Cp+"(?:d|ll|m|re|s|t|ve))?",$p="(?:"+Cp+"(?:D|LL|M|RE|S|T|VE))?",Fp=XM+"?",Up="["+zM+"]?",QM="(?:"+jM+"(?:"+[ZM,Ip,kp].join("|")+")"+Up+Fp+")*",JM="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",tC="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",eC=Up+Fp+QM,nC="(?:"+[YM,Ip,kp].join("|")+")"+eC,iC=RegExp([Gi+"?"+Lp+"+"+Np+"(?="+[Ap,Gi,"$"].join("|")+")",KM+"+"+$p+"(?="+[Ap,Gi+Pp,"$"].join("|")+")",Gi+"?"+Pp+"+"+Np,Gi+"+"+$p,tC,JM,Dp,nC].join("|"),"g");function rC(e){return e.match(iC)||[]}function sC(e,t,n){return e=Qr(e),t=t,t===void 0?PM(e)?rC(e):IM(e):e.match(t)||[]}var aC="['’]",oC=RegExp(aC,"g");function Bp(e){return function(t){return xM(sC(LM(t).replace(oC,"")),e,"")}}var lC=Bp(function(e,t,n){return t=t.toLowerCase(),e+(n?EM(t):t)});function cC(e,t,n){return e===e&&(n!==void 0&&(e=e<=n?e:n),t!==void 0&&(e=e>=t?e:t)),e}function Hp(e,t,n){return n===void 0&&(n=t,t=void 0),n!==void 0&&(n=$i(n),n=n===n?n:0),t!==void 0&&(t=$i(t),t=t===t?t:0),cC($i(e),t,n)}function uC(){this.__data__=new bn,this.size=0}function hC(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function dC(e){return this.__data__.get(e)}function fC(e){return this.__data__.has(e)}var pC=200;function gC(e,t){var n=this.__data__;if(n instanceof bn){var i=n.__data__;if(!Kr||i.length<pC-1)return i.push([e,t]),this.size=++n.size,this;n=this.__data__=new Sn(i)}return n.set(e,t),this.size=n.size,this}function ze(e){var t=this.__data__=new bn(e);this.size=t.size}ze.prototype.clear=uC,ze.prototype.delete=hC,ze.prototype.get=dC,ze.prototype.has=fC,ze.prototype.set=gC;function mC(e,t){return e&&Fi(t,Xr(t),e)}function vC(e,t){return e&&Fi(t,Zr(t),e)}var Gp=typeof q=="object"&&q&&!q.nodeType&&q,Vp=Gp&&typeof module=="object"&&module&&!module.nodeType&&module,yC=Vp&&Vp.exports===Gp,zp=yC?Ve.Buffer:void 0,Wp=zp?zp.allocUnsafe:void 0;function Yp(e,t){if(t)return e.slice();var n=e.length,i=Wp?Wp(n):new e.constructor(n);return e.copy(i),i}function EC(e,t){for(var n=-1,i=e==null?0:e.length,r=0,s=[];++n<i;){var a=e[n];t(a,n,e)&&(s[r++]=a)}return s}function qp(){return[]}var xC=Object.prototype,bC=xC.propertyIsEnumerable,Xp=Object.getOwnPropertySymbols,vc=Xp?function(e){return e==null?[]:(e=Object(e),EC(Xp(e),function(t){return bC.call(e,t)}))}:qp;function SC(e,t){return Fi(e,vc(e),t)}var _C=Object.getOwnPropertySymbols,Zp=_C?function(e){for(var t=[];e;)dc(t,vc(e)),e=pc(e);return t}:qp;function TC(e,t){return Fi(e,Zp(e),t)}function jp(e,t,n){var i=t(e);return Zt(e)?i:dc(i,n(e))}function yc(e){return jp(e,Xr,vc)}function Kp(e){return jp(e,Zr,Zp)}var Ec=si(Ve,"DataView"),xc=si(Ve,"Promise"),Vi=si(Ve,"Set"),Qp="[object Map]",OC="[object Object]",Jp="[object Promise]",tg="[object Set]",eg="[object WeakMap]",ng="[object DataView]",wC=ri(Ec),MC=ri(Kr),CC=ri(xc),AC=ri(Vi),DC=ri(ic),Le=ii;(Ec&&Le(new Ec(new ArrayBuffer(1)))!=ng||Kr&&Le(new Kr)!=Qp||xc&&Le(xc.resolve())!=Jp||Vi&&Le(new Vi)!=tg||ic&&Le(new ic)!=eg)&&(Le=function(e){var t=ii(e),n=t==OC?e.constructor:void 0,i=n?ri(n):"";if(i)switch(i){case wC:return ng;case MC:return Qp;case CC:return Jp;case AC:return tg;case DC:return eg}return t});var LC=Object.prototype,RC=LC.hasOwnProperty;function IC(e){var t=e.length,n=new e.constructor(t);return t&&typeof e[0]=="string"&&RC.call(e,"index")&&(n.index=e.index,n.input=e.input),n}var Ha=Ve.Uint8Array;function bc(e){var t=new e.constructor(e.byteLength);return new Ha(t).set(new Ha(e)),t}function kC(e,t){var n=t?bc(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}var PC=/\w*$/;function NC(e){var t=new e.constructor(e.source,PC.exec(e));return t.lastIndex=e.lastIndex,t}var ig=Ae?Ae.prototype:void 0,rg=ig?ig.valueOf:void 0;function $C(e){return rg?Object(rg.call(e)):{}}function sg(e,t){var n=t?bc(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var FC="[object Boolean]",UC="[object Date]",BC="[object Map]",HC="[object Number]",GC="[object RegExp]",VC="[object Set]",zC="[object String]",WC="[object Symbol]",YC="[object ArrayBuffer]",qC="[object DataView]",XC="[object Float32Array]",ZC="[object Float64Array]",jC="[object Int8Array]",KC="[object Int16Array]",QC="[object Int32Array]",JC="[object Uint8Array]",tA="[object Uint8ClampedArray]",eA="[object Uint16Array]",nA="[object Uint32Array]";function iA(e,t,n){var i=e.constructor;switch(t){case YC:return bc(e);case FC:case UC:return new i(+e);case qC:return kC(e,n);case XC:case ZC:case jC:case KC:case QC:case JC:case tA:case eA:case nA:return sg(e,n);case BC:return new i;case HC:case zC:return new i(e);case GC:return NC(e);case VC:return new i;case WC:return $C(e)}}function ag(e){return typeof e.constructor=="function"&&!Pa(e)?KT(pc(e)):{}}var rA="[object Map]";function sA(e){return nn(e)&&Le(e)==rA}var og=Hi&&Hi.isMap,aA=og?oc(og):sA,oA="[object Set]";function lA(e){return nn(e)&&Le(e)==oA}var lg=Hi&&Hi.isSet,cA=lg?oc(lg):lA,uA=1,hA=2,dA=4,cg="[object Arguments]",fA="[object Array]",pA="[object Boolean]",gA="[object Date]",mA="[object Error]",ug="[object Function]",vA="[object GeneratorFunction]",yA="[object Map]",EA="[object Number]",hg="[object Object]",xA="[object RegExp]",bA="[object Set]",SA="[object String]",_A="[object Symbol]",TA="[object WeakMap]",OA="[object ArrayBuffer]",wA="[object DataView]",MA="[object Float32Array]",CA="[object Float64Array]",AA="[object Int8Array]",DA="[object Int16Array]",LA="[object Int32Array]",RA="[object Uint8Array]",IA="[object Uint8ClampedArray]",kA="[object Uint16Array]",PA="[object Uint32Array]",Dt={};Dt[cg]=Dt[fA]=Dt[OA]=Dt[wA]=Dt[pA]=Dt[gA]=Dt[MA]=Dt[CA]=Dt[AA]=Dt[DA]=Dt[LA]=Dt[yA]=Dt[EA]=Dt[hg]=Dt[xA]=Dt[bA]=Dt[SA]=Dt[_A]=Dt[RA]=Dt[IA]=Dt[kA]=Dt[PA]=!0,Dt[mA]=Dt[ug]=Dt[TA]=!1;function ts(e,t,n,i,r,s){var a,o=t&uA,l=t&hA,c=t&dA;if(n&&(a=r?n(e,i,r,s):n(e)),a!==void 0)return a;if(!De(e))return e;var u=Zt(e);if(u){if(a=IC(e),!o)return Kf(e,a)}else{var d=Le(e),h=d==ug||d==vA;if(Bi(e))return Yp(e,o);if(d==hg||d==cg||h&&!r){if(a=l||h?{}:ag(e),!o)return l?TC(e,vC(a,e)):SC(e,mC(a,e))}else{if(!Dt[d])return r?e:{};a=iA(e,d,o)}}s||(s=new ze);var f=s.get(e);if(f)return f;s.set(e,a),cA(e)?e.forEach(function(m){a.add(ts(m,t,n,m,e,s))}):aA(e)&&e.forEach(function(m,v){a.set(v,ts(m,t,n,v,e,s))});var p=c?l?Kp:yc:l?Zr:Xr,g=u?void 0:p(e);return aO(g||e,function(m,v){g&&(v=m,m=e[v]),Jf(a,v,ts(m,t,n,v,e,s))}),a}var NA=1,$A=4;function _n(e){return ts(e,NA|$A)}var FA="__lodash_hash_undefined__";function UA(e){return this.__data__.set(e,FA),this}function BA(e){return this.__data__.has(e)}function es(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new Sn;++t<n;)this.add(e[t])}es.prototype.add=es.prototype.push=UA,es.prototype.has=BA;function dg(e,t){for(var n=-1,i=e==null?0:e.length;++n<i;)if(t(e[n],n,e))return!0;return!1}function fg(e,t){return e.has(t)}var HA=1,GA=2;function pg(e,t,n,i,r,s){var a=n&HA,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&GA?new es:void 0;for(s.set(e,t),s.set(t,e);++d<o;){var p=e[d],g=t[d];if(i)var m=a?i(g,p,d,t,e,s):i(p,g,d,e,t,s);if(m!==void 0){if(m)continue;h=!1;break}if(f){if(!dg(t,function(v,S){if(!fg(f,S)&&(p===v||r(p,v,n,i,s)))return f.push(S)})){h=!1;break}}else if(!(p===g||r(p,g,n,i,s))){h=!1;break}}return s.delete(e),s.delete(t),h}function VA(e){var t=-1,n=Array(e.size);return e.forEach(function(i,r){n[++t]=[r,i]}),n}function Sc(e){var t=-1,n=Array(e.size);return e.forEach(function(i){n[++t]=i}),n}var zA=1,WA=2,YA="[object Boolean]",qA="[object Date]",XA="[object Error]",ZA="[object Map]",jA="[object Number]",KA="[object RegExp]",QA="[object Set]",JA="[object String]",tD="[object Symbol]",eD="[object ArrayBuffer]",nD="[object DataView]",gg=Ae?Ae.prototype:void 0,_c=gg?gg.valueOf:void 0;function iD(e,t,n,i,r,s,a){switch(n){case nD:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case eD:return!(e.byteLength!=t.byteLength||!s(new Ha(e),new Ha(t)));case YA:case qA:case jA:return Yr(+e,+t);case XA:return e.name==t.name&&e.message==t.message;case KA:case JA:return e==t+"";case ZA:var o=VA;case QA:var l=i&zA;if(o||(o=Sc),e.size!=t.size&&!l)return!1;var c=a.get(e);if(c)return c==t;i|=WA,a.set(e,t);var u=pg(o(e),o(t),i,r,s,a);return a.delete(e),u;case tD:if(_c)return _c.call(e)==_c.call(t)}return!1}var rD=1,sD=Object.prototype,aD=sD.hasOwnProperty;function oD(e,t,n,i,r,s){var a=n&rD,o=yc(e),l=o.length,c=yc(t),u=c.length;if(l!=u&&!a)return!1;for(var d=l;d--;){var h=o[d];if(!(a?h in t:aD.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],S=t[h];if(i)var E=a?i(S,v,h,t,e,s):i(v,S,h,e,t,s);if(!(E===void 0?v===S||r(v,S,n,i,s):E)){g=!1;break}m||(m=h=="constructor")}if(g&&!m){var b=e.constructor,x=t.constructor;b!=x&&"constructor"in e&&"constructor"in t&&!(typeof b=="function"&&b instanceof b&&typeof x=="function"&&x instanceof x)&&(g=!1)}return s.delete(e),s.delete(t),g}var lD=1,mg="[object Arguments]",vg="[object Array]",Ga="[object Object]",cD=Object.prototype,yg=cD.hasOwnProperty;function uD(e,t,n,i,r,s){var a=Zt(e),o=Zt(t),l=a?vg:Le(e),c=o?vg:Le(t);l=l==mg?Ga:l,c=c==mg?Ga:c;var u=l==Ga,d=c==Ga,h=l==c;if(h&&Bi(e)){if(!Bi(t))return!1;a=!0,u=!1}if(h&&!u)return s||(s=new ze),a||Na(e)?pg(e,t,n,i,r,s):iD(e,t,l,n,i,r,s);if(!(n&lD)){var f=u&&yg.call(e,"__wrapped__"),p=d&&yg.call(t,"__wrapped__");if(f||p){var g=f?e.value():e,m=p?t.value():t;return s||(s=new ze),r(g,m,n,i,s)}}return h?(s||(s=new ze),oD(e,t,n,i,r,s)):!1}function Va(e,t,n,i,r){return e===t?!0:e==null||t==null||!nn(e)&&!nn(t)?e!==e&&t!==t:uD(e,t,n,i,Va,r)}var hD=1,dD=2;function fD(e,t,n,i){var r=n.length,s=r;if(e==null)return!s;for(e=Object(e);r--;){var a=n[r];if(a[2]?a[1]!==e[a[0]]:!(a[0]in e))return!1}for(;++r<s;){a=n[r];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 ze,d;if(!(d===void 0?Va(c,l,hD|dD,i,u):d))return!1}}return!0}function Eg(e){return e===e&&!De(e)}function pD(e){for(var t=Xr(e),n=t.length;n--;){var i=t[n],r=e[i];t[n]=[i,r,Eg(r)]}return t}function xg(e,t){return function(n){return n==null?!1:n[e]===t&&(t!==void 0||e in Object(n))}}function gD(e){var t=pD(e);return t.length==1&&t[0][2]?xg(t[0][0],t[0][1]):function(n){return n===e||fD(n,e,t)}}function mD(e,t){return e!=null&&t in Object(e)}function vD(e,t,n){t=Ua(t,e);for(var i=-1,r=t.length,s=!1;++i<r;){var a=Jr(t[i]);if(!(s=e!=null&&n(e,a)))break;e=e[a]}return s||++i!=r?s:(r=e==null?0:e.length,!!r&&ac(r)&&rc(a,r)&&(Zt(e)||Ui(e)))}function yD(e,t){return e!=null&&vD(e,t,mD)}var ED=1,xD=2;function bD(e,t){return cc(e)&&Eg(t)?xg(Jr(e),t):function(n){var i=yt(n,e);return i===void 0&&i===t?yD(n,e):Va(t,i,ED|xD)}}function SD(e){return function(t){return t?.[e]}}function _D(e){return function(t){return hc(t,e)}}function TD(e){return cc(e)?SD(Jr(e)):_D(e)}function za(e){return typeof e=="function"?e:e==null?tc:typeof e=="object"?Zt(e)?bD(e[0],e[1]):gD(e):TD(e)}function OD(e,t,n,i){for(var r=-1,s=e==null?0:e.length;++r<s;){var a=e[r];t(i,a,n(a),e)}return i}function wD(e){return function(t,n,i){for(var r=-1,s=Object(t),a=i(t),o=a.length;o--;){var l=a[++r];if(n(s[l],l,s)===!1)break}return t}}var bg=wD();function MD(e,t){return e&&bg(e,t,Xr)}function CD(e,t){return function(n,i){if(n==null)return n;if(!ai(n))return e(n,i);for(var r=n.length,s=-1,a=Object(n);++s<r&&i(a[s],s,a)!==!1;);return n}}var Tc=CD(MD);function AD(e,t,n,i){return Tc(e,function(r,s,a){t(i,r,n(r),a)}),i}function DD(e,t){return function(n,i){var r=Zt(n)?OD:AD,s={};return r(n,e,za(i),s)}}var Oc=function(){return Ve.Date.now()},LD="Expected a function",RD=Math.max,ID=Math.min;function Wa(e,t,n){var i,r,s,a,o,l,c=0,u=!1,d=!1,h=!0;if(typeof e!="function")throw new TypeError(LD);t=$i(t)||0,De(n)&&(u=!!n.leading,d="maxWait"in n,s=d?RD($i(n.maxWait)||0,t):s,h="trailing"in n?!!n.trailing:h);function f(_){var C=i,A=r;return i=r=void 0,c=_,a=e.apply(A,C),a}function p(_){return c=_,o=setTimeout(v,t),u?f(_):a}function g(_){var C=_-l,A=_-c,$=t-C;return d?ID($,s-A):$}function m(_){var C=_-l,A=_-c;return l===void 0||C>=t||C<0||d&&A>=s}function v(){var _=Oc();if(m(_))return S(_);o=setTimeout(v,g(_))}function S(_){return o=void 0,h&&i?f(_):(i=r=void 0,a)}function E(){o!==void 0&&clearTimeout(o),c=0,i=l=r=o=void 0}function b(){return o===void 0?a:S(Oc())}function x(){var _=Oc(),C=m(_);if(i=arguments,r=this,l=_,C){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 x.cancel=E,x.flush=b,x}function wc(e,t,n){(n!==void 0&&!Yr(e[t],n)||n===void 0&&!(t in e))&&ka(e,t,n)}function Mc(e){return nn(e)&&ai(e)}function Cc(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}function kD(e){return Fi(e,Zr(e))}function PD(e,t,n,i,r,s,a){var o=Cc(e,n),l=Cc(t,n),c=a.get(l);if(c){wc(e,n,c);return}var u=s?s(o,l,n+"",e,t,a):void 0,d=u===void 0;if(d){var h=Zt(l),f=!h&&Bi(l),p=!h&&!f&&Na(l);u=l,h||f||p?Zt(o)?u=o:Mc(o)?u=Kf(o):f?(d=!1,u=Yp(l,!0)):p?(d=!1,u=sg(l,!0)):u=[]:pp(l)||Ui(l)?(u=o,Ui(o)?u=kD(o):(!De(o)||ec(o))&&(u=ag(l))):d=!1}d&&(a.set(l,u),r(u,l,i,s,a),a.delete(l)),wc(e,n,u)}function Sg(e,t,n,i,r){e!==t&&bg(t,function(s,a){if(r||(r=new ze),De(s))PD(e,t,a,n,Sg,i,r);else{var o=i?i(Cc(e,a),s,a+"",e,t,r):void 0;o===void 0&&(o=s),wc(e,a,o)}},Zr)}var ND="Expected a function";function $D(e,t,n){if(typeof e!="function")throw new TypeError(ND);return setTimeout(function(){e.apply(void 0,n)},t)}var FD=sc(function(e,t,n){return $D(e,$i(t)||0,n)});function _g(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}function UD(e,t){var n=-1,i=ai(e)?Array(e.length):[];return Tc(e,function(r,s,a){i[++n]=t(r,s,a)}),i}function BD(e,t){var n=Zt(e)?Jl:UD;return n(e,za(t))}var HD=1/0;function GD(e,t){return Ba(BD(e,t),HD)}function VD(e){for(var t=-1,n=e==null?0:e.length,i={};++t<n;){var r=e[t];i[r[0]]=r[1]}return i}var zD=Object.prototype,WD=zD.hasOwnProperty,YD=DD(function(e,t,n){WD.call(e,n)?e[n].push(t):ka(e,n,[t])});function qD(e,t){return t.length<2?e:hc(e,gp(t,0,-1))}var XD="[object Map]",ZD="[object Set]",jD=Object.prototype,KD=jD.hasOwnProperty;function We(e){if(e==null)return!0;if(ai(e)&&(Zt(e)||typeof e=="string"||typeof e.splice=="function"||Bi(e)||Na(e)||Ui(e)))return!e.length;var t=Le(e);if(t==XD||t==ZD)return!e.size;if(Pa(e))return!hp(e).length;for(var n in e)if(KD.call(e,n))return!1;return!0}function Tg(e,t){return Va(e,t)}var zi=Bp(function(e,t,n){return e+(n?"-":"")+t.toLowerCase()}),ct=yO(function(e,t,n){Sg(e,t,n)});function QD(e,t){return t=Ua(t,e),e=qD(e,t),e==null||delete e[Jr(_g(t))]}function JD(e){return pp(e)?void 0:e}var tL=1,eL=2,nL=4,iL=Hw(function(e,t){var n={};if(e==null)return n;var i=!1;t=Jl(t,function(s){return s=Ua(s,e),i||(i=s.length>1),s}),Fi(e,Kp(e),n),i&&(n=ts(n,tL|eL|nL,JD));for(var r=t.length;r--;)QD(n,t[r]);return n});function rL(e,t){var n;return Tc(e,function(i,r,s){return n=t(i,r,s),!n}),!!n}function sL(e,t,n){var i=Zt(e)?dg:rL;return i(e,za(t))}var aL=1/0,oL=Vi&&1/Sc(new Vi([,-0]))[1]==aL?function(e){return new Vi(e)}:JT,lL=200;function Og(e,t,n){var i=-1,r=hO,s=e.length,a=!0,o=[],l=o;if(s>=lL){var c=t?null:oL(e);if(c)return Sc(c);a=!1,r=fg,l=new es}else l=t?[]:o;t:for(;++i<s;){var u=e[i],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 r(l,d,n)||(l!==o&&l.push(d),o.push(u))}return o}var cL=sc(function(e){var t=_g(e);return Mc(t)&&(t=void 0),Og(Ba(e,1,Mc,!0),za(t))});function ns(e){return e&&e.length?Og(e):[]}var Ac=(e=>(e.RENDER_FINISHED="render-finished",e.RESIZE="chart-resize",e.MOUSEOVER="chart-mouseover",e.MOUSEOUT="chart-mouseout",e))(Ac||{}),Dc=(e=>(e.SHOW="show-modal",e.HIDE="hide-modal",e))(Dc||{}),Lc=(e=>(e.UPDATE="model-update",e))(Lc||{}),wg=(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))(wg||{}),Rc=(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))(Rc||{}),Ic=(e=>(e.CHANGE="zoom-domain-change",e))(Ic||{}),kc=(e=>(e.CANVAS_ZOOM_IN="canvas-zoom-in",e.CANVAS_ZOOM_OUT="canvas-zoom-out",e))(kc||{}),Pc=(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))(Pc||{}),Nc=(e=>(e.POINT_MOUSEOVER="scatter-mouseover",e.POINT_MOUSEMOVE="scatter-mousemove",e.POINT_CLICK="scatter-click",e.POINT_MOUSEOUT="scatter-mouseout",e))(Nc||{}),$c=(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))($c||{}),Fc=(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))(Fc||{}),Uc=(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))(Uc||{}),Bc=(e=>(e.BAR_MOUSEOVER="bar-mouseover",e.BAR_MOUSEMOVE="bar-mousemove",e.BAR_CLICK="bar-click",e.BAR_MOUSEOUT="bar-mouseout",e))(Bc||{}),Hc=(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))(Hc||{}),Gc=(e=>(e.SCATTER_MOUSEOVER="scatter-mouseover",e.SCATTER_MOUSEMOVE="scatter-mousemove",e.SCATTER_CLICK="scatter-click",e.SCATTER_MOUSEOUT="scatter-mouseout",e))(Gc||{}),Vc=(e=>(e.POINT_MOUSEOVER="scatter-mouseover",e.POINT_MOUSEMOVE="scatter-mousemove",e.POINT_CLICK="scatter-click",e.POINT_MOUSEOUT="scatter-mouseout",e))(Vc||{}),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||{}),Wc=(e=>(e.NODE_MOUSEOVER="tree-node-mouseover",e.NODE_CLICK="tree-node-click",e.NODE_MOUSEOUT="tree-node-mouseout",e))(Wc||{}),Yc=(e=>(e.LEAF_MOUSEOVER="leaf-mouseover",e.LEAF_MOUSEMOVE="leaf-mousemove",e.LEAF_CLICK="leaf-click",e.LEAF_MOUSEOUT="leaf-mouseout",e))(Yc||{}),Wi=(e=>(e.SHOW="show-tooltip",e.MOVE="move-tooltip",e.HIDE="hide-tooltip",e))(Wi||{}),qc=(e=>(e.SHOW="show-threshold",e.HIDE="hide-threshold",e))(qc||{}),Mg=(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))(Mg||{}),Cg=(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))(Cg||{}),Ag=(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))(Ag||{}),Dg=(e=>(e.METER_MOUSEOVER="meter-mouseover",e.METER_CLICK="meter-click",e.METER_MOUSEOUT="meter-mouseout",e.METER_MOUSEMOVE="meter-mousemove",e))(Dg||{}),Lg=(e=>(e.HEATMAP_MOUSEOVER="heatmap-mouseover",e.HEATMAP_CLICK="heatmap-click",e.HEATMAP_MOUSEOUT="heatmap-mouseout",e.HEATMAP_MOUSEMOVE="hetmap-mousemove",e))(Lg||{}),Yi=(e=>(e.CHOROPLETH_MOUSEOVER="choropleth-mouseover",e.CHOROPLETH_CLICK="choropleth-click",e.CHOROPLETH_MOUSEOUT="choropleth-mouseout",e.CHOROPLETH_MOUSEMOVE="choropleth-mousemove",e))(Yi||{});const T=Object.freeze(Object.defineProperty({__proto__:null,Alluvial:Ag,Area:Nc,Axis:Pc,Bar:Bc,Boxplot:Hc,CanvasZoom:kc,Chart:Ac,Choropleth:Yi,CirclePack:Cg,Gauge:Uc,Heatmap:Lg,Legend:Mg,Line:Vc,Meter:Dg,Modal:Dc,Model:Lc,Pie:Fc,Radar:zc,Scatter:Gc,Threshold:qc,Toolbar:wg,Tooltip:Wi,Tree:Wc,Treemap:Yc,WordCloud:$c,ZoomBar:Rc,ZoomDomain:Ic},Symbol.toStringTag,{value:"Module"}));var at=(e=>(e.HTML="html",e.SVG="svg",e))(at||{}),Xc=(e=>(e.WHITE="white",e.G100="g100",e.G90="g90",e.G10="g10",e))(Xc||{}),lt=(e=>(e.BACKGROUND="background",e.FILL="fill",e.STROKE="stroke",e.TOOLTIP="tooltip",e))(lt||{}),z=(e=>(e.LEFT="left",e.RIGHT="right",e.TOP="top",e.BOTTOM="bottom",e))(z||{}),Ye=(e=>(e.GRAPH_VIEW="graph_view",e.SLIDER_VIEW="slider_view",e))(Ye||{}),Re=(e=>(e.END_LINE="end_line",e.MID_LINE="mid_line",e.FRONT_LINE="front_line",e.NONE="none",e))(Re||{}),Ht=(e=>(e.VERTICAL="vertical",e.HORIZONTAL="horizontal",e))(Ht||{}),it=(e=>(e.TIME="time",e.LINEAR="linear",e.LOG="log",e.LABELS="labels",e.LABELS_RATIO="labels-ratio",e))(it||{}),qi=(e=>(e.RIGHT="right",e.LEFT="left",e.TOP="top",e.BOTTOM="bottom",e))(qi||{}),Gt=(e=>(e.LEFT="left",e.CENTER="center",e.RIGHT="right",e))(Gt||{}),Xi=(e=>(e.HORIZONTAL="horizontal",e.VERTICAL="vertical",e))(Xi||{}),Ya=(e=>(e.TREE="tree",e.DENDROGRAM="dendrogram",e))(Ya||{}),Ct=(e=>(e.ROW="row",e.COLUMN="column",e.ROW_REVERSE="row-reverse",e.COLUMN_REVERSE="column-reverse",e))(Ct||{}),dt=(e=>(e.FIXED="fixed",e.PREFERRED="preferred",e.STRETCH="stretch",e))(dt||{}),li=(e=>(e.CENTER="center",e))(li||{}),is=(e=>(e.LEFT="left",e.RIGHT="right",e))(is||{}),Vt=(e=>(e.GRID="grid",e.VERT_OR_HORIZ="vertOrHoriz",e.PIE="pie",e.DONUT="donut",e))(Vt||{}),rn=(e=>(e.START="start",e.MIDDLE="middle",e.END="end",e))(rn||{}),sn=(e=>(e.BASELINE="baseline",e.MIDDLE="middle",e.HANGING="hanging",e))(sn||{}),ci=(e=>(e.SEMI="semi",e.FULL="full",e))(ci||{}),qa=(e=>(e.UP="up",e.DOWN="down",e))(qa||{}),rs=(e=>(e.SUCCESS="success",e.WARNING="warning",e.DANGER="danger",e))(rs||{}),ss=(e=>(e.ALWAYS="always",e.AUTO="auto",e.NEVER="never",e))(ss||{}),be=(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))(be||{}),St=(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))(St||{}),Xa=(e=>(e.LEFT="left",e.RIGHT="right",e))(Xa||{}),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||{}),as=(e=>(e.LINEAR="linear",e.QUANTIZE="quantize",e))(as||{}),Zi=(e=>(e.ON="on",e.AUTO="auto",e.OFF="off",e))(Zi||{}),os=(e=>(e.DEFAULT="default",e.HOVERABLE="hoverable",e))(os||{}),an=(e=>(e.geoEqualEarth="geoEqualEarth",e.geoAlbers="geoAlbers",e.geoConicEqualArea="geoConicEqualArea",e.geoConicEquidistant="geoConicEquidistant",e.geoEquirectangular="geoEquirectangular",e.geoMercator="geoMercator",e.geoNaturalEarth1="geoNaturalEarth1",e))(an||{});const fe="cds",Tn={opacity:{unselected:.05,selected:.4}},Fn={ticks:{number:7,verticalSpaceRatio:2.5,horizontalSpaceRatio:3.5},ratio:{reference:"value",compareTo:"marker"},paddingRatio:.1,hover:{rectanglePadding:4}},ji={duration:1e3,ease:Lh,zoomLevel:3},Ki={circles:{fillOpacity:.3,hover:{stroke:"#FFF"}},padding:{mainGroup:4,children:2},depth:2},Rg={pairingOptions:{"1-color":4,"2-color":5,"3-color":5,"4-color":3,"5-color":2,"14-color":1}},Ie={circle:{radius:4,opacity:{hovered:1,default:.3}},box:{opacity:{hovered:.5,default:.3}},strokeWidth:{default:1,thicker:2}},uL={defaultBins:10},Pt={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}},On={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},Lt={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}},ui={opacity:{unselected:.1,selected:.3},xLabelPadding:10,yLabelPadding:8,yTicksNumber:4,minRange:10,xAxisRectHeight:50,dotsRadius:5},qe={nodeWidth:4,minNodePadding:24,opacity:{unfocus:.3,default:.8,selected:1}},Ig={minCellDividerDimension:16},kg={default:{size:24}},Pg={defaultOffset:4,horizontalOffset:10},Ng={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}},Se={height:{[Ye.GRAPH_VIEW]:32,[Ye.SLIDER_VIEW]:10},spacerHeight:8,handleWidth:5,handleBarWidth:1,handleBarHeight:12},hL=[{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 dL(e,t,n){let i=null;return function(...r){const s=this;s.mousePosition=Wn(r[0],n),clearTimeout(i),i=setTimeout(function(){e.apply(s,r)},t)}}function It(e,t){const n=_n(e),i=Object.keys(t.axes||{});t?.toolbar?.controls&&delete n.toolbar.controls,i.length===0&&delete n.axes;for(const r in n.axes)if(i.includes(r)){const s=t.axes[r];(s.primary||s.secondary)&&console.warn("`primary` & `secondary` are no longer needed for axis configurations. Read more here https://charts.carbondesignsystem.com/");const a=s.mapsTo;if(a==null){const o=s.scaleType;o==null?s.mapsTo="value":o===it.TIME?s.mapsTo="date":o===it.LABELS&&(s.mapsTo="key")}}else delete n.axes[r];return jc(n,t),ct(n,t)}function wn(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 i=n[0].replace(/translate\(/,"").replace(/\)/,"").split(",");return{tx:i[0],ty:i[1]}}return null}function ls(e){const n=/\(([^)]+)\)/.exec(e);if(n&&n.length>1){const i=n[1].split(",");if(i.length>1)return{x:parseFloat(i[0]),y:parseFloat(i[1])}}return{x:0,y:0}}function Zc(e,t,n="value",i=!1){const r=e/t.reduce((s,a)=>s+a[n],0)*100;return i?r:r%1!==0?parseFloat(r.toFixed(1)):r}function cs(e,t,n){if(n>e.length)return e;if(t===Re.MID_LINE)return e.substr(0,n/2)+"..."+e.substr(-n/2);if(t===Re.FRONT_LINE)return"..."+e.substr(-n);if(t===Re.END_LINE)return e.substr(0,n)+"..."}function jc(e,t){const n=y(e,"legend","additionalItems"),i=y(t,"legend","additionalItems");if(n&&i){const r=i.map(o=>o.type),s=n.map(o=>o.type),a=hL.filter(o=>s.includes(o.type)&&!r.includes(o.type));e.legend.additionalItems=a,t.legend.additionalItems=cL(a,i,"name")}}const y=(e,...t)=>{let n=e;if(n){for(const i of t)if(n[i]!==null&&n[i]!==void 0)n=n[i];else return null;return n}return null},$g=(e,t)=>t===Ht.HORIZONTAL?{y0:e.x0,y1:e.x1,x0:e.y0,x1:e.y1}:e,se=(e,t)=>{const{x0:n,x1:i,y0:r,y1:s}=$g(e,t);return`M${n},${r}L${n},${s}L${i},${s}L${i},${r}L${n},${r}`};function Mn(e,t,n){return n===Ht.VERTICAL?[e,t]:[t,e]}function Kc(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}function us(e){return(t,n)=>{const i=n?.context?String(n.context):"standalone";let r;if(i==="formatting"&&e.formattingValues){const a=e.defaultFormattingWidth||e.defaultWidth,o=n?.width?String(n.width):a;r=e.formattingValues[o]||e.formattingValues[a]}else{const a=e.defaultWidth,o=n?.width?String(n.width):e.defaultWidth;r=e.values[o]||e.values[a]}const s=e.argumentCallback?e.argumentCallback(t):t;return r[s]}}function hs(e){return(t,n={})=>{const i=n.width,r=i&&e.matchPatterns[i]||e.matchPatterns[e.defaultMatchWidth],s=t.match(r);if(!s)return null;const a=s[0],o=i&&e.parsePatterns[i]||e.parsePatterns[e.defaultParseWidth],l=Array.isArray(o)?pL(o,d=>d.test(a)):fL(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 fL(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function pL(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function gL(e){return(t,n={})=>{const i=t.match(e.matchPattern);if(!i)return null;const r=i[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(r.length);return{value:a,rest:o}}}const Fg=6048e5,mL=864e5,Ug=6e4,Bg=36e5,Hg=Symbol.for("constructDateFrom");function ke(e,t){return typeof e=="function"?e(t):e&&typeof e=="object"&&Hg in e?e[Hg](t):e instanceof Date?new e.constructor(t):new Date(t)}function hi(e,...t){const n=ke.bind(null,t.find(i=>typeof i=="object"));return t.map(n)}let vL={};function Za(){return vL}function $t(e,t){return ke(t||e,e)}function ds(e,t){const n=Za(),i=t?.weekStartsOn??t?.locale?.options?.weekStartsOn??n.weekStartsOn??n.locale?.options?.weekStartsOn??0,r=$t(e,t?.in),s=r.getDay(),a=(s<i?7:0)+s-i;return r.setDate(r.getDate()-a),r.setHours(0,0,0,0),r}const yL={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"}},EL=(e,t,n)=>{let i;const r=yL[e];return typeof r=="string"?i=r:t===1?i=r.one:i=r.other.replace("{{count}}",t.toString()),n?.addSuffix?n.comparison&&n.comparison>0?"in "+i:i+" ago":i},xL={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},bL=(e,t,n,i)=>xL[e],SL={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},_L={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},TL={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"]},OL={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"]},wL={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"}},ML={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"}},CL={ordinalNumber:(e,t)=>{const n=Number(e),i=n%100;if(i>20||i<10)switch(i%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},era:us({values:SL,defaultWidth:"wide"}),quarter:us({values:_L,defaultWidth:"wide",argumentCallback:e=>e-1}),month:us({values:TL,defaultWidth:"wide"}),day:us({values:OL,defaultWidth:"wide"}),dayPeriod:us({values:wL,defaultWidth:"wide",formattingValues:ML,defaultFormattingWidth:"wide"})},AL=/^(\d+)(th|st|nd|rd)?/i,DL=/\d+/i,LL={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},RL={any:[/^b/i,/^(a|c)/i]},IL={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},kL={any:[/1/i,/2/i,/3/i,/4/i]},PL={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},NL={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]},$L={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},FL={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]},UL={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},BL={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}},HL={ordinalNumber:gL({matchPattern:AL,parsePattern:DL,valueCallback:e=>parseInt(e,10)}),era:hs({matchPatterns:LL,defaultMatchWidth:"wide",parsePatterns:RL,defaultParseWidth:"any"}),quarter:hs({matchPatterns:IL,defaultMatchWidth:"wide",parsePatterns:kL,defaultParseWidth:"any",valueCallback:e=>e+1}),month:hs({matchPatterns:PL,defaultMatchWidth:"wide",parsePatterns:NL,defaultParseWidth:"any"}),day:hs({matchPatterns:$L,defaultMatchWidth:"wide",parsePatterns:FL,defaultParseWidth:"any"}),dayPeriod:hs({matchPatterns:UL,defaultMatchWidth:"any",parsePatterns:BL,defaultParseWidth:"any"})},GL={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},VL={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},zL={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},WL={date:Kc({formats:GL,defaultWidth:"full"}),time:Kc({formats:VL,defaultWidth:"full"}),dateTime:Kc({formats:zL,defaultWidth:"full"})},Gg={code:"en-US",formatDistance:EL,formatLong:WL,formatRelative:bL,localize:CL,match:HL,options:{weekStartsOn:0,firstWeekContainsDate:1}},Qi={type:Re.END_LINE,threshold:16,numCharacter:14},Vg=4,YL={code:typeof navigator<"u"&&navigator?.language||"en-US",number:(e,t=navigator?.language||"en-US")=>e?.toLocaleString?.(t),date:(e,t=navigator?.language||"en-US",n={},i=null)=>i||e.toLocaleDateString(t,n),time:(e,t=navigator?.language||"en-US",n={},i=null)=>i||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"}}},qL={enabled:!0,position:qi.BOTTOM,clickable:!0,truncation:Qi,alignment:Gt.LEFT,order:null,additionalItems:[]},XL={x:{enabled:!0,numberOfTicks:15,alignWithAxisTicks:!1},y:{enabled:!0,numberOfTicks:5,alignWithAxisTicks:!1}},ZL={enabled:!0},zg={enabled:!0,showTotal:!0,truncation:Qi,groupLabel:"Group"},Wg={top:{visible:!0,includeZero:!0,truncation:Qi},bottom:{visible:!0,includeZero:!0,truncation:Qi},left:{visible:!0,includeZero:!0,truncation:Qi},right:{visible:!0,includeZero:!0,truncation:Qi}},ja={addSpaceOnEdges:1,showDayName:!1,localeObject:Gg,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 Yg=!1;try{Yg=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:Xc.WHITE,tooltip:zg,legend:qL,locale:YL,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:St.SHOW_AS_DATATABLE},...Yg?[{type:St.MAKE_FULLSCREEN}]:[],{type:St.EXPORT_CSV},{type:St.EXPORT_PNG},{type:St.EXPORT_JPG}]}},qg=ct({},ee,{thematic:{projection:an.geoNaturalEarth1}}),fs=ct({},ee,{axes:Wg,timeScale:ja,grid:XL,ruler:ZL,zoomBar:{zoomRatio:.4,minZoomRatio:.01,top:{enabled:!1,type:Ye.GRAPH_VIEW}}}),di=ct({},fs,{bars:{maxWidth:16,spacingFactor:.25,preserveSpaceForMissingBars:!0},timeScale:ct(ja,{addSpaceOnEdges:1})}),jL=ct({},di,{}),KL=ct({},di,{}),QL=ct({},di,{bars:ct({},di.bars,{dividerSize:1.5})}),JL=ct({},di,{}),Qc=ct({},fs,{points:{radius:4,fillOpacity:.3,filled:!0,enabled:!0}}),tR=Qc,Xg=ct({},Qc,{points:{radius:3,filled:!1,enabled:!0}}),Zg=ct({},Xg,{timeScale:ct(ja,{addSpaceOnEdges:0})}),eR=Zg,nR=ct({},fs,{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"}]}}),iR=ct({},fs,{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"}]}}),rR=ct({},di,{bars:{dividerSize:1.5},timeScale:ct(ja,{addSpaceOnEdges:0})}),sR=ct({},ee,{tooltip:ct({},zg,{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"}}),jg=ct({},ee,{pie:{labels:{formatter:null,enabled:!0},alignment:Gt.LEFT,sortFunction:null,valueMapsTo:"value"}}),aR=ct({},ee,{legend:{enabled:!1},gauge:{type:ci.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}}),oR=ct({},jg,{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}}),Kg=ct({},ee,{legend:{enabled:!1,clickable:!1},meter:{showLabels:!0,proportional:null,statusBar:{percentageIndicator:{enabled:!0}}}}),lR=ct({},Kg,{legend:{enabled:!0}}),cR=ct({},ee,{radar:{axes:{angle:"key",value:"value"},alignment:Gt.LEFT},tooltip:{gridline:{enabled:!0}}}),uR=ct({},di,{comboChartTypes:[]}),hR=ct({tree:{type:Ya.TREE}},ee,{}),dR=ct({},ee,{data:ct(ee.data,{groupMapsTo:"name"})}),fR=ct({},ee,Ki,{data:ct(ee.data,{groupMapsTo:"name"})}),pR=ct({},ee,{alluvial:{data:ct(ee.data,{groupMapsTo:"source"}),nodeAlignment:Gt.CENTER,nodePadding:24,monochrome:!1,nodes:[]}}),gR=ct({},ee,{axes:Wg,heatmap:{divider:{state:Zi.AUTO},colorLegend:{type:"linear"}}}),mR=ct({},qg,{choropleth:{colorLegend:{type:"linear"}}}),At={alluvialChart:pR,areaChart:Zg,axisChart:fs,boxplotChart:JL,bubbleChart:nR,bulletChart:iR,chart:ee,circlePackChart:fR,choroplethChart:mR,comboChart:uR,donutChart:oR,gaugeChart:aR,groupedBarChart:KL,heatmapChart:gR,histogramChart:rR,lineChart:Xg,lollipopChart:tR,meterChart:Kg,pieChart:jg,proportionalMeterChart:lR,radarChart:cR,scatterChart:Qc,simpleBarChart:jL,stackedAreaChart:eR,stackedBarChart:QL,thematicChart:qg,treeChart:hR,treemapChart:dR,wordCloudChart:sR};function Qg(e){const t=$t(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 Jg(e,t){const n=$t(e,t?.in);return n.setHours(0,0,0,0),n}function tm(e,t,n){const[i,r]=hi(n?.in,e,t),s=Jg(i),a=Jg(r),o=+s-Qg(s),l=+a-Qg(a);return Math.round((o-l)/mL)}function vR(e,t){const n=$t(e,t?.in);return n.setFullYear(n.getFullYear(),0,1),n.setHours(0,0,0,0),n}function yR(e,t){const n=$t(e,t?.in);return tm(n,vR(n))+1}function Ka(e,t){return ds(e,{...t,weekStartsOn:1})}function em(e,t){const n=$t(e,t?.in),i=n.getFullYear(),r=ke(n,0);r.setFullYear(i+1,0,4),r.setHours(0,0,0,0);const s=Ka(r),a=ke(n,0);a.setFullYear(i,0,4),a.setHours(0,0,0,0);const o=Ka(a);return n.getTime()>=s.getTime()?i+1:n.getTime()>=o.getTime()?i:i-1}function ER(e,t){const n=em(e,t),i=ke(e,0);return i.setFullYear(n,0,4),i.setHours(0,0,0,0),Ka(i)}function xR(e,t){const n=$t(e,t?.in),i=+Ka(n)-+ER(n);return Math.round(i/Fg)+1}function nm(e,t){const n=$t(e,t?.in),i=n.getFullYear(),r=Za(),s=t?.firstWeekContainsDate??t?.locale?.options?.firstWeekContainsDate??r.firstWeekContainsDate??r.locale?.options?.firstWeekContainsDate??1,a=ke(t?.in||e,0);a.setFullYear(i+1,0,s),a.setHours(0,0,0,0);const o=ds(a,t),l=ke(t?.in||e,0);l.setFullYear(i,0,s),l.setHours(0,0,0,0);const c=ds(l,t);return+n>=+o?i+1:+n>=+c?i:i-1}function bR(e,t){const n=Za(),i=t?.firstWeekContainsDate??t?.locale?.options?.firstWeekContainsDate??n.firstWeekContainsDate??n.locale?.options?.firstWeekContainsDate??1,r=nm(e,t),s=ke(t?.in||e,0);return s.setFullYear(r,0,i),s.setHours(0,0,0,0),ds(s,t)}function SR(e,t){const n=$t(e,t?.in),i=+ds(n,t)-+bR(n,t);return Math.round(i/Fg)+1}function wt(e,t){const n=e<0?"-":"",i=Math.abs(e).toString().padStart(t,"0");return n+i}const Un={y(e,t){const n=e.getFullYear(),i=n>0?n:1-n;return wt(t==="yy"?i%100:i,t.length)},M(e,t){const n=e.getMonth();return t==="M"?String(n+1):wt(n+1,2)},d(e,t){return wt(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 wt(e.getHours()%12||12,t.length)},H(e,t){return wt(e.getHours(),t.length)},m(e,t){return wt(e.getMinutes(),t.length)},s(e,t){return wt(e.getSeconds(),t.length)},S(e,t){const n=t.length,i=e.getMilliseconds(),r=Math.trunc(i*Math.pow(10,n-3));return wt(r,t.length)}},Ji={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},im={G:function(e,t,n){const i=e.getFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return n.era(i,{width:"abbreviated"});case"GGGGG":return n.era(i,{width:"narrow"});case"GGGG":default:return n.era(i,{width:"wide"})}},y:function(e,t,n){if(t==="yo"){const i=e.getFullYear(),r=i>0?i:1-i;return n.ordinalNumber(r,{unit:"year"})}return Un.y(e,t)},Y:function(e,t,n,i){const r=nm(e,i),s=r>0?r:1-r;if(t==="YY"){const a=s%100;return wt(a,2)}return t==="Yo"?n.ordinalNumber(s,{unit:"year"}):wt(s,t.length)},R:function(e,t){const n=em(e);return wt(n,t.length)},u:function(e,t){const n=e.getFullYear();return wt(n,t.length)},Q:function(e,t,n){const i=Math.ceil((e.getMonth()+1)/3);switch(t){case"Q":return String(i);case"QQ":return wt(i,2);case"Qo":return n.ordinalNumber(i,{unit:"quarter"});case"QQQ":return n.quarter(i,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(i,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(i,{width:"wide",context:"formatting"})}},q:function(e,t,n){const i=Math.ceil((e.getMonth()+1)/3);switch(t){case"q":return String(i);case"qq":return wt(i,2);case"qo":return n.ordinalNumber(i,{unit:"quarter"});case"qqq":return n.quarter(i,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(i,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(i,{width:"wide",context:"standalone"})}},M:function(e,t,n){const i=e.getMonth();switch(t){case"M":case"MM":return Un.M(e,t);case"Mo":return n.ordinalNumber(i+1,{unit:"month"});case"MMM":return n.month(i,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(i,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(i,{width:"wide",context:"formatting"})}},L:function(e,t,n){const i=e.getMonth();switch(t){case"L":return String(i+1);case"LL":return wt(i+1,2);case"Lo":return n.ordinalNumber(i+1,{unit:"month"});case"LLL":return n.month(i,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(i,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(i,{width:"wide",context:"standalone"})}},w:function(e,t,n,i){const r=SR(e,i);return t==="wo"?n.ordinalNumber(r,{unit:"week"}):wt(r,t.length)},I:function(e,t,n){const i=xR(e);return t==="Io"?n.ordinalNumber(i,{unit:"week"}):wt(i,t.length)},d:function(e,t,n){return t==="do"?n.ordinalNumber(e.getDate(),{unit:"date"}):Un.d(e,t)},D:function(e,t,n){const i=yR(e);return t==="Do"?n.ordinalNumber(i,{unit:"dayOfYear"}):wt(i,t.length)},E:function(e,t,n){const i=e.getDay();switch(t){case"E":case"EE":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"})}},e:function(e,t,n,i){const r=e.getDay(),s=(r-i.weekStartsOn+8)%7||7;switch(t){case"e":return String(s);case"ee":return wt(s,2);case"eo":return n.ordinalNumber(s,{unit:"day"});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"})}},c:function(e,t,n,i){const r=e.getDay(),s=(r-i.weekStartsOn+8)%7||7;switch(t){case"c":return String(s);case"cc":return wt(s,t.length);case"co":return n.ordinalNumber(s,{unit:"day"});case"ccc":return n.day(r,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(r,{width:"narrow",context:"standalone"});case"cccccc":return n.day(r,{width:"short",context:"standalone"});case"cccc":default:return n.day(r,{width:"wide",context:"standalone"})}},i:function(e,t,n){const i=e.getDay(),r=i===0?7:i;switch(t){case"i":return String(r);case"ii":return wt(r,t.length);case"io":return n.ordinalNumber(r,{unit:"day"});case"iii":return n.day(i,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(i,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(i,{width:"short",context:"formatting"});case"iiii":default:return n.day(i,{width:"wide",context:"formatting"})}},a:function(e,t,n){const r=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(r,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},b:function(e,t,n){const i=e.getHours();let r;switch(i===12?r=Ji.noon:i===0?r=Ji.midnight:r=i/12>=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(r,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},B:function(e,t,n){const i=e.getHours();let r;switch(i>=17?r=Ji.evening:i>=12?r=Ji.afternoon:i>=4?r=Ji.morning:r=Ji.night,t){case"B":case"BB":case"BBB":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(r,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},h:function(e,t,n){if(t==="ho"){let i=e.getHours()%12;return i===0&&(i=12),n.ordinalNumber(i,{unit:"hour"})}return Un.h(e,t)},H:function(e,t,n){return t==="Ho"?n.ordinalNumber(e.getHours(),{unit:"hour"}):Un.H(e,t)},K:function(e,t,n){const i=e.getHours()%12;return t==="Ko"?n.ordinalNumber(i,{unit:"hour"}):wt(i,t.length)},k:function(e,t,n){let i=e.getHours();return i===0&&(i=24),t==="ko"?n.ordinalNumber(i,{unit:"hour"}):wt(i,t.length)},m:function(e,t,n){return t==="mo"?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):Un.m(e,t)},s:function(e,t,n){return t==="so"?n.ordinalNumber(e.getSeconds(),{unit:"second"}):Un.s(e,t)},S:function(e,t){return Un.S(e,t)},X:function(e,t,n){const i=e.getTimezoneOffset();if(i===0)return"Z";switch(t){case"X":return sm(i);case"XXXX":case"XX":return fi(i);case"XXXXX":case"XXX":default:return fi(i,":")}},x:function(e,t,n){const i=e.getTimezoneOffset();switch(t){case"x":return sm(i);case"xxxx":case"xx":return fi(i);case"xxxxx":case"xxx":default:return fi(i,":")}},O:function(e,t,n){const i=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+rm(i,":");case"OOOO":default:return"GMT"+fi(i,":")}},z:function(e,t,n){const i=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+rm(i,":");case"zzzz":default:return"GMT"+fi(i,":")}},t:function(e,t,n){const i=Math.trunc(+e/1e3);return wt(i,t.length)},T:function(e,t,n){return wt(+e,t.length)}};function rm(e,t=""){const n=e>0?"-":"+",i=Math.abs(e),r=Math.trunc(i/60),s=i%60;return s===0?n+String(r):n+String(r)+t+wt(s,2)}function sm(e,t){return e%60===0?(e>0?"-":"+")+wt(Math.abs(e)/60,2):fi(e,t)}function fi(e,t=""){const n=e>0?"-":"+",i=Math.abs(e),r=wt(Math.trunc(i/60),2),s=wt(i%60,2);return n+r+t+s}const am=(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"})}},om=(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"})}},_R={p:om,P:(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],i=n[1],r=n[2];if(!r)return am(e,t);let s;switch(i){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}}",am(i,t)).replace("{{time}}",om(r,t))}},TR=/^D+$/,OR=/^Y+$/,wR=["D","DD","YY","YYYY"];function MR(e){return TR.test(e)}function CR(e){return OR.test(e)}function AR(e,t,n){const i=DR(e,t,n);if(console.warn(i),wR.includes(e))throw new RangeError(i)}function DR(e,t,n){const i=e[0]==="Y"?"years":"days of the month";return`Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${t}\`) for formatting ${i} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}function LR(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function RR(e){return!(!LR(e)&&typeof e!="number"||isNaN(+$t(e)))}const IR=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,kR=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,PR=/^'([^]*?)'?$/,NR=/''/g,$R=/[a-zA-Z]/;function Jc(e,t,n){const i=Za(),r=n?.locale??i.locale??Gg,s=n?.firstWeekContainsDate??n?.locale?.options?.firstWeekContainsDate??i.firstWeekContainsDate??i.locale?.options?.firstWeekContainsDate??1,a=n?.weekStartsOn??n?.locale?.options?.weekStartsOn??i.weekStartsOn??i.locale?.options?.weekStartsOn??0,o=$t(e,n?.in);if(!RR(o))throw new RangeError("Invalid time value");let l=t.match(kR).map(u=>{const d=u[0];if(d==="p"||d==="P"){const h=_R[d];return h(u,r.formatLong)}return u}).join("").match(IR).map(u=>{if(u==="''")return{isToken:!1,value:"'"};const d=u[0];if(d==="'")return{isToken:!1,value:FR(u)};if(im[d])return{isToken:!0,value:u};if(d.match($R))throw new RangeError("Format string contains an unescaped latin alphabet character `"+d+"`");return{isToken:!1,value:u}});r.localize.preprocessor&&(l=r.localize.preprocessor(o,l));const c={firstWeekContainsDate:s,weekStartsOn:a,locale:r};return l.map(u=>{if(!u.isToken)return u.value;const d=u.value;(!n?.useAdditionalWeekYearTokens&&CR(d)||!n?.useAdditionalDayOfYearTokens&&MR(d))&&AR(d,t,String(e));const h=im[d[0]];return h(o,d,r.localize,c)}).join("")}function FR(e){const t=e.match(PR);return t?t[1].replace(NR,"'"):e}var lm=(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))(lm||{});const tu=[["15seconds",15*1e3],["minute",60*1e3],["30minutes",1800*1e3],["hourly",3600*1e3],["daily",1440*60*1e3],["monthly",720*60*60*1e3],["quarterly",2160*60*60*1e3],["yearly",360*24*60*60*1e3]];function cm(e,t,n,i,r){const s=t===0,a=Number(Jc(new Date(e),"c"))===2,o=Number(Jc(new Date(e),"q"))===1,l=t!==0?n[t-1]:null;switch(i){case"15seconds":return s||Ja(e)||ps(e,l)||Bn(e);case"minute":return s||Ja(e)||ps(e,l)||Bn(e);case"30minutes":return s||Ja(e)||ps(e,l)||Bn(e);case"hourly":return s||Ja(e)||ps(e,l)||Bn(e);case"daily":return r?s||a||Bn(e):s||ps(e,l)||Bn(e);case"weekly":return s||a||Bn(e);case"monthly":return s||Bn(e);case"quarterly":return s||o;case"yearly":return!1;default:throw new Error(`${i} is not a valid time interval.`)}}function eu(e,t,n,i,r,s){const a=r.showDayName,o=i==="daily"&&a?"weekly":i,l=new Date(e),c=y(r,"timeIntervalFormats")[o],u=y(c,"primary"),d=y(c,"secondary"),h=cm(e,t,n,i,a);let f=h?u:d;i==="15seconds"&&l.getMilliseconds()!==0&&(f=f.replace("pp","h:mm:ss.SSS a"));const p=r.localeObject,{code:g,optionsObject:m}=s,v=m[i].type,S=m[i][h?"primary":"secondary"][f];if(i==="quarterly"||!S){const b=Jc(l,f,{locale:p}).split("").map(x=>{const _=Number(x);return x!==" "&&!Number.isNaN(_)?_?.toLocaleString?.(g):x});return s[v](l,g,{},b.join(""))}else return s[v](l,g,S)}function Qa(e){const t=new Date(e);return{M:t.getMonth()+1,d:t.getDate(),H:t.getHours(),m:t.getMinutes(),s:t.getSeconds()}}function UR(e){if(e)return e.slice(1).map((t,n)=>t-e[n])}function BR(e){const t=tu.reduce((n,[,i],r)=>{const s=tu[n][1],a=Math.abs(s-e),o=Math.abs(i-e);return a<o?n:r},0);return tu[t][0]}function nu(e,t){if(lm[t])return t;if(e.length===1)return"15seconds";const n=UR(e),i=Pn(n);return BR(i)}function Ja(e){const{s:t,m:n,H:i}=Qa(e);return i===0&&n===0&&t===0}function ps(e,t){const n=Qa(e).M,i=Qa(t).M;return n!==i}function Bn(e){const{M:t,d:n,s:i,m:r,H:s}=Qa(e);return t===1&&n===1&&s===0&&r===0&&i===0}function um(e){return e===void 0?"":e.toISOString()}function HR(e){const t=e.trim();return["=","+","-","@"," ","\r"].includes(t.charAt(0))?` ${t}`:/[,\"\n]/.test(t)?`"${t}"`:t}class on{constructor(t){this.state={options:{}},this.colorScale={},this.colorClassNames={},this.services=t}formatTable({headers:t,cells:n}){const i=this.getOptions(),{code:r,date:s,number:a}=y(i,"locale"),o=y(i,"tabularRepModal","tableHeadingFormatter"),l=y(i,"tabularRepModal","tableCellFormatter"),{cartesianScales:c}=this.services,u=c?.getDomainAxisScaleType();let d;return u===it.TIME&&(d=f=>s(f,r,{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,r))}return f})]}getAllDataFromDomain(t){if(!this.getData())return null;const n=this.getOptions();let i=this.getData();const r=this.getDataGroups(),{groupMapsTo:s}=y(n,"data"),a=y(n,"axes");return t&&(i=i.filter(o=>t.includes(o[s]))),a&&Object.keys(a).forEach(o=>{const l=a[o].mapsTo,c=a[o].scaleType;if((c===it.LINEAR||c===it.LOG)&&(i=i.map(u=>({...u,[l]:u[l]===null?u[l]:Number(u[l])}))),l&&a[o].domain)if(c===it.LABELS)i=i.filter(u=>a[o].domain.includes(u[l]));else{const[u,d]=a[o].domain;i=i.filter(h=>!(l in h)||h[l]>=u&&h[l]<=d)}}),i.filter(o=>r.find(l=>l.name===o[s]))}getDisplayData(t){if(!this.get("data"))return null;const{ACTIVE:n}=Pt.items.status,i=this.getDataGroups(t),{groupMapsTo:r}=this.getOptions().data;return this.getAllDataFromDomain(t).filter(a=>i.find(o=>o.name===a[r]&&o.status===n))}getData(){return this.get("data")}isDataEmpty(){return!this.getData().length}setData(t){const n=this.sanitize(_n(t)),i=this.generateDataGroups(n);return this.set({data:n,dataGroups:i}),n}getDataGroups(t){return y(this.getOptions(),"data","loading")?[]:t?this.get("dataGroups").filter(i=>t.includes(i.name)):this.get("dataGroups")}getActiveDataGroups(t){const{ACTIVE:n}=Pt.items.status;return this.getDataGroups(t).filter(i=>i.status===n)}getDataGroupNames(t){return this.getDataGroups(t).map(i=>i.name)}getActiveDataGroupNames(t){return this.getActiveDataGroups(t).map(i=>i.name)}aggregateBinDataByGroup(t){return YD(t,"group")}getBinConfigurations(){const t=this.getDisplayData(),n=this.getOptions(),i=this.services.cartesianScales.getMainXAxisPosition(),r=this.services.cartesianScales.getDomainIdentifier(),s=n.axes[i],{groupMapsTo:a}=n.data,{bins:o=uL.defaultBins}=s,l=Array.isArray(o),c=h0().value(f=>f[r]).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,i=this.getActiveDataGroupNames(),{bins:r}=this.getBinConfigurations(),s=this.getDataValuesGroupedByKeys({bins:r});return Ql().keys(i)(s).map((a,o)=>Object.keys(a).filter(l=>!isNaN(l)).map(l=>{const c=a[l];return c[n]=i[o],c}))}getGroupedData(t){const n=this.getDisplayData(t),i={},{groupMapsTo:r}=this.getOptions().data;return n.map(s=>{const a=s[r];i[a]!==null&&i[a]!==void 0?i[a].push(s):i[a]=[s]}),Object.keys(i).map(s=>({name:s,data:i[s]}))}getStackKeys({bins:t=null,groups:n=null}={bins:null,groups:null}){const i=this.getOptions(),r=this.getDisplayData(n);let s;t?s=t.map(l=>`${l.x0}:${l.x1}`):s=ns(r.map(l=>{const c=this.services.cartesianScales.getDomainIdentifier(l);return l[c]instanceof Date?um(l[c]):l[c]&&typeof l[c].toString=="function"?l[c].toString():l[c]}));const a=this.services.cartesianScales.domainAxisPosition,o=i.axes[a].scaleType;return o===it.TIME?s.sort((l,c)=>{const u=new Date(l),d=new Date(c);return u-d}):(o===it.LOG||o===it.LINEAR)&&s.sort((l,c)=>l-c),s}getDataValuesGroupedByKeys({bins:t=null,groups:n=null}){const i=this.getOptions(),{groupMapsTo:r}=i.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[r]===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[r]===u&&Object.prototype.hasOwnProperty.call(f,p)&&(f[p]instanceof Date?um(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:i=!1}){const r=this.getOptions(),{groupMapsTo:s}=r.data,a=this.getActiveDataGroupNames(n),o=this.getDataValuesGroupedByKeys({groups:n});if(t){const c=VD(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(i?Ql().offset(mT):Ql()).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 i=Object.assign({skipUpdate:!1,animate:!0},n);i.skipUpdate||this.update(i.animate)}get(t){return t?this.state[t]:this.state}setOptions(t){const n=this.getOptions();jc(n,t),this.set({options:ct(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:i}=Pt.items.status,r=this.getDataGroups(),s=r.some(u=>u.status===i),a=r.filter(u=>u.status===n);if(s)if(a.length===1&&a[0].name===t)r.forEach((u,d)=>{r[d].status=n});else{const u=r.findIndex(d=>d.name===t);r[u].status=r[u].status===i?n:i}else r.forEach((u,d)=>{r[d].status=u.name===t?n:i});const o=r.filter(u=>u.status===n),l=this.getOptions();r.some(u=>u.status===i)?l.data.selectedGroups=o.map(u=>u.name):l.data.selectedGroups=[],this.services.events.dispatchEvent(T.Legend.ITEMS_UPDATE,{dataGroups:r}),this.set({dataGroups:r})}getIsFilled(t,n,i,r){const s=this.getOptions();return s.getIsFilled?s.getIsFilled(t,n,i,r):r}getFillColor(t,n,i){const r=this.getOptions(),s=y(this.colorScale,t);return r.getFillColor?r.getFillColor(t,n,i,s):s}getStrokeColor(t,n,i){const r=this.getOptions(),s=y(this.colorScale,t);return r.getStrokeColor?r.getStrokeColor(t,n,i,s):s}isUserProvidedColorScaleValid(){const t=y(this.getOptions(),"color","scale"),n=this.getDataGroups();return t==null||Object.keys(t).length==0?!1:n.some(i=>Object.keys(t).includes(i.name))}getColorClassName(t){const n=this.colorClassNames(t.dataGroupName);let i=t.originalClassName;return t.classNameTypes.forEach(r=>i=t.originalClassName?`${i} ${r}-${n}`:`${r}-${n}`),i||""}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:i,labels:r}=t;return i.forEach(s=>{s.data.forEach((a,o)=>{let l;const c=y(s,"label");if(c===null){const d=y(r,o);d?l=d:l="Ungrouped"}else l=c;const u={group:l,key:r[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==="&ndash;"?"–":o).split(/[,;'"`]/).map(u=>HR(u)).join("")}"`)).map(a=>a.join(",")).join(`
2
2
  `),i=this.getOptions();let r="myChart";const s=y(i,"fileDownload","fileName");typeof s=="function"?r=s("csv"):typeof s=="string"&&(r=s),this.services.files.downloadCSV(n,`${r}.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:i,DISABLED:r}=Pt.items.status,s=this.getOptions(),a=ns(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)?i:r;return a.map(l=>({name:l,status:o(l)}))}setCustomColorScale(){if(!this.isUserProvidedColorScaleValid())return;const t=this.getOptions(),n=y(t,"color","scale");Object.keys(n).forEach(r=>{this.allDataGroups.includes(r)||console.warn(`"${r}" does not exist in data groups.`)}),this.allDataGroups.filter(r=>n[r]).forEach(r=>this.colorScale[r]=n[r])}setColorClassNames(){const t=y(this.getOptions(),"color","pairing");let n=y(t,"numberOfVariants");(!n||n<this.allDataGroups.length)&&(n=this.allDataGroups.length);let i=y(t,"option");const r=Rg.pairingOptions,s=n>5?14:n,a=`${s}-color`;i=i<=r[a]?i:1;const o=this.allDataGroups.map((l,c)=>`${s}-${i}-${c%14+1}`);this.colorClassNames=ma().range(o).domain(this.allDataGroups)}}function GR(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(),i=n.createElement("base"),r=n.createElement("a");return n.head.appendChild(i),n.body.appendChild(r),t&&(i.href=t),r.href=e,r.href}const VR=(()=>{let e=0;const t=()=>`0000${(Math.random()*36**4<<0).toString(36)}`.slice(-4);return()=>(e+=1,`u${t()}${e}`)})();function Cn(e){const t=[];for(let n=0,i=e.length;n<i;n++)t.push(e[n]);return t}function to(e,t){const i=(e.ownerDocument.defaultView||window).getComputedStyle(e).getPropertyValue(t);return i?parseFloat(i.replace("px","")):0}function zR(e){const t=to(e,"border-left-width"),n=to(e,"border-right-width");return e.clientWidth+t+n}function WR(e){const t=to(e,"border-top-width"),n=to(e,"border-bottom-width");return e.clientHeight+t+n}function hm(e,t={}){const n=t.width||zR(e),i=t.height||WR(e);return{width:n,height:i}}function YR(){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 qR(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 eo(e){return new Promise((t,n)=>{const i=new Image;i.decode=()=>t(i),i.onload=()=>t(i),i.onerror=n,i.crossOrigin="anonymous",i.decoding="async",i.src=e})}async function XR(e){return Promise.resolve().then(()=>new XMLSerializer().serializeToString(e)).then(encodeURIComponent).then(t=>`data:image/svg+xml;charset=utf-8,${t}`)}async function ZR(e,t,n){const i="http://www.w3.org/2000/svg",r=document.createElementNS(i,"svg"),s=document.createElementNS(i,"foreignObject");return r.setAttribute("width",`${t}`),r.setAttribute("height",`${n}`),r.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"),r.appendChild(s),s.appendChild(e),XR(r)}const pe=(e,t)=>{if(e instanceof t)return!0;const n=Object.getPrototypeOf(e);return n===null?!1:n.constructor.name===t.name||pe(n,t)};function jR(e){const t=e.getPropertyValue("content");return`${e.cssText} content: '${t.replace(/'|"/g,"")}';`}function KR(e){return Cn(e).map(t=>{const n=e.getPropertyValue(t),i=e.getPropertyPriority(t);return`${t}: ${n}${i?" !important":""};`}).join(" ")}function QR(e,t,n){const i=`.${e}:${t}`,r=n.cssText?jR(n):KR(n);return document.createTextNode(`${i}{${r}}`)}function dm(e,t,n){const i=window.getComputedStyle(e,n),r=i.getPropertyValue("content");if(r===""||r==="none")return;const s=VR();try{t.className=`${t.className} ${s}`}catch{return}const a=document.createElement("style");a.appendChild(QR(s,n,i)),t.appendChild(a)}function JR(e,t){dm(e,t,":before"),dm(e,t,":after")}const fm="application/font-woff",pm="image/jpeg",tI={woff:fm,woff2:fm,ttf:"application/font-truetype",eot:"application/vnd.ms-fontobject",png:"image/png",jpg:pm,jpeg:pm,gif:"image/gif",tiff:"image/tiff",svg:"image/svg+xml",webp:"image/webp"};function eI(e){const t=/\.([^./]*?)$/g.exec(e);return t?t[1]:""}function iu(e){const t=eI(e).toLowerCase();return tI[t]||""}function nI(e){return e.split(/,/)[1]}function ru(e){return e.search(/^(data:)/)!==-1}function iI(e,t){return`data:${t};base64,${e}`}async function gm(e,t,n){const i=await fetch(e,t);if(i.status===404)throw new Error(`Resource "${i.url}" not found`);const r=await i.blob();return new Promise((s,a)=>{const o=new FileReader;o.onerror=a,o.onloadend=()=>{try{s(n({res:i,result:o.result}))}catch(l){a(l)}},o.readAsDataURL(r)})}const su={};function rI(e,t,n){let i=e.replace(/\?.*/,"");return n&&(i=e),/ttf|otf|eot|woff2?/i.test(i)&&(i=i.replace(/.*\//,"")),t?`[${t}]${i}`:i}async function au(e,t,n){const i=rI(e,t,n.includeQueryParams);if(su[i]!=null)return su[i];n.cacheBust&&(e+=(/\?/.test(e)?"&":"?")+new Date().getTime());let r;try{const s=await gm(e,n.fetchRequestInit,({res:a,result:o})=>(t||(t=a.headers.get("Content-Type")||""),nI(o)));r=iI(s,t)}catch(s){r=n.imagePlaceholder||"";let a=`Failed to fetch resource: ${e}`;s&&(a=typeof s=="string"?s:s.message),a&&console.warn(a)}return su[i]=r,r}async function sI(e){const t=e.toDataURL();return t==="data:,"?e.cloneNode(!1):eo(t)}async function aI(e,t){if(e.currentSrc){const s=document.createElement("canvas"),a=s.getContext("2d");s.width=e.clientWidth,s.height=e.clientHeight,a?.drawImage(e,0,0,s.width,s.height);const o=s.toDataURL();return eo(o)}const n=e.poster,i=iu(n),r=await au(n,i,t);return eo(r)}async function oI(e){var t;try{if(!((t=e?.contentDocument)===null||t===void 0)&&t.body)return await no(e.contentDocument.body,{},!0)}catch{}return e.cloneNode(!1)}async function lI(e,t){return pe(e,HTMLCanvasElement)?sI(e):pe(e,HTMLVideoElement)?aI(e,t):pe(e,HTMLIFrameElement)?oI(e):e.cloneNode(!1)}const cI=e=>e.tagName!=null&&e.tagName.toUpperCase()==="SLOT";async function uI(e,t,n){var i,r;let s=[];return cI(e)&&e.assignedNodes?s=Cn(e.assignedNodes()):pe(e,HTMLIFrameElement)&&(!((i=e.contentDocument)===null||i===void 0)&&i.body)?s=Cn(e.contentDocument.body.childNodes):s=Cn(((r=e.shadowRoot)!==null&&r!==void 0?r:e).childNodes),s.length===0||pe(e,HTMLVideoElement)||await s.reduce((a,o)=>a.then(()=>no(o,n)).then(l=>{l&&t.appendChild(l)}),Promise.resolve()),t}function hI(e,t){const n=t.style;if(!n)return;const i=window.getComputedStyle(e);i.cssText?(n.cssText=i.cssText,n.transformOrigin=i.transformOrigin):Cn(i).forEach(r=>{let s=i.getPropertyValue(r);r==="font-size"&&s.endsWith("px")&&(s=`${Math.floor(parseFloat(s.substring(0,s.length-2)))-.1}px`),pe(e,HTMLIFrameElement)&&r==="display"&&s==="inline"&&(s="block"),r==="d"&&t.getAttribute("d")&&(s=`path(${t.getAttribute("d")})`),n.setProperty(r,s,i.getPropertyPriority(r))})}function dI(e,t){pe(e,HTMLTextAreaElement)&&(t.innerHTML=e.value),pe(e,HTMLInputElement)&&t.setAttribute("value",e.value)}function fI(e,t){if(pe(e,HTMLSelectElement)){const n=t,i=Array.from(n.children).find(r=>e.value===r.getAttribute("value"));i&&i.setAttribute("selected","")}}function pI(e,t){return pe(t,Element)&&(hI(e,t),JR(e,t),dI(e,t),fI(e,t)),t}async function gI(e,t){const n=e.querySelectorAll?e.querySelectorAll("use"):[];if(n.length===0)return e;const i={};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&&!i[o]&&(i[o]=await no(c,t,!0))}}const r=Object.values(i);if(r.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<r.length;l++)o.appendChild(r[l]);e.appendChild(a)}return e}async function no(e,t,n){return!n&&t.filter&&!t.filter(e)?null:Promise.resolve(e).then(i=>lI(i,t)).then(i=>uI(e,i,t)).then(i=>pI(e,i)).then(i=>gI(i,t))}const mm=/url\((['"]?)([^'"]+?)\1\)/g,mI=/url\([^)]+\)\s*format\((["']?)([^"']+)\1\)/g,vI=/src:\s*(?:url\([^)]+\)\s*format\([^)]+\)[,;]\s*)+/g;function yI(e){const t=e.replace(/([.*+?^${}()|\[\]\/\\])/g,"\\$1");return new RegExp(`(url\\(['"]?)(${t})(['"]?\\))`,"g")}function EI(e){const t=[];return e.replace(mm,(n,i,r)=>(t.push(r),n)),t.filter(n=>!ru(n))}async function xI(e,t,n,i,r){try{const s=n?GR(t,n):t,a=iu(t);let o;return r||(o=await au(s,a,i)),e.replace(yI(t),`$1${o}$3`)}catch{}return e}function bI(e,{preferredFontFormat:t}){return t?e.replace(vI,n=>{for(;;){const[i,,r]=mI.exec(n)||[];if(!r)return"";if(r===t)return`src: ${i};`}}):e}function vm(e){return e.search(mm)!==-1}async function ym(e,t,n){if(!vm(e))return e;const i=bI(e,n);return EI(i).reduce((s,a)=>s.then(o=>xI(o,a,t,n)),Promise.resolve(i))}async function io(e,t,n){var i;const r=(i=t.style)===null||i===void 0?void 0:i.getPropertyValue(e);if(r){const s=await ym(r,null,n);return t.style.setProperty(e,s,t.style.getPropertyPriority(e)),!0}return!1}async function SI(e,t){await io("background",e,t)||await io("background-image",e,t),await io("mask",e,t)||await io("mask-image",e,t)}async function _I(e,t){const n=pe(e,HTMLImageElement);if(!(n&&!ru(e.src))&&!(pe(e,SVGImageElement)&&!ru(e.href.baseVal)))return;const i=n?e.src:e.href.baseVal,r=await au(i,iu(i),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=r):e.href.baseVal=r})}async function TI(e,t){const i=Cn(e.childNodes).map(r=>Em(r,t));await Promise.all(i).then(()=>e)}async function Em(e,t){pe(e,Element)&&(await SI(e,t),await _I(e,t),await TI(e,t))}function OI(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 i=t.style;return i!=null&&Object.keys(i).forEach(r=>{n[r]=i[r]}),e}const xm={};async function bm(e){let t=xm[e];if(t!=null)return t;const i=await(await fetch(e)).text();return t={url:e,cssText:i},xm[e]=t,t}async function Sm(e,t){let n=e.cssText;const i=/url\(["']?([^"')]+)["']?\)/g,s=(n.match(/url\([^)]+\)/g)||[]).map(async a=>{let o=a.replace(i,"$1");return o.startsWith("https://")||(o=new URL(o,e.url).href),gm(o,t.fetchRequestInit,({result:l})=>(n=n.replace(a,`url(${l})`),[a,l]))});return Promise.all(s).then(()=>n)}function _m(e){if(e==null)return[];const t=[],n=/(\/\*[\s\S]*?\*\/)/gi;let i=e.replace(n,"");const r=new RegExp("((@.*?keyframes [\\s\\S]*?){([\\s\\S]*?}\\s*?)})","gi");for(;;){const l=r.exec(i);if(l===null)break;t.push(l[0])}i=i.replace(r,"");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(i);if(l===null){if(l=o.exec(i),l===null)break;s.lastIndex=o.lastIndex}else o.lastIndex=s.lastIndex;t.push(l[0])}return t}async function wI(e,t){const n=[],i=[];return e.forEach(r=>{if("cssRules"in r)try{Cn(r.cssRules||[]).forEach((s,a)=>{if(s.type===CSSRule.IMPORT_RULE){let o=a+1;const l=s.href,c=bm(l).then(u=>Sm(u,t)).then(u=>_m(u).forEach(d=>{try{r.insertRule(d,d.startsWith("@import")?o+=1:r.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())});i.push(c)}})}catch(s){const a=e.find(o=>o.href==null)||document.styleSheets[0];r.href!=null&&i.push(bm(r.href).then(o=>Sm(o,t)).then(o=>_m(o).forEach(l=>{a.insertRule(l,r.cssRules.length)})).catch(o=>{console.error("Error loading remote stylesheet",o)})),console.error("Error inlining remote css file",s)}}),Promise.all(i).then(()=>(e.forEach(r=>{if("cssRules"in r)try{Cn(r.cssRules||[]).forEach(s=>{n.push(s)})}catch(s){console.error(`Error while reading CSS rules from ${r.href}`,s)}}),n))}function MI(e){return e.filter(t=>t.type===CSSRule.FONT_FACE_RULE).filter(t=>vm(t.style.getPropertyValue("src")))}async function CI(e,t){if(e.ownerDocument==null)throw new Error("Provided element is not within a Document");const n=Cn(e.ownerDocument.styleSheets),i=await wI(n,t);return MI(i)}async function AI(e,t){const n=await CI(e,t);return(await Promise.all(n.map(r=>{const s=r.parentStyleSheet?r.parentStyleSheet.href:null;return ym(r.cssText,s,t)}))).join(`
3
- `)}async function DI(e,t){const n=t.fontEmbedCSS!=null?t.fontEmbedCSS:t.skipFonts?null:await AI(e,t);if(n){const i=document.createElement("style"),r=document.createTextNode(n);i.appendChild(r),e.firstChild?e.insertBefore(i,e.firstChild):e.appendChild(i)}}async function LI(e,t={}){const{width:n,height:i}=hm(e,t),r=await no(e,t,!0);return await DI(r,t),await Em(r,t),OI(r,t),await ZR(r,n,i)}async function Tm(e,t={}){const{width:n,height:i}=hm(e,t),r=await LI(e,t),s=await eo(r),a=document.createElement("canvas"),o=a.getContext("2d"),l=t.pixelRatio||YR(),c=t.canvasWidth||n,u=t.canvasHeight||i;return a.width=c*l,a.height=u*l,t.skipAutoScale||qR(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 RI(e,t={}){return(await Tm(e,t)).toDataURL()}async function II(e,t={}){return(await Tm(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 kI="DONT_STYLE_ME_css_styles_verifier";class k 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=I(t));const i={width:0,height:0},r=h=>{h&&Object.keys(i).forEach(f=>{if(h[f]){const p=h[f],g=parseFloat(p);p&&g>i[f]&&(""+p).indexOf("%")===-1&&(i[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?.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&&(r(s),i.width>0&&i.height>0))return i;if(n.useClientDimensions&&(r(d),i.width>0&&i.height>0))return d;if(n.useBBox&&(r(l),i.width>0&&i.height>0))return l;if(n.useBoundingRect&&(r(u),i.width>0&&i.height>0))return u}try{const h={width:y(t.node(),"width","baseVal","value"),height:y(t.node(),"height","baseVal","value")};r(h)}catch{r(d),r(l),r(s)}return i}static appendOrSelect(t,n){const i=t.select(`${n}`);if(i.empty()){let r=n.split("#"),s,a;return r.length===2?(s=r[0],r=r[1].split("."),a=r[0]):(r=n.split("."),s=r[0]),t.append(s).attr("id",a).attr("class",r.slice(1).join(" "))}return i}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 i={left:0,top:0},r=t.getBoundingClientRect(),s=n?{left:0,top:0}:this.getHolder().getBoundingClientRect();try{i.left=r.left-s.left,i.top=r.top-s.top}catch(a){console.error(a)}return i}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=y(t,"style","prefix"),i=I(this.getHolder()).append("div").classed(`${fe}--${n}--chart-wrapper`,!0).attr("id",`chart-${this.getChartID()}`).style("height","100%").style("width","100%");i.append("g").attr("class",kI),this.mainContainer=i.node()}update(){this.styleHolderElement()}styleHolderElement(){const t=this.getHolder(),{width:n,height:i,theme:r}=this.model.getOptions();n!==this.width&&(t.style.width=n,this.width=n),i!==this.height&&(t.style.height=i,this.height=i),I(this.getHolder()).classed(`${fe}--chart-holder`,!0).attr("data-carbon-theme",r)}getHolder(){return this.model.get("holder")}exportToJPG(){const t=this,n=this.model.getOptions(),i=this.getHolder(),r=I(i);r.classed("filled",!0),II(this.getMainContainer(),{quality:1,filter:s=>!(s.classList&&s.classList.contains("cds--cc--toolbar"))}).then(function(s){let a="myChart";const o=y(n,"fileDownload","fileName");typeof o=="function"?a=o("jpg"):typeof o=="string"&&(a=o),t.services.files?.downloadImage(s,`${a}.jpg`),r.classed("filled",!1)})}exportToPNG(){const t=this,n=this.model.getOptions(),i=this.getHolder(),r=I(i);r.classed("filled",!0),RI(this.getMainContainer(),{quality:1,filter:s=>!(s.classList&&s.classList.contains("cds--cc--toolbar"))}).then(function(s){let a="myChart";const o=y(n,"fileDownload","fileName");typeof o=="function"?a=o("png"):typeof o=="string"&&(a=o),t.services.files?.downloadImage(s,`${a}.png`),r.classed("filled",!1)}).catch(function(s){console.error("oops, something went wrong!",s)})}isFullScreenMode(){return I(this.getHolder()).classed("fullscreen")}toggleFullscreen(){const t=this.getHolder();I(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=I(this.getHolder()),n=t.classed("fullscreen");t.classed("fullscreen",!n)})}setSVGMaxHeight(){if(!this.model.getOptions().height){const{height:t}=k.getSVGElementSize(I(this.mainContainer),{useBBox:!0}),n=I(this.mainContainer).attr("class"),i=I(this.mainContainer).selectAll(`.${n} > svg`);let r=0;i.nodes().forEach(function(s){r+=Number(k.getSVGElementSize(I(s),{useBBox:!0}).height)}),r<=t?I(this.mainContainer).attr("height",r):I(this.mainContainer).attr("height","100%")}}getMainContainer(){return this.mainContainer}addHolderListeners(){const t=this.getHolder();t&&I(t).on("mouseover",()=>{this.services.events?.dispatchEvent(T.Chart.MOUSEOVER)}).on("mouseout",()=>{this.services.events?.dispatchEvent(T.Chart.MOUSEOUT)})}addResizeListener(){const t=this.getHolder();if(!t)return;let n=t.clientWidth,i=t.clientHeight;const r=Wa(()=>{t&&(Math.abs(n-t.clientWidth)>1||Math.abs(i-t.clientHeight)>1)&&(n=t.clientWidth,i=t.clientHeight,this.services.events?.dispatchEvent(T.Chart.RESIZE))},12.5);new ResizeObserver(r).observe(t)}}class mt{constructor(t,n,i){if(this.type="",this.renderType=at.HTML,this.id="",this.parent=void 0,this.configs={},this.model=t,this.services=n,i&&(this.configs=i,this.configs.id)){const r=y(this.model.getOptions(),"style","prefix");this.id=`${r}--${this.configs.id}`}this.parent||this.setParent(I(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){const n=this.parent;if(this.parent=t,!(n&&n.node()===t.node())&&this.type){const i=y(this.model.getOptions(),"style","prefix");this.parent?.classed(`${fe}--${i}--${this.type}`,!0),n&&n.classed(`${fe}--${i}--${this.type}`,!1)}}getParent(){return this.parent}getComponentContainer(t={ariaLabel:null,isPresentational:!1,withinChartClip:!1}){if(this.type){const n=y(this.model.getOptions(),"style","prefix"),i=this.id?`#${this.id}`:"",r=k.appendOrSelect(this.parent,`${this.renderType===at.SVG?"svg":"div"}${i}.${fe}--${n}--${this.type}`);if(t.ariaLabel&&r.attr("aria-label",t.ariaLabel),t.isPresentational&&r.attr("role","presentation"),t.withinChartClip){const s=this.model.get("chartClipId");if(s){const o=I(`#${s}`).select("rect");if(o.size()!==0){const l=parseFloat(o.attr("height")),c=parseFloat(o.attr("width"));!isNaN(l)&&!isNaN(c)&&l>0&&c>0&&r.attr("clip-path",`url(#${s})`)}}}return r.attr("width","100%").attr("height","100%")}return this.parent}getOptions(){return this.configs.options?ct({},this.model.getOptions(),this.configs.options):this.model.getOptions()}}/*! @license DOMPurify 3.2.6 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.2.6/LICENSE */const{entries:Om,setPrototypeOf:wm,isFrozen:PI,getPrototypeOf:NI,getOwnPropertyDescriptor:$I}=Object;let{freeze:ae,seal:Pe,create:Mm}=Object,{apply:ou,construct:lu}=typeof Reflect<"u"&&Reflect;ae||(ae=function(t){return t}),Pe||(Pe=function(t){return t}),ou||(ou=function(t,n,i){return t.apply(n,i)}),lu||(lu=function(t,n){return new t(...n)});const ro=le(Array.prototype.forEach),FI=le(Array.prototype.lastIndexOf),Cm=le(Array.prototype.pop),gs=le(Array.prototype.push),UI=le(Array.prototype.splice),so=le(String.prototype.toLowerCase),cu=le(String.prototype.toString),Am=le(String.prototype.match),ms=le(String.prototype.replace),BI=le(String.prototype.indexOf),HI=le(String.prototype.trim),Xe=le(Object.prototype.hasOwnProperty),oe=le(RegExp.prototype.test),vs=GI(TypeError);function le(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var n=arguments.length,i=new Array(n>1?n-1:0),r=1;r<n;r++)i[r-1]=arguments[r];return ou(e,t,i)}}function GI(e){return function(){for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];return lu(e,n)}}function vt(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:so;wm&&wm(e,null);let i=t.length;for(;i--;){let r=t[i];if(typeof r=="string"){const s=n(r);s!==r&&(PI(t)||(t[i]=s),r=s)}e[r]=!0}return e}function VI(e){for(let t=0;t<e.length;t++)Xe(e,t)||(e[t]=null);return e}function Dn(e){const t=Mm(null);for(const[n,i]of Om(e))Xe(e,n)&&(Array.isArray(i)?t[n]=VI(i):i&&typeof i=="object"&&i.constructor===Object?t[n]=Dn(i):t[n]=i);return t}function ys(e,t){for(;e!==null;){const i=$I(e,t);if(i){if(i.get)return le(i.get);if(typeof i.value=="function")return le(i.value)}e=NI(e)}function n(){return null}return n}const Dm=ae(["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"]),uu=ae(["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"]),hu=ae(["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"]),zI=ae(["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"]),du=ae(["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"]),WI=ae(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Lm=ae(["#text"]),Rm=ae(["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"]),fu=ae(["accent-height","accumulate","additive","alignment-baseline","amplitude","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","exponent","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","intercept","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","slope","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","tablevalues","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"]),Im=ae(["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=ae(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),YI=Pe(/\{\{[\w\W]*|[\w\W]*\}\}/gm),qI=Pe(/<%[\w\W]*|[\w\W]*%>/gm),XI=Pe(/\$\{[\w\W]*/gm),ZI=Pe(/^data-[\-\w.\u00B7-\uFFFF]+$/),jI=Pe(/^aria-[\-\w]+$/),km=Pe(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),KI=Pe(/^(?:\w+script|data):/i),QI=Pe(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),Pm=Pe(/^html$/i),JI=Pe(/^[a-z][.\w]*(-[.\w]+)+$/i);var Nm=Object.freeze({__proto__:null,ARIA_ATTR:jI,ATTR_WHITESPACE:QI,CUSTOM_ELEMENT:JI,DATA_ATTR:ZI,DOCTYPE_NAME:Pm,ERB_EXPR:qI,IS_ALLOWED_URI:km,IS_SCRIPT_OR_DATA:KI,MUSTACHE_EXPR:YI,TMPLIT_EXPR:XI});const Es={element:1,text:3,progressingInstruction:7,comment:8,document:9},tk=function(){return typeof window>"u"?null:window},ek=function(t,n){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let i=null;const r="data-tt-policy-suffix";n&&n.hasAttribute(r)&&(i=n.getAttribute(r));const s="dompurify"+(i?"#"+i:"");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}},$m=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function Fm(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:tk();const t=ot=>Fm(ot);if(t.version="3.2.6",t.removed=[],!e||!e.document||e.document.nodeType!==Es.document||!e.Element)return t.isSupported=!1,t;let{document:n}=e;const i=n,r=i.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=ys(p,"cloneNode"),m=ys(p,"remove"),v=ys(p,"nextSibling"),S=ys(p,"childNodes"),E=ys(p,"parentNode");if(typeof a=="function"){const ot=n.createElement("template");ot.content&&ot.content.ownerDocument&&(n=ot.content.ownerDocument)}let b,x="";const{implementation:_,createNodeIterator:C,createDocumentFragment:A,getElementsByTagName:$}=n,{importNode:P}=i;let w=$m();t.isSupported=typeof Om=="function"&&typeof E=="function"&&_&&_.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:H,ERB_EXPR:N,TMPLIT_EXPR:M,DATA_ATTR:O,ARIA_ATTR:F,IS_SCRIPT_OR_DATA:U,ATTR_WHITESPACE:L,CUSTOM_ELEMENT:B}=Nm;let{IS_ALLOWED_URI:tt}=Nm,X=null;const Y=vt({},[...Dm,...uu,...hu,...du,...Lm]);let Q=null;const ut=vt({},[...Rm,...fu,...Im,...ao]);let et=Object.seal(Mm(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}})),K=null,nt=null,ht=!0,W=!0,j=!1,J=!0,D=!1,G=!0,V=!1,xt=!1,Ut=!1,st=!1,_t=!1,Ne=!1,Oe=!0,_s=!1;const Ts="user-content-";let mi=!0,je=!1,ar={},or=null;const Rv=vt({},["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 Iv=null;const kv=vt({},["audio","video","img","source","image","track"]);let Du=null;const Pv=vt({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),vo="http://www.w3.org/1998/Math/MathML",yo="http://www.w3.org/2000/svg",Rn="http://www.w3.org/1999/xhtml";let lr=Rn,Lu=!1,Ru=null;const q$=vt({},[vo,yo,Rn],cu);let Eo=vt({},["mi","mo","mn","ms","mtext"]),xo=vt({},["annotation-xml"]);const X$=vt({},["title","style","font","a","script"]);let Os=null;const Z$=["application/xhtml+xml","text/html"],j$="text/html";let Xt=null,cr=null;const K$=n.createElement("form"),Nv=function(R){return R instanceof RegExp||R instanceof Function},Iu=function(){let R=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(cr&&cr===R)){if((!R||typeof R!="object")&&(R={}),R=Dn(R),Os=Z$.indexOf(R.PARSER_MEDIA_TYPE)===-1?j$:R.PARSER_MEDIA_TYPE,Xt=Os==="application/xhtml+xml"?cu:so,X=Xe(R,"ALLOWED_TAGS")?vt({},R.ALLOWED_TAGS,Xt):Y,Q=Xe(R,"ALLOWED_ATTR")?vt({},R.ALLOWED_ATTR,Xt):ut,Ru=Xe(R,"ALLOWED_NAMESPACES")?vt({},R.ALLOWED_NAMESPACES,cu):q$,Du=Xe(R,"ADD_URI_SAFE_ATTR")?vt(Dn(Pv),R.ADD_URI_SAFE_ATTR,Xt):Pv,Iv=Xe(R,"ADD_DATA_URI_TAGS")?vt(Dn(kv),R.ADD_DATA_URI_TAGS,Xt):kv,or=Xe(R,"FORBID_CONTENTS")?vt({},R.FORBID_CONTENTS,Xt):Rv,K=Xe(R,"FORBID_TAGS")?vt({},R.FORBID_TAGS,Xt):Dn({}),nt=Xe(R,"FORBID_ATTR")?vt({},R.FORBID_ATTR,Xt):Dn({}),ar=Xe(R,"USE_PROFILES")?R.USE_PROFILES:!1,ht=R.ALLOW_ARIA_ATTR!==!1,W=R.ALLOW_DATA_ATTR!==!1,j=R.ALLOW_UNKNOWN_PROTOCOLS||!1,J=R.ALLOW_SELF_CLOSE_IN_ATTR!==!1,D=R.SAFE_FOR_TEMPLATES||!1,G=R.SAFE_FOR_XML!==!1,V=R.WHOLE_DOCUMENT||!1,st=R.RETURN_DOM||!1,_t=R.RETURN_DOM_FRAGMENT||!1,Ne=R.RETURN_TRUSTED_TYPE||!1,Ut=R.FORCE_BODY||!1,Oe=R.SANITIZE_DOM!==!1,_s=R.SANITIZE_NAMED_PROPS||!1,mi=R.KEEP_CONTENT!==!1,je=R.IN_PLACE||!1,tt=R.ALLOWED_URI_REGEXP||km,lr=R.NAMESPACE||Rn,Eo=R.MATHML_TEXT_INTEGRATION_POINTS||Eo,xo=R.HTML_INTEGRATION_POINTS||xo,et=R.CUSTOM_ELEMENT_HANDLING||{},R.CUSTOM_ELEMENT_HANDLING&&Nv(R.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(et.tagNameCheck=R.CUSTOM_ELEMENT_HANDLING.tagNameCheck),R.CUSTOM_ELEMENT_HANDLING&&Nv(R.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(et.attributeNameCheck=R.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),R.CUSTOM_ELEMENT_HANDLING&&typeof R.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(et.allowCustomizedBuiltInElements=R.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),D&&(W=!1),_t&&(st=!0),ar&&(X=vt({},Lm),Q=[],ar.html===!0&&(vt(X,Dm),vt(Q,Rm)),ar.svg===!0&&(vt(X,uu),vt(Q,fu),vt(Q,ao)),ar.svgFilters===!0&&(vt(X,hu),vt(Q,fu),vt(Q,ao)),ar.mathMl===!0&&(vt(X,du),vt(Q,Im),vt(Q,ao))),R.ADD_TAGS&&(X===Y&&(X=Dn(X)),vt(X,R.ADD_TAGS,Xt)),R.ADD_ATTR&&(Q===ut&&(Q=Dn(Q)),vt(Q,R.ADD_ATTR,Xt)),R.ADD_URI_SAFE_ATTR&&vt(Du,R.ADD_URI_SAFE_ATTR,Xt),R.FORBID_CONTENTS&&(or===Rv&&(or=Dn(or)),vt(or,R.FORBID_CONTENTS,Xt)),mi&&(X["#text"]=!0),V&&vt(X,["html","head","body"]),X.table&&(vt(X,["tbody"]),delete K.tbody),R.TRUSTED_TYPES_POLICY){if(typeof R.TRUSTED_TYPES_POLICY.createHTML!="function")throw vs('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof R.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw vs('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');b=R.TRUSTED_TYPES_POLICY,x=b.createHTML("")}else b===void 0&&(b=ek(f,r)),b!==null&&typeof x=="string"&&(x=b.createHTML(""));ae&&ae(R),cr=R}},$v=vt({},[...uu,...hu,...zI]),Fv=vt({},[...du,...WI]),Q$=function(R){let Z=E(R);(!Z||!Z.tagName)&&(Z={namespaceURI:lr,tagName:"template"});const rt=so(R.tagName),kt=so(Z.tagName);return Ru[R.namespaceURI]?R.namespaceURI===yo?Z.namespaceURI===Rn?rt==="svg":Z.namespaceURI===vo?rt==="svg"&&(kt==="annotation-xml"||Eo[kt]):!!$v[rt]:R.namespaceURI===vo?Z.namespaceURI===Rn?rt==="math":Z.namespaceURI===yo?rt==="math"&&xo[kt]:!!Fv[rt]:R.namespaceURI===Rn?Z.namespaceURI===yo&&!xo[kt]||Z.namespaceURI===vo&&!Eo[kt]?!1:!Fv[rt]&&(X$[rt]||!$v[rt]):!!(Os==="application/xhtml+xml"&&Ru[R.namespaceURI]):!1},un=function(R){gs(t.removed,{element:R});try{E(R).removeChild(R)}catch{m(R)}},ur=function(R,Z){try{gs(t.removed,{attribute:Z.getAttributeNode(R),from:Z})}catch{gs(t.removed,{attribute:null,from:Z})}if(Z.removeAttribute(R),R==="is")if(st||_t)try{un(Z)}catch{}else try{Z.setAttribute(R,"")}catch{}},Uv=function(R){let Z=null,rt=null;if(Ut)R="<remove></remove>"+R;else{const Yt=Am(R,/^[\r\n\t ]+/);rt=Yt&&Yt[0]}Os==="application/xhtml+xml"&&lr===Rn&&(R='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+R+"</body></html>");const kt=b?b.createHTML(R):R;if(lr===Rn)try{Z=new h().parseFromString(kt,Os)}catch{}if(!Z||!Z.documentElement){Z=_.createDocument(lr,"template",null);try{Z.documentElement.innerHTML=Lu?x:kt}catch{}}const ne=Z.body||Z.documentElement;return R&&rt&&ne.insertBefore(n.createTextNode(rt),ne.childNodes[0]||null),lr===Rn?$.call(Z,V?"html":"body")[0]:V?Z.documentElement:ne},Bv=function(R){return C.call(R.ownerDocument||R,R,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT|c.SHOW_PROCESSING_INSTRUCTION|c.SHOW_CDATA_SECTION,null)},ku=function(R){return R instanceof d&&(typeof R.nodeName!="string"||typeof R.textContent!="string"||typeof R.removeChild!="function"||!(R.attributes instanceof u)||typeof R.removeAttribute!="function"||typeof R.setAttribute!="function"||typeof R.namespaceURI!="string"||typeof R.insertBefore!="function"||typeof R.hasChildNodes!="function")},Hv=function(R){return typeof o=="function"&&R instanceof o};function In(ot,R,Z){ro(ot,rt=>{rt.call(t,R,Z,cr)})}const Gv=function(R){let Z=null;if(In(w.beforeSanitizeElements,R,null),ku(R))return un(R),!0;const rt=Xt(R.nodeName);if(In(w.uponSanitizeElement,R,{tagName:rt,allowedTags:X}),G&&R.hasChildNodes()&&!Hv(R.firstElementChild)&&oe(/<[/\w!]/g,R.innerHTML)&&oe(/<[/\w!]/g,R.textContent)||R.nodeType===Es.progressingInstruction||G&&R.nodeType===Es.comment&&oe(/<[/\w]/g,R.data))return un(R),!0;if(!X[rt]||K[rt]){if(!K[rt]&&zv(rt)&&(et.tagNameCheck instanceof RegExp&&oe(et.tagNameCheck,rt)||et.tagNameCheck instanceof Function&&et.tagNameCheck(rt)))return!1;if(mi&&!or[rt]){const kt=E(R)||R.parentNode,ne=S(R)||R.childNodes;if(ne&&kt){const Yt=ne.length;for(let ve=Yt-1;ve>=0;--ve){const kn=g(ne[ve],!0);kn.__removalCount=(R.__removalCount||0)+1,kt.insertBefore(kn,v(R))}}}return un(R),!0}return R instanceof l&&!Q$(R)||(rt==="noscript"||rt==="noembed"||rt==="noframes")&&oe(/<\/no(script|embed|frames)/i,R.innerHTML)?(un(R),!0):(D&&R.nodeType===Es.text&&(Z=R.textContent,ro([H,N,M],kt=>{Z=ms(Z,kt," ")}),R.textContent!==Z&&(gs(t.removed,{element:R.cloneNode()}),R.textContent=Z)),In(w.afterSanitizeElements,R,null),!1)},Vv=function(R,Z,rt){if(Oe&&(Z==="id"||Z==="name")&&(rt in n||rt in K$))return!1;if(!(W&&!nt[Z]&&oe(O,Z))){if(!(ht&&oe(F,Z))){if(!Q[Z]||nt[Z]){if(!(zv(R)&&(et.tagNameCheck instanceof RegExp&&oe(et.tagNameCheck,R)||et.tagNameCheck instanceof Function&&et.tagNameCheck(R))&&(et.attributeNameCheck instanceof RegExp&&oe(et.attributeNameCheck,Z)||et.attributeNameCheck instanceof Function&&et.attributeNameCheck(Z))||Z==="is"&&et.allowCustomizedBuiltInElements&&(et.tagNameCheck instanceof RegExp&&oe(et.tagNameCheck,rt)||et.tagNameCheck instanceof Function&&et.tagNameCheck(rt))))return!1}else if(!Du[Z]){if(!oe(tt,ms(rt,L,""))){if(!((Z==="src"||Z==="xlink:href"||Z==="href")&&R!=="script"&&BI(rt,"data:")===0&&Iv[R])){if(!(j&&!oe(U,ms(rt,L,"")))){if(rt)return!1}}}}}}return!0},zv=function(R){return R!=="annotation-xml"&&Am(R,B)},Wv=function(R){In(w.beforeSanitizeAttributes,R,null);const{attributes:Z}=R;if(!Z||ku(R))return;const rt={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:Q,forceKeepAttr:void 0};let kt=Z.length;for(;kt--;){const ne=Z[kt],{name:Yt,namespaceURI:ve,value:kn}=ne,ws=Xt(Yt),Pu=kn;let ie=Yt==="value"?Pu:HI(Pu);if(rt.attrName=ws,rt.attrValue=ie,rt.keepAttr=!0,rt.forceKeepAttr=void 0,In(w.uponSanitizeAttribute,R,rt),ie=rt.attrValue,_s&&(ws==="id"||ws==="name")&&(ur(Yt,R),ie=Ts+ie),G&&oe(/((--!?|])>)|<\/(style|title)/i,ie)){ur(Yt,R);continue}if(rt.forceKeepAttr)continue;if(!rt.keepAttr){ur(Yt,R);continue}if(!J&&oe(/\/>/i,ie)){ur(Yt,R);continue}D&&ro([H,N,M],qv=>{ie=ms(ie,qv," ")});const Yv=Xt(R.nodeName);if(!Vv(Yv,ws,ie)){ur(Yt,R);continue}if(b&&typeof f=="object"&&typeof f.getAttributeType=="function"&&!ve)switch(f.getAttributeType(Yv,ws)){case"TrustedHTML":{ie=b.createHTML(ie);break}case"TrustedScriptURL":{ie=b.createScriptURL(ie);break}}if(ie!==Pu)try{ve?R.setAttributeNS(ve,Yt,ie):R.setAttribute(Yt,ie),ku(R)?un(R):Cm(t.removed)}catch{ur(Yt,R)}}In(w.afterSanitizeAttributes,R,null)},J$=function ot(R){let Z=null;const rt=Bv(R);for(In(w.beforeSanitizeShadowDOM,R,null);Z=rt.nextNode();)In(w.uponSanitizeShadowNode,Z,null),Gv(Z),Wv(Z),Z.content instanceof s&&ot(Z.content);In(w.afterSanitizeShadowDOM,R,null)};return t.sanitize=function(ot){let R=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Z=null,rt=null,kt=null,ne=null;if(Lu=!ot,Lu&&(ot="<!-->"),typeof ot!="string"&&!Hv(ot))if(typeof ot.toString=="function"){if(ot=ot.toString(),typeof ot!="string")throw vs("dirty is not a string, aborting")}else throw vs("toString is not a function");if(!t.isSupported)return ot;if(xt||Iu(R),t.removed=[],typeof ot=="string"&&(je=!1),je){if(ot.nodeName){const kn=Xt(ot.nodeName);if(!X[kn]||K[kn])throw vs("root node is forbidden and cannot be sanitized in-place")}}else if(ot instanceof o)Z=Uv("<!---->"),rt=Z.ownerDocument.importNode(ot,!0),rt.nodeType===Es.element&&rt.nodeName==="BODY"||rt.nodeName==="HTML"?Z=rt:Z.appendChild(rt);else{if(!st&&!D&&!V&&ot.indexOf("<")===-1)return b&&Ne?b.createHTML(ot):ot;if(Z=Uv(ot),!Z)return st?null:Ne?x:""}Z&&Ut&&un(Z.firstChild);const Yt=Bv(je?ot:Z);for(;kt=Yt.nextNode();)Gv(kt),Wv(kt),kt.content instanceof s&&J$(kt.content);if(je)return ot;if(st){if(_t)for(ne=A.call(Z.ownerDocument);Z.firstChild;)ne.appendChild(Z.firstChild);else ne=Z;return(Q.shadowroot||Q.shadowrootmode)&&(ne=P.call(i,ne,!0)),ne}let ve=V?Z.outerHTML:Z.innerHTML;return V&&X["!doctype"]&&Z.ownerDocument&&Z.ownerDocument.doctype&&Z.ownerDocument.doctype.name&&oe(Pm,Z.ownerDocument.doctype.name)&&(ve="<!DOCTYPE "+Z.ownerDocument.doctype.name+`>
3
+ `)}async function DI(e,t){const n=t.fontEmbedCSS!=null?t.fontEmbedCSS:t.skipFonts?null:await AI(e,t);if(n){const i=document.createElement("style"),r=document.createTextNode(n);i.appendChild(r),e.firstChild?e.insertBefore(i,e.firstChild):e.appendChild(i)}}async function LI(e,t={}){const{width:n,height:i}=hm(e,t),r=await no(e,t,!0);return await DI(r,t),await Em(r,t),OI(r,t),await ZR(r,n,i)}async function Tm(e,t={}){const{width:n,height:i}=hm(e,t),r=await LI(e,t),s=await eo(r),a=document.createElement("canvas"),o=a.getContext("2d"),l=t.pixelRatio||YR(),c=t.canvasWidth||n,u=t.canvasHeight||i;return a.width=c*l,a.height=u*l,t.skipAutoScale||qR(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 RI(e,t={}){return(await Tm(e,t)).toDataURL()}async function II(e,t={}){return(await Tm(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 kI="DONT_STYLE_ME_css_styles_verifier";class k 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=I(t));const i={width:0,height:0},r=h=>{h&&Object.keys(i).forEach(f=>{if(h[f]){const p=h[f],g=parseFloat(p);p&&g>i[f]&&(""+p).indexOf("%")===-1&&(i[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?.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&&(r(s),i.width>0&&i.height>0))return i;if(n.useClientDimensions&&(r(d),i.width>0&&i.height>0))return d;if(n.useBBox&&(r(l),i.width>0&&i.height>0))return l;if(n.useBoundingRect&&(r(u),i.width>0&&i.height>0))return u}try{const h={width:y(t.node(),"width","baseVal","value"),height:y(t.node(),"height","baseVal","value")};r(h)}catch{r(d),r(l),r(s)}return i}static appendOrSelect(t,n){const i=t.select(`${n}`);if(i.empty()){let r=n.split("#"),s,a;return r.length===2?(s=r[0],r=r[1].split("."),a=r[0]):(r=n.split("."),s=r[0]),t.append(s).attr("id",a).attr("class",r.slice(1).join(" "))}return i}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 i={left:0,top:0},r=t.getBoundingClientRect(),s=n?{left:0,top:0}:this.getHolder().getBoundingClientRect();try{i.left=r.left-s.left,i.top=r.top-s.top}catch(a){console.error(a)}return i}generateElementIDString(t){return`chart-${this.chartID}-${t}`}initializeID(){const t=this.model.getOptions().chartId;t?this.chartID=t:this.chartID=Math.floor((1+Math.random())*281474976710656).toString(16)}addMainContainer(){const t=this.model.getOptions(),n=y(t,"style","prefix"),i=I(this.getHolder()).append("div").classed(`${fe}--${n}--chart-wrapper`,!0).attr("id",`chart-${this.getChartID()}`).style("height","100%").style("width","100%");i.append("g").attr("class",kI),this.mainContainer=i.node()}update(){this.styleHolderElement()}styleHolderElement(){const t=this.getHolder(),{width:n,height:i,theme:r}=this.model.getOptions();n!==this.width&&(t.style.width=n,this.width=n),i!==this.height&&(t.style.height=i,this.height=i),I(this.getHolder()).classed(`${fe}--chart-holder`,!0).attr("data-carbon-theme",r)}getHolder(){return this.model.get("holder")}exportToJPG(){const t=this,n=this.model.getOptions(),i=this.getHolder(),r=I(i);r.classed("filled",!0),II(this.getMainContainer(),{quality:1,filter:s=>!(s.classList&&s.classList.contains("cds--cc--toolbar"))}).then(function(s){let a="myChart";const o=y(n,"fileDownload","fileName");typeof o=="function"?a=o("jpg"):typeof o=="string"&&(a=o),t.services.files?.downloadImage(s,`${a}.jpg`),r.classed("filled",!1)})}exportToPNG(){const t=this,n=this.model.getOptions(),i=this.getHolder(),r=I(i);r.classed("filled",!0),RI(this.getMainContainer(),{quality:1,filter:s=>!(s.classList&&s.classList.contains("cds--cc--toolbar"))}).then(function(s){let a="myChart";const o=y(n,"fileDownload","fileName");typeof o=="function"?a=o("png"):typeof o=="string"&&(a=o),t.services.files?.downloadImage(s,`${a}.png`),r.classed("filled",!1)}).catch(function(s){console.error("oops, something went wrong!",s)})}isFullScreenMode(){return I(this.getHolder()).classed("fullscreen")}toggleFullscreen(){const t=this.getHolder();I(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=I(this.getHolder()),n=t.classed("fullscreen");t.classed("fullscreen",!n)})}setSVGMaxHeight(){if(!this.model.getOptions().height){const{height:t}=k.getSVGElementSize(I(this.mainContainer),{useBBox:!0}),n=I(this.mainContainer).attr("class"),i=I(this.mainContainer).selectAll(`.${n} > svg`);let r=0;i.nodes().forEach(function(s){r+=Number(k.getSVGElementSize(I(s),{useBBox:!0}).height)}),r<=t?I(this.mainContainer).attr("height",r):I(this.mainContainer).attr("height","100%")}}getMainContainer(){return this.mainContainer}addHolderListeners(){const t=this.getHolder();t&&I(t).on("mouseover",()=>{this.services.events?.dispatchEvent(T.Chart.MOUSEOVER)}).on("mouseout",()=>{this.services.events?.dispatchEvent(T.Chart.MOUSEOUT)})}addResizeListener(){const t=this.getHolder();if(!t)return;let n=t.clientWidth,i=t.clientHeight;const r=Wa(()=>{t&&(Math.abs(n-t.clientWidth)>1||Math.abs(i-t.clientHeight)>1)&&(n=t.clientWidth,i=t.clientHeight,this.services.events?.dispatchEvent(T.Chart.RESIZE))},12.5);new ResizeObserver(r).observe(t)}}class mt{constructor(t,n,i){if(this.type="",this.renderType=at.HTML,this.id="",this.parent=void 0,this.configs={},this.model=t,this.services=n,i&&(this.configs=i,this.configs.id)){const r=y(this.model.getOptions(),"style","prefix");this.id=`${r}--${this.configs.id}`}this.parent||this.setParent(I(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){const n=this.parent;if(this.parent=t,!(n&&n.node()===t.node())&&this.type){const i=y(this.model.getOptions(),"style","prefix");this.parent?.classed(`${fe}--${i}--${this.type}`,!0),n&&n.classed(`${fe}--${i}--${this.type}`,!1)}}getParent(){return this.parent}getComponentContainer(t={ariaLabel:null,isPresentational:!1,withinChartClip:!1}){if(this.type){const n=y(this.model.getOptions(),"style","prefix"),i=this.id?`#${this.id}`:"",r=k.appendOrSelect(this.parent,`${this.renderType===at.SVG?"svg":"div"}${i}.${fe}--${n}--${this.type}`);if(t.ariaLabel&&r.attr("aria-label",t.ariaLabel),t.isPresentational&&r.attr("role","presentation"),t.withinChartClip){const s=this.model.get("chartClipId");if(s){const o=I(`#${s}`).select("rect");if(o.size()!==0){const l=parseFloat(o.attr("height")),c=parseFloat(o.attr("width"));!isNaN(l)&&!isNaN(c)&&l>0&&c>0&&r.attr("clip-path",`url(#${s})`)}}}return r.attr("width","100%").attr("height","100%")}return this.parent}getOptions(){return this.configs.options?ct({},this.model.getOptions(),this.configs.options):this.model.getOptions()}}/*! @license DOMPurify 3.2.6 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.2.6/LICENSE */const{entries:Om,setPrototypeOf:wm,isFrozen:PI,getPrototypeOf:NI,getOwnPropertyDescriptor:$I}=Object;let{freeze:ae,seal:Pe,create:Mm}=Object,{apply:ou,construct:lu}=typeof Reflect<"u"&&Reflect;ae||(ae=function(t){return t}),Pe||(Pe=function(t){return t}),ou||(ou=function(t,n,i){return t.apply(n,i)}),lu||(lu=function(t,n){return new t(...n)});const ro=le(Array.prototype.forEach),FI=le(Array.prototype.lastIndexOf),Cm=le(Array.prototype.pop),gs=le(Array.prototype.push),UI=le(Array.prototype.splice),so=le(String.prototype.toLowerCase),cu=le(String.prototype.toString),Am=le(String.prototype.match),ms=le(String.prototype.replace),BI=le(String.prototype.indexOf),HI=le(String.prototype.trim),Xe=le(Object.prototype.hasOwnProperty),oe=le(RegExp.prototype.test),vs=GI(TypeError);function le(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var n=arguments.length,i=new Array(n>1?n-1:0),r=1;r<n;r++)i[r-1]=arguments[r];return ou(e,t,i)}}function GI(e){return function(){for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];return lu(e,n)}}function vt(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:so;wm&&wm(e,null);let i=t.length;for(;i--;){let r=t[i];if(typeof r=="string"){const s=n(r);s!==r&&(PI(t)||(t[i]=s),r=s)}e[r]=!0}return e}function VI(e){for(let t=0;t<e.length;t++)Xe(e,t)||(e[t]=null);return e}function Dn(e){const t=Mm(null);for(const[n,i]of Om(e))Xe(e,n)&&(Array.isArray(i)?t[n]=VI(i):i&&typeof i=="object"&&i.constructor===Object?t[n]=Dn(i):t[n]=i);return t}function ys(e,t){for(;e!==null;){const i=$I(e,t);if(i){if(i.get)return le(i.get);if(typeof i.value=="function")return le(i.value)}e=NI(e)}function n(){return null}return n}const Dm=ae(["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"]),uu=ae(["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"]),hu=ae(["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"]),zI=ae(["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"]),du=ae(["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"]),WI=ae(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Lm=ae(["#text"]),Rm=ae(["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"]),fu=ae(["accent-height","accumulate","additive","alignment-baseline","amplitude","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","exponent","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","intercept","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","slope","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","tablevalues","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"]),Im=ae(["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=ae(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),YI=Pe(/\{\{[\w\W]*|[\w\W]*\}\}/gm),qI=Pe(/<%[\w\W]*|[\w\W]*%>/gm),XI=Pe(/\$\{[\w\W]*/gm),ZI=Pe(/^data-[\-\w.\u00B7-\uFFFF]+$/),jI=Pe(/^aria-[\-\w]+$/),km=Pe(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),KI=Pe(/^(?:\w+script|data):/i),QI=Pe(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),Pm=Pe(/^html$/i),JI=Pe(/^[a-z][.\w]*(-[.\w]+)+$/i);var Nm=Object.freeze({__proto__:null,ARIA_ATTR:jI,ATTR_WHITESPACE:QI,CUSTOM_ELEMENT:JI,DATA_ATTR:ZI,DOCTYPE_NAME:Pm,ERB_EXPR:qI,IS_ALLOWED_URI:km,IS_SCRIPT_OR_DATA:KI,MUSTACHE_EXPR:YI,TMPLIT_EXPR:XI});const Es={element:1,text:3,progressingInstruction:7,comment:8,document:9},tk=function(){return typeof window>"u"?null:window},ek=function(t,n){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let i=null;const r="data-tt-policy-suffix";n&&n.hasAttribute(r)&&(i=n.getAttribute(r));const s="dompurify"+(i?"#"+i:"");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}},$m=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function Fm(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:tk();const t=ot=>Fm(ot);if(t.version="3.2.6",t.removed=[],!e||!e.document||e.document.nodeType!==Es.document||!e.Element)return t.isSupported=!1,t;let{document:n}=e;const i=n,r=i.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=ys(p,"cloneNode"),m=ys(p,"remove"),v=ys(p,"nextSibling"),S=ys(p,"childNodes"),E=ys(p,"parentNode");if(typeof a=="function"){const ot=n.createElement("template");ot.content&&ot.content.ownerDocument&&(n=ot.content.ownerDocument)}let b,x="";const{implementation:_,createNodeIterator:C,createDocumentFragment:A,getElementsByTagName:$}=n,{importNode:P}=i;let w=$m();t.isSupported=typeof Om=="function"&&typeof E=="function"&&_&&_.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:H,ERB_EXPR:N,TMPLIT_EXPR:M,DATA_ATTR:O,ARIA_ATTR:F,IS_SCRIPT_OR_DATA:U,ATTR_WHITESPACE:L,CUSTOM_ELEMENT:B}=Nm;let{IS_ALLOWED_URI:tt}=Nm,X=null;const Y=vt({},[...Dm,...uu,...hu,...du,...Lm]);let Q=null;const ut=vt({},[...Rm,...fu,...Im,...ao]);let et=Object.seal(Mm(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}})),K=null,nt=null,ht=!0,W=!0,j=!1,J=!0,D=!1,G=!0,V=!1,xt=!1,Ut=!1,st=!1,_t=!1,Ne=!1,Oe=!0,_s=!1;const Ts="user-content-";let mi=!0,je=!1,ar={},or=null;const Rv=vt({},["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 Iv=null;const kv=vt({},["audio","video","img","source","image","track"]);let Du=null;const Pv=vt({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),vo="http://www.w3.org/1998/Math/MathML",yo="http://www.w3.org/2000/svg",Rn="http://www.w3.org/1999/xhtml";let lr=Rn,Lu=!1,Ru=null;const q$=vt({},[vo,yo,Rn],cu);let Eo=vt({},["mi","mo","mn","ms","mtext"]),xo=vt({},["annotation-xml"]);const X$=vt({},["title","style","font","a","script"]);let Os=null;const Z$=["application/xhtml+xml","text/html"],j$="text/html";let Xt=null,cr=null;const K$=n.createElement("form"),Nv=function(R){return R instanceof RegExp||R instanceof Function},Iu=function(){let R=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(cr&&cr===R)){if((!R||typeof R!="object")&&(R={}),R=Dn(R),Os=Z$.indexOf(R.PARSER_MEDIA_TYPE)===-1?j$:R.PARSER_MEDIA_TYPE,Xt=Os==="application/xhtml+xml"?cu:so,X=Xe(R,"ALLOWED_TAGS")?vt({},R.ALLOWED_TAGS,Xt):Y,Q=Xe(R,"ALLOWED_ATTR")?vt({},R.ALLOWED_ATTR,Xt):ut,Ru=Xe(R,"ALLOWED_NAMESPACES")?vt({},R.ALLOWED_NAMESPACES,cu):q$,Du=Xe(R,"ADD_URI_SAFE_ATTR")?vt(Dn(Pv),R.ADD_URI_SAFE_ATTR,Xt):Pv,Iv=Xe(R,"ADD_DATA_URI_TAGS")?vt(Dn(kv),R.ADD_DATA_URI_TAGS,Xt):kv,or=Xe(R,"FORBID_CONTENTS")?vt({},R.FORBID_CONTENTS,Xt):Rv,K=Xe(R,"FORBID_TAGS")?vt({},R.FORBID_TAGS,Xt):Dn({}),nt=Xe(R,"FORBID_ATTR")?vt({},R.FORBID_ATTR,Xt):Dn({}),ar=Xe(R,"USE_PROFILES")?R.USE_PROFILES:!1,ht=R.ALLOW_ARIA_ATTR!==!1,W=R.ALLOW_DATA_ATTR!==!1,j=R.ALLOW_UNKNOWN_PROTOCOLS||!1,J=R.ALLOW_SELF_CLOSE_IN_ATTR!==!1,D=R.SAFE_FOR_TEMPLATES||!1,G=R.SAFE_FOR_XML!==!1,V=R.WHOLE_DOCUMENT||!1,st=R.RETURN_DOM||!1,_t=R.RETURN_DOM_FRAGMENT||!1,Ne=R.RETURN_TRUSTED_TYPE||!1,Ut=R.FORCE_BODY||!1,Oe=R.SANITIZE_DOM!==!1,_s=R.SANITIZE_NAMED_PROPS||!1,mi=R.KEEP_CONTENT!==!1,je=R.IN_PLACE||!1,tt=R.ALLOWED_URI_REGEXP||km,lr=R.NAMESPACE||Rn,Eo=R.MATHML_TEXT_INTEGRATION_POINTS||Eo,xo=R.HTML_INTEGRATION_POINTS||xo,et=R.CUSTOM_ELEMENT_HANDLING||{},R.CUSTOM_ELEMENT_HANDLING&&Nv(R.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(et.tagNameCheck=R.CUSTOM_ELEMENT_HANDLING.tagNameCheck),R.CUSTOM_ELEMENT_HANDLING&&Nv(R.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(et.attributeNameCheck=R.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),R.CUSTOM_ELEMENT_HANDLING&&typeof R.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(et.allowCustomizedBuiltInElements=R.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),D&&(W=!1),_t&&(st=!0),ar&&(X=vt({},Lm),Q=[],ar.html===!0&&(vt(X,Dm),vt(Q,Rm)),ar.svg===!0&&(vt(X,uu),vt(Q,fu),vt(Q,ao)),ar.svgFilters===!0&&(vt(X,hu),vt(Q,fu),vt(Q,ao)),ar.mathMl===!0&&(vt(X,du),vt(Q,Im),vt(Q,ao))),R.ADD_TAGS&&(X===Y&&(X=Dn(X)),vt(X,R.ADD_TAGS,Xt)),R.ADD_ATTR&&(Q===ut&&(Q=Dn(Q)),vt(Q,R.ADD_ATTR,Xt)),R.ADD_URI_SAFE_ATTR&&vt(Du,R.ADD_URI_SAFE_ATTR,Xt),R.FORBID_CONTENTS&&(or===Rv&&(or=Dn(or)),vt(or,R.FORBID_CONTENTS,Xt)),mi&&(X["#text"]=!0),V&&vt(X,["html","head","body"]),X.table&&(vt(X,["tbody"]),delete K.tbody),R.TRUSTED_TYPES_POLICY){if(typeof R.TRUSTED_TYPES_POLICY.createHTML!="function")throw vs('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof R.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw vs('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');b=R.TRUSTED_TYPES_POLICY,x=b.createHTML("")}else b===void 0&&(b=ek(f,r)),b!==null&&typeof x=="string"&&(x=b.createHTML(""));ae&&ae(R),cr=R}},$v=vt({},[...uu,...hu,...zI]),Fv=vt({},[...du,...WI]),Q$=function(R){let Z=E(R);(!Z||!Z.tagName)&&(Z={namespaceURI:lr,tagName:"template"});const rt=so(R.tagName),kt=so(Z.tagName);return Ru[R.namespaceURI]?R.namespaceURI===yo?Z.namespaceURI===Rn?rt==="svg":Z.namespaceURI===vo?rt==="svg"&&(kt==="annotation-xml"||Eo[kt]):!!$v[rt]:R.namespaceURI===vo?Z.namespaceURI===Rn?rt==="math":Z.namespaceURI===yo?rt==="math"&&xo[kt]:!!Fv[rt]:R.namespaceURI===Rn?Z.namespaceURI===yo&&!xo[kt]||Z.namespaceURI===vo&&!Eo[kt]?!1:!Fv[rt]&&(X$[rt]||!$v[rt]):!!(Os==="application/xhtml+xml"&&Ru[R.namespaceURI]):!1},un=function(R){gs(t.removed,{element:R});try{E(R).removeChild(R)}catch{m(R)}},ur=function(R,Z){try{gs(t.removed,{attribute:Z.getAttributeNode(R),from:Z})}catch{gs(t.removed,{attribute:null,from:Z})}if(Z.removeAttribute(R),R==="is")if(st||_t)try{un(Z)}catch{}else try{Z.setAttribute(R,"")}catch{}},Uv=function(R){let Z=null,rt=null;if(Ut)R="<remove></remove>"+R;else{const Yt=Am(R,/^[\r\n\t ]+/);rt=Yt&&Yt[0]}Os==="application/xhtml+xml"&&lr===Rn&&(R='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+R+"</body></html>");const kt=b?b.createHTML(R):R;if(lr===Rn)try{Z=new h().parseFromString(kt,Os)}catch{}if(!Z||!Z.documentElement){Z=_.createDocument(lr,"template",null);try{Z.documentElement.innerHTML=Lu?x:kt}catch{}}const ne=Z.body||Z.documentElement;return R&&rt&&ne.insertBefore(n.createTextNode(rt),ne.childNodes[0]||null),lr===Rn?$.call(Z,V?"html":"body")[0]:V?Z.documentElement:ne},Bv=function(R){return C.call(R.ownerDocument||R,R,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT|c.SHOW_PROCESSING_INSTRUCTION|c.SHOW_CDATA_SECTION,null)},ku=function(R){return R instanceof d&&(typeof R.nodeName!="string"||typeof R.textContent!="string"||typeof R.removeChild!="function"||!(R.attributes instanceof u)||typeof R.removeAttribute!="function"||typeof R.setAttribute!="function"||typeof R.namespaceURI!="string"||typeof R.insertBefore!="function"||typeof R.hasChildNodes!="function")},Hv=function(R){return typeof o=="function"&&R instanceof o};function In(ot,R,Z){ro(ot,rt=>{rt.call(t,R,Z,cr)})}const Gv=function(R){let Z=null;if(In(w.beforeSanitizeElements,R,null),ku(R))return un(R),!0;const rt=Xt(R.nodeName);if(In(w.uponSanitizeElement,R,{tagName:rt,allowedTags:X}),G&&R.hasChildNodes()&&!Hv(R.firstElementChild)&&oe(/<[/\w!]/g,R.innerHTML)&&oe(/<[/\w!]/g,R.textContent)||R.nodeType===Es.progressingInstruction||G&&R.nodeType===Es.comment&&oe(/<[/\w]/g,R.data))return un(R),!0;if(!X[rt]||K[rt]){if(!K[rt]&&zv(rt)&&(et.tagNameCheck instanceof RegExp&&oe(et.tagNameCheck,rt)||et.tagNameCheck instanceof Function&&et.tagNameCheck(rt)))return!1;if(mi&&!or[rt]){const kt=E(R)||R.parentNode,ne=S(R)||R.childNodes;if(ne&&kt){const Yt=ne.length;for(let ve=Yt-1;ve>=0;--ve){const kn=g(ne[ve],!0);kn.__removalCount=(R.__removalCount||0)+1,kt.insertBefore(kn,v(R))}}}return un(R),!0}return R instanceof l&&!Q$(R)||(rt==="noscript"||rt==="noembed"||rt==="noframes")&&oe(/<\/no(script|embed|frames)/i,R.innerHTML)?(un(R),!0):(D&&R.nodeType===Es.text&&(Z=R.textContent,ro([H,N,M],kt=>{Z=ms(Z,kt," ")}),R.textContent!==Z&&(gs(t.removed,{element:R.cloneNode()}),R.textContent=Z)),In(w.afterSanitizeElements,R,null),!1)},Vv=function(R,Z,rt){if(Oe&&(Z==="id"||Z==="name")&&(rt in n||rt in K$))return!1;if(!(W&&!nt[Z]&&oe(O,Z))){if(!(ht&&oe(F,Z))){if(!Q[Z]||nt[Z]){if(!(zv(R)&&(et.tagNameCheck instanceof RegExp&&oe(et.tagNameCheck,R)||et.tagNameCheck instanceof Function&&et.tagNameCheck(R))&&(et.attributeNameCheck instanceof RegExp&&oe(et.attributeNameCheck,Z)||et.attributeNameCheck instanceof Function&&et.attributeNameCheck(Z))||Z==="is"&&et.allowCustomizedBuiltInElements&&(et.tagNameCheck instanceof RegExp&&oe(et.tagNameCheck,rt)||et.tagNameCheck instanceof Function&&et.tagNameCheck(rt))))return!1}else if(!Du[Z]){if(!oe(tt,ms(rt,L,""))){if(!((Z==="src"||Z==="xlink:href"||Z==="href")&&R!=="script"&&BI(rt,"data:")===0&&Iv[R])){if(!(j&&!oe(U,ms(rt,L,"")))){if(rt)return!1}}}}}}return!0},zv=function(R){return R!=="annotation-xml"&&Am(R,B)},Wv=function(R){In(w.beforeSanitizeAttributes,R,null);const{attributes:Z}=R;if(!Z||ku(R))return;const rt={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:Q,forceKeepAttr:void 0};let kt=Z.length;for(;kt--;){const ne=Z[kt],{name:Yt,namespaceURI:ve,value:kn}=ne,ws=Xt(Yt),Pu=kn;let ie=Yt==="value"?Pu:HI(Pu);if(rt.attrName=ws,rt.attrValue=ie,rt.keepAttr=!0,rt.forceKeepAttr=void 0,In(w.uponSanitizeAttribute,R,rt),ie=rt.attrValue,_s&&(ws==="id"||ws==="name")&&(ur(Yt,R),ie=Ts+ie),G&&oe(/((--!?|])>)|<\/(style|title)/i,ie)){ur(Yt,R);continue}if(rt.forceKeepAttr)continue;if(!rt.keepAttr){ur(Yt,R);continue}if(!J&&oe(/\/>/i,ie)){ur(Yt,R);continue}D&&ro([H,N,M],qv=>{ie=ms(ie,qv," ")});const Yv=Xt(R.nodeName);if(!Vv(Yv,ws,ie)){ur(Yt,R);continue}if(b&&typeof f=="object"&&typeof f.getAttributeType=="function"&&!ve)switch(f.getAttributeType(Yv,ws)){case"TrustedHTML":{ie=b.createHTML(ie);break}case"TrustedScriptURL":{ie=b.createScriptURL(ie);break}}if(ie!==Pu)try{ve?R.setAttributeNS(ve,Yt,ie):R.setAttribute(Yt,ie),ku(R)?un(R):Cm(t.removed)}catch{ur(Yt,R)}}In(w.afterSanitizeAttributes,R,null)},J$=function ot(R){let Z=null;const rt=Bv(R);for(In(w.beforeSanitizeShadowDOM,R,null);Z=rt.nextNode();)In(w.uponSanitizeShadowNode,Z,null),Gv(Z),Wv(Z),Z.content instanceof s&&ot(Z.content);In(w.afterSanitizeShadowDOM,R,null)};return t.sanitize=function(ot){let R=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Z=null,rt=null,kt=null,ne=null;if(Lu=!ot,Lu&&(ot="<!-->"),typeof ot!="string"&&!Hv(ot))if(typeof ot.toString=="function"){if(ot=ot.toString(),typeof ot!="string")throw vs("dirty is not a string, aborting")}else throw vs("toString is not a function");if(!t.isSupported)return ot;if(xt||Iu(R),t.removed=[],typeof ot=="string"&&(je=!1),je){if(ot.nodeName){const kn=Xt(ot.nodeName);if(!X[kn]||K[kn])throw vs("root node is forbidden and cannot be sanitized in-place")}}else if(ot instanceof o)Z=Uv("<!---->"),rt=Z.ownerDocument.importNode(ot,!0),rt.nodeType===Es.element&&rt.nodeName==="BODY"||rt.nodeName==="HTML"?Z=rt:Z.appendChild(rt);else{if(!st&&!D&&!V&&ot.indexOf("<")===-1)return b&&Ne?b.createHTML(ot):ot;if(Z=Uv(ot),!Z)return st?null:Ne?x:""}Z&&Ut&&un(Z.firstChild);const Yt=Bv(je?ot:Z);for(;kt=Yt.nextNode();)Gv(kt),Wv(kt),kt.content instanceof s&&J$(kt.content);if(je)return ot;if(st){if(_t)for(ne=A.call(Z.ownerDocument);Z.firstChild;)ne.appendChild(Z.firstChild);else ne=Z;return(Q.shadowroot||Q.shadowrootmode)&&(ne=P.call(i,ne,!0)),ne}let ve=V?Z.outerHTML:Z.innerHTML;return V&&X["!doctype"]&&Z.ownerDocument&&Z.ownerDocument.doctype&&Z.ownerDocument.doctype.name&&oe(Pm,Z.ownerDocument.doctype.name)&&(ve="<!DOCTYPE "+Z.ownerDocument.doctype.name+`>
4
4
  `+ve),D&&ro([H,N,M],kn=>{ve=ms(ve,kn," ")}),b&&Ne?b.createHTML(ve):ve},t.setConfig=function(){let ot=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Iu(ot),xt=!0},t.clearConfig=function(){cr=null,xt=!1},t.isValidAttribute=function(ot,R,Z){cr||Iu({});const rt=Xt(ot),kt=Xt(R);return Vv(rt,kt,Z)},t.addHook=function(ot,R){typeof R=="function"&&gs(w[ot],R)},t.removeHook=function(ot,R){if(R!==void 0){const Z=FI(w[ot],R);return Z===-1?void 0:UI(w[ot],Z,1)[0]}return Cm(w[ot])},t.removeHooks=function(ot){w[ot]=[]},t.removeAllHooks=function(){w=$m()},t}var pu=Fm();const oo=e=>pu.sanitize(e,{USE_PROFILES:{html:!0,svg:!0,svgFilters:!0}}),nk=e=>pu.sanitize(e,{NAMESPACE:"http://www.w3.org/2000/svg",USE_PROFILES:{html:!0,svg:!0,svgFilters:!0}}),ln=e=>pu.sanitize(e,{ALLOWED_TAGS:[]}),go=class go extends mt{constructor(){super(...arguments),this.type="toolbar",this.renderType=at.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({ariaLabel:"toolbar"}).attr("role","group");if(y(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:r,overflowMenuItemList:s}=this.getControlConfigs();s&&r.push(this.getOverflowButtonConfig());const a=n.selectAll("div.toolbar-control").data(r,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=>`
5
5
  <button
6
6
  type="button"
@@ -17,7 +17,7 @@
17
17
  <div class="cds--modal-container">
18
18
  <div class="cds--modal-header">
19
19
 
20
- <p class="cds--modal-header__label cds--type-delta" id="modal-title">${i}</p>
20
+ <p class="cds--modal-header__label cds--type-delta" id="${t}__modal-title">${i}</p>
21
21
 
22
22
  <p class="cds--modal-header__heading cds--type-beta" id="${t}__modal-description">${ln(n.title)}</p>
23
23