!/**
 * Highcharts JS v12.6.0 (2026-04-13)
 * @module highcharts/modules/annotations-advanced
 * @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-advanced",["highcharts/highcharts"],function(t){return i(t,t.SeriesRegistry,t.Templating,t.AST,t.Color)}):"object"==typeof exports?exports["highcharts/modules/annotations-advanced"]=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,s,e,o)=>(()=>{"use strict";var n,a,r,h,l,p={512:t=>{t.exports=i},620:t=>{t.exports=o},660:t=>{t.exports=e},944:i=>{i.exports=t},984:t=>{t.exports=s}},c={};function d(t){var i=c[t];if(void 0!==i)return i.exports;var s=c[t]={exports:{}};return p[t](s,s.exports,d),s.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 s in i)d.o(i,s)&&!d.o(t,s)&&Object.defineProperty(t,s,{enumerable:!0,get:i[s]})},d.o=(t,i)=>Object.prototype.hasOwnProperty.call(t,i);var u={};d.d(u,{default:()=>i1});var x=d(944),g=d.n(x);let{doc:y,win:f}=g();function m(t,i,s,e={}){let o="function"==typeof t&&t.prototype||t;Object.hasOwnProperty.call(o,"hcEvents")||(o.hcEvents={});let n=o.hcEvents;g().Point&&t instanceof g().Point&&t.series&&t.series.chart&&(t.series.chart.runTrackerClick=!0);let a=t.addEventListener;a&&a.call(t,i,s,!!g().supportsPassiveEvents&&{passive:void 0===e.passive?-1!==i.indexOf("touch"):e.passive,capture:!1}),n[i]||(n[i]=[]);let r={fn:s,order:"number"==typeof e.order?e.order:1/0};return n[i].push(r),n[i].sort((t,i)=>t.order-i.order),function(){X(t,i,s)}}function v(t,i,s,e,o){var n,a,r;let h=y.createElement(t);return i&&P(h,i),o&&(n={padding:"0",border:"none",margin:"0"},P(h.style,n)),s&&(a=h,r=s,P(a.style,r)),e&&e.appendChild(h),h}function b(t){return null!=t}function A(t,i){let s=t.length;for(;s--;)if(t[s]===i){t.splice(s,1);break}}function P(t,i){let s;for(s in t||(t={}),i)t[s]=i[s];return t}function O(t,i,s,e){if(s=s||{},y?.createEvent&&(t.dispatchEvent||t.fireEvent&&t!==g())){let e=y.createEvent("Events");e.initEvent(i,!0,!0),s=P(e,s),t.dispatchEvent?t.dispatchEvent(s):t.fireEvent(i,s)}else if(t.hcEvents){s.target||P(s,{preventDefault:function(){s.defaultPrevented=!0},target:t,type:i});let e=[],o=t,n=!1;for(;o.hcEvents;)Object.hasOwnProperty.call(o,"hcEvents")&&o.hcEvents[i]&&(e.length&&(n=!0),e.unshift.apply(e,o.hcEvents[i])),o=Object.getPrototypeOf(o);n&&e.sort((t,i)=>t.order-i.order),e.forEach(i=>{!1===i.fn.call(t,s,t)&&s.preventDefault()})}e&&!s.defaultPrevented&&e.call(t,s)}let M=(t="")=>({center:.5,right:1,middle:.5,bottom:1})[t]||0,k=Array.prototype.find?function(t,i){return t.find(i)}:function(t,i){let s,e=t.length;for(s=0;s<e;s++)if(i(t[s],s))return t[s]};function w(t){return N(t)&&"number"==typeof t.nodeType}function C(t){return"number"==typeof t&&!isNaN(t)&&t<1/0&&t>-1/0}function E(t){return"string"==typeof t}function T(t){let i=Object.prototype.toString.call(t);return"[object Array]"===i||"[object Array Iterator]"===i}function N(t,i){return!!t&&"object"==typeof t&&(!i||!T(t))}function B(t,...i){let s,e=[t,...i],o={},n=function(t,i){return"object"!=typeof t&&(t={}),L(i,function(s,e){if("__proto__"!==e&&"constructor"!==e){let o;!N(s,!0)||(o=s?.constructor,N(s,!0)&&!w(s)&&o?.name&&"Object"!==o.name)||w(s)?t[e]=i[e]:t[e]=n(t[e]||{},s)}}),t};!0===t&&(o=e[1],e=Array.prototype.slice.call(e,2));let a=e.length;for(s=0;s<a;s++)o=n(o,e[s]);return o}function L(t,i,s){for(let e in t)Object.hasOwnProperty.call(t,e)&&i.call(s||t[e],t[e],e,t)}function S(){let t=arguments,i=t.length;for(let s=0;s<i;s++){let i=t[s];if(null!=i)return i}}function Y(t,i){return 0>t.indexOf(i)&&!!t.push(i)}function X(t,i,s){function e(i,s){let e=t.removeEventListener;e&&e.call(t,i,s,!1)}function o(s){let o,n;t.nodeName&&(i?(o={})[i]=!0:o=s,L(o,function(t,i){if(s[i])for(n=s[i].length;n--;)e(i,s[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]||[];s?(t[i]=n.filter(function(t){return s!==t.fn}),e(i,s)):(o(t),t[i]=[])}else o(t),delete n.hcEvents}}function I(t,i){let s,e,o=t.length;for(e=0;e<o;e++)t[e].safeI=e;for(t.sort(function(t,e){return 0===(s=i(t,e))?t.safeI-e.safeI:s}),e=0;e<o;e++)delete t[e].safeI}function D(t,i,s){let e=t[i];t[i]=function(){let t=arguments,i=this;return s.apply(this,[function(){return e.apply(i,arguments.length?arguments:t)}].concat([].slice.call(arguments)))}}function R(t,i){let s=this.initAnnotation(t);return this.options.annotations.push(s.options),S(i,!0)&&(s.redraw(),s.graphic.attr({opacity:1})),s}function W(){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,s)=>{if(!t.annotations.some(t=>t.options===i)){let e=t.initAnnotation(i);t.options.annotations[s]=e.options}}),t.drawAnnotations(),m(t,"redraw",t.drawAnnotations),m(t,"destroy",function(){t.plotBoxClip.destroy(),t.controlPointsGroup.destroy()}),m(t,"exportData",function(i){let s=t.annotations,e=(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;s.forEach(t=>{t.options.labelOptions?.includeInDataExport&&t.labels.forEach(t=>{if(t.options.text){let s=t.options.text;t.points.forEach(t=>{let e=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(s),a.xValues=[],a.xValues[o]=e,i.dataRows.push(a),n=!0}if(n||i.dataRows.forEach(t=>{!n&&t.xValues&&void 0!==o&&e===t.xValues[o]&&(h&&t.length>a?t[t.length-1]+=r+s:t.push(s),n=!0)}),!n){let t=i.dataRows[0].length,n=Array(t);for(let i=0;i<t;++i)n[i]="";n[0]=e,n.push(s),n.xValues=[],void 0!==o&&(n.xValues[o]=e),i.dataRows.push(n)}})}})});let l=0;i.dataRows.forEach(t=>{l=Math.max(l,t.length)});let p=l-i.dataRows[0].length;for(let t=0;t<p;t++){let s=function(t){let i;return e&&!1!==(i=e(t))?i:(i=n+" "+t,o)?{columnTitle:i,topLevelColumnTitle:i}:i}(t+1);o?(i.dataRows[0].push(s.topLevelColumnTitle),i.dataRows[1].push(s.columnTitle)):i.dataRows[0].push(s)}})}function F(){this.plotBoxClip.attr(this.plotBox),this.annotations.forEach(t=>{t.redraw(),t.graphic.animate({opacity:1},t.animationConfig)})}function z(t){let i=this.annotations,s="annotations"===t.coll?t:k(i,function(i){return i.options.id===t});s&&(O(s,"remove"),A(this.options.annotations,s.options),A(i,s),s.destroy())}function U(){let t=this.options.annotations,i=this.userOptions.annotations;this.annotations=[],T(this.options.annotations)||(this.options.annotations=[]),N(i,!0)&&N(t,!0)&&this.options.annotations.push(t)}function H(t){this.chart.hasDraggedAnnotation||t.apply(this,Array.prototype.slice.call(arguments,1))}(a||(a={})).compose=function(t,i,s){let e=i.prototype;if(!e.addAnnotation){let o=s.prototype;m(i,"afterInit",U),e.addAnnotation=R,e.callbacks.push(W),e.collectionsWithInit.annotations=[R],e.collectionsWithUpdate.push("annotations"),e.drawAnnotations=F,e.removeAnnotation=z,e.initAnnotation=function(i){let s=new(t.types[i.type]||t)(this,i);return this.annotations.push(s),s},D(o,"onContainerMouseDown",H)}};let V=a,j={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:_}=g(),G=class{addEvents(){let t=this,i=function(i){m(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)}),L(t.options.events,(i,s)=>{let e=function(e){"click"===s&&t.cancelClick||i.call(t,t.chart.pointer?.normalize(e),t.target,t)};-1===(t.nonDOMEvents||[]).indexOf(s)?(m(t.graphic.element,s,e,{passive:!1}),t.graphic.div&&m(t.graphic.div,s,e,{passive:!1})):m(t,s,e,{passive:!1})}),t.options.draggable&&(m(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||O(t,"add")}destroy(){this.removeDocEvents(),X(this),this.hcEvents=null}mouseMoveToRadians(t,i,s){let e=t.prevChartY-s,o=t.prevChartX-i,n=t.chartY-s,a=t.chartX-i,r;return this.chart.inverted&&(r=o,o=e,e=r,r=a,a=n,n=r),Math.atan2(n,a)-Math.atan2(e,o)}mouseMoveToScale(t,i,s){let e=t.prevChartX-i,o=t.prevChartY-s,n=t.chartX-i,a=t.chartY-s,r=(n||1)/(e||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,s=t.chartY-t.prevChartY,e;return this.chart.inverted&&(e=s,s=i,i=e),{x:i,y:s}}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,s=i.chart.pointer,e=t?.sourceCapabilities?.firesTouchEvents||!1,o=(t=s?.normalize(t)||t).chartX,n=t.chartY;i.cancelClick=!1,i.chart.hasDraggedAnnotation=!0,i.removeDrag=m(q,_||e?"touchmove":"mousemove",function(t){i.hasDragged=!0,(t=s?.normalize(t)||t).prevChartX=o,t.prevChartY=n,O(i,"drag",t),o=t.chartX,n=t.chartY},_||e?{passive:!1}:void 0),i.removeMouseUp=m(q,_||e?"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&&O(S(t,i),"afterUpdate"),i.hasDragged=!1,i.onMouseUp()},_||e?{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,s,e){super(),this.nonDOMEvents=["drag"],this.chart=t,this.target=i,this.options=s,this.index=S(s.index,e)}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,s=this.target,e=this.index,o=B(!0,this.options,t);this.destroy(),this.constructor(i,s,o,e),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 s=t.series,e=s.chart,o=t.plotX||0,n=t.plotY||0,a;return e.inverted&&(t.mock?(o=t.plotY,n=t.plotX):(o=e.plotWidth-(t.plotY||0),n=e.plotHeight-(t.plotX||0))),s&&!i&&(o+=(a=s.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,s){this.mock=!0,this.point=this,this.series={visible:!0,chart:t,getPlotBox:J.getPlotBox},this.target=i||null,this.options=s,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,s=this.series.xAxis,e=this.series.yAxis,o={x:t,y:i,isInsidePlot:!0,options:{}};return s&&(o.isInsidePlot=b(t)&&t>=0&&t<=s.len),e&&(o.isInsidePlot=o.isInsidePlot&&b(i)&&i>=0&&i<=e.len),O(this.series.chart,"afterIsInsidePlot",o),o.isInsidePlot}refresh(){let t=this.series,i=t.xAxis,s=t.yAxis,e=this.getOptions();i?(this.x=e.x,this.plotX=i.toPixels(e.x,!0)):(this.x=void 0,this.plotX=e.x),s?(this.y=e.y,this.plotY=s.toPixels(e.y,!0)):(this.y=null,this.plotY=e.y),this.isInside=this.isInsidePlot()}refreshOptions(){let t=this.series,i=t.xAxis,s=t.yAxis;this.x=this.options.x=i?this.options.x=i.toValue(this.plotX,!0):this.plotX,this.y=this.options.y=s?s.toValue(this.plotY,!0):this.plotY}rotate(t,i,s){if(!this.hasDynamicOptions()){let e=Math.cos(s),o=Math.sin(s),n=this.plotX-t,a=this.plotY-i;this.plotX=n*e-a*o+t,this.plotY=n*o+a*e+i,this.refreshOptions()}}scale(t,i,s,e){if(!this.hasDynamicOptions()){let o=this.plotX*s,n=this.plotY*e;this.plotX=(1-s)*t+o,this.plotY=(1-e)*i+n,this.refreshOptions()}}setAxis(t,i){let s=i+"Axis",e=t[s],o=this.series.chart;this.series[s]="object"==typeof e?e:b(e)?o[s][e]||o.get(e):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,s,e){this.hasDynamicOptions()||(this.plotX+=s,this.plotY+=e,this.refreshOptions())}}!function(t){function i(){let t=this.controlPoints,i=this.options.controlPoints||[];i.forEach((s,e)=>{let o=B(this.options.controlPointOptions,s);o.index||(o.index=e),i[e]=o,t.push(new K(this.chart,this,o))})}function s(t){let i=t.series.getPlotBox(),s=t.series.chart,e=t.mock?t.toAnchor():s.tooltip&&s.tooltip.getAnchor.call({chart:t.series.chart},t)||[0,0,0,0],o={x:e[0]+(this.options.x||0),y:e[1]+(this.options.y||0),height:e[2]||0,width:e[3]||0};return{relativePosition:o,absolutePosition:B(o,{x:o.x+(t.mock?i.translateX:s.plotLeft),y:o.y+(t.mock?i.translateY:s.plotTop)})}}function e(){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&&(T(t=i.point)?t:[t])}function n(){let t,i,s=this.getPointsOptions(),e=this.points,o=s?.length||0;for(t=0;t<o;t++){if(!(i=this.point(s[t],e[t]))){e.length=0;return}i.mock&&i.refresh(),e[t]=i}return e}function a(t,i){if(t&&t.series)return t;if(!i||null===i.series){if(N(t))i=new Q(this.chart,this,t);else if(E(t))i=this.chart.get(t)||null;else if("function"==typeof t){let s=t.call(i,this);i=s.series?s: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,s,e,o){if(this.chart.inverted){let t=i;i=s,s=t}this.points.forEach((n,a)=>this.transformPoint(t,i,s,e,o,a),this)}function p(t,i,s,e,o,n){let a=this.points[n];a.mock||(a=this.points[n]=Q.fromPoint(a)),a[t](i,s,e,o)}function c(t,i){this.transform("translate",null,null,t,i)}function d(t,i,s){this.transformPoint("translate",null,null,t,i,s)}t.compose=function(t){let u=t.prototype;u.addControlPoints||B(!0,u,{addControlPoints:i,anchor:s,destroyControlTarget:e,getPointsOptions:o,linkPoints:n,point:a,redrawControlPoints:r,renderControlPoints:h,transform:l,transformPoint:p,translate:c,translatePoint:d})}}(r||(r={}));let tt=r;class ti{constructor(t,i,s,e){this.annotation=t,this.chart=t.chart,this.collection="label"===e?"labels":"shapes",this.controlPoints=[],this.options=i,this.points=[],this.index=s,this.itemType=e,this.init(t,i,s)}attr(){this.graphic.attr.apply(this.graphic,arguments)}attrsFromOptions(t){let i,s,e=this.constructor.attrsMap,o={},n=this.chart.styledMode;for(i in t)s=e[i],void 0===e[i]||n&&-1!==["fill","stroke","stroke-width"].indexOf(s)||(o[s]=t[i]);return o}destroy(){this.graphic&&(this.graphic=this.graphic.destroy()),this.tracker&&(this.tracker=this.tracker.destroy()),this.destroyControlTarget()}calculateAnnotationSize(t,i,s){let e=s.toPixels(t,!0);return Math.abs(s.toPixels(t+i,!0)-e)}init(t,i,s){this.annotation=t,this.chart=t.chart,this.options=i,this.points=[],this.controlPoints=[],this.index=s,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,s){this.transform("rotate",t,i,s)}scale(t,i,s,e){this.transform("scale",t,i,s,e)}setControlPointsVisibility(t){this.controlPoints.forEach(i=>{i.setVisibility(t)})}shouldBeDrawn(){return!!this.points.length}translateShape(t,i,s){let e=this.annotation.chart,o=this.annotation.userOptions,n=e.annotations.indexOf(this.annotation),a=e.options.annotations[n];this.translatePoint(t,i,0),s&&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,s=B(!0,this.options,t),e=this.graphic.parentGroup,o=this.constructor;this.destroy(),B(!0,this,new o(i,s,this.index,this.itemType)),this.render(e),this.redraw()}}tt.compose(ti);let ts=ti,{defaultMarkers:te}={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,"+(g().svg?1e-4:.002)+")";function tr(t){return function(i){this.attr(t,"url(#"+i+")")}}function th(){this.options.defs=B(te,this.options.defs||{})}function tl(t,i){let s={attributes:{id:t}},e={stroke:i.color||"none",fill:i.color||"rgba(0, 0, 0, 0.75)"};s.children=i.children&&i.children.map(function(t){return B(e,t)});let o=B(!0,{attributes:{markerWidth:20,markerHeight:20,refX:0,refY:0,orient:"auto"}},i,s),n=this.definition(o);return n.id=t,n}class tp extends ts{static compose(t,i){let s=i.prototype;s.addMarker||(m(t,"afterGetContainer",th),s.addMarker=tl)}constructor(t,i,s){super(t,i,s,"shape"),this.type="path"}init(t,i,s){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,s)}toD(){let t=this.options.d;if(t)return"function"==typeof t?t.call(this):t;let i=this.points,s=i.length,e=[],o=s,n=i[0],a=o&&this.anchor(n).absolutePosition,r=0,h;if(a)for(e.push(["M",a.x,a.y]);++r<s&&o;)h=(n=i[r]).command||"L",a=this.anchor(n).absolutePosition,"M"===h||"L"===h?e.push([h,a.x,a.y]):"Z"===h&&e.push([h]),o=n.series.visible;return o&&this.graphic?this.chart.renderer.crispLine(e,this.graphic.strokeWidth()):null}shouldBeDrawn(){return super.shouldBeDrawn()||!!this.options.d}render(t){let i=this.options,s=this.attrsFromOptions(i);this.graphic=this.annotation.chart.renderer.path([["M",0,0]]).attr(s).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(),P(this.graphic,{markerStartSetter:tn,markerEndSetter:to}),this.setMarkers(this)}redraw(t){if(this.graphic){let i=this.toD(),s=t?"animate":"attr";i?(this.graphic[s]({d:i}),this.tracker[s]({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,s=t.chart,e=s.options.defs,o=i.fill,n=b(o)&&"none"!==o?o:i.stroke;["markerStart","markerEnd"].forEach(function(o){let a,r,h,l,p=i[o];if(p){for(h in e)if((p===((a=e[h]).attributes&&a.attributes.id)||p===a.id)&&"marker"===a.tagName){r=a;break}r&&(l=t[o]=s.renderer.addMarker((i.id||(0,x.uniqueKey)())+"-"+p,B(r,{color:n})),t.attr(o,l.getAttribute("id")))}})}}tp.attrsMap={dashStyle:"dashstyle",strokeWidth:"stroke-width",stroke:"stroke",fill:"fill",zIndex:"zIndex"};class tc extends ts{constructor(t,i,s){super(t,i,s,"shape"),this.type="rect",this.translate=super.translateShape}init(t,i,s){let{point:e,xAxis:o,yAxis:n}=i;e&&"string"!=typeof e&&(b(o)&&(e.xAxis=o),b(n)&&(e.yAxis=n)),super.init(t,i,s)}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],s=this.anchor(i).absolutePosition,e=this.options.width||0,o=this.options.height||0;if(s){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)&&(e=this.calculateAnnotationSize(i.x,e,n)),a&&b(i.y)&&(o=this.calculateAnnotationSize(i.y,o,a)),this.graphic[t?"animate":"attr"]({x:s.x,y:s.y,width:e,height:o})}else this.attr({x:0,y:-9e9});this.graphic.placed=!!s}super.redraw(t)}}tc.attrsMap=B(tp.attrsMap,{width:"width",height:"height"});class td extends ts{constructor(t,i,s){super(t,i,s,"shape"),this.type="circle",this.translate=super.translateShape}init(t,i,s){let{point:e,xAxis:o,yAxis:n}=i;e&&"string"!=typeof e&&(b(o)&&(e.xAxis=o),b(n)&&(e.yAxis=n)),super.init(t,i,s)}redraw(t){if(this.graphic){let i=this.points[0],s=this.anchor(i).absolutePosition,e=this.options.r||0;if(s){let o=b(this.options.yAxis)?this.chart.yAxis[this.options.yAxis]:void 0;o&&b(i.y)&&(e=this.calculateAnnotationSize(i.y,e,o)),this.graphic[t?"animate":"attr"]({x:s.x,y:s.y,r:e})}else this.graphic.attr({x:0,y:-9e9});this.graphic.placed=!!s}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=B(tp.attrsMap,{r:"r"});class tu extends ts{constructor(t,i,s){super(t,i,s,"shape"),this.type="ellipse"}init(t,i,s){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,s)}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,s,e){return Math.abs((i.y-t.y)*s-(i.x-t.x)*e+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 s=t.x,e=t.y,o=i.x,n=i.y,a=(s+o)/2,r=Math.sqrt((s-o)*(s-o)/4+(e-n)*(e-n)/4),h=180*Math.atan((n-e)/(o-s))/Math.PI;return a<s&&(h+=180),{cx:a,cy:(e+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]),s=this.getAbsolutePosition(this.points[1]),e=this.getAttrs(i,s);i?this.graphic[t?"animate":"attr"]({cx:e.cx,cy:e.cy,rx:e.rx,ry:e.ry,rotation:e.angle,rotationOriginX:e.cx,rotationOriginY:e.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=B(tp.attrsMap,{ry:"ry"});var tx=d(984),tg=d.n(tx);let{format:ty}=tg();function tf(t,i,s,e,o){let n=o&&o.anchorX,a=o&&o.anchorY,r,h,l=s/2;return C(n)&&C(a)&&(r=[["M",n,a]],(h=i-a)<0&&(h=-e-h),h<s&&(l=n<t+s/2?h:s-h),a>i+e?r.push(["L",t+l,i+e]):a<i?r.push(["L",t+l,i]):n<t?r.push(["L",t,i+e/2]):n>t+s&&r.push(["L",t+s,i+e/2])),r||[]}class tm extends ts{static alignedPosition(t,i){return{x:Math.round((i.x||0)+(t.x||0)+(i.width-(t.width||0))*M(t.align)),y:Math.round((i.y||0)+(t.y||0)+(i.height-(t.height||0))*M(t.verticalAlign))}}static compose(t){t.prototype.symbols.connector=tf}static justifiedOptions(t,i,s,e){let o,n=s.align,a=s.verticalAlign,r=i.box?0:i.padding||0,h=i.getBBox(),l={align:n,verticalAlign:a,x:s.x,y:s.y,width:i.width,height:i.height},p=(e.x||0)-t.plotLeft,c=(e.y||0)-t.plotTop;return(o=p+r)<0&&("right"===n?l.align="left":l.x=(l.x||0)-o),(o=p+h.width-r)>t.plotWidth&&("left"===n?l.align="right":l.x=(l.x||0)+t.plotWidth-o),(o=c+r)<0&&("bottom"===a?l.verticalAlign="top":l.y=(l.y||0)-o),(o=c+h.height-r)>t.plotHeight&&("top"===a?l.verticalAlign="bottom":l.y=(l.y||0)+t.plotHeight-o),l}constructor(t,i,s){super(t,i,s,"label")}translatePoint(t,i){super.translatePoint(t,i,0)}translate(t,i){var s,e;let o=this.annotation.chart,n=this.annotation.userOptions,a=o.annotations.indexOf(this.annotation),r=o.options.annotations[a];if(o.inverted){let s=t;t=i,i=s}(s=this.options).x||(s.x=0),(e=this.options).y||(e.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,s=this.attrsFromOptions(i),e=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(s).add(t),!this.annotation.chart.styledMode){if(e?.color==="contrast"){let t=!i.shape||tm.shapesWithoutBackground.indexOf(i.shape)>-1||"none"===i.backgroundColor?n:i.backgroundColor;e.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,s=this.text||i.format||i.text,e=this.graphic,o=this.points[0];if(!e)return void this.redraw(t);e.attr({text:s?ty(String(s),o,this.annotation.chart):i.formatter.call(o,o)});let n=this.anchor(o),a=this.position(n);a?(e.alignAttr=a,a.anchorX=n.absolutePosition.x,a.anchorY=n.absolutePosition.y,e[t?"animate":"attr"](a)):e.attr({x:0,y:-9999}),e.placed=!!a,super.redraw(t)}anchor(t){let i=super.anchor.apply(this,arguments),s=this.options.x||0,e=this.options.y||0;return i.absolutePosition.x-=s,i.absolutePosition.y-=e,i.relativePosition.x-=s,i.relativePosition.y-=e,i}position(t){let i=this.graphic,s=this.annotation.chart,e=s.tooltip,o=this.points[0],n=this.options,a=t.absolutePosition,r=t.relativePosition,h,l,p,c,d=o.series.visible&&Q.prototype.isInsidePlot.call(o);if(i&&d){let{width:t=0,height:u=0}=i;n.distance&&e?h=e.getPosition.call({chart:s,distance:S(n.distance,16),getPlayingField:e.getPlayingField,pointer:e.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=tm.alignedPosition(P(n,{width:t,height:u}),l),"justify"===this.options.overflow&&(h=tm.alignedPosition(tm.justifiedOptions(s,i,n,h),l))),n.crop&&(p=h.x-s.plotLeft,c=h.y-s.plotTop,d=s.isInsidePlot(p,c)&&s.isInsidePlot(p+t,c+u))}return d?h:null}}tm.attrsMap={backgroundColor:"fill",borderColor:"stroke",borderWidth:"stroke-width",zIndex:"zIndex",borderRadius:"r",padding:"padding"},tm.shapesWithoutBackground=["connector"];class tv extends ts{constructor(t,i,s){super(t,i,s,"shape"),this.type="image",this.translate=super.translateShape}render(t){let i=this.attrsFromOptions(this.options),s=this.options;this.graphic=this.annotation.chart.renderer.image(s.src,0,-9e9,s.width,s.height).attr(i).add(t),this.graphic.width=s.width,this.graphic.height=s.height,super.render()}redraw(t){if(this.graphic){let i=this.anchor(this.points[0]),s=tm.prototype.position.call(this,i);s?this.graphic[t?"animate":"attr"]({x:s.x,y:s.y}):this.graphic.attr({x:0,y:-9e9}),this.graphic.placed=!!s}super.redraw(t)}}tv.attrsMap={width:"width",height:"height",zIndex:"zIndex"};var tb=d(660),tA=d.n(tb);let tP=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 v("div",{className:i},void 0,t)}addCloseButton(t="highcharts-popup-close"){let i=this,s=this.iconsURL,e=v("button",{className:t},void 0,this.container);return v("span",{className:"highcharts-icon"},{backgroundImage:"url("+(s.match(/png|svg|jpeg|jpg|gif/ig)?s:s+"close.svg")+")"},e),["click","touchstart"].forEach(t=>{m(e,t,i.closeButtonEvents.bind(i))}),m(document,"keydown",function(t){"Escape"===t.code&&i.closeButtonEvents()}),e}closeButtonEvents(){this.closePopup()}showPopup(t="highcharts-annotation-toolbar"){let i=this.container,s=this.closeButton;this.type=void 0,i.innerHTML=tA().emptyHTML,i.className.indexOf(t)>=0&&(i.classList.remove(t),i.removeAttribute("style")),i.appendChild(s),i.style.display="block",i.style.height=""}closePopup(){this.container.style.display="none"}};var tO=d(620),tM=d.n(tO);let{doc:tk,isFirefox:tw}=g();function tC(t,i,s,e,o,n){let a,r;if(!i)return;let h=this.addInput,l=this.lang;L(e,(e,n)=>{a=""!==s?s+"."+n:n,N(e)&&(!T(e)||T(e)&&N(e[0])?((r=l[n]||n).match(/\d/g)||o.push([!0,r,t]),tC.call(this,t,i,a,e,o,!1)):o.push([this,a,"annotation",t,e]))}),n&&(I(o,t=>t[1].match(/format/g)?-1:1),tw&&o.reverse(),o.forEach(t=>{!0===t[0]?v("span",{className:"highcharts-annotation-title"},void 0,t[2]).appendChild(tk.createTextNode(t[1])):(t[4]={value:t[4][0],type:t[4][1]},h.apply(t[0],t.splice(1)))}))}let{doc:tE}=g(),{seriesTypes:tT}=Z();(n=h||(h={}))[n["params.algorithm"]=0]="params.algorithm",n[n["params.average"]=1]="params.average";let tN={"algorithm-pivotpoints":["standard","fibonacci","camarilla"],"average-disparityindex":["sma","ema","dema","tema","wma"]};function tB(t){let i=v("div",{className:"highcharts-popup-lhs-col"},void 0,t),s=v("div",{className:"highcharts-popup-rhs-col"},void 0,t);return v("div",{className:"highcharts-popup-rhs-col-wrapper"},void 0,s),{lhsCol:i,rhsCol:s}}function tL(t,i,s,e){let o=i.params||i.options.params;e.innerHTML=tA().emptyHTML,v("h3",{className:"highcharts-indicator-title"},void 0,e).appendChild(tE.createTextNode(tF(i,s).indicatorFullName)),v("input",{type:"hidden",name:"highcharts-type-"+s,value:s},void 0,e),tz.call(this,s,"series",t,e,i,i.linkedParent&&i.linkedParent.options.id),o.volumeSeriesID&&tz.call(this,s,"volume",t,e,i,i.linkedParent&&o.volumeSeriesID),tY.call(this,t,"params",o,s,e)}function tS(t,i,s,e){function o(i,s){let e=x.parentNode.children[1];tL.call(n,t,i,s,x),e&&(e.style.display="block"),l&&i.options&&v("input",{type:"hidden",name:"highcharts-id-"+s,value:i.options.id},void 0,x).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"===s,p=l?t.series:t.options.plotOptions||{};if(!t&&p)return;let c,d=[];l||T(p)?T(p)&&(d=tW.call(this,p)):d=tR.call(this,p,e),I(d,(t,i)=>{let s=t.indicatorFullName.toLowerCase(),e=i.indicatorFullName.toLowerCase();return s<e?-1:+(s>e)}),r.children[1]&&r.children[1].remove();let u=v("ul",{className:"highcharts-indicator-list"},void 0,r),x=h.querySelectorAll(".highcharts-popup-rhs-col-wrapper")[0];if(d.forEach(t=>{let{indicatorFullName:i,indicatorType:s,series:e}=t;c=v("li",{className:"highcharts-indicator-list"},void 0,u);let n=v("button",{className:"highcharts-indicator-list-item",textContent:i},void 0,c);["click","touchstart"].forEach(t=>{m(n,t,function(){o(e,s)})})}),d.length>0){let{series:t,indicatorType:i}=d[0];o(t,i)}else l||(tA().setElementHTML(x.parentNode.children[0],a.noFilterMatch||""),x.parentNode.children[1].style.display="none")}function tY(t,i,s,e,o){if(!t)return;let n=this.addInput;L(s,(s,a)=>{let r=i+"."+a;if(b(s)&&r)if(N(s)&&(n.call(this,r,e,o,{}),tY.call(this,t,r,s,e,o)),r in h){let n=tI.call(this,e,r,o);tD.call(this,t,i,n,e,a,s)}else"params.volumeSeriesID"===r||T(s)||n.call(this,r,e,o,{value:s,type:"number"})})}function tX(t,i){let s=this,e=i.querySelectorAll(".highcharts-popup-lhs-col")[0],o=this.lang.clearFilter,n=v("div",{className:"highcharts-input-wrapper"},void 0,e),a=function(i){tS.call(s,t,s.container,"add",i)},r=this.addInput("searchIndicators","input",n,{value:"",type:"text",htmlFor:"search-indicators",labelClassName:"highcharts-input-search-indicators-label"}),h=v("a",{textContent:o},void 0,n);r.classList.add("highcharts-input-search-indicators"),h.classList.add("clear-filter-button"),m(r,"input",function(){a(this.value),this.value.length?h.style.display="inline-block":h.style.display="none"}),["click","touchstart"].forEach(t=>{m(h,t,function(){r.value="",a(""),h.style.display="none"})})}function tI(t,i,s){let e=i.split("."),o=e[e.length-1],n="highcharts-"+i+"-type-"+t,a=this.lang;v("label",{htmlFor:n},null,s).appendChild(tE.createTextNode(a[o]||i));let r=v("select",{name:n,className:"highcharts-popup-field",id:"highcharts-select-"+i},null,s);return r.setAttribute("id","highcharts-select-"+i),r}function tD(t,i,s,e,o,n,a){"series"===i||"volume"===i?t.series.forEach(t=>{let e=t.options,o=e.name||e.params?t.name:e.id||"";"highcharts-navigator-series"!==e.id&&e.id!==(a&&a.options&&a.options.id)&&(b(n)||"volume"!==i||"column"!==t.type||(n=e.id),v("option",{value:e.id},void 0,s).appendChild(tE.createTextNode(o)))}):e&&o&&tN[o+"-"+e].forEach(t=>{v("option",{value:t},void 0,s).appendChild(tE.createTextNode(t))}),b(n)&&(s.value=n)}function tR(t,i){let s,e=this.chart&&this.chart.options.lang,o=e&&e.navigation&&e.navigation.popup&&e.navigation.popup.indicatorAliases,n=new Map;return L(t,(t,e)=>{let a=t&&t.options;if(t.params||a&&a.params){let{indicatorFullName:a,indicatorType:r}=tF(t,e);if(i){let e=RegExp(i.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),"i"),h=o&&o[r]&&o[r].join(" ")||"";(a.match(e)||h.match(e))&&(s={indicatorFullName:a,indicatorType:r,series:t},n.set(r.toLowerCase(),s))}else s={indicatorFullName:a,indicatorType:r,series:t},n.set(r.toLowerCase(),s)}}),Array.from(n.values())}function tW(t){let i=[];return t.forEach(t=>{t.is("sma")&&i.push({indicatorFullName:t.name,indicatorType:t.type,series:t})}),i}function tF(t,i){let s=t.options,e=tT[i]&&tT[i].prototype.nameBase||i.toUpperCase(),o=i;return s&&s.type&&(o=t.options.type,e=t.name),{indicatorFullName:e,indicatorType:o}}function tz(t,i,s,e,o,n){if(!s)return;let a=tI.call(this,t,i,e);tD.call(this,s,i,a,void 0,void 0,void 0,o),b(n)&&(a.value=n)}let{doc:tU}=g();function tH(){return v("div",{className:"highcharts-tab-item-content highcharts-no-mousewheel"},void 0,this.container)}function tV(t,i){let s=this.container,e=this.lang,o="highcharts-tab-item";0===i&&(o+=" highcharts-tab-disabled");let n=v("button",{className:o},void 0,s);return n.appendChild(tU.createTextNode(e[t+"Button"]||t)),n.setAttribute("highcharts-data-tab-type",t),n}function tj(){let t=this.container,i=t.querySelectorAll(".highcharts-tab-item"),s=t.querySelectorAll(".highcharts-tab-item-content");for(let t=0;t<i.length;t++)i[t].classList.remove("highcharts-tab-item-active"),s[t].classList.remove("highcharts-tab-item-show")}function tq(t,i){let s=this.container.querySelectorAll(".highcharts-tab-item-content");t.className+=" highcharts-tab-item-active",s[i].className+=" highcharts-tab-item-show"}function t_(t){let i=this;this.container.querySelectorAll(".highcharts-tab-item").forEach((s,e)=>{(0!==t||"edit"!==s.getAttribute("highcharts-data-tab-type"))&&["click","touchstart"].forEach(t=>{m(s,t,function(){tj.call(i),tq.call(i,this,e)})})})}let{doc:tG}=g(),{getOptions:tK}=g();class t$ extends tP{constructor(t,i,s){super(t,i),this.chart=s,this.lang=(tK().lang.navigation||{}).popup||{},m(this.container,"mousedown",()=>{let t=s&&s.navigationBindings&&s.navigationBindings.activeAnnotation;if(t){t.cancelClick=!0;let i=m(tG,"click",()=>{setTimeout(()=>{t.cancelClick=!1},0),i()})}})}addInput(t,i,s,e){let o=t.split("."),n=o[o.length-1],a=this.lang,r="highcharts-"+i+"-"+S(e.htmlFor,n);if(n.match(/^\d+$/)||v("label",{htmlFor:r,className:e.labelClassName},void 0,s).appendChild(tG.createTextNode(a[n]||n)),"color"===e.type&&this.chart?.container)return this.createColorInput(t,r,e,s,this.chart.container);let h=v("input",{name:r,value:e.value,type:e.type,className:"highcharts-popup-field"},void 0,s);return h.setAttribute("highcharts-data-name",t),h}createColorInput(t,i,s,e,o){let{value:n,alpha:a}=function(t,i){let s=t=>("0"+Math.round(t).toString(16)).slice(-2).toUpperCase(),e=t=>{let[i,e,o,n]=tM().parse(t).rgba;return{value:"#"+s(i)+s(e)+s(o),alpha:n}};if(t.startsWith("rgb")||t.startsWith("rgba"))return e(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])),e=Math.round(255*parseFloat(t[2])),o=Math.round(255*parseFloat(t[3])),n=t[4]?parseFloat(t[4]):1;return{value:"#"+s(i)+s(e)+s(o),alpha:n}}}if(n.startsWith("rgb")||n.startsWith("rgba"))return e(n)}return{value:t,alpha:1}}(s.value||"",o),r=tM().parse(s.value||"").rgba[3],h=isNaN(r)?a:r,l=v("div",{className:"highcharts-popup-color-wrapper"},void 0,e),p=v("input",{type:"color",value:n,className:"highcharts-popup-field highcharts-popup-field-color"},void 0,l),c=v("input",{name:i,id:i,value:n,type:"text",className:"highcharts-popup-field highcharts-popup-field-text"},void 0,l);c.setAttribute("highcharts-data-name",t);let d=v("span",{className:"highcharts-popup-color-separator"},void 0,l),u=v("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),x=v("span",{className:"highcharts-popup-opacity-percent-suffix"},void 0,l);x.appendChild(tG.createTextNode(" %"));let g=v("input",{type:"range",value:String(Math.round(100*h)),className:"highcharts-popup-opacity-slider",min:"0",max:"100",step:"1"},void 0,e);g.style.setProperty("--highcharts-popup-opacity-track-color",n),g.style.setProperty("display","none");let y=()=>{let t=/^#[0-9A-Fa-f]{6}$/.test(c.value);d.style.display=t?"":"none",u.style.display=t?"":"none",x.style.display=t?"":"none"};y();let f=t=>{var i;let s=(i=Number(t.target.value),i>0?i<100?i:100:0);g.value=String(s),u.value=String(Math.round(s))},b=t=>{t.target===p?c.value=p.value.toUpperCase():p.value=c.value,g.style.setProperty("--highcharts-popup-opacity-track-color",p.value),y()};return m(e,"mousedown",t=>{t.target!==u&&t.target!==g&&(g.style.display="none")}),m(u,"focus",()=>{g.style.display=""}),m(u,"input",f),m(g,"input",f),m(p,"input",b),m(c,"input",b),l}closeButtonEvents(){if(this.chart){let t=this.chart.navigationBindings;O(t,"closePopup"),t&&t.selectedButtonElement&&O(t,"deselectButton",{button:t.selectedButtonElement})}else super.closeButtonEvents()}addButton(t,i,s,e,o){let n=v("button",void 0,void 0,t);return n.appendChild(tG.createTextNode(i)),o&&["click","touchstart"].forEach(t=>{m(n,t,()=>{let t,i,n,a,r;return this.closePopup(),o((t=Array.prototype.slice.call(e.querySelectorAll("input")),i=Array.prototype.slice.call(e.querySelectorAll("select")),n=e.querySelectorAll("#highcharts-select-series > option:checked")[0],a=e.querySelectorAll("#highcharts-select-volume > option:checked")[0],r={actionType:s,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 s=t.closest(".highcharts-popup-color-wrapper"),e=s?.querySelector(".highcharts-popup-opacity-percentage"),o=e?Number(e.value)/100:1;if(e){let s=tM().parse(t.value).rgba;r.fields[i]=Number.isNaN(s[0])?t.value:`rgba(${s[0]},${s[1]},${s[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 s=i.split("highcharts-select-")[1];r.fields[s]=t.value}}),a&&(r.fields["params.volumeSeriesID"]=a.getAttribute("value")||""),r))})}),n}showForm(t,i,s,e){i&&(this.showPopup(),"indicators"===t&&this.indicators.addForm.call(this,i,s,e),"annotation-toolbar"===t&&this.annotations.addToolbar.call(this,i,s,e),"annotation-edit"===t&&this.annotations.addForm.call(this,i,s,e),"flag"===t&&this.annotations.addForm.call(this,i,s,e,!0),this.type=t,this.container.style.height=this.container.offsetHeight+"px")}}P(t$.prototype,{annotations:{addForm:function(t,i,s,e){if(!t)return;let o=this.container,n=this.lang,a=v("h2",{className:"highcharts-popup-main-title"},void 0,o);a.appendChild(tk.createTextNode(n[i.langKey]||i.langKey||"")),a=v("div",{className:"highcharts-popup-lhs-col highcharts-popup-lhs-full"},void 0,o);let r=v("div",{className:"highcharts-popup-bottom-row"},void 0,o);tC.call(this,a,t,"",i,[],!0),this.addButton(r,e?n.addButton||"Add":n.saveButton||"Save",e?"add":"save",o,s)},addToolbar:function(t,i,s){let e=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=v("p",{className:"highcharts-annotation-label"},void 0,o);r.setAttribute("aria-label","Annotation type"),r.appendChild(tk.createTextNode(S(e[i.langKey]||i.langKey,i.shapes&&i.shapes[0].type,"")));let h=this.addButton(o,e.editButton||"Edit","edit",o,()=>{n.call(this,"annotation-edit",t,i,s)});h.className+=" highcharts-annotation-edit-button",v("span",{className:"highcharts-icon"},{backgroundImage:`url(${this.iconsURL}edit.svg)`},h),h=this.addButton(o,e.removeButton||"Remove","remove",o,s),h.className+=" highcharts-annotation-remove-button",v("span",{className:"highcharts-icon"},{backgroundImage:`url(${this.iconsURL}destroy.svg)`},h)}},indicators:{addForm:function(t,i,s){let e,o=this.lang;if(!t)return;this.tabs.init.call(this,t);let n=this.container.querySelectorAll(".highcharts-tab-item-content");tB(n[0]),tX.call(this,t,n[0]),tS.call(this,t,n[0],"add"),e=n[0].querySelectorAll(".highcharts-popup-rhs-col")[0],this.addButton(e,o.addButton||"add","add",e,s),tB(n[1]),tS.call(this,t,n[1],"edit"),e=n[1].querySelectorAll(".highcharts-popup-rhs-col")[0],this.addButton(e,o.saveButton||"save","edit",e,s),this.addButton(e,o.removeButton||"remove","remove",e,s)},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),s=tV.call(this,"add");tV.call(this,"edit",i),tH.call(this),tH.call(this),t_.call(this,i),tq.call(this,s,0)}}});let{composed:tZ}=g();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){Y(tZ,"Popup")&&(m(t,"closePopup",tJ),m(t,"showPopup",tQ),D(i.prototype,"onContainerMouseDown",t0))},{getDeferredAnimation:t2}=g(),{defaultOptions:t3}=g();function t9(t,i){let s={};return["labels","shapes"].forEach(e=>{let o=t[e],n=i[e];if(o)if(n)s[e]=(T(n)?n:[n]).map((t,i)=>B(o[i],t));else s[e]=t[e]}),s}class t5 extends G{static compose(t,i,s,e){V.compose(t5,t,s),tm.compose(e),tp.compose(t,e),i.compose(t5,t),t1(i,s)}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 s=t9(this.options,i);this.options.labels=s.labels,this.options.shapes=s.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,s)=>{let e=this.initLabel(i,s);B(!0,t[s],e.options)})}addShapes(){let t=this.options.shapes||[];t.forEach((i,s)=>{let e=this.initShape(i,s);B(!0,t[s],e.options)})}destroy(){var t;let i=this.chart,s=function(t){t.destroy()};this.labels.forEach(s),this.shapes.forEach(s),this.clipXAxis=null,this.clipYAxis=null,A(i.labelCollectors,this.labelCollector),super.destroy(),this.destroyControlTarget(),t=this,L(t,function(s,e){s!==i&&s?.destroy&&s.destroy(),s?.destroy,delete t[e]})}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 s=t9(this.options,i);this.options.labels=s.labels,this.options.shapes=s.shapes,this.chart=t,this.points=[],this.controlPoints=[],this.coll="annotations",this.userOptions=i,this.labels=[],this.shapes=[]}init(t,i,s=this.index){let e=this.chart,o=this.options.animation;this.index=s,this.linkPoints(),this.addControlPoints(),this.addShapes(),this.addLabels(),this.setLabelCollector(),this.animationConfig=t2(e,o)}initLabel(t,i){this.options.labelOptions?.align;let s=new tm(this,B(this.options.labelOptions,{controlPointOptions:this.options.controlPointOptions},t),i);return s.itemType="label",this.labels.push(s),s}initShape(t,i){let s=B(this.options.shapeOptions,{controlPointOptions:this.options.controlPointOptions},t),e=new t5.shapesMap[s.type||"rect"](this,s,i);return e.itemType="shape",this.shapes.push(e),e}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 s,e;t.graphic||this.renderItem(t),t.redraw(S(i,!0)&&t.graphic.placed),t.points.length&&(s=t.graphic,e=t.points.some(t=>!1!==t.series.visible&&!1!==t.visible),s&&(e?"hidden"===s.visibility&&s.show():s.hide()))}else this.destroyItem(t)}redrawItems(t,i){let s=t.length;for(;s--;)this.redrawItem(t[s],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,s=[...this.options.labels??[],...this.options.shapes??[]].reduce((s,e)=>{let o=e&&(e.point||"points"in e&&e.points?.[0]);return[t[o&&o.xAxis]||s[0],i[o&&o.yAxis]||s[1]]},[]);this.clipXAxis=s[0],this.clipYAxis=s[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=B(this.defaultOptions,t.type&&this.defaultOptions.types?.[t.type]||{},t),(i=this.options).typeOptions||(i.typeOptions={})}setVisibility(t){let i=this.options,s=this.chart.navigationBindings,e=S(t,!i.visible);if(this.graphic.attr("visibility",e?"inherit":"hidden"),!e){let t=function(t){t.setControlPointsVisibility(e)};this.shapes.forEach(t),this.labels.forEach(t),s.activeAnnotation===this&&s.popup&&"annotation-toolbar"===s.popup.type&&O(s,"closePopup")}i.visible=e}update(t,i){let s=this.chart,e=t9(this.userOptions,t),o=s.annotations.indexOf(this),n=B(!0,this.userOptions,t);n.labels=e.labels,n.shapes=e.shapes,this.destroy(),this.initProperties(s,n),this.init(s,n),s.options.annotations[o]=this.options,this.isUpdating=!0,S(i,!0)&&s.drawAnnotations(),O(this,"afterUpdate"),this.isUpdating=!1}}t5.ControlPoint=K,t5.MockPoint=Q,t5.shapesMap={rect:tc,circle:td,ellipse:tu,path:tp,image:tv},t5.types={},t5.prototype.defaultOptions=j,t3.annotations=j,t5.prototype.nonDOMEvents=["add","afterUpdate","drag","remove"],tt.compose(t5);let t4=t5;var t6=l||(l={});t6.compose=function(t){return t.navigation||(t.navigation=new t7(t)),t};class t7{constructor(t){this.updates=[],this.chart=t}addUpdate(t){this.chart.navigation.updates.push(t)}update(t,i){this.updates.forEach(s=>{s.call(this.chart,t,i)})}}t6.Additions=t7;let t8=l,it={backgroundColor:"color",backgroundColors:"color",borderColor:"color",borderRadius:"string",color:"color",fill:"color",fontSize:"string",labels:"string",name:"string",stroke:"color",title:"string"},ii={annotationsFieldsTypes:it,getAssignedAxis:function(t){return t.filter(t=>{let i=t.axis.getExtremes(),s=i.min,e=i.max,o=S(t.axis.minPointOffset,0);return C(s)&&C(e)&&t.value>=s-o&&t.value<=e+o&&!t.axis.options.isInternal})[0]},getFieldType:function(t,i){let s=it[t],e=typeof i;return b(s)&&(e=s),({string:"text",number:"number",boolean:"checkbox",color:"color"})[e]}},{getAssignedAxis:is}=ii,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),s=i&&is(i.xAxis),e=i&&is(i.yAxis),o=this.chart.options.navigation;if(s&&e)return this.chart.addAnnotation(B({langKey:"circle",type:"basicAnnotation",shapes:[{type:"circle",point:{x:s.value,y:e.value,xAxis:s.axis.index,yAxis:e.axis.index},r:5}]},o.annotationsOptions,o.bindings.circleAnnotation.annotationsOptions))},steps:[function(t,i){let s,e=i.options.shapes,o=e&&e[0]&&e[0].point||{};if(C(o.xAxis)&&C(o.yAxis)){let i=this.chart.inverted,e=this.chart.xAxis[o.xAxis].toPixels(o.x),n=this.chart.yAxis[o.yAxis].toPixels(o.y);s=Math.max(Math.sqrt(Math.pow(i?n-t.chartX:e-t.chartX,2)+Math.pow(i?e-t.chartY:n-t.chartY,2)),5)}i.update({shapes:[{r:s}]})}]},ellipseAnnotation:{className:"highcharts-ellipse-annotation",start:function(t){let i=this.chart.pointer?.getCoordinates(t),s=i&&is(i.xAxis),e=i&&is(i.yAxis),o=this.chart.options.navigation;if(s&&e)return this.chart.addAnnotation(B({langKey:"ellipse",type:"basicAnnotation",shapes:[{type:"ellipse",xAxis:s.axis.index,yAxis:e.axis.index,points:[{x:s.value,y:e.value},{x:s.value,y:e.value}],ry:1}]},o.annotationsOptions,o.bindings.ellipseAnnotation.annotationsOptions))},steps:[function(t,i){let s=i.shapes[0],e=s.getAbsolutePosition(s.points[1]);s.translatePoint(t.chartX-e.x,t.chartY-e.y,1),s.redraw(!1)},function(t,i){let s=i.shapes[0],e=s.getAbsolutePosition(s.points[0]),o=s.getAbsolutePosition(s.points[1]),n=s.getDistanceFromLine(e,o,t.chartX,t.chartY),a=s.getYAxis(),r=Math.abs(a.toValue(0)-a.toValue(n));s.setYRadius(r),s.redraw(!1)}]},rectangleAnnotation:{className:"highcharts-rectangle-annotation",start:function(t){let i=this.chart.pointer?.getCoordinates(t),s=i&&is(i.xAxis),e=i&&is(i.yAxis);if(!s||!e)return;let o=s.value,n=e.value,a=s.axis.index,r=e.axis.index,h=this.chart.options.navigation;return this.chart.addAnnotation(B({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 s=i.options.shapes,e=s&&s[0]&&s[0].points||[],o=this.chart.pointer?.getCoordinates(t),n=o&&is(o.xAxis),a=o&&is(o.yAxis);if(n&&a){let t=n.value,s=a.value;e[1].x=t,e[2].x=t,e[2].y=s,e[3].y=s,i.update({shapes:[{points:e}]})}}]},labelAnnotation:{className:"highcharts-label-annotation",start:function(t){let i=this.chart.pointer?.getCoordinates(t),s=i&&is(i.xAxis),e=i&&is(i.yAxis),o=this.chart.options.navigation;if(s&&e)return this.chart.addAnnotation(B({langKey:"label",type:"basicAnnotation",labelOptions:{format:"{y:.2f}",overflow:"none",crop:!0},labels:[{point:{xAxis:s.axis.index,yAxis:e.axis.index,x:s.value,y:e.value}}]},o.annotationsOptions,o.bindings.labelAnnotation.annotationsOptions))}}},events:{},annotationsOptions:{animation:{defer:0}}}},{setOptions:io}=g(),{format:ia}=tg(),{composed:ir,doc:ih,win:il}=g(),{getAssignedAxis:ip,getFieldType:ic}=ii;function id(){this.chart.navigationBindings&&this.chart.navigationBindings.deselectAnnotation()}function iu(){this.navigationBindings&&this.navigationBindings.destroy()}function ix(){let t=this.options;t&&t.navigation&&t.navigation.bindings&&(this.navigationBindings=new ib(this,t.navigation),this.navigationBindings.initEvents(),this.navigationBindings.initUpdate())}function ig(){let t=this.navigationBindings,i="highcharts-disabled-btn";if(this&&t){let s=!1;if(this.series.forEach(t=>{!t.options.isInternal&&t.visible&&(s=!0)}),this.navigationBindings&&this.navigationBindings.container&&this.navigationBindings.container[0]){let e=this.navigationBindings.container[0];L(t.boundClassNames,(t,o)=>{let n=e.querySelectorAll("."+o);if(n)for(let e=0;e<n.length;e++){let o=n[e],a=o.className;"normal"===t.noDataState||s?-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,s,e=t.prototype.defaultOptions.events&&t.prototype.defaultOptions.events.click;function o(t){let i=this,s=i.chart.navigationBindings,o=s.activeAnnotation;e&&e.call(i,t),o!==i?(s.deselectAnnotation(),s.activeAnnotation=i,i.setControlPointsVisibility(!0),O(s,"showPopup",{annotation:i,formType:"annotation-toolbar",options:s.annotationToFields(i),onSubmit:function(t){if("remove"===t.actionType)s.activeAnnotation=!1,s.chart.removeAnnotation(i);else{let e={};s.fieldsToOptions(t.fields,e),s.deselectAnnotation();let o=e.typeOptions;"measure"===i.options.type&&(o.crosshairY.enabled=0!==o.crosshairY.strokeWidth,o.crosshairX.enabled=0!==o.crosshairX.strokeWidth),i.update(e)}}})):O(s,"closePopup"),t.activeAnnotation=!0}B(!0,t.prototype.defaultOptions.events,{click:o,touchstart:function(t){i=t.touches[0].clientX,s=t.touches[0].clientY},touchend:function(t){i&&Math.sqrt(Math.pow(i-t.changedTouches[0].clientX,2)+Math.pow(s-t.changedTouches[0].clientY,2))>=4||o.call(this,t)}})}class ib{static compose(t,i){Y(ir,"NavigationBindings")&&(m(t,"remove",id),iv(t),L(t.types,t=>{iv(t)}),m(i,"destroy",iu),m(i,"load",ix),m(i,"render",ig),m(ib,"closePopup",iy),m(ib,"deselectButton",im),io(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=ih.getElementsByClassName(this.options.bindingsClassName||""))}getCoords(t){let i=this.chart.pointer?.getCoordinates(t);return[i&&ip(i.xAxis),i&&ip(i.yAxis)]}initEvents(){let t=this,i=t.chart,s=t.container,e=t.options;t.boundClassNames={},L(e.bindings||{},i=>{t.boundClassNames[i.className]=i}),[].forEach.call(s,i=>{t.eventsToUnbind.push(m(i,"click",s=>{let e=t.getButtonEvents(i,s);e&&!e.button.classList.contains("highcharts-disabled-btn")&&t.bindingsButtonClick(e.button,e.events,s)}))}),L(e.events||{},(i,s)=>{"function"==typeof i&&t.eventsToUnbind.push(m(t,s,i,{passive:!1}))}),t.eventsToUnbind.push(m(i.container,"click",function(s){!i.cancelClick&&i.isInsidePlot(s.chartX-i.plotLeft,s.chartY-i.plotTop,{visiblePlotOnly:!0})&&t.bindingsChartClick(this,s)})),t.eventsToUnbind.push(m(i.container,g().isTouchDevice?"touchmove":"mousemove",function(i){t.bindingsContainerMouseMove(this,i)},g().isTouchDevice?{passive:!1}:void 0))}initUpdate(){let t=this;t8.compose(this.chart).navigation.addUpdate(i=>{t.update(i)})}bindingsButtonClick(t,i,s){let e=this.chart,o=e.renderer.boxWrapper,n=!0;this.selectedButtonElement&&(this.selectedButtonElement.classList===t.classList&&(n=!1),O(this,"deselectButton",{button:this.selectedButtonElement}),this.nextEvent&&(this.currentUserDetails&&"annotations"===this.currentUserDetails.coll&&e.removeAnnotation(this.currentUserDetails),this.mouseMoveEvent=this.nextEvent=!1)),n?(this.selectedButton=i,this.selectedButtonElement=t,O(this,"selectButton",{button:t}),i.init&&i.init.call(this,t,s),(i.start||i.steps)&&e.renderer.boxWrapper.addClass("highcharts-draw-mode")):(e.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 s=this.activeAnnotation,e=this.selectedButton,o=t.renderer.boxWrapper;s&&(s.cancelClick||i.activeAnnotation||!i.target.parentNode||function(t,i){let s=il.Element.prototype,e=s.matches||s.msMatchesSelector||s.webkitMatchesSelector,o=null;if(s.closest)o=s.closest.call(t,i);else do{if(e.call(t,i))return t;t=t.parentElement||t.parentNode}while(null!==t&&1===t.nodeType);return o}(i.target,".highcharts-popup")?s.cancelClick&&setTimeout(()=>{s.cancelClick=!1},0):O(this,"closePopup")),e&&e.start&&(this.nextEvent?(this.nextEvent(i,this.currentUserDetails),this.steps&&(this.stepIndex++,e.steps[this.stepIndex]?this.mouseMoveEvent=this.nextEvent=e.steps[this.stepIndex]:(O(this,"deselectButton",{button:this.selectedButtonElement}),o.removeClass("highcharts-draw-mode"),e.end&&e.end.call(this,i,this.currentUserDetails),this.nextEvent=!1,this.mouseMoveEvent=!1,this.selectedButton=null))):(this.currentUserDetails=e.start.call(this,i),this.currentUserDetails&&e.steps?(this.stepIndex=0,this.steps=!0,this.mouseMoveEvent=this.nextEvent=e.steps[this.stepIndex]):(O(this,"deselectButton",{button:this.selectedButtonElement}),o.removeClass("highcharts-draw-mode"),this.steps=!1,this.selectedButton=null,e.end&&e.end.call(this,i,this.currentUserDetails))))}bindingsContainerMouseMove(t,i){this.mouseMoveEvent&&this.mouseMoveEvent(i,this.currentUserDetails)}fieldsToOptions(t,i){return L(t,(t,s)=>{let e=parseFloat(t),o=s.split("."),n=o.length-1;if(!C(e)||t.match(/px|em/g)||s.match(/format/g)||(t=e),"undefined"!==t){let s=i;o.forEach((i,e)=>{if("__proto__"!==i&&"constructor"!==i){let a=S(o[e+1],"");n===e?s[i]=t:(s[i]||(s[i]=a.match(/\d/g)?[]:{}),s=s[i])}})}}),i}deselectAnnotation(){this.activeAnnotation&&(this.activeAnnotation.setControlPointsVisibility(!1),this.activeAnnotation=!1)}annotationToFields(t){let i=t.options,s=ib.annotationsEditable,e=s.nestedOptions,o=S(i.type,i.shapes?.[0]?.type,i.labels?.[0]?.type,"label"),n=ib.annotationsNonEditable[i.langKey]||[],a={langKey:i.langKey,type:o};function r(i,s,o,a,h){let l;o&&b(i)&&-1===n.indexOf(s)&&((o.indexOf&&o.indexOf(s))>=0||o[s]||!0===o)&&(T(i)?(a[s]=[],i.forEach((t,i)=>{N(t)?(a[s][i]={},L(t,(t,o)=>{r(t,o,e[s],a[s][i],s)})):r(t,0,e[s],a[s],s)})):N(i)?(l={},T(a)?(a.push(l),l[s]={},l=l[s]):a[s]=l,L(i,(t,i)=>{r(t,i,0===s?o:e[s],l,s)})):"format"===s?a[s]=[ia(i,t.labels[0].points[0]).toString(),"text"]:T(a)?a.push([i,ic(h,i)]):a[s]=[i,ic(s,i)])}return L(i,(t,n)=>{"typeOptions"===n&&"basicAnnotation"!==a.type?(a[n]={},L(i[n],(t,i)=>{r(t,i,e,a[n],i)})):r(t,n,s[o],a,n)}),a}getClickedClassNames(t,i){var s,e;let o,n,a,r=i.target,h=[],l;for(;r&&r.tagName&&(s=r,n=E(e="class")&&!b(void 0),a=(t,i)=>{b(t)?s.setAttribute(i,t):n?(o=s.getAttribute(i))||"class"!==i||(o=s.getAttribute(i+"Name")):s.removeAttribute(i)},E(e)?a(void 0,e):L(e,a),(l=o)&&(h=h.concat(l.split(" ").map(t=>[t,r]))),(r=r.parentNode)!==t););return h}getButtonEvents(t,i){let s,e=this;return this.getClickedClassNames(t,i).forEach(t=>{e.boundClassNames[t[0]]&&!s&&(s={events:e.boundClassNames[t[0]],button:t[1]})}),s}update(t){this.options=B(!0,this.options,t),this.removeEvents(),this.initEvents()}removeEvents(){this.eventsToUnbind.forEach(t=>t())}destroy(){this.removeEvents()}}ib.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"]},ib.annotationsNonEditable={rectangle:["crosshairX","crosshairY","labelOptions"],ellipse:["labelOptions"],circle:["labelOptions"]};class iA extends t4{addControlPoints(){let t=this.options,i=iA.basicControlPoints,s=this.basicType;(t.labels||t.shapes||[]).forEach(t=>{t.controlPoints=i[s]})}init(){let t=this.options;if(t.shapes){delete t.labelOptions;let i=t.shapes[0].type;t.shapes[0].className=(t.shapes[0].className||"")+" highcharts-basic-shape",i&&"path"!==i?this.basicType=i:this.basicType="rectangle"}else delete t.shapes,this.basicType="label";super.init.apply(this,arguments)}}iA.basicControlPoints={label:[{symbol:"triangle-down",positioner:function(t){if(!t.graphic.placed)return{x:0,y:-9e7};let i=Q.pointToPixels(t.points[0]);return{x:i.x-(this.graphic.width||0)/2,y:i.y-(this.graphic.height||0)/2}},events:{drag:function(t,i){let s=this.mouseMoveToTranslation(t);i.translatePoint(s.x,s.y),i.annotation.userOptions.labels[0].point=i.options.point,i.redraw(!1)}}},{symbol:"square",positioner:function(t){return t.graphic.placed?{x:t.graphic.alignAttr.x-(this.graphic.width||0)/2,y:t.graphic.alignAttr.y-(this.graphic.height||0)/2}:{x:0,y:-9e7}},events:{drag:function(t,i){let s=this.mouseMoveToTranslation(t);i.translate(s.x,s.y),i.annotation.userOptions.labels[0].point=i.options.point,i.redraw(!1)}}}],rectangle:[{positioner:function(t){let i=Q.pointToPixels(t.points[2]);return{x:i.x-4,y:i.y-4}},events:{drag:function(t,i){let s=i.annotation,e=this.chart.pointer?.getCoordinates(t),o=i.options.points,n=s.userOptions.shapes,a=s.clipXAxis?.index||0,r=s.clipYAxis?.index||0;if(e){let t=e.xAxis[a].value,s=e.yAxis[r].value;o[1].x=t,o[2].x=t,o[2].y=s,o[3].y=s,n?.[0]&&(n[0].points=i.options.points)}s.redraw(!1)}}}],circle:[{positioner:function(t){let i=Q.pointToPixels(t.points[0]),s=t.options.r;return{x:i.x+s*Math.cos(Math.PI/4)-(this.graphic.width||0)/2,y:i.y+s*Math.sin(Math.PI/4)-(this.graphic.height||0)/2}},events:{drag:function(t,i){let s=i.annotation,e=this.mouseMoveToTranslation(t),o=s.userOptions.shapes;i.setRadius(Math.max((i.options.r||0)+e.y/Math.sin(Math.PI/4),5)),o&&o[0]&&(o[0].r=i.options.r,o[0].point=i.options.point),i.redraw(!1)}}}],ellipse:[{positioner:function(t){let i=t.getAbsolutePosition(t.points[0]);return{x:i.x-(this.graphic.width||0)/2,y:i.y-(this.graphic.height||0)/2}},events:{drag:function(t,i){let s=i.getAbsolutePosition(i.points[0]);i.translatePoint(t.chartX-s.x,t.chartY-s.y,0),i.redraw(!1)}}},{positioner:function(t){let i=t.getAbsolutePosition(t.points[1]);return{x:i.x-(this.graphic.width||0)/2,y:i.y-(this.graphic.height||0)/2}},events:{drag:function(t,i){let s=i.getAbsolutePosition(i.points[1]);i.translatePoint(t.chartX-s.x,t.chartY-s.y,1),i.redraw(!1)}}},{positioner:function(t){let i=t.getAbsolutePosition(t.points[0]),s=t.getAbsolutePosition(t.points[1]),e=t.getAttrs(i,s);return{x:e.cx-(this.graphic.width||0)/2+e.ry*Math.sin(e.angle*Math.PI/180),y:e.cy-(this.graphic.height||0)/2-e.ry*Math.cos(e.angle*Math.PI/180)}},events:{drag:function(t,i){let s=i.getAbsolutePosition(i.points[0]),e=i.getAbsolutePosition(i.points[1]),o=i.getDistanceFromLine(s,e,t.chartX,t.chartY),n=i.getYAxis(),a=Math.abs(n.toValue(0)-n.toValue(o));i.setYRadius(a),i.redraw(!1)}}}]},t4.types.basicAnnotation=iA;let{defaultOptions:iP}=g();iP.annotations?.types&&(iP.annotations.types.crookedLine={typeOptions:{xAxis:0,yAxis:0,line:{fill:"none"}},controlPointOptions:{positioner:function(t){let i=this.graphic,s=Q.pointToPixels(t.points[this.index]);return{x:s.x-(i.width||0)/2,y:s.y-(i.height||0)/2}},events:{drag:function(t,i){if(i.chart.isInsidePlot(t.chartX-i.chart.plotLeft,t.chartY-i.chart.plotTop,{visiblePlotOnly:!0})){let s=this.mouseMoveToTranslation(t),e=i.options.typeOptions;i.translatePoint(s.x,s.y,this.index),e.points[this.index].x=i.points[this.index].x,e.points[this.index].y=i.points[this.index].y,i.redraw(!1)}}}}});class iO extends t4{setClipAxes(){this.clipXAxis=this.chart.xAxis[this.options.typeOptions?.xAxis],this.clipYAxis=this.chart.yAxis[this.options.typeOptions?.yAxis]}getPointsOptions(){var t;let i=(t=this.options).typeOptions||(t.typeOptions={});return(i.points||[]).map(t=>("string"!=typeof t&&(t.xAxis=i.xAxis,t.yAxis=i.yAxis),t))}getControlPointsOptions(){return this.getPointsOptions()}addControlPoints(){this.getControlPointsOptions().forEach(function(t,i){let s=new K(this.chart,this,B(this.options.controlPointOptions,t.controlPoint),i);this.controlPoints.push(s),t.controlPoint=s.options},this)}addShapes(){var t;let i=(t=this.options).typeOptions||(t.typeOptions={}),s=this.initShape(B(i.line,{type:"path",className:"highcharts-crooked-lines",points:this.points.map((t,i)=>function(t){return t.annotation.points[i]})}),0);i.line=s.options}}t4.types.crookedLine=iO;let iM=iO,{defaultOptions:ik}=g();ik.annotations?.types&&(ik.annotations.types.elliottWave=B(ik.annotations.types.crookedLine,{typeOptions:{labels:["(0)","(A)","(B)","(C)","(D)","(E)"],line:{strokeWidth:1}},labelOptions:{align:"center",allowOverlap:!0,crop:!0,overflow:"none",type:"rect",backgroundColor:"none",borderWidth:0,y:-5,style:{color:"#333333"}}})),t4.types.elliottWave=class extends iM{addLabels(){this.getPointsOptions().forEach((t,i)=>{let s=this.options.typeOptions,e=this.initLabel(B(t.label,{text:s.labels[i],point:function(t){return t.annotation.points[i]}}),!1);t.label=e.options})}};let{defaultOptions:iw}=g();iw.annotations?.types&&(iw.annotations.types.tunnel=B(iw.annotations.types.crookedLine,{typeOptions:{background:{fill:"rgba(130, 170, 255, 0.4)",strokeWidth:0},line:{strokeWidth:1},height:-2,heightControlPoint:{positioner:function(t){var i,s,e;let o=Q.pointToPixels(t.points[2]),n=Q.pointToPixels(t.points[3]),a=(o.x+n.x)/2;return{x:a-(this.graphic.width||0)/2,y:(i=o,s=n,e=a,(s.y-i.y)/(s.x-i.x)*(e-i.x)+i.y-(this.graphic.height||0)/2)}},events:{drag:function(t,i){i.chart.isInsidePlot(t.chartX-i.chart.plotLeft,t.chartY-i.chart.plotTop,{visiblePlotOnly:!0})&&(i.translateHeight(this.mouseMoveToTranslation(t).y),i.redraw(!1))}}}},controlPointOptions:{events:{drag:function(t,i){if(i.chart.isInsidePlot(t.chartX-i.chart.plotLeft,t.chartY-i.chart.plotTop,{visiblePlotOnly:!0})){let s=this.mouseMoveToTranslation(t);i.translateSide(s.x,s.y,!!this.index),i.redraw(!1)}}}}}));class iC extends iM{getPointsOptions(){let t=iM.prototype.getPointsOptions.call(this),i=this.options.typeOptions?.yAxis||0,s=this.chart.yAxis[i];if(t[2]=this.heightPointOptions(t[1]),t[3]=this.heightPointOptions(t[0]),s&&s.logarithmic){let i=s.toPixels(t[2].y)-s.toPixels(t[1].y),e=s.toPixels(t[0].y)+i;t[3].y=s.toValue(e)}return t}getControlPointsOptions(){return this.getPointsOptions().slice(0,2)}heightPointOptions(t){let i=B(t),s=this.options.typeOptions;return i.y+=s.height,i}addControlPoints(){iM.prototype.addControlPoints.call(this);let t=this.options,i=t.typeOptions,s=new K(this.chart,this,B(t.controlPointOptions,i.heightControlPoint),2);this.controlPoints.push(s),i.heightControlPoint=s.options}addShapes(){this.addLine(),this.addBackground()}addLine(){var t;let i=this.initShape(B(((t=this.options).typeOptions||(t.typeOptions={})).line,{type:"path",className:"highcharts-tunnel-lines",points:[this.points[0],this.points[1],function(t){let i=Q.pointToOptions(t.annotation.points[2]);return i.command="M",i},this.points[3]]}),0);this.options.typeOptions.line=i.options}addBackground(){let t=this.initShape(B(this.options.typeOptions.background,{type:"path",points:this.points.slice(),className:"highcharts-tunnel-background"}),1);this.options.typeOptions.background=t.options}translateSide(t,i,s){let e=Number(s);this.translatePoint(t,i,e),this.translatePoint(t,i,0===e?3:2)}translateHeight(t){this.translatePoint(0,t,2),this.translatePoint(0,t,3),this.options.typeOptions.height=this.points[3].y-this.points[0].y,this.userOptions.typeOptions.height=this.options.typeOptions.height}}t4.types.tunnel=iC;let iE=iC,{defaultOptions:iT}=g();iT.annotations?.types&&(iT.annotations.types.infinityLine=B(iT.annotations.types.crookedLine));class iN extends iM{static edgePoint(t,i){return function(s){let e=s.annotation,o=e.options.typeOptions.type,n=e.points;return("horizontalLine"===o||"verticalLine"===o)&&(n=[n[0],new Q(e.chart,n[0].target,{x:n[0].x+ +("horizontalLine"===o),y:n[0].y+ +("verticalLine"===o),xAxis:n[0].options.xAxis,yAxis:n[0].options.yAxis})]),iN.findEdgePoint(n[t],n[i])}}static findEdgeCoordinate(t,i,s,e){let o="x"===s?"y":"x";return(i[s]-t[s])*(e-t[o])/(i[o]-t[o])+t[s]}static findEdgePoint(t,i){let s,e,o,n=t.series.chart,a=t.series.xAxis,r=i.series.yAxis,h=Q.pointToPixels(t),l=Q.pointToPixels(i),p=l.x-h.x,c=l.y-h.y,d=a.left,u=d+a.width,x=r.top,g=x+r.height,y=p<0?d:u,f=c<0?x:g,m={x:0===p?h.x:y,y:0===c?h.y:f};return 0!==p&&0!==c&&(e=iN.findEdgeCoordinate(h,l,"y",y),s=iN.findEdgeCoordinate(h,l,"x",f),e>=x&&e<=g?(m.x=y,m.y=e):(m.x=s,m.y=f)),m.x-=n.plotLeft,m.y-=n.plotTop,t.series.chart.inverted&&(o=m.x,m.x=m.y,m.y=o),m}addShapes(){let t=this.options.typeOptions,i=[this.points[0],iN.endEdgePoint];t.type.match(/line/gi)&&(i[0]=iN.startEdgePoint);let s=this.initShape(B(t.line,{type:"path",className:"highcharts-infinity-lines",points:i}),0);t.line=s.options}}iN.endEdgePoint=iN.edgePoint(0,1),iN.startEdgePoint=iN.edgePoint(1,0),t4.types.infinityLine=iN;let iB=iN,{defaultOptions:iL}=g();iL.annotations?.types&&(iL.annotations.types.timeCycles=B(iL.annotations.types.crookedLine,{typeOptions:{controlPointOptions:[{positioner:function(t){let i=t.points[0];return{x:t.anchor(i).absolutePosition.x-(this.graphic.width||0)/2,y:t.y-(this.graphic.height||0)}},events:{drag:function(t,i){let s=i.anchor(i.points[0]).absolutePosition;i.translatePoint(t.chartX-s.x,0,0),i.redraw(!1)}}},{positioner:function(t){let i=t.points[1];return{x:t.anchor(i).absolutePosition.x-(this.graphic.width||0)/2,y:t.y-(this.graphic.height||0)}},events:{drag:function(t,i){let s=i.anchor(i.points[1]).absolutePosition;i.translatePoint(t.chartX-s.x,0,1),i.redraw(!1)}}}]}})),t4.types.timeCycles=class extends iM{init(t,i,s){b(i.yAxis)&&i.points.forEach(t=>{t.yAxis=i.yAxis}),b(i.xAxis)&&i.points.forEach(t=>{t.xAxis=i.xAxis}),super.init(t,i,s)}setPath(){this.shapes[0].options.d=this.getPath()}getPath(){return[["M",this.startX,this.y]].concat(function(t,i,s,e){let o=[];for(let n=1;n<=i;n++)o.push(["A",t/2,t/2,0,1,1,s+n*t,e]);return o}(this.pixelInterval,this.numberOfCircles,this.startX,this.y))}addShapes(){let t=this.options.typeOptions;this.setPathProperties();let i=this.initShape(B(t.line,{type:"path",d:this.getPath(),points:this.options.points,className:"highcharts-timecycles-lines"}),0);t.line=i.options}addControlPoints(){let t=this.options,i=t.typeOptions;t.controlPointOptions.style.cursor=this.chart.inverted?"ns-resize":"ew-resize",i.controlPointOptions.forEach(i=>{let s=B(t.controlPointOptions,i),e=new K(this.chart,this,s,0);this.controlPoints.push(e)})}setPathProperties(){let t=this.options.typeOptions,i=t.points;if(!i)return;let s=i[0],e=i[1],o=t.xAxis||0,n=t.yAxis||0,a=this.chart.xAxis[o],r=this.chart.yAxis[n],h=s.x,l=s.y,p=e.x;if(!h||!p)return;let c=C(l)?r.toPixels(l):r.top+r.height,d=C(h)?a.toPixels(h):a.left,u=C(p)?a.toPixels(p):a.left+30,x=a.len,g=Math.round(Math.max(Math.abs(u-d),2)),y=Math.floor(x/g)+2,f=(Math.floor((d-a.left)/g)+1)*g;this.startX=d-f,this.y=c,this.pixelInterval=g,this.numberOfCircles=y}redraw(t){this.setPathProperties(),this.setPath(),super.redraw(t)}};let{defaultOptions:iS}=g();function iY(t,i){return function(){let s=this.annotation;if(!s.startRetracements||!s.endRetracements)return[];let e=this.anchor(s.startRetracements[t]).absolutePosition,o=this.anchor(s.endRetracements[t]).absolutePosition,n=[["M",Math.round(e.x),Math.round(e.y)],["L",Math.round(o.x),Math.round(o.y)]];if(i){let i=this.anchor(s.endRetracements[t-1]).absolutePosition,e=this.anchor(s.startRetracements[t-1]).absolutePosition;n.push(["L",Math.round(i.x),Math.round(i.y)],["L",Math.round(e.x),Math.round(e.y)])}return n}}iS.annotations?.types&&(iS.annotations.types.fibonacci=B(iS.annotations.types.tunnel,{typeOptions:{reversed:!1,height:2,backgroundColors:["rgba(130, 170, 255, 0.4)","rgba(139, 191, 216, 0.4)","rgba(150, 216, 192, 0.4)","rgba(156, 229, 161, 0.4)","rgba(162, 241, 130, 0.4)","rgba(169, 255, 101, 0.4)"],lineColor:"#999999",lineColors:[],labels:[]},labelOptions:{allowOverlap:!0,align:"right",backgroundColor:"none",borderWidth:0,crop:!1,overflow:"none",shape:"rect",style:{color:"#333333"},verticalAlign:"middle",y:0}}));class iX extends iE{linkPoints(){super.linkPoints(),this.linkRetracementsPoints()}linkRetracementsPoints(){let t=this.points,i=t[0].y-t[3].y,s=t[1].y-t[2].y,e=t[0].x,o=t[1].x;iX.levels.forEach((n,a)=>{let r=t[0].y-i*n,h=t[1].y-s*n,l=this.options.typeOptions.reversed?iX.levels.length-a-1:a;this.startRetracements=this.startRetracements||[],this.endRetracements=this.endRetracements||[],this.linkRetracementPoint(l,e,r,this.startRetracements),this.linkRetracementPoint(l,o,h,this.endRetracements)})}linkRetracementPoint(t,i,s,e){let o=e[t],n=this.options.typeOptions;o?(o.options.x=i,o.options.y=s,o.refresh()):e[t]=new Q(this.chart,this,{x:i,y:s,xAxis:n.xAxis,yAxis:n.yAxis})}addShapes(){iX.levels.forEach(function(t,i){let{backgroundColors:s,lineColor:e,lineColors:o}=this.options.typeOptions;this.initShape({type:"path",d:iY(i),stroke:o[i]||e,className:"highcharts-fibonacci-line"},i),i>0&&this.initShape({type:"path",fill:s[i-1],strokeWidth:0,d:iY(i,!0),className:"highcharts-fibonacci-background-"+(i-1)})},this)}addLabels(){iX.levels.forEach(function(t,i){let s=this.options.typeOptions,e=this.initLabel(B(s.labels[i],{point:function(t){return Q.pointToOptions(t.annotation.startRetracements[i])},text:t.toString()}));s.labels[i]=e.options},this)}}iX.levels=[0,.236,.382,.5,.618,.786,1],t4.types.fibonacci=iX;let{defaultOptions:iI}=g();function iD(t,i,s){return function(e){let o=e.annotation.chart,n=o.inverted?o.plotTop:o.plotLeft,a=e.annotation.points,r=a[0].series.xAxis,h=a.length>1?a[1].plotX-a[0].plotX:0,l=r.toValue(a[0].plotX+n+s*h);return a=[new Q(o,a[0].target,{x:l,y:0,xAxis:a[0].options.xAxis,yAxis:a[0].options.yAxis}),new Q(o,a[0].target,{x:l,y:1,xAxis:a[0].options.xAxis,yAxis:a[0].options.yAxis})],iB.findEdgePoint(a[t],a[i])}}iI.annotations?.types&&(iI.annotations.types.fibonacciTimeZones=B(iI.annotations.types.crookedLine,{typeOptions:{line:{stroke:"#333333",strokeWidth:1,fill:void 0},controlPointOptions:{positioner:function(){let t=this.target,i=this.graphic,s=t.secondLineEdgePoints,e={annotation:t},o=s[0](e).y,n=s[1](e).y,a=this.chart.plotLeft,r=this.chart.plotTop,h=s[0](e).x,l=(o+n)/2;return this.chart.inverted&&([h,l]=[l,h]),{x:a+h-(i.width||0)/2,y:r+l-(i.height||0)/2}},events:{drag:function(t,i){if(i.chart.isInsidePlot(t.chartX-i.chart.plotLeft,t.chartY-i.chart.plotTop,{visiblePlotOnly:!0})){let s=this.mouseMoveToTranslation(t);i.translatePoint(s.x,0,1),i.redraw(!1)}}}}}})),t4.types.fibonacciTimeZones=class extends iM{addShapes(){let t=1,i=1;for(let s=0;s<11;s++){let e=s?t:0,o=[iD(1,0,e),iD(0,1,e)];t=(i=t+i)-t,1===s&&(this.secondLineEdgePoints=[o[0],o[1]]),this.initShape(B(this.options.typeOptions?.line,{type:"path",className:"highcharts-fibonacci-timezones-lines",points:o}),s)}}addControlPoints(){let t=this.options,i=t.typeOptions,s=new K(this.chart,this,B(t.controlPointOptions,i.controlPointOptions),0);this.controlPoints.push(s),i.controlPointOptions=s.options}};let{defaultOptions:iR}=g();iR.annotations?.types&&(iR.annotations.types.pitchfork=B(iR.annotations.types.infinityLine,{typeOptions:{innerBackground:{fill:"rgba(130, 170, 255, 0.4)",strokeWidth:0},outerBackground:{fill:"rgba(156, 229, 161, 0.4)",strokeWidth:0}}}));class iW extends iB{static outerLineEdgePoint(t){return function(i){let s=i.annotation,e=s.points;return iW.findEdgePoint(e[t],e[0],new Q(s.chart,i,s.midPointOptions()))}}static findEdgePoint(t,i,s){let e=Math.atan2(s.plotY-i.plotY,s.plotX-i.plotX);return{x:t.plotX+1e7*Math.cos(e),y:t.plotY+1e7*Math.sin(e)}}static middleLineEdgePoint(t){let i=t.annotation,s=i.points;return iB.findEdgePoint(s[0],new Q(i.chart,t,i.midPointOptions()))}midPointOptions(){let t=this.points;return{x:(t[1].x+t[2].x)/2,y:(t[1].y+t[2].y)/2,xAxis:t[0].series.xAxis,yAxis:t[0].series.yAxis}}addShapes(){this.addLines(),this.addBackgrounds()}addLines(){let t="highcharts-pitchfork-lines";this.initShape({type:"path",points:[this.points[0],iW.middleLineEdgePoint],className:t},0),this.initShape({type:"path",points:[this.points[1],iW.topLineEdgePoint],className:t},1),this.initShape({type:"path",points:[this.points[2],iW.bottomLineEdgePoint],className:t},2)}addBackgrounds(){let t=this.shapes,i=this.options.typeOptions,s=this.initShape(B(i.innerBackground,{type:"path",points:[function(t){let i=t.annotation,s=i.points,e=i.midPointOptions();return{x:(s[1].x+e.x)/2,y:(s[1].y+e.y)/2,xAxis:e.xAxis,yAxis:e.yAxis}},t[1].points[1],t[2].points[1],function(t){let i=t.annotation,s=i.points,e=i.midPointOptions();return{x:(e.x+s[2].x)/2,y:(e.y+s[2].y)/2,xAxis:e.xAxis,yAxis:e.yAxis}}],className:"highcharts-pitchfork-inner-background"}),3),e=this.initShape(B(i.outerBackground,{type:"path",points:[this.points[1],t[1].points[1],t[2].points[1],this.points[2]],className:"highcharts-pitchfork-outer-background"}),4);i.innerBackground=s.options,i.outerBackground=e.options}}iW.topLineEdgePoint=iW.outerLineEdgePoint(1),iW.bottomLineEdgePoint=iW.outerLineEdgePoint(0),t4.types.pitchfork=iW;let{defaultOptions:iF}=g();iF.annotations?.types&&(iF.annotations.types.verticalLine={typeOptions:{yOffset:10,label:{offset:-40,point:function(t){return t.annotation.points[0]},allowOverlap:!0,backgroundColor:"none",borderWidth:0,crop:!0,overflow:"none",shape:"rect",text:"{y:.2f}"},connector:{strokeWidth:1,markerEnd:"arrow"}},labelOptions:{style:{color:"#333333",fontSize:"0.7em"}}});class iz extends t4{static connectorFirstPoint(t){let i=t.annotation,s=i.chart,e=s.inverted,o=i.points[0],n=S(o.series.yAxis?.left,0),a=S(o.series.yAxis?.top,0),r=i.options.typeOptions?.label?.offset||0,h=Q.pointToPixels(o,!0)[e?"x":"y"];return{x:o.x,xAxis:o.series.xAxis,y:h+r+(e?n-s.plotLeft:a-s.plotTop)}}static connectorSecondPoint(t){let i=t.annotation,s=i.chart,e=s.inverted,o=i.options.typeOptions,n=i.points[0],a=S(n.series.yAxis&&n.series.yAxis.left,0),r=S(n.series.yAxis&&n.series.yAxis.top,0),h=Q.pointToPixels(n,!0)[e?"x":"y"],l=o?.yOffset||0;return 0>(o?.label?.offset||0)&&(l*=-1),{x:n.x,xAxis:n.series.xAxis,y:h+l+(e?a-s.plotLeft:r-s.plotTop)}}getPointsOptions(){return this.options.typeOptions?.point?[this.options.typeOptions.point]:[]}addShapes(){var t;let i=this.options.typeOptions,s=this.initShape(B(i.connector,{type:"path",points:[iz.connectorFirstPoint,iz.connectorSecondPoint],className:"highcharts-vertical-line"}),0);i.connector=s.options,((t=this.userOptions).typeOptions||(t.typeOptions={})).point=i.point}addLabels(){let t=this.options.typeOptions,i=t.label,s=i?.offset||0,e=0,o=s,n=s<0?"bottom":"top",a="center";this.chart.inverted&&(e=s,o=0,n="middle",a=s<0?"right":"left"),t.label=this.initLabel(B(i,{verticalAlign:n,align:a,x:e,y:o})).options}}t4.types.verticalLine=iz;let{defaultOptions:iU}=g();function iH(){let t=0,i=0,s=0,e=this.chart.series,o=i_(this.xAxisMin,this.xAxisMax,this.yAxisMin,this.yAxisMax);return e.forEach(t=>{t.visible&&"highcharts-navigator-series"!==t.options.id&&t.points.forEach(t=>{iV(t,o)&&C(t.y)&&(i+=t.y,s++)})}),s>0&&(t=i/s),t}function iV(t,i){return!t.isNull&&C(t.y)&&t.x>i.xAxisMin&&t.x<=i.xAxisMax&&t.y>i.yAxisMin&&t.y<=i.yAxisMax}function ij(){let t=this.chart.series,i=i_(this.xAxisMin,this.xAxisMax,this.yAxisMin,this.yAxisMax),s=0;return t.forEach(t=>{t.visible&&"highcharts-navigator-series"!==t.options.id&&t.points.forEach(t=>{iV(t,i)&&s++})}),s}function iq(){return"Min: "+this.min+"<br>Max: "+this.max+"<br>Average: "+this.average.toFixed(2)+"<br>Bins: "+this.bins}function i_(t,i,s,e){return{xAxisMin:Math.min(i,t),xAxisMax:Math.max(i,t),yAxisMin:Math.min(e,s),yAxisMax:Math.max(e,s)}}function iG(t,i,s){return t.toValue(t.toPixels(i)+s)}function iK(){let t=this.options.typeOptions,i=this.chart,s=i.inverted,e=i.xAxis[t.xAxis],o=i.yAxis[t.yAxis],n=t.background,a=s?n.height:n.width,r=s?n.width:n.height,h=t.selectType,l=s?e.left:o.top,p=s?o.top:e.left;this.startXMin=t.point.x,this.startYMin=t.point.y,C(a)?this.startXMax=this.startXMin+a:this.startXMax=iG(e,this.startXMin,parseFloat(a)),C(r)?this.startYMax=this.startYMin-r:this.startYMax=iG(o,this.startYMin,parseFloat(r)),"x"===h?(this.startYMin=o.toValue(l),this.startYMax=o.toValue(l+o.len)):"y"===h&&(this.startXMin=e.toValue(p),this.startXMax=e.toValue(p+e.len))}function i$(){let t=this.chart.series,i=i_(this.xAxisMin,this.xAxisMax,this.yAxisMin,this.yAxisMax),s=-1/0,e=!1;return t.forEach(t=>{t.visible&&"highcharts-navigator-series"!==t.options.id&&t.points.forEach(t=>{C(t.y)&&t.y>s&&iV(t,i)&&(s=t.y,e=!0)})}),e||(s=0),s}function iZ(){let t=this.chart.series,i=i_(this.xAxisMin,this.xAxisMax,this.yAxisMin,this.yAxisMax),s=1/0,e=!1;return t.forEach(t=>{t.visible&&"highcharts-navigator-series"!==t.options.id&&t.points.forEach(t=>{C(t.y)&&t.y<s&&iV(t,i)&&(s=t.y,e=!0)})}),e||(s=0),s}function iJ(t){let i=this.options.typeOptions,s=this.chart.xAxis[i.xAxis],e=this.chart.yAxis[i.yAxis],o=this.offsetX,n=this.offsetY;this.xAxisMin=iG(s,this.startXMin,o),this.xAxisMax=iG(s,this.startXMax,o),this.yAxisMin=iG(e,this.startYMin,n),this.yAxisMax=iG(e,this.startYMax,n),this.min=iZ.call(this),this.max=i$.call(this),this.average=iH.call(this),this.bins=ij.call(this),t&&this.resize(0,0)}function iQ(t,i,s,e,o){var n;let a=this.options.typeOptions,r=a.selectType,h=this.chart.xAxis[a.xAxis],l=this.chart.yAxis[a.yAxis],p=this.startXMin,c=this.startXMax,d=this.startYMin,u=this.startYMax,x=this.offsetX,g=this.offsetY;i&&("x"===r?0===s?this.startXMin=iG(h,p,e):this.startXMax=iG(h,c,e):"y"===r?0===s?this.startYMin=iG(l,d,o):this.startYMax=iG(l,u,o):(this.startXMax=iG(h,c,e),this.startYMax=iG(l,u,o))),t&&(this.startXMin=iG(h,p,x),this.startXMax=iG(h,c,x),this.startYMin=iG(l,d,g),this.startYMax=iG(l,u,g),this.offsetX=0,this.offsetY=0),this.options.typeOptions.point={x:this.startXMin,y:this.startYMin},((n=this.userOptions).typeOptions||(n.typeOptions={})).point={x:this.startXMin,y:this.startYMin}}iU.annotations?.types&&(iU.annotations.types.measure={typeOptions:{selectType:"xy",xAxis:0,yAxis:0,background:{fill:"rgba(130, 170, 255, 0.4)",strokeWidth:0,stroke:void 0},crosshairX:{enabled:!0,zIndex:6,dashStyle:"Dash",markerEnd:"arrow"},crosshairY:{enabled:!0,zIndex:6,dashStyle:"Dash",markerEnd:"arrow"},label:{enabled:!0,style:{fontSize:"0.7em",color:"#333333"},formatter:void 0}},controlPointOptions:{positioner:function(t){let i=this.index,s=t.chart,e=t.options,o=e.typeOptions,n=o.selectType,a=e.controlPointOptions,r=s.inverted,h=s.xAxis[o.xAxis],l=s.yAxis[o.yAxis],p=i_(t.xAxisMin,t.xAxisMax,t.yAxisMin,t.yAxisMax),c=t.xAxisMax,d=t.yAxisMax,u,x;return"x"===n&&(d=(p.yAxisMax+p.yAxisMin)/2,0===i&&(c=t.xAxisMin)),"y"===n&&(c=p.xAxisMin+(p.xAxisMax-p.xAxisMin)/2,0===i&&(d=t.yAxisMin)),r?(u=l.toPixels(d),x=h.toPixels(c)):(u=h.toPixels(c),x=l.toPixels(d)),{x:u-(a?.width||0)/2,y:x-(a?.height||0)/2}},events:{drag:function(t,i){let s=this.mouseMoveToTranslation(t),e=i.options.typeOptions.selectType,o=this.index,n="y"===e?0:s.x,a="x"===e?0:s.y;i.resize(n,a,o,e),i.resizeX+=n,i.resizeY+=a,i.redraw(!1,!0)}}}}),t4.types.measure=class extends t4{init(t,i,s){super.init(t,i,s),this.offsetX=0,this.offsetY=0,this.resizeX=0,this.resizeY=0,iK.call(this),this.addValues(),this.addShapes()}setClipAxes(){this.clipXAxis=this.chart.xAxis[this.options.typeOptions.xAxis],this.clipYAxis=this.chart.yAxis[this.options.typeOptions.yAxis]}shapePointsOptions(){let t=this.options.typeOptions,i=t.xAxis,s=t.yAxis;return[{x:this.xAxisMin,y:this.yAxisMin,xAxis:i,yAxis:s},{x:this.xAxisMax,y:this.yAxisMin,xAxis:i,yAxis:s},{x:this.xAxisMax,y:this.yAxisMax,xAxis:i,yAxis:s},{x:this.xAxisMin,y:this.yAxisMax,xAxis:i,yAxis:s},{command:"Z"}]}addControlPoints(){let t=this.chart.inverted,i=this.options.controlPointOptions,s=this.options.typeOptions.selectType;b(this.userOptions.controlPointOptions?.style?.cursor)||("x"===s?i.style.cursor=t?"ns-resize":"ew-resize":"y"===s&&(i.style.cursor=t?"ew-resize":"ns-resize"));let e=new K(this.chart,this,this.options.controlPointOptions,0);this.controlPoints.push(e),"xy"!==s&&(e=new K(this.chart,this,this.options.controlPointOptions,1),this.controlPoints.push(e))}addValues(t){let i=this.options.typeOptions,s=i.label.formatter;iJ.call(this,t),i.label.enabled&&(this.labels.length>0?this.labels[0].text=s?.call(this,this)||iq.call(this):this.initLabel(P({shape:"rect",backgroundColor:"none",color:"black",borderWidth:0,dashStyle:"Dash",overflow:"allow",align:"left",y:0,x:0,verticalAlign:"top",crop:!0,xAxis:0,yAxis:0,point:function(t){let s=t.annotation,e=t.options;return{x:s.xAxisMin,y:s.yAxisMin,xAxis:S(i.xAxis,e.xAxis),yAxis:S(i.yAxis,e.yAxis)}},text:s?.call(this,this)||iq.call(this)},i.label),void 0))}addShapes(){this.addCrosshairs(),this.addBackground()}addBackground(){let t=this.shapePointsOptions();void 0!==t[0].x&&this.initShape(P({type:"path",points:t,className:"highcharts-measure-background"},this.options.typeOptions.background),2)}addCrosshairs(){let t=this.chart,i=this.options.typeOptions,s=this.options.typeOptions.point,e=t.xAxis[i.xAxis],o=t.yAxis[i.yAxis],n=t.inverted,a={point:s,type:"path"},r=e.toPixels(this.xAxisMin),h=e.toPixels(this.xAxisMax),l=o.toPixels(this.yAxisMin),p=o.toPixels(this.yAxisMax),c=[],d=[],u,x,g;n&&(g=r,r=l,l=g,g=h,h=p,p=g),i.crosshairX.enabled&&(c=[["M",r,l+(p-l)/2],["L",h,l+(p-l)/2]]),i.crosshairY.enabled&&(d=[["M",r+(h-r)/2,l],["L",r+(h-r)/2,p]]),this.shapes.length>0?(this.shapes[0].options.d=c,this.shapes[1].options.d=d):(u=B(a,{className:"highcharts-measure-crosshair-x"},i.crosshairX),x=B(a,{className:"highcharts-measure-crosshair-y"},i.crosshairY),this.initShape(P({d:c},u),0),this.initShape(P({d:d},x),1))}onDrag(t){let i=this.mouseMoveToTranslation(t),s=this.options.typeOptions.selectType,e="y"===s?0:i.x,o="x"===s?0:i.y;this.translate(e,o),this.offsetX+=e,this.offsetY+=o,this.redraw(!1,!1,!0)}resize(t,i,s,e){let o=this.shapes[2];"x"===e?0===s?(o.translatePoint(t,0,0),o.translatePoint(t,i,3)):(o.translatePoint(t,0,1),o.translatePoint(t,i,2)):"y"===e?0===s?(o.translatePoint(0,i,0),o.translatePoint(0,i,1)):(o.translatePoint(0,i,2),o.translatePoint(0,i,3)):(o.translatePoint(t,0,1),o.translatePoint(t,i,2),o.translatePoint(0,i,3)),iQ.call(this,!1,!0,s,t,i),this.options.typeOptions.background.height=Math.abs(this.startYMax-this.startYMin),this.options.typeOptions.background.width=Math.abs(this.startXMax-this.startXMin)}redraw(t,i,s){this.linkPoints(),this.graphic||this.render(),s&&iQ.call(this,!0,!1),this.clipRect&&this.clipRect.animate(this.getClipBox()),this.addValues(i),this.addCrosshairs(),this.redrawItems(this.shapes,t),this.redrawItems(this.labels,t);let e=this.options.typeOptions.background;if(e?.strokeWidth&&this.shapes[2]?.graphic){let t=e.strokeWidth/2,i=this.shapes[2],s=i.graphic.pathArray,o=s[0],n=s[1],a=s[2],r=s[3];o[1]=(o[1]||0)+t,n[1]=(n[1]||0)-t,a[1]=(a[1]||0)-t,r[1]=(r[1]||0)+t,o[2]=(o[2]||0)+t,n[2]=(n[2]||0)+t,a[2]=(a[2]||0)-t,r[2]=(r[2]||0)-t,i.graphic.attr({d:s})}this.controlPoints.forEach(t=>t.redraw())}translate(t,i){this.shapes.forEach(s=>s.translate(t,i))}};let i0=g();i0.Annotation||(i0.Annotation=t4,i0.NavigationBindings=i0.NavigationBindings||ib,i0.Annotation.compose(i0.Chart,i0.NavigationBindings,i0.Pointer,i0.SVGRenderer)),i0.Annotation!==t4&&t4.types&&Object.assign(i0.Annotation.types,t4.types);let i1=g();return u.default})());