1 line
54 KiB
JavaScript
1 line
54 KiB
JavaScript
(()=>{"use strict";function t(t,n){let e;if(void 0===n)for(const n of t)null!=n&&(e<n||void 0===e&&n>=n)&&(e=n);else{let r=-1;for(let i of t)null!=(i=n(i,++r,t))&&(e<i||void 0===e&&i>=i)&&(e=i)}return e}function n(t){return t}var e=1e-6;function r(t){return"translate("+t+",0)"}function i(t){return"translate(0,"+t+")"}function o(t){return n=>+t(n)}function a(t,n){return n=Math.max(0,t.bandwidth()-2*n)/2,t.round()&&(n=Math.round(n)),e=>+t(e)+n}function u(){return!this.__axis}function s(t,s){var l=[],c=null,h=null,f=6,p=6,d=3,g="undefined"!=typeof window&&window.devicePixelRatio>1?0:.5,y=1===t||4===t?-1:1,m=4===t||2===t?"x":"y",v=1===t||3===t?r:i;function w(r){var i=null==c?s.ticks?s.ticks.apply(s,l):s.domain():c,w=null==h?s.tickFormat?s.tickFormat.apply(s,l):n:h,_=Math.max(f,0)+d,b=s.range(),x=+b[0]+g,M=+b[b.length-1]+g,k=(s.bandwidth?a:o)(s.copy(),g),A=r.selection?r.selection():r,N=A.selectAll(".domain").data([null]),E=A.selectAll(".tick").data(i,s).order(),$=E.exit(),S=E.enter().append("g").attr("class","tick"),C=E.select("line"),O=E.select("text");N=N.merge(N.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),E=E.merge(S),C=C.merge(S.append("line").attr("stroke","currentColor").attr(m+"2",y*f)),O=O.merge(S.append("text").attr("fill","currentColor").attr(m,y*_).attr("dy",1===t?"0em":3===t?"0.71em":"0.32em")),r!==A&&(N=N.transition(r),E=E.transition(r),C=C.transition(r),O=O.transition(r),$=$.transition(r).attr("opacity",e).attr("transform",(function(t){return isFinite(t=k(t))?v(t+g):this.getAttribute("transform")})),S.attr("opacity",e).attr("transform",(function(t){var n=this.parentNode.__axis;return v((n&&isFinite(n=n(t))?n:k(t))+g)}))),$.remove(),N.attr("d",4===t||2===t?p?"M"+y*p+","+x+"H"+g+"V"+M+"H"+y*p:"M"+g+","+x+"V"+M:p?"M"+x+","+y*p+"V"+g+"H"+M+"V"+y*p:"M"+x+","+g+"H"+M),E.attr("opacity",1).attr("transform",(function(t){return v(k(t)+g)})),C.attr(m+"2",y*f),O.attr(m,y*_).text(w),A.filter(u).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",2===t?"start":4===t?"end":"middle"),A.each((function(){this.__axis=k}))}return w.scale=function(t){return arguments.length?(s=t,w):s},w.ticks=function(){return l=Array.from(arguments),w},w.tickArguments=function(t){return arguments.length?(l=null==t?[]:Array.from(t),w):l.slice()},w.tickValues=function(t){return arguments.length?(c=null==t?null:Array.from(t),w):c&&c.slice()},w.tickFormat=function(t){return arguments.length?(h=t,w):h},w.tickSize=function(t){return arguments.length?(f=p=+t,w):f},w.tickSizeInner=function(t){return arguments.length?(f=+t,w):f},w.tickSizeOuter=function(t){return arguments.length?(p=+t,w):p},w.tickPadding=function(t){return arguments.length?(d=+t,w):d},w.offset=function(t){return arguments.length?(g=+t,w):g},w}function l(t){return s(3,t)}function c(t){return s(4,t)}function h(){}function f(t){return null==t?h:function(){return this.querySelector(t)}}function p(){return[]}function d(t){return null==t?p:function(){return this.querySelectorAll(t)}}function g(t){return function(){return this.matches(t)}}function y(t){return function(n){return n.matches(t)}}var m=Array.prototype.find;function v(){return this.firstElementChild}var w=Array.prototype.filter;function _(){return Array.from(this.children)}function b(t){return new Array(t.length)}function x(t,n){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=n}function M(t,n,e,r,i,o){for(var a,u=0,s=n.length,l=o.length;u<l;++u)(a=n[u])?(a.__data__=o[u],r[u]=a):e[u]=new x(t,o[u]);for(;u<s;++u)(a=n[u])&&(i[u]=a)}function k(t,n,e,r,i,o,a){var u,s,l,c=new Map,h=n.length,f=o.length,p=new Array(h);for(u=0;u<h;++u)(s=n[u])&&(p[u]=l=a.call(s,s.__data__,u,n)+"",c.has(l)?i[u]=s:c.set(l,s));for(u=0;u<f;++u)l=a.call(t,o[u],u,o)+"",(s=c.get(l))?(r[u]=s,s.__data__=o[u],c.delete(l)):e[u]=new x(t,o[u]);for(u=0;u<h;++u)(s=n[u])&&c.get(p[u])===s&&(i[u]=s)}function A(t){return t.__data__}function N(t){return"object"==typeof t&&"length"in t?t:Array.from(t)}function E(t,n){return t<n?-1:t>n?1:t>=n?0:NaN}x.prototype={constructor:x,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,n){return this._parent.insertBefore(t,n)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};var $="http://www.w3.org/1999/xhtml";const S={svg:"http://www.w3.org/2000/svg",xhtml:$,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function C(t){var n=t+="",e=n.indexOf(":");return e>=0&&"xmlns"!==(n=t.slice(0,e))&&(t=t.slice(e+1)),S.hasOwnProperty(n)?{space:S[n],local:t}:t}function O(t){return function(){this.removeAttribute(t)}}function P(t){return function(){this.removeAttributeNS(t.space,t.local)}}function j(t,n){return function(){this.setAttribute(t,n)}}function q(t,n){return function(){this.setAttributeNS(t.space,t.local,n)}}function H(t,n){return function(){var e=n.apply(this,arguments);null==e?this.removeAttribute(t):this.setAttribute(t,e)}}function T(t,n){return function(){var e=n.apply(this,arguments);null==e?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,e)}}function X(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function z(t){return function(){this.style.removeProperty(t)}}function L(t,n,e){return function(){this.style.setProperty(t,n,e)}}function D(t,n,e){return function(){var r=n.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,e)}}function R(t,n){return t.style.getPropertyValue(n)||X(t).getComputedStyle(t,null).getPropertyValue(n)}function I(t){return function(){delete this[t]}}function V(t,n){return function(){this[t]=n}}function Y(t,n){return function(){var e=n.apply(this,arguments);null==e?delete this[t]:this[t]=e}}function B(t){return t.trim().split(/^|\s+/)}function F(t){return t.classList||new G(t)}function G(t){this._node=t,this._names=B(t.getAttribute("class")||"")}function U(t,n){for(var e=F(t),r=-1,i=n.length;++r<i;)e.add(n[r])}function W(t,n){for(var e=F(t),r=-1,i=n.length;++r<i;)e.remove(n[r])}function K(t){return function(){U(this,t)}}function Z(t){return function(){W(this,t)}}function J(t,n){return function(){(n.apply(this,arguments)?U:W)(this,t)}}function Q(){this.textContent=""}function tt(t){return function(){this.textContent=t}}function nt(t){return function(){var n=t.apply(this,arguments);this.textContent=null==n?"":n}}function et(){this.innerHTML=""}function rt(t){return function(){this.innerHTML=t}}function it(t){return function(){var n=t.apply(this,arguments);this.innerHTML=null==n?"":n}}function ot(){this.nextSibling&&this.parentNode.appendChild(this)}function at(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function ut(t){return function(){var n=this.ownerDocument,e=this.namespaceURI;return e===$&&n.documentElement.namespaceURI===$?n.createElement(t):n.createElementNS(e,t)}}function st(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function lt(t){var n=C(t);return(n.local?st:ut)(n)}function ct(){return null}function ht(){var t=this.parentNode;t&&t.removeChild(this)}function ft(){var t=this.cloneNode(!1),n=this.parentNode;return n?n.insertBefore(t,this.nextSibling):t}function pt(){var t=this.cloneNode(!0),n=this.parentNode;return n?n.insertBefore(t,this.nextSibling):t}function dt(t){return function(){var n=this.__on;if(n){for(var e,r=0,i=-1,o=n.length;r<o;++r)e=n[r],t.type&&e.type!==t.type||e.name!==t.name?n[++i]=e:this.removeEventListener(e.type,e.listener,e.options);++i?n.length=i:delete this.__on}}}function gt(t,n,e){return function(){var r,i=this.__on,o=function(t){return function(n){t.call(this,n,this.__data__)}}(n);if(i)for(var a=0,u=i.length;a<u;++a)if((r=i[a]).type===t.type&&r.name===t.name)return this.removeEventListener(r.type,r.listener,r.options),this.addEventListener(r.type,r.listener=o,r.options=e),void(r.value=n);this.addEventListener(t.type,o,e),r={type:t.type,name:t.name,value:n,listener:o,options:e},i?i.push(r):this.__on=[r]}}function yt(t,n,e){var r=X(t),i=r.CustomEvent;"function"==typeof i?i=new i(n,e):(i=r.document.createEvent("Event"),e?(i.initEvent(n,e.bubbles,e.cancelable),i.detail=e.detail):i.initEvent(n,!1,!1)),t.dispatchEvent(i)}function mt(t,n){return function(){return yt(this,t,n)}}function vt(t,n){return function(){return yt(this,t,n.apply(this,arguments))}}G.prototype={add:function(t){this._names.indexOf(t)<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var n=this._names.indexOf(t);n>=0&&(this._names.splice(n,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var wt=[null];function _t(t,n){this._groups=t,this._parents=n}function bt(){return new _t([[document.documentElement]],wt)}_t.prototype=bt.prototype={constructor:_t,select:function(t){"function"!=typeof t&&(t=f(t));for(var n=this._groups,e=n.length,r=new Array(e),i=0;i<e;++i)for(var o,a,u=n[i],s=u.length,l=r[i]=new Array(s),c=0;c<s;++c)(o=u[c])&&(a=t.call(o,o.__data__,c,u))&&("__data__"in o&&(a.__data__=o.__data__),l[c]=a);return new _t(r,this._parents)},selectAll:function(t){t="function"==typeof t?function(t){return function(){return null==(n=t.apply(this,arguments))?[]:Array.isArray(n)?n:Array.from(n);var n}}(t):d(t);for(var n=this._groups,e=n.length,r=[],i=[],o=0;o<e;++o)for(var a,u=n[o],s=u.length,l=0;l<s;++l)(a=u[l])&&(r.push(t.call(a,a.__data__,l,u)),i.push(a));return new _t(r,i)},selectChild:function(t){return this.select(null==t?v:function(t){return function(){return m.call(this.children,t)}}("function"==typeof t?t:y(t)))},selectChildren:function(t){return this.selectAll(null==t?_:function(t){return function(){return w.call(this.children,t)}}("function"==typeof t?t:y(t)))},filter:function(t){"function"!=typeof t&&(t=g(t));for(var n=this._groups,e=n.length,r=new Array(e),i=0;i<e;++i)for(var o,a=n[i],u=a.length,s=r[i]=[],l=0;l<u;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&s.push(o);return new _t(r,this._parents)},data:function(t,n){if(!arguments.length)return Array.from(this,A);var e,r=n?k:M,i=this._parents,o=this._groups;"function"!=typeof t&&(e=t,t=function(){return e});for(var a=o.length,u=new Array(a),s=new Array(a),l=new Array(a),c=0;c<a;++c){var h=i[c],f=o[c],p=f.length,d=N(t.call(h,h&&h.__data__,c,i)),g=d.length,y=s[c]=new Array(g),m=u[c]=new Array(g);r(h,f,y,m,l[c]=new Array(p),d,n);for(var v,w,_=0,b=0;_<g;++_)if(v=y[_]){for(_>=b&&(b=_+1);!(w=m[b])&&++b<g;);v._next=w||null}}return(u=new _t(u,i))._enter=s,u._exit=l,u},enter:function(){return new _t(this._enter||this._groups.map(b),this._parents)},exit:function(){return new _t(this._exit||this._groups.map(b),this._parents)},join:function(t,n,e){var r=this.enter(),i=this,o=this.exit();return"function"==typeof t?(r=t(r))&&(r=r.selection()):r=r.append(t+""),null!=n&&(i=n(i))&&(i=i.selection()),null==e?o.remove():e(o),r&&i?r.merge(i).order():i},merge:function(t){for(var n=t.selection?t.selection():t,e=this._groups,r=n._groups,i=e.length,o=r.length,a=Math.min(i,o),u=new Array(i),s=0;s<a;++s)for(var l,c=e[s],h=r[s],f=c.length,p=u[s]=new Array(f),d=0;d<f;++d)(l=c[d]||h[d])&&(p[d]=l);for(;s<i;++s)u[s]=e[s];return new _t(u,this._parents)},selection:function(){return this},order:function(){for(var t=this._groups,n=-1,e=t.length;++n<e;)for(var r,i=t[n],o=i.length-1,a=i[o];--o>=0;)(r=i[o])&&(a&&4^r.compareDocumentPosition(a)&&a.parentNode.insertBefore(r,a),a=r);return this},sort:function(t){function n(n,e){return n&&e?t(n.__data__,e.__data__):!n-!e}t||(t=E);for(var e=this._groups,r=e.length,i=new Array(r),o=0;o<r;++o){for(var a,u=e[o],s=u.length,l=i[o]=new Array(s),c=0;c<s;++c)(a=u[c])&&(l[c]=a);l.sort(n)}return new _t(i,this._parents).order()},call:function(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this},nodes:function(){return Array.from(this)},node:function(){for(var t=this._groups,n=0,e=t.length;n<e;++n)for(var r=t[n],i=0,o=r.length;i<o;++i){var a=r[i];if(a)return a}return null},size:function(){let t=0;for(const n of this)++t;return t},empty:function(){return!this.node()},each:function(t){for(var n=this._groups,e=0,r=n.length;e<r;++e)for(var i,o=n[e],a=0,u=o.length;a<u;++a)(i=o[a])&&t.call(i,i.__data__,a,o);return this},attr:function(t,n){var e=C(t);if(arguments.length<2){var r=this.node();return e.local?r.getAttributeNS(e.space,e.local):r.getAttribute(e)}return this.each((null==n?e.local?P:O:"function"==typeof n?e.local?T:H:e.local?q:j)(e,n))},style:function(t,n,e){return arguments.length>1?this.each((null==n?z:"function"==typeof n?D:L)(t,n,null==e?"":e)):R(this.node(),t)},property:function(t,n){return arguments.length>1?this.each((null==n?I:"function"==typeof n?Y:V)(t,n)):this.node()[t]},classed:function(t,n){var e=B(t+"");if(arguments.length<2){for(var r=F(this.node()),i=-1,o=e.length;++i<o;)if(!r.contains(e[i]))return!1;return!0}return this.each(("function"==typeof n?J:n?K:Z)(e,n))},text:function(t){return arguments.length?this.each(null==t?Q:("function"==typeof t?nt:tt)(t)):this.node().textContent},html:function(t){return arguments.length?this.each(null==t?et:("function"==typeof t?it:rt)(t)):this.node().innerHTML},raise:function(){return this.each(ot)},lower:function(){return this.each(at)},append:function(t){var n="function"==typeof t?t:lt(t);return this.select((function(){return this.appendChild(n.apply(this,arguments))}))},insert:function(t,n){var e="function"==typeof t?t:lt(t),r=null==n?ct:"function"==typeof n?n:f(n);return this.select((function(){return this.insertBefore(e.apply(this,arguments),r.apply(this,arguments)||null)}))},remove:function(){return this.each(ht)},clone:function(t){return this.select(t?pt:ft)},datum:function(t){return arguments.length?this.property("__data__",t):this.node().__data__},on:function(t,n,e){var r,i,o=function(t){return t.trim().split(/^|\s+/).map((function(t){var n="",e=t.indexOf(".");return e>=0&&(n=t.slice(e+1),t=t.slice(0,e)),{type:t,name:n}}))}(t+""),a=o.length;if(!(arguments.length<2)){for(u=n?gt:dt,r=0;r<a;++r)this.each(u(o[r],n,e));return this}var u=this.node().__on;if(u)for(var s,l=0,c=u.length;l<c;++l)for(r=0,s=u[l];r<a;++r)if((i=o[r]).type===s.type&&i.name===s.name)return s.value},dispatch:function(t,n){return this.each(("function"==typeof n?vt:mt)(t,n))},[Symbol.iterator]:function*(){for(var t=this._groups,n=0,e=t.length;n<e;++n)for(var r,i=t[n],o=0,a=i.length;o<a;++o)(r=i[o])&&(yield r)}};const xt=bt;var Mt={value:()=>{}};function kt(){for(var t,n=0,e=arguments.length,r={};n<e;++n){if(!(t=arguments[n]+"")||t in r||/[\s.]/.test(t))throw new Error("illegal type: "+t);r[t]=[]}return new At(r)}function At(t){this._=t}function Nt(t,n){for(var e,r=0,i=t.length;r<i;++r)if((e=t[r]).name===n)return e.value}function Et(t,n,e){for(var r=0,i=t.length;r<i;++r)if(t[r].name===n){t[r]=Mt,t=t.slice(0,r).concat(t.slice(r+1));break}return null!=e&&t.push({name:n,value:e}),t}At.prototype=kt.prototype={constructor:At,on:function(t,n){var e,r,i=this._,o=(r=i,(t+"").trim().split(/^|\s+/).map((function(t){var n="",e=t.indexOf(".");if(e>=0&&(n=t.slice(e+1),t=t.slice(0,e)),t&&!r.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:n}}))),a=-1,u=o.length;if(!(arguments.length<2)){if(null!=n&&"function"!=typeof n)throw new Error("invalid callback: "+n);for(;++a<u;)if(e=(t=o[a]).type)i[e]=Et(i[e],t.name,n);else if(null==n)for(e in i)i[e]=Et(i[e],t.name,null);return this}for(;++a<u;)if((e=(t=o[a]).type)&&(e=Nt(i[e],t.name)))return e},copy:function(){var t={},n=this._;for(var e in n)t[e]=n[e].slice();return new At(t)},call:function(t,n){if((e=arguments.length-2)>0)for(var e,r,i=new Array(e),o=0;o<e;++o)i[o]=arguments[o+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(o=0,e=(r=this._[t]).length;o<e;++o)r[o].value.apply(n,i)},apply:function(t,n,e){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var r=this._[t],i=0,o=r.length;i<o;++i)r[i].value.apply(n,e)}};const $t=kt;var St,Ct,Ot=0,Pt=0,jt=0,qt=0,Ht=0,Tt=0,Xt="object"==typeof performance&&performance.now?performance:Date,zt="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function Lt(){return Ht||(zt(Dt),Ht=Xt.now()+Tt)}function Dt(){Ht=0}function Rt(){this._call=this._time=this._next=null}function It(t,n,e){var r=new Rt;return r.restart(t,n,e),r}function Vt(){Ht=(qt=Xt.now())+Tt,Ot=Pt=0;try{!function(){Lt(),++Ot;for(var t,n=St;n;)(t=Ht-n._time)>=0&&n._call.call(void 0,t),n=n._next;--Ot}()}finally{Ot=0,function(){for(var t,n,e=St,r=1/0;e;)e._call?(r>e._time&&(r=e._time),t=e,e=e._next):(n=e._next,e._next=null,e=t?t._next=n:St=n);Ct=t,Bt(r)}(),Ht=0}}function Yt(){var t=Xt.now(),n=t-qt;n>1e3&&(Tt-=n,qt=t)}function Bt(t){Ot||(Pt&&(Pt=clearTimeout(Pt)),t-Ht>24?(t<1/0&&(Pt=setTimeout(Vt,t-Xt.now()-Tt)),jt&&(jt=clearInterval(jt))):(jt||(qt=Xt.now(),jt=setInterval(Yt,1e3)),Ot=1,zt(Vt)))}function Ft(t,n,e){var r=new Rt;return n=null==n?0:+n,r.restart((e=>{r.stop(),t(e+n)}),n,e),r}Rt.prototype=It.prototype={constructor:Rt,restart:function(t,n,e){if("function"!=typeof t)throw new TypeError("callback is not a function");e=(null==e?Lt():+e)+(null==n?0:+n),this._next||Ct===this||(Ct?Ct._next=this:St=this,Ct=this),this._call=t,this._time=e,Bt()},stop:function(){this._call&&(this._call=null,this._time=1/0,Bt())}};var Gt=$t("start","end","cancel","interrupt"),Ut=[];function Wt(t,n,e,r,i,o){var a=t.__transition;if(a){if(e in a)return}else t.__transition={};!function(t,n,e){var r,i=t.__transition;function o(s){var l,c,h,f;if(1!==e.state)return u();for(l in i)if((f=i[l]).name===e.name){if(3===f.state)return Ft(o);4===f.state?(f.state=6,f.timer.stop(),f.on.call("interrupt",t,t.__data__,f.index,f.group),delete i[l]):+l<n&&(f.state=6,f.timer.stop(),f.on.call("cancel",t,t.__data__,f.index,f.group),delete i[l])}if(Ft((function(){3===e.state&&(e.state=4,e.timer.restart(a,e.delay,e.time),a(s))})),e.state=2,e.on.call("start",t,t.__data__,e.index,e.group),2===e.state){for(e.state=3,r=new Array(h=e.tween.length),l=0,c=-1;l<h;++l)(f=e.tween[l].value.call(t,t.__data__,e.index,e.group))&&(r[++c]=f);r.length=c+1}}function a(n){for(var i=n<e.duration?e.ease.call(null,n/e.duration):(e.timer.restart(u),e.state=5,1),o=-1,a=r.length;++o<a;)r[o].call(t,i);5===e.state&&(e.on.call("end",t,t.__data__,e.index,e.group),u())}function u(){for(var r in e.state=6,e.timer.stop(),delete i[n],i)return;delete t.__transition}i[n]=e,e.timer=It((function(t){e.state=1,e.timer.restart(o,e.delay,e.time),e.delay<=t&&o(t-e.delay)}),0,e.time)}(t,e,{name:n,index:r,group:i,on:Gt,tween:Ut,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:0})}function Kt(t,n){var e=Jt(t,n);if(e.state>0)throw new Error("too late; already scheduled");return e}function Zt(t,n){var e=Jt(t,n);if(e.state>3)throw new Error("too late; already running");return e}function Jt(t,n){var e=t.__transition;if(!e||!(e=e[n]))throw new Error("transition not found");return e}function Qt(t,n){return t=+t,n=+n,function(e){return t*(1-e)+n*e}}var tn,nn=180/Math.PI,en={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function rn(t,n,e,r,i,o){var a,u,s;return(a=Math.sqrt(t*t+n*n))&&(t/=a,n/=a),(s=t*e+n*r)&&(e-=t*s,r-=n*s),(u=Math.sqrt(e*e+r*r))&&(e/=u,r/=u,s/=u),t*r<n*e&&(t=-t,n=-n,s=-s,a=-a),{translateX:i,translateY:o,rotate:Math.atan2(n,t)*nn,skewX:Math.atan(s)*nn,scaleX:a,scaleY:u}}function on(t,n,e,r){function i(t){return t.length?t.pop()+" ":""}return function(o,a){var u=[],s=[];return o=t(o),a=t(a),function(t,r,i,o,a,u){if(t!==i||r!==o){var s=a.push("translate(",null,n,null,e);u.push({i:s-4,x:Qt(t,i)},{i:s-2,x:Qt(r,o)})}else(i||o)&&a.push("translate("+i+n+o+e)}(o.translateX,o.translateY,a.translateX,a.translateY,u,s),function(t,n,e,o){t!==n?(t-n>180?n+=360:n-t>180&&(t+=360),o.push({i:e.push(i(e)+"rotate(",null,r)-2,x:Qt(t,n)})):n&&e.push(i(e)+"rotate("+n+r)}(o.rotate,a.rotate,u,s),function(t,n,e,o){t!==n?o.push({i:e.push(i(e)+"skewX(",null,r)-2,x:Qt(t,n)}):n&&e.push(i(e)+"skewX("+n+r)}(o.skewX,a.skewX,u,s),function(t,n,e,r,o,a){if(t!==e||n!==r){var u=o.push(i(o)+"scale(",null,",",null,")");a.push({i:u-4,x:Qt(t,e)},{i:u-2,x:Qt(n,r)})}else 1===e&&1===r||o.push(i(o)+"scale("+e+","+r+")")}(o.scaleX,o.scaleY,a.scaleX,a.scaleY,u,s),o=a=null,function(t){for(var n,e=-1,r=s.length;++e<r;)u[(n=s[e]).i]=n.x(t);return u.join("")}}}var an=on((function(t){const n=new("function"==typeof DOMMatrix?DOMMatrix:WebKitCSSMatrix)(t+"");return n.isIdentity?en:rn(n.a,n.b,n.c,n.d,n.e,n.f)}),"px, ","px)","deg)"),un=on((function(t){return null==t?en:(tn||(tn=document.createElementNS("http://www.w3.org/2000/svg","g")),tn.setAttribute("transform",t),(t=tn.transform.baseVal.consolidate())?rn((t=t.matrix).a,t.b,t.c,t.d,t.e,t.f):en)}),", ",")",")");function sn(t,n){var e,r;return function(){var i=Zt(this,t),o=i.tween;if(o!==e)for(var a=0,u=(r=e=o).length;a<u;++a)if(r[a].name===n){(r=r.slice()).splice(a,1);break}i.tween=r}}function ln(t,n,e){var r,i;if("function"!=typeof e)throw new Error;return function(){var o=Zt(this,t),a=o.tween;if(a!==r){i=(r=a).slice();for(var u={name:n,value:e},s=0,l=i.length;s<l;++s)if(i[s].name===n){i[s]=u;break}s===l&&i.push(u)}o.tween=i}}function cn(t,n,e){var r=t._id;return t.each((function(){var t=Zt(this,r);(t.value||(t.value={}))[n]=e.apply(this,arguments)})),function(t){return Jt(t,r).value[n]}}function hn(t,n,e){t.prototype=n.prototype=e,e.constructor=t}function fn(t,n){var e=Object.create(t.prototype);for(var r in n)e[r]=n[r];return e}function pn(){}var dn=.7,gn=1/dn,yn="\\s*([+-]?\\d+)\\s*",mn="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",vn="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",wn=/^#([0-9a-f]{3,8})$/,bn=new RegExp(`^rgb\\(${yn},${yn},${yn}\\)$`),xn=new RegExp(`^rgb\\(${vn},${vn},${vn}\\)$`),Mn=new RegExp(`^rgba\\(${yn},${yn},${yn},${mn}\\)$`),kn=new RegExp(`^rgba\\(${vn},${vn},${vn},${mn}\\)$`),An=new RegExp(`^hsl\\(${mn},${vn},${vn}\\)$`),Nn=new RegExp(`^hsla\\(${mn},${vn},${vn},${mn}\\)$`),En={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};function $n(){return this.rgb().formatHex()}function Sn(){return this.rgb().formatRgb()}function Cn(t){var n,e;return t=(t+"").trim().toLowerCase(),(n=wn.exec(t))?(e=n[1].length,n=parseInt(n[1],16),6===e?On(n):3===e?new qn(n>>8&15|n>>4&240,n>>4&15|240&n,(15&n)<<4|15&n,1):8===e?Pn(n>>24&255,n>>16&255,n>>8&255,(255&n)/255):4===e?Pn(n>>12&15|n>>8&240,n>>8&15|n>>4&240,n>>4&15|240&n,((15&n)<<4|15&n)/255):null):(n=bn.exec(t))?new qn(n[1],n[2],n[3],1):(n=xn.exec(t))?new qn(255*n[1]/100,255*n[2]/100,255*n[3]/100,1):(n=Mn.exec(t))?Pn(n[1],n[2],n[3],n[4]):(n=kn.exec(t))?Pn(255*n[1]/100,255*n[2]/100,255*n[3]/100,n[4]):(n=An.exec(t))?Dn(n[1],n[2]/100,n[3]/100,1):(n=Nn.exec(t))?Dn(n[1],n[2]/100,n[3]/100,n[4]):En.hasOwnProperty(t)?On(En[t]):"transparent"===t?new qn(NaN,NaN,NaN,0):null}function On(t){return new qn(t>>16&255,t>>8&255,255&t,1)}function Pn(t,n,e,r){return r<=0&&(t=n=e=NaN),new qn(t,n,e,r)}function jn(t,n,e,r){return 1===arguments.length?((i=t)instanceof pn||(i=Cn(i)),i?new qn((i=i.rgb()).r,i.g,i.b,i.opacity):new qn):new qn(t,n,e,null==r?1:r);var i}function qn(t,n,e,r){this.r=+t,this.g=+n,this.b=+e,this.opacity=+r}function Hn(){return`#${Ln(this.r)}${Ln(this.g)}${Ln(this.b)}`}function Tn(){const t=Xn(this.opacity);return`${1===t?"rgb(":"rgba("}${zn(this.r)}, ${zn(this.g)}, ${zn(this.b)}${1===t?")":`, ${t})`}`}function Xn(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function zn(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function Ln(t){return((t=zn(t))<16?"0":"")+t.toString(16)}function Dn(t,n,e,r){return r<=0?t=n=e=NaN:e<=0||e>=1?t=n=NaN:n<=0&&(t=NaN),new In(t,n,e,r)}function Rn(t){if(t instanceof In)return new In(t.h,t.s,t.l,t.opacity);if(t instanceof pn||(t=Cn(t)),!t)return new In;if(t instanceof In)return t;var n=(t=t.rgb()).r/255,e=t.g/255,r=t.b/255,i=Math.min(n,e,r),o=Math.max(n,e,r),a=NaN,u=o-i,s=(o+i)/2;return u?(a=n===o?(e-r)/u+6*(e<r):e===o?(r-n)/u+2:(n-e)/u+4,u/=s<.5?o+i:2-o-i,a*=60):u=s>0&&s<1?0:a,new In(a,u,s,t.opacity)}function In(t,n,e,r){this.h=+t,this.s=+n,this.l=+e,this.opacity=+r}function Vn(t){return(t=(t||0)%360)<0?t+360:t}function Yn(t){return Math.max(0,Math.min(1,t||0))}function Bn(t,n,e){return 255*(t<60?n+(e-n)*t/60:t<180?e:t<240?n+(e-n)*(240-t)/60:n)}function Fn(t,n,e,r,i){var o=t*t,a=o*t;return((1-3*t+3*o-a)*n+(4-6*o+3*a)*e+(1+3*t+3*o-3*a)*r+a*i)/6}hn(pn,Cn,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:$n,formatHex:$n,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return Rn(this).formatHsl()},formatRgb:Sn,toString:Sn}),hn(qn,jn,fn(pn,{brighter(t){return t=null==t?gn:Math.pow(gn,t),new qn(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=null==t?dn:Math.pow(dn,t),new qn(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new qn(zn(this.r),zn(this.g),zn(this.b),Xn(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:Hn,formatHex:Hn,formatHex8:function(){return`#${Ln(this.r)}${Ln(this.g)}${Ln(this.b)}${Ln(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:Tn,toString:Tn})),hn(In,(function(t,n,e,r){return 1===arguments.length?Rn(t):new In(t,n,e,null==r?1:r)}),fn(pn,{brighter(t){return t=null==t?gn:Math.pow(gn,t),new In(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=null==t?dn:Math.pow(dn,t),new In(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+360*(this.h<0),n=isNaN(t)||isNaN(this.s)?0:this.s,e=this.l,r=e+(e<.5?e:1-e)*n,i=2*e-r;return new qn(Bn(t>=240?t-240:t+120,i,r),Bn(t,i,r),Bn(t<120?t+240:t-120,i,r),this.opacity)},clamp(){return new In(Vn(this.h),Yn(this.s),Yn(this.l),Xn(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 t=Xn(this.opacity);return`${1===t?"hsl(":"hsla("}${Vn(this.h)}, ${100*Yn(this.s)}%, ${100*Yn(this.l)}%${1===t?")":`, ${t})`}`}}));const Gn=t=>()=>t;function Un(t,n){var e=n-t;return e?function(t,n){return function(e){return t+e*n}}(t,e):Gn(isNaN(t)?n:t)}const Wn=function t(n){var e=function(t){return 1==(t=+t)?Un:function(n,e){return e-n?function(t,n,e){return t=Math.pow(t,e),n=Math.pow(n,e)-t,e=1/e,function(r){return Math.pow(t+r*n,e)}}(n,e,t):Gn(isNaN(n)?e:n)}}(n);function r(t,n){var r=e((t=jn(t)).r,(n=jn(n)).r),i=e(t.g,n.g),o=e(t.b,n.b),a=Un(t.opacity,n.opacity);return function(n){return t.r=r(n),t.g=i(n),t.b=o(n),t.opacity=a(n),t+""}}return r.gamma=t,r}(1);function Kn(t){return function(n){var e,r,i=n.length,o=new Array(i),a=new Array(i),u=new Array(i);for(e=0;e<i;++e)r=jn(n[e]),o[e]=r.r||0,a[e]=r.g||0,u[e]=r.b||0;return o=t(o),a=t(a),u=t(u),r.opacity=1,function(t){return r.r=o(t),r.g=a(t),r.b=u(t),r+""}}}Kn((function(t){var n=t.length-1;return function(e){var r=e<=0?e=0:e>=1?(e=1,n-1):Math.floor(e*n),i=t[r],o=t[r+1],a=r>0?t[r-1]:2*i-o,u=r<n-1?t[r+2]:2*o-i;return Fn((e-r/n)*n,a,i,o,u)}})),Kn((function(t){var n=t.length;return function(e){var r=Math.floor(((e%=1)<0?++e:e)*n),i=t[(r+n-1)%n],o=t[r%n],a=t[(r+1)%n],u=t[(r+2)%n];return Fn((e-r/n)*n,i,o,a,u)}}));var Zn=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Jn=new RegExp(Zn.source,"g");function Qn(t,n){var e,r,i,o=Zn.lastIndex=Jn.lastIndex=0,a=-1,u=[],s=[];for(t+="",n+="";(e=Zn.exec(t))&&(r=Jn.exec(n));)(i=r.index)>o&&(i=n.slice(o,i),u[a]?u[a]+=i:u[++a]=i),(e=e[0])===(r=r[0])?u[a]?u[a]+=r:u[++a]=r:(u[++a]=null,s.push({i:a,x:Qt(e,r)})),o=Jn.lastIndex;return o<n.length&&(i=n.slice(o),u[a]?u[a]+=i:u[++a]=i),u.length<2?s[0]?function(t){return function(n){return t(n)+""}}(s[0].x):function(t){return function(){return t}}(n):(n=s.length,function(t){for(var e,r=0;r<n;++r)u[(e=s[r]).i]=e.x(t);return u.join("")})}function te(t,n){var e;return("number"==typeof n?Qt:n instanceof Cn?Wn:(e=Cn(n))?(n=e,Wn):Qn)(t,n)}function ne(t){return function(){this.removeAttribute(t)}}function ee(t){return function(){this.removeAttributeNS(t.space,t.local)}}function re(t,n,e){var r,i,o=e+"";return function(){var a=this.getAttribute(t);return a===o?null:a===r?i:i=n(r=a,e)}}function ie(t,n,e){var r,i,o=e+"";return function(){var a=this.getAttributeNS(t.space,t.local);return a===o?null:a===r?i:i=n(r=a,e)}}function oe(t,n,e){var r,i,o;return function(){var a,u,s=e(this);if(null!=s)return(a=this.getAttribute(t))===(u=s+"")?null:a===r&&u===i?o:(i=u,o=n(r=a,s));this.removeAttribute(t)}}function ae(t,n,e){var r,i,o;return function(){var a,u,s=e(this);if(null!=s)return(a=this.getAttributeNS(t.space,t.local))===(u=s+"")?null:a===r&&u===i?o:(i=u,o=n(r=a,s));this.removeAttributeNS(t.space,t.local)}}function ue(t,n){var e,r;function i(){var i=n.apply(this,arguments);return i!==r&&(e=(r=i)&&function(t,n){return function(e){this.setAttributeNS(t.space,t.local,n.call(this,e))}}(t,i)),e}return i._value=n,i}function se(t,n){var e,r;function i(){var i=n.apply(this,arguments);return i!==r&&(e=(r=i)&&function(t,n){return function(e){this.setAttribute(t,n.call(this,e))}}(t,i)),e}return i._value=n,i}function le(t,n){return function(){Kt(this,t).delay=+n.apply(this,arguments)}}function ce(t,n){return n=+n,function(){Kt(this,t).delay=n}}function he(t,n){return function(){Zt(this,t).duration=+n.apply(this,arguments)}}function fe(t,n){return n=+n,function(){Zt(this,t).duration=n}}var pe=xt.prototype.constructor;function de(t){return function(){this.style.removeProperty(t)}}var ge=0;function ye(t,n,e,r){this._groups=t,this._parents=n,this._name=e,this._id=r}function me(){return++ge}var ve=xt.prototype;ye.prototype=function(t){return xt().transition(t)}.prototype={constructor:ye,select:function(t){var n=this._name,e=this._id;"function"!=typeof t&&(t=f(t));for(var r=this._groups,i=r.length,o=new Array(i),a=0;a<i;++a)for(var u,s,l=r[a],c=l.length,h=o[a]=new Array(c),p=0;p<c;++p)(u=l[p])&&(s=t.call(u,u.__data__,p,l))&&("__data__"in u&&(s.__data__=u.__data__),h[p]=s,Wt(h[p],n,e,p,h,Jt(u,e)));return new ye(o,this._parents,n,e)},selectAll:function(t){var n=this._name,e=this._id;"function"!=typeof t&&(t=d(t));for(var r=this._groups,i=r.length,o=[],a=[],u=0;u<i;++u)for(var s,l=r[u],c=l.length,h=0;h<c;++h)if(s=l[h]){for(var f,p=t.call(s,s.__data__,h,l),g=Jt(s,e),y=0,m=p.length;y<m;++y)(f=p[y])&&Wt(f,n,e,y,p,g);o.push(p),a.push(s)}return new ye(o,a,n,e)},selectChild:ve.selectChild,selectChildren:ve.selectChildren,filter:function(t){"function"!=typeof t&&(t=g(t));for(var n=this._groups,e=n.length,r=new Array(e),i=0;i<e;++i)for(var o,a=n[i],u=a.length,s=r[i]=[],l=0;l<u;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&s.push(o);return new ye(r,this._parents,this._name,this._id)},merge:function(t){if(t._id!==this._id)throw new Error;for(var n=this._groups,e=t._groups,r=n.length,i=e.length,o=Math.min(r,i),a=new Array(r),u=0;u<o;++u)for(var s,l=n[u],c=e[u],h=l.length,f=a[u]=new Array(h),p=0;p<h;++p)(s=l[p]||c[p])&&(f[p]=s);for(;u<r;++u)a[u]=n[u];return new ye(a,this._parents,this._name,this._id)},selection:function(){return new pe(this._groups,this._parents)},transition:function(){for(var t=this._name,n=this._id,e=me(),r=this._groups,i=r.length,o=0;o<i;++o)for(var a,u=r[o],s=u.length,l=0;l<s;++l)if(a=u[l]){var c=Jt(a,n);Wt(a,t,e,l,u,{time:c.time+c.delay+c.duration,delay:0,duration:c.duration,ease:c.ease})}return new ye(r,this._parents,t,e)},call:ve.call,nodes:ve.nodes,node:ve.node,size:ve.size,empty:ve.empty,each:ve.each,on:function(t,n){var e=this._id;return arguments.length<2?Jt(this.node(),e).on.on(t):this.each(function(t,n,e){var r,i,o=function(t){return(t+"").trim().split(/^|\s+/).every((function(t){var n=t.indexOf(".");return n>=0&&(t=t.slice(0,n)),!t||"start"===t}))}(n)?Kt:Zt;return function(){var a=o(this,t),u=a.on;u!==r&&(i=(r=u).copy()).on(n,e),a.on=i}}(e,t,n))},attr:function(t,n){var e=C(t),r="transform"===e?un:te;return this.attrTween(t,"function"==typeof n?(e.local?ae:oe)(e,r,cn(this,"attr."+t,n)):null==n?(e.local?ee:ne)(e):(e.local?ie:re)(e,r,n))},attrTween:function(t,n){var e="attr."+t;if(arguments.length<2)return(e=this.tween(e))&&e._value;if(null==n)return this.tween(e,null);if("function"!=typeof n)throw new Error;var r=C(t);return this.tween(e,(r.local?ue:se)(r,n))},style:function(t,n,e){var r="transform"==(t+="")?an:te;return null==n?this.styleTween(t,function(t,n){var e,r,i;return function(){var o=R(this,t),a=(this.style.removeProperty(t),R(this,t));return o===a?null:o===e&&a===r?i:i=n(e=o,r=a)}}(t,r)).on("end.style."+t,de(t)):"function"==typeof n?this.styleTween(t,function(t,n,e){var r,i,o;return function(){var a=R(this,t),u=e(this),s=u+"";return null==u&&(this.style.removeProperty(t),s=u=R(this,t)),a===s?null:a===r&&s===i?o:(i=s,o=n(r=a,u))}}(t,r,cn(this,"style."+t,n))).each(function(t,n){var e,r,i,o,a="style."+n,u="end."+a;return function(){var s=Zt(this,t),l=s.on,c=null==s.value[a]?o||(o=de(n)):void 0;l===e&&i===c||(r=(e=l).copy()).on(u,i=c),s.on=r}}(this._id,t)):this.styleTween(t,function(t,n,e){var r,i,o=e+"";return function(){var a=R(this,t);return a===o?null:a===r?i:i=n(r=a,e)}}(t,r,n),e).on("end.style."+t,null)},styleTween:function(t,n,e){var r="style."+(t+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(null==n)return this.tween(r,null);if("function"!=typeof n)throw new Error;return this.tween(r,function(t,n,e){var r,i;function o(){var o=n.apply(this,arguments);return o!==i&&(r=(i=o)&&function(t,n,e){return function(r){this.style.setProperty(t,n.call(this,r),e)}}(t,o,e)),r}return o._value=n,o}(t,n,null==e?"":e))},text:function(t){return this.tween("text","function"==typeof t?function(t){return function(){var n=t(this);this.textContent=null==n?"":n}}(cn(this,"text",t)):function(t){return function(){this.textContent=t}}(null==t?"":t+""))},textTween:function(t){var n="text";if(arguments.length<1)return(n=this.tween(n))&&n._value;if(null==t)return this.tween(n,null);if("function"!=typeof t)throw new Error;return this.tween(n,function(t){var n,e;function r(){var r=t.apply(this,arguments);return r!==e&&(n=(e=r)&&function(t){return function(n){this.textContent=t.call(this,n)}}(r)),n}return r._value=t,r}(t))},remove:function(){return this.on("end.remove",function(t){return function(){var n=this.parentNode;for(var e in this.__transition)if(+e!==t)return;n&&n.removeChild(this)}}(this._id))},tween:function(t,n){var e=this._id;if(t+="",arguments.length<2){for(var r,i=Jt(this.node(),e).tween,o=0,a=i.length;o<a;++o)if((r=i[o]).name===t)return r.value;return null}return this.each((null==n?sn:ln)(e,t,n))},delay:function(t){var n=this._id;return arguments.length?this.each(("function"==typeof t?le:ce)(n,t)):Jt(this.node(),n).delay},duration:function(t){var n=this._id;return arguments.length?this.each(("function"==typeof t?he:fe)(n,t)):Jt(this.node(),n).duration},ease:function(t){var n=this._id;return arguments.length?this.each(function(t,n){if("function"!=typeof n)throw new Error;return function(){Zt(this,t).ease=n}}(n,t)):Jt(this.node(),n).ease},easeVarying:function(t){if("function"!=typeof t)throw new Error;return this.each(function(t,n){return function(){var e=n.apply(this,arguments);if("function"!=typeof e)throw new Error;Zt(this,t).ease=e}}(this._id,t))},end:function(){var t,n,e=this,r=e._id,i=e.size();return new Promise((function(o,a){var u={value:a},s={value:function(){0==--i&&o()}};e.each((function(){var e=Zt(this,r),i=e.on;i!==t&&((n=(t=i).copy())._.cancel.push(u),n._.interrupt.push(u),n._.end.push(s)),e.on=n})),0===i&&o()}))},[Symbol.iterator]:ve[Symbol.iterator]};var we={time:null,delay:0,duration:250,ease:function(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}};function _e(t,n){for(var e;!(e=t.__transition)||!(e=e[n]);)if(!(t=t.parentNode))throw new Error(`transition ${n} not found`);return e}xt.prototype.interrupt=function(t){return this.each((function(){!function(t,n){var e,r,i,o=t.__transition,a=!0;if(o){for(i in n=null==n?null:n+"",o)(e=o[i]).name===n?(r=e.state>2&&e.state<5,e.state=6,e.timer.stop(),e.on.call(r?"interrupt":"cancel",t,t.__data__,e.index,e.group),delete o[i]):a=!1;a&&delete t.__transition}}(this,t)}))},xt.prototype.transition=function(t){var n,e;t instanceof ye?(n=t._id,t=t._name):(n=me(),(e=we).time=Lt(),t=null==t?null:t+"");for(var r=this._groups,i=r.length,o=0;o<i;++o)for(var a,u=r[o],s=u.length,l=0;l<s;++l)(a=u[l])&&Wt(a,t,n,l,u,e||_e(a,n));return new ye(r,this._parents,t,n)};const{abs:be,max:xe,min:Me}=Math;function ke(t){return{type:t}}function Ae(t,n){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(n).domain(t)}return this}["w","e"].map(ke),["n","s"].map(ke),["n","w","e","s","nw","ne","sw","se"].map(ke);class Ne extends Map{constructor(t,n=$e){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),null!=t)for(const[n,e]of t)this.set(n,e)}get(t){return super.get(Ee(this,t))}has(t){return super.has(Ee(this,t))}set(t,n){return super.set(function({_intern:t,_key:n},e){const r=n(e);return t.has(r)?t.get(r):(t.set(r,e),e)}(this,t),n)}delete(t){return super.delete(function({_intern:t,_key:n},e){const r=n(e);return t.has(r)&&(e=t.get(r),t.delete(r)),e}(this,t))}}function Ee({_intern:t,_key:n},e){const r=n(e);return t.has(r)?t.get(r):e}function $e(t){return null!==t&&"object"==typeof t?t.valueOf():t}Set;const Se=Symbol("implicit");function Ce(){var t=new Ne,n=[],e=[],r=Se;function i(i){let o=t.get(i);if(void 0===o){if(r!==Se)return r;t.set(i,o=n.push(i)-1)}return e[o%e.length]}return i.domain=function(e){if(!arguments.length)return n.slice();n=[],t=new Ne;for(const r of e)t.has(r)||t.set(r,n.push(r)-1);return i},i.range=function(t){return arguments.length?(e=Array.from(t),i):e.slice()},i.unknown=function(t){return arguments.length?(r=t,i):r},i.copy=function(){return Ce(n,e).unknown(r)},Ae.apply(i,arguments),i}function Oe(){var t,n,e=Ce().unknown(void 0),r=e.domain,i=e.range,o=0,a=1,u=!1,s=0,l=0,c=.5;function h(){var e=r().length,h=a<o,f=h?a:o,p=h?o:a;t=(p-f)/Math.max(1,e-s+2*l),u&&(t=Math.floor(t)),f+=(p-f-t*(e-s))*c,n=t*(1-s),u&&(f=Math.round(f),n=Math.round(n));var d=function(t,n,e){t=+t,n=+n,e=(i=arguments.length)<2?(n=t,t=0,1):i<3?1:+e;for(var r=-1,i=0|Math.max(0,Math.ceil((n-t)/e)),o=new Array(i);++r<i;)o[r]=t+r*e;return o}(e).map((function(n){return f+t*n}));return i(h?d.reverse():d)}return delete e.unknown,e.domain=function(t){return arguments.length?(r(t),h()):r()},e.range=function(t){return arguments.length?([o,a]=t,o=+o,a=+a,h()):[o,a]},e.rangeRound=function(t){return[o,a]=t,o=+o,a=+a,u=!0,h()},e.bandwidth=function(){return n},e.step=function(){return t},e.round=function(t){return arguments.length?(u=!!t,h()):u},e.padding=function(t){return arguments.length?(s=Math.min(1,l=+t),h()):s},e.paddingInner=function(t){return arguments.length?(s=Math.min(1,t),h()):s},e.paddingOuter=function(t){return arguments.length?(l=+t,h()):l},e.align=function(t){return arguments.length?(c=Math.max(0,Math.min(1,t)),h()):c},e.copy=function(){return Oe(r(),[o,a]).round(u).paddingInner(s).paddingOuter(l).align(c)},Ae.apply(h(),arguments)}const Pe=Math.sqrt(50),je=Math.sqrt(10),qe=Math.sqrt(2);function He(t,n,e){const r=(n-t)/Math.max(0,e),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),a=o>=Pe?10:o>=je?5:o>=qe?2:1;let u,s,l;return i<0?(l=Math.pow(10,-i)/a,u=Math.round(t*l),s=Math.round(n*l),u/l<t&&++u,s/l>n&&--s,l=-l):(l=Math.pow(10,i)*a,u=Math.round(t/l),s=Math.round(n/l),u*l<t&&++u,s*l>n&&--s),s<u&&.5<=e&&e<2?He(t,n,2*e):[u,s,l]}function Te(t,n,e){return He(t=+t,n=+n,e=+e)[2]}function Xe(t,n){return null==t||null==n?NaN:t<n?-1:t>n?1:t>=n?0:NaN}function ze(t,n){return null==t||null==n?NaN:n<t?-1:n>t?1:n>=t?0:NaN}function Le(t){let n,e,r;function i(t,r,i=0,o=t.length){if(i<o){if(0!==n(r,r))return o;do{const n=i+o>>>1;e(t[n],r)<0?i=n+1:o=n}while(i<o)}return i}return 2!==t.length?(n=Xe,e=(n,e)=>Xe(t(n),e),r=(n,e)=>t(n)-e):(n=t===Xe||t===ze?t:De,e=t,r=t),{left:i,center:function(t,n,e=0,o=t.length){const a=i(t,n,e,o-1);return a>e&&r(t[a-1],n)>-r(t[a],n)?a-1:a},right:function(t,r,i=0,o=t.length){if(i<o){if(0!==n(r,r))return o;do{const n=i+o>>>1;e(t[n],r)<=0?i=n+1:o=n}while(i<o)}return i}}}function De(){return 0}const Re=Le(Xe),Ie=Re.right,Ve=(Re.left,Le((function(t){return null===t?NaN:+t})).center,Ie);function Ye(t,n){var e,r=n?n.length:0,i=t?Math.min(r,t.length):0,o=new Array(i),a=new Array(r);for(e=0;e<i;++e)o[e]=Ue(t[e],n[e]);for(;e<r;++e)a[e]=n[e];return function(t){for(e=0;e<i;++e)a[e]=o[e](t);return a}}function Be(t,n){var e=new Date;return t=+t,n=+n,function(r){return e.setTime(t*(1-r)+n*r),e}}function Fe(t,n){var e,r={},i={};for(e in null!==t&&"object"==typeof t||(t={}),null!==n&&"object"==typeof n||(n={}),n)e in t?r[e]=Ue(t[e],n[e]):i[e]=n[e];return function(t){for(e in r)i[e]=r[e](t);return i}}function Ge(t,n){n||(n=[]);var e,r=t?Math.min(n.length,t.length):0,i=n.slice();return function(o){for(e=0;e<r;++e)i[e]=t[e]*(1-o)+n[e]*o;return i}}function Ue(t,n){var e,r,i=typeof n;return null==n||"boolean"===i?Gn(n):("number"===i?Qt:"string"===i?(e=Cn(n))?(n=e,Wn):Qn:n instanceof Cn?Wn:n instanceof Date?Be:(r=n,!ArrayBuffer.isView(r)||r instanceof DataView?Array.isArray(n)?Ye:"function"!=typeof n.valueOf&&"function"!=typeof n.toString||isNaN(n)?Fe:Qt:Ge))(t,n)}function We(t,n){return t=+t,n=+n,function(e){return Math.round(t*(1-e)+n*e)}}function Ke(t){return+t}var Ze=[0,1];function Je(t){return t}function Qe(t,n){return(n-=t=+t)?function(e){return(e-t)/n}:(e=isNaN(n)?NaN:.5,function(){return e});var e}function tr(t,n,e){var r=t[0],i=t[1],o=n[0],a=n[1];return i<r?(r=Qe(i,r),o=e(a,o)):(r=Qe(r,i),o=e(o,a)),function(t){return o(r(t))}}function nr(t,n,e){var r=Math.min(t.length,n.length)-1,i=new Array(r),o=new Array(r),a=-1;for(t[r]<t[0]&&(t=t.slice().reverse(),n=n.slice().reverse());++a<r;)i[a]=Qe(t[a],t[a+1]),o[a]=e(n[a],n[a+1]);return function(n){var e=Ve(t,n,1,r)-1;return o[e](i[e](n))}}var er,rr=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function ir(t){if(!(n=rr.exec(t)))throw new Error("invalid format: "+t);var n;return new or({fill:n[1],align:n[2],sign:n[3],symbol:n[4],zero:n[5],width:n[6],comma:n[7],precision:n[8]&&n[8].slice(1),trim:n[9],type:n[10]})}function or(t){this.fill=void 0===t.fill?" ":t.fill+"",this.align=void 0===t.align?">":t.align+"",this.sign=void 0===t.sign?"-":t.sign+"",this.symbol=void 0===t.symbol?"":t.symbol+"",this.zero=!!t.zero,this.width=void 0===t.width?void 0:+t.width,this.comma=!!t.comma,this.precision=void 0===t.precision?void 0:+t.precision,this.trim=!!t.trim,this.type=void 0===t.type?"":t.type+""}function ar(t,n){if((e=(t=n?t.toExponential(n-1):t.toExponential()).indexOf("e"))<0)return null;var e,r=t.slice(0,e);return[r.length>1?r[0]+r.slice(2):r,+t.slice(e+1)]}function ur(t){return(t=ar(Math.abs(t)))?t[1]:NaN}function sr(t,n){var e=ar(t,n);if(!e)return t+"";var r=e[0],i=e[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}ir.prototype=or.prototype,or.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};const lr={"%":(t,n)=>(100*t).toFixed(n),b:t=>Math.round(t).toString(2),c:t=>t+"",d:function(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)},e:(t,n)=>t.toExponential(n),f:(t,n)=>t.toFixed(n),g:(t,n)=>t.toPrecision(n),o:t=>Math.round(t).toString(8),p:(t,n)=>sr(100*t,n),r:sr,s:function(t,n){var e=ar(t,n);if(!e)return t+"";var r=e[0],i=e[1],o=i-(er=3*Math.max(-8,Math.min(8,Math.floor(i/3))))+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+ar(t,Math.max(0,n+o-1))[0]},X:t=>Math.round(t).toString(16).toUpperCase(),x:t=>Math.round(t).toString(16)};function cr(t){return t}var hr,fr,pr,dr=Array.prototype.map,gr=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function yr(t){var n=t.domain;return t.ticks=function(t){var e=n();return function(t,n,e){if(!((e=+e)>0))return[];if((t=+t)==(n=+n))return[t];const r=n<t,[i,o,a]=r?He(n,t,e):He(t,n,e);if(!(o>=i))return[];const u=o-i+1,s=new Array(u);if(r)if(a<0)for(let t=0;t<u;++t)s[t]=(o-t)/-a;else for(let t=0;t<u;++t)s[t]=(o-t)*a;else if(a<0)for(let t=0;t<u;++t)s[t]=(i+t)/-a;else for(let t=0;t<u;++t)s[t]=(i+t)*a;return s}(e[0],e[e.length-1],null==t?10:t)},t.tickFormat=function(t,e){var r=n();return function(t,n,e,r){var i,o=function(t,n,e){e=+e;const r=(n=+n)<(t=+t),i=r?Te(n,t,e):Te(t,n,e);return(r?-1:1)*(i<0?1/-i:i)}(t,n,e);switch((r=ir(null==r?",f":r)).type){case"s":var a=Math.max(Math.abs(t),Math.abs(n));return null!=r.precision||isNaN(i=function(t,n){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(ur(n)/3)))-ur(Math.abs(t)))}(o,a))||(r.precision=i),pr(r,a);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(i=function(t,n){return t=Math.abs(t),n=Math.abs(n)-t,Math.max(0,ur(n)-ur(t))+1}(o,Math.max(Math.abs(t),Math.abs(n))))||(r.precision=i-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(i=function(t){return Math.max(0,-ur(Math.abs(t)))}(o))||(r.precision=i-2*("%"===r.type))}return fr(r)}(r[0],r[r.length-1],null==t?10:t,e)},t.nice=function(e){null==e&&(e=10);var r,i,o=n(),a=0,u=o.length-1,s=o[a],l=o[u],c=10;for(l<s&&(i=s,s=l,l=i,i=a,a=u,u=i);c-- >0;){if((i=Te(s,l,e))===r)return o[a]=s,o[u]=l,n(o);if(i>0)s=Math.floor(s/i)*i,l=Math.ceil(l/i)*i;else{if(!(i<0))break;s=Math.ceil(s*i)/i,l=Math.floor(l*i)/i}r=i}return t},t}function mr(){var t=function(){var t,n,e,r,i,o,a=Ze,u=Ze,s=Ue,l=Je;function c(){var t,n,e,s=Math.min(a.length,u.length);return l!==Je&&(t=a[0],n=a[s-1],t>n&&(e=t,t=n,n=e),l=function(e){return Math.max(t,Math.min(n,e))}),r=s>2?nr:tr,i=o=null,h}function h(n){return null==n||isNaN(n=+n)?e:(i||(i=r(a.map(t),u,s)))(t(l(n)))}return h.invert=function(e){return l(n((o||(o=r(u,a.map(t),Qt)))(e)))},h.domain=function(t){return arguments.length?(a=Array.from(t,Ke),c()):a.slice()},h.range=function(t){return arguments.length?(u=Array.from(t),c()):u.slice()},h.rangeRound=function(t){return u=Array.from(t),s=We,c()},h.clamp=function(t){return arguments.length?(l=!!t||Je,c()):l!==Je},h.interpolate=function(t){return arguments.length?(s=t,c()):s},h.unknown=function(t){return arguments.length?(e=t,h):e},function(e,r){return t=e,n=r,c()}}()(Je,Je);return t.copy=function(){return n=t,mr().domain(n.domain()).range(n.range()).interpolate(n.interpolate()).clamp(n.clamp()).unknown(n.unknown());var n},Ae.apply(t,arguments),yr(t)}function vr(t,n,e){this.k=t,this.x=n,this.y=e}function wr(n,e){const r=n.querySelector(".bar-graph-container");if(!r)return;r.innerHTML="";const i=r.clientWidth,o=i-60-20,a=e.chartHeight-40-60,u=[];e.chartData&&"object"==typeof e.chartData&&Object.entries(e.chartData).forEach((([t,n])=>{Array.isArray(n)&&n.forEach((n=>{u.push({dataset:t,label:n.label||"",value:parseFloat(n.value)||0,color:n.color||e.barColor})}))}));const s=function(t){return"string"==typeof t?new _t([[document.querySelector(t)]],[document.documentElement]):new _t([[t]],wt)}(r).append("svg").attr("width",i).attr("height",e.chartHeight).style("background-color",e.backgroundColor),h=s.append("g").attr("transform","translate(60,40)"),f=Oe().domain(u.map((t=>t.label))).range([0,o]).padding(.1),p=mr().domain([0,t(u,(t=>t.value))||100]).range([a,0]);e.showGridX&&h.append("g").attr("class","grid x-grid").attr("transform",`translate(0,${a})`).style("color",e.xGridColor).style("stroke-width",e.xGridWidth).call(l(f).tickSize(-a).tickFormat("")),e.showGridY&&h.append("g").attr("class","grid y-grid").style("color",e.yGridColor).style("stroke-width",e.yGridWidth).call(c(p).tickSize(-o).tickFormat("")),h.selectAll("rect").data(u).enter().append("rect").attr("x",(t=>f(t.label))).attr("y",(t=>p(t.value))).attr("width",f.bandwidth()).attr("height",(t=>a-p(t.value))).attr("fill",(t=>(t=>{switch(e.chartColorSource){case"singleColor":return e.barColor;case"customColors":const n=e.chartCustomColors?.find((n=>n.dataset===t.dataset&&n.label===t.label));return n?n.color:t.color;default:return t.color}})(t))).style("opacity",e.barOpacity),e.showBarValues&&h.selectAll(".bar-value").data(u).enter().append("text").attr("class","bar-value").attr("x",(t=>f(t.label)+f.bandwidth()/2)).attr("y",(t=>p(t.value)-5)).attr("text-anchor","middle").text((t=>t.value)),h.append("g").attr("class","x-axis").attr("transform",`translate(0,${a})`).call(l(f)).selectAll("text").style("text-anchor","end").attr("dx","-.8em").attr("dy",".15em").attr("transform","rotate(-45)"),h.append("g").attr("class","y-axis").call(c(p)),e.displayChartTitle&&e.chartTitle&&s.append("text").attr("x",i/2).attr("y",20).attr("text-anchor","middle").style("font-size","16px").text(e.chartTitle),e.xAxisLabel&&s.append("text").attr("x",i/2).attr("y",e.chartHeight-10).attr("text-anchor","middle").text(e.xAxisLabel),e.yAxisLabel&&s.append("text").attr("transform","rotate(-90)").attr("x",-e.chartHeight/2).attr("y",20).attr("text-anchor","middle").text(e.yAxisLabel),new ResizeObserver((()=>{r.clientWidth!==i&&(r.innerHTML="",wr(n,e))})).observe(r)}hr=function(t){var n,e,r=void 0===t.grouping||void 0===t.thousands?cr:(n=dr.call(t.grouping,Number),e=t.thousands+"",function(t,r){for(var i=t.length,o=[],a=0,u=n[0],s=0;i>0&&u>0&&(s+u+1>r&&(u=Math.max(1,r-s)),o.push(t.substring(i-=u,i+u)),!((s+=u+1)>r));)u=n[a=(a+1)%n.length];return o.reverse().join(e)}),i=void 0===t.currency?"":t.currency[0]+"",o=void 0===t.currency?"":t.currency[1]+"",a=void 0===t.decimal?".":t.decimal+"",u=void 0===t.numerals?cr:function(t){return function(n){return n.replace(/[0-9]/g,(function(n){return t[+n]}))}}(dr.call(t.numerals,String)),s=void 0===t.percent?"%":t.percent+"",l=void 0===t.minus?"−":t.minus+"",c=void 0===t.nan?"NaN":t.nan+"";function h(t){var n=(t=ir(t)).fill,e=t.align,h=t.sign,f=t.symbol,p=t.zero,d=t.width,g=t.comma,y=t.precision,m=t.trim,v=t.type;"n"===v?(g=!0,v="g"):lr[v]||(void 0===y&&(y=12),m=!0,v="g"),(p||"0"===n&&"="===e)&&(p=!0,n="0",e="=");var w="$"===f?i:"#"===f&&/[boxX]/.test(v)?"0"+v.toLowerCase():"",_="$"===f?o:/[%p]/.test(v)?s:"",b=lr[v],x=/[defgprs%]/.test(v);function M(t){var i,o,s,f=w,M=_;if("c"===v)M=b(t)+M,t="";else{var k=(t=+t)<0||1/t<0;if(t=isNaN(t)?c:b(Math.abs(t),y),m&&(t=function(t){t:for(var n,e=t.length,r=1,i=-1;r<e;++r)switch(t[r]){case".":i=n=r;break;case"0":0===i&&(i=r),n=r;break;default:if(!+t[r])break t;i>0&&(i=0)}return i>0?t.slice(0,i)+t.slice(n+1):t}(t)),k&&0==+t&&"+"!==h&&(k=!1),f=(k?"("===h?h:l:"-"===h||"("===h?"":h)+f,M=("s"===v?gr[8+er/3]:"")+M+(k&&"("===h?")":""),x)for(i=-1,o=t.length;++i<o;)if(48>(s=t.charCodeAt(i))||s>57){M=(46===s?a+t.slice(i+1):t.slice(i))+M,t=t.slice(0,i);break}}g&&!p&&(t=r(t,1/0));var A=f.length+t.length+M.length,N=A<d?new Array(d-A+1).join(n):"";switch(g&&p&&(t=r(N+t,N.length?d-M.length:1/0),N=""),e){case"<":t=f+t+M+N;break;case"=":t=f+N+t+M;break;case"^":t=N.slice(0,A=N.length>>1)+f+t+M+N.slice(A);break;default:t=N+f+t+M}return u(t)}return y=void 0===y?6:/[gprs]/.test(v)?Math.max(1,Math.min(21,y)):Math.max(0,Math.min(20,y)),M.toString=function(){return t+""},M}return{format:h,formatPrefix:function(t,n){var e=h(((t=ir(t)).type="f",t)),r=3*Math.max(-8,Math.min(8,Math.floor(ur(n)/3))),i=Math.pow(10,-r),o=gr[8+r/3];return function(t){return e(i*t)+o}}}}({thousands:",",grouping:[3],currency:["$",""]}),fr=hr.format,pr=hr.formatPrefix,vr.prototype={constructor:vr,scale:function(t){return 1===t?this:new vr(this.k*t,this.x,this.y)},translate:function(t,n){return 0===t&0===n?this:new vr(this.k,this.x+this.k*t,this.y+this.k*n)},apply:function(t){return[t[0]*this.k+this.x,t[1]*this.k+this.y]},applyX:function(t){return t*this.k+this.x},applyY:function(t){return t*this.k+this.y},invert:function(t){return[(t[0]-this.x)/this.k,(t[1]-this.y)/this.k]},invertX:function(t){return(t-this.x)/this.k},invertY:function(t){return(t-this.y)/this.k},rescaleX:function(t){return t.copy().domain(t.range().map(this.invertX,this).map(t.invert,t))},rescaleY:function(t){return t.copy().domain(t.range().map(this.invertY,this).map(t.invert,t))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}},new vr(1,0,0),vr.prototype,window.addEventListener("load",(function(){window.lcpBarGraphData&&Object.entries(window.lcpBarGraphData).forEach((([t,n])=>{const{attributes:e}=n,r=document.getElementById(t);r&&wr(r,e)}))}))})(); |