1?n:1)},e}(ip),ap=function(){var t=up,n=!1,e=1,r=1,i=[0],o=zd,u=zd,a=zd,c=zd,f=zd;function s(t){return t.x0=t.y0=0,t.x1=e,t.y1=r,t.eachBefore(l),i=[0],n&&t.eachBefore(Vd),t}function l(n){var e=i[n.depth],r=n.x0+e,s=n.y0+e,l=n.x1-e,h=n.y1-e;l=e-1){var s=a[n];return s.x0=i,s.y0=o,s.x1=u,void(s.y1=c)}var l=f[n],h=r/2+l,d=n+1,p=e-1;for(;d>>1;f[v]c-o){var _=(i*y+u*g)/r;t(n,d,g,i,o,_,c),t(d,e,y,_,o,u,c)}else{var b=(o*y+c*g)/r;t(n,d,g,i,o,u,b),t(d,e,y,i,b,u,c)}}(0,c,t.value,n,e,r,i)},fp=function(t,n,e,r,i){(1&t.depth?rp:qd)(t,n,e,r,i)},sp=function t(n){function e(t,e,r,i,o){if((u=t._squarify)&&u.ratio===n)for(var u,a,c,f,s,l=-1,h=u.length,d=t.value;++l1?n:1)},e}(ip),lp=function(t){var n=t.length;return function(e){return t[Math.max(0,Math.min(n-1,Math.floor(e*n)))]}},hp=function(t,n){var e=de(+t,+n);return function(t){var n=e(t);return n-360*Math.floor(n/360)}},dp=function(t,n){return t=+t,n=+n,function(e){return Math.round(t*(1-e)+n*e)}},pp=Math.SQRT2;function vp(t){return((t=Math.exp(t))+1/t)/2}var gp=function(t,n){var e,r,i=t[0],o=t[1],u=t[2],a=n[0],c=n[1],f=n[2],s=a-i,l=c-o,h=s*s+l*l;if(h<1e-12)r=Math.log(f/u)/pp,e=function(t){return[i+t*s,o+t*l,u*Math.exp(pp*t*r)]};else{var d=Math.sqrt(h),p=(f*f-u*u+4*h)/(2*u*2*d),v=(f*f-u*u-4*h)/(2*f*2*d),g=Math.log(Math.sqrt(p*p+1)-p),y=Math.log(Math.sqrt(v*v+1)-v);r=(y-g)/pp,e=function(t){var n,e=t*r,a=vp(g),c=u/(2*d)*(a*(n=pp*e+g,((n=Math.exp(2*n))-1)/(n+1))-function(t){return((t=Math.exp(t))-1/t)/2}(g));return[i+c*s,o+c*l,u*a/vp(pp*e+g)]}}return e.duration=1e3*r,e};function yp(t){return function(n,e){var r=t((n=oe(n)).h,(e=oe(e)).h),i=ve(n.s,e.s),o=ve(n.l,e.l),u=ve(n.opacity,e.opacity);return function(t){return n.h=r(t),n.s=i(t),n.l=o(t),n.opacity=u(t),n+""}}}var _p=yp(de),bp=yp(ve);function mp(t,n){var e=ve((t=bo(t)).l,(n=bo(n)).l),r=ve(t.a,n.a),i=ve(t.b,n.b),o=ve(t.opacity,n.opacity);return function(n){return t.l=e(n),t.a=r(n),t.b=i(n),t.opacity=o(n),t+""}}function xp(t){return function(n,e){var r=t((n=To(n)).h,(e=To(e)).h),i=ve(n.c,e.c),o=ve(n.l,e.l),u=ve(n.opacity,e.opacity);return function(t){return n.h=r(t),n.c=i(t),n.l=o(t),n.opacity=u(t),n+""}}}var wp=xp(de),Mp=xp(ve);function Ap(t){return function n(e){function r(n,r){var i=t((n=zo(n)).h,(r=zo(r)).h),o=ve(n.s,r.s),u=ve(n.l,r.l),a=ve(n.opacity,r.opacity);return function(t){return n.h=i(t),n.s=o(t),n.l=u(Math.pow(t,e)),n.opacity=a(t),n+""}}return e=+e,r.gamma=n,r}(1)}var kp=Ap(de),Sp=Ap(ve);function Tp(t,n){for(var e=0,r=n.length-1,i=n[0],o=new Array(r<0?0:r);e1&&(n=t[o[u-2]],e=t[o[u-1]],r=t[a],(e[0]-n[0])*(r[1]-n[1])-(e[1]-n[1])*(r[0]-n[0])<=0);)--u;o[u++]=a}return o.slice(0,u)}var Rp=function(t){if((e=t.length)<3)return null;var n,e,r=new Array(e),i=new Array(e);for(n=0;n=0;--n)f.push(t[r[o[n]][2]]);for(n=+a;na!=f>a&&u<(c-e)*(a-r)/(f-r)+e&&(s=!s),c=e,f=r;return s},zp=function(t){for(var n,e,r=-1,i=t.length,o=t[i-1],u=o[0],a=o[1],c=0;++r1);return t+e*o*Math.sqrt(-2*Math.log(i)/i)}}return e.source=t,e}(Ip),Up=function t(n){function e(){var t=Fp.source(n).apply(this,arguments);return function(){return Math.exp(t())}}return e.source=t,e}(Ip),Dp=function t(n){function e(t){return function(){for(var e=0,r=0;rr&&(n=e,e=r,r=n),function(t){return Math.max(e,Math.min(r,t))}}function iv(t,n,e){var r=t[0],i=t[1],o=n[0],u=n[1];return i2?ov:iv,i=o=null,l}function l(n){return isNaN(n=+n)?e:(i||(i=r(u.map(t),a,c)))(t(f(n)))}return l.invert=function(e){return f(n((o||(o=r(a,u.map(t),ke)))(e)))},l.domain=function(t){return arguments.length?(u=$p.call(t,Jp),f===nv||(f=rv(u)),s()):u.slice()},l.range=function(t){return arguments.length?(a=Wp.call(t),s()):a.slice()},l.rangeRound=function(t){return a=Wp.call(t),c=dp,s()},l.clamp=function(t){return arguments.length?(f=t?rv(u):nv,l):f!==nv},l.interpolate=function(t){return arguments.length?(c=t,s()):c},l.unknown=function(t){return arguments.length?(e=t,l):e},function(e,r){return t=e,n=r,s()}}function cv(t,n){return av()(t,n)}var fv=function(t,n,e,r){var i,o=O(t,n,e);switch((r=Za(null==r?",f":r)).type){case"s":var u=Math.max(Math.abs(t),Math.abs(n));return null!=r.precision||isNaN(i=sc(o,u))||(r.precision=i),nc(r,u);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(i=lc(o,Math.max(Math.abs(t),Math.abs(n))))||(r.precision=i-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(i=fc(o))||(r.precision=i-2*("%"===r.type))}return tc(r)};function sv(t){var n=t.domain;return t.ticks=function(t){var e=n();return N(e[0],e[e.length-1],null==t?10:t)},t.tickFormat=function(t,e){var r=n();return fv(r[0],r[r.length-1],null==t?10:t,e)},t.nice=function(e){null==e&&(e=10);var r,i=n(),o=0,u=i.length-1,a=i[o],c=i[u];return c0?r=j(a=Math.floor(a/r)*r,c=Math.ceil(c/r)*r,e):r<0&&(r=j(a=Math.ceil(a*r)/r,c=Math.floor(c*r)/r,e)),r>0?(i[o]=Math.floor(a/r)*r,i[u]=Math.ceil(c/r)*r,n(i)):r<0&&(i[o]=Math.ceil(a*r)/r,i[u]=Math.floor(c*r)/r,n(i)),t},t}function lv(){var t=cv(nv,nv);return t.copy=function(){return uv(t,lv())},qp.apply(t,arguments),sv(t)}function hv(t){var n;function e(t){return isNaN(t=+t)?n:t}return e.invert=e,e.domain=e.range=function(n){return arguments.length?(t=$p.call(n,Jp),e):t.slice()},e.unknown=function(t){return arguments.length?(n=t,e):n},e.copy=function(){return hv(t).unknown(n)},t=arguments.length?$p.call(t,Jp):[0,1],sv(e)}var dv=function(t,n){var e,r=0,i=(t=t.slice()).length-1,o=t[r],u=t[i];return u0){for(;hc)break;v.push(l)}}else for(;h=1;--s)if(!((l=f*s)c)break;v.push(l)}}else v=N(h,d,Math.min(d-h,p)).map(e);return r?v.reverse():v},r.tickFormat=function(t,i){if(null==i&&(i=10===o?".0e":","),"function"!=typeof i&&(i=tc(i)),t===1/0)return i;null==t&&(t=10);var u=Math.max(1,o*t/r.ticks().length);return function(t){var r=t/e(Math.round(n(t)));return r*o0?r[i-1]:n[0],i=r?[i[r-1],e]:[i[u-1],i[u]]},u.unknown=function(n){return arguments.length?(t=n,u):u},u.thresholds=function(){return i.slice()},u.copy=function(){return Rv().domain([n,e]).range(o).unknown(t)},qp.apply(sv(u),arguments)}function Pv(){var t,n=[.5],e=[0,1],r=1;function i(i){return i<=i?e[h(n,i,0,r)]:t}return i.domain=function(t){return arguments.length?(n=Wp.call(t),r=Math.min(n.length,e.length-1),i):n.slice()},i.range=function(t){return arguments.length?(e=Wp.call(t),r=Math.min(n.length,e.length-1),i):e.slice()},i.invertExtent=function(t){var r=e.indexOf(t);return[n[r-1],n[r]]},i.unknown=function(n){return arguments.length?(t=n,i):t},i.copy=function(){return Pv().domain(n).range(e).unknown(t)},qp.apply(i,arguments)}var zv=new Date,Iv=new Date;function Lv(t,n,e,r){function i(n){return t(n=0===arguments.length?new Date:new Date(+n)),n}return i.floor=function(n){return t(n=new Date(+n)),n},i.ceil=function(e){return t(e=new Date(e-1)),n(e,1),t(e),e},i.round=function(t){var n=i(t),e=i.ceil(t);return t-n0))return a;do{a.push(u=new Date(+e)),n(e,o),t(e)}while(u=n)for(;t(n),!e(n);)n.setTime(n-1)}),(function(t,r){if(t>=t)if(r<0)for(;++r<=0;)for(;n(t,-1),!e(t););else for(;--r>=0;)for(;n(t,1),!e(t););}))},e&&(i.count=function(n,r){return zv.setTime(+n),Iv.setTime(+r),t(zv),t(Iv),Math.floor(e(zv,Iv))},i.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?i.filter(r?function(n){return r(n)%t==0}:function(n){return i.count(0,n)%t==0}):i:null}),i}var Fv=Lv((function(t){t.setMonth(0,1),t.setHours(0,0,0,0)}),(function(t,n){t.setFullYear(t.getFullYear()+n)}),(function(t,n){return n.getFullYear()-t.getFullYear()}),(function(t){return t.getFullYear()}));Fv.every=function(t){return isFinite(t=Math.floor(t))&&t>0?Lv((function(n){n.setFullYear(Math.floor(n.getFullYear()/t)*t),n.setMonth(0,1),n.setHours(0,0,0,0)}),(function(n,e){n.setFullYear(n.getFullYear()+e*t)})):null};var Uv=Fv,Dv=Fv.range,Bv=Lv((function(t){t.setDate(1),t.setHours(0,0,0,0)}),(function(t,n){t.setMonth(t.getMonth()+n)}),(function(t,n){return n.getMonth()-t.getMonth()+12*(n.getFullYear()-t.getFullYear())}),(function(t){return t.getMonth()})),Vv=Bv,qv=Bv.range;function Yv(t){return Lv((function(n){n.setDate(n.getDate()-(n.getDay()+7-t)%7),n.setHours(0,0,0,0)}),(function(t,n){t.setDate(t.getDate()+7*n)}),(function(t,n){return(n-t-6e4*(n.getTimezoneOffset()-t.getTimezoneOffset()))/6048e5}))}var Hv=Yv(0),$v=Yv(1),Wv=Yv(2),Xv=Yv(3),Gv=Yv(4),Zv=Yv(5),Kv=Yv(6),Qv=Hv.range,Jv=$v.range,tg=Wv.range,ng=Xv.range,eg=Gv.range,rg=Zv.range,ig=Kv.range,og=Lv((function(t){t.setHours(0,0,0,0)}),(function(t,n){t.setDate(t.getDate()+n)}),(function(t,n){return(n-t-6e4*(n.getTimezoneOffset()-t.getTimezoneOffset()))/864e5}),(function(t){return t.getDate()-1})),ug=og,ag=og.range,cg=Lv((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds()-6e4*t.getMinutes())}),(function(t,n){t.setTime(+t+36e5*n)}),(function(t,n){return(n-t)/36e5}),(function(t){return t.getHours()})),fg=cg,sg=cg.range,lg=Lv((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds())}),(function(t,n){t.setTime(+t+6e4*n)}),(function(t,n){return(n-t)/6e4}),(function(t){return t.getMinutes()})),hg=lg,dg=lg.range,pg=Lv((function(t){t.setTime(t-t.getMilliseconds())}),(function(t,n){t.setTime(+t+1e3*n)}),(function(t,n){return(n-t)/1e3}),(function(t){return t.getUTCSeconds()})),vg=pg,gg=pg.range,yg=Lv((function(){}),(function(t,n){t.setTime(+t+n)}),(function(t,n){return n-t}));yg.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?Lv((function(n){n.setTime(Math.floor(n/t)*t)}),(function(n,e){n.setTime(+n+e*t)}),(function(n,e){return(e-n)/t})):yg:null};var _g=yg,bg=yg.range;function mg(t){return Lv((function(n){n.setUTCDate(n.getUTCDate()-(n.getUTCDay()+7-t)%7),n.setUTCHours(0,0,0,0)}),(function(t,n){t.setUTCDate(t.getUTCDate()+7*n)}),(function(t,n){return(n-t)/6048e5}))}var xg=mg(0),wg=mg(1),Mg=mg(2),Ag=mg(3),kg=mg(4),Sg=mg(5),Tg=mg(6),Cg=xg.range,Eg=wg.range,Ng=Mg.range,jg=Ag.range,Og=kg.range,Rg=Sg.range,Pg=Tg.range,zg=Lv((function(t){t.setUTCHours(0,0,0,0)}),(function(t,n){t.setUTCDate(t.getUTCDate()+n)}),(function(t,n){return(n-t)/864e5}),(function(t){return t.getUTCDate()-1})),Ig=zg,Lg=zg.range,Fg=Lv((function(t){t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),(function(t,n){t.setUTCFullYear(t.getUTCFullYear()+n)}),(function(t,n){return n.getUTCFullYear()-t.getUTCFullYear()}),(function(t){return t.getUTCFullYear()}));Fg.every=function(t){return isFinite(t=Math.floor(t))&&t>0?Lv((function(n){n.setUTCFullYear(Math.floor(n.getUTCFullYear()/t)*t),n.setUTCMonth(0,1),n.setUTCHours(0,0,0,0)}),(function(n,e){n.setUTCFullYear(n.getUTCFullYear()+e*t)})):null};var Ug=Fg,Dg=Fg.range;function Bg(t){if(0<=t.y&&t.y<100){var n=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return n.setFullYear(t.y),n}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function Vg(t){if(0<=t.y&&t.y<100){var n=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return n.setUTCFullYear(t.y),n}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function qg(t,n,e){return{y:t,m:n,d:e,H:0,M:0,S:0,L:0}}function Yg(t){var n=t.dateTime,e=t.date,r=t.time,i=t.periods,o=t.days,u=t.shortDays,a=t.months,c=t.shortMonths,f=ey(i),s=ry(i),l=ey(o),h=ry(o),d=ey(u),p=ry(u),v=ey(a),g=ry(a),y=ey(c),_=ry(c),b={a:function(t){return u[t.getDay()]},A:function(t){return o[t.getDay()]},b:function(t){return c[t.getMonth()]},B:function(t){return a[t.getMonth()]},c:null,d:Ay,e:Ay,f:Ey,g:Dy,G:Vy,H:ky,I:Sy,j:Ty,L:Cy,m:Ny,M:jy,p:function(t){return i[+(t.getHours()>=12)]},q:function(t){return 1+~~(t.getMonth()/3)},Q:l_,s:h_,S:Oy,u:Ry,U:Py,V:Iy,w:Ly,W:Fy,x:null,X:null,y:Uy,Y:By,Z:qy,"%":s_},m={a:function(t){return u[t.getUTCDay()]},A:function(t){return o[t.getUTCDay()]},b:function(t){return c[t.getUTCMonth()]},B:function(t){return a[t.getUTCMonth()]},c:null,d:Yy,e:Yy,f:Gy,g:u_,G:c_,H:Hy,I:$y,j:Wy,L:Xy,m:Zy,M:Ky,p:function(t){return i[+(t.getUTCHours()>=12)]},q:function(t){return 1+~~(t.getUTCMonth()/3)},Q:l_,s:h_,S:Qy,u:Jy,U:t_,V:e_,w:r_,W:i_,x:null,X:null,y:o_,Y:a_,Z:f_,"%":s_},x={a:function(t,n,e){var r=d.exec(n.slice(e));return r?(t.w=p[r[0].toLowerCase()],e+r[0].length):-1},A:function(t,n,e){var r=l.exec(n.slice(e));return r?(t.w=h[r[0].toLowerCase()],e+r[0].length):-1},b:function(t,n,e){var r=y.exec(n.slice(e));return r?(t.m=_[r[0].toLowerCase()],e+r[0].length):-1},B:function(t,n,e){var r=v.exec(n.slice(e));return r?(t.m=g[r[0].toLowerCase()],e+r[0].length):-1},c:function(t,e,r){return A(t,n,e,r)},d:py,e:py,f:my,g:sy,G:fy,H:gy,I:gy,j:vy,L:by,m:dy,M:yy,p:function(t,n,e){var r=f.exec(n.slice(e));return r?(t.p=s[r[0].toLowerCase()],e+r[0].length):-1},q:hy,Q:wy,s:My,S:_y,u:oy,U:uy,V:ay,w:iy,W:cy,x:function(t,n,r){return A(t,e,n,r)},X:function(t,n,e){return A(t,r,n,e)},y:sy,Y:fy,Z:ly,"%":xy};function w(t,n){return function(e){var r,i,o,u=[],a=-1,c=0,f=t.length;for(e instanceof Date||(e=new Date(+e));++a53)return null;"w"in o||(o.w=1),"Z"in o?(i=(r=Vg(qg(o.y,0,1))).getUTCDay(),r=i>4||0===i?wg.ceil(r):wg(r),r=Ig.offset(r,7*(o.V-1)),o.y=r.getUTCFullYear(),o.m=r.getUTCMonth(),o.d=r.getUTCDate()+(o.w+6)%7):(i=(r=Bg(qg(o.y,0,1))).getDay(),r=i>4||0===i?$v.ceil(r):$v(r),r=ug.offset(r,7*(o.V-1)),o.y=r.getFullYear(),o.m=r.getMonth(),o.d=r.getDate()+(o.w+6)%7)}else("W"in o||"U"in o)&&("w"in o||(o.w="u"in o?o.u%7:"W"in o?1:0),i="Z"in o?Vg(qg(o.y,0,1)).getUTCDay():Bg(qg(o.y,0,1)).getDay(),o.m=0,o.d="W"in o?(o.w+6)%7+7*o.W-(i+5)%7:o.w+7*o.U-(i+6)%7);return"Z"in o?(o.H+=o.Z/100|0,o.M+=o.Z%100,Vg(o)):Bg(o)}}function A(t,n,e,r){for(var i,o,u=0,a=n.length,c=e.length;u=c)return-1;if(37===(i=n.charCodeAt(u++))){if(i=n.charAt(u++),!(o=x[i in Zg?n.charAt(u++):i])||(r=o(t,e,r))<0)return-1}else if(i!=e.charCodeAt(r++))return-1}return r}return b.x=w(e,b),b.X=w(r,b),b.c=w(n,b),m.x=w(e,m),m.X=w(r,m),m.c=w(n,m),{format:function(t){var n=w(t+="",b);return n.toString=function(){return t},n},parse:function(t){var n=M(t+="",!1);return n.toString=function(){return t},n},utcFormat:function(t){var n=w(t+="",m);return n.toString=function(){return t},n},utcParse:function(t){var n=M(t+="",!0);return n.toString=function(){return t},n}}}var Hg,$g,Wg,Xg,Gg,Zg={"-":"",_:" ",0:"0"},Kg=/^\s*\d+/,Qg=/^%/,Jg=/[\\^$*+?|[\]().{}]/g;function ty(t,n,e){var r=t<0?"-":"",i=(r?-t:t)+"",o=i.length;return r+(o68?1900:2e3),e+r[0].length):-1}function ly(t,n,e){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(n.slice(e,e+6));return r?(t.Z=r[1]?0:-(r[2]+(r[3]||"00")),e+r[0].length):-1}function hy(t,n,e){var r=Kg.exec(n.slice(e,e+1));return r?(t.q=3*r[0]-3,e+r[0].length):-1}function dy(t,n,e){var r=Kg.exec(n.slice(e,e+2));return r?(t.m=r[0]-1,e+r[0].length):-1}function py(t,n,e){var r=Kg.exec(n.slice(e,e+2));return r?(t.d=+r[0],e+r[0].length):-1}function vy(t,n,e){var r=Kg.exec(n.slice(e,e+3));return r?(t.m=0,t.d=+r[0],e+r[0].length):-1}function gy(t,n,e){var r=Kg.exec(n.slice(e,e+2));return r?(t.H=+r[0],e+r[0].length):-1}function yy(t,n,e){var r=Kg.exec(n.slice(e,e+2));return r?(t.M=+r[0],e+r[0].length):-1}function _y(t,n,e){var r=Kg.exec(n.slice(e,e+2));return r?(t.S=+r[0],e+r[0].length):-1}function by(t,n,e){var r=Kg.exec(n.slice(e,e+3));return r?(t.L=+r[0],e+r[0].length):-1}function my(t,n,e){var r=Kg.exec(n.slice(e,e+6));return r?(t.L=Math.floor(r[0]/1e3),e+r[0].length):-1}function xy(t,n,e){var r=Qg.exec(n.slice(e,e+1));return r?e+r[0].length:-1}function wy(t,n,e){var r=Kg.exec(n.slice(e));return r?(t.Q=+r[0],e+r[0].length):-1}function My(t,n,e){var r=Kg.exec(n.slice(e));return r?(t.s=+r[0],e+r[0].length):-1}function Ay(t,n){return ty(t.getDate(),n,2)}function ky(t,n){return ty(t.getHours(),n,2)}function Sy(t,n){return ty(t.getHours()%12||12,n,2)}function Ty(t,n){return ty(1+ug.count(Uv(t),t),n,3)}function Cy(t,n){return ty(t.getMilliseconds(),n,3)}function Ey(t,n){return Cy(t,n)+"000"}function Ny(t,n){return ty(t.getMonth()+1,n,2)}function jy(t,n){return ty(t.getMinutes(),n,2)}function Oy(t,n){return ty(t.getSeconds(),n,2)}function Ry(t){var n=t.getDay();return 0===n?7:n}function Py(t,n){return ty(Hv.count(Uv(t)-1,t),n,2)}function zy(t){var n=t.getDay();return n>=4||0===n?Gv(t):Gv.ceil(t)}function Iy(t,n){return t=zy(t),ty(Gv.count(Uv(t),t)+(4===Uv(t).getDay()),n,2)}function Ly(t){return t.getDay()}function Fy(t,n){return ty($v.count(Uv(t)-1,t),n,2)}function Uy(t,n){return ty(t.getFullYear()%100,n,2)}function Dy(t,n){return ty((t=zy(t)).getFullYear()%100,n,2)}function By(t,n){return ty(t.getFullYear()%1e4,n,4)}function Vy(t,n){var e=t.getDay();return ty((t=e>=4||0===e?Gv(t):Gv.ceil(t)).getFullYear()%1e4,n,4)}function qy(t){var n=t.getTimezoneOffset();return(n>0?"-":(n*=-1,"+"))+ty(n/60|0,"0",2)+ty(n%60,"0",2)}function Yy(t,n){return ty(t.getUTCDate(),n,2)}function Hy(t,n){return ty(t.getUTCHours(),n,2)}function $y(t,n){return ty(t.getUTCHours()%12||12,n,2)}function Wy(t,n){return ty(1+Ig.count(Ug(t),t),n,3)}function Xy(t,n){return ty(t.getUTCMilliseconds(),n,3)}function Gy(t,n){return Xy(t,n)+"000"}function Zy(t,n){return ty(t.getUTCMonth()+1,n,2)}function Ky(t,n){return ty(t.getUTCMinutes(),n,2)}function Qy(t,n){return ty(t.getUTCSeconds(),n,2)}function Jy(t){var n=t.getUTCDay();return 0===n?7:n}function t_(t,n){return ty(xg.count(Ug(t)-1,t),n,2)}function n_(t){var n=t.getUTCDay();return n>=4||0===n?kg(t):kg.ceil(t)}function e_(t,n){return t=n_(t),ty(kg.count(Ug(t),t)+(4===Ug(t).getUTCDay()),n,2)}function r_(t){return t.getUTCDay()}function i_(t,n){return ty(wg.count(Ug(t)-1,t),n,2)}function o_(t,n){return ty(t.getUTCFullYear()%100,n,2)}function u_(t,n){return ty((t=n_(t)).getUTCFullYear()%100,n,2)}function a_(t,n){return ty(t.getUTCFullYear()%1e4,n,4)}function c_(t,n){var e=t.getUTCDay();return ty((t=e>=4||0===e?kg(t):kg.ceil(t)).getUTCFullYear()%1e4,n,4)}function f_(){return"+0000"}function s_(){return"%"}function l_(t){return+t}function h_(t){return Math.floor(+t/1e3)}function d_(t){return Hg=Yg(t),$g=Hg.format,Wg=Hg.parse,Xg=Hg.utcFormat,Gg=Hg.utcParse,Hg}d_({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function p_(t){return new Date(t)}function v_(t){return t instanceof Date?+t:+new Date(+t)}function g_(t,n,e,r,i,o,u,a,f){var s=cv(nv,nv),l=s.invert,h=s.domain,d=f(".%L"),p=f(":%S"),v=f("%I:%M"),g=f("%I %p"),y=f("%a %d"),_=f("%b %d"),b=f("%B"),m=f("%Y"),x=[[u,1,1e3],[u,5,5e3],[u,15,15e3],[u,30,3e4],[o,1,6e4],[o,5,3e5],[o,15,9e5],[o,30,18e5],[i,1,36e5],[i,3,108e5],[i,6,216e5],[i,12,432e5],[r,1,864e5],[r,2,1728e5],[e,1,6048e5],[n,1,2592e6],[n,3,7776e6],[t,1,31536e6]];function w(a){return(u(a)1)&&(t-=Math.floor(t));var n=Math.abs(t-.5);return im.h=360*t-100,im.s=1.5-1.5*n,im.l=.8-.9*n,im+""},um=Qn(),am=Math.PI/3,cm=2*Math.PI/3,fm=function(t){var n;return t=(.5-t)*Math.PI,um.r=255*(n=Math.sin(t))*n,um.g=255*(n=Math.sin(t+am))*n,um.b=255*(n=Math.sin(t+cm))*n,um+""},sm=function(t){return t=Math.max(0,Math.min(1,t)),"rgb("+Math.max(0,Math.min(255,Math.round(34.61+t*(1172.33-t*(10793.56-t*(33300.12-t*(38394.49-14825.05*t)))))))+", "+Math.max(0,Math.min(255,Math.round(23.31+t*(557.33+t*(1225.33-t*(3574.96-t*(1073.77+707.56*t)))))))+", "+Math.max(0,Math.min(255,Math.round(27.2+t*(3211.1-t*(15327.97-t*(27814-t*(22569.18-6838.66*t)))))))+")"};function lm(t){var n=t.length;return function(e){return t[Math.max(0,Math.min(n-1,Math.floor(e*n)))]}}var hm=lm(V_("44015444025645045745055946075a46085c460a5d460b5e470d60470e6147106347116447136548146748166848176948186a481a6c481b6d481c6e481d6f481f70482071482173482374482475482576482677482878482979472a7a472c7a472d7b472e7c472f7d46307e46327e46337f463480453581453781453882443983443a83443b84433d84433e85423f854240864241864142874144874045884046883f47883f48893e49893e4a893e4c8a3d4d8a3d4e8a3c4f8a3c508b3b518b3b528b3a538b3a548c39558c39568c38588c38598c375a8c375b8d365c8d365d8d355e8d355f8d34608d34618d33628d33638d32648e32658e31668e31678e31688e30698e306a8e2f6b8e2f6c8e2e6d8e2e6e8e2e6f8e2d708e2d718e2c718e2c728e2c738e2b748e2b758e2a768e2a778e2a788e29798e297a8e297b8e287c8e287d8e277e8e277f8e27808e26818e26828e26828e25838e25848e25858e24868e24878e23888e23898e238a8d228b8d228c8d228d8d218e8d218f8d21908d21918c20928c20928c20938c1f948c1f958b1f968b1f978b1f988b1f998a1f9a8a1e9b8a1e9c891e9d891f9e891f9f881fa0881fa1881fa1871fa28720a38620a48621a58521a68522a78522a88423a98324aa8325ab8225ac8226ad8127ad8128ae8029af7f2ab07f2cb17e2db27d2eb37c2fb47c31b57b32b67a34b67935b77937b87838b9773aba763bbb753dbc743fbc7340bd7242be7144bf7046c06f48c16e4ac16d4cc26c4ec36b50c46a52c56954c56856c66758c7655ac8645cc8635ec96260ca6063cb5f65cb5e67cc5c69cd5b6ccd5a6ece5870cf5773d05675d05477d1537ad1517cd2507fd34e81d34d84d44b86d54989d5488bd6468ed64590d74393d74195d84098d83e9bd93c9dd93ba0da39a2da37a5db36a8db34aadc32addc30b0dd2fb2dd2db5de2bb8de29bade28bddf26c0df25c2df23c5e021c8e020cae11fcde11dd0e11cd2e21bd5e21ad8e219dae319dde318dfe318e2e418e5e419e7e419eae51aece51befe51cf1e51df4e61ef6e620f8e621fbe723fde725")),dm=lm(V_("00000401000501010601010802010902020b02020d03030f03031204041405041606051806051a07061c08071e0907200a08220b09240c09260d0a290e0b2b100b2d110c2f120d31130d34140e36150e38160f3b180f3d19103f1a10421c10441d11471e114920114b21114e22115024125325125527125829115a2a115c2c115f2d11612f116331116533106734106936106b38106c390f6e3b0f703d0f713f0f72400f74420f75440f764510774710784910784a10794c117a4e117b4f127b51127c52137c54137d56147d57157e59157e5a167e5c167f5d177f5f187f601880621980641a80651a80671b80681c816a1c816b1d816d1d816e1e81701f81721f817320817521817621817822817922827b23827c23827e24828025828125818326818426818627818827818928818b29818c29818e2a81902a81912b81932b80942c80962c80982d80992d809b2e7f9c2e7f9e2f7fa02f7fa1307ea3307ea5317ea6317da8327daa337dab337cad347cae347bb0357bb2357bb3367ab5367ab73779b83779ba3878bc3978bd3977bf3a77c03a76c23b75c43c75c53c74c73d73c83e73ca3e72cc3f71cd4071cf4070d0416fd2426fd3436ed5446dd6456cd8456cd9466bdb476adc4869de4968df4a68e04c67e24d66e34e65e44f64e55064e75263e85362e95462ea5661eb5760ec5860ed5a5fee5b5eef5d5ef05f5ef1605df2625df2645cf3655cf4675cf4695cf56b5cf66c5cf66e5cf7705cf7725cf8745cf8765cf9785df9795df97b5dfa7d5efa7f5efa815ffb835ffb8560fb8761fc8961fc8a62fc8c63fc8e64fc9065fd9266fd9467fd9668fd9869fd9a6afd9b6bfe9d6cfe9f6dfea16efea36ffea571fea772fea973feaa74feac76feae77feb078feb27afeb47bfeb67cfeb77efeb97ffebb81febd82febf84fec185fec287fec488fec68afec88cfeca8dfecc8ffecd90fecf92fed194fed395fed597fed799fed89afdda9cfddc9efddea0fde0a1fde2a3fde3a5fde5a7fde7a9fde9aafdebacfcecaefceeb0fcf0b2fcf2b4fcf4b6fcf6b8fcf7b9fcf9bbfcfbbdfcfdbf")),pm=lm(V_("00000401000501010601010802010a02020c02020e03021004031204031405041706041907051b08051d09061f0a07220b07240c08260d08290e092b10092d110a30120a32140b34150b37160b39180c3c190c3e1b0c411c0c431e0c451f0c48210c4a230c4c240c4f260c51280b53290b552b0b572d0b592f0a5b310a5c320a5e340a5f3609613809623909633b09643d09653e0966400a67420a68440a68450a69470b6a490b6a4a0c6b4c0c6b4d0d6c4f0d6c510e6c520e6d540f6d550f6d57106e59106e5a116e5c126e5d126e5f136e61136e62146e64156e65156e67166e69166e6a176e6c186e6d186e6f196e71196e721a6e741a6e751b6e771c6d781c6d7a1d6d7c1d6d7d1e6d7f1e6c801f6c82206c84206b85216b87216b88226a8a226a8c23698d23698f24699025689225689326679526679727669827669a28659b29649d29649f2a63a02a63a22b62a32c61a52c60a62d60a82e5fa92e5eab2f5ead305dae305cb0315bb1325ab3325ab43359b63458b73557b93556ba3655bc3754bd3853bf3952c03a51c13a50c33b4fc43c4ec63d4dc73e4cc83f4bca404acb4149cc4248ce4347cf4446d04545d24644d34743d44842d54a41d74b3fd84c3ed94d3dda4e3cdb503bdd513ade5238df5337e05536e15635e25734e35933e45a31e55c30e65d2fe75e2ee8602de9612bea632aeb6429eb6628ec6726ed6925ee6a24ef6c23ef6e21f06f20f1711ff1731df2741cf3761bf37819f47918f57b17f57d15f67e14f68013f78212f78410f8850ff8870ef8890cf98b0bf98c0af98e09fa9008fa9207fa9407fb9606fb9706fb9906fb9b06fb9d07fc9f07fca108fca309fca50afca60cfca80dfcaa0ffcac11fcae12fcb014fcb216fcb418fbb61afbb81dfbba1ffbbc21fbbe23fac026fac228fac42afac62df9c72ff9c932f9cb35f8cd37f8cf3af7d13df7d340f6d543f6d746f5d949f5db4cf4dd4ff4df53f4e156f3e35af3e55df2e661f2e865f2ea69f1ec6df1ed71f1ef75f1f179f2f27df2f482f3f586f3f68af4f88ef5f992f6fa96f8fb9af9fc9dfafda1fcffa4")),vm=lm(V_("0d088710078813078916078a19068c1b068d1d068e20068f2206902406912605912805922a05932c05942e05952f059631059733059735049837049938049a3a049a3c049b3e049c3f049c41049d43039e44039e46039f48039f4903a04b03a14c02a14e02a25002a25102a35302a35502a45601a45801a45901a55b01a55c01a65e01a66001a66100a76300a76400a76600a76700a86900a86a00a86c00a86e00a86f00a87100a87201a87401a87501a87701a87801a87a02a87b02a87d03a87e03a88004a88104a78305a78405a78606a68707a68808a68a09a58b0aa58d0ba58e0ca48f0da4910ea3920fa39410a29511a19613a19814a099159f9a169f9c179e9d189d9e199da01a9ca11b9ba21d9aa31e9aa51f99a62098a72197a82296aa2395ab2494ac2694ad2793ae2892b02991b12a90b22b8fb32c8eb42e8db52f8cb6308bb7318ab83289ba3388bb3488bc3587bd3786be3885bf3984c03a83c13b82c23c81c33d80c43e7fc5407ec6417dc7427cc8437bc9447aca457acb4679cc4778cc4977cd4a76ce4b75cf4c74d04d73d14e72d24f71d35171d45270d5536fd5546ed6556dd7566cd8576bd9586ada5a6ada5b69db5c68dc5d67dd5e66de5f65de6164df6263e06363e16462e26561e26660e3685fe4695ee56a5de56b5de66c5ce76e5be76f5ae87059e97158e97257ea7457eb7556eb7655ec7754ed7953ed7a52ee7b51ef7c51ef7e50f07f4ff0804ef1814df1834cf2844bf3854bf3874af48849f48948f58b47f58c46f68d45f68f44f79044f79143f79342f89441f89540f9973ff9983ef99a3efa9b3dfa9c3cfa9e3bfb9f3afba139fba238fca338fca537fca636fca835fca934fdab33fdac33fdae32fdaf31fdb130fdb22ffdb42ffdb52efeb72dfeb82cfeba2cfebb2bfebd2afebe2afec029fdc229fdc328fdc527fdc627fdc827fdca26fdcb26fccd25fcce25fcd025fcd225fbd324fbd524fbd724fad824fada24f9dc24f9dd25f8df25f8e125f7e225f7e425f6e626f6e826f5e926f5eb27f4ed27f3ee27f3f027f2f227f1f426f1f525f0f724f0f921")),gm=function(t){return Tn(an(t).call(document.documentElement))},ym=0;function _m(){return new bm}function bm(){this._="@"+(++ym).toString(36)}bm.prototype=_m.prototype={constructor:bm,get:function(t){for(var n=this._;!(n in t);)if(!(t=t.parentNode))return;return t[n]},set:function(t,n){return t[this._]=n},remove:function(t){return this._ in t&&delete t[this._]},toString:function(){return this._}};var mm=function(t){return"string"==typeof t?new An([document.querySelectorAll(t)],[document.documentElement]):new An([null==t?[]:t],Mn)},xm=function(t,n){null==n&&(n=Re().touches);for(var e=0,r=n?n.length:0,i=new Array(r);e1?0:t<-1?Nm:Math.acos(t)}function Pm(t){return t>=1?jm:t<=-1?-jm:Math.asin(t)}function zm(t){return t.innerRadius}function Im(t){return t.outerRadius}function Lm(t){return t.startAngle}function Fm(t){return t.endAngle}function Um(t){return t&&t.padAngle}function Dm(t,n,e,r,i,o,u,a){var c=e-t,f=r-n,s=u-i,l=a-o,h=l*c-s*f;if(!(h*h<1e-12))return[t+(h=(s*(n-o)-l*(t-i))/h)*c,n+h*f]}function Bm(t,n,e,r,i,o,u){var a=t-e,c=n-r,f=(u?o:-o)/Em(a*a+c*c),s=f*c,l=-f*a,h=t+s,d=n+l,p=e+s,v=r+l,g=(h+p)/2,y=(d+v)/2,_=p-h,b=v-d,m=_*_+b*b,x=i-o,w=h*v-p*d,M=(b<0?-1:1)*Em(Sm(0,x*x*m-w*w)),A=(w*b-_*M)/m,k=(-w*_-b*M)/m,S=(w*b+_*M)/m,T=(-w*_+b*M)/m,C=A-g,E=k-y,N=S-g,j=T-y;return C*C+E*E>N*N+j*j&&(A=S,k=T),{cx:A,cy:k,x01:-s,y01:-l,x11:A*(i/x-1),y11:k*(i/x-1)}}var Vm=function(){var t=zm,n=Im,e=wm(0),r=null,i=Lm,o=Fm,u=Um,a=null;function c(){var c,f,s=+t.apply(this,arguments),l=+n.apply(this,arguments),h=i.apply(this,arguments)-jm,d=o.apply(this,arguments)-jm,p=Mm(d-h),v=d>h;if(a||(a=c=$i()),l1e-12)if(p>Om-1e-12)a.moveTo(l*km(h),l*Cm(h)),a.arc(0,0,l,h,d,!v),s>1e-12&&(a.moveTo(s*km(d),s*Cm(d)),a.arc(0,0,s,d,h,v));else{var g,y,_=h,b=d,m=h,x=d,w=p,M=p,A=u.apply(this,arguments)/2,k=A>1e-12&&(r?+r.apply(this,arguments):Em(s*s+l*l)),S=Tm(Mm(l-s)/2,+e.apply(this,arguments)),T=S,C=S;if(k>1e-12){var E=Pm(k/s*Cm(A)),N=Pm(k/l*Cm(A));(w-=2*E)>1e-12?(m+=E*=v?1:-1,x-=E):(w=0,m=x=(h+d)/2),(M-=2*N)>1e-12?(_+=N*=v?1:-1,b-=N):(M=0,_=b=(h+d)/2)}var j=l*km(_),O=l*Cm(_),R=s*km(x),P=s*Cm(x);if(S>1e-12){var z,I=l*km(b),L=l*Cm(b),F=s*km(m),U=s*Cm(m);if(p1e-12?C>1e-12?(g=Bm(F,U,j,O,l,C,v),y=Bm(I,L,R,P,l,C,v),a.moveTo(g.cx+g.x01,g.cy+g.y01),C1e-12&&w>1e-12?T>1e-12?(g=Bm(R,P,I,L,s,-T,v),y=Bm(j,O,F,U,s,-T,v),a.lineTo(g.cx+g.x01,g.cy+g.y01),T=s;--l)a.point(g[l],y[l]);a.lineEnd(),a.areaEnd()}v&&(g[f]=+t(h,f,c),y[f]=+e(h,f,c),a.point(n?+n(h,f,c):g[f],r?+r(h,f,c):y[f]))}if(d)return a=null,d+""||null}function f(){return Wm().defined(i).curve(u).context(o)}return c.x=function(e){return arguments.length?(t="function"==typeof e?e:wm(+e),n=null,c):t},c.x0=function(n){return arguments.length?(t="function"==typeof n?n:wm(+n),c):t},c.x1=function(t){return arguments.length?(n=null==t?null:"function"==typeof t?t:wm(+t),c):n},c.y=function(t){return arguments.length?(e="function"==typeof t?t:wm(+t),r=null,c):e},c.y0=function(t){return arguments.length?(e="function"==typeof t?t:wm(+t),c):e},c.y1=function(t){return arguments.length?(r=null==t?null:"function"==typeof t?t:wm(+t),c):r},c.lineX0=c.lineY0=function(){return f().x(t).y(e)},c.lineY1=function(){return f().x(t).y(r)},c.lineX1=function(){return f().x(n).y(e)},c.defined=function(t){return arguments.length?(i="function"==typeof t?t:wm(!!t),c):i},c.curve=function(t){return arguments.length?(u=t,null!=o&&(a=u(o)),c):u},c.context=function(t){return arguments.length?(null==t?o=a=null:a=u(o=t),c):o},c},Gm=function(t,n){return nt?1:n>=t?0:NaN},Zm=function(t){return t},Km=function(){var t=Zm,n=Gm,e=null,r=wm(0),i=wm(Om),o=wm(0);function u(u){var a,c,f,s,l,h=u.length,d=0,p=new Array(h),v=new Array(h),g=+r.apply(this,arguments),y=Math.min(Om,Math.max(-Om,i.apply(this,arguments)-g)),_=Math.min(Math.abs(y)/h,o.apply(this,arguments)),b=_*(y<0?-1:1);for(a=0;a0&&(d+=l);for(null!=n?p.sort((function(t,e){return n(v[t],v[e])})):null!=e&&p.sort((function(t,n){return e(u[t],u[n])})),a=0,f=d?(y-h*b)/d:0;a0?l*f:0)+b,v[c]={data:u[c],index:a,value:l,startAngle:g,endAngle:s,padAngle:_};return v}return u.value=function(n){return arguments.length?(t="function"==typeof n?n:wm(+n),u):t},u.sortValues=function(t){return arguments.length?(n=t,e=null,u):n},u.sort=function(t){return arguments.length?(e=t,n=null,u):e},u.startAngle=function(t){return arguments.length?(r="function"==typeof t?t:wm(+t),u):r},u.endAngle=function(t){return arguments.length?(i="function"==typeof t?t:wm(+t),u):i},u.padAngle=function(t){return arguments.length?(o="function"==typeof t?t:wm(+t),u):o},u},Qm=tx(Ym);function Jm(t){this._curve=t}function tx(t){function n(n){return new Jm(t(n))}return n._curve=t,n}function nx(t){var n=t.curve;return t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t.curve=function(t){return arguments.length?n(tx(t)):n()._curve},t}Jm.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(t,n){this._curve.point(n*Math.sin(t),n*-Math.cos(t))}};var ex=function(){return nx(Wm().curve(Qm))},rx=function(){var t=Xm().curve(Qm),n=t.curve,e=t.lineX0,r=t.lineX1,i=t.lineY0,o=t.lineY1;return t.angle=t.x,delete t.x,t.startAngle=t.x0,delete t.x0,t.endAngle=t.x1,delete t.x1,t.radius=t.y,delete t.y,t.innerRadius=t.y0,delete t.y0,t.outerRadius=t.y1,delete t.y1,t.lineStartAngle=function(){return nx(e())},delete t.lineX0,t.lineEndAngle=function(){return nx(r())},delete t.lineX1,t.lineInnerRadius=function(){return nx(i())},delete t.lineY0,t.lineOuterRadius=function(){return nx(o())},delete t.lineY1,t.curve=function(t){return arguments.length?n(tx(t)):n()._curve},t},ix=function(t,n){return[(n=+n)*Math.cos(t-=Math.PI/2),n*Math.sin(t)]},ox=Array.prototype.slice;function ux(t){return t.source}function ax(t){return t.target}function cx(t){var n=ux,e=ax,r=Hm,i=$m,o=null;function u(){var u,a=ox.call(arguments),c=n.apply(this,a),f=e.apply(this,a);if(o||(o=u=$i()),t(o,+r.apply(this,(a[0]=c,a)),+i.apply(this,a),+r.apply(this,(a[0]=f,a)),+i.apply(this,a)),u)return o=null,u+""||null}return u.source=function(t){return arguments.length?(n=t,u):n},u.target=function(t){return arguments.length?(e=t,u):e},u.x=function(t){return arguments.length?(r="function"==typeof t?t:wm(+t),u):r},u.y=function(t){return arguments.length?(i="function"==typeof t?t:wm(+t),u):i},u.context=function(t){return arguments.length?(o=null==t?null:t,u):o},u}function fx(t,n,e,r,i){t.moveTo(n,e),t.bezierCurveTo(n=(n+r)/2,e,n,i,r,i)}function sx(t,n,e,r,i){t.moveTo(n,e),t.bezierCurveTo(n,e=(e+i)/2,r,e,r,i)}function lx(t,n,e,r,i){var o=ix(n,e),u=ix(n,e=(e+i)/2),a=ix(r,e),c=ix(r,i);t.moveTo(o[0],o[1]),t.bezierCurveTo(u[0],u[1],a[0],a[1],c[0],c[1])}function hx(){return cx(fx)}function dx(){return cx(sx)}function px(){var t=cx(lx);return t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t}var vx={draw:function(t,n){var e=Math.sqrt(n/Nm);t.moveTo(e,0),t.arc(0,0,e,0,Om)}},gx={draw:function(t,n){var e=Math.sqrt(n/5)/2;t.moveTo(-3*e,-e),t.lineTo(-e,-e),t.lineTo(-e,-3*e),t.lineTo(e,-3*e),t.lineTo(e,-e),t.lineTo(3*e,-e),t.lineTo(3*e,e),t.lineTo(e,e),t.lineTo(e,3*e),t.lineTo(-e,3*e),t.lineTo(-e,e),t.lineTo(-3*e,e),t.closePath()}},yx=Math.sqrt(1/3),_x=2*yx,bx={draw:function(t,n){var e=Math.sqrt(n/_x),r=e*yx;t.moveTo(0,-e),t.lineTo(r,0),t.lineTo(0,e),t.lineTo(-r,0),t.closePath()}},mx=Math.sin(Nm/10)/Math.sin(7*Nm/10),xx=Math.sin(Om/10)*mx,wx=-Math.cos(Om/10)*mx,Mx={draw:function(t,n){var e=Math.sqrt(.8908130915292852*n),r=xx*e,i=wx*e;t.moveTo(0,-e),t.lineTo(r,i);for(var o=1;o<5;++o){var u=Om*o/5,a=Math.cos(u),c=Math.sin(u);t.lineTo(c*e,-a*e),t.lineTo(a*r-c*i,c*r+a*i)}t.closePath()}},Ax={draw:function(t,n){var e=Math.sqrt(n),r=-e/2;t.rect(r,r,e,e)}},kx=Math.sqrt(3),Sx={draw:function(t,n){var e=-Math.sqrt(n/(3*kx));t.moveTo(0,2*e),t.lineTo(-kx*e,-e),t.lineTo(kx*e,-e),t.closePath()}},Tx=Math.sqrt(3)/2,Cx=1/Math.sqrt(12),Ex=3*(Cx/2+1),Nx={draw:function(t,n){var e=Math.sqrt(n/Ex),r=e/2,i=e*Cx,o=r,u=e*Cx+e,a=-o,c=u;t.moveTo(r,i),t.lineTo(o,u),t.lineTo(a,c),t.lineTo(-.5*r-Tx*i,Tx*r+-.5*i),t.lineTo(-.5*o-Tx*u,Tx*o+-.5*u),t.lineTo(-.5*a-Tx*c,Tx*a+-.5*c),t.lineTo(-.5*r+Tx*i,-.5*i-Tx*r),t.lineTo(-.5*o+Tx*u,-.5*u-Tx*o),t.lineTo(-.5*a+Tx*c,-.5*c-Tx*a),t.closePath()}},jx=[vx,gx,bx,Ax,Mx,Sx,Nx],Ox=function(){var t=wm(vx),n=wm(64),e=null;function r(){var r;if(e||(e=r=$i()),t.apply(this,arguments).draw(e,+n.apply(this,arguments)),r)return e=null,r+""||null}return r.type=function(n){return arguments.length?(t="function"==typeof n?n:wm(n),r):t},r.size=function(t){return arguments.length?(n="function"==typeof t?t:wm(+t),r):n},r.context=function(t){return arguments.length?(e=null==t?null:t,r):e},r},Rx=function(){};function Px(t,n,e){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+n)/6,(t._y0+4*t._y1+e)/6)}function zx(t){this._context=t}zx.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:Px(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,n){switch(t=+t,n=+n,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,n):this._context.moveTo(t,n);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:Px(this,t,n)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=n}};var Ix=function(t){return new zx(t)};function Lx(t){this._context=t}Lx.prototype={areaStart:Rx,areaEnd:Rx,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(t,n){switch(t=+t,n=+n,this._point){case 0:this._point=1,this._x2=t,this._y2=n;break;case 1:this._point=2,this._x3=t,this._y3=n;break;case 2:this._point=3,this._x4=t,this._y4=n,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+n)/6);break;default:Px(this,t,n)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=n}};var Fx=function(t){return new Lx(t)};function Ux(t){this._context=t}Ux.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,n){switch(t=+t,n=+n,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var e=(this._x0+4*this._x1+t)/6,r=(this._y0+4*this._y1+n)/6;this._line?this._context.lineTo(e,r):this._context.moveTo(e,r);break;case 3:this._point=4;default:Px(this,t,n)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=n}};var Dx=function(t){return new Ux(t)};function Bx(t,n){this._basis=new zx(t),this._beta=n}Bx.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,n=this._y,e=t.length-1;if(e>0)for(var r,i=t[0],o=n[0],u=t[e]-i,a=n[e]-o,c=-1;++c<=e;)r=c/e,this._basis.point(this._beta*t[c]+(1-this._beta)*(i+r*u),this._beta*n[c]+(1-this._beta)*(o+r*a));this._x=this._y=null,this._basis.lineEnd()},point:function(t,n){this._x.push(+t),this._y.push(+n)}};var Vx=function t(n){function e(t){return 1===n?new zx(t):new Bx(t,n)}return e.beta=function(n){return t(+n)},e}(.85);function qx(t,n,e){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-n),t._y2+t._k*(t._y1-e),t._x2,t._y2)}function Yx(t,n){this._context=t,this._k=(1-n)/6}Yx.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:qx(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,n){switch(t=+t,n=+n,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,n):this._context.moveTo(t,n);break;case 1:this._point=2,this._x1=t,this._y1=n;break;case 2:this._point=3;default:qx(this,t,n)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=n}};var Hx=function t(n){function e(t){return new Yx(t,n)}return e.tension=function(n){return t(+n)},e}(0);function $x(t,n){this._context=t,this._k=(1-n)/6}$x.prototype={areaStart:Rx,areaEnd:Rx,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,n){switch(t=+t,n=+n,this._point){case 0:this._point=1,this._x3=t,this._y3=n;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=n);break;case 2:this._point=3,this._x5=t,this._y5=n;break;default:qx(this,t,n)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=n}};var Wx=function t(n){function e(t){return new $x(t,n)}return e.tension=function(n){return t(+n)},e}(0);function Xx(t,n){this._context=t,this._k=(1-n)/6}Xx.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,n){switch(t=+t,n=+n,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:qx(this,t,n)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=n}};var Gx=function t(n){function e(t){return new Xx(t,n)}return e.tension=function(n){return t(+n)},e}(0);function Zx(t,n,e){var r=t._x1,i=t._y1,o=t._x2,u=t._y2;if(t._l01_a>1e-12){var a=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,c=3*t._l01_a*(t._l01_a+t._l12_a);r=(r*a-t._x0*t._l12_2a+t._x2*t._l01_2a)/c,i=(i*a-t._y0*t._l12_2a+t._y2*t._l01_2a)/c}if(t._l23_a>1e-12){var f=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,s=3*t._l23_a*(t._l23_a+t._l12_a);o=(o*f+t._x1*t._l23_2a-n*t._l12_2a)/s,u=(u*f+t._y1*t._l23_2a-e*t._l12_2a)/s}t._context.bezierCurveTo(r,i,o,u,t._x2,t._y2)}function Kx(t,n){this._context=t,this._alpha=n}Kx.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,n){if(t=+t,n=+n,this._point){var e=this._x2-t,r=this._y2-n;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(e*e+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,n):this._context.moveTo(t,n);break;case 1:this._point=2;break;case 2:this._point=3;default:Zx(this,t,n)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=n}};var Qx=function t(n){function e(t){return n?new Kx(t,n):new Yx(t,0)}return e.alpha=function(n){return t(+n)},e}(.5);function Jx(t,n){this._context=t,this._alpha=n}Jx.prototype={areaStart:Rx,areaEnd:Rx,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,n){if(t=+t,n=+n,this._point){var e=this._x2-t,r=this._y2-n;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(e*e+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=n;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=n);break;case 2:this._point=3,this._x5=t,this._y5=n;break;default:Zx(this,t,n)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=n}};var tw=function t(n){function e(t){return n?new Jx(t,n):new $x(t,0)}return e.alpha=function(n){return t(+n)},e}(.5);function nw(t,n){this._context=t,this._alpha=n}nw.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,n){if(t=+t,n=+n,this._point){var e=this._x2-t,r=this._y2-n;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(e*e+r*r,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:Zx(this,t,n)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=n}};var ew=function t(n){function e(t){return n?new nw(t,n):new Xx(t,0)}return e.alpha=function(n){return t(+n)},e}(.5);function rw(t){this._context=t}rw.prototype={areaStart:Rx,areaEnd:Rx,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(t,n){t=+t,n=+n,this._point?this._context.lineTo(t,n):(this._point=1,this._context.moveTo(t,n))}};var iw=function(t){return new rw(t)};function ow(t){return t<0?-1:1}function uw(t,n,e){var r=t._x1-t._x0,i=n-t._x1,o=(t._y1-t._y0)/(r||i<0&&-0),u=(e-t._y1)/(i||r<0&&-0),a=(o*i+u*r)/(r+i);return(ow(o)+ow(u))*Math.min(Math.abs(o),Math.abs(u),.5*Math.abs(a))||0}function aw(t,n){var e=t._x1-t._x0;return e?(3*(t._y1-t._y0)/e-n)/2:n}function cw(t,n,e){var r=t._x0,i=t._y0,o=t._x1,u=t._y1,a=(o-r)/3;t._context.bezierCurveTo(r+a,i+a*n,o-a,u-a*e,o,u)}function fw(t){this._context=t}function sw(t){this._context=new lw(t)}function lw(t){this._context=t}function hw(t){return new fw(t)}function dw(t){return new sw(t)}function pw(t){this._context=t}function vw(t){var n,e,r=t.length-1,i=new Array(r),o=new Array(r),u=new Array(r);for(i[0]=0,o[0]=2,u[0]=t[0]+2*t[1],n=1;n=0;--n)i[n]=(u[n]-i[n+1])/o[n];for(o[r-1]=(t[r]+i[r-1])/2,n=0;n=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(t,n){switch(t=+t,n=+n,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,n):this._context.moveTo(t,n);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,n),this._context.lineTo(t,n);else{var e=this._x*(1-this._t)+t*this._t;this._context.lineTo(e,this._y),this._context.lineTo(e,n)}}this._x=t,this._y=n}};var _w=function(t){return new yw(t,.5)};function bw(t){return new yw(t,0)}function mw(t){return new yw(t,1)}var xw=function(t,n){if((i=t.length)>1)for(var e,r,i,o=1,u=t[n[0]],a=u.length;o=0;)e[n]=n;return e};function Mw(t,n){return t[n]}var Aw=function(){var t=wm([]),n=ww,e=xw,r=Mw;function i(i){var o,u,a=t.apply(this,arguments),c=i.length,f=a.length,s=new Array(f);for(o=0;o0){for(var e,r,i,o=0,u=t[0].length;o0)for(var e,r,i,o,u,a,c=0,f=t[n[0]].length;c0?(r[0]=o,r[1]=o+=i):i<0?(r[1]=u,r[0]=u+=i):(r[0]=0,r[1]=i)},Tw=function(t,n){if((e=t.length)>0){for(var e,r=0,i=t[n[0]],o=i.length;r0&&(r=(e=t[n[0]]).length)>0){for(var e,r,i,o=0,u=1;uo&&(o=n,r=e);return r}var jw=function(t){var n=t.map(Ow);return ww(t).sort((function(t,e){return n[t]-n[e]}))};function Ow(t){for(var n,e=0,r=-1,i=t.length;++r0)){if(o/=h,h<0){if(o0){if(o>l)return;o>s&&(s=o)}if(o=r-c,h||!(o<0)){if(o/=h,h<0){if(o>l)return;o>s&&(s=o)}else if(h>0){if(o0)){if(o/=d,d<0){if(o0){if(o>l)return;o>s&&(s=o)}if(o=i-f,d||!(o<0)){if(o/=d,d<0){if(o>l)return;o>s&&(s=o)}else if(d>0){if(o0||l<1)||(s>0&&(t[0]=[c+s*h,f+s*d]),l<1&&(t[1]=[c+l*h,f+l*d]),!0)}}}}}function Qw(t,n,e,r,i){var o=t[1];if(o)return!0;var u,a,c=t[0],f=t.left,s=t.right,l=f[0],h=f[1],d=s[0],p=s[1],v=(l+d)/2,g=(h+p)/2;if(p===h){if(v=r)return;if(l>d){if(c){if(c[1]>=i)return}else c=[v,e];o=[v,i]}else{if(c){if(c[1]1)if(l>d){if(c){if(c[1]>=i)return}else c=[(e-a)/u,e];o=[(i-a)/u,i]}else{if(c){if(c[1]=r)return}else c=[n,u*n+a];o=[r,u*r+a]}else{if(c){if(c[0]=-mM)){var d=c*c+f*f,p=s*s+l*l,v=(l*d-f*p)/h,g=(c*p-s*d)/h,y=rM.pop()||new iM;y.arc=t,y.site=i,y.x=v+u,y.y=(y.cy=g+a)+Math.sqrt(v*v+g*g),t.circle=y;for(var _=null,b=yM._;b;)if(y.ybM)a=a.L;else{if(!((i=o-pM(a,u))>bM)){r>-bM?(n=a.P,e=a):i>-bM?(n=a,e=a.N):n=e=a;break}if(!a.R){n=a;break}a=a.R}!function(t){gM[t.index]={site:t,halfedges:[]}}(t);var c=fM(t);if(vM.insert(n,c),n||e){if(n===e)return uM(n),e=fM(n.site),vM.insert(c,e),c.edge=e.edge=Xw(n.site,c.site),oM(n),void oM(e);if(e){uM(n),uM(e);var f=n.site,s=f[0],l=f[1],h=t[0]-s,d=t[1]-l,p=e.site,v=p[0]-s,g=p[1]-l,y=2*(h*g-d*v),_=h*h+d*d,b=v*v+g*g,m=[(g*_-d*b)/y+s,(h*b-v*_)/y+l];Zw(e.edge,f,p,m),c.edge=Xw(f,t,null,m),e.edge=Xw(t,p,null,m),oM(n),oM(e)}else c.edge=Xw(n.site,c.site)}}function dM(t,n){var e=t.site,r=e[0],i=e[1],o=i-n;if(!o)return r;var u=t.P;if(!u)return-1/0;var a=(e=u.site)[0],c=e[1],f=c-n;if(!f)return a;var s=a-r,l=1/o-1/f,h=s/f;return l?(-h+Math.sqrt(h*h-2*l*(s*s/(-2*f)-c+f/2+i-o/2)))/l+r:(r+a)/2}function pM(t,n){var e=t.N;if(e)return dM(e,n);var r=t.site;return r[1]===n?r[0]:1/0}var vM,gM,yM,_M,bM=1e-6,mM=1e-12;function xM(t,n){return n[1]-t[1]||n[0]-t[0]}function wM(t,n){var e,r,i,o=t.sort(xM).pop();for(_M=[],gM=new Array(t.length),vM=new Ww,yM=new Ww;;)if(i=eM,o&&(!i||o[1]bM||Math.abs(i[0][1]-i[1][1])>bM)||delete _M[o]}(u,a,c,f),function(t,n,e,r){var i,o,u,a,c,f,s,l,h,d,p,v,g=gM.length,y=!0;for(i=0;ibM||Math.abs(v-h)>bM)&&(c.splice(a,0,_M.push(Gw(u,d,Math.abs(p-t)bM?[t,Math.abs(l-t)bM?[Math.abs(h-r)bM?[e,Math.abs(l-e)bM?[Math.abs(h-n)=a)return null;var c=t-i.site[0],f=n-i.site[1],s=c*c+f*f;do{i=o.cells[r=u],u=null,i.halfedges.forEach((function(e){var r=o.edges[e],a=r.left;if(a!==i.site&&a||(a=r.right)){var c=t-a[0],f=n-a[1],l=c*c+f*f;lr?(r+i)/2:Math.min(0,r)||Math.max(0,i),u>o?(o+u)/2:Math.min(0,o)||Math.max(0,u))}var LM,FM=function(){var t,n,e=jM,r=OM,i=IM,o=PM,u=zM,a=[0,1/0],c=[[-1/0,-1/0],[1/0,1/0]],f=250,s=gp,l=pt("start","zoom","end"),h=0;function d(t){t.property("__zoom",RM).on("wheel.zoom",m).on("mousedown.zoom",x).on("dblclick.zoom",w).filter(u).on("touchstart.zoom",M).on("touchmove.zoom",A).on("touchend.zoom touchcancel.zoom",k).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function p(t,n){return(n=Math.max(a[0],Math.min(a[1],n)))===t.k?t:new SM(n,t.x,t.y)}function v(t,n,e){var r=n[0]-e[0]*t.k,i=n[1]-e[1]*t.k;return r===t.x&&i===t.y?t:new SM(t.k,r,i)}function g(t){return[(+t[0][0]+ +t[1][0])/2,(+t[0][1]+ +t[1][1])/2]}function y(t,n,e){t.on("start.zoom",(function(){_(this,arguments).start()})).on("interrupt.zoom end.zoom",(function(){_(this,arguments).end()})).tween("zoom",(function(){var t=this,i=arguments,o=_(t,i),u=r.apply(t,i),a=null==e?g(u):"function"==typeof e?e.apply(t,i):e,c=Math.max(u[1][0]-u[0][0],u[1][1]-u[0][1]),f=t.__zoom,l="function"==typeof n?n.apply(t,i):n,h=s(f.invert(a).concat(c/f.k),l.invert(a).concat(c/l.k));return function(t){if(1===t)t=l;else{var n=h(t),e=c/n[2];t=new SM(e,a[0]-n[0]*e,a[1]-n[1]*e)}o.zoom(null,t)}}))}function _(t,n,e){return!e&&t.__zooming||new b(t,n)}function b(t,n){this.that=t,this.args=n,this.active=0,this.extent=r.apply(t,n),this.taps=0}function m(){if(e.apply(this,arguments)){var t=_(this,arguments),n=this.__zoom,r=Math.max(a[0],Math.min(a[1],n.k*Math.pow(2,o.apply(this,arguments)))),u=Ie(this);if(t.wheel)t.mouse[0][0]===u[0]&&t.mouse[0][1]===u[1]||(t.mouse[1]=n.invert(t.mouse[0]=u)),clearTimeout(t.wheel);else{if(n.k===r)return;t.mouse=[u,n.invert(u)],sr(this),t.start()}NM(),t.wheel=setTimeout(f,150),t.zoom("mouse",i(v(p(n,r),t.mouse[0],t.mouse[1]),t.extent,c))}function f(){t.wheel=null,t.end()}}function x(){if(!n&&e.apply(this,arguments)){var t=_(this,arguments,!0),r=Tn(dn.view).on("mousemove.zoom",f,!0).on("mouseup.zoom",s,!0),o=Ie(this),u=dn.clientX,a=dn.clientY;Nn(dn.view),EM(),t.mouse=[o,this.__zoom.invert(o)],sr(this),t.start()}function f(){if(NM(),!t.moved){var n=dn.clientX-u,e=dn.clientY-a;t.moved=n*n+e*e>h}t.zoom("mouse",i(v(t.that.__zoom,t.mouse[0]=Ie(t.that),t.mouse[1]),t.extent,c))}function s(){r.on("mousemove.zoom mouseup.zoom",null),jn(dn.view,t.moved),NM(),t.end()}}function w(){if(e.apply(this,arguments)){var t=this.__zoom,n=Ie(this),o=t.invert(n),u=t.k*(dn.shiftKey?.5:2),a=i(v(p(t,u),n,o),r.apply(this,arguments),c);NM(),f>0?Tn(this).transition().duration(f).call(y,a,n):Tn(this).call(d.transform,a)}}function M(){if(e.apply(this,arguments)){var n,r,i,o,u=dn.touches,a=u.length,c=_(this,arguments,dn.changedTouches.length===a);for(EM(),r=0;rUM.max(this._stopsValues)||this.aggregatedValue<0||0===this._sortedStops.length)return this.options.defaultColor;var t=function(t,n){if(0===t.length)return-1;for(var e=0,r=t.length-1;r-e>1;){var i=Math.floor((e+r)/2);t[i]n.value?this._sortedStops[t+1].color:n.color},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"_stopsRange",{get:function(){var t=BM(this._stopsValues,[this._maxValue]);if(t.length<2)return this.getUpdatedRangeWithMinValue(t);for(var n=[t[0]],e=1;e6&&this._valueText.length<=10?14:this._valueText.length>10&&this._valueText.length<=12?12:10,this.rescaleValueFont(t)},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"_stat",{get:function(){return this.options.stat},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"_innerRadius",{get:function(){return this.rescaleArcRadius(this.options.innerRadius)},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"_outerRadius",{get:function(){return this.rescaleArcRadius(this.options.outerRadius)},enumerable:!1,configurable:!0}),n.prototype.rescaleArcRadius=function(t){return t*this._scaleFactor},n.prototype.rescaleValueFont=function(t){return t*(.8*this._scaleFactor)},n.prototype.rescaleSpace=function(t){return t*(.5*this._scaleFactor)},n.prototype.rescaleWith=function(t){return t*(.6*this._scaleFactor)},Object.defineProperty(n.prototype,"_scaleFactor",{get:function(){var t=this.options.outerRadius+2+4;return this._minWH/(t+20)},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"aggregatedValue",{get:function(){switch(this._stat){case r.CURRENT:return UM.last(this.series[0].datapoints)[0];default:throw new Error("Unsupported stat: "+this._stat)}},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"_maxValue",{get:function(){return this.options.maxValue||this.maxValue},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"_minValue",{get:function(){return this.options.minValue||0},enumerable:!1,configurable:!0}),n.prototype.onMouseOver=function(){},n.prototype.onMouseMove=function(){},n.prototype.onMouseOut=function(){},n.prototype.renderSharedCrosshair=function(){},n.prototype.hideSharedCrosshair=function(){},n}(o.ChartwerkPod),YM={render:function(t){return t("div",{class:{"chartwerk-gauge-pod":!0},attrs:{id:this.id}})},mixins:[o.VueChartwerkPodMixin],methods:{render:function(){new qM(document.getElementById(this.id),this.series,this.options).render()}}}}])}));