UNPKG

highcharts

Version:
1 lines 93.3 kB
import*as t from"./highcharts.js";var e,i,s,a,o={};o.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return o.d(e,{a:e}),e},o.d=(t,e)=>{for(var i in e)o.o(e,i)&&!o.o(t,i)&&Object.defineProperty(t,i,{enumerable:!0,get:e[i]})},o.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e);let r=t.default;var n=o.n(r);let l=t.default.SeriesRegistry;var h=o.n(l);let p=t.default.Series;var d=o.n(p);let{deg2rad:c}=n(),{fireEvent:u,isNumber:g,pick:f,relativeLength:m}=n();(e=i||(i={})).getCenter=function(){let t=this.options,e=this.chart,i=2*(t.slicedOffset||0),s=e.plotWidth-2*i,a=e.plotHeight-2*i,o=t.center,r=Math.min(s,a),n=t.thickness,l,h=t.size,p=t.innerSize||0,c,b;"string"==typeof h&&(h=parseFloat(h)),"string"==typeof p&&(p=parseFloat(p));let y=[f(o?.[0],"50%"),f(o?.[1],"50%"),f(h&&h<0?void 0:t.size,"100%"),f(p&&p<0?void 0:t.innerSize||0,"0%")];for(!e.angular||this instanceof d()||(y[3]=0),c=0;c<4;++c)b=y[c],l=c<2||2===c&&/%$/.test(b),y[c]=m(b,[s,a,r,y[2]][c])+(l?i:0);return y[3]>y[2]&&(y[3]=y[2]),g(n)&&2*n<y[2]&&n>0&&(y[3]=y[2]-2*n),u(this,"afterGetCenter",{positions:y}),y},e.getStartAndEndRadians=function(t,e){let i=g(t)?t:0,s=g(e)&&e>i&&e-i<360?e:i+360;return{start:c*(i+-90),end:c*(s+-90)}};let b=i,{addEvent:y,correctFloat:x,defined:P,pick:v}=n();function M(t){let e,i=this;return t&&i.pane.forEach(s=>{L(t.chartX-i.plotLeft,t.chartY-i.plotTop,s.center)&&(e=s)}),e}function L(t,e,i,s,a){let o=!0,r=i[0],n=i[1],l=Math.sqrt(Math.pow(t-r,2)+Math.pow(e-n,2));if(P(s)&&P(a)){let i=Math.atan2(x(e-n,8),x(t-r,8));a!==s&&(o=s>a?i>=s&&i<=Math.PI||i<=a&&i>=-Math.PI:i>=s&&i<=x(a,8))}return l<=Math.ceil(i[2]/2)&&o}function k(t){this.polar&&(t.options.inverted&&([t.x,t.y]=[t.y,t.x]),t.isInsidePlot=this.pane.some(e=>L(t.x,t.y,e.center,e.axis&&e.axis.normalizedStartAngleRad,e.axis&&e.axis.normalizedEndAngleRad)))}function w(t){let e=this.chart;t.hoverPoint&&t.hoverPoint.plotX&&t.hoverPoint.plotY&&e.hoverPane&&!L(t.hoverPoint.plotX,t.hoverPoint.plotY,e.hoverPane.center)&&(t.hoverPoint=void 0)}function A(t){let e=this.chart;e.polar?(e.hoverPane=e.getHoverPane(t),t.filter=function(i){return i.visible&&!(!t.shared&&i.directTouch)&&v(i.options.enableMouseTracking,!0)&&(!e.hoverPane||i.xAxis.pane===e.hoverPane)}):e.hoverPane=void 0}let S={pane:{center:["50%","50%"],size:"85%",innerSize:"0%",startAngle:0},background:{shape:"circle",borderRadius:0,borderWidth:1,borderColor:"#cccccc",backgroundColor:{linearGradient:{x1:0,y1:0,x2:0,y2:1},stops:[[0,"#ffffff"],[1,"#e6e6e6"]]},from:-Number.MAX_VALUE,innerRadius:0,to:Number.MAX_VALUE,outerRadius:"105%"}},{extend:N,merge:T,splat:C}=n();class X{constructor(t,e){this.coll="pane",this.init(t,e)}init(t,e){this.chart=e,this.background=[],e.pane.push(this),this.setOptions(t)}setOptions(t){this.options=t=T(S.pane,this.chart.angular?{background:{}}:void 0,t)}render(){let t=this.options,e=this.chart.renderer;this.group||(this.group=e.g("pane-group").attr({zIndex:t.zIndex||0}).add()),this.updateCenter();let i=this.options.background;if(i){let t=Math.max((i=C(i)).length,this.background.length||0);for(let e=0;e<t;e++)i[e]&&this.axis?this.renderBackground(T(S.background,i[e]),e):this.background[e]&&(this.background[e]=this.background[e].destroy(),this.background.splice(e,1))}}renderBackground(t,e){let i={class:"highcharts-pane "+(t.className||"")},s="animate";this.chart.styledMode||N(i,{fill:t.backgroundColor,stroke:t.borderColor,"stroke-width":t.borderWidth}),this.background[e]||(this.background[e]=this.chart.renderer.path().add(this.group),s="attr"),this.background[e][s]({d:this.axis.getPlotBandPath(t.from,t.to,t)}).attr(i)}updateCenter(t){this.center=(t||this.axis||{}).center=b.getCenter.call(this)}update(t,e){T(!0,this.options,t),this.setOptions(this.options),this.render(),this.chart.axes.forEach(function(t){t.pane===this&&(t.pane=null,t.update({},e))},this)}}X.compose=function(t,e){let i=t.prototype;i.getHoverPane||(i.collectionsWithUpdate.push("pane"),i.getHoverPane=M,y(t,"afterIsInsidePlot",k),y(e,"afterGetHoverData",w),y(e,"beforeGetHoverData",A))};let{area:{prototype:{pointClass:Y,pointClass:{prototype:I}}}}=h().seriesTypes,{defined:R,isNumber:E}=n(),z=class extends Y{setState(){let t=this.state,e=this.series,i=e.chart.polar;R(this.plotHigh)||(this.plotHigh=e.yAxis.toPixels(this.high,!0)),R(this.plotLow)||(this.plotLow=this.plotY=e.yAxis.toPixels(this.low,!0)),e.lowerStateMarkerGraphic=e.stateMarkerGraphic,e.stateMarkerGraphic=e.upperStateMarkerGraphic,this.graphic=this.graphics&&this.graphics[1],this.plotY=this.plotHigh,i&&E(this.plotHighX)&&(this.plotX=this.plotHighX),I.setState.apply(this,arguments),this.state=t,this.plotY=this.plotLow,this.graphic=this.graphics&&this.graphics[0],i&&E(this.plotLowX)&&(this.plotX=this.plotLowX),e.upperStateMarkerGraphic=e.stateMarkerGraphic,e.stateMarkerGraphic=e.lowerStateMarkerGraphic,e.lowerStateMarkerGraphic=void 0;let s=e.modifyMarkerSettings();I.setState.apply(this,arguments),e.restoreMarkerSettings(s)}haloPath(){let t=this.series.chart.polar,e=[];return this.plotY=this.plotLow,t&&E(this.plotLowX)&&(this.plotX=this.plotLowX),this.isInside&&(e=I.haloPath.apply(this,arguments)),this.plotY=this.plotHigh,t&&E(this.plotHighX)&&(this.plotX=this.plotHighX),this.isTopInside&&(e=e.concat(I.haloPath.apply(this,arguments))),e}isValid(){return E(this.low)&&E(this.high)}},{noop:D}=n(),{area:O,area:{prototype:B},column:{prototype:W}}=h().seriesTypes,{addEvent:F,defined:H,extend:G,isArray:q,isNumber:V,pick:U,merge:K}=n();class _ extends O{toYData(t){return[t.low,t.high]}highToXY(t){let e=this.chart,i=this.xAxis.postTranslate(t.rectPlotX||0,this.yAxis.len-(t.plotHigh||0));t.plotHighX=i.x-e.plotLeft,t.plotHigh=i.y-e.plotTop,t.plotLowX=t.plotX}getGraphPath(t){let e=[],i=[],s=B.getGraphPath,a=this.options,o=this.chart.polar,r=o&&!1!==a.connectEnds,n=a.connectNulls,l,h,p,d=a.step;for(l=(t=t||this.points).length;l--;){h=t[l];let s=o?{plotX:h.rectPlotX,plotY:h.yBottom,doCurve:!1}:{plotX:h.plotX,plotY:h.plotY,doCurve:!1};h.isNull||r||n||t[l+1]&&!t[l+1].isNull||i.push(s),p={polarPlotY:h.polarPlotY,rectPlotX:h.rectPlotX,yBottom:h.yBottom,plotX:U(h.plotHighX,h.plotX),plotY:h.plotHigh,isNull:h.isNull},i.push(p),e.push(p),h.isNull||r||n||t[l-1]&&!t[l-1].isNull||i.push(s)}let c=s.call(this,t);d&&(!0===d&&(d="left"),a.step=({left:"right",center:"center",right:"left"})[d]);let u=s.call(this,e),g=s.call(this,i);a.step=d;let f=[].concat(c,u);return!this.chart.polar&&g[0]&&"M"===g[0][0]&&(g[0]=["L",g[0][1],g[0][2]]),this.graphPath=f,this.areaPath=c.concat(g),f.isArea=!0,f.xMap=c.xMap,this.areaPath.xMap=c.xMap,f}drawDataLabels(){let t,e,i,s,a,o=this.points,r=o.length,n=[],l=this.options.dataLabels,h=this.chart.inverted;if(l){if(q(l)?(s=l[0]||{enabled:!1},a=l[1]||{enabled:!1}):((s=G({},l)).x=l.xHigh,s.y=l.yHigh,(a=G({},l)).x=l.xLow,a.y=l.yLow),s.enabled||this.hasDataLabels?.()){for(t=r;t--;)if(e=o[t]){let{plotHigh:a=0,plotLow:o=0}=e;i=s.inside?a<o:a>o,e.y=e.high,e._plotY=e.plotY,e.plotY=a,n[t]=e.dataLabel,e.dataLabel=e.dataLabelUpper,e.below=i,h?s.align||(s.align=i?"right":"left"):s.verticalAlign||(s.verticalAlign=i?"top":"bottom")}for(this.options.dataLabels=s,B.drawDataLabels&&B.drawDataLabels.apply(this,arguments),t=r;t--;)(e=o[t])&&(e.dataLabelUpper=e.dataLabel,e.dataLabel=n[t],delete e.dataLabels,e.y=e.low,e.plotY=e._plotY)}if(a.enabled||this.hasDataLabels?.()){for(t=r;t--;)if(e=o[t]){let{plotHigh:t=0,plotLow:s=0}=e;i=a.inside?t<s:t>s,e.below=!i,h?a.align||(a.align=i?"left":"right"):a.verticalAlign||(a.verticalAlign=i?"bottom":"top")}this.options.dataLabels=a,B.drawDataLabels&&B.drawDataLabels.apply(this,arguments)}if(s.enabled)for(t=r;t--;)(e=o[t])&&(e.dataLabels=[e.dataLabelUpper,e.dataLabel].filter(function(t){return!!t}));this.options.dataLabels=l}}alignDataLabel(){W.alignDataLabel.apply(this,arguments)}modifyMarkerSettings(){let t={marker:this.options.marker,symbol:this.symbol};if(this.options.lowMarker){let{options:{marker:t,lowMarker:e}}=this;this.options.marker=K(t,e),e.symbol&&(this.symbol=e.symbol)}return t}restoreMarkerSettings(t){this.options.marker=t.marker,this.symbol=t.symbol}drawPoints(){let t,e,i=this.points.length,s=this.modifyMarkerSettings();for(B.drawPoints.apply(this,arguments),this.restoreMarkerSettings(s),t=0;t<i;)(e=this.points[t]).graphics=e.graphics||[],e.origProps={plotY:e.plotY,plotX:e.plotX,isInside:e.isInside,negative:e.negative,zone:e.zone,y:e.y},(e.graphic||e.graphics[0])&&(e.graphics[0]=e.graphic),e.graphic=e.graphics[1],e.plotY=e.plotHigh,H(e.plotHighX)&&(e.plotX=e.plotHighX),e.y=U(e.high,e.origProps.y),e.negative=e.y<(this.options.threshold||0),this.zones.length&&(e.zone=e.getZone()),this.chart.polar||(e.isInside=e.isTopInside=void 0!==e.plotY&&e.plotY>=0&&e.plotY<=this.yAxis.len&&e.plotX>=0&&e.plotX<=this.xAxis.len),t++;for(B.drawPoints.apply(this,arguments),t=0;t<i;)(e=this.points[t]).graphics=e.graphics||[],(e.graphic||e.graphics[1])&&(e.graphics[1]=e.graphic),e.graphic=e.graphics[0],e.origProps&&(G(e,e.origProps),delete e.origProps),t++}hasMarkerChanged(t,e){let i=t.lowMarker,s=e.lowMarker||{};return i&&(!1===i.enabled||s.symbol!==i.symbol||s.height!==i.height||s.width!==i.width)||super.hasMarkerChanged(t,e)}}_.defaultOptions=K(O.defaultOptions,{lineWidth:1,threshold:null,tooltip:{pointFormat:'<span style="color:{series.color}">●</span> {series.name}: <b>{point.low}</b> - <b>{point.high}</b><br/>'},trackByArea:!0,dataLabels:{align:void 0,verticalAlign:void 0,xLow:0,xHigh:0,yLow:0,yHigh:0}}),F(_,"afterTranslate",function(){"low,high"===this.pointArrayMap.join(",")&&this.points.forEach(t=>{let e=t.high,i=t.plotY;t.isNull?t.plotY=void 0:(t.plotLow=i,t.plotHigh=V(e)?this.yAxis.translate(this.dataModify?this.dataModify.modifyValue(e):e,!1,!0,void 0,!0):void 0,this.dataModify&&(t.yBottom=t.plotHigh))})},{order:0}),F(_,"afterTranslate",function(){this.points.forEach(t=>{if(this.chart.polar)this.highToXY(t),t.plotLow=t.plotY,t.tooltipPos=[((t.plotHighX||0)+(t.plotLowX||0))/2,((t.plotHigh||0)+(t.plotLow||0))/2];else{let e=t.pos(!1,t.plotLow),i=t.pos(!1,t.plotHigh);e&&i&&(e[0]=(e[0]+i[0])/2,e[1]=(e[1]+i[1])/2),t.tooltipPos=e}})},{order:3}),G(_.prototype,{deferTranslatePolar:!0,pointArrayMap:["low","high"],pointClass:z,pointValKey:"low",setStackedPoints:D}),h().registerSeriesType("arearange",_);let Z=_,{spline:{prototype:j}}=h().seriesTypes,{merge:$,extend:Q}=n();class J extends Z{}J.defaultOptions=$(Z.defaultOptions),Q(J.prototype,{getPointSpline:j.getPointSpline}),h().registerSeriesType("areasplinerange",J);let tt=t.default.Series.types.column;var te=o.n(tt);let{noop:ti}=n(),{crisp:ts,extend:ta,merge:to,pick:tr,relativeLength:tn}=n();class tl extends te(){pointAttribs(){return{}}getWhiskerPair(t,e,i,s,a){let o=a.whiskers.strokeWidth(),r=(i,s)=>{let a=tn(i,2*t)/2,r=ts(s,o);return[["M",ts(e-a),r],["L",ts(e+a),r]]};return[...r(i,a.highPlot),...r(s,a.lowPlot)]}translate(){let t=this.yAxis,e=this.pointArrayMap;super.translate.apply(this),this.points.forEach(function(i){e.forEach(function(e){null!==i[e]&&(i[e+"Plot"]=t.translate(i[e],0,1,0,1))}),i.plotHigh=i.highPlot})}drawPoints(){let t,e,i,s,a,o,r,n,l,h,p,d=this.points,c=this.options,u=this.chart,g=u.renderer,f=!1!==this.doQuartiles,m=this.options.whiskerLength;for(let b of d){let d=(n=b.graphic)?"animate":"attr",y=b.shapeArgs,x={},P={},v={},M={},L=b.color||this.color,k=b.options.whiskerLength||m;if(void 0!==b.plotY){let w;l=y.width,p=(h=y.x)+l,t=f?b.q1Plot:b.lowPlot,e=f?b.q3Plot:b.lowPlot,i=b.highPlot,s=b.lowPlot,n||(b.graphic=n=g.g("point").add(this.group),b.stem=g.path().addClass("highcharts-boxplot-stem").add(n),m&&(b.whiskers=g.path().addClass("highcharts-boxplot-whisker").add(n)),f&&(b.box=g.path(r).addClass("highcharts-boxplot-box").add(n)),b.medianShape=g.path(o).addClass("highcharts-boxplot-median").add(n)),u.styledMode||(P.stroke=b.stemColor||c.stemColor||L,P["stroke-width"]=tr(b.stemWidth,c.stemWidth,c.lineWidth),P.dashstyle=b.stemDashStyle||c.stemDashStyle||c.dashStyle,b.stem.attr(P),k&&(v.stroke=b.whiskerColor||c.whiskerColor||L,v["stroke-width"]=tr(b.whiskerWidth,c.whiskerWidth,c.lineWidth),v.dashstyle=b.whiskerDashStyle||c.whiskerDashStyle||c.dashStyle,b.whiskers.attr(v)),f&&(x.fill=b.fillColor||c.fillColor||L,x.stroke=c.lineColor||L,x["stroke-width"]=c.lineWidth||0,x.dashstyle=b.boxDashStyle||c.boxDashStyle||c.dashStyle,b.box.attr(x)),M.stroke=b.medianColor||c.medianColor||L,M["stroke-width"]=tr(b.medianWidth,c.medianWidth,c.lineWidth),M.dashstyle=b.medianDashStyle||c.medianDashStyle||c.dashStyle,b.medianShape.attr(M));let A=ts((b.plotX||0)+(this.pointXOffset||0)+(this.barW||0)/2,b.stem.strokeWidth());if(w=[["M",A,e],["L",A,i],["M",A,t],["L",A,s]],b.stem[d]({d:w}),f){let i=b.box.strokeWidth();t=ts(t,i),e=ts(e,i),w=[["M",h=ts(h,i),e],["L",h,t],["L",p=ts(p,i),t],["L",p,e],["L",h,e],["Z"]],b.box[d]({d:w})}if(k){let t=l/2,e=this.getWhiskerPair(t,A,b.upperWhiskerLength??c.upperWhiskerLength??k,b.lowerWhiskerLength??c.lowerWhiskerLength??k,b);b.whiskers[d]({d:e})}w=[["M",h,a=ts(b.medianPlot,b.medianShape.strokeWidth())],["L",p,a]],b.medianShape[d]({d:w})}}}toYData(t){return[t.low,t.q1,t.median,t.q3,t.high]}}tl.defaultOptions=to(te().defaultOptions,{threshold:null,tooltip:{pointFormat:'<span style="color:{point.color}">●</span> <b>{series.name}</b><br/>Maximum: {point.high}<br/>Upper quartile: {point.q3}<br/>Median: {point.median}<br/>Lower quartile: {point.q1}<br/>Minimum: {point.low}<br/>'},whiskerLength:"50%",fillColor:"#ffffff",lineWidth:1,medianWidth:2,whiskerWidth:2}),ta(tl.prototype,{pointArrayMap:["low","q1","median","q3","high"],pointValKey:"high",drawDataLabels:ti,setStackedPoints:ti}),h().registerSeriesType("boxplot",tl);let th=tl,tp={borderColor:void 0,borderWidth:2,className:void 0,color:void 0,connectorClassName:void 0,connectorColor:void 0,connectorDistance:60,connectorWidth:1,enabled:!1,labels:{className:void 0,allowOverlap:!1,format:"",formatter:void 0,align:"right",style:{fontSize:"0.9em",color:"#000000"},x:0,y:0},maxSize:60,minSize:10,legendIndex:0,ranges:{value:void 0,borderColor:void 0,color:void 0,connectorColor:void 0},sizeBy:"area",sizeByAbsoluteValue:!1,zIndex:1,zThreshold:0},td=t.default.Templating;var tc=o.n(td);let{noop:tu}=n(),{arrayMax:tg,arrayMin:tf,isNumber:tm,merge:tb,pick:ty,stableSort:tx}=n(),tP=class{constructor(t,e){this.setState=tu,this.init(t,e)}init(t,e){this.options=t,this.visible=!0,this.chart=e.chart,this.legend=e}addToLegend(t){t.splice(this.options.legendIndex,0,this)}drawLegendSymbol(t){let e,i=ty(t.options.itemDistance,20),s=this.legendItem||{},a=this.options,o=a.ranges,r=a.connectorDistance;if(!o||!o.length||!tm(o[0].value)){t.options.bubbleLegend.autoRanges=!0;return}tx(o,function(t,e){return e.value-t.value}),this.ranges=o,this.setOptions(),this.render();let n=this.getMaxLabelSize(),l=this.ranges[0].radius,h=2*l;e=(e=r-l+n.width)>0?e:0,this.maxLabel=n,this.movementX="left"===a.labels.align?e:0,s.labelWidth=h+e+i,s.labelHeight=h+n.height/2}setOptions(){let t=this.ranges,e=this.options,i=this.chart.series[e.seriesIndex],s=this.legend.baseline,a={zIndex:e.zIndex,"stroke-width":e.borderWidth},o={zIndex:e.zIndex,"stroke-width":e.connectorWidth},r={align:this.legend.options.rtl||"left"===e.labels.align?"right":"left",zIndex:e.zIndex},n=i.options.marker.fillOpacity,l=this.chart.styledMode;t.forEach(function(h,p){l||(a.stroke=ty(h.borderColor,e.borderColor,i.color),a.fill=h.color||e.color,a.fill||(a.fill=i.color,a["fill-opacity"]=n??1),o.stroke=ty(h.connectorColor,e.connectorColor,i.color)),t[p].radius=this.getRangeRadius(h.value),t[p]=tb(t[p],{center:t[0].radius-t[p].radius+s}),l||tb(!0,t[p],{bubbleAttribs:tb(a),connectorAttribs:tb(o),labelAttribs:r})},this)}getRangeRadius(t){let e=this.options,i=this.options.seriesIndex,s=this.chart.series[i],a=e.ranges[0].value,o=e.ranges[e.ranges.length-1].value,r=e.minSize,n=e.maxSize;return s.getRadius.call(this,o,a,r,n,t)}render(){let t=this.legendItem||{},e=this.chart.renderer,i=this.options.zThreshold;for(let s of(this.symbols||(this.symbols={connectors:[],bubbleItems:[],labels:[]}),t.symbol=e.g("bubble-legend"),t.label=e.g("bubble-legend-item").css(this.legend.itemStyle||{}),t.symbol.translateX=0,t.symbol.translateY=0,t.symbol.add(t.label),t.label.add(t.group),this.ranges))s.value>=i&&this.renderRange(s);this.hideOverlappingLabels()}renderRange(t){let e=this.ranges[0],i=this.legend,s=this.options,a=s.labels,o=this.chart,r=o.series[s.seriesIndex],n=o.renderer,l=this.symbols,h=l.labels,p=t.center,d=Math.abs(t.radius),c=s.connectorDistance||0,u=a.align,g=i.options.rtl,f=s.borderWidth,m=s.connectorWidth,b=e.radius||0,y=p-d-f/2+m/2,x=(y%1?1:.5)-(m%2?0:.5),P=n.styledMode,v=g||"left"===u?-c:c;"center"===u&&(v=0,s.connectorDistance=0,t.labelAttribs.align="center"),l.bubbleItems.push(n.circle(b,p+x,d).attr(P?{}:t.bubbleAttribs).addClass((P?"highcharts-color-"+r.colorIndex+" ":"")+"highcharts-bubble-legend-symbol "+(s.className||"")).add(this.legendItem.symbol)),l.connectors.push(n.path(n.crispLine([["M",b,y],["L",b+v,y]],s.connectorWidth)).attr(P?{}:t.connectorAttribs).addClass((P?"highcharts-color-"+this.options.seriesIndex+" ":"")+"highcharts-bubble-legend-connectors "+(s.connectorClassName||"")).add(this.legendItem.symbol));let M=n.text(this.formatLabel(t)).attr(P?{}:t.labelAttribs).css(P?{}:a.style).addClass("highcharts-bubble-legend-labels "+(s.labels.className||"")).add(this.legendItem.symbol),L={x:b+v+s.labels.x,y:y+s.labels.y+.4*M.getBBox().height};M.attr(L),h.push(M),M.placed=!0,M.alignAttr=L}getMaxLabelSize(){let t,e;return this.symbols.labels.forEach(function(i){e=i.getBBox(!0),t=t?e.width>t.width?e:t:e}),t||{}}formatLabel(t){let e=this.options,i=e.labels.formatter,s=e.labels.format,{numberFormatter:a}=this.chart;return s?tc().format(s,t,this.chart):i?i.call(t):a(t.value,1)}hideOverlappingLabels(){let t=this.chart,e=this.options.labels.allowOverlap,i=this.symbols;!e&&i&&(t.hideOverlappingLabels(i.labels),i.labels.forEach(function(t,e){t.newOpacity?t.newOpacity!==t.oldOpacity&&i.connectors[e].show():i.connectors[e].hide()}))}getRanges(){let t=this.legend.bubbleLegend,e=t.chart.series,i=t.options.ranges,s,a,o=Number.MAX_VALUE,r=-Number.MAX_VALUE;return e.forEach(function(t){t.isBubble&&!t.ignoreSeries&&(a=t.getColumn("z").filter(tm)).length&&(o=ty(t.options.zMin,Math.min(o,Math.max(tf(a),!1===t.options.displayNegative?t.options.zThreshold:-Number.MAX_VALUE))),r=ty(t.options.zMax,Math.max(r,tg(a))))}),s=o===r?[{value:r}]:[{value:o},{value:(o+r)/2},{value:r,autoRanges:!0}],i.length&&i[0].radius&&s.reverse(),s.forEach(function(t,e){i&&i[e]&&(s[e]=tb(i[e],t))}),s}predictBubbleSizes(){let t=this.chart,e=t.legend.options,i=e.floating,s="horizontal"===e.layout,a=s?t.legend.lastLineHeight:0,o=t.plotSizeX,r=t.plotSizeY,n=t.series[this.options.seriesIndex],l=n.getPxExtremes(),h=Math.ceil(l.minPxSize),p=Math.ceil(l.maxPxSize),d=Math.min(r,o),c,u=n.options.maxSize;return i||!/%$/.test(u)?c=p:(c=(d+a)*(u=parseFloat(u))/100/(u/100+1),(s&&r-c>=o||!s&&o-c>=r)&&(c=p)),[h,Math.ceil(c)]}updateRanges(t,e){let i=this.legend.options.bubbleLegend;i.minSize=t,i.maxSize=e,i.ranges=this.getRanges()}correctSizes(){let t=this.legend,e=this.chart.series[this.options.seriesIndex].getPxExtremes();Math.abs(Math.ceil(e.maxPxSize)-this.options.maxSize)>1&&(this.updateRanges(this.options.minSize,e.maxPxSize),t.render())}},{setOptions:tv}=n(),{composed:tM}=n(),{addEvent:tL,objectEach:tk,pushUnique:tw,wrap:tA}=n();function tS(t,e,i){let s,a,o,r=this.legend,n=tN(this)>=0;r&&r.options.enabled&&r.bubbleLegend&&r.options.bubbleLegend.autoRanges&&n?(s=r.bubbleLegend.options,a=r.bubbleLegend.predictBubbleSizes(),r.bubbleLegend.updateRanges(a[0],a[1]),s.placed||(r.group.placed=!1,r.allItems.forEach(t=>{(o=t.legendItem||{}).group&&(o.group.translateY=void 0)})),r.render(),s.placed||(this.getMargins(),this.axes.forEach(t=>{t.setScale(),t.updateNames(),tk(t.ticks,function(t){t.isNew=!0,t.isNewLabel=!0})}),this.getMargins()),s.placed=!0,t.call(this,e,i),r.bubbleLegend.correctSizes(),tY(r,tT(r))):(t.call(this,e,i),r&&r.options.enabled&&r.bubbleLegend&&(r.render(),tY(r,tT(r))))}function tN(t){let e=t.series,i=0;for(;i<e.length;){if(e[i]&&e[i].isBubble&&e[i].visible&&e[i].dataTable.rowCount)return i;i++}return -1}function tT(t){let e=t.allItems,i=[],s=e.length,a,o,r,n=0,l=0;for(n=0;n<s;n++)if(o=e[n].legendItem||{},r=(e[n+1]||{}).legendItem||{},o.labelHeight&&(e[n].itemHeight=o.labelHeight),e[n]===e[s-1]||o.y!==r.y){for(i.push({height:0}),a=i[i.length-1];l<=n;l++)e[l].itemHeight>a.height&&(a.height=e[l].itemHeight);a.step=n}return i}function tC(t){let e=this.bubbleLegend,i=this.options,s=i.bubbleLegend,a=tN(this.chart);e&&e.ranges&&e.ranges.length&&(s.ranges.length&&(s.autoRanges=!!s.ranges[0].autoRanges),this.destroyItem(e)),a>=0&&i.enabled&&s.enabled&&(s.seriesIndex=a,this.bubbleLegend=new tP(s,this),this.bubbleLegend.addToLegend(t.allItems))}function tX(t){let e;if(t.defaultPrevented)return!1;let i=t.legendItem,s=this.chart,a=i.visible;this&&this.bubbleLegend&&(i.visible=!a,i.ignoreSeries=a,e=tN(s)>=0,this.bubbleLegend.visible!==e&&(this.update({bubbleLegend:{enabled:e}}),this.bubbleLegend.visible=e),i.visible=a)}function tY(t,e){let i=t.allItems,s=t.options.rtl,a,o,r,n,l=0;i.forEach((t,i)=>{(n=t.legendItem||{}).group&&(a=n.group.translateX||0,o=n.y||0,((r=t.movementX)||s&&t.ranges)&&(r=s?a-t.options.maxSize/2:a+r,n.group.attr({translateX:r})),i>e[l].step&&l++,n.group.attr({translateY:Math.round(o+e[l].height/2)}),n.y=o+e[l].height/2)})}let tI=function(t,e){tw(tM,"Series.BubbleLegend")&&(tv({legend:{bubbleLegend:tp}}),tA(t.prototype,"drawChartBox",tS),tL(e,"afterGetAllItems",tC),tL(e,"itemClick",tX))},tR=t.default.Point;var tE=o.n(tR);let{seriesTypes:{scatter:{prototype:{pointClass:tz}}}}=h(),{extend:tD}=n();class tO extends tz{haloPath(t){let e=(t&&this.marker&&this.marker.radius||0)+t;if(this.series.chart.inverted){let t=this.pos()||[0,0],{xAxis:i,yAxis:s,chart:a}=this.series;return a.renderer.symbols.circle(i.len-t[1]-e,s.len-t[0]-e,2*e,2*e)}return tE().prototype.haloPath.call(this,e)}}tD(tO.prototype,{ttBelow:!1});let{composed:tB,noop:tW}=n(),{series:tF,seriesTypes:{column:{prototype:tH},scatter:tG}}=h(),{addEvent:tq,arrayMax:tV,arrayMin:tU,clamp:tK,extend:t_,isNumber:tZ,merge:tj,pick:t$,pushUnique:tQ}=n();function tJ(){let t=this.len,{coll:e,isXAxis:i,min:s}=this,a=(this.max||0)-(s||0),o=0,r=t,n=t/a,l;("xAxis"===e||"yAxis"===e)&&(this.series.forEach(t=>{if(t.bubblePadding&&t.reserveSpace()){this.allowZoomOutside=!0,l=!0;let e=t.getColumn(i?"x":"y");if(i&&((t.onPoint||t).getRadii(0,0,t),t.onPoint&&(t.radii=t.onPoint.radii)),a>0){let i=e.length;for(;i--;)if(tZ(e[i])&&this.dataMin<=e[i]&&e[i]<=this.max){let a=t.radii&&t.radii[i]||0;o=Math.min((e[i]-s)*n-a,o),r=Math.max((e[i]-s)*n+a,r)}}}}),l&&a>0&&!this.logarithmic&&(r-=t,n*=(t+Math.max(0,o)-Math.min(r,t))/t,[["min","userMin",o],["max","userMax",r]].forEach(t=>{void 0===t$(this.options[t[0]],this[t[1]])&&(this[t[0]]+=t[2]/n)})))}function t0(){let{ticks:t,tickPositions:e,dataMin:i=0,dataMax:s=0,categories:a}=this,o=this.options.type;if((a?.length||"category"===o)&&this.series.find(t=>t.bubblePadding)){let a=e.length;for(;a--;){let o=t[e[a]],r=o.pos||0;(r>s||r<i)&&o.label?.hide()}}}class t1 extends tG{static compose(t,e,i){tI(e,i),tQ(tB,"Series.Bubble")&&(tq(t,"foundExtremes",tJ),tq(t,"afterRender",t0))}animate(t){!t&&this.points.length<this.options.animationLimit&&this.points.forEach(function(t){let{graphic:e,plotX:i=0,plotY:s=0}=t;e&&e.width&&(this.hasRendered||e.attr({x:i,y:s,width:1,height:1}),e.animate(this.markerAttribs(t),this.options.animation))},this)}getRadii(){let t=this.getColumn("z"),e=this.getColumn("y"),i=[],s,a,o,r=this.chart.bubbleZExtremes,{minPxSize:n,maxPxSize:l}=this.getPxExtremes();if(!r){let t,e=Number.MAX_VALUE,i=-Number.MAX_VALUE;this.chart.series.forEach(s=>{if(s.bubblePadding&&s.reserveSpace()){let a=(s.onPoint||s).getZExtremes();a&&(e=Math.min(t$(e,a.zMin),a.zMin),i=Math.max(t$(i,a.zMax),a.zMax),t=!0)}}),t?(r={zMin:e,zMax:i},this.chart.bubbleZExtremes=r):r={zMin:0,zMax:0}}for(a=0,s=t.length;a<s;a++)o=t[a],i.push(this.getRadius(r.zMin,r.zMax,n,l,o,e&&e[a]));this.radii=i}getRadius(t,e,i,s,a,o){let r=this.options,n="width"!==r.sizeBy,l=r.zThreshold,h=e-t,p=.5;if(null===o||null===a)return null;if(tZ(a)){if(r.sizeByAbsoluteValue&&(a=Math.abs(a-l),e=h=Math.max(e-l,Math.abs(t-l)),t=0),a<t)return i/2-1;h>0&&(p=(a-t)/h)}return n&&p>=0&&(p=Math.sqrt(p)),Math.ceil(i+p*(s-i))/2}hasData(){return!!this.dataTable.rowCount}markerAttribs(t,e){let i=super.markerAttribs(t,e),{height:s=0,width:a=0}=i;return this.chart.inverted?t_(i,{x:(t.plotX||0)-a/2,y:(t.plotY||0)-s/2}):i}pointAttribs(t,e){let i=this.options.marker,s=i?.fillOpacity,a=tF.prototype.pointAttribs.call(this,t,e);return a["fill-opacity"]=s??1,a}translate(){super.translate.call(this),this.getRadii(),this.translateBubble()}translateBubble(){let{data:t,options:e,radii:i}=this,{minPxSize:s}=this.getPxExtremes(),a=t.length;for(;a--;){let o=t[a],r=i?i[a]:0;"z"===this.zoneAxis&&(o.negative=(o.z||0)<(e.zThreshold||0)),tZ(r)&&r>=s/2?(o.marker=t_(o.marker,{radius:r,width:2*r,height:2*r}),o.dlBox={x:o.plotX-r,y:o.plotY-r,width:2*r,height:2*r}):(o.shapeArgs=o.plotY=o.dlBox=void 0,o.isInside=!1)}}getPxExtremes(){let t=Math.min(this.chart.plotWidth,this.chart.plotHeight),e=e=>{let i;return"string"==typeof e&&(i=/%$/.test(e),e=parseInt(e,10)),i?t*e/100:e},i=e(t$(this.options.minSize,8)),s=Math.max(e(t$(this.options.maxSize,"20%")),i);return{minPxSize:i,maxPxSize:s}}getZExtremes(){let t=this.options,e=this.getColumn("z").filter(tZ);if(e.length){let i=t$(t.zMin,tK(tU(e),!1===t.displayNegative?t.zThreshold||0:-Number.MAX_VALUE,Number.MAX_VALUE)),s=t$(t.zMax,tV(e));if(tZ(i)&&tZ(s))return{zMin:i,zMax:s}}}searchKDTree(t,e,i,s=tW,a=tW){return s=(t,e,i)=>{let s=t[i]||0,a=e[i]||0,o,r=!1;return s===a?o=t.index>e.index?t:e:s<0&&a<0?(o=s-(t.marker?.radius||0)>=a-(e.marker?.radius||0)?t:e,r=!0):o=s<a?t:e,[o,r]},a=(t,e,i)=>!i&&t>e||t<e,super.searchKDTree(t,e,i,s,a)}}t1.defaultOptions=tj(tG.defaultOptions,{dataLabels:{formatter:function(){let{numberFormatter:t}=this.series.chart,{z:e}=this.point;return tZ(e)?t(e,-1):""},inside:!0,verticalAlign:"middle"},animationLimit:250,marker:{lineColor:null,lineWidth:1,fillOpacity:.5,radius:null,states:{hover:{radiusPlus:0}},symbol:"circle"},minSize:8,maxSize:"20%",softThreshold:!1,states:{hover:{halo:{size:5}}},tooltip:{pointFormat:"({point.x}, {point.y}), Size: {point.z}"},turboThreshold:0,zThreshold:0,zoneAxis:"z"}),t_(t1.prototype,{alignDataLabel:tH.alignDataLabel,applyZones:tW,bubblePadding:!0,isBubble:!0,keysAffectYAxis:["y"],pointArrayMap:["y","z"],pointClass:tO,parallelArrays:["x","y","z"],trackerGroups:["group","dataLabelsGroup"],specialGroup:"group",zoneAxis:"z"}),tq(t1,"updatedData",t=>{delete t.target.chart.bubbleZExtremes}),tq(t1,"remove",t=>{delete t.target.chart.bubbleZExtremes}),h().registerSeriesType("bubble",t1);let{seriesTypes:{column:{prototype:{pointClass:{prototype:t2}}},arearange:{prototype:{pointClass:t3}}}}=h(),{extend:t5,isNumber:t8}=n();class t6 extends t3{isValid(){return t8(this.low)}}t5(t6.prototype,{setState:t2.setState});let{noop:t9}=n(),{seriesTypes:{arearange:t4,column:t7,column:{prototype:et}}}=h(),{addEvent:ee,clamp:ei,extend:es,isNumber:ea,merge:eo,pick:er}=n();class en extends t4{setOptions(){return eo(!0,arguments[0],{stacking:void 0}),t4.prototype.setOptions.apply(this,arguments)}translate(){return et.translate.apply(this)}pointAttribs(){return et.pointAttribs.apply(this,arguments)}translate3dPoints(){return et.translate3dPoints.apply(this,arguments)}translate3dShapes(){return et.translate3dShapes.apply(this,arguments)}afterColumnTranslate(){let t,e,i,s,a=this.yAxis,o=this.xAxis,r=o.startAngleRad,n=this.chart,l=this.xAxis.isRadial,h=Math.max(n.chartWidth,n.chartHeight)+999;this.points.forEach(p=>{let d=p.shapeArgs||{},c=this.options.minPointLength,u=p.plotY,g=a.translate(p.high,0,1,0,1);if(ea(g)&&ea(u)){if(p.plotHigh=ei(g,-h,h),p.plotLow=ei(u,-h,h),s=p.plotHigh,Math.abs(t=er(p.rectPlotY,p.plotY)-p.plotHigh)<c?(e=c-t,t+=e,s-=e/2):t<0&&(t*=-1,s-=t),l&&this.polar)i=p.barX+r,p.shapeType="arc",p.shapeArgs=this.polar.arc(s+t,s,i,i+p.pointWidth);else{d.height=t,d.y=s;let{x:e=0,width:i=0}=d;p.shapeArgs=eo(p.shapeArgs,this.crispCol(e,s,i,t)),p.tooltipPos=n.inverted?[a.len+a.pos-n.plotLeft-s-t/2,o.len+o.pos-n.plotTop-e-i/2,t]:[o.left-n.plotLeft+e+i/2,a.pos-n.plotTop+s+t/2,t]}}})}}en.defaultOptions=eo(t7.defaultOptions,t4.defaultOptions,{borderRadius:{where:"all"},pointRange:null,legendSymbol:"rectangle",marker:null,states:{hover:{halo:!1}}}),ee(en,"afterColumnTranslate",function(){en.prototype.afterColumnTranslate.apply(this)},{order:5}),es(en.prototype,{directTouch:!0,pointClass:t6,trackerGroups:["group","dataLabelsGroup"],adjustForMissingColumns:et.adjustForMissingColumns,animate:et.animate,crispCol:et.crispCol,drawGraph:t9,drawPoints:et.drawPoints,getSymbol:t9,drawTracker:et.drawTracker,getColumnMetrics:et.getColumnMetrics}),h().registerSeriesType("columnrange",en);let{column:el}=h().seriesTypes,{clamp:eh,merge:ep,pick:ed}=n();class ec extends el{translate(){let t=this.chart,e=this.options,i=this.dense=this.closestPointRange*this.xAxis.transA<2,s=this.borderWidth=ed(e.borderWidth,+!i),a=this.yAxis,o=e.threshold,r=ed(e.minPointLength,5),n=this.getColumnMetrics(),l=n.width,h=this.pointXOffset=n.offset,p=this.translatedThreshold=a.getThreshold(o),d=this.barW=Math.max(l,1+2*s);for(let i of(t.inverted&&(p-=.5),e.pointPadding&&(d=Math.ceil(d)),super.translate(),this.points)){let s=ed(i.yBottom,p),c=999+Math.abs(s),u=eh(i.plotY,-c,a.len+c),g=d/2,f=Math.min(u,s),m=Math.max(u,s)-f,b=i.plotX+h,y,x,P,v,M,L,k,w,A,S,N;e.centerInCategory&&(b=this.adjustForMissingColumns(b,l,i,n)),i.barX=b,i.pointWidth=l,i.tooltipPos=t.inverted?[a.len+a.pos-t.plotLeft-u,this.xAxis.len-b-g,m]:[b+g,u+a.pos-t.plotTop,m],y=o+(i.total||i.y),"percent"===e.stacking&&(y=o+(i.y<0)?-100:100);let T=a.toPixels(y,!0);P=(x=t.plotHeight-T-(t.plotHeight-p))?g*(f-T)/x:0,v=x?g*(f+m-T)/x:0,L=b-P+g,k=b+P+g,w=b+v+g,A=b-v+g,S=f-r,N=f+m,i.y<0&&(S=f,N=f+m+r),t.inverted&&(M=a.width-f,x=T-(a.width-p),P=g*(T-M)/x,v=g*(T-(M-m))/x,k=(L=b+g+P)-2*P,w=b-v+g,A=b+v+g,S=f,N=f+m-r,i.y<0&&(N=f+m+r)),i.shapeType="path",i.shapeArgs={x:L,y:S,width:k-L,height:m,d:[["M",L,S],["L",k,S],["L",w,N],["L",A,N],["Z"]]}}}}ec.defaultOptions=ep(el.defaultOptions,{}),h().registerSeriesType("columnpyramid",ec);let{arearange:eu}=h().seriesTypes,{addEvent:eg,merge:ef,extend:em}=n();class eb extends th{getColumnMetrics(){return this.linkedParent&&this.linkedParent.columnMetrics||te().prototype.getColumnMetrics.call(this)}drawDataLabels(){let t=this.pointValKey;if(eu)for(let e of(eu.prototype.drawDataLabels.call(this),this.points))e.y=e[t]}toYData(t){return[t.low,t.high]}}eb.defaultOptions=ef(th.defaultOptions,{color:"#000000",grouping:!1,linkedTo:":previous",tooltip:{pointFormat:'<span style="color:{point.color}">●</span> {series.name}: <b>{point.low}</b> - <b>{point.high}</b><br/>'},whiskerWidth:null}),eg(eb,"afterTranslate",function(){for(let t of this.points)t.plotLow=t.plotY},{order:0}),em(eb.prototype,{pointArrayMap:["low","high"],pointValKey:"high",doQuartiles:!1}),h().registerSeriesType("errorbar",eb);let{series:{prototype:{pointClass:ey}}}=h(),{noop:ex}=n(),{series:eP,seriesTypes:{column:ev}}=h(),{clamp:eM,isNumber:eL,extend:ek,merge:ew,pick:eA,pInt:eS,defined:eN}=n();class eT extends eP{translate(){let t=this.yAxis,e=this.options,i=t.center;this.generatePoints(),this.points.forEach(s=>{let a=ew(e.dial,s.dial),o=eS(a.radius)*i[2]/200,r=eS(a.baseLength)*o/100,n=eS(a.rearLength)*o/100,l=a.baseWidth,h=a.topWidth,p=e.overshoot,d=t.startAngleRad+t.translate(s.y,void 0,void 0,void 0,!0);(eL(p)||!1===e.wrap)&&(p=eL(p)?p/180*Math.PI:0,d=eM(d,t.startAngleRad-p,t.endAngleRad+p)),d=180*d/Math.PI,s.shapeType="path",s.shapeArgs={d:a.path||[["M",-n,-l/2],["L",r,-l/2],["L",o,-h/2],["L",o,h/2],["L",r,l/2],["L",-n,l/2],["Z"]],translateX:i[0],translateY:i[1],rotation:d},s.plotX=i[0],s.plotY=i[1],eN(s.y)&&t.max-t.min&&(s.percentage=(s.y-t.min)/(t.max-t.min)*100)})}drawPoints(){let t=this,e=t.chart,i=t.yAxis.center,s=t.pivot,a=t.options,o=a.pivot,r=e.renderer;t.points.forEach(i=>{let s=i.graphic,o=i.shapeArgs,n=o.d,l=ew(a.dial,i.dial);s?(s.animate(o),o.d=n):i.graphic=r[i.shapeType](o).addClass("highcharts-dial").add(t.group),e.styledMode||i.graphic[s?"animate":"attr"]({stroke:l.borderColor,"stroke-width":l.borderWidth,fill:l.backgroundColor})}),s?s.animate({translateX:i[0],translateY:i[1]}):o&&(t.pivot=r.circle(0,0,o.radius).attr({zIndex:2}).addClass("highcharts-pivot").translate(i[0],i[1]).add(t.group),e.styledMode||t.pivot.attr({fill:o.backgroundColor,stroke:o.borderColor,"stroke-width":o.borderWidth}))}animate(t){let e=this;t||e.points.forEach(t=>{let i=t.graphic;i&&(i.attr({rotation:180*e.yAxis.startAngleRad/Math.PI}),i.animate({rotation:t.shapeArgs.rotation},e.options.animation))})}render(){this.group=this.plotGroup("group","series",this.visible?"inherit":"hidden",this.options.zIndex,this.chart.seriesGroup),eP.prototype.render.call(this),this.group.clip(this.chart.clipRect)}setData(t,e){eP.prototype.setData.call(this,t,!1),this.processData(),this.generatePoints(),eA(e,!0)&&this.chart.redraw()}hasData(){return!!this.points.length}}eT.defaultOptions=ew(eP.defaultOptions,{dataLabels:{borderColor:"#cccccc",borderRadius:3,borderWidth:1,crop:!1,defer:!1,enabled:!0,verticalAlign:"top",y:15,zIndex:2},dial:{backgroundColor:"#000000",baseLength:"70%",baseWidth:3,borderColor:"#cccccc",borderWidth:0,radius:"80%",rearLength:"10%",topWidth:1},pivot:{radius:5,borderWidth:0,borderColor:"#cccccc",backgroundColor:"#000000"},tooltip:{headerFormat:""},showInLegend:!1}),ek(eT.prototype,{angular:!0,directTouch:!0,drawGraph:ex,drawTracker:ev.prototype.drawTracker,fixedBox:!0,forceDL:!0,noSharedTooltip:!0,pointClass:class extends ey{setState(t){this.state=t}},trackerGroups:["group","dataLabelsGroup"]}),h().registerSeriesType("gauge",eT);let eC=t.default.Color;var eX=o.n(eC);let{composed:eY}=n(),{addEvent:eI,pushUnique:eR}=n();function eE(){let t,e,i,s,a=this;a.container&&(t=eI(a.container,"mousedown",t=>{e&&e(),i&&i(),(s=a.hoverPoint)&&s.series&&s.series.hasDraggableNodes&&s.series.options.draggable&&(s.series.onMouseDown(s,t),e=eI(a.container,"mousemove",t=>s&&s.series&&s.series.onMouseMove(s,t)),i=eI(a.container.ownerDocument,"mouseup",t=>(e(),i(),s&&s.series&&s.series.onMouseUp(s,t))))})),eI(a,"destroy",function(){t()})}let ez={compose:function(t){eR(eY,"DragNodes")&&eI(t,"load",eE)},onMouseDown:function(t,e){let i=this.chart.pointer?.normalize(e)||e;t.fixedPosition={chartX:i.chartX,chartY:i.chartY,plotX:t.plotX,plotY:t.plotY},t.inDragMode=!0},onMouseMove:function(t,e){if(t.fixedPosition&&t.inDragMode){let i,s,a=this.chart,o=a.pointer?.normalize(e)||e,r=t.fixedPosition.chartX-o.chartX,n=t.fixedPosition.chartY-o.chartY,l=a.graphLayoutsLookup;(Math.abs(r)>5||Math.abs(n)>5)&&(i=t.fixedPosition.plotX-r,s=t.fixedPosition.plotY-n,a.isInsidePlot(i,s)&&(t.plotX=i,t.plotY=s,t.hasDragged=!0,this.redrawHalo(t),l.forEach(t=>{t.restartSimulation()})))}},onMouseUp:function(t){t.fixedPosition&&(t.hasDragged&&(this.layout.enableSimulation?this.layout.start():this.chart.redraw()),t.inDragMode=t.hasDragged=!1,this.options.fixedDraggable||delete t.fixedPosition)},redrawHalo:function(t){t&&this.halo&&this.halo.attr({d:t.haloPath(this.options.states.hover.halo.size)})}},{setAnimation:eD}=n(),{composed:eO}=n(),{addEvent:eB,pushUnique:eW}=n();function eF(){this.graphLayoutsLookup&&(this.graphLayoutsLookup.forEach(t=>{t.updateSimulation()}),this.redraw())}function eH(){this.graphLayoutsLookup&&(this.graphLayoutsLookup.forEach(t=>{t.updateSimulation(!1)}),this.redraw())}function eG(){this.graphLayoutsLookup&&this.graphLayoutsLookup.forEach(t=>{t.stop()})}function eq(){let t,e=!1,i=i=>{i.maxIterations--&&isFinite(i.temperature)&&!i.isStable()&&!i.enableSimulation&&(i.beforeStep&&i.beforeStep(),i.step(),t=!1,e=!0)};if(this.graphLayoutsLookup){for(eD(!1,this),this.graphLayoutsLookup.forEach(t=>t.start());!t;)t=!0,this.graphLayoutsLookup.forEach(i);e&&this.series.forEach(t=>{t&&t.layout&&t.render()})}}let eV={compose:function(t){eW(eO,"GraphLayout")&&(eB(t,"afterPrint",eF),eB(t,"beforePrint",eH),eB(t,"predraw",eG),eB(t,"render",eq))},integrations:{},layouts:{}},eU=t.default.Chart;var eK=o.n(eU);let{seriesTypes:{bubble:{prototype:{pointClass:e_}}}}=h(),eZ=class extends e_{destroy(){return this.series?.layout&&this.series.layout.removeElementFromCollection(this,this.series.layout.nodes),tE().prototype.destroy.apply(this,arguments)}firePointEvent(){let t=this.series.options;if(this.isParentNode&&t.parentNode){let e=t.allowPointSelect;t.allowPointSelect=t.parentNode.allowPointSelect,tE().prototype.firePointEvent.apply(this,arguments),t.allowPointSelect=e}else tE().prototype.firePointEvent.apply(this,arguments)}select(){let t=this.series.chart;this.isParentNode?(t.getSelectedPoints=t.getSelectedParentNodes,tE().prototype.select.apply(this,arguments),t.getSelectedPoints=eK().prototype.getSelectedPoints):tE().prototype.select.apply(this,arguments)}},{isNumber:ej}=n(),e$={attractive:function(t,e,i){let s=t.getMass(),a=-i.x*e*this.diffTemperature,o=-i.y*e*this.diffTemperature;t.fromNode.fixedPosition||(t.fromNode.plotX-=a*s.fromNode/t.fromNode.degree,t.fromNode.plotY-=o*s.fromNode/t.fromNode.degree),t.toNode.fixedPosition||(t.toNode.plotX+=a*s.toNode/t.toNode.degree,t.toNode.plotY+=o*s.toNode/t.toNode.degree)},attractiveForceFunction:function(t,e){return(e-t)/t},barycenter:function(){let t=this.options.gravitationalConstant||0,e=(this.barycenter.xFactor-(this.box.left+this.box.width)/2)*t,i=(this.barycenter.yFactor-(this.box.top+this.box.height)/2)*t;this.nodes.forEach(function(t){t.fixedPosition||(t.plotX-=e/t.mass/t.degree,t.plotY-=i/t.mass/t.degree)})},getK:function(t){return Math.pow(t.box.width*t.box.height/t.nodes.length,.5)},integrate:function(t,e){let i=-t.options.friction,s=t.options.maxSpeed,a=e.prevX,o=e.prevY,r=(e.plotX+e.dispX-a)*i,n=(e.plotY+e.dispY-o)*i,l=Math.abs,h=l(r)/(r||1),p=l(n)/(n||1),d=h*Math.min(s,Math.abs(r)),c=p*Math.min(s,Math.abs(n));e.prevX=e.plotX+e.dispX,e.prevY=e.plotY+e.dispY,e.plotX+=d,e.plotY+=c,e.temperature=t.vectorLength({x:d,y:c})},repulsive:function(t,e,i){let s=e*this.diffTemperature/t.mass/t.degree;t.fixedPosition||(t.plotX+=i.x*s,t.plotY+=i.y*s)},repulsiveForceFunction:function(t,e){return(e-t)/t*+(e>t)}},{noop:eQ}=n(),eJ={barycenter:function(){let t,e,i=this.options.gravitationalConstant||0,s=this.box,a=this.nodes,o=Math.sqrt(a.length);for(let r of a)if(!r.fixedPosition){let a=r.mass*o,n=r.plotX||0,l=r.plotY||0,h=r.series,p=h.parentNode;this.resolveSplitSeries(r)&&p&&!r.isParentNode?(t=p.plotX||0,e=p.plotY||0):(t=s.width/2,e=s.height/2),r.plotX=n-(n-t)*i/a,r.plotY=l-(l-e)*i/a,h.chart.hoverPoint===r&&h.redrawHalo&&h.halo&&h.redrawHalo(r)}},getK:eQ,integrate:e$.integrate,repulsive:function(t,e,i,s){let a=e*this.diffTemperature/t.mass/t.degree,o=i.x*a,r=i.y*a;t.fixedPosition||(t.plotX+=o,t.plotY+=r),s.fixedPosition||(s.plotX-=o,s.plotY-=r)},repulsiveForceFunction:function(t,e,i,s){return Math.min(t,(i.marker.radius+s.marker.radius)/2)}},e0={attractive:function(t,e,i,s){let a=t.getMass(),o=i.x/s*e,r=i.y/s*e;t.fromNode.fixedPosition||(t.fromNode.dispX-=o*a.fromNode/t.fromNode.degree,t.fromNode.dispY-=r*a.fromNode/t.fromNode.degree),t.toNode.fixedPosition||(t.toNode.dispX+=o*a.toNode/t.toNode.degree,t.toNode.dispY+=r*a.toNode/t.toNode.degree)},attractiveForceFunction:function(t,e){return t*t/e},barycenter:function(){let t=this.options.gravitationalConstant,e=this.barycenter.xFactor,i=this.barycenter.yFactor;this.nodes.forEach(function(s){if(!s.fixedPosition){let a=s.getDegree(),o=a*(1+a/2);s.dispX+=(e-s.plotX)*t*o/s.degree,s.dispY+=(i-s.plotY)*t*o/s.degree}})},getK:function(t){return Math.pow(t.box.width*t.box.height/t.nodes.length,.3)},integrate:function(t,e){e.dispX+=e.dispX*t.options.friction,e.dispY+=e.dispY*t.options.friction;let i=e.temperature=t.vectorLength({x:e.dispX,y:e.dispY});0!==i&&(e.plotX+=e.dispX/i*Math.min(Math.abs(e.dispX),t.temperature),e.plotY+=e.dispY/i*Math.min(Math.abs(e.dispY),t.temperature))},repulsive:function(t,e,i,s){t.dispX+=i.x/s*e/t.degree,t.dispY+=i.y/s*e/t.degree},repulsiveForceFunction:function(t,e){return e*e/t}};class e1{constructor(t){this.body=!1,this.isEmpty=!1,this.isInternal=!1,this.nodes=[],this.box=t,this.boxSize=Math.min(t.width,t.height)}divideBox(){let t=this.box.width/2,e=this.box.height/2;this.nodes[0]=new e1({left:this.box.left,top:this.box.top,width:t,height:e}),this.nodes[1]=new e1({left:this.box.left+t,top:this.box.top,width:t,height:e}),this.nodes[2]=new e1({left:this.box.left+t,top:this.box.top+e,width:t,height:e}),this.nodes[3]=new e1({left:this.box.left,top:this.box.top+e,width:t,height:e})}getBoxPosition(t){let e=t.plotX<this.box.left+this.box.width/2,i=t.plotY<this.box.top+this.box.height/2;return e?3*!i:i?1:2}insert(t,e){let i;this.isInternal?this.nodes[this.getBoxPosition(t)].insert(t,e-1):(this.isEmpty=!1,this.body?e?(this.isInternal=!0,this.divideBox(),!0!==this.body&&(this.nodes[this.getBoxPosition(this.body)].insert(this.body,e-1),this.body=!0),this.nodes[this.getBoxPosition(t)].insert(t,e-1)):((i=new e1({top:t.plotX||NaN,left:t.plotY||NaN,width:.1,height:.1})).body=t,i.isInternal=!1,this.nodes.push(i)):(this.isInternal=!1,this.body=t))}updateMassAndCenter(){let t=0,e=0,i=0;if(this.isInternal){for(let s of this.nodes)s.isEmpty||(t+=s.mass,e+=s.plotX*s.mass,i+=s.plotY*s.mass);e/=t,i/=t}else this.body&&(t=this.body.mass,e=this.body.plotX,i=this.body.plotY);this.mass=t,this.plotX=e,this.plotY=i}}let e2=class{constructor(t,e,i,s){this.box={left:t,top:e,width:i,height:s},this.maxDepth=25,this.root=new e1(this.box),this.root.isInternal=!0,this.root.isRoot=!0,this.root.divideBox()}calculateMassAndCenter(){this.visitNodeRecursive(null,null,function(t){t.updateMassAndCenter()})}insertNodes(t){for(let e of t)this.root.insert(e,this.maxDepth)}visitNodeRecursive(t,e,i){let s;if(t||(t=this.root),t===this.root&&e&&(s=e(t)),!1!==s){for(let a of t.nodes){if(a.isInternal){if(e&&(s=e(a)),!1===s)continue;this.visitNodeRecursive(a,e,i)}else a.body&&e&&e(a.body);i&&i(a)}t===this.root&&i&&i(t)}}},{win:e3}=n(),{clamp:e5,defined:e8,isFunction:e6,fireEvent:e9,pick:e4}=n();class e7{constructor(){this.box={},this.currentStep=0,this.initialRendering=!0,this.links=[],this.nodes=[],this.series=[],this.simulation=!1}static compose(t){eV.compose(t),eV.integrations.euler=e0,eV.integrations.verlet=e$,eV.layouts["reingold-fruchterman"]=e7}init(t){this.options=t,this.nodes=[],this.links=[],this.series=[],this.box={x:0,y:0,width:0,height:0},this.setInitialRendering(!0),this.integration=eV.integrations[t.integration],this.enableSimulation=t.enableSimulation,this.attractiveForce=e4(t.attractiveForce,this.integration.attractiveForceFunction),this.repulsiveForce=e4(t.repulsiveForce,this.integration.repulsiveForceFunction),this.approximation=t.approximation}updateSimulation(t){this.enableSimulation=e4(t,this.options.enableSimulation)}start(){let t=this.series,e=this.options;this.currentStep=0,this.forces=t[0]&&t[0].forces||[],this.chart=t[0]&&t[0].chart,this.initialRendering&&(this.initPositions(),t.forEach(function(t){t.finishedAnimating=!0,t.render()})),this.setK(),this.resetSimulation(e),this.enableSimulation&&this.step()}step(){let t=this.series;for(let t of(this.currentStep++,"barnes-hut"===this.approximation&&(this.createQuadTree(),this.quadTree.calculateMassAndCenter()),this.forces||[]))this[t+"Forces"](this.temperature);if(this.applyLimits(),this.temperature=this.coolDown(this.startTemperature,this.diffTemperature,this.currentStep),this.prevSystemTemperature=this.systemTemperature,this.systemTemperature=this.getSystemTemperature(),this.enableSimulation){for(let e of t)e.chart&&e.render();this.maxIterations--&&isFinite(this.temperature)&&!this.isStable()?(this.simulation&&e3.cancelAnimationFrame(this.simulation),this.simulation=e3.requestAnimationFrame(()=>this.step())):(this.simulation=!1,this.series.forEach(t=>{e9(t,"afterSimulation")}))}}stop(){this.simulation&&e3.cancelAnimationFrame(this.simulation)}setArea(t,e,i,s){this.box={left:t,top:e,width:i,height:s}}setK(){this.k=this.options.linkLength||this.integration.getK(this)}addElementsToCollection(t,e){for(let i of t)-1===e.indexOf(i)&&e.push(i)}removeElementFromCollection(t,e){let i=e.indexOf(t);-1!==i&&e.splice(i,1)}clear(){this.nodes.length=0,this.links.length=0,this.series.length=0,this.resetSimulation()}resetSimulation(){this.forcedStop=!1,this.systemTemperature=0,this.setMaxIterations(),this.setTemperature(),this.setDiffTemperature()}restartSimulation(){this.simulation?this.resetSimulation():(this.setInitialRendering(!1),this.enableSimulation?this.start():this.setMaxIterations(1),this.chart&&this.chart.redraw(),this.setInitialRendering(!0))}setMaxIterations(t){this.maxIterations=e4(t,this.options.maxIterations)}setTemperature(){this.temperature=this.startTemperature=Math.sqrt(this.nodes.length)}setDiffTemperature(){this.diffTemperature=this.startTemperature/(this.options.maxIterations+1)}setInitialRendering(t){this.initialRendering=t}createQuadTree(){this.quadTree=new e2(this.box.left,this.box.top,this.box.width,this.box.height),this.quadTree.insertNodes(this.nodes)}initPositions(){let t=this.options.initialPositions;if(e6(t))for(let e of(t.call(this),this.nodes))e8(e.prevX)||(e.prevX=e.plotX),e8(e.prevY)||(e.prevY=e.plotY),e.dispX=0,e.dispY=0;else"circle"===t?this.setCircularPositions():this.setRandomPositions()}setCircularPositions(){let t,e=this.box,i=this.nodes,s=2*Math.PI/(i.length+1),a=i.filter(function(t){return 0===t.linksTo.length}),o={},r=this.options.initialPositionRadius,n=t=>{for(let e of t.linksFrom||[])o[e.toNode.id]||(o[e.toNode.id]=!0,l.push(e.toNode),n(e.toNode))},l=[];for(let t of a)l.push(t),n(t);if(l.length)for(let t of i)-1===l.indexOf(t)&&l.push(t);else l=i;for(let i=0,a=l.length;i<a;++i)(t=l[i]).plotX=t.prevX=e4(t.plotX,e.width/2+r*Math.cos(i*s)),t.plotY=t.prevY=e4(t.plotY,e.height/2+r*Math.sin(i*s)),t.dispX=0,t.dispY=0}setRandomPositions(){let t,e=this.box,i=this.nodes,s=i.length+1,a=t=>{let e=t*t/Math.PI;return e-Math.floor(e)};for(let o=0,r=i.length;o<r;++o)(t=i[o]).plotX=t.prevX=e4(t.plotX,e.width*a(o)),t.plotY=t.prevY=e4(t.plotY,e.height*a(s+o)),t.dispX=0,t.dispY=0}force(t,...e){this.integration[t].apply(this,e)}barycenterForces(){this.getBarycenter(),this.force("barycenter")}getBarycenter(){let t=0,e=0,i=0;for(let s of this.nodes)e+=s.plotX*s.mass,i+=s.plotY*s.mass,t+=s.mass;return this.barycenter={x:e,y:i,xFactor:e/t,yFactor:i/t},this.barycenter}barnesHutApproximation(t,e){let i,s,a=this.getDistXY(t,e),o=this.vectorLength(a);return t!==e&&0!==o&&(e.isInternal?e.boxSize/o<this.options.theta&&0!==o?(s=this.repulsiveForce(o,this.k),this.force("repulsive",t,s*e.mass,a,o),i=!1):i=!0:(s=this.repulsiveForce(o,this.k),this.force("repulsive",t,s*e.mass,a,o))),i}repulsiveForces(){if("barnes-hut"===this.approximation)for(let t of this.nodes)this.quadTree.visitNodeRecursive(null,e=>this.barnesHutApproximation(t,e));else{let t,e,i;for(let s of this.nodes)for(let a of this.nodes)s===a||s.fixedPosition||(i=this.getDistXY(s,a),0!==(e=this.vectorLength(i))&&(t=this.repulsiveForce(e,this.k),this.force("repulsive",s,t*a.mass,i,e)))}}attractiveForces(){let t,e,i;for(let s of this.links)s.fromNode&&s.toNode&&(t=this.getDistXY(s.fromNode,s.toNode),0!==(e=this.vectorLength(t))&&(i=this.attractiveForce(e,this.k),this.force("attractive",s,i,t,e)))}applyLimits(){for(let t of this.nodes)!t.fixedPosition&&(this.integration.integrate(this,t),this.applyLimitBox(t,this.box),t.dispX=0,t.dispY=0)}applyLimitBox(t,e){let i=t.radius;t.plotX=e5(t.plotX,e.left+i,e.width-i),t.plotY=e5(t.plotY,e.top+i,e.height-i)}coolDown(t,e,i){return t-e*i}isStable(){return 1e-5>Math.abs(this.systemTemperature-this.prevSystemTemperature)||this.temperature<=0}getSystemTemperature(){let t=0;for(let e of this.nodes)t+=e.temperature;return t}vectorLength(t){return Math.sqrt(t.x*t.x+t.y*t.y)}getDistR(t,e){let i=this.getDistXY(t,e);return this.vectorLength(i)}getDistXY(t,e){let i=t.plotX-e.plotX,s=t.plotY-e.plotY;return{x:i,y:s,absX:Math.abs(i),absY:Math.abs(s)}}}let it=e7,{addEvent:ie,defined:ii,pick:is}=n();function ia(){let t=this.series,e=[];return t.forEach(t=>{t.parentNode&&t.parentNode.selected&&e.push(t.parentNode)}),e}function io(){this.allDataPoints&&delete this.allDataPoints}class ir extends it{constructor(){super(...arguments),this.index=NaN,this.nodes=[],this.series=[]}static compose(t){it.compose(t),eV.integrations.packedbubble=eJ,eV.layouts.packedbubble=ir;let e=t.prototype;e.getSelectedParentNodes||(ie(t,"beforeRedraw",io),e.getSelectedParentNodes=ia),e.allParentNodes||(e.allParentNodes=[])}beforeStep(){this.options.marker&&this.series.forEach(t=>{t&&t.calculateParentRadius()})}isStable(){let t=Math.abs(this.prevSystemTemperature-this.systemTemperature);return 1>Math.abs(10*this.systemTemperature/Math.sqrt(this.nodes.length))&&t<1e-5||this.temperature<=0}setCircularPositions(){let t=this.box,e=[...this.nodes,...this?.chart?.allParentNodes||[]],i=2*Math.PI/(e.length+1),s=this.options.initialPositionRadius,a,o,r=0;for(let n of e)this.resolveSplitSeries(n)&&!n.isParentNode?(a=n.series.parentNode.plotX,o=n.series.parentNode.plotY):(a=t.width/2,o=t.height/2),n.plotX=n.prevX=is(n.plotX,a+s*Math.cos(n.index||r*i)),n.plotY=n.prevY=is(n.plotY,o+s*Math.sin(n.index||r*i)),n.dispX=0,n.dispY=0,r++}repulsiveForces(){let{options:t,k:e}=this,{bubblePadding:i=0,seriesInteraction:s}=t,a=[...this.nodes,...this?.chart?.allParentNodes||[]];for(let t of a){let o=t.series,r=t.fixedPosition,n=(t.marker?.radius||0)+i;for(let i of(t.degree=t.mass,t.neighbours=0,a)){let a=i.series;if(t!==i&&!r&&(s||o===a)&&!(o===a&&(i.isParentNode||t.isParentNode))){let s,a=this.getDistXY(t,i),o=this.vectorLength(a)-(n+(i.marker?.radius||0));o<0&&(t.degree+=.01,s=this.repulsiveForce(-o/Math.sqrt(++t.neighbours),e,t,i)*i.mass),this.force("repulsive",t,s||0,a,i,o)}}}}resolveSplitSeries(t){let e=t.series?.options?.lay