billboard.js 3.14.2 → 3.14.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. package/dist/billboard.css +1 -1
  2. package/dist/billboard.js +7 -6
  3. package/dist/billboard.min.css +1 -1
  4. package/dist/billboard.min.js +3 -3
  5. package/dist/billboard.pkgd.js +7 -6
  6. package/dist/billboard.pkgd.min.js +17 -17
  7. package/dist/plugin/billboardjs-plugin-bubblecompare.js +2 -2
  8. package/dist/plugin/billboardjs-plugin-bubblecompare.min.js +2 -2
  9. package/dist/plugin/billboardjs-plugin-sparkline.js +2 -2
  10. package/dist/plugin/billboardjs-plugin-sparkline.min.js +2 -2
  11. package/dist/plugin/billboardjs-plugin-stanford.js +2 -2
  12. package/dist/plugin/billboardjs-plugin-stanford.min.js +2 -2
  13. package/dist/plugin/billboardjs-plugin-tableview.js +2 -2
  14. package/dist/plugin/billboardjs-plugin-tableview.min.js +2 -2
  15. package/dist/plugin/billboardjs-plugin-textoverlap.js +2 -2
  16. package/dist/plugin/billboardjs-plugin-textoverlap.min.js +2 -2
  17. package/dist/plugin/pkgd/billboardjs-plugin-bubblecompare.pkgd.js +2 -2
  18. package/dist/plugin/pkgd/billboardjs-plugin-bubblecompare.pkgd.min.js +2 -2
  19. package/dist/plugin/pkgd/billboardjs-plugin-sparkline.pkgd.js +2 -2
  20. package/dist/plugin/pkgd/billboardjs-plugin-sparkline.pkgd.min.js +2 -2
  21. package/dist/plugin/pkgd/billboardjs-plugin-stanford.pkgd.js +2 -2
  22. package/dist/plugin/pkgd/billboardjs-plugin-stanford.pkgd.min.js +2 -2
  23. package/dist/plugin/pkgd/billboardjs-plugin-tableview.pkgd.js +2 -2
  24. package/dist/plugin/pkgd/billboardjs-plugin-tableview.pkgd.min.js +2 -2
  25. package/dist/plugin/pkgd/billboardjs-plugin-textoverlap.pkgd.js +2 -2
  26. package/dist/plugin/pkgd/billboardjs-plugin-textoverlap.pkgd.min.js +2 -2
  27. package/dist/theme/dark.css +1 -1
  28. package/dist/theme/dark.min.css +1 -1
  29. package/dist/theme/datalab.css +1 -1
  30. package/dist/theme/datalab.min.css +1 -1
  31. package/dist/theme/graph.css +1 -1
  32. package/dist/theme/graph.min.css +1 -1
  33. package/dist/theme/insight.css +1 -1
  34. package/dist/theme/insight.min.css +1 -1
  35. package/dist/theme/modern.css +1 -1
  36. package/dist/theme/modern.min.css +1 -1
  37. package/dist-esm/billboard.js +377 -376
  38. package/dist-esm/plugin/billboardjs-plugin-bubblecompare.js +4 -4
  39. package/dist-esm/plugin/billboardjs-plugin-sparkline.js +15 -15
  40. package/dist-esm/plugin/billboardjs-plugin-stanford.js +13 -13
  41. package/dist-esm/plugin/billboardjs-plugin-tableview.js +10 -10
  42. package/dist-esm/plugin/billboardjs-plugin-textoverlap.js +8 -8
  43. package/package.json +29 -29
  44. package/src/ChartInternal/data/data.ts +1 -1
  45. package/src/ChartInternal/interactions/interaction.ts +1 -1
  46. package/src/config/Options/shape/gauge.ts +3 -2
  47. package/types/options.shape.d.ts +3 -2
@@ -5,7 +5,7 @@
5
5
  * billboard.js, JavaScript chart library
6
6
  * https://naver.github.io/billboard.js/
7
7
  *
8
- * @version 3.14.2
8
+ * @version 3.14.3
9
9
  * @requires billboard.js
10
10
  * @summary billboard.js plugin
11
11
  */
@@ -24624,7 +24624,7 @@ class Plugin {
24624
24624
  });
24625
24625
  }
24626
24626
  }
24627
- __publicField(Plugin, "version", "3.14.2");
24627
+ __publicField(Plugin, "version", "3.14.3");
24628
24628
 
24629
24629
  ;// ./node_modules/d3-axis/src/identity.js
24630
24630
  /* harmony default export */ function d3_axis_src_identity(x) {
@@ -5,12 +5,12 @@
5
5
  * billboard.js, JavaScript chart library
6
6
  * https://naver.github.io/billboard.js/
7
7
  *
8
- * @version 3.14.2
8
+ * @version 3.14.3
9
9
  * @requires billboard.js
10
10
  * @summary billboard.js plugin
11
11
  */(function(qr,Gr){typeof exports=="object"&&typeof module=="object"?module.exports=Gr():typeof define=="function"&&define.amd?define("bb",[],Gr):typeof exports=="object"?exports.bb=Gr():(qr.bb=qr.bb||{},qr.bb.plugin=qr.bb.plugin||{},qr.bb.plugin["stanford.pkgd"]=Gr())})(this,function(){return function(){"use strict";var Ne={33539:function(u,h,t){t.d(h,{default:function(){return mf}});function n(r,o,l){r.prototype=o.prototype=l,l.constructor=r}function e(r,o){var l=Object.create(r.prototype);for(var g in o)l[g]=o[g];return l}function a(){}var s=.7,i=1/s,f="\\s*([+-]?\\d+)\\s*",c="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",v="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",d=/^#([0-9a-f]{3,8})$/,p=new RegExp(`^rgb\\(${f},${f},${f}\\)$`),y=new RegExp(`^rgb\\(${v},${v},${v}\\)$`),m=new RegExp(`^rgba\\(${f},${f},${f},${c}\\)$`),S=new RegExp(`^rgba\\(${v},${v},${v},${c}\\)$`),I=new RegExp(`^hsl\\(${c},${v},${v}\\)$`),E=new RegExp(`^hsla\\(${c},${v},${v},${c}\\)$`),R={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};n(a,A,{copy(r){return Object.assign(new this.constructor,this,r)},displayable(){return this.rgb().displayable()},hex:N,formatHex:N,formatHex8:P,formatHsl:C,formatRgb:b,toString:b});function N(){return this.rgb().formatHex()}function P(){return this.rgb().formatHex8()}function C(){return q(this).formatHsl()}function b(){return this.rgb().formatRgb()}function A(r){var o,l;return r=(r+"").trim().toLowerCase(),(o=d.exec(r))?(l=o[1].length,o=parseInt(o[1],16),l===6?M(o):l===3?new j(o>>8&15|o>>4&240,o>>4&15|o&240,(o&15)<<4|o&15,1):l===8?F(o>>24&255,o>>16&255,o>>8&255,(o&255)/255):l===4?F(o>>12&15|o>>8&240,o>>8&15|o>>4&240,o>>4&15|o&240,((o&15)<<4|o&15)/255):null):(o=p.exec(r))?new j(o[1],o[2],o[3],1):(o=y.exec(r))?new j(o[1]*255/100,o[2]*255/100,o[3]*255/100,1):(o=m.exec(r))?F(o[1],o[2],o[3],o[4]):(o=S.exec(r))?F(o[1]*255/100,o[2]*255/100,o[3]*255/100,o[4]):(o=I.exec(r))?tt(o[1],o[2]/100,o[3]/100,1):(o=E.exec(r))?tt(o[1],o[2]/100,o[3]/100,o[4]):R.hasOwnProperty(r)?M(R[r]):r==="transparent"?new j(NaN,NaN,NaN,0):null}function M(r){return new j(r>>16&255,r>>8&255,r&255,1)}function F(r,o,l,g){return g<=0&&(r=o=l=NaN),new j(r,o,l,g)}function B(r){return r instanceof a||(r=A(r)),r?(r=r.rgb(),new j(r.r,r.g,r.b,r.opacity)):new j}function U(r,o,l,g){return arguments.length===1?B(r):new j(r,o,l,g==null?1:g)}function j(r,o,l,g){this.r=+r,this.g=+o,this.b=+l,this.opacity=+g}n(j,U,e(a,{brighter(r){return r=r==null?i:Math.pow(i,r),new j(this.r*r,this.g*r,this.b*r,this.opacity)},darker(r){return r=r==null?s:Math.pow(s,r),new j(this.r*r,this.g*r,this.b*r,this.opacity)},rgb(){return this},clamp(){return new j(V(this.r),V(this.g),V(this.b),G(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:W,formatHex:W,formatHex8:z,formatRgb:w,toString:w}));function W(){return`#${X(this.r)}${X(this.g)}${X(this.b)}`}function z(){return`#${X(this.r)}${X(this.g)}${X(this.b)}${X((isNaN(this.opacity)?1:this.opacity)*255)}`}function w(){const r=G(this.opacity);return`${r===1?"rgb(":"rgba("}${V(this.r)}, ${V(this.g)}, ${V(this.b)}${r===1?")":`, ${r})`}`}function G(r){return isNaN(r)?1:Math.max(0,Math.min(1,r))}function V(r){return Math.max(0,Math.min(255,Math.round(r)||0))}function X(r){return r=V(r),(r<16?"0":"")+r.toString(16)}function tt(r,o,l,g){return g<=0?r=o=l=NaN:l<=0||l>=1?r=o=NaN:o<=0&&(r=NaN),new Z(r,o,l,g)}function q(r){if(r instanceof Z)return new Z(r.h,r.s,r.l,r.opacity);if(r instanceof a||(r=A(r)),!r)return new Z;if(r instanceof Z)return r;r=r.rgb();var o=r.r/255,l=r.g/255,g=r.b/255,x=Math.min(o,l,g),O=Math.max(o,l,g),T=NaN,D=O-x,$=(O+x)/2;return D?(o===O?T=(l-g)/D+(l<g)*6:l===O?T=(g-o)/D+2:T=(o-l)/D+4,D/=$<.5?O+x:2-O-x,T*=60):D=$>0&&$<1?0:T,new Z(T,D,$,r.opacity)}function rt(r,o,l,g){return arguments.length===1?q(r):new Z(r,o,l,g==null?1:g)}function Z(r,o,l,g){this.h=+r,this.s=+o,this.l=+l,this.opacity=+g}n(Z,rt,e(a,{brighter(r){return r=r==null?i:Math.pow(i,r),new Z(this.h,this.s,this.l*r,this.opacity)},darker(r){return r=r==null?s:Math.pow(s,r),new Z(this.h,this.s,this.l*r,this.opacity)},rgb(){var r=this.h%360+(this.h<0)*360,o=isNaN(r)||isNaN(this.s)?0:this.s,l=this.l,g=l+(l<.5?l:1-l)*o,x=2*l-g;return new j(xt(r>=240?r-240:r+120,x,g),xt(r,x,g),xt(r<120?r+240:r-120,x,g),this.opacity)},clamp(){return new Z(mt(this.h),ht(this.s),ht(this.l),G(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 r=G(this.opacity);return`${r===1?"hsl(":"hsla("}${mt(this.h)}, ${ht(this.s)*100}%, ${ht(this.l)*100}%${r===1?")":`, ${r})`}`}}));function mt(r){return r=(r||0)%360,r<0?r+360:r}function ht(r){return Math.max(0,Math.min(1,r||0))}function xt(r,o,l){return(r<60?o+(l-o)*r/60:r<180?l:r<240?o+(l-o)*(240-r)/60:o)*255}var Rt=r=>()=>r;function Nt(r,o){return function(l){return r+l*o}}function Jt(r,o,l){return r=Math.pow(r,l),o=Math.pow(o,l)-r,l=1/l,function(g){return Math.pow(r+g*o,l)}}function Xt(r,o){var l=o-r;return l?Nt(r,l>180||l<-180?l-360*Math.round(l/360):l):Rt(isNaN(r)?o:r)}function jt(r){return(r=+r)==1?vt:function(o,l){return l-o?Jt(o,l,r):Rt(isNaN(o)?l:o)}}function vt(r,o){var l=o-r;return l?Nt(r,l):Rt(isNaN(r)?o:r)}function Et(r){return function(o,l){var g=r((o=rt(o)).h,(l=rt(l)).h),x=vt(o.s,l.s),O=vt(o.l,l.l),T=vt(o.opacity,l.opacity);return function(D){return o.h=g(D),o.s=x(D),o.l=O(D),o.opacity=T(D),o+""}}}var $t=Et(Xt),Bt=Et(vt);function Ft(r,o,l,g,x){var O=r*r,T=O*r;return((1-3*r+3*O-T)*o+(4-6*O+3*T)*l+(1+3*r+3*O-3*T)*g+T*x)/6}function Vt(r){var o=r.length-1;return function(l){var g=l<=0?l=0:l>=1?(l=1,o-1):Math.floor(l*o),x=r[g],O=r[g+1],T=g>0?r[g-1]:2*x-O,D=g<o-1?r[g+2]:2*O-x;return Ft((l-g/o)*o,T,x,O,D)}}function nr(r){var o=r.length;return function(l){var g=Math.floor(((l%=1)<0?++l:l)*o),x=r[(g+o-1)%o],O=r[g%o],T=r[(g+1)%o],D=r[(g+2)%o];return Ft((l-g/o)*o,x,O,T,D)}}var tr=function r(o){var l=jt(o);function g(x,O){var T=l((x=U(x)).r,(O=U(O)).r),D=l(x.g,O.g),$=l(x.b,O.b),L=vt(x.opacity,O.opacity);return function(H){return x.r=T(H),x.g=D(H),x.b=$(H),x.opacity=L(H),x+""}}return g.gamma=r,g}(1);function Zt(r){return function(o){var l=o.length,g=new Array(l),x=new Array(l),O=new Array(l),T,D;for(T=0;T<l;++T)D=U(o[T]),g[T]=D.r||0,x[T]=D.g||0,O[T]=D.b||0;return g=r(g),x=r(x),O=r(O),D.opacity=1,function($){return D.r=g($),D.g=x($),D.b=O($),D+""}}}var Ht=Zt(Vt),rr=Zt(nr);function Qt(r,o){return(isNumberArray(o)?numberArray:wt)(r,o)}function wt(r,o){var l=o?o.length:0,g=r?Math.min(l,r.length):0,x=new Array(g),O=new Array(l),T;for(T=0;T<g;++T)x[T]=ot(r[T],o[T]);for(;T<l;++T)O[T]=o[T];return function(D){for(T=0;T<g;++T)O[T]=x[T](D);return O}}function ft(r,o){var l=new Date;return r=+r,o=+o,function(g){return l.setTime(r*(1-g)+o*g),l}}function ct(r,o){return r=+r,o=+o,function(l){return r*(1-l)+o*l}}function nt(r,o){var l={},g={},x;(r===null||typeof r!="object")&&(r={}),(o===null||typeof o!="object")&&(o={});for(x in o)x in r?l[x]=ot(r[x],o[x]):g[x]=o[x];return function(O){for(x in l)g[x]=l[x](O);return g}}var Mt=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,bt=new RegExp(Mt.source,"g");function At(r){return function(){return r}}function Tt(r){return function(o){return r(o)+""}}function ur(r,o){var l=Mt.lastIndex=bt.lastIndex=0,g,x,O,T=-1,D=[],$=[];for(r=r+"",o=o+"";(g=Mt.exec(r))&&(x=bt.exec(o));)(O=x.index)>l&&(O=o.slice(l,O),D[T]?D[T]+=O:D[++T]=O),(g=g[0])===(x=x[0])?D[T]?D[T]+=x:D[++T]=x:(D[++T]=null,$.push({i:T,x:ct(g,x)})),l=bt.lastIndex;return l<o.length&&(O=o.slice(l),D[T]?D[T]+=O:D[++T]=O),D.length<2?$[0]?Tt($[0].x):At(o):(o=$.length,function(L){for(var H=0,K;H<o;++H)D[(K=$[H]).i]=K.x(L);return D.join("")})}function vr(r,o){o||(o=[]);var l=r?Math.min(o.length,r.length):0,g=o.slice(),x;return function(O){for(x=0;x<l;++x)g[x]=r[x]*(1-O)+o[x]*O;return g}}function Q(r){return ArrayBuffer.isView(r)&&!(r instanceof DataView)}function ot(r,o){var l=typeof o,g;return o==null||l==="boolean"?Rt(o):(l==="number"?ct:l==="string"?(g=A(o))?(o=g,tr):ur:o instanceof A?tr:o instanceof Date?ft:Q(o)?vr:Array.isArray(o)?wt:typeof o.valueOf!="function"&&typeof o.toString!="function"||isNaN(o)?nt:ct)(r,o)}function lt(r,o){return r=+r,o=+o,function(l){return Math.round(r*(1-l)+o*l)}}function st(r,o){return r==null||o==null?NaN:r<o?-1:r>o?1:r>=o?0:NaN}function yt(r,o){return r==null||o==null?NaN:o<r?-1:o>r?1:o>=r?0:NaN}function at(r){let o,l,g;r.length!==2?(o=st,l=(D,$)=>st(r(D),$),g=(D,$)=>r(D)-$):(o=r===st||r===yt?r:Lt,l=r,g=r);function x(D,$,L=0,H=D.length){if(L<H){if(o($,$)!==0)return H;do{const K=L+H>>>1;l(D[K],$)<0?L=K+1:H=K}while(L<H)}return L}function O(D,$,L=0,H=D.length){if(L<H){if(o($,$)!==0)return H;do{const K=L+H>>>1;l(D[K],$)<=0?L=K+1:H=K}while(L<H)}return L}function T(D,$,L=0,H=D.length){const K=x(D,$,L,H-1);return K>L&&g(D[K-1],$)>-g(D[K],$)?K-1:K}return{left:x,center:T,right:O}}function Lt(){return 0}function er(r){return r===null?NaN:+r}function*it(r,o){if(o===void 0)for(let l of r)l!=null&&(l=+l)>=l&&(yield l);else{let l=-1;for(let g of r)(g=o(g,++l,r))!=null&&(g=+g)>=g&&(yield g)}}const St=at(st),It=St.right,Ot=St.left,Wt=at(er).center;var _t=It;function ir(r){return function(){return r}}function lr(r){return+r}var mr=[0,1];function dr(r){return r}function Lr(r,o){return(o-=r=+r)?function(l){return(l-r)/o}:ir(isNaN(o)?NaN:.5)}function dn(r,o){var l;return r>o&&(l=r,r=o,o=l),function(g){return Math.max(r,Math.min(o,g))}}function Nn(r,o,l){var g=r[0],x=r[1],O=o[0],T=o[1];return x<g?(g=Lr(x,g),O=l(T,O)):(g=Lr(g,x),O=l(O,T)),function(D){return O(g(D))}}function hn(r,o,l){var g=Math.min(r.length,o.length)-1,x=new Array(g),O=new Array(g),T=-1;for(r[g]<r[0]&&(r=r.slice().reverse(),o=o.slice().reverse());++T<g;)x[T]=Lr(r[T],r[T+1]),O[T]=l(o[T],o[T+1]);return function(D){var $=_t(r,D,1,g)-1;return O[$](x[$](D))}}function _r(r,o){return o.domain(r.domain()).range(r.range()).interpolate(r.interpolate()).clamp(r.clamp()).unknown(r.unknown())}function jr(){var r=mr,o=mr,l=ot,g,x,O,T=dr,D,$,L;function H(){var _=Math.min(r.length,o.length);return T!==dr&&(T=dn(r[0],r[_-1])),D=_>2?hn:Nn,$=L=null,K}function K(_){return _==null||isNaN(_=+_)?O:($||($=D(r.map(g),o,l)))(g(T(_)))}return K.invert=function(_){return T(x((L||(L=D(o,r.map(g),ct)))(_)))},K.domain=function(_){return arguments.length?(r=Array.from(_,lr),H()):r.slice()},K.range=function(_){return arguments.length?(o=Array.from(_),H()):o.slice()},K.rangeRound=function(_){return o=Array.from(_),l=lt,H()},K.clamp=function(_){return arguments.length?(T=_?!0:dr,H()):T!==dr},K.interpolate=function(_){return arguments.length?(l=_,H()):l},K.unknown=function(_){return arguments.length?(O=_,K):O},function(_,et){return g=_,x=et,H()}}function ee(){return jr()(dr,dr)}function Jr(r,o){switch(arguments.length){case 0:break;case 1:this.range(r);break;default:this.range(o).domain(r);break}return this}function Vr(r,o){switch(arguments.length){case 0:break;case 1:{typeof r=="function"?this.interpolator(r):this.range(r);break}default:{this.domain(r),typeof o=="function"?this.interpolator(o):this.range(o);break}}return this}const gn=Math.sqrt(50),tn=Math.sqrt(10),Mr=Math.sqrt(2);function br(r,o,l){const g=(o-r)/Math.max(0,l),x=Math.floor(Math.log10(g)),O=g/Math.pow(10,x),T=O>=gn?10:O>=tn?5:O>=Mr?2:1;let D,$,L;return x<0?(L=Math.pow(10,-x)/T,D=Math.round(r*L),$=Math.round(o*L),D/L<r&&++D,$/L>o&&--$,L=-L):(L=Math.pow(10,x)*T,D=Math.round(r/L),$=Math.round(o/L),D*L<r&&++D,$*L>o&&--$),$<D&&.5<=l&&l<2?br(r,o,l*2):[D,$,L]}function an(r,o,l){if(o=+o,r=+r,l=+l,!(l>0))return[];if(r===o)return[r];const g=o<r,[x,O,T]=g?br(o,r,l):br(r,o,l);if(!(O>=x))return[];const D=O-x+1,$=new Array(D);if(g)if(T<0)for(let L=0;L<D;++L)$[L]=(O-L)/-T;else for(let L=0;L<D;++L)$[L]=(O-L)*T;else if(T<0)for(let L=0;L<D;++L)$[L]=(x+L)/-T;else for(let L=0;L<D;++L)$[L]=(x+L)*T;return $}function on(r,o,l){return o=+o,r=+r,l=+l,br(r,o,l)[2]}function J(r,o,l){o=+o,r=+r,l=+l;const g=o<r,x=g?on(o,r,l):on(r,o,l);return(g?-1:1)*(x<0?1/-x:x)}var gt=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function k(r){if(!(o=gt.exec(r)))throw new Error("invalid format: "+r);var o;return new Y({fill:o[1],align:o[2],sign:o[3],symbol:o[4],zero:o[5],width:o[6],comma:o[7],precision:o[8]&&o[8].slice(1),trim:o[9],type:o[10]})}k.prototype=Y.prototype;function Y(r){this.fill=r.fill===void 0?" ":r.fill+"",this.align=r.align===void 0?">":r.align+"",this.sign=r.sign===void 0?"-":r.sign+"",this.symbol=r.symbol===void 0?"":r.symbol+"",this.zero=!!r.zero,this.width=r.width===void 0?void 0:+r.width,this.comma=!!r.comma,this.precision=r.precision===void 0?void 0:+r.precision,this.trim=!!r.trim,this.type=r.type===void 0?"":r.type+""}Y.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 ut(r){return Math.abs(r=Math.round(r))>=1e21?r.toLocaleString("en").replace(/,/g,""):r.toString(10)}function Kt(r,o){if((l=(r=o?r.toExponential(o-1):r.toExponential()).indexOf("e"))<0)return null;var l,g=r.slice(0,l);return[g.length>1?g[0]+g.slice(2):g,+r.slice(l+1)]}function Pt(r){return r=Kt(Math.abs(r)),r?r[1]:NaN}function xr(r,o){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Pt(o)/3)))*3-Pt(Math.abs(r)))}function Or(r,o){return function(l,g){for(var x=l.length,O=[],T=0,D=r[0],$=0;x>0&&D>0&&($+D+1>g&&(D=Math.max(1,g-$)),O.push(l.substring(x-=D,x+D)),!(($+=D+1)>g));)D=r[T=(T+1)%r.length];return O.reverse().join(o)}}function Rr(r){return function(o){return o.replace(/[0-9]/g,function(l){return r[+l]})}}function Ur(r){t:for(var o=r.length,l=1,g=-1,x;l<o;++l)switch(r[l]){case".":g=x=l;break;case"0":g===0&&(g=l),x=l;break;default:if(!+r[l])break t;g>0&&(g=0);break}return g>0?r.slice(0,g)+r.slice(x+1):r}var dt;function Tr(r,o){var l=Kt(r,o);if(!l)return r+"";var g=l[0],x=l[1],O=x-(dt=Math.max(-8,Math.min(8,Math.floor(x/3)))*3)+1,T=g.length;return O===T?g:O>T?g+new Array(O-T+1).join("0"):O>0?g.slice(0,O)+"."+g.slice(O):"0."+new Array(1-O).join("0")+Kt(r,Math.max(0,o+O-1))[0]}function Hr(r,o){var l=Kt(r,o);if(!l)return r+"";var g=l[0],x=l[1];return x<0?"0."+new Array(-x).join("0")+g:g.length>x+1?g.slice(0,x+1)+"."+g.slice(x+1):g+new Array(x-g.length+2).join("0")}var sn={"%":(r,o)=>(r*100).toFixed(o),b:r=>Math.round(r).toString(2),c:r=>r+"",d:ut,e:(r,o)=>r.toExponential(o),f:(r,o)=>r.toFixed(o),g:(r,o)=>r.toPrecision(o),o:r=>Math.round(r).toString(8),p:(r,o)=>Hr(r*100,o),r:Hr,s:Tr,X:r=>Math.round(r).toString(16).toUpperCase(),x:r=>Math.round(r).toString(16)};function pn(r){return r}var yn=Array.prototype.map,un=["y","z","a","f","p","n","\xB5","m","","k","M","G","T","P","E","Z","Y"];function Ba(r){var o=r.grouping===void 0||r.thousands===void 0?pn:Or(yn.call(r.grouping,Number),r.thousands+""),l=r.currency===void 0?"":r.currency[0]+"",g=r.currency===void 0?"":r.currency[1]+"",x=r.decimal===void 0?".":r.decimal+"",O=r.numerals===void 0?pn:Rr(yn.call(r.numerals,String)),T=r.percent===void 0?"%":r.percent+"",D=r.minus===void 0?"\u2212":r.minus+"",$=r.nan===void 0?"NaN":r.nan+"";function L(K){K=k(K);var _=K.fill,et=K.align,zt=K.sign,or=K.symbol,pt=K.zero,Ct=K.width,Gt=K.comma,Dt=K.precision,kt=K.trim,Yt=K.type;Yt==="n"?(Gt=!0,Yt="g"):sn[Yt]||(Dt===void 0&&(Dt=12),kt=!0,Yt="g"),(pt||_==="0"&&et==="=")&&(pt=!0,_="0",et="=");var pr=or==="$"?l:or==="#"&&/[boxX]/.test(Yt)?"0"+Yt.toLowerCase():"",Sr=or==="$"?g:/[%p]/.test(Yt)?T:"",cr=sn[Yt],Nr=/[defgprs%]/.test(Yt);Dt=Dt===void 0?6:/[gprs]/.test(Yt)?Math.max(1,Math.min(21,Dt)):Math.max(0,Math.min(20,Dt));function sr(Ut){var gr=pr,ar=Sr,yr,Yr,Er;if(Yt==="c")ar=cr(Ut)+ar,Ut="";else{Ut=+Ut;var Ir=Ut<0||1/Ut<0;if(Ut=isNaN(Ut)?$:cr(Math.abs(Ut),Dt),kt&&(Ut=Ur(Ut)),Ir&&+Ut==0&&zt!=="+"&&(Ir=!1),gr=(Ir?zt==="("?zt:D:zt==="-"||zt==="("?"":zt)+gr,ar=(Yt==="s"?un[8+dt/3]:"")+ar+(Ir&&zt==="("?")":""),Nr){for(yr=-1,Yr=Ut.length;++yr<Yr;)if(Er=Ut.charCodeAt(yr),48>Er||Er>57){ar=(Er===46?x+Ut.slice(yr+1):Ut.slice(yr))+ar,Ut=Ut.slice(0,yr);break}}}Gt&&!pt&&(Ut=o(Ut,1/0));var wr=gr.length+Ut.length+ar.length,fr=wr<Ct?new Array(Ct-wr+1).join(_):"";switch(Gt&&pt&&(Ut=o(fr+Ut,fr.length?Ct-ar.length:1/0),fr=""),et){case"<":Ut=gr+Ut+ar+fr;break;case"=":Ut=gr+fr+Ut+ar;break;case"^":Ut=fr.slice(0,wr=fr.length>>1)+gr+Ut+ar+fr.slice(wr);break;default:Ut=fr+gr+Ut+ar;break}return O(Ut)}return sr.toString=function(){return K+""},sr}function H(K,_){var et=L((K=k(K),K.type="f",K)),zt=Math.max(-8,Math.min(8,Math.floor(Pt(_)/3)))*3,or=Math.pow(10,-zt),pt=un[8+zt/3];return function(Ct){return et(or*Ct)+pt}}return{format:L,formatPrefix:H}}var Mn,bn,Me;ja({thousands:",",grouping:[3],currency:["$",""]});function ja(r){return Mn=Ba(r),bn=Mn.format,Me=Mn.formatPrefix,Mn}function wa(r,o){return r=Math.abs(r),o=Math.abs(o)-r,Math.max(0,Pt(o)-Pt(r))+1}function Ga(r){return Math.max(0,-Pt(Math.abs(r)))}function Va(r,o,l,g){var x=J(r,o,l),O;switch(g=k(g==null?",f":g),g.type){case"s":{var T=Math.max(Math.abs(r),Math.abs(o));return g.precision==null&&!isNaN(O=xr(x,T))&&(g.precision=O),Me(g,T)}case"":case"e":case"g":case"p":case"r":{g.precision==null&&!isNaN(O=wa(x,Math.max(Math.abs(r),Math.abs(o))))&&(g.precision=O-(g.type==="e"));break}case"f":case"%":{g.precision==null&&!isNaN(O=Ga(x))&&(g.precision=O-(g.type==="%")*2);break}}return bn(g)}function ae(r){var o=r.domain;return r.ticks=function(l){var g=o();return an(g[0],g[g.length-1],l==null?10:l)},r.tickFormat=function(l,g){var x=o();return Va(x[0],x[x.length-1],l==null?10:l,g)},r.nice=function(l){l==null&&(l=10);var g=o(),x=0,O=g.length-1,T=g[x],D=g[O],$,L,H=10;for(D<T&&(L=T,T=D,D=L,L=x,x=O,O=L);H-- >0;){if(L=on(T,D,l),L===$)return g[x]=T,g[O]=D,o(g);if(L>0)T=Math.floor(T/L)*L,D=Math.ceil(D/L)*L;else if(L<0)T=Math.ceil(T*L)/L,D=Math.floor(D*L)/L;else break;$=L}return r},r}function Ha(){var r=continuous();return r.copy=function(){return copy(r,Ha())},initRange.apply(r,arguments),ae(r)}function Wa(r,o){r=r.slice();var l=0,g=r.length-1,x=r[l],O=r[g],T;return O<x&&(T=l,l=g,g=T,T=x,x=O,O=T),r[l]=o.floor(x),r[g]=o.ceil(O),r}function be(r){return Math.log(r)}function De(r){return Math.exp(r)}function za(r){return-Math.log(-r)}function Ya(r){return-Math.exp(-r)}function Ka(r){return isFinite(r)?+("1e"+r):r<0?0:r}function Xa(r){return r===10?Ka:r===Math.E?Math.exp:o=>Math.pow(r,o)}function Ja(r){return r===Math.E?Math.log:r===10&&Math.log10||r===2&&Math.log2||(r=Math.log(r),o=>Math.log(o)/r)}function Fe(r){return(o,l)=>-r(-o,l)}function $e(r){const o=r(be,De),l=o.domain;let g=10,x,O;function T(){return x=Ja(g),O=Xa(g),l()[0]<0?(x=Fe(x),O=Fe(O),r(za,Ya)):r(be,De),o}return o.base=function(D){return arguments.length?(g=+D,T()):g},o.domain=function(D){return arguments.length?(l(D),T()):l()},o.ticks=D=>{const $=l();let L=$[0],H=$[$.length-1];const K=H<L;K&&([L,H]=[H,L]);let _=x(L),et=x(H),zt,or;const pt=D==null?10:+D;let Ct=[];if(!(g%1)&&et-_<pt){if(_=Math.floor(_),et=Math.ceil(et),L>0){for(;_<=et;++_)for(zt=1;zt<g;++zt)if(or=_<0?zt/O(-_):zt*O(_),!(or<L)){if(or>H)break;Ct.push(or)}}else for(;_<=et;++_)for(zt=g-1;zt>=1;--zt)if(or=_>0?zt/O(-_):zt*O(_),!(or<L)){if(or>H)break;Ct.push(or)}Ct.length*2<pt&&(Ct=an(L,H,pt))}else Ct=an(_,et,Math.min(et-_,pt)).map(O);return K?Ct.reverse():Ct},o.tickFormat=(D,$)=>{if(D==null&&(D=10),$==null&&($=g===10?"s":","),typeof $!="function"&&(!(g%1)&&($=k($)).precision==null&&($.trim=!0),$=bn($)),D===1/0)return $;const L=Math.max(1,g*D/o.ticks().length);return H=>{let K=H/O(Math.round(x(H)));return K*g<g-.5&&(K*=g),K<=L?$(H):""}},o.nice=()=>l(Wa(l(),{floor:D=>O(Math.floor(x(D))),ceil:D=>O(Math.ceil(x(D)))})),o}function Qa(){const r=$e(transformer()).domain([1,10]);return r.copy=()=>copy(r,Qa()).base(r.base()),initRange.apply(r,arguments),r}function Dn(){var r=0,o=1,l,g,x,O,T=dr,D=!1,$;function L(K){return K==null||isNaN(K=+K)?$:T(x===0?.5:(K=(O(K)-l)*x,D?Math.max(0,Math.min(1,K)):K))}L.domain=function(K){return arguments.length?([r,o]=K,l=O(r=+r),g=O(o=+o),x=l===g?0:1/(g-l),L):[r,o]},L.clamp=function(K){return arguments.length?(D=!!K,L):D},L.interpolator=function(K){return arguments.length?(T=K,L):T};function H(K){return function(_){var et,zt;return arguments.length?([et,zt]=_,T=K(et,zt),L):[T(0),T(1)]}}return L.range=H(ot),L.rangeRound=H(lt),L.unknown=function(K){return arguments.length?($=K,L):$},function(K){return O=K,l=K(r),g=K(o),x=l===g?0:1/(g-l),L}}function Fn(r,o){return o.domain(r.domain()).interpolator(r.interpolator()).clamp(r.clamp()).unknown(r.unknown())}function Le(){var r=ae(Dn()(dr));return r.copy=function(){return Fn(r,Le())},Vr.apply(r,arguments)}function Ue(){var r=$e(Dn()).domain([1,10]);return r.copy=function(){return Fn(r,Ue()).base(r.base())},Vr.apply(r,arguments)}function Za(){var r=symlogish(Dn());return r.copy=function(){return Fn(r,Za()).constant(r.constant())},initInterpolator.apply(r,arguments)}function Be(){var r=powish(Dn());return r.copy=function(){return Fn(r,Be()).exponent(r.exponent())},initInterpolator.apply(r,arguments)}function Ef(){return Be.apply(null,arguments).exponent(.5)}var ka=Object.defineProperty,je=Object.getOwnPropertySymbols,qa=Object.prototype.hasOwnProperty,_a=Object.prototype.propertyIsEnumerable,we=(r,o,l)=>o in r?ka(r,o,{enumerable:!0,configurable:!0,writable:!0,value:l}):r[o]=l,hr=(r,o)=>{for(var l in o||(o={}))qa.call(o,l)&&we(r,l,o[l]);if(je)for(var l of je(o))_a.call(o,l)&&we(r,l,o[l]);return r};const to={button:"bb-button",chart:"bb-chart",empty:"bb-empty",main:"bb-main",target:"bb-target",EXPANDED:"_expanded_"},ro={arc:"bb-arc",arcLabelLine:"bb-arc-label-line",arcRange:"bb-arc-range",arcs:"bb-arcs",chartArc:"bb-chart-arc",chartArcs:"bb-chart-arcs",chartArcsBackground:"bb-chart-arcs-background",chartArcsTitle:"bb-chart-arcs-title",needle:"bb-needle"},no={area:"bb-area",areas:"bb-areas"},eo={axis:"bb-axis",axisX:"bb-axis-x",axisXLabel:"bb-axis-x-label",axisY:"bb-axis-y",axisY2:"bb-axis-y2",axisY2Label:"bb-axis-y2-label",axisYLabel:"bb-axis-y-label",axisXTooltip:"bb-axis-x-tooltip",axisYTooltip:"bb-axis-y-tooltip",axisY2Tooltip:"bb-axis-y2-tooltip"},ao={bar:"bb-bar",bars:"bb-bars",chartBar:"bb-chart-bar",chartBars:"bb-chart-bars"},oo={candlestick:"bb-candlestick",candlesticks:"bb-candlesticks",chartCandlestick:"bb-chart-candlestick",chartCandlesticks:"bb-chart-candlesticks",valueDown:"bb-value-down",valueUp:"bb-value-up"},so={chartCircles:"bb-chart-circles",circle:"bb-circle",circles:"bb-circles"},io={colorPattern:"bb-color-pattern",colorScale:"bb-colorscale"},uo={dragarea:"bb-dragarea",INCLUDED:"_included_"},fo={funnel:"bb-funnel",chartFunnel:"bb-chart-funnel",chartFunnels:"bb-chart-funnels",funnelBackground:"bb-funnel-background"},lo={chartArcsGaugeMax:"bb-chart-arcs-gauge-max",chartArcsGaugeMin:"bb-chart-arcs-gauge-min",chartArcsGaugeUnit:"bb-chart-arcs-gauge-unit",chartArcsGaugeTitle:"bb-chart-arcs-gauge-title",gaugeValue:"bb-gauge-value"},co={legend:"bb-legend",legendBackground:"bb-legend-background",legendItem:"bb-legend-item",legendItemEvent:"bb-legend-item-event",legendItemHidden:"bb-legend-item-hidden",legendItemPoint:"bb-legend-item-point",legendItemTile:"bb-legend-item-tile"},vo={chartLine:"bb-chart-line",chartLines:"bb-chart-lines",line:"bb-line",lines:"bb-lines"},ho={eventRect:"bb-event-rect",eventRects:"bb-event-rects",eventRectsMultiple:"bb-event-rects-multiple",eventRectsSingle:"bb-event-rects-single"},go={focused:"bb-focused",defocused:"bb-defocused",legendItemFocused:"bb-legend-item-focused",xgridFocus:"bb-xgrid-focus",ygridFocus:"bb-ygrid-focus"},po={grid:"bb-grid",gridLines:"bb-grid-lines",xgrid:"bb-xgrid",xgridLine:"bb-xgrid-line",xgridLines:"bb-xgrid-lines",xgrids:"bb-xgrids",ygrid:"bb-ygrid",ygridLine:"bb-ygrid-line",ygridLines:"bb-ygrid-lines",ygrids:"bb-ygrids"},If={level:"bb-level",levels:"bb-levels"},yo={chartRadar:"bb-chart-radar",chartRadars:"bb-chart-radars"},mo={region:"bb-region",regions:"bb-regions"},xo={selectedCircle:"bb-selected-circle",selectedCircles:"bb-selected-circles",SELECTED:"_selected_"},So={shape:"bb-shape",shapes:"bb-shapes"},Eo={brush:"bb-brush",subchart:"bb-subchart"},Io={chartText:"bb-chart-text",chartTexts:"bb-chart-texts",text:"bb-text",texts:"bb-texts",title:"bb-title",TextOverlapping:"text-overlapping"},oe={tooltip:"bb-tooltip",tooltipContainer:"bb-tooltip-container",tooltipName:"bb-tooltip-name"},Oo={treemap:"bb-treemap",chartTreemap:"bb-chart-treemap",chartTreemaps:"bb-chart-treemaps"},To={buttonZoomReset:"bb-zoom-reset",zoomBrush:"bb-zoom-brush"};var Of=hr(hr(hr(hr(hr(hr(hr(hr(hr(hr(hr(hr(hr(hr(hr(hr(hr(hr(hr(hr(hr(hr(hr(hr(hr({},to),ro),no),eo),ao),oo),so),io),uo),lo),co),vo),ho),go),fo),po),yo),mo),xo),So),Eo),Io),oe),Oo),To);function Ro(){}function se(r){return r==null?Ro:function(){return this.querySelector(r)}}function Ao(r){typeof r!="function"&&(r=se(r));for(var o=this._groups,l=o.length,g=new Array(l),x=0;x<l;++x)for(var O=o[x],T=O.length,D=g[x]=new Array(T),$,L,H=0;H<T;++H)($=O[H])&&(L=r.call($,$.__data__,H,O))&&("__data__"in $&&(L.__data__=$.__data__),D[H]=L);return new Wr(g,this._parents)}function Po(r){return r==null?[]:Array.isArray(r)?r:Array.from(r)}function Co(){return[]}function Ge(r){return r==null?Co:function(){return this.querySelectorAll(r)}}function No(r){return function(){return Po(r.apply(this,arguments))}}function Mo(r){typeof r=="function"?r=No(r):r=Ge(r);for(var o=this._groups,l=o.length,g=[],x=[],O=0;O<l;++O)for(var T=o[O],D=T.length,$,L=0;L<D;++L)($=T[L])&&(g.push(r.call($,$.__data__,L,T)),x.push($));return new Wr(g,x)}function Ve(r){return function(){return this.matches(r)}}function He(r){return function(o){return o.matches(r)}}var bo=Array.prototype.find;function Do(r){return function(){return bo.call(this.children,r)}}function Fo(){return this.firstElementChild}function $o(r){return this.select(r==null?Fo:Do(typeof r=="function"?r:He(r)))}var Lo=Array.prototype.filter;function Uo(){return Array.from(this.children)}function Bo(r){return function(){return Lo.call(this.children,r)}}function jo(r){return this.selectAll(r==null?Uo:Bo(typeof r=="function"?r:He(r)))}function wo(r){typeof r!="function"&&(r=Ve(r));for(var o=this._groups,l=o.length,g=new Array(l),x=0;x<l;++x)for(var O=o[x],T=O.length,D=g[x]=[],$,L=0;L<T;++L)($=O[L])&&r.call($,$.__data__,L,O)&&D.push($);return new Wr(g,this._parents)}function We(r){return new Array(r.length)}function Go(){return new Wr(this._enter||this._groups.map(We),this._parents)}function $n(r,o){this.ownerDocument=r.ownerDocument,this.namespaceURI=r.namespaceURI,this._next=null,this._parent=r,this.__data__=o}$n.prototype={constructor:$n,appendChild:function(r){return this._parent.insertBefore(r,this._next)},insertBefore:function(r,o){return this._parent.insertBefore(r,o)},querySelector:function(r){return this._parent.querySelector(r)},querySelectorAll:function(r){return this._parent.querySelectorAll(r)}};function Vo(r){return function(){return r}}function Ho(r,o,l,g,x,O){for(var T=0,D,$=o.length,L=O.length;T<L;++T)(D=o[T])?(D.__data__=O[T],g[T]=D):l[T]=new $n(r,O[T]);for(;T<$;++T)(D=o[T])&&(x[T]=D)}function Wo(r,o,l,g,x,O,T){var D,$,L=new Map,H=o.length,K=O.length,_=new Array(H),et;for(D=0;D<H;++D)($=o[D])&&(_[D]=et=T.call($,$.__data__,D,o)+"",L.has(et)?x[D]=$:L.set(et,$));for(D=0;D<K;++D)et=T.call(r,O[D],D,O)+"",($=L.get(et))?(g[D]=$,$.__data__=O[D],L.delete(et)):l[D]=new $n(r,O[D]);for(D=0;D<H;++D)($=o[D])&&L.get(_[D])===$&&(x[D]=$)}function zo(r){return r.__data__}function Yo(r,o){if(!arguments.length)return Array.from(this,zo);var l=o?Wo:Ho,g=this._parents,x=this._groups;typeof r!="function"&&(r=Vo(r));for(var O=x.length,T=new Array(O),D=new Array(O),$=new Array(O),L=0;L<O;++L){var H=g[L],K=x[L],_=K.length,et=Ko(r.call(H,H&&H.__data__,L,g)),zt=et.length,or=D[L]=new Array(zt),pt=T[L]=new Array(zt),Ct=$[L]=new Array(_);l(H,K,or,pt,Ct,et,o);for(var Gt=0,Dt=0,kt,Yt;Gt<zt;++Gt)if(kt=or[Gt]){for(Gt>=Dt&&(Dt=Gt+1);!(Yt=pt[Dt])&&++Dt<zt;);kt._next=Yt||null}}return T=new Wr(T,g),T._enter=D,T._exit=$,T}function Ko(r){return typeof r=="object"&&"length"in r?r:Array.from(r)}function Xo(){return new Wr(this._exit||this._groups.map(We),this._parents)}function Jo(r,o,l){var g=this.enter(),x=this,O=this.exit();return typeof r=="function"?(g=r(g),g&&(g=g.selection())):g=g.append(r+""),o!=null&&(x=o(x),x&&(x=x.selection())),l==null?O.remove():l(O),g&&x?g.merge(x).order():x}function Qo(r){for(var o=r.selection?r.selection():r,l=this._groups,g=o._groups,x=l.length,O=g.length,T=Math.min(x,O),D=new Array(x),$=0;$<T;++$)for(var L=l[$],H=g[$],K=L.length,_=D[$]=new Array(K),et,zt=0;zt<K;++zt)(et=L[zt]||H[zt])&&(_[zt]=et);for(;$<x;++$)D[$]=l[$];return new Wr(D,this._parents)}function Zo(){for(var r=this._groups,o=-1,l=r.length;++o<l;)for(var g=r[o],x=g.length-1,O=g[x],T;--x>=0;)(T=g[x])&&(O&&T.compareDocumentPosition(O)^4&&O.parentNode.insertBefore(T,O),O=T);return this}function ko(r){r||(r=qo);function o(K,_){return K&&_?r(K.__data__,_.__data__):!K-!_}for(var l=this._groups,g=l.length,x=new Array(g),O=0;O<g;++O){for(var T=l[O],D=T.length,$=x[O]=new Array(D),L,H=0;H<D;++H)(L=T[H])&&($[H]=L);$.sort(o)}return new Wr(x,this._parents).order()}function qo(r,o){return r<o?-1:r>o?1:r>=o?0:NaN}function _o(){var r=arguments[0];return arguments[0]=this,r.apply(null,arguments),this}function ts(){return Array.from(this)}function rs(){for(var r=this._groups,o=0,l=r.length;o<l;++o)for(var g=r[o],x=0,O=g.length;x<O;++x){var T=g[x];if(T)return T}return null}function ns(){let r=0;for(const o of this)++r;return r}function es(){return!this.node()}function as(r){for(var o=this._groups,l=0,g=o.length;l<g;++l)for(var x=o[l],O=0,T=x.length,D;O<T;++O)(D=x[O])&&r.call(D,D.__data__,O,x);return this}var ie="http://www.w3.org/1999/xhtml",ze={svg:"http://www.w3.org/2000/svg",xhtml:ie,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Ln(r){var o=r+="",l=o.indexOf(":");return l>=0&&(o=r.slice(0,l))!=="xmlns"&&(r=r.slice(l+1)),ze.hasOwnProperty(o)?{space:ze[o],local:r}:r}function os(r){return function(){this.removeAttribute(r)}}function ss(r){return function(){this.removeAttributeNS(r.space,r.local)}}function is(r,o){return function(){this.setAttribute(r,o)}}function us(r,o){return function(){this.setAttributeNS(r.space,r.local,o)}}function fs(r,o){return function(){var l=o.apply(this,arguments);l==null?this.removeAttribute(r):this.setAttribute(r,l)}}function ls(r,o){return function(){var l=o.apply(this,arguments);l==null?this.removeAttributeNS(r.space,r.local):this.setAttributeNS(r.space,r.local,l)}}function cs(r,o){var l=Ln(r);if(arguments.length<2){var g=this.node();return l.local?g.getAttributeNS(l.space,l.local):g.getAttribute(l)}return this.each((o==null?l.local?ss:os:typeof o=="function"?l.local?ls:fs:l.local?us:is)(l,o))}function Ye(r){return r.ownerDocument&&r.ownerDocument.defaultView||r.document&&r||r.defaultView}function vs(r){return function(){this.style.removeProperty(r)}}function ds(r,o,l){return function(){this.style.setProperty(r,o,l)}}function hs(r,o,l){return function(){var g=o.apply(this,arguments);g==null?this.style.removeProperty(r):this.style.setProperty(r,g,l)}}function gs(r,o,l){return arguments.length>1?this.each((o==null?vs:typeof o=="function"?hs:ds)(r,o,l==null?"":l)):fn(this.node(),r)}function fn(r,o){return r.style.getPropertyValue(o)||Ye(r).getComputedStyle(r,null).getPropertyValue(o)}function ps(r){return function(){delete this[r]}}function ys(r,o){return function(){this[r]=o}}function ms(r,o){return function(){var l=o.apply(this,arguments);l==null?delete this[r]:this[r]=l}}function xs(r,o){return arguments.length>1?this.each((o==null?ps:typeof o=="function"?ms:ys)(r,o)):this.node()[r]}function Ke(r){return r.trim().split(/^|\s+/)}function ue(r){return r.classList||new Xe(r)}function Xe(r){this._node=r,this._names=Ke(r.getAttribute("class")||"")}Xe.prototype={add:function(r){var o=this._names.indexOf(r);o<0&&(this._names.push(r),this._node.setAttribute("class",this._names.join(" ")))},remove:function(r){var o=this._names.indexOf(r);o>=0&&(this._names.splice(o,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(r){return this._names.indexOf(r)>=0}};function Je(r,o){for(var l=ue(r),g=-1,x=o.length;++g<x;)l.add(o[g])}function Qe(r,o){for(var l=ue(r),g=-1,x=o.length;++g<x;)l.remove(o[g])}function Ss(r){return function(){Je(this,r)}}function Es(r){return function(){Qe(this,r)}}function Is(r,o){return function(){(o.apply(this,arguments)?Je:Qe)(this,r)}}function Os(r,o){var l=Ke(r+"");if(arguments.length<2){for(var g=ue(this.node()),x=-1,O=l.length;++x<O;)if(!g.contains(l[x]))return!1;return!0}return this.each((typeof o=="function"?Is:o?Ss:Es)(l,o))}function Ts(){this.textContent=""}function Rs(r){return function(){this.textContent=r}}function As(r){return function(){var o=r.apply(this,arguments);this.textContent=o==null?"":o}}function Ps(r){return arguments.length?this.each(r==null?Ts:(typeof r=="function"?As:Rs)(r)):this.node().textContent}function Cs(){this.innerHTML=""}function Ns(r){return function(){this.innerHTML=r}}function Ms(r){return function(){var o=r.apply(this,arguments);this.innerHTML=o==null?"":o}}function bs(r){return arguments.length?this.each(r==null?Cs:(typeof r=="function"?Ms:Ns)(r)):this.node().innerHTML}function Ds(){this.nextSibling&&this.parentNode.appendChild(this)}function Fs(){return this.each(Ds)}function $s(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function Ls(){return this.each($s)}function Us(r){return function(){var o=this.ownerDocument,l=this.namespaceURI;return l===ie&&o.documentElement.namespaceURI===ie?o.createElement(r):o.createElementNS(l,r)}}function Bs(r){return function(){return this.ownerDocument.createElementNS(r.space,r.local)}}function Ze(r){var o=Ln(r);return(o.local?Bs:Us)(o)}function js(r){var o=typeof r=="function"?r:Ze(r);return this.select(function(){return this.appendChild(o.apply(this,arguments))})}function ws(){return null}function Gs(r,o){var l=typeof r=="function"?r:Ze(r),g=o==null?ws:typeof o=="function"?o:se(o);return this.select(function(){return this.insertBefore(l.apply(this,arguments),g.apply(this,arguments)||null)})}function Vs(){var r=this.parentNode;r&&r.removeChild(this)}function Hs(){return this.each(Vs)}function Ws(){var r=this.cloneNode(!1),o=this.parentNode;return o?o.insertBefore(r,this.nextSibling):r}function zs(){var r=this.cloneNode(!0),o=this.parentNode;return o?o.insertBefore(r,this.nextSibling):r}function Ys(r){return this.select(r?zs:Ws)}function Ks(r){return arguments.length?this.property("__data__",r):this.node().__data__}function Xs(r){return function(o){r.call(this,o,this.__data__)}}function Js(r){return r.trim().split(/^|\s+/).map(function(o){var l="",g=o.indexOf(".");return g>=0&&(l=o.slice(g+1),o=o.slice(0,g)),{type:o,name:l}})}function Qs(r){return function(){var o=this.__on;if(o){for(var l=0,g=-1,x=o.length,O;l<x;++l)O=o[l],(!r.type||O.type===r.type)&&O.name===r.name?this.removeEventListener(O.type,O.listener,O.options):o[++g]=O;++g?o.length=g:delete this.__on}}}function Zs(r,o,l){return function(){var g=this.__on,x,O=Xs(o);if(g){for(var T=0,D=g.length;T<D;++T)if((x=g[T]).type===r.type&&x.name===r.name){this.removeEventListener(x.type,x.listener,x.options),this.addEventListener(x.type,x.listener=O,x.options=l),x.value=o;return}}this.addEventListener(r.type,O,l),x={type:r.type,name:r.name,value:o,listener:O,options:l},g?g.push(x):this.__on=[x]}}function ks(r,o,l){var g=Js(r+""),x,O=g.length,T;if(arguments.length<2){var D=this.node().__on;if(D){for(var $=0,L=D.length,H;$<L;++$)for(x=0,H=D[$];x<O;++x)if((T=g[x]).type===H.type&&T.name===H.name)return H.value}return}for(D=o?Zs:Qs,x=0;x<O;++x)this.each(D(g[x],o,l));return this}function ke(r,o,l){var g=Ye(r),x=g.CustomEvent;typeof x=="function"?x=new x(o,l):(x=g.document.createEvent("Event"),l?(x.initEvent(o,l.bubbles,l.cancelable),x.detail=l.detail):x.initEvent(o,!1,!1)),r.dispatchEvent(x)}function qs(r,o){return function(){return ke(this,r,o)}}function _s(r,o){return function(){return ke(this,r,o.apply(this,arguments))}}function ti(r,o){return this.each((typeof o=="function"?_s:qs)(r,o))}function*ri(){for(var r=this._groups,o=0,l=r.length;o<l;++o)for(var g=r[o],x=0,O=g.length,T;x<O;++x)(T=g[x])&&(yield T)}var ni=[null];function Wr(r,o){this._groups=r,this._parents=o}function qe(){return new Wr([[document.documentElement]],ni)}function ei(){return this}Wr.prototype=qe.prototype={constructor:Wr,select:Ao,selectAll:Mo,selectChild:$o,selectChildren:jo,filter:wo,data:Yo,enter:Go,exit:Xo,join:Jo,merge:Qo,selection:ei,order:Zo,sort:ko,call:_o,nodes:ts,node:rs,size:ns,empty:es,each:as,attr:cs,style:gs,property:xs,classed:Os,text:Ps,html:bs,raise:Fs,lower:Ls,append:js,insert:Gs,remove:Hs,clone:Ys,datum:Ks,on:ks,dispatch:ti,[Symbol.iterator]:ri};var mn=qe,ai={value:()=>{}};function _e(){for(var r=0,o=arguments.length,l={},g;r<o;++r){if(!(g=arguments[r]+"")||g in l||/[\s.]/.test(g))throw new Error("illegal type: "+g);l[g]=[]}return new Un(l)}function Un(r){this._=r}function oi(r,o){return r.trim().split(/^|\s+/).map(function(l){var g="",x=l.indexOf(".");if(x>=0&&(g=l.slice(x+1),l=l.slice(0,x)),l&&!o.hasOwnProperty(l))throw new Error("unknown type: "+l);return{type:l,name:g}})}Un.prototype=_e.prototype={constructor:Un,on:function(r,o){var l=this._,g=oi(r+"",l),x,O=-1,T=g.length;if(arguments.length<2){for(;++O<T;)if((x=(r=g[O]).type)&&(x=si(l[x],r.name)))return x;return}if(o!=null&&typeof o!="function")throw new Error("invalid callback: "+o);for(;++O<T;)if(x=(r=g[O]).type)l[x]=ta(l[x],r.name,o);else if(o==null)for(x in l)l[x]=ta(l[x],r.name,null);return this},copy:function(){var r={},o=this._;for(var l in o)r[l]=o[l].slice();return new Un(r)},call:function(r,o){if((x=arguments.length-2)>0)for(var l=new Array(x),g=0,x,O;g<x;++g)l[g]=arguments[g+2];if(!this._.hasOwnProperty(r))throw new Error("unknown type: "+r);for(O=this._[r],g=0,x=O.length;g<x;++g)O[g].value.apply(o,l)},apply:function(r,o,l){if(!this._.hasOwnProperty(r))throw new Error("unknown type: "+r);for(var g=this._[r],x=0,O=g.length;x<O;++x)g[x].value.apply(o,l)}};function si(r,o){for(var l=0,g=r.length,x;l<g;++l)if((x=r[l]).name===o)return x.value}function ta(r,o,l){for(var g=0,x=r.length;g<x;++g)if(r[g].name===o){r[g]=ai,r=r.slice(0,g).concat(r.slice(g+1));break}return l!=null&&r.push({name:o,value:l}),r}var ii=_e,ln=0,xn=0,Sn=0,ra=1e3,Bn,En,jn=0,nn=0,wn=0,In=typeof performance=="object"&&performance.now?performance:Date,na=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(r){setTimeout(r,17)};function fe(){return nn||(na(ui),nn=In.now()+wn)}function ui(){nn=0}function Gn(){this._call=this._time=this._next=null}Gn.prototype=ea.prototype={constructor:Gn,restart:function(r,o,l){if(typeof r!="function")throw new TypeError("callback is not a function");l=(l==null?fe():+l)+(o==null?0:+o),!this._next&&En!==this&&(En?En._next=this:Bn=this,En=this),this._call=r,this._time=l,le()},stop:function(){this._call&&(this._call=null,this._time=1/0,le())}};function ea(r,o,l){var g=new Gn;return g.restart(r,o,l),g}function fi(){fe(),++ln;for(var r=Bn,o;r;)(o=nn-r._time)>=0&&r._call.call(void 0,o),r=r._next;--ln}function aa(){nn=(jn=In.now())+wn,ln=xn=0;try{fi()}finally{ln=0,ci(),nn=0}}function li(){var r=In.now(),o=r-jn;o>ra&&(wn-=o,jn=r)}function ci(){for(var r,o=Bn,l,g=1/0;o;)o._call?(g>o._time&&(g=o._time),r=o,o=o._next):(l=o._next,o._next=null,o=r?r._next=l:Bn=l);En=r,le(g)}function le(r){if(!ln){xn&&(xn=clearTimeout(xn));var o=r-nn;o>24?(r<1/0&&(xn=setTimeout(aa,r-In.now()-wn)),Sn&&(Sn=clearInterval(Sn))):(Sn||(jn=In.now(),Sn=setInterval(li,ra)),ln=1,na(aa))}}function oa(r,o,l){var g=new Gn;return o=o==null?0:+o,g.restart(x=>{g.stop(),r(x+o)},o,l),g}var vi=ii("start","end","cancel","interrupt"),di=[],sa=0,ia=1,ce=2,Vn=3,ua=4,ve=5,Hn=6;function Wn(r,o,l,g,x,O){var T=r.__transition;if(!T)r.__transition={};else if(l in T)return;hi(r,l,{name:o,index:g,group:x,on:vi,tween:di,time:O.time,delay:O.delay,duration:O.duration,ease:O.ease,timer:null,state:sa})}function de(r,o){var l=zr(r,o);if(l.state>sa)throw new Error("too late; already scheduled");return l}function Kr(r,o){var l=zr(r,o);if(l.state>Vn)throw new Error("too late; already running");return l}function zr(r,o){var l=r.__transition;if(!l||!(l=l[o]))throw new Error("transition not found");return l}function hi(r,o,l){var g=r.__transition,x;g[o]=l,l.timer=ea(O,0,l.time);function O(L){l.state=ia,l.timer.restart(T,l.delay,l.time),l.delay<=L&&T(L-l.delay)}function T(L){var H,K,_,et;if(l.state!==ia)return $();for(H in g)if(et=g[H],et.name===l.name){if(et.state===Vn)return oa(T);et.state===ua?(et.state=Hn,et.timer.stop(),et.on.call("interrupt",r,r.__data__,et.index,et.group),delete g[H]):+H<o&&(et.state=Hn,et.timer.stop(),et.on.call("cancel",r,r.__data__,et.index,et.group),delete g[H])}if(oa(function(){l.state===Vn&&(l.state=ua,l.timer.restart(D,l.delay,l.time),D(L))}),l.state=ce,l.on.call("start",r,r.__data__,l.index,l.group),l.state===ce){for(l.state=Vn,x=new Array(_=l.tween.length),H=0,K=-1;H<_;++H)(et=l.tween[H].value.call(r,r.__data__,l.index,l.group))&&(x[++K]=et);x.length=K+1}}function D(L){for(var H=L<l.duration?l.ease.call(null,L/l.duration):(l.timer.restart($),l.state=ve,1),K=-1,_=x.length;++K<_;)x[K].call(r,H);l.state===ve&&(l.on.call("end",r,r.__data__,l.index,l.group),$())}function $(){l.state=Hn,l.timer.stop(),delete g[o];for(var L in g)return;delete r.__transition}}function gi(r,o){var l=r.__transition,g,x,O=!0,T;if(l){o=o==null?null:o+"";for(T in l){if((g=l[T]).name!==o){O=!1;continue}x=g.state>ce&&g.state<ve,g.state=Hn,g.timer.stop(),g.on.call(x?"interrupt":"cancel",r,r.__data__,g.index,g.group),delete l[T]}O&&delete r.__transition}}function pi(r){return this.each(function(){gi(this,r)})}var fa=180/Math.PI,he={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function la(r,o,l,g,x,O){var T,D,$;return(T=Math.sqrt(r*r+o*o))&&(r/=T,o/=T),($=r*l+o*g)&&(l-=r*$,g-=o*$),(D=Math.sqrt(l*l+g*g))&&(l/=D,g/=D,$/=D),r*g<o*l&&(r=-r,o=-o,$=-$,T=-T),{translateX:x,translateY:O,rotate:Math.atan2(o,r)*fa,skewX:Math.atan($)*fa,scaleX:T,scaleY:D}}var zn;function yi(r){const o=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(r+"");return o.isIdentity?he:la(o.a,o.b,o.c,o.d,o.e,o.f)}function mi(r){return r==null||(zn||(zn=document.createElementNS("http://www.w3.org/2000/svg","g")),zn.setAttribute("transform",r),!(r=zn.transform.baseVal.consolidate()))?he:(r=r.matrix,la(r.a,r.b,r.c,r.d,r.e,r.f))}function ca(r,o,l,g){function x(L){return L.length?L.pop()+" ":""}function O(L,H,K,_,et,zt){if(L!==K||H!==_){var or=et.push("translate(",null,o,null,l);zt.push({i:or-4,x:ct(L,K)},{i:or-2,x:ct(H,_)})}else(K||_)&&et.push("translate("+K+o+_+l)}function T(L,H,K,_){L!==H?(L-H>180?H+=360:H-L>180&&(L+=360),_.push({i:K.push(x(K)+"rotate(",null,g)-2,x:ct(L,H)})):H&&K.push(x(K)+"rotate("+H+g)}function D(L,H,K,_){L!==H?_.push({i:K.push(x(K)+"skewX(",null,g)-2,x:ct(L,H)}):H&&K.push(x(K)+"skewX("+H+g)}function $(L,H,K,_,et,zt){if(L!==K||H!==_){var or=et.push(x(et)+"scale(",null,",",null,")");zt.push({i:or-4,x:ct(L,K)},{i:or-2,x:ct(H,_)})}else(K!==1||_!==1)&&et.push(x(et)+"scale("+K+","+_+")")}return function(L,H){var K=[],_=[];return L=r(L),H=r(H),O(L.translateX,L.translateY,H.translateX,H.translateY,K,_),T(L.rotate,H.rotate,K,_),D(L.skewX,H.skewX,K,_),$(L.scaleX,L.scaleY,H.scaleX,H.scaleY,K,_),L=H=null,function(et){for(var zt=-1,or=_.length,pt;++zt<or;)K[(pt=_[zt]).i]=pt.x(et);return K.join("")}}}var xi=ca(yi,"px, ","px)","deg)"),Si=ca(mi,", ",")",")");function Ei(r,o){var l,g;return function(){var x=Kr(this,r),O=x.tween;if(O!==l){g=l=O;for(var T=0,D=g.length;T<D;++T)if(g[T].name===o){g=g.slice(),g.splice(T,1);break}}x.tween=g}}function Ii(r,o,l){var g,x;if(typeof l!="function")throw new Error;return function(){var O=Kr(this,r),T=O.tween;if(T!==g){x=(g=T).slice();for(var D={name:o,value:l},$=0,L=x.length;$<L;++$)if(x[$].name===o){x[$]=D;break}$===L&&x.push(D)}O.tween=x}}function Oi(r,o){var l=this._id;if(r+="",arguments.length<2){for(var g=zr(this.node(),l).tween,x=0,O=g.length,T;x<O;++x)if((T=g[x]).name===r)return T.value;return null}return this.each((o==null?Ei:Ii)(l,r,o))}function ge(r,o,l){var g=r._id;return r.each(function(){var x=Kr(this,g);(x.value||(x.value={}))[o]=l.apply(this,arguments)}),function(x){return zr(x,g).value[o]}}function va(r,o){var l;return(typeof o=="number"?ct:o instanceof A?tr:(l=A(o))?(o=l,tr):ur)(r,o)}function Ti(r){return function(){this.removeAttribute(r)}}function Ri(r){return function(){this.removeAttributeNS(r.space,r.local)}}function Ai(r,o,l){var g,x=l+"",O;return function(){var T=this.getAttribute(r);return T===x?null:T===g?O:O=o(g=T,l)}}function Pi(r,o,l){var g,x=l+"",O;return function(){var T=this.getAttributeNS(r.space,r.local);return T===x?null:T===g?O:O=o(g=T,l)}}function Ci(r,o,l){var g,x,O;return function(){var T,D=l(this),$;return D==null?void this.removeAttribute(r):(T=this.getAttribute(r),$=D+"",T===$?null:T===g&&$===x?O:(x=$,O=o(g=T,D)))}}function Ni(r,o,l){var g,x,O;return function(){var T,D=l(this),$;return D==null?void this.removeAttributeNS(r.space,r.local):(T=this.getAttributeNS(r.space,r.local),$=D+"",T===$?null:T===g&&$===x?O:(x=$,O=o(g=T,D)))}}function Mi(r,o){var l=Ln(r),g=l==="transform"?Si:va;return this.attrTween(r,typeof o=="function"?(l.local?Ni:Ci)(l,g,ge(this,"attr."+r,o)):o==null?(l.local?Ri:Ti)(l):(l.local?Pi:Ai)(l,g,o))}function bi(r,o){return function(l){this.setAttribute(r,o.call(this,l))}}function Di(r,o){return function(l){this.setAttributeNS(r.space,r.local,o.call(this,l))}}function Fi(r,o){var l,g;function x(){var O=o.apply(this,arguments);return O!==g&&(l=(g=O)&&Di(r,O)),l}return x._value=o,x}function $i(r,o){var l,g;function x(){var O=o.apply(this,arguments);return O!==g&&(l=(g=O)&&bi(r,O)),l}return x._value=o,x}function Li(r,o){var l="attr."+r;if(arguments.length<2)return(l=this.tween(l))&&l._value;if(o==null)return this.tween(l,null);if(typeof o!="function")throw new Error;var g=Ln(r);return this.tween(l,(g.local?Fi:$i)(g,o))}function Ui(r,o){return function(){de(this,r).delay=+o.apply(this,arguments)}}function Bi(r,o){return o=+o,function(){de(this,r).delay=o}}function ji(r){var o=this._id;return arguments.length?this.each((typeof r=="function"?Ui:Bi)(o,r)):zr(this.node(),o).delay}function wi(r,o){return function(){Kr(this,r).duration=+o.apply(this,arguments)}}function Gi(r,o){return o=+o,function(){Kr(this,r).duration=o}}function Vi(r){var o=this._id;return arguments.length?this.each((typeof r=="function"?wi:Gi)(o,r)):zr(this.node(),o).duration}function Hi(r,o){if(typeof o!="function")throw new Error;return function(){Kr(this,r).ease=o}}function Wi(r){var o=this._id;return arguments.length?this.each(Hi(o,r)):zr(this.node(),o).ease}function zi(r,o){return function(){var l=o.apply(this,arguments);if(typeof l!="function")throw new Error;Kr(this,r).ease=l}}function Yi(r){if(typeof r!="function")throw new Error;return this.each(zi(this._id,r))}function Ki(r){typeof r!="function"&&(r=Ve(r));for(var o=this._groups,l=o.length,g=new Array(l),x=0;x<l;++x)for(var O=o[x],T=O.length,D=g[x]=[],$,L=0;L<T;++L)($=O[L])&&r.call($,$.__data__,L,O)&&D.push($);return new Qr(g,this._parents,this._name,this._id)}function Xi(r){if(r._id!==this._id)throw new Error;for(var o=this._groups,l=r._groups,g=o.length,x=l.length,O=Math.min(g,x),T=new Array(g),D=0;D<O;++D)for(var $=o[D],L=l[D],H=$.length,K=T[D]=new Array(H),_,et=0;et<H;++et)(_=$[et]||L[et])&&(K[et]=_);for(;D<g;++D)T[D]=o[D];return new Qr(T,this._parents,this._name,this._id)}function Ji(r){return(r+"").trim().split(/^|\s+/).every(function(o){var l=o.indexOf(".");return l>=0&&(o=o.slice(0,l)),!o||o==="start"})}function Qi(r,o,l){var g,x,O=Ji(o)?de:Kr;return function(){var T=O(this,r),D=T.on;D!==g&&(x=(g=D).copy()).on(o,l),T.on=x}}function Zi(r,o){var l=this._id;return arguments.length<2?zr(this.node(),l).on.on(r):this.each(Qi(l,r,o))}function ki(r){return function(){var o=this.parentNode;for(var l in this.__transition)if(+l!==r)return;o&&o.removeChild(this)}}function qi(){return this.on("end.remove",ki(this._id))}function _i(r){var o=this._name,l=this._id;typeof r!="function"&&(r=se(r));for(var g=this._groups,x=g.length,O=new Array(x),T=0;T<x;++T)for(var D=g[T],$=D.length,L=O[T]=new Array($),H,K,_=0;_<$;++_)(H=D[_])&&(K=r.call(H,H.__data__,_,D))&&("__data__"in H&&(K.__data__=H.__data__),L[_]=K,Wn(L[_],o,l,_,L,zr(H,l)));return new Qr(O,this._parents,o,l)}function tu(r){var o=this._name,l=this._id;typeof r!="function"&&(r=Ge(r));for(var g=this._groups,x=g.length,O=[],T=[],D=0;D<x;++D)for(var $=g[D],L=$.length,H,K=0;K<L;++K)if(H=$[K]){for(var _=r.call(H,H.__data__,K,$),et,zt=zr(H,l),or=0,pt=_.length;or<pt;++or)(et=_[or])&&Wn(et,o,l,or,_,zt);O.push(_),T.push(H)}return new Qr(O,T,o,l)}var ru=mn.prototype.constructor;function nu(){return new ru(this._groups,this._parents)}function eu(r,o){var l,g,x;return function(){var O=fn(this,r),T=(this.style.removeProperty(r),fn(this,r));return O===T?null:O===l&&T===g?x:x=o(l=O,g=T)}}function da(r){return function(){this.style.removeProperty(r)}}function au(r,o,l){var g,x=l+"",O;return function(){var T=fn(this,r);return T===x?null:T===g?O:O=o(g=T,l)}}function ou(r,o,l){var g,x,O;return function(){var T=fn(this,r),D=l(this),$=D+"";return D==null&&($=D=(this.style.removeProperty(r),fn(this,r))),T===$?null:T===g&&$===x?O:(x=$,O=o(g=T,D))}}function su(r,o){var l,g,x,O="style."+o,T="end."+O,D;return function(){var $=Kr(this,r),L=$.on,H=$.value[O]==null?D||(D=da(o)):void 0;(L!==l||x!==H)&&(g=(l=L).copy()).on(T,x=H),$.on=g}}function iu(r,o,l){var g=(r+="")=="transform"?xi:va;return o==null?this.styleTween(r,eu(r,g)).on("end.style."+r,da(r)):typeof o=="function"?this.styleTween(r,ou(r,g,ge(this,"style."+r,o))).each(su(this._id,r)):this.styleTween(r,au(r,g,o),l).on("end.style."+r,null)}function uu(r,o,l){return function(g){this.style.setProperty(r,o.call(this,g),l)}}function fu(r,o,l){var g,x;function O(){var T=o.apply(this,arguments);return T!==x&&(g=(x=T)&&uu(r,T,l)),g}return O._value=o,O}function lu(r,o,l){var g="style."+(r+="");if(arguments.length<2)return(g=this.tween(g))&&g._value;if(o==null)return this.tween(g,null);if(typeof o!="function")throw new Error;return this.tween(g,fu(r,o,l==null?"":l))}function cu(r){return function(){this.textContent=r}}function vu(r){return function(){var o=r(this);this.textContent=o==null?"":o}}function du(r){return this.tween("text",typeof r=="function"?vu(ge(this,"text",r)):cu(r==null?"":r+""))}function hu(r){return function(o){this.textContent=r.call(this,o)}}function gu(r){var o,l;function g(){var x=r.apply(this,arguments);return x!==l&&(o=(l=x)&&hu(x)),o}return g._value=r,g}function pu(r){var o="text";if(arguments.length<1)return(o=this.tween(o))&&o._value;if(r==null)return this.tween(o,null);if(typeof r!="function")throw new Error;return this.tween(o,gu(r))}function yu(){for(var r=this._name,o=this._id,l=ha(),g=this._groups,x=g.length,O=0;O<x;++O)for(var T=g[O],D=T.length,$,L=0;L<D;++L)if($=T[L]){var H=zr($,o);Wn($,r,l,L,T,{time:H.time+H.delay+H.duration,delay:0,duration:H.duration,ease:H.ease})}return new Qr(g,this._parents,r,l)}function mu(){var r,o,l=this,g=l._id,x=l.size();return new Promise(function(O,T){var D={value:T},$={value:function(){--x===0&&O()}};l.each(function(){var L=Kr(this,g),H=L.on;H!==r&&(o=(r=H).copy(),o._.cancel.push(D),o._.interrupt.push(D),o._.end.push($)),L.on=o}),x===0&&O()})}var xu=0;function Qr(r,o,l,g){this._groups=r,this._parents=o,this._name=l,this._id=g}function Su(r){return mn().transition(r)}function ha(){return++xu}var Zr=mn.prototype;Qr.prototype=Su.prototype={constructor:Qr,select:_i,selectAll:tu,selectChild:Zr.selectChild,selectChildren:Zr.selectChildren,filter:Ki,merge:Xi,selection:nu,transition:yu,call:Zr.call,nodes:Zr.nodes,node:Zr.node,size:Zr.size,empty:Zr.empty,each:Zr.each,on:Zi,attr:Mi,attrTween:Li,style:iu,styleTween:lu,text:du,textTween:pu,remove:qi,tween:Oi,delay:ji,duration:Vi,ease:Wi,easeVarying:Yi,end:mu,[Symbol.iterator]:Zr[Symbol.iterator]};function Tf(r){return r*r*r}function Rf(r){return--r*r*r+1}function Eu(r){return((r*=2)<=1?r*r*r:(r-=2)*r*r+2)/2}var Iu={time:null,delay:0,duration:250,ease:Eu};function Ou(r,o){for(var l;!(l=r.__transition)||!(l=l[o]);)if(!(r=r.parentNode))throw new Error(`transition ${o} not found`);return l}function Tu(r){var o,l;r instanceof Qr?(o=r._id,r=r._name):(o=ha(),(l=Iu).time=fe(),r=r==null?null:r+"");for(var g=this._groups,x=g.length,O=0;O<x;++O)for(var T=g[O],D=T.length,$,L=0;L<D;++L)($=T[L])&&Wn($,r,o,L,T,l||Ou($,o));return new Qr(g,this._parents,r,o)}mn.prototype.interrupt=pi,mn.prototype.transition=Tu;var ga={name:"drag"},pe={name:"space"},cn={name:"handle"},vn={name:"center"};const{abs:pa,max:Fr,min:$r}=Math;function ya(r){return[+r[0],+r[1]]}function ye(r){return[ya(r[0]),ya(r[1])]}var Yn={name:"x",handles:["w","e"].map(On),input:function(r,o){return r==null?null:[[+r[0],o[0][1]],[+r[1],o[1][1]]]},output:function(r){return r&&[r[0][0],r[1][0]]}},Kn={name:"y",handles:["n","s"].map(On),input:function(r,o){return r==null?null:[[o[0][0],+r[0]],[o[1][0],+r[1]]]},output:function(r){return r&&[r[0][1],r[1][1]]}},Ru={name:"xy",handles:["n","w","e","s","nw","ne","sw","se"].map(On),input:function(r){return r==null?null:ye(r)},output:function(r){return r}},kr={overlay:"crosshair",selection:"move",n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},ma={e:"w",w:"e",nw:"ne",ne:"nw",se:"sw",sw:"se"},xa={n:"s",s:"n",nw:"sw",ne:"se",se:"ne",sw:"nw"},Au={overlay:1,selection:1,n:null,e:1,s:null,w:-1,nw:-1,ne:1,se:1,sw:-1},Pu={overlay:1,selection:1,n:-1,e:null,s:1,w:null,nw:-1,ne:-1,se:1,sw:1};function On(r){return{type:r}}function Cu(r){return!r.ctrlKey&&!r.button}function Nu(){var r=this.ownerSVGElement||this;return r.hasAttribute("viewBox")?(r=r.viewBox.baseVal,[[r.x,r.y],[r.x+r.width,r.y+r.height]]):[[0,0],[r.width.baseVal.value,r.height.baseVal.value]]}function Mu(){return navigator.maxTouchPoints||"ontouchstart"in this}function me(r){for(;!r.__brush;)if(!(r=r.parentNode))return;return r.__brush}function bu(r){return r[0][0]===r[1][0]||r[0][1]===r[1][1]}function Af(r){var o=r.__brush;return o?o.dim.output(o.selection):null}function Pf(){return xe(Yn)}function Cf(){return xe(Kn)}function Nf(){return xe(Ru)}function xe(r){var o=Nu,l=Cu,g=Mu,x=!0,O=dispatch("start","brush","end"),T=6,D;function $(pt){var Ct=pt.property("__brush",or).selectAll(".overlay").data([On("overlay")]);Ct.enter().append("rect").attr("class","overlay").attr("pointer-events","all").attr("cursor",kr.overlay).merge(Ct).each(function(){var Dt=me(this).extent;select(this).attr("x",Dt[0][0]).attr("y",Dt[0][1]).attr("width",Dt[1][0]-Dt[0][0]).attr("height",Dt[1][1]-Dt[0][1])}),pt.selectAll(".selection").data([On("selection")]).enter().append("rect").attr("class","selection").attr("cursor",kr.selection).attr("fill","#777").attr("fill-opacity",.3).attr("stroke","#fff").attr("shape-rendering","crispEdges");var Gt=pt.selectAll(".handle").data(r.handles,function(Dt){return Dt.type});Gt.exit().remove(),Gt.enter().append("rect").attr("class",function(Dt){return"handle handle--"+Dt.type}).attr("cursor",function(Dt){return kr[Dt.type]}),pt.each(L).attr("fill","none").attr("pointer-events","all").on("mousedown.brush",_).filter(g).on("touchstart.brush",_).on("touchmove.brush",et).on("touchend.brush touchcancel.brush",zt).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}$.move=function(pt,Ct,Gt){pt.tween?pt.on("start.brush",function(Dt){H(this,arguments).beforestart().start(Dt)}).on("interrupt.brush end.brush",function(Dt){H(this,arguments).end(Dt)}).tween("brush",function(){var Dt=this,kt=Dt.__brush,Yt=H(Dt,arguments),pr=kt.selection,Sr=r.input(typeof Ct=="function"?Ct.apply(this,arguments):Ct,kt.extent),cr=interpolate(pr,Sr);function Nr(sr){kt.selection=sr===1&&Sr===null?null:cr(sr),L.call(Dt),Yt.brush()}return pr!==null&&Sr!==null?Nr:Nr(1)}):pt.each(function(){var Dt=this,kt=arguments,Yt=Dt.__brush,pr=r.input(typeof Ct=="function"?Ct.apply(Dt,kt):Ct,Yt.extent),Sr=H(Dt,kt).beforestart();interrupt(Dt),Yt.selection=pr===null?null:pr,L.call(Dt),Sr.start(Gt).brush(Gt).end(Gt)})},$.clear=function(pt,Ct){$.move(pt,null,Ct)};function L(){var pt=select(this),Ct=me(this).selection;Ct?(pt.selectAll(".selection").style("display",null).attr("x",Ct[0][0]).attr("y",Ct[0][1]).attr("width",Ct[1][0]-Ct[0][0]).attr("height",Ct[1][1]-Ct[0][1]),pt.selectAll(".handle").style("display",null).attr("x",function(Gt){return Gt.type[Gt.type.length-1]==="e"?Ct[1][0]-T/2:Ct[0][0]-T/2}).attr("y",function(Gt){return Gt.type[0]==="s"?Ct[1][1]-T/2:Ct[0][1]-T/2}).attr("width",function(Gt){return Gt.type==="n"||Gt.type==="s"?Ct[1][0]-Ct[0][0]+T:T}).attr("height",function(Gt){return Gt.type==="e"||Gt.type==="w"?Ct[1][1]-Ct[0][1]+T:T})):pt.selectAll(".selection,.handle").style("display","none").attr("x",null).attr("y",null).attr("width",null).attr("height",null)}function H(pt,Ct,Gt){var Dt=pt.__brush.emitter;return Dt&&(!Gt||!Dt.clean)?Dt:new K(pt,Ct,Gt)}function K(pt,Ct,Gt){this.that=pt,this.args=Ct,this.state=pt.__brush,this.active=0,this.clean=Gt}K.prototype={beforestart:function(){return++this.active===1&&(this.state.emitter=this,this.starting=!0),this},start:function(pt,Ct){return this.starting?(this.starting=!1,this.emit("start",pt,Ct)):this.emit("brush",pt),this},brush:function(pt,Ct){return this.emit("brush",pt,Ct),this},end:function(pt,Ct){return--this.active===0&&(delete this.state.emitter,this.emit("end",pt,Ct)),this},emit:function(pt,Ct,Gt){var Dt=select(this.that).datum();O.call(pt,this.that,new BrushEvent(pt,{sourceEvent:Ct,target:$,selection:r.output(this.state.selection),mode:Gt,dispatch:O}),Dt)}};function _(pt){if(D&&!pt.touches||!l.apply(this,arguments))return;var Ct=this,Gt=pt.target.__data__.type,Dt=(x&&pt.metaKey?Gt="overlay":Gt)==="selection"?ga:x&&pt.altKey?vn:cn,kt=r===Kn?null:Au[Gt],Yt=r===Yn?null:Pu[Gt],pr=me(Ct),Sr=pr.extent,cr=pr.selection,Nr=Sr[0][0],sr,Ut,gr=Sr[0][1],ar,yr,Yr=Sr[1][0],Er,Ir,wr=Sr[1][1],fr,Dr,Ar=0,Pr=0,Ce,_n=kt&&Yt&&x&&pt.shiftKey,te,re,Br=Array.from(pt.touches||[pt],qt=>{const Cr=qt.identifier;return qt=pointer(qt,Ct),qt.point0=qt.slice(),qt.identifier=Cr,qt});interrupt(Ct);var An=H(Ct,arguments,!0).beforestart();if(Gt==="overlay"){cr&&(Ce=!0);const qt=[Br[0],Br[1]||Br[0]];pr.selection=cr=[[sr=r===Kn?Nr:$r(qt[0][0],qt[1][0]),ar=r===Yn?gr:$r(qt[0][1],qt[1][1])],[Er=r===Kn?Yr:Fr(qt[0][0],qt[1][0]),fr=r===Yn?wr:Fr(qt[0][1],qt[1][1])]],Br.length>1&&en(pt)}else sr=cr[0][0],ar=cr[0][1],Er=cr[1][0],fr=cr[1][1];Ut=sr,yr=ar,Ir=Er,Dr=fr;var Fa=select(Ct).attr("pointer-events","none"),Pn=Fa.selectAll(".overlay").attr("cursor",kr[Gt]);if(pt.touches)An.moved=La,An.ended=Ua;else{var $a=select(pt.view).on("mousemove.brush",La,!0).on("mouseup.brush",Ua,!0);x&&$a.on("keydown.brush",xf,!0).on("keyup.brush",Sf,!0),dragDisable(pt.view)}L.call(Ct),An.start(pt,Dt.name);function La(qt){for(const Cr of qt.changedTouches||[qt])for(const Cn of Br)Cn.identifier===Cr.identifier&&(Cn.cur=pointer(Cr,Ct));if(_n&&!te&&!re&&Br.length===1){const Cr=Br[0];pa(Cr.cur[0]-Cr[0])>pa(Cr.cur[1]-Cr[1])?re=!0:te=!0}for(const Cr of Br)Cr.cur&&(Cr[0]=Cr.cur[0],Cr[1]=Cr.cur[1]);Ce=!0,noevent(qt),en(qt)}function en(qt){const Cr=Br[0],Cn=Cr.point0;var rn;switch(Ar=Cr[0]-Cn[0],Pr=Cr[1]-Cn[1],Dt){case pe:case ga:{kt&&(Ar=Fr(Nr-sr,$r(Yr-Er,Ar)),Ut=sr+Ar,Ir=Er+Ar),Yt&&(Pr=Fr(gr-ar,$r(wr-fr,Pr)),yr=ar+Pr,Dr=fr+Pr);break}case cn:{Br[1]?(kt&&(Ut=Fr(Nr,$r(Yr,Br[0][0])),Ir=Fr(Nr,$r(Yr,Br[1][0])),kt=1),Yt&&(yr=Fr(gr,$r(wr,Br[0][1])),Dr=Fr(gr,$r(wr,Br[1][1])),Yt=1)):(kt<0?(Ar=Fr(Nr-sr,$r(Yr-sr,Ar)),Ut=sr+Ar,Ir=Er):kt>0&&(Ar=Fr(Nr-Er,$r(Yr-Er,Ar)),Ut=sr,Ir=Er+Ar),Yt<0?(Pr=Fr(gr-ar,$r(wr-ar,Pr)),yr=ar+Pr,Dr=fr):Yt>0&&(Pr=Fr(gr-fr,$r(wr-fr,Pr)),yr=ar,Dr=fr+Pr));break}case vn:{kt&&(Ut=Fr(Nr,$r(Yr,sr-Ar*kt)),Ir=Fr(Nr,$r(Yr,Er+Ar*kt))),Yt&&(yr=Fr(gr,$r(wr,ar-Pr*Yt)),Dr=Fr(gr,$r(wr,fr+Pr*Yt)));break}}Ir<Ut&&(kt*=-1,rn=sr,sr=Er,Er=rn,rn=Ut,Ut=Ir,Ir=rn,Gt in ma&&Pn.attr("cursor",kr[Gt=ma[Gt]])),Dr<yr&&(Yt*=-1,rn=ar,ar=fr,fr=rn,rn=yr,yr=Dr,Dr=rn,Gt in xa&&Pn.attr("cursor",kr[Gt=xa[Gt]])),pr.selection&&(cr=pr.selection),te&&(Ut=cr[0][0],Ir=cr[1][0]),re&&(yr=cr[0][1],Dr=cr[1][1]),(cr[0][0]!==Ut||cr[0][1]!==yr||cr[1][0]!==Ir||cr[1][1]!==Dr)&&(pr.selection=[[Ut,yr],[Ir,Dr]],L.call(Ct),An.brush(qt,Dt.name))}function Ua(qt){if(nopropagation(qt),qt.touches){if(qt.touches.length)return;D&&clearTimeout(D),D=setTimeout(function(){D=null},500)}else dragEnable(qt.view,Ce),$a.on("keydown.brush keyup.brush mousemove.brush mouseup.brush",null);Fa.attr("pointer-events","all"),Pn.attr("cursor",kr.overlay),pr.selection&&(cr=pr.selection),bu(cr)&&(pr.selection=null,L.call(Ct)),An.end(qt,Dt.name)}function xf(qt){switch(qt.keyCode){case 16:{_n=kt&&Yt;break}case 18:{Dt===cn&&(kt&&(Er=Ir-Ar*kt,sr=Ut+Ar*kt),Yt&&(fr=Dr-Pr*Yt,ar=yr+Pr*Yt),Dt=vn,en(qt));break}case 32:{(Dt===cn||Dt===vn)&&(kt<0?Er=Ir-Ar:kt>0&&(sr=Ut-Ar),Yt<0?fr=Dr-Pr:Yt>0&&(ar=yr-Pr),Dt=pe,Pn.attr("cursor",kr.selection),en(qt));break}default:return}noevent(qt)}function Sf(qt){switch(qt.keyCode){case 16:{_n&&(te=re=_n=!1,en(qt));break}case 18:{Dt===vn&&(kt<0?Er=Ir:kt>0&&(sr=Ut),Yt<0?fr=Dr:Yt>0&&(ar=yr),Dt=cn,en(qt));break}case 32:{Dt===pe&&(qt.altKey?(kt&&(Er=Ir-Ar*kt,sr=Ut+Ar*kt),Yt&&(fr=Dr-Pr*Yt,ar=yr+Pr*Yt),Dt=vn):(kt<0?Er=Ir:kt>0&&(sr=Ut),Yt<0?fr=Dr:Yt>0&&(ar=yr),Dt=cn),Pn.attr("cursor",kr[Gt]),en(qt));break}default:return}noevent(qt)}}function et(pt){H(this,arguments).moved(pt)}function zt(pt){H(this,arguments).ended(pt)}function or(){var pt=this.__brush||{selection:null};return pt.extent=ye(o.apply(this,arguments)),pt.dim=r,pt}return $.extent=function(pt){return arguments.length?(o=typeof pt=="function"?pt:constant(ye(pt)),$):o},$.filter=function(pt){return arguments.length?(l=typeof pt=="function"?pt:constant(!!pt),$):l},$.touchable=function(pt){return arguments.length?(g=typeof pt=="function"?pt:constant(!!pt),$):g},$.handleSize=function(pt){return arguments.length?(T=+pt,$):T},$.keyModifiers=function(pt){return arguments.length?(x=!!pt,$):x},$.on=function(){var pt=O.on.apply(O,arguments);return pt===O?$:pt},$}function Du(){return typeof globalThis=="object"&&globalThis!==null&&globalThis.Object===Object&&globalThis||typeof global=="object"&&global!==null&&global.Object===Object&&global||typeof self=="object"&&self!==null&&self.Object===Object&&self||Function("return this")()}function Fu(r){const o=typeof(r==null?void 0:r.requestAnimationFrame)=="function"&&typeof(r==null?void 0:r.cancelAnimationFrame)=="function",l=typeof(r==null?void 0:r.requestIdleCallback)=="function"&&typeof(r==null?void 0:r.cancelIdleCallback)=="function",g=O=>setTimeout(O,1),x=O=>clearTimeout(O);return[o?r.requestAnimationFrame:g,o?r.cancelAnimationFrame:x,l?r.requestIdleCallback:g,l?r.cancelIdleCallback:x]}const Xn=Du(),$u=Xn==null?void 0:Xn.document,[Mf,bf,Df,Ff]=Fu(Xn);var Lu=Object.defineProperty,Sa=Object.getOwnPropertySymbols,Uu=Object.prototype.hasOwnProperty,Bu=Object.prototype.propertyIsEnumerable,Ea=(r,o,l)=>o in r?Lu(r,o,{enumerable:!0,configurable:!0,writable:!0,value:l}):r[o]=l,Ia=(r,o)=>{for(var l in o||(o={}))Uu.call(o,l)&&Ea(r,l,o[l]);if(Sa)for(var l of Sa(o))Bu.call(o,l)&&Ea(r,l,o[l]);return r};const $f=r=>r||r===0,Se=r=>typeof r=="function",Tn=r=>typeof r=="string",Ee=r=>typeof r=="number",ju=r=>typeof r=="undefined",Oa=r=>typeof r!="undefined",Lf=r=>typeof r=="boolean",Uf=r=>Math.ceil(r/10)*10,Bf=r=>Math.ceil(r)+.5,jf=r=>r[1]-r[0],Ie=r=>typeof r=="object",Ta=r=>ju(r)||r===null||Tn(r)&&r.length===0||Ie(r)&&!(r instanceof Date)&&Object.keys(r).length===0||Ee(r)&&isNaN(r),wu=r=>!Ta(r),Oe=r=>Array.isArray(r),Jn=r=>r&&!(r!=null&&r.nodeType)&&Ie(r)&&!Oe(r);function wf(r,o,l){return Oa(r[o])?r[o]:l}function Gf(r,o){let l=!1;return Object.keys(r).forEach(g=>r[g]===o&&(l=!0)),l}function Vf(r,o,...l){const g=Se(r);return g&&r.call(o,...l),g}function Hf(r,o){let l=0;const g=function(...x){!--l&&o.apply(this,...x)};"duration"in r?r.each(()=>++l).on("end",g):(++l,r.call(g))}function Wf(r){return Tn(r)?r.replace(/<(script|img)?/ig,"&lt;").replace(/(script)?>/ig,"&gt;"):r}function zf(r,o,l=[-1,1],g=!1){if(!(!r||!Tn(o)))if(o.indexOf(`
12
12
  `)===-1)r.text(o);else{const x=[r.text(),o].map(O=>O.replace(/[\s\n]/g,""));if(x[0]!==x[1]){const O=o.split(`
13
- `),T=g?O.length-1:1;r.html(""),O.forEach((D,$)=>{r.append("tspan").attr("x",0).attr("dy",`${$===0?l[0]*T:l[1]}em`).text(D)})}}}function Gu(r){const{x:o,y:l,width:g,height:x}=r.getBBox();return[{x:o,y:l+x},{x:o,y:l},{x:o+g,y:l},{x:o+g,y:l+x}]}function Yf(r){const{width:o,height:l}=r.getBoundingClientRect(),g=Gu(r),x=g[0].x,O=Math.min(g[0].y,g[1].y);return{x,y:O,width:o,height:l}}function Kf(r,o){var l;const g=r&&((l=r.touches||r.sourceEvent&&r.sourceEvent.touches)==null?void 0:l[0]);let x=[0,0];try{x=d3Pointer(g||r,o)}catch(O){}return x.map(O=>isNaN(O)?0:O)}function Vu(r){const{event:o,$el:l}=r,g=l.subchart.main||l.main;let x;return o&&o.type==="brush"?x=o.selection:g&&(x=g.select(".bb-brush").node())&&(x=d3BrushSelection(x)),x}function Xf(r){return!("rect"in r)||"rect"in r&&r.hasAttribute("width")&&r.rect.width!==+r.getAttribute("width")?r.rect=r.getBoundingClientRect():r.rect}function Jf(r=!0,o=0,l=1e4){const g=window.crypto||window.msCrypto,x=g?o+g.getRandomValues(new Uint32Array(1))[0]%(l-o+1):Math.floor(Math.random()*(l-o)+o);return r?String(x):x}function Ra(r,o,l,g,x){if(l>g)return-1;const O=Math.floor((l+g)/2);let{x:T,w:D=0}=r[O];return x&&(T=r[O].y,D=r[O].h),o>=T&&o<=T+D?O:o<T?Ra(r,o,l,O-1,x):Ra(r,o,O+1,g,x)}function Qf(r){const o=Vu(r);return o?o[0]===o[1]:!0}function Zf(...r){const o=l=>{if(Jn(l)&&l.constructor){const g=new l.constructor;for(const x in l)g[x]=o(l[x]);return g}return l};return r.map(l=>o(l)).reduce((l,g)=>Ia(Ia({},l),g))}function Hu(r={},o){Oe(o)&&o.forEach(l=>Hu(r,l));for(const l in o)/^\d+$/.test(l)||l in r||(r[l]=o[l]);return r}const kf=r=>r.charAt(0).toUpperCase()+r.slice(1);function qf(r,o="-"){return r.split(o).map((l,g)=>g?l.charAt(0).toUpperCase()+l.slice(1).toLowerCase():l.toLowerCase()).join("")}const Wu=r=>[].slice.call(r);function _f(r,o,l){const{rootSelector:g="",sheet:x}=r,T=`${g} ${(D=>D.replace(/\s?(bb-)/g,".$1").replace(/\.+/g,"."))(o)} {${l.join(";")}}`;return x[x.insertRule?"insertRule":"addRule"](T,x.cssRules.length)}function tl(r){let o=[];return r.forEach(l=>{var g;try{l.cssRules&&l.cssRules.length&&(o=o.concat(Wu(l.cssRules)))}catch(x){(g=window.console)==null||g.warn(`Error while reading rules from ${l.href}: ${x.toString()}`)}}),o}function rl(r){var o,l,g,x,O,T;return{x:((l=(o=window.pageXOffset)!=null?o:window.scrollX)!=null?l:0)+((g=r.scrollLeft)!=null?g:0),y:((O=(x=window.pageYOffset)!=null?x:window.scrollY)!=null?O:0)+((T=r.scrollTop)!=null?T:0)}}function nl(r,o=0,l=0,g=!0){const x=new DOMPoint(o,l),O=r.getScreenCTM(),T=x.matrixTransform(g?O==null?void 0:O.inverse():O);if(g===!1){const D=r.getBoundingClientRect();T.x-=D.x,T.y-=D.y}return T}function el(r){const o=r?r.transform:null,l=o&&o.baseVal;return l&&l.numberOfItems?l.getItem(0).matrix:{a:0,b:0,c:0,d:0,e:0,f:0}}function al(r){const o=r[0]instanceof Date,l=(o?r.map(Number):r).filter((g,x,O)=>O.indexOf(g)===x);return o?l.map(g=>new Date(g)):l}function ol(r){return r&&r.length?r.reduce((o,l)=>o.concat(l)):[]}function Te(r,...o){if(!o.length||o.length===1&&!o[0])return r;const l=o.shift();return Jn(r)&&Jn(l)&&Object.keys(l).forEach(g=>{const x=l[g];Jn(x)?(!r[g]&&(r[g]={}),r[g]=Te(r[g],x)):r[g]=Oe(x)?x.concat():x}),Te(r,...o)}function zu(r,o=!0){let l;return r[0]instanceof Date?l=o?(g,x)=>g-x:(g,x)=>x-g:o&&!r.every(isNaN)?l=(g,x)=>g-x:o||(l=(g,x)=>g>x&&-1||g<x&&1||g===x&&0),r.concat().sort(l)}function sl(r,o){let l=o.filter(g=>wu(g));return l.length?Ee(l[0])?l=Math[r](...l):l[0]instanceof Date&&(l=zu(l,r==="min")[0]):l=void 0,l}const Yu=(r,o,l=1)=>{const g=[],x=Math.max(0,Math.ceil((o-r)/l))|0;for(let O=r;O<x;O++)g.push(r+O*l);return g},il={mouse:(()=>{const r=()=>({bubbles:!1,cancelable:!1,screenX:0,screenY:0,clientX:0,clientY:0});try{return new MouseEvent("t"),(o,l,g=r())=>{o.dispatchEvent(new MouseEvent(l,g))}}catch(o){return(l,g,x=r())=>{const O=$u.createEvent("MouseEvent");O.initMouseEvent(g,x.bubbles,x.cancelable,Xn,0,x.screenX,x.screenY,x.clientX,x.clientY,!1,!1,!1,!1,0,null),l.dispatchEvent(O)}}})(),touch:(r,o,l)=>{const g=new Touch(Te({identifier:Date.now(),target:r,radiusX:2.5,radiusY:2.5,rotationAngle:10,force:.5},l));r.dispatchEvent(new TouchEvent(o,{cancelable:!0,bubbles:!0,shiftKey:!0,touches:[g],targetTouches:[],changedTouches:[g]}))}};function ul(r,o){let l=r;for(const g in o)l=l.replace(new RegExp(`{=${g}}`,"g"),o[g]);return l}function Ku(r){var o;let l;if(r instanceof Date)l=r;else if(Tn(r)){const{config:g,format:x}=this;l=(o=x.dataTime(g.data_xFormat)(r))!=null?o:new Date(r)}else Ee(r)&&!isNaN(r)&&(l=new Date(+r));return(!l||isNaN(+l))&&console&&console.error&&console.error(`Failed to parse x '${r}' to Date object`),l}function fl(r){const o=r.attr("viewBox");return o?/(\d+(\.\d+)?){3}/.test(o):!1}function ll(r,o,l=!1){const g=!!r.node;let x=!1;for(const[O,T]of Object.entries(o))if(x=g?r.style(O)===T:r.style[O]===T,l===!1&&x)break;return x}function cl(){var r,o;return((r=document)==null?void 0:r.hidden)===!1||((o=document)==null?void 0:o.visibilityState)==="visible"}function vl(r,o){const{DocumentTouch:l,matchMedia:g,navigator:x}=window,O=g==null?void 0:g("(pointer:coarse)").matches;let T=!1;if(o)if(x&&"maxTouchPoints"in x)T=x.maxTouchPoints>0;else if("ontouchmove"in window||l&&document instanceof l)T=!0;else if(O)T=!0;else{const $=x.userAgent;T=/\b(BlackBerry|webOS|iPhone|IEMobile)\b/i.test($)||/\b(Android|Windows Phone|iPad|iPod)\b/i.test($)}return r&&!O&&(g==null?void 0:g("(pointer:fine)").matches)&&"mouse"||T&&"touch"||"mouse"}function Xu(r,o){o()===!1?requestAnimationFrame(()=>Xu(r,o)):r()}function Ju(r){const o=this.config;let l,g,x;const O=()=>{const T=g.shift();if(T&&l&&Ie(l)&&T in l)return l=l[T],O();if(!T)return l};Object.keys(o).forEach(T=>{l=r,g=T.split("_"),x=O(),Oa(x)&&(o[T]=x)}),this.api&&(this.state.orgConfig=r)}var Qu=Object.defineProperty,Zu=(r,o,l)=>o in r?Qu(r,o,{enumerable:!0,configurable:!0,writable:!0,value:l}):r[o]=l,Re=(r,o,l)=>Zu(r,typeof o!="symbol"?o+"":o,l);class Aa{constructor(o={}){Re(this,"$$"),Re(this,"options"),this.options=o}$beforeInit(){}$init(){}$afterInit(){}$redraw(){}$willDestroy(){Object.keys(this).forEach(o=>{this[o]=null,delete this[o]})}}Re(Aa,"version","3.14.2");function ku(r){return r}var Qn=1,Zn=2,Ae=3,Rn=4,Pa=1e-6;function qu(r){return"translate("+r+",0)"}function _u(r){return"translate(0,"+r+")"}function tf(r){return o=>+r(o)}function rf(r,o){return o=Math.max(0,r.bandwidth()-o*2)/2,r.round()&&(o=Math.round(o)),l=>+r(l)+o}function nf(){return!this.__axis}function kn(r,o){var l=[],g=null,x=null,O=6,T=6,D=3,$=typeof window!="undefined"&&window.devicePixelRatio>1?0:.5,L=r===Qn||r===Rn?-1:1,H=r===Rn||r===Zn?"x":"y",K=r===Qn||r===Ae?qu:_u;function _(et){var zt=g==null?o.ticks?o.ticks.apply(o,l):o.domain():g,or=x==null?o.tickFormat?o.tickFormat.apply(o,l):ku:x,pt=Math.max(O,0)+D,Ct=o.range(),Gt=+Ct[0]+$,Dt=+Ct[Ct.length-1]+$,kt=(o.bandwidth?rf:tf)(o.copy(),$),Yt=et.selection?et.selection():et,pr=Yt.selectAll(".domain").data([null]),Sr=Yt.selectAll(".tick").data(zt,o).order(),cr=Sr.exit(),Nr=Sr.enter().append("g").attr("class","tick"),sr=Sr.select("line"),Ut=Sr.select("text");pr=pr.merge(pr.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),Sr=Sr.merge(Nr),sr=sr.merge(Nr.append("line").attr("stroke","currentColor").attr(H+"2",L*O)),Ut=Ut.merge(Nr.append("text").attr("fill","currentColor").attr(H,L*pt).attr("dy",r===Qn?"0em":r===Ae?"0.71em":"0.32em")),et!==Yt&&(pr=pr.transition(et),Sr=Sr.transition(et),sr=sr.transition(et),Ut=Ut.transition(et),cr=cr.transition(et).attr("opacity",Pa).attr("transform",function(gr){return isFinite(gr=kt(gr))?K(gr+$):this.getAttribute("transform")}),Nr.attr("opacity",Pa).attr("transform",function(gr){var ar=this.parentNode.__axis;return K((ar&&isFinite(ar=ar(gr))?ar:kt(gr))+$)})),cr.remove(),pr.attr("d",r===Rn||r===Zn?T?"M"+L*T+","+Gt+"H"+$+"V"+Dt+"H"+L*T:"M"+$+","+Gt+"V"+Dt:T?"M"+Gt+","+L*T+"V"+$+"H"+Dt+"V"+L*T:"M"+Gt+","+$+"H"+Dt),Sr.attr("opacity",1).attr("transform",function(gr){return K(kt(gr)+$)}),sr.attr(H+"2",L*O),Ut.attr(H,L*pt).text(or),Yt.filter(nf).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",r===Zn?"start":r===Rn?"end":"middle"),Yt.each(function(){this.__axis=kt})}return _.scale=function(et){return arguments.length?(o=et,_):o},_.ticks=function(){return l=Array.from(arguments),_},_.tickArguments=function(et){return arguments.length?(l=et==null?[]:Array.from(et),_):l.slice()},_.tickValues=function(et){return arguments.length?(g=et==null?null:Array.from(et),_):g&&g.slice()},_.tickFormat=function(et){return arguments.length?(x=et,_):x},_.tickSize=function(et){return arguments.length?(O=T=+et,_):O},_.tickSizeInner=function(et){return arguments.length?(O=+et,_):O},_.tickSizeOuter=function(et){return arguments.length?(T=+et,_):T},_.tickPadding=function(et){return arguments.length?(D=+et,_):D},_.offset=function(et){return arguments.length?($=+et,_):$},_}function dl(r){return kn(Qn,r)}function ef(r){return kn(Zn,r)}function hl(r){return kn(Ae,r)}function gl(r){return kn(Rn,r)}function Ca(r){return function(o){return Math.sign(o)*Math.log1p(Math.abs(o/r))}}function Na(r){return function(o){return Math.sign(o)*Math.expm1(Math.abs(o))*r}}function af(r){var o=1,l=r(Ca(o),Na(o));return l.constant=function(g){return arguments.length?r(Ca(o=+g),Na(o)):o},ae(l)}function Ma(){var r=af(jr());return r.copy=function(){return _r(r,Ma()).constant(r.constant())},Jr.apply(r,arguments)}var Xr={colorScale:"bb-colorscale",stanfordElements:"bb-stanford-elements",stanfordLine:"bb-stanford-line",stanfordLines:"bb-stanford-lines",stanfordRegion:"bb-stanford-region",stanfordRegions:"bb-stanford-regions"},of=Object.defineProperty,sf=(r,o,l)=>o in r?of(r,o,{enumerable:!0,configurable:!0,writable:!0,value:l}):r[o]=l,ba=(r,o,l)=>sf(r,typeof o!="symbol"?o+"":o,l);class uf{constructor(o){ba(this,"owner"),ba(this,"colorScale"),this.owner=o}drawColorScale(){const{$$:o,config:l}=this.owner,g=o.data.targets[0],x=o.state.height-l.padding_bottom-l.padding_top,O=l.scale_width,T=5,D=Yu(l.padding_bottom,x,T),$=Le(g.colors).domain([D[D.length-1],D[0]]);this.colorScale&&this.colorScale.remove(),this.colorScale=o.$el.svg.append("g").attr("width",50).attr("height",x).attr("class",Xr.colorScale),this.colorScale.append("g").attr("transform",`translate(0, ${l.padding_top})`).selectAll("bars").data(D).enter().append("rect").attr("y",(et,zt)=>zt*T).attr("x",0).attr("width",O).attr("height",T).attr("fill",et=>$(et));const L=Ma().domain([g.minEpochs,g.maxEpochs]).range([D[0]+l.padding_top+D[D.length-1]+T-1,D[0]+l.padding_top]),H=ef(L),K=l.scale_format;K==="pow10"?H.tickValues([1,10,100,1e3,1e4,1e5,1e6,1e7]):Se(K)?H.tickFormat(K):H.tickFormat(bn("d"));const _=this.colorScale.append("g").attr("class","legend axis").attr("transform",`translate(${O},0)`).call(H);K==="pow10"&&_.selectAll(".tick text").text(null).filter(et=>et/Math.pow(10,Math.ceil(Math.log(et)/Math.LN10-1e-12))===1).text(10).append("tspan").attr("dy","-.7em").text(et=>Math.round(Math.log(et)/Math.LN10)),this.colorScale.attr("transform",`translate(${o.state.current.width-this.xForColorScale()}, 0)`)}xForColorScale(){return this.owner.config.padding_right+this.colorScale.node().getBBox().width}getColorScalePadding(){return this.xForColorScale()+this.owner.config.padding_left+20}}function ff(r,o){const l=r.x,g=r.value;let x=!1;for(let O=0,T=o.length-1;O<o.length;T=O++){const D=o[O].x,$=o[O].y,L=o[T].x,H=o[T].y;$>g!=H>g&&l<(L-D)*(g-$)/(H-$)+D&&(x=!x)}return x}function lf(r,o){return r.epochs<o.epochs?-1:r.epochs>o.epochs?1:0}function cf(r){let o=0,l,g;for(let x=0,O=r.length,T=O-1;x<O;T=x,x++)l=r[x],g=r[T],o+=l.x*g.y,o-=l.y*g.x;return o/=2,o}function qn(r){const o=cf(r);let l=0,g=0,x;for(let O=0,T=r.length,D=T-1;O<T;D=O,O++){const $=r[O],L=r[D];x=$.x*L.y-L.x*$.y,l+=($.x+L.x)*x,g+=($.y+L.y)*x}return x=o*6,{x:l/x,y:g/x}}var vf=Object.defineProperty,df=(r,o,l)=>o in r?vf(r,o,{enumerable:!0,configurable:!0,writable:!0,value:l}):r[o]=l,hf=(r,o,l)=>df(r,typeof o!="symbol"?o+"":o,l);class gf{constructor(o){hf(this,"owner"),this.owner=o;const l=o.$$.$el.main.select(".bb-chart").append("g").attr("class",Xr.stanfordElements);l.append("g").attr("class",Xr.stanfordLines),l.append("g").attr("class",Xr.stanfordRegions)}updateStanfordLines(o){const{$$:l}=this.owner,{config:g,$el:{main:x}}=l,O=g.axis_rotated,T=this.xvCustom.bind(l),D=this.yvCustom.bind(l),$=x.select(`.${Xr.stanfordLines}`).style("shape-rendering","geometricprecision").selectAll(`.${Xr.stanfordLine}`).data(this.owner.config.lines);$.exit().transition().duration(o).style("opacity","0").remove();const L=$.enter().append("g");L.append("line").style("opacity","0"),L.merge($).attr("class",H=>Xr.stanfordLine+(H.class?` ${H.class}`:"")).select("line").transition().duration(o).attr("x1",H=>O?D(H,"y1"):T(H,"x1")).attr("x2",H=>O?D(H,"y2"):T(H,"x2")).attr("y1",H=>O?T(H,"x1"):D(H,"y1")).attr("y2",H=>O?T(H,"x2"):D(H,"y2")).transition().style("opacity",null)}updateStanfordRegions(o){const{$$:l}=this.owner,{config:g,$el:{main:x}}=l,O=g.axis_rotated,T=this.xvCustom.bind(l),D=this.yvCustom.bind(l),$=this.owner.countEpochsInRegion.bind(l);let L=x.select(`.${Xr.stanfordRegions}`).selectAll(`.${Xr.stanfordRegion}`).data(this.owner.config.regions);L.exit().transition().duration(o).style("opacity","0").remove();const H=L.enter().append("g");H.append("polygon").style("opacity","0"),H.append("text").attr("transform",O?"rotate(-90)":"").style("opacity","0"),L=H.merge(L),L.attr("class",K=>Xr.stanfordRegion+(K.class?` ${K.class}`:"")).select("polygon").transition().duration(o).attr("points",K=>K.points.map(_=>[O?D(_,"y"):T(_,"x"),O?T(_,"x"):D(_,"y")].join(",")).join(" ")).transition().style("opacity",K=>String(K.opacity?K.opacity:.2)),L.select("text").transition().duration(o).attr("x",K=>O?D(qn(K.points),"y"):T(qn(K.points),"x")).attr("y",K=>O?T(qn(K.points),"x"):D(qn(K.points),"y")).text(K=>{if(K.text){const{value:_,percentage:et}=$(K.points);return K.text(_,et)}return""}).attr("text-anchor","middle").attr("dominant-baseline","middle").transition().style("opacity",null)}updateStanfordElements(o=0){this.updateStanfordLines(o),this.updateStanfordRegions(o)}xvCustom(o,l){const g=this,{axis:x,config:O}=g;let T=l?o[l]:g.getBaseValue(o);return x.isTimeSeries()?T=Ku.call(g,T):x.isCategorized()&&Tn(T)&&(T=O.axis_x_categories.indexOf(o.value)),g.scale.x(T)}yvCustom(o,l){const g=this,x=o.axis&&o.axis==="y2"?g.scale.y2:g.scale.y,O=l?o[l]:g.getBaseValue(o);return x(O)}}class Da{constructor(){return{colors:void 0,epochs:[],lines:[],scale_min:void 0,scale_max:void 0,scale_width:20,scale_format:void 0,padding_top:0,padding_right:0,padding_bottom:0,padding_left:0,regions:[]}}}var pf=Object.defineProperty,yf=(r,o,l)=>o in r?pf(r,o,{enumerable:!0,configurable:!0,writable:!0,value:l}):r[o]=l,Pe=(r,o,l)=>yf(r,typeof o!="symbol"?o+"":o,l);class mf extends Aa{constructor(o){return super(o),Pe(this,"config"),Pe(this,"colorScale"),Pe(this,"elements"),this.config=new Da,this}$beforeInit(){const{$$:o}=this;o.config.data_xSort=!1,o.isMultipleX=()=>!0,o.showGridFocus=()=>{},o.labelishData=g=>g.values,o.opacityForCircle=()=>1;const l=o.getCurrentPadding.bind(o);o.getCurrentPadding=()=>{const g=l();return g.right+=this.colorScale?this.colorScale.getColorScalePadding():0,g}}$init(){const{$$:o}=this;Ju.call(this,this.options),o.color=this.getStanfordPointColor.bind(o),this.colorScale=new uf(this),this.elements=new gf(this),this.convertData(),this.initStanfordData(),this.setStanfordTooltip(),this.colorScale.drawColorScale(),o.right+=this.colorScale?this.colorScale.getColorScalePadding():0,this.$redraw()}$redraw(o){var l,g;(l=this.colorScale)==null||l.drawColorScale(),(g=this.elements)==null||g.updateStanfordElements(o)}getOptions(){return new Da}convertData(){const o=this.$$.data.targets,l=this.options.epochs;o.forEach(g=>{g.values.forEach((x,O)=>{x.epochs=l[O]}),g.minEpochs=void 0,g.maxEpochs=void 0,g.colors=void 0,g.colorscale=void 0})}initStanfordData(){const{config:o}=this,l=this.$$.data.targets[0];l.values.sort(lf);const g=l.values.map(x=>x.epochs);l.minEpochs=isNaN(o.scale_min)?Math.min(...g):o.scale_min,l.maxEpochs=isNaN(o.scale_max)?Math.max(...g):o.scale_max,l.colors=Se(o.colors)?o.colors:Bt(rt(250,1,.5),rt(0,1,.5)),l.colorscale=Ue(l.colors).domain([l.minEpochs,l.maxEpochs])}getStanfordPointColor(o){return this.data.targets[0].colorscale(o.epochs)}setStanfordTooltip(){const{config:o}=this.$$;Ta(o.tooltip_contents)&&(o.tooltip_contents=function(l,g,x,O){const{data_x:T}=o;let D=`<table class="${oe.tooltip}"><tbody>`;return l.forEach($=>{const{id:L="",value:H=0,epochs:K=0,x:_=""}=$;D+=`<tr>
13
+ `),T=g?O.length-1:1;r.html(""),O.forEach((D,$)=>{r.append("tspan").attr("x",0).attr("dy",`${$===0?l[0]*T:l[1]}em`).text(D)})}}}function Gu(r){const{x:o,y:l,width:g,height:x}=r.getBBox();return[{x:o,y:l+x},{x:o,y:l},{x:o+g,y:l},{x:o+g,y:l+x}]}function Yf(r){const{width:o,height:l}=r.getBoundingClientRect(),g=Gu(r),x=g[0].x,O=Math.min(g[0].y,g[1].y);return{x,y:O,width:o,height:l}}function Kf(r,o){var l;const g=r&&((l=r.touches||r.sourceEvent&&r.sourceEvent.touches)==null?void 0:l[0]);let x=[0,0];try{x=d3Pointer(g||r,o)}catch(O){}return x.map(O=>isNaN(O)?0:O)}function Vu(r){const{event:o,$el:l}=r,g=l.subchart.main||l.main;let x;return o&&o.type==="brush"?x=o.selection:g&&(x=g.select(".bb-brush").node())&&(x=d3BrushSelection(x)),x}function Xf(r){return!("rect"in r)||"rect"in r&&r.hasAttribute("width")&&r.rect.width!==+r.getAttribute("width")?r.rect=r.getBoundingClientRect():r.rect}function Jf(r=!0,o=0,l=1e4){const g=window.crypto||window.msCrypto,x=g?o+g.getRandomValues(new Uint32Array(1))[0]%(l-o+1):Math.floor(Math.random()*(l-o)+o);return r?String(x):x}function Ra(r,o,l,g,x){if(l>g)return-1;const O=Math.floor((l+g)/2);let{x:T,w:D=0}=r[O];return x&&(T=r[O].y,D=r[O].h),o>=T&&o<=T+D?O:o<T?Ra(r,o,l,O-1,x):Ra(r,o,O+1,g,x)}function Qf(r){const o=Vu(r);return o?o[0]===o[1]:!0}function Zf(...r){const o=l=>{if(Jn(l)&&l.constructor){const g=new l.constructor;for(const x in l)g[x]=o(l[x]);return g}return l};return r.map(l=>o(l)).reduce((l,g)=>Ia(Ia({},l),g))}function Hu(r={},o){Oe(o)&&o.forEach(l=>Hu(r,l));for(const l in o)/^\d+$/.test(l)||l in r||(r[l]=o[l]);return r}const kf=r=>r.charAt(0).toUpperCase()+r.slice(1);function qf(r,o="-"){return r.split(o).map((l,g)=>g?l.charAt(0).toUpperCase()+l.slice(1).toLowerCase():l.toLowerCase()).join("")}const Wu=r=>[].slice.call(r);function _f(r,o,l){const{rootSelector:g="",sheet:x}=r,T=`${g} ${(D=>D.replace(/\s?(bb-)/g,".$1").replace(/\.+/g,"."))(o)} {${l.join(";")}}`;return x[x.insertRule?"insertRule":"addRule"](T,x.cssRules.length)}function tl(r){let o=[];return r.forEach(l=>{var g;try{l.cssRules&&l.cssRules.length&&(o=o.concat(Wu(l.cssRules)))}catch(x){(g=window.console)==null||g.warn(`Error while reading rules from ${l.href}: ${x.toString()}`)}}),o}function rl(r){var o,l,g,x,O,T;return{x:((l=(o=window.pageXOffset)!=null?o:window.scrollX)!=null?l:0)+((g=r.scrollLeft)!=null?g:0),y:((O=(x=window.pageYOffset)!=null?x:window.scrollY)!=null?O:0)+((T=r.scrollTop)!=null?T:0)}}function nl(r,o=0,l=0,g=!0){const x=new DOMPoint(o,l),O=r.getScreenCTM(),T=x.matrixTransform(g?O==null?void 0:O.inverse():O);if(g===!1){const D=r.getBoundingClientRect();T.x-=D.x,T.y-=D.y}return T}function el(r){const o=r?r.transform:null,l=o&&o.baseVal;return l&&l.numberOfItems?l.getItem(0).matrix:{a:0,b:0,c:0,d:0,e:0,f:0}}function al(r){const o=r[0]instanceof Date,l=(o?r.map(Number):r).filter((g,x,O)=>O.indexOf(g)===x);return o?l.map(g=>new Date(g)):l}function ol(r){return r&&r.length?r.reduce((o,l)=>o.concat(l)):[]}function Te(r,...o){if(!o.length||o.length===1&&!o[0])return r;const l=o.shift();return Jn(r)&&Jn(l)&&Object.keys(l).forEach(g=>{const x=l[g];Jn(x)?(!r[g]&&(r[g]={}),r[g]=Te(r[g],x)):r[g]=Oe(x)?x.concat():x}),Te(r,...o)}function zu(r,o=!0){let l;return r[0]instanceof Date?l=o?(g,x)=>g-x:(g,x)=>x-g:o&&!r.every(isNaN)?l=(g,x)=>g-x:o||(l=(g,x)=>g>x&&-1||g<x&&1||g===x&&0),r.concat().sort(l)}function sl(r,o){let l=o.filter(g=>wu(g));return l.length?Ee(l[0])?l=Math[r](...l):l[0]instanceof Date&&(l=zu(l,r==="min")[0]):l=void 0,l}const Yu=(r,o,l=1)=>{const g=[],x=Math.max(0,Math.ceil((o-r)/l))|0;for(let O=r;O<x;O++)g.push(r+O*l);return g},il={mouse:(()=>{const r=()=>({bubbles:!1,cancelable:!1,screenX:0,screenY:0,clientX:0,clientY:0});try{return new MouseEvent("t"),(o,l,g=r())=>{o.dispatchEvent(new MouseEvent(l,g))}}catch(o){return(l,g,x=r())=>{const O=$u.createEvent("MouseEvent");O.initMouseEvent(g,x.bubbles,x.cancelable,Xn,0,x.screenX,x.screenY,x.clientX,x.clientY,!1,!1,!1,!1,0,null),l.dispatchEvent(O)}}})(),touch:(r,o,l)=>{const g=new Touch(Te({identifier:Date.now(),target:r,radiusX:2.5,radiusY:2.5,rotationAngle:10,force:.5},l));r.dispatchEvent(new TouchEvent(o,{cancelable:!0,bubbles:!0,shiftKey:!0,touches:[g],targetTouches:[],changedTouches:[g]}))}};function ul(r,o){let l=r;for(const g in o)l=l.replace(new RegExp(`{=${g}}`,"g"),o[g]);return l}function Ku(r){var o;let l;if(r instanceof Date)l=r;else if(Tn(r)){const{config:g,format:x}=this;l=(o=x.dataTime(g.data_xFormat)(r))!=null?o:new Date(r)}else Ee(r)&&!isNaN(r)&&(l=new Date(+r));return(!l||isNaN(+l))&&console&&console.error&&console.error(`Failed to parse x '${r}' to Date object`),l}function fl(r){const o=r.attr("viewBox");return o?/(\d+(\.\d+)?){3}/.test(o):!1}function ll(r,o,l=!1){const g=!!r.node;let x=!1;for(const[O,T]of Object.entries(o))if(x=g?r.style(O)===T:r.style[O]===T,l===!1&&x)break;return x}function cl(){var r,o;return((r=document)==null?void 0:r.hidden)===!1||((o=document)==null?void 0:o.visibilityState)==="visible"}function vl(r,o){const{DocumentTouch:l,matchMedia:g,navigator:x}=window,O=g==null?void 0:g("(pointer:coarse)").matches;let T=!1;if(o)if(x&&"maxTouchPoints"in x)T=x.maxTouchPoints>0;else if("ontouchmove"in window||l&&document instanceof l)T=!0;else if(O)T=!0;else{const $=x.userAgent;T=/\b(BlackBerry|webOS|iPhone|IEMobile)\b/i.test($)||/\b(Android|Windows Phone|iPad|iPod)\b/i.test($)}return r&&!O&&(g==null?void 0:g("(pointer:fine)").matches)&&"mouse"||T&&"touch"||"mouse"}function Xu(r,o){o()===!1?requestAnimationFrame(()=>Xu(r,o)):r()}function Ju(r){const o=this.config;let l,g,x;const O=()=>{const T=g.shift();if(T&&l&&Ie(l)&&T in l)return l=l[T],O();if(!T)return l};Object.keys(o).forEach(T=>{l=r,g=T.split("_"),x=O(),Oa(x)&&(o[T]=x)}),this.api&&(this.state.orgConfig=r)}var Qu=Object.defineProperty,Zu=(r,o,l)=>o in r?Qu(r,o,{enumerable:!0,configurable:!0,writable:!0,value:l}):r[o]=l,Re=(r,o,l)=>Zu(r,typeof o!="symbol"?o+"":o,l);class Aa{constructor(o={}){Re(this,"$$"),Re(this,"options"),this.options=o}$beforeInit(){}$init(){}$afterInit(){}$redraw(){}$willDestroy(){Object.keys(this).forEach(o=>{this[o]=null,delete this[o]})}}Re(Aa,"version","3.14.3");function ku(r){return r}var Qn=1,Zn=2,Ae=3,Rn=4,Pa=1e-6;function qu(r){return"translate("+r+",0)"}function _u(r){return"translate(0,"+r+")"}function tf(r){return o=>+r(o)}function rf(r,o){return o=Math.max(0,r.bandwidth()-o*2)/2,r.round()&&(o=Math.round(o)),l=>+r(l)+o}function nf(){return!this.__axis}function kn(r,o){var l=[],g=null,x=null,O=6,T=6,D=3,$=typeof window!="undefined"&&window.devicePixelRatio>1?0:.5,L=r===Qn||r===Rn?-1:1,H=r===Rn||r===Zn?"x":"y",K=r===Qn||r===Ae?qu:_u;function _(et){var zt=g==null?o.ticks?o.ticks.apply(o,l):o.domain():g,or=x==null?o.tickFormat?o.tickFormat.apply(o,l):ku:x,pt=Math.max(O,0)+D,Ct=o.range(),Gt=+Ct[0]+$,Dt=+Ct[Ct.length-1]+$,kt=(o.bandwidth?rf:tf)(o.copy(),$),Yt=et.selection?et.selection():et,pr=Yt.selectAll(".domain").data([null]),Sr=Yt.selectAll(".tick").data(zt,o).order(),cr=Sr.exit(),Nr=Sr.enter().append("g").attr("class","tick"),sr=Sr.select("line"),Ut=Sr.select("text");pr=pr.merge(pr.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),Sr=Sr.merge(Nr),sr=sr.merge(Nr.append("line").attr("stroke","currentColor").attr(H+"2",L*O)),Ut=Ut.merge(Nr.append("text").attr("fill","currentColor").attr(H,L*pt).attr("dy",r===Qn?"0em":r===Ae?"0.71em":"0.32em")),et!==Yt&&(pr=pr.transition(et),Sr=Sr.transition(et),sr=sr.transition(et),Ut=Ut.transition(et),cr=cr.transition(et).attr("opacity",Pa).attr("transform",function(gr){return isFinite(gr=kt(gr))?K(gr+$):this.getAttribute("transform")}),Nr.attr("opacity",Pa).attr("transform",function(gr){var ar=this.parentNode.__axis;return K((ar&&isFinite(ar=ar(gr))?ar:kt(gr))+$)})),cr.remove(),pr.attr("d",r===Rn||r===Zn?T?"M"+L*T+","+Gt+"H"+$+"V"+Dt+"H"+L*T:"M"+$+","+Gt+"V"+Dt:T?"M"+Gt+","+L*T+"V"+$+"H"+Dt+"V"+L*T:"M"+Gt+","+$+"H"+Dt),Sr.attr("opacity",1).attr("transform",function(gr){return K(kt(gr)+$)}),sr.attr(H+"2",L*O),Ut.attr(H,L*pt).text(or),Yt.filter(nf).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",r===Zn?"start":r===Rn?"end":"middle"),Yt.each(function(){this.__axis=kt})}return _.scale=function(et){return arguments.length?(o=et,_):o},_.ticks=function(){return l=Array.from(arguments),_},_.tickArguments=function(et){return arguments.length?(l=et==null?[]:Array.from(et),_):l.slice()},_.tickValues=function(et){return arguments.length?(g=et==null?null:Array.from(et),_):g&&g.slice()},_.tickFormat=function(et){return arguments.length?(x=et,_):x},_.tickSize=function(et){return arguments.length?(O=T=+et,_):O},_.tickSizeInner=function(et){return arguments.length?(O=+et,_):O},_.tickSizeOuter=function(et){return arguments.length?(T=+et,_):T},_.tickPadding=function(et){return arguments.length?(D=+et,_):D},_.offset=function(et){return arguments.length?($=+et,_):$},_}function dl(r){return kn(Qn,r)}function ef(r){return kn(Zn,r)}function hl(r){return kn(Ae,r)}function gl(r){return kn(Rn,r)}function Ca(r){return function(o){return Math.sign(o)*Math.log1p(Math.abs(o/r))}}function Na(r){return function(o){return Math.sign(o)*Math.expm1(Math.abs(o))*r}}function af(r){var o=1,l=r(Ca(o),Na(o));return l.constant=function(g){return arguments.length?r(Ca(o=+g),Na(o)):o},ae(l)}function Ma(){var r=af(jr());return r.copy=function(){return _r(r,Ma()).constant(r.constant())},Jr.apply(r,arguments)}var Xr={colorScale:"bb-colorscale",stanfordElements:"bb-stanford-elements",stanfordLine:"bb-stanford-line",stanfordLines:"bb-stanford-lines",stanfordRegion:"bb-stanford-region",stanfordRegions:"bb-stanford-regions"},of=Object.defineProperty,sf=(r,o,l)=>o in r?of(r,o,{enumerable:!0,configurable:!0,writable:!0,value:l}):r[o]=l,ba=(r,o,l)=>sf(r,typeof o!="symbol"?o+"":o,l);class uf{constructor(o){ba(this,"owner"),ba(this,"colorScale"),this.owner=o}drawColorScale(){const{$$:o,config:l}=this.owner,g=o.data.targets[0],x=o.state.height-l.padding_bottom-l.padding_top,O=l.scale_width,T=5,D=Yu(l.padding_bottom,x,T),$=Le(g.colors).domain([D[D.length-1],D[0]]);this.colorScale&&this.colorScale.remove(),this.colorScale=o.$el.svg.append("g").attr("width",50).attr("height",x).attr("class",Xr.colorScale),this.colorScale.append("g").attr("transform",`translate(0, ${l.padding_top})`).selectAll("bars").data(D).enter().append("rect").attr("y",(et,zt)=>zt*T).attr("x",0).attr("width",O).attr("height",T).attr("fill",et=>$(et));const L=Ma().domain([g.minEpochs,g.maxEpochs]).range([D[0]+l.padding_top+D[D.length-1]+T-1,D[0]+l.padding_top]),H=ef(L),K=l.scale_format;K==="pow10"?H.tickValues([1,10,100,1e3,1e4,1e5,1e6,1e7]):Se(K)?H.tickFormat(K):H.tickFormat(bn("d"));const _=this.colorScale.append("g").attr("class","legend axis").attr("transform",`translate(${O},0)`).call(H);K==="pow10"&&_.selectAll(".tick text").text(null).filter(et=>et/Math.pow(10,Math.ceil(Math.log(et)/Math.LN10-1e-12))===1).text(10).append("tspan").attr("dy","-.7em").text(et=>Math.round(Math.log(et)/Math.LN10)),this.colorScale.attr("transform",`translate(${o.state.current.width-this.xForColorScale()}, 0)`)}xForColorScale(){return this.owner.config.padding_right+this.colorScale.node().getBBox().width}getColorScalePadding(){return this.xForColorScale()+this.owner.config.padding_left+20}}function ff(r,o){const l=r.x,g=r.value;let x=!1;for(let O=0,T=o.length-1;O<o.length;T=O++){const D=o[O].x,$=o[O].y,L=o[T].x,H=o[T].y;$>g!=H>g&&l<(L-D)*(g-$)/(H-$)+D&&(x=!x)}return x}function lf(r,o){return r.epochs<o.epochs?-1:r.epochs>o.epochs?1:0}function cf(r){let o=0,l,g;for(let x=0,O=r.length,T=O-1;x<O;T=x,x++)l=r[x],g=r[T],o+=l.x*g.y,o-=l.y*g.x;return o/=2,o}function qn(r){const o=cf(r);let l=0,g=0,x;for(let O=0,T=r.length,D=T-1;O<T;D=O,O++){const $=r[O],L=r[D];x=$.x*L.y-L.x*$.y,l+=($.x+L.x)*x,g+=($.y+L.y)*x}return x=o*6,{x:l/x,y:g/x}}var vf=Object.defineProperty,df=(r,o,l)=>o in r?vf(r,o,{enumerable:!0,configurable:!0,writable:!0,value:l}):r[o]=l,hf=(r,o,l)=>df(r,typeof o!="symbol"?o+"":o,l);class gf{constructor(o){hf(this,"owner"),this.owner=o;const l=o.$$.$el.main.select(".bb-chart").append("g").attr("class",Xr.stanfordElements);l.append("g").attr("class",Xr.stanfordLines),l.append("g").attr("class",Xr.stanfordRegions)}updateStanfordLines(o){const{$$:l}=this.owner,{config:g,$el:{main:x}}=l,O=g.axis_rotated,T=this.xvCustom.bind(l),D=this.yvCustom.bind(l),$=x.select(`.${Xr.stanfordLines}`).style("shape-rendering","geometricprecision").selectAll(`.${Xr.stanfordLine}`).data(this.owner.config.lines);$.exit().transition().duration(o).style("opacity","0").remove();const L=$.enter().append("g");L.append("line").style("opacity","0"),L.merge($).attr("class",H=>Xr.stanfordLine+(H.class?` ${H.class}`:"")).select("line").transition().duration(o).attr("x1",H=>O?D(H,"y1"):T(H,"x1")).attr("x2",H=>O?D(H,"y2"):T(H,"x2")).attr("y1",H=>O?T(H,"x1"):D(H,"y1")).attr("y2",H=>O?T(H,"x2"):D(H,"y2")).transition().style("opacity",null)}updateStanfordRegions(o){const{$$:l}=this.owner,{config:g,$el:{main:x}}=l,O=g.axis_rotated,T=this.xvCustom.bind(l),D=this.yvCustom.bind(l),$=this.owner.countEpochsInRegion.bind(l);let L=x.select(`.${Xr.stanfordRegions}`).selectAll(`.${Xr.stanfordRegion}`).data(this.owner.config.regions);L.exit().transition().duration(o).style("opacity","0").remove();const H=L.enter().append("g");H.append("polygon").style("opacity","0"),H.append("text").attr("transform",O?"rotate(-90)":"").style("opacity","0"),L=H.merge(L),L.attr("class",K=>Xr.stanfordRegion+(K.class?` ${K.class}`:"")).select("polygon").transition().duration(o).attr("points",K=>K.points.map(_=>[O?D(_,"y"):T(_,"x"),O?T(_,"x"):D(_,"y")].join(",")).join(" ")).transition().style("opacity",K=>String(K.opacity?K.opacity:.2)),L.select("text").transition().duration(o).attr("x",K=>O?D(qn(K.points),"y"):T(qn(K.points),"x")).attr("y",K=>O?T(qn(K.points),"x"):D(qn(K.points),"y")).text(K=>{if(K.text){const{value:_,percentage:et}=$(K.points);return K.text(_,et)}return""}).attr("text-anchor","middle").attr("dominant-baseline","middle").transition().style("opacity",null)}updateStanfordElements(o=0){this.updateStanfordLines(o),this.updateStanfordRegions(o)}xvCustom(o,l){const g=this,{axis:x,config:O}=g;let T=l?o[l]:g.getBaseValue(o);return x.isTimeSeries()?T=Ku.call(g,T):x.isCategorized()&&Tn(T)&&(T=O.axis_x_categories.indexOf(o.value)),g.scale.x(T)}yvCustom(o,l){const g=this,x=o.axis&&o.axis==="y2"?g.scale.y2:g.scale.y,O=l?o[l]:g.getBaseValue(o);return x(O)}}class Da{constructor(){return{colors:void 0,epochs:[],lines:[],scale_min:void 0,scale_max:void 0,scale_width:20,scale_format:void 0,padding_top:0,padding_right:0,padding_bottom:0,padding_left:0,regions:[]}}}var pf=Object.defineProperty,yf=(r,o,l)=>o in r?pf(r,o,{enumerable:!0,configurable:!0,writable:!0,value:l}):r[o]=l,Pe=(r,o,l)=>yf(r,typeof o!="symbol"?o+"":o,l);class mf extends Aa{constructor(o){return super(o),Pe(this,"config"),Pe(this,"colorScale"),Pe(this,"elements"),this.config=new Da,this}$beforeInit(){const{$$:o}=this;o.config.data_xSort=!1,o.isMultipleX=()=>!0,o.showGridFocus=()=>{},o.labelishData=g=>g.values,o.opacityForCircle=()=>1;const l=o.getCurrentPadding.bind(o);o.getCurrentPadding=()=>{const g=l();return g.right+=this.colorScale?this.colorScale.getColorScalePadding():0,g}}$init(){const{$$:o}=this;Ju.call(this,this.options),o.color=this.getStanfordPointColor.bind(o),this.colorScale=new uf(this),this.elements=new gf(this),this.convertData(),this.initStanfordData(),this.setStanfordTooltip(),this.colorScale.drawColorScale(),o.right+=this.colorScale?this.colorScale.getColorScalePadding():0,this.$redraw()}$redraw(o){var l,g;(l=this.colorScale)==null||l.drawColorScale(),(g=this.elements)==null||g.updateStanfordElements(o)}getOptions(){return new Da}convertData(){const o=this.$$.data.targets,l=this.options.epochs;o.forEach(g=>{g.values.forEach((x,O)=>{x.epochs=l[O]}),g.minEpochs=void 0,g.maxEpochs=void 0,g.colors=void 0,g.colorscale=void 0})}initStanfordData(){const{config:o}=this,l=this.$$.data.targets[0];l.values.sort(lf);const g=l.values.map(x=>x.epochs);l.minEpochs=isNaN(o.scale_min)?Math.min(...g):o.scale_min,l.maxEpochs=isNaN(o.scale_max)?Math.max(...g):o.scale_max,l.colors=Se(o.colors)?o.colors:Bt(rt(250,1,.5),rt(0,1,.5)),l.colorscale=Ue(l.colors).domain([l.minEpochs,l.maxEpochs])}getStanfordPointColor(o){return this.data.targets[0].colorscale(o.epochs)}setStanfordTooltip(){const{config:o}=this.$$;Ta(o.tooltip_contents)&&(o.tooltip_contents=function(l,g,x,O){const{data_x:T}=o;let D=`<table class="${oe.tooltip}"><tbody>`;return l.forEach($=>{const{id:L="",value:H=0,epochs:K=0,x:_=""}=$;D+=`<tr>
14
14
  <th>${T||""}</th>
15
15
  <th class="value">${g(_)}</th>
16
16
  </tr>
@@ -5,7 +5,7 @@
5
5
  * billboard.js, JavaScript chart library
6
6
  * https://naver.github.io/billboard.js/
7
7
  *
8
- * @version 3.14.2
8
+ * @version 3.14.3
9
9
  * @requires billboard.js
10
10
  * @summary billboard.js plugin
11
11
  */
@@ -23534,7 +23534,7 @@ class Plugin {
23534
23534
  });
23535
23535
  }
23536
23536
  }
23537
- __publicField(Plugin, "version", "3.14.2");
23537
+ __publicField(Plugin, "version", "3.14.3");
23538
23538
 
23539
23539
  ;// ./src/Plugin/tableview/const.ts
23540
23540
 
@@ -5,12 +5,12 @@
5
5
  * billboard.js, JavaScript chart library
6
6
  * https://naver.github.io/billboard.js/
7
7
  *
8
- * @version 3.14.2
8
+ * @version 3.14.3
9
9
  * @requires billboard.js
10
10
  * @summary billboard.js plugin
11
11
  */(function(kr,$r){typeof exports=="object"&&typeof module=="object"?module.exports=$r():typeof define=="function"&&define.amd?define("bb",[],$r):typeof exports=="object"?exports.bb=$r():(kr.bb=kr.bb||{},kr.bb.plugin=kr.bb.plugin||{},kr.bb.plugin["tableview.pkgd"]=$r())})(this,function(){return function(){"use strict";var Ae={72611:function(i,d,t){t.d(d,{default:function(){return bs}});function r(){}function n(a){return a==null?r:function(){return this.querySelector(a)}}function e(a){typeof a!="function"&&(a=n(a));for(var l=this._groups,h=l.length,E=new Array(h),I=0;I<h;++I)for(var D=l[I],L=D.length,V=E[I]=new Array(L),z,_,tt=0;tt<L;++tt)(z=D[tt])&&(_=a.call(z,z.__data__,tt,D))&&("__data__"in z&&(_.__data__=z.__data__),V[tt]=_);return new Lt(E,this._parents)}function o(a){return a==null?[]:Array.isArray(a)?a:Array.from(a)}function s(){return[]}function u(a){return a==null?s:function(){return this.querySelectorAll(a)}}function f(a){return function(){return o(a.apply(this,arguments))}}function v(a){typeof a=="function"?a=f(a):a=u(a);for(var l=this._groups,h=l.length,E=[],I=[],D=0;D<h;++D)for(var L=l[D],V=L.length,z,_=0;_<V;++_)(z=L[_])&&(E.push(a.call(z,z.__data__,_,L)),I.push(z));return new Lt(E,I)}function c(a){return function(){return this.matches(a)}}function g(a){return function(l){return l.matches(a)}}var y=Array.prototype.find;function p(a){return function(){return y.call(this.children,a)}}function m(){return this.firstElementChild}function S(a){return this.select(a==null?m:p(typeof a=="function"?a:g(a)))}var x=Array.prototype.filter;function O(){return Array.from(this.children)}function P(a){return function(){return x.call(this.children,a)}}function T(a){return this.selectAll(a==null?O:P(typeof a=="function"?a:g(a)))}function R(a){typeof a!="function"&&(a=c(a));for(var l=this._groups,h=l.length,E=new Array(h),I=0;I<h;++I)for(var D=l[I],L=D.length,V=E[I]=[],z,_=0;_<L;++_)(z=D[_])&&a.call(z,z.__data__,_,D)&&V.push(z);return new Lt(E,this._parents)}function N(a){return new Array(a.length)}function A(){return new Lt(this._enter||this._groups.map(N),this._parents)}function C(a,l){this.ownerDocument=a.ownerDocument,this.namespaceURI=a.namespaceURI,this._next=null,this._parent=a,this.__data__=l}C.prototype={constructor:C,appendChild:function(a){return this._parent.insertBefore(a,this._next)},insertBefore:function(a,l){return this._parent.insertBefore(a,l)},querySelector:function(a){return this._parent.querySelector(a)},querySelectorAll:function(a){return this._parent.querySelectorAll(a)}};function M(a){return function(){return a}}function $(a,l,h,E,I,D){for(var L=0,V,z=l.length,_=D.length;L<_;++L)(V=l[L])?(V.__data__=D[L],E[L]=V):h[L]=new C(a,D[L]);for(;L<z;++L)(V=l[L])&&(I[L]=V)}function F(a,l,h,E,I,D,L){var V,z,_=new Map,tt=l.length,Rt=D.length,Mt=new Array(tt),Wt;for(V=0;V<tt;++V)(z=l[V])&&(Mt[V]=Wt=L.call(z,z.__data__,V,l)+"",_.has(Wt)?I[V]=z:_.set(Wt,z));for(V=0;V<Rt;++V)Wt=L.call(a,D[V],V,D)+"",(z=_.get(Wt))?(E[V]=z,z.__data__=D[V],_.delete(Wt)):h[V]=new C(a,D[V]);for(V=0;V<tt;++V)(z=l[V])&&_.get(Mt[V])===z&&(I[V]=z)}function U(a){return a.__data__}function w(a,l){if(!arguments.length)return Array.from(this,U);var h=l?F:$,E=this._parents,I=this._groups;typeof a!="function"&&(a=M(a));for(var D=I.length,L=new Array(D),V=new Array(D),z=new Array(D),_=0;_<D;++_){var tt=E[_],Rt=I[_],Mt=Rt.length,Wt=G(a.call(tt,tt&&tt.__data__,_,E)),fr=Wt.length,xr=V[_]=new Array(fr),Et=L[_]=new Array(fr),Ht=z[_]=new Array(Mt);h(tt,Rt,xr,Et,Ht,Wt,l);for(var Yt=0,Gt=0,tr,rr;Yt<fr;++Yt)if(tr=xr[Yt]){for(Yt>=Gt&&(Gt=Yt+1);!(rr=Et[Gt])&&++Gt<fr;);tr._next=rr||null}}return L=new Lt(L,E),L._enter=V,L._exit=z,L}function G(a){return typeof a=="object"&&"length"in a?a:Array.from(a)}function B(){return new Lt(this._exit||this._groups.map(N),this._parents)}function b(a,l,h){var E=this.enter(),I=this,D=this.exit();return typeof a=="function"?(E=a(E),E&&(E=E.selection())):E=E.append(a+""),l!=null&&(I=l(I),I&&(I=I.selection())),h==null?D.remove():h(D),E&&I?E.merge(I).order():I}function j(a){for(var l=a.selection?a.selection():a,h=this._groups,E=l._groups,I=h.length,D=E.length,L=Math.min(I,D),V=new Array(I),z=0;z<L;++z)for(var _=h[z],tt=E[z],Rt=_.length,Mt=V[z]=new Array(Rt),Wt,fr=0;fr<Rt;++fr)(Wt=_[fr]||tt[fr])&&(Mt[fr]=Wt);for(;z<I;++z)V[z]=h[z];return new Lt(V,this._parents)}function W(){for(var a=this._groups,l=-1,h=a.length;++l<h;)for(var E=a[l],I=E.length-1,D=E[I],L;--I>=0;)(L=E[I])&&(D&&L.compareDocumentPosition(D)^4&&D.parentNode.insertBefore(L,D),D=L);return this}function Q(a){a||(a=X);function l(Rt,Mt){return Rt&&Mt?a(Rt.__data__,Mt.__data__):!Rt-!Mt}for(var h=this._groups,E=h.length,I=new Array(E),D=0;D<E;++D){for(var L=h[D],V=L.length,z=I[D]=new Array(V),_,tt=0;tt<V;++tt)(_=L[tt])&&(z[tt]=_);z.sort(l)}return new Lt(I,this._parents).order()}function X(a,l){return a<l?-1:a>l?1:a>=l?0:NaN}function k(){var a=arguments[0];return arguments[0]=this,a.apply(null,arguments),this}function Z(){return Array.from(this)}function ht(){for(var a=this._groups,l=0,h=a.length;l<h;++l)for(var E=a[l],I=0,D=E.length;I<D;++I){var L=E[I];if(L)return L}return null}function lt(){let a=0;for(const l of this)++a;return a}function pt(){return!this.node()}function Ot(a){for(var l=this._groups,h=0,E=l.length;h<E;++h)for(var I=l[h],D=0,L=I.length,V;D<L;++D)(V=I[D])&&a.call(V,V.__data__,D,I);return this}var Tt="http://www.w3.org/1999/xhtml",Kt={svg:"http://www.w3.org/2000/svg",xhtml:Tt,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Vt(a){var l=a+="",h=l.indexOf(":");return h>=0&&(l=a.slice(0,h))!=="xmlns"&&(a=a.slice(h+1)),Kt.hasOwnProperty(l)?{space:Kt[l],local:a}:a}function Ut(a){return function(){this.removeAttribute(a)}}function vt(a){return function(){this.removeAttributeNS(a.space,a.local)}}function mt(a,l){return function(){this.setAttribute(a,l)}}function Dt(a,l){return function(){this.setAttributeNS(a.space,a.local,l)}}function $t(a,l){return function(){var h=l.apply(this,arguments);h==null?this.removeAttribute(a):this.setAttribute(a,h)}}function Nt(a,l){return function(){var h=l.apply(this,arguments);h==null?this.removeAttributeNS(a.space,a.local):this.setAttributeNS(a.space,a.local,h)}}function jt(a,l){var h=Vt(a);if(arguments.length<2){var E=this.node();return h.local?E.getAttributeNS(h.space,h.local):E.getAttribute(h)}return this.each((l==null?h.local?vt:Ut:typeof l=="function"?h.local?Nt:$t:h.local?Dt:mt)(h,l))}function kt(a){return a.ownerDocument&&a.ownerDocument.defaultView||a.document&&a||a.defaultView}function _t(a){return function(){this.style.removeProperty(a)}}function Xt(a,l,h){return function(){this.style.setProperty(a,l,h)}}function Bt(a,l,h){return function(){var E=l.apply(this,arguments);E==null?this.style.removeProperty(a):this.style.setProperty(a,E,h)}}function Qt(a,l,h){return arguments.length>1?this.each((l==null?_t:typeof l=="function"?Bt:Xt)(a,l,h==null?"":h)):zt(this.node(),a)}function zt(a,l){return a.style.getPropertyValue(l)||kt(a).getComputedStyle(a,null).getPropertyValue(l)}function wt(a){return function(){delete this[a]}}function st(a,l){return function(){this[a]=l}}function dt(a,l){return function(){var h=l.apply(this,arguments);h==null?delete this[a]:this[a]=h}}function q(a,l){return arguments.length>1?this.each((l==null?wt:typeof l=="function"?dt:st)(a,l)):this.node()[a]}function At(a){return a.trim().split(/^|\s+/)}function Pt(a){return a.classList||new It(a)}function It(a){this._node=a,this._names=At(a.getAttribute("class")||"")}It.prototype={add:function(a){var l=this._names.indexOf(a);l<0&&(this._names.push(a),this._node.setAttribute("class",this._names.join(" ")))},remove:function(a){var l=this._names.indexOf(a);l>=0&&(this._names.splice(l,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(a){return this._names.indexOf(a)>=0}};function St(a,l){for(var h=Pt(a),E=-1,I=l.length;++E<I;)h.add(l[E])}function er(a,l){for(var h=Pt(a),E=-1,I=l.length;++E<I;)h.remove(l[E])}function or(a){return function(){St(this,a)}}function Y(a){return function(){er(this,a)}}function et(a,l){return function(){(l.apply(this,arguments)?St:er)(this,a)}}function ut(a,l){var h=At(a+"");if(arguments.length<2){for(var E=Pt(this.node()),I=-1,D=h.length;++I<D;)if(!E.contains(h[I]))return!1;return!0}return this.each((typeof l=="function"?et:l?or:Y)(h,l))}function ot(){this.textContent=""}function ct(a){return function(){this.textContent=a}}function rt(a){return function(){var l=a.apply(this,arguments);this.textContent=l==null?"":l}}function Ft(a){return arguments.length?this.each(a==null?ot:(typeof a=="function"?rt:ct)(a)):this.node().textContent}function qt(){this.innerHTML=""}function nt(a){return function(){this.innerHTML=a}}function gt(a){return function(){var l=a.apply(this,arguments);this.innerHTML=l==null?"":l}}function yt(a){return arguments.length?this.each(a==null?qt:(typeof a=="function"?gt:nt)(a)):this.node().innerHTML}function xt(){this.nextSibling&&this.parentNode.appendChild(this)}function bt(){return this.each(xt)}function Zt(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function nr(){return this.each(Zt)}function ar(a){return function(){var l=this.ownerDocument,h=this.namespaceURI;return h===Tt&&l.documentElement.namespaceURI===Tt?l.createElement(a):l.createElementNS(h,a)}}function ur(a){return function(){return this.ownerDocument.createElementNS(a.space,a.local)}}function cr(a){var l=Vt(a);return(l.local?ur:ar)(l)}function Ur(a){var l=typeof a=="function"?a:cr(a);return this.select(function(){return this.appendChild(l.apply(this,arguments))})}function gn(){return null}function Dn(a,l){var h=typeof a=="function"?a:cr(a),E=l==null?gn:typeof l=="function"?l:n(l);return this.select(function(){return this.insertBefore(h.apply(this,arguments),E.apply(this,arguments)||null)})}function yn(){var a=this.parentNode;a&&a.removeChild(this)}function qr(){return this.each(yn)}function Br(){var a=this.cloneNode(!1),l=this.parentNode;return l?l.insertBefore(a,this.nextSibling):a}function Fn(){var a=this.cloneNode(!0),l=this.parentNode;return l?l.insertBefore(a,this.nextSibling):a}function Kr(a){return this.select(a?Fn:Br)}function br(a){return arguments.length?this.property("__data__",a):this.node().__data__}function pn(a){return function(l){a.call(this,l,this.__data__)}}function _r(a){return a.trim().split(/^|\s+/).map(function(l){var h="",E=l.indexOf(".");return E>=0&&(h=l.slice(E+1),l=l.slice(0,E)),{type:l,name:h}})}function mr(a){return function(){var l=this.__on;if(l){for(var h=0,E=-1,I=l.length,D;h<I;++h)D=l[h],(!a.type||D.type===a.type)&&D.name===a.name?this.removeEventListener(D.type,D.listener,D.options):l[++E]=D;++E?l.length=E:delete this.__on}}}function Dr(a,l,h){return function(){var E=this.__on,I,D=pn(l);if(E){for(var L=0,V=E.length;L<V;++L)if((I=E[L]).type===a.type&&I.name===a.name){this.removeEventListener(I.type,I.listener,I.options),this.addEventListener(I.type,I.listener=D,I.options=h),I.value=l;return}}this.addEventListener(a.type,D,h),I={type:a.type,name:a.name,value:l,listener:D,options:h},E?E.push(I):this.__on=[I]}}function Ln(a,l,h){var E=_r(a+""),I,D=E.length,L;if(arguments.length<2){var V=this.node().__on;if(V){for(var z=0,_=V.length,tt;z<_;++z)for(I=0,tt=V[z];I<D;++I)if((L=E[I]).type===tt.type&&L.name===tt.name)return tt.value}return}for(V=l?Dr:mr,I=0;I<D;++I)this.each(V(E[I],l,h));return this}function mn(a,l,h){var E=kt(a),I=E.CustomEvent;typeof I=="function"?I=new I(l,h):(I=E.document.createEvent("Event"),h?(I.initEvent(l,h.bubbles,h.cancelable),I.detail=h.detail):I.initEvent(l,!1,!1)),a.dispatchEvent(I)}function K(a,l){return function(){return mn(this,a,l)}}function ft(a,l){return function(){return mn(this,a,l.apply(this,arguments))}}function J(a,l){return this.each((typeof l=="function"?ft:K)(a,l))}function*H(){for(var a=this._groups,l=0,h=a.length;l<h;++l)for(var E=a[l],I=0,D=E.length,L;I<D;++I)(L=E[I])&&(yield L)}var at=[null];function Lt(a,l){this._groups=a,this._parents=l}function Ct(){return new Lt([[document.documentElement]],at)}function ir(){return this}Lt.prototype=Ct.prototype={constructor:Lt,select:e,selectAll:v,selectChild:S,selectChildren:T,filter:R,data:w,enter:A,exit:B,join:b,merge:j,selection:ir,order:W,sort:Q,call:k,nodes:Z,node:ht,size:lt,empty:pt,each:Ot,attr:jt,style:Qt,property:q,classed:ut,text:Ft,html:yt,raise:bt,lower:nr,append:Ur,insert:Dn,remove:qr,clone:Kr,datum:br,on:Ln,dispatch:J,[Symbol.iterator]:H};var sr=Ct,dr={value:()=>{}};function Nr(){for(var a=0,l=arguments.length,h={},E;a<l;++a){if(!(E=arguments[a]+"")||E in h||/[\s.]/.test(E))throw new Error("illegal type: "+E);h[E]=[]}return new it(h)}function it(a){this._=a}function lr(a,l){return a.trim().split(/^|\s+/).map(function(h){var E="",I=h.indexOf(".");if(I>=0&&(E=h.slice(I+1),h=h.slice(0,I)),h&&!l.hasOwnProperty(h))throw new Error("unknown type: "+h);return{type:h,name:E}})}it.prototype=Nr.prototype={constructor:it,on:function(a,l){var h=this._,E=lr(a+"",h),I,D=-1,L=E.length;if(arguments.length<2){for(;++D<L;)if((I=(a=E[D]).type)&&(I=jr(h[I],a.name)))return I;return}if(l!=null&&typeof l!="function")throw new Error("invalid callback: "+l);for(;++D<L;)if(I=(a=E[D]).type)h[I]=ln(h[I],a.name,l);else if(l==null)for(I in h)h[I]=ln(h[I],a.name,null);return this},copy:function(){var a={},l=this._;for(var h in l)a[h]=l[h].slice();return new it(a)},call:function(a,l){if((I=arguments.length-2)>0)for(var h=new Array(I),E=0,I,D;E<I;++E)h[E]=arguments[E+2];if(!this._.hasOwnProperty(a))throw new Error("unknown type: "+a);for(D=this._[a],E=0,I=D.length;E<I;++E)D[E].value.apply(l,h)},apply:function(a,l,h){if(!this._.hasOwnProperty(a))throw new Error("unknown type: "+a);for(var E=this._[a],I=0,D=E.length;I<D;++I)E[I].value.apply(l,h)}};function jr(a,l){for(var h=0,E=a.length,I;h<E;++h)if((I=a[h]).name===l)return I.value}function ln(a,l,h){for(var E=0,I=a.length;E<I;++E)if(a[E].name===l){a[E]=dr,a=a.slice(0,E).concat(a.slice(E+1));break}return h!=null&&a.push({name:l,value:h}),a}var $n=Nr,Yr=0,Xr=0,xn=0,Pe=1e3,Un,Sn,Bn=0,on=0,bn=0,En=typeof performance=="object"&&performance.now?performance:Date,Ce=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(a){setTimeout(a,17)};function oe(){return on||(Ce(Sa),on=En.now()+bn)}function Sa(){on=0}function jn(){this._call=this._time=this._next=null}jn.prototype=Ne.prototype={constructor:jn,restart:function(a,l,h){if(typeof a!="function")throw new TypeError("callback is not a function");h=(h==null?oe():+h)+(l==null?0:+l),!this._next&&Sn!==this&&(Sn?Sn._next=this:Un=this,Sn=this),this._call=a,this._time=h,se()},stop:function(){this._call&&(this._call=null,this._time=1/0,se())}};function Ne(a,l,h){var E=new jn;return E.restart(a,l,h),E}function Ea(){oe(),++Yr;for(var a=Un,l;a;)(l=on-a._time)>=0&&a._call.call(void 0,l),a=a._next;--Yr}function Me(){on=(Bn=En.now())+bn,Yr=Xr=0;try{Ea()}finally{Yr=0,Oa(),on=0}}function Ia(){var a=En.now(),l=a-Bn;l>Pe&&(bn-=l,Bn=a)}function Oa(){for(var a,l=Un,h,E=1/0;l;)l._call?(E>l._time&&(E=l._time),a=l,l=l._next):(h=l._next,l._next=null,l=a?a._next=h:Un=h);Sn=a,se(E)}function se(a){if(!Yr){Xr&&(Xr=clearTimeout(Xr));var l=a-on;l>24?(a<1/0&&(Xr=setTimeout(Me,a-En.now()-bn)),xn&&(xn=clearInterval(xn))):(xn||(Bn=En.now(),xn=setInterval(Ia,Pe)),Yr=1,Ce(Me))}}function De(a,l,h){var E=new jn;return l=l==null?0:+l,E.restart(I=>{E.stop(),a(I+l)},l,h),E}var Ta=$n("start","end","cancel","interrupt"),Ra=[],Fe=0,Le=1,ie=2,wn=3,$e=4,ue=5,Gn=6;function Vn(a,l,h,E,I,D){var L=a.__transition;if(!L)a.__transition={};else if(h in L)return;Aa(a,h,{name:l,index:E,group:I,on:Ta,tween:Ra,time:D.time,delay:D.delay,duration:D.duration,ease:D.ease,timer:null,state:Fe})}function fe(a,l){var h=wr(a,l);if(h.state>Fe)throw new Error("too late; already scheduled");return h}function Hr(a,l){var h=wr(a,l);if(h.state>wn)throw new Error("too late; already running");return h}function wr(a,l){var h=a.__transition;if(!h||!(h=h[l]))throw new Error("transition not found");return h}function Aa(a,l,h){var E=a.__transition,I;E[l]=h,h.timer=Ne(D,0,h.time);function D(_){h.state=Le,h.timer.restart(L,h.delay,h.time),h.delay<=_&&L(_-h.delay)}function L(_){var tt,Rt,Mt,Wt;if(h.state!==Le)return z();for(tt in E)if(Wt=E[tt],Wt.name===h.name){if(Wt.state===wn)return De(L);Wt.state===$e?(Wt.state=Gn,Wt.timer.stop(),Wt.on.call("interrupt",a,a.__data__,Wt.index,Wt.group),delete E[tt]):+tt<l&&(Wt.state=Gn,Wt.timer.stop(),Wt.on.call("cancel",a,a.__data__,Wt.index,Wt.group),delete E[tt])}if(De(function(){h.state===wn&&(h.state=$e,h.timer.restart(V,h.delay,h.time),V(_))}),h.state=ie,h.on.call("start",a,a.__data__,h.index,h.group),h.state===ie){for(h.state=wn,I=new Array(Mt=h.tween.length),tt=0,Rt=-1;tt<Mt;++tt)(Wt=h.tween[tt].value.call(a,a.__data__,h.index,h.group))&&(I[++Rt]=Wt);I.length=Rt+1}}function V(_){for(var tt=_<h.duration?h.ease.call(null,_/h.duration):(h.timer.restart(z),h.state=ue,1),Rt=-1,Mt=I.length;++Rt<Mt;)I[Rt].call(a,tt);h.state===ue&&(h.on.call("end",a,a.__data__,h.index,h.group),z())}function z(){h.state=Gn,h.timer.stop(),delete E[l];for(var _ in E)return;delete a.__transition}}function Pa(a,l){var h=a.__transition,E,I,D=!0,L;if(h){l=l==null?null:l+"";for(L in h){if((E=h[L]).name!==l){D=!1;continue}I=E.state>ie&&E.state<ue,E.state=Gn,E.timer.stop(),E.on.call(I?"interrupt":"cancel",a,a.__data__,E.index,E.group),delete h[L]}D&&delete a.__transition}}function Ca(a){return this.each(function(){Pa(this,a)})}function tn(a,l){return a=+a,l=+l,function(h){return a*(1-h)+l*h}}var Ue=180/Math.PI,le={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Be(a,l,h,E,I,D){var L,V,z;return(L=Math.sqrt(a*a+l*l))&&(a/=L,l/=L),(z=a*h+l*E)&&(h-=a*z,E-=l*z),(V=Math.sqrt(h*h+E*E))&&(h/=V,E/=V,z/=V),a*E<l*h&&(a=-a,l=-l,z=-z,L=-L),{translateX:I,translateY:D,rotate:Math.atan2(l,a)*Ue,skewX:Math.atan(z)*Ue,scaleX:L,scaleY:V}}var Hn;function Na(a){const l=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(a+"");return l.isIdentity?le:Be(l.a,l.b,l.c,l.d,l.e,l.f)}function Ma(a){return a==null||(Hn||(Hn=document.createElementNS("http://www.w3.org/2000/svg","g")),Hn.setAttribute("transform",a),!(a=Hn.transform.baseVal.consolidate()))?le:(a=a.matrix,Be(a.a,a.b,a.c,a.d,a.e,a.f))}function be(a,l,h,E){function I(_){return _.length?_.pop()+" ":""}function D(_,tt,Rt,Mt,Wt,fr){if(_!==Rt||tt!==Mt){var xr=Wt.push("translate(",null,l,null,h);fr.push({i:xr-4,x:tn(_,Rt)},{i:xr-2,x:tn(tt,Mt)})}else(Rt||Mt)&&Wt.push("translate("+Rt+l+Mt+h)}function L(_,tt,Rt,Mt){_!==tt?(_-tt>180?tt+=360:tt-_>180&&(_+=360),Mt.push({i:Rt.push(I(Rt)+"rotate(",null,E)-2,x:tn(_,tt)})):tt&&Rt.push(I(Rt)+"rotate("+tt+E)}function V(_,tt,Rt,Mt){_!==tt?Mt.push({i:Rt.push(I(Rt)+"skewX(",null,E)-2,x:tn(_,tt)}):tt&&Rt.push(I(Rt)+"skewX("+tt+E)}function z(_,tt,Rt,Mt,Wt,fr){if(_!==Rt||tt!==Mt){var xr=Wt.push(I(Wt)+"scale(",null,",",null,")");fr.push({i:xr-4,x:tn(_,Rt)},{i:xr-2,x:tn(tt,Mt)})}else(Rt!==1||Mt!==1)&&Wt.push(I(Wt)+"scale("+Rt+","+Mt+")")}return function(_,tt){var Rt=[],Mt=[];return _=a(_),tt=a(tt),D(_.translateX,_.translateY,tt.translateX,tt.translateY,Rt,Mt),L(_.rotate,tt.rotate,Rt,Mt),V(_.skewX,tt.skewX,Rt,Mt),z(_.scaleX,_.scaleY,tt.scaleX,tt.scaleY,Rt,Mt),_=tt=null,function(Wt){for(var fr=-1,xr=Mt.length,Et;++fr<xr;)Rt[(Et=Mt[fr]).i]=Et.x(Wt);return Rt.join("")}}}var Da=be(Na,"px, ","px)","deg)"),Fa=be(Ma,", ",")",")");function La(a,l){var h,E;return function(){var I=Hr(this,a),D=I.tween;if(D!==h){E=h=D;for(var L=0,V=E.length;L<V;++L)if(E[L].name===l){E=E.slice(),E.splice(L,1);break}}I.tween=E}}function $a(a,l,h){var E,I;if(typeof h!="function")throw new Error;return function(){var D=Hr(this,a),L=D.tween;if(L!==E){I=(E=L).slice();for(var V={name:l,value:h},z=0,_=I.length;z<_;++z)if(I[z].name===l){I[z]=V;break}z===_&&I.push(V)}D.tween=I}}function Ua(a,l){var h=this._id;if(a+="",arguments.length<2){for(var E=wr(this.node(),h).tween,I=0,D=E.length,L;I<D;++I)if((L=E[I]).name===a)return L.value;return null}return this.each((l==null?La:$a)(h,a,l))}function ve(a,l,h){var E=a._id;return a.each(function(){var I=Hr(this,E);(I.value||(I.value={}))[l]=h.apply(this,arguments)}),function(I){return wr(I,E).value[l]}}function ce(a,l,h){a.prototype=l.prototype=h,h.constructor=a}function je(a,l){var h=Object.create(a.prototype);for(var E in l)h[E]=l[E];return h}function In(){}var On=.7,Wn=1/On,vn="\\s*([+-]?\\d+)\\s*",Tn="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Wr="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Ba=/^#([0-9a-f]{3,8})$/,ba=new RegExp(`^rgb\\(${vn},${vn},${vn}\\)$`),ja=new RegExp(`^rgb\\(${Wr},${Wr},${Wr}\\)$`),wa=new RegExp(`^rgba\\(${vn},${vn},${vn},${Tn}\\)$`),Ga=new RegExp(`^rgba\\(${Wr},${Wr},${Wr},${Tn}\\)$`),Va=new RegExp(`^hsl\\(${Tn},${Wr},${Wr}\\)$`),Ha=new RegExp(`^hsla\\(${Tn},${Wr},${Wr},${Tn}\\)$`),we={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};ce(In,Rn,{copy(a){return Object.assign(new this.constructor,this,a)},displayable(){return this.rgb().displayable()},hex:Ge,formatHex:Ge,formatHex8:Wa,formatHsl:za,formatRgb:Ve,toString:Ve});function Ge(){return this.rgb().formatHex()}function Wa(){return this.rgb().formatHex8()}function za(){return Ye(this).formatHsl()}function Ve(){return this.rgb().formatRgb()}function Rn(a){var l,h;return a=(a+"").trim().toLowerCase(),(l=Ba.exec(a))?(h=l[1].length,l=parseInt(l[1],16),h===6?He(l):h===3?new Fr(l>>8&15|l>>4&240,l>>4&15|l&240,(l&15)<<4|l&15,1):h===8?zn(l>>24&255,l>>16&255,l>>8&255,(l&255)/255):h===4?zn(l>>12&15|l>>8&240,l>>8&15|l>>4&240,l>>4&15|l&240,((l&15)<<4|l&15)/255):null):(l=ba.exec(a))?new Fr(l[1],l[2],l[3],1):(l=ja.exec(a))?new Fr(l[1]*255/100,l[2]*255/100,l[3]*255/100,1):(l=wa.exec(a))?zn(l[1],l[2],l[3],l[4]):(l=Ga.exec(a))?zn(l[1]*255/100,l[2]*255/100,l[3]*255/100,l[4]):(l=Va.exec(a))?Ke(l[1],l[2]/100,l[3]/100,1):(l=Ha.exec(a))?Ke(l[1],l[2]/100,l[3]/100,l[4]):we.hasOwnProperty(a)?He(we[a]):a==="transparent"?new Fr(NaN,NaN,NaN,0):null}function He(a){return new Fr(a>>16&255,a>>8&255,a&255,1)}function zn(a,l,h,E){return E<=0&&(a=l=h=NaN),new Fr(a,l,h,E)}function Ka(a){return a instanceof In||(a=Rn(a)),a?(a=a.rgb(),new Fr(a.r,a.g,a.b,a.opacity)):new Fr}function Kn(a,l,h,E){return arguments.length===1?Ka(a):new Fr(a,l,h,E==null?1:E)}function Fr(a,l,h,E){this.r=+a,this.g=+l,this.b=+h,this.opacity=+E}ce(Fr,Kn,je(In,{brighter(a){return a=a==null?Wn:Math.pow(Wn,a),new Fr(this.r*a,this.g*a,this.b*a,this.opacity)},darker(a){return a=a==null?On:Math.pow(On,a),new Fr(this.r*a,this.g*a,this.b*a,this.opacity)},rgb(){return this},clamp(){return new Fr(sn(this.r),sn(this.g),sn(this.b),Yn(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:We,formatHex:We,formatHex8:Ya,formatRgb:ze,toString:ze}));function We(){return`#${un(this.r)}${un(this.g)}${un(this.b)}`}function Ya(){return`#${un(this.r)}${un(this.g)}${un(this.b)}${un((isNaN(this.opacity)?1:this.opacity)*255)}`}function ze(){const a=Yn(this.opacity);return`${a===1?"rgb(":"rgba("}${sn(this.r)}, ${sn(this.g)}, ${sn(this.b)}${a===1?")":`, ${a})`}`}function Yn(a){return isNaN(a)?1:Math.max(0,Math.min(1,a))}function sn(a){return Math.max(0,Math.min(255,Math.round(a)||0))}function un(a){return a=sn(a),(a<16?"0":"")+a.toString(16)}function Ke(a,l,h,E){return E<=0?a=l=h=NaN:h<=0||h>=1?a=l=NaN:l<=0&&(a=NaN),new Gr(a,l,h,E)}function Ye(a){if(a instanceof Gr)return new Gr(a.h,a.s,a.l,a.opacity);if(a instanceof In||(a=Rn(a)),!a)return new Gr;if(a instanceof Gr)return a;a=a.rgb();var l=a.r/255,h=a.g/255,E=a.b/255,I=Math.min(l,h,E),D=Math.max(l,h,E),L=NaN,V=D-I,z=(D+I)/2;return V?(l===D?L=(h-E)/V+(h<E)*6:h===D?L=(E-l)/V+2:L=(l-h)/V+4,V/=z<.5?D+I:2-D-I,L*=60):V=z>0&&z<1?0:L,new Gr(L,V,z,a.opacity)}function Xa(a,l,h,E){return arguments.length===1?Ye(a):new Gr(a,l,h,E==null?1:E)}function Gr(a,l,h,E){this.h=+a,this.s=+l,this.l=+h,this.opacity=+E}ce(Gr,Xa,je(In,{brighter(a){return a=a==null?Wn:Math.pow(Wn,a),new Gr(this.h,this.s,this.l*a,this.opacity)},darker(a){return a=a==null?On:Math.pow(On,a),new Gr(this.h,this.s,this.l*a,this.opacity)},rgb(){var a=this.h%360+(this.h<0)*360,l=isNaN(a)||isNaN(this.s)?0:this.s,h=this.l,E=h+(h<.5?h:1-h)*l,I=2*h-E;return new Fr(de(a>=240?a-240:a+120,I,E),de(a,I,E),de(a<120?a+240:a-120,I,E),this.opacity)},clamp(){return new Gr(Xe(this.h),Xn(this.s),Xn(this.l),Yn(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 a=Yn(this.opacity);return`${a===1?"hsl(":"hsla("}${Xe(this.h)}, ${Xn(this.s)*100}%, ${Xn(this.l)*100}%${a===1?")":`, ${a})`}`}}));function Xe(a){return a=(a||0)%360,a<0?a+360:a}function Xn(a){return Math.max(0,Math.min(1,a||0))}function de(a,l,h){return(a<60?l+(h-l)*a/60:a<180?h:a<240?l+(h-l)*(240-a)/60:l)*255}function Je(a,l,h,E,I){var D=a*a,L=D*a;return((1-3*a+3*D-L)*l+(4-6*D+3*L)*h+(1+3*a+3*D-3*L)*E+L*I)/6}function Ja(a){var l=a.length-1;return function(h){var E=h<=0?h=0:h>=1?(h=1,l-1):Math.floor(h*l),I=a[E],D=a[E+1],L=E>0?a[E-1]:2*I-D,V=E<l-1?a[E+2]:2*D-I;return Je((h-E/l)*l,L,I,D,V)}}function Qa(a){var l=a.length;return function(h){var E=Math.floor(((h%=1)<0?++h:h)*l),I=a[(E+l-1)%l],D=a[E%l],L=a[(E+1)%l],V=a[(E+2)%l];return Je((h-E/l)*l,I,D,L,V)}}var Qe=a=>()=>a;function Ze(a,l){return function(h){return a+h*l}}function Za(a,l,h){return a=Math.pow(a,h),l=Math.pow(l,h)-a,h=1/h,function(E){return Math.pow(a+E*l,h)}}function Gs(a,l){var h=l-a;return h?Ze(a,h>180||h<-180?h-360*Math.round(h/360):h):constant(isNaN(a)?l:a)}function ka(a){return(a=+a)==1?ke:function(l,h){return h-l?Za(l,h,a):Qe(isNaN(l)?h:l)}}function ke(a,l){var h=l-a;return h?Ze(a,h):Qe(isNaN(a)?l:a)}var qe=function a(l){var h=ka(l);function E(I,D){var L=h((I=Kn(I)).r,(D=Kn(D)).r),V=h(I.g,D.g),z=h(I.b,D.b),_=ke(I.opacity,D.opacity);return function(tt){return I.r=L(tt),I.g=V(tt),I.b=z(tt),I.opacity=_(tt),I+""}}return E.gamma=a,E}(1);function _e(a){return function(l){var h=l.length,E=new Array(h),I=new Array(h),D=new Array(h),L,V;for(L=0;L<h;++L)V=Kn(l[L]),E[L]=V.r||0,I[L]=V.g||0,D[L]=V.b||0;return E=a(E),I=a(I),D=a(D),V.opacity=1,function(z){return V.r=E(z),V.g=I(z),V.b=D(z),V+""}}}var Vs=_e(Ja),Hs=_e(Qa),he=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,ge=new RegExp(he.source,"g");function qa(a){return function(){return a}}function _a(a){return function(l){return a(l)+""}}function to(a,l){var h=he.lastIndex=ge.lastIndex=0,E,I,D,L=-1,V=[],z=[];for(a=a+"",l=l+"";(E=he.exec(a))&&(I=ge.exec(l));)(D=I.index)>h&&(D=l.slice(h,D),V[L]?V[L]+=D:V[++L]=D),(E=E[0])===(I=I[0])?V[L]?V[L]+=I:V[++L]=I:(V[++L]=null,z.push({i:L,x:tn(E,I)})),h=ge.lastIndex;return h<l.length&&(D=l.slice(h),V[L]?V[L]+=D:V[++L]=D),V.length<2?z[0]?_a(z[0].x):qa(l):(l=z.length,function(_){for(var tt=0,Rt;tt<l;++tt)V[(Rt=z[tt]).i]=Rt.x(_);return V.join("")})}function ta(a,l){var h;return(typeof l=="number"?tn:l instanceof Rn?qe:(h=Rn(l))?(l=h,qe):to)(a,l)}function ro(a){return function(){this.removeAttribute(a)}}function no(a){return function(){this.removeAttributeNS(a.space,a.local)}}function eo(a,l,h){var E,I=h+"",D;return function(){var L=this.getAttribute(a);return L===I?null:L===E?D:D=l(E=L,h)}}function ao(a,l,h){var E,I=h+"",D;return function(){var L=this.getAttributeNS(a.space,a.local);return L===I?null:L===E?D:D=l(E=L,h)}}function oo(a,l,h){var E,I,D;return function(){var L,V=h(this),z;return V==null?void this.removeAttribute(a):(L=this.getAttribute(a),z=V+"",L===z?null:L===E&&z===I?D:(I=z,D=l(E=L,V)))}}function so(a,l,h){var E,I,D;return function(){var L,V=h(this),z;return V==null?void this.removeAttributeNS(a.space,a.local):(L=this.getAttributeNS(a.space,a.local),z=V+"",L===z?null:L===E&&z===I?D:(I=z,D=l(E=L,V)))}}function io(a,l){var h=Vt(a),E=h==="transform"?Fa:ta;return this.attrTween(a,typeof l=="function"?(h.local?so:oo)(h,E,ve(this,"attr."+a,l)):l==null?(h.local?no:ro)(h):(h.local?ao:eo)(h,E,l))}function uo(a,l){return function(h){this.setAttribute(a,l.call(this,h))}}function fo(a,l){return function(h){this.setAttributeNS(a.space,a.local,l.call(this,h))}}function lo(a,l){var h,E;function I(){var D=l.apply(this,arguments);return D!==E&&(h=(E=D)&&fo(a,D)),h}return I._value=l,I}function vo(a,l){var h,E;function I(){var D=l.apply(this,arguments);return D!==E&&(h=(E=D)&&uo(a,D)),h}return I._value=l,I}function co(a,l){var h="attr."+a;if(arguments.length<2)return(h=this.tween(h))&&h._value;if(l==null)return this.tween(h,null);if(typeof l!="function")throw new Error;var E=Vt(a);return this.tween(h,(E.local?lo:vo)(E,l))}function ho(a,l){return function(){fe(this,a).delay=+l.apply(this,arguments)}}function go(a,l){return l=+l,function(){fe(this,a).delay=l}}function yo(a){var l=this._id;return arguments.length?this.each((typeof a=="function"?ho:go)(l,a)):wr(this.node(),l).delay}function po(a,l){return function(){Hr(this,a).duration=+l.apply(this,arguments)}}function mo(a,l){return l=+l,function(){Hr(this,a).duration=l}}function xo(a){var l=this._id;return arguments.length?this.each((typeof a=="function"?po:mo)(l,a)):wr(this.node(),l).duration}function So(a,l){if(typeof l!="function")throw new Error;return function(){Hr(this,a).ease=l}}function Eo(a){var l=this._id;return arguments.length?this.each(So(l,a)):wr(this.node(),l).ease}function Io(a,l){return function(){var h=l.apply(this,arguments);if(typeof h!="function")throw new Error;Hr(this,a).ease=h}}function Oo(a){if(typeof a!="function")throw new Error;return this.each(Io(this._id,a))}function To(a){typeof a!="function"&&(a=c(a));for(var l=this._groups,h=l.length,E=new Array(h),I=0;I<h;++I)for(var D=l[I],L=D.length,V=E[I]=[],z,_=0;_<L;++_)(z=D[_])&&a.call(z,z.__data__,_,D)&&V.push(z);return new Jr(E,this._parents,this._name,this._id)}function Ro(a){if(a._id!==this._id)throw new Error;for(var l=this._groups,h=a._groups,E=l.length,I=h.length,D=Math.min(E,I),L=new Array(E),V=0;V<D;++V)for(var z=l[V],_=h[V],tt=z.length,Rt=L[V]=new Array(tt),Mt,Wt=0;Wt<tt;++Wt)(Mt=z[Wt]||_[Wt])&&(Rt[Wt]=Mt);for(;V<E;++V)L[V]=l[V];return new Jr(L,this._parents,this._name,this._id)}function Ao(a){return(a+"").trim().split(/^|\s+/).every(function(l){var h=l.indexOf(".");return h>=0&&(l=l.slice(0,h)),!l||l==="start"})}function Po(a,l,h){var E,I,D=Ao(l)?fe:Hr;return function(){var L=D(this,a),V=L.on;V!==E&&(I=(E=V).copy()).on(l,h),L.on=I}}function Co(a,l){var h=this._id;return arguments.length<2?wr(this.node(),h).on.on(a):this.each(Po(h,a,l))}function No(a){return function(){var l=this.parentNode;for(var h in this.__transition)if(+h!==a)return;l&&l.removeChild(this)}}function Mo(){return this.on("end.remove",No(this._id))}function Do(a){var l=this._name,h=this._id;typeof a!="function"&&(a=n(a));for(var E=this._groups,I=E.length,D=new Array(I),L=0;L<I;++L)for(var V=E[L],z=V.length,_=D[L]=new Array(z),tt,Rt,Mt=0;Mt<z;++Mt)(tt=V[Mt])&&(Rt=a.call(tt,tt.__data__,Mt,V))&&("__data__"in tt&&(Rt.__data__=tt.__data__),_[Mt]=Rt,Vn(_[Mt],l,h,Mt,_,wr(tt,h)));return new Jr(D,this._parents,l,h)}function Fo(a){var l=this._name,h=this._id;typeof a!="function"&&(a=u(a));for(var E=this._groups,I=E.length,D=[],L=[],V=0;V<I;++V)for(var z=E[V],_=z.length,tt,Rt=0;Rt<_;++Rt)if(tt=z[Rt]){for(var Mt=a.call(tt,tt.__data__,Rt,z),Wt,fr=wr(tt,h),xr=0,Et=Mt.length;xr<Et;++xr)(Wt=Mt[xr])&&Vn(Wt,l,h,xr,Mt,fr);D.push(Mt),L.push(tt)}return new Jr(D,L,l,h)}var Lo=sr.prototype.constructor;function $o(){return new Lo(this._groups,this._parents)}function Uo(a,l){var h,E,I;return function(){var D=zt(this,a),L=(this.style.removeProperty(a),zt(this,a));return D===L?null:D===h&&L===E?I:I=l(h=D,E=L)}}function ra(a){return function(){this.style.removeProperty(a)}}function Bo(a,l,h){var E,I=h+"",D;return function(){var L=zt(this,a);return L===I?null:L===E?D:D=l(E=L,h)}}function bo(a,l,h){var E,I,D;return function(){var L=zt(this,a),V=h(this),z=V+"";return V==null&&(z=V=(this.style.removeProperty(a),zt(this,a))),L===z?null:L===E&&z===I?D:(I=z,D=l(E=L,V))}}function jo(a,l){var h,E,I,D="style."+l,L="end."+D,V;return function(){var z=Hr(this,a),_=z.on,tt=z.value[D]==null?V||(V=ra(l)):void 0;(_!==h||I!==tt)&&(E=(h=_).copy()).on(L,I=tt),z.on=E}}function wo(a,l,h){var E=(a+="")=="transform"?Da:ta;return l==null?this.styleTween(a,Uo(a,E)).on("end.style."+a,ra(a)):typeof l=="function"?this.styleTween(a,bo(a,E,ve(this,"style."+a,l))).each(jo(this._id,a)):this.styleTween(a,Bo(a,E,l),h).on("end.style."+a,null)}function Go(a,l,h){return function(E){this.style.setProperty(a,l.call(this,E),h)}}function Vo(a,l,h){var E,I;function D(){var L=l.apply(this,arguments);return L!==I&&(E=(I=L)&&Go(a,L,h)),E}return D._value=l,D}function Ho(a,l,h){var E="style."+(a+="");if(arguments.length<2)return(E=this.tween(E))&&E._value;if(l==null)return this.tween(E,null);if(typeof l!="function")throw new Error;return this.tween(E,Vo(a,l,h==null?"":h))}function Wo(a){return function(){this.textContent=a}}function zo(a){return function(){var l=a(this);this.textContent=l==null?"":l}}function Ko(a){return this.tween("text",typeof a=="function"?zo(ve(this,"text",a)):Wo(a==null?"":a+""))}function Yo(a){return function(l){this.textContent=a.call(this,l)}}function Xo(a){var l,h;function E(){var I=a.apply(this,arguments);return I!==h&&(l=(h=I)&&Yo(I)),l}return E._value=a,E}function Jo(a){var l="text";if(arguments.length<1)return(l=this.tween(l))&&l._value;if(a==null)return this.tween(l,null);if(typeof a!="function")throw new Error;return this.tween(l,Xo(a))}function Qo(){for(var a=this._name,l=this._id,h=na(),E=this._groups,I=E.length,D=0;D<I;++D)for(var L=E[D],V=L.length,z,_=0;_<V;++_)if(z=L[_]){var tt=wr(z,l);Vn(z,a,h,_,L,{time:tt.time+tt.delay+tt.duration,delay:0,duration:tt.duration,ease:tt.ease})}return new Jr(E,this._parents,a,h)}function Zo(){var a,l,h=this,E=h._id,I=h.size();return new Promise(function(D,L){var V={value:L},z={value:function(){--I===0&&D()}};h.each(function(){var _=Hr(this,E),tt=_.on;tt!==a&&(l=(a=tt).copy(),l._.cancel.push(V),l._.interrupt.push(V),l._.end.push(z)),_.on=l}),I===0&&D()})}var ko=0;function Jr(a,l,h,E){this._groups=a,this._parents=l,this._name=h,this._id=E}function qo(a){return sr().transition(a)}function na(){return++ko}var Qr=sr.prototype;Jr.prototype=qo.prototype={constructor:Jr,select:Do,selectAll:Fo,selectChild:Qr.selectChild,selectChildren:Qr.selectChildren,filter:To,merge:Ro,selection:$o,transition:Qo,call:Qr.call,nodes:Qr.nodes,node:Qr.node,size:Qr.size,empty:Qr.empty,each:Qr.each,on:Co,attr:io,attrTween:co,style:wo,styleTween:Ho,text:Ko,textTween:Jo,remove:Mo,tween:Ua,delay:yo,duration:xo,ease:Eo,easeVarying:Oo,end:Zo,[Symbol.iterator]:Qr[Symbol.iterator]};function Ws(a){return a*a*a}function zs(a){return--a*a*a+1}function _o(a){return((a*=2)<=1?a*a*a:(a-=2)*a*a+2)/2}var ts={time:null,delay:0,duration:250,ease:_o};function rs(a,l){for(var h;!(h=a.__transition)||!(h=h[l]);)if(!(a=a.parentNode))throw new Error(`transition ${l} not found`);return h}function ns(a){var l,h;a instanceof Jr?(l=a._id,a=a._name):(l=na(),(h=ts).time=oe(),a=a==null?null:a+"");for(var E=this._groups,I=E.length,D=0;D<I;++D)for(var L=E[D],V=L.length,z,_=0;_<V;++_)(z=L[_])&&Vn(z,a,l,_,L,h||rs(z,l));return new Jr(E,this._parents,a,l)}sr.prototype.interrupt=Ca,sr.prototype.transition=ns;var ea={name:"drag"},ye={name:"space"},cn={name:"handle"},dn={name:"center"};const{abs:aa,max:Pr,min:Cr}=Math;function oa(a){return[+a[0],+a[1]]}function pe(a){return[oa(a[0]),oa(a[1])]}var Jn={name:"x",handles:["w","e"].map(An),input:function(a,l){return a==null?null:[[+a[0],l[0][1]],[+a[1],l[1][1]]]},output:function(a){return a&&[a[0][0],a[1][0]]}},Qn={name:"y",handles:["n","s"].map(An),input:function(a,l){return a==null?null:[[l[0][0],+a[0]],[l[1][0],+a[1]]]},output:function(a){return a&&[a[0][1],a[1][1]]}},es={name:"xy",handles:["n","w","e","s","nw","ne","sw","se"].map(An),input:function(a){return a==null?null:pe(a)},output:function(a){return a}},Zr={overlay:"crosshair",selection:"move",n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},sa={e:"w",w:"e",nw:"ne",ne:"nw",se:"sw",sw:"se"},ia={n:"s",s:"n",nw:"sw",ne:"se",se:"ne",sw:"nw"},as={overlay:1,selection:1,n:null,e:1,s:null,w:-1,nw:-1,ne:1,se:1,sw:-1},os={overlay:1,selection:1,n:-1,e:null,s:1,w:null,nw:-1,ne:-1,se:1,sw:1};function An(a){return{type:a}}function ss(a){return!a.ctrlKey&&!a.button}function is(){var a=this.ownerSVGElement||this;return a.hasAttribute("viewBox")?(a=a.viewBox.baseVal,[[a.x,a.y],[a.x+a.width,a.y+a.height]]):[[0,0],[a.width.baseVal.value,a.height.baseVal.value]]}function us(){return navigator.maxTouchPoints||"ontouchstart"in this}function me(a){for(;!a.__brush;)if(!(a=a.parentNode))return;return a.__brush}function fs(a){return a[0][0]===a[1][0]||a[0][1]===a[1][1]}function Ks(a){var l=a.__brush;return l?l.dim.output(l.selection):null}function Ys(){return xe(Jn)}function Xs(){return xe(Qn)}function Js(){return xe(es)}function xe(a){var l=is,h=ss,E=us,I=!0,D=dispatch("start","brush","end"),L=6,V;function z(Et){var Ht=Et.property("__brush",xr).selectAll(".overlay").data([An("overlay")]);Ht.enter().append("rect").attr("class","overlay").attr("pointer-events","all").attr("cursor",Zr.overlay).merge(Ht).each(function(){var Gt=me(this).extent;select(this).attr("x",Gt[0][0]).attr("y",Gt[0][1]).attr("width",Gt[1][0]-Gt[0][0]).attr("height",Gt[1][1]-Gt[0][1])}),Et.selectAll(".selection").data([An("selection")]).enter().append("rect").attr("class","selection").attr("cursor",Zr.selection).attr("fill","#777").attr("fill-opacity",.3).attr("stroke","#fff").attr("shape-rendering","crispEdges");var Yt=Et.selectAll(".handle").data(a.handles,function(Gt){return Gt.type});Yt.exit().remove(),Yt.enter().append("rect").attr("class",function(Gt){return"handle handle--"+Gt.type}).attr("cursor",function(Gt){return Zr[Gt.type]}),Et.each(_).attr("fill","none").attr("pointer-events","all").on("mousedown.brush",Mt).filter(E).on("touchstart.brush",Mt).on("touchmove.brush",Wt).on("touchend.brush touchcancel.brush",fr).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}z.move=function(Et,Ht,Yt){Et.tween?Et.on("start.brush",function(Gt){tt(this,arguments).beforestart().start(Gt)}).on("interrupt.brush end.brush",function(Gt){tt(this,arguments).end(Gt)}).tween("brush",function(){var Gt=this,tr=Gt.__brush,rr=tt(Gt,arguments),Mr=tr.selection,zr=a.input(typeof Ht=="function"?Ht.apply(this,arguments):Ht,tr.extent),hr=interpolate(Mr,zr);function Vr(vr){tr.selection=vr===1&&zr===null?null:hr(vr),_.call(Gt),rr.brush()}return Mr!==null&&zr!==null?Vr:Vr(1)}):Et.each(function(){var Gt=this,tr=arguments,rr=Gt.__brush,Mr=a.input(typeof Ht=="function"?Ht.apply(Gt,tr):Ht,rr.extent),zr=tt(Gt,tr).beforestart();interrupt(Gt),rr.selection=Mr===null?null:Mr,_.call(Gt),zr.start(Yt).brush(Yt).end(Yt)})},z.clear=function(Et,Ht){z.move(Et,null,Ht)};function _(){var Et=select(this),Ht=me(this).selection;Ht?(Et.selectAll(".selection").style("display",null).attr("x",Ht[0][0]).attr("y",Ht[0][1]).attr("width",Ht[1][0]-Ht[0][0]).attr("height",Ht[1][1]-Ht[0][1]),Et.selectAll(".handle").style("display",null).attr("x",function(Yt){return Yt.type[Yt.type.length-1]==="e"?Ht[1][0]-L/2:Ht[0][0]-L/2}).attr("y",function(Yt){return Yt.type[0]==="s"?Ht[1][1]-L/2:Ht[0][1]-L/2}).attr("width",function(Yt){return Yt.type==="n"||Yt.type==="s"?Ht[1][0]-Ht[0][0]+L:L}).attr("height",function(Yt){return Yt.type==="e"||Yt.type==="w"?Ht[1][1]-Ht[0][1]+L:L})):Et.selectAll(".selection,.handle").style("display","none").attr("x",null).attr("y",null).attr("width",null).attr("height",null)}function tt(Et,Ht,Yt){var Gt=Et.__brush.emitter;return Gt&&(!Yt||!Gt.clean)?Gt:new Rt(Et,Ht,Yt)}function Rt(Et,Ht,Yt){this.that=Et,this.args=Ht,this.state=Et.__brush,this.active=0,this.clean=Yt}Rt.prototype={beforestart:function(){return++this.active===1&&(this.state.emitter=this,this.starting=!0),this},start:function(Et,Ht){return this.starting?(this.starting=!1,this.emit("start",Et,Ht)):this.emit("brush",Et),this},brush:function(Et,Ht){return this.emit("brush",Et,Ht),this},end:function(Et,Ht){return--this.active===0&&(delete this.state.emitter,this.emit("end",Et,Ht)),this},emit:function(Et,Ht,Yt){var Gt=select(this.that).datum();D.call(Et,this.that,new BrushEvent(Et,{sourceEvent:Ht,target:z,selection:a.output(this.state.selection),mode:Yt,dispatch:D}),Gt)}};function Mt(Et){if(V&&!Et.touches||!h.apply(this,arguments))return;var Ht=this,Yt=Et.target.__data__.type,Gt=(I&&Et.metaKey?Yt="overlay":Yt)==="selection"?ea:I&&Et.altKey?dn:cn,tr=a===Qn?null:as[Yt],rr=a===Jn?null:os[Yt],Mr=me(Ht),zr=Mr.extent,hr=Mr.selection,Vr=zr[0][0],vr,Sr,rn=zr[0][1],Er,Ir,nn=zr[1][0],Or,Tr,en=zr[1][1],Rr,Ar,gr=0,yr=0,Re,re=tr&&rr&&I&&Et.shiftKey,ne,ee,Lr=Array.from(Et.touches||[Et],Jt=>{const pr=Jt.identifier;return Jt=pointer(Jt,Ht),Jt.point0=Jt.slice(),Jt.identifier=pr,Jt});interrupt(Ht);var Cn=tt(Ht,arguments,!0).beforestart();if(Yt==="overlay"){hr&&(Re=!0);const Jt=[Lr[0],Lr[1]||Lr[0]];Mr.selection=hr=[[vr=a===Qn?Vr:Cr(Jt[0][0],Jt[1][0]),Er=a===Jn?rn:Cr(Jt[0][1],Jt[1][1])],[Or=a===Qn?nn:Pr(Jt[0][0],Jt[1][0]),Rr=a===Jn?en:Pr(Jt[0][1],Jt[1][1])]],Lr.length>1&&fn(Et)}else vr=hr[0][0],Er=hr[0][1],Or=hr[1][0],Rr=hr[1][1];Sr=vr,Ir=Er,Tr=Or,Ar=Rr;var ya=select(Ht).attr("pointer-events","none"),Nn=ya.selectAll(".overlay").attr("cursor",Zr[Yt]);if(Et.touches)Cn.moved=ma,Cn.ended=xa;else{var pa=select(Et.view).on("mousemove.brush",ma,!0).on("mouseup.brush",xa,!0);I&&pa.on("keydown.brush",js,!0).on("keyup.brush",ws,!0),dragDisable(Et.view)}_.call(Ht),Cn.start(Et,Gt.name);function ma(Jt){for(const pr of Jt.changedTouches||[Jt])for(const Mn of Lr)Mn.identifier===pr.identifier&&(Mn.cur=pointer(pr,Ht));if(re&&!ne&&!ee&&Lr.length===1){const pr=Lr[0];aa(pr.cur[0]-pr[0])>aa(pr.cur[1]-pr[1])?ee=!0:ne=!0}for(const pr of Lr)pr.cur&&(pr[0]=pr.cur[0],pr[1]=pr.cur[1]);Re=!0,noevent(Jt),fn(Jt)}function fn(Jt){const pr=Lr[0],Mn=pr.point0;var an;switch(gr=pr[0]-Mn[0],yr=pr[1]-Mn[1],Gt){case ye:case ea:{tr&&(gr=Pr(Vr-vr,Cr(nn-Or,gr)),Sr=vr+gr,Tr=Or+gr),rr&&(yr=Pr(rn-Er,Cr(en-Rr,yr)),Ir=Er+yr,Ar=Rr+yr);break}case cn:{Lr[1]?(tr&&(Sr=Pr(Vr,Cr(nn,Lr[0][0])),Tr=Pr(Vr,Cr(nn,Lr[1][0])),tr=1),rr&&(Ir=Pr(rn,Cr(en,Lr[0][1])),Ar=Pr(rn,Cr(en,Lr[1][1])),rr=1)):(tr<0?(gr=Pr(Vr-vr,Cr(nn-vr,gr)),Sr=vr+gr,Tr=Or):tr>0&&(gr=Pr(Vr-Or,Cr(nn-Or,gr)),Sr=vr,Tr=Or+gr),rr<0?(yr=Pr(rn-Er,Cr(en-Er,yr)),Ir=Er+yr,Ar=Rr):rr>0&&(yr=Pr(rn-Rr,Cr(en-Rr,yr)),Ir=Er,Ar=Rr+yr));break}case dn:{tr&&(Sr=Pr(Vr,Cr(nn,vr-gr*tr)),Tr=Pr(Vr,Cr(nn,Or+gr*tr))),rr&&(Ir=Pr(rn,Cr(en,Er-yr*rr)),Ar=Pr(rn,Cr(en,Rr+yr*rr)));break}}Tr<Sr&&(tr*=-1,an=vr,vr=Or,Or=an,an=Sr,Sr=Tr,Tr=an,Yt in sa&&Nn.attr("cursor",Zr[Yt=sa[Yt]])),Ar<Ir&&(rr*=-1,an=Er,Er=Rr,Rr=an,an=Ir,Ir=Ar,Ar=an,Yt in ia&&Nn.attr("cursor",Zr[Yt=ia[Yt]])),Mr.selection&&(hr=Mr.selection),ne&&(Sr=hr[0][0],Tr=hr[1][0]),ee&&(Ir=hr[0][1],Ar=hr[1][1]),(hr[0][0]!==Sr||hr[0][1]!==Ir||hr[1][0]!==Tr||hr[1][1]!==Ar)&&(Mr.selection=[[Sr,Ir],[Tr,Ar]],_.call(Ht),Cn.brush(Jt,Gt.name))}function xa(Jt){if(nopropagation(Jt),Jt.touches){if(Jt.touches.length)return;V&&clearTimeout(V),V=setTimeout(function(){V=null},500)}else dragEnable(Jt.view,Re),pa.on("keydown.brush keyup.brush mousemove.brush mouseup.brush",null);ya.attr("pointer-events","all"),Nn.attr("cursor",Zr.overlay),Mr.selection&&(hr=Mr.selection),fs(hr)&&(Mr.selection=null,_.call(Ht)),Cn.end(Jt,Gt.name)}function js(Jt){switch(Jt.keyCode){case 16:{re=tr&&rr;break}case 18:{Gt===cn&&(tr&&(Or=Tr-gr*tr,vr=Sr+gr*tr),rr&&(Rr=Ar-yr*rr,Er=Ir+yr*rr),Gt=dn,fn(Jt));break}case 32:{(Gt===cn||Gt===dn)&&(tr<0?Or=Tr-gr:tr>0&&(vr=Sr-gr),rr<0?Rr=Ar-yr:rr>0&&(Er=Ir-yr),Gt=ye,Nn.attr("cursor",Zr.selection),fn(Jt));break}default:return}noevent(Jt)}function ws(Jt){switch(Jt.keyCode){case 16:{re&&(ne=ee=re=!1,fn(Jt));break}case 18:{Gt===dn&&(tr<0?Or=Tr:tr>0&&(vr=Sr),rr<0?Rr=Ar:rr>0&&(Er=Ir),Gt=cn,fn(Jt));break}case 32:{Gt===ye&&(Jt.altKey?(tr&&(Or=Tr-gr*tr,vr=Sr+gr*tr),rr&&(Rr=Ar-yr*rr,Er=Ir+yr*rr),Gt=dn):(tr<0?Or=Tr:tr>0&&(vr=Sr),rr<0?Rr=Ar:rr>0&&(Er=Ir),Gt=cn),Nn.attr("cursor",Zr[Yt]),fn(Jt));break}default:return}noevent(Jt)}}function Wt(Et){tt(this,arguments).moved(Et)}function fr(Et){tt(this,arguments).ended(Et)}function xr(){var Et=this.__brush||{selection:null};return Et.extent=pe(l.apply(this,arguments)),Et.dim=a,Et}return z.extent=function(Et){return arguments.length?(l=typeof Et=="function"?Et:constant(pe(Et)),z):l},z.filter=function(Et){return arguments.length?(h=typeof Et=="function"?Et:constant(!!Et),z):h},z.touchable=function(Et){return arguments.length?(E=typeof Et=="function"?Et:constant(!!Et),z):E},z.handleSize=function(Et){return arguments.length?(L=+Et,z):L},z.keyModifiers=function(Et){return arguments.length?(I=!!Et,z):I},z.on=function(){var Et=D.on.apply(D,arguments);return Et===D?z:Et},z}function ls(){return typeof globalThis=="object"&&globalThis!==null&&globalThis.Object===Object&&globalThis||typeof global=="object"&&global!==null&&global.Object===Object&&global||typeof self=="object"&&self!==null&&self.Object===Object&&self||Function("return this")()}function vs(a){const l=typeof(a==null?void 0:a.requestAnimationFrame)=="function"&&typeof(a==null?void 0:a.cancelAnimationFrame)=="function",h=typeof(a==null?void 0:a.requestIdleCallback)=="function"&&typeof(a==null?void 0:a.cancelIdleCallback)=="function",E=D=>setTimeout(D,1),I=D=>clearTimeout(D);return[l?a.requestAnimationFrame:E,l?a.cancelAnimationFrame:I,h?a.requestIdleCallback:E,h?a.cancelIdleCallback:I]}const Zn=ls(),cs=Zn==null?void 0:Zn.document,[Qs,Zs,ks,qs]=vs(Zn);var ds=Object.defineProperty,ua=Object.getOwnPropertySymbols,hs=Object.prototype.hasOwnProperty,gs=Object.prototype.propertyIsEnumerable,fa=(a,l,h)=>l in a?ds(a,l,{enumerable:!0,configurable:!0,writable:!0,value:h}):a[l]=h,la=(a,l)=>{for(var h in l||(l={}))hs.call(l,h)&&fa(a,h,l[h]);if(ua)for(var h of ua(l))gs.call(l,h)&&fa(a,h,l[h]);return a};const _s=a=>a||a===0,ys=a=>typeof a=="function",kn=a=>typeof a=="string",qn=a=>typeof a=="number",ps=a=>typeof a=="undefined",va=a=>typeof a!="undefined",ti=a=>typeof a=="boolean",ri=a=>Math.ceil(a/10)*10,ni=a=>Math.ceil(a)+.5,ei=a=>a[1]-a[0],Se=a=>typeof a=="object",ms=a=>ps(a)||a===null||kn(a)&&a.length===0||Se(a)&&!(a instanceof Date)&&Object.keys(a).length===0||qn(a)&&isNaN(a),xs=a=>!ms(a),Ee=a=>Array.isArray(a),_n=a=>a&&!(a!=null&&a.nodeType)&&Se(a)&&!Ee(a);function ai(a,l,h){return va(a[l])?a[l]:h}function oi(a,l){let h=!1;return Object.keys(a).forEach(E=>a[E]===l&&(h=!0)),h}function si(a,l,...h){const E=ys(a);return E&&a.call(l,...h),E}function ii(a,l){let h=0;const E=function(...I){!--h&&l.apply(this,...I)};"duration"in a?a.each(()=>++h).on("end",E):(++h,a.call(E))}function ui(a){return kn(a)?a.replace(/<(script|img)?/ig,"&lt;").replace(/(script)?>/ig,"&gt;"):a}function fi(a,l,h=[-1,1],E=!1){if(!(!a||!kn(l)))if(l.indexOf(`
12
12
  `)===-1)a.text(l);else{const I=[a.text(),l].map(D=>D.replace(/[\s\n]/g,""));if(I[0]!==I[1]){const D=l.split(`
13
- `),L=E?D.length-1:1;a.html(""),D.forEach((V,z)=>{a.append("tspan").attr("x",0).attr("dy",`${z===0?h[0]*L:h[1]}em`).text(V)})}}}function Ss(a){const{x:l,y:h,width:E,height:I}=a.getBBox();return[{x:l,y:h+I},{x:l,y:h},{x:l+E,y:h},{x:l+E,y:h+I}]}function li(a){const{width:l,height:h}=a.getBoundingClientRect(),E=Ss(a),I=E[0].x,D=Math.min(E[0].y,E[1].y);return{x:I,y:D,width:l,height:h}}function vi(a,l){var h;const E=a&&((h=a.touches||a.sourceEvent&&a.sourceEvent.touches)==null?void 0:h[0]);let I=[0,0];try{I=d3Pointer(E||a,l)}catch(D){}return I.map(D=>isNaN(D)?0:D)}function Es(a){const{event:l,$el:h}=a,E=h.subchart.main||h.main;let I;return l&&l.type==="brush"?I=l.selection:E&&(I=E.select(".bb-brush").node())&&(I=d3BrushSelection(I)),I}function ci(a){return!("rect"in a)||"rect"in a&&a.hasAttribute("width")&&a.rect.width!==+a.getAttribute("width")?a.rect=a.getBoundingClientRect():a.rect}function di(a=!0,l=0,h=1e4){const E=window.crypto||window.msCrypto,I=E?l+E.getRandomValues(new Uint32Array(1))[0]%(h-l+1):Math.floor(Math.random()*(h-l)+l);return a?String(I):I}function ca(a,l,h,E,I){if(h>E)return-1;const D=Math.floor((h+E)/2);let{x:L,w:V=0}=a[D];return I&&(L=a[D].y,V=a[D].h),l>=L&&l<=L+V?D:l<L?ca(a,l,h,D-1,I):ca(a,l,D+1,E,I)}function hi(a){const l=Es(a);return l?l[0]===l[1]:!0}function gi(...a){const l=h=>{if(_n(h)&&h.constructor){const E=new h.constructor;for(const I in h)E[I]=l(h[I]);return E}return h};return a.map(h=>l(h)).reduce((h,E)=>la(la({},h),E))}function Is(a={},l){Ee(l)&&l.forEach(h=>Is(a,h));for(const h in l)/^\d+$/.test(h)||h in a||(a[h]=l[h]);return a}const yi=a=>a.charAt(0).toUpperCase()+a.slice(1);function pi(a,l="-"){return a.split(l).map((h,E)=>E?h.charAt(0).toUpperCase()+h.slice(1).toLowerCase():h.toLowerCase()).join("")}const Os=a=>[].slice.call(a);function mi(a,l,h){const{rootSelector:E="",sheet:I}=a,L=`${E} ${(V=>V.replace(/\s?(bb-)/g,".$1").replace(/\.+/g,"."))(l)} {${h.join(";")}}`;return I[I.insertRule?"insertRule":"addRule"](L,I.cssRules.length)}function xi(a){let l=[];return a.forEach(h=>{var E;try{h.cssRules&&h.cssRules.length&&(l=l.concat(Os(h.cssRules)))}catch(I){(E=window.console)==null||E.warn(`Error while reading rules from ${h.href}: ${I.toString()}`)}}),l}function Si(a){var l,h,E,I,D,L;return{x:((h=(l=window.pageXOffset)!=null?l:window.scrollX)!=null?h:0)+((E=a.scrollLeft)!=null?E:0),y:((D=(I=window.pageYOffset)!=null?I:window.scrollY)!=null?D:0)+((L=a.scrollTop)!=null?L:0)}}function Ei(a,l=0,h=0,E=!0){const I=new DOMPoint(l,h),D=a.getScreenCTM(),L=I.matrixTransform(E?D==null?void 0:D.inverse():D);if(E===!1){const V=a.getBoundingClientRect();L.x-=V.x,L.y-=V.y}return L}function Ii(a){const l=a?a.transform:null,h=l&&l.baseVal;return h&&h.numberOfItems?h.getItem(0).matrix:{a:0,b:0,c:0,d:0,e:0,f:0}}function Oi(a){const l=a[0]instanceof Date,h=(l?a.map(Number):a).filter((E,I,D)=>D.indexOf(E)===I);return l?h.map(E=>new Date(E)):h}function Ti(a){return a&&a.length?a.reduce((l,h)=>l.concat(h)):[]}function Ie(a,...l){if(!l.length||l.length===1&&!l[0])return a;const h=l.shift();return _n(a)&&_n(h)&&Object.keys(h).forEach(E=>{const I=h[E];_n(I)?(!a[E]&&(a[E]={}),a[E]=Ie(a[E],I)):a[E]=Ee(I)?I.concat():I}),Ie(a,...l)}function Ts(a,l=!0){let h;return a[0]instanceof Date?h=l?(E,I)=>E-I:(E,I)=>I-E:l&&!a.every(isNaN)?h=(E,I)=>E-I:l||(h=(E,I)=>E>I&&-1||E<I&&1||E===I&&0),a.concat().sort(h)}function Ri(a,l){let h=l.filter(E=>xs(E));return h.length?qn(h[0])?h=Math[a](...h):h[0]instanceof Date&&(h=Ts(h,a==="min")[0]):h=void 0,h}const Ai=(a,l,h=1)=>{const E=[],I=Math.max(0,Math.ceil((l-a)/h))|0;for(let D=a;D<I;D++)E.push(a+D*h);return E},Pi={mouse:(()=>{const a=()=>({bubbles:!1,cancelable:!1,screenX:0,screenY:0,clientX:0,clientY:0});try{return new MouseEvent("t"),(l,h,E=a())=>{l.dispatchEvent(new MouseEvent(h,E))}}catch(l){return(h,E,I=a())=>{const D=cs.createEvent("MouseEvent");D.initMouseEvent(E,I.bubbles,I.cancelable,Zn,0,I.screenX,I.screenY,I.clientX,I.clientY,!1,!1,!1,!1,0,null),h.dispatchEvent(D)}}})(),touch:(a,l,h)=>{const E=new Touch(Ie({identifier:Date.now(),target:a,radiusX:2.5,radiusY:2.5,rotationAngle:10,force:.5},h));a.dispatchEvent(new TouchEvent(l,{cancelable:!0,bubbles:!0,shiftKey:!0,touches:[E],targetTouches:[],changedTouches:[E]}))}};function te(a,l){let h=a;for(const E in l)h=h.replace(new RegExp(`{=${E}}`,"g"),l[E]);return h}function Ci(a){var l;let h;if(a instanceof Date)h=a;else if(kn(a)){const{config:E,format:I}=this;h=(l=I.dataTime(E.data_xFormat)(a))!=null?l:new Date(a)}else qn(a)&&!isNaN(a)&&(h=new Date(+a));return(!h||isNaN(+h))&&console&&console.error&&console.error(`Failed to parse x '${a}' to Date object`),h}function Ni(a){const l=a.attr("viewBox");return l?/(\d+(\.\d+)?){3}/.test(l):!1}function Mi(a,l,h=!1){const E=!!a.node;let I=!1;for(const[D,L]of Object.entries(l))if(I=E?a.style(D)===L:a.style[D]===L,h===!1&&I)break;return I}function Di(){var a,l;return((a=document)==null?void 0:a.hidden)===!1||((l=document)==null?void 0:l.visibilityState)==="visible"}function Fi(a,l){const{DocumentTouch:h,matchMedia:E,navigator:I}=window,D=E==null?void 0:E("(pointer:coarse)").matches;let L=!1;if(l)if(I&&"maxTouchPoints"in I)L=I.maxTouchPoints>0;else if("ontouchmove"in window||h&&document instanceof h)L=!0;else if(D)L=!0;else{const z=I.userAgent;L=/\b(BlackBerry|webOS|iPhone|IEMobile)\b/i.test(z)||/\b(Android|Windows Phone|iPad|iPod)\b/i.test(z)}return a&&!D&&(E==null?void 0:E("(pointer:fine)").matches)&&"mouse"||L&&"touch"||"mouse"}function Rs(a,l){l()===!1?requestAnimationFrame(()=>Rs(a,l)):a()}function As(a){const l=this.config;let h,E,I;const D=()=>{const L=E.shift();if(L&&h&&Se(h)&&L in h)return h=h[L],D();if(!L)return h};Object.keys(l).forEach(L=>{h=a,E=L.split("_"),I=D(),va(I)&&(l[L]=I)}),this.api&&(this.state.orgConfig=a)}var Ps=Object.defineProperty,Cs=(a,l,h)=>l in a?Ps(a,l,{enumerable:!0,configurable:!0,writable:!0,value:h}):a[l]=h,Oe=(a,l,h)=>Cs(a,typeof l!="symbol"?l+"":l,h);class da{constructor(l={}){Oe(this,"$$"),Oe(this,"options"),this.options=l}$beforeInit(){}$init(){}$afterInit(){}$redraw(){}$willDestroy(){Object.keys(this).forEach(l=>{this[l]=null,delete this[l]})}}Oe(da,"version","3.14.2");const hn={id:"__tableview-style__",class:"bb-tableview",rule:`.bb-tableview {
13
+ `),L=E?D.length-1:1;a.html(""),D.forEach((V,z)=>{a.append("tspan").attr("x",0).attr("dy",`${z===0?h[0]*L:h[1]}em`).text(V)})}}}function Ss(a){const{x:l,y:h,width:E,height:I}=a.getBBox();return[{x:l,y:h+I},{x:l,y:h},{x:l+E,y:h},{x:l+E,y:h+I}]}function li(a){const{width:l,height:h}=a.getBoundingClientRect(),E=Ss(a),I=E[0].x,D=Math.min(E[0].y,E[1].y);return{x:I,y:D,width:l,height:h}}function vi(a,l){var h;const E=a&&((h=a.touches||a.sourceEvent&&a.sourceEvent.touches)==null?void 0:h[0]);let I=[0,0];try{I=d3Pointer(E||a,l)}catch(D){}return I.map(D=>isNaN(D)?0:D)}function Es(a){const{event:l,$el:h}=a,E=h.subchart.main||h.main;let I;return l&&l.type==="brush"?I=l.selection:E&&(I=E.select(".bb-brush").node())&&(I=d3BrushSelection(I)),I}function ci(a){return!("rect"in a)||"rect"in a&&a.hasAttribute("width")&&a.rect.width!==+a.getAttribute("width")?a.rect=a.getBoundingClientRect():a.rect}function di(a=!0,l=0,h=1e4){const E=window.crypto||window.msCrypto,I=E?l+E.getRandomValues(new Uint32Array(1))[0]%(h-l+1):Math.floor(Math.random()*(h-l)+l);return a?String(I):I}function ca(a,l,h,E,I){if(h>E)return-1;const D=Math.floor((h+E)/2);let{x:L,w:V=0}=a[D];return I&&(L=a[D].y,V=a[D].h),l>=L&&l<=L+V?D:l<L?ca(a,l,h,D-1,I):ca(a,l,D+1,E,I)}function hi(a){const l=Es(a);return l?l[0]===l[1]:!0}function gi(...a){const l=h=>{if(_n(h)&&h.constructor){const E=new h.constructor;for(const I in h)E[I]=l(h[I]);return E}return h};return a.map(h=>l(h)).reduce((h,E)=>la(la({},h),E))}function Is(a={},l){Ee(l)&&l.forEach(h=>Is(a,h));for(const h in l)/^\d+$/.test(h)||h in a||(a[h]=l[h]);return a}const yi=a=>a.charAt(0).toUpperCase()+a.slice(1);function pi(a,l="-"){return a.split(l).map((h,E)=>E?h.charAt(0).toUpperCase()+h.slice(1).toLowerCase():h.toLowerCase()).join("")}const Os=a=>[].slice.call(a);function mi(a,l,h){const{rootSelector:E="",sheet:I}=a,L=`${E} ${(V=>V.replace(/\s?(bb-)/g,".$1").replace(/\.+/g,"."))(l)} {${h.join(";")}}`;return I[I.insertRule?"insertRule":"addRule"](L,I.cssRules.length)}function xi(a){let l=[];return a.forEach(h=>{var E;try{h.cssRules&&h.cssRules.length&&(l=l.concat(Os(h.cssRules)))}catch(I){(E=window.console)==null||E.warn(`Error while reading rules from ${h.href}: ${I.toString()}`)}}),l}function Si(a){var l,h,E,I,D,L;return{x:((h=(l=window.pageXOffset)!=null?l:window.scrollX)!=null?h:0)+((E=a.scrollLeft)!=null?E:0),y:((D=(I=window.pageYOffset)!=null?I:window.scrollY)!=null?D:0)+((L=a.scrollTop)!=null?L:0)}}function Ei(a,l=0,h=0,E=!0){const I=new DOMPoint(l,h),D=a.getScreenCTM(),L=I.matrixTransform(E?D==null?void 0:D.inverse():D);if(E===!1){const V=a.getBoundingClientRect();L.x-=V.x,L.y-=V.y}return L}function Ii(a){const l=a?a.transform:null,h=l&&l.baseVal;return h&&h.numberOfItems?h.getItem(0).matrix:{a:0,b:0,c:0,d:0,e:0,f:0}}function Oi(a){const l=a[0]instanceof Date,h=(l?a.map(Number):a).filter((E,I,D)=>D.indexOf(E)===I);return l?h.map(E=>new Date(E)):h}function Ti(a){return a&&a.length?a.reduce((l,h)=>l.concat(h)):[]}function Ie(a,...l){if(!l.length||l.length===1&&!l[0])return a;const h=l.shift();return _n(a)&&_n(h)&&Object.keys(h).forEach(E=>{const I=h[E];_n(I)?(!a[E]&&(a[E]={}),a[E]=Ie(a[E],I)):a[E]=Ee(I)?I.concat():I}),Ie(a,...l)}function Ts(a,l=!0){let h;return a[0]instanceof Date?h=l?(E,I)=>E-I:(E,I)=>I-E:l&&!a.every(isNaN)?h=(E,I)=>E-I:l||(h=(E,I)=>E>I&&-1||E<I&&1||E===I&&0),a.concat().sort(h)}function Ri(a,l){let h=l.filter(E=>xs(E));return h.length?qn(h[0])?h=Math[a](...h):h[0]instanceof Date&&(h=Ts(h,a==="min")[0]):h=void 0,h}const Ai=(a,l,h=1)=>{const E=[],I=Math.max(0,Math.ceil((l-a)/h))|0;for(let D=a;D<I;D++)E.push(a+D*h);return E},Pi={mouse:(()=>{const a=()=>({bubbles:!1,cancelable:!1,screenX:0,screenY:0,clientX:0,clientY:0});try{return new MouseEvent("t"),(l,h,E=a())=>{l.dispatchEvent(new MouseEvent(h,E))}}catch(l){return(h,E,I=a())=>{const D=cs.createEvent("MouseEvent");D.initMouseEvent(E,I.bubbles,I.cancelable,Zn,0,I.screenX,I.screenY,I.clientX,I.clientY,!1,!1,!1,!1,0,null),h.dispatchEvent(D)}}})(),touch:(a,l,h)=>{const E=new Touch(Ie({identifier:Date.now(),target:a,radiusX:2.5,radiusY:2.5,rotationAngle:10,force:.5},h));a.dispatchEvent(new TouchEvent(l,{cancelable:!0,bubbles:!0,shiftKey:!0,touches:[E],targetTouches:[],changedTouches:[E]}))}};function te(a,l){let h=a;for(const E in l)h=h.replace(new RegExp(`{=${E}}`,"g"),l[E]);return h}function Ci(a){var l;let h;if(a instanceof Date)h=a;else if(kn(a)){const{config:E,format:I}=this;h=(l=I.dataTime(E.data_xFormat)(a))!=null?l:new Date(a)}else qn(a)&&!isNaN(a)&&(h=new Date(+a));return(!h||isNaN(+h))&&console&&console.error&&console.error(`Failed to parse x '${a}' to Date object`),h}function Ni(a){const l=a.attr("viewBox");return l?/(\d+(\.\d+)?){3}/.test(l):!1}function Mi(a,l,h=!1){const E=!!a.node;let I=!1;for(const[D,L]of Object.entries(l))if(I=E?a.style(D)===L:a.style[D]===L,h===!1&&I)break;return I}function Di(){var a,l;return((a=document)==null?void 0:a.hidden)===!1||((l=document)==null?void 0:l.visibilityState)==="visible"}function Fi(a,l){const{DocumentTouch:h,matchMedia:E,navigator:I}=window,D=E==null?void 0:E("(pointer:coarse)").matches;let L=!1;if(l)if(I&&"maxTouchPoints"in I)L=I.maxTouchPoints>0;else if("ontouchmove"in window||h&&document instanceof h)L=!0;else if(D)L=!0;else{const z=I.userAgent;L=/\b(BlackBerry|webOS|iPhone|IEMobile)\b/i.test(z)||/\b(Android|Windows Phone|iPad|iPod)\b/i.test(z)}return a&&!D&&(E==null?void 0:E("(pointer:fine)").matches)&&"mouse"||L&&"touch"||"mouse"}function Rs(a,l){l()===!1?requestAnimationFrame(()=>Rs(a,l)):a()}function As(a){const l=this.config;let h,E,I;const D=()=>{const L=E.shift();if(L&&h&&Se(h)&&L in h)return h=h[L],D();if(!L)return h};Object.keys(l).forEach(L=>{h=a,E=L.split("_"),I=D(),va(I)&&(l[L]=I)}),this.api&&(this.state.orgConfig=a)}var Ps=Object.defineProperty,Cs=(a,l,h)=>l in a?Ps(a,l,{enumerable:!0,configurable:!0,writable:!0,value:h}):a[l]=h,Oe=(a,l,h)=>Cs(a,typeof l!="symbol"?l+"":l,h);class da{constructor(l={}){Oe(this,"$$"),Oe(this,"options"),this.options=l}$beforeInit(){}$init(){}$afterInit(){}$redraw(){}$willDestroy(){Object.keys(this).forEach(l=>{this[l]=null,delete this[l]})}}Oe(da,"version","3.14.3");const hn={id:"__tableview-style__",class:"bb-tableview",rule:`.bb-tableview {
14
14
  border-collapse:collapse;
15
15
  border-spacing:0;
16
16
  background:#fff;
@@ -5,7 +5,7 @@
5
5
  * billboard.js, JavaScript chart library
6
6
  * https://naver.github.io/billboard.js/
7
7
  *
8
- * @version 3.14.2
8
+ * @version 3.14.3
9
9
  * @requires billboard.js
10
10
  * @summary billboard.js plugin
11
11
  */
@@ -26974,7 +26974,7 @@ class Plugin {
26974
26974
  });
26975
26975
  }
26976
26976
  }
26977
- __publicField(Plugin, "version", "3.14.2");
26977
+ __publicField(Plugin, "version", "3.14.3");
26978
26978
 
26979
26979
  ;// ./src/Plugin/textoverlap/Options.ts
26980
26980
  class Options {