-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathd3.custom.min.js
More file actions
1 lines (1 loc) · 51.7 KB
/
d3.custom.min.js
File metadata and controls
1 lines (1 loc) · 51.7 KB
1
var d3=(()=>{var xe=Object.defineProperty;var uo=Object.getOwnPropertyDescriptor;var so=Object.getOwnPropertyNames;var lo=Object.prototype.hasOwnProperty;var co=(t,e)=>{for(var r in e)xe(t,r,{get:e[r],enumerable:!0})},po=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of so(e))!lo.call(t,o)&&o!==r&&xe(t,o,{get:()=>e[o],enumerable:!(n=uo(e,o))||n.enumerable});return t};var mo=t=>po(xe({},"__esModule",{value:!0}),t);var Da={};co(Da,{default:()=>Fa,extent:()=>rt,interpolateNumber:()=>w,max:()=>ot,min:()=>it,scaleBand:()=>Y,scaleLinear:()=>W,scaleLog:()=>J,select:()=>yt,selectAll:()=>wt,transition:()=>tt});var Lt="http://www.w3.org/1999/xhtml",ge={svg:"http://www.w3.org/2000/svg",xhtml:Lt,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function q(t){var e=t+="",r=e.indexOf(":");return r>=0&&(e=t.slice(0,r))!=="xmlns"&&(t=t.slice(r+1)),ge.hasOwnProperty(e)?{space:ge[e],local:t}:t}function ho(t){return function(){var e=this.ownerDocument,r=this.namespaceURI;return r===Lt&&e.documentElement.namespaceURI===Lt?e.createElement(t):e.createElementNS(r,t)}}function xo(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function Ft(t){var e=q(t);return(e.local?xo:ho)(e)}function go(){}function z(t){return t==null?go:function(){return this.querySelector(t)}}function Je(t){typeof t!="function"&&(t=z(t));for(var e=this._groups,r=e.length,n=new Array(r),o=0;o<r;++o)for(var i=e[o],a=i.length,f=n[o]=new Array(a),s,u,l=0;l<a;++l)(s=i[l])&&(u=t.call(s,s.__data__,l,i))&&("__data__"in s&&(u.__data__=s.__data__),f[l]=u);return new g(n,this._parents)}function mt(t){return t==null?[]:Array.isArray(t)?t:Array.from(t)}function yo(){return[]}function ht(t){return t==null?yo:function(){return this.querySelectorAll(t)}}function wo(t){return function(){return mt(t.apply(this,arguments))}}function je(t){typeof t=="function"?t=wo(t):t=ht(t);for(var e=this._groups,r=e.length,n=[],o=[],i=0;i<r;++i)for(var a=e[i],f=a.length,s,u=0;u<f;++u)(s=a[u])&&(n.push(t.call(s,s.__data__,u,a)),o.push(s));return new g(n,o)}function dt(t){return function(){return this.matches(t)}}function Dt(t){return function(e){return e.matches(t)}}var _o=Array.prototype.find;function vo(t){return function(){return _o.call(this.children,t)}}function bo(){return this.firstElementChild}function tr(t){return this.select(t==null?bo:vo(typeof t=="function"?t:Dt(t)))}var Mo=Array.prototype.filter;function No(){return Array.from(this.children)}function ko(t){return function(){return Mo.call(this.children,t)}}function er(t){return this.selectAll(t==null?No:ko(typeof t=="function"?t:Dt(t)))}function rr(t){typeof t!="function"&&(t=dt(t));for(var e=this._groups,r=e.length,n=new Array(r),o=0;o<r;++o)for(var i=e[o],a=i.length,f=n[o]=[],s,u=0;u<a;++u)(s=i[u])&&t.call(s,s.__data__,u,i)&&f.push(s);return new g(n,this._parents)}function Bt(t){return new Array(t.length)}function nr(){return new g(this._enter||this._groups.map(Bt),this._parents)}function xt(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}xt.prototype={constructor:xt,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};function or(t){return function(){return t}}function So(t,e,r,n,o,i){for(var a=0,f,s=e.length,u=i.length;a<u;++a)(f=e[a])?(f.__data__=i[a],n[a]=f):r[a]=new xt(t,i[a]);for(;a<s;++a)(f=e[a])&&(o[a]=f)}function Ao(t,e,r,n,o,i,a){var f,s,u=new Map,l=e.length,c=i.length,p=new Array(l),m;for(f=0;f<l;++f)(s=e[f])&&(p[f]=m=a.call(s,s.__data__,f,e)+"",u.has(m)?o[f]=s:u.set(m,s));for(f=0;f<c;++f)m=a.call(t,i[f],f,i)+"",(s=u.get(m))?(n[f]=s,s.__data__=i[f],u.delete(m)):r[f]=new xt(t,i[f]);for(f=0;f<l;++f)(s=e[f])&&u.get(p[f])===s&&(o[f]=s)}function Io(t){return t.__data__}function ir(t,e){if(!arguments.length)return Array.from(this,Io);var r=e?Ao:So,n=this._parents,o=this._groups;typeof t!="function"&&(t=or(t));for(var i=o.length,a=new Array(i),f=new Array(i),s=new Array(i),u=0;u<i;++u){var l=n[u],c=o[u],p=c.length,m=Eo(t.call(l,l&&l.__data__,u,n)),h=m.length,d=f[u]=new Array(h),y=a[u]=new Array(h),v=s[u]=new Array(p);r(l,c,d,y,v,m,e);for(var T=0,S=0,pt,M;T<h;++T)if(pt=d[T]){for(T>=S&&(S=T+1);!(M=y[S])&&++S<h;);pt._next=M||null}}return a=new g(a,n),a._enter=f,a._exit=s,a}function Eo(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}function ar(){return new g(this._exit||this._groups.map(Bt),this._parents)}function fr(t,e,r){var n=this.enter(),o=this,i=this.exit();return typeof t=="function"?(n=t(n),n&&(n=n.selection())):n=n.append(t+""),e!=null&&(o=e(o),o&&(o=o.selection())),r==null?i.remove():r(i),n&&o?n.merge(o).order():o}function ur(t){for(var e=t.selection?t.selection():t,r=this._groups,n=e._groups,o=r.length,i=n.length,a=Math.min(o,i),f=new Array(o),s=0;s<a;++s)for(var u=r[s],l=n[s],c=u.length,p=f[s]=new Array(c),m,h=0;h<c;++h)(m=u[h]||l[h])&&(p[h]=m);for(;s<o;++s)f[s]=r[s];return new g(f,this._parents)}function sr(){for(var t=this._groups,e=-1,r=t.length;++e<r;)for(var n=t[e],o=n.length-1,i=n[o],a;--o>=0;)(a=n[o])&&(i&&a.compareDocumentPosition(i)^4&&i.parentNode.insertBefore(a,i),i=a);return this}function lr(t){t||(t=Oo);function e(c,p){return c&&p?t(c.__data__,p.__data__):!c-!p}for(var r=this._groups,n=r.length,o=new Array(n),i=0;i<n;++i){for(var a=r[i],f=a.length,s=o[i]=new Array(f),u,l=0;l<f;++l)(u=a[l])&&(s[l]=u);s.sort(e)}return new g(o,this._parents).order()}function Oo(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function cr(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}function pr(){return Array.from(this)}function mr(){for(var t=this._groups,e=0,r=t.length;e<r;++e)for(var n=t[e],o=0,i=n.length;o<i;++o){var a=n[o];if(a)return a}return null}function hr(){let t=0;for(let e of this)++t;return t}function dr(){return!this.node()}function xr(t){for(var e=this._groups,r=0,n=e.length;r<n;++r)for(var o=e[r],i=0,a=o.length,f;i<a;++i)(f=o[i])&&t.call(f,f.__data__,i,o);return this}function Co(t){return function(){this.removeAttribute(t)}}function Ro(t){return function(){this.removeAttributeNS(t.space,t.local)}}function To(t,e){return function(){this.setAttribute(t,e)}}function $o(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function qo(t,e){return function(){var r=e.apply(this,arguments);r==null?this.removeAttribute(t):this.setAttribute(t,r)}}function Po(t,e){return function(){var r=e.apply(this,arguments);r==null?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,r)}}function gr(t,e){var r=q(t);if(arguments.length<2){var n=this.node();return r.local?n.getAttributeNS(r.space,r.local):n.getAttribute(r)}return this.each((e==null?r.local?Ro:Co:typeof e=="function"?r.local?Po:qo:r.local?$o:To)(r,e))}function Ht(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function Lo(t){return function(){this.style.removeProperty(t)}}function Fo(t,e,r){return function(){this.style.setProperty(t,e,r)}}function Do(t,e,r){return function(){var n=e.apply(this,arguments);n==null?this.style.removeProperty(t):this.style.setProperty(t,n,r)}}function yr(t,e,r){return arguments.length>1?this.each((e==null?Lo:typeof e=="function"?Do:Fo)(t,e,r==null?"":r)):F(this.node(),t)}function F(t,e){return t.style.getPropertyValue(e)||Ht(t).getComputedStyle(t,null).getPropertyValue(e)}function Bo(t){return function(){delete this[t]}}function Ho(t,e){return function(){this[t]=e}}function zo(t,e){return function(){var r=e.apply(this,arguments);r==null?delete this[t]:this[t]=r}}function wr(t,e){return arguments.length>1?this.each((e==null?Bo:typeof e=="function"?zo:Ho)(t,e)):this.node()[t]}function _r(t){return t.trim().split(/^|\s+/)}function ye(t){return t.classList||new vr(t)}function vr(t){this._node=t,this._names=_r(t.getAttribute("class")||"")}vr.prototype={add:function(t){var e=this._names.indexOf(t);e<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};function br(t,e){for(var r=ye(t),n=-1,o=e.length;++n<o;)r.add(e[n])}function Mr(t,e){for(var r=ye(t),n=-1,o=e.length;++n<o;)r.remove(e[n])}function Vo(t){return function(){br(this,t)}}function Xo(t){return function(){Mr(this,t)}}function Yo(t,e){return function(){(e.apply(this,arguments)?br:Mr)(this,t)}}function Nr(t,e){var r=_r(t+"");if(arguments.length<2){for(var n=ye(this.node()),o=-1,i=r.length;++o<i;)if(!n.contains(r[o]))return!1;return!0}return this.each((typeof e=="function"?Yo:e?Vo:Xo)(r,e))}function Uo(){this.textContent=""}function Go(t){return function(){this.textContent=t}}function Qo(t){return function(){var e=t.apply(this,arguments);this.textContent=e==null?"":e}}function kr(t){return arguments.length?this.each(t==null?Uo:(typeof t=="function"?Qo:Go)(t)):this.node().textContent}function Ko(){this.innerHTML=""}function Zo(t){return function(){this.innerHTML=t}}function Wo(t){return function(){var e=t.apply(this,arguments);this.innerHTML=e==null?"":e}}function Sr(t){return arguments.length?this.each(t==null?Ko:(typeof t=="function"?Wo:Zo)(t)):this.node().innerHTML}function Jo(){this.nextSibling&&this.parentNode.appendChild(this)}function Ar(){return this.each(Jo)}function jo(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function Ir(){return this.each(jo)}function Er(t){var e=typeof t=="function"?t:Ft(t);return this.select(function(){return this.appendChild(e.apply(this,arguments))})}function ti(){return null}function Or(t,e){var r=typeof t=="function"?t:Ft(t),n=e==null?ti:typeof e=="function"?e:z(e);return this.select(function(){return this.insertBefore(r.apply(this,arguments),n.apply(this,arguments)||null)})}function ei(){var t=this.parentNode;t&&t.removeChild(this)}function Cr(){return this.each(ei)}function ri(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function ni(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function Rr(t){return this.select(t?ni:ri)}function Tr(t){return arguments.length?this.property("__data__",t):this.node().__data__}function oi(t){return function(e){t.call(this,e,this.__data__)}}function ii(t){return t.trim().split(/^|\s+/).map(function(e){var r="",n=e.indexOf(".");return n>=0&&(r=e.slice(n+1),e=e.slice(0,n)),{type:e,name:r}})}function ai(t){return function(){var e=this.__on;if(e){for(var r=0,n=-1,o=e.length,i;r<o;++r)i=e[r],(!t.type||i.type===t.type)&&i.name===t.name?this.removeEventListener(i.type,i.listener,i.options):e[++n]=i;++n?e.length=n:delete this.__on}}}function fi(t,e,r){return function(){var n=this.__on,o,i=oi(e);if(n){for(var a=0,f=n.length;a<f;++a)if((o=n[a]).type===t.type&&o.name===t.name){this.removeEventListener(o.type,o.listener,o.options),this.addEventListener(o.type,o.listener=i,o.options=r),o.value=e;return}}this.addEventListener(t.type,i,r),o={type:t.type,name:t.name,value:e,listener:i,options:r},n?n.push(o):this.__on=[o]}}function $r(t,e,r){var n=ii(t+""),o,i=n.length,a;if(arguments.length<2){var f=this.node().__on;if(f){for(var s=0,u=f.length,l;s<u;++s)for(o=0,l=f[s];o<i;++o)if((a=n[o]).type===l.type&&a.name===l.name)return l.value}return}for(f=e?fi:ai,o=0;o<i;++o)this.each(f(n[o],e,r));return this}function qr(t,e,r){var n=Ht(t),o=n.CustomEvent;typeof o=="function"?o=new o(e,r):(o=n.document.createEvent("Event"),r?(o.initEvent(e,r.bubbles,r.cancelable),o.detail=r.detail):o.initEvent(e,!1,!1)),t.dispatchEvent(o)}function ui(t,e){return function(){return qr(this,t,e)}}function si(t,e){return function(){return qr(this,t,e.apply(this,arguments))}}function Pr(t,e){return this.each((typeof e=="function"?si:ui)(t,e))}function*Lr(){for(var t=this._groups,e=0,r=t.length;e<r;++e)for(var n=t[e],o=0,i=n.length,a;o<i;++o)(a=n[o])&&(yield a)}var gt=[null];function g(t,e){this._groups=t,this._parents=e}function Fr(){return new g([[document.documentElement]],gt)}function li(){return this}g.prototype=Fr.prototype={constructor:g,select:Je,selectAll:je,selectChild:tr,selectChildren:er,filter:rr,data:ir,enter:nr,exit:ar,join:fr,merge:ur,selection:li,order:sr,sort:lr,call:cr,nodes:pr,node:mr,size:hr,empty:dr,each:xr,attr:gr,style:yr,property:wr,classed:Nr,text:kr,html:Sr,raise:Ar,lower:Ir,append:Er,insert:Or,remove:Cr,clone:Rr,datum:Tr,on:$r,dispatch:Pr,[Symbol.iterator]:Lr};var P=Fr;function yt(t){return typeof t=="string"?new g([[document.querySelector(t)]],[document.documentElement]):new g([[t]],gt)}function wt(t){return typeof t=="string"?new g([document.querySelectorAll(t)],[document.documentElement]):new g([mt(t)],gt)}function V(t,e){return t==null||e==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function we(t,e){return t==null||e==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function zt(t){let e,r,n;t.length!==2?(e=V,r=(f,s)=>V(t(f),s),n=(f,s)=>t(f)-s):(e=t===V||t===we?t:ci,r=t,n=t);function o(f,s,u=0,l=f.length){if(u<l){if(e(s,s)!==0)return l;do{let c=u+l>>>1;r(f[c],s)<0?u=c+1:l=c}while(u<l)}return u}function i(f,s,u=0,l=f.length){if(u<l){if(e(s,s)!==0)return l;do{let c=u+l>>>1;r(f[c],s)<=0?u=c+1:l=c}while(u<l)}return u}function a(f,s,u=0,l=f.length){let c=o(f,s,u,l-1);return c>u&&n(f[c-1],s)>-n(f[c],s)?c-1:c}return{left:o,center:a,right:i}}function ci(){return 0}function _e(t){return t===null?NaN:+t}var Dr=zt(V),Br=Dr.right,pi=Dr.left,mi=zt(_e).center,ve=Br;function rt(t,e){let r,n;if(e===void 0)for(let o of t)o!=null&&(r===void 0?o>=o&&(r=n=o):(r>o&&(r=o),n<o&&(n=o)));else{let o=-1;for(let i of t)(i=e(i,++o,t))!=null&&(r===void 0?i>=i&&(r=n=i):(r>i&&(r=i),n<i&&(n=i)))}return[r,n]}var nt=class extends Map{constructor(e,r=xi){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),e!=null)for(let[n,o]of e)this.set(n,o)}get(e){return super.get(Hr(this,e))}has(e){return super.has(Hr(this,e))}set(e,r){return super.set(hi(this,e),r)}delete(e){return super.delete(di(this,e))}};function Hr({_intern:t,_key:e},r){let n=e(r);return t.has(n)?t.get(n):r}function hi({_intern:t,_key:e},r){let n=e(r);return t.has(n)?t.get(n):(t.set(n,r),r)}function di({_intern:t,_key:e},r){let n=e(r);return t.has(n)&&(r=t.get(n),t.delete(n)),r}function xi(t){return t!==null&&typeof t=="object"?t.valueOf():t}var gi=Math.sqrt(50),yi=Math.sqrt(10),wi=Math.sqrt(2);function Vt(t,e,r){let n=(e-t)/Math.max(0,r),o=Math.floor(Math.log10(n)),i=n/Math.pow(10,o),a=i>=gi?10:i>=yi?5:i>=wi?2:1,f,s,u;return o<0?(u=Math.pow(10,-o)/a,f=Math.round(t*u),s=Math.round(e*u),f/u<t&&++f,s/u>e&&--s,u=-u):(u=Math.pow(10,o)*a,f=Math.round(t/u),s=Math.round(e/u),f*u<t&&++f,s*u>e&&--s),s<f&&.5<=r&&r<2?Vt(t,e,r*2):[f,s,u]}function X(t,e,r){if(e=+e,t=+t,r=+r,!(r>0))return[];if(t===e)return[t];let n=e<t,[o,i,a]=n?Vt(e,t,r):Vt(t,e,r);if(!(i>=o))return[];let f=i-o+1,s=new Array(f);if(n)if(a<0)for(let u=0;u<f;++u)s[u]=(i-u)/-a;else for(let u=0;u<f;++u)s[u]=(i-u)*a;else if(a<0)for(let u=0;u<f;++u)s[u]=(o+u)/-a;else for(let u=0;u<f;++u)s[u]=(o+u)*a;return s}function _t(t,e,r){return e=+e,t=+t,r=+r,Vt(t,e,r)[2]}function be(t,e,r){e=+e,t=+t,r=+r;let n=e<t,o=n?_t(e,t,r):_t(t,e,r);return(n?-1:1)*(o<0?1/-o:o)}function ot(t,e){let r;if(e===void 0)for(let n of t)n!=null&&(r<n||r===void 0&&n>=n)&&(r=n);else{let n=-1;for(let o of t)(o=e(o,++n,t))!=null&&(r<o||r===void 0&&o>=o)&&(r=o)}return r}function it(t,e){let r;if(e===void 0)for(let n of t)n!=null&&(r>n||r===void 0&&n>=n)&&(r=n);else{let n=-1;for(let o of t)(o=e(o,++n,t))!=null&&(r>o||r===void 0&&o>=o)&&(r=o)}return r}function Xt(t,e,r){t=+t,e=+e,r=(o=arguments.length)<2?(e=t,t=0,1):o<3?1:+r;for(var n=-1,o=Math.max(0,Math.ceil((e-t)/r))|0,i=new Array(o);++n<o;)i[n]=t+n*r;return i}function D(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t);break}return this}var zr=Symbol("implicit");function Yt(){var t=new nt,e=[],r=[],n=zr;function o(i){let a=t.get(i);if(a===void 0){if(n!==zr)return n;t.set(i,a=e.push(i)-1)}return r[a%r.length]}return o.domain=function(i){if(!arguments.length)return e.slice();e=[],t=new nt;for(let a of i)t.has(a)||t.set(a,e.push(a)-1);return o},o.range=function(i){return arguments.length?(r=Array.from(i),o):r.slice()},o.unknown=function(i){return arguments.length?(n=i,o):n},o.copy=function(){return Yt(e,r).unknown(n)},D.apply(o,arguments),o}function Y(){var t=Yt().unknown(void 0),e=t.domain,r=t.range,n=0,o=1,i,a,f=!1,s=0,u=0,l=.5;delete t.unknown;function c(){var p=e().length,m=o<n,h=m?o:n,d=m?n:o;i=(d-h)/Math.max(1,p-s+u*2),f&&(i=Math.floor(i)),h+=(d-h-i*(p-s))*l,a=i*(1-s),f&&(h=Math.round(h),a=Math.round(a));var y=Xt(p).map(function(v){return h+i*v});return r(m?y.reverse():y)}return t.domain=function(p){return arguments.length?(e(p),c()):e()},t.range=function(p){return arguments.length?([n,o]=p,n=+n,o=+o,c()):[n,o]},t.rangeRound=function(p){return[n,o]=p,n=+n,o=+o,f=!0,c()},t.bandwidth=function(){return a},t.step=function(){return i},t.round=function(p){return arguments.length?(f=!!p,c()):f},t.padding=function(p){return arguments.length?(s=Math.min(1,u=+p),c()):s},t.paddingInner=function(p){return arguments.length?(s=Math.min(1,p),c()):s},t.paddingOuter=function(p){return arguments.length?(u=+p,c()):u},t.align=function(p){return arguments.length?(l=Math.max(0,Math.min(1,p)),c()):l},t.copy=function(){return Y(e(),[n,o]).round(f).paddingInner(s).paddingOuter(u).align(l)},D.apply(c(),arguments)}function Ut(t,e,r){t.prototype=e.prototype=r,r.constructor=t}function Me(t,e){var r=Object.create(t.prototype);for(var n in e)r[n]=e[n];return r}function Mt(){}var vt=.7,Kt=1/vt,at="\\s*([+-]?\\d+)\\s*",bt="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",O="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",_i=/^#([0-9a-f]{3,8})$/,vi=new RegExp(`^rgb\\(${at},${at},${at}\\)$`),bi=new RegExp(`^rgb\\(${O},${O},${O}\\)$`),Mi=new RegExp(`^rgba\\(${at},${at},${at},${bt}\\)$`),Ni=new RegExp(`^rgba\\(${O},${O},${O},${bt}\\)$`),ki=new RegExp(`^hsl\\(${bt},${O},${O}\\)$`),Si=new RegExp(`^hsla\\(${bt},${O},${O},${bt}\\)$`),Vr={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};Ut(Mt,E,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:Xr,formatHex:Xr,formatHex8:Ai,formatHsl:Ii,formatRgb:Yr,toString:Yr});function Xr(){return this.rgb().formatHex()}function Ai(){return this.rgb().formatHex8()}function Ii(){return Wr(this).formatHsl()}function Yr(){return this.rgb().formatRgb()}function E(t){var e,r;return t=(t+"").trim().toLowerCase(),(e=_i.exec(t))?(r=e[1].length,e=parseInt(e[1],16),r===6?Ur(e):r===3?new k(e>>8&15|e>>4&240,e>>4&15|e&240,(e&15)<<4|e&15,1):r===8?Gt(e>>24&255,e>>16&255,e>>8&255,(e&255)/255):r===4?Gt(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|e&240,((e&15)<<4|e&15)/255):null):(e=vi.exec(t))?new k(e[1],e[2],e[3],1):(e=bi.exec(t))?new k(e[1]*255/100,e[2]*255/100,e[3]*255/100,1):(e=Mi.exec(t))?Gt(e[1],e[2],e[3],e[4]):(e=Ni.exec(t))?Gt(e[1]*255/100,e[2]*255/100,e[3]*255/100,e[4]):(e=ki.exec(t))?Kr(e[1],e[2]/100,e[3]/100,1):(e=Si.exec(t))?Kr(e[1],e[2]/100,e[3]/100,e[4]):Vr.hasOwnProperty(t)?Ur(Vr[t]):t==="transparent"?new k(NaN,NaN,NaN,0):null}function Ur(t){return new k(t>>16&255,t>>8&255,t&255,1)}function Gt(t,e,r,n){return n<=0&&(t=e=r=NaN),new k(t,e,r,n)}function Ei(t){return t instanceof Mt||(t=E(t)),t?(t=t.rgb(),new k(t.r,t.g,t.b,t.opacity)):new k}function ft(t,e,r,n){return arguments.length===1?Ei(t):new k(t,e,r,n==null?1:n)}function k(t,e,r,n){this.r=+t,this.g=+e,this.b=+r,this.opacity=+n}Ut(k,ft,Me(Mt,{brighter(t){return t=t==null?Kt:Math.pow(Kt,t),new k(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=t==null?vt:Math.pow(vt,t),new k(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new k(G(this.r),G(this.g),G(this.b),Zt(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:Gr,formatHex:Gr,formatHex8:Oi,formatRgb:Qr,toString:Qr}));function Gr(){return`#${U(this.r)}${U(this.g)}${U(this.b)}`}function Oi(){return`#${U(this.r)}${U(this.g)}${U(this.b)}${U((isNaN(this.opacity)?1:this.opacity)*255)}`}function Qr(){let t=Zt(this.opacity);return`${t===1?"rgb(":"rgba("}${G(this.r)}, ${G(this.g)}, ${G(this.b)}${t===1?")":`, ${t})`}`}function Zt(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function G(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function U(t){return t=G(t),(t<16?"0":"")+t.toString(16)}function Kr(t,e,r,n){return n<=0?t=e=r=NaN:r<=0||r>=1?t=e=NaN:e<=0&&(t=NaN),new I(t,e,r,n)}function Wr(t){if(t instanceof I)return new I(t.h,t.s,t.l,t.opacity);if(t instanceof Mt||(t=E(t)),!t)return new I;if(t instanceof I)return t;t=t.rgb();var e=t.r/255,r=t.g/255,n=t.b/255,o=Math.min(e,r,n),i=Math.max(e,r,n),a=NaN,f=i-o,s=(i+o)/2;return f?(e===i?a=(r-n)/f+(r<n)*6:r===i?a=(n-e)/f+2:a=(e-r)/f+4,f/=s<.5?i+o:2-i-o,a*=60):f=s>0&&s<1?0:a,new I(a,f,s,t.opacity)}function Jr(t,e,r,n){return arguments.length===1?Wr(t):new I(t,e,r,n==null?1:n)}function I(t,e,r,n){this.h=+t,this.s=+e,this.l=+r,this.opacity=+n}Ut(I,Jr,Me(Mt,{brighter(t){return t=t==null?Kt:Math.pow(Kt,t),new I(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=t==null?vt:Math.pow(vt,t),new I(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+(this.h<0)*360,e=isNaN(t)||isNaN(this.s)?0:this.s,r=this.l,n=r+(r<.5?r:1-r)*e,o=2*r-n;return new k(Ne(t>=240?t-240:t+120,o,n),Ne(t,o,n),Ne(t<120?t+240:t-120,o,n),this.opacity)},clamp(){return new I(Zr(this.h),Qt(this.s),Qt(this.l),Zt(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(){let t=Zt(this.opacity);return`${t===1?"hsl(":"hsla("}${Zr(this.h)}, ${Qt(this.s)*100}%, ${Qt(this.l)*100}%${t===1?")":`, ${t})`}`}}));function Zr(t){return t=(t||0)%360,t<0?t+360:t}function Qt(t){return Math.max(0,Math.min(1,t||0))}function Ne(t,e,r){return(t<60?e+(r-e)*t/60:t<180?r:t<240?e+(r-e)*(240-t)/60:e)*255}function ke(t,e,r,n,o){var i=t*t,a=i*t;return((1-3*t+3*i-a)*e+(4-6*i+3*a)*r+(1+3*t+3*i-3*a)*n+a*o)/6}function jr(t){var e=t.length-1;return function(r){var n=r<=0?r=0:r>=1?(r=1,e-1):Math.floor(r*e),o=t[n],i=t[n+1],a=n>0?t[n-1]:2*o-i,f=n<e-1?t[n+2]:2*i-o;return ke((r-n/e)*e,a,o,i,f)}}function tn(t){var e=t.length;return function(r){var n=Math.floor(((r%=1)<0?++r:r)*e),o=t[(n+e-1)%e],i=t[n%e],a=t[(n+1)%e],f=t[(n+2)%e];return ke((r-n/e)*e,o,i,a,f)}}var Nt=t=>()=>t;function Ci(t,e){return function(r){return t+r*e}}function Ri(t,e,r){return t=Math.pow(t,r),e=Math.pow(e,r)-t,r=1/r,function(n){return Math.pow(t+n*e,r)}}function en(t){return(t=+t)==1?Wt:function(e,r){return r-e?Ri(e,r,t):Nt(isNaN(e)?r:e)}}function Wt(t,e){var r=e-t;return r?Ci(t,r):Nt(isNaN(t)?e:t)}var Q=function t(e){var r=en(e);function n(o,i){var a=r((o=ft(o)).r,(i=ft(i)).r),f=r(o.g,i.g),s=r(o.b,i.b),u=Wt(o.opacity,i.opacity);return function(l){return o.r=a(l),o.g=f(l),o.b=s(l),o.opacity=u(l),o+""}}return n.gamma=t,n}(1);function rn(t){return function(e){var r=e.length,n=new Array(r),o=new Array(r),i=new Array(r),a,f;for(a=0;a<r;++a)f=ft(e[a]),n[a]=f.r||0,o[a]=f.g||0,i[a]=f.b||0;return n=t(n),o=t(o),i=t(i),f.opacity=1,function(s){return f.r=n(s),f.g=o(s),f.b=i(s),f+""}}}var Ti=rn(jr),$i=rn(tn);function nn(t,e){e||(e=[]);var r=t?Math.min(e.length,t.length):0,n=e.slice(),o;return function(i){for(o=0;o<r;++o)n[o]=t[o]*(1-i)+e[o]*i;return n}}function on(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}function an(t,e){var r=e?e.length:0,n=t?Math.min(r,t.length):0,o=new Array(n),i=new Array(r),a;for(a=0;a<n;++a)o[a]=K(t[a],e[a]);for(;a<r;++a)i[a]=e[a];return function(f){for(a=0;a<n;++a)i[a]=o[a](f);return i}}function fn(t,e){var r=new Date;return t=+t,e=+e,function(n){return r.setTime(t*(1-n)+e*n),r}}function w(t,e){return t=+t,e=+e,function(r){return t*(1-r)+e*r}}function un(t,e){var r={},n={},o;(t===null||typeof t!="object")&&(t={}),(e===null||typeof e!="object")&&(e={});for(o in e)o in t?r[o]=K(t[o],e[o]):n[o]=e[o];return function(i){for(o in r)n[o]=r[o](i);return n}}var Ae=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Se=new RegExp(Ae.source,"g");function qi(t){return function(){return t}}function Pi(t){return function(e){return t(e)+""}}function kt(t,e){var r=Ae.lastIndex=Se.lastIndex=0,n,o,i,a=-1,f=[],s=[];for(t=t+"",e=e+"";(n=Ae.exec(t))&&(o=Se.exec(e));)(i=o.index)>r&&(i=e.slice(r,i),f[a]?f[a]+=i:f[++a]=i),(n=n[0])===(o=o[0])?f[a]?f[a]+=o:f[++a]=o:(f[++a]=null,s.push({i:a,x:w(n,o)})),r=Se.lastIndex;return r<e.length&&(i=e.slice(r),f[a]?f[a]+=i:f[++a]=i),f.length<2?s[0]?Pi(s[0].x):qi(e):(e=s.length,function(u){for(var l=0,c;l<e;++l)f[(c=s[l]).i]=c.x(u);return f.join("")})}function K(t,e){var r=typeof e,n;return e==null||r==="boolean"?Nt(e):(r==="number"?w:r==="string"?(n=E(e))?(e=n,Q):kt:e instanceof E?Q:e instanceof Date?fn:on(e)?nn:Array.isArray(e)?an:typeof e.valueOf!="function"&&typeof e.toString!="function"||isNaN(e)?un:w)(t,e)}function Ie(t,e){return t=+t,e=+e,function(r){return Math.round(t*(1-r)+e*r)}}var sn=180/Math.PI,Jt={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Ee(t,e,r,n,o,i){var a,f,s;return(a=Math.sqrt(t*t+e*e))&&(t/=a,e/=a),(s=t*r+e*n)&&(r-=t*s,n-=e*s),(f=Math.sqrt(r*r+n*n))&&(r/=f,n/=f,s/=f),t*n<e*r&&(t=-t,e=-e,s=-s,a=-a),{translateX:o,translateY:i,rotate:Math.atan2(e,t)*sn,skewX:Math.atan(s)*sn,scaleX:a,scaleY:f}}var jt;function ln(t){let e=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(t+"");return e.isIdentity?Jt:Ee(e.a,e.b,e.c,e.d,e.e,e.f)}function cn(t){return t==null?Jt:(jt||(jt=document.createElementNS("http://www.w3.org/2000/svg","g")),jt.setAttribute("transform",t),(t=jt.transform.baseVal.consolidate())?(t=t.matrix,Ee(t.a,t.b,t.c,t.d,t.e,t.f)):Jt)}function pn(t,e,r,n){function o(u){return u.length?u.pop()+" ":""}function i(u,l,c,p,m,h){if(u!==c||l!==p){var d=m.push("translate(",null,e,null,r);h.push({i:d-4,x:w(u,c)},{i:d-2,x:w(l,p)})}else(c||p)&&m.push("translate("+c+e+p+r)}function a(u,l,c,p){u!==l?(u-l>180?l+=360:l-u>180&&(u+=360),p.push({i:c.push(o(c)+"rotate(",null,n)-2,x:w(u,l)})):l&&c.push(o(c)+"rotate("+l+n)}function f(u,l,c,p){u!==l?p.push({i:c.push(o(c)+"skewX(",null,n)-2,x:w(u,l)}):l&&c.push(o(c)+"skewX("+l+n)}function s(u,l,c,p,m,h){if(u!==c||l!==p){var d=m.push(o(m)+"scale(",null,",",null,")");h.push({i:d-4,x:w(u,c)},{i:d-2,x:w(l,p)})}else(c!==1||p!==1)&&m.push(o(m)+"scale("+c+","+p+")")}return function(u,l){var c=[],p=[];return u=t(u),l=t(l),i(u.translateX,u.translateY,l.translateX,l.translateY,c,p),a(u.rotate,l.rotate,c,p),f(u.skewX,l.skewX,c,p),s(u.scaleX,u.scaleY,l.scaleX,l.scaleY,c,p),u=l=null,function(m){for(var h=-1,d=p.length,y;++h<d;)c[(y=p[h]).i]=y.x(m);return c.join("")}}}var Oe=pn(ln,"px, ","px)","deg)"),Ce=pn(cn,", ",")",")");function Re(t){return function(){return t}}function Te(t){return+t}var mn=[0,1];function ut(t){return t}function $e(t,e){return(e-=t=+t)?function(r){return(r-t)/e}:Re(isNaN(e)?NaN:.5)}function Li(t,e){var r;return t>e&&(r=t,t=e,e=r),function(n){return Math.max(t,Math.min(e,n))}}function Fi(t,e,r){var n=t[0],o=t[1],i=e[0],a=e[1];return o<n?(n=$e(o,n),i=r(a,i)):(n=$e(n,o),i=r(i,a)),function(f){return i(n(f))}}function Di(t,e,r){var n=Math.min(t.length,e.length)-1,o=new Array(n),i=new Array(n),a=-1;for(t[n]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());++a<n;)o[a]=$e(t[a],t[a+1]),i[a]=r(e[a],e[a+1]);return function(f){var s=ve(t,f,1,n)-1;return i[s](o[s](f))}}function te(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())}function qe(){var t=mn,e=mn,r=K,n,o,i,a=ut,f,s,u;function l(){var p=Math.min(t.length,e.length);return a!==ut&&(a=Li(t[0],t[p-1])),f=p>2?Di:Fi,s=u=null,c}function c(p){return p==null||isNaN(p=+p)?i:(s||(s=f(t.map(n),e,r)))(n(a(p)))}return c.invert=function(p){return a(o((u||(u=f(e,t.map(n),w)))(p)))},c.domain=function(p){return arguments.length?(t=Array.from(p,Te),l()):t.slice()},c.range=function(p){return arguments.length?(e=Array.from(p),l()):e.slice()},c.rangeRound=function(p){return e=Array.from(p),r=Ie,l()},c.clamp=function(p){return arguments.length?(a=p?!0:ut,l()):a!==ut},c.interpolate=function(p){return arguments.length?(r=p,l()):r},c.unknown=function(p){return arguments.length?(i=p,c):i},function(p,m){return n=p,o=m,l()}}function Pe(){return qe()(ut,ut)}function hn(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)}function Z(t,e){if((r=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var r,n=t.slice(0,r);return[n.length>1?n[0]+n.slice(2):n,+t.slice(r+1)]}function C(t){return t=Z(Math.abs(t)),t?t[1]:NaN}function dn(t,e){return function(r,n){for(var o=r.length,i=[],a=0,f=t[0],s=0;o>0&&f>0&&(s+f+1>n&&(f=Math.max(1,n-s)),i.push(r.substring(o-=f,o+f)),!((s+=f+1)>n));)f=t[a=(a+1)%t.length];return i.reverse().join(e)}}function xn(t){return function(e){return e.replace(/[0-9]/g,function(r){return t[+r]})}}var Bi=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function R(t){if(!(e=Bi.exec(t)))throw new Error("invalid format: "+t);var e;return new ee({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}R.prototype=ee.prototype;function ee(t){this.fill=t.fill===void 0?" ":t.fill+"",this.align=t.align===void 0?">":t.align+"",this.sign=t.sign===void 0?"-":t.sign+"",this.symbol=t.symbol===void 0?"":t.symbol+"",this.zero=!!t.zero,this.width=t.width===void 0?void 0:+t.width,this.comma=!!t.comma,this.precision=t.precision===void 0?void 0:+t.precision,this.trim=!!t.trim,this.type=t.type===void 0?"":t.type+""}ee.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 gn(t){t:for(var e=t.length,r=1,n=-1,o;r<e;++r)switch(t[r]){case".":n=o=r;break;case"0":n===0&&(n=r),o=r;break;default:if(!+t[r])break t;n>0&&(n=0);break}return n>0?t.slice(0,n)+t.slice(o+1):t}var Le;function yn(t,e){var r=Z(t,e);if(!r)return t+"";var n=r[0],o=r[1],i=o-(Le=Math.max(-8,Math.min(8,Math.floor(o/3)))*3)+1,a=n.length;return i===a?n:i>a?n+new Array(i-a+1).join("0"):i>0?n.slice(0,i)+"."+n.slice(i):"0."+new Array(1-i).join("0")+Z(t,Math.max(0,e+i-1))[0]}function Fe(t,e){var r=Z(t,e);if(!r)return t+"";var n=r[0],o=r[1];return o<0?"0."+new Array(-o).join("0")+n:n.length>o+1?n.slice(0,o+1)+"."+n.slice(o+1):n+new Array(o-n.length+2).join("0")}var De={"%":(t,e)=>(t*100).toFixed(e),b:t=>Math.round(t).toString(2),c:t=>t+"",d:hn,e:(t,e)=>t.toExponential(e),f:(t,e)=>t.toFixed(e),g:(t,e)=>t.toPrecision(e),o:t=>Math.round(t).toString(8),p:(t,e)=>Fe(t*100,e),r:Fe,s:yn,X:t=>Math.round(t).toString(16).toUpperCase(),x:t=>Math.round(t).toString(16)};function Be(t){return t}var wn=Array.prototype.map,_n=["y","z","a","f","p","n","\xB5","m","","k","M","G","T","P","E","Z","Y"];function vn(t){var e=t.grouping===void 0||t.thousands===void 0?Be:dn(wn.call(t.grouping,Number),t.thousands+""),r=t.currency===void 0?"":t.currency[0]+"",n=t.currency===void 0?"":t.currency[1]+"",o=t.decimal===void 0?".":t.decimal+"",i=t.numerals===void 0?Be:xn(wn.call(t.numerals,String)),a=t.percent===void 0?"%":t.percent+"",f=t.minus===void 0?"\u2212":t.minus+"",s=t.nan===void 0?"NaN":t.nan+"";function u(c){c=R(c);var p=c.fill,m=c.align,h=c.sign,d=c.symbol,y=c.zero,v=c.width,T=c.comma,S=c.precision,pt=c.trim,M=c.type;M==="n"?(T=!0,M="g"):De[M]||(S===void 0&&(S=12),pt=!0,M="g"),(y||p==="0"&&m==="=")&&(y=!0,p="0",m="=");var io=d==="$"?r:d==="#"&&/[boxX]/.test(M)?"0"+M.toLowerCase():"",ao=d==="$"?n:/[%p]/.test(M)?a:"",Ke=De[M],fo=/[defgprs%]/.test(M);S=S===void 0?6:/[gprs]/.test(M)?Math.max(1,Math.min(21,S)):Math.max(0,Math.min(20,S));function Ze(x){var H=io,A=ao,et,We,$t;if(M==="c")A=Ke(x)+A,x="";else{x=+x;var qt=x<0||1/x<0;if(x=isNaN(x)?s:Ke(Math.abs(x),S),pt&&(x=gn(x)),qt&&+x==0&&h!=="+"&&(qt=!1),H=(qt?h==="("?h:f:h==="-"||h==="("?"":h)+H,A=(M==="s"?_n[8+Le/3]:"")+A+(qt&&h==="("?")":""),fo){for(et=-1,We=x.length;++et<We;)if($t=x.charCodeAt(et),48>$t||$t>57){A=($t===46?o+x.slice(et+1):x.slice(et))+A,x=x.slice(0,et);break}}}T&&!y&&(x=e(x,1/0));var Pt=H.length+x.length+A.length,$=Pt<v?new Array(v-Pt+1).join(p):"";switch(T&&y&&(x=e($+x,$.length?v-A.length:1/0),$=""),m){case"<":x=H+x+A+$;break;case"=":x=H+$+x+A;break;case"^":x=$.slice(0,Pt=$.length>>1)+H+x+A+$.slice(Pt);break;default:x=$+H+x+A;break}return i(x)}return Ze.toString=function(){return c+""},Ze}function l(c,p){var m=u((c=R(c),c.type="f",c)),h=Math.max(-8,Math.min(8,Math.floor(C(p)/3)))*3,d=Math.pow(10,-h),y=_n[8+h/3];return function(v){return m(d*v)+y}}return{format:u,formatPrefix:l}}var re,st,ne;He({thousands:",",grouping:[3],currency:["$",""]});function He(t){return re=vn(t),st=re.format,ne=re.formatPrefix,re}function ze(t){return Math.max(0,-C(Math.abs(t)))}function Ve(t,e){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(C(e)/3)))*3-C(Math.abs(t)))}function Xe(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,C(e)-C(t))+1}function Ye(t,e,r,n){var o=be(t,e,r),i;switch(n=R(n==null?",f":n),n.type){case"s":{var a=Math.max(Math.abs(t),Math.abs(e));return n.precision==null&&!isNaN(i=Ve(o,a))&&(n.precision=i),ne(n,a)}case"":case"e":case"g":case"p":case"r":{n.precision==null&&!isNaN(i=Xe(o,Math.max(Math.abs(t),Math.abs(e))))&&(n.precision=i-(n.type==="e"));break}case"f":case"%":{n.precision==null&&!isNaN(i=ze(o))&&(n.precision=i-(n.type==="%")*2);break}}return st(n)}function Hi(t){var e=t.domain;return t.ticks=function(r){var n=e();return X(n[0],n[n.length-1],r==null?10:r)},t.tickFormat=function(r,n){var o=e();return Ye(o[0],o[o.length-1],r==null?10:r,n)},t.nice=function(r){r==null&&(r=10);var n=e(),o=0,i=n.length-1,a=n[o],f=n[i],s,u,l=10;for(f<a&&(u=a,a=f,f=u,u=o,o=i,i=u);l-- >0;){if(u=_t(a,f,r),u===s)return n[o]=a,n[i]=f,e(n);if(u>0)a=Math.floor(a/u)*u,f=Math.ceil(f/u)*u;else if(u<0)a=Math.ceil(a*u)/u,f=Math.floor(f*u)/u;else break;s=u}return t},t}function W(){var t=Pe();return t.copy=function(){return te(t,W())},D.apply(t,arguments),Hi(t)}function Ue(t,e){t=t.slice();var r=0,n=t.length-1,o=t[r],i=t[n],a;return i<o&&(a=r,r=n,n=a,a=o,o=i,i=a),t[r]=e.floor(o),t[n]=e.ceil(i),t}function bn(t){return Math.log(t)}function Mn(t){return Math.exp(t)}function zi(t){return-Math.log(-t)}function Vi(t){return-Math.exp(-t)}function Xi(t){return isFinite(t)?+("1e"+t):t<0?0:t}function Yi(t){return t===10?Xi:t===Math.E?Math.exp:e=>Math.pow(t,e)}function Ui(t){return t===Math.E?Math.log:t===10&&Math.log10||t===2&&Math.log2||(t=Math.log(t),e=>Math.log(e)/t)}function Nn(t){return(e,r)=>-t(-e,r)}function Gi(t){let e=t(bn,Mn),r=e.domain,n=10,o,i;function a(){return o=Ui(n),i=Yi(n),r()[0]<0?(o=Nn(o),i=Nn(i),t(zi,Vi)):t(bn,Mn),e}return e.base=function(f){return arguments.length?(n=+f,a()):n},e.domain=function(f){return arguments.length?(r(f),a()):r()},e.ticks=f=>{let s=r(),u=s[0],l=s[s.length-1],c=l<u;c&&([u,l]=[l,u]);let p=o(u),m=o(l),h,d,y=f==null?10:+f,v=[];if(!(n%1)&&m-p<y){if(p=Math.floor(p),m=Math.ceil(m),u>0){for(;p<=m;++p)for(h=1;h<n;++h)if(d=p<0?h/i(-p):h*i(p),!(d<u)){if(d>l)break;v.push(d)}}else for(;p<=m;++p)for(h=n-1;h>=1;--h)if(d=p>0?h/i(-p):h*i(p),!(d<u)){if(d>l)break;v.push(d)}v.length*2<y&&(v=X(u,l,y))}else v=X(p,m,Math.min(m-p,y)).map(i);return c?v.reverse():v},e.tickFormat=(f,s)=>{if(f==null&&(f=10),s==null&&(s=n===10?"s":","),typeof s!="function"&&(!(n%1)&&(s=R(s)).precision==null&&(s.trim=!0),s=st(s)),f===1/0)return s;let u=Math.max(1,n*f/e.ticks().length);return l=>{let c=l/i(Math.round(o(l)));return c*n<n-.5&&(c*=n),c<=u?s(l):""}},e.nice=()=>r(Ue(r(),{floor:f=>i(Math.floor(o(f))),ceil:f=>i(Math.ceil(o(f)))})),e}function J(){let t=Gi(qe()).domain([1,10]);return t.copy=()=>te(t,J()).base(t.base()),D.apply(t,arguments),t}var Qi={value:()=>{}};function Sn(){for(var t=0,e=arguments.length,r={},n;t<e;++t){if(!(n=arguments[t]+"")||n in r||/[\s.]/.test(n))throw new Error("illegal type: "+n);r[n]=[]}return new oe(r)}function oe(t){this._=t}function Ki(t,e){return t.trim().split(/^|\s+/).map(function(r){var n="",o=r.indexOf(".");if(o>=0&&(n=r.slice(o+1),r=r.slice(0,o)),r&&!e.hasOwnProperty(r))throw new Error("unknown type: "+r);return{type:r,name:n}})}oe.prototype=Sn.prototype={constructor:oe,on:function(t,e){var r=this._,n=Ki(t+"",r),o,i=-1,a=n.length;if(arguments.length<2){for(;++i<a;)if((o=(t=n[i]).type)&&(o=Zi(r[o],t.name)))return o;return}if(e!=null&&typeof e!="function")throw new Error("invalid callback: "+e);for(;++i<a;)if(o=(t=n[i]).type)r[o]=kn(r[o],t.name,e);else if(e==null)for(o in r)r[o]=kn(r[o],t.name,null);return this},copy:function(){var t={},e=this._;for(var r in e)t[r]=e[r].slice();return new oe(t)},call:function(t,e){if((o=arguments.length-2)>0)for(var r=new Array(o),n=0,o,i;n<o;++n)r[n]=arguments[n+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(i=this._[t],n=0,o=i.length;n<o;++n)i[n].value.apply(e,r)},apply:function(t,e,r){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var n=this._[t],o=0,i=n.length;o<i;++o)n[o].value.apply(e,r)}};function Zi(t,e){for(var r=0,n=t.length,o;r<n;++r)if((o=t[r]).name===e)return o.value}function kn(t,e,r){for(var n=0,o=t.length;n<o;++n)if(t[n].name===e){t[n]=Qi,t=t.slice(0,n).concat(t.slice(n+1));break}return r!=null&&t.push({name:e,value:r}),t}var Ge=Sn;var lt=0,At=0,St=0,In=1e3,ie,It,ae=0,j=0,fe=0,Et=typeof performance=="object"&&performance.now?performance:Date,En=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function Ct(){return j||(En(Wi),j=Et.now()+fe)}function Wi(){j=0}function Ot(){this._call=this._time=this._next=null}Ot.prototype=ue.prototype={constructor:Ot,restart:function(t,e,r){if(typeof t!="function")throw new TypeError("callback is not a function");r=(r==null?Ct():+r)+(e==null?0:+e),!this._next&&It!==this&&(It?It._next=this:ie=this,It=this),this._call=t,this._time=r,Qe()},stop:function(){this._call&&(this._call=null,this._time=1/0,Qe())}};function ue(t,e,r){var n=new Ot;return n.restart(t,e,r),n}function On(){Ct(),++lt;for(var t=ie,e;t;)(e=j-t._time)>=0&&t._call.call(void 0,e),t=t._next;--lt}function An(){j=(ae=Et.now())+fe,lt=At=0;try{On()}finally{lt=0,ji(),j=0}}function Ji(){var t=Et.now(),e=t-ae;e>In&&(fe-=e,ae=t)}function ji(){for(var t,e=ie,r,n=1/0;e;)e._call?(n>e._time&&(n=e._time),t=e,e=e._next):(r=e._next,e._next=null,e=t?t._next=r:ie=r);It=t,Qe(n)}function Qe(t){if(!lt){At&&(At=clearTimeout(At));var e=t-j;e>24?(t<1/0&&(At=setTimeout(An,t-Et.now()-fe)),St&&(St=clearInterval(St))):(St||(ae=Et.now(),St=setInterval(Ji,In)),lt=1,En(An))}}function se(t,e,r){var n=new Ot;return e=e==null?0:+e,n.restart(o=>{n.stop(),t(o+e)},e,r),n}var ta=Ge("start","end","cancel","interrupt"),ea=[],Tn=0,Cn=1,ce=2,le=3,Rn=4,pe=5,Rt=6;function B(t,e,r,n,o,i){var a=t.__transition;if(!a)t.__transition={};else if(r in a)return;ra(t,r,{name:e,index:n,group:o,on:ta,tween:ea,time:i.time,delay:i.delay,duration:i.duration,ease:i.ease,timer:null,state:Tn})}function Tt(t,e){var r=_(t,e);if(r.state>Tn)throw new Error("too late; already scheduled");return r}function b(t,e){var r=_(t,e);if(r.state>le)throw new Error("too late; already running");return r}function _(t,e){var r=t.__transition;if(!r||!(r=r[e]))throw new Error("transition not found");return r}function ra(t,e,r){var n=t.__transition,o;n[e]=r,r.timer=ue(i,0,r.time);function i(u){r.state=Cn,r.timer.restart(a,r.delay,r.time),r.delay<=u&&a(u-r.delay)}function a(u){var l,c,p,m;if(r.state!==Cn)return s();for(l in n)if(m=n[l],m.name===r.name){if(m.state===le)return se(a);m.state===Rn?(m.state=Rt,m.timer.stop(),m.on.call("interrupt",t,t.__data__,m.index,m.group),delete n[l]):+l<e&&(m.state=Rt,m.timer.stop(),m.on.call("cancel",t,t.__data__,m.index,m.group),delete n[l])}if(se(function(){r.state===le&&(r.state=Rn,r.timer.restart(f,r.delay,r.time),f(u))}),r.state=ce,r.on.call("start",t,t.__data__,r.index,r.group),r.state===ce){for(r.state=le,o=new Array(p=r.tween.length),l=0,c=-1;l<p;++l)(m=r.tween[l].value.call(t,t.__data__,r.index,r.group))&&(o[++c]=m);o.length=c+1}}function f(u){for(var l=u<r.duration?r.ease.call(null,u/r.duration):(r.timer.restart(s),r.state=pe,1),c=-1,p=o.length;++c<p;)o[c].call(t,l);r.state===pe&&(r.on.call("end",t,t.__data__,r.index,r.group),s())}function s(){r.state=Rt,r.timer.stop(),delete n[e];for(var u in n)return;delete t.__transition}}function $n(t,e){var r=t.__transition,n,o,i=!0,a;if(r){e=e==null?null:e+"";for(a in r){if((n=r[a]).name!==e){i=!1;continue}o=n.state>ce&&n.state<pe,n.state=Rt,n.timer.stop(),n.on.call(o?"interrupt":"cancel",t,t.__data__,n.index,n.group),delete r[a]}i&&delete t.__transition}}function qn(t){return this.each(function(){$n(this,t)})}function na(t,e){var r,n;return function(){var o=b(this,t),i=o.tween;if(i!==r){n=r=i;for(var a=0,f=n.length;a<f;++a)if(n[a].name===e){n=n.slice(),n.splice(a,1);break}}o.tween=n}}function oa(t,e,r){var n,o;if(typeof r!="function")throw new Error;return function(){var i=b(this,t),a=i.tween;if(a!==n){o=(n=a).slice();for(var f={name:e,value:r},s=0,u=o.length;s<u;++s)if(o[s].name===e){o[s]=f;break}s===u&&o.push(f)}i.tween=o}}function Pn(t,e){var r=this._id;if(t+="",arguments.length<2){for(var n=_(this.node(),r).tween,o=0,i=n.length,a;o<i;++o)if((a=n[o]).name===t)return a.value;return null}return this.each((e==null?na:oa)(r,t,e))}function ct(t,e,r){var n=t._id;return t.each(function(){var o=b(this,n);(o.value||(o.value={}))[e]=r.apply(this,arguments)}),function(o){return _(o,n).value[e]}}function me(t,e){var r;return(typeof e=="number"?w:e instanceof E?Q:(r=E(e))?(e=r,Q):kt)(t,e)}function ia(t){return function(){this.removeAttribute(t)}}function aa(t){return function(){this.removeAttributeNS(t.space,t.local)}}function fa(t,e,r){var n,o=r+"",i;return function(){var a=this.getAttribute(t);return a===o?null:a===n?i:i=e(n=a,r)}}function ua(t,e,r){var n,o=r+"",i;return function(){var a=this.getAttributeNS(t.space,t.local);return a===o?null:a===n?i:i=e(n=a,r)}}function sa(t,e,r){var n,o,i;return function(){var a,f=r(this),s;return f==null?void this.removeAttribute(t):(a=this.getAttribute(t),s=f+"",a===s?null:a===n&&s===o?i:(o=s,i=e(n=a,f)))}}function la(t,e,r){var n,o,i;return function(){var a,f=r(this),s;return f==null?void this.removeAttributeNS(t.space,t.local):(a=this.getAttributeNS(t.space,t.local),s=f+"",a===s?null:a===n&&s===o?i:(o=s,i=e(n=a,f)))}}function Ln(t,e){var r=q(t),n=r==="transform"?Ce:me;return this.attrTween(t,typeof e=="function"?(r.local?la:sa)(r,n,ct(this,"attr."+t,e)):e==null?(r.local?aa:ia)(r):(r.local?ua:fa)(r,n,e))}function ca(t,e){return function(r){this.setAttribute(t,e.call(this,r))}}function pa(t,e){return function(r){this.setAttributeNS(t.space,t.local,e.call(this,r))}}function ma(t,e){var r,n;function o(){var i=e.apply(this,arguments);return i!==n&&(r=(n=i)&&pa(t,i)),r}return o._value=e,o}function ha(t,e){var r,n;function o(){var i=e.apply(this,arguments);return i!==n&&(r=(n=i)&&ca(t,i)),r}return o._value=e,o}function Fn(t,e){var r="attr."+t;if(arguments.length<2)return(r=this.tween(r))&&r._value;if(e==null)return this.tween(r,null);if(typeof e!="function")throw new Error;var n=q(t);return this.tween(r,(n.local?ma:ha)(n,e))}function da(t,e){return function(){Tt(this,t).delay=+e.apply(this,arguments)}}function xa(t,e){return e=+e,function(){Tt(this,t).delay=e}}function Dn(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?da:xa)(e,t)):_(this.node(),e).delay}function ga(t,e){return function(){b(this,t).duration=+e.apply(this,arguments)}}function ya(t,e){return e=+e,function(){b(this,t).duration=e}}function Bn(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?ga:ya)(e,t)):_(this.node(),e).duration}function wa(t,e){if(typeof e!="function")throw new Error;return function(){b(this,t).ease=e}}function Hn(t){var e=this._id;return arguments.length?this.each(wa(e,t)):_(this.node(),e).ease}function _a(t,e){return function(){var r=e.apply(this,arguments);if(typeof r!="function")throw new Error;b(this,t).ease=r}}function zn(t){if(typeof t!="function")throw new Error;return this.each(_a(this._id,t))}function Vn(t){typeof t!="function"&&(t=dt(t));for(var e=this._groups,r=e.length,n=new Array(r),o=0;o<r;++o)for(var i=e[o],a=i.length,f=n[o]=[],s,u=0;u<a;++u)(s=i[u])&&t.call(s,s.__data__,u,i)&&f.push(s);return new N(n,this._parents,this._name,this._id)}function Xn(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,r=t._groups,n=e.length,o=r.length,i=Math.min(n,o),a=new Array(n),f=0;f<i;++f)for(var s=e[f],u=r[f],l=s.length,c=a[f]=new Array(l),p,m=0;m<l;++m)(p=s[m]||u[m])&&(c[m]=p);for(;f<n;++f)a[f]=e[f];return new N(a,this._parents,this._name,this._id)}function va(t){return(t+"").trim().split(/^|\s+/).every(function(e){var r=e.indexOf(".");return r>=0&&(e=e.slice(0,r)),!e||e==="start"})}function ba(t,e,r){var n,o,i=va(e)?Tt:b;return function(){var a=i(this,t),f=a.on;f!==n&&(o=(n=f).copy()).on(e,r),a.on=o}}function Yn(t,e){var r=this._id;return arguments.length<2?_(this.node(),r).on.on(t):this.each(ba(r,t,e))}function Ma(t){return function(){var e=this.parentNode;for(var r in this.__transition)if(+r!==t)return;e&&e.removeChild(this)}}function Un(){return this.on("end.remove",Ma(this._id))}function Gn(t){var e=this._name,r=this._id;typeof t!="function"&&(t=z(t));for(var n=this._groups,o=n.length,i=new Array(o),a=0;a<o;++a)for(var f=n[a],s=f.length,u=i[a]=new Array(s),l,c,p=0;p<s;++p)(l=f[p])&&(c=t.call(l,l.__data__,p,f))&&("__data__"in l&&(c.__data__=l.__data__),u[p]=c,B(u[p],e,r,p,u,_(l,r)));return new N(i,this._parents,e,r)}function Qn(t){var e=this._name,r=this._id;typeof t!="function"&&(t=ht(t));for(var n=this._groups,o=n.length,i=[],a=[],f=0;f<o;++f)for(var s=n[f],u=s.length,l,c=0;c<u;++c)if(l=s[c]){for(var p=t.call(l,l.__data__,c,s),m,h=_(l,r),d=0,y=p.length;d<y;++d)(m=p[d])&&B(m,e,r,d,p,h);i.push(p),a.push(l)}return new N(i,a,e,r)}var Na=P.prototype.constructor;function Kn(){return new Na(this._groups,this._parents)}function ka(t,e){var r,n,o;return function(){var i=F(this,t),a=(this.style.removeProperty(t),F(this,t));return i===a?null:i===r&&a===n?o:o=e(r=i,n=a)}}function Zn(t){return function(){this.style.removeProperty(t)}}function Sa(t,e,r){var n,o=r+"",i;return function(){var a=F(this,t);return a===o?null:a===n?i:i=e(n=a,r)}}function Aa(t,e,r){var n,o,i;return function(){var a=F(this,t),f=r(this),s=f+"";return f==null&&(s=f=(this.style.removeProperty(t),F(this,t))),a===s?null:a===n&&s===o?i:(o=s,i=e(n=a,f))}}function Ia(t,e){var r,n,o,i="style."+e,a="end."+i,f;return function(){var s=b(this,t),u=s.on,l=s.value[i]==null?f||(f=Zn(e)):void 0;(u!==r||o!==l)&&(n=(r=u).copy()).on(a,o=l),s.on=n}}function Wn(t,e,r){var n=(t+="")=="transform"?Oe:me;return e==null?this.styleTween(t,ka(t,n)).on("end.style."+t,Zn(t)):typeof e=="function"?this.styleTween(t,Aa(t,n,ct(this,"style."+t,e))).each(Ia(this._id,t)):this.styleTween(t,Sa(t,n,e),r).on("end.style."+t,null)}function Ea(t,e,r){return function(n){this.style.setProperty(t,e.call(this,n),r)}}function Oa(t,e,r){var n,o;function i(){var a=e.apply(this,arguments);return a!==o&&(n=(o=a)&&Ea(t,a,r)),n}return i._value=e,i}function Jn(t,e,r){var n="style."+(t+="");if(arguments.length<2)return(n=this.tween(n))&&n._value;if(e==null)return this.tween(n,null);if(typeof e!="function")throw new Error;return this.tween(n,Oa(t,e,r==null?"":r))}function Ca(t){return function(){this.textContent=t}}function Ra(t){return function(){var e=t(this);this.textContent=e==null?"":e}}function jn(t){return this.tween("text",typeof t=="function"?Ra(ct(this,"text",t)):Ca(t==null?"":t+""))}function Ta(t){return function(e){this.textContent=t.call(this,e)}}function $a(t){var e,r;function n(){var o=t.apply(this,arguments);return o!==r&&(e=(r=o)&&Ta(o)),e}return n._value=t,n}function to(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(t==null)return this.tween(e,null);if(typeof t!="function")throw new Error;return this.tween(e,$a(t))}function eo(){for(var t=this._name,e=this._id,r=he(),n=this._groups,o=n.length,i=0;i<o;++i)for(var a=n[i],f=a.length,s,u=0;u<f;++u)if(s=a[u]){var l=_(s,e);B(s,t,r,u,a,{time:l.time+l.delay+l.duration,delay:0,duration:l.duration,ease:l.ease})}return new N(n,this._parents,t,r)}function ro(){var t,e,r=this,n=r._id,o=r.size();return new Promise(function(i,a){var f={value:a},s={value:function(){--o===0&&i()}};r.each(function(){var u=b(this,n),l=u.on;l!==t&&(e=(t=l).copy(),e._.cancel.push(f),e._.interrupt.push(f),e._.end.push(s)),u.on=e}),o===0&&i()})}var qa=0;function N(t,e,r,n){this._groups=t,this._parents=e,this._name=r,this._id=n}function tt(t){return P().transition(t)}function he(){return++qa}var L=P.prototype;N.prototype=tt.prototype={constructor:N,select:Gn,selectAll:Qn,selectChild:L.selectChild,selectChildren:L.selectChildren,filter:Vn,merge:Xn,selection:Kn,transition:eo,call:L.call,nodes:L.nodes,node:L.node,size:L.size,empty:L.empty,each:L.each,on:Yn,attr:Ln,attrTween:Fn,style:Wn,styleTween:Jn,text:jn,textTween:to,remove:Un,tween:Pn,delay:Dn,duration:Bn,ease:Hn,easeVarying:zn,end:ro,[Symbol.iterator]:L[Symbol.iterator]};function de(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}var Pa={time:null,delay:0,duration:250,ease:de};function La(t,e){for(var r;!(r=t.__transition)||!(r=r[e]);)if(!(t=t.parentNode))throw new Error(`transition ${e} not found`);return r}function no(t){var e,r;t instanceof N?(e=t._id,t=t._name):(e=he(),(r=Pa).time=Ct(),t=t==null?null:t+"");for(var n=this._groups,o=n.length,i=0;i<o;++i)for(var a=n[i],f=a.length,s,u=0;u<f;++u)(s=a[u])&&B(s,t,e,u,a,r||La(s,e));return new N(n,this._parents,t,e)}P.prototype.interrupt=qn;P.prototype.transition=no;var oo={select:yt,selectAll:wt,scaleLinear:W,scaleLog:J,scaleBand:Y,max:ot,min:it,extent:rt,interpolateNumber:w,transition:tt};typeof window!="undefined"&&(window.d3=oo);var Fa=oo;return mo(Da);})();