/* Highcharts JS v8.0.2 (2020-03-03) (c) 2016-2019 Highsoft AS Authors: Jon Arild Nygard License: www.highcharts.com/license */ (function(b){"object"===typeof module&&module.exports?(b["default"]=b,module.exports=b):"function"===typeof define&&define.amd?define("highcharts/modules/wordcloud",["highcharts"],function(l){b(l);b.Highcharts=l;return b}):b("undefined"!==typeof Highcharts?Highcharts:void 0)})(function(b){function l(b,e,y,h){b.hasOwnProperty(e)||(b[e]=h.apply(null,y))}b=b?b._modules:{};l(b,"mixins/draw-point.js",[],function(){var b=function(e){var b=this,h=b.graphic,l=e.animatableAttribs,t=e.onComplete,w=e.css,r= e.renderer;if(b.shouldDraw())h||(b.graphic=h=r[e.shapeType](e.shapeArgs).add(e.group)),h.css(w).attr(e.attribs).animate(l,e.isNew?!1:void 0,t);else if(h){var q=function(){b.graphic=h=h.destroy();"function"===typeof t&&t()};Object.keys(l).length?h.animate(l,void 0,function(){q()}):q()}};return function(e){(e.attribs=e.attribs||{})["class"]=this.getClassName();b.call(this,e)}});l(b,"mixins/polygon.js",[b["parts/Globals.js"],b["parts/Utilities.js"]],function(b,e){var l=e.find,h=e.isArray,r=e.isNumber, t=b.deg2rad,w=function(a,c){c=r(c)?c:14;c=Math.pow(10,c);return Math.round(a*c)/c},H=function(a,c){var b=c[0]-a[0];a=c[1]-a[1];return[[-a,b],[a,-b]]},q=function(a,c){a=a.map(function(a){return a[0]*c[0]+a[1]*c[1]});return{min:Math.min.apply(this,a),max:Math.max.apply(this,a)}},E=function(a,c){var b=a[0];a=a[1];var k=t*-c;c=Math.cos(k);k=Math.sin(k);return[w(b*c-a*k),w(b*k+a*c)]},x=function(a,c,b){a=E([a[0]-c[0],a[1]-c[1]],b);return[a[0]+c[0],a[1]+c[1]]},B=function(a){var c=a.axes;if(!h(c)){c=[];var b= b=a.concat([a[0]]);b.reduce(function(a,b){var k=H(a,b)[0];l(c,function(a){return a[0]===k[0]&&a[1]===k[1]})||c.push(k);return b});a.axes=c}return c},F=function(a,c){a=B(a);c=B(c);return a.concat(c)};return{getBoundingBoxFromPolygon:function(a){return a.reduce(function(a,b){var c=b[0];b=b[1];a.left=Math.min(c,a.left);a.right=Math.max(c,a.right);a.bottom=Math.max(b,a.bottom);a.top=Math.min(b,a.top);return a},{left:Number.MAX_VALUE,right:-Number.MAX_VALUE,bottom:-Number.MAX_VALUE,top:Number.MAX_VALUE})}, getPolygon:function(a,b,e,k,h){var c=[a,b],l=a-e/2;a+=e/2;e=b-k/2;b+=k/2;return[[l,e],[a,e],[a,b],[l,b]].map(function(a){return x(a,c,-h)})},isPolygonsColliding:function(a,b){var c=F(a,b);return!l(c,function(c){var e=q(a,c);c=q(b,c);return!!(c.min>e.max||c.maxa.right||f.righta.bottom||f.bottom=g&&("boolean"===typeof c&&d>=b-a&&(c={x:f- (b-d),y:-f}),b-=a,"boolean"===typeof c&&d>=b-a&&(c={x:-f,y:-f+(b-d)}),b-=a,"boolean"===typeof c&&(c=d>=b-a?{x:-f+(b-d),y:f}:{x:f,y:f-(b-d-a)}),c.x*=5,c.y*=5);return c}function w(g,d,f){var a=2*Math.max(Math.abs(f.top),Math.abs(f.bottom));f=2*Math.max(Math.abs(f.left),Math.abs(f.right));return Math.min(0d?g/d:1;g=d>g?d/g:1;return{width:a*f,height:a*g,ratioX:f,ratioY:g}}function q(a,d,f,b){var g=!1;k(a)&&k(d)&&k(f)&&k(b)&&0f&&(g=f+d%a*((b-f)/(a-1||1)));return g}function E(a,d){var g,b=[];for(g=1;1E4>g;g++)b.push(a(g,d));return function(a){return 1E4>=a?b[a-1]:!1}}function x(a,d){var g=d.width/2,b=-(d.height/2),c=d.height/2;return!(-(d.width/2)a.right&&ba.bottom)}function B(g,d){var b=d.placed,c=d.field,e=d.rectangle,k=d.polygon,h=d.spiral,l=1,p={x:0,y:0},n=g.rect=a({},e);g.polygon=k;for(g.rotation=d.rotation;!1!==p&&(r(g,b)||x(n,c));)p=h(l),z(p)&&(n.left=e.left+p.x,n.right=e.right+p.x,n.top=e.top+p.y,n.bottom=e.bottom+p.y,g.polygon=K(p.x,p.y,k)),l++;return p}function F(a,d){if(z(a)&&z(d)){var g=d.bottom-d.top;var b=d.right-d.left;d=a.ratioX;var c=a.ratioY;g=b*d>g*c?b:g;a=I(a,{width:a.width+g*d*2,height:a.height+g*c*2})}return a}var a=e.extend, c=e.find,y=e.isArray,k=e.isNumber,z=e.isObject,I=e.merge;e=e.seriesType;var A=b.noop,J=h.getBoundingBoxFromPolygon,L=h.getPolygon,C=h.isPolygonsColliding,K=h.movePolygon,D=b.Series;e("wordcloud","column",{allowExtendPlayingField:!0,animation:{duration:500},borderWidth:0,clip:!1,colorByPoint:!0,minFontSize:1,maxFontSize:25,placementStrategy:"center",rotation:{from:0,orientations:2,to:90},showInLegend:!1,spiral:"rectangular",style:{fontFamily:"sans-serif",fontWeight:"900",whiteSpace:"nowrap"},tooltip:{followPointer:!0, pointFormat:'\u25cf {series.name}: {point.weight}
'}},{animate:D.prototype.animate,animateDrilldown:A,animateDrillupFrom:A,setClip:A,bindAxes:function(){var g={endOnTick:!1,gridLineWidth:0,lineWidth:0,maxPadding:0,startOnTick:!1,title:null,tickPositions:[]};D.prototype.bindAxes.call(this);a(this.yAxis.options,g);a(this.xAxis.options,g)},pointAttribs:function(a,d){a=b.seriesTypes.column.prototype.pointAttribs.call(this,a,d);delete a.stroke;delete a["stroke-width"]; return a},deriveFontSize:function(a,d,b){a=k(a)?a:0;d=k(d)?d:1;b=k(b)?b:1;return Math.floor(Math.max(b,a*d))},drawPoints:function(){var b=this,d=b.hasRendered,c=b.xAxis,e=b.yAxis,l=b.group,h=b.options,q=h.animation,t=h.allowExtendPlayingField,p=b.chart.renderer,n=p.text().add(l),r=[],x=b.placementStrategy[h.placementStrategy],y=h.rotation,A=b.points.map(function(a){return a.weight}),C=Math.max.apply(null,A),G=b.points.concat().sort(function(a,b){return b.weight-a.weight});b.group.attr({scaleX:1,scaleY:1}); G.forEach(function(d){var c=b.deriveFontSize(1/C*d.weight,h.maxFontSize,h.minFontSize);c=a({fontSize:c+"px"},h.style);n.css(c).attr({x:0,y:0,text:d.name});c=n.getBBox(!0);d.dimensions={height:c.height,width:c.width}});var u=H(c.len,e.len,G);var D=E(b.spirals[h.spiral],{field:u});G.forEach(function(c){var g=b.deriveFontSize(1/C*c.weight,h.maxFontSize,h.minFontSize);g=a({fontSize:g+"px"},h.style);var f=x(c,{data:G,field:u,placed:r,rotation:y}),e=a(b.pointAttribs(c,c.selected&&"select"),{align:"center", "alignment-baseline":"middle",x:f.x,y:f.y,text:c.name,rotation:f.rotation}),n=L(f.x,f.y,c.dimensions.width,c.dimensions.height,f.rotation),m=J(n),v=B(c,{rectangle:m,polygon:n,field:u,placed:r,spiral:D,rotation:f.rotation});!v&&t&&(u=F(u,m),v=B(c,{rectangle:m,polygon:n,field:u,placed:r,spiral:D,rotation:f.rotation}));if(z(v)){e.x+=v.x;e.y+=v.y;m.left+=v.x;m.right+=v.x;m.top+=v.y;m.bottom+=v.y;f=u;if(!k(f.left)||f.left>m.left)f.left=m.left;if(!k(f.right)||f.rightm.top)f.top=m.top;if(!k(f.bottom)||f.bottom=a&&(b={x:d*Math.cos(d),y:d*Math.sin(d)},Math.min(Math.abs(b.x),Math.abs(b.y))