/* Highcharts JS v7.0.2 (2019-01-17) Sankey diagram module (c) 2010-2019 Torstein Honsi License: www.highcharts.com/license */ (function(g){"object"===typeof module&&module.exports?(g["default"]=g,module.exports=g):"function"===typeof define&&define.amd?define(function(){return g}):g("undefined"!==typeof Highcharts?Highcharts:void 0)})(function(g){(function(f){f.NodesMixin={createNode:function(g){function q(c,e){return f.find(c,function(a){return a.id===e})}var b=q(this.nodes,g),k=this.pointClass,d;b||(d=this.options.nodes&&q(this.options.nodes,g),b=(new k).init(this,f.extend({className:"highcharts-node",isNode:!0,id:g,y:1}, d)),b.linksTo=[],b.linksFrom=[],b.formatPrefix="node",b.name=b.name||b.options.id,b.getSum=function(){var c=0,e=0;b.linksTo.forEach(function(a){c+=a.weight});b.linksFrom.forEach(function(a){e+=a.weight});return Math.max(c,e)},b.offset=function(c,e){for(var a=0,d=0;da&&(a=e.fromNode.column);c.column=a+1}d[c.column]||(d[c.column]=this.createNodeColumn());d[c.column].push(c)},this);for(var c=0;cn;c&&(m=d.plotSizeY-m,r=d.plotSizeY-r,h=d.plotSizeX-h,t=-t,b=-b,u=n>h);a.shapeType= "path";if(u)a.shapeArgs={d:["M",n+t,m,"C",n+t+B,m,h-B,r,h,r,"L",h+(k?t:0),r+b/2,"L",h,r+b,"C",h-B,r+b,n+t+B,m+b,n+t,m+b,"z"]};else{var k=h-20-b,u=h-20,l=h,x=n+t,w=x+20,C=w+b,H=m,y=m+b,F=y+20,z=F+(d.plotHeight-m-b),v=z+20,D=v+b,G=r,A=G+b,I=A+20,J=v+.7*b,K=l-.7*b,L=x+.7*b;a.shapeArgs={d:["M",x,H,"C",L,H,C,y-.7*b,C,F,"L",C,z,"C",C,J,L,D,x,D,"L",l,D,"C",K,D,k,J,k,z,"L",k,I,"C",k,A-.7*b,K,G,l,G,"L",l,A,"C",u,A,u,A,u,I,"L",u,z,"C",u,v,u,v,l,v,"L",x,v,"C",w,v,w,v,w,z,"L",w,F,"C",w,y,w,y,x,y,"z"]}}a.dlBox= {x:n+(h-n+t)/2,y:m+(r-m)/2,height:b,width:0};a.y=a.plotY=1;a.color||(a.color=e.color)})});a+=q},this)},render:function(){var b=this.points;this.points=this.points.concat(this.nodes);f.seriesTypes.column.prototype.render.call(this);this.points=b},animate:f.Series.prototype.animate,destroy:function(){this.data=[].concat(this.points,this.nodes);f.Series.prototype.destroy.call(this)}},{getClassName:function(){return(this.isNode?"highcharts-node ":"highcharts-link ")+k.prototype.getClassName.call(this)}, isValid:function(){return this.isNode||"number"===typeof this.weight}})})(g)}); //# sourceMappingURL=sankey.js.map