!/**
 * Highcharts JS v12.6.0 (2026-04-13)
 * @module highcharts/modules/annotations
 * @requires highcharts
 *
 * Annotations module
 *
 * (c) 2009-2026 Highsoft AS
 * Author: Torstein Hønsi
 *
 * A commercial license may be required depending on use.
 * See www.highcharts.com/license
 */function(t,i){"object"==typeof exports&&"object"==typeof module?module.exports=i(t._Highcharts,t._Highcharts.SeriesRegistry,t._Highcharts.Templating,t._Highcharts.AST,t._Highcharts.Color):"function"==typeof define&&define.amd?define("highcharts/modules/annotations",["highcharts/highcharts"],function(t){return i(t,t.SeriesRegistry,t.Templating,t.AST,t.Color)}):"object"==typeof exports?exports["highcharts/modules/annotations"]=i(t._Highcharts,t._Highcharts.SeriesRegistry,t._Highcharts.Templating,t._Highcharts.AST,t._Highcharts.Color):t.Highcharts=i(t.Highcharts,t.Highcharts.SeriesRegistry,t.Highcharts.Templating,t.Highcharts.AST,t.Highcharts.Color)}("u"<typeof window?this:window,(t,i,e,s,o)=>(()=>{"use strict";var n,a,r,h,l,c={512:t=>{t.exports=i},620:t=>{t.exports=o},660:t=>{t.exports=s},944:i=>{i.exports=t},984:t=>{t.exports=e}},p={};function d(t){var i=p[t];if(void 0!==i)return i.exports;var e=p[t]={exports:{}};return c[t](e,e.exports,d),e.exports}d.n=t=>{var i=t&&t.__esModule?()=>t.default:()=>t;return d.d(i,{a:i}),i},d.d=(t,i)=>{for(var e in i)d.o(i,e)&&!d.o(t,e)&&Object.defineProperty(t,e,{enumerable:!0,get:i[e]})},d.o=(t,i)=>Object.prototype.hasOwnProperty.call(t,i);var u={};d.d(u,{default:()=>iA});var g=d(944),f=d.n(g);let{doc:y,win:m}=f();function v(t,i,e,s={}){let o="function"==typeof t&&t.prototype||t;Object.hasOwnProperty.call(o,"hcEvents")||(o.hcEvents={});let n=o.hcEvents;f().Point&&t instanceof f().Point&&t.series&&t.series.chart&&(t.series.chart.runTrackerClick=!0);let a=t.addEventListener;a&&a.call(t,i,e,!!f().supportsPassiveEvents&&{passive:void 0===s.passive?-1!==i.indexOf("touch"):s.passive,capture:!1}),n[i]||(n[i]=[]);let r={fn:e,order:"number"==typeof s.order?s.order:1/0};return n[i].push(r),n[i].sort((t,i)=>t.order-i.order),function(){D(t,i,e)}}function x(t,i,e,s,o){var n,a,r;let h=y.createElement(t);return i&&k(h,i),o&&(n={padding:"0",border:"none",margin:"0"},k(h.style,n)),e&&(a=h,r=e,k(a.style,r)),s&&s.appendChild(h),h}function b(t){return null!=t}function A(t,i){let e=t.length;for(;e--;)if(t[e]===i){t.splice(e,1);break}}function k(t,i){let e;for(e in t||(t={}),i)t[e]=i[e];return t}function w(t,i,e,s){if(e=e||{},y?.createEvent&&(t.dispatchEvent||t.fireEvent&&t!==f())){let s=y.createEvent("Events");s.initEvent(i,!0,!0),e=k(s,e),t.dispatchEvent?t.dispatchEvent(e):t.fireEvent(i,e)}else if(t.hcEvents){e.target||k(e,{preventDefault:function(){e.defaultPrevented=!0},target:t,type:i});let s=[],o=t,n=!1;for(;o.hcEvents;)Object.hasOwnProperty.call(o,"hcEvents")&&o.hcEvents[i]&&(s.length&&(n=!0),s.unshift.apply(s,o.hcEvents[i])),o=Object.getPrototypeOf(o);n&&s.sort((t,i)=>t.order-i.order),s.forEach(i=>{!1===i.fn.call(t,e,t)&&e.preventDefault()})}s&&!e.defaultPrevented&&s.call(t,e)}let C=(t="")=>({center:.5,right:1,middle:.5,bottom:1})[t]||0,P=Array.prototype.find?function(t,i){return t.find(i)}:function(t,i){let e,s=t.length;for(e=0;e<s;e++)if(i(t[e],e))return t[e]};function E(t){return M(t)&&"number"==typeof t.nodeType}function O(t){return"number"==typeof t&&!isNaN(t)&&t<1/0&&t>-1/0}function B(t){return"string"==typeof t}function N(t){let i=Object.prototype.toString.call(t);return"[object Array]"===i||"[object Array Iterator]"===i}function M(t,i){return!!t&&"object"==typeof t&&(!i||!N(t))}function T(t,...i){let e,s=[t,...i],o={},n=function(t,i){return"object"!=typeof t&&(t={}),I(i,function(e,s){if("__proto__"!==s&&"constructor"!==s){let o;!M(e,!0)||(o=e?.constructor,M(e,!0)&&!E(e)&&o?.name&&"Object"!==o.name)||E(e)?t[s]=i[s]:t[s]=n(t[s]||{},e)}}),t};!0===t&&(o=s[1],s=Array.prototype.slice.call(s,2));let a=s.length;for(e=0;e<a;e++)o=n(o,s[e]);return o}function I(t,i,e){for(let s in t)Object.hasOwnProperty.call(t,s)&&i.call(e||t[s],t[s],s,t)}function S(){let t=arguments,i=t.length;for(let e=0;e<i;e++){let i=t[e];if(null!=i)return i}}function L(t,i){return 0>t.indexOf(i)&&!!t.push(i)}function D(t,i,e){function s(i,e){let s=t.removeEventListener;s&&s.call(t,i,e,!1)}function o(e){let o,n;t.nodeName&&(i?(o={})[i]=!0:o=e,I(o,function(t,i){if(e[i])for(n=e[i].length;n--;)s(i,e[i][n].fn)}))}let n="function"==typeof t&&t.prototype||t;if(Object.hasOwnProperty.call(n,"hcEvents")){let t=n.hcEvents;if(i){let n=t[i]||[];e?(t[i]=n.filter(function(t){return e!==t.fn}),s(i,e)):(o(t),t[i]=[])}else o(t),delete n.hcEvents}}function Y(t,i){let e,s,o=t.length;for(s=0;s<o;s++)t[s].safeI=s;for(t.sort(function(t,s){return 0===(e=i(t,s))?t.safeI-s.safeI:e}),s=0;s<o;s++)delete t[s].safeI}function X(t,i,e){let s=t[i];t[i]=function(){let t=arguments,i=this;return e.apply(this,[function(){return s.apply(i,arguments.length?arguments:t)}].concat([].slice.call(arguments)))}}function R(t,i){let e=this.initAnnotation(t);return this.options.annotations.push(e.options),S(i,!0)&&(e.redraw(),e.graphic.attr({opacity:1})),e}function F(){let t=this;t.plotBoxClip=this.renderer.clipRect(this.plotBox),t.controlPointsGroup=t.renderer.g("control-points").attr({zIndex:99}).clip(t.plotBoxClip).add(),t.options.annotations.forEach((i,e)=>{if(!t.annotations.some(t=>t.options===i)){let s=t.initAnnotation(i);t.options.annotations[e]=s.options}}),t.drawAnnotations(),v(t,"redraw",t.drawAnnotations),v(t,"destroy",function(){t.plotBoxClip.destroy(),t.controlPointsGroup.destroy()}),v(t,"exportData",function(i){let e=t.annotations,s=(this.options.exporting&&this.options.exporting.csv||{}).columnHeaderFormatter,o=!i.dataRows[1].xValues,n=t.options.lang&&t.options.lang.exportData&&t.options.lang.exportData.annotationHeader,a=i.dataRows[0].length,r=t.options.exporting?.csv?.annotations?.itemDelimiter,h=t.options.exporting?.csv?.annotations?.join;e.forEach(t=>{t.options.labelOptions?.includeInDataExport&&t.labels.forEach(t=>{if(t.options.text){let e=t.options.text;t.points.forEach(t=>{let s=t.x,o=t.series.xAxis?t.series.xAxis.index:-1,n=!1;if(-1===o){let t=i.dataRows[0].length,a=Array(t);for(let i=0;i<t;++i)a[i]="";a.push(e),a.xValues=[],a.xValues[o]=s,i.dataRows.push(a),n=!0}if(n||i.dataRows.forEach(t=>{!n&&t.xValues&&void 0!==o&&s===t.xValues[o]&&(h&&t.length>a?t[t.length-1]+=r+e:t.push(e),n=!0)}),!n){let t=i.dataRows[0].length,n=Array(t);for(let i=0;i<t;++i)n[i]="";n[0]=s,n.push(e),n.xValues=[],void 0!==o&&(n.xValues[o]=s),i.dataRows.push(n)}})}})});let l=0;i.dataRows.forEach(t=>{l=Math.max(l,t.length)});let c=l-i.dataRows[0].length;for(let t=0;t<c;t++){let e=function(t){let i;return s&&!1!==(i=s(t))?i:(i=n+" "+t,o)?{columnTitle:i,topLevelColumnTitle:i}:i}(t+1);o?(i.dataRows[0].push(e.topLevelColumnTitle),i.dataRows[1].push(e.columnTitle)):i.dataRows[0].push(e)}})}function U(){this.plotBoxClip.attr(this.plotBox),this.annotations.forEach(t=>{t.redraw(),t.graphic.animate({opacity:1},t.animationConfig)})}function W(t){let i=this.annotations,e="annotations"===t.coll?t:P(i,function(i){return i.options.id===t});e&&(w(e,"remove"),A(this.options.annotations,e.options),A(i,e),e.destroy())}function H(){let t=this.options.annotations,i=this.userOptions.annotations;this.annotations=[],N(this.options.annotations)||(this.options.annotations=[]),M(i,!0)&&M(t,!0)&&this.options.annotations.push(t)}function j(t){this.chart.hasDraggedAnnotation||t.apply(this,Array.prototype.slice.call(arguments,1))}(a||(a={})).compose=function(t,i,e){let s=i.prototype;if(!s.addAnnotation){let o=e.prototype;v(i,"afterInit",H),s.addAnnotation=R,s.callbacks.push(F),s.collectionsWithInit.annotations=[R],s.collectionsWithUpdate.push("annotations"),s.drawAnnotations=U,s.removeAnnotation=W,s.initAnnotation=function(i){let e=new(t.types[i.type]||t)(this,i);return this.annotations.push(e),e},X(o,"onContainerMouseDown",j)}};let z=a,V={visible:!0,animation:{},crop:!0,draggable:"xy",labelOptions:{align:"center",allowOverlap:!1,backgroundColor:"rgba(0, 0, 0, 0.75)",borderColor:"#000000",borderRadius:3,borderWidth:1,className:"highcharts-no-tooltip",crop:!1,formatter:function(){return b(this.y)?""+this.y:"Annotation label"},includeInDataExport:!0,overflow:"justify",padding:5,shadow:!1,shape:"callout",style:{fontSize:"0.7em",fontWeight:"normal",color:"contrast"},useHTML:!1,verticalAlign:"bottom",x:0,y:-16},shapeOptions:{stroke:"rgba(0, 0, 0, 0.75)",strokeWidth:1,fill:"rgba(0, 0, 0, 0.75)",r:0,snap:2},controlPointOptions:{events:{},style:{cursor:"pointer",fill:"#ffffff",stroke:"#000000","stroke-width":2},height:10,symbol:"circle",visible:!1,width:10},events:{},typeOptions:{},types:{},zIndex:6},{doc:q,isTouchDevice:_}=f(),G=class{addEvents(){let t=this,i=function(i){v(i,_?"touchstart":"mousedown",i=>{t.onMouseDown(i)},{passive:!1})};if(i(this.graphic.element),(t.labels||[]).forEach(t=>{t.options.useHTML&&t.graphic.text&&!t.graphic.text.foreignObject&&i(t.graphic.text.element)}),I(t.options.events,(i,e)=>{let s=function(s){"click"===e&&t.cancelClick||i.call(t,t.chart.pointer?.normalize(s),t.target,t)};-1===(t.nonDOMEvents||[]).indexOf(e)?(v(t.graphic.element,e,s,{passive:!1}),t.graphic.div&&v(t.graphic.div,e,s,{passive:!1})):v(t,e,s,{passive:!1})}),t.options.draggable&&(v(t,"drag",t.onDrag),!t.graphic.renderer.styledMode)){let i={cursor:{x:"ew-resize",y:"ns-resize",xy:"move"}[t.options.draggable]};t.graphic.css(i),(t.labels||[]).forEach(t=>{t.options.useHTML&&t.graphic.text&&!t.graphic.text.foreignObject&&t.graphic.text.css(i)})}t.isUpdating||w(t,"add")}destroy(){this.removeDocEvents(),D(this),this.hcEvents=null}mouseMoveToRadians(t,i,e){let s=t.prevChartY-e,o=t.prevChartX-i,n=t.chartY-e,a=t.chartX-i,r;return this.chart.inverted&&(r=o,o=s,s=r,r=a,a=n,n=r),Math.atan2(n,a)-Math.atan2(s,o)}mouseMoveToScale(t,i,e){let s=t.prevChartX-i,o=t.prevChartY-e,n=t.chartX-i,a=t.chartY-e,r=(n||1)/(s||1),h=(a||1)/(o||1);if(this.chart.inverted){let t=h;h=r,r=t}return{x:r,y:h}}mouseMoveToTranslation(t){let i=t.chartX-t.prevChartX,e=t.chartY-t.prevChartY,s;return this.chart.inverted&&(s=e,e=i,i=s),{x:i,y:e}}onDrag(t){if(this.chart.isInsidePlot(t.chartX-this.chart.plotLeft,t.chartY-this.chart.plotTop,{visiblePlotOnly:!0})){let i=this.mouseMoveToTranslation(t);"x"===this.options.draggable&&(i.y=0),"y"===this.options.draggable&&(i.x=0),this.points.length?this.translate(i.x,i.y):(this.shapes.forEach(t=>t.translate(i.x,i.y)),this.labels.forEach(t=>t.translate(i.x,i.y))),this.redraw(!1)}}onMouseDown(t){if(t.preventDefault&&t.preventDefault(),2===t.button)return;let i=this,e=i.chart.pointer,s=t?.sourceCapabilities?.firesTouchEvents||!1,o=(t=e?.normalize(t)||t).chartX,n=t.chartY;i.cancelClick=!1,i.chart.hasDraggedAnnotation=!0,i.removeDrag=v(q,_||s?"touchmove":"mousemove",function(t){i.hasDragged=!0,(t=e?.normalize(t)||t).prevChartX=o,t.prevChartY=n,w(i,"drag",t),o=t.chartX,n=t.chartY},_||s?{passive:!1}:void 0),i.removeMouseUp=v(q,_||s?"touchend":"mouseup",function(){let t=S(i.target&&i.target.annotation,i.target);t&&(t.cancelClick=i.hasDragged),i.cancelClick=i.hasDragged,i.chart.hasDraggedAnnotation=!1,i.hasDragged&&w(S(t,i),"afterUpdate"),i.hasDragged=!1,i.onMouseUp()},_||s?{passive:!1}:void 0)}onMouseUp(){this.removeDocEvents()}removeDocEvents(){this.removeDrag&&(this.removeDrag=this.removeDrag()),this.removeMouseUp&&(this.removeMouseUp=this.removeMouseUp())}},K=class extends G{constructor(t,i,e,s){super(),this.nonDOMEvents=["drag"],this.chart=t,this.target=i,this.options=e,this.index=S(e.index,s)}destroy(){super.destroy(),this.graphic&&(this.graphic=this.graphic.destroy()),this.chart=null,this.target=null,this.options=null}redraw(t){this.graphic[t?"animate":"attr"](this.options.positioner.call(this,this.target,this))}render(){let t=this.chart,i=this.options;this.graphic=t.renderer.symbol(i.symbol,0,0,i.width,i.height).add(t.controlPointsGroup).css(i.style),this.setVisibility(i.visible),this.addEvents()}setVisibility(t){this.graphic[t?"show":"hide"](),this.options.visible=t}update(t){let i=this.chart,e=this.target,s=this.index,o=T(!0,this.options,t);this.destroy(),this.constructor(i,e,o,s),this.render(i.controlPointsGroup),this.redraw()}};var $=d(512),Z=d.n($);let{series:{prototype:J}}=Z();class Q{static fromPoint(t){return new Q(t.series.chart,null,{x:t.x,y:t.y,xAxis:t.series.xAxis,yAxis:t.series.yAxis})}static pointToPixels(t,i){let e=t.series,s=e.chart,o=t.plotX||0,n=t.plotY||0,a;return s.inverted&&(t.mock?(o=t.plotY,n=t.plotX):(o=s.plotWidth-(t.plotY||0),n=s.plotHeight-(t.plotX||0))),e&&!i&&(o+=(a=e.getPlotBox()).translateX,n+=a.translateY),{x:o,y:n}}static pointToOptions(t){return{x:t.x,y:t.y,xAxis:t.series.xAxis,yAxis:t.series.yAxis}}constructor(t,i,e){this.mock=!0,this.point=this,this.series={visible:!0,chart:t,getPlotBox:J.getPlotBox},this.target=i||null,this.options=e,this.applyOptions(this.getOptions())}applyOptions(t){this.command=t.command,this.setAxis(t,"x"),this.setAxis(t,"y"),this.refresh()}getOptions(){return this.hasDynamicOptions()&&"function"==typeof this.options?this.options(this.target):this.options}hasDynamicOptions(){return"function"==typeof this.options}isInsidePlot(){let t=this.plotX,i=this.plotY,e=this.series.xAxis,s=this.series.yAxis,o={x:t,y:i,isInsidePlot:!0,options:{}};return e&&(o.isInsidePlot=b(t)&&t>=0&&t<=e.len),s&&(o.isInsidePlot=o.isInsidePlot&&b(i)&&i>=0&&i<=s.len),w(this.series.chart,"afterIsInsidePlot",o),o.isInsidePlot}refresh(){let t=this.series,i=t.xAxis,e=t.yAxis,s=this.getOptions();i?(this.x=s.x,this.plotX=i.toPixels(s.x,!0)):(this.x=void 0,this.plotX=s.x),e?(this.y=s.y,this.plotY=e.toPixels(s.y,!0)):(this.y=null,this.plotY=s.y),this.isInside=this.isInsidePlot()}refreshOptions(){let t=this.series,i=t.xAxis,e=t.yAxis;this.x=this.options.x=i?this.options.x=i.toValue(this.plotX,!0):this.plotX,this.y=this.options.y=e?e.toValue(this.plotY,!0):this.plotY}rotate(t,i,e){if(!this.hasDynamicOptions()){let s=Math.cos(e),o=Math.sin(e),n=this.plotX-t,a=this.plotY-i;this.plotX=n*s-a*o+t,this.plotY=n*o+a*s+i,this.refreshOptions()}}scale(t,i,e,s){if(!this.hasDynamicOptions()){let o=this.plotX*e,n=this.plotY*s;this.plotX=(1-e)*t+o,this.plotY=(1-s)*i+n,this.refreshOptions()}}setAxis(t,i){let e=i+"Axis",s=t[e],o=this.series.chart;this.series[e]="object"==typeof s?s:b(s)?o[e][s]||o.get(s):null}toAnchor(){let t=[this.plotX,this.plotY,0,0];return this.series.chart.inverted&&(t[0]=this.plotY,t[1]=this.plotX),t}translate(t,i,e,s){this.hasDynamicOptions()||(this.plotX+=e,this.plotY+=s,this.refreshOptions())}}!function(t){function i(){let t=this.controlPoints,i=this.options.controlPoints||[];i.forEach((e,s)=>{let o=T(this.options.controlPointOptions,e);o.index||(o.index=s),i[s]=o,t.push(new K(this.chart,this,o))})}function e(t){let i=t.series.getPlotBox(),e=t.series.chart,s=t.mock?t.toAnchor():e.tooltip&&e.tooltip.getAnchor.call({chart:t.series.chart},t)||[0,0,0,0],o={x:s[0]+(this.options.x||0),y:s[1]+(this.options.y||0),height:s[2]||0,width:s[3]||0};return{relativePosition:o,absolutePosition:T(o,{x:o.x+(t.mock?i.translateX:e.plotLeft),y:o.y+(t.mock?i.translateY:e.plotTop)})}}function s(){this.controlPoints.forEach(t=>t.destroy()),this.chart=null,this.controlPoints=null,this.points=null,this.options=null,this.annotation&&(this.annotation=null)}function o(){var t;let i=this.options;return i.points||i.point&&(N(t=i.point)?t:[t])}function n(){let t,i,e=this.getPointsOptions(),s=this.points,o=e?.length||0;for(t=0;t<o;t++){if(!(i=this.point(e[t],s[t]))){s.length=0;return}i.mock&&i.refresh(),s[t]=i}return s}function a(t,i){if(t&&t.series)return t;if(!i||null===i.series){if(M(t))i=new Q(this.chart,this,t);else if(B(t))i=this.chart.get(t)||null;else if("function"==typeof t){let e=t.call(i,this);i=e.series?e:new Q(this.chart,this,t)}}return i}function r(t){this.controlPoints.forEach(i=>i.redraw(t))}function h(){this.controlPoints.forEach(t=>t.render())}function l(t,i,e,s,o){if(this.chart.inverted){let t=i;i=e,e=t}this.points.forEach((n,a)=>this.transformPoint(t,i,e,s,o,a),this)}function c(t,i,e,s,o,n){let a=this.points[n];a.mock||(a=this.points[n]=Q.fromPoint(a)),a[t](i,e,s,o)}function p(t,i){this.transform("translate",null,null,t,i)}function d(t,i,e){this.transformPoint("translate",null,null,t,i,e)}t.compose=function(t){let u=t.prototype;u.addControlPoints||T(!0,u,{addControlPoints:i,anchor:e,destroyControlTarget:s,getPointsOptions:o,linkPoints:n,point:a,redrawControlPoints:r,renderControlPoints:h,transform:l,transformPoint:c,translate:p,translatePoint:d})}}(r||(r={}));let tt=r;class ti{constructor(t,i,e,s){this.annotation=t,this.chart=t.chart,this.collection="label"===s?"labels":"shapes",this.controlPoints=[],this.options=i,this.points=[],this.index=e,this.itemType=s,this.init(t,i,e)}attr(){this.graphic.attr.apply(this.graphic,arguments)}attrsFromOptions(t){let i,e,s=this.constructor.attrsMap,o={},n=this.chart.styledMode;for(i in t)e=s[i],void 0===s[i]||n&&-1!==["fill","stroke","stroke-width"].indexOf(e)||(o[e]=t[i]);return o}destroy(){this.graphic&&(this.graphic=this.graphic.destroy()),this.tracker&&(this.tracker=this.tracker.destroy()),this.destroyControlTarget()}calculateAnnotationSize(t,i,e){let s=e.toPixels(t,!0);return Math.abs(e.toPixels(t+i,!0)-s)}init(t,i,e){this.annotation=t,this.chart=t.chart,this.options=i,this.points=[],this.controlPoints=[],this.index=e,this.linkPoints(),this.addControlPoints()}redraw(t){this.redrawControlPoints(t)}render(t){this.options.className&&this.graphic&&this.graphic.addClass(this.options.className),this.renderControlPoints()}rotate(t,i,e){this.transform("rotate",t,i,e)}scale(t,i,e,s){this.transform("scale",t,i,e,s)}setControlPointsVisibility(t){this.controlPoints.forEach(i=>{i.setVisibility(t)})}shouldBeDrawn(){return!!this.points.length}translateShape(t,i,e){let s=this.annotation.chart,o=this.annotation.userOptions,n=s.annotations.indexOf(this.annotation),a=s.options.annotations[n];this.translatePoint(t,i,0),e&&this.translatePoint(t,i,1),a[this.collection][this.index].point=this.options.point,o[this.collection][this.index].point=this.options.point}update(t){let i=this.annotation,e=T(!0,this.options,t),s=this.graphic.parentGroup,o=this.constructor;this.destroy(),T(!0,this,new o(i,e,this.index,this.itemType)),this.render(s),this.redraw()}}tt.compose(ti);let te=ti,{defaultMarkers:ts}={defaultMarkers:{arrow:{tagName:"marker",attributes:{id:"arrow",refY:5,refX:9,markerWidth:10,markerHeight:10},children:[{tagName:"path",attributes:{d:"M 0 0 L 10 5 L 0 10 Z","stroke-width":0}}]},"reverse-arrow":{tagName:"marker",attributes:{id:"reverse-arrow",refY:5,refX:1,markerWidth:10,markerHeight:10},children:[{tagName:"path",attributes:{d:"M 0 5 L 10 0 L 10 10 Z","stroke-width":0}}]}}},to=tr("marker-end"),tn=tr("marker-start"),ta="rgba(192,192,192,"+(f().svg?1e-4:.002)+")";function tr(t){return function(i){this.attr(t,"url(#"+i+")")}}function th(){this.options.defs=T(ts,this.options.defs||{})}function tl(t,i){let e={attributes:{id:t}},s={stroke:i.color||"none",fill:i.color||"rgba(0, 0, 0, 0.75)"};e.children=i.children&&i.children.map(function(t){return T(s,t)});let o=T(!0,{attributes:{markerWidth:20,markerHeight:20,refX:0,refY:0,orient:"auto"}},i,e),n=this.definition(o);return n.id=t,n}class tc extends te{static compose(t,i){let e=i.prototype;e.addMarker||(v(t,"afterGetContainer",th),e.addMarker=tl)}constructor(t,i,e){super(t,i,e,"shape"),this.type="path"}init(t,i,e){b(i.yAxis)&&i.points.forEach(t=>{t&&"string"!=typeof t&&(t.yAxis=i.yAxis)}),b(i.xAxis)&&i.points.forEach(t=>{t&&"string"!=typeof t&&(t.xAxis=i.xAxis)}),super.init(t,i,e)}toD(){let t=this.options.d;if(t)return"function"==typeof t?t.call(this):t;let i=this.points,e=i.length,s=[],o=e,n=i[0],a=o&&this.anchor(n).absolutePosition,r=0,h;if(a)for(s.push(["M",a.x,a.y]);++r<e&&o;)h=(n=i[r]).command||"L",a=this.anchor(n).absolutePosition,"M"===h||"L"===h?s.push([h,a.x,a.y]):"Z"===h&&s.push([h]),o=n.series.visible;return o&&this.graphic?this.chart.renderer.crispLine(s,this.graphic.strokeWidth()):null}shouldBeDrawn(){return super.shouldBeDrawn()||!!this.options.d}render(t){let i=this.options,e=this.attrsFromOptions(i);this.graphic=this.annotation.chart.renderer.path([["M",0,0]]).attr(e).add(t),this.tracker=this.annotation.chart.renderer.path([["M",0,0]]).addClass("highcharts-tracker-line").attr({zIndex:2}).add(t),this.annotation.chart.styledMode||this.tracker.attr({"stroke-linejoin":"round",stroke:ta,fill:ta,"stroke-width":this.graphic.strokeWidth()+2*i.snap}),super.render(),k(this.graphic,{markerStartSetter:tn,markerEndSetter:to}),this.setMarkers(this)}redraw(t){if(this.graphic){let i=this.toD(),e=t?"animate":"attr";i?(this.graphic[e]({d:i}),this.tracker[e]({d:i})):(this.graphic.attr({d:"M 0 -9000000000"}),this.tracker.attr({d:"M 0 -9000000000"})),this.graphic.placed=this.tracker.placed=!!i}super.redraw(t)}setMarkers(t){let i=t.options,e=t.chart,s=e.options.defs,o=i.fill,n=b(o)&&"none"!==o?o:i.stroke;["markerStart","markerEnd"].forEach(function(o){let a,r,h,l,c=i[o];if(c){for(h in s)if((c===((a=s[h]).attributes&&a.attributes.id)||c===a.id)&&"marker"===a.tagName){r=a;break}r&&(l=t[o]=e.renderer.addMarker((i.id||(0,g.uniqueKey)())+"-"+c,T(r,{color:n})),t.attr(o,l.getAttribute("id")))}})}}tc.attrsMap={dashStyle:"dashstyle",strokeWidth:"stroke-width",stroke:"stroke",fill:"fill",zIndex:"zIndex"};class tp extends te{constructor(t,i,e){super(t,i,e,"shape"),this.type="rect",this.translate=super.translateShape}init(t,i,e){let{point:s,xAxis:o,yAxis:n}=i;s&&"string"!=typeof s&&(b(o)&&(s.xAxis=o),b(n)&&(s.yAxis=n)),super.init(t,i,e)}render(t){let i=this.attrsFromOptions(this.options);this.graphic=this.annotation.chart.renderer.rect(0,-9e9,0,0).attr(i).add(t),super.render()}redraw(t){if(this.graphic){let i=this.points[0],e=this.anchor(i).absolutePosition,s=this.options.width||0,o=this.options.height||0;if(e){let n=b(this.options.xAxis)?this.chart.xAxis[this.options.xAxis]:void 0,a=b(this.options.yAxis)?this.chart.yAxis[this.options.yAxis]:void 0;n&&b(i.x)&&(s=this.calculateAnnotationSize(i.x,s,n)),a&&b(i.y)&&(o=this.calculateAnnotationSize(i.y,o,a)),this.graphic[t?"animate":"attr"]({x:e.x,y:e.y,width:s,height:o})}else this.attr({x:0,y:-9e9});this.graphic.placed=!!e}super.redraw(t)}}tp.attrsMap=T(tc.attrsMap,{width:"width",height:"height"});class td extends te{constructor(t,i,e){super(t,i,e,"shape"),this.type="circle",this.translate=super.translateShape}init(t,i,e){let{point:s,xAxis:o,yAxis:n}=i;s&&"string"!=typeof s&&(b(o)&&(s.xAxis=o),b(n)&&(s.yAxis=n)),super.init(t,i,e)}redraw(t){if(this.graphic){let i=this.points[0],e=this.anchor(i).absolutePosition,s=this.options.r||0;if(e){let o=b(this.options.yAxis)?this.chart.yAxis[this.options.yAxis]:void 0;o&&b(i.y)&&(s=this.calculateAnnotationSize(i.y,s,o)),this.graphic[t?"animate":"attr"]({x:e.x,y:e.y,r:s})}else this.graphic.attr({x:0,y:-9e9});this.graphic.placed=!!e}super.redraw.call(this,t)}render(t){let i=this.attrsFromOptions(this.options);this.graphic=this.annotation.chart.renderer.circle(0,-9e9,0).attr(i).add(t),super.render()}setRadius(t){this.options.r=t}}td.attrsMap=T(tc.attrsMap,{r:"r"});class tu extends te{constructor(t,i,e){super(t,i,e,"shape"),this.type="ellipse"}init(t,i,e){b(i.yAxis)&&i.points.forEach(t=>{t&&"string"!=typeof t&&(t.yAxis=i.yAxis)}),b(i.xAxis)&&i.points.forEach(t=>{t&&"string"!=typeof t&&(t.xAxis=i.xAxis)}),super.init(t,i,e)}render(t){this.graphic=this.annotation.chart.renderer.createElement("ellipse").attr(this.attrsFromOptions(this.options)).add(t),super.render()}translate(t,i){super.translateShape(t,i,!0)}getDistanceFromLine(t,i,e,s){return Math.abs((i.y-t.y)*e-(i.x-t.x)*s+i.x*t.y-i.y*t.x)/Math.sqrt((i.y-t.y)*(i.y-t.y)+(i.x-t.x)*(i.x-t.x))}getAttrs(t,i){let e=t.x,s=t.y,o=i.x,n=i.y,a=(e+o)/2,r=Math.sqrt((e-o)*(e-o)/4+(s-n)*(s-n)/4),h=180*Math.atan((n-s)/(o-e))/Math.PI;return a<e&&(h+=180),{cx:a,cy:(s+n)/2,rx:r,ry:this.getRY(),angle:h}}getRY(){let t=this.getYAxis();return b(t)?Math.abs(t.toPixels(this.options.ry)-t.toPixels(0)):this.options.ry}getYAxis(){let t=this.options.yAxis;return this.chart.yAxis[t]}getAbsolutePosition(t){return this.anchor(t).absolutePosition}redraw(t){if(this.graphic){let i=this.getAbsolutePosition(this.points[0]),e=this.getAbsolutePosition(this.points[1]),s=this.getAttrs(i,e);i?this.graphic[t?"animate":"attr"]({cx:s.cx,cy:s.cy,rx:s.rx,ry:s.ry,rotation:s.angle,rotationOriginX:s.cx,rotationOriginY:s.cy}):this.graphic.attr({x:0,y:-9e9}),this.graphic.placed=!!i}super.redraw(t)}setYRadius(t){let i=this.annotation.userOptions.shapes;this.options.ry=t,i&&i[0]&&(i[0].ry=t,i[0].ry=t)}}tu.attrsMap=T(tc.attrsMap,{ry:"ry"});var tg=d(984),tf=d.n(tg);let{format:ty}=tf();function tm(t,i,e,s,o){let n=o&&o.anchorX,a=o&&o.anchorY,r,h,l=e/2;return O(n)&&O(a)&&(r=[["M",n,a]],(h=i-a)<0&&(h=-s-h),h<e&&(l=n<t+e/2?h:e-h),a>i+s?r.push(["L",t+l,i+s]):a<i?r.push(["L",t+l,i]):n<t?r.push(["L",t,i+s/2]):n>t+e&&r.push(["L",t+e,i+s/2])),r||[]}class tv extends te{static alignedPosition(t,i){return{x:Math.round((i.x||0)+(t.x||0)+(i.width-(t.width||0))*C(t.align)),y:Math.round((i.y||0)+(t.y||0)+(i.height-(t.height||0))*C(t.verticalAlign))}}static compose(t){t.prototype.symbols.connector=tm}static justifiedOptions(t,i,e,s){let o,n=e.align,a=e.verticalAlign,r=i.box?0:i.padding||0,h=i.getBBox(),l={align:n,verticalAlign:a,x:e.x,y:e.y,width:i.width,height:i.height},c=(s.x||0)-t.plotLeft,p=(s.y||0)-t.plotTop;return(o=c+r)<0&&("right"===n?l.align="left":l.x=(l.x||0)-o),(o=c+h.width-r)>t.plotWidth&&("left"===n?l.align="right":l.x=(l.x||0)+t.plotWidth-o),(o=p+r)<0&&("bottom"===a?l.verticalAlign="top":l.y=(l.y||0)-o),(o=p+h.height-r)>t.plotHeight&&("top"===a?l.verticalAlign="bottom":l.y=(l.y||0)+t.plotHeight-o),l}constructor(t,i,e){super(t,i,e,"label")}translatePoint(t,i){super.translatePoint(t,i,0)}translate(t,i){var e,s;let o=this.annotation.chart,n=this.annotation.userOptions,a=o.annotations.indexOf(this.annotation),r=o.options.annotations[a];if(o.inverted){let e=t;t=i,i=e}(e=this.options).x||(e.x=0),(s=this.options).y||(s.y=0),this.options.x+=t,this.options.y+=i,r[this.collection][this.index].x=this.options.x,r[this.collection][this.index].y=this.options.y,n[this.collection][this.index].x=this.options.x,n[this.collection][this.index].y=this.options.y}render(t){let i=this.options,e=this.attrsFromOptions(i),s=i.style,o=this.annotation.chart.options.chart,n=o.plotBackgroundColor||o.backgroundColor;if(this.graphic=this.annotation.chart.renderer.label("",0,-9999,i.shape,void 0,void 0,i.useHTML,void 0,"annotation-label").attr(e).add(t),!this.annotation.chart.styledMode){if(s?.color==="contrast"){let t=!i.shape||tv.shapesWithoutBackground.indexOf(i.shape)>-1||"none"===i.backgroundColor?n:i.backgroundColor;s.color=this.annotation.chart.renderer.getContrast("string"==typeof t?t:"string"==typeof n?n:"#ffffff")}this.graphic.css(i.style||{}).shadow(i.shadow)}this.graphic.labelrank=i.labelrank,super.render()}redraw(t){let i=this.options,e=this.text||i.format||i.text,s=this.graphic,o=this.points[0];if(!s)return void this.redraw(t);s.attr({text:e?ty(String(e),o,this.annotation.chart):i.formatter.call(o,o)});let n=this.anchor(o),a=this.position(n);a?(s.alignAttr=a,a.anchorX=n.absolutePosition.x,a.anchorY=n.absolutePosition.y,s[t?"animate":"attr"](a)):s.attr({x:0,y:-9999}),s.placed=!!a,super.redraw(t)}anchor(t){let i=super.anchor.apply(this,arguments),e=this.options.x||0,s=this.options.y||0;return i.absolutePosition.x-=e,i.absolutePosition.y-=s,i.relativePosition.x-=e,i.relativePosition.y-=s,i}position(t){let i=this.graphic,e=this.annotation.chart,s=e.tooltip,o=this.points[0],n=this.options,a=t.absolutePosition,r=t.relativePosition,h,l,c,p,d=o.series.visible&&Q.prototype.isInsidePlot.call(o);if(i&&d){let{width:t=0,height:u=0}=i;n.distance&&s?h=s.getPosition.call({chart:e,distance:S(n.distance,16),getPlayingField:s.getPlayingField,pointer:s.pointer},t,u,{plotX:r.x,plotY:r.y,negative:o.negative,ttBelow:o.ttBelow,h:r.height||r.width}):n.positioner?h=n.positioner.call(this,this):(l={x:a.x,y:a.y,width:0,height:0},h=tv.alignedPosition(k(n,{width:t,height:u}),l),"justify"===this.options.overflow&&(h=tv.alignedPosition(tv.justifiedOptions(e,i,n,h),l))),n.crop&&(c=h.x-e.plotLeft,p=h.y-e.plotTop,d=e.isInsidePlot(c,p)&&e.isInsidePlot(c+t,p+u))}return d?h:null}}tv.attrsMap={backgroundColor:"fill",borderColor:"stroke",borderWidth:"stroke-width",zIndex:"zIndex",borderRadius:"r",padding:"padding"},tv.shapesWithoutBackground=["connector"];class tx extends te{constructor(t,i,e){super(t,i,e,"shape"),this.type="image",this.translate=super.translateShape}render(t){let i=this.attrsFromOptions(this.options),e=this.options;this.graphic=this.annotation.chart.renderer.image(e.src,0,-9e9,e.width,e.height).attr(i).add(t),this.graphic.width=e.width,this.graphic.height=e.height,super.render()}redraw(t){if(this.graphic){let i=this.anchor(this.points[0]),e=tv.prototype.position.call(this,i);e?this.graphic[t?"animate":"attr"]({x:e.x,y:e.y}):this.graphic.attr({x:0,y:-9e9}),this.graphic.placed=!!e}super.redraw(t)}}tx.attrsMap={width:"width",height:"height",zIndex:"zIndex"};var tb=d(660),tA=d.n(tb);let tk=class{constructor(t,i){this.iconsURL=i,this.container=this.createPopupContainer(t),this.closeButton=this.addCloseButton()}createPopupContainer(t,i="highcharts-popup highcharts-no-tooltip"){return x("div",{className:i},void 0,t)}addCloseButton(t="highcharts-popup-close"){let i=this,e=this.iconsURL,s=x("button",{className:t},void 0,this.container);return x("span",{className:"highcharts-icon"},{backgroundImage:"url("+(e.match(/png|svg|jpeg|jpg|gif/ig)?e:e+"close.svg")+")"},s),["click","touchstart"].forEach(t=>{v(s,t,i.closeButtonEvents.bind(i))}),v(document,"keydown",function(t){"Escape"===t.code&&i.closeButtonEvents()}),s}closeButtonEvents(){this.closePopup()}showPopup(t="highcharts-annotation-toolbar"){let i=this.container,e=this.closeButton;this.type=void 0,i.innerHTML=tA().emptyHTML,i.className.indexOf(t)>=0&&(i.classList.remove(t),i.removeAttribute("style")),i.appendChild(e),i.style.display="block",i.style.height=""}closePopup(){this.container.style.display="none"}};var tw=d(620),tC=d.n(tw);let{doc:tP,isFirefox:tE}=f();function tO(t,i,e,s,o,n){let a,r;if(!i)return;let h=this.addInput,l=this.lang;I(s,(s,n)=>{a=""!==e?e+"."+n:n,M(s)&&(!N(s)||N(s)&&M(s[0])?((r=l[n]||n).match(/\d/g)||o.push([!0,r,t]),tO.call(this,t,i,a,s,o,!1)):o.push([this,a,"annotation",t,s]))}),n&&(Y(o,t=>t[1].match(/format/g)?-1:1),tE&&o.reverse(),o.forEach(t=>{!0===t[0]?x("span",{className:"highcharts-annotation-title"},void 0,t[2]).appendChild(tP.createTextNode(t[1])):(t[4]={value:t[4][0],type:t[4][1]},h.apply(t[0],t.splice(1)))}))}let{doc:tB}=f(),{seriesTypes:tN}=Z();(n=h||(h={}))[n["params.algorithm"]=0]="params.algorithm",n[n["params.average"]=1]="params.average";let tM={"algorithm-pivotpoints":["standard","fibonacci","camarilla"],"average-disparityindex":["sma","ema","dema","tema","wma"]};function tT(t){let i=x("div",{className:"highcharts-popup-lhs-col"},void 0,t),e=x("div",{className:"highcharts-popup-rhs-col"},void 0,t);return x("div",{className:"highcharts-popup-rhs-col-wrapper"},void 0,e),{lhsCol:i,rhsCol:e}}function tI(t,i,e,s){let o=i.params||i.options.params;s.innerHTML=tA().emptyHTML,x("h3",{className:"highcharts-indicator-title"},void 0,s).appendChild(tB.createTextNode(tU(i,e).indicatorFullName)),x("input",{type:"hidden",name:"highcharts-type-"+e,value:e},void 0,s),tW.call(this,e,"series",t,s,i,i.linkedParent&&i.linkedParent.options.id),o.volumeSeriesID&&tW.call(this,e,"volume",t,s,i,i.linkedParent&&o.volumeSeriesID),tL.call(this,t,"params",o,e,s)}function tS(t,i,e,s){function o(i,e){let s=g.parentNode.children[1];tI.call(n,t,i,e,g),s&&(s.style.display="block"),l&&i.options&&x("input",{type:"hidden",name:"highcharts-id-"+e,value:i.options.id},void 0,g).setAttribute("highcharts-data-series-id",i.options.id)}let n=this,a=n.lang,r=i.querySelectorAll(".highcharts-popup-lhs-col")[0],h=i.querySelectorAll(".highcharts-popup-rhs-col")[0],l="edit"===e,c=l?t.series:t.options.plotOptions||{};if(!t&&c)return;let p,d=[];l||N(c)?N(c)&&(d=tF.call(this,c)):d=tR.call(this,c,s),Y(d,(t,i)=>{let e=t.indicatorFullName.toLowerCase(),s=i.indicatorFullName.toLowerCase();return e<s?-1:+(e>s)}),r.children[1]&&r.children[1].remove();let u=x("ul",{className:"highcharts-indicator-list"},void 0,r),g=h.querySelectorAll(".highcharts-popup-rhs-col-wrapper")[0];if(d.forEach(t=>{let{indicatorFullName:i,indicatorType:e,series:s}=t;p=x("li",{className:"highcharts-indicator-list"},void 0,u);let n=x("button",{className:"highcharts-indicator-list-item",textContent:i},void 0,p);["click","touchstart"].forEach(t=>{v(n,t,function(){o(s,e)})})}),d.length>0){let{series:t,indicatorType:i}=d[0];o(t,i)}else l||(tA().setElementHTML(g.parentNode.children[0],a.noFilterMatch||""),g.parentNode.children[1].style.display="none")}function tL(t,i,e,s,o){if(!t)return;let n=this.addInput;I(e,(e,a)=>{let r=i+"."+a;if(b(e)&&r)if(M(e)&&(n.call(this,r,s,o,{}),tL.call(this,t,r,e,s,o)),r in h){let n=tY.call(this,s,r,o);tX.call(this,t,i,n,s,a,e)}else"params.volumeSeriesID"===r||N(e)||n.call(this,r,s,o,{value:e,type:"number"})})}function tD(t,i){let e=this,s=i.querySelectorAll(".highcharts-popup-lhs-col")[0],o=this.lang.clearFilter,n=x("div",{className:"highcharts-input-wrapper"},void 0,s),a=function(i){tS.call(e,t,e.container,"add",i)},r=this.addInput("searchIndicators","input",n,{value:"",type:"text",htmlFor:"search-indicators",labelClassName:"highcharts-input-search-indicators-label"}),h=x("a",{textContent:o},void 0,n);r.classList.add("highcharts-input-search-indicators"),h.classList.add("clear-filter-button"),v(r,"input",function(){a(this.value),this.value.length?h.style.display="inline-block":h.style.display="none"}),["click","touchstart"].forEach(t=>{v(h,t,function(){r.value="",a(""),h.style.display="none"})})}function tY(t,i,e){let s=i.split("."),o=s[s.length-1],n="highcharts-"+i+"-type-"+t,a=this.lang;x("label",{htmlFor:n},null,e).appendChild(tB.createTextNode(a[o]||i));let r=x("select",{name:n,className:"highcharts-popup-field",id:"highcharts-select-"+i},null,e);return r.setAttribute("id","highcharts-select-"+i),r}function tX(t,i,e,s,o,n,a){"series"===i||"volume"===i?t.series.forEach(t=>{let s=t.options,o=s.name||s.params?t.name:s.id||"";"highcharts-navigator-series"!==s.id&&s.id!==(a&&a.options&&a.options.id)&&(b(n)||"volume"!==i||"column"!==t.type||(n=s.id),x("option",{value:s.id},void 0,e).appendChild(tB.createTextNode(o)))}):s&&o&&tM[o+"-"+s].forEach(t=>{x("option",{value:t},void 0,e).appendChild(tB.createTextNode(t))}),b(n)&&(e.value=n)}function tR(t,i){let e,s=this.chart&&this.chart.options.lang,o=s&&s.navigation&&s.navigation.popup&&s.navigation.popup.indicatorAliases,n=new Map;return I(t,(t,s)=>{let a=t&&t.options;if(t.params||a&&a.params){let{indicatorFullName:a,indicatorType:r}=tU(t,s);if(i){let s=RegExp(i.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),"i"),h=o&&o[r]&&o[r].join(" ")||"";(a.match(s)||h.match(s))&&(e={indicatorFullName:a,indicatorType:r,series:t},n.set(r.toLowerCase(),e))}else e={indicatorFullName:a,indicatorType:r,series:t},n.set(r.toLowerCase(),e)}}),Array.from(n.values())}function tF(t){let i=[];return t.forEach(t=>{t.is("sma")&&i.push({indicatorFullName:t.name,indicatorType:t.type,series:t})}),i}function tU(t,i){let e=t.options,s=tN[i]&&tN[i].prototype.nameBase||i.toUpperCase(),o=i;return e&&e.type&&(o=t.options.type,s=t.name),{indicatorFullName:s,indicatorType:o}}function tW(t,i,e,s,o,n){if(!e)return;let a=tY.call(this,t,i,s);tX.call(this,e,i,a,void 0,void 0,void 0,o),b(n)&&(a.value=n)}let{doc:tH}=f();function tj(){return x("div",{className:"highcharts-tab-item-content highcharts-no-mousewheel"},void 0,this.container)}function tz(t,i){let e=this.container,s=this.lang,o="highcharts-tab-item";0===i&&(o+=" highcharts-tab-disabled");let n=x("button",{className:o},void 0,e);return n.appendChild(tH.createTextNode(s[t+"Button"]||t)),n.setAttribute("highcharts-data-tab-type",t),n}function tV(){let t=this.container,i=t.querySelectorAll(".highcharts-tab-item"),e=t.querySelectorAll(".highcharts-tab-item-content");for(let t=0;t<i.length;t++)i[t].classList.remove("highcharts-tab-item-active"),e[t].classList.remove("highcharts-tab-item-show")}function tq(t,i){let e=this.container.querySelectorAll(".highcharts-tab-item-content");t.className+=" highcharts-tab-item-active",e[i].className+=" highcharts-tab-item-show"}function t_(t){let i=this;this.container.querySelectorAll(".highcharts-tab-item").forEach((e,s)=>{(0!==t||"edit"!==e.getAttribute("highcharts-data-tab-type"))&&["click","touchstart"].forEach(t=>{v(e,t,function(){tV.call(i),tq.call(i,this,s)})})})}let{doc:tG}=f(),{getOptions:tK}=f();class t$ extends tk{constructor(t,i,e){super(t,i),this.chart=e,this.lang=(tK().lang.navigation||{}).popup||{},v(this.container,"mousedown",()=>{let t=e&&e.navigationBindings&&e.navigationBindings.activeAnnotation;if(t){t.cancelClick=!0;let i=v(tG,"click",()=>{setTimeout(()=>{t.cancelClick=!1},0),i()})}})}addInput(t,i,e,s){let o=t.split("."),n=o[o.length-1],a=this.lang,r="highcharts-"+i+"-"+S(s.htmlFor,n);if(n.match(/^\d+$/)||x("label",{htmlFor:r,className:s.labelClassName},void 0,e).appendChild(tG.createTextNode(a[n]||n)),"color"===s.type&&this.chart?.container)return this.createColorInput(t,r,s,e,this.chart.container);let h=x("input",{name:r,value:s.value,type:s.type,className:"highcharts-popup-field"},void 0,e);return h.setAttribute("highcharts-data-name",t),h}createColorInput(t,i,e,s,o){let{value:n,alpha:a}=function(t,i){let e=t=>("0"+Math.round(t).toString(16)).slice(-2).toUpperCase(),s=t=>{let[i,s,o,n]=tC().parse(t).rgba;return{value:"#"+e(i)+e(s)+e(o),alpha:n}};if(t.startsWith("rgb")||t.startsWith("rgba"))return s(t);if(t.startsWith("color")||t.startsWith("var")){let o=tG.createElement("span");o.style.setProperty("color",t),i.appendChild(o);let n=window.getComputedStyle(o).color;if(i.removeChild(o),n.startsWith("color")){let t=n.match(RegExp("color\\s*\\(\\s*srgb\\s+([\\d.]+)\\s+([\\d.]+)\\s+([\\d.]+)\\s+(?:\\s*\\/\\s*([\\d.]+))?\\s*\\)"));if(t){let i=Math.round(255*parseFloat(t[1])),s=Math.round(255*parseFloat(t[2])),o=Math.round(255*parseFloat(t[3])),n=t[4]?parseFloat(t[4]):1;return{value:"#"+e(i)+e(s)+e(o),alpha:n}}}if(n.startsWith("rgb")||n.startsWith("rgba"))return s(n)}return{value:t,alpha:1}}(e.value||"",o),r=tC().parse(e.value||"").rgba[3],h=isNaN(r)?a:r,l=x("div",{className:"highcharts-popup-color-wrapper"},void 0,s),c=x("input",{type:"color",value:n,className:"highcharts-popup-field highcharts-popup-field-color"},void 0,l),p=x("input",{name:i,id:i,value:n,type:"text",className:"highcharts-popup-field highcharts-popup-field-text"},void 0,l);p.setAttribute("highcharts-data-name",t);let d=x("span",{className:"highcharts-popup-color-separator"},void 0,l),u=x("input",{type:"number",value:String(Math.round(100*h)),className:"highcharts-popup-field highcharts-popup-opacity-percentage",min:"0",max:"100",step:"1"},void 0,l),g=x("span",{className:"highcharts-popup-opacity-percent-suffix"},void 0,l);g.appendChild(tG.createTextNode(" %"));let f=x("input",{type:"range",value:String(Math.round(100*h)),className:"highcharts-popup-opacity-slider",min:"0",max:"100",step:"1"},void 0,s);f.style.setProperty("--highcharts-popup-opacity-track-color",n),f.style.setProperty("display","none");let y=()=>{let t=/^#[0-9A-Fa-f]{6}$/.test(p.value);d.style.display=t?"":"none",u.style.display=t?"":"none",g.style.display=t?"":"none"};y();let m=t=>{var i;let e=(i=Number(t.target.value),i>0?i<100?i:100:0);f.value=String(e),u.value=String(Math.round(e))},b=t=>{t.target===c?p.value=c.value.toUpperCase():c.value=p.value,f.style.setProperty("--highcharts-popup-opacity-track-color",c.value),y()};return v(s,"mousedown",t=>{t.target!==u&&t.target!==f&&(f.style.display="none")}),v(u,"focus",()=>{f.style.display=""}),v(u,"input",m),v(f,"input",m),v(c,"input",b),v(p,"input",b),l}closeButtonEvents(){if(this.chart){let t=this.chart.navigationBindings;w(t,"closePopup"),t&&t.selectedButtonElement&&w(t,"deselectButton",{button:t.selectedButtonElement})}else super.closeButtonEvents()}addButton(t,i,e,s,o){let n=x("button",void 0,void 0,t);return n.appendChild(tG.createTextNode(i)),o&&["click","touchstart"].forEach(t=>{v(n,t,()=>{let t,i,n,a,r;return this.closePopup(),o((t=Array.prototype.slice.call(s.querySelectorAll("input")),i=Array.prototype.slice.call(s.querySelectorAll("select")),n=s.querySelectorAll("#highcharts-select-series > option:checked")[0],a=s.querySelectorAll("#highcharts-select-volume > option:checked")[0],r={actionType:e,linkedTo:n&&n.getAttribute("value")||"",fields:{}},t.forEach(t=>{let i=t.getAttribute("highcharts-data-name");if(t.getAttribute("highcharts-data-series-id"))r.seriesId=t.value;else if(i){let e=t.closest(".highcharts-popup-color-wrapper"),s=e?.querySelector(".highcharts-popup-opacity-percentage"),o=s?Number(s.value)/100:1;if(s){let e=tC().parse(t.value).rgba;r.fields[i]=Number.isNaN(e[0])?t.value:`rgba(${e[0]},${e[1]},${e[2]},${o})`}else r.fields[i]=t.value}else r.type=t.value}),i.forEach(t=>{let i=t.id;if("highcharts-select-series"!==i&&"highcharts-select-volume"!==i){let e=i.split("highcharts-select-")[1];r.fields[e]=t.value}}),a&&(r.fields["params.volumeSeriesID"]=a.getAttribute("value")||""),r))})}),n}showForm(t,i,e,s){i&&(this.showPopup(),"indicators"===t&&this.indicators.addForm.call(this,i,e,s),"annotation-toolbar"===t&&this.annotations.addToolbar.call(this,i,e,s),"annotation-edit"===t&&this.annotations.addForm.call(this,i,e,s),"flag"===t&&this.annotations.addForm.call(this,i,e,s,!0),this.type=t,this.container.style.height=this.container.offsetHeight+"px")}}k(t$.prototype,{annotations:{addForm:function(t,i,e,s){if(!t)return;let o=this.container,n=this.lang,a=x("h2",{className:"highcharts-popup-main-title"},void 0,o);a.appendChild(tP.createTextNode(n[i.langKey]||i.langKey||"")),a=x("div",{className:"highcharts-popup-lhs-col highcharts-popup-lhs-full"},void 0,o);let r=x("div",{className:"highcharts-popup-bottom-row"},void 0,o);tO.call(this,a,t,"",i,[],!0),this.addButton(r,s?n.addButton||"Add":n.saveButton||"Save",s?"add":"save",o,e)},addToolbar:function(t,i,e){let s=this.lang,o=this.container,n=this.showForm,a="highcharts-annotation-toolbar";-1===o.className.indexOf(a)&&(o.className+=" "+a+" highcharts-no-mousewheel"),t&&(o.style.top=t.plotTop+10+"px");let r=x("p",{className:"highcharts-annotation-label"},void 0,o);r.setAttribute("aria-label","Annotation type"),r.appendChild(tP.createTextNode(S(s[i.langKey]||i.langKey,i.shapes&&i.shapes[0].type,"")));let h=this.addButton(o,s.editButton||"Edit","edit",o,()=>{n.call(this,"annotation-edit",t,i,e)});h.className+=" highcharts-annotation-edit-button",x("span",{className:"highcharts-icon"},{backgroundImage:`url(${this.iconsURL}edit.svg)`},h),h=this.addButton(o,s.removeButton||"Remove","remove",o,e),h.className+=" highcharts-annotation-remove-button",x("span",{className:"highcharts-icon"},{backgroundImage:`url(${this.iconsURL}destroy.svg)`},h)}},indicators:{addForm:function(t,i,e){let s,o=this.lang;if(!t)return;this.tabs.init.call(this,t);let n=this.container.querySelectorAll(".highcharts-tab-item-content");tT(n[0]),tD.call(this,t,n[0]),tS.call(this,t,n[0],"add"),s=n[0].querySelectorAll(".highcharts-popup-rhs-col")[0],this.addButton(s,o.addButton||"add","add",s,e),tT(n[1]),tS.call(this,t,n[1],"edit"),s=n[1].querySelectorAll(".highcharts-popup-rhs-col")[0],this.addButton(s,o.saveButton||"save","edit",s,e),this.addButton(s,o.removeButton||"remove","remove",s,e)},getAmount:function(){let t=0;return this.series.forEach(i=>{(i.params||i.options.params)&&t++}),t}},tabs:{init:function(t){if(!t)return;let i=this.indicators.getAmount.call(t),e=tz.call(this,"add");tz.call(this,"edit",i),tj.call(this),tj.call(this),t_.call(this,i),tq.call(this,e,0)}}});let{composed:tZ}=f();function tJ(){this.popup&&this.popup.closePopup()}function tQ(t){this.popup||(this.popup=new t$(this.chart.container,this.chart.options.navigation.iconsURL||this.chart.options.stockTools&&this.chart.options.stockTools.gui.iconsURL||"https://code.highcharts.com/12.6.0/gfx/stock-icons/",this.chart)),this.popup.showForm(t.formType,this.chart,t.options,t.onSubmit)}function t0(t,i){this.inClass(i.target,"highcharts-popup")||t.apply(this,Array.prototype.slice.call(arguments,1))}let t1=function(t,i){L(tZ,"Popup")&&(v(t,"closePopup",tJ),v(t,"showPopup",tQ),X(i.prototype,"onContainerMouseDown",t0))},{getDeferredAnimation:t2}=f(),{defaultOptions:t9}=f();function t5(t,i){let e={};return["labels","shapes"].forEach(s=>{let o=t[s],n=i[s];if(o)if(n)e[s]=(N(n)?n:[n]).map((t,i)=>T(o[i],t));else e[s]=t[s]}),e}class t4 extends G{static compose(t,i,e,s){z.compose(t4,t,e),tv.compose(s),tc.compose(t,s),i.compose(t4,t),t1(i,e)}constructor(t,i){super(),this.coll="annotations",this.chart=t,this.points=[],this.controlPoints=[],this.coll="annotations",this.index=-1,this.labels=[],this.shapes=[],this.setOptions(i),this.userOptions=i;const e=t5(this.options,i);this.options.labels=e.labels,this.options.shapes=e.shapes,this.init(t,this.options)}addClipPaths(){this.setClipAxes(),this.clipXAxis&&this.clipYAxis&&this.options.crop&&(this.clipRect=this.chart.renderer.clipRect(this.getClipBox()))}addLabels(){let t=this.options.labels||[];t.forEach((i,e)=>{let s=this.initLabel(i,e);T(!0,t[e],s.options)})}addShapes(){let t=this.options.shapes||[];t.forEach((i,e)=>{let s=this.initShape(i,e);T(!0,t[e],s.options)})}destroy(){var t;let i=this.chart,e=function(t){t.destroy()};this.labels.forEach(e),this.shapes.forEach(e),this.clipXAxis=null,this.clipYAxis=null,A(i.labelCollectors,this.labelCollector),super.destroy(),this.destroyControlTarget(),t=this,I(t,function(e,s){e!==i&&e?.destroy&&e.destroy(),e?.destroy,delete t[s]})}destroyItem(t){A(this[t.itemType+"s"],t),t.destroy()}getClipBox(){if(this.clipXAxis&&this.clipYAxis)return{x:this.clipXAxis.left,y:this.clipYAxis.top,width:this.clipXAxis.width,height:this.clipYAxis.height}}initProperties(t,i){this.setOptions(i);let e=t5(this.options,i);this.options.labels=e.labels,this.options.shapes=e.shapes,this.chart=t,this.points=[],this.controlPoints=[],this.coll="annotations",this.userOptions=i,this.labels=[],this.shapes=[]}init(t,i,e=this.index){let s=this.chart,o=this.options.animation;this.index=e,this.linkPoints(),this.addControlPoints(),this.addShapes(),this.addLabels(),this.setLabelCollector(),this.animationConfig=t2(s,o)}initLabel(t,i){this.options.labelOptions?.align;let e=new tv(this,T(this.options.labelOptions,{controlPointOptions:this.options.controlPointOptions},t),i);return e.itemType="label",this.labels.push(e),e}initShape(t,i){let e=T(this.options.shapeOptions,{controlPointOptions:this.options.controlPointOptions},t),s=new t4.shapesMap[e.type||"rect"](this,e,i);return s.itemType="shape",this.shapes.push(s),s}redraw(t){this.linkPoints(),this.graphic||this.render(),this.clipRect&&this.clipRect.animate(this.getClipBox()),this.redrawItems(this.shapes,t),this.redrawItems(this.labels,t),this.redrawControlPoints(t)}redrawItem(t,i){if(t.linkPoints(),t.shouldBeDrawn()){let e,s;t.graphic||this.renderItem(t),t.redraw(S(i,!0)&&t.graphic.placed),t.points.length&&(e=t.graphic,s=t.points.some(t=>!1!==t.series.visible&&!1!==t.visible),e&&(s?"hidden"===e.visibility&&e.show():e.hide()))}else this.destroyItem(t)}redrawItems(t,i){let e=t.length;for(;e--;)this.redrawItem(t[e],i)}remove(){return this.chart.removeAnnotation(this)}render(){let t=this.chart.renderer;this.graphic=t.g("annotation").addClass(this.options.className||"").attr({opacity:0,zIndex:this.options.zIndex,visibility:this.options.visible?"inherit":"hidden"}).add(),this.shapesGroup=t.g("annotation-shapes").add(this.graphic),this.options.crop&&this.shapesGroup.clip(this.chart.plotBoxClip),this.labelsGroup=t.g("annotation-labels").attr({translateX:0,translateY:0}).add(this.graphic),this.addClipPaths(),this.clipRect&&this.graphic.clip(this.clipRect),this.renderItems(this.shapes),this.renderItems(this.labels),this.addEvents(),this.renderControlPoints()}renderItem(t){t.render("label"===t.itemType?this.labelsGroup:this.shapesGroup)}renderItems(t){let i=t.length;for(;i--;)this.renderItem(t[i])}setClipAxes(){let t=this.chart.xAxis,i=this.chart.yAxis,e=[...this.options.labels??[],...this.options.shapes??[]].reduce((e,s)=>{let o=s&&(s.point||"points"in s&&s.points?.[0]);return[t[o&&o.xAxis]||e[0],i[o&&o.yAxis]||e[1]]},[]);this.clipXAxis=e[0],this.clipYAxis=e[1]}setControlPointsVisibility(t){let i=function(i){i.setControlPointsVisibility(t)};this.controlPoints.forEach(i=>{i.setVisibility(t)}),this.shapes.forEach(i),this.labels.forEach(i)}setLabelCollector(){let t=this;t.labelCollector=function(){return t.labels.reduce(function(t,i){return i.options.allowOverlap||t.push(i.graphic),t},[])},t.chart.labelCollectors.push(t.labelCollector)}setOptions(t){var i;this.options=T(this.defaultOptions,t.type&&this.defaultOptions.types?.[t.type]||{},t),(i=this.options).typeOptions||(i.typeOptions={})}setVisibility(t){let i=this.options,e=this.chart.navigationBindings,s=S(t,!i.visible);if(this.graphic.attr("visibility",s?"inherit":"hidden"),!s){let t=function(t){t.setControlPointsVisibility(s)};this.shapes.forEach(t),this.labels.forEach(t),e.activeAnnotation===this&&e.popup&&"annotation-toolbar"===e.popup.type&&w(e,"closePopup")}i.visible=s}update(t,i){let e=this.chart,s=t5(this.userOptions,t),o=e.annotations.indexOf(this),n=T(!0,this.userOptions,t);n.labels=s.labels,n.shapes=s.shapes,this.destroy(),this.initProperties(e,n),this.init(e,n),e.options.annotations[o]=this.options,this.isUpdating=!0,S(i,!0)&&e.drawAnnotations(),w(this,"afterUpdate"),this.isUpdating=!1}}t4.ControlPoint=K,t4.MockPoint=Q,t4.shapesMap={rect:tp,circle:td,ellipse:tu,path:tc,image:tx},t4.types={},t4.prototype.defaultOptions=V,t9.annotations=V,t4.prototype.nonDOMEvents=["add","afterUpdate","drag","remove"],tt.compose(t4);var t6=l||(l={});t6.compose=function(t){return t.navigation||(t.navigation=new t3(t)),t};class t3{constructor(t){this.updates=[],this.chart=t}addUpdate(t){this.chart.navigation.updates.push(t)}update(t,i){this.updates.forEach(e=>{e.call(this.chart,t,i)})}}t6.Additions=t3;let t7=l,t8={backgroundColor:"color",backgroundColors:"color",borderColor:"color",borderRadius:"string",color:"color",fill:"color",fontSize:"string",labels:"string",name:"string",stroke:"color",title:"string"},it={annotationsFieldsTypes:t8,getAssignedAxis:function(t){return t.filter(t=>{let i=t.axis.getExtremes(),e=i.min,s=i.max,o=S(t.axis.minPointOffset,0);return O(e)&&O(s)&&t.value>=e-o&&t.value<=s+o&&!t.axis.options.isInternal})[0]},getFieldType:function(t,i){let e=t8[t],s=typeof i;return b(e)&&(s=e),({string:"text",number:"number",boolean:"checkbox",color:"color"})[s]}},{getAssignedAxis:ii}=it,ie={lang:{navigation:{popup:{simpleShapes:"Simple shapes",lines:"Lines",circle:"Circle",ellipse:"Ellipse",rectangle:"Rectangle",label:"Label",shapeOptions:"Shape options",typeOptions:"Details",fill:"Fill",format:"Text",strokeWidth:"Line width",stroke:"Line color",title:"Title",name:"Name",labelOptions:"Label options",labels:"Labels",backgroundColor:"Background color",backgroundColors:"Background colors",borderColor:"Border color",borderRadius:"Border radius",borderWidth:"Border width",style:"Style",padding:"Padding",fontSize:"Font size",color:"Color",height:"Height",shapes:"Shape options"}}},navigation:{bindingsClassName:"highcharts-bindings-container",bindings:{circleAnnotation:{className:"highcharts-circle-annotation",start:function(t){let i=this.chart.pointer?.getCoordinates(t),e=i&&ii(i.xAxis),s=i&&ii(i.yAxis),o=this.chart.options.navigation;if(e&&s)return this.chart.addAnnotation(T({langKey:"circle",type:"basicAnnotation",shapes:[{type:"circle",point:{x:e.value,y:s.value,xAxis:e.axis.index,yAxis:s.axis.index},r:5}]},o.annotationsOptions,o.bindings.circleAnnotation.annotationsOptions))},steps:[function(t,i){let e,s=i.options.shapes,o=s&&s[0]&&s[0].point||{};if(O(o.xAxis)&&O(o.yAxis)){let i=this.chart.inverted,s=this.chart.xAxis[o.xAxis].toPixels(o.x),n=this.chart.yAxis[o.yAxis].toPixels(o.y);e=Math.max(Math.sqrt(Math.pow(i?n-t.chartX:s-t.chartX,2)+Math.pow(i?s-t.chartY:n-t.chartY,2)),5)}i.update({shapes:[{r:e}]})}]},ellipseAnnotation:{className:"highcharts-ellipse-annotation",start:function(t){let i=this.chart.pointer?.getCoordinates(t),e=i&&ii(i.xAxis),s=i&&ii(i.yAxis),o=this.chart.options.navigation;if(e&&s)return this.chart.addAnnotation(T({langKey:"ellipse",type:"basicAnnotation",shapes:[{type:"ellipse",xAxis:e.axis.index,yAxis:s.axis.index,points:[{x:e.value,y:s.value},{x:e.value,y:s.value}],ry:1}]},o.annotationsOptions,o.bindings.ellipseAnnotation.annotationsOptions))},steps:[function(t,i){let e=i.shapes[0],s=e.getAbsolutePosition(e.points[1]);e.translatePoint(t.chartX-s.x,t.chartY-s.y,1),e.redraw(!1)},function(t,i){let e=i.shapes[0],s=e.getAbsolutePosition(e.points[0]),o=e.getAbsolutePosition(e.points[1]),n=e.getDistanceFromLine(s,o,t.chartX,t.chartY),a=e.getYAxis(),r=Math.abs(a.toValue(0)-a.toValue(n));e.setYRadius(r),e.redraw(!1)}]},rectangleAnnotation:{className:"highcharts-rectangle-annotation",start:function(t){let i=this.chart.pointer?.getCoordinates(t),e=i&&ii(i.xAxis),s=i&&ii(i.yAxis);if(!e||!s)return;let o=e.value,n=s.value,a=e.axis.index,r=s.axis.index,h=this.chart.options.navigation;return this.chart.addAnnotation(T({langKey:"rectangle",type:"basicAnnotation",shapes:[{type:"path",points:[{xAxis:a,yAxis:r,x:o,y:n},{xAxis:a,yAxis:r,x:o,y:n},{xAxis:a,yAxis:r,x:o,y:n},{xAxis:a,yAxis:r,x:o,y:n},{command:"Z"}]}]},h.annotationsOptions,h.bindings.rectangleAnnotation.annotationsOptions))},steps:[function(t,i){let e=i.options.shapes,s=e&&e[0]&&e[0].points||[],o=this.chart.pointer?.getCoordinates(t),n=o&&ii(o.xAxis),a=o&&ii(o.yAxis);if(n&&a){let t=n.value,e=a.value;s[1].x=t,s[2].x=t,s[2].y=e,s[3].y=e,i.update({shapes:[{points:s}]})}}]},labelAnnotation:{className:"highcharts-label-annotation",start:function(t){let i=this.chart.pointer?.getCoordinates(t),e=i&&ii(i.xAxis),s=i&&ii(i.yAxis),o=this.chart.options.navigation;if(e&&s)return this.chart.addAnnotation(T({langKey:"label",type:"basicAnnotation",labelOptions:{format:"{y:.2f}",overflow:"none",crop:!0},labels:[{point:{xAxis:e.axis.index,yAxis:s.axis.index,x:e.value,y:s.value}}]},o.annotationsOptions,o.bindings.labelAnnotation.annotationsOptions))}}},events:{},annotationsOptions:{animation:{defer:0}}}},{setOptions:is}=f(),{format:io}=tf(),{composed:ia,doc:ir,win:ih}=f(),{getAssignedAxis:il,getFieldType:ic}=it;function ip(){this.chart.navigationBindings&&this.chart.navigationBindings.deselectAnnotation()}function id(){this.navigationBindings&&this.navigationBindings.destroy()}function iu(){let t=this.options;t&&t.navigation&&t.navigation.bindings&&(this.navigationBindings=new ix(this,t.navigation),this.navigationBindings.initEvents(),this.navigationBindings.initUpdate())}function ig(){let t=this.navigationBindings,i="highcharts-disabled-btn";if(this&&t){let e=!1;if(this.series.forEach(t=>{!t.options.isInternal&&t.visible&&(e=!0)}),this.navigationBindings&&this.navigationBindings.container&&this.navigationBindings.container[0]){let s=this.navigationBindings.container[0];I(t.boundClassNames,(t,o)=>{let n=s.querySelectorAll("."+o);if(n)for(let s=0;s<n.length;s++){let o=n[s],a=o.className;"normal"===t.noDataState||e?-1!==a.indexOf(i)&&o.classList.remove(i):-1===a.indexOf(i)&&(o.className+=" "+i)}})}}}function iy(){this.deselectAnnotation()}function im(){this.selectedButtonElement=null}function iv(t){let i,e,s=t.prototype.defaultOptions.events&&t.prototype.defaultOptions.events.click;function o(t){let i=this,e=i.chart.navigationBindings,o=e.activeAnnotation;s&&s.call(i,t),o!==i?(e.deselectAnnotation(),e.activeAnnotation=i,i.setControlPointsVisibility(!0),w(e,"showPopup",{annotation:i,formType:"annotation-toolbar",options:e.annotationToFields(i),onSubmit:function(t){if("remove"===t.actionType)e.activeAnnotation=!1,e.chart.removeAnnotation(i);else{let s={};e.fieldsToOptions(t.fields,s),e.deselectAnnotation();let o=s.typeOptions;"measure"===i.options.type&&(o.crosshairY.enabled=0!==o.crosshairY.strokeWidth,o.crosshairX.enabled=0!==o.crosshairX.strokeWidth),i.update(s)}}})):w(e,"closePopup"),t.activeAnnotation=!0}T(!0,t.prototype.defaultOptions.events,{click:o,touchstart:function(t){i=t.touches[0].clientX,e=t.touches[0].clientY},touchend:function(t){i&&Math.sqrt(Math.pow(i-t.changedTouches[0].clientX,2)+Math.pow(e-t.changedTouches[0].clientY,2))>=4||o.call(this,t)}})}class ix{static compose(t,i){L(ia,"NavigationBindings")&&(v(t,"remove",ip),iv(t),I(t.types,t=>{iv(t)}),v(i,"destroy",id),v(i,"load",iu),v(i,"render",ig),v(ix,"closePopup",iy),v(ix,"deselectButton",im),is(ie))}constructor(t,i){this.boundClassNames=void 0,this.chart=t,this.options=i,this.eventsToUnbind=[],this.container=this.chart.container.getElementsByClassName(this.options.bindingsClassName||""),this.container.length||(this.container=ir.getElementsByClassName(this.options.bindingsClassName||""))}getCoords(t){let i=this.chart.pointer?.getCoordinates(t);return[i&&il(i.xAxis),i&&il(i.yAxis)]}initEvents(){let t=this,i=t.chart,e=t.container,s=t.options;t.boundClassNames={},I(s.bindings||{},i=>{t.boundClassNames[i.className]=i}),[].forEach.call(e,i=>{t.eventsToUnbind.push(v(i,"click",e=>{let s=t.getButtonEvents(i,e);s&&!s.button.classList.contains("highcharts-disabled-btn")&&t.bindingsButtonClick(s.button,s.events,e)}))}),I(s.events||{},(i,e)=>{"function"==typeof i&&t.eventsToUnbind.push(v(t,e,i,{passive:!1}))}),t.eventsToUnbind.push(v(i.container,"click",function(e){!i.cancelClick&&i.isInsidePlot(e.chartX-i.plotLeft,e.chartY-i.plotTop,{visiblePlotOnly:!0})&&t.bindingsChartClick(this,e)})),t.eventsToUnbind.push(v(i.container,f().isTouchDevice?"touchmove":"mousemove",function(i){t.bindingsContainerMouseMove(this,i)},f().isTouchDevice?{passive:!1}:void 0))}initUpdate(){let t=this;t7.compose(this.chart).navigation.addUpdate(i=>{t.update(i)})}bindingsButtonClick(t,i,e){let s=this.chart,o=s.renderer.boxWrapper,n=!0;this.selectedButtonElement&&(this.selectedButtonElement.classList===t.classList&&(n=!1),w(this,"deselectButton",{button:this.selectedButtonElement}),this.nextEvent&&(this.currentUserDetails&&"annotations"===this.currentUserDetails.coll&&s.removeAnnotation(this.currentUserDetails),this.mouseMoveEvent=this.nextEvent=!1)),n?(this.selectedButton=i,this.selectedButtonElement=t,w(this,"selectButton",{button:t}),i.init&&i.init.call(this,t,e),(i.start||i.steps)&&s.renderer.boxWrapper.addClass("highcharts-draw-mode")):(s.stockTools&&t.classList.remove("highcharts-active"),o.removeClass("highcharts-draw-mode"),this.nextEvent=!1,this.mouseMoveEvent=!1,this.selectedButton=null)}bindingsChartClick(t,i){t=this.chart;let e=this.activeAnnotation,s=this.selectedButton,o=t.renderer.boxWrapper;e&&(e.cancelClick||i.activeAnnotation||!i.target.parentNode||function(t,i){let e=ih.Element.prototype,s=e.matches||e.msMatchesSelector||e.webkitMatchesSelector,o=null;if(e.closest)o=e.closest.call(t,i);else do{if(s.call(t,i))return t;t=t.parentElement||t.parentNode}while(null!==t&&1===t.nodeType);return o}(i.target,".highcharts-popup")?e.cancelClick&&setTimeout(()=>{e.cancelClick=!1},0):w(this,"closePopup")),s&&s.start&&(this.nextEvent?(this.nextEvent(i,this.currentUserDetails),this.steps&&(this.stepIndex++,s.steps[this.stepIndex]?this.mouseMoveEvent=this.nextEvent=s.steps[this.stepIndex]:(w(this,"deselectButton",{button:this.selectedButtonElement}),o.removeClass("highcharts-draw-mode"),s.end&&s.end.call(this,i,this.currentUserDetails),this.nextEvent=!1,this.mouseMoveEvent=!1,this.selectedButton=null))):(this.currentUserDetails=s.start.call(this,i),this.currentUserDetails&&s.steps?(this.stepIndex=0,this.steps=!0,this.mouseMoveEvent=this.nextEvent=s.steps[this.stepIndex]):(w(this,"deselectButton",{button:this.selectedButtonElement}),o.removeClass("highcharts-draw-mode"),this.steps=!1,this.selectedButton=null,s.end&&s.end.call(this,i,this.currentUserDetails))))}bindingsContainerMouseMove(t,i){this.mouseMoveEvent&&this.mouseMoveEvent(i,this.currentUserDetails)}fieldsToOptions(t,i){return I(t,(t,e)=>{let s=parseFloat(t),o=e.split("."),n=o.length-1;if(!O(s)||t.match(/px|em/g)||e.match(/format/g)||(t=s),"undefined"!==t){let e=i;o.forEach((i,s)=>{if("__proto__"!==i&&"constructor"!==i){let a=S(o[s+1],"");n===s?e[i]=t:(e[i]||(e[i]=a.match(/\d/g)?[]:{}),e=e[i])}})}}),i}deselectAnnotation(){this.activeAnnotation&&(this.activeAnnotation.setControlPointsVisibility(!1),this.activeAnnotation=!1)}annotationToFields(t){let i=t.options,e=ix.annotationsEditable,s=e.nestedOptions,o=S(i.type,i.shapes?.[0]?.type,i.labels?.[0]?.type,"label"),n=ix.annotationsNonEditable[i.langKey]||[],a={langKey:i.langKey,type:o};function r(i,e,o,a,h){let l;o&&b(i)&&-1===n.indexOf(e)&&((o.indexOf&&o.indexOf(e))>=0||o[e]||!0===o)&&(N(i)?(a[e]=[],i.forEach((t,i)=>{M(t)?(a[e][i]={},I(t,(t,o)=>{r(t,o,s[e],a[e][i],e)})):r(t,0,s[e],a[e],e)})):M(i)?(l={},N(a)?(a.push(l),l[e]={},l=l[e]):a[e]=l,I(i,(t,i)=>{r(t,i,0===e?o:s[e],l,e)})):"format"===e?a[e]=[io(i,t.labels[0].points[0]).toString(),"text"]:N(a)?a.push([i,ic(h,i)]):a[e]=[i,ic(e,i)])}return I(i,(t,n)=>{"typeOptions"===n&&"basicAnnotation"!==a.type?(a[n]={},I(i[n],(t,i)=>{r(t,i,s,a[n],i)})):r(t,n,e[o],a,n)}),a}getClickedClassNames(t,i){var e,s;let o,n,a,r=i.target,h=[],l;for(;r&&r.tagName&&(e=r,n=B(s="class")&&!b(void 0),a=(t,i)=>{b(t)?e.setAttribute(i,t):n?(o=e.getAttribute(i))||"class"!==i||(o=e.getAttribute(i+"Name")):e.removeAttribute(i)},B(s)?a(void 0,s):I(s,a),(l=o)&&(h=h.concat(l.split(" ").map(t=>[t,r]))),(r=r.parentNode)!==t););return h}getButtonEvents(t,i){let e,s=this;return this.getClickedClassNames(t,i).forEach(t=>{s.boundClassNames[t[0]]&&!e&&(e={events:s.boundClassNames[t[0]],button:t[1]})}),e}update(t){this.options=T(!0,this.options,t),this.removeEvents(),this.initEvents()}removeEvents(){this.eventsToUnbind.forEach(t=>t())}destroy(){this.removeEvents()}}ix.annotationsEditable={nestedOptions:{labelOptions:["style","format","backgroundColor"],labels:["style"],label:["style"],style:["fontSize","color"],background:["fill","strokeWidth","stroke"],innerBackground:["fill","strokeWidth","stroke"],outerBackground:["fill","strokeWidth","stroke"],shapeOptions:["fill","strokeWidth","stroke"],shapes:["fill","strokeWidth","stroke"],line:["strokeWidth","stroke"],backgroundColors:[!0],connector:["fill","strokeWidth","stroke"],crosshairX:["strokeWidth","stroke"],crosshairY:["strokeWidth","stroke"]},circle:["shapes"],ellipse:["shapes"],verticalLine:[],label:["labelOptions"],measure:["background","crosshairY","crosshairX"],fibonacci:[],tunnel:["background","line","height"],pitchfork:["innerBackground","outerBackground"],rect:["shapes"],crookedLine:[],basicAnnotation:["shapes","labelOptions"]},ix.annotationsNonEditable={rectangle:["crosshairX","crosshairY","labelOptions"],ellipse:["labelOptions"],circle:["labelOptions"]};let ib=f();ib.Annotation=ib.Annotation||t4,ib.NavigationBindings=ib.NavigationBindings||ix,ib.Annotation.compose(ib.Chart,ib.NavigationBindings,ib.Pointer,ib.SVGRenderer);let iA=f();return u.default})());