CoolFace
Apppublic

admin08077/Githubgemini

sourceHugging Faceotherupdated 10mo agoView on Hugging Face
0likes
d3-shape-CX8xTzfR.js3 linesDownload Raw Back to assets
1import{P as qt}from"./d3-path-CimkQT29.js";function d(t){return function(){return t}}const yt=Math.abs,T=Math.atan2,L=Math.cos,jt=Math.max,at=Math.min,M=Math.sin,I=Math.sqrt,k=1e-12,V=Math.PI,U=V/2,Q=2*V;function Lt(t){return t>1?0:t<-1?V:Math.acos(t)}function dt(t){return t>=1?U:t<=-1?-U:Math.asin(t)}function Tt(t){let i=3;return t.digits=function(n){if(!arguments.length)return i;if(n==null)i=null;else{const s=Math.floor(n);if(!(s>=0))throw new RangeError(`invalid digits: ${n}`);i=s}return t},()=>new qt(i)}function Xt(t){return t.innerRadius}function Yt(t){return t.outerRadius}function It(t){return t.startAngle}function Vt(t){return t.endAngle}function Dt(t){return t&&t.padAngle}function Ft(t,i,n,s,a,_,r,e){var o=n-t,c=s-i,h=r-a,m=e-_,l=m*o-h*c;if(!(l*l<k))return l=(h*(i-_)-m*(t-a))/l,[t+l*o,i+l*c]}function K(t,i,n,s,a,_,r){var e=t-n,o=i-s,c=(r?_:-_)/I(e*e+o*o),h=c*o,m=-c*e,l=t+h,f=i+m,y=n+h,v=s+m,A=(l+y)/2,x=(f+v)/2,w=y-l,b=v-f,g=w*w+b*b,N=a-_,S=l*v-y*f,B=(b<0?-1:1)*I(jt(0,N*N*g-S*S)),z=(S*b-w*B)/g,O=(-S*w-b*B)/g,P=(S*b+w*B)/g,E=(-S*w+b*B)/g,C=z-A,u=O-x,p=P-A,j=E-x;return C*C+u*u>p*p+j*j&&(z=P,O=E),{cx:z,cy:O,x01:-h,y01:-m,x11:z*(a/N-1),y11:O*(a/N-1)}}function Wt(){var t=Xt,i=Yt,n=d(0),s=null,a=It,_=Vt,r=Dt,e=null,o=Tt(c);function c(){var h,m,l=+t.apply(this,arguments),f=+i.apply(this,arguments),y=a.apply(this,arguments)-U,v=_.apply(this,arguments)-U,A=yt(v-y),x=v>y;if(e||(e=h=o()),f<l&&(m=f,f=l,l=m),!(f>k))e.moveTo(0,0);else if(A>Q-k)e.moveTo(f*L(y),f*M(y)),e.arc(0,0,f,y,v,!x),l>k&&(e.moveTo(l*L(v),l*M(v)),e.arc(0,0,l,v,y,x));else{var w=y,b=v,g=y,N=v,S=A,B=A,z=r.apply(this,arguments)/2,O=z>k&&(s?+s.apply(this,arguments):I(l*l+f*f)),P=at(yt(f-l)/2,+n.apply(this,arguments)),E=P,C=P,u,p;if(O>k){var j=dt(O/l*M(z)),D=dt(O/f*M(z));(S-=j*2)>k?(j*=x?1:-1,g+=j,N-=j):(S=0,g=N=(y+v)/2),(B-=D*2)>k?(D*=x?1:-1,w+=D,b-=D):(B=0,w=b=(y+v)/2)}var X=f*L(w),Y=f*M(w),F=l*L(N),G=l*M(N);if(P>k){var H=f*L(b),J=f*M(b),nt=l*L(g),st=l*M(g),R;if(A<V)if(R=Ft(X,Y,nt,st,H,J,F,G)){var et=X-R[0],_t=Y-R[1],ht=H-R[0],ot=J-R[1],pt=1/M(Lt((et*ht+_t*ot)/(I(et*et+_t*_t)*I(ht*ht+ot*ot)))/2),xt=I(R[0]*R[0]+R[1]*R[1]);E=at(P,(l-xt)/(pt-1)),C=at(P,(f-xt)/(pt+1))}else E=C=0}B>k?C>k?(u=K(nt,st,X,Y,f,C,x),p=K(H,J,F,G,f,C,x),e.moveTo(u.cx+u.x01,u.cy+u.y01),C<P?e.arc(u.cx,u.cy,C,T(u.y01,u.x01),T(p.y01,p.x01),!x):(e.arc(u.cx,u.cy,C,T(u.y01,u.x01),T(u.y11,u.x11),!x),e.arc(0,0,f,T(u.cy+u.y11,u.cx+u.x11),T(p.cy+p.y11,p.cx+p.x11),!x),e.arc(p.cx,p.cy,C,T(p.y11,p.x11),T(p.y01,p.x01),!x))):(e.moveTo(X,Y),e.arc(0,0,f,w,b,!x)):e.moveTo(X,Y),!(l>k)||!(S>k)?e.lineTo(F,G):E>k?(u=K(F,G,H,J,l,-E,x),p=K(X,Y,nt,st,l,-E,x),e.lineTo(u.cx+u.x01,u.cy+u.y01),E<P?e.arc(u.cx,u.cy,E,T(u.y01,u.x01),T(p.y01,p.x01),!x):(e.arc(u.cx,u.cy,E,T(u.y01,u.x01),T(u.y11,u.x11),!x),e.arc(0,0,l,T(u.cy+u.y11,u.cx+u.x11),T(p.cy+p.y11,p.cx+p.x11),x),e.arc(p.cx,p.cy,E,T(p.y11,p.x11),T(p.y01,p.x01),!x))):e.arc(0,0,l,N,g,x)}if(e.closePath(),h)return e=null,h+""||null}return c.centroid=function(){var h=(+t.apply(this,arguments)+ +i.apply(this,arguments))/2,m=(+a.apply(this,arguments)+ +_.apply(this,arguments))/2-V/2;return[L(m)*h,M(m)*h]},c.innerRadius=function(h){return arguments.length?(t=typeof h=="function"?h:d(+h),c):t},c.outerRadius=function(h){return arguments.length?(i=typeof h=="function"?h:d(+h),c):i},c.cornerRadius=function(h){return arguments.length?(n=typeof h=="function"?h:d(+h),c):n},c.padRadius=function(h){return arguments.length?(s=h==null?null:typeof h=="function"?h:d(+h),c):s},c.startAngle=function(h){return arguments.length?(a=typeof h=="function"?h:d(+h),c):a},c.endAngle=function(h){return arguments.length?(_=typeof h=="function"?h:d(+h),c):_},c.padAngle=function(h){return arguments.length?(r=typeof h=="function"?h:d(+h),c):r},c.context=function(h){return arguments.length?(e=h??null,c):e},c}function kt(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}function wt(t){this._context=t}wt.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,i){switch(t=+t,i=+i,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,i):this._context.moveTo(t,i);break;case 1:this._point=2;default:this._context.lineTo(t,i);break}}};function Gt(t){return new wt(t)}function Ht(t){return t[0]}function Jt(t){return t[1]}function Zt(t,i){var n=d(!0),s=null,a=Gt,_=null,r=Tt(e);t=typeof t=="function"?t:t===void 0?Ht:d(t),i=typeof i=="function"?i:i===void 0?Jt:d(i);function e(o){var c,h=(o=kt(o)).length,m,l=!1,f;for(s==null&&(_=a(f=r())),c=0;c<=h;++c)!(c<h&&n(m=o[c],c,o))===l&&((l=!l)?_.lineStart():_.lineEnd()),l&&_.point(+t(m,c,o),+i(m,c,o));if(f)return _=null,f+""||null}return e.x=function(o){return arguments.length?(t=typeof o=="function"?o:d(+o),e):t},e.y=function(o){return arguments.length?(i=typeof o=="function"?o:d(+o),e):i},e.defined=function(o){return arguments.length?(n=typeof o=="function"?o:d(!!o),e):n},e.curve=function(o){return arguments.length?(a=o,s!=null&&(_=a(s)),e):a},e.context=function(o){return arguments.length?(o==null?s=_=null:_=a(s=o),e):s},e}function Kt(t,i){return i<t?-1:i>t?1:i>=t?0:NaN}function Qt(t){return t}function $t(){var t=Qt,i=Kt,n=null,s=d(0),a=d(Q),_=d(0);function r(e){var o,c=(e=kt(e)).length,h,m,l=0,f=new Array(c),y=new Array(c),v=+s.apply(this,arguments),A=Math.min(Q,Math.max(-Q,a.apply(this,arguments)-v)),x,w=Math.min(Math.abs(A)/c,_.apply(this,arguments)),b=w*(A<0?-1:1),g;for(o=0;o<c;++o)(g=y[f[o]=o]=+t(e[o],o,e))>0&&(l+=g);for(i!=null?f.sort(function(N,S){return i(y[N],y[S])}):n!=null&&f.sort(function(N,S){return n(e[N],e[S])}),o=0,m=l?(A-c*b)/l:0;o<c;++o,v=x)h=f[o],g=y[h],x=v+(g>0?g*m:0)+b,y[h]={data:e[h],index:o,value:g,startAngle:v,endAngle:x,padAngle:w};return y}return r.value=function(e){return arguments.length?(t=typeof e=="function"?e:d(+e),r):t},r.sortValues=function(e){return arguments.length?(i=e,n=null,r):i},r.sort=function(e){return arguments.length?(n=e,i=null,r):n},r.startAngle=function(e){return arguments.length?(s=typeof e=="function"?e:d(+e),r):s},r.endAngle=function(e){return arguments.length?(a=typeof e=="function"?e:d(+e),r):a},r.padAngle=function(e){return arguments.length?(_=typeof e=="function"?e:d(+e),r):_},r}class Nt{constructor(i,n){this._context=i,this._x=n}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(i,n){switch(i=+i,n=+n,this._point){case 0:{this._point=1,this._line?this._context.lineTo(i,n):this._context.moveTo(i,n);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+i)/2,this._y0,this._x0,n,i,n):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+n)/2,i,this._y0,i,n);break}}this._x0=i,this._y0=n}}function ti(t){return new Nt(t,!0)}function ii(t){return new Nt(t,!1)}function q(){}function W(t,i,n){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+i)/6,(t._y0+4*t._y1+n)/6)}function tt(t){this._context=t}tt.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:W(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,i){switch(t=+t,i=+i,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,i):this._context.moveTo(t,i);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:W(this,t,i);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=i}};function ni(t){return new tt(t)}function St(t){this._context=t}St.prototype={areaStart:q,areaEnd:q,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(t,i){switch(t=+t,i=+i,this._point){case 0:this._point=1,this._x2=t,this._y2=i;break;case 1:this._point=2,this._x3=t,this._y3=i;break;case 2:this._point=3,this._x4=t,this._y4=i,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+i)/6);break;default:W(this,t,i);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=i}};function si(t){return new St(t)}function Et(t){this._context=t}Et.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(t,i){switch(t=+t,i=+i,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+t)/6,s=(this._y0+4*this._y1+i)/6;this._line?this._context.lineTo(n,s):this._context.moveTo(n,s);break;case 3:this._point=4;default:W(this,t,i);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=i}};function ei(t){return new Et(t)}function Ct(t,i){this._basis=new tt(t),this._beta=i}Ct.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,i=this._y,n=t.length-1;if(n>0)for(var s=t[0],a=i[0],_=t[n]-s,r=i[n]-a,e=-1,o;++e<=n;)o=e/n,this._basis.point(this._beta*t[e]+(1-this._beta)*(s+o*_),this._beta*i[e]+(1-this._beta)*(a+o*r));this._x=this._y=null,this._basis.lineEnd()},point:function(t,i){this._x.push(+t),this._y.push(+i)}};const _i=(function t(i){function n(s){return i===1?new tt(s):new Ct(s,i)}return n.beta=function(s){return t(+s)},n})(.85);function Z(t,i,n){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-i),t._y2+t._k*(t._y1-n),t._x2,t._y2)}function ct(t,i){this._context=t,this._k=(1-i)/6}ct.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:Z(this,this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,i){switch(t=+t,i=+i,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,i):this._context.moveTo(t,i);break;case 1:this._point=2,this._x1=t,this._y1=i;break;case 2:this._point=3;default:Z(this,t,i);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=i}};const hi=(function t(i){function n(s){return new ct(s,i)}return n.tension=function(s){return t(+s)},n})(0);function lt(t,i){this._context=t,this._k=(1-i)/6}lt.prototype={areaStart:q,areaEnd:q,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(t,i){switch(t=+t,i=+i,this._point){case 0:this._point=1,this._x3=t,this._y3=i;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=i);break;case 2:this._point=3,this._x5=t,this._y5=i;break;default:Z(this,t,i);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=i}};const oi=(function t(i){function n(s){return new lt(s,i)}return n.tension=function(s){return t(+s)},n})(0);function ut(t,i){this._context=t,this._k=(1-i)/6}ut.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(t,i){switch(t=+t,i=+i,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:Z(this,t,i);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=i}};const ai=(function t(i){function n(s){return new ut(s,i)}return n.tension=function(s){return t(+s)},n})(0);function ft(t,i,n){var s=t._x1,a=t._y1,_=t._x2,r=t._y2;if(t._l01_a>k){var e=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,o=3*t._l01_a*(t._l01_a+t._l12_a);s=(s*e-t._x0*t._l12_2a+t._x2*t._l01_2a)/o,a=(a*e-t._y0*t._l12_2a+t._y2*t._l01_2a)/o}if(t._l23_a>k){var c=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,h=3*t._l23_a*(t._l23_a+t._l12_a);_=(_*c+t._x1*t._l23_2a-i*t._l12_2a)/h,r=(r*c+t._y1*t._l23_2a-n*t._l12_2a)/h}t._context.bezierCurveTo(s,a,_,r,t._x2,t._y2)}function At(t,i){this._context=t,this._alpha=i}At.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,i){if(t=+t,i=+i,this._point){var n=this._x2-t,s=this._y2-i;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+s*s,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,i):this._context.moveTo(t,i);break;case 1:this._point=2;break;case 2:this._point=3;default:ft(this,t,i);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=i}};const ri=(function t(i){function n(s){return i?new At(s,i):new ct(s,0)}return n.alpha=function(s){return t(+s)},n})(.5);function Pt(t,i){this._context=t,this._alpha=i}Pt.prototype={areaStart:q,areaEnd:q,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(t,i){if(t=+t,i=+i,this._point){var n=this._x2-t,s=this._y2-i;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+s*s,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=i;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=i);break;case 2:this._point=3,this._x5=t,this._y5=i;break;default:ft(this,t,i);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=i}};const ci=(function t(i){function n(s){return i?new Pt(s,i):new lt(s,0)}return n.alpha=function(s){return t(+s)},n})(.5);function Mt(t,i){this._context=t,this._alpha=i}Mt.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(t,i){if(t=+t,i=+i,this._point){var n=this._x2-t,s=this._y2-i;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+s*s,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:ft(this,t,i);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=i}};const li=(function t(i){function n(s){return i?new Mt(s,i):new ut(s,0)}return n.alpha=function(s){return t(+s)},n})(.5);function Rt(t){this._context=t}Rt.prototype={areaStart:q,areaEnd:q,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(t,i){t=+t,i=+i,this._point?this._context.lineTo(t,i):(this._point=1,this._context.moveTo(t,i))}};function ui(t){return new Rt(t)}function mt(t){return t<0?-1:1}function vt(t,i,n){var s=t._x1-t._x0,a=i-t._x1,_=(t._y1-t._y0)/(s||a<0&&-0),r=(n-t._y1)/(a||s<0&&-0),e=(_*a+r*s)/(s+a);return(mt(_)+mt(r))*Math.min(Math.abs(_),Math.abs(r),.5*Math.abs(e))||0}function gt(t,i){var n=t._x1-t._x0;return n?(3*(t._y1-t._y0)/n-i)/2:i}function rt(t,i,n){var s=t._x0,a=t._y0,_=t._x1,r=t._y1,e=(_-s)/3;t._context.bezierCurveTo(s+e,a+e*i,_-e,r-e*n,_,r)}function $(t){this._context=t}$.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:rt(this,this._t0,gt(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,i){var n=NaN;if(t=+t,i=+i,!(t===this._x1&&i===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,i):this._context.moveTo(t,i);break;case 1:this._point=2;break;case 2:this._point=3,rt(this,gt(this,n=vt(this,t,i)),n);break;default:rt(this,this._t0,n=vt(this,t,i));break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=i,this._t0=n}}};function Bt(t){this._context=new zt(t)}(Bt.prototype=Object.create($.prototype)).point=function(t,i){$.prototype.point.call(this,i,t)};function zt(t){this._context=t}zt.prototype={moveTo:function(t,i){this._context.moveTo(i,t)},closePath:function(){this._context.closePath()},lineTo:function(t,i){this._context.lineTo(i,t)},bezierCurveTo:function(t,i,n,s,a,_){this._context.bezierCurveTo(i,t,s,n,_,a)}};function fi(t){return new $(t)}function pi(t){return new Bt(t)}function Ot(t){this._context=t}Ot.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var t=this._x,i=this._y,n=t.length;if(n)if(this._line?this._context.lineTo(t[0],i[0]):this._context.moveTo(t[0],i[0]),n===2)this._context.lineTo(t[1],i[1]);else for(var s=bt(t),a=bt(i),_=0,r=1;r<n;++_,++r)this._context.bezierCurveTo(s[0][_],a[0][_],s[1][_],a[1][_],t[r],i[r]);(this._line||this._line!==0&&n===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(t,i){this._x.push(+t),this._y.push(+i)}};function bt(t){var i,n=t.length-1,s,a=new Array(n),_=new Array(n),r=new Array(n);for(a[0]=0,_[0]=2,r[0]=t[0]+2*t[1],i=1;i<n-1;++i)a[i]=1,_[i]=4,r[i]=4*t[i]+2*t[i+1];for(a[n-1]=2,_[n-1]=7,r[n-1]=8*t[n-1]+t[n],i=1;i<n;++i)s=a[i]/_[i-1],_[i]-=s,r[i]-=s*r[i-1];for(a[n-1]=r[n-1]/_[n-1],i=n-2;i>=0;--i)a[i]=(r[i]-a[i+1])/_[i];for(_[n-1]=(t[n]+a[n-1])/2,i=0;i<n-1;++i)_[i]=2*t[i+1]-a[i+1];return[a,_]}function xi(t){return new Ot(t)}function it(t,i){this._context=t,this._t=i}it.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(t,i){switch(t=+t,i=+i,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,i):this._context.moveTo(t,i);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,i),this._context.lineTo(t,i);else{var n=this._x*(1-this._t)+t*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,i)}break}}this._x=t,this._y=i}};function yi(t){return new it(t,.5)}function di(t){return new it(t,0)}function mi(t){return new it(t,1)}export{mi as a,yi as b,Gt as c,xi as d,fi as e,ui as f,ri as g,li as h,ci as i,hi as j,ai as k,Zt as l,pi as m,oi as n,_i as o,ii as p,ti as q,ei as r,di as s,si as t,ni as u,Wt as v,$t as w};2//# sourceMappingURL=d3-shape-CX8xTzfR.js.map3