import { ref as Le, reactive as C0, nextTick as fo, openBlock as Je, createElementBlock as qe, normalizeStyle as Pr, createElementVNode as ar, toDisplayString as yn, unref as k0, createCommentVNode as Kn, createTextVNode as Fp, Fragment as Qa, renderList as tl, normalizeClass as A0, defineCustomElement as Up } from "vue";
const go = {
//图表配置
chart: {
spacingTop: 30,
backgroundColor: "rgba(0,0,0,0)"
},
title: {
enabled: !1
},
exporting: {
enabled: !1
},
boost: {
useGPUTranslations: !0
},
//默认颜色配置
colors: [
"#00f",
"#f00",
"#999",
"#000",
"#7cb5ec",
"#90ed7d",
"#f7a35c",
"#8085e9",
"#f15c80",
"#e4d354",
"#2b908f",
"#f45b5b",
"#91e8e1"
],
//版权信息
credits: { enabled: !1 },
//数据列通用配置
plotOptions: {
series: {
turboThreshold: 0,
//不限制数据点个数
boostThreshold: 0,
dataGrouping: {
enabled: !1
},
//取消数据大自动数据合并
animation: {
duration: 1e3
}
},
areaspline: {
lineWidth: 1,
stacking: "normal",
marker: {
enabled: !1
}
// fillOpacity: 0.5,
},
column: {
pointPadding: 0.05,
stacking: "normal"
},
scatter: {
turboThreshold: 0,
marker: {
symbol: "circle",
radius: 5,
states: {
hover: {
enabled: !0
}
}
},
states: {
hover: {
marker: {
enabled: !0
}
}
}
}
},
//范围选择器
rangeSelector: {
enabled: !1,
selected: 2
},
//悬浮提示框
tooltip: {
split: !1,
shared: !0,
dateTimeLabelFormats: {
// 时间格式化字符
day: "%Y/%m/%d",
week: "%Y/%m",
month: "%Y/%m",
year: "%Y/%m"
},
xDateFormat: "%Y/%m/%d",
className: "chart-tooltips-box"
// formatter:function(e){
// return `
${this.x}
aaa
`
// // return e
// }
// outside: true,
// valueDecimals: 4,
},
//图例
legend: {
enabled: !0,
verticalAlign: "top",
margin: 3
// layout: 'vertical'
},
//滚动条
scrollbar: {
enabled: !1
},
//导航器
navigator: {
enabled: !1
},
//范围选择器
rangeSelector: {
enabled: !1
},
xAxis: {
tickPosition: "inside",
lineColor: "#bfbfbf",
tickColor: "#bfbfbf",
tickLength: 5,
type: "datetime",
ordinal: !1,
dateTimeLabelFormats: {
day: "%y/%m",
week: "%y/%m",
month: "%y/%m",
year: "%y/%m"
}
// gridLineWidth:0
}
}, T0 = {
//默认颜色配置
colors: ["#4B0082", "#7FFFAA", "#FF4500", "#808000", "#EEE8AA", "#849EC1", "#8A4294", "#578B5A", "#FDA8C7", "#53B3FF", "#999999", "#000000", "#FFDF0C", "#FF0000", "#0033FF"],
yAxis: {
lineWidth: 1,
lineColor: "#bfbfbf",
tickColor: "#bfbfbf",
offset: 0,
opposite: !1,
reversed: !1,
visible: !0,
gridLineWidth: 0,
tickWidth: 1,
tickLength: 5,
tickPosition: "inside",
endOnTick: !1,
startOnTick: !1,
showLastLabel: !0,
//显示最后刻度值
tickPixelInterval: 50
}
}, Mn = {
tickPosition: "inside",
lineColor: "#bfbfbf",
tickColor: "#bfbfbf",
tickLength: 5,
ordinal: !1,
type: "linear"
}, fr = {
tickWidth: 1,
tickLength: 5,
lineWidth: 1,
lineColor: "#bfbfbf",
tickColor: "#bfbfbf",
// offset: 0,
visible: !0,
gridLineWidth: 0,
tickPosition: "inside",
endOnTick: !1,
startOnTick: !1,
showLastLabel: !0,
tickPixelInterval: 50
}, Vp = {
tickPosition: "inside",
lineColor: "#bfbfbf",
tickColor: "#bfbfbf",
tickLength: 5,
type: "datetime",
ordinal: !1,
dateTimeLabelFormats: {
day: "%y/%m",
week: "%y/%m",
month: "%y/%m",
year: "%y/%m"
},
xDateFormat: "%Y-%m-%d"
}, P0 = {
年: "Y",
季: "Q",
月: "M",
周: "W",
天: "D"
}, Pp = {
年: "Year",
季: "Season",
月: "Month",
周: "Week",
天: "Day"
};
var Fr = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, ul = {}, E0 = {
get exports() {
return ul;
},
set exports(r) {
ul = r;
}
};
(function(r) {
(function(f, E) {
r.exports ? (E.default = E, r.exports = f.document ? E(f) : E) : (f.Highcharts && f.Highcharts.error(16, !0), f.Highcharts = E(f));
})(typeof window < "u" ? window : Fr, function(f) {
function E(y, j, I, Z) {
y.hasOwnProperty(j) || (y[j] = Z.apply(null, I));
}
var l = {};
return E(l, "Core/Globals.js", [], function() {
var y = typeof f < "u" ? f : typeof window < "u" ? window : {}, j;
return function(I) {
I.SVG_NS = "http://www.w3.org/2000/svg", I.product = "Highcharts", I.version = "9.3.3", I.win = y, I.doc = I.win.document, I.svg = I.doc && I.doc.createElementNS && !!I.doc.createElementNS(I.SVG_NS, "svg").createSVGRect, I.userAgent = I.win.navigator && I.win.navigator.userAgent || "", I.isChrome = I.userAgent.indexOf("Chrome") !== -1, I.isFirefox = I.userAgent.indexOf("Firefox") !== -1, I.isMS = /(edge|msie|trident)/i.test(I.userAgent) && !I.win.opera, I.isSafari = !I.isChrome && I.userAgent.indexOf("Safari") !== -1, I.isTouchDevice = /(Mobile|Android|Windows Phone)/.test(I.userAgent), I.isWebKit = I.userAgent.indexOf("AppleWebKit") !== -1, I.deg2rad = 2 * Math.PI / 360, I.hasBidiBug = I.isFirefox && 4 > parseInt(I.userAgent.split("Firefox/")[1], 10), I.hasTouch = !!I.win.TouchEvent, I.marginNames = ["plotTop", "marginRight", "marginBottom", "plotLeft"], I.noop = function() {
}, I.supportsPassiveEvents = function() {
var Z = !1;
if (!I.isMS) {
var H = Object.defineProperty({}, "passive", { get: function() {
Z = !0;
} });
I.win.addEventListener && I.win.removeEventListener && (I.win.addEventListener(
"testPassive",
I.noop,
H
), I.win.removeEventListener("testPassive", I.noop, H));
}
return Z;
}(), I.charts = [], I.dateFormats = {}, I.seriesTypes = {}, I.symbolSizes = {}, I.chartCount = 0;
}(j || (j = {})), j;
}), E(l, "Core/Utilities.js", [l["Core/Globals.js"]], function(y) {
function j(t, s, n, A) {
var _ = s ? "Highcharts error" : "Highcharts warning";
t === 32 && (t = _ + ": Deprecated member");
var D = S(t), W = D ? _ + " #" + t + ": www.highcharts.com/errors/" + t + "/" : t.toString();
if (typeof A < "u") {
var P = "";
D && (W += "?"), b(A, function(X, g) {
P += `
- ` + g + ": " + X, D && (W += encodeURI(g) + "=" + encodeURI(X));
}), W += P;
}
x(y, "displayError", { chart: n, code: t, message: W, params: A }, function() {
if (s)
throw Error(W);
p.console && j.messages.indexOf(W) === -1 && console.warn(W);
}), j.messages.push(W);
}
function I(t, s) {
var n = {};
return b(t, function(A, _) {
F(t[_], !0) && !t.nodeType && s[_] ? (A = I(t[_], s[_]), Object.keys(A).length && (n[_] = A)) : (F(t[_]) || t[_] !== s[_]) && (n[_] = t[_]);
}), n;
}
function Z(t, s) {
return parseInt(t, s || 10);
}
function H(t) {
return typeof t == "string";
}
function U(t) {
return t = Object.prototype.toString.call(t), t === "[object Array]" || t === "[object Array Iterator]";
}
function F(t, s) {
return !!t && typeof t == "object" && (!s || !U(t));
}
function N(t) {
return F(t) && typeof t.nodeType == "number";
}
function R(t) {
var s = t && t.constructor;
return !(!F(t, !0) || N(t) || !s || !s.name || s.name === "Object");
}
function S(t) {
return typeof t == "number" && !isNaN(t) && 1 / 0 > t && -1 / 0 < t;
}
function v(t) {
return typeof t < "u" && t !== null;
}
function d(t, s, n) {
var A;
return H(s) ? v(n) ? t.setAttribute(s, n) : t && t.getAttribute && ((A = t.getAttribute(s)) || s !== "class" || (A = t.getAttribute(s + "Name"))) : b(s, function(_, D) {
v(_) ? t.setAttribute(D, _) : t.removeAttribute(D);
}), A;
}
function u(t, s) {
var n;
t || (t = {});
for (n in s)
t[n] = s[n];
return t;
}
function T() {
for (var t = arguments, s = t.length, n = 0; n < s; n++) {
var A = t[n];
if (typeof A < "u" && A !== null)
return A;
}
}
function O(t, s) {
y.isMS && !y.svg && s && typeof s.opacity < "u" && (s.filter = "alpha(opacity=" + 100 * s.opacity + ")"), u(t.style, s);
}
function B(t, s) {
return 1e14 < t ? t : parseFloat(t.toPrecision(s || 14));
}
function C(t, s, n) {
var A = y.getStyle || C;
if (s === "width")
return s = Math.min(t.offsetWidth, t.scrollWidth), n = t.getBoundingClientRect && t.getBoundingClientRect().width, n < s && n >= s - 1 && (s = Math.floor(n)), Math.max(0, s - (A(t, "padding-left", !0) || 0) - (A(t, "padding-right", !0) || 0));
if (s === "height")
return Math.max(0, Math.min(t.offsetHeight, t.scrollHeight) - (A(t, "padding-top", !0) || 0) - (A(t, "padding-bottom", !0) || 0));
if (p.getComputedStyle || j(27, !0), t = p.getComputedStyle(t, void 0)) {
var _ = t.getPropertyValue(s);
T(n, s !== "opacity") && (_ = Z(_));
}
return _;
}
function b(t, s, n) {
for (var A in t)
Object.hasOwnProperty.call(t, A) && s.call(n || t[A], t[A], A, t);
}
function w(t, s, n) {
function A(P, X) {
var g = t.removeEventListener || y.removeEventListenerPolyfill;
g && g.call(t, P, X, !1);
}
function _(P) {
var X;
if (t.nodeName) {
if (s) {
var g = {};
g[s] = !0;
} else
g = P;
b(g, function(m, L) {
if (P[L])
for (X = P[L].length; X--; )
A(L, P[L][X].fn);
});
}
}
var D = typeof t == "function" && t.prototype || t;
if (Object.hasOwnProperty.call(D, "hcEvents")) {
var W = D.hcEvents;
s ? (D = W[s] || [], n ? (W[s] = D.filter(function(P) {
return n !== P.fn;
}), A(s, n)) : (_(W), W[s] = [])) : (_(W), delete D.hcEvents);
}
}
function x(t, s, n, A) {
if (n = n || {}, c.createEvent && (t.dispatchEvent || t.fireEvent && t !== y)) {
var _ = c.createEvent("Events");
_.initEvent(s, !0, !0), n = u(_, n), t.dispatchEvent ? t.dispatchEvent(n) : t.fireEvent(s, n);
} else if (t.hcEvents) {
n.target || u(n, { preventDefault: function() {
n.defaultPrevented = !0;
}, target: t, type: s }), _ = [];
for (var D = t, W = !1; D.hcEvents; )
Object.hasOwnProperty.call(D, "hcEvents") && D.hcEvents[s] && (_.length && (W = !0), _.unshift.apply(_, D.hcEvents[s])), D = Object.getPrototypeOf(D);
W && _.sort(function(P, X) {
return P.order - X.order;
}), _.forEach(function(P) {
P.fn.call(t, n) === !1 && n.preventDefault();
});
}
A && !n.defaultPrevented && A.call(t, n);
}
var a = y.charts, c = y.doc, p = y.win;
(j || (j = {})).messages = [], Math.easeInOutSine = function(t) {
return -0.5 * (Math.cos(Math.PI * t) - 1);
};
var i = Array.prototype.find ? function(t, s) {
return t.find(s);
} : function(t, s) {
var n, A = t.length;
for (n = 0; n < A; n++)
if (s(t[n], n))
return t[n];
};
b({ map: "map", each: "forEach", grep: "filter", reduce: "reduce", some: "some" }, function(t, s) {
y[s] = function(n) {
var A;
return j(32, !1, void 0, (A = {}, A["Highcharts." + s] = "use Array." + t, A)), Array.prototype[t].apply(n, [].slice.call(arguments, 1));
};
});
var h, o = function() {
var t = Math.random().toString(36).substring(2, 9) + "-", s = 0;
return function() {
return "highcharts-" + (h ? "" : t) + s++;
};
}();
return p.jQuery && (p.jQuery.fn.highcharts = function() {
var t = [].slice.call(arguments);
if (this[0])
return t[0] ? (new y[H(t[0]) ? t.shift() : "Chart"](this[0], t[0], t[1]), this) : a[d(this[0], "data-highcharts-chart")];
}), i = { addEvent: function(t, s, n, A) {
A === void 0 && (A = {});
var _ = typeof t == "function" && t.prototype || t;
Object.hasOwnProperty.call(_, "hcEvents") || (_.hcEvents = {}), _ = _.hcEvents, y.Point && t instanceof y.Point && t.series && t.series.chart && (t.series.chart.runTrackerClick = !0);
var D = t.addEventListener || y.addEventListenerPolyfill;
return D && D.call(t, s, n, y.supportsPassiveEvents ? { passive: A.passive === void 0 ? s.indexOf("touch") !== -1 : A.passive, capture: !1 } : !1), _[s] || (_[s] = []), _[s].push({ fn: n, order: typeof A.order == "number" ? A.order : 1 / 0 }), _[s].sort(function(W, P) {
return W.order - P.order;
}), function() {
w(t, s, n);
};
}, arrayMax: function(t) {
for (var s = t.length, n = t[0]; s--; )
t[s] > n && (n = t[s]);
return n;
}, arrayMin: function(t) {
for (var s = t.length, n = t[0]; s--; )
t[s] < n && (n = t[s]);
return n;
}, attr: d, clamp: function(t, s, n) {
return t > s ? t < n ? t : n : s;
}, cleanRecursively: I, clearTimeout: function(t) {
v(t) && clearTimeout(t);
}, correctFloat: B, createElement: function(t, s, n, A, _) {
return t = c.createElement(t), s && u(t, s), _ && O(t, { padding: "0", border: "none", margin: "0" }), n && O(t, n), A && A.appendChild(t), t;
}, css: O, defined: v, destroyObjectProperties: function(t, s) {
b(t, function(n, A) {
n && n !== s && n.destroy && n.destroy(), delete t[A];
});
}, discardElement: function(t) {
t && t.parentElement && t.parentElement.removeChild(t);
}, erase: function(t, s) {
for (var n = t.length; n--; )
if (t[n] === s) {
t.splice(n, 1);
break;
}
}, error: j, extend: u, extendClass: function(t, s) {
var n = function() {
};
return n.prototype = new t(), u(n.prototype, s), n;
}, find: i, fireEvent: x, getMagnitude: function(t) {
return Math.pow(10, Math.floor(Math.log(t) / Math.LN10));
}, getNestedProperty: function(t, s) {
for (t = t.split("."); t.length && v(s); ) {
var n = t.shift();
if (typeof n > "u" || n === "__proto__" || (s = s[n], !v(s) || typeof s == "function" || typeof s.nodeType == "number" || s === p))
return;
}
return s;
}, getStyle: C, inArray: function(t, s, n) {
return j(32, !1, void 0, { "Highcharts.inArray": "use Array.indexOf" }), s.indexOf(t, n);
}, isArray: U, isClass: R, isDOMElement: N, isFunction: function(t) {
return typeof t == "function";
}, isNumber: S, isObject: F, isString: H, keys: function(t) {
return j(32, !1, void 0, { "Highcharts.keys": "use Object.keys" }), Object.keys(t);
}, merge: function() {
var t, s = arguments, n = {}, A = function(D, W) {
return typeof D != "object" && (D = {}), b(W, function(P, X) {
X !== "__proto__" && X !== "constructor" && (!F(P, !0) || R(P) || N(P) ? D[X] = W[X] : D[X] = A(D[X] || {}, P));
}), D;
};
s[0] === !0 && (n = s[1], s = Array.prototype.slice.call(s, 2));
var _ = s.length;
for (t = 0; t < _; t++)
n = A(n, s[t]);
return n;
}, normalizeTickInterval: function(t, s, n, A, _) {
var D = t;
n = T(n, 1);
var W = t / n;
for (s || (s = _ ? [1, 1.2, 1.5, 2, 2.5, 3, 4, 5, 6, 8, 10] : [1, 2, 2.5, 5, 10], A === !1 && (n === 1 ? s = s.filter(function(P) {
return P % 1 === 0;
}) : 0.1 >= n && (s = [1 / n]))), A = 0; A < s.length && (D = s[A], !(_ && D * n >= t || !_ && W <= (s[A] + (s[A + 1] || s[A])) / 2)); A++)
;
return D = B(D * n, -Math.round(Math.log(1e-3) / Math.LN10));
}, objectEach: b, offset: function(t) {
var s = c.documentElement;
return t = t.parentElement || t.parentNode ? t.getBoundingClientRect() : { top: 0, left: 0, width: 0, height: 0 }, { top: t.top + (p.pageYOffset || s.scrollTop) - (s.clientTop || 0), left: t.left + (p.pageXOffset || s.scrollLeft) - (s.clientLeft || 0), width: t.width, height: t.height };
}, pad: function(t, s, n) {
return Array((s || 2) + 1 - String(t).replace("-", "").length).join(n || "0") + t;
}, pick: T, pInt: Z, relativeLength: function(t, s, n) {
return /%$/.test(t) ? s * parseFloat(t) / 100 + (n || 0) : parseFloat(t);
}, removeEvent: w, splat: function(t) {
return U(t) ? t : [t];
}, stableSort: function(t, s) {
var n = t.length, A, _;
for (_ = 0; _ < n; _++)
t[_].safeI = _;
for (t.sort(function(D, W) {
return A = s(D, W), A === 0 ? D.safeI - W.safeI : A;
}), _ = 0; _ < n; _++)
delete t[_].safeI;
}, syncTimeout: function(t, s, n) {
return 0 < s ? setTimeout(t, s, n) : (t.call(0, n), -1);
}, timeUnits: {
millisecond: 1,
second: 1e3,
minute: 6e4,
hour: 36e5,
day: 864e5,
week: 6048e5,
month: 24192e5,
year: 314496e5
}, uniqueKey: o, useSerialIds: function(t) {
return h = T(t, h);
}, wrap: function(t, s, n) {
var A = t[s];
t[s] = function() {
var _ = Array.prototype.slice.call(arguments), D = arguments, W = this;
return W.proceed = function() {
A.apply(W, arguments.length ? arguments : D);
}, _.unshift(A), _ = n.apply(this, _), W.proceed = null, _;
};
} }, i;
}), E(l, "Core/Chart/ChartDefaults.js", [], function() {
return { panning: { enabled: !1, type: "x" }, styledMode: !1, borderRadius: 0, colorCount: 10, defaultSeriesType: "line", ignoreHiddenSeries: !0, spacing: [
10,
10,
15,
10
], resetZoomButton: { theme: { zIndex: 6 }, position: { align: "right", x: -10, y: 10 } }, zoomBySingleTouch: !1, width: null, height: null, borderColor: "#335cad", backgroundColor: "#ffffff", plotBorderColor: "#cccccc" };
}), E(l, "Core/Color/Color.js", [l["Core/Globals.js"], l["Core/Utilities.js"]], function(y, j) {
var I = j.isNumber, Z = j.merge, H = j.pInt;
return j = function() {
function U(F) {
this.rgba = [NaN, NaN, NaN, NaN], this.input = F;
var N = y.Color;
if (N && N !== U)
return new N(F);
if (!(this instanceof U))
return new U(F);
this.init(F);
}
return U.parse = function(F) {
return F ? new U(F) : U.None;
}, U.prototype.init = function(F) {
var N;
if (typeof F == "object" && typeof F.stops < "u")
this.stops = F.stops.map(function(d) {
return new U(d[1]);
});
else if (typeof F == "string") {
if (this.input = F = U.names[F.toLowerCase()] || F, F.charAt(0) === "#") {
var R = F.length, S = parseInt(F.substr(1), 16);
R === 7 ? N = [(S & 16711680) >> 16, (S & 65280) >> 8, S & 255, 1] : R === 4 && (N = [(S & 3840) >> 4 | (S & 3840) >> 8, (S & 240) >> 4 | S & 240, (S & 15) << 4 | S & 15, 1]);
}
if (!N)
for (S = U.parsers.length; S-- && !N; ) {
var v = U.parsers[S];
(R = v.regex.exec(F)) && (N = v.parse(R));
}
}
N && (this.rgba = N);
}, U.prototype.get = function(F) {
var N = this.input, R = this.rgba;
if (typeof N == "object" && typeof this.stops < "u") {
var S = Z(N);
return S.stops = [].slice.call(S.stops), this.stops.forEach(function(v, d) {
S.stops[d] = [S.stops[d][0], v.get(F)];
}), S;
}
return R && I(R[0]) ? F === "rgb" || !F && R[3] === 1 ? "rgb(" + R[0] + "," + R[1] + "," + R[2] + ")" : F === "a" ? "" + R[3] : "rgba(" + R.join(",") + ")" : N;
}, U.prototype.brighten = function(F) {
var N = this.rgba;
if (this.stops)
this.stops.forEach(function(S) {
S.brighten(F);
});
else if (I(F) && F !== 0)
for (var R = 0; 3 > R; R++)
N[R] += H(255 * F), 0 > N[R] && (N[R] = 0), 255 < N[R] && (N[R] = 255);
return this;
}, U.prototype.setOpacity = function(F) {
return this.rgba[3] = F, this;
}, U.prototype.tweenTo = function(F, N) {
var R = this.rgba, S = F.rgba;
return !I(R[0]) || !I(S[0]) ? F.input || "none" : (F = S[3] !== 1 || R[3] !== 1, (F ? "rgba(" : "rgb(") + Math.round(S[0] + (R[0] - S[0]) * (1 - N)) + "," + Math.round(S[1] + (R[1] - S[1]) * (1 - N)) + "," + Math.round(S[2] + (R[2] - S[2]) * (1 - N)) + (F ? "," + (S[3] + (R[3] - S[3]) * (1 - N)) : "") + ")");
}, U.names = { white: "#ffffff", black: "#000000" }, U.parsers = [{
regex: /rgba\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]?(?:\.[0-9]+)?)\s*\)/,
parse: function(F) {
return [H(F[1]), H(F[2]), H(F[3]), parseFloat(F[4], 10)];
}
}, { regex: /rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/, parse: function(F) {
return [H(F[1]), H(F[2]), H(F[3]), 1];
} }], U.None = new U(""), U;
}(), j;
}), E(l, "Core/Color/Palettes.js", [], function() {
return { colors: "#7cb5ec #434348 #90ed7d #f7a35c #8085e9 #f15c80 #e4d354 #2b908f #f45b5b #91e8e1".split(" ") };
}), E(l, "Core/Time.js", [l["Core/Globals.js"], l["Core/Utilities.js"]], function(y, j) {
var I = y.win, Z = j.defined, H = j.error, U = j.extend, F = j.isObject, N = j.merge, R = j.objectEach, S = j.pad, v = j.pick, d = j.splat, u = j.timeUnits, T = y.isSafari && I.Intl && I.Intl.DateTimeFormat.prototype.formatRange, O = y.isSafari && I.Intl && !I.Intl.DateTimeFormat.prototype.formatRange;
return j = function() {
function B(C) {
this.options = {}, this.variableTimezone = this.useUTC = !1, this.Date = I.Date, this.getTimezoneOffset = this.timezoneOffsetFunction(), this.update(C);
}
return B.prototype.get = function(C, b) {
if (this.variableTimezone || this.timezoneOffset) {
var w = b.getTime(), x = w - this.getTimezoneOffset(b);
return b.setTime(x), C = b["getUTC" + C](), b.setTime(w), C;
}
return this.useUTC ? b["getUTC" + C]() : b["get" + C]();
}, B.prototype.set = function(C, b, w) {
if (this.variableTimezone || this.timezoneOffset) {
if (C === "Milliseconds" || C === "Seconds" || C === "Minutes" && this.getTimezoneOffset(b) % 36e5 === 0)
return b["setUTC" + C](w);
var x = this.getTimezoneOffset(b);
return x = b.getTime() - x, b.setTime(x), b["setUTC" + C](w), C = this.getTimezoneOffset(b), x = b.getTime() + C, b.setTime(x);
}
return this.useUTC || T && C === "FullYear" ? b["setUTC" + C](w) : b["set" + C](w);
}, B.prototype.update = function(C) {
var b = v(C && C.useUTC, !0);
this.options = C = N(!0, this.options || {}, C), this.Date = C.Date || I.Date || Date, this.timezoneOffset = (this.useUTC = b) && C.timezoneOffset, this.getTimezoneOffset = this.timezoneOffsetFunction(), this.variableTimezone = b && !(!C.getTimezoneOffset && !C.timezone);
}, B.prototype.makeTime = function(C, b, w, x, a, c) {
if (this.useUTC) {
var p = this.Date.UTC.apply(0, arguments), i = this.getTimezoneOffset(p);
p += i;
var h = this.getTimezoneOffset(p);
i !== h ? p += h - i : i - 36e5 !== this.getTimezoneOffset(p - 36e5) || O || (p -= 36e5);
} else
p = new this.Date(C, b, v(w, 1), v(x, 0), v(a, 0), v(c, 0)).getTime();
return p;
}, B.prototype.timezoneOffsetFunction = function() {
var C = this, b = this.options, w = b.getTimezoneOffset, x = b.moment || I.moment;
if (!this.useUTC)
return function(a) {
return 6e4 * new Date(a.toString()).getTimezoneOffset();
};
if (b.timezone) {
if (x)
return function(a) {
return 6e4 * -x.tz(a, b.timezone).utcOffset();
};
H(25);
}
return this.useUTC && w ? function(a) {
return 6e4 * w(a.valueOf());
} : function() {
return 6e4 * (C.timezoneOffset || 0);
};
}, B.prototype.dateFormat = function(C, b, w) {
if (!Z(b) || isNaN(b))
return y.defaultOptions.lang && y.defaultOptions.lang.invalidDate || "";
C = v(C, "%Y-%m-%d %H:%M:%S");
var x = this, a = new this.Date(b), c = this.get("Hours", a), p = this.get("Day", a), i = this.get("Date", a), h = this.get("Month", a), o = this.get("FullYear", a), t = y.defaultOptions.lang, s = t && t.weekdays, n = t && t.shortWeekdays;
return a = U({ a: n ? n[p] : s[p].substr(0, 3), A: s[p], d: S(i), e: S(i, 2, " "), w: p, b: t.shortMonths[h], B: t.months[h], m: S(h + 1), o: h + 1, y: o.toString().substr(2, 2), Y: o, H: S(c), k: c, I: S(c % 12 || 12), l: c % 12 || 12, M: S(this.get("Minutes", a)), p: 12 > c ? "AM" : "PM", P: 12 > c ? "am" : "pm", S: S(a.getSeconds()), L: S(Math.floor(b % 1e3), 3) }, y.dateFormats), R(a, function(A, _) {
for (; C.indexOf("%" + _) !== -1; )
C = C.replace("%" + _, typeof A == "function" ? A.call(x, b) : A);
}), w ? C.substr(0, 1).toUpperCase() + C.substr(1) : C;
}, B.prototype.resolveDTLFormat = function(C) {
return F(C, !0) ? C : (C = d(C), { main: C[0], from: C[1], to: C[2] });
}, B.prototype.getTimeTicks = function(C, b, w, x) {
var a = this, c = [], p = {}, i = new a.Date(b), h = C.unitRange, o = C.count || 1, t;
if (x = v(x, 1), Z(b)) {
if (a.set(
"Milliseconds",
i,
h >= u.second ? 0 : o * Math.floor(a.get("Milliseconds", i) / o)
), h >= u.second && a.set("Seconds", i, h >= u.minute ? 0 : o * Math.floor(a.get("Seconds", i) / o)), h >= u.minute && a.set("Minutes", i, h >= u.hour ? 0 : o * Math.floor(a.get("Minutes", i) / o)), h >= u.hour && a.set("Hours", i, h >= u.day ? 0 : o * Math.floor(a.get("Hours", i) / o)), h >= u.day && a.set("Date", i, h >= u.month ? 1 : Math.max(1, o * Math.floor(a.get("Date", i) / o))), h >= u.month) {
a.set("Month", i, h >= u.year ? 0 : o * Math.floor(a.get("Month", i) / o));
var s = a.get("FullYear", i);
}
h >= u.year && a.set(
"FullYear",
i,
s - s % o
), h === u.week && (s = a.get("Day", i), a.set("Date", i, a.get("Date", i) - s + x + (s < x ? -7 : 0))), s = a.get("FullYear", i), x = a.get("Month", i);
var n = a.get("Date", i), A = a.get("Hours", i);
for (b = i.getTime(), !a.variableTimezone && a.useUTC || !Z(w) || (t = w - b > 4 * u.month || a.getTimezoneOffset(b) !== a.getTimezoneOffset(w)), b = i.getTime(), i = 1; b < w; )
c.push(b), b = h === u.year ? a.makeTime(s + i * o, 0) : h === u.month ? a.makeTime(s, x + i * o) : !t || h !== u.day && h !== u.week ? t && h === u.hour && 1 < o ? a.makeTime(s, x, n, A + i * o) : b + h * o : a.makeTime(s, x, n + i * o * (h === u.day ? 1 : 7)), i++;
c.push(b), h <= u.hour && 1e4 > c.length && c.forEach(function(_) {
_ % 18e5 === 0 && a.dateFormat("%H%M%S%L", _) === "000000000" && (p[_] = "day");
});
}
return c.info = U(C, { higherRanks: p, totalRange: h * o }), c;
}, B.prototype.getDateFormat = function(C, b, w, x) {
var a = this.dateFormat("%m-%d %H:%M:%S.%L", b), c = { millisecond: 15, second: 12, minute: 9, hour: 6, day: 3 }, p = "millisecond";
for (i in u) {
if (C === u.week && +this.dateFormat("%w", b) === w && a.substr(6) === "00:00:00.000") {
var i = "week";
break;
}
if (u[i] > C) {
i = p;
break;
}
if (c[i] && a.substr(c[i]) !== "01-01 00:00:00.000".substr(c[i]))
break;
i !== "week" && (p = i);
}
if (i)
var h = this.resolveDTLFormat(x[i]).main;
return h;
}, B;
}(), j;
}), E(l, "Core/DefaultOptions.js", [l["Core/Chart/ChartDefaults.js"], l["Core/Color/Color.js"], l["Core/Globals.js"], l["Core/Color/Palettes.js"], l["Core/Time.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H, U) {
j = j.parse;
var F = U.merge, N = {
colors: Z.colors,
symbols: ["circle", "diamond", "square", "triangle", "triangle-down"],
lang: {
loading: "Loading...",
months: "January February March April May June July August September October November December".split(" "),
shortMonths: "Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec".split(" "),
weekdays: "Sunday Monday Tuesday Wednesday Thursday Friday Saturday".split(" "),
decimalPoint: ".",
numericSymbols: "kMGTPE".split(""),
resetZoom: "Reset zoom",
resetZoomTitle: "Reset zoom level 1:1",
thousandsSep: " "
},
global: {},
time: { Date: void 0, getTimezoneOffset: void 0, timezone: void 0, timezoneOffset: 0, useUTC: !0 },
chart: y,
title: { text: "Chart title", align: "center", margin: 15, widthAdjust: -44 },
subtitle: { text: "", align: "center", widthAdjust: -44 },
caption: { margin: 15, text: "", align: "left", verticalAlign: "bottom" },
plotOptions: {},
labels: { style: { position: "absolute", color: "#333333" } },
legend: {
enabled: !0,
align: "center",
alignColumns: !0,
className: "highcharts-no-tooltip",
layout: "horizontal",
labelFormatter: function() {
return this.name;
},
borderColor: "#999999",
borderRadius: 0,
navigation: { activeColor: "#003399", inactiveColor: "#cccccc" },
itemStyle: { color: "#333333", cursor: "pointer", fontSize: "12px", fontWeight: "bold", textOverflow: "ellipsis" },
itemHoverStyle: { color: "#000000" },
itemHiddenStyle: { color: "#cccccc" },
shadow: !1,
itemCheckboxStyle: { position: "absolute", width: "13px", height: "13px" },
squareSymbol: !0,
symbolPadding: 5,
verticalAlign: "bottom",
x: 0,
y: 0,
title: { style: { fontWeight: "bold" } }
},
loading: { labelStyle: { fontWeight: "bold", position: "relative", top: "45%" }, style: { position: "absolute", backgroundColor: "#ffffff", opacity: 0.5, textAlign: "center" } },
tooltip: {
enabled: !0,
animation: I.svg,
borderRadius: 3,
dateTimeLabelFormats: {
millisecond: "%A, %b %e, %H:%M:%S.%L",
second: "%A, %b %e, %H:%M:%S",
minute: "%A, %b %e, %H:%M",
hour: "%A, %b %e, %H:%M",
day: "%A, %b %e, %Y",
week: "Week from %A, %b %e, %Y",
month: "%B %Y",
year: "%Y"
},
footerFormat: "",
headerShape: "callout",
hideDelay: 500,
padding: 8,
shape: "callout",
shared: !1,
snap: I.isTouchDevice ? 25 : 10,
headerFormat: '{point.key}
',
pointFormat: '● {series.name}: {point.y}
',
backgroundColor: j("#f7f7f7").setOpacity(0.85).get(),
borderWidth: 1,
shadow: !0,
stickOnContact: !1,
style: { color: "#333333", cursor: "default", fontSize: "12px", whiteSpace: "nowrap" },
useHTML: !1
},
credits: { enabled: !0, href: "https://www.highcharts.com?credits", position: { align: "right", x: -10, verticalAlign: "bottom", y: -5 }, style: { cursor: "pointer", color: "#999999", fontSize: "9px" }, text: "Highcharts.com" }
};
N.chart.styledMode = !1;
var R = new H(F(N.global, N.time));
return y = { defaultOptions: N, defaultTime: R, getOptions: function() {
return N;
}, setOptions: function(S) {
return F(!0, N, S), (S.time || S.global) && (I.time ? I.time.update(F(
N.global,
N.time,
S.global,
S.time
)) : I.time = R), N;
} }, y;
}), E(l, "Core/Animation/Fx.js", [l["Core/Color/Color.js"], l["Core/Globals.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = y.parse, H = j.win, U = I.isNumber, F = I.objectEach;
return function() {
function N(R, S, v) {
this.pos = NaN, this.options = S, this.elem = R, this.prop = v;
}
return N.prototype.dSetter = function() {
var R = this.paths, S = R && R[0];
R = R && R[1];
var v = this.now || 0, d = [];
if (v !== 1 && S && R)
if (S.length === R.length && 1 > v)
for (var u = 0; u < R.length; u++) {
for (var T = S[u], O = R[u], B = [], C = 0; C < O.length; C++) {
var b = T[C], w = O[C];
U(b) && U(w) && (O[0] !== "A" || C !== 4 && C !== 5) ? B[C] = b + v * (w - b) : B[C] = w;
}
d.push(B);
}
else
d = R;
else
d = this.toD || [];
this.elem.attr("d", d, void 0, !0);
}, N.prototype.update = function() {
var R = this.elem, S = this.prop, v = this.now, d = this.options.step;
this[S + "Setter"] ? this[S + "Setter"]() : R.attr ? R.element && R.attr(S, v, null, !0) : R.style[S] = v + this.unit, d && d.call(R, v, this);
}, N.prototype.run = function(R, S, v) {
var d = this, u = d.options, T = function(C) {
return T.stopped ? !1 : d.step(C);
}, O = H.requestAnimationFrame || function(C) {
setTimeout(
C,
13
);
}, B = function() {
for (var C = 0; C < N.timers.length; C++)
N.timers[C]() || N.timers.splice(C--, 1);
N.timers.length && O(B);
};
R !== S || this.elem["forceAnimate:" + this.prop] ? (this.startTime = +/* @__PURE__ */ new Date(), this.start = R, this.end = S, this.unit = v, this.now = this.start, this.pos = 0, T.elem = this.elem, T.prop = this.prop, T() && N.timers.push(T) === 1 && O(B)) : (delete u.curAnim[this.prop], u.complete && Object.keys(u.curAnim).length === 0 && u.complete.call(this.elem));
}, N.prototype.step = function(R) {
var S = +/* @__PURE__ */ new Date(), v = this.options, d = this.elem, u = v.complete, T = v.duration, O = v.curAnim;
if (d.attr && !d.element)
R = !1;
else if (R || S >= T + this.startTime) {
this.now = this.end, this.pos = 1, this.update();
var B = O[this.prop] = !0;
F(O, function(C) {
C !== !0 && (B = !1);
}), B && u && u.call(d), R = !1;
} else
this.pos = v.easing((S - this.startTime) / T), this.now = this.start + (this.end - this.start) * this.pos, this.update(), R = !0;
return R;
}, N.prototype.initPath = function(R, S, v) {
function d(a, c) {
for (; a.length < x; ) {
var p = a[0], i = c[x - a.length];
i && p[0] === "M" && (a[0] = i[0] === "C" ? ["C", p[1], p[2], p[1], p[2], p[1], p[2]] : [
"L",
p[1],
p[2]
]), a.unshift(p), B && (p = a.pop(), a.push(a[a.length - 1], p));
}
}
function u(a, c) {
for (; a.length < x; )
if (c = a[Math.floor(a.length / C) - 1].slice(), c[0] === "C" && (c[1] = c[5], c[2] = c[6]), B) {
var p = a[Math.floor(a.length / C)].slice();
a.splice(a.length / 2, 0, c, p);
} else
a.push(c);
}
var T = R.startX, O = R.endX;
v = v.slice();
var B = R.isArea, C = B ? 2 : 1;
if (S = S && S.slice(), !S)
return [v, v];
if (T && O && O.length) {
for (R = 0; R < T.length; R++)
if (T[R] === O[0]) {
var b = R;
break;
} else if (T[0] === O[O.length - T.length + R]) {
b = R;
var w = !0;
break;
} else if (T[T.length - 1] === O[O.length - T.length + R]) {
b = T.length - R;
break;
}
typeof b > "u" && (S = []);
}
if (S.length && U(b)) {
var x = v.length + b * C;
w ? (d(S, v), u(v, S)) : (d(v, S), u(S, v));
}
return [S, v];
}, N.prototype.fillSetter = function() {
N.prototype.strokeSetter.apply(this, arguments);
}, N.prototype.strokeSetter = function() {
this.elem.attr(this.prop, Z(this.start).tweenTo(Z(this.end), this.pos), void 0, !0);
}, N.timers = [], N;
}();
}), E(l, "Core/Animation/AnimationUtilities.js", [l["Core/Animation/Fx.js"], l["Core/Utilities.js"]], function(y, j) {
function I(u) {
return R(u) ? S({ duration: 500, defer: 0 }, u) : { duration: u ? 500 : 0, defer: 0 };
}
function Z(u, T) {
for (var O = y.timers.length; O--; )
y.timers[O].elem !== u || T && T !== y.timers[O].prop || (y.timers[O].stopped = !0);
}
var H = j.defined, U = j.getStyle, F = j.isArray, N = j.isNumber, R = j.isObject, S = j.merge, v = j.objectEach, d = j.pick;
return { animate: function(u, T, O) {
var B, C = "", b, w;
if (!R(O)) {
var x = arguments;
O = { duration: x[2], easing: x[3], complete: x[4] };
}
N(O.duration) || (O.duration = 400), O.easing = typeof O.easing == "function" ? O.easing : Math[O.easing] || Math.easeInOutSine, O.curAnim = S(T), v(T, function(a, c) {
Z(u, c), w = new y(u, O, c), b = void 0, c === "d" && F(T.d) ? (w.paths = w.initPath(u, u.pathArray, T.d), w.toD = T.d, B = 0, b = 1) : u.attr ? B = u.attr(c) : (B = parseFloat(U(u, c)) || 0, c !== "opacity" && (C = "px")), b || (b = a), typeof b == "string" && b.match("px") && (b = b.replace(/px/g, "")), w.run(B, b, C);
});
}, animObject: I, getDeferredAnimation: function(u, T, O) {
var B = I(T), C = 0, b = 0;
return (O ? [O] : u.series).forEach(function(w) {
w = I(w.options.animation), C = T && H(T.defer) ? B.defer : Math.max(C, w.duration + w.defer), b = Math.min(B.duration, w.duration);
}), u.renderer.forExport && (C = 0), { defer: Math.max(0, C - b), duration: Math.min(C, b) };
}, setAnimation: function(u, T) {
T.renderer.globalAnimation = d(u, T.options.chart.animation, !0);
}, stop: Z };
}), E(l, "Core/Renderer/HTML/AST.js", [l["Core/Globals.js"], l["Core/Utilities.js"]], function(y, j) {
var I = y.SVG_NS, Z = j.attr, H = j.createElement, U = j.error, F = j.isFunction, N = j.isString, R = j.objectEach, S = j.splat, v = (j = y.win.trustedTypes) && F(j.createPolicy) && j.createPolicy("highcharts", { createHTML: function(T) {
return T;
} }), d = v ? v.createHTML("") : "";
try {
var u = !!new DOMParser().parseFromString(d, "text/html");
} catch {
u = !1;
}
return F = function() {
function T(O) {
this.nodes = typeof O == "string" ? this.parseMarkup(O) : O;
}
return T.filterUserAttributes = function(O) {
return R(O, function(B, C) {
var b = !0;
T.allowedAttributes.indexOf(C) === -1 && (b = !1), ["background", "dynsrc", "href", "lowsrc", "src"].indexOf(C) !== -1 && (b = N(B) && T.allowedReferences.some(function(w) {
return B.indexOf(w) === 0;
})), b || (U("Highcharts warning: Invalid attribute '" + C + "' in config"), delete O[C]);
}), O;
}, T.setElementHTML = function(O, B) {
O.innerHTML = T.emptyHTML, B && new T(B).addToDOM(O);
}, T.prototype.addToDOM = function(O) {
function B(C, b) {
var w;
return S(C).forEach(function(x) {
var a = x.tagName, c = x.textContent ? y.doc.createTextNode(x.textContent) : void 0;
if (a)
if (a === "#text")
var p = c;
else if (T.allowedTags.indexOf(a) !== -1) {
a = y.doc.createElementNS(a === "svg" ? I : b.namespaceURI || I, a);
var i = x.attributes || {};
R(x, function(h, o) {
o !== "tagName" && o !== "attributes" && o !== "children" && o !== "textContent" && (i[o] = h);
}), Z(a, T.filterUserAttributes(i)), c && a.appendChild(c), B(x.children || [], a), p = a;
} else
U("Highcharts warning: Invalid tagName " + a + " in config");
p && b.appendChild(p), w = p;
}), w;
}
return B(this.nodes, O);
}, T.prototype.parseMarkup = function(O) {
var B = [];
if (O = O.trim(), u)
O = new DOMParser().parseFromString(v ? v.createHTML(O) : O, "text/html");
else {
var C = H("div");
C.innerHTML = O, O = { body: C };
}
var b = function(w, x) {
var a = w.nodeName.toLowerCase(), c = { tagName: a };
if (a === "#text" && (c.textContent = w.textContent || ""), a = w.attributes) {
var p = {};
[].forEach.call(a, function(h) {
p[h.name] = h.value;
}), c.attributes = p;
}
if (w.childNodes.length) {
var i = [];
[].forEach.call(w.childNodes, function(h) {
b(h, i);
}), i.length && (c.children = i);
}
x.push(c);
};
return [].forEach.call(O.body.childNodes, function(w) {
return b(w, B);
}), B;
}, T.allowedAttributes = "aria-controls aria-describedby aria-expanded aria-haspopup aria-hidden aria-label aria-labelledby aria-live aria-pressed aria-readonly aria-roledescription aria-selected class clip-path color colspan cx cy d dx dy disabled fill height href id in markerHeight markerWidth offset opacity orient padding paddingLeft paddingRight patternUnits r refX refY role scope slope src startOffset stdDeviation stroke stroke-linecap stroke-width style tableValues result rowspan summary target tabindex text-align textAnchor textLength title type valign width x x1 x2 y y1 y2 zIndex".split(" "), T.allowedReferences = "https:// http:// mailto: / ../ ./ #".split(" "), T.allowedTags = "a abbr b br button caption circle clipPath code dd defs div dl dt em feComponentTransfer feFuncA feFuncB feFuncG feFuncR feGaussianBlur feOffset feMerge feMergeNode filter h1 h2 h3 h4 h5 h6 hr i img li linearGradient marker ol p path pattern pre rect small span stop strong style sub sup svg table text thead tbody tspan td th tr u ul #text".split(" "), T.emptyHTML = d, T;
}(), F;
}), E(
l,
"Core/FormatUtilities.js",
[l["Core/DefaultOptions.js"], l["Core/Utilities.js"]],
function(y, j) {
function I(S, v, d, u) {
S = +S || 0, v = +v;
var T = Z.lang, O = (S.toString().split(".")[1] || "").split("e")[0].length, B = S.toString().split("e"), C = v;
if (v === -1)
v = Math.min(O, 20);
else if (!F(v))
v = 2;
else if (v && B[1] && 0 > B[1]) {
var b = v + +B[1];
0 <= b ? (B[0] = (+B[0]).toExponential(b).split("e")[0], v = b) : (B[0] = B[0].split(".")[0] || 0, S = 20 > v ? (B[0] * Math.pow(10, B[1])).toFixed(v) : 0, B[1] = 0);
}
b = (Math.abs(B[1] ? B[0] : S) + Math.pow(10, -Math.max(v, O) - 1)).toFixed(v), O = String(R(b));
var w = 3 < O.length ? O.length % 3 : 0;
return d = N(d, T.decimalPoint), u = N(u, T.thousandsSep), S = (0 > S ? "-" : "") + (w ? O.substr(0, w) + u : ""), S = 0 > +B[1] && !C ? "0" : S + O.substr(w).replace(/(\d{3})(?=\d)/g, "$1" + u), v && (S += d + b.slice(-v)), B[1] && +S != 0 && (S += "e" + B[1]), S;
}
var Z = y.defaultOptions, H = y.defaultTime, U = j.getNestedProperty, F = j.isNumber, N = j.pick, R = j.pInt;
return { dateFormat: function(S, v, d) {
return H.dateFormat(S, v, d);
}, format: function(S, v, d) {
var u = "{", T = !1, O = /f$/, B = /\.([0-9])/, C = Z.lang, b = d && d.time || H;
d = d && d.numberFormatter || I;
for (var w = []; S; ) {
var x = S.indexOf(u);
if (x === -1)
break;
var a = S.slice(0, x);
if (T) {
if (a = a.split(":"), u = U(a.shift() || "", v), a.length && typeof u == "number")
if (a = a.join(":"), O.test(a)) {
var c = parseInt((a.match(B) || ["", "-1"])[1], 10);
u !== null && (u = d(u, c, C.decimalPoint, -1 < a.indexOf(",") ? C.thousandsSep : ""));
} else
u = b.dateFormat(a, u);
w.push(u);
} else
w.push(a);
S = S.slice(x + 1), u = (T = !T) ? "}" : "{";
}
return w.push(S), w.join("");
}, numberFormat: I };
}
), E(l, "Core/Renderer/RendererUtilities.js", [l["Core/Utilities.js"]], function(y) {
var j = y.clamp, I = y.pick, Z = y.stableSort, H;
return function(U) {
function F(N, R, S) {
var v = N, d = v.reducedLen || R, u = function(w, x) {
return (x.rank || 0) - (w.rank || 0);
}, T = function(w, x) {
return w.target - x.target;
}, O, B = !0, C = [], b = 0;
for (O = N.length; O--; )
b += N[O].size;
if (b > d) {
for (Z(N, u), b = O = 0; b <= d; )
b += N[O].size, O++;
C = N.splice(O - 1, N.length);
}
for (Z(N, T), N = N.map(function(w) {
return { size: w.size, targets: [w.target], align: I(w.align, 0.5) };
}); B; ) {
for (O = N.length; O--; )
d = N[O], u = (Math.min.apply(0, d.targets) + Math.max.apply(0, d.targets)) / 2, d.pos = j(
u - d.size * d.align,
0,
R - d.size
);
for (O = N.length, B = !1; O--; )
0 < O && N[O - 1].pos + N[O - 1].size > N[O].pos && (N[O - 1].size += N[O].size, N[O - 1].targets = N[O - 1].targets.concat(N[O].targets), N[O - 1].align = 0.5, N[O - 1].pos + N[O - 1].size > R && (N[O - 1].pos = R - N[O - 1].size), N.splice(O, 1), B = !0);
}
return v.push.apply(v, C), O = 0, N.some(function(w) {
var x = 0;
return (w.targets || []).some(function() {
return v[O].pos = w.pos + x, typeof S < "u" && Math.abs(v[O].pos - v[O].target) > S ? (v.slice(0, O + 1).forEach(function(a) {
return delete a.pos;
}), v.reducedLen = (v.reducedLen || R) - 0.1 * R, v.reducedLen > 0.1 * R && F(v, R, S), !0) : (x += v[O].size, O++, !1);
});
}), Z(v, T), v;
}
U.distribute = F;
}(H || (H = {})), H;
}), E(l, "Core/Renderer/SVG/SVGElement.js", [l["Core/Animation/AnimationUtilities.js"], l["Core/Renderer/HTML/AST.js"], l["Core/Color/Color.js"], l["Core/Globals.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H) {
var U = y.animate, F = y.animObject, N = y.stop, R = Z.deg2rad, S = Z.doc, v = Z.noop, d = Z.svg, u = Z.SVG_NS, T = Z.win, O = H.addEvent, B = H.attr, C = H.createElement, b = H.css, w = H.defined, x = H.erase, a = H.extend, c = H.fireEvent, p = H.isArray, i = H.isFunction, h = H.isNumber, o = H.isString, t = H.merge, s = H.objectEach, n = H.pick, A = H.pInt, _ = H.syncTimeout, D = H.uniqueKey;
return y = function() {
function W() {
this.element = void 0, this.onEvents = {}, this.opacity = 1, this.renderer = void 0, this.SVG_NS = u, this.symbolCustomAttribs = "x y width height r start end innerR anchorX anchorY rounded".split(" ");
}
return W.prototype._defaultGetter = function(P) {
return P = n(this[P + "Value"], this[P], this.element ? this.element.getAttribute(P) : null, 0), /^[\-0-9\.]+$/.test(P) && (P = parseFloat(P)), P;
}, W.prototype._defaultSetter = function(P, X, g) {
g.setAttribute(X, P);
}, W.prototype.add = function(P) {
var X = this.renderer, g = this.element;
if (P && (this.parentGroup = P), this.parentInverted = P && P.inverted, typeof this.textStr < "u" && this.element.nodeName === "text" && X.buildText(this), this.added = !0, !P || P.handleZ || this.zIndex)
var m = this.zIndexSetter();
return m || (P ? P.element : X.box).appendChild(g), this.onAdd && this.onAdd(), this;
}, W.prototype.addClass = function(P, X) {
var g = X ? "" : this.attr("class") || "";
return P = (P || "").split(/ /g).reduce(function(m, L) {
return g.indexOf(L) === -1 && m.push(L), m;
}, g ? [g] : []).join(" "), P !== g && this.attr("class", P), this;
}, W.prototype.afterSetters = function() {
this.doTransform && (this.updateTransform(), this.doTransform = !1);
}, W.prototype.align = function(P, X, g) {
var m = {}, L = this.renderer, Y = L.alignedObjects, V, Q, k;
P ? (this.alignOptions = P, this.alignByTranslate = X, (!g || o(g)) && (this.alignTo = V = g || "renderer", x(Y, this), Y.push(this), g = void 0)) : (P = this.alignOptions, X = this.alignByTranslate, V = this.alignTo), g = n(g, L[V], V === "scrollablePlotBox" ? L.plotBox : void 0, L), V = P.align;
var G = P.verticalAlign;
return L = (g.x || 0) + (P.x || 0), Y = (g.y || 0) + (P.y || 0), V === "right" ? Q = 1 : V === "center" && (Q = 2), Q && (L += (g.width - (P.width || 0)) / Q), m[X ? "translateX" : "x"] = Math.round(L), G === "bottom" ? k = 1 : G === "middle" && (k = 2), k && (Y += (g.height - (P.height || 0)) / k), m[X ? "translateY" : "y"] = Math.round(Y), this[this.placed ? "animate" : "attr"](m), this.placed = !0, this.alignAttr = m, this;
}, W.prototype.alignSetter = function(P) {
var X = { left: "start", center: "middle", right: "end" };
X[P] && (this.alignValue = P, this.element.setAttribute(
"text-anchor",
X[P]
));
}, W.prototype.animate = function(P, X, g) {
var m = this, L = F(n(X, this.renderer.globalAnimation, !0));
return X = L.defer, n(S.hidden, S.msHidden, S.webkitHidden, !1) && (L.duration = 0), L.duration !== 0 ? (g && (L.complete = g), _(function() {
m.element && U(m, P, L);
}, X)) : (this.attr(P, void 0, g), s(P, function(Y, V) {
L.step && L.step.call(this, Y, { prop: V, pos: 1, elem: this });
}, this)), this;
}, W.prototype.applyTextOutline = function(P) {
var X = this.element;
P.indexOf("contrast") !== -1 && (P = P.replace(/contrast/g, this.renderer.getContrast(X.style.fill)));
var g = P.split(" ");
if (P = g[g.length - 1], (g = g[0]) && g !== "none" && Z.svg) {
this.fakeTS = !0, this.ySetter = this.xSetter, g = g.replace(/(^[\d\.]+)(.*?)$/g, function(Y, V, Q) {
return 2 * Number(V) + Q;
}), this.removeTextOutline();
var m = S.createElementNS(u, "tspan");
B(m, { class: "highcharts-text-outline", fill: P, stroke: P, "stroke-width": g, "stroke-linejoin": "round" }), [].forEach.call(X.childNodes, function(Y) {
var V = Y.cloneNode(!0);
V.removeAttribute && ["fill", "stroke", "stroke-width", "stroke"].forEach(function(Q) {
return V.removeAttribute(Q);
}), m.appendChild(V);
});
var L = S.createElementNS(u, "tspan");
L.textContent = "", ["x", "y"].forEach(function(Y) {
var V = X.getAttribute(Y);
V && L.setAttribute(Y, V);
}), m.appendChild(L), X.insertBefore(m, X.firstChild);
}
}, W.prototype.attr = function(P, X, g, m) {
var L = this.element, Y = this.symbolCustomAttribs, V, Q = this, k, G;
if (typeof P == "string" && typeof X < "u") {
var z = P;
P = {}, P[z] = X;
}
return typeof P == "string" ? Q = (this[P + "Getter"] || this._defaultGetter).call(this, P, L) : (s(P, function($, q) {
k = !1, m || N(this, q), this.symbolName && Y.indexOf(q) !== -1 && (V || (this.symbolAttr(P), V = !0), k = !0), !this.rotation || q !== "x" && q !== "y" || (this.doTransform = !0), k || (G = this[q + "Setter"] || this._defaultSetter, G.call(this, $, q, L), !this.styledMode && this.shadows && /^(width|height|visibility|x|y|d|transform|cx|cy|r)$/.test(q) && this.updateShadows(q, $, G));
}, this), this.afterSetters()), g && g.call(this), Q;
}, W.prototype.clip = function(P) {
return this.attr("clip-path", P ? "url(" + this.renderer.url + "#" + P.id + ")" : "none");
}, W.prototype.crisp = function(P, X) {
X = X || P.strokeWidth || 0;
var g = Math.round(X) % 2 / 2;
return P.x = Math.floor(P.x || this.x || 0) + g, P.y = Math.floor(P.y || this.y || 0) + g, P.width = Math.floor((P.width || this.width || 0) - 2 * g), P.height = Math.floor((P.height || this.height || 0) - 2 * g), w(P.strokeWidth) && (P.strokeWidth = X), P;
}, W.prototype.complexColor = function(P, X, g) {
var m = this.renderer, L, Y, V, Q, k, G, z, $, q, it, et = [], nt;
c(this.renderer, "complexColor", { args: arguments }, function() {
if (P.radialGradient ? Y = "radialGradient" : P.linearGradient && (Y = "linearGradient"), Y) {
if (V = P[Y], k = m.gradients, G = P.stops, q = g.radialReference, p(V) && (P[Y] = V = { x1: V[0], y1: V[1], x2: V[2], y2: V[3], gradientUnits: "userSpaceOnUse" }), Y === "radialGradient" && q && !w(V.gradientUnits) && (Q = V, V = t(V, m.getRadialAttr(q, Q), { gradientUnits: "userSpaceOnUse" })), s(V, function(ct, gt) {
gt !== "id" && et.push(gt, ct);
}), s(G, function(ct) {
et.push(ct);
}), et = et.join(","), k[et])
it = k[et].attr("id");
else {
V.id = it = D();
var rt = k[et] = m.createElement(Y).attr(V).add(m.defs);
rt.radAttr = Q, rt.stops = [], G.forEach(function(ct) {
ct[1].indexOf("rgba") === 0 ? (L = I.parse(ct[1]), z = L.get("rgb"), $ = L.get("a")) : (z = ct[1], $ = 1), ct = m.createElement("stop").attr({
offset: ct[0],
"stop-color": z,
"stop-opacity": $
}).add(rt), rt.stops.push(ct);
});
}
nt = "url(" + m.url + "#" + it + ")", g.setAttribute(X, nt), g.gradient = et, P.toString = function() {
return nt;
};
}
});
}, W.prototype.css = function(P) {
var X = this.styles, g = {}, m = this.element, L = ["textOutline", "textOverflow", "width"], Y = "", V = !X;
if (P && P.color && (P.fill = P.color), X && s(P, function(G, z) {
X && X[z] !== G && (g[z] = G, V = !0);
}), V) {
if (X && (P = a(X, g)), P) {
if (P.width === null || P.width === "auto")
delete this.textWidth;
else if (m.nodeName.toLowerCase() === "text" && P.width)
var Q = this.textWidth = A(P.width);
}
if (this.styles = P, Q && !d && this.renderer.forExport && delete P.width, m.namespaceURI === this.SVG_NS) {
var k = function(G, z) {
return "-" + z.toLowerCase();
};
s(P, function(G, z) {
L.indexOf(z) === -1 && (Y += z.replace(/([A-Z])/g, k) + ":" + G + ";");
}), Y && B(m, "style", Y);
} else
b(m, P);
this.added && (this.element.nodeName === "text" && this.renderer.buildText(this), P && P.textOutline && this.applyTextOutline(P.textOutline));
}
return this;
}, W.prototype.dashstyleSetter = function(P) {
var X = this["stroke-width"];
if (X === "inherit" && (X = 1), P = P && P.toLowerCase()) {
var g = P.replace("shortdashdotdot", "3,1,1,1,1,1,").replace("shortdashdot", "3,1,1,1").replace("shortdot", "1,1,").replace("shortdash", "3,1,").replace("longdash", "8,3,").replace(/dot/g, "1,3,").replace("dash", "4,3,").replace(/,$/, "").split(",");
for (P = g.length; P--; )
g[P] = "" + A(g[P]) * n(X, NaN);
P = g.join(",").replace(/NaN/g, "none"), this.element.setAttribute("stroke-dasharray", P);
}
}, W.prototype.destroy = function() {
var P = this, X = P.element || {}, g = P.renderer, m = X.ownerSVGElement, L = g.isSVG && X.nodeName === "SPAN" && P.parentGroup || void 0;
if (X.onclick = X.onmouseout = X.onmouseover = X.onmousemove = X.point = null, N(P), P.clipPath && m) {
var Y = P.clipPath;
[].forEach.call(m.querySelectorAll("[clip-path],[CLIP-PATH]"), function(V) {
-1 < V.getAttribute("clip-path").indexOf(Y.element.id) && V.removeAttribute("clip-path");
}), P.clipPath = Y.destroy();
}
if (P.stops) {
for (m = 0; m < P.stops.length; m++)
P.stops[m].destroy();
P.stops.length = 0, P.stops = void 0;
}
for (P.safeRemoveChild(X), g.styledMode || P.destroyShadows(); L && L.div && L.div.childNodes.length === 0; )
X = L.parentGroup, P.safeRemoveChild(L.div), delete L.div, L = X;
P.alignTo && x(g.alignedObjects, P), s(P, function(V, Q) {
P[Q] && P[Q].parentGroup === P && P[Q].destroy && P[Q].destroy(), delete P[Q];
});
}, W.prototype.destroyShadows = function() {
(this.shadows || []).forEach(function(P) {
this.safeRemoveChild(P);
}, this), this.shadows = void 0;
}, W.prototype.destroyTextPath = function(P, X) {
var g = P.getElementsByTagName("text")[0];
if (g) {
if (g.removeAttribute("dx"), g.removeAttribute("dy"), X.element.setAttribute("id", ""), this.textPathWrapper && g.getElementsByTagName("textPath").length) {
for (P = this.textPathWrapper.element.childNodes; P.length; )
g.appendChild(P[0]);
g.removeChild(this.textPathWrapper.element);
}
} else
(P.getAttribute("dx") || P.getAttribute("dy")) && (P.removeAttribute("dx"), P.removeAttribute("dy"));
this.textPathWrapper && (this.textPathWrapper = this.textPathWrapper.destroy());
}, W.prototype.dSetter = function(P, X, g) {
p(P) && (typeof P[0] == "string" && (P = this.renderer.pathToSegments(P)), this.pathArray = P, P = P.reduce(function(m, L, Y) {
return L && L.join ? (Y ? m + " " : "") + L.join(" ") : (L || "").toString();
}, "")), /(NaN| {2}|^$)/.test(P) && (P = "M 0 0"), this[X] !== P && (g.setAttribute(X, P), this[X] = P);
}, W.prototype.fadeOut = function(P) {
var X = this;
X.animate({ opacity: 0 }, { duration: n(P, 150), complete: function() {
X.attr({ y: -9999 }).hide();
} });
}, W.prototype.fillSetter = function(P, X, g) {
typeof P == "string" ? g.setAttribute(X, P) : P && this.complexColor(P, X, g);
}, W.prototype.getBBox = function(P, X) {
var g = this.renderer, m = this.element, L = this.styles, Y = this.textStr, V = g.cache, Q = g.cacheKeys, k = m.namespaceURI === this.SVG_NS;
X = n(X, this.rotation, 0);
var G = g.styledMode ? m && W.prototype.getStyle.call(m, "font-size") : L && L.fontSize, z;
if (w(Y)) {
var $ = Y.toString();
$.indexOf("<") === -1 && ($ = $.replace(/[0-9]/g, "0")), $ += ["", X, G, this.textWidth, L && L.textOverflow, L && L.fontWeight].join();
}
if ($ && !P && (z = V[$]), !z) {
if (k || g.forExport) {
try {
var q = this.fakeTS && function(it) {
var et = m.querySelector(".highcharts-text-outline");
et && b(et, { display: it });
};
i(q) && q("none"), z = m.getBBox ? a({}, m.getBBox()) : { width: m.offsetWidth, height: m.offsetHeight }, i(q) && q("");
} catch {
}
(!z || 0 > z.width) && (z = {
width: 0,
height: 0
});
} else
z = this.htmlGetBBox();
if (g.isSVG && (P = z.width, g = z.height, k && (z.height = g = { "11px,17": 14, "13px,20": 16 }[(G || "") + "," + Math.round(g)] || g), X && (k = X * R, z.width = Math.abs(g * Math.sin(k)) + Math.abs(P * Math.cos(k)), z.height = Math.abs(g * Math.cos(k)) + Math.abs(P * Math.sin(k)))), $ && (Y === "" || 0 < z.height)) {
for (; 250 < Q.length; )
delete V[Q.shift()];
V[$] || Q.push($), V[$] = z;
}
}
return z;
}, W.prototype.getStyle = function(P) {
return T.getComputedStyle(this.element || this, "").getPropertyValue(P);
}, W.prototype.hasClass = function(P) {
return ("" + this.attr("class")).split(" ").indexOf(P) !== -1;
}, W.prototype.hide = function(P) {
return P ? this.attr({ y: -9999 }) : this.attr({ visibility: "hidden" }), this;
}, W.prototype.htmlGetBBox = function() {
return { height: 0, width: 0, x: 0, y: 0 };
}, W.prototype.init = function(P, X) {
this.element = X === "span" ? C(X) : S.createElementNS(this.SVG_NS, X), this.renderer = P, c(this, "afterInit");
}, W.prototype.invert = function(P) {
return this.inverted = P, this.updateTransform(), this;
}, W.prototype.on = function(P, X) {
var g = this.onEvents;
return g[P] && g[P](), g[P] = O(
this.element,
P,
X
), this;
}, W.prototype.opacitySetter = function(P, X, g) {
this.opacity = P = Number(Number(P).toFixed(3)), g.setAttribute(X, P);
}, W.prototype.removeClass = function(P) {
return this.attr("class", ("" + this.attr("class")).replace(o(P) ? new RegExp("(^| )" + P + "( |$)") : P, " ").replace(/ +/g, " ").trim());
}, W.prototype.removeTextOutline = function() {
var P = this.element.querySelector("tspan.highcharts-text-outline");
P && this.safeRemoveChild(P);
}, W.prototype.safeRemoveChild = function(P) {
var X = P.parentNode;
X && X.removeChild(P);
}, W.prototype.setRadialReference = function(P) {
var X = this.element.gradient && this.renderer.gradients[this.element.gradient];
return this.element.radialReference = P, X && X.radAttr && X.animate(this.renderer.getRadialAttr(P, X.radAttr)), this;
}, W.prototype.setTextPath = function(P, X) {
var g = this.element, m = this.text ? this.text.element : g, L = { textAnchor: "text-anchor" }, Y = !1, V = this.textPathWrapper, Q = !V;
X = t(!0, { enabled: !0, attributes: { dy: -5, startOffset: "50%", textAnchor: "middle" } }, X);
var k = j.filterUserAttributes(X.attributes);
if (P && X && X.enabled) {
V && V.element.parentNode === null ? (Q = !0, V = V.destroy()) : V && this.removeTextOutline.call(V.parentGroup), this.options && this.options.padding && (k.dx = -this.options.padding), V || (this.textPathWrapper = V = this.renderer.createElement("textPath"), Y = !0);
var G = V.element;
if ((X = P.element.getAttribute("id")) || P.element.setAttribute("id", X = D()), Q)
for (m.setAttribute("y", 0), h(k.dx) && m.setAttribute("x", -k.dx), P = [].slice.call(m.childNodes), Q = 0; Q < P.length; Q++) {
var z = P[Q];
z.nodeType !== T.Node.TEXT_NODE && z.nodeName !== "tspan" || G.appendChild(z);
}
Y && V && V.add({ element: m }), G.setAttributeNS("http://www.w3.org/1999/xlink", "href", this.renderer.url + "#" + X), w(k.dy) && (G.parentNode.setAttribute("dy", k.dy), delete k.dy), w(k.dx) && (G.parentNode.setAttribute("dx", k.dx), delete k.dx), s(k, function($, q) {
G.setAttribute(L[q] || q, $);
}), g.removeAttribute("transform"), this.removeTextOutline.call(V), this.text && !this.renderer.styledMode && this.attr({ fill: "none", "stroke-width": 0 }), this.applyTextOutline = this.updateTransform = v;
} else
V && (delete this.updateTransform, delete this.applyTextOutline, this.destroyTextPath(g, P), this.updateTransform(), this.options && this.options.rotation && this.applyTextOutline(this.options.style.textOutline));
return this;
}, W.prototype.shadow = function(P, X, g) {
var m = [], L = this.element, Y = this.oldShadowOptions, V = { color: "#000000", offsetX: this.parentInverted ? -1 : 1, offsetY: this.parentInverted ? -1 : 1, opacity: 0.15, width: 3 }, Q = !1, k;
if (P === !0 ? k = V : typeof P == "object" && (k = a(V, P)), k && (k && Y && s(k, function(it, et) {
it !== Y[et] && (Q = !0);
}), Q && this.destroyShadows(), this.oldShadowOptions = k), !k)
this.destroyShadows();
else if (!this.shadows) {
var G = k.opacity / k.width, z = this.parentInverted ? "translate(" + k.offsetY + ", " + k.offsetX + ")" : "translate(" + k.offsetX + ", " + k.offsetY + ")";
for (V = 1; V <= k.width; V++) {
var $ = L.cloneNode(!1), q = 2 * k.width + 1 - 2 * V;
B($, { stroke: P.color || "#000000", "stroke-opacity": G * V, "stroke-width": q, transform: z, fill: "none" }), $.setAttribute("class", ($.getAttribute("class") || "") + " highcharts-shadow"), g && (B($, "height", Math.max(B($, "height") - q, 0)), $.cutHeight = q), X ? X.element.appendChild($) : L.parentNode && L.parentNode.insertBefore($, L), m.push($);
}
this.shadows = m;
}
return this;
}, W.prototype.show = function(P) {
return this.attr({ visibility: P ? "inherit" : "visible" });
}, W.prototype.strokeSetter = function(P, X, g) {
this[X] = P, this.stroke && this["stroke-width"] ? (W.prototype.fillSetter.call(this, this.stroke, "stroke", g), g.setAttribute("stroke-width", this["stroke-width"]), this.hasStroke = !0) : X === "stroke-width" && P === 0 && this.hasStroke ? (g.removeAttribute("stroke"), this.hasStroke = !1) : this.renderer.styledMode && this["stroke-width"] && (g.setAttribute("stroke-width", this["stroke-width"]), this.hasStroke = !0);
}, W.prototype.strokeWidth = function() {
if (!this.renderer.styledMode)
return this["stroke-width"] || 0;
var P = this.getStyle("stroke-width"), X = 0;
if (P.indexOf("px") === P.length - 2)
X = A(P);
else if (P !== "") {
var g = S.createElementNS(u, "rect");
B(g, { width: P, "stroke-width": 0 }), this.element.parentNode.appendChild(g), X = g.getBBox().width, g.parentNode.removeChild(g);
}
return X;
}, W.prototype.symbolAttr = function(P) {
var X = this;
"x y r start end width height innerR anchorX anchorY clockwise".split(" ").forEach(function(g) {
X[g] = n(P[g], X[g]);
}), X.attr({ d: X.renderer.symbols[X.symbolName](X.x, X.y, X.width, X.height, X) });
}, W.prototype.textSetter = function(P) {
P !== this.textStr && (delete this.textPxLength, this.textStr = P, this.added && this.renderer.buildText(this));
}, W.prototype.titleSetter = function(P) {
var X = this.element, g = X.getElementsByTagName("title")[0] || S.createElementNS(this.SVG_NS, "title");
X.insertBefore ? X.insertBefore(g, X.firstChild) : X.appendChild(g), g.textContent = String(n(P, "")).replace(/<[^>]*>/g, "").replace(/</g, "<").replace(
/>/g,
">"
);
}, W.prototype.toFront = function() {
var P = this.element;
return P.parentNode.appendChild(P), this;
}, W.prototype.translate = function(P, X) {
return this.attr({ translateX: P, translateY: X });
}, W.prototype.updateShadows = function(P, X, g) {
var m = this.shadows;
if (m)
for (var L = m.length; L--; )
g.call(m[L], P === "height" ? Math.max(X - (m[L].cutHeight || 0), 0) : P === "d" ? this.d : X, P, m[L]);
}, W.prototype.updateTransform = function() {
var P = this.scaleX, X = this.scaleY, g = this.inverted, m = this.rotation, L = this.matrix, Y = this.element, V = this.translateX || 0, Q = this.translateY || 0;
g && (V += this.width, Q += this.height), V = ["translate(" + V + "," + Q + ")"], w(L) && V.push("matrix(" + L.join(",") + ")"), g ? V.push("rotate(90) scale(-1,1)") : m && V.push("rotate(" + m + " " + n(this.rotationOriginX, Y.getAttribute("x"), 0) + " " + n(this.rotationOriginY, Y.getAttribute("y") || 0) + ")"), (w(P) || w(X)) && V.push("scale(" + n(P, 1) + " " + n(X, 1) + ")"), V.length && Y.setAttribute("transform", V.join(" "));
}, W.prototype.visibilitySetter = function(P, X, g) {
P === "inherit" ? g.removeAttribute(X) : this[X] !== P && g.setAttribute(
X,
P
), this[X] = P;
}, W.prototype.xGetter = function(P) {
return this.element.nodeName === "circle" && (P === "x" ? P = "cx" : P === "y" && (P = "cy")), this._defaultGetter(P);
}, W.prototype.zIndexSetter = function(P, X) {
var g = this.renderer, m = this.parentGroup, L = (m || g).element || g.box, Y = this.element;
g = L === g.box;
var V = !1, Q = this.added, k;
if (w(P) ? (Y.setAttribute("data-z-index", P), P = +P, this[X] === P && (Q = !1)) : w(this[X]) && Y.removeAttribute("data-z-index"), this[X] = P, Q) {
for ((P = this.zIndex) && m && (m.handleZ = !0), X = L.childNodes, k = X.length - 1; 0 <= k && !V; k--) {
m = X[k], Q = m.getAttribute("data-z-index");
var G = !w(Q);
m !== Y && (0 > P && G && !g && !k ? (L.insertBefore(Y, X[k]), V = !0) : (A(Q) <= P || G && (!w(P) || 0 <= P)) && (L.insertBefore(Y, X[k + 1] || null), V = !0));
}
V || (L.insertBefore(Y, X[g ? 3 : 0] || null), V = !0);
}
return V;
}, W;
}(), y.prototype["stroke-widthSetter"] = y.prototype.strokeSetter, y.prototype.yGetter = y.prototype.xGetter, y.prototype.matrixSetter = y.prototype.rotationOriginXSetter = y.prototype.rotationOriginYSetter = y.prototype.rotationSetter = y.prototype.scaleXSetter = y.prototype.scaleYSetter = y.prototype.translateXSetter = y.prototype.translateYSetter = y.prototype.verticalAlignSetter = function(W, P) {
this[P] = W, this.doTransform = !0;
}, y;
}), E(l, "Core/Renderer/RendererRegistry.js", [l["Core/Globals.js"]], function(y) {
var j;
return function(I) {
I.rendererTypes = {};
var Z;
I.getRendererType = function(H) {
return H === void 0 && (H = Z), I.rendererTypes[H] || I.rendererTypes[Z];
}, I.registerRendererType = function(H, U, F) {
I.rendererTypes[H] = U, (!Z || F) && (Z = H, y.Renderer = U);
};
}(j || (j = {})), j;
}), E(
l,
"Core/Renderer/SVG/SVGLabel.js",
[l["Core/Renderer/SVG/SVGElement.js"], l["Core/Utilities.js"]],
function(y, j) {
var I = this && this.__extends || function() {
var S = function(v, d) {
return S = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(u, T) {
u.__proto__ = T;
} || function(u, T) {
for (var O in T)
T.hasOwnProperty(O) && (u[O] = T[O]);
}, S(v, d);
};
return function(v, d) {
function u() {
this.constructor = v;
}
S(v, d), v.prototype = d === null ? Object.create(d) : (u.prototype = d.prototype, new u());
};
}(), Z = j.defined, H = j.extend, U = j.isNumber, F = j.merge, N = j.pick, R = j.removeEvent;
return function(S) {
function v(d, u, T, O, B, C, b, w, x, a) {
var c = S.call(this) || this;
c.paddingLeftSetter = c.paddingSetter, c.paddingRightSetter = c.paddingSetter, c.init(d, "g"), c.textStr = u, c.x = T, c.y = O, c.anchorX = C, c.anchorY = b, c.baseline = x, c.className = a, c.addClass(a === "button" ? "highcharts-no-tooltip" : "highcharts-label"), a && c.addClass("highcharts-" + a), c.text = d.text(void 0, 0, 0, w).attr({ zIndex: 1 });
var p;
return typeof B == "string" && ((p = /^url\((.*?)\)$/.test(B)) || c.renderer.symbols[B]) && (c.symbolKey = B), c.bBox = v.emptyBBox, c.padding = 3, c.baselineOffset = 0, c.needsBox = d.styledMode || p, c.deferredAttr = {}, c.alignFactor = 0, c;
}
return I(v, S), v.prototype.alignSetter = function(d) {
d = { left: 0, center: 0.5, right: 1 }[d], d !== this.alignFactor && (this.alignFactor = d, this.bBox && U(this.xSetting) && this.attr({ x: this.xSetting }));
}, v.prototype.anchorXSetter = function(d, u) {
this.anchorX = d, this.boxAttr(u, Math.round(d) - this.getCrispAdjust() - this.xSetting);
}, v.prototype.anchorYSetter = function(d, u) {
this.anchorY = d, this.boxAttr(u, d - this.ySetting);
}, v.prototype.boxAttr = function(d, u) {
this.box ? this.box.attr(d, u) : this.deferredAttr[d] = u;
}, v.prototype.css = function(d) {
if (d) {
var u = {};
d = F(d), v.textProps.forEach(function(O) {
typeof d[O] < "u" && (u[O] = d[O], delete d[O]);
}), this.text.css(u);
var T = "width" in u;
"fontSize" in u || "fontWeight" in u ? this.updateTextPadding() : T && this.updateBoxSize();
}
return y.prototype.css.call(this, d);
}, v.prototype.destroy = function() {
R(this.element, "mouseenter"), R(this.element, "mouseleave"), this.text && this.text.destroy(), this.box && (this.box = this.box.destroy()), y.prototype.destroy.call(this);
}, v.prototype.fillSetter = function(d, u) {
d && (this.needsBox = !0), this.fill = d, this.boxAttr(u, d);
}, v.prototype.getBBox = function() {
this.textStr && this.bBox.width === 0 && this.bBox.height === 0 && this.updateBoxSize();
var d = this.padding, u = N(this.paddingLeft, d);
return { width: this.width, height: this.height, x: this.bBox.x - u, y: this.bBox.y - d };
}, v.prototype.getCrispAdjust = function() {
return this.renderer.styledMode && this.box ? this.box.strokeWidth() % 2 / 2 : (this["stroke-width"] ? parseInt(
this["stroke-width"],
10
) : 0) % 2 / 2;
}, v.prototype.heightSetter = function(d) {
this.heightSetting = d;
}, v.prototype.onAdd = function() {
var d = this.textStr;
this.text.add(this), this.attr({ text: Z(d) ? d : "", x: this.x, y: this.y }), this.box && Z(this.anchorX) && this.attr({ anchorX: this.anchorX, anchorY: this.anchorY });
}, v.prototype.paddingSetter = function(d, u) {
U(d) ? d !== this[u] && (this[u] = d, this.updateTextPadding()) : this[u] = void 0;
}, v.prototype.rSetter = function(d, u) {
this.boxAttr(u, d);
}, v.prototype.shadow = function(d) {
return d && !this.renderer.styledMode && (this.updateBoxSize(), this.box && this.box.shadow(d)), this;
}, v.prototype.strokeSetter = function(d, u) {
this.stroke = d, this.boxAttr(u, d);
}, v.prototype["stroke-widthSetter"] = function(d, u) {
d && (this.needsBox = !0), this["stroke-width"] = d, this.boxAttr(u, d);
}, v.prototype["text-alignSetter"] = function(d) {
this.textAlign = d;
}, v.prototype.textSetter = function(d) {
typeof d < "u" && this.text.attr({ text: d }), this.updateTextPadding();
}, v.prototype.updateBoxSize = function() {
var d = this.text.element.style, u = {}, T = this.padding, O = this.bBox = U(this.widthSetting) && U(this.heightSetting) && !this.textAlign || !Z(this.text.textStr) ? v.emptyBBox : this.text.getBBox();
this.width = this.getPaddedWidth(), this.height = (this.heightSetting || O.height || 0) + 2 * T, d = this.renderer.fontMetrics(d && d.fontSize, this.text), this.baselineOffset = T + Math.min((this.text.firstLineMetrics || d).b, O.height || 1 / 0), this.heightSetting && (this.baselineOffset += (this.heightSetting - d.h) / 2), this.needsBox && (this.box || (T = this.box = this.symbolKey ? this.renderer.symbol(this.symbolKey) : this.renderer.rect(), T.addClass((this.className === "button" ? "" : "highcharts-label-box") + (this.className ? " highcharts-" + this.className + "-box" : "")), T.add(this)), T = this.getCrispAdjust(), u.x = T, u.y = (this.baseline ? -this.baselineOffset : 0) + T, u.width = Math.round(this.width), u.height = Math.round(this.height), this.box.attr(H(u, this.deferredAttr)), this.deferredAttr = {});
}, v.prototype.updateTextPadding = function() {
var d = this.text;
this.updateBoxSize();
var u = this.baseline ? 0 : this.baselineOffset, T = N(this.paddingLeft, this.padding);
Z(this.widthSetting) && this.bBox && (this.textAlign === "center" || this.textAlign === "right") && (T += { center: 0.5, right: 1 }[this.textAlign] * (this.widthSetting - this.bBox.width)), (T !== d.x || u !== d.y) && (d.attr("x", T), d.hasBoxWidthChanged && (this.bBox = d.getBBox(!0)), typeof u < "u" && d.attr("y", u)), d.x = T, d.y = u;
}, v.prototype.widthSetter = function(d) {
this.widthSetting = U(d) ? d : void 0;
}, v.prototype.getPaddedWidth = function() {
var d = this.padding, u = N(this.paddingLeft, d);
return d = N(this.paddingRight, d), (this.widthSetting || this.bBox.width || 0) + u + d;
}, v.prototype.xSetter = function(d) {
this.x = d, this.alignFactor && (d -= this.alignFactor * this.getPaddedWidth(), this["forceAnimate:x"] = !0), this.xSetting = Math.round(d), this.attr("translateX", this.xSetting);
}, v.prototype.ySetter = function(d) {
this.ySetting = this.y = Math.round(d), this.attr("translateY", this.ySetting);
}, v.emptyBBox = { width: 0, height: 0, x: 0, y: 0 }, v.textProps = "color direction fontFamily fontSize fontStyle fontWeight lineHeight textAlign textDecoration textOutline textOverflow width".split(" "), v;
}(y);
}
), E(
l,
"Core/Renderer/SVG/Symbols.js",
[l["Core/Utilities.js"]],
function(y) {
function j(N, R, S, v, d) {
var u = [];
if (d) {
var T = d.start || 0, O = F(d.r, S);
S = F(d.r, v || S);
var B = (d.end || 0) - 1e-3;
v = d.innerR;
var C = F(d.open, 1e-3 > Math.abs((d.end || 0) - T - 2 * Math.PI)), b = Math.cos(T), w = Math.sin(T), x = Math.cos(B), a = Math.sin(B);
T = F(d.longArc, 1e-3 > B - T - Math.PI ? 0 : 1), u.push(["M", N + O * b, R + S * w], ["A", O, S, 0, T, F(d.clockwise, 1), N + O * x, R + S * a]), H(v) && u.push(C ? ["M", N + v * x, R + v * a] : ["L", N + v * x, R + v * a], ["A", v, v, 0, T, H(d.clockwise) ? 1 - d.clockwise : 0, N + v * b, R + v * w]), C || u.push(["Z"]);
}
return u;
}
function I(N, R, S, v, d) {
return d && d.r ? Z(N, R, S, v, d) : [["M", N, R], ["L", N + S, R], ["L", N + S, R + v], ["L", N, R + v], ["Z"]];
}
function Z(N, R, S, v, d) {
return d = d && d.r || 0, [["M", N + d, R], ["L", N + S - d, R], ["C", N + S, R, N + S, R, N + S, R + d], ["L", N + S, R + v - d], ["C", N + S, R + v, N + S, R + v, N + S - d, R + v], ["L", N + d, R + v], ["C", N, R + v, N, R + v, N, R + v - d], ["L", N, R + d], ["C", N, R, N, R, N + d, R]];
}
var H = y.defined, U = y.isNumber, F = y.pick;
return { arc: j, callout: function(N, R, S, v, d) {
var u = Math.min(d && d.r || 0, S, v), T = u + 6, O = d && d.anchorX;
d = d && d.anchorY || 0;
var B = Z(N, R, S, v, { r: u });
return U(O) && (N + O >= S ? d > R + T && d < R + v - T ? B.splice(3, 1, ["L", N + S, d - 6], ["L", N + S + 6, d], ["L", N + S, d + 6], ["L", N + S, R + v - u]) : B.splice(3, 1, ["L", N + S, v / 2], ["L", O, d], ["L", N + S, v / 2], ["L", N + S, R + v - u]) : 0 >= N + O ? d > R + T && d < R + v - T ? B.splice(7, 1, ["L", N, d + 6], ["L", N - 6, d], ["L", N, d - 6], ["L", N, R + u]) : B.splice(7, 1, ["L", N, v / 2], ["L", O, d], ["L", N, v / 2], ["L", N, R + u]) : d && d > v && O > N + T && O < N + S - T ? B.splice(5, 1, ["L", O + 6, R + v], ["L", O, R + v + 6], ["L", O - 6, R + v], ["L", N + u, R + v]) : d && 0 > d && O > N + T && O < N + S - T && B.splice(1, 1, ["L", O - 6, R], ["L", O, R - 6], ["L", O + 6, R], ["L", S - u, R])), B;
}, circle: function(N, R, S, v) {
return j(N + S / 2, R + v / 2, S / 2, v / 2, { start: 0.5 * Math.PI, end: 2.5 * Math.PI, open: !1 });
}, diamond: function(N, R, S, v) {
return [["M", N + S / 2, R], ["L", N + S, R + v / 2], ["L", N + S / 2, R + v], ["L", N, R + v / 2], ["Z"]];
}, rect: I, roundedRect: Z, square: I, triangle: function(N, R, S, v) {
return [["M", N + S / 2, R], ["L", N + S, R + v], ["L", N, R + v], ["Z"]];
}, "triangle-down": function(N, R, S, v) {
return [["M", N, R], ["L", N + S, R], ["L", N + S / 2, R + v], ["Z"]];
} };
}
), E(l, "Core/Renderer/SVG/TextBuilder.js", [l["Core/Renderer/HTML/AST.js"], l["Core/Globals.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = j.doc, H = j.SVG_NS, U = j.win, F = I.attr, N = I.isString, R = I.objectEach, S = I.pick;
return function() {
function v(d) {
var u = d.styles;
this.renderer = d.renderer, this.svgElement = d, this.width = d.textWidth, this.textLineHeight = u && u.lineHeight, this.textOutline = u && u.textOutline, this.ellipsis = !(!u || u.textOverflow !== "ellipsis"), this.noWrap = !(!u || u.whiteSpace !== "nowrap"), this.fontSize = u && u.fontSize;
}
return v.prototype.buildSVG = function() {
var d = this.svgElement, u = d.element, T = d.renderer, O = S(d.textStr, "").toString(), B = O.indexOf("<") !== -1, C = u.childNodes;
T = this.width && !d.added && T.box;
var b = //g, w = [O, this.ellipsis, this.noWrap, this.textLineHeight, this.textOutline, this.fontSize, this.width].join();
if (w !== d.textCache) {
for (d.textCache = w, delete d.actualWidth, w = C.length; w--; )
u.removeChild(C[w]);
B || this.ellipsis || this.width || O.indexOf(" ") !== -1 && (!this.noWrap || b.test(O)) ? O !== "" && (T && T.appendChild(u), O = new y(O), this.modifyTree(O.nodes), O.addToDOM(d.element), this.modifyDOM(), this.ellipsis && (u.textContent || "").indexOf("…") !== -1 && d.attr(
"title",
this.unescapeEntities(d.textStr || "", ["<", ">"])
), T && T.removeChild(u)) : u.appendChild(Z.createTextNode(this.unescapeEntities(O))), N(this.textOutline) && d.applyTextOutline && d.applyTextOutline(this.textOutline);
}
}, v.prototype.modifyDOM = function() {
var d = this, u = this.svgElement, T = F(u.element, "x");
u.firstLineMetrics = void 0;
for (var O; (O = u.element.firstChild) && /^[\s\u200B]*$/.test(O.textContent || " "); )
u.element.removeChild(O);
[].forEach.call(u.element.querySelectorAll("tspan.highcharts-br"), function(w, x) {
w.nextSibling && w.previousSibling && (x === 0 && w.previousSibling.nodeType === 1 && (u.firstLineMetrics = u.renderer.fontMetrics(void 0, w.previousSibling)), F(w, { dy: d.getLineHeight(w.nextSibling), x: T }));
});
var B = this.width || 0;
if (B) {
var C = function(w, x) {
var a = w.textContent || "", c = a.replace(/([^\^])-/g, "$1- ").split(" "), p = !d.noWrap && (1 < c.length || 1 < u.element.childNodes.length), i = d.getLineHeight(x), h = 0, o = u.actualWidth;
if (d.ellipsis)
a && d.truncate(w, a, void 0, 0, Math.max(0, B - parseInt(d.fontSize || 12, 10)), function(t, s) {
return t.substring(
0,
s
) + "…";
});
else if (p) {
for (a = [], p = []; x.firstChild && x.firstChild !== w; )
p.push(x.firstChild), x.removeChild(x.firstChild);
for (; c.length; )
c.length && !d.noWrap && 0 < h && (a.push(w.textContent || ""), w.textContent = c.join(" ").replace(/- /g, "-")), d.truncate(w, void 0, c, h === 0 && o || 0, B, function(t, s) {
return c.slice(0, s).join(" ").replace(/- /g, "-");
}), o = u.actualWidth, h++;
p.forEach(function(t) {
x.insertBefore(t, w);
}), a.forEach(function(t) {
x.insertBefore(Z.createTextNode(t), w), t = Z.createElementNS(H, "tspan"), t.textContent = "", F(t, { dy: i, x: T }), x.insertBefore(t, w);
});
}
}, b = function(w) {
[].slice.call(w.childNodes).forEach(function(x) {
x.nodeType === U.Node.TEXT_NODE ? C(x, w) : (x.className.baseVal.indexOf("highcharts-br") !== -1 && (u.actualWidth = 0), b(x));
});
};
b(u.element);
}
}, v.prototype.getLineHeight = function(d) {
var u;
return d = d.nodeType === U.Node.TEXT_NODE ? d.parentElement : d, this.renderer.styledMode || (u = d && /(px|em)$/.test(d.style.fontSize) ? d.style.fontSize : this.fontSize || this.renderer.style.fontSize || 12), this.textLineHeight ? parseInt(
this.textLineHeight.toString(),
10
) : this.renderer.fontMetrics(u, d || this.svgElement.element).h;
}, v.prototype.modifyTree = function(d) {
var u = this, T = function(O, B) {
var C = O.attributes;
C = C === void 0 ? {} : C;
var b = O.children, w = O.tagName, x = u.renderer.styledMode;
w === "b" || w === "strong" ? x ? C.class = "highcharts-strong" : C.style = "font-weight:bold;" + (C.style || "") : (w === "i" || w === "em") && (x ? C.class = "highcharts-emphasized" : C.style = "font-style:italic;" + (C.style || "")), N(C.style) && (C.style = C.style.replace(/(;| |^)color([ :])/, "$1fill$2")), w === "br" ? (C.class = "highcharts-br", O.textContent = "", (B = d[B + 1]) && B.textContent && (B.textContent = B.textContent.replace(/^ +/gm, ""))) : w === "a" && b && b.some(function(a) {
return a.tagName === "#text";
}) && (O.children = [{ children: b, tagName: "tspan" }]), w !== "#text" && w !== "a" && (O.tagName = "tspan"), O.attributes = C, b && b.filter(function(a) {
return a.tagName !== "#text";
}).forEach(T);
};
d.forEach(T);
}, v.prototype.truncate = function(d, u, T, O, B, C) {
var b = this.svgElement, w = b.renderer, x = b.rotation, a = [], c = T ? 1 : 0, p = (u || T || "").length, i = p, h, o = function(s, n) {
n = n || s;
var A = d.parentNode;
if (A && typeof a[n] > "u")
if (A.getSubStringLength)
try {
a[n] = O + A.getSubStringLength(0, T ? n + 1 : n);
} catch {
}
else
w.getSpanWidth && (d.textContent = C(u || T, s), a[n] = O + w.getSpanWidth(b, d));
return a[n];
};
b.rotation = 0;
var t = o(d.textContent.length);
if (O + t > B) {
for (; c <= p; )
i = Math.ceil((c + p) / 2), T && (h = C(T, i)), t = o(i, h && h.length - 1), c === p ? c = p + 1 : t > B ? p = i - 1 : c = i;
p === 0 ? d.textContent = "" : u && p === u.length - 1 || (d.textContent = h || C(u || T, i));
}
T && T.splice(0, i), b.actualWidth = t, b.rotation = x;
}, v.prototype.unescapeEntities = function(d, u) {
return R(this.renderer.escapes, function(T, O) {
u && u.indexOf(T) !== -1 || (d = d.toString().replace(new RegExp(T, "g"), O));
}), d;
}, v;
}();
}), E(l, "Core/Renderer/SVG/SVGRenderer.js", [l["Core/Renderer/HTML/AST.js"], l["Core/Color/Color.js"], l["Core/Globals.js"], l["Core/Renderer/RendererRegistry.js"], l["Core/Renderer/SVG/SVGElement.js"], l["Core/Renderer/SVG/SVGLabel.js"], l["Core/Renderer/SVG/Symbols.js"], l["Core/Renderer/SVG/TextBuilder.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H, U, F, N, R) {
var S = I.charts, v = I.deg2rad, d = I.doc, u = I.isFirefox, T = I.isMS, O = I.isWebKit, B = I.noop, C = I.SVG_NS, b = I.symbolSizes, w = I.win, x = R.addEvent, a = R.attr, c = R.createElement, p = R.css, i = R.defined, h = R.destroyObjectProperties, o = R.extend, t = R.isArray, s = R.isNumber, n = R.isObject, A = R.isString, _ = R.merge, D = R.pick, W = R.pInt, P = R.uniqueKey, X;
return I = function() {
function g(m, L, Y, V, Q, k, G) {
this.width = this.url = this.style = this.isSVG = this.imgCount = this.height = this.gradients = this.globalAnimation = this.defs = this.chartIndex = this.cacheKeys = this.cache = this.boxWrapper = this.box = this.alignedObjects = void 0, this.init(m, L, Y, V, Q, k, G);
}
return g.prototype.init = function(m, L, Y, V, Q, k, G) {
var z = this.createElement("svg").attr({ version: "1.1", class: "highcharts-root" }), $ = z.element;
G || z.css(this.getStyle(V)), m.appendChild($), a(m, "dir", "ltr"), m.innerHTML.indexOf("xmlns") === -1 && a($, "xmlns", this.SVG_NS), this.isSVG = !0, this.box = $, this.boxWrapper = z, this.alignedObjects = [], this.url = this.getReferenceURL(), this.createElement("desc").add().element.appendChild(d.createTextNode("Created with Highcharts 9.3.3")), this.defs = this.createElement("defs").add(), this.allowHTML = k, this.forExport = Q, this.styledMode = G, this.gradients = {}, this.cache = {}, this.cacheKeys = [], this.imgCount = 0, this.setSize(L, Y, !1);
var q;
u && m.getBoundingClientRect && (L = function() {
p(m, { left: 0, top: 0 }), q = m.getBoundingClientRect(), p(m, { left: Math.ceil(q.left) - q.left + "px", top: Math.ceil(q.top) - q.top + "px" });
}, L(), this.unSubPixelFix = x(w, "resize", L));
}, g.prototype.definition = function(m) {
return new y([m]).addToDOM(this.defs.element);
}, g.prototype.getReferenceURL = function() {
if ((u || O) && d.getElementsByTagName("base").length) {
if (!i(X)) {
var m = P();
m = new y([{ tagName: "svg", attributes: { width: 8, height: 8 }, children: [{ tagName: "defs", children: [{ tagName: "clipPath", attributes: { id: m }, children: [{ tagName: "rect", attributes: { width: 4, height: 4 } }] }] }, { tagName: "rect", attributes: { id: "hitme", width: 8, height: 8, "clip-path": "url(#" + m + ")", fill: "rgba(0,0,0,0.001)" } }] }]).addToDOM(d.body), p(m, { position: "fixed", top: 0, left: 0, zIndex: 9e5 });
var L = d.elementFromPoint(6, 6);
X = (L && L.id) === "hitme", d.body.removeChild(m);
}
if (X)
return w.location.href.split("#")[0].replace(/<[^>]*>/g, "").replace(/([\('\)])/g, "\\$1").replace(/ /g, "%20");
}
return "";
}, g.prototype.getStyle = function(m) {
return this.style = o({ fontFamily: '"Lucida Grande", "Lucida Sans Unicode", Arial, Helvetica, sans-serif', fontSize: "12px" }, m);
}, g.prototype.setStyle = function(m) {
this.boxWrapper.css(this.getStyle(m));
}, g.prototype.isHidden = function() {
return !this.boxWrapper.getBBox().width;
}, g.prototype.destroy = function() {
var m = this.defs;
return this.box = null, this.boxWrapper = this.boxWrapper.destroy(), h(this.gradients || {}), this.gradients = null, m && (this.defs = m.destroy()), this.unSubPixelFix && this.unSubPixelFix(), this.alignedObjects = null;
}, g.prototype.createElement = function(m) {
var L = new this.Element();
return L.init(this, m), L;
}, g.prototype.getRadialAttr = function(m, L) {
return { cx: m[0] - m[2] / 2 + (L.cx || 0) * m[2], cy: m[1] - m[2] / 2 + (L.cy || 0) * m[2], r: (L.r || 0) * m[2] };
}, g.prototype.buildText = function(m) {
new N(m).buildSVG();
}, g.prototype.getContrast = function(m) {
return m = j.parse(m).rgba, m[0] *= 1, m[1] *= 1.2, m[2] *= 0.5, 459 < m[0] + m[1] + m[2] ? "#000000" : "#FFFFFF";
}, g.prototype.button = function(m, L, Y, V, Q, k, G, z, $, q) {
var it = this.label(m, L, Y, $, void 0, void 0, q, void 0, "button"), et = this.styledMode, nt = 0, rt = Q ? _(Q) : {};
if (m = rt && rt.style || {}, rt = y.filterUserAttributes(rt), it.attr(_({ padding: 8, r: 2 }, rt)), !et) {
rt = _({ fill: "#f7f7f7", stroke: "#cccccc", "stroke-width": 1, style: { color: "#333333", cursor: "pointer", fontWeight: "normal" } }, { style: m }, rt);
var ct = rt.style;
delete rt.style, k = _(rt, { fill: "#e6e6e6" }, y.filterUserAttributes(k || {}));
var gt = k.style;
delete k.style, G = _(rt, { fill: "#e6ebf5", style: { color: "#000000", fontWeight: "bold" } }, y.filterUserAttributes(G || {}));
var dt = G.style;
delete G.style, z = _(rt, { style: { color: "#cccccc" } }, y.filterUserAttributes(z || {}));
var ht = z.style;
delete z.style;
}
return x(it.element, T ? "mouseover" : "mouseenter", function() {
nt !== 3 && it.setState(1);
}), x(it.element, T ? "mouseout" : "mouseleave", function() {
nt !== 3 && it.setState(nt);
}), it.setState = function(at) {
at !== 1 && (it.state = nt = at), it.removeClass(/highcharts-button-(normal|hover|pressed|disabled)/).addClass("highcharts-button-" + ["normal", "hover", "pressed", "disabled"][at || 0]), et || it.attr([rt, k, G, z][at || 0]).css([ct, gt, dt, ht][at || 0]);
}, et || it.attr(rt).css(o({ cursor: "default" }, ct)), it.on("touchstart", function(at) {
return at.stopPropagation();
}).on("click", function(at) {
nt !== 3 && V.call(it, at);
});
}, g.prototype.crispLine = function(m, L, Y) {
Y === void 0 && (Y = "round");
var V = m[0], Q = m[1];
return i(V[1]) && V[1] === Q[1] && (V[1] = Q[1] = Math[Y](V[1]) - L % 2 / 2), i(V[2]) && V[2] === Q[2] && (V[2] = Q[2] = Math[Y](V[2]) + L % 2 / 2), m;
}, g.prototype.path = function(m) {
var L = this.styledMode ? {} : { fill: "none" };
return t(m) ? L.d = m : n(m) && o(L, m), this.createElement("path").attr(L);
}, g.prototype.circle = function(m, L, Y) {
return m = n(m) ? m : typeof m > "u" ? {} : { x: m, y: L, r: Y }, L = this.createElement("circle"), L.xSetter = L.ySetter = function(V, Q, k) {
k.setAttribute("c" + Q, V);
}, L.attr(m);
}, g.prototype.arc = function(m, L, Y, V, Q, k) {
return n(m) ? (V = m, L = V.y, Y = V.r, m = V.x) : V = { innerR: V, start: Q, end: k }, m = this.symbol("arc", m, L, Y, Y, V), m.r = Y, m;
}, g.prototype.rect = function(m, L, Y, V, Q, k) {
Q = n(m) ? m.r : Q;
var G = this.createElement("rect");
return m = n(m) ? m : typeof m > "u" ? {} : { x: m, y: L, width: Math.max(Y, 0), height: Math.max(V, 0) }, this.styledMode || (typeof k < "u" && (m["stroke-width"] = k, m = G.crisp(m)), m.fill = "none"), Q && (m.r = Q), G.rSetter = function(z, $, q) {
G.r = z, a(q, { rx: z, ry: z });
}, G.rGetter = function() {
return G.r || 0;
}, G.attr(m);
}, g.prototype.setSize = function(m, L, Y) {
this.width = m, this.height = L, this.boxWrapper.animate({ width: m, height: L }, { step: function() {
this.attr({ viewBox: "0 0 " + this.attr("width") + " " + this.attr("height") });
}, duration: D(
Y,
!0
) ? void 0 : 0 }), this.alignElements();
}, g.prototype.g = function(m) {
var L = this.createElement("g");
return m ? L.attr({ class: "highcharts-" + m }) : L;
}, g.prototype.image = function(m, L, Y, V, Q, k) {
var G = { preserveAspectRatio: "none" }, z = function(q, it) {
q.setAttributeNS ? q.setAttributeNS("http://www.w3.org/1999/xlink", "href", it) : q.setAttribute("hc-svg-href", it);
};
s(L) && (G.x = L), s(Y) && (G.y = Y), s(V) && (G.width = V), s(Q) && (G.height = Q);
var $ = this.createElement("image").attr(G);
return L = function(q) {
z($.element, m), k.call($, q);
}, k ? (z(
$.element,
"data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw=="
), Y = new w.Image(), x(Y, "load", L), Y.src = m, Y.complete && L({})) : z($.element, m), $;
}, g.prototype.symbol = function(m, L, Y, V, Q, k) {
var G = this, z = /^url\((.*?)\)$/, $ = z.test(m), q = !$ && (this.symbols[m] ? m : "circle"), it = q && this.symbols[q], et;
if (it) {
typeof L == "number" && (et = it.call(this.symbols, Math.round(L || 0), Math.round(Y || 0), V || 0, Q || 0, k));
var nt = this.path(et);
G.styledMode || nt.attr("fill", "none"), o(nt, { symbolName: q || void 0, x: L, y: Y, width: V, height: Q }), k && o(nt, k);
} else if ($) {
var rt = m.match(z)[1], ct = nt = this.image(rt);
ct.imgwidth = D(b[rt] && b[rt].width, k && k.width), ct.imgheight = D(b[rt] && b[rt].height, k && k.height);
var gt = function(dt) {
return dt.attr({ width: dt.width, height: dt.height });
};
["width", "height"].forEach(function(dt) {
ct[dt + "Setter"] = function(ht, at) {
var J = this["img" + at];
this[at] = ht, i(J) && (k && k.backgroundSize === "within" && this.width && this.height && (J = Math.round(J * Math.min(this.width / this.imgwidth, this.height / this.imgheight))), this.element && this.element.setAttribute(at, J), this.alignByTranslate || (ht = ((this[at] || 0) - J) / 2, this.attr(at === "width" ? { translateX: ht } : { translateY: ht })));
};
}), i(L) && ct.attr({ x: L, y: Y }), ct.isImg = !0, i(ct.imgwidth) && i(ct.imgheight) ? gt(ct) : (ct.attr({ width: 0, height: 0 }), c("img", { onload: function() {
var dt = S[G.chartIndex];
this.width === 0 && (p(this, { position: "absolute", top: "-999em" }), d.body.appendChild(this)), b[rt] = { width: this.width, height: this.height }, ct.imgwidth = this.width, ct.imgheight = this.height, ct.element && gt(ct), this.parentNode && this.parentNode.removeChild(this), G.imgCount--, !G.imgCount && dt && !dt.hasLoaded && dt.onload();
}, src: rt }), this.imgCount++);
}
return nt;
}, g.prototype.clipRect = function(m, L, Y, V) {
var Q = P() + "-", k = this.createElement("clipPath").attr({ id: Q }).add(this.defs);
return m = this.rect(m, L, Y, V, 0).add(k), m.id = Q, m.clipPath = k, m.count = 0, m;
}, g.prototype.text = function(m, L, Y, V) {
var Q = {};
return V && (this.allowHTML || !this.forExport) ? this.html(m, L, Y) : (Q.x = Math.round(L || 0), Y && (Q.y = Math.round(Y)), i(m) && (Q.text = m), m = this.createElement("text").attr(Q), (!V || this.forExport && !this.allowHTML) && (m.xSetter = function(k, G, z) {
for (var $ = z.getElementsByTagName("tspan"), q = z.getAttribute(G), it = 0, et; it < $.length; it++)
et = $[it], et.getAttribute(G) === q && et.setAttribute(G, k);
z.setAttribute(G, k);
}), m);
}, g.prototype.fontMetrics = function(m, L) {
return m = !this.styledMode && /px/.test(m) || !w.getComputedStyle ? m || L && L.style && L.style.fontSize || this.style && this.style.fontSize : L && H.prototype.getStyle.call(L, "font-size"), m = /px/.test(m) ? W(m) : 12, L = 24 > m ? m + 3 : Math.round(1.2 * m), { h: L, b: Math.round(0.8 * L), f: m };
}, g.prototype.rotCorr = function(m, L, Y) {
var V = m;
return L && Y && (V = Math.max(V * Math.cos(L * v), 4)), { x: -m / 3 * Math.sin(L * v), y: V };
}, g.prototype.pathToSegments = function(m) {
for (var L = [], Y = [], V = { A: 8, C: 7, H: 2, L: 3, M: 3, Q: 5, S: 5, T: 3, V: 2 }, Q = 0; Q < m.length; Q++)
A(Y[0]) && s(m[Q]) && Y.length === V[Y[0].toUpperCase()] && m.splice(Q, 0, Y[0].replace("M", "L").replace("m", "l")), typeof m[Q] == "string" && (Y.length && L.push(Y.slice(0)), Y.length = 0), Y.push(m[Q]);
return L.push(Y.slice(0)), L;
}, g.prototype.label = function(m, L, Y, V, Q, k, G, z, $) {
return new U(this, m, L, Y, V, Q, k, G, z, $);
}, g.prototype.alignElements = function() {
this.alignedObjects.forEach(function(m) {
return m.align();
});
}, g;
}(), o(I.prototype, { Element: H, SVG_NS: C, escapes: { "&": "&", "<": "<", ">": ">", "'": "'", '"': """ }, symbols: F, draw: B }), Z.registerRendererType("svg", I, !0), I;
}), E(l, "Core/Renderer/HTML/HTMLElement.js", [l["Core/Globals.js"], l["Core/Renderer/SVG/SVGElement.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = this && this.__extends || function() {
var T = function(O, B) {
return T = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(C, b) {
C.__proto__ = b;
} || function(C, b) {
for (var w in b)
b.hasOwnProperty(w) && (C[w] = b[w]);
}, T(O, B);
};
return function(O, B) {
function C() {
this.constructor = O;
}
T(O, B), O.prototype = B === null ? Object.create(B) : (C.prototype = B.prototype, new C());
};
}(), H = y.isFirefox, U = y.isMS, F = y.isWebKit, N = y.win, R = I.css, S = I.defined, v = I.extend, d = I.pick, u = I.pInt;
return function(T) {
function O() {
return T !== null && T.apply(this, arguments) || this;
}
return Z(O, T), O.compose = function(B) {
if (O.composedClasses.indexOf(B) === -1) {
O.composedClasses.push(B);
var C = O.prototype, b = B.prototype;
b.getSpanCorrection = C.getSpanCorrection, b.htmlCss = C.htmlCss, b.htmlGetBBox = C.htmlGetBBox, b.htmlUpdateTransform = C.htmlUpdateTransform, b.setSpanRotation = C.setSpanRotation;
}
return B;
}, O.prototype.getSpanCorrection = function(B, C, b) {
this.xCorr = -B * b, this.yCorr = -C;
}, O.prototype.htmlCss = function(B) {
var C = this.element.tagName === "SPAN" && B && "width" in B, b = d(C && B.width, void 0);
if (C) {
delete B.width, this.textWidth = b;
var w = !0;
}
return B && B.textOverflow === "ellipsis" && (B.whiteSpace = "nowrap", B.overflow = "hidden"), this.styles = v(this.styles, B), R(this.element, B), w && this.htmlUpdateTransform(), this;
}, O.prototype.htmlGetBBox = function() {
var B = this.element;
return { x: B.offsetLeft, y: B.offsetTop, width: B.offsetWidth, height: B.offsetHeight };
}, O.prototype.htmlUpdateTransform = function() {
if (this.added) {
var B = this.renderer, C = this.element, b = this.translateX || 0, w = this.translateY || 0, x = this.x || 0, a = this.y || 0, c = this.textAlign || "left", p = { left: 0, center: 0.5, right: 1 }[c], i = this.styles;
if (i = i && i.whiteSpace, R(C, { marginLeft: b, marginTop: w }), !B.styledMode && this.shadows && this.shadows.forEach(function(A) {
R(A, { marginLeft: b + 1, marginTop: w + 1 });
}), this.inverted && [].forEach.call(C.childNodes, function(A) {
B.invertChild(A, C);
}), C.tagName === "SPAN") {
var h = this.rotation, o = this.textWidth && u(this.textWidth), t = [h, c, C.innerHTML, this.textWidth, this.textAlign].join(), s = void 0;
if (s = !1, o !== this.oldTextWidth) {
if (this.textPxLength)
var n = this.textPxLength;
else
R(C, { width: "", whiteSpace: i || "nowrap" }), n = C.offsetWidth;
(o > this.oldTextWidth || n > o) && (/[ \-]/.test(C.textContent || C.innerText) || C.style.textOverflow === "ellipsis") && (R(C, { width: n > o || h ? o + "px" : "auto", display: "block", whiteSpace: i || "normal" }), this.oldTextWidth = o, s = !0);
}
this.hasBoxWidthChanged = s, t !== this.cTT && (s = B.fontMetrics(C.style.fontSize, C).b, !S(h) || h === (this.oldRotation || 0) && c === this.oldAlign || this.setSpanRotation(h, p, s), this.getSpanCorrection(!S(h) && this.textPxLength || C.offsetWidth, s, p, h, c)), R(C, { left: x + (this.xCorr || 0) + "px", top: a + (this.yCorr || 0) + "px" }), this.cTT = t, this.oldRotation = h, this.oldAlign = c;
}
} else
this.alignOnAdd = !0;
}, O.prototype.setSpanRotation = function(B, C, b) {
var w = {}, x = U && !/Edge/.test(N.navigator.userAgent) ? "-ms-transform" : F ? "-webkit-transform" : H ? "MozTransform" : N.opera ? "-o-transform" : void 0;
x && (w[x] = w.transform = "rotate(" + B + "deg)", w[x + (H ? "Origin" : "-origin")] = w.transformOrigin = 100 * C + "% " + b + "px", R(this.element, w));
}, O.composedClasses = [], O;
}(j);
}), E(
l,
"Core/Renderer/HTML/HTMLRenderer.js",
[l["Core/Renderer/HTML/AST.js"], l["Core/Renderer/SVG/SVGElement.js"], l["Core/Renderer/SVG/SVGRenderer.js"], l["Core/Utilities.js"]],
function(y, j, I, Z) {
var H = this && this.__extends || function() {
var S = function(v, d) {
return S = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(u, T) {
u.__proto__ = T;
} || function(u, T) {
for (var O in T)
T.hasOwnProperty(O) && (u[O] = T[O]);
}, S(v, d);
};
return function(v, d) {
function u() {
this.constructor = v;
}
S(v, d), v.prototype = d === null ? Object.create(d) : (u.prototype = d.prototype, new u());
};
}(), U = Z.attr, F = Z.createElement, N = Z.extend, R = Z.pick;
return function(S) {
function v() {
return S !== null && S.apply(this, arguments) || this;
}
return H(v, S), v.compose = function(d) {
return v.composedClasses.indexOf(d) === -1 && (v.composedClasses.push(d), d.prototype.html = v.prototype.html), d;
}, v.prototype.html = function(d, u, T) {
var O = this.createElement("span"), B = O.element, C = O.renderer, b = C.isSVG, w = function(x, a) {
["opacity", "visibility"].forEach(function(c) {
x[c + "Setter"] = function(p, i, h) {
var o = x.div ? x.div.style : a;
j.prototype[c + "Setter"].call(this, p, i, h), o && (o[i] = p);
};
}), x.addedSetters = !0;
};
return O.textSetter = function(x) {
x !== this.textStr && (delete this.bBox, delete this.oldTextWidth, y.setElementHTML(this.element, R(x, "")), this.textStr = x, O.doTransform = !0);
}, b && w(O, O.element.style), O.xSetter = O.ySetter = O.alignSetter = O.rotationSetter = function(x, a) {
a === "align" ? O.alignValue = O.textAlign = x : O[a] = x, O.doTransform = !0;
}, O.afterSetters = function() {
this.doTransform && (this.htmlUpdateTransform(), this.doTransform = !1);
}, O.attr({ text: d, x: Math.round(u), y: Math.round(T) }).css({ position: "absolute" }), C.styledMode || O.css({ fontFamily: this.style.fontFamily, fontSize: this.style.fontSize }), B.style.whiteSpace = "nowrap", O.css = O.htmlCss, b && (O.add = function(x) {
var a = C.box.parentNode, c = [];
if (this.parentGroup = x) {
var p = x.div;
if (!p) {
for (; x; )
c.push(x), x = x.parentGroup;
c.reverse().forEach(function(i) {
function h(n, A) {
i[A] = n, A === "translateX" ? s.left = n + "px" : s.top = n + "px", i.doTransform = !0;
}
var o = U(i.element, "class"), t = i.styles || {};
p = i.div = i.div || F("div", o ? { className: o } : void 0, {
position: "absolute",
left: (i.translateX || 0) + "px",
top: (i.translateY || 0) + "px",
display: i.display,
opacity: i.opacity,
cursor: t.cursor,
pointerEvents: t.pointerEvents,
visibility: i.visibility
}, p || a);
var s = p.style;
N(i, { classSetter: function(n) {
return function(A) {
this.element.setAttribute("class", A), n.className = A;
};
}(p), on: function() {
return c[0].div && O.on.apply({ element: c[0].div, onEvents: i.onEvents }, arguments), i;
}, translateXSetter: h, translateYSetter: h }), i.addedSetters || w(i);
});
}
} else
p = a;
return p.appendChild(B), O.added = !0, O.alignOnAdd && O.htmlUpdateTransform(), O;
}), O;
}, v.composedClasses = [], v;
}(I);
}
), E(l, "Core/Axis/AxisDefaults.js", [], function() {
var y;
return function(j) {
j.defaultXAxisOptions = { alignTicks: !0, allowDecimals: void 0, panningEnabled: !0, zIndex: 2, zoomEnabled: !0, dateTimeLabelFormats: { millisecond: { main: "%H:%M:%S.%L", range: !1 }, second: { main: "%H:%M:%S", range: !1 }, minute: { main: "%H:%M", range: !1 }, hour: { main: "%H:%M", range: !1 }, day: { main: "%e. %b" }, week: { main: "%e. %b" }, month: { main: "%b '%y" }, year: { main: "%Y" } }, endOnTick: !1, gridLineDashStyle: "Solid", gridZIndex: 1, labels: {
autoRotation: void 0,
autoRotationLimit: 80,
distance: void 0,
enabled: !0,
indentation: 10,
overflow: "justify",
padding: 5,
reserveSpace: void 0,
rotation: void 0,
staggerLines: 0,
step: 0,
useHTML: !1,
x: 0,
zIndex: 7,
style: { color: "#666666", cursor: "default", fontSize: "11px" }
}, maxPadding: 0.01, minorGridLineDashStyle: "Solid", minorTickLength: 2, minorTickPosition: "outside", minPadding: 0.01, offset: void 0, opposite: !1, reversed: void 0, reversedStacks: !1, showEmpty: !0, showFirstLabel: !0, showLastLabel: !0, startOfWeek: 1, startOnTick: !1, tickLength: 10, tickPixelInterval: 100, tickmarkPlacement: "between", tickPosition: "outside", title: {
align: "middle",
rotation: 0,
useHTML: !1,
x: 0,
y: 0,
style: { color: "#666666" }
}, type: "linear", uniqueNames: !0, visible: !0, minorGridLineColor: "#f2f2f2", minorGridLineWidth: 1, minorTickColor: "#999999", lineColor: "#ccd6eb", lineWidth: 1, gridLineColor: "#e6e6e6", gridLineWidth: void 0, tickColor: "#ccd6eb" }, j.defaultYAxisOptions = { reversedStacks: !0, endOnTick: !0, maxPadding: 0.05, minPadding: 0.05, tickPixelInterval: 72, showLastLabel: !0, labels: { x: -8 }, startOnTick: !0, title: { rotation: 270, text: "Values" }, stackLabels: {
animation: {},
allowOverlap: !1,
enabled: !1,
crop: !0,
overflow: "justify",
formatter: function() {
var I = this.axis.chart.numberFormatter;
return I(this.total, -1);
},
style: { color: "#000000", fontSize: "11px", fontWeight: "bold", textOutline: "1px contrast" }
}, gridLineWidth: 1, lineWidth: 0 }, j.defaultLeftAxisOptions = { labels: { x: -15 }, title: { rotation: 270 } }, j.defaultRightAxisOptions = { labels: { x: 15 }, title: { rotation: 90 } }, j.defaultBottomAxisOptions = { labels: { autoRotation: [-45], x: 0 }, margin: 15, title: { rotation: 0 } }, j.defaultTopAxisOptions = { labels: { autoRotation: [-45], x: 0 }, margin: 15, title: { rotation: 0 } };
}(y || (y = {})), y;
}), E(l, "Core/Foundation.js", [l["Core/Utilities.js"]], function(y) {
var j = y.addEvent, I = y.isFunction, Z = y.objectEach, H = y.removeEvent, U;
return function(F) {
F.registerEventOptions = function(N, R) {
N.eventOptions = N.eventOptions || {}, Z(R.events, function(S, v) {
N.eventOptions[v] !== S && (N.eventOptions[v] && (H(N, v, N.eventOptions[v]), delete N.eventOptions[v]), I(S) && (N.eventOptions[v] = S, j(N, v, S)));
});
};
}(U || (U = {})), U;
}), E(
l,
"Core/Axis/Tick.js",
[l["Core/FormatUtilities.js"], l["Core/Globals.js"], l["Core/Utilities.js"]],
function(y, j, I) {
var Z = j.deg2rad, H = I.clamp, U = I.correctFloat, F = I.defined, N = I.destroyObjectProperties, R = I.extend, S = I.fireEvent, v = I.isNumber, d = I.merge, u = I.objectEach, T = I.pick;
return j = function() {
function O(B, C, b, w, x) {
this.isNewLabel = this.isNew = !0, this.axis = B, this.pos = C, this.type = b || "", this.parameters = x || {}, this.tickmarkOffset = this.parameters.tickmarkOffset, this.options = this.parameters.options, S(this, "init"), b || w || this.addLabel();
}
return O.prototype.addLabel = function() {
var B = this, C = B.axis, b = C.options, w = C.chart, x = C.categories, a = C.logarithmic, c = C.names, p = B.pos, i = T(B.options && B.options.labels, b.labels), h = C.tickPositions, o = p === h[0], t = p === h[h.length - 1], s = (!i.step || i.step === 1) && C.tickInterval === 1;
h = h.info;
var n = B.label, A;
if (x = this.parameters.category || (x ? T(x[p], c[p], p) : p), a && v(x) && (x = U(a.lin2log(x))), C.dateTime)
if (h)
var _ = w.time.resolveDTLFormat(b.dateTimeLabelFormats[!b.grid && h.higherRanks[p] || h.unitName]), D = _.main;
else
v(x) && (D = C.dateTime.getXDateFormat(x, b.dateTimeLabelFormats || {}));
B.isFirst = o, B.isLast = t;
var W = {
axis: C,
chart: w,
dateTimeLabelFormat: D,
isFirst: o,
isLast: t,
pos: p,
tick: B,
tickPositionInfo: h,
value: x
};
S(this, "labelFormat", W);
var P = function(g) {
return i.formatter ? i.formatter.call(g, g) : i.format ? (g.text = C.defaultLabelFormatter.call(g), y.format(i.format, g, w)) : C.defaultLabelFormatter.call(g, g);
};
b = P.call(W, W);
var X = _ && _.list;
B.shortenLabel = X ? function() {
for (A = 0; A < X.length; A++)
if (R(W, { dateTimeLabelFormat: X[A] }), n.attr({ text: P.call(W, W) }), n.getBBox().width < C.getSlotWidth(B) - 2 * i.padding)
return;
n.attr({ text: "" });
} : void 0, s && C._addedPlotLB && B.moveLabel(b, i), F(n) || B.movedLabel ? n && n.textStr !== b && !s && (!n.textWidth || i.style.width || n.styles.width || n.css({ width: null }), n.attr({ text: b }), n.textPxLength = n.getBBox().width) : (B.label = n = B.createLabel({ x: 0, y: 0 }, b, i), B.rotation = 0);
}, O.prototype.createLabel = function(B, C, b) {
var w = this.axis, x = w.chart;
return (B = F(C) && b.enabled ? x.renderer.text(C, B.x, B.y, b.useHTML).add(w.labelGroup) : null) && (x.styledMode || B.css(d(b.style)), B.textPxLength = B.getBBox().width), B;
}, O.prototype.destroy = function() {
N(
this,
this.axis
);
}, O.prototype.getPosition = function(B, C, b, w) {
var x = this.axis, a = x.chart, c = w && a.oldChartHeight || a.chartHeight;
return B = { x: B ? U(x.translate(C + b, null, null, w) + x.transB) : x.left + x.offset + (x.opposite ? (w && a.oldChartWidth || a.chartWidth) - x.right - x.left : 0), y: B ? c - x.bottom + x.offset - (x.opposite ? x.height : 0) : U(c - x.translate(C + b, null, null, w) - x.transB) }, B.y = H(B.y, -1e5, 1e5), S(this, "afterGetPosition", { pos: B }), B;
}, O.prototype.getLabelPosition = function(B, C, b, w, x, a, c, p) {
var i = this.axis, h = i.transA, o = i.isLinked && i.linkedParent ? i.linkedParent.reversed : i.reversed, t = i.staggerLines, s = i.tickRotCorr || { x: 0, y: 0 }, n = w || i.reserveSpaceDefault ? 0 : -i.labelOffset * (i.labelAlign === "center" ? 0.5 : 1), A = {}, _ = x.y;
return F(_) || (_ = i.side === 0 ? b.rotation ? -8 : -b.getBBox().height : i.side === 2 ? s.y + 8 : Math.cos(b.rotation * Z) * (s.y - b.getBBox(!1, 0).height / 2)), B = B + x.x + n + s.x - (a && w ? a * h * (o ? -1 : 1) : 0), C = C + _ - (a && !w ? a * h * (o ? 1 : -1) : 0), t && (b = c / (p || 1) % t, i.opposite && (b = t - b - 1), C += i.labelOffset / t * b), A.x = B, A.y = Math.round(C), S(this, "afterGetLabelPosition", { pos: A, tickmarkOffset: a, index: c }), A;
}, O.prototype.getLabelSize = function() {
return this.label ? this.label.getBBox()[this.axis.horiz ? "height" : "width"] : 0;
}, O.prototype.getMarkPath = function(B, C, b, w, x, a) {
return a.crispLine([["M", B, C], ["L", B + (x ? 0 : -b), C + (x ? b : 0)]], w);
}, O.prototype.handleOverflow = function(B) {
var C = this.axis, b = C.options.labels, w = B.x, x = C.chart.chartWidth, a = C.chart.spacing, c = T(C.labelLeft, Math.min(C.pos, a[3]));
a = T(C.labelRight, Math.max(C.isRadial ? 0 : C.pos + C.len, x - a[1]));
var p = this.label, i = this.rotation, h = { left: 0, center: 0.5, right: 1 }[C.labelAlign || p.attr("align")], o = p.getBBox().width, t = C.getSlotWidth(this), s = {}, n = t, A = 1, _;
i || b.overflow !== "justify" ? 0 > i && w - h * o < c ? _ = Math.round(w / Math.cos(i * Z) - c) : 0 < i && w + h * o > a && (_ = Math.round((x - w) / Math.cos(i * Z))) : (x = w + (1 - h) * o, w - h * o < c ? n = B.x + n * (1 - h) - c : x > a && (n = a - B.x + n * h, A = -1), n = Math.min(t, n), n < t && C.labelAlign === "center" && (B.x += A * (t - n - h * (t - Math.min(o, n)))), (o > n || C.autoRotation && (p.styles || {}).width) && (_ = n)), _ && (this.shortenLabel ? this.shortenLabel() : (s.width = Math.floor(_) + "px", (b.style || {}).textOverflow || (s.textOverflow = "ellipsis"), p.css(s)));
}, O.prototype.moveLabel = function(B, C) {
var b = this, w = b.label, x = b.axis, a = x.reversed, c = !1;
if (w && w.textStr === B ? (b.movedLabel = w, c = !0, delete b.label) : u(x.ticks, function(i) {
c || i.isNew || i === b || !i.label || i.label.textStr !== B || (b.movedLabel = i.label, c = !0, i.labelPos = b.movedLabel.xy, delete i.label);
}), !c && (b.labelPos || w)) {
var p = b.labelPos || w.xy;
w = x.horiz ? a ? 0 : x.width + x.left : p.x, x = x.horiz ? p.y : a ? x.width + x.left : 0, b.movedLabel = b.createLabel({ x: w, y: x }, B, C), b.movedLabel && b.movedLabel.attr({ opacity: 0 });
}
}, O.prototype.render = function(B, C, b) {
var w = this.axis, x = w.horiz, a = this.pos, c = T(this.tickmarkOffset, w.tickmarkOffset);
a = this.getPosition(x, a, c, C), c = a.x;
var p = a.y;
w = x && c === w.pos + w.len || !x && p === w.pos ? -1 : 1, x = T(b, this.label && this.label.newOpacity, 1), b = T(b, 1), this.isActive = !0, this.renderGridLine(C, b, w), this.renderMark(a, b, w), this.renderLabel(a, C, x, B), this.isNew = !1, S(this, "afterRender");
}, O.prototype.renderGridLine = function(B, C, b) {
var w = this.axis, x = w.options, a = {}, c = this.pos, p = this.type, i = T(
this.tickmarkOffset,
w.tickmarkOffset
), h = w.chart.renderer, o = this.gridLine, t = x.gridLineWidth, s = x.gridLineColor, n = x.gridLineDashStyle;
this.type === "minor" && (t = x.minorGridLineWidth, s = x.minorGridLineColor, n = x.minorGridLineDashStyle), o || (w.chart.styledMode || (a.stroke = s, a["stroke-width"] = t || 0, a.dashstyle = n), p || (a.zIndex = 1), B && (C = 0), this.gridLine = o = h.path().attr(a).addClass("highcharts-" + (p ? p + "-" : "") + "grid-line").add(w.gridGroup)), o && (b = w.getPlotLinePath({ value: c + i, lineWidth: o.strokeWidth() * b, force: "pass", old: B })) && o[B || this.isNew ? "attr" : "animate"]({ d: b, opacity: C });
}, O.prototype.renderMark = function(B, C, b) {
var w = this.axis, x = w.options, a = w.chart.renderer, c = this.type, p = w.tickSize(c ? c + "Tick" : "tick"), i = B.x;
B = B.y;
var h = T(x[c !== "minor" ? "tickWidth" : "minorTickWidth"], !c && w.isXAxis ? 1 : 0);
x = x[c !== "minor" ? "tickColor" : "minorTickColor"];
var o = this.mark, t = !o;
p && (w.opposite && (p[0] = -p[0]), o || (this.mark = o = a.path().addClass("highcharts-" + (c ? c + "-" : "") + "tick").add(w.axisGroup), w.chart.styledMode || o.attr({ stroke: x, "stroke-width": h })), o[t ? "attr" : "animate"]({ d: this.getMarkPath(
i,
B,
p[0],
o.strokeWidth() * b,
w.horiz,
a
), opacity: C }));
}, O.prototype.renderLabel = function(B, C, b, w) {
var x = this.axis, a = x.horiz, c = x.options, p = this.label, i = c.labels, h = i.step;
x = T(this.tickmarkOffset, x.tickmarkOffset);
var o = B.x;
B = B.y;
var t = !0;
p && v(o) && (p.xy = B = this.getLabelPosition(o, B, p, a, i, x, w, h), this.isFirst && !this.isLast && !c.showFirstLabel || this.isLast && !this.isFirst && !c.showLastLabel ? t = !1 : !a || i.step || i.rotation || C || b === 0 || this.handleOverflow(B), h && w % h && (t = !1), t && v(B.y) ? (B.opacity = b, p[this.isNewLabel ? "attr" : "animate"](B), this.isNewLabel = !1) : (p.attr("y", -9999), this.isNewLabel = !0));
}, O.prototype.replaceMovedLabel = function() {
var B = this.label, C = this.axis, b = C.reversed;
if (B && !this.isNew) {
var w = C.horiz ? b ? C.left : C.width + C.left : B.xy.x;
b = C.horiz ? B.xy.y : b ? C.width + C.top : C.top, B.animate({ x: w, y: b, opacity: 0 }, void 0, B.destroy), delete this.label;
}
C.isDirty = !0, this.label = this.movedLabel, delete this.movedLabel;
}, O;
}(), j;
}
), E(l, "Core/Axis/Axis.js", [
l["Core/Animation/AnimationUtilities.js"],
l["Core/Axis/AxisDefaults.js"],
l["Core/Color/Color.js"],
l["Core/DefaultOptions.js"],
l["Core/Foundation.js"],
l["Core/Globals.js"],
l["Core/Axis/Tick.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z, H, U, F, N) {
var R = y.animObject, S = Z.defaultOptions, v = H.registerEventOptions, d = U.deg2rad, u = N.arrayMax, T = N.arrayMin, O = N.clamp, B = N.correctFloat, C = N.defined, b = N.destroyObjectProperties, w = N.erase, x = N.error, a = N.extend, c = N.fireEvent, p = N.getMagnitude, i = N.isArray, h = N.isNumber, o = N.isString, t = N.merge, s = N.normalizeTickInterval, n = N.objectEach, A = N.pick, _ = N.relativeLength, D = N.removeEvent, W = N.splat, P = N.syncTimeout;
return y = function() {
function X(g, m) {
this.zoomEnabled = this.width = this.visible = this.userOptions = this.translationSlope = this.transB = this.transA = this.top = this.ticks = this.tickRotCorr = this.tickPositions = this.tickmarkOffset = this.tickInterval = this.tickAmount = this.side = this.series = this.right = this.positiveValuesOnly = this.pos = this.pointRangePadding = this.pointRange = this.plotLinesAndBandsGroups = this.plotLinesAndBands = this.paddedTicks = this.overlap = this.options = this.offset = this.names = this.minPixelPadding = this.minorTicks = this.minorTickInterval = this.min = this.maxLabelLength = this.max = this.len = this.left = this.labelFormatter = this.labelEdge = this.isLinked = this.height = this.hasVisibleSeries = this.hasNames = this.eventOptions = this.coll = this.closestPointRange = this.chart = this.categories = this.bottom = this.alternateBands = void 0, this.init(g, m);
}
return X.prototype.init = function(g, m) {
var L = m.isX;
this.chart = g, this.horiz = g.inverted && !this.isZAxis ? !L : L, this.isXAxis = L, this.coll = this.coll || (L ? "xAxis" : "yAxis"), c(this, "init", { userOptions: m }), this.opposite = A(m.opposite, this.opposite), this.side = A(m.side, this.side, this.horiz ? this.opposite ? 0 : 2 : this.opposite ? 1 : 3), this.setOptions(m);
var Y = this.options, V = Y.labels, Q = Y.type;
this.userOptions = m, this.minPixelPadding = 0, this.reversed = A(Y.reversed, this.reversed), this.visible = Y.visible, this.zoomEnabled = Y.zoomEnabled, this.hasNames = Q === "category" || Y.categories === !0, this.categories = Y.categories || this.hasNames, this.names || (this.names = [], this.names.keys = {}), this.plotLinesAndBandsGroups = {}, this.positiveValuesOnly = !!this.logarithmic, this.isLinked = C(Y.linkedTo), this.ticks = {}, this.labelEdge = [], this.minorTicks = {}, this.plotLinesAndBands = [], this.alternateBands = {}, this.len = 0, this.minRange = this.userMinRange = Y.minRange || Y.maxZoom, this.range = Y.range, this.offset = Y.offset || 0, this.min = this.max = null, m = A(Y.crosshair, W(g.options.tooltip.crosshairs)[L ? 0 : 1]), this.crosshair = m === !0 ? {} : m, g.axes.indexOf(this) === -1 && (L ? g.axes.splice(g.xAxis.length, 0, this) : g.axes.push(this), g[this.coll].push(this)), this.series = this.series || [], g.inverted && !this.isZAxis && L && typeof this.reversed > "u" && (this.reversed = !0), this.labelRotation = h(V.rotation) ? V.rotation : void 0, v(this, Y), c(this, "afterInit");
}, X.prototype.setOptions = function(g) {
this.options = t(j.defaultXAxisOptions, this.coll === "yAxis" && j.defaultYAxisOptions, [j.defaultTopAxisOptions, j.defaultRightAxisOptions, j.defaultBottomAxisOptions, j.defaultLeftAxisOptions][this.side], t(S[this.coll], g)), c(this, "afterSetOptions", { userOptions: g });
}, X.prototype.defaultLabelFormatter = function(g) {
var m = this.axis;
g = this.chart.numberFormatter;
var L = h(this.value) ? this.value : NaN, Y = m.chart.time, V = this.dateTimeLabelFormat, Q = S.lang, k = Q.numericSymbols;
Q = Q.numericSymbolMagnitude || 1e3;
var G = m.logarithmic ? Math.abs(L) : m.tickInterval, z = k && k.length;
if (m.categories)
var $ = "" + this.value;
else if (V)
$ = Y.dateFormat(V, L);
else if (z && 1e3 <= G)
for (; z-- && typeof $ > "u"; )
m = Math.pow(Q, z + 1), G >= m && 10 * L % m === 0 && k[z] !== null && L !== 0 && ($ = g(L / m, -1) + k[z]);
return typeof $ > "u" && ($ = 1e4 <= Math.abs(L) ? g(L, -1) : g(L, -1, void 0, "")), $;
}, X.prototype.getSeriesExtremes = function() {
var g = this, m = g.chart, L;
c(this, "getSeriesExtremes", null, function() {
g.hasVisibleSeries = !1, g.dataMin = g.dataMax = g.threshold = null, g.softThreshold = !g.isXAxis, g.stacking && g.stacking.buildStacks(), g.series.forEach(function(Y) {
if (Y.visible || !m.options.chart.ignoreHiddenSeries) {
var V = Y.options, Q = V.threshold;
if (g.hasVisibleSeries = !0, g.positiveValuesOnly && 0 >= Q && (Q = null), g.isXAxis) {
if (V = Y.xData, V.length) {
V = g.logarithmic ? V.filter(g.validatePositiveValue) : V, L = Y.getXExtremes(V);
var k = L.min, G = L.max;
h(k) || k instanceof Date || (V = V.filter(h), L = Y.getXExtremes(V), k = L.min, G = L.max), V.length && (g.dataMin = Math.min(A(g.dataMin, k), k), g.dataMax = Math.max(A(g.dataMax, G), G));
}
} else
Y = Y.applyExtremes(), h(Y.dataMin) && (k = Y.dataMin, g.dataMin = Math.min(A(g.dataMin, k), k)), h(Y.dataMax) && (G = Y.dataMax, g.dataMax = Math.max(A(g.dataMax, G), G)), C(Q) && (g.threshold = Q), (!V.softThreshold || g.positiveValuesOnly) && (g.softThreshold = !1);
}
});
}), c(this, "afterGetSeriesExtremes");
}, X.prototype.translate = function(g, m, L, Y, V, Q) {
var k = this.linkedParent || this, G = Y && k.old ? k.old.min : k.min, z = k.minPixelPadding;
V = (k.isOrdinal || k.brokenAxis && k.brokenAxis.hasBreaks || k.logarithmic && V) && k.lin2val;
var $ = 1, q = 0;
return Y = Y && k.old ? k.old.transA : k.transA, Y || (Y = k.transA), L && ($ *= -1, q = k.len), k.reversed && ($ *= -1, q -= $ * (k.sector || k.len)), m ? (g = (g * $ + q - z) / Y + G, V && (g = k.lin2val(g))) : (V && (g = k.val2lin(g)), g = h(G) ? $ * (g - G) * Y + q + $ * z + (h(Q) ? Y * Q : 0) : void 0), g;
}, X.prototype.toPixels = function(g, m) {
return this.translate(
g,
!1,
!this.horiz,
null,
!0
) + (m ? 0 : this.pos);
}, X.prototype.toValue = function(g, m) {
return this.translate(g - (m ? 0 : this.pos), !0, !this.horiz, null, !0);
}, X.prototype.getPlotLinePath = function(g) {
function m(at, J, tt) {
return (nt !== "pass" && at < J || at > tt) && (nt ? at = O(at, J, tt) : ht = !0), at;
}
var L = this, Y = L.chart, V = L.left, Q = L.top, k = g.old, G = g.value, z = g.lineWidth, $ = k && Y.oldChartHeight || Y.chartHeight, q = k && Y.oldChartWidth || Y.chartWidth, it = L.transB, et = g.translatedValue, nt = g.force, rt, ct, gt, dt, ht;
return g = {
value: G,
lineWidth: z,
old: k,
force: nt,
acrossPanes: g.acrossPanes,
translatedValue: et
}, c(this, "getPlotLinePath", g, function(at) {
et = A(et, L.translate(G, null, null, k)), et = O(et, -1e5, 1e5), rt = gt = Math.round(et + it), ct = dt = Math.round($ - et - it), h(et) ? L.horiz ? (ct = Q, dt = $ - L.bottom, rt = gt = m(rt, V, V + L.width)) : (rt = V, gt = q - L.right, ct = dt = m(ct, Q, Q + L.height)) : (ht = !0, nt = !1), at.path = ht && !nt ? null : Y.renderer.crispLine([["M", rt, ct], ["L", gt, dt]], z || 1);
}), g.path;
}, X.prototype.getLinearTickPositions = function(g, m, L) {
var Y = B(Math.floor(m / g) * g);
L = B(Math.ceil(L / g) * g);
var V = [], Q;
if (B(Y + g) === Y && (Q = 20), this.single)
return [m];
for (m = Y; m <= L && (V.push(m), m = B(m + g, Q), m !== k); )
var k = m;
return V;
}, X.prototype.getMinorTickInterval = function() {
var g = this.options;
return g.minorTicks === !0 ? A(g.minorTickInterval, "auto") : g.minorTicks === !1 ? null : g.minorTickInterval;
}, X.prototype.getMinorTickPositions = function() {
var g = this.options, m = this.tickPositions, L = this.minorTickInterval, Y = this.pointRangePadding || 0, V = this.min - Y;
Y = this.max + Y;
var Q = Y - V, k = [];
if (Q && Q / L < this.len / 3) {
var G = this.logarithmic;
if (G)
this.paddedTicks.forEach(function(z, $, q) {
$ && k.push.apply(
k,
G.getLogTickPositions(L, q[$ - 1], q[$], !0)
);
});
else if (this.dateTime && this.getMinorTickInterval() === "auto")
k = k.concat(this.getTimeTicks(this.dateTime.normalizeTimeTickInterval(L), V, Y, g.startOfWeek));
else
for (g = V + (m[0] - V) % L; g <= Y && g !== k[0]; g += L)
k.push(g);
}
return k.length !== 0 && this.trimTicks(k), k;
}, X.prototype.adjustForMinRange = function() {
var g = this.options, m = this.logarithmic, L = this.min, Y = this.max, V = 0, Q, k, G, z;
if (this.isXAxis && typeof this.minRange > "u" && !m && (C(g.min) || C(g.max) || C(g.floor) || C(g.ceiling) ? this.minRange = null : (this.series.forEach(function(et) {
if (G = et.xData, z = et.xIncrement ? 1 : G.length - 1, 1 < G.length)
for (Q = z; 0 < Q; Q--)
k = G[Q] - G[Q - 1], (!V || k < V) && (V = k);
}), this.minRange = Math.min(5 * V, this.dataMax - this.dataMin))), Y - L < this.minRange) {
var $ = this.dataMax - this.dataMin >= this.minRange, q = this.minRange, it = (q - Y + L) / 2;
it = [L - it, A(g.min, L - it)], $ && (it[2] = this.logarithmic ? this.logarithmic.log2lin(this.dataMin) : this.dataMin), L = u(it), Y = [L + q, A(g.max, L + q)], $ && (Y[2] = m ? m.log2lin(this.dataMax) : this.dataMax), Y = T(Y), Y - L < q && (it[0] = Y - q, it[1] = A(g.min, Y - q), L = u(it));
}
this.min = L, this.max = Y;
}, X.prototype.getClosest = function() {
var g;
return this.categories ? g = 1 : this.series.forEach(function(m) {
var L = m.closestPointRange, Y = m.visible || !m.chart.options.chart.ignoreHiddenSeries;
!m.noSharedTooltip && C(L) && Y && (g = C(g) ? Math.min(g, L) : L);
}), g;
}, X.prototype.nameToX = function(g) {
var m = i(this.categories), L = m ? this.categories : this.names, Y = g.options.x;
if (g.series.requireSorting = !1, C(Y) || (Y = this.options.uniqueNames ? m ? L.indexOf(g.name) : A(L.keys[g.name], -1) : g.series.autoIncrement()), Y === -1) {
if (!m)
var V = L.length;
} else
V = Y;
return typeof V < "u" && (this.names[V] = g.name, this.names.keys[g.name] = V), V;
}, X.prototype.updateNames = function() {
var g = this, m = this.names;
0 < m.length && (Object.keys(m.keys).forEach(function(L) {
delete m.keys[L];
}), m.length = 0, this.minRange = this.userMinRange, (this.series || []).forEach(function(L) {
L.xIncrement = null, (!L.points || L.isDirtyData) && (g.max = Math.max(g.max, L.xData.length - 1), L.processData(), L.generatePoints()), L.data.forEach(function(Y, V) {
if (Y && Y.options && typeof Y.name < "u") {
var Q = g.nameToX(Y);
typeof Q < "u" && Q !== Y.x && (Y.x = Q, L.xData[V] = Q);
}
});
}));
}, X.prototype.setAxisTranslation = function() {
var g = this, m = g.max - g.min, L = g.linkedParent, Y = !!g.categories, V = g.isXAxis, Q = g.axisPointRange || 0, k = 0, G = 0, z = g.transA;
if (V || Y || Q) {
var $ = g.getClosest();
L ? (k = L.minPointOffset, G = L.pointRangePadding) : g.series.forEach(function(q) {
var it = Y ? 1 : V ? A(q.options.pointRange, $, 0) : g.axisPointRange || 0, et = q.options.pointPlacement;
Q = Math.max(Q, it), (!g.single || Y) && (q = q.is("xrange") ? !V : V, k = Math.max(k, q && o(et) ? 0 : it / 2), G = Math.max(G, q && et === "on" ? 0 : it));
}), L = g.ordinal && g.ordinal.slope && $ ? g.ordinal.slope / $ : 1, g.minPointOffset = k *= L, g.pointRangePadding = G *= L, g.pointRange = Math.min(Q, g.single && Y ? 1 : m), V && (g.closestPointRange = $);
}
g.translationSlope = g.transA = z = g.staticScale || g.len / (m + G || 1), g.transB = g.horiz ? g.left : g.bottom, g.minPixelPadding = z * k, c(this, "afterSetAxisTranslation");
}, X.prototype.minFromRange = function() {
return this.max - this.range;
}, X.prototype.setTickInterval = function(g) {
var m = this.chart, L = this.logarithmic, Y = this.options, V = this.isXAxis, Q = this.isLinked, k = Y.tickPixelInterval, G = this.categories, z = this.softThreshold, $ = Y.maxPadding, q = Y.minPadding, it = h(Y.tickInterval) && 0 <= Y.tickInterval ? Y.tickInterval : void 0, et = h(this.threshold) ? this.threshold : null;
this.dateTime || G || Q || this.getTickAmount();
var nt = A(this.userMin, Y.min), rt = A(this.userMax, Y.max);
if (Q) {
this.linkedParent = m[this.coll][Y.linkedTo];
var ct = this.linkedParent.getExtremes();
this.min = A(ct.min, ct.dataMin), this.max = A(ct.max, ct.dataMax), Y.type !== this.linkedParent.options.type && x(11, 1, m);
} else {
if (z && C(et)) {
if (this.dataMin >= et)
ct = et, q = 0;
else if (this.dataMax <= et) {
var gt = et;
$ = 0;
}
}
this.min = A(nt, ct, this.dataMin), this.max = A(rt, gt, this.dataMax);
}
if (L && (this.positiveValuesOnly && !g && 0 >= Math.min(this.min, A(this.dataMin, this.min)) && x(10, 1, m), this.min = B(L.log2lin(this.min), 16), this.max = B(L.log2lin(this.max), 16)), this.range && C(this.max) && (this.userMin = this.min = nt = Math.max(this.dataMin, this.minFromRange()), this.userMax = rt = this.max, this.range = null), c(this, "foundExtremes"), this.beforePadding && this.beforePadding(), this.adjustForMinRange(), !(G || this.axisPointRange || this.stacking && this.stacking.usePercentage || Q) && C(this.min) && C(this.max) && (m = this.max - this.min) && (!C(nt) && q && (this.min -= m * q), !C(rt) && $ && (this.max += m * $)), h(this.userMin) || (h(Y.softMin) && Y.softMin < this.min && (this.min = nt = Y.softMin), h(Y.floor) && (this.min = Math.max(this.min, Y.floor))), h(this.userMax) || (h(Y.softMax) && Y.softMax > this.max && (this.max = rt = Y.softMax), h(Y.ceiling) && (this.max = Math.min(this.max, Y.ceiling))), z && C(this.dataMin) && (et = et || 0, !C(nt) && this.min < et && this.dataMin >= et ? this.min = this.options.minRange ? Math.min(et, this.max - this.minRange) : et : !C(rt) && this.max > et && this.dataMax <= et && (this.max = this.options.minRange ? Math.max(et, this.min + this.minRange) : et)), h(this.min) && h(this.max) && !this.chart.polar && this.min > this.max && (C(this.options.min) ? this.max = this.min : C(this.options.max) && (this.min = this.max)), this.tickInterval = this.min === this.max || typeof this.min > "u" || typeof this.max > "u" ? 1 : Q && this.linkedParent && !it && k === this.linkedParent.options.tickPixelInterval ? it = this.linkedParent.tickInterval : A(it, this.tickAmount ? (this.max - this.min) / Math.max(this.tickAmount - 1, 1) : void 0, G ? 1 : (this.max - this.min) * k / Math.max(this.len, k)), V && !g) {
var dt = this.min !== (this.old && this.old.min) || this.max !== (this.old && this.old.max);
this.series.forEach(function(ht) {
ht.forceCrop = ht.forceCropping && ht.forceCropping(), ht.processData(dt);
}), c(this, "postProcessData", { hasExtemesChanged: dt });
}
this.setAxisTranslation(), c(this, "initialAxisTranslation"), this.pointRange && !it && (this.tickInterval = Math.max(this.pointRange, this.tickInterval)), g = A(Y.minTickInterval, this.dateTime && !this.series.some(function(ht) {
return ht.noSharedTooltip;
}) ? this.closestPointRange : 0), !it && this.tickInterval < g && (this.tickInterval = g), this.dateTime || this.logarithmic || it || (this.tickInterval = s(this.tickInterval, void 0, p(this.tickInterval), A(Y.allowDecimals, 0.5 > this.tickInterval || this.tickAmount !== void 0), !!this.tickAmount)), this.tickAmount || (this.tickInterval = this.unsquish()), this.setTickPositions();
}, X.prototype.setTickPositions = function() {
var g = this.options, m = g.tickPositions, L = this.getMinorTickInterval(), Y = this.hasVerticalPanning(), V = this.coll === "colorAxis", Q = (V || !Y) && g.startOnTick;
Y = (V || !Y) && g.endOnTick, V = g.tickPositioner, this.tickmarkOffset = this.categories && g.tickmarkPlacement === "between" && this.tickInterval === 1 ? 0.5 : 0, this.minorTickInterval = L === "auto" && this.tickInterval ? this.tickInterval / 5 : L, this.single = this.min === this.max && C(this.min) && !this.tickAmount && (parseInt(this.min, 10) === this.min || g.allowDecimals !== !1), this.tickPositions = L = m && m.slice(), !L && (this.ordinal && this.ordinal.positions || !((this.max - this.min) / this.tickInterval > Math.max(2 * this.len, 200)) ? L = this.dateTime ? this.getTimeTicks(this.dateTime.normalizeTimeTickInterval(this.tickInterval, g.units), this.min, this.max, g.startOfWeek, this.ordinal && this.ordinal.positions, this.closestPointRange, !0) : this.logarithmic ? this.logarithmic.getLogTickPositions(this.tickInterval, this.min, this.max) : this.getLinearTickPositions(
this.tickInterval,
this.min,
this.max
) : (L = [this.min, this.max], x(19, !1, this.chart)), L.length > this.len && (L = [L[0], L.pop()], L[0] === L[1] && (L.length = 1)), this.tickPositions = L, V && (V = V.apply(this, [this.min, this.max]))) && (this.tickPositions = L = V), this.paddedTicks = L.slice(0), this.trimTicks(L, Q, Y), this.isLinked || (this.single && 2 > L.length && !this.categories && !this.series.some(function(k) {
return k.is("heatmap") && k.options.pointPlacement === "between";
}) && (this.min -= 0.5, this.max += 0.5), m || V || this.adjustTickAmount()), c(this, "afterSetTickPositions");
}, X.prototype.trimTicks = function(g, m, L) {
var Y = g[0], V = g[g.length - 1], Q = !this.isOrdinal && this.minPointOffset || 0;
if (c(this, "trimTicks"), !this.isLinked) {
if (m && Y !== -1 / 0)
this.min = Y;
else
for (; this.min - Q > g[0]; )
g.shift();
if (L)
this.max = V;
else
for (; this.max + Q < g[g.length - 1]; )
g.pop();
g.length === 0 && C(Y) && !this.options.tickPositions && g.push((V + Y) / 2);
}
}, X.prototype.alignToOthers = function() {
var g = {}, m = this.options, L;
return this.chart.options.chart.alignTicks !== !1 && m.alignTicks && m.startOnTick !== !1 && m.endOnTick !== !1 && !this.logarithmic && this.chart[this.coll].forEach(function(Y) {
var V = Y.options;
V = [Y.horiz ? V.left : V.top, V.width, V.height, V.pane].join(), Y.series.length && (g[V] ? L = !0 : g[V] = 1);
}), L;
}, X.prototype.getTickAmount = function() {
var g = this.options, m = g.tickPixelInterval, L = g.tickAmount;
!C(g.tickInterval) && !L && this.len < m && !this.isRadial && !this.logarithmic && g.startOnTick && g.endOnTick && (L = 2), !L && this.alignToOthers() && (L = Math.ceil(this.len / m) + 1), 4 > L && (this.finalTickAmt = L, L = 5), this.tickAmount = L;
}, X.prototype.adjustTickAmount = function() {
var g = this.options, m = this.tickInterval, L = this.tickPositions, Y = this.tickAmount, V = this.finalTickAmt, Q = L && L.length, k = A(this.threshold, this.softThreshold ? 0 : null);
if (this.hasData() && h(this.min) && h(this.max)) {
if (Q < Y) {
for (; L.length < Y; )
L.length % 2 || this.min === k ? L.push(B(L[L.length - 1] + m)) : L.unshift(B(L[0] - m));
this.transA *= (Q - 1) / (Y - 1), this.min = g.startOnTick ? L[0] : Math.min(this.min, L[0]), this.max = g.endOnTick ? L[L.length - 1] : Math.max(this.max, L[L.length - 1]);
} else
Q > Y && (this.tickInterval *= 2, this.setTickPositions());
if (C(V)) {
for (m = g = L.length; m--; )
(V === 3 && m % 2 === 1 || 2 >= V && 0 < m && m < g - 1) && L.splice(m, 1);
this.finalTickAmt = void 0;
}
}
}, X.prototype.setScale = function() {
var g = !1, m = !1;
this.series.forEach(function(Y) {
g = g || Y.isDirtyData || Y.isDirty, m = m || Y.xAxis && Y.xAxis.isDirty || !1;
}), this.setAxisSize();
var L = this.len !== (this.old && this.old.len);
L || g || m || this.isLinked || this.forceRedraw || this.userMin !== (this.old && this.old.userMin) || this.userMax !== (this.old && this.old.userMax) || this.alignToOthers() ? (this.stacking && this.stacking.resetStacks(), this.forceRedraw = !1, this.getSeriesExtremes(), this.setTickInterval(), this.isDirty || (this.isDirty = L || this.min !== (this.old && this.old.min) || this.max !== (this.old && this.old.max))) : this.stacking && this.stacking.cleanStacks(), g && this.panningState && (this.panningState.isDirty = !0), c(this, "afterSetScale");
}, X.prototype.setExtremes = function(g, m, L, Y, V) {
var Q = this, k = Q.chart;
L = A(L, !0), Q.series.forEach(function(G) {
delete G.kdTree;
}), V = a(V, { min: g, max: m }), c(Q, "setExtremes", V, function() {
Q.userMin = g, Q.userMax = m, Q.eventArgs = V, L && k.redraw(Y);
});
}, X.prototype.zoom = function(g, m) {
var L = this, Y = this.dataMin, V = this.dataMax, Q = this.options, k = Math.min(Y, A(Q.min, Y)), G = Math.max(V, A(Q.max, V));
return g = { newMin: g, newMax: m }, c(this, "zoom", g, function(z) {
var $ = z.newMin, q = z.newMax;
($ !== L.min || q !== L.max) && (L.allowZoomOutside || (C(Y) && ($ < k && ($ = k), $ > G && ($ = G)), C(V) && (q < k && (q = k), q > G && (q = G))), L.displayBtn = typeof $ < "u" || typeof q < "u", L.setExtremes($, q, !1, void 0, { trigger: "zoom" })), z.zoomed = !0;
}), g.zoomed;
}, X.prototype.setAxisSize = function() {
var g = this.chart, m = this.options, L = m.offsets || [0, 0, 0, 0], Y = this.horiz, V = this.width = Math.round(_(A(m.width, g.plotWidth - L[3] + L[1]), g.plotWidth)), Q = this.height = Math.round(_(A(m.height, g.plotHeight - L[0] + L[2]), g.plotHeight)), k = this.top = Math.round(_(A(m.top, g.plotTop + L[0]), g.plotHeight, g.plotTop));
m = this.left = Math.round(_(A(m.left, g.plotLeft + L[3]), g.plotWidth, g.plotLeft)), this.bottom = g.chartHeight - Q - k, this.right = g.chartWidth - V - m, this.len = Math.max(Y ? V : Q, 0), this.pos = Y ? m : k;
}, X.prototype.getExtremes = function() {
var g = this.logarithmic;
return { min: g ? B(g.lin2log(this.min)) : this.min, max: g ? B(g.lin2log(this.max)) : this.max, dataMin: this.dataMin, dataMax: this.dataMax, userMin: this.userMin, userMax: this.userMax };
}, X.prototype.getThreshold = function(g) {
var m = this.logarithmic, L = m ? m.lin2log(this.min) : this.min;
return m = m ? m.lin2log(this.max) : this.max, g === null || g === -1 / 0 ? g = L : g === 1 / 0 ? g = m : L > g ? g = L : m < g && (g = m), this.translate(g, 0, 1, 0, 1);
}, X.prototype.autoLabelAlign = function(g) {
var m = (A(g, 0) - 90 * this.side + 720) % 360;
return g = { align: "center" }, c(
this,
"autoLabelAlign",
g,
function(L) {
15 < m && 165 > m ? L.align = "right" : 195 < m && 345 > m && (L.align = "left");
}
), g.align;
}, X.prototype.tickSize = function(g) {
var m = this.options, L = A(m[g === "tick" ? "tickWidth" : "minorTickWidth"], g === "tick" && this.isXAxis && !this.categories ? 1 : 0), Y = m[g === "tick" ? "tickLength" : "minorTickLength"];
if (L && Y) {
m[g + "Position"] === "inside" && (Y = -Y);
var V = [Y, L];
}
return g = { tickSize: V }, c(this, "afterTickSize", g), g.tickSize;
}, X.prototype.labelMetrics = function() {
var g = this.tickPositions && this.tickPositions[0] || 0;
return this.chart.renderer.fontMetrics(
this.options.labels.style.fontSize,
this.ticks[g] && this.ticks[g].label
);
}, X.prototype.unsquish = function() {
var g = this.options.labels, m = this.horiz, L = this.tickInterval, Y = this.len / (((this.categories ? 1 : 0) + this.max - this.min) / L), V = g.rotation, Q = this.labelMetrics(), k = Math.max(this.max - this.min, 0), G = function(nt) {
var rt = nt / (Y || 1);
return rt = 1 < rt ? Math.ceil(rt) : 1, rt * L > k && nt !== 1 / 0 && Y !== 1 / 0 && k && (rt = Math.ceil(k / L)), B(rt * L);
}, z = L, $, q, it = Number.MAX_VALUE;
if (m) {
if (!g.staggerLines && !g.step)
if (h(V))
var et = [V];
else
Y < g.autoRotationLimit && (et = g.autoRotation);
et && et.forEach(function(nt) {
if (nt === V || nt && -90 <= nt && 90 >= nt) {
q = G(Math.abs(Q.h / Math.sin(d * nt)));
var rt = q + Math.abs(nt / 360);
rt < it && (it = rt, $ = nt, z = q);
}
});
} else
g.step || (z = G(Q.h));
return this.autoRotation = et, this.labelRotation = A($, h(V) ? V : 0), z;
}, X.prototype.getSlotWidth = function(g) {
var m = this.chart, L = this.horiz, Y = this.options.labels, V = Math.max(this.tickPositions.length - (this.categories ? 0 : 1), 1), Q = m.margin[3];
if (g && h(g.slotWidth))
return g.slotWidth;
if (L && 2 > Y.step)
return Y.rotation ? 0 : (this.staggerLines || 1) * this.len / V;
if (!L) {
if (g = Y.style.width, g !== void 0)
return parseInt(String(g), 10);
if (Q)
return Q - m.spacing[3];
}
return 0.33 * m.chartWidth;
}, X.prototype.renderUnsquish = function() {
var g = this.chart, m = g.renderer, L = this.tickPositions, Y = this.ticks, V = this.options.labels, Q = V.style, k = this.horiz, G = this.getSlotWidth(), z = Math.max(1, Math.round(G - 2 * V.padding)), $ = {}, q = this.labelMetrics(), it = Q.textOverflow, et = 0;
if (o(V.rotation) || ($.rotation = V.rotation || 0), L.forEach(function(gt) {
gt = Y[gt], gt.movedLabel && gt.replaceMovedLabel(), gt && gt.label && gt.label.textPxLength > et && (et = gt.label.textPxLength);
}), this.maxLabelLength = et, this.autoRotation)
et > z && et > q.h ? $.rotation = this.labelRotation : this.labelRotation = 0;
else if (G) {
var nt = z;
if (!it) {
var rt = "clip";
for (z = L.length; !k && z--; ) {
var ct = L[z];
(ct = Y[ct].label) && (ct.styles && ct.styles.textOverflow === "ellipsis" ? ct.css({ textOverflow: "clip" }) : ct.textPxLength > G && ct.css({ width: G + "px" }), ct.getBBox().height > this.len / L.length - (q.h - q.f) && (ct.specificTextOverflow = "ellipsis"));
}
}
}
$.rotation && (nt = et > 0.5 * g.chartHeight ? 0.33 * g.chartHeight : et, it || (rt = "ellipsis")), (this.labelAlign = V.align || this.autoLabelAlign(this.labelRotation)) && ($.align = this.labelAlign), L.forEach(function(gt) {
var dt = (gt = Y[gt]) && gt.label, ht = Q.width, at = {};
dt && (dt.attr($), gt.shortenLabel ? gt.shortenLabel() : nt && !ht && Q.whiteSpace !== "nowrap" && (nt < dt.textPxLength || dt.element.tagName === "SPAN") ? (at.width = nt + "px", it || (at.textOverflow = dt.specificTextOverflow || rt), dt.css(at)) : dt.styles && dt.styles.width && !at.width && !ht && dt.css({ width: null }), delete dt.specificTextOverflow, gt.rotation = $.rotation);
}, this), this.tickRotCorr = m.rotCorr(q.b, this.labelRotation || 0, this.side !== 0);
}, X.prototype.hasData = function() {
return this.series.some(function(g) {
return g.hasData();
}) || this.options.showEmpty && C(this.min) && C(this.max);
}, X.prototype.addTitle = function(g) {
var m = this.chart.renderer, L = this.horiz, Y = this.opposite, V = this.options.title, Q = this.chart.styledMode, k;
this.axisTitle || ((k = V.textAlign) || (k = (L ? { low: "left", middle: "center", high: "right" } : { low: Y ? "right" : "left", middle: "center", high: Y ? "left" : "right" })[V.align]), this.axisTitle = m.text(V.text || "", 0, 0, V.useHTML).attr({ zIndex: 7, rotation: V.rotation, align: k }).addClass("highcharts-axis-title"), Q || this.axisTitle.css(t(V.style)), this.axisTitle.add(this.axisGroup), this.axisTitle.isNew = !0), Q || V.style.width || this.isRadial || this.axisTitle.css({ width: this.len + "px" }), this.axisTitle[g ? "show" : "hide"](g);
}, X.prototype.generateTick = function(g) {
var m = this.ticks;
m[g] ? m[g].addLabel() : m[g] = new F(this, g);
}, X.prototype.getOffset = function() {
var g = this, m = this, L = m.chart, Y = m.horiz, V = m.options, Q = m.side, k = m.ticks, G = m.tickPositions, z = m.coll, $ = m.axisParent, q = L.renderer, it = L.inverted && !m.isZAxis ? [1, 0, 3, 2][Q] : Q, et = m.hasData(), nt = V.title, rt = V.labels, ct = L.axisOffset;
L = L.clipOffset;
var gt = [
-1,
1,
1,
-1
][Q], dt = V.className, ht, at = 0, J = 0, tt = 0;
if (m.showAxis = ht = et || V.showEmpty, m.staggerLines = m.horiz && rt.staggerLines || void 0, !m.axisGroup) {
var ot = function(pt, yt, vt) {
return q.g(pt).attr({ zIndex: vt }).addClass("highcharts-" + z.toLowerCase() + yt + " " + (g.isRadial ? "highcharts-radial-axis" + yt + " " : "") + (dt || "")).add($);
};
m.gridGroup = ot("grid", "-grid", V.gridZIndex), m.axisGroup = ot("axis", "", V.zIndex), m.labelGroup = ot("axis-labels", "-labels", rt.zIndex);
}
if (et || m.isLinked ? (G.forEach(function(pt) {
m.generateTick(pt);
}), m.renderUnsquish(), m.reserveSpaceDefault = Q === 0 || Q === 2 || { 1: "left", 3: "right" }[Q] === m.labelAlign, A(rt.reserveSpace, m.labelAlign === "center" ? !0 : null, m.reserveSpaceDefault) && G.forEach(function(pt) {
tt = Math.max(k[pt].getLabelSize(), tt);
}), m.staggerLines && (tt *= m.staggerLines), m.labelOffset = tt * (m.opposite ? -1 : 1)) : n(k, function(pt, yt) {
pt.destroy(), delete k[yt];
}), nt && nt.text && nt.enabled !== !1 && (m.addTitle(ht), ht && nt.reserveSpace !== !1)) {
m.titleOffset = at = m.axisTitle.getBBox()[Y ? "height" : "width"];
var lt = nt.offset;
J = C(lt) ? 0 : A(nt.margin, Y ? 5 : 10);
}
m.renderLine(), m.offset = gt * A(
V.offset,
ct[Q] ? ct[Q] + (V.margin || 0) : 0
), m.tickRotCorr = m.tickRotCorr || { x: 0, y: 0 }, nt = Q === 0 ? -m.labelMetrics().h : Q === 2 ? m.tickRotCorr.y : 0, et = Math.abs(tt) + J, tt && (et = et - nt + gt * (Y ? A(rt.y, m.tickRotCorr.y + 8 * gt) : rt.x)), m.axisTitleMargin = A(lt, et), m.getMaxLabelDimensions && (m.maxLabelDimensions = m.getMaxLabelDimensions(k, G)), z !== "colorAxis" && (Y = this.tickSize("tick"), ct[Q] = Math.max(ct[Q], (m.axisTitleMargin || 0) + at + gt * m.offset, et, G && G.length && Y ? Y[0] + gt * m.offset : 0), V = !m.axisLine || V.offset ? 0 : 2 * Math.floor(m.axisLine.strokeWidth() / 2), L[it] = Math.max(
L[it],
V
)), c(this, "afterGetOffset");
}, X.prototype.getLinePath = function(g) {
var m = this.chart, L = this.opposite, Y = this.offset, V = this.horiz, Q = this.left + (L ? this.width : 0) + Y;
return Y = m.chartHeight - this.bottom - (L ? this.height : 0) + Y, L && (g *= -1), m.renderer.crispLine([["M", V ? this.left : Q, V ? Y : this.top], ["L", V ? m.chartWidth - this.right : Q, V ? Y : m.chartHeight - this.bottom]], g);
}, X.prototype.renderLine = function() {
this.axisLine || (this.axisLine = this.chart.renderer.path().addClass("highcharts-axis-line").add(this.axisGroup), this.chart.styledMode || this.axisLine.attr({ stroke: this.options.lineColor, "stroke-width": this.options.lineWidth, zIndex: 7 }));
}, X.prototype.getTitlePosition = function() {
var g = this.horiz, m = this.left, L = this.top, Y = this.len, V = this.options.title, Q = g ? m : L, k = this.opposite, G = this.offset, z = V.x, $ = V.y, q = this.axisTitle, it = this.chart.renderer.fontMetrics(V.style.fontSize, q);
return q = Math.max(q.getBBox(null, 0).height - it.h - 1, 0), Y = { low: Q + (g ? 0 : Y), middle: Q + Y / 2, high: Q + (g ? Y : 0) }[V.align], m = (g ? L + this.height : m) + (g ? 1 : -1) * (k ? -1 : 1) * this.axisTitleMargin + [
-q,
q,
it.f,
-q
][this.side], g = { x: g ? Y + z : m + (k ? this.width : 0) + G + z, y: g ? m + $ - (k ? this.height : 0) + G : Y + $ }, c(this, "afterGetTitlePosition", { titlePosition: g }), g;
}, X.prototype.renderMinorTick = function(g, m) {
var L = this.minorTicks;
L[g] || (L[g] = new F(this, g, "minor")), m && L[g].isNew && L[g].render(null, !0), L[g].render(null, !1, 1);
}, X.prototype.renderTick = function(g, m, L) {
var Y = this.ticks;
(!this.isLinked || g >= this.min && g <= this.max || this.grid && this.grid.isColumn) && (Y[g] || (Y[g] = new F(this, g)), L && Y[g].isNew && Y[g].render(m, !0, -1), Y[g].render(m));
}, X.prototype.render = function() {
var g = this, m = g.chart, L = g.logarithmic, Y = g.options, V = g.isLinked, Q = g.tickPositions, k = g.axisTitle, G = g.ticks, z = g.minorTicks, $ = g.alternateBands, q = Y.stackLabels, it = Y.alternateGridColor, et = g.tickmarkOffset, nt = g.axisLine, rt = g.showAxis, ct = R(m.renderer.globalAnimation), gt, dt;
if (g.labelEdge.length = 0, g.overlap = !1, [G, z, $].forEach(function(at) {
n(at, function(J) {
J.isActive = !1;
});
}), g.hasData() || V) {
var ht = g.chart.hasRendered && g.old && h(g.old.min);
g.minorTickInterval && !g.categories && g.getMinorTickPositions().forEach(function(at) {
g.renderMinorTick(
at,
ht
);
}), Q.length && (Q.forEach(function(at, J) {
g.renderTick(at, J, ht);
}), et && (g.min === 0 || g.single) && (G[-1] || (G[-1] = new F(g, -1, null, !0)), G[-1].render(-1))), it && Q.forEach(function(at, J) {
dt = typeof Q[J + 1] < "u" ? Q[J + 1] + et : g.max - et, J % 2 === 0 && at < g.max && dt <= g.max + (m.polar ? -et : et) && ($[at] || ($[at] = new U.PlotLineOrBand(g)), gt = at + et, $[at].options = { from: L ? L.lin2log(gt) : gt, to: L ? L.lin2log(dt) : dt, color: it, className: "highcharts-alternate-grid" }, $[at].render(), $[at].isActive = !0);
}), g._addedPlotLB || (g._addedPlotLB = !0, (Y.plotLines || []).concat(Y.plotBands || []).forEach(function(at) {
g.addPlotBandOrLine(at);
}));
}
[G, z, $].forEach(function(at) {
var J = [], tt = ct.duration;
n(at, function(ot, lt) {
ot.isActive || (ot.render(lt, !1, 0), ot.isActive = !1, J.push(lt));
}), P(function() {
for (var ot = J.length; ot--; )
at[J[ot]] && !at[J[ot]].isActive && (at[J[ot]].destroy(), delete at[J[ot]]);
}, at !== $ && m.hasRendered && tt ? tt : 0);
}), nt && (nt[nt.isPlaced ? "animate" : "attr"]({ d: this.getLinePath(nt.strokeWidth()) }), nt.isPlaced = !0, nt[rt ? "show" : "hide"](rt)), k && rt && (Y = g.getTitlePosition(), h(Y.y) ? (k[k.isNew ? "attr" : "animate"](Y), k.isNew = !1) : (k.attr(
"y",
-9999
), k.isNew = !0)), q && q.enabled && g.stacking && g.stacking.renderStackTotals(), g.old = { len: g.len, max: g.max, min: g.min, transA: g.transA, userMax: g.userMax, userMin: g.userMin }, g.isDirty = !1, c(this, "afterRender");
}, X.prototype.redraw = function() {
this.visible && (this.render(), this.plotLinesAndBands.forEach(function(g) {
g.render();
})), this.series.forEach(function(g) {
g.isDirty = !0;
});
}, X.prototype.getKeepProps = function() {
return this.keepProps || X.keepProps;
}, X.prototype.destroy = function(g) {
var m = this, L = m.plotLinesAndBands, Y = this.eventOptions;
if (c(this, "destroy", { keepEvents: g }), g || D(m), [m.ticks, m.minorTicks, m.alternateBands].forEach(function(Q) {
b(Q);
}), L)
for (g = L.length; g--; )
L[g].destroy();
"axisLine axisTitle axisGroup gridGroup labelGroup cross scrollbar".split(" ").forEach(function(Q) {
m[Q] && (m[Q] = m[Q].destroy());
});
for (var V in m.plotLinesAndBandsGroups)
m.plotLinesAndBandsGroups[V] = m.plotLinesAndBandsGroups[V].destroy();
n(m, function(Q, k) {
m.getKeepProps().indexOf(k) === -1 && delete m[k];
}), this.eventOptions = Y;
}, X.prototype.drawCrosshair = function(g, m) {
var L = this.crosshair, Y = A(L && L.snap, !0), V = this.chart, Q, k = this.cross;
if (c(this, "drawCrosshair", { e: g, point: m }), g || (g = this.cross && this.cross.e), L && (C(m) || !Y) !== !1) {
if (Y ? C(m) && (Q = A(this.coll !== "colorAxis" ? m.crosshairPos : null, this.isXAxis ? m.plotX : this.len - m.plotY)) : Q = g && (this.horiz ? g.chartX - this.pos : this.len - g.chartY + this.pos), C(Q)) {
var G = { value: m && (this.isXAxis ? m.x : A(m.stackY, m.y)), translatedValue: Q };
V.polar && a(G, { isCrosshair: !0, chartX: g && g.chartX, chartY: g && g.chartY, point: m }), G = this.getPlotLinePath(G) || null;
}
if (!C(G)) {
this.hideCrosshair();
return;
}
Y = this.categories && !this.isRadial, k || (this.cross = k = V.renderer.path().addClass("highcharts-crosshair highcharts-crosshair-" + (Y ? "category " : "thin ") + (L.className || "")).attr({ zIndex: A(L.zIndex, 2) }).add(), V.styledMode || (k.attr({ stroke: L.color || (Y ? I.parse("#ccd6eb").setOpacity(0.25).get() : "#cccccc"), "stroke-width": A(L.width, 1) }).css({ "pointer-events": "none" }), L.dashStyle && k.attr({ dashstyle: L.dashStyle }))), k.show().attr({ d: G }), Y && !L.width && k.attr({ "stroke-width": this.transA }), this.cross.e = g;
} else
this.hideCrosshair();
c(this, "afterDrawCrosshair", { e: g, point: m });
}, X.prototype.hideCrosshair = function() {
this.cross && this.cross.hide(), c(this, "afterHideCrosshair");
}, X.prototype.hasVerticalPanning = function() {
var g = this.chart.options.chart.panning;
return !!(g && g.enabled && /y/.test(g.type));
}, X.prototype.validatePositiveValue = function(g) {
return h(g) && 0 < g;
}, X.prototype.update = function(g, m) {
var L = this.chart;
g = t(this.userOptions, g), this.destroy(!0), this.init(L, g), L.isDirtyBox = !0, A(m, !0) && L.redraw();
}, X.prototype.remove = function(g) {
for (var m = this.chart, L = this.coll, Y = this.series, V = Y.length; V--; )
Y[V] && Y[V].remove(!1);
w(m.axes, this), w(m[L], this), m[L].forEach(function(Q, k) {
Q.options.index = Q.userOptions.index = k;
}), this.destroy(), m.isDirtyBox = !0, A(g, !0) && m.redraw();
}, X.prototype.setTitle = function(g, m) {
this.update({ title: g }, m);
}, X.prototype.setCategories = function(g, m) {
this.update({ categories: g }, m);
}, X.defaultOptions = j.defaultXAxisOptions, X.keepProps = "extKey hcEvents names series userMax userMin".split(" "), X;
}(), y;
}), E(l, "Core/Axis/DateTimeAxis.js", [l["Core/Utilities.js"]], function(y) {
var j = y.addEvent, I = y.getMagnitude, Z = y.normalizeTickInterval, H = y.timeUnits, U;
return function(F) {
function N() {
return this.chart.time.getTimeTicks.apply(this.chart.time, arguments);
}
function R(d) {
d.userOptions.type !== "datetime" ? this.dateTime = void 0 : this.dateTime || (this.dateTime = new v(this));
}
var S = [];
F.compose = function(d) {
return S.indexOf(d) === -1 && (S.push(d), d.keepProps.push("dateTime"), d.prototype.getTimeTicks = N, j(
d,
"init",
R
)), d;
};
var v = function() {
function d(u) {
this.axis = u;
}
return d.prototype.normalizeTimeTickInterval = function(u, T) {
var O = T || [["millisecond", [1, 2, 5, 10, 20, 25, 50, 100, 200, 500]], ["second", [1, 2, 5, 10, 15, 30]], ["minute", [1, 2, 5, 10, 15, 30]], ["hour", [1, 2, 3, 4, 6, 8, 12]], ["day", [1, 2]], ["week", [1, 2]], ["month", [1, 2, 3, 4, 6]], ["year", null]];
T = O[O.length - 1];
var B = H[T[0]], C = T[1], b;
for (b = 0; b < O.length && (T = O[b], B = H[T[0]], C = T[1], !(O[b + 1] && u <= (B * C[C.length - 1] + H[O[b + 1][0]]) / 2)); b++)
;
return B === H.year && u < 5 * B && (C = [1, 2, 5]), u = Z(u / B, C, T[0] === "year" ? Math.max(I(u / B), 1) : 1), { unitRange: B, count: u, unitName: T[0] };
}, d.prototype.getXDateFormat = function(u, T) {
var O = this.axis;
return O.closestPointRange ? O.chart.time.getDateFormat(O.closestPointRange, u, O.options.startOfWeek, T) || T.year : T.day;
}, d;
}();
F.Additions = v;
}(U || (U = {})), U;
}), E(l, "Core/Axis/LogarithmicAxis.js", [l["Core/Utilities.js"]], function(y) {
var j = y.addEvent, I = y.getMagnitude, Z = y.normalizeTickInterval, H = y.pick, U;
return function(F) {
function N(d) {
var u = this.logarithmic;
d.userOptions.type !== "logarithmic" ? this.logarithmic = void 0 : u || (this.logarithmic = new v(this));
}
function R() {
var d = this.logarithmic;
d && (this.lin2val = function(u) {
return d.lin2log(u);
}, this.val2lin = function(u) {
return d.log2lin(u);
});
}
var S = [];
F.compose = function(d) {
return S.indexOf(d) === -1 && (S.push(d), d.keepProps.push("logarithmic"), j(d, "init", N), j(d, "afterInit", R)), d;
};
var v = function() {
function d(u) {
this.axis = u;
}
return d.prototype.getLogTickPositions = function(u, T, O, B) {
var C = this.axis, b = C.len, w = C.options, x = [];
if (B || (this.minorAutoInterval = void 0), 0.5 <= u)
u = Math.round(u), x = C.getLinearTickPositions(u, T, O);
else if (0.08 <= u) {
var a = Math.floor(T), c, p = w = void 0;
for (b = 0.3 < u ? [1, 2, 4] : 0.15 < u ? [1, 2, 4, 6, 8] : [1, 2, 3, 4, 5, 6, 7, 8, 9]; a < O + 1 && !p; a++) {
var i = b.length;
for (c = 0; c < i && !p; c++) {
var h = this.log2lin(this.lin2log(a) * b[c]);
h > T && (!B || w <= O) && typeof w < "u" && x.push(w), w > O && (p = !0), w = h;
}
}
} else
T = this.lin2log(T), O = this.lin2log(O), u = B ? C.getMinorTickInterval() : w.tickInterval, u = H(u === "auto" ? null : u, this.minorAutoInterval, w.tickPixelInterval / (B ? 5 : 1) * (O - T) / ((B ? b / C.tickPositions.length : b) || 1)), u = Z(u, void 0, I(u)), x = C.getLinearTickPositions(u, T, O).map(this.log2lin), B || (this.minorAutoInterval = u / 5);
return B || (C.tickInterval = u), x;
}, d.prototype.lin2log = function(u) {
return Math.pow(10, u);
}, d.prototype.log2lin = function(u) {
return Math.log(u) / Math.LN10;
}, d;
}();
F.Additions = v;
}(U || (U = {})), U;
}), E(l, "Core/Axis/PlotLineOrBand/PlotLineOrBandAxis.js", [l["Core/Utilities.js"]], function(y) {
var j = y.erase, I = y.extend, Z = y.isNumber, H;
return function(U) {
var F = [], N;
U.compose = function(S, v) {
return N || (N = S), F.indexOf(v) === -1 && (F.push(v), I(v.prototype, R.prototype)), v;
};
var R = function() {
function S() {
}
return S.prototype.getPlotBandPath = function(v, d, u) {
u === void 0 && (u = this.options);
var T = this.getPlotLinePath({ value: d, force: !0, acrossPanes: u.acrossPanes }), O = [], B = this.horiz;
if (d = !Z(this.min) || !Z(this.max) || v < this.min && d < this.min || v > this.max && d > this.max, v = this.getPlotLinePath({ value: v, force: !0, acrossPanes: u.acrossPanes }), u = 1, v && T) {
if (d) {
var C = v.toString() === T.toString();
u = 0;
}
for (d = 0; d < v.length; d += 2) {
var b = v[d], w = v[d + 1], x = T[d], a = T[d + 1];
b[0] !== "M" && b[0] !== "L" || w[0] !== "M" && w[0] !== "L" || x[0] !== "M" && x[0] !== "L" || a[0] !== "M" && a[0] !== "L" || (B && x[1] === b[1] ? (x[1] += u, a[1] += u) : B || x[2] !== b[2] || (x[2] += u, a[2] += u), O.push(["M", b[1], b[2]], ["L", w[1], w[2]], ["L", a[1], a[2]], ["L", x[1], x[2]], ["Z"])), O.isFlat = C;
}
}
return O;
}, S.prototype.addPlotBand = function(v) {
return this.addPlotBandOrLine(v, "plotBands");
}, S.prototype.addPlotLine = function(v) {
return this.addPlotBandOrLine(v, "plotLines");
}, S.prototype.addPlotBandOrLine = function(v, d) {
var u = this, T = this.userOptions, O = new N(this, v);
if (this.visible && (O = O.render()), O) {
if (this._addedPlotLB || (this._addedPlotLB = !0, (T.plotLines || []).concat(T.plotBands || []).forEach(function(C) {
u.addPlotBandOrLine(C);
})), d) {
var B = T[d] || [];
B.push(v), T[d] = B;
}
this.plotLinesAndBands.push(O);
}
return O;
}, S.prototype.removePlotBandOrLine = function(v) {
var d = this.plotLinesAndBands, u = this.options, T = this.userOptions;
if (d) {
for (var O = d.length; O--; )
d[O].id === v && d[O].destroy();
[u.plotLines || [], T.plotLines || [], u.plotBands || [], T.plotBands || []].forEach(function(B) {
for (O = B.length; O--; )
(B[O] || {}).id === v && j(B, B[O]);
});
}
}, S.prototype.removePlotBand = function(v) {
this.removePlotBandOrLine(v);
}, S.prototype.removePlotLine = function(v) {
this.removePlotBandOrLine(v);
}, S;
}();
}(H || (H = {})), H;
}), E(l, "Core/Axis/PlotLineOrBand/PlotLineOrBand.js", [l["Core/Axis/PlotLineOrBand/PlotLineOrBandAxis.js"], l["Core/Utilities.js"]], function(y, j) {
var I = j.arrayMax, Z = j.arrayMin, H = j.defined, U = j.destroyObjectProperties, F = j.erase, N = j.fireEvent, R = j.merge, S = j.objectEach, v = j.pick;
return j = function() {
function d(u, T) {
this.axis = u, T && (this.options = T, this.id = T.id);
}
return d.compose = function(u) {
return y.compose(d, u);
}, d.prototype.render = function() {
N(this, "render");
var u = this, T = u.axis, O = T.horiz, B = T.logarithmic, C = u.options, b = C.color, w = v(C.zIndex, 0), x = C.events, a = {}, c = T.chart.renderer, p = C.label, i = u.label, h = C.to, o = C.from, t = C.value, s = u.svgElem, n = [], A = H(o) && H(h);
n = H(t);
var _ = !s, D = { class: "highcharts-plot-" + (A ? "band " : "line ") + (C.className || "") }, W = A ? "bands" : "lines";
if (B && (o = B.log2lin(o), h = B.log2lin(h), t = B.log2lin(t)), T.chart.styledMode || (n ? (D.stroke = b || "#999999", D["stroke-width"] = v(C.width, 1), C.dashStyle && (D.dashstyle = C.dashStyle)) : A && (D.fill = b || "#e6ebf5", C.borderWidth && (D.stroke = C.borderColor, D["stroke-width"] = C.borderWidth))), a.zIndex = w, W += "-" + w, (B = T.plotLinesAndBandsGroups[W]) || (T.plotLinesAndBandsGroups[W] = B = c.g("plot-" + W).attr(a).add()), _ && (u.svgElem = s = c.path().attr(D).add(B)), n)
n = T.getPlotLinePath({ value: t, lineWidth: s.strokeWidth(), acrossPanes: C.acrossPanes });
else if (A)
n = T.getPlotBandPath(
o,
h,
C
);
else
return;
return !u.eventsAdded && x && (S(x, function(P, X) {
s.on(X, function(g) {
x[X].apply(u, [g]);
});
}), u.eventsAdded = !0), (_ || !s.d) && n && n.length ? s.attr({ d: n }) : s && (n ? (s.show(!0), s.animate({ d: n })) : s.d && (s.hide(), i && (u.label = i = i.destroy()))), p && (H(p.text) || H(p.formatter)) && n && n.length && 0 < T.width && 0 < T.height && !n.isFlat ? (p = R({ align: O && A && "center", x: O ? !A && 4 : 10, verticalAlign: !O && A && "middle", y: O ? A ? 16 : 10 : A ? 6 : -4, rotation: O && !A && 90 }, p), this.renderLabel(p, n, A, w)) : i && i.hide(), u;
}, d.prototype.renderLabel = function(u, T, O, B) {
var C = this.axis, b = C.chart.renderer, w = this.label;
w || (this.label = w = b.text(this.getLabelText(u), 0, 0, u.useHTML).attr({ align: u.textAlign || u.align, rotation: u.rotation, class: "highcharts-plot-" + (O ? "band" : "line") + "-label " + (u.className || ""), zIndex: B }).add(), C.chart.styledMode || w.css(R({ textOverflow: "ellipsis" }, u.style))), B = T.xBounds || [T[0][1], T[1][1], O ? T[2][1] : T[0][1]], T = T.yBounds || [T[0][2], T[1][2], O ? T[2][2] : T[0][2]], O = Z(B), b = Z(T), w.align(u, !1, { x: O, y: b, width: I(B) - O, height: I(T) - b }), w.alignValue && w.alignValue !== "left" || w.css({ width: (w.rotation === 90 ? C.height - (w.alignAttr.y - C.top) : C.width - (w.alignAttr.x - C.left)) + "px" }), w.show(!0);
}, d.prototype.getLabelText = function(u) {
return H(u.formatter) ? u.formatter.call(this) : u.text;
}, d.prototype.destroy = function() {
F(this.axis.plotLinesAndBands, this), delete this.axis, U(this);
}, d;
}(), j;
}), E(
l,
"Core/Tooltip.js",
[l["Core/FormatUtilities.js"], l["Core/Globals.js"], l["Core/Renderer/RendererUtilities.js"], l["Core/Renderer/RendererRegistry.js"], l["Core/Utilities.js"]],
function(y, j, I, Z, H) {
var U = y.format, F = j.doc, N = I.distribute, R = H.addEvent, S = H.clamp, v = H.css, d = H.defined, u = H.discardElement, T = H.extend, O = H.fireEvent, B = H.isArray, C = H.isNumber, b = H.isString, w = H.merge, x = H.pick, a = H.splat, c = H.syncTimeout;
return y = function() {
function p(i, h) {
this.allowShared = !0, this.container = void 0, this.crosshairs = [], this.distance = 0, this.isHidden = !0, this.isSticky = !1, this.now = {}, this.options = {}, this.outside = !1, this.chart = i, this.init(i, h);
}
return p.prototype.applyFilter = function() {
var i = this.chart;
i.renderer.definition({
tagName: "filter",
attributes: { id: "drop-shadow-" + i.index, opacity: 0.5 },
children: [{ tagName: "feGaussianBlur", attributes: { in: "SourceAlpha", stdDeviation: 1 } }, { tagName: "feOffset", attributes: { dx: 1, dy: 1 } }, { tagName: "feComponentTransfer", children: [{ tagName: "feFuncA", attributes: { type: "linear", slope: 0.3 } }] }, { tagName: "feMerge", children: [{ tagName: "feMergeNode" }, { tagName: "feMergeNode", attributes: { in: "SourceGraphic" } }] }]
});
}, p.prototype.bodyFormatter = function(i) {
return i.map(function(h) {
var o = h.series.tooltipOptions;
return (o[(h.point.formatPrefix || "point") + "Formatter"] || h.point.tooltipFormatter).call(h.point, o[(h.point.formatPrefix || "point") + "Format"] || "");
});
}, p.prototype.cleanSplit = function(i) {
this.chart.series.forEach(function(h) {
var o = h && h.tt;
o && (!o.isActive || i ? h.tt = o.destroy() : o.isActive = !1);
});
}, p.prototype.defaultFormatter = function(i) {
var h = this.points || a(this), o = [i.tooltipFooterHeaderFormatter(h[0])];
return o = o.concat(i.bodyFormatter(h)), o.push(i.tooltipFooterHeaderFormatter(h[0], !0)), o;
}, p.prototype.destroy = function() {
this.label && (this.label = this.label.destroy()), this.split && this.tt && (this.cleanSplit(!0), this.tt = this.tt.destroy()), this.renderer && (this.renderer = this.renderer.destroy(), u(this.container)), H.clearTimeout(this.hideTimer), H.clearTimeout(this.tooltipTimeout);
}, p.prototype.getAnchor = function(i, h) {
var o = this.chart, t = o.pointer, s = o.inverted, n = o.plotTop, A = o.plotLeft, _, D, W = 0, P = 0;
return i = a(i), this.followPointer && h ? (typeof h.chartX > "u" && (h = t.normalize(h)), t = [h.chartX - A, h.chartY - n]) : i[0].tooltipPos ? t = i[0].tooltipPos : (i.forEach(function(X) {
_ = X.series.yAxis, D = X.series.xAxis, W += X.plotX || 0, P += X.plotLow ? (X.plotLow + (X.plotHigh || 0)) / 2 : X.plotY || 0, D && _ && (s ? (W += n + o.plotHeight - D.len - D.pos, P += A + o.plotWidth - _.len - _.pos) : (W += D.pos - A, P += _.pos - n));
}), W /= i.length, P /= i.length, t = [s ? o.plotWidth - P : W, s ? o.plotHeight - W : P], this.shared && 1 < i.length && h && (s ? t[0] = h.chartX - A : t[1] = h.chartY - n)), t.map(Math.round);
}, p.prototype.getLabel = function() {
var i = this, h = this.chart.styledMode, o = this.options, t = this.split && this.allowShared, s = "tooltip" + (d(o.className) ? " " + o.className : ""), n = o.style.pointerEvents || (!this.followPointer && o.stickOnContact ? "auto" : "none"), A = function() {
i.inContact = !0;
}, _ = function(Y) {
var V = i.chart.hoverSeries;
i.inContact = i.shouldStickOnContact() && i.chart.pointer.inClass(Y.relatedTarget, "highcharts-tooltip"), !i.inContact && V && V.onMouseOut && V.onMouseOut();
}, D, W = this.chart.renderer;
if (i.label) {
var P = !i.label.hasClass("highcharts-label");
(t && !P || !t && P) && i.destroy();
}
if (!this.label) {
if (this.outside) {
P = this.chart.options.chart.style;
var X = Z.getRendererType();
this.container = D = j.doc.createElement("div"), D.className = "highcharts-tooltip-container", v(D, { position: "absolute", top: "1px", pointerEvents: n, zIndex: Math.max(this.options.style.zIndex || 0, (P && P.zIndex || 0) + 3) }), R(D, "mouseenter", A), R(D, "mouseleave", _), j.doc.body.appendChild(D), this.renderer = W = new X(D, 0, 0, P, void 0, void 0, W.styledMode);
}
if (t ? this.label = W.g(s) : (this.label = W.label("", 0, 0, o.shape, void 0, void 0, o.useHTML, void 0, s).attr({ padding: o.padding, r: o.borderRadius }), h || this.label.attr({
fill: o.backgroundColor,
"stroke-width": o.borderWidth
}).css(o.style).css({ pointerEvents: n }).shadow(o.shadow)), h && o.shadow && (this.applyFilter(), this.label.attr({ filter: "url(#drop-shadow-" + this.chart.index + ")" })), i.outside && !i.split) {
var g = this.label, m = g.xSetter, L = g.ySetter;
g.xSetter = function(Y) {
m.call(g, i.distance), D.style.left = Y + "px";
}, g.ySetter = function(Y) {
L.call(g, i.distance), D.style.top = Y + "px";
};
}
this.label.on("mouseenter", A).on("mouseleave", _).attr({ zIndex: 8 }).add();
}
return this.label;
}, p.prototype.getPosition = function(i, h, o) {
var t = this.chart, s = this.distance, n = {}, A = t.inverted && o.h || 0, _ = this.outside, D = _ ? F.documentElement.clientWidth - 2 * s : t.chartWidth, W = _ ? Math.max(F.body.scrollHeight, F.documentElement.scrollHeight, F.body.offsetHeight, F.documentElement.offsetHeight, F.documentElement.clientHeight) : t.chartHeight, P = t.pointer.getChartPosition(), X = function(z) {
var $ = z === "x";
return [z, $ ? D : W, $ ? i : h].concat(_ ? [$ ? i * P.scaleX : h * P.scaleY, $ ? P.left - s + (o.plotX + t.plotLeft) * P.scaleX : P.top - s + (o.plotY + t.plotTop) * P.scaleY, 0, $ ? D : W] : [$ ? i : h, $ ? o.plotX + t.plotLeft : o.plotY + t.plotTop, $ ? t.plotLeft : t.plotTop, $ ? t.plotLeft + t.plotWidth : t.plotTop + t.plotHeight]);
}, g = X("y"), m = X("x"), L;
X = !!o.negative, !t.polar && t.hoverSeries && t.hoverSeries.yAxis && t.hoverSeries.yAxis.reversed && (X = !X);
var Y = !this.followPointer && x(o.ttBelow, !t.inverted === X), V = function(z, $, q, it, et, nt, rt) {
var ct = _ ? z === "y" ? s * P.scaleY : s * P.scaleX : s, gt = (q - it) / 2, dt = it < et - s, ht = et + s + it < $, at = et - ct - q + gt;
if (et = et + ct - gt, Y && ht)
n[z] = et;
else if (!Y && dt)
n[z] = at;
else if (dt)
n[z] = Math.min(rt - it, 0 > at - A ? at : at - A);
else if (ht)
n[z] = Math.max(nt, et + A + q > $ ? et : et + A);
else
return !1;
}, Q = function(z, $, q, it, et) {
var nt;
return et < s || et > $ - s ? nt = !1 : n[z] = et < q / 2 ? 1 : et > $ - it / 2 ? $ - it - 2 : et - q / 2, nt;
}, k = function(z) {
var $ = g;
g = m, m = $, L = z;
}, G = function() {
V.apply(0, g) !== !1 ? Q.apply(0, m) !== !1 || L || (k(!0), G()) : L ? n.x = n.y = 0 : (k(!0), G());
};
return (t.inverted || 1 < this.len) && k(), G(), n;
}, p.prototype.hide = function(i) {
var h = this;
H.clearTimeout(this.hideTimer), i = x(i, this.options.hideDelay), this.isHidden || (this.hideTimer = c(function() {
h.getLabel().fadeOut(i && void 0), h.isHidden = !0;
}, i));
}, p.prototype.init = function(i, h) {
this.chart = i, this.options = h, this.crosshairs = [], this.now = { x: 0, y: 0 }, this.isHidden = !0, this.split = h.split && !i.inverted && !i.polar, this.shared = h.shared || this.split, this.outside = x(h.outside, !(!i.scrollablePixelsX && !i.scrollablePixelsY));
}, p.prototype.shouldStickOnContact = function() {
return !(this.followPointer || !this.options.stickOnContact);
}, p.prototype.isStickyOnContact = function() {
return !(!this.shouldStickOnContact() || !this.inContact);
}, p.prototype.move = function(i, h, o, t) {
var s = this, n = s.now, A = s.options.animation !== !1 && !s.isHidden && (1 < Math.abs(i - n.x) || 1 < Math.abs(h - n.y)), _ = s.followPointer || 1 < s.len;
T(n, { x: A ? (2 * n.x + i) / 3 : i, y: A ? (n.y + h) / 2 : h, anchorX: _ ? void 0 : A ? (2 * n.anchorX + o) / 3 : o, anchorY: _ ? void 0 : A ? (n.anchorY + t) / 2 : t }), s.getLabel().attr(n), s.drawTracker(), A && (H.clearTimeout(this.tooltipTimeout), this.tooltipTimeout = setTimeout(function() {
s && s.move(i, h, o, t);
}, 32));
}, p.prototype.refresh = function(i, h) {
var o = this.chart, t = this.options, s = a(i), n = s[0], A = [], _ = t.formatter || this.defaultFormatter, D = this.shared, W = o.styledMode, P = {};
if (t.enabled) {
H.clearTimeout(this.hideTimer), this.allowShared = !(!B(i) && i.series && i.series.noSharedTooltip), this.followPointer = !this.split && n.series.tooltipOptions.followPointer, i = this.getAnchor(i, h);
var X = i[0], g = i[1];
if (D && this.allowShared ? (o.pointer.applyInactiveState(s), s.forEach(function(Y) {
Y.setState("hover"), A.push(Y.getLabelConfig());
}), P = { x: n.category, y: n.y }, P.points = A) : P = n.getLabelConfig(), this.len = A.length, _ = _.call(P, this), D = n.series, this.distance = x(D.tooltipOptions.distance, 16), _ === !1)
this.hide();
else {
if (this.split && this.allowShared)
this.renderSplit(
_,
s
);
else {
var m = X, L = g;
if (h && o.pointer.isDirectTouch && (m = h.chartX - o.plotLeft, L = h.chartY - o.plotTop), o.polar || D.options.clip === !1 || s.some(function(Y) {
return Y.series.shouldShowTooltip(m, L);
}))
h = this.getLabel(), t.style.width && !W || h.css({ width: this.chart.spacingBox.width + "px" }), h.attr({ text: _ && _.join ? _.join("") : _ }), h.removeClass(/highcharts-color-[\d]+/g).addClass("highcharts-color-" + x(n.colorIndex, D.colorIndex)), W || h.attr({ stroke: t.borderColor || n.color || D.color || "#666666" }), this.updatePosition({
plotX: X,
plotY: g,
negative: n.negative,
ttBelow: n.ttBelow,
h: i[2] || 0
});
else {
this.hide();
return;
}
}
this.isHidden && this.label && this.label.attr({ opacity: 1 }).show(), this.isHidden = !1;
}
O(this, "refresh");
}
}, p.prototype.renderSplit = function(i, h) {
function o(ht, at, J, tt, ot) {
return ot === void 0 && (ot = !0), J ? (at = it ? 0 : ct, ht = S(ht - tt / 2, z.left, z.right - tt - (t.outside ? et : 0))) : (at -= nt, ht = ot ? ht - tt - Q : ht + Q, ht = S(ht, ot ? ht : z.left, z.right)), { x: ht, y: at };
}
var t = this, s = t.chart, n = t.chart, A = n.chartWidth, _ = n.chartHeight, D = n.plotHeight, W = n.plotLeft, P = n.plotTop, X = n.pointer, g = n.scrollablePixelsY;
g = g === void 0 ? 0 : g;
var m = n.scrollablePixelsX, L = n.scrollingContainer;
L = L === void 0 ? { scrollLeft: 0, scrollTop: 0 } : L;
var Y = L.scrollLeft;
L = L.scrollTop;
var V = n.styledMode, Q = t.distance, k = t.options, G = t.options.positioner, z = t.outside && typeof m != "number" ? F.documentElement.getBoundingClientRect() : { left: Y, right: Y + A, top: L, bottom: L + _ }, $ = t.getLabel(), q = this.renderer || s.renderer, it = !(!s.xAxis[0] || !s.xAxis[0].opposite);
s = X.getChartPosition();
var et = s.left;
s = s.top;
var nt = P + L, rt = 0, ct = D - g;
b(i) && (i = [!1, i]), i = i.slice(0, h.length + 1).reduce(function(ht, at, J) {
if (at !== !1 && at !== "") {
J = h[J - 1] || { isHeader: !0, plotX: h[0].plotX, plotY: D, series: {} };
var tt = J.isHeader, ot = tt ? t : J.series;
at = at.toString();
var lt = ot.tt, pt = J.isHeader, yt = J.series, vt = "highcharts-color-" + x(J.colorIndex, yt.colorIndex, "none");
if (lt || (lt = { padding: k.padding, r: k.borderRadius }, V || (lt.fill = k.backgroundColor, lt["stroke-width"] = k.borderWidth), lt = q.label("", 0, 0, k[pt ? "headerShape" : "shape"], void 0, void 0, k.useHTML).addClass((pt ? "highcharts-tooltip-header " : "") + "highcharts-tooltip-box " + vt).attr(lt).add($)), lt.isActive = !0, lt.attr({ text: at }), V || lt.css(k.style).shadow(k.shadow).attr({ stroke: k.borderColor || J.color || yt.color || "#333333" }), ot = ot.tt = lt, pt = ot.getBBox(), at = pt.width + ot.strokeWidth(), tt && (rt = pt.height, ct += rt, it && (nt -= rt)), yt = J.plotX, yt = yt === void 0 ? 0 : yt, vt = J.plotY, vt = vt === void 0 ? 0 : vt, lt = J.series, J.isHeader) {
yt = W + yt;
var Ct = P + D / 2;
} else {
var Pt = lt.xAxis, At = lt.yAxis;
yt = Pt.pos + S(yt, -Q, Pt.len + Q), lt.shouldShowTooltip(0, At.pos - P + vt, { ignoreX: !0 }) && (Ct = At.pos + vt);
}
yt = S(yt, z.left - Q, z.right + Q), typeof Ct == "number" ? (pt = pt.height + 1, vt = G ? G.call(t, at, pt, J) : o(
yt,
Ct,
tt,
at
), ht.push({ align: G ? 0 : void 0, anchorX: yt, anchorY: Ct, boxWidth: at, point: J, rank: x(vt.rank, tt ? 1 : 0), size: pt, target: vt.y, tt: ot, x: vt.x })) : ot.isActive = !1;
}
return ht;
}, []), !G && i.some(function(ht) {
var at = (t.outside ? et : 0) + ht.anchorX;
return at < z.left && at + ht.boxWidth < z.right ? !0 : at < et - z.left + ht.boxWidth && z.right - at > at;
}) && (i = i.map(function(ht) {
var at = o(ht.anchorX, ht.anchorY, ht.point.isHeader, ht.boxWidth, !1);
return T(ht, { target: at.y, x: at.x });
})), t.cleanSplit(), N(i, ct);
var gt = et, dt = et;
i.forEach(function(ht) {
var at = ht.x, J = ht.boxWidth;
ht = ht.isHeader, ht || (t.outside && et + at < gt && (gt = et + at), !ht && t.outside && gt + J > dt && (dt = et + at));
}), i.forEach(function(ht) {
var at = ht.x, J = ht.anchorX, tt = ht.pos, ot = ht.point.isHeader;
if (tt = { visibility: typeof tt > "u" ? "hidden" : "inherit", x: at, y: tt + nt, anchorX: J, anchorY: ht.anchorY }, t.outside && at < J) {
var lt = et - gt;
0 < lt && (ot || (tt.x = at + lt, tt.anchorX = J + lt), ot && (tt.x = (dt - gt) / 2, tt.anchorX = J + lt));
}
ht.tt.attr(tt);
}), i = t.container, g = t.renderer, t.outside && i && g && (n = $.getBBox(), g.setSize(n.width + n.x, n.height + n.y, !1), i.style.left = gt + "px", i.style.top = s + "px");
}, p.prototype.drawTracker = function() {
if (this.followPointer || !this.options.stickOnContact)
this.tracker && this.tracker.destroy();
else {
var i = this.chart, h = this.label, o = this.shared ? i.hoverPoints : i.hoverPoint;
if (h && o) {
var t = { x: 0, y: 0, width: 0, height: 0 };
o = this.getAnchor(o);
var s = h.getBBox();
o[0] += i.plotLeft - h.translateX, o[1] += i.plotTop - h.translateY, t.x = Math.min(0, o[0]), t.y = Math.min(0, o[1]), t.width = 0 > o[0] ? Math.max(Math.abs(o[0]), s.width - o[0]) : Math.max(Math.abs(o[0]), s.width), t.height = 0 > o[1] ? Math.max(Math.abs(o[1]), s.height - Math.abs(o[1])) : Math.max(Math.abs(o[1]), s.height), this.tracker ? this.tracker.attr(t) : (this.tracker = h.renderer.rect(t).addClass("highcharts-tracker").add(h), i.styledMode || this.tracker.attr({ fill: "rgba(0,0,0,0)" }));
}
}
}, p.prototype.styledModeFormat = function(i) {
return i.replace('style="font-size: 10px"', 'class="highcharts-header"').replace(/style="color:{(point|series)\.color}"/g, 'class="highcharts-color-{$1.colorIndex}"');
}, p.prototype.tooltipFooterHeaderFormatter = function(i, h) {
var o = i.series, t = o.tooltipOptions, s = o.xAxis, n = s && s.dateTime;
s = {
isFooter: h,
labelConfig: i
};
var A = t.xDateFormat, _ = t[h ? "footerFormat" : "headerFormat"];
return O(this, "headerFormatter", s, function(D) {
n && !A && C(i.key) && (A = n.getXDateFormat(i.key, t.dateTimeLabelFormats)), n && A && (i.point && i.point.tooltipDateKeys || ["key"]).forEach(function(W) {
_ = _.replace("{point." + W + "}", "{point." + W + ":" + A + "}");
}), o.chart.styledMode && (_ = this.styledModeFormat(_)), D.text = U(_, { point: i, series: o }, this.chart);
}), s.text;
}, p.prototype.update = function(i) {
this.destroy(), w(!0, this.chart.options.tooltip.userOptions, i), this.init(this.chart, w(!0, this.options, i));
}, p.prototype.updatePosition = function(i) {
var h = this.chart, o = this.options, t = h.pointer, s = this.getLabel();
t = t.getChartPosition();
var n = (o.positioner || this.getPosition).call(this, s.width, s.height, i), A = i.plotX + h.plotLeft;
i = i.plotY + h.plotTop, this.outside && (o = o.borderWidth + 2 * this.distance, this.renderer.setSize(s.width + o, s.height + o, !1), (t.scaleX !== 1 || t.scaleY !== 1) && (v(this.container, { transform: "scale(" + t.scaleX + ", " + t.scaleY + ")" }), A *= t.scaleX, i *= t.scaleY), A += t.left - n.x, i += t.top - n.y), this.move(Math.round(n.x), Math.round(n.y || 0), A, i);
}, p;
}(), y;
}
), E(l, "Core/Series/Point.js", [l["Core/Renderer/HTML/AST.js"], l["Core/Animation/AnimationUtilities.js"], l["Core/DefaultOptions.js"], l["Core/FormatUtilities.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H) {
var U = j.animObject, F = I.defaultOptions, N = Z.format, R = H.addEvent, S = H.defined, v = H.erase, d = H.extend, u = H.fireEvent, T = H.getNestedProperty, O = H.isArray, B = H.isFunction, C = H.isNumber, b = H.isObject, w = H.merge, x = H.objectEach, a = H.pick, c = H.syncTimeout, p = H.removeEvent, i = H.uniqueKey;
return j = function() {
function h() {
this.colorIndex = this.category = void 0, this.formatPrefix = "point", this.id = void 0, this.isNull = !1, this.percentage = this.options = this.name = void 0, this.selected = !1, this.total = this.series = void 0, this.visible = !0, this.x = void 0;
}
return h.prototype.animateBeforeDestroy = function() {
var o = this, t = { x: o.startXPos, opacity: 0 }, s = o.getGraphicalProps();
s.singular.forEach(function(n) {
o[n] = o[n].animate(n === "dataLabel" ? {
x: o[n].startXPos,
y: o[n].startYPos,
opacity: 0
} : t);
}), s.plural.forEach(function(n) {
o[n].forEach(function(A) {
A.element && A.animate(d({ x: o.startXPos }, A.startYPos ? { x: A.startXPos, y: A.startYPos } : {}));
});
});
}, h.prototype.applyOptions = function(o, t) {
var s = this.series, n = s.options.pointValKey || s.pointValKey;
return o = h.prototype.optionsToObject.call(this, o), d(this, o), this.options = this.options ? d(this.options, o) : o, o.group && delete this.group, o.dataLabels && delete this.dataLabels, n && (this.y = h.prototype.getNestedProperty.call(this, n)), this.formatPrefix = (this.isNull = a(this.isValid && !this.isValid(), this.x === null || !C(this.y))) ? "null" : "point", this.selected && (this.state = "select"), "name" in this && typeof t > "u" && s.xAxis && s.xAxis.hasNames && (this.x = s.xAxis.nameToX(this)), typeof this.x > "u" && s ? this.x = typeof t > "u" ? s.autoIncrement() : t : C(o.x) && s.options.relativeXValue && (this.x = s.autoIncrement(o.x)), this;
}, h.prototype.destroy = function() {
function o() {
(t.graphic || t.dataLabel || t.dataLabels) && (p(t), t.destroyElements());
for (D in t)
t[D] = null;
}
var t = this, s = t.series, n = s.chart;
s = s.options.dataSorting;
var A = n.hoverPoints, _ = U(t.series.chart.renderer.globalAnimation), D;
t.legendItem && n.legend.destroyItem(t), A && (t.setState(), v(A, t), A.length || (n.hoverPoints = null)), t === n.hoverPoint && t.onMouseOut(), s && s.enabled ? (this.animateBeforeDestroy(), c(o, _.duration)) : o(), n.pointCount--;
}, h.prototype.destroyElements = function(o) {
var t = this;
o = t.getGraphicalProps(o), o.singular.forEach(function(s) {
t[s] = t[s].destroy();
}), o.plural.forEach(function(s) {
t[s].forEach(function(n) {
n.element && n.destroy();
}), delete t[s];
});
}, h.prototype.firePointEvent = function(o, t, s) {
var n = this, A = this.series.options;
(A.point.events[o] || n.options && n.options.events && n.options.events[o]) && n.importEvents(), o === "click" && A.allowPointSelect && (s = function(_) {
n.select && n.select(null, _.ctrlKey || _.metaKey || _.shiftKey);
}), u(n, o, t, s);
}, h.prototype.getClassName = function() {
return "highcharts-point" + (this.selected ? " highcharts-point-select" : "") + (this.negative ? " highcharts-negative" : "") + (this.isNull ? " highcharts-null-point" : "") + (typeof this.colorIndex < "u" ? " highcharts-color-" + this.colorIndex : "") + (this.options.className ? " " + this.options.className : "") + (this.zone && this.zone.className ? " " + this.zone.className.replace("highcharts-negative", "") : "");
}, h.prototype.getGraphicalProps = function(o) {
var t = this, s = [], n = { singular: [], plural: [] }, A;
for (o = o || { graphic: 1, dataLabel: 1 }, o.graphic && s.push("graphic", "upperGraphic", "shadowGroup"), o.dataLabel && s.push("dataLabel", "dataLabelUpper", "connector"), A = s.length; A--; ) {
var _ = s[A];
t[_] && n.singular.push(_);
}
return ["dataLabel", "connector"].forEach(function(D) {
var W = D + "s";
o[D] && t[W] && n.plural.push(W);
}), n;
}, h.prototype.getLabelConfig = function() {
return { x: this.category, y: this.y, color: this.color, colorIndex: this.colorIndex, key: this.name || this.category, series: this.series, point: this, percentage: this.percentage, total: this.total || this.stackTotal };
}, h.prototype.getNestedProperty = function(o) {
if (o)
return o.indexOf("custom.") === 0 ? T(o, this.options) : this[o];
}, h.prototype.getZone = function() {
var o = this.series, t = o.zones;
o = o.zoneAxis || "y";
var s, n = 0;
for (s = t[n]; this[o] >= s.value; )
s = t[++n];
return this.nonZonedColor || (this.nonZonedColor = this.color), this.color = s && s.color && !this.options.color ? s.color : this.nonZonedColor, s;
}, h.prototype.hasNewShapeType = function() {
return (this.graphic && (this.graphic.symbolName || this.graphic.element.nodeName)) !== this.shapeType;
}, h.prototype.init = function(o, t, s) {
return this.series = o, this.applyOptions(t, s), this.id = S(this.id) ? this.id : i(), this.resolveColor(), o.chart.pointCount++, u(this, "afterInit"), this;
}, h.prototype.optionsToObject = function(o) {
var t = this.series, s = t.options.keys, n = s || t.pointArrayMap || ["y"], A = n.length, _ = {}, D = 0, W = 0;
if (C(o) || o === null)
_[n[0]] = o;
else if (O(o))
for (!s && o.length > A && (t = typeof o[0], t === "string" ? _.name = o[0] : t === "number" && (_.x = o[0]), D++); W < A; )
s && typeof o[D] > "u" || (0 < n[W].indexOf(".") ? h.prototype.setNestedProperty(_, o[D], n[W]) : _[n[W]] = o[D]), D++, W++;
else
typeof o == "object" && (_ = o, o.dataLabels && (t._hasPointLabels = !0), o.marker && (t._hasPointMarkers = !0));
return _;
}, h.prototype.resolveColor = function() {
var o = this.series, t = o.chart.styledMode, s = o.chart.options.chart.colorCount;
if (delete this.nonZonedColor, o.options.colorByPoint) {
if (!t) {
s = o.options.colors || o.chart.options.colors;
var n = s[o.colorCounter];
s = s.length;
}
t = o.colorCounter, o.colorCounter++, o.colorCounter === s && (o.colorCounter = 0);
} else
t || (n = o.color), t = o.colorIndex;
this.colorIndex = a(this.options.colorIndex, t), this.color = a(this.options.color, n);
}, h.prototype.setNestedProperty = function(o, t, s) {
return s.split(".").reduce(function(n, A, _, D) {
return n[A] = D.length - 1 === _ ? t : b(n[A], !0) ? n[A] : {}, n[A];
}, o), o;
}, h.prototype.tooltipFormatter = function(o) {
var t = this.series, s = t.tooltipOptions, n = a(s.valueDecimals, ""), A = s.valuePrefix || "", _ = s.valueSuffix || "";
return t.chart.styledMode && (o = t.chart.tooltip.styledModeFormat(o)), (t.pointArrayMap || ["y"]).forEach(function(D) {
D = "{point." + D, (A || _) && (o = o.replace(RegExp(D + "}", "g"), A + D + "}" + _)), o = o.replace(RegExp(D + "}", "g"), D + ":,." + n + "f}");
}), N(o, { point: this, series: this.series }, t.chart);
}, h.prototype.update = function(o, t, s, n) {
function A() {
_.applyOptions(o);
var m = W && _.hasDummyGraphic;
m = _.y === null ? !m : m, W && m && (_.graphic = W.destroy(), delete _.hasDummyGraphic), b(o, !0) && (W && W.element && o && o.marker && typeof o.marker.symbol < "u" && (_.graphic = W.destroy()), o && o.dataLabels && _.dataLabel && (_.dataLabel = _.dataLabel.destroy()), _.connector && (_.connector = _.connector.destroy())), g = _.index, D.updateParallelArrays(_, g), X.data[g] = b(X.data[g], !0) || b(o, !0) ? _.options : a(o, X.data[g]), D.isDirty = D.isDirtyData = !0, !D.fixedBox && D.hasCartesianSeries && (P.isDirtyBox = !0), X.legendType === "point" && (P.isDirtyLegend = !0), t && P.redraw(s);
}
var _ = this, D = _.series, W = _.graphic, P = D.chart, X = D.options, g;
t = a(t, !0), n === !1 ? A() : _.firePointEvent("update", { options: o }, A);
}, h.prototype.remove = function(o, t) {
this.series.removePoint(this.series.data.indexOf(this), o, t);
}, h.prototype.select = function(o, t) {
var s = this, n = s.series, A = n.chart;
this.selectedStaging = o = a(o, !s.selected), s.firePointEvent(o ? "select" : "unselect", { accumulate: t }, function() {
s.selected = s.options.selected = o, n.options.data[n.data.indexOf(s)] = s.options, s.setState(o && "select"), t || A.getSelectedPoints().forEach(function(_) {
var D = _.series;
_.selected && _ !== s && (_.selected = _.options.selected = !1, D.options.data[D.data.indexOf(_)] = _.options, _.setState(A.hoverPoints && D.options.inactiveOtherPoints ? "inactive" : ""), _.firePointEvent("unselect"));
});
}), delete this.selectedStaging;
}, h.prototype.onMouseOver = function(o) {
var t = this.series.chart, s = t.pointer;
o = o ? s.normalize(o) : s.getChartCoordinatesFromPoint(this, t.inverted), s.runPointActions(
o,
this
);
}, h.prototype.onMouseOut = function() {
var o = this.series.chart;
this.firePointEvent("mouseOut"), this.series.options.inactiveOtherPoints || (o.hoverPoints || []).forEach(function(t) {
t.setState();
}), o.hoverPoints = o.hoverPoint = null;
}, h.prototype.importEvents = function() {
if (!this.hasImportedEvents) {
var o = this, t = w(o.series.options.point, o.options).events;
o.events = t, x(t, function(s, n) {
B(s) && R(o, n, s);
}), this.hasImportedEvents = !0;
}
}, h.prototype.setState = function(o, t) {
var s = this.series, n = this.state, A = s.options.states[o || "normal"] || {}, _ = F.plotOptions[s.type].marker && s.options.marker, D = _ && _.enabled === !1, W = _ && _.states && _.states[o || "normal"] || {}, P = W.enabled === !1, X = this.marker || {}, g = s.chart, m = _ && s.markerAttribs, L = s.halo, Y, V = s.stateMarkerGraphic;
if (o = o || "", !(o === this.state && !t || this.selected && o !== "select" || A.enabled === !1 || o && (P || D && W.enabled === !1) || o && X.states && X.states[o] && X.states[o].enabled === !1)) {
if (this.state = o, m && (Y = s.markerAttribs(this, o)), this.graphic && !this.hasDummyGraphic) {
if (n && this.graphic.removeClass("highcharts-point-" + n), o && this.graphic.addClass("highcharts-point-" + o), !g.styledMode) {
var Q = s.pointAttribs(this, o), k = a(g.options.chart.animation, A.animation);
s.options.inactiveOtherPoints && C(Q.opacity) && ((this.dataLabels || []).forEach(function(G) {
G && G.animate({ opacity: Q.opacity }, k);
}), this.connector && this.connector.animate({ opacity: Q.opacity }, k)), this.graphic.animate(Q, k);
}
Y && this.graphic.animate(Y, a(g.options.chart.animation, W.animation, _.animation)), V && V.hide();
} else
o && W && (n = X.symbol || s.symbol, V && V.currentSymbol !== n && (V = V.destroy()), Y && (V ? V[t ? "animate" : "attr"]({ x: Y.x, y: Y.y }) : n && (s.stateMarkerGraphic = V = g.renderer.symbol(n, Y.x, Y.y, Y.width, Y.height).add(s.markerGroup), V.currentSymbol = n)), !g.styledMode && V && this.state !== "inactive" && V.attr(s.pointAttribs(this, o))), V && (V[o && this.isInside ? "show" : "hide"](), V.element.point = this, V.addClass(this.getClassName(), !0));
A = A.halo, Y = (V = this.graphic || V) && V.visibility || "inherit", A && A.size && V && Y !== "hidden" && !this.isCluster ? (L || (s.halo = L = g.renderer.path().add(V.parentGroup)), L.show()[t ? "animate" : "attr"]({ d: this.haloPath(A.size) }), L.attr({ class: "highcharts-halo highcharts-color-" + a(this.colorIndex, s.colorIndex) + (this.className ? " " + this.className : ""), visibility: Y, zIndex: -1 }), L.point = this, g.styledMode || L.attr(d({ fill: this.color || s.color, "fill-opacity": A.opacity }, y.filterUserAttributes(A.attributes || {})))) : L && L.point && L.point.haloPath && L.animate({ d: L.point.haloPath(0) }, null, L.hide), u(this, "afterSetState", { state: o });
}
}, h.prototype.haloPath = function(o) {
return this.series.chart.renderer.symbols.circle(Math.floor(this.plotX) - o, this.plotY - o, 2 * o, 2 * o);
}, h;
}(), j;
}), E(l, "Core/Pointer.js", [l["Core/Color/Color.js"], l["Core/Globals.js"], l["Core/Tooltip.js"], l["Core/Utilities.js"]], function(y, j, I, Z) {
var H = y.parse, U = j.charts, F = j.noop, N = Z.addEvent, R = Z.attr, S = Z.css, v = Z.defined, d = Z.extend, u = Z.find, T = Z.fireEvent, O = Z.isNumber, B = Z.isObject, C = Z.objectEach, b = Z.offset, w = Z.pick, x = Z.splat;
return y = function() {
function a(c, p) {
this.lastValidTouch = {}, this.pinchDown = [], this.runChartClick = !1, this.eventsToUnbind = [], this.chart = c, this.hasDragged = !1, this.options = p, this.init(c, p);
}
return a.prototype.applyInactiveState = function(c) {
var p = [], i;
(c || []).forEach(function(h) {
i = h.series, p.push(i), i.linkedParent && p.push(i.linkedParent), i.linkedSeries && (p = p.concat(i.linkedSeries)), i.navigatorSeries && p.push(i.navigatorSeries);
}), this.chart.series.forEach(function(h) {
p.indexOf(h) === -1 ? h.setState("inactive", !0) : h.options.inactiveOtherPoints && h.setAllPointsToState("inactive");
});
}, a.prototype.destroy = function() {
var c = this;
this.eventsToUnbind.forEach(function(p) {
return p();
}), this.eventsToUnbind = [], j.chartCount || (a.unbindDocumentMouseUp && (a.unbindDocumentMouseUp = a.unbindDocumentMouseUp()), a.unbindDocumentTouchEnd && (a.unbindDocumentTouchEnd = a.unbindDocumentTouchEnd())), clearInterval(c.tooltipTimeout), C(c, function(p, i) {
c[i] = void 0;
});
}, a.prototype.drag = function(c) {
var p = this.chart, i = p.options.chart, h = this.zoomHor, o = this.zoomVert, t = p.plotLeft, s = p.plotTop, n = p.plotWidth, A = p.plotHeight, _ = this.mouseDownX || 0, D = this.mouseDownY || 0, W = B(i.panning) ? i.panning && i.panning.enabled : i.panning, P = i.panKey && c[i.panKey + "Key"], X = c.chartX, g = c.chartY, m = this.selectionMarker;
if ((!m || !m.touch) && (X < t ? X = t : X > t + n && (X = t + n), g < s ? g = s : g > s + A && (g = s + A), this.hasDragged = Math.sqrt(Math.pow(_ - X, 2) + Math.pow(D - g, 2)), 10 < this.hasDragged)) {
var L = p.isInsidePlot(_ - t, D - s, { visiblePlotOnly: !0 });
!p.hasCartesianSeries && !p.mapView || !this.zoomX && !this.zoomY || !L || P || m || (this.selectionMarker = m = p.renderer.rect(t, s, h ? 1 : n, o ? 1 : A, 0).attr({ class: "highcharts-selection-marker", zIndex: 7 }).add(), p.styledMode || m.attr({ fill: i.selectionMarkerFill || H("#335cad").setOpacity(0.25).get() })), m && h && (h = X - _, m.attr({ width: Math.abs(h), x: (0 < h ? 0 : h) + _ })), m && o && (h = g - D, m.attr({ height: Math.abs(h), y: (0 < h ? 0 : h) + D })), L && !m && W && p.pan(c, i.panning);
}
}, a.prototype.dragStart = function(c) {
var p = this.chart;
p.mouseIsDown = c.type, p.cancelClick = !1, p.mouseDownX = this.mouseDownX = c.chartX, p.mouseDownY = this.mouseDownY = c.chartY;
}, a.prototype.drop = function(c) {
var p = this, i = this.chart, h = this.hasPinched;
if (this.selectionMarker) {
var o = this.selectionMarker, t = o.attr ? o.attr("x") : o.x, s = o.attr ? o.attr("y") : o.y, n = o.attr ? o.attr("width") : o.width, A = o.attr ? o.attr("height") : o.height, _ = { originalEvent: c, xAxis: [], yAxis: [], x: t, y: s, width: n, height: A }, D = !!i.mapView;
(this.hasDragged || h) && (i.axes.forEach(function(W) {
if (W.zoomEnabled && v(W.min) && (h || p[{ xAxis: "zoomX", yAxis: "zoomY" }[W.coll]]) && O(t) && O(s)) {
var P = W.horiz, X = c.type === "touchend" ? W.minPixelPadding : 0, g = W.toValue((P ? t : s) + X);
P = W.toValue((P ? t + n : s + A) - X), _[W.coll].push({ axis: W, min: Math.min(g, P), max: Math.max(g, P) }), D = !0;
}
}), D && T(i, "selection", _, function(W) {
i.zoom(d(
W,
h ? { animation: !1 } : null
));
})), O(i.index) && (this.selectionMarker = this.selectionMarker.destroy()), h && this.scaleGroups();
}
i && O(i.index) && (S(i.container, { cursor: i._cursor }), i.cancelClick = 10 < this.hasDragged, i.mouseIsDown = this.hasDragged = this.hasPinched = !1, this.pinchDown = []);
}, a.prototype.findNearestKDPoint = function(c, p, i) {
var h = this.chart, o = h.hoverPoint;
if (h = h.tooltip, o && h && h.isStickyOnContact())
return o;
var t;
return c.forEach(function(s) {
var n = !(s.noSharedTooltip && p) && 0 > s.options.findNearestPointBy.indexOf("y");
if (s = s.searchPoint(i, n), (n = B(s, !0) && s.series) && !(n = !B(t, !0))) {
n = t.distX - s.distX;
var A = t.dist - s.dist, _ = (s.series.group && s.series.group.zIndex) - (t.series.group && t.series.group.zIndex);
n = 0 < (n !== 0 && p ? n : A !== 0 ? A : _ !== 0 ? _ : t.series.index > s.series.index ? -1 : 1);
}
n && (t = s);
}), t;
}, a.prototype.getChartCoordinatesFromPoint = function(c, p) {
var i = c.series, h = i.xAxis;
i = i.yAxis;
var o = c.shapeArgs;
if (h && i) {
var t = w(c.clientX, c.plotX), s = c.plotY || 0;
return c.isNode && o && O(o.x) && O(o.y) && (t = o.x, s = o.y), p ? { chartX: i.len + i.pos - s, chartY: h.len + h.pos - t } : { chartX: t + h.pos, chartY: s + i.pos };
}
if (o && o.x && o.y)
return { chartX: o.x, chartY: o.y };
}, a.prototype.getChartPosition = function() {
if (this.chartPosition)
return this.chartPosition;
var c = this.chart.container, p = b(c);
this.chartPosition = { left: p.left, top: p.top, scaleX: 1, scaleY: 1 };
var i = c.offsetWidth;
return c = c.offsetHeight, 2 < i && 2 < c && (this.chartPosition.scaleX = p.width / i, this.chartPosition.scaleY = p.height / c), this.chartPosition;
}, a.prototype.getCoordinates = function(c) {
var p = { xAxis: [], yAxis: [] };
return this.chart.axes.forEach(function(i) {
p[i.isXAxis ? "xAxis" : "yAxis"].push({ axis: i, value: i.toValue(c[i.horiz ? "chartX" : "chartY"]) });
}), p;
}, a.prototype.getHoverData = function(c, p, i, h, o, t) {
var s = [];
h = !(!h || !c);
var n = { chartX: t ? t.chartX : void 0, chartY: t ? t.chartY : void 0, shared: o };
T(this, "beforeGetHoverData", n);
var A = p && !p.stickyTracking ? [p] : i.filter(function(D) {
return n.filter ? n.filter(D) : D.visible && !(!o && D.directTouch) && w(D.options.enableMouseTracking, !0) && D.stickyTracking;
}), _ = h || !t ? c : this.findNearestKDPoint(A, o, t);
return p = _ && _.series, _ && (o && !p.noSharedTooltip ? (A = i.filter(function(D) {
return n.filter ? n.filter(D) : D.visible && !(!o && D.directTouch) && w(D.options.enableMouseTracking, !0) && !D.noSharedTooltip;
}), A.forEach(function(D) {
var W = u(D.points, function(P) {
return P.x === _.x && !P.isNull;
});
B(W) && (D.chart.isBoosting && (W = D.getPoint(W)), s.push(W));
})) : s.push(_)), n = { hoverPoint: _ }, T(this, "afterGetHoverData", n), { hoverPoint: n.hoverPoint, hoverSeries: p, hoverPoints: s };
}, a.prototype.getPointFromEvent = function(c) {
c = c.target;
for (var p; c && !p; )
p = c.point, c = c.parentNode;
return p;
}, a.prototype.onTrackerMouseOut = function(c) {
c = c.relatedTarget || c.toElement;
var p = this.chart.hoverSeries;
this.isDirectTouch = !1, !p || !c || p.stickyTracking || this.inClass(c, "highcharts-tooltip") || this.inClass(c, "highcharts-series-" + p.index) && this.inClass(c, "highcharts-tracker") || p.onMouseOut();
}, a.prototype.inClass = function(c, p) {
for (var i; c; ) {
if (i = R(c, "class")) {
if (i.indexOf(p) !== -1)
return !0;
if (i.indexOf("highcharts-container") !== -1)
return !1;
}
c = c.parentNode;
}
}, a.prototype.init = function(c, p) {
this.options = p, this.chart = c, this.runChartClick = !(!p.chart.events || !p.chart.events.click), this.pinchDown = [], this.lastValidTouch = {}, I && (c.tooltip = new I(c, p.tooltip), this.followTouchMove = w(p.tooltip.followTouchMove, !0)), this.setDOMEvents();
}, a.prototype.normalize = function(c, p) {
var i = c.touches, h = i ? i.length ? i.item(0) : w(i.changedTouches, c.changedTouches)[0] : c;
return p || (p = this.getChartPosition()), i = h.pageX - p.left, h = h.pageY - p.top, i /= p.scaleX, h /= p.scaleY, d(c, { chartX: Math.round(i), chartY: Math.round(h) });
}, a.prototype.onContainerClick = function(c) {
var p = this.chart, i = p.hoverPoint;
c = this.normalize(c);
var h = p.plotLeft, o = p.plotTop;
p.cancelClick || (i && this.inClass(c.target, "highcharts-tracker") ? (T(i.series, "click", d(c, { point: i })), p.hoverPoint && i.firePointEvent("click", c)) : (d(c, this.getCoordinates(c)), p.isInsidePlot(c.chartX - h, c.chartY - o, { visiblePlotOnly: !0 }) && T(p, "click", c)));
}, a.prototype.onContainerMouseDown = function(c) {
var p = ((c.buttons || c.button) & 1) === 1;
c = this.normalize(c), j.isFirefox && c.button !== 0 && this.onContainerMouseMove(c), (typeof c.button > "u" || p) && (this.zoomOption(c), p && c.preventDefault && c.preventDefault(), this.dragStart(c));
}, a.prototype.onContainerMouseLeave = function(c) {
var p = U[w(a.hoverChartIndex, -1)], i = this.chart.tooltip;
i && i.shouldStickOnContact() && this.inClass(c.relatedTarget, "highcharts-tooltip-container") || (c = this.normalize(c), p && (c.relatedTarget || c.toElement) && (p.pointer.reset(), p.pointer.chartPosition = void 0), i && !i.isHidden && this.reset());
}, a.prototype.onContainerMouseEnter = function(c) {
delete this.chartPosition;
}, a.prototype.onContainerMouseMove = function(c) {
var p = this.chart;
c = this.normalize(c), this.setHoverChartIndex(), c.preventDefault || (c.returnValue = !1), (p.mouseIsDown === "mousedown" || this.touchSelect(c)) && this.drag(c), p.openMenu || !this.inClass(c.target, "highcharts-tracker") && !p.isInsidePlot(c.chartX - p.plotLeft, c.chartY - p.plotTop, { visiblePlotOnly: !0 }) || (this.inClass(c.target, "highcharts-no-tooltip") ? this.reset(!1, 0) : this.runPointActions(c));
}, a.prototype.onDocumentTouchEnd = function(c) {
var p = U[w(
a.hoverChartIndex,
-1
)];
p && p.pointer.drop(c);
}, a.prototype.onContainerTouchMove = function(c) {
this.touchSelect(c) ? this.onContainerMouseMove(c) : this.touch(c);
}, a.prototype.onContainerTouchStart = function(c) {
this.touchSelect(c) ? this.onContainerMouseDown(c) : (this.zoomOption(c), this.touch(c, !0));
}, a.prototype.onDocumentMouseMove = function(c) {
var p = this.chart, i = this.chartPosition;
c = this.normalize(c, i);
var h = p.tooltip;
!i || h && h.isStickyOnContact() || p.isInsidePlot(c.chartX - p.plotLeft, c.chartY - p.plotTop, { visiblePlotOnly: !0 }) || this.inClass(c.target, "highcharts-tracker") || this.reset();
}, a.prototype.onDocumentMouseUp = function(c) {
var p = U[w(a.hoverChartIndex, -1)];
p && p.pointer.drop(c);
}, a.prototype.pinch = function(c) {
var p = this, i = p.chart, h = p.pinchDown, o = c.touches || [], t = o.length, s = p.lastValidTouch, n = p.hasZoom, A = {}, _ = t === 1 && (p.inClass(c.target, "highcharts-tracker") && i.runTrackerClick || p.runChartClick), D = {}, W = p.selectionMarker;
1 < t ? p.initiated = !0 : t === 1 && this.followTouchMove && (p.initiated = !1), n && p.initiated && !_ && c.cancelable !== !1 && c.preventDefault(), [].map.call(o, function(P) {
return p.normalize(P);
}), c.type === "touchstart" ? ([].forEach.call(o, function(P, X) {
h[X] = { chartX: P.chartX, chartY: P.chartY };
}), s.x = [h[0].chartX, h[1] && h[1].chartX], s.y = [h[0].chartY, h[1] && h[1].chartY], i.axes.forEach(function(P) {
if (P.zoomEnabled) {
var X = i.bounds[P.horiz ? "h" : "v"], g = P.minPixelPadding, m = P.toPixels(Math.min(w(P.options.min, P.dataMin), P.dataMin)), L = P.toPixels(Math.max(w(P.options.max, P.dataMax), P.dataMax)), Y = Math.max(m, L);
X.min = Math.min(P.pos, Math.min(
m,
L
) - g), X.max = Math.max(P.pos + P.len, Y + g);
}
}), p.res = !0) : p.followTouchMove && t === 1 ? this.runPointActions(p.normalize(c)) : h.length && (T(i, "touchpan", { originalEvent: c }, function() {
W || (p.selectionMarker = W = d({ destroy: F, touch: !0 }, i.plotBox)), p.pinchTranslate(h, o, A, W, D, s), p.hasPinched = n, p.scaleGroups(A, D);
}), p.res && (p.res = !1, this.reset(!1, 0)));
}, a.prototype.pinchTranslate = function(c, p, i, h, o, t) {
this.zoomHor && this.pinchTranslateDirection(!0, c, p, i, h, o, t), this.zoomVert && this.pinchTranslateDirection(!1, c, p, i, h, o, t);
}, a.prototype.pinchTranslateDirection = function(c, p, i, h, o, t, s, n) {
var A = this.chart, _ = c ? "x" : "y", D = c ? "X" : "Y", W = "chart" + D, P = c ? "width" : "height", X = A["plot" + (c ? "Left" : "Top")], g = A.inverted, m = A.bounds[c ? "h" : "v"], L = p.length === 1, Y = p[0][W], V = !L && p[1][W];
p = function() {
typeof $ == "number" && 20 < Math.abs(Y - V) && (G = n || Math.abs(z - $) / Math.abs(Y - V)), k = (X - z) / G + Y, Q = A["plot" + (c ? "Width" : "Height")] / G;
};
var Q, k, G = n || 1, z = i[0][W], $ = !L && i[1][W];
if (p(), i = k, i < m.min) {
i = m.min;
var q = !0;
} else
i + Q > m.max && (i = m.max - Q, q = !0);
q ? (z -= 0.8 * (z - s[_][0]), typeof $ == "number" && ($ -= 0.8 * ($ - s[_][1])), p()) : s[_] = [z, $], g || (t[_] = k - X, t[P] = Q), t = g ? 1 / G : G, o[P] = Q, o[_] = i, h[g ? c ? "scaleY" : "scaleX" : "scale" + D] = G, h["translate" + D] = t * X + (z - t * Y);
}, a.prototype.reset = function(c, p) {
var i = this.chart, h = i.hoverSeries, o = i.hoverPoint, t = i.hoverPoints, s = i.tooltip, n = s && s.shared ? t : o;
c && n && x(n).forEach(function(A) {
A.series.isCartesian && typeof A.plotX > "u" && (c = !1);
}), c ? s && n && x(n).length && (s.refresh(n), s.shared && t ? t.forEach(function(A) {
A.setState(A.state, !0), A.series.isCartesian && (A.series.xAxis.crosshair && A.series.xAxis.drawCrosshair(
null,
A
), A.series.yAxis.crosshair && A.series.yAxis.drawCrosshair(null, A));
}) : o && (o.setState(o.state, !0), i.axes.forEach(function(A) {
A.crosshair && o.series[A.coll] === A && A.drawCrosshair(null, o);
}))) : (o && o.onMouseOut(), t && t.forEach(function(A) {
A.setState();
}), h && h.onMouseOut(), s && s.hide(p), this.unDocMouseMove && (this.unDocMouseMove = this.unDocMouseMove()), i.axes.forEach(function(A) {
A.hideCrosshair();
}), this.hoverX = i.hoverPoints = i.hoverPoint = null);
}, a.prototype.runPointActions = function(c, p) {
var i = this.chart, h = i.tooltip && i.tooltip.options.enabled ? i.tooltip : void 0, o = h ? h.shared : !1, t = p || i.hoverPoint, s = t && t.series || i.hoverSeries;
p = this.getHoverData(t, s, i.series, (!c || c.type !== "touchmove") && (!!p || s && s.directTouch && this.isDirectTouch), o, c), t = p.hoverPoint, s = p.hoverSeries;
var n = p.hoverPoints;
if (p = s && s.tooltipOptions.followPointer && !s.tooltipOptions.split, o = o && s && !s.noSharedTooltip, t && (t !== i.hoverPoint || h && h.isHidden)) {
if ((i.hoverPoints || []).forEach(function(A) {
n.indexOf(A) === -1 && A.setState();
}), i.hoverSeries !== s && s.onMouseOver(), this.applyInactiveState(n), (n || []).forEach(function(A) {
A.setState("hover");
}), i.hoverPoint && i.hoverPoint.firePointEvent("mouseOut"), !t.series)
return;
i.hoverPoints = n, i.hoverPoint = t, t.firePointEvent("mouseOver"), h && h.refresh(o ? n : t, c);
} else
p && h && !h.isHidden && (t = h.getAnchor([{}], c), i.isInsidePlot(t[0], t[1], { visiblePlotOnly: !0 }) && h.updatePosition({ plotX: t[0], plotY: t[1] }));
this.unDocMouseMove || (this.unDocMouseMove = N(i.container.ownerDocument, "mousemove", function(A) {
var _ = U[a.hoverChartIndex];
_ && _.pointer.onDocumentMouseMove(A);
}), this.eventsToUnbind.push(this.unDocMouseMove)), i.axes.forEach(function(A) {
var _ = w((A.crosshair || {}).snap, !0), D;
_ && ((D = i.hoverPoint) && D.series[A.coll] === A || (D = u(n, function(W) {
return W.series[A.coll] === A;
}))), D || !_ ? A.drawCrosshair(c, D) : A.hideCrosshair();
});
}, a.prototype.scaleGroups = function(c, p) {
var i = this.chart;
i.series.forEach(function(h) {
var o = c || h.getPlotBox();
h.group && (h.xAxis && h.xAxis.zoomEnabled || i.mapView) && (h.group.attr(o), h.markerGroup && (h.markerGroup.attr(o), h.markerGroup.clip(p ? i.clipRect : null)), h.dataLabelsGroup && h.dataLabelsGroup.attr(o));
}), i.clipRect.attr(p || i.clipBox);
}, a.prototype.setDOMEvents = function() {
var c = this, p = this.chart.container, i = p.ownerDocument;
p.onmousedown = this.onContainerMouseDown.bind(this), p.onmousemove = this.onContainerMouseMove.bind(this), p.onclick = this.onContainerClick.bind(this), this.eventsToUnbind.push(N(p, "mouseenter", this.onContainerMouseEnter.bind(this))), this.eventsToUnbind.push(N(p, "mouseleave", this.onContainerMouseLeave.bind(this))), a.unbindDocumentMouseUp || (a.unbindDocumentMouseUp = N(i, "mouseup", this.onDocumentMouseUp.bind(this)));
for (var h = this.chart.renderTo.parentElement; h && h.tagName !== "BODY"; )
this.eventsToUnbind.push(N(h, "scroll", function() {
delete c.chartPosition;
})), h = h.parentElement;
j.hasTouch && (this.eventsToUnbind.push(N(p, "touchstart", this.onContainerTouchStart.bind(this), { passive: !1 })), this.eventsToUnbind.push(N(p, "touchmove", this.onContainerTouchMove.bind(this), { passive: !1 })), a.unbindDocumentTouchEnd || (a.unbindDocumentTouchEnd = N(i, "touchend", this.onDocumentTouchEnd.bind(this), { passive: !1 })));
}, a.prototype.setHoverChartIndex = function() {
var c = this.chart, p = j.charts[w(a.hoverChartIndex, -1)];
p && p !== c && p.pointer.onContainerMouseLeave({ relatedTarget: !0 }), p && p.mouseIsDown || (a.hoverChartIndex = c.index);
}, a.prototype.touch = function(c, p) {
var i = this.chart;
if (this.setHoverChartIndex(), c.touches.length === 1)
if (c = this.normalize(c), i.isInsidePlot(c.chartX - i.plotLeft, c.chartY - i.plotTop, { visiblePlotOnly: !0 }) && !i.openMenu) {
if (p && this.runPointActions(c), c.type === "touchmove") {
p = this.pinchDown;
var h = p[0] ? 4 <= Math.sqrt(Math.pow(p[0].chartX - c.chartX, 2) + Math.pow(p[0].chartY - c.chartY, 2)) : !1;
}
w(h, !0) && this.pinch(c);
} else
p && this.reset();
else
c.touches.length === 2 && this.pinch(c);
}, a.prototype.touchSelect = function(c) {
return !(!this.chart.options.chart.zoomBySingleTouch || !c.touches || c.touches.length !== 1);
}, a.prototype.zoomOption = function(c) {
var p = this.chart, i = p.options.chart;
p = p.inverted;
var h = i.zoomType || "";
/touch/.test(c.type) && (h = w(i.pinchType, h)), this.zoomX = c = /x/.test(h), this.zoomY = i = /y/.test(h), this.zoomHor = c && !p || i && p, this.zoomVert = i && !p || c && p, this.hasZoom = c || i;
}, a;
}(), y;
}), E(l, "Core/MSPointer.js", [l["Core/Globals.js"], l["Core/Pointer.js"], l["Core/Utilities.js"]], function(y, j, I) {
function Z() {
var C = [];
return C.item = function(b) {
return this[b];
}, u(O, function(b) {
C.push({ pageX: b.pageX, pageY: b.pageY, target: b.target });
}), C;
}
function H(C, b, w, x) {
var a = F[j.hoverChartIndex || NaN];
C.pointerType !== "touch" && C.pointerType !== C.MSPOINTER_TYPE_TOUCH || !a || (a = a.pointer, x(C), a[b]({ type: w, target: C.currentTarget, preventDefault: R, touches: Z() }));
}
var U = this && this.__extends || function() {
var C = function(b, w) {
return C = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(x, a) {
x.__proto__ = a;
} || function(x, a) {
for (var c in a)
a.hasOwnProperty(c) && (x[c] = a[c]);
}, C(b, w);
};
return function(b, w) {
function x() {
this.constructor = b;
}
C(b, w), b.prototype = w === null ? Object.create(w) : (x.prototype = w.prototype, new x());
};
}(), F = y.charts, N = y.doc, R = y.noop, S = y.win, v = I.addEvent, d = I.css, u = I.objectEach, T = I.removeEvent, O = {}, B = !!S.PointerEvent;
return function(C) {
function b() {
return C !== null && C.apply(this, arguments) || this;
}
return U(b, C), b.isRequired = function() {
return !(y.hasTouch || !S.PointerEvent && !S.MSPointerEvent);
}, b.prototype.batchMSEvents = function(w) {
w(this.chart.container, B ? "pointerdown" : "MSPointerDown", this.onContainerPointerDown), w(this.chart.container, B ? "pointermove" : "MSPointerMove", this.onContainerPointerMove), w(N, B ? "pointerup" : "MSPointerUp", this.onDocumentPointerUp);
}, b.prototype.destroy = function() {
this.batchMSEvents(T), C.prototype.destroy.call(this);
}, b.prototype.init = function(w, x) {
C.prototype.init.call(this, w, x), this.hasZoom && d(w.container, { "-ms-touch-action": "none", "touch-action": "none" });
}, b.prototype.onContainerPointerDown = function(w) {
H(w, "onContainerTouchStart", "touchstart", function(x) {
O[x.pointerId] = { pageX: x.pageX, pageY: x.pageY, target: x.currentTarget };
});
}, b.prototype.onContainerPointerMove = function(w) {
H(w, "onContainerTouchMove", "touchmove", function(x) {
O[x.pointerId] = {
pageX: x.pageX,
pageY: x.pageY
}, O[x.pointerId].target || (O[x.pointerId].target = x.currentTarget);
});
}, b.prototype.onDocumentPointerUp = function(w) {
H(w, "onDocumentTouchEnd", "touchend", function(x) {
delete O[x.pointerId];
});
}, b.prototype.setDOMEvents = function() {
C.prototype.setDOMEvents.call(this), (this.hasZoom || this.followTouchMove) && this.batchMSEvents(v);
}, b;
}(j);
}), E(l, "Core/Legend/Legend.js", [
l["Core/Animation/AnimationUtilities.js"],
l["Core/FormatUtilities.js"],
l["Core/Globals.js"],
l["Core/Series/Point.js"],
l["Core/Renderer/RendererUtilities.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z, H, U) {
var F = y.animObject, N = y.setAnimation, R = j.format;
y = I.isFirefox;
var S = I.marginNames;
I = I.win;
var v = H.distribute, d = U.addEvent, u = U.createElement, T = U.css, O = U.defined, B = U.discardElement, C = U.find, b = U.fireEvent, w = U.isNumber, x = U.merge, a = U.pick, c = U.relativeLength, p = U.stableSort, i = U.syncTimeout;
return H = U.wrap, U = function() {
function h(o, t) {
this.allItems = [], this.contentGroup = this.box = void 0, this.display = !1, this.group = void 0, this.offsetWidth = this.maxLegendWidth = this.maxItemWidth = this.legendWidth = this.legendHeight = this.lastLineHeight = this.lastItemY = this.itemY = this.itemX = this.itemMarginTop = this.itemMarginBottom = this.itemHeight = this.initialItemY = 0, this.options = {}, this.padding = 0, this.pages = [], this.proximate = !1, this.scrollGroup = void 0, this.widthOption = this.totalItemWidth = this.titleHeight = this.symbolWidth = this.symbolHeight = 0, this.chart = o, this.init(o, t);
}
return h.prototype.init = function(o, t) {
this.chart = o, this.setOptions(t), t.enabled && (this.render(), d(this.chart, "endResize", function() {
this.legend.positionCheckboxes();
}), this.proximate ? this.unchartrender = d(this.chart, "render", function() {
this.legend.proximatePositions(), this.legend.positionItems();
}) : this.unchartrender && this.unchartrender());
}, h.prototype.setOptions = function(o) {
var t = a(o.padding, 8);
this.options = o, this.chart.styledMode || (this.itemStyle = o.itemStyle, this.itemHiddenStyle = x(this.itemStyle, o.itemHiddenStyle)), this.itemMarginTop = o.itemMarginTop || 0, this.itemMarginBottom = o.itemMarginBottom || 0, this.padding = t, this.initialItemY = t - 5, this.symbolWidth = a(
o.symbolWidth,
16
), this.pages = [], this.proximate = o.layout === "proximate" && !this.chart.inverted, this.baseline = void 0;
}, h.prototype.update = function(o, t) {
var s = this.chart;
this.setOptions(x(!0, this.options, o)), this.destroy(), s.isDirtyLegend = s.isDirtyBox = !0, a(t, !0) && s.redraw(), b(this, "afterUpdate");
}, h.prototype.colorizeItem = function(o, t) {
if (o.legendGroup[t ? "removeClass" : "addClass"]("highcharts-legend-item-hidden"), !this.chart.styledMode) {
var s = this.options, n = o.legendItem, A = o.legendLine, _ = o.legendSymbol, D = this.itemHiddenStyle.color;
s = t ? s.itemStyle.color : D;
var W = t && o.color || D, P = o.options && o.options.marker, X = { fill: W };
n && n.css({ fill: s, color: s }), A && A.attr({ stroke: W }), _ && (P && _.isMarker && (X = o.pointAttribs(), t || (X.stroke = X.fill = D)), _.attr(X));
}
b(this, "afterColorizeItem", { item: o, visible: t });
}, h.prototype.positionItems = function() {
this.allItems.forEach(this.positionItem, this), this.chart.isResizing || this.positionCheckboxes();
}, h.prototype.positionItem = function(o) {
var t = this, s = this.options, n = s.symbolPadding, A = !s.rtl, _ = o._legendItemPos;
s = _[0], _ = _[1];
var D = o.checkbox, W = o.legendGroup;
W && W.element && (n = { translateX: A ? s : this.legendWidth - s - 2 * n - 4, translateY: _ }, A = function() {
b(t, "afterPositionItem", { item: o });
}, O(W.translateY) ? W.animate(n, void 0, A) : (W.attr(n), A())), D && (D.x = s, D.y = _);
}, h.prototype.destroyItem = function(o) {
var t = o.checkbox;
["legendItem", "legendLine", "legendSymbol", "legendGroup"].forEach(function(s) {
o[s] && (o[s] = o[s].destroy());
}), t && B(o.checkbox);
}, h.prototype.destroy = function() {
function o(t) {
this[t] && (this[t] = this[t].destroy());
}
this.getAllItems().forEach(function(t) {
[
"legendItem",
"legendGroup"
].forEach(o, t);
}), "clipRect up down pager nav box title group".split(" ").forEach(o, this), this.display = null;
}, h.prototype.positionCheckboxes = function() {
var o = this.group && this.group.alignAttr, t = this.clipHeight || this.legendHeight, s = this.titleHeight;
if (o) {
var n = o.translateY;
this.allItems.forEach(function(A) {
var _ = A.checkbox;
if (_) {
var D = n + s + _.y + (this.scrollOffset || 0) + 3;
T(_, { left: o.translateX + A.checkboxOffset + _.x - 20 + "px", top: D + "px", display: this.proximate || D > n - 6 && D < n + t - 6 ? "" : "none" });
}
}, this);
}
}, h.prototype.renderTitle = function() {
var o = this.options, t = this.padding, s = o.title, n = 0;
s.text && (this.title || (this.title = this.chart.renderer.label(s.text, t - 3, t - 4, null, null, null, o.useHTML, null, "legend-title").attr({ zIndex: 1 }), this.chart.styledMode || this.title.css(s.style), this.title.add(this.group)), s.width || this.title.css({ width: this.maxLegendWidth + "px" }), o = this.title.getBBox(), n = o.height, this.offsetWidth = o.width, this.contentGroup.attr({ translateY: n })), this.titleHeight = n;
}, h.prototype.setText = function(o) {
var t = this.options;
o.legendItem.attr({ text: t.labelFormat ? R(t.labelFormat, o, this.chart) : t.labelFormatter.call(o) });
}, h.prototype.renderItem = function(o) {
var t = this.chart, s = t.renderer, n = this.options, A = this.symbolWidth, _ = n.symbolPadding || 0, D = this.itemStyle, W = this.itemHiddenStyle, P = n.layout === "horizontal" ? a(n.itemDistance, 20) : 0, X = !n.rtl, g = !o.series, m = !g && o.series.drawLegendSymbol ? o.series : o, L = m.options, Y = this.createCheckboxForItem && L && L.showCheckbox, V = n.useHTML, Q = o.options.className, k = o.legendItem;
L = A + _ + P + (Y ? 20 : 0), k || (o.legendGroup = s.g("legend-item").addClass("highcharts-" + m.type + "-series highcharts-color-" + o.colorIndex + (Q ? " " + Q : "") + (g ? " highcharts-series-" + o.index : "")).attr({ zIndex: 1 }).add(this.scrollGroup), o.legendItem = k = s.text("", X ? A + _ : -_, this.baseline || 0, V), t.styledMode || k.css(x(o.visible ? D : W)), k.attr({ align: X ? "left" : "right", zIndex: 2 }).add(o.legendGroup), this.baseline || (this.fontMetrics = s.fontMetrics(t.styledMode ? 12 : D.fontSize, k), this.baseline = this.fontMetrics.f + 3 + this.itemMarginTop, k.attr("y", this.baseline), this.symbolHeight = n.symbolHeight || this.fontMetrics.f, n.squareSymbol && (this.symbolWidth = a(n.symbolWidth, Math.max(this.symbolHeight, 16)), L = this.symbolWidth + _ + P + (Y ? 20 : 0), X && k.attr("x", this.symbolWidth + _))), m.drawLegendSymbol(this, o), this.setItemEvents && this.setItemEvents(o, k, V)), Y && !o.checkbox && this.createCheckboxForItem && this.createCheckboxForItem(o), this.colorizeItem(o, o.visible), !t.styledMode && D.width || k.css({ width: (n.itemWidth || this.widthOption || t.spacingBox.width) - L + "px" }), this.setText(o), t = k.getBBox(), s = this.fontMetrics && this.fontMetrics.h || 0, o.itemWidth = o.checkboxOffset = n.itemWidth || o.legendItemWidth || t.width + L, this.maxItemWidth = Math.max(this.maxItemWidth, o.itemWidth), this.totalItemWidth += o.itemWidth, this.itemHeight = o.itemHeight = Math.round(o.legendItemHeight || (t.height > 1.5 * s ? t.height : s));
}, h.prototype.layoutItem = function(o) {
var t = this.options, s = this.padding, n = t.layout === "horizontal", A = o.itemHeight, _ = this.itemMarginBottom, D = this.itemMarginTop, W = n ? a(t.itemDistance, 20) : 0, P = this.maxLegendWidth;
t = t.alignColumns && this.totalItemWidth > P ? this.maxItemWidth : o.itemWidth, n && this.itemX - s + t > P && (this.itemX = s, this.lastLineHeight && (this.itemY += D + this.lastLineHeight + _), this.lastLineHeight = 0), this.lastItemY = D + this.itemY + _, this.lastLineHeight = Math.max(A, this.lastLineHeight), o._legendItemPos = [this.itemX, this.itemY], n ? this.itemX += t : (this.itemY += D + A + _, this.lastLineHeight = A), this.offsetWidth = this.widthOption || Math.max((n ? this.itemX - s - (o.checkbox ? 0 : W) : t) + s, this.offsetWidth);
}, h.prototype.getAllItems = function() {
var o = [];
return this.chart.series.forEach(function(t) {
var s = t && t.options;
t && a(s.showInLegend, O(s.linkedTo) ? !1 : void 0, !0) && (o = o.concat(t.legendItems || (s.legendType === "point" ? t.data : t)));
}), b(this, "afterGetAllItems", { allItems: o }), o;
}, h.prototype.getAlignment = function() {
var o = this.options;
return this.proximate ? o.align.charAt(0) + "tv" : o.floating ? "" : o.align.charAt(0) + o.verticalAlign.charAt(0) + o.layout.charAt(0);
}, h.prototype.adjustMargins = function(o, t) {
var s = this.chart, n = this.options, A = this.getAlignment();
A && [/(lth|ct|rth)/, /(rtv|rm|rbv)/, /(rbh|cb|lbh)/, /(lbv|lm|ltv)/].forEach(function(_, D) {
_.test(A) && !O(o[D]) && (s[S[D]] = Math.max(s[S[D]], s.legend[(D + 1) % 2 ? "legendHeight" : "legendWidth"] + [1, -1, -1, 1][D] * n[D % 2 ? "x" : "y"] + a(n.margin, 12) + t[D] + (s.titleOffset[D] || 0)));
});
}, h.prototype.proximatePositions = function() {
var o = this.chart, t = [], s = this.options.align === "left";
this.allItems.forEach(function(n) {
var A, _ = s;
if (n.yAxis) {
n.xAxis.options.reversed && (_ = !_), n.points && (A = C(_ ? n.points : n.points.slice(0).reverse(), function(W) {
return w(W.plotY);
})), _ = this.itemMarginTop + n.legendItem.getBBox().height + this.itemMarginBottom;
var D = n.yAxis.top - o.plotTop;
n.visible ? (A = A ? A.plotY : n.yAxis.height, A += D - 0.3 * _) : A = D + n.yAxis.height, t.push({ target: A, size: _, item: n });
}
}, this), v(t, o.plotHeight).forEach(function(n) {
n.item._legendItemPos && (n.item._legendItemPos[1] = o.plotTop - o.spacing[0] + n.pos);
});
}, h.prototype.render = function() {
var o = this.chart, t = o.renderer, s = this.options, n = this.padding, A = this.getAllItems(), _ = this.group, D = this.box;
this.itemX = n, this.itemY = this.initialItemY, this.lastItemY = this.offsetWidth = 0, this.widthOption = c(s.width, o.spacingBox.width - n);
var W = o.spacingBox.width - 2 * n - s.x;
-1 < ["rm", "lm"].indexOf(this.getAlignment().substring(0, 2)) && (W /= 2), this.maxLegendWidth = this.widthOption || W, _ || (this.group = _ = t.g("legend").addClass(s.className || "").attr({ zIndex: 7 }).add(), this.contentGroup = t.g().attr({ zIndex: 1 }).add(_), this.scrollGroup = t.g().add(this.contentGroup)), this.renderTitle(), p(A, function(X, g) {
return (X.options && X.options.legendIndex || 0) - (g.options && g.options.legendIndex || 0);
}), s.reversed && A.reverse(), this.allItems = A, this.display = W = !!A.length, this.itemHeight = this.totalItemWidth = this.maxItemWidth = this.lastLineHeight = 0, A.forEach(this.renderItem, this), A.forEach(this.layoutItem, this), A = (this.widthOption || this.offsetWidth) + n;
var P = this.lastItemY + this.lastLineHeight + this.titleHeight;
P = this.handleOverflow(P), P += n, D || (this.box = D = t.rect().addClass("highcharts-legend-box").attr({ r: s.borderRadius }).add(_), D.isNew = !0), o.styledMode || D.attr({ stroke: s.borderColor, "stroke-width": s.borderWidth || 0, fill: s.backgroundColor || "none" }).shadow(s.shadow), 0 < A && 0 < P && (D[D.isNew ? "attr" : "animate"](D.crisp.call({}, { x: 0, y: 0, width: A, height: P }, D.strokeWidth())), D.isNew = !1), D[W ? "show" : "hide"](), o.styledMode && _.getStyle("display") === "none" && (A = P = 0), this.legendWidth = A, this.legendHeight = P, W && this.align(), this.proximate || this.positionItems(), b(this, "afterRender");
}, h.prototype.align = function(o) {
o === void 0 && (o = this.chart.spacingBox);
var t = this.chart, s = this.options, n = o.y;
/(lth|ct|rth)/.test(this.getAlignment()) && 0 < t.titleOffset[0] ? n += t.titleOffset[0] : /(lbh|cb|rbh)/.test(this.getAlignment()) && 0 < t.titleOffset[2] && (n -= t.titleOffset[2]), n !== o.y && (o = x(o, { y: n })), this.group.align(x(s, { width: this.legendWidth, height: this.legendHeight, verticalAlign: this.proximate ? "top" : s.verticalAlign }), !0, o);
}, h.prototype.handleOverflow = function(o) {
var t = this, s = this.chart, n = s.renderer, A = this.options, _ = A.y, D = A.verticalAlign === "top", W = this.padding, P = A.maxHeight, X = A.navigation, g = a(X.animation, !0), m = X.arrowSize || 12, L = this.pages, Y = this.allItems, V = function(q) {
typeof q == "number" ? $.attr({ height: q }) : $ && (t.clipRect = $.destroy(), t.contentGroup.clip()), t.contentGroup.div && (t.contentGroup.div.style.clip = q ? "rect(" + W + "px,9999px," + (W + q) + "px,0)" : "auto");
}, Q = function(q) {
return t[q] = n.circle(0, 0, 1.3 * m).translate(m / 2, m / 2).add(z), s.styledMode || t[q].attr("fill", "rgba(0,0,0,0.0001)"), t[q];
}, k, G;
_ = s.spacingBox.height + (D ? -_ : _) - W;
var z = this.nav, $ = this.clipRect;
return A.layout !== "horizontal" || A.verticalAlign === "middle" || A.floating || (_ /= 2), P && (_ = Math.min(_, P)), L.length = 0, o && 0 < _ && o > _ && X.enabled !== !1 ? (this.clipHeight = k = Math.max(_ - 20 - this.titleHeight - W, 0), this.currentPage = a(this.currentPage, 1), this.fullHeight = o, Y.forEach(function(q, it) {
var et = q._legendItemPos[1], nt = Math.round(q.legendItem.getBBox().height), rt = L.length;
(!rt || et - L[rt - 1] > k && (G || et) !== L[rt - 1]) && (L.push(G || et), rt++), q.pageIx = rt - 1, G && (Y[it - 1].pageIx = rt - 1), it === Y.length - 1 && et + nt - L[rt - 1] > k && nt <= k && (L.push(et), q.pageIx = rt), et !== G && (G = et);
}), $ || ($ = t.clipRect = n.clipRect(0, W, 9999, 0), t.contentGroup.clip($)), V(k), z || (this.nav = z = n.g().attr({ zIndex: 1 }).add(this.group), this.up = n.symbol("triangle", 0, 0, m, m).add(z), Q("upTracker").on(
"click",
function() {
t.scroll(-1, g);
}
), this.pager = n.text("", 15, 10).addClass("highcharts-legend-navigation"), s.styledMode || this.pager.css(X.style), this.pager.add(z), this.down = n.symbol("triangle-down", 0, 0, m, m).add(z), Q("downTracker").on("click", function() {
t.scroll(1, g);
})), t.scroll(0), o = _) : z && (V(), this.nav = z.destroy(), this.scrollGroup.attr({ translateY: 1 }), this.clipHeight = 0), o;
}, h.prototype.scroll = function(o, t) {
var s = this, n = this.chart, A = this.pages, _ = A.length, D = this.clipHeight, W = this.options.navigation, P = this.pager, X = this.padding, g = this.currentPage + o;
g > _ && (g = _), 0 < g && (typeof t < "u" && N(t, n), this.nav.attr({ translateX: X, translateY: D + this.padding + 7 + this.titleHeight, visibility: "visible" }), [this.up, this.upTracker].forEach(function(m) {
m.attr({ class: g === 1 ? "highcharts-legend-nav-inactive" : "highcharts-legend-nav-active" });
}), P.attr({ text: g + "/" + _ }), [this.down, this.downTracker].forEach(
function(m) {
m.attr({ x: 18 + this.pager.getBBox().width, class: g === _ ? "highcharts-legend-nav-inactive" : "highcharts-legend-nav-active" });
},
this
), n.styledMode || (this.up.attr({ fill: g === 1 ? W.inactiveColor : W.activeColor }), this.upTracker.css({ cursor: g === 1 ? "default" : "pointer" }), this.down.attr({ fill: g === _ ? W.inactiveColor : W.activeColor }), this.downTracker.css({ cursor: g === _ ? "default" : "pointer" })), this.scrollOffset = -A[g - 1] + this.initialItemY, this.scrollGroup.animate({ translateY: this.scrollOffset }), this.currentPage = g, this.positionCheckboxes(), o = F(a(t, n.renderer.globalAnimation, !0)), i(function() {
b(s, "afterScroll", { currentPage: g });
}, o.duration));
}, h.prototype.setItemEvents = function(o, t, s) {
var n = this, A = n.chart.renderer.boxWrapper, _ = o instanceof Z, D = "highcharts-legend-" + (_ ? "point" : "series") + "-active", W = n.chart.styledMode, P = function(X) {
n.allItems.forEach(function(g) {
o !== g && [g].concat(g.linkedSeries || []).forEach(function(m) {
m.setState(X, !_);
});
});
};
(s ? [t, o.legendSymbol] : [o.legendGroup]).forEach(function(X) {
X && X.on("mouseover", function() {
o.visible && P("inactive"), o.setState("hover"), o.visible && A.addClass(D), W || t.css(n.options.itemHoverStyle);
}).on("mouseout", function() {
n.chart.styledMode || t.css(x(o.visible ? n.itemStyle : n.itemHiddenStyle)), P(""), A.removeClass(D), o.setState();
}).on("click", function(g) {
var m = function() {
o.setVisible && o.setVisible(), P(o.visible ? "inactive" : "");
};
A.removeClass(D), g = { browserEvent: g }, o.firePointEvent ? o.firePointEvent("legendItemClick", g, m) : b(o, "legendItemClick", g, m);
});
});
}, h.prototype.createCheckboxForItem = function(o) {
o.checkbox = u(
"input",
{ type: "checkbox", className: "highcharts-legend-checkbox", checked: o.selected, defaultChecked: o.selected },
this.options.itemCheckboxStyle,
this.chart.container
), d(o.checkbox, "click", function(t) {
b(o.series || o, "checkboxClick", { checked: t.target.checked, item: o }, function() {
o.select();
});
});
}, h;
}(), (/Trident\/7\.0/.test(I.navigator && I.navigator.userAgent) || y) && H(U.prototype, "positionItem", function(h, o) {
var t = this, s = function() {
o._legendItemPos && h.call(t, o);
};
s(), t.bubbleLegend || setTimeout(s);
}), U;
}), E(
l,
"Core/Series/SeriesRegistry.js",
[l["Core/Globals.js"], l["Core/DefaultOptions.js"], l["Core/Series/Point.js"], l["Core/Utilities.js"]],
function(y, j, I, Z) {
var H = j.defaultOptions, U = Z.error, F = Z.extendClass, N = Z.merge, R;
return function(S) {
function v(d, u) {
var T = H.plotOptions || {}, O = u.defaultOptions;
u.prototype.pointClass || (u.prototype.pointClass = I), u.prototype.type = d, O && (T[d] = O), S.seriesTypes[d] = u;
}
S.seriesTypes = y.seriesTypes, S.getSeries = function(d, u) {
u === void 0 && (u = {});
var T = d.options.chart;
T = u.type || T.type || T.defaultSeriesType || "";
var O = S.seriesTypes[T];
return S || U(17, !0, d, { missingModuleFor: T }), T = new O(), typeof T.init == "function" && T.init(d, u), T;
}, S.registerSeriesType = v, S.seriesType = function(d, u, T, O, B) {
var C = H.plotOptions || {};
return u = u || "", C[d] = N(C[u], T), v(d, F(S.seriesTypes[u] || function() {
}, O)), S.seriesTypes[d].prototype.type = d, B && (S.seriesTypes[d].prototype.pointClass = F(I, B)), S.seriesTypes[d];
};
}(R || (R = {})), R;
}
), E(l, "Core/Chart/Chart.js", [
l["Core/Animation/AnimationUtilities.js"],
l["Core/Axis/Axis.js"],
l["Core/FormatUtilities.js"],
l["Core/Foundation.js"],
l["Core/Globals.js"],
l["Core/Legend/Legend.js"],
l["Core/MSPointer.js"],
l["Core/DefaultOptions.js"],
l["Core/Pointer.js"],
l["Core/Renderer/RendererRegistry.js"],
l["Core/Series/SeriesRegistry.js"],
l["Core/Renderer/SVG/SVGRenderer.js"],
l["Core/Time.js"],
l["Core/Utilities.js"],
l["Core/Renderer/HTML/AST.js"]
], function(y, j, I, Z, H, U, F, N, R, S, v, d, u, T, O) {
var B = y.animate, C = y.animObject, b = y.setAnimation, w = I.numberFormat, x = Z.registerEventOptions, a = H.charts, c = H.doc, p = H.marginNames, i = H.svg, h = H.win, o = N.defaultOptions, t = N.defaultTime, s = v.seriesTypes, n = T.addEvent, A = T.attr, _ = T.cleanRecursively, D = T.createElement, W = T.css, P = T.defined, X = T.discardElement, g = T.erase, m = T.error, L = T.extend, Y = T.find, V = T.fireEvent, Q = T.getStyle, k = T.isArray, G = T.isNumber, z = T.isObject, $ = T.isString, q = T.merge, it = T.objectEach, et = T.pick, nt = T.pInt, rt = T.relativeLength, ct = T.removeEvent, gt = T.splat, dt = T.syncTimeout, ht = T.uniqueKey;
return y = function() {
function at(J, tt, ot) {
this.series = this.renderTo = this.renderer = this.pointer = this.pointCount = this.plotWidth = this.plotTop = this.plotLeft = this.plotHeight = this.plotBox = this.options = this.numberFormatter = this.margin = this.legend = this.labelCollectors = this.isResizing = this.index = this.eventOptions = this.container = this.colorCounter = this.clipBox = this.chartWidth = this.chartHeight = this.bounds = this.axisOffset = this.axes = void 0, this.sharedClips = {}, this.yAxis = this.xAxis = this.userOptions = this.titleOffset = this.time = this.symbolCounter = this.spacingBox = this.spacing = void 0, this.getArgs(J, tt, ot);
}
return at.chart = function(J, tt, ot) {
return new at(J, tt, ot);
}, at.prototype.getArgs = function(J, tt, ot) {
$(J) || J.nodeName ? (this.renderTo = J, this.init(tt, ot)) : this.init(J, tt);
}, at.prototype.init = function(J, tt) {
var ot = J.plotOptions || {};
V(this, "init", { args: arguments }, function() {
var lt = q(o, J), pt = lt.chart;
it(lt.plotOptions, function(yt, vt) {
z(yt) && (yt.tooltip = ot[vt] && q(ot[vt].tooltip) || void 0);
}), lt.tooltip.userOptions = J.chart && J.chart.forExport && J.tooltip.userOptions || J.tooltip, this.userOptions = J, this.margin = [], this.spacing = [], this.bounds = { h: {}, v: {} }, this.labelCollectors = [], this.callback = tt, this.isResizing = 0, this.options = lt, this.axes = [], this.series = [], this.time = J.time && Object.keys(J.time).length ? new u(J.time) : H.time, this.numberFormatter = pt.numberFormatter || w, this.styledMode = pt.styledMode, this.hasCartesianSeries = pt.showAxes, this.index = a.length, a.push(this), H.chartCount++, x(this, pt), this.xAxis = [], this.yAxis = [], this.pointCount = this.colorCounter = this.symbolCounter = 0, V(this, "afterInit"), this.firstRender();
});
}, at.prototype.initSeries = function(J) {
var tt = this.options.chart;
tt = J.type || tt.type || tt.defaultSeriesType;
var ot = s[tt];
return ot || m(17, !0, this, { missingModuleFor: tt }), tt = new ot(), typeof tt.init == "function" && tt.init(this, J), tt;
}, at.prototype.setSeriesData = function() {
this.getSeriesOrderByLinks().forEach(function(J) {
J.points || J.data || !J.enabledDataSorting || J.setData(J.options.data, !1);
});
}, at.prototype.getSeriesOrderByLinks = function() {
return this.series.concat().sort(function(J, tt) {
return J.linkedSeries.length || tt.linkedSeries.length ? tt.linkedSeries.length - J.linkedSeries.length : 0;
});
}, at.prototype.orderSeries = function(J) {
var tt = this.series;
J = J || 0;
for (var ot = tt.length; J < ot; ++J)
tt[J] && (tt[J].index = J, tt[J].name = tt[J].getName());
}, at.prototype.isInsidePlot = function(J, tt, ot) {
ot === void 0 && (ot = {});
var lt = this.inverted, pt = this.plotBox, yt = this.plotLeft, vt = this.plotTop, Ct = this.scrollablePlotBox, Pt = 0, At = 0;
ot.visiblePlotOnly && this.scrollingContainer && (At = this.scrollingContainer, Pt = At.scrollLeft, At = At.scrollTop);
var St = ot.series;
if (pt = ot.visiblePlotOnly && Ct || pt, Ct = ot.inverted ? tt : J, tt = ot.inverted ? J : tt, J = { x: Ct, y: tt, isInsidePlot: !0 }, !ot.ignoreX) {
var Dt = St && (lt ? St.yAxis : St.xAxis) || { pos: yt, len: 1 / 0 };
Ct = ot.paneCoordinates ? Dt.pos + Ct : yt + Ct, Ct >= Math.max(Pt + yt, Dt.pos) && Ct <= Math.min(Pt + yt + pt.width, Dt.pos + Dt.len) || (J.isInsidePlot = !1);
}
return !ot.ignoreY && J.isInsidePlot && (lt = St && (lt ? St.xAxis : St.yAxis) || { pos: vt, len: 1 / 0 }, ot = ot.paneCoordinates ? lt.pos + tt : vt + tt, ot >= Math.max(At + vt, lt.pos) && ot <= Math.min(At + vt + pt.height, lt.pos + lt.len) || (J.isInsidePlot = !1)), V(this, "afterIsInsidePlot", J), J.isInsidePlot;
}, at.prototype.redraw = function(J) {
V(this, "beforeRedraw");
var tt = this.hasCartesianSeries ? this.axes : this.colorAxis || [], ot = this.series, lt = this.pointer, pt = this.legend, yt = this.userOptions.legend, vt = this.renderer, Ct = vt.isHidden(), Pt = [], At = this.isDirtyBox, St = this.isDirtyLegend;
for (this.setResponsive && this.setResponsive(!1), b(this.hasRendered ? J : !1, this), Ct && this.temporaryDisplay(), this.layOutTitles(), J = ot.length; J--; ) {
var Dt = ot[J];
if (Dt.options.stacking || Dt.options.centerInCategory) {
var Lt = !0;
if (Dt.isDirty) {
var Nt = !0;
break;
}
}
}
if (Nt)
for (J = ot.length; J--; )
Dt = ot[J], Dt.options.stacking && (Dt.isDirty = !0);
ot.forEach(function(Et) {
Et.isDirty && (Et.options.legendType === "point" ? (typeof Et.updateTotals == "function" && Et.updateTotals(), St = !0) : yt && (yt.labelFormatter || yt.labelFormat) && (St = !0)), Et.isDirtyData && V(Et, "updatedData");
}), St && pt && pt.options.enabled && (pt.render(), this.isDirtyLegend = !1), Lt && this.getStacks(), tt.forEach(function(Et) {
Et.updateNames(), Et.setScale();
}), this.getMargins(), tt.forEach(function(Et) {
Et.isDirty && (At = !0);
}), tt.forEach(function(Et) {
var Kt = Et.min + "," + Et.max;
Et.extKey !== Kt && (Et.extKey = Kt, Pt.push(function() {
V(Et, "afterSetExtremes", L(Et.eventArgs, Et.getExtremes())), delete Et.eventArgs;
})), (At || Lt) && Et.redraw();
}), At && this.drawChartBox(), V(this, "predraw"), ot.forEach(function(Et) {
(At || Et.isDirty) && Et.visible && Et.redraw(), Et.isDirtyData = !1;
}), lt && lt.reset(!0), vt.draw(), V(this, "redraw"), V(this, "render"), Ct && this.temporaryDisplay(!0), Pt.forEach(function(Et) {
Et.call();
});
}, at.prototype.get = function(J) {
function tt(yt) {
return yt.id === J || yt.options && yt.options.id === J;
}
for (var ot = this.series, lt = Y(this.axes, tt) || Y(this.series, tt), pt = 0; !lt && pt < ot.length; pt++)
lt = Y(ot[pt].points || [], tt);
return lt;
}, at.prototype.getAxes = function() {
var J = this, tt = this.options, ot = tt.xAxis = gt(tt.xAxis || {});
tt = tt.yAxis = gt(tt.yAxis || {}), V(this, "getAxes"), ot.forEach(function(lt, pt) {
lt.index = pt, lt.isX = !0;
}), tt.forEach(function(lt, pt) {
lt.index = pt;
}), ot.concat(tt).forEach(function(lt) {
new j(J, lt);
}), V(this, "afterGetAxes");
}, at.prototype.getSelectedPoints = function() {
return this.series.reduce(function(J, tt) {
return tt.getPointsCollection().forEach(function(ot) {
et(ot.selectedStaging, ot.selected) && J.push(ot);
}), J;
}, []);
}, at.prototype.getSelectedSeries = function() {
return this.series.filter(function(J) {
return J.selected;
});
}, at.prototype.setTitle = function(J, tt, ot) {
this.applyDescription("title", J), this.applyDescription("subtitle", tt), this.applyDescription("caption", void 0), this.layOutTitles(ot);
}, at.prototype.applyDescription = function(J, tt) {
var ot = this, lt = J === "title" ? { color: "#333333", fontSize: this.options.isStock ? "16px" : "18px" } : { color: "#666666" };
lt = this.options[J] = q(!this.styledMode && { style: lt }, this.options[J], tt);
var pt = this[J];
pt && tt && (this[J] = pt = pt.destroy()), lt && !pt && (pt = this.renderer.text(lt.text, 0, 0, lt.useHTML).attr({ align: lt.align, class: "highcharts-" + J, zIndex: lt.zIndex || 4 }).add(), pt.update = function(yt) {
ot[{ title: "setTitle", subtitle: "setSubtitle", caption: "setCaption" }[J]](yt);
}, this.styledMode || pt.css(lt.style), this[J] = pt);
}, at.prototype.layOutTitles = function(J) {
var tt = [0, 0, 0], ot = this.renderer, lt = this.spacingBox;
["title", "subtitle", "caption"].forEach(function(yt) {
var vt = this[yt], Ct = this.options[yt], Pt = Ct.verticalAlign || "top";
yt = yt === "title" ? Pt === "top" ? -3 : 0 : Pt === "top" ? tt[0] + 2 : 0;
var At;
if (vt) {
this.styledMode || (At = Ct.style && Ct.style.fontSize), At = ot.fontMetrics(At, vt).b, vt.css({ width: (Ct.width || lt.width + (Ct.widthAdjust || 0)) + "px" });
var St = Math.round(vt.getBBox(Ct.useHTML).height);
vt.align(
L({ y: Pt === "bottom" ? At : yt + At, height: St }, Ct),
!1,
"spacingBox"
), Ct.floating || (Pt === "top" ? tt[0] = Math.ceil(tt[0] + St) : Pt === "bottom" && (tt[2] = Math.ceil(tt[2] + St)));
}
}, this), tt[0] && (this.options.title.verticalAlign || "top") === "top" && (tt[0] += this.options.title.margin), tt[2] && this.options.caption.verticalAlign === "bottom" && (tt[2] += this.options.caption.margin);
var pt = !this.titleOffset || this.titleOffset.join(",") !== tt.join(",");
this.titleOffset = tt, V(this, "afterLayOutTitles"), !this.isDirtyBox && pt && (this.isDirtyBox = this.isDirtyLegend = pt, this.hasRendered && et(J, !0) && this.isDirtyBox && this.redraw());
}, at.prototype.getChartSize = function() {
var J = this.options.chart, tt = J.width;
J = J.height;
var ot = this.renderTo;
P(tt) || (this.containerWidth = Q(ot, "width")), P(J) || (this.containerHeight = Q(ot, "height")), this.chartWidth = Math.max(0, tt || this.containerWidth || 600), this.chartHeight = Math.max(0, rt(J, this.chartWidth) || (1 < this.containerHeight ? this.containerHeight : 400));
}, at.prototype.temporaryDisplay = function(J) {
var tt = this.renderTo;
if (J)
for (; tt && tt.style; )
tt.hcOrigStyle && (W(tt, tt.hcOrigStyle), delete tt.hcOrigStyle), tt.hcOrigDetached && (c.body.removeChild(tt), tt.hcOrigDetached = !1), tt = tt.parentNode;
else
for (; tt && tt.style && (c.body.contains(tt) || tt.parentNode || (tt.hcOrigDetached = !0, c.body.appendChild(tt)), (Q(tt, "display", !1) === "none" || tt.hcOricDetached) && (tt.hcOrigStyle = { display: tt.style.display, height: tt.style.height, overflow: tt.style.overflow }, J = { display: "block", overflow: "hidden" }, tt !== this.renderTo && (J.height = 0), W(tt, J), tt.offsetWidth || tt.style.setProperty("display", "block", "important")), tt = tt.parentNode, tt !== c.body); )
;
}, at.prototype.setClassName = function(J) {
this.container.className = "highcharts-container " + (J || "");
}, at.prototype.getContainer = function() {
var J = this.options, tt = J.chart, ot = ht(), lt, pt = this.renderTo;
pt || (this.renderTo = pt = tt.renderTo), $(pt) && (this.renderTo = pt = c.getElementById(pt)), pt || m(13, !0, this);
var yt = nt(A(pt, "data-highcharts-chart"));
G(yt) && a[yt] && a[yt].hasRendered && a[yt].destroy(), A(pt, "data-highcharts-chart", this.index), pt.innerHTML = O.emptyHTML, tt.skipClone || pt.offsetWidth || this.temporaryDisplay(), this.getChartSize(), yt = this.chartWidth;
var vt = this.chartHeight;
if (W(pt, { overflow: "hidden" }), this.styledMode || (lt = L({ position: "relative", overflow: "hidden", width: yt + "px", height: vt + "px", textAlign: "left", lineHeight: "normal", zIndex: 0, "-webkit-tap-highlight-color": "rgba(0,0,0,0)", userSelect: "none", "touch-action": "manipulation", outline: "none" }, tt.style || {})), this.container = ot = D("div", { id: ot }, lt, pt), this._cursor = ot.style.cursor, this.renderer = new (tt.renderer || !i ? S.getRendererType(tt.renderer) : d)(ot, yt, vt, void 0, tt.forExport, J.exporting && J.exporting.allowHTML, this.styledMode), b(
void 0,
this
), this.setClassName(tt.className), this.styledMode)
for (var Ct in J.defs)
this.renderer.definition(J.defs[Ct]);
else
this.renderer.setStyle(tt.style);
this.renderer.chartIndex = this.index, V(this, "afterGetContainer");
}, at.prototype.getMargins = function(J) {
var tt = this.spacing, ot = this.margin, lt = this.titleOffset;
this.resetMargins(), lt[0] && !P(ot[0]) && (this.plotTop = Math.max(this.plotTop, lt[0] + tt[0])), lt[2] && !P(ot[2]) && (this.marginBottom = Math.max(this.marginBottom, lt[2] + tt[2])), this.legend && this.legend.display && this.legend.adjustMargins(
ot,
tt
), V(this, "getMargins"), J || this.getAxisMargins();
}, at.prototype.getAxisMargins = function() {
var J = this, tt = J.axisOffset = [0, 0, 0, 0], ot = J.colorAxis, lt = J.margin, pt = function(yt) {
yt.forEach(function(vt) {
vt.visible && vt.getOffset();
});
};
J.hasCartesianSeries ? pt(J.axes) : ot && ot.length && pt(ot), p.forEach(function(yt, vt) {
P(lt[vt]) || (J[yt] += tt[vt]);
}), J.setChartSize();
}, at.prototype.reflow = function(J) {
var tt = this, ot = tt.options.chart, lt = tt.renderTo, pt = P(ot.width) && P(ot.height), yt = ot.width || Q(lt, "width");
ot = ot.height || Q(lt, "height"), lt = J ? J.target : h, delete tt.pointer.chartPosition, !pt && !tt.isPrinting && yt && ot && (lt === h || lt === c) && ((yt !== tt.containerWidth || ot !== tt.containerHeight) && (T.clearTimeout(tt.reflowTimeout), tt.reflowTimeout = dt(function() {
tt.container && tt.setSize(void 0, void 0, !1);
}, J ? 100 : 0)), tt.containerWidth = yt, tt.containerHeight = ot);
}, at.prototype.setReflow = function(J) {
var tt = this;
J === !1 || this.unbindReflow ? J === !1 && this.unbindReflow && (this.unbindReflow = this.unbindReflow()) : (this.unbindReflow = n(h, "resize", function(ot) {
tt.options && tt.reflow(ot);
}), n(this, "destroy", this.unbindReflow));
}, at.prototype.setSize = function(J, tt, ot) {
var lt = this, pt = lt.renderer;
lt.isResizing += 1, b(ot, lt), ot = pt.globalAnimation, lt.oldChartHeight = lt.chartHeight, lt.oldChartWidth = lt.chartWidth, typeof J < "u" && (lt.options.chart.width = J), typeof tt < "u" && (lt.options.chart.height = tt), lt.getChartSize(), lt.styledMode || (ot ? B : W)(lt.container, { width: lt.chartWidth + "px", height: lt.chartHeight + "px" }, ot), lt.setChartSize(!0), pt.setSize(lt.chartWidth, lt.chartHeight, ot), lt.axes.forEach(function(yt) {
yt.isDirty = !0, yt.setScale();
}), lt.isDirtyLegend = !0, lt.isDirtyBox = !0, lt.layOutTitles(), lt.getMargins(), lt.redraw(ot), lt.oldChartHeight = null, V(lt, "resize"), dt(function() {
lt && V(lt, "endResize", null, function() {
--lt.isResizing;
});
}, C(ot).duration);
}, at.prototype.setChartSize = function(J) {
var tt = this.inverted, ot = this.renderer, lt = this.chartWidth, pt = this.chartHeight, yt = this.options.chart, vt = this.spacing, Ct = this.clipOffset, Pt, At, St, Dt;
this.plotLeft = Pt = Math.round(this.plotLeft), this.plotTop = At = Math.round(this.plotTop), this.plotWidth = St = Math.max(0, Math.round(lt - Pt - this.marginRight)), this.plotHeight = Dt = Math.max(0, Math.round(pt - At - this.marginBottom)), this.plotSizeX = tt ? Dt : St, this.plotSizeY = tt ? St : Dt, this.plotBorderWidth = yt.plotBorderWidth || 0, this.spacingBox = ot.spacingBox = { x: vt[3], y: vt[0], width: lt - vt[3] - vt[1], height: pt - vt[0] - vt[2] }, this.plotBox = ot.plotBox = { x: Pt, y: At, width: St, height: Dt }, tt = 2 * Math.floor(this.plotBorderWidth / 2), lt = Math.ceil(Math.max(tt, Ct[3]) / 2), pt = Math.ceil(Math.max(tt, Ct[0]) / 2), this.clipBox = { x: lt, y: pt, width: Math.floor(this.plotSizeX - Math.max(tt, Ct[1]) / 2 - lt), height: Math.max(0, Math.floor(this.plotSizeY - Math.max(tt, Ct[2]) / 2 - pt)) }, J || (this.axes.forEach(function(Lt) {
Lt.setAxisSize(), Lt.setAxisTranslation();
}), ot.alignElements()), V(this, "afterSetChartSize", { skipAxes: J });
}, at.prototype.resetMargins = function() {
V(this, "resetMargins");
var J = this, tt = J.options.chart;
["margin", "spacing"].forEach(function(ot) {
var lt = tt[ot], pt = z(lt) ? lt : [lt, lt, lt, lt];
["Top", "Right", "Bottom", "Left"].forEach(function(yt, vt) {
J[ot][vt] = et(tt[ot + yt], pt[vt]);
});
}), p.forEach(function(ot, lt) {
J[ot] = et(J.margin[lt], J.spacing[lt]);
}), J.axisOffset = [0, 0, 0, 0], J.clipOffset = [0, 0, 0, 0];
}, at.prototype.drawChartBox = function() {
var J = this.options.chart, tt = this.renderer, ot = this.chartWidth, lt = this.chartHeight, pt = this.styledMode, yt = this.plotBGImage, vt = J.backgroundColor, Ct = J.plotBackgroundColor, Pt = J.plotBackgroundImage, At = this.plotLeft, St = this.plotTop, Dt = this.plotWidth, Lt = this.plotHeight, Nt = this.plotBox, Et = this.clipRect, Kt = this.clipBox, Gt = this.chartBackground, Wt = this.plotBackground, Jt = this.plotBorder, be, zt = "animate";
if (Gt || (this.chartBackground = Gt = tt.rect().addClass("highcharts-background").add(), zt = "attr"), pt)
var Vt = be = Gt.strokeWidth();
else
Vt = J.borderWidth || 0, be = Vt + (J.shadow ? 8 : 0), vt = { fill: vt || "none" }, (Vt || Gt["stroke-width"]) && (vt.stroke = J.borderColor, vt["stroke-width"] = Vt), Gt.attr(vt).shadow(J.shadow);
Gt[zt]({ x: be / 2, y: be / 2, width: ot - be - Vt % 2, height: lt - be - Vt % 2, r: J.borderRadius }), zt = "animate", Wt || (zt = "attr", this.plotBackground = Wt = tt.rect().addClass("highcharts-plot-background").add()), Wt[zt](Nt), pt || (Wt.attr({ fill: Ct || "none" }).shadow(J.plotShadow), Pt && (yt ? (Pt !== yt.attr("href") && yt.attr("href", Pt), yt.animate(Nt)) : this.plotBGImage = tt.image(Pt, At, St, Dt, Lt).add())), Et ? Et.animate({ width: Kt.width, height: Kt.height }) : this.clipRect = tt.clipRect(Kt), zt = "animate", Jt || (zt = "attr", this.plotBorder = Jt = tt.rect().addClass("highcharts-plot-border").attr({ zIndex: 1 }).add()), pt || Jt.attr({ stroke: J.plotBorderColor, "stroke-width": J.plotBorderWidth || 0, fill: "none" }), Jt[zt](Jt.crisp({ x: At, y: St, width: Dt, height: Lt }, -Jt.strokeWidth())), this.isDirtyBox = !1, V(this, "afterDrawChartBox");
}, at.prototype.propFromSeries = function() {
var J = this, tt = J.options.chart, ot = J.options.series, lt, pt, yt;
["inverted", "angular", "polar"].forEach(function(vt) {
for (pt = s[tt.type || tt.defaultSeriesType], yt = tt[vt] || pt && pt.prototype[vt], lt = ot && ot.length; !yt && lt--; )
(pt = s[ot[lt].type]) && pt.prototype[vt] && (yt = !0);
J[vt] = yt;
});
}, at.prototype.linkSeries = function() {
var J = this, tt = J.series;
tt.forEach(function(ot) {
ot.linkedSeries.length = 0;
}), tt.forEach(function(ot) {
var lt = ot.options.linkedTo;
$(lt) && (lt = lt === ":previous" ? J.series[ot.index - 1] : J.get(lt)) && lt.linkedParent !== ot && (lt.linkedSeries.push(ot), ot.linkedParent = lt, lt.enabledDataSorting && ot.setDataSortingOptions(), ot.visible = et(ot.options.visible, lt.options.visible, ot.visible));
}), V(this, "afterLinkSeries");
}, at.prototype.renderSeries = function() {
this.series.forEach(function(J) {
J.translate(), J.render();
});
}, at.prototype.renderLabels = function() {
var J = this, tt = J.options.labels;
tt.items && tt.items.forEach(function(ot) {
var lt = L(tt.style, ot.style), pt = nt(lt.left) + J.plotLeft, yt = nt(lt.top) + J.plotTop + 12;
delete lt.left, delete lt.top, J.renderer.text(ot.html, pt, yt).attr({ zIndex: 2 }).css(lt).add();
});
}, at.prototype.render = function() {
var J = this.axes, tt = this.colorAxis, ot = this.renderer, lt = this.options, pt = function(At) {
At.forEach(function(St) {
St.visible && St.render();
});
}, yt = 0;
this.setTitle(), this.legend = new U(this, lt.legend), this.getStacks && this.getStacks(), this.getMargins(!0), this.setChartSize(), lt = this.plotWidth, J.some(function(At) {
if (At.horiz && At.visible && At.options.labels.enabled && At.series.length)
return yt = 21, !0;
});
var vt = this.plotHeight = Math.max(this.plotHeight - yt, 0);
J.forEach(function(At) {
At.setScale();
}), this.getAxisMargins();
var Ct = 1.1 < lt / this.plotWidth, Pt = 1.05 < vt / this.plotHeight;
(Ct || Pt) && (J.forEach(function(At) {
(At.horiz && Ct || !At.horiz && Pt) && At.setTickInterval(!0);
}), this.getMargins()), this.drawChartBox(), this.hasCartesianSeries ? pt(J) : tt && tt.length && pt(tt), this.seriesGroup || (this.seriesGroup = ot.g("series-group").attr({ zIndex: 3 }).add()), this.renderSeries(), this.renderLabels(), this.addCredits(), this.setResponsive && this.setResponsive(), this.hasRendered = !0;
}, at.prototype.addCredits = function(J) {
var tt = this, ot = q(!0, this.options.credits, J);
ot.enabled && !this.credits && (this.credits = this.renderer.text(ot.text + (this.mapCredits || ""), 0, 0).addClass("highcharts-credits").on("click", function() {
ot.href && (h.location.href = ot.href);
}).attr({ align: ot.position.align, zIndex: 8 }), tt.styledMode || this.credits.css(ot.style), this.credits.add().align(ot.position), this.credits.update = function(lt) {
tt.credits = tt.credits.destroy(), tt.addCredits(lt);
});
}, at.prototype.destroy = function() {
var J = this, tt = J.axes, ot = J.series, lt = J.container, pt = lt && lt.parentNode, yt;
for (V(J, "destroy"), J.renderer.forExport ? g(a, J) : a[J.index] = void 0, H.chartCount--, J.renderTo.removeAttribute("data-highcharts-chart"), ct(J), yt = tt.length; yt--; )
tt[yt] = tt[yt].destroy();
for (this.scroller && this.scroller.destroy && this.scroller.destroy(), yt = ot.length; yt--; )
ot[yt] = ot[yt].destroy();
"title subtitle chartBackground plotBackground plotBGImage plotBorder seriesGroup clipRect credits pointer rangeSelector legend resetZoomButton tooltip renderer".split(" ").forEach(function(vt) {
var Ct = J[vt];
Ct && Ct.destroy && (J[vt] = Ct.destroy());
}), lt && (lt.innerHTML = O.emptyHTML, ct(lt), pt && X(lt)), it(J, function(vt, Ct) {
delete J[Ct];
});
}, at.prototype.firstRender = function() {
var J = this, tt = J.options;
(!J.isReadyToRender || J.isReadyToRender()) && (J.getContainer(), J.resetMargins(), J.setChartSize(), J.propFromSeries(), J.getAxes(), (k(tt.series) ? tt.series : []).forEach(function(ot) {
J.initSeries(ot);
}), J.linkSeries(), J.setSeriesData(), V(J, "beforeRender"), R && (F.isRequired() ? J.pointer = new F(J, tt) : J.pointer = new R(J, tt)), J.render(), J.pointer.getChartPosition(), !J.renderer.imgCount && !J.hasLoaded && J.onload(), J.temporaryDisplay(!0));
}, at.prototype.onload = function() {
this.callbacks.concat([this.callback]).forEach(function(J) {
J && typeof this.index < "u" && J.apply(this, [this]);
}, this), V(this, "load"), V(this, "render"), P(this.index) && this.setReflow(this.options.chart.reflow), this.hasLoaded = !0;
}, at.prototype.addSeries = function(J, tt, ot) {
var lt = this, pt;
return J && (tt = et(tt, !0), V(lt, "addSeries", { options: J }, function() {
pt = lt.initSeries(J), lt.isDirtyLegend = !0, lt.linkSeries(), pt.enabledDataSorting && pt.setData(J.data, !1), V(lt, "afterAddSeries", { series: pt }), tt && lt.redraw(ot);
})), pt;
}, at.prototype.addAxis = function(J, tt, ot, lt) {
return this.createAxis(tt ? "xAxis" : "yAxis", { axis: J, redraw: ot, animation: lt });
}, at.prototype.addColorAxis = function(J, tt, ot) {
return this.createAxis("colorAxis", { axis: J, redraw: tt, animation: ot });
}, at.prototype.createAxis = function(J, tt) {
return J = new j(this, q(tt.axis, { index: this[J].length, isX: J === "xAxis" })), et(tt.redraw, !0) && this.redraw(tt.animation), J;
}, at.prototype.showLoading = function(J) {
var tt = this, ot = tt.options, lt = ot.loading, pt = function() {
yt && W(yt, { left: tt.plotLeft + "px", top: tt.plotTop + "px", width: tt.plotWidth + "px", height: tt.plotHeight + "px" });
}, yt = tt.loadingDiv, vt = tt.loadingSpan;
yt || (tt.loadingDiv = yt = D("div", { className: "highcharts-loading highcharts-loading-hidden" }, null, tt.container)), vt || (tt.loadingSpan = vt = D(
"span",
{ className: "highcharts-loading-inner" },
null,
yt
), n(tt, "redraw", pt)), yt.className = "highcharts-loading", O.setElementHTML(vt, et(J, ot.lang.loading, "")), tt.styledMode || (W(yt, L(lt.style, { zIndex: 10 })), W(vt, lt.labelStyle), tt.loadingShown || (W(yt, { opacity: 0, display: "" }), B(yt, { opacity: lt.style.opacity || 0.5 }, { duration: lt.showDuration || 0 }))), tt.loadingShown = !0, pt();
}, at.prototype.hideLoading = function() {
var J = this.options, tt = this.loadingDiv;
tt && (tt.className = "highcharts-loading highcharts-loading-hidden", this.styledMode || B(tt, { opacity: 0 }, {
duration: J.loading.hideDuration || 100,
complete: function() {
W(tt, { display: "none" });
}
})), this.loadingShown = !1;
}, at.prototype.update = function(J, tt, ot, lt) {
var pt = this, yt = { credits: "addCredits", title: "setTitle", subtitle: "setSubtitle", caption: "setCaption" }, vt = J.isResponsiveOptions, Ct = [], Pt, At;
V(pt, "update", { options: J }), vt || pt.setResponsive(!1, !0), J = _(J, pt.options), pt.userOptions = q(pt.userOptions, J);
var St = J.chart;
if (St) {
if (q(!0, pt.options.chart, St), "className" in St && pt.setClassName(St.className), "reflow" in St && pt.setReflow(St.reflow), "inverted" in St || "polar" in St || "type" in St) {
pt.propFromSeries();
var Dt = !0;
}
"alignTicks" in St && (Dt = !0), "events" in St && x(this, St), it(St, function(Lt, Nt) {
pt.propsRequireUpdateSeries.indexOf("chart." + Nt) !== -1 && (Pt = !0), pt.propsRequireDirtyBox.indexOf(Nt) !== -1 && (pt.isDirtyBox = !0), pt.propsRequireReflow.indexOf(Nt) !== -1 && (vt ? pt.isDirtyBox = !0 : At = !0);
}), !pt.styledMode && St.style && pt.renderer.setStyle(pt.options.chart.style || {});
}
!pt.styledMode && J.colors && (this.options.colors = J.colors), J.time && (this.time === t && (this.time = new u(J.time)), q(!0, pt.options.time, J.time)), it(J, function(Lt, Nt) {
pt[Nt] && typeof pt[Nt].update == "function" ? pt[Nt].update(Lt, !1) : typeof pt[yt[Nt]] == "function" ? pt[yt[Nt]](Lt) : Nt !== "colors" && pt.collectionsWithUpdate.indexOf(Nt) === -1 && q(!0, pt.options[Nt], J[Nt]), Nt !== "chart" && pt.propsRequireUpdateSeries.indexOf(Nt) !== -1 && (Pt = !0);
}), this.collectionsWithUpdate.forEach(function(Lt) {
if (J[Lt]) {
var Nt = [];
pt[Lt].forEach(function(Et, Kt) {
Et.options.isInternal || Nt.push(et(Et.options.index, Kt));
}), gt(J[Lt]).forEach(function(Et, Kt) {
var Gt = P(Et.id), Wt;
Gt && (Wt = pt.get(Et.id)), !Wt && pt[Lt] && (Wt = pt[Lt][Nt ? Nt[Kt] : Kt]) && Gt && P(Wt.options.id) && (Wt = void 0), Wt && Wt.coll === Lt && (Wt.update(Et, !1), ot && (Wt.touched = !0)), !Wt && ot && pt.collectionsWithInit[Lt] && (pt.collectionsWithInit[Lt][0].apply(pt, [Et].concat(pt.collectionsWithInit[Lt][1] || []).concat([!1])).touched = !0);
}), ot && pt[Lt].forEach(function(Et) {
Et.touched || Et.options.isInternal ? delete Et.touched : Ct.push(Et);
});
}
}), Ct.forEach(function(Lt) {
Lt.chart && Lt.remove && Lt.remove(!1);
}), Dt && pt.axes.forEach(function(Lt) {
Lt.update({}, !1);
}), Pt && pt.getSeriesOrderByLinks().forEach(function(Lt) {
Lt.chart && Lt.update({}, !1);
}, this), Dt = St && St.width, St = St && ($(St.height) ? rt(St.height, Dt || pt.chartWidth) : St.height), At || G(Dt) && Dt !== pt.chartWidth || G(St) && St !== pt.chartHeight ? pt.setSize(Dt, St, lt) : et(tt, !0) && pt.redraw(lt), V(pt, "afterUpdate", { options: J, redraw: tt, animation: lt });
}, at.prototype.setSubtitle = function(J, tt) {
this.applyDescription("subtitle", J), this.layOutTitles(tt);
}, at.prototype.setCaption = function(J, tt) {
this.applyDescription("caption", J), this.layOutTitles(tt);
}, at.prototype.showResetZoom = function() {
function J() {
tt.zoomOut();
}
var tt = this, ot = o.lang, lt = tt.options.chart.resetZoomButton, pt = lt.theme, yt = pt.states, vt = lt.relativeTo === "chart" || lt.relativeTo === "spacingBox" ? null : "scrollablePlotBox";
V(this, "beforeShowResetZoom", null, function() {
tt.resetZoomButton = tt.renderer.button(ot.resetZoom, null, null, J, pt, yt && yt.hover).attr({ align: lt.position.align, title: ot.resetZoomTitle }).addClass("highcharts-reset-zoom").add().align(lt.position, !1, vt);
}), V(this, "afterShowResetZoom");
}, at.prototype.zoomOut = function() {
V(this, "selection", { resetSelection: !0 }, this.zoom);
}, at.prototype.zoom = function(J) {
var tt = this, ot = tt.pointer, lt = tt.inverted ? ot.mouseDownX : ot.mouseDownY, pt = !1, yt;
!J || J.resetSelection ? (tt.axes.forEach(function(Ct) {
yt = Ct.zoom();
}), ot.initiated = !1) : J.xAxis.concat(J.yAxis).forEach(function(Ct) {
var Pt = Ct.axis, At = tt.inverted ? Pt.left : Pt.top, St = tt.inverted ? At + Pt.width : At + Pt.height, Dt = Pt.isXAxis, Lt = !1;
(!Dt && lt >= At && lt <= St || Dt || !P(lt)) && (Lt = !0), ot[Dt ? "zoomX" : "zoomY"] && Lt && (yt = Pt.zoom(Ct.min, Ct.max), Pt.displayBtn && (pt = !0));
});
var vt = tt.resetZoomButton;
pt && !vt ? tt.showResetZoom() : !pt && z(vt) && (tt.resetZoomButton = vt.destroy()), yt && tt.redraw(et(
tt.options.chart.animation,
J && J.animation,
100 > tt.pointCount
));
}, at.prototype.pan = function(J, tt) {
var ot = this, lt = ot.hoverPoints;
tt = typeof tt == "object" ? tt : { enabled: tt, type: "x" };
var pt = ot.options.chart, yt = ot.options.mapNavigation && ot.options.mapNavigation.enabled;
pt && pt.panning && (pt.panning = tt);
var vt = tt.type, Ct;
V(this, "pan", { originalEvent: J }, function() {
lt && lt.forEach(function(St) {
St.setState();
});
var Pt = ot.xAxis;
vt === "xy" ? Pt = Pt.concat(ot.yAxis) : vt === "y" && (Pt = ot.yAxis);
var At = {};
Pt.forEach(function(St) {
if (St.options.panningEnabled && !St.options.isInternal) {
var Dt = St.horiz, Lt = J[Dt ? "chartX" : "chartY"];
Dt = Dt ? "mouseDownX" : "mouseDownY";
var Nt = ot[Dt], Et = St.minPointOffset || 0, Kt = St.reversed && !ot.inverted || !St.reversed && ot.inverted ? -1 : 1, Gt = St.getExtremes(), Wt = St.toValue(Nt - Lt, !0) + Et * Kt, Jt = St.toValue(Nt + St.len - Lt, !0) - (Et * Kt || St.isXAxis && St.pointRangePadding || 0), be = Jt < Wt;
Kt = St.hasVerticalPanning(), Nt = be ? Jt : Wt, Wt = be ? Wt : Jt;
var zt = St.panningState;
!Kt || St.isXAxis || zt && !zt.isDirty || St.series.forEach(function(Vt) {
var Me = Vt.getProcessedData(!0);
Me = Vt.getExtremes(Me.yData, !0), zt || (zt = { startMin: Number.MAX_VALUE, startMax: -Number.MAX_VALUE }), G(Me.dataMin) && G(Me.dataMax) && (zt.startMin = Math.min(et(Vt.options.threshold, 1 / 0), Me.dataMin, zt.startMin), zt.startMax = Math.max(et(Vt.options.threshold, -1 / 0), Me.dataMax, zt.startMax));
}), Kt = Math.min(et(zt && zt.startMin, Gt.dataMin), Et ? Gt.min : St.toValue(St.toPixels(Gt.min) - St.minPixelPadding)), Jt = Math.max(et(zt && zt.startMax, Gt.dataMax), Et ? Gt.max : St.toValue(St.toPixels(Gt.max) + St.minPixelPadding)), St.panningState = zt, St.isOrdinal || (Et = Kt - Nt, 0 < Et && (Wt += Et, Nt = Kt), Et = Wt - Jt, 0 < Et && (Wt = Jt, Nt -= Et), St.series.length && Nt !== Gt.min && Wt !== Gt.max && Nt >= Kt && Wt <= Jt && (St.setExtremes(Nt, Wt, !1, !1, { trigger: "pan" }), ot.resetZoomButton || yt || Nt === Kt || Wt === Jt || !vt.match("y") || (ot.showResetZoom(), St.displayBtn = !1), Ct = !0), At[Dt] = Lt);
}
}), it(At, function(St, Dt) {
ot[Dt] = St;
}), Ct && ot.redraw(!1), W(ot.container, { cursor: "move" });
});
}, at;
}(), L(y.prototype, {
callbacks: [],
collectionsWithInit: { xAxis: [y.prototype.addAxis, [!0]], yAxis: [y.prototype.addAxis, [!1]], series: [y.prototype.addSeries] },
collectionsWithUpdate: ["xAxis", "yAxis", "series"],
propsRequireDirtyBox: "backgroundColor borderColor borderWidth borderRadius plotBackgroundColor plotBackgroundImage plotBorderColor plotBorderWidth plotShadow shadow".split(" "),
propsRequireReflow: "margin marginTop marginRight marginBottom marginLeft spacing spacingTop spacingRight spacingBottom spacingLeft".split(" "),
propsRequireUpdateSeries: "chart.inverted chart.polar chart.ignoreHiddenSeries chart.type colors plotOptions time tooltip".split(" ")
}), y;
}), E(l, "Core/Legend/LegendSymbol.js", [l["Core/Utilities.js"]], function(y) {
var j = y.merge, I = y.pick, Z;
return function(H) {
H.drawLineMarker = function(U) {
var F = this.options, N = U.symbolWidth, R = U.symbolHeight, S = R / 2, v = this.chart.renderer, d = this.legendGroup;
U = U.baseline - Math.round(0.3 * U.fontMetrics.b);
var u = {}, T = F.marker;
this.chart.styledMode || (u = { "stroke-width": F.lineWidth || 0 }, F.dashStyle && (u.dashstyle = F.dashStyle)), this.legendLine = v.path([["M", 0, U], ["L", N, U]]).addClass("highcharts-graph").attr(u).add(d), T && T.enabled !== !1 && N && (F = Math.min(I(T.radius, S), S), this.symbol.indexOf("url") === 0 && (T = j(T, { width: R, height: R }), F = 0), this.legendSymbol = N = v.symbol(this.symbol, N / 2 - F, U - F, 2 * F, 2 * F, T).addClass("highcharts-point").add(d), N.isMarker = !0);
}, H.drawRectangle = function(U, F) {
var N = U.symbolHeight, R = U.options.squareSymbol;
F.legendSymbol = this.chart.renderer.rect(R ? (U.symbolWidth - N) / 2 : 0, U.baseline - N + 1, R ? N : U.symbolWidth, N, I(U.options.symbolRadius, N / 2)).addClass("highcharts-point").attr({ zIndex: 3 }).add(F.legendGroup);
};
}(Z || (Z = {})), Z;
}), E(l, "Core/Series/SeriesDefaults.js", [], function() {
return { lineWidth: 2, allowPointSelect: !1, crisp: !0, showCheckbox: !1, animation: { duration: 1e3 }, events: {}, marker: { enabledThreshold: 2, lineColor: "#ffffff", lineWidth: 0, radius: 4, states: {
normal: { animation: !0 },
hover: { animation: { duration: 50 }, enabled: !0, radiusPlus: 2, lineWidthPlus: 1 },
select: { fillColor: "#cccccc", lineColor: "#000000", lineWidth: 2 }
} }, point: { events: {} }, dataLabels: { animation: {}, align: "center", defer: !0, formatter: function() {
var y = this.series.chart.numberFormatter;
return typeof this.y != "number" ? "" : y(this.y, -1);
}, padding: 5, style: { fontSize: "11px", fontWeight: "bold", color: "contrast", textOutline: "1px contrast" }, verticalAlign: "bottom", x: 0, y: 0 }, cropThreshold: 300, opacity: 1, pointRange: 0, softThreshold: !0, states: {
normal: { animation: !0 },
hover: { animation: { duration: 50 }, lineWidthPlus: 1, marker: {}, halo: { size: 10, opacity: 0.25 } },
select: { animation: { duration: 0 } },
inactive: { animation: { duration: 50 }, opacity: 0.2 }
}, stickyTracking: !0, turboThreshold: 1e3, findNearestPointBy: "x" };
}), E(l, "Core/Series/Series.js", [
l["Core/Animation/AnimationUtilities.js"],
l["Core/DefaultOptions.js"],
l["Core/Foundation.js"],
l["Core/Globals.js"],
l["Core/Legend/LegendSymbol.js"],
l["Core/Series/Point.js"],
l["Core/Series/SeriesDefaults.js"],
l["Core/Series/SeriesRegistry.js"],
l["Core/Renderer/SVG/SVGElement.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z, H, U, F, N, R, S) {
var v = y.animObject, d = y.setAnimation, u = j.defaultOptions, T = I.registerEventOptions, O = Z.hasTouch, B = Z.svg, C = Z.win, b = N.seriesTypes, w = S.addEvent, x = S.arrayMax, a = S.arrayMin, c = S.clamp, p = S.cleanRecursively, i = S.correctFloat, h = S.defined, o = S.erase, t = S.error, s = S.extend, n = S.find, A = S.fireEvent, _ = S.getNestedProperty, D = S.isArray, W = S.isNumber, P = S.isString, X = S.merge, g = S.objectEach, m = S.pick, L = S.removeEvent, Y = S.splat, V = S.syncTimeout;
return y = function() {
function Q() {
this.zones = this.yAxis = this.xAxis = this.userOptions = this.tooltipOptions = this.processedYData = this.processedXData = this.points = this.options = this.linkedSeries = this.index = this.eventsToUnbind = this.eventOptions = this.data = this.chart = this._i = void 0;
}
return Q.prototype.init = function(k, G) {
A(this, "init", { options: G });
var z = this, $ = k.series;
this.eventsToUnbind = [], z.chart = k, z.options = z.setOptions(G), G = z.options, z.linkedSeries = [], z.bindAxes(), s(z, { name: G.name, state: "", visible: G.visible !== !1, selected: G.selected === !0 }), T(this, G);
var q = G.events;
(q && q.click || G.point && G.point.events && G.point.events.click || G.allowPointSelect) && (k.runTrackerClick = !0), z.getColor(), z.getSymbol(), z.parallelArrays.forEach(function(et) {
z[et + "Data"] || (z[et + "Data"] = []);
}), z.isCartesian && (k.hasCartesianSeries = !0);
var it;
$.length && (it = $[$.length - 1]), z._i = m(it && it._i, -1) + 1, z.opacity = z.options.opacity, k.orderSeries(this.insert($)), G.dataSorting && G.dataSorting.enabled ? z.setDataSortingOptions() : z.points || z.data || z.setData(G.data, !1), A(this, "afterInit");
}, Q.prototype.is = function(k) {
return b[k] && this instanceof b[k];
}, Q.prototype.insert = function(k) {
var G = this.options.index, z;
if (W(G)) {
for (z = k.length; z--; )
if (G >= m(k[z].options.index, k[z]._i)) {
k.splice(z + 1, 0, this);
break;
}
z === -1 && k.unshift(this), z += 1;
} else
k.push(this);
return m(z, k.length - 1);
}, Q.prototype.bindAxes = function() {
var k = this, G = k.options, z = k.chart, $;
A(this, "bindAxes", null, function() {
(k.axisTypes || []).forEach(function(q) {
var it = 0;
z[q].forEach(function(et) {
$ = et.options, (G[q] === it && !$.isInternal || typeof G[q] < "u" && G[q] === $.id || typeof G[q] > "u" && $.index === 0) && (k.insert(et.series), k[q] = et, et.isDirty = !0), $.isInternal || it++;
}), k[q] || k.optionalAxis === q || t(18, !0, z);
});
}), A(this, "afterBindAxes");
}, Q.prototype.updateParallelArrays = function(k, G) {
var z = k.series, $ = arguments, q = W(G) ? function(it) {
var et = it === "y" && z.toYData ? z.toYData(k) : k[it];
z[it + "Data"][G] = et;
} : function(it) {
Array.prototype[G].apply(z[it + "Data"], Array.prototype.slice.call($, 2));
};
z.parallelArrays.forEach(q);
}, Q.prototype.hasData = function() {
return this.visible && typeof this.dataMax < "u" && typeof this.dataMin < "u" || this.visible && this.yData && 0 < this.yData.length;
}, Q.prototype.autoIncrement = function(k) {
var G = this.options, z = G.pointIntervalUnit, $ = G.relativeXValue, q = this.chart.time, it = this.xIncrement, et;
return it = m(it, G.pointStart, 0), this.pointInterval = et = m(this.pointInterval, G.pointInterval, 1), $ && W(k) && (et *= k), z && (G = new q.Date(it), z === "day" ? q.set("Date", G, q.get("Date", G) + et) : z === "month" ? q.set("Month", G, q.get("Month", G) + et) : z === "year" && q.set("FullYear", G, q.get("FullYear", G) + et), et = G.getTime() - it), $ && W(k) ? it + et : (this.xIncrement = it + et, it);
}, Q.prototype.setDataSortingOptions = function() {
var k = this.options;
s(this, { requireSorting: !1, sorted: !1, enabledDataSorting: !0, allowDG: !1 }), h(k.pointRange) || (k.pointRange = 1);
}, Q.prototype.setOptions = function(k) {
var G = this.chart, z = G.options, $ = z.plotOptions, q = G.userOptions || {};
k = X(k), G = G.styledMode;
var it = { plotOptions: $, userOptions: k };
A(this, "setOptions", it);
var et = it.plotOptions[this.type], nt = q.plotOptions || {};
return this.userOptions = it.userOptions, q = X(et, $.series, q.plotOptions && q.plotOptions[this.type], k), this.tooltipOptions = X(u.tooltip, u.plotOptions.series && u.plotOptions.series.tooltip, u.plotOptions[this.type].tooltip, z.tooltip.userOptions, $.series && $.series.tooltip, $[this.type].tooltip, k.tooltip), this.stickyTracking = m(k.stickyTracking, nt[this.type] && nt[this.type].stickyTracking, nt.series && nt.series.stickyTracking, this.tooltipOptions.shared && !this.noSharedTooltip ? !0 : q.stickyTracking), et.marker === null && delete q.marker, this.zoneAxis = q.zoneAxis, $ = this.zones = (q.zones || []).slice(), !q.negativeColor && !q.negativeFillColor || q.zones || (z = { value: q[this.zoneAxis + "Threshold"] || q.threshold || 0, className: "highcharts-negative" }, G || (z.color = q.negativeColor, z.fillColor = q.negativeFillColor), $.push(z)), $.length && h($[$.length - 1].value) && $.push(G ? {} : { color: this.color, fillColor: this.fillColor }), A(this, "afterSetOptions", { options: q }), q;
}, Q.prototype.getName = function() {
return m(this.options.name, "Series " + (this.index + 1));
}, Q.prototype.getCyclic = function(k, G, z) {
var $ = this.chart, q = this.userOptions, it = k + "Index", et = k + "Counter", nt = z ? z.length : m($.options.chart[k + "Count"], $[k + "Count"]);
if (!G) {
var rt = m(q[it], q["_" + it]);
h(rt) || ($.series.length || ($[et] = 0), q["_" + it] = rt = $[et] % nt, $[et] += 1), z && (G = z[rt]);
}
typeof rt < "u" && (this[it] = rt), this[k] = G;
}, Q.prototype.getColor = function() {
this.chart.styledMode ? this.getCyclic("color") : this.options.colorByPoint ? this.color = "#cccccc" : this.getCyclic("color", this.options.color || u.plotOptions[this.type].color, this.chart.options.colors);
}, Q.prototype.getPointsCollection = function() {
return (this.hasGroupedData ? this.points : this.data) || [];
}, Q.prototype.getSymbol = function() {
this.getCyclic("symbol", this.options.marker.symbol, this.chart.options.symbols);
}, Q.prototype.findPointIndex = function(k, G) {
var z = k.id, $ = k.x, q = this.points, it = this.options.dataSorting, et, nt;
if (z)
it = this.chart.get(z), it instanceof U && (et = it);
else if ((this.linkedParent || this.enabledDataSorting || this.options.relativeXValue) && (et = function(ct) {
return !ct.touched && ct.index === k.index;
}, it && it.matchByName ? et = function(ct) {
return !ct.touched && ct.name === k.name;
} : this.options.relativeXValue && (et = function(ct) {
return !ct.touched && ct.options.x === k.x;
}), et = n(q, et), !et))
return;
if (et) {
var rt = et && et.index;
typeof rt < "u" && (nt = !0);
}
return typeof rt > "u" && W($) && (rt = this.xData.indexOf($, G)), rt !== -1 && typeof rt < "u" && this.cropped && (rt = rt >= this.cropStart ? rt - this.cropStart : rt), !nt && W(rt) && q[rt] && q[rt].touched && (rt = void 0), rt;
}, Q.prototype.updateData = function(k, G) {
var z = this.options, $ = z.dataSorting, q = this.points, it = [], et = this.requireSorting, nt = k.length === q.length, rt, ct, gt, dt = !0;
if (this.xIncrement = null, k.forEach(function(ht, at) {
var J = h(ht) && this.pointClass.prototype.optionsToObject.call({ series: this }, ht) || {}, tt = J.x;
J.id || W(tt) ? (J = this.findPointIndex(J, gt), J === -1 || typeof J > "u" ? it.push(ht) : q[J] && ht !== z.data[J] ? (q[J].update(ht, !1, null, !1), q[J].touched = !0, et && (gt = J + 1)) : q[J] && (q[J].touched = !0), (!nt || at !== J || $ && $.enabled || this.hasDerivedData) && (rt = !0)) : it.push(ht);
}, this), rt)
for (k = q.length; k--; )
(ct = q[k]) && !ct.touched && ct.remove && ct.remove(!1, G);
else
!nt || $ && $.enabled ? dt = !1 : (k.forEach(function(ht, at) {
ht !== q[at].y && q[at].update && q[at].update(
ht,
!1,
null,
!1
);
}), it.length = 0);
return q.forEach(function(ht) {
ht && (ht.touched = !1);
}), dt ? (it.forEach(function(ht) {
this.addPoint(ht, !1, null, null, !1);
}, this), this.xIncrement === null && this.xData && this.xData.length && (this.xIncrement = x(this.xData), this.autoIncrement()), !0) : !1;
}, Q.prototype.setData = function(k, G, z, $) {
var q = this, it = q.points, et = it && it.length || 0, nt = q.options, rt = q.chart, ct = nt.dataSorting, gt = q.xAxis, dt = nt.turboThreshold, ht = this.xData, at = this.yData, J = q.pointArrayMap;
J = J && J.length;
var tt = nt.keys, ot, lt = 0, pt = 1, yt = null;
k = k || [];
var vt = k.length;
if (G = m(G, !0), ct && ct.enabled && (k = this.sortData(k)), $ !== !1 && vt && et && !q.cropped && !q.hasGroupedData && q.visible && !q.isSeriesBoosting && (ot = this.updateData(k, z)), !ot) {
if (q.xIncrement = null, q.colorCounter = 0, this.parallelArrays.forEach(function(Ct) {
q[Ct + "Data"].length = 0;
}), dt && vt > dt)
if (yt = q.getFirstValidPoint(k), W(yt))
for (z = 0; z < vt; z++)
ht[z] = this.autoIncrement(), at[z] = k[z];
else if (D(yt))
if (J)
if (yt.length === J)
for (z = 0; z < vt; z++)
ht[z] = this.autoIncrement(), at[z] = k[z];
else
for (z = 0; z < vt; z++)
$ = k[z], ht[z] = $[0], at[z] = $.slice(
1,
J + 1
);
else if (tt && (lt = tt.indexOf("x"), pt = tt.indexOf("y"), lt = 0 <= lt ? lt : 0, pt = 0 <= pt ? pt : 1), yt.length === 1 && (pt = 0), lt === pt)
for (z = 0; z < vt; z++)
ht[z] = this.autoIncrement(), at[z] = k[z][pt];
else
for (z = 0; z < vt; z++)
$ = k[z], ht[z] = $[lt], at[z] = $[pt];
else
t(12, !1, rt);
else
for (z = 0; z < vt; z++)
typeof k[z] < "u" && ($ = { series: q }, q.pointClass.prototype.applyOptions.apply($, [k[z]]), q.updateParallelArrays($, z));
for (at && P(at[0]) && t(14, !0, rt), q.data = [], q.options.data = q.userOptions.data = k, z = et; z--; )
it[z] && it[z].destroy && it[z].destroy();
gt && (gt.minRange = gt.userMinRange), q.isDirty = rt.isDirtyBox = !0, q.isDirtyData = !!it, z = !1;
}
nt.legendType === "point" && (this.processData(), this.generatePoints()), G && rt.redraw(z);
}, Q.prototype.sortData = function(k) {
var G = this, z = G.options.dataSorting.sortKey || "y", $ = function(q, it) {
return h(it) && q.pointClass.prototype.optionsToObject.call({ series: q }, it) || {};
};
return k.forEach(function(q, it) {
k[it] = $(G, q), k[it].index = it;
}, this), k.concat().sort(function(q, it) {
return q = _(z, q), it = _(z, it), it < q ? -1 : it > q ? 1 : 0;
}).forEach(function(q, it) {
q.x = it;
}, this), G.linkedSeries && G.linkedSeries.forEach(function(q) {
var it = q.options, et = it.data;
it.dataSorting && it.dataSorting.enabled || !et || (et.forEach(function(nt, rt) {
et[rt] = $(q, nt), k[rt] && (et[rt].x = k[rt].x, et[rt].index = rt);
}), q.setData(et, !1));
}), k;
}, Q.prototype.getProcessedData = function(k) {
var G = this.xAxis, z = this.options, $ = z.cropThreshold, q = k || this.getExtremesFromAll || z.getExtremesFromAll, it = this.isCartesian;
k = G && G.val2lin, z = !(!G || !G.logarithmic);
var et = 0, nt = this.xData, rt = this.yData, ct = this.requireSorting, gt = !1, dt = nt.length;
if (G) {
gt = G.getExtremes();
var ht = gt.min, at = gt.max;
gt = G.categories && !G.names.length;
}
if (it && this.sorted && !q && (!$ || dt > $ || this.forceCrop)) {
if (nt[dt - 1] < ht || nt[0] > at)
nt = [], rt = [];
else if (this.yData && (nt[0] < ht || nt[dt - 1] > at)) {
var J = this.cropData(this.xData, this.yData, ht, at);
nt = J.xData, rt = J.yData, et = J.start, J = !0;
}
}
for ($ = nt.length || 1; --$; )
if (G = z ? k(nt[$]) - k(nt[$ - 1]) : nt[$] - nt[$ - 1], 0 < G && (typeof tt > "u" || G < tt))
var tt = G;
else
0 > G && ct && !gt && (t(15, !1, this.chart), ct = !1);
return { xData: nt, yData: rt, cropped: J, cropStart: et, closestPointRange: tt };
}, Q.prototype.processData = function(k) {
var G = this.xAxis;
if (this.isCartesian && !this.isDirty && !G.isDirty && !this.yAxis.isDirty && !k)
return !1;
k = this.getProcessedData(), this.cropped = k.cropped, this.cropStart = k.cropStart, this.processedXData = k.xData, this.processedYData = k.yData, this.closestPointRange = this.basePointRange = k.closestPointRange, A(this, "afterProcessData");
}, Q.prototype.cropData = function(k, G, z, $, q) {
var it = k.length, et, nt = 0, rt = it;
for (q = m(q, this.cropShoulder), et = 0; et < it; et++)
if (k[et] >= z) {
nt = Math.max(0, et - q);
break;
}
for (z = et; z < it; z++)
if (k[z] > $) {
rt = z + q;
break;
}
return { xData: k.slice(nt, rt), yData: G.slice(
nt,
rt
), start: nt, end: rt };
}, Q.prototype.generatePoints = function() {
var k = this.options, G = k.data, z = this.processedXData, $ = this.processedYData, q = this.pointClass, it = z.length, et = this.cropStart || 0, nt = this.hasGroupedData, rt = k.keys, ct = [];
k = k.dataGrouping && k.dataGrouping.groupAll ? et : 0;
var gt, dt, ht = this.data;
if (!ht && !nt) {
var at = [];
at.length = G.length, ht = this.data = at;
}
for (rt && nt && (this.options.keys = !1), dt = 0; dt < it; dt++) {
if (at = et + dt, nt) {
var J = new q().init(this, [z[dt]].concat(Y($[dt])));
J.dataGroup = this.groupMap[k + dt], J.dataGroup.options && (J.options = J.dataGroup.options, s(J, J.dataGroup.options), delete J.dataLabels);
} else
(J = ht[at]) || typeof G[at] > "u" || (ht[at] = J = new q().init(this, G[at], z[dt]));
J && (J.index = nt ? k + dt : at, ct[dt] = J);
}
if (this.options.keys = rt, ht && (it !== (gt = ht.length) || nt))
for (dt = 0; dt < gt; dt++)
dt !== et || nt || (dt += it), ht[dt] && (ht[dt].destroyElements(), ht[dt].plotX = void 0);
this.data = ht, this.points = ct, A(this, "afterGeneratePoints");
}, Q.prototype.getXExtremes = function(k) {
return { min: a(k), max: x(k) };
}, Q.prototype.getExtremes = function(k, G) {
var z = this.xAxis, $ = this.yAxis, q = this.processedXData || this.xData, it = [], et = this.requireSorting ? this.cropShoulder : 0;
$ = $ ? $.positiveValuesOnly : !1;
var nt, rt = 0, ct = 0, gt = 0;
k = k || this.stackedYData || this.processedYData || [];
var dt = k.length;
if (z) {
var ht = z.getExtremes();
rt = ht.min, ct = ht.max;
}
for (nt = 0; nt < dt; nt++) {
var at = q[nt];
ht = k[nt];
var J = (W(ht) || D(ht)) && (ht.length || 0 < ht || !$);
if (at = G || this.getExtremesFromAll || this.options.getExtremesFromAll || this.cropped || !z || (q[nt + et] || at) >= rt && (q[nt - et] || at) <= ct, J && at)
if (J = ht.length)
for (; J--; )
W(ht[J]) && (it[gt++] = ht[J]);
else
it[gt++] = ht;
}
return k = { activeYData: it, dataMin: a(it), dataMax: x(it) }, A(this, "afterGetExtremes", { dataExtremes: k }), k;
}, Q.prototype.applyExtremes = function() {
var k = this.getExtremes();
return this.dataMin = k.dataMin, this.dataMax = k.dataMax, k;
}, Q.prototype.getFirstValidPoint = function(k) {
for (var G = k.length, z = 0, $ = null; $ === null && z < G; )
$ = k[z], z++;
return $;
}, Q.prototype.translate = function() {
this.processedXData || this.processData(), this.generatePoints();
var k = this.options, G = k.stacking, z = this.xAxis, $ = z.categories, q = this.enabledDataSorting, it = this.yAxis, et = this.points, nt = et.length, rt = this.pointPlacementToXValue(), ct = !!rt, gt = k.threshold, dt = k.startFromThreshold ? gt : 0, ht = this.zoneAxis || "y", at, J, tt = Number.MAX_VALUE;
for (at = 0; at < nt; at++) {
var ot = et[at], lt = ot.x, pt = void 0, yt = void 0, vt = ot.y, Ct = ot.low, Pt = G && it.stacking && it.stacking.stacks[(this.negStacks && vt < (dt ? 0 : gt) ? "-" : "") + this.stackKey];
if ((it.positiveValuesOnly && !it.validatePositiveValue(vt) || z.positiveValuesOnly && !z.validatePositiveValue(lt)) && (ot.isNull = !0), ot.plotX = J = i(c(z.translate(lt, 0, 0, 0, 1, rt, this.type === "flags"), -1e5, 1e5)), G && this.visible && Pt && Pt[lt]) {
var At = this.getStackIndicator(
At,
lt,
this.index
);
ot.isNull || (pt = Pt[lt], yt = pt.points[At.key]);
}
if (D(yt) && (Ct = yt[0], vt = yt[1], Ct === dt && At.key === Pt[lt].base && (Ct = m(W(gt) && gt, it.min)), it.positiveValuesOnly && 0 >= Ct && (Ct = null), ot.total = ot.stackTotal = pt.total, ot.percentage = pt.total && ot.y / pt.total * 100, ot.stackY = vt, this.irregularWidths || pt.setOffset(this.pointXOffset || 0, this.barW || 0)), ot.yBottom = h(Ct) ? c(it.translate(Ct, 0, 1, 0, 1), -1e5, 1e5) : null, this.dataModify && (vt = this.dataModify.modifyValue(vt, at)), ot.plotY = void 0, W(vt) && (pt = it.translate(vt, !1, !0, !1, !0), typeof pt < "u" && (ot.plotY = c(
pt,
-1e5,
1e5
))), ot.isInside = this.isPointInside(ot), ot.clientX = ct ? i(z.translate(lt, 0, 0, 0, 1, rt)) : J, ot.negative = ot[ht] < (k[ht + "Threshold"] || gt || 0), ot.category = $ && typeof $[ot.x] < "u" ? $[ot.x] : ot.x, !ot.isNull && ot.visible !== !1) {
typeof St < "u" && (tt = Math.min(tt, Math.abs(J - St)));
var St = J;
}
ot.zone = this.zones.length ? ot.getZone() : void 0, !ot.graphic && this.group && q && (ot.isNew = !0);
}
this.closestPointRangePx = tt, A(this, "afterTranslate");
}, Q.prototype.getValidPoints = function(k, G, z) {
var $ = this.chart;
return (k || this.points || []).filter(function(q) {
return G && !$.isInsidePlot(q.plotX, q.plotY, { inverted: $.inverted }) ? !1 : q.visible !== !1 && (z || !q.isNull);
});
}, Q.prototype.getClipBox = function() {
var k = this.chart, G = this.xAxis, z = this.yAxis, $ = X(k.clipBox);
return G && G.len !== k.plotSizeX && ($.width = G.len), z && z.len !== k.plotSizeY && ($.height = z.len), $;
}, Q.prototype.getSharedClipKey = function() {
return this.sharedClipKey = (this.options.xAxis || 0) + "," + (this.options.yAxis || 0);
}, Q.prototype.setClip = function() {
var k = this.chart, G = this.group, z = this.markerGroup, $ = k.sharedClips;
k = k.renderer;
var q = this.getClipBox(), it = this.getSharedClipKey(), et = $[it];
et ? et.animate(q) : $[it] = et = k.clipRect(q), G && G.clip(this.options.clip === !1 ? void 0 : et), z && z.clip();
}, Q.prototype.animate = function(k) {
var G = this.chart, z = this.group, $ = this.markerGroup, q = G.inverted, it = v(this.options.animation), et = [this.getSharedClipKey(), it.duration, it.easing, it.defer].join(), nt = G.sharedClips[et], rt = G.sharedClips[et + "m"];
if (k && z)
it = this.getClipBox(), nt ? nt.attr("height", it.height) : (it.width = 0, q && (it.x = G.plotHeight), nt = G.renderer.clipRect(it), G.sharedClips[et] = nt, rt = G.renderer.clipRect({ x: q ? (G.plotSizeX || 0) + 99 : -99, y: q ? -G.plotLeft : -G.plotTop, width: 99, height: q ? G.chartWidth : G.chartHeight }), G.sharedClips[et + "m"] = rt), z.clip(nt), $ && $.clip(rt);
else if (nt && !nt.hasClass("highcharts-animating")) {
G = this.getClipBox();
var ct = it.step;
$ && $.element.childNodes.length && (it.step = function(gt, dt) {
ct && ct.apply(dt, arguments), rt && rt.element && rt.attr(dt.prop, dt.prop === "width" ? gt + 99 : gt);
}), nt.addClass("highcharts-animating").animate(G, it);
}
}, Q.prototype.afterAnimate = function() {
var k = this;
this.setClip(), g(
this.chart.sharedClips,
function(G, z, $) {
G && !k.chart.container.querySelector('[clip-path="url(#' + G.id + ')"]') && (G.destroy(), delete $[z]);
}
), this.finishedAnimating = !0, A(this, "afterAnimate");
}, Q.prototype.drawPoints = function() {
var k = this.points, G = this.chart, z = this.options.marker, $ = this[this.specialGroup] || this.markerGroup, q = this.xAxis, it = m(z.enabled, !q || q.isRadial ? !0 : null, this.closestPointRangePx >= z.enabledThreshold * z.radius), et, nt;
if (z.enabled !== !1 || this._hasPointMarkers)
for (et = 0; et < k.length; et++) {
var rt = k[et], ct = (nt = rt.graphic) ? "animate" : "attr", gt = rt.marker || {}, dt = !!rt.marker;
if ((it && typeof gt.enabled > "u" || gt.enabled) && !rt.isNull && rt.visible !== !1) {
var ht = m(gt.symbol, this.symbol, "rect"), at = this.markerAttribs(rt, rt.selected && "select");
this.enabledDataSorting && (rt.startXPos = q.reversed ? -(at.width || 0) : q.width);
var J = rt.isInside !== !1;
nt ? nt[J ? "show" : "hide"](J).animate(at) : J && (0 < (at.width || 0) || rt.hasImage) && (rt.graphic = nt = G.renderer.symbol(ht, at.x, at.y, at.width, at.height, dt ? gt : z).add($), this.enabledDataSorting && G.hasRendered && (nt.attr({ x: rt.startXPos }), ct = "animate")), nt && ct === "animate" && nt[J ? "show" : "hide"](J).animate(at), nt && !G.styledMode && nt[ct](this.pointAttribs(rt, rt.selected && "select")), nt && nt.addClass(rt.getClassName(), !0);
} else
nt && (rt.graphic = nt.destroy());
}
}, Q.prototype.markerAttribs = function(k, G) {
var z = this.options, $ = z.marker, q = k.marker || {}, it = q.symbol || $.symbol, et = m(q.radius, $.radius);
return G && ($ = $.states[G], G = q.states && q.states[G], et = m(G && G.radius, $ && $.radius, et + ($ && $.radiusPlus || 0))), k.hasImage = it && it.indexOf("url") === 0, k.hasImage && (et = 0), k = { x: z.crisp ? Math.floor(k.plotX - et) : k.plotX - et, y: k.plotY - et }, et && (k.width = k.height = 2 * et), k;
}, Q.prototype.pointAttribs = function(k, G) {
var z = this.options.marker, $ = k && k.options, q = $ && $.marker || {}, it = $ && $.color, et = k && k.color, nt = k && k.zone && k.zone.color, rt = this.color;
return k = m(q.lineWidth, z.lineWidth), $ = 1, rt = it || nt || et || rt, it = q.fillColor || z.fillColor || rt, et = q.lineColor || z.lineColor || rt, G = G || "normal", z = z.states[G] || {}, G = q.states && q.states[G] || {}, k = m(G.lineWidth, z.lineWidth, k + m(G.lineWidthPlus, z.lineWidthPlus, 0)), it = G.fillColor || z.fillColor || it, et = G.lineColor || z.lineColor || et, $ = m(G.opacity, z.opacity, $), { stroke: et, "stroke-width": k, fill: it, opacity: $ };
}, Q.prototype.destroy = function(k) {
var G = this, z = G.chart, $ = /AppleWebKit\/533/.test(C.navigator.userAgent), q = G.data || [], it, et, nt, rt;
for (A(G, "destroy"), this.removeEvents(k), (G.axisTypes || []).forEach(function(ct) {
(rt = G[ct]) && rt.series && (o(rt.series, G), rt.isDirty = rt.forceRedraw = !0);
}), G.legendItem && G.chart.legend.destroyItem(G), et = q.length; et--; )
(nt = q[et]) && nt.destroy && nt.destroy();
G.clips && G.clips.forEach(function(ct) {
return ct.destroy();
}), S.clearTimeout(G.animationTimeout), g(G, function(ct, gt) {
ct instanceof R && !ct.survive && (it = $ && gt === "group" ? "hide" : "destroy", ct[it]());
}), z.hoverSeries === G && (z.hoverSeries = void 0), o(z.series, G), z.orderSeries(), g(G, function(ct, gt) {
k && gt === "hcEvents" || delete G[gt];
});
}, Q.prototype.applyZones = function() {
var k = this, G = this.chart, z = G.renderer, $ = this.zones, q = this.clips || [], it = this.graph, et = this.area, nt = Math.max(G.chartWidth, G.chartHeight), rt = this[(this.zoneAxis || "y") + "Axis"], ct = G.inverted, gt, dt, ht, at, J, tt, ot, lt, pt = !1;
if ($.length && (it || et) && rt && typeof rt.min < "u") {
var yt = rt.reversed, vt = rt.horiz;
it && !this.showLine && it.hide(), et && et.hide();
var Ct = rt.getExtremes();
$.forEach(function(Pt, At) {
gt = yt ? vt ? G.plotWidth : 0 : vt ? 0 : rt.toPixels(Ct.min) || 0, gt = c(m(dt, gt), 0, nt), dt = c(Math.round(rt.toPixels(m(Pt.value, Ct.max), !0) || 0), 0, nt), pt && (gt = dt = rt.toPixels(Ct.max)), at = Math.abs(gt - dt), J = Math.min(gt, dt), tt = Math.max(gt, dt), rt.isXAxis ? (ht = { x: ct ? tt : J, y: 0, width: at, height: nt }, vt || (ht.x = G.plotHeight - ht.x)) : (ht = { x: 0, y: ct ? tt : J, width: nt, height: at }, vt && (ht.y = G.plotWidth - ht.y)), ct && z.isVML && (ht = rt.isXAxis ? {
x: 0,
y: yt ? J : tt,
height: ht.width,
width: G.chartWidth
} : { x: ht.y - G.plotLeft - G.spacingBox.x, y: 0, width: ht.height, height: G.chartHeight }), q[At] ? q[At].animate(ht) : q[At] = z.clipRect(ht), ot = k["zone-area-" + At], lt = k["zone-graph-" + At], it && lt && lt.clip(q[At]), et && ot && ot.clip(q[At]), pt = Pt.value > Ct.max, k.resetZones && dt === 0 && (dt = void 0);
}), this.clips = q;
} else
k.visible && (it && it.show(!0), et && et.show(!0));
}, Q.prototype.invertGroups = function(k) {
function G() {
["group", "markerGroup"].forEach(function(q) {
z[q] && ($.renderer.isVML && z[q].attr({ width: z.yAxis.len, height: z.xAxis.len }), z[q].width = z.yAxis.len, z[q].height = z.xAxis.len, z[q].invert(z.isRadialSeries ? !1 : k));
});
}
var z = this, $ = z.chart;
z.xAxis && (z.eventsToUnbind.push(w($, "resize", G)), G(), z.invertGroups = G);
}, Q.prototype.plotGroup = function(k, G, z, $, q) {
var it = this[k], et = !it;
return z = { visibility: z, zIndex: $ || 0.1 }, typeof this.opacity > "u" || this.chart.styledMode || this.state === "inactive" || (z.opacity = this.opacity), et && (this[k] = it = this.chart.renderer.g().add(q)), it.addClass("highcharts-" + G + " highcharts-series-" + this.index + " highcharts-" + this.type + "-series " + (h(this.colorIndex) ? "highcharts-color-" + this.colorIndex + " " : "") + (this.options.className || "") + (it.hasClass("highcharts-tracker") ? " highcharts-tracker" : ""), !0), it.attr(z)[et ? "attr" : "animate"](this.getPlotBox()), it;
}, Q.prototype.getPlotBox = function() {
var k = this.chart, G = this.xAxis, z = this.yAxis;
return k.inverted && (G = z, z = this.xAxis), { translateX: G ? G.left : k.plotLeft, translateY: z ? z.top : k.plotTop, scaleX: 1, scaleY: 1 };
}, Q.prototype.removeEvents = function(k) {
k || L(this), this.eventsToUnbind.length && (this.eventsToUnbind.forEach(function(G) {
G();
}), this.eventsToUnbind.length = 0);
}, Q.prototype.render = function() {
var k = this, G = k.chart, z = k.options, $ = v(z.animation), q = k.visible ? "inherit" : "hidden", it = z.zIndex, et = k.hasRendered, nt = G.seriesGroup, rt = G.inverted;
G = !k.finishedAnimating && G.renderer.isSVG ? $.duration : 0, A(this, "render");
var ct = k.plotGroup("group", "series", q, it, nt);
k.markerGroup = k.plotGroup("markerGroup", "markers", q, it, nt), z.clip !== !1 && k.setClip(), k.animate && G && k.animate(!0), ct.inverted = m(k.invertible, k.isCartesian) ? rt : !1, k.drawGraph && (k.drawGraph(), k.applyZones()), k.visible && k.drawPoints(), k.drawDataLabels && k.drawDataLabels(), k.redrawPoints && k.redrawPoints(), k.drawTracker && k.options.enableMouseTracking !== !1 && k.drawTracker(), k.invertGroups(rt), k.animate && G && k.animate(), et || (G && $.defer && (G += $.defer), k.animationTimeout = V(function() {
k.afterAnimate();
}, G || 0)), k.isDirty = !1, k.hasRendered = !0, A(k, "afterRender");
}, Q.prototype.redraw = function() {
var k = this.chart, G = this.isDirty || this.isDirtyData, z = this.group, $ = this.xAxis, q = this.yAxis;
z && (k.inverted && z.attr({
width: k.plotWidth,
height: k.plotHeight
}), z.animate({ translateX: m($ && $.left, k.plotLeft), translateY: m(q && q.top, k.plotTop) })), this.translate(), this.render(), G && delete this.kdTree;
}, Q.prototype.searchPoint = function(k, G) {
var z = this.xAxis, $ = this.yAxis, q = this.chart.inverted;
return this.searchKDTree({ clientX: q ? z.len - k.chartY + z.pos : k.chartX - z.pos, plotY: q ? $.len - k.chartX + $.pos : k.chartY - $.pos }, G, k);
}, Q.prototype.buildKDTree = function(k) {
function G(q, it, et) {
var nt = q && q.length;
if (nt) {
var rt = z.kdAxisArray[it % et];
return q.sort(function(ct, gt) {
return ct[rt] - gt[rt];
}), nt = Math.floor(nt / 2), { point: q[nt], left: G(q.slice(0, nt), it + 1, et), right: G(q.slice(nt + 1), it + 1, et) };
}
}
this.buildingKdTree = !0;
var z = this, $ = -1 < z.options.findNearestPointBy.indexOf("y") ? 2 : 1;
delete z.kdTree, V(function() {
z.kdTree = G(z.getValidPoints(null, !z.directTouch), $, $), z.buildingKdTree = !1;
}, z.options.kdNow || k && k.type === "touchstart" ? 0 : 1);
}, Q.prototype.searchKDTree = function(k, G, z) {
function $(rt, ct, gt, dt) {
var ht = ct.point, at = q.kdAxisArray[gt % dt], J = ht, tt = h(rt[it]) && h(ht[it]) ? Math.pow(rt[it] - ht[it], 2) : null, ot = h(rt[et]) && h(ht[et]) ? Math.pow(rt[et] - ht[et], 2) : null;
return ot = (tt || 0) + (ot || 0), ht.dist = h(ot) ? Math.sqrt(ot) : Number.MAX_VALUE, ht.distX = h(tt) ? Math.sqrt(tt) : Number.MAX_VALUE, at = rt[at] - ht[at], ot = 0 > at ? "left" : "right", tt = 0 > at ? "right" : "left", ct[ot] && (ot = $(rt, ct[ot], gt + 1, dt), J = ot[nt] < J[nt] ? ot : ht), ct[tt] && Math.sqrt(at * at) < J[nt] && (rt = $(rt, ct[tt], gt + 1, dt), J = rt[nt] < J[nt] ? rt : J), J;
}
var q = this, it = this.kdAxisArray[0], et = this.kdAxisArray[1], nt = G ? "distX" : "dist";
if (G = -1 < q.options.findNearestPointBy.indexOf("y") ? 2 : 1, this.kdTree || this.buildingKdTree || this.buildKDTree(z), this.kdTree)
return $(
k,
this.kdTree,
G,
G
);
}, Q.prototype.pointPlacementToXValue = function() {
var k = this.options, G = k.pointRange, z = this.xAxis;
return k = k.pointPlacement, k === "between" && (k = z.reversed ? -0.5 : 0.5), W(k) ? k * (G || z.pointRange) : 0;
}, Q.prototype.isPointInside = function(k) {
var G = this.chart, z = this.xAxis, $ = this.yAxis;
return typeof k.plotY < "u" && typeof k.plotX < "u" && 0 <= k.plotY && k.plotY <= ($ ? $.len : G.plotHeight) && 0 <= k.plotX && k.plotX <= (z ? z.len : G.plotWidth);
}, Q.prototype.drawTracker = function() {
var k = this, G = k.options, z = G.trackByArea, $ = [].concat(z ? k.areaPath : k.graphPath), q = k.chart, it = q.pointer, et = q.renderer, nt = q.options.tooltip.snap, rt = k.tracker, ct = function(dt) {
q.hoverSeries !== k && k.onMouseOver();
}, gt = "rgba(192,192,192," + (B ? 1e-4 : 2e-3) + ")";
rt ? rt.attr({ d: $ }) : k.graph && (k.tracker = et.path($).attr({ visibility: k.visible ? "visible" : "hidden", zIndex: 2 }).addClass(z ? "highcharts-tracker-area" : "highcharts-tracker-line").add(k.group), q.styledMode || k.tracker.attr({ "stroke-linecap": "round", "stroke-linejoin": "round", stroke: gt, fill: z ? gt : "none", "stroke-width": k.graph.strokeWidth() + (z ? 0 : 2 * nt) }), [k.tracker, k.markerGroup, k.dataLabelsGroup].forEach(function(dt) {
dt && (dt.addClass("highcharts-tracker").on("mouseover", ct).on("mouseout", function(ht) {
it.onTrackerMouseOut(ht);
}), G.cursor && !q.styledMode && dt.css({ cursor: G.cursor }), O) && dt.on("touchstart", ct);
})), A(this, "afterDrawTracker");
}, Q.prototype.addPoint = function(k, G, z, $, q) {
var it = this.options, et = this.data, nt = this.chart, rt = this.xAxis;
rt = rt && rt.hasNames && rt.names;
var ct = it.data, gt = this.xData, dt;
G = m(G, !0);
var ht = { series: this };
this.pointClass.prototype.applyOptions.apply(
ht,
[k]
);
var at = ht.x, J = gt.length;
if (this.requireSorting && at < gt[J - 1])
for (dt = !0; J && gt[J - 1] > at; )
J--;
this.updateParallelArrays(ht, "splice", J, 0, 0), this.updateParallelArrays(ht, J), rt && ht.name && (rt[at] = ht.name), ct.splice(J, 0, k), dt && (this.data.splice(J, 0, null), this.processData()), it.legendType === "point" && this.generatePoints(), z && (et[0] && et[0].remove ? et[0].remove(!1) : (et.shift(), this.updateParallelArrays(ht, "shift"), ct.shift())), q !== !1 && A(this, "addPoint", { point: ht }), this.isDirtyData = this.isDirty = !0, G && nt.redraw($);
}, Q.prototype.removePoint = function(k, G, z) {
var $ = this, q = $.data, it = q[k], et = $.points, nt = $.chart, rt = function() {
et && et.length === q.length && et.splice(k, 1), q.splice(k, 1), $.options.data.splice(k, 1), $.updateParallelArrays(it || { series: $ }, "splice", k, 1), it && it.destroy(), $.isDirty = !0, $.isDirtyData = !0, G && nt.redraw();
};
d(z, nt), G = m(G, !0), it ? it.firePointEvent("remove", null, rt) : rt();
}, Q.prototype.remove = function(k, G, z, $) {
function q() {
it.destroy($), et.isDirtyLegend = et.isDirtyBox = !0, et.linkSeries(), m(k, !0) && et.redraw(G);
}
var it = this, et = it.chart;
z !== !1 ? A(
it,
"remove",
null,
q
) : q();
}, Q.prototype.update = function(k, G) {
k = p(k, this.userOptions), A(this, "update", { options: k });
var z = this, $ = z.chart, q = z.userOptions, it = z.initialType || z.type, et = $.options.plotOptions, nt = b[it].prototype, rt = z.finishedAnimating && { animation: !1 }, ct = {}, gt, dt = ["eventOptions", "navigatorSeries", "baseSeries"], ht = k.type || q.type || $.options.chart.type, at = !(this.hasDerivedData || ht && ht !== this.type || typeof k.pointStart < "u" || typeof k.pointInterval < "u" || typeof k.relativeXValue < "u" || z.hasOptionChanged("dataGrouping") || z.hasOptionChanged("pointStart") || z.hasOptionChanged("pointInterval") || z.hasOptionChanged("pointIntervalUnit") || z.hasOptionChanged("keys"));
if (ht = ht || it, at && (dt.push("data", "isDirtyData", "points", "processedXData", "processedYData", "xIncrement", "cropped", "_hasPointMarkers", "_hasPointLabels", "clips", "nodes", "layout", "mapMap", "mapData", "minY", "maxY", "minX", "maxX"), k.visible !== !1 && dt.push("area", "graph"), z.parallelArrays.forEach(function(tt) {
dt.push(tt + "Data");
}), k.data && (k.dataSorting && s(z.options.dataSorting, k.dataSorting), this.setData(k.data, !1))), k = X(q, rt, { index: typeof q.index > "u" ? z.index : q.index, pointStart: m(et && et.series && et.series.pointStart, q.pointStart, z.xData[0]) }, !at && { data: z.options.data }, k), at && k.data && (k.data = z.options.data), dt = ["group", "markerGroup", "dataLabelsGroup", "transformGroup"].concat(dt), dt.forEach(function(tt) {
dt[tt] = z[tt], delete z[tt];
}), et = !1, b[ht]) {
if (et = ht !== z.type, z.remove(!1, !1, !1, !0), et)
if (Object.setPrototypeOf)
Object.setPrototypeOf(z, b[ht].prototype);
else {
rt = Object.hasOwnProperty.call(z, "hcEvents") && z.hcEvents;
for (gt in nt)
z[gt] = void 0;
s(z, b[ht].prototype), rt ? z.hcEvents = rt : delete z.hcEvents;
}
} else
t(17, !0, $, { missingModuleFor: ht });
if (dt.forEach(function(tt) {
z[tt] = dt[tt];
}), z.init($, k), at && this.points) {
var J = z.options;
J.visible === !1 ? (ct.graphic = 1, ct.dataLabel = 1) : z._hasPointLabels || (k = J.marker, nt = J.dataLabels, !k || k.enabled !== !1 && (q.marker && q.marker.symbol) === k.symbol || (ct.graphic = 1), nt && nt.enabled === !1 && (ct.dataLabel = 1)), this.points.forEach(function(tt) {
tt && tt.series && (tt.resolveColor(), Object.keys(ct).length && tt.destroyElements(ct), J.showInLegend === !1 && tt.legendItem && $.legend.destroyItem(tt));
}, this);
}
z.initialType = it, $.linkSeries(), et && z.linkedSeries.length && (z.isDirtyData = !0), A(this, "afterUpdate"), m(G, !0) && $.redraw(at ? void 0 : !1);
}, Q.prototype.setName = function(k) {
this.name = this.options.name = this.userOptions.name = k, this.chart.isDirtyLegend = !0;
}, Q.prototype.hasOptionChanged = function(k) {
var G = this.options[k], z = this.chart.options.plotOptions, $ = this.userOptions[k];
return $ ? G !== $ : G !== m(
z && z[this.type] && z[this.type][k],
z && z.series && z.series[k],
G
);
}, Q.prototype.onMouseOver = function() {
var k = this.chart, G = k.hoverSeries;
k.pointer.setHoverChartIndex(), G && G !== this && G.onMouseOut(), this.options.events.mouseOver && A(this, "mouseOver"), this.setState("hover"), k.hoverSeries = this;
}, Q.prototype.onMouseOut = function() {
var k = this.options, G = this.chart, z = G.tooltip, $ = G.hoverPoint;
G.hoverSeries = null, $ && $.onMouseOut(), this && k.events.mouseOut && A(this, "mouseOut"), !z || this.stickyTracking || z.shared && !this.noSharedTooltip || z.hide(), G.series.forEach(function(q) {
q.setState(
"",
!0
);
});
}, Q.prototype.setState = function(k, G) {
var z = this, $ = z.options, q = z.graph, it = $.inactiveOtherPoints, et = $.states, nt = m(et[k || "normal"] && et[k || "normal"].animation, z.chart.options.chart.animation), rt = $.lineWidth, ct = 0, gt = $.opacity;
if (k = k || "", z.state !== k && ([z.group, z.markerGroup, z.dataLabelsGroup].forEach(function(dt) {
dt && (z.state && dt.removeClass("highcharts-series-" + z.state), k && dt.addClass("highcharts-series-" + k));
}), z.state = k, !z.chart.styledMode)) {
if (et[k] && et[k].enabled === !1)
return;
if (k && (rt = et[k].lineWidth || rt + (et[k].lineWidthPlus || 0), gt = m(et[k].opacity, gt)), q && !q.dashstyle)
for ($ = { "stroke-width": rt }, q.animate($, nt); z["zone-graph-" + ct]; )
z["zone-graph-" + ct].animate($, nt), ct += 1;
it || [z.group, z.markerGroup, z.dataLabelsGroup, z.labelBySeries].forEach(function(dt) {
dt && dt.animate({ opacity: gt }, nt);
});
}
G && it && z.points && z.setAllPointsToState(k || void 0);
}, Q.prototype.setAllPointsToState = function(k) {
this.points.forEach(function(G) {
G.setState && G.setState(k);
});
}, Q.prototype.setVisible = function(k, G) {
var z = this, $ = z.chart, q = z.legendItem, it = $.options.chart.ignoreHiddenSeries, et = z.visible, nt = (z.visible = k = z.options.visible = z.userOptions.visible = typeof k > "u" ? !et : k) ? "show" : "hide";
["group", "dataLabelsGroup", "markerGroup", "tracker", "tt"].forEach(function(rt) {
z[rt] && z[rt][nt]();
}), ($.hoverSeries === z || ($.hoverPoint && $.hoverPoint.series) === z) && z.onMouseOut(), q && $.legend.colorizeItem(z, k), z.isDirty = !0, z.options.stacking && $.series.forEach(function(rt) {
rt.options.stacking && rt.visible && (rt.isDirty = !0);
}), z.linkedSeries.forEach(function(rt) {
rt.setVisible(k, !1);
}), it && ($.isDirtyBox = !0), A(z, nt), G !== !1 && $.redraw();
}, Q.prototype.show = function() {
this.setVisible(!0);
}, Q.prototype.hide = function() {
this.setVisible(!1);
}, Q.prototype.select = function(k) {
this.selected = k = this.options.selected = typeof k > "u" ? !this.selected : k, this.checkbox && (this.checkbox.checked = k), A(this, k ? "select" : "unselect");
}, Q.prototype.shouldShowTooltip = function(k, G, z) {
return z === void 0 && (z = {}), z.series = this, z.visiblePlotOnly = !0, this.chart.isInsidePlot(k, G, z);
}, Q.defaultOptions = F, Q;
}(), s(y.prototype, { axisTypes: [
"xAxis",
"yAxis"
], coll: "series", colorCounter: 0, cropShoulder: 1, directTouch: !1, drawLegendSymbol: H.drawLineMarker, isCartesian: !0, kdAxisArray: ["clientX", "plotY"], parallelArrays: ["x", "y"], pointClass: U, requireSorting: !0, sorted: !0 }), N.series = y, y;
}), E(l, "Extensions/ScrollablePlotArea.js", [l["Core/Animation/AnimationUtilities.js"], l["Core/Axis/Axis.js"], l["Core/Chart/Chart.js"], l["Core/Series/Series.js"], l["Core/Renderer/RendererRegistry.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H, U) {
var F = y.stop, N = U.addEvent, R = U.createElement, S = U.merge, v = U.pick;
N(I, "afterSetChartSize", function(d) {
var u = this.options.chart.scrollablePlotArea, T = u && u.minWidth;
if (u = u && u.minHeight, !this.renderer.forExport) {
if (T) {
if (this.scrollablePixelsX = T = Math.max(0, T - this.chartWidth)) {
this.scrollablePlotBox = this.renderer.scrollablePlotBox = S(this.plotBox), this.plotBox.width = this.plotWidth += T, this.inverted ? this.clipBox.height += T : this.clipBox.width += T;
var O = { 1: { name: "right", value: T } };
}
} else
u && (this.scrollablePixelsY = T = Math.max(
0,
u - this.chartHeight
)) && (this.scrollablePlotBox = this.renderer.scrollablePlotBox = S(this.plotBox), this.plotBox.height = this.plotHeight += T, this.inverted ? this.clipBox.width += T : this.clipBox.height += T, O = { 2: { name: "bottom", value: T } });
O && !d.skipAxes && this.axes.forEach(function(B) {
O[B.side] ? B.getPlotLinePath = function() {
var C = O[B.side].name, b = this[C];
this[C] = b - O[B.side].value;
var w = j.prototype.getPlotLinePath.apply(this, arguments);
return this[C] = b, w;
} : (B.setAxisSize(), B.setAxisTranslation());
});
}
}), N(I, "render", function() {
this.scrollablePixelsX || this.scrollablePixelsY ? (this.setUpScrolling && this.setUpScrolling(), this.applyFixed()) : this.fixedDiv && this.applyFixed();
}), I.prototype.setUpScrolling = function() {
var d = this, u = { WebkitOverflowScrolling: "touch", overflowX: "hidden", overflowY: "hidden" };
this.scrollablePixelsX && (u.overflowX = "auto"), this.scrollablePixelsY && (u.overflowY = "auto"), this.scrollingParent = R("div", { className: "highcharts-scrolling-parent" }, { position: "relative" }, this.renderTo), this.scrollingContainer = R(
"div",
{ className: "highcharts-scrolling" },
u,
this.scrollingParent
), N(this.scrollingContainer, "scroll", function() {
d.pointer && delete d.pointer.chartPosition;
}), this.innerContainer = R("div", { className: "highcharts-inner-container" }, null, this.scrollingContainer), this.innerContainer.appendChild(this.container), this.setUpScrolling = null;
}, I.prototype.moveFixedElements = function() {
var d = this.container, u = this.fixedRenderer, T = ".highcharts-contextbutton .highcharts-credits .highcharts-legend .highcharts-legend-checkbox .highcharts-navigator-series .highcharts-navigator-xaxis .highcharts-navigator-yaxis .highcharts-navigator .highcharts-reset-zoom .highcharts-drillup-button .highcharts-scrollbar .highcharts-subtitle .highcharts-title".split(" "), O;
this.scrollablePixelsX && !this.inverted ? O = ".highcharts-yaxis" : this.scrollablePixelsX && this.inverted || this.scrollablePixelsY && !this.inverted ? O = ".highcharts-xaxis" : this.scrollablePixelsY && this.inverted && (O = ".highcharts-yaxis"), O && T.push(O + ":not(.highcharts-radial-axis)", O + "-labels:not(.highcharts-radial-axis-labels)"), T.forEach(function(B) {
[].forEach.call(d.querySelectorAll(B), function(C) {
(C.namespaceURI === u.SVG_NS ? u.box : u.box.parentNode).appendChild(C), C.style.pointerEvents = "auto";
});
});
}, I.prototype.applyFixed = function() {
var d = !this.fixedDiv, u = this.options.chart, T = u.scrollablePlotArea, O = H.getRendererType();
d ? (this.fixedDiv = R("div", { className: "highcharts-fixed" }, { position: "absolute", overflow: "hidden", pointerEvents: "none", zIndex: (u.style && u.style.zIndex || 0) + 2, top: 0 }, null, !0), this.scrollingContainer && this.scrollingContainer.parentNode.insertBefore(this.fixedDiv, this.scrollingContainer), this.renderTo.style.overflow = "visible", this.fixedRenderer = u = new O(
this.fixedDiv,
this.chartWidth,
this.chartHeight,
this.options.chart.style
), this.scrollableMask = u.path().attr({ fill: this.options.chart.backgroundColor || "#fff", "fill-opacity": v(T.opacity, 0.85), zIndex: -1 }).addClass("highcharts-scrollable-mask").add(), N(this, "afterShowResetZoom", this.moveFixedElements), N(this, "afterDrilldown", this.moveFixedElements), N(this, "afterLayOutTitles", this.moveFixedElements)) : this.fixedRenderer.setSize(this.chartWidth, this.chartHeight), (this.scrollableDirty || d) && (this.scrollableDirty = !1, this.moveFixedElements()), u = this.chartWidth + (this.scrollablePixelsX || 0), O = this.chartHeight + (this.scrollablePixelsY || 0), F(this.container), this.container.style.width = u + "px", this.container.style.height = O + "px", this.renderer.boxWrapper.attr({ width: u, height: O, viewBox: [0, 0, u, O].join(" ") }), this.chartBackground.attr({ width: u, height: O }), this.scrollingContainer.style.height = this.chartHeight + "px", d && (T.scrollPositionX && (this.scrollingContainer.scrollLeft = this.scrollablePixelsX * T.scrollPositionX), T.scrollPositionY && (this.scrollingContainer.scrollTop = this.scrollablePixelsY * T.scrollPositionY)), O = this.axisOffset, d = this.plotTop - O[0] - 1, T = this.plotLeft - O[3] - 1, u = this.plotTop + this.plotHeight + O[2] + 1, O = this.plotLeft + this.plotWidth + O[1] + 1;
var B = this.plotLeft + this.plotWidth - (this.scrollablePixelsX || 0), C = this.plotTop + this.plotHeight - (this.scrollablePixelsY || 0);
d = this.scrollablePixelsX ? [["M", 0, d], ["L", this.plotLeft - 1, d], ["L", this.plotLeft - 1, u], ["L", 0, u], ["Z"], ["M", B, d], ["L", this.chartWidth, d], ["L", this.chartWidth, u], ["L", B, u], ["Z"]] : this.scrollablePixelsY ? [["M", T, 0], ["L", T, this.plotTop - 1], ["L", O, this.plotTop - 1], ["L", O, 0], ["Z"], ["M", T, C], ["L", T, this.chartHeight], ["L", O, this.chartHeight], ["L", O, C], ["Z"]] : [["M", 0, 0]], this.redrawTrigger !== "adjustHeight" && this.scrollableMask.attr({ d });
}, N(j, "afterInit", function() {
this.chart.scrollableDirty = !0;
}), N(Z, "show", function() {
this.chart.scrollableDirty = !0;
});
}), E(l, "Core/Axis/StackingAxis.js", [l["Core/Animation/AnimationUtilities.js"], l["Core/Axis/Axis.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = y.getDeferredAnimation, H = I.addEvent, U = I.destroyObjectProperties, F = I.fireEvent, N = I.isNumber, R = I.objectEach, S;
return function(v) {
function d() {
var B = this.stacking;
if (B) {
var C = B.stacks;
R(C, function(b, w) {
U(b), C[w] = null;
}), B && B.stackTotalGroup && B.stackTotalGroup.destroy();
}
}
function u() {
this.stacking || (this.stacking = new O(this));
}
var T = [];
v.compose = function(B) {
return T.indexOf(B) === -1 && (T.push(B), H(B, "init", u), H(B, "destroy", d)), B;
};
var O = function() {
function B(C) {
this.oldStacks = {}, this.stacks = {}, this.stacksTouched = 0, this.axis = C;
}
return B.prototype.buildStacks = function() {
var C = this.axis, b = C.series, w = C.options.reversedStacks, x = b.length, a;
if (!C.isXAxis) {
for (this.usePercentage = !1, a = x; a--; ) {
var c = b[w ? a : x - a - 1];
c.setStackedPoints(), c.setGroupedPoints();
}
for (a = 0; a < x; a++)
b[a].modifyStacks();
F(C, "afterBuildStacks");
}
}, B.prototype.cleanStacks = function() {
if (!this.axis.isXAxis) {
if (this.oldStacks)
var C = this.stacks = this.oldStacks;
R(C, function(b) {
R(b, function(w) {
w.cumulative = w.total;
});
});
}
}, B.prototype.resetStacks = function() {
var C = this, b = C.stacks;
C.axis.isXAxis || R(b, function(w) {
R(
w,
function(x, a) {
N(x.touched) && x.touched < C.stacksTouched ? (x.destroy(), delete w[a]) : (x.total = null, x.cumulative = null);
}
);
});
}, B.prototype.renderStackTotals = function() {
var C = this.axis, b = C.chart, w = b.renderer, x = this.stacks;
C = Z(b, C.options.stackLabels && C.options.stackLabels.animation || !1);
var a = this.stackTotalGroup = this.stackTotalGroup || w.g("stack-labels").attr({ visibility: "visible", zIndex: 6, opacity: 0 }).add();
a.translate(b.plotLeft, b.plotTop), R(x, function(c) {
R(c, function(p) {
p.render(a);
});
}), a.animate(
{ opacity: 1 },
C
);
}, B;
}();
v.Additions = O;
}(S || (S = {})), S;
}), E(l, "Extensions/Stacking.js", [l["Core/Axis/Axis.js"], l["Core/Chart/Chart.js"], l["Core/FormatUtilities.js"], l["Core/Globals.js"], l["Core/Series/Series.js"], l["Core/Axis/StackingAxis.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H, U, F) {
var N = I.format, R = F.correctFloat, S = F.defined, v = F.destroyObjectProperties, d = F.isArray, u = F.isNumber, T = F.objectEach, O = F.pick, B = function() {
function C(b, w, x, a, c) {
var p = b.chart.inverted;
this.axis = b, this.isNegative = x, this.options = w = w || {}, this.x = a, this.total = null, this.points = {}, this.hasValidPoints = !1, this.stack = c, this.rightCliff = this.leftCliff = 0, this.alignOptions = { align: w.align || (p ? x ? "left" : "right" : "center"), verticalAlign: w.verticalAlign || (p ? "middle" : x ? "bottom" : "top"), y: w.y, x: w.x }, this.textAlign = w.textAlign || (p ? x ? "right" : "left" : "center");
}
return C.prototype.destroy = function() {
v(this, this.axis);
}, C.prototype.render = function(b) {
var w = this.axis.chart, x = this.options, a = x.format;
a = a ? N(a, this, w) : x.formatter.call(this), this.label ? this.label.attr({
text: a,
visibility: "hidden"
}) : (this.label = w.renderer.label(a, null, null, x.shape, null, null, x.useHTML, !1, "stack-labels"), a = { r: x.borderRadius || 0, text: a, rotation: x.rotation, padding: O(x.padding, 5), visibility: "hidden" }, w.styledMode || (a.fill = x.backgroundColor, a.stroke = x.borderColor, a["stroke-width"] = x.borderWidth, this.label.css(x.style)), this.label.attr(a), this.label.added || this.label.add(b)), this.label.labelrank = w.plotSizeY;
}, C.prototype.setOffset = function(b, w, x, a, c) {
var p = this.axis, i = p.chart;
a = p.translate(p.stacking.usePercentage ? 100 : a || this.total, 0, 0, 0, 1), x = p.translate(x || 0), x = S(a) && Math.abs(a - x), b = O(c, i.xAxis[0].translate(this.x)) + b, p = S(a) && this.getStackBox(i, this, b, a, w, x, p), w = this.label, x = this.isNegative, b = O(this.options.overflow, "justify") === "justify";
var h = this.textAlign;
w && p && (c = w.getBBox(), a = w.padding, h = h === "left" ? i.inverted ? -a : a : h === "right" ? c.width : i.inverted && h === "center" ? c.width / 2 : i.inverted ? x ? c.width + a : -a : c.width / 2, x = i.inverted ? c.height / 2 : x ? -a : c.height, this.alignOptions.x = O(this.options.x, 0), this.alignOptions.y = O(this.options.y, 0), p.x -= h, p.y -= x, w.align(this.alignOptions, null, p), i.isInsidePlot(w.alignAttr.x + h - this.alignOptions.x, w.alignAttr.y + x - this.alignOptions.y) ? w.show() : (w.alignAttr.y = -9999, b = !1), b && H.prototype.justifyDataLabel.call(this.axis, w, this.alignOptions, w.alignAttr, c, p), w.attr({ x: w.alignAttr.x, y: w.alignAttr.y }), O(!b && this.options.crop, !0) && ((i = u(w.x) && u(w.y) && i.isInsidePlot(w.x - a + w.width, w.y) && i.isInsidePlot(w.x + a, w.y)) || w.hide()));
}, C.prototype.getStackBox = function(b, w, x, a, c, p, i) {
var h = w.axis.reversed, o = b.inverted, t = i.height + i.pos - (o ? b.plotLeft : b.plotTop);
return w = w.isNegative && !h || !w.isNegative && h, { x: o ? w ? a - i.right : a - p + i.pos - b.plotLeft : x + b.xAxis[0].transB - b.plotLeft, y: o ? i.height - x - c : w ? t - a - p : t - a, width: o ? p : c, height: o ? c : p };
}, C;
}();
return j.prototype.getStacks = function() {
var C = this, b = C.inverted;
C.yAxis.forEach(function(w) {
w.stacking && w.stacking.stacks && w.hasVisibleSeries && (w.stacking.oldStacks = w.stacking.stacks);
}), C.series.forEach(function(w) {
var x = w.xAxis && w.xAxis.options || {};
!w.options.stacking || w.visible !== !0 && C.options.chart.ignoreHiddenSeries !== !1 || (w.stackKey = [w.type, O(w.options.stack, ""), b ? x.top : x.left, b ? x.height : x.width].join());
});
}, U.compose(y), H.prototype.setGroupedPoints = function() {
var C = this.yAxis.stacking;
this.options.centerInCategory && (this.is("column") || this.is("columnrange")) && !this.options.stacking && 1 < this.chart.series.length ? H.prototype.setStackedPoints.call(this, "group") : C && T(C.stacks, function(b, w) {
w.slice(-5) === "group" && (T(b, function(x) {
return x.destroy();
}), delete C.stacks[w]);
});
}, H.prototype.setStackedPoints = function(C) {
var b = C || this.options.stacking;
if (b && (this.visible === !0 || this.chart.options.chart.ignoreHiddenSeries === !1)) {
var w = this.processedXData, x = this.processedYData, a = [], c = x.length, p = this.options, i = p.threshold, h = O(p.startFromThreshold && i, 0);
p = p.stack, C = C ? this.type + "," + b : this.stackKey;
var o = "-" + C, t = this.negStacks, s = this.yAxis, n = s.stacking.stacks, A = s.stacking.oldStacks, _, D;
for (s.stacking.stacksTouched += 1, D = 0; D < c; D++) {
var W = w[D], P = x[D], X = this.getStackIndicator(
X,
W,
this.index
), g = X.key, m = (_ = t && P < (h ? 0 : i)) ? o : C;
n[m] || (n[m] = {}), n[m][W] || (A[m] && A[m][W] ? (n[m][W] = A[m][W], n[m][W].total = null) : n[m][W] = new B(s, s.options.stackLabels, _, W, p)), m = n[m][W], P !== null ? (m.points[g] = m.points[this.index] = [O(m.cumulative, h)], S(m.cumulative) || (m.base = g), m.touched = s.stacking.stacksTouched, 0 < X.index && this.singleStacks === !1 && (m.points[g][0] = m.points[this.index + "," + W + ",0"][0])) : m.points[g] = m.points[this.index] = null, b === "percent" ? (_ = _ ? C : o, t && n[_] && n[_][W] ? (_ = n[_][W], m.total = _.total = Math.max(_.total, m.total) + Math.abs(P) || 0) : m.total = R(m.total + (Math.abs(P) || 0))) : b === "group" ? (d(P) && (P = P[0]), P !== null && (m.total = (m.total || 0) + 1)) : m.total = R(m.total + (P || 0)), m.cumulative = b === "group" ? (m.total || 1) - 1 : O(m.cumulative, h) + (P || 0), P !== null && (m.points[g].push(m.cumulative), a[D] = m.cumulative, m.hasValidPoints = !0);
}
b === "percent" && (s.stacking.usePercentage = !0), b !== "group" && (this.stackedYData = a), s.stacking.oldStacks = {};
}
}, H.prototype.modifyStacks = function() {
var C = this, b = C.stackKey, w = C.yAxis.stacking.stacks, x = C.processedXData, a, c = C.options.stacking;
C[c + "Stacker"] && [b, "-" + b].forEach(function(p) {
for (var i = x.length, h, o; i--; )
h = x[i], a = C.getStackIndicator(a, h, C.index, p), (o = (h = w[p] && w[p][h]) && h.points[a.key]) && C[c + "Stacker"](o, h, i);
});
}, H.prototype.percentStacker = function(C, b, w) {
b = b.total ? 100 / b.total : 0, C[0] = R(C[0] * b), C[1] = R(C[1] * b), this.stackedYData[w] = C[1];
}, H.prototype.getStackIndicator = function(C, b, w, x) {
return !S(C) || C.x !== b || x && C.key !== x ? C = { x: b, index: 0, key: x } : C.index++, C.key = [w, b, C.index].join(), C;
}, Z.StackItem = B, Z.StackItem;
}), E(l, "Series/Line/LineSeries.js", [l["Core/Series/Series.js"], l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = this && this.__extends || function() {
var F = function(N, R) {
return F = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(S, v) {
S.__proto__ = v;
} || function(S, v) {
for (var d in v)
v.hasOwnProperty(d) && (S[d] = v[d]);
}, F(N, R);
};
return function(N, R) {
function S() {
this.constructor = N;
}
F(N, R), N.prototype = R === null ? Object.create(R) : (S.prototype = R.prototype, new S());
};
}(), H = I.defined, U = I.merge;
return I = function(F) {
function N() {
var R = F !== null && F.apply(this, arguments) || this;
return R.data = void 0, R.options = void 0, R.points = void 0, R;
}
return Z(N, F), N.prototype.drawGraph = function() {
var R = this, S = this.options, v = (this.gappedPath || this.getGraphPath).call(this), d = this.chart.styledMode, u = [["graph", "highcharts-graph"]];
d || u[0].push(S.lineColor || this.color || "#cccccc", S.dashStyle), u = R.getZonesGraphs(u), u.forEach(function(T, O) {
var B = T[0], C = R[B], b = C ? "animate" : "attr";
C ? (C.endX = R.preventGraphAnimation ? null : v.xMap, C.animate({ d: v })) : v.length && (R[B] = C = R.chart.renderer.path(v).addClass(T[1]).attr({ zIndex: 1 }).add(R.group)), C && !d && (B = { stroke: T[2], "stroke-width": S.lineWidth, fill: R.fillGraph && R.color || "none" }, T[3] ? B.dashstyle = T[3] : S.linecap !== "square" && (B["stroke-linecap"] = B["stroke-linejoin"] = "round"), C[b](B).shadow(2 > O && S.shadow)), C && (C.startX = v.xMap, C.isArea = v.isArea);
});
}, N.prototype.getGraphPath = function(R, S, v) {
var d = this, u = d.options, T = [], O = [], B, C = u.step;
R = R || d.points;
var b = R.reversed;
return b && R.reverse(), (C = { right: 1, center: 2 }[C] || C && 3) && b && (C = 4 - C), R = this.getValidPoints(R, !1, !(u.connectNulls && !S && !v)), R.forEach(function(w, x) {
var a = w.plotX, c = w.plotY, p = R[x - 1];
(w.leftCliff || p && p.rightCliff) && !v && (B = !0), w.isNull && !H(S) && 0 < x ? B = !u.connectNulls : w.isNull && !S ? B = !0 : (x === 0 || B ? x = [["M", w.plotX, w.plotY]] : d.getPointSpline ? x = [d.getPointSpline(R, w, x)] : C ? (x = C === 1 ? [["L", p.plotX, c]] : C === 2 ? [["L", (p.plotX + a) / 2, p.plotY], ["L", (p.plotX + a) / 2, c]] : [["L", a, p.plotY]], x.push(["L", a, c])) : x = [["L", a, c]], O.push(w.x), C && (O.push(w.x), C === 2 && O.push(w.x)), T.push.apply(T, x), B = !1);
}), T.xMap = O, d.graphPath = T;
}, N.prototype.getZonesGraphs = function(R) {
return this.zones.forEach(function(S, v) {
v = ["zone-graph-" + v, "highcharts-graph highcharts-zone-graph-" + v + " " + (S.className || "")], this.chart.styledMode || v.push(S.color || this.color, S.dashStyle || this.options.dashStyle), R.push(v);
}, this), R;
}, N.defaultOptions = U(y.defaultOptions, {}), N;
}(y), j.registerSeriesType("line", I), I;
}), E(l, "Series/Area/AreaSeries.js", [
l["Core/Color/Color.js"],
l["Core/Legend/LegendSymbol.js"],
l["Core/Series/SeriesRegistry.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z) {
var H = this && this.__extends || function() {
var v = function(d, u) {
return v = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(T, O) {
T.__proto__ = O;
} || function(T, O) {
for (var B in O)
O.hasOwnProperty(B) && (T[B] = O[B]);
}, v(d, u);
};
return function(d, u) {
function T() {
this.constructor = d;
}
v(d, u), d.prototype = u === null ? Object.create(u) : (T.prototype = u.prototype, new T());
};
}(), U = y.parse, F = I.seriesTypes.line;
y = Z.extend;
var N = Z.merge, R = Z.objectEach, S = Z.pick;
return Z = function(v) {
function d() {
var u = v !== null && v.apply(this, arguments) || this;
return u.data = void 0, u.options = void 0, u.points = void 0, u;
}
return H(d, v), d.prototype.drawGraph = function() {
this.areaPath = [], v.prototype.drawGraph.apply(this);
var u = this, T = this.areaPath, O = this.options, B = [["area", "highcharts-area", this.color, O.fillColor]];
this.zones.forEach(function(C, b) {
B.push(["zone-area-" + b, "highcharts-area highcharts-zone-area-" + b + " " + C.className, C.color || u.color, C.fillColor || O.fillColor]);
}), B.forEach(function(C) {
var b = C[0], w = u[b], x = w ? "animate" : "attr", a = {};
w ? (w.endX = u.preventGraphAnimation ? null : T.xMap, w.animate({ d: T })) : (a.zIndex = 0, w = u[b] = u.chart.renderer.path(T).addClass(C[1]).add(u.group), w.isArea = !0), u.chart.styledMode || (a.fill = S(C[3], U(C[2]).setOpacity(S(O.fillOpacity, 0.75)).get())), w[x](a), w.startX = T.xMap, w.shiftUnit = O.step ? 2 : 1;
});
}, d.prototype.getGraphPath = function(u) {
var T = F.prototype.getGraphPath, O = this.options, B = O.stacking, C = this.yAxis, b, w = [], x = [], a = this.index, c = C.stacking.stacks[this.stackKey], p = O.threshold, i = Math.round(C.getThreshold(O.threshold));
O = S(O.connectNulls, B === "percent");
var h = function(n, A, _) {
var D = u[n];
n = B && c[D.x].points[a];
var W = D[_ + "Null"] || 0;
if (_ = D[_ + "Cliff"] || 0, D = !0, _ || W) {
var P = (W ? n[0] : n[1]) + _, X = n[0] + _;
D = !!W;
} else
!B && u[A] && u[A].isNull && (P = X = p);
typeof P < "u" && (x.push({ plotX: t, plotY: P === null ? i : C.getThreshold(P), isNull: D, isCliff: !0 }), w.push({ plotX: t, plotY: X === null ? i : C.getThreshold(X), doCurve: !1 }));
};
for (u = u || this.points, B && (u = this.getStackPoints(u)), b = 0; b < u.length; b++) {
B || (u[b].leftCliff = u[b].rightCliff = u[b].leftNull = u[b].rightNull = void 0);
var o = u[b].isNull, t = S(u[b].rectPlotX, u[b].plotX), s = B ? S(u[b].yBottom, i) : i;
(!o || O) && (O || h(b, b - 1, "left"), o && !B && O || (x.push(u[b]), w.push({ x: b, plotX: t, plotY: s })), O || h(b, b + 1, "right"));
}
return b = T.call(this, x, !0, !0), w.reversed = !0, o = T.call(this, w, !0, !0), (s = o[0]) && s[0] === "M" && (o[0] = ["L", s[1], s[2]]), o = b.concat(o), o.length && o.push(["Z"]), T = T.call(this, x, !1, O), o.xMap = b.xMap, this.areaPath = o, T;
}, d.prototype.getStackPoints = function(u) {
var T = this, O = [], B = [], C = this.xAxis, b = this.yAxis, w = b.stacking.stacks[this.stackKey], x = {}, a = b.series, c = a.length, p = b.options.reversedStacks ? 1 : -1, i = a.indexOf(T);
if (u = u || this.points, this.options.stacking) {
for (var h = 0; h < u.length; h++)
u[h].leftNull = u[h].rightNull = void 0, x[u[h].x] = u[h];
R(w, function(t, s) {
t.total !== null && B.push(s);
}), B.sort(function(t, s) {
return t - s;
});
var o = a.map(function(t) {
return t.visible;
});
B.forEach(function(t, s) {
var n = 0, A, _;
if (x[t] && !x[t].isNull)
O.push(x[t]), [-1, 1].forEach(function(W) {
var P = W === 1 ? "rightNull" : "leftNull", X = 0, g = w[B[s + W]];
if (g)
for (var m = i; 0 <= m && m < c; ) {
var L = a[m].index;
A = g.points[L], A || (L === T.index ? x[t][P] = !0 : o[m] && (_ = w[t].points[L]) && (X -= _[1] - _[0])), m += p;
}
x[t][W === 1 ? "rightCliff" : "leftCliff"] = X;
});
else {
for (var D = i; 0 <= D && D < c; ) {
if (A = w[t].points[a[D].index]) {
n = A[1];
break;
}
D += p;
}
n = S(n, 0), n = b.translate(n, 0, 1, 0, 1), O.push({ isNull: !0, plotX: C.translate(t, 0, 0, 0, 1), x: t, plotY: n, yBottom: n });
}
});
}
return O;
}, d.defaultOptions = N(F.defaultOptions, { threshold: 0 }), d;
}(F), y(Z.prototype, {
singleStacks: !1,
drawLegendSymbol: j.drawRectangle
}), I.registerSeriesType("area", Z), Z;
}), E(l, "Series/Spline/SplineSeries.js", [l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]], function(y, j) {
var I = this && this.__extends || function() {
var F = function(N, R) {
return F = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(S, v) {
S.__proto__ = v;
} || function(S, v) {
for (var d in v)
v.hasOwnProperty(d) && (S[d] = v[d]);
}, F(N, R);
};
return function(N, R) {
function S() {
this.constructor = N;
}
F(N, R), N.prototype = R === null ? Object.create(R) : (S.prototype = R.prototype, new S());
};
}(), Z = y.seriesTypes.line, H = j.merge, U = j.pick;
return j = function(F) {
function N() {
var R = F !== null && F.apply(this, arguments) || this;
return R.data = void 0, R.options = void 0, R.points = void 0, R;
}
return I(N, F), N.prototype.getPointSpline = function(R, S, v) {
var d = S.plotX || 0, u = S.plotY || 0, T = R[v - 1];
if (v = R[v + 1], T && !T.isNull && T.doCurve !== !1 && !S.isCliff && v && !v.isNull && v.doCurve !== !1 && !S.isCliff) {
R = T.plotY || 0;
var O = v.plotX || 0;
v = v.plotY || 0;
var B = 0, C = (1.5 * d + (T.plotX || 0)) / 2.5, b = (1.5 * u + R) / 2.5;
O = (1.5 * d + O) / 2.5;
var w = (1.5 * u + v) / 2.5;
O !== C && (B = (w - b) * (O - d) / (O - C) + u - w), b += B, w += B, b > R && b > u ? (b = Math.max(R, u), w = 2 * u - b) : b < R && b < u && (b = Math.min(R, u), w = 2 * u - b), w > v && w > u ? (w = Math.max(v, u), b = 2 * u - w) : w < v && w < u && (w = Math.min(v, u), b = 2 * u - w), S.rightContX = O, S.rightContY = w;
}
return S = ["C", U(T.rightContX, T.plotX, 0), U(T.rightContY, T.plotY, 0), U(C, d, 0), U(b, u, 0), d, u], T.rightContX = T.rightContY = void 0, S;
}, N.defaultOptions = H(Z.defaultOptions), N;
}(Z), y.registerSeriesType("spline", j), j;
}), E(
l,
"Series/AreaSpline/AreaSplineSeries.js",
[l["Series/Area/AreaSeries.js"], l["Series/Spline/SplineSeries.js"], l["Core/Legend/LegendSymbol.js"], l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]],
function(y, j, I, Z, H) {
var U = this && this.__extends || function() {
var S = function(v, d) {
return S = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(u, T) {
u.__proto__ = T;
} || function(u, T) {
for (var O in T)
T.hasOwnProperty(O) && (u[O] = T[O]);
}, S(v, d);
};
return function(v, d) {
function u() {
this.constructor = v;
}
S(v, d), v.prototype = d === null ? Object.create(d) : (u.prototype = d.prototype, new u());
};
}(), F = y.prototype, N = H.extend, R = H.merge;
return H = function(S) {
function v() {
var d = S !== null && S.apply(this, arguments) || this;
return d.data = void 0, d.points = void 0, d.options = void 0, d;
}
return U(v, S), v.defaultOptions = R(j.defaultOptions, y.defaultOptions), v;
}(j), N(H.prototype, { getGraphPath: F.getGraphPath, getStackPoints: F.getStackPoints, drawGraph: F.drawGraph, drawLegendSymbol: I.drawRectangle }), Z.registerSeriesType("areaspline", H), H;
}
), E(l, "Series/Column/ColumnSeries.js", [
l["Core/Animation/AnimationUtilities.js"],
l["Core/Color/Color.js"],
l["Core/Globals.js"],
l["Core/Legend/LegendSymbol.js"],
l["Core/Series/Series.js"],
l["Core/Series/SeriesRegistry.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z, H, U, F) {
var N = this && this.__extends || function() {
var c = function(p, i) {
return c = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(h, o) {
h.__proto__ = o;
} || function(h, o) {
for (var t in o)
o.hasOwnProperty(t) && (h[t] = o[t]);
}, c(p, i);
};
return function(p, i) {
function h() {
this.constructor = p;
}
c(p, i), p.prototype = i === null ? Object.create(i) : (h.prototype = i.prototype, new h());
};
}(), R = y.animObject, S = j.parse, v = I.hasTouch;
y = I.noop;
var d = F.clamp, u = F.css, T = F.defined, O = F.extend, B = F.fireEvent, C = F.isArray, b = F.isNumber, w = F.merge, x = F.pick, a = F.objectEach;
return F = function(c) {
function p() {
var i = c !== null && c.apply(this, arguments) || this;
return i.borderWidth = void 0, i.data = void 0, i.group = void 0, i.options = void 0, i.points = void 0, i;
}
return N(p, c), p.prototype.animate = function(i) {
var h = this, o = this.yAxis, t = h.options, s = this.chart.inverted, n = {}, A = s ? "translateX" : "translateY";
if (i)
n.scaleY = 1e-3, i = d(o.toPixels(t.threshold), o.pos, o.pos + o.len), s ? n.translateX = i - o.len : n.translateY = i, h.clipBox && h.setClip(), h.group.attr(n);
else {
var _ = Number(h.group.attr(A));
h.group.animate({ scaleY: 1 }, O(R(h.options.animation), { step: function(D, W) {
h.group && (n[A] = _ + W.pos * (o.pos - _), h.group.attr(n));
} }));
}
}, p.prototype.init = function(i, h) {
c.prototype.init.apply(this, arguments);
var o = this;
i = o.chart, i.hasRendered && i.series.forEach(function(t) {
t.type === o.type && (t.isDirty = !0);
});
}, p.prototype.getColumnMetrics = function() {
var i = this, h = i.options, o = i.xAxis, t = i.yAxis, s = o.options.reversedStacks;
s = o.reversed && !s || !o.reversed && s;
var n = {}, A, _ = 0;
h.grouping === !1 ? _ = 1 : i.chart.series.forEach(function(X) {
var g = X.yAxis, m = X.options;
if (X.type === i.type && (X.visible || !i.chart.options.chart.ignoreHiddenSeries) && t.len === g.len && t.pos === g.pos) {
if (m.stacking && m.stacking !== "group") {
A = X.stackKey, typeof n[A] > "u" && (n[A] = _++);
var L = n[A];
} else
m.grouping !== !1 && (L = _++);
X.columnIndex = L;
}
});
var D = Math.min(Math.abs(o.transA) * (o.ordinal && o.ordinal.slope || h.pointRange || o.closestPointRange || o.tickInterval || 1), o.len), W = D * h.groupPadding, P = (D - 2 * W) / (_ || 1);
return h = Math.min(h.maxPointWidth || o.len, x(h.pointWidth, P * (1 - 2 * h.pointPadding))), i.columnMetrics = { width: h, offset: (P - h) / 2 + (W + ((i.columnIndex || 0) + (s ? 1 : 0)) * P - D / 2) * (s ? -1 : 1), paddedWidth: P, columnCount: _ }, i.columnMetrics;
}, p.prototype.crispCol = function(i, h, o, t) {
var s = this.chart, n = this.borderWidth, A = -(n % 2 ? 0.5 : 0);
return n = n % 2 ? 0.5 : 1, s.inverted && s.renderer.isVML && (n += 1), this.options.crisp && (o = Math.round(i + o) + A, i = Math.round(i) + A, o -= i), t = Math.round(h + t) + n, A = 0.5 >= Math.abs(h) && 0.5 < t, h = Math.round(h) + n, t -= h, A && t && (--h, t += 1), { x: i, y: h, width: o, height: t };
}, p.prototype.adjustForMissingColumns = function(i, h, o, t) {
var s = this, n = this.options.stacking;
if (!o.isNull && 1 < t.columnCount) {
var A = 0, _ = 0;
a(this.yAxis.stacking && this.yAxis.stacking.stacks, function(D) {
if (typeof o.x == "number" && (D = D[o.x.toString()])) {
var W = D.points[s.index], P = D.total;
n ? (W && (A = _), D.hasValidPoints && _++) : C(W) && (A = W[1], _ = P || 0);
}
}), i = (o.plotX || 0) + ((_ - 1) * t.paddedWidth + h) / 2 - h - A * t.paddedWidth;
}
return i;
}, p.prototype.translate = function() {
var i = this, h = i.chart, o = i.options, t = i.dense = 2 > i.closestPointRange * i.xAxis.transA;
t = i.borderWidth = x(o.borderWidth, t ? 0 : 1);
var s = i.xAxis, n = i.yAxis, A = o.threshold, _ = i.translatedThreshold = n.getThreshold(A), D = x(o.minPointLength, 5), W = i.getColumnMetrics(), P = W.width, X = i.pointXOffset = W.offset, g = i.dataMin, m = i.dataMax, L = i.barW = Math.max(P, 1 + 2 * t);
h.inverted && (_ -= 0.5), o.pointPadding && (L = Math.ceil(L)), H.prototype.translate.apply(i), i.points.forEach(function(Y) {
var V = x(Y.yBottom, _), Q = 999 + Math.abs(V), k = Y.plotX || 0;
Q = d(Y.plotY, -Q, n.len + Q);
var G = Math.min(Q, V), z = Math.max(Q, V) - G, $ = P, q = k + X, it = L;
D && Math.abs(z) < D && (z = D, k = !n.reversed && !Y.negative || n.reversed && Y.negative, b(A) && b(m) && Y.y === A && m <= A && (n.min || 0) < A && (g !== m || (n.max || 0) <= A) && (k = !k), G = Math.abs(G - _) > D ? V - D : _ - (k ? D : 0)), T(Y.options.pointWidth) && ($ = it = Math.ceil(Y.options.pointWidth), q -= Math.round(($ - P) / 2)), o.centerInCategory && (q = i.adjustForMissingColumns(q, $, Y, W)), Y.barX = q, Y.pointWidth = $, Y.tooltipPos = h.inverted ? [d(n.len + n.pos - h.plotLeft - Q, n.pos - h.plotLeft, n.len + n.pos - h.plotLeft), s.len + s.pos - h.plotTop - q - it / 2, z] : [s.left - h.plotLeft + q + it / 2, d(Q + n.pos - h.plotTop, n.pos - h.plotTop, n.len + n.pos - h.plotTop), z], Y.shapeType = i.pointClass.prototype.shapeType || "rect", Y.shapeArgs = i.crispCol.apply(i, Y.isNull ? [q, _, it, 0] : [q, G, it, z]);
});
}, p.prototype.drawGraph = function() {
this.group[this.dense ? "addClass" : "removeClass"]("highcharts-dense-data");
}, p.prototype.pointAttribs = function(i, h) {
var o = this.options, t = this.pointAttrToOptions || {}, s = t.stroke || "borderColor", n = t["stroke-width"] || "borderWidth", A = i && i.color || this.color, _ = i && i[s] || o[s] || A;
t = i && i.options.dashStyle || o.dashStyle;
var D = i && i[n] || o[n] || this[n] || 0, W = x(i && i.opacity, o.opacity, 1);
if (i && this.zones.length) {
var P = i.getZone();
A = i.options.color || P && (P.color || i.nonZonedColor) || this.color, P && (_ = P.borderColor || _, t = P.dashStyle || t, D = P.borderWidth || D);
}
return h && i && (i = w(o.states[h], i.options.states && i.options.states[h] || {}), h = i.brightness, A = i.color || typeof h < "u" && S(A).brighten(i.brightness).get() || A, _ = i[s] || _, D = i[n] || D, t = i.dashStyle || t, W = x(i.opacity, W)), s = { fill: A, stroke: _, "stroke-width": D, opacity: W }, t && (s.dashstyle = t), s;
}, p.prototype.drawPoints = function() {
var i = this, h = this.chart, o = i.options, t = h.renderer, s = o.animationLimit || 250, n;
i.points.forEach(function(A) {
var _ = A.graphic, D = !!_, W = _ && h.pointCount < s ? "animate" : "attr";
b(A.plotY) && A.y !== null ? (n = A.shapeArgs, _ && A.hasNewShapeType() && (_ = _.destroy()), i.enabledDataSorting && (A.startXPos = i.xAxis.reversed ? -(n && n.width || 0) : i.xAxis.width), _ || (A.graphic = _ = t[A.shapeType](n).add(A.group || i.group)) && i.enabledDataSorting && h.hasRendered && h.pointCount < s && (_.attr({ x: A.startXPos }), D = !0, W = "animate"), _ && D && _[W](w(n)), o.borderRadius && _[W]({ r: o.borderRadius }), h.styledMode || _[W](i.pointAttribs(A, A.selected && "select")).shadow(A.allowShadow !== !1 && o.shadow, null, o.stacking && !o.borderRadius), _ && (_.addClass(A.getClassName(), !0), _.attr({ visibility: A.visible ? "inherit" : "hidden" }))) : _ && (A.graphic = _.destroy());
});
}, p.prototype.drawTracker = function() {
var i = this, h = i.chart, o = h.pointer, t = function(n) {
var A = o.getPointFromEvent(n);
typeof A < "u" && (o.isDirectTouch = !0, A.onMouseOver(n));
}, s;
i.points.forEach(function(n) {
s = C(n.dataLabels) ? n.dataLabels : n.dataLabel ? [n.dataLabel] : [], n.graphic && (n.graphic.element.point = n), s.forEach(function(A) {
A.div ? A.div.point = n : A.element.point = n;
});
}), i._hasTracking || (i.trackerGroups.forEach(function(n) {
i[n] && (i[n].addClass("highcharts-tracker").on("mouseover", t).on("mouseout", function(A) {
o.onTrackerMouseOut(A);
}), v && i[n].on(
"touchstart",
t
), !h.styledMode && i.options.cursor && i[n].css(u).css({ cursor: i.options.cursor }));
}), i._hasTracking = !0), B(this, "afterDrawTracker");
}, p.prototype.remove = function() {
var i = this, h = i.chart;
h.hasRendered && h.series.forEach(function(o) {
o.type === i.type && (o.isDirty = !0);
}), H.prototype.remove.apply(i, arguments);
}, p.defaultOptions = w(H.defaultOptions, { borderRadius: 0, centerInCategory: !1, groupPadding: 0.2, marker: null, pointPadding: 0.1, minPointLength: 0, cropThreshold: 50, pointRange: null, states: {
hover: { halo: !1, brightness: 0.1 },
select: { color: "#cccccc", borderColor: "#000000" }
}, dataLabels: { align: void 0, verticalAlign: void 0, y: void 0 }, startFromThreshold: !0, stickyTracking: !1, tooltip: { distance: 6 }, threshold: 0, borderColor: "#ffffff" }), p;
}(H), O(F.prototype, { cropShoulder: 0, directTouch: !0, drawLegendSymbol: Z.drawRectangle, getSymbol: y, negStacks: !0, trackerGroups: ["group", "dataLabelsGroup"] }), U.registerSeriesType("column", F), F;
}), E(l, "Core/Series/DataLabel.js", [
l["Core/Animation/AnimationUtilities.js"],
l["Core/FormatUtilities.js"],
l["Core/Utilities.js"]
], function(y, j, I) {
var Z = y.getDeferredAnimation, H = j.format, U = I.defined, F = I.extend, N = I.fireEvent, R = I.isArray, S = I.merge, v = I.objectEach, d = I.pick, u = I.splat, T;
return function(O) {
function B(p, i, h, o, t) {
var s = this, n = this.chart, A = this.isCartesian && n.inverted, _ = this.enabledDataSorting, D = d(p.dlBox && p.dlBox.centerX, p.plotX, -9999), W = d(p.plotY, -9999), P = i.getBBox(), X = h.rotation, g = h.align, m = n.isInsidePlot(D, Math.round(W), { inverted: A, paneCoordinates: !0, series: s }), L = function(k) {
_ && s.xAxis && !Y && s.setDataLabelStartPos(
p,
i,
t,
m,
k
);
}, Y = d(h.overflow, _ ? "none" : "justify") === "justify", V = this.visible && p.visible !== !1 && (p.series.forceDL || _ && !Y || m || d(h.inside, !!this.options.stacking) && o && n.isInsidePlot(D, A ? o.x + 1 : o.y + o.height - 1, { inverted: A, paneCoordinates: !0, series: s }));
if (V) {
var Q = n.renderer.fontMetrics(n.styledMode ? void 0 : h.style.fontSize, i).b;
o = F({ x: A ? this.yAxis.len - W : D, y: Math.round(A ? this.xAxis.len - D : W), width: 0, height: 0 }, o), F(h, { width: P.width, height: P.height }), X ? (Y = !1, D = n.renderer.rotCorr(Q, X), D = { x: o.x + (h.x || 0) + o.width / 2 + D.x, y: o.y + (h.y || 0) + { top: 0, middle: 0.5, bottom: 1 }[h.verticalAlign] * o.height }, L(D), i[t ? "attr" : "animate"](D).attr({ align: g }), L = (X + 720) % 360, L = 180 < L && 360 > L, g === "left" ? D.y -= L ? P.height : 0 : g === "center" ? (D.x -= P.width / 2, D.y -= P.height / 2) : g === "right" && (D.x -= P.width, D.y -= L ? 0 : P.height), i.placed = !0, i.alignAttr = D) : (L(o), i.align(h, void 0, o), D = i.alignAttr), Y && 0 <= o.height ? this.justifyDataLabel(i, h, D, P, o, t) : d(h.crop, !0) && (V = n.isInsidePlot(D.x, D.y, { paneCoordinates: !0, series: s }) && n.isInsidePlot(D.x + P.width, D.y + P.height, {
paneCoordinates: !0,
series: s
})), h.shape && !X && i[t ? "attr" : "animate"]({ anchorX: A ? n.plotWidth - p.plotY : p.plotX, anchorY: A ? n.plotHeight - p.plotX : p.plotY });
}
t && _ && (i.placed = !1), V || _ && !Y || (i.hide(!0), i.placed = !1);
}
function C(p, i) {
var h = i.filter;
return h ? (i = h.operator, p = p[h.property], h = h.value, i === ">" && p > h || i === "<" && p < h || i === ">=" && p >= h || i === "<=" && p <= h || i === "==" && p == h || i === "===" && p === h) : !0;
}
function b() {
var p = this, i = p.chart, h = p.options, o = p.points, t = p.hasRendered || 0, s = i.renderer, n = h.dataLabels, A, _ = n.animation;
if (_ = n.defer ? Z(
i,
_,
p
) : { defer: 0, duration: 0 }, n = x(x(i.options.plotOptions && i.options.plotOptions.series && i.options.plotOptions.series.dataLabels, i.options.plotOptions && i.options.plotOptions[p.type] && i.options.plotOptions[p.type].dataLabels), n), N(this, "drawDataLabels"), R(n) || n.enabled || p._hasPointLabels) {
var D = p.plotGroup("dataLabelsGroup", "data-labels", t ? "inherit" : "hidden", n.zIndex || 6);
D.attr({ opacity: +t }), !t && (t = p.dataLabelsGroup) && (p.visible && D.show(!0), t[h.animation ? "animate" : "attr"]({ opacity: 1 }, _)), o.forEach(function(W) {
A = u(x(n, W.dlOptions || W.options && W.options.dataLabels)), A.forEach(function(P, X) {
var g = P.enabled && (!W.isNull || W.dataLabelOnNull) && C(W, P), m = W.connectors ? W.connectors[X] : W.connector, L = W.dataLabels ? W.dataLabels[X] : W.dataLabel, Y = d(P.distance, W.labelDistance), V = !L;
if (g) {
var Q = W.getLabelConfig(), k = d(P[W.formatPrefix + "Format"], P.format);
Q = U(k) ? H(k, Q, i) : (P[W.formatPrefix + "Formatter"] || P.formatter).call(Q, P), k = P.style;
var G = P.rotation;
i.styledMode || (k.color = d(P.color, k.color, p.color, "#000000"), k.color === "contrast" ? (W.contrastColor = s.getContrast(W.color || p.color), k.color = !U(Y) && P.inside || 0 > Y || h.stacking ? W.contrastColor : "#000000") : delete W.contrastColor, h.cursor && (k.cursor = h.cursor));
var z = { r: P.borderRadius || 0, rotation: G, padding: P.padding, zIndex: 1 };
i.styledMode || (z.fill = P.backgroundColor, z.stroke = P.borderColor, z["stroke-width"] = P.borderWidth), v(z, function($, q) {
typeof $ > "u" && delete z[q];
});
}
!L || g && U(Q) && !!L.div == !!P.useHTML || (W.dataLabel = L = W.dataLabel && W.dataLabel.destroy(), W.dataLabels && (W.dataLabels.length === 1 ? delete W.dataLabels : delete W.dataLabels[X]), X || delete W.dataLabel, m && (W.connector = W.connector.destroy(), W.connectors && (W.connectors.length === 1 ? delete W.connectors : delete W.connectors[X]))), g && U(Q) && (L ? z.text = Q : (W.dataLabels = W.dataLabels || [], L = W.dataLabels[X] = G ? s.text(Q, 0, -9999, P.useHTML).addClass("highcharts-data-label") : s.label(Q, 0, -9999, P.shape, null, null, P.useHTML, null, "data-label"), X || (W.dataLabel = L), L.addClass(" highcharts-data-label-color-" + W.colorIndex + " " + (P.className || "") + (P.useHTML ? " highcharts-tracker" : ""))), L.options = P, L.attr(z), i.styledMode || L.css(k).shadow(P.shadow), L.added || L.add(D), P.textPath && !P.useHTML && (L.setTextPath(W.getDataLabelPath && W.getDataLabelPath(L) || W.graphic, P.textPath), W.dataLabelPath && !P.textPath.enabled && (W.dataLabelPath = W.dataLabelPath.destroy())), p.alignDataLabel(W, L, P, null, V));
});
});
}
N(this, "afterDrawDataLabels");
}
function w(p, i, h, o, t, s) {
var n = this.chart, A = i.align, _ = i.verticalAlign, D = p.box ? 0 : p.padding || 0, W = i.x;
W = W === void 0 ? 0 : W;
var P = i.y;
P = P === void 0 ? 0 : P;
var X = (h.x || 0) + D;
if (0 > X) {
A === "right" && 0 <= W ? (i.align = "left", i.inside = !0) : W -= X;
var g = !0;
}
return X = (h.x || 0) + o.width - D, X > n.plotWidth && (A === "left" && 0 >= W ? (i.align = "right", i.inside = !0) : W += n.plotWidth - X, g = !0), X = h.y + D, 0 > X && (_ === "bottom" && 0 <= P ? (i.verticalAlign = "top", i.inside = !0) : P -= X, g = !0), X = (h.y || 0) + o.height - D, X > n.plotHeight && (_ === "top" && 0 >= P ? (i.verticalAlign = "bottom", i.inside = !0) : P += n.plotHeight - X, g = !0), g && (i.x = W, i.y = P, p.placed = !s, p.align(i, void 0, t)), g;
}
function x(p, i) {
var h = [], o;
if (R(p) && !R(i))
h = p.map(function(t) {
return S(t, i);
});
else if (R(i) && !R(p))
h = i.map(function(t) {
return S(p, t);
});
else if (R(p) || R(i))
for (o = Math.max(p.length, i.length); o--; )
h[o] = S(p[o], i[o]);
else
h = S(p, i);
return h;
}
function a(p, i, h, o, t) {
var s = this.chart, n = s.inverted, A = this.xAxis, _ = A.reversed, D = n ? i.height / 2 : i.width / 2;
p = (p = p.pointWidth) ? p / 2 : 0, i.startXPos = n ? t.x : _ ? -D - p : A.width - D + p, i.startYPos = n ? _ ? this.yAxis.height - D + p : -D - p : t.y, o ? i.visibility === "hidden" && (i.show(), i.attr({ opacity: 0 }).animate({ opacity: 1 })) : i.attr({ opacity: 1 }).animate(
{ opacity: 0 },
void 0,
i.hide
), s.hasRendered && (h && i.attr({ x: i.startXPos, y: i.startYPos }), i.placed = !0);
}
var c = [];
O.compose = function(p) {
if (c.indexOf(p) === -1) {
var i = p.prototype;
c.push(p), i.alignDataLabel = B, i.drawDataLabels = b, i.justifyDataLabel = w, i.setDataLabelStartPos = a;
}
};
}(T || (T = {})), T;
}), E(l, "Series/Column/ColumnDataLabel.js", [l["Core/Series/DataLabel.js"], l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = j.series, H = I.merge, U = I.pick, F;
return function(N) {
function R(v, d, u, T, O) {
var B = this.chart.inverted, C = v.series, b = (C.xAxis ? C.xAxis.len : this.chart.plotSizeX) || 0;
C = (C.yAxis ? C.yAxis.len : this.chart.plotSizeY) || 0;
var w = v.dlBox || v.shapeArgs, x = U(v.below, v.plotY > U(this.translatedThreshold, C)), a = U(u.inside, !!this.options.stacking);
w && (T = H(w), 0 > T.y && (T.height += T.y, T.y = 0), w = T.y + T.height - C, 0 < w && w < T.height && (T.height -= w), B && (T = { x: C - T.y - T.height, y: b - T.x - T.width, width: T.height, height: T.width }), a || (B ? (T.x += x ? 0 : T.width, T.width = 0) : (T.y += x ? T.height : 0, T.height = 0))), u.align = U(u.align, !B || a ? "center" : x ? "right" : "left"), u.verticalAlign = U(u.verticalAlign, B || a ? "middle" : x ? "top" : "bottom"), Z.prototype.alignDataLabel.call(this, v, d, u, T, O), u.inside && v.contrastColor && d.css({ color: v.contrastColor });
}
var S = [];
N.compose = function(v) {
y.compose(Z), S.indexOf(v) === -1 && (S.push(v), v.prototype.alignDataLabel = R);
};
}(F || (F = {})), F;
}), E(l, "Series/Bar/BarSeries.js", [l["Series/Column/ColumnSeries.js"], l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = this && this.__extends || function() {
var F = function(N, R) {
return F = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(S, v) {
S.__proto__ = v;
} || function(S, v) {
for (var d in v)
v.hasOwnProperty(d) && (S[d] = v[d]);
}, F(N, R);
};
return function(N, R) {
function S() {
this.constructor = N;
}
F(N, R), N.prototype = R === null ? Object.create(R) : (S.prototype = R.prototype, new S());
};
}(), H = I.extend, U = I.merge;
return I = function(F) {
function N() {
var R = F !== null && F.apply(this, arguments) || this;
return R.data = void 0, R.options = void 0, R.points = void 0, R;
}
return Z(N, F), N.defaultOptions = U(
y.defaultOptions,
{}
), N;
}(y), H(I.prototype, { inverted: !0 }), j.registerSeriesType("bar", I), I;
}), E(l, "Series/Scatter/ScatterSeries.js", [l["Series/Column/ColumnSeries.js"], l["Series/Line/LineSeries.js"], l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]], function(y, j, I, Z) {
var H = this && this.__extends || function() {
var R = function(S, v) {
return R = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(d, u) {
d.__proto__ = u;
} || function(d, u) {
for (var T in u)
u.hasOwnProperty(T) && (d[T] = u[T]);
}, R(S, v);
};
return function(S, v) {
function d() {
this.constructor = S;
}
R(S, v), S.prototype = v === null ? Object.create(v) : (d.prototype = v.prototype, new d());
};
}(), U = Z.addEvent, F = Z.extend, N = Z.merge;
return Z = function(R) {
function S() {
var v = R !== null && R.apply(this, arguments) || this;
return v.data = void 0, v.options = void 0, v.points = void 0, v;
}
return H(S, R), S.prototype.applyJitter = function() {
var v = this, d = this.options.jitter, u = this.points.length;
d && this.points.forEach(function(T, O) {
["x", "y"].forEach(function(B, C) {
var b = "plot" + B.toUpperCase();
if (d[B] && !T.isNull) {
var w = v[B + "Axis"], x = d[B] * w.transA;
if (w && !w.isLog) {
var a = Math.max(0, T[b] - x);
w = Math.min(w.len, T[b] + x), C = 1e4 * Math.sin(O + C * u), T[b] = a + (w - a) * (C - Math.floor(C)), B === "x" && (T.clientX = T.plotX);
}
}
});
});
}, S.prototype.drawGraph = function() {
this.options.lineWidth ? R.prototype.drawGraph.call(this) : this.graph && (this.graph = this.graph.destroy());
}, S.defaultOptions = N(j.defaultOptions, { lineWidth: 0, findNearestPointBy: "xy", jitter: { x: 0, y: 0 }, marker: { enabled: !0 }, tooltip: {
headerFormat: '● {series.name}
',
pointFormat: "x: {point.x}
y: {point.y}
"
} }), S;
}(j), F(Z.prototype, { drawTracker: y.prototype.drawTracker, sorted: !1, requireSorting: !1, noSharedTooltip: !0, trackerGroups: ["group", "markerGroup", "dataLabelsGroup"], takeOrdinalPosition: !1 }), U(Z, "afterTranslate", function() {
this.applyJitter();
}), I.registerSeriesType("scatter", Z), Z;
}), E(l, "Series/CenteredUtilities.js", [l["Core/Globals.js"], l["Core/Series/Series.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = y.deg2rad, H = I.isNumber, U = I.pick, F = I.relativeLength, N;
return function(R) {
R.getCenter = function() {
var S = this.options, v = this.chart, d = 2 * (S.slicedOffset || 0), u = v.plotWidth - 2 * d, T = v.plotHeight - 2 * d, O = S.center, B = Math.min(u, T), C = S.size, b = S.innerSize || 0;
for (typeof C == "string" && (C = parseFloat(C)), typeof b == "string" && (b = parseFloat(b)), S = [U(O[0], "50%"), U(O[1], "50%"), U(C && 0 > C ? void 0 : S.size, "100%"), U(b && 0 > b ? void 0 : S.innerSize || 0, "0%")], !v.angular || this instanceof j || (S[3] = 0), O = 0; 4 > O; ++O)
C = S[O], v = 2 > O || O === 2 && /%$/.test(C), S[O] = F(C, [u, T, B, S[2]][O]) + (v ? d : 0);
return S[3] > S[2] && (S[3] = S[2]), S;
}, R.getStartAndEndRadians = function(S, v) {
return S = H(S) ? S : 0, v = H(v) && v > S && 360 > v - S ? v : S + 360, { start: Z * (S + -90), end: Z * (v + -90) };
};
}(N || (N = {})), N;
}), E(l, "Series/Pie/PiePoint.js", [l["Core/Animation/AnimationUtilities.js"], l["Core/Series/Point.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = this && this.__extends || function() {
var v = function(d, u) {
return v = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(T, O) {
T.__proto__ = O;
} || function(T, O) {
for (var B in O)
O.hasOwnProperty(B) && (T[B] = O[B]);
}, v(d, u);
};
return function(d, u) {
function T() {
this.constructor = d;
}
v(d, u), d.prototype = u === null ? Object.create(u) : (T.prototype = u.prototype, new T());
};
}(), H = y.setAnimation, U = I.addEvent, F = I.defined;
y = I.extend;
var N = I.isNumber, R = I.pick, S = I.relativeLength;
return j = function(v) {
function d() {
var u = v !== null && v.apply(this, arguments) || this;
return u.labelDistance = void 0, u.options = void 0, u.series = void 0, u;
}
return Z(d, v), d.prototype.getConnectorPath = function() {
var u = this.labelPosition, T = this.series.options.dataLabels, O = this.connectorShapes, B = T.connectorShape;
return O[B] && (B = O[B]), B.call(this, { x: u.final.x, y: u.final.y, alignment: u.alignment }, u.connectorPosition, T);
}, d.prototype.getTranslate = function() {
return this.sliced ? this.slicedTranslation : { translateX: 0, translateY: 0 };
}, d.prototype.haloPath = function(u) {
var T = this.shapeArgs;
return this.sliced || !this.visible ? [] : this.series.chart.renderer.symbols.arc(T.x, T.y, T.r + u, T.r + u, { innerR: T.r - 1, start: T.start, end: T.end });
}, d.prototype.init = function() {
var u = this;
v.prototype.init.apply(
this,
arguments
), this.name = R(this.name, "Slice");
var T = function(O) {
u.slice(O.type === "select");
};
return U(this, "select", T), U(this, "unselect", T), this;
}, d.prototype.isValid = function() {
return N(this.y) && 0 <= this.y;
}, d.prototype.setVisible = function(u, T) {
var O = this, B = this.series, C = B.chart, b = B.options.ignoreHiddenPoint;
T = R(T, b), u !== this.visible && (this.visible = this.options.visible = u = typeof u > "u" ? !this.visible : u, B.options.data[B.data.indexOf(this)] = this.options, ["graphic", "dataLabel", "connector", "shadowGroup"].forEach(function(w) {
O[w] && O[w][u ? "show" : "hide"](u);
}), this.legendItem && C.legend.colorizeItem(this, u), u || this.state !== "hover" || this.setState(""), b && (B.isDirty = !0), T && C.redraw());
}, d.prototype.slice = function(u, T, O) {
var B = this.series;
H(O, B.chart), R(T, !0), this.sliced = this.options.sliced = F(u) ? u : !this.sliced, B.options.data[B.data.indexOf(this)] = this.options, this.graphic && this.graphic.animate(this.getTranslate()), this.shadowGroup && this.shadowGroup.animate(this.getTranslate());
}, d;
}(j), y(j.prototype, { connectorShapes: { fixedOffset: function(v, d, u) {
var T = d.breakAt;
return d = d.touchingSliceAt, [["M", v.x, v.y], u.softConnector ? ["C", v.x + (v.alignment === "left" ? -5 : 5), v.y, 2 * T.x - d.x, 2 * T.y - d.y, T.x, T.y] : ["L", T.x, T.y], ["L", d.x, d.y]];
}, straight: function(v, d) {
return d = d.touchingSliceAt, [["M", v.x, v.y], ["L", d.x, d.y]];
}, crookedLine: function(v, d, u) {
d = d.touchingSliceAt;
var T = this.series, O = T.center[0], B = T.chart.plotWidth, C = T.chart.plotLeft;
T = v.alignment;
var b = this.shapeArgs.r;
return u = S(u.crookDistance, 1), B = T === "left" ? O + b + (B + C - O - b) * (1 - u) : C + (O - b) * u, u = ["L", B, v.y], O = !0, (T === "left" ? B > v.x || B < d.x : B < v.x || B > d.x) && (O = !1), v = [["M", v.x, v.y]], O && v.push(u), v.push(["L", d.x, d.y]), v;
} } }), j;
}), E(l, "Series/Pie/PieSeries.js", [l["Series/CenteredUtilities.js"], l["Series/Column/ColumnSeries.js"], l["Core/Globals.js"], l["Core/Legend/LegendSymbol.js"], l["Series/Pie/PiePoint.js"], l["Core/Series/Series.js"], l["Core/Series/SeriesRegistry.js"], l["Core/Renderer/SVG/Symbols.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H, U, F, N, R) {
var S = this && this.__extends || function() {
var b = function(w, x) {
return b = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(a, c) {
a.__proto__ = c;
} || function(a, c) {
for (var p in c)
c.hasOwnProperty(p) && (a[p] = c[p]);
}, b(w, x);
};
return function(w, x) {
function a() {
this.constructor = w;
}
b(w, x), w.prototype = x === null ? Object.create(x) : (a.prototype = x.prototype, new a());
};
}(), v = y.getStartAndEndRadians;
I = I.noop;
var d = R.clamp, u = R.extend, T = R.fireEvent, O = R.merge, B = R.pick, C = R.relativeLength;
return R = function(b) {
function w() {
var x = b !== null && b.apply(this, arguments) || this;
return x.center = void 0, x.data = void 0, x.maxLabelDistance = void 0, x.options = void 0, x.points = void 0, x;
}
return S(w, b), w.prototype.animate = function(x) {
var a = this, c = a.points, p = a.startAngleRad;
x || c.forEach(function(i) {
var h = i.graphic, o = i.shapeArgs;
h && o && (h.attr({ r: B(i.startR, a.center && a.center[3] / 2), start: p, end: p }), h.animate({ r: o.r, start: o.start, end: o.end }, a.options.animation));
});
}, w.prototype.drawEmpty = function() {
var x = this.startAngleRad, a = this.endAngleRad, c = this.options;
if (this.total === 0 && this.center) {
var p = this.center[0], i = this.center[1];
this.graph || (this.graph = this.chart.renderer.arc(p, i, this.center[1] / 2, 0, x, a).addClass("highcharts-empty-series").add(this.group)), this.graph.attr({ d: N.arc(p, i, this.center[2] / 2, 0, { start: x, end: a, innerR: this.center[3] / 2 }) }), this.chart.styledMode || this.graph.attr({ "stroke-width": c.borderWidth, fill: c.fillColor || "none", stroke: c.color || "#cccccc" });
} else
this.graph && (this.graph = this.graph.destroy());
}, w.prototype.drawPoints = function() {
var x = this.chart.renderer;
this.points.forEach(function(a) {
a.graphic && a.hasNewShapeType() && (a.graphic = a.graphic.destroy()), a.graphic || (a.graphic = x[a.shapeType](a.shapeArgs).add(a.series.group), a.delayedRendering = !0);
});
}, w.prototype.generatePoints = function() {
b.prototype.generatePoints.call(this), this.updateTotals();
}, w.prototype.getX = function(x, a, c) {
var p = this.center, i = this.radii ? this.radii[c.index] || 0 : p[2] / 2;
return x = Math.asin(d((x - p[1]) / (i + c.labelDistance), -1, 1)), p[0] + (a ? -1 : 1) * Math.cos(x) * (i + c.labelDistance) + (0 < c.labelDistance ? (a ? -1 : 1) * this.options.dataLabels.padding : 0);
}, w.prototype.hasData = function() {
return !!this.processedXData.length;
}, w.prototype.redrawPoints = function() {
var x = this, a = x.chart, c = a.renderer, p = x.options.shadow, i, h, o, t;
this.drawEmpty(), !p || x.shadowGroup || a.styledMode || (x.shadowGroup = c.g("shadow").attr({ zIndex: -1 }).add(x.group)), x.points.forEach(function(s) {
var n = {};
if (h = s.graphic, !s.isNull && h) {
var A = void 0;
t = s.shapeArgs, i = s.getTranslate(), a.styledMode || (A = s.shadowGroup, p && !A && (A = s.shadowGroup = c.g("shadow").add(x.shadowGroup)), A && A.attr(i), o = x.pointAttribs(s, s.selected && "select")), s.delayedRendering ? (h.setRadialReference(x.center).attr(t).attr(i), a.styledMode || h.attr(o).attr({ "stroke-linejoin": "round" }).shadow(p, A), s.delayedRendering = !1) : (h.setRadialReference(x.center), a.styledMode || O(!0, n, o), O(!0, n, t, i), h.animate(n)), h.attr({ visibility: s.visible ? "inherit" : "hidden" }), h.addClass(s.getClassName(), !0);
} else
h && (s.graphic = h.destroy());
});
}, w.prototype.sortByAngle = function(x, a) {
x.sort(function(c, p) {
return typeof c.angle < "u" && (p.angle - c.angle) * a;
});
}, w.prototype.translate = function(x) {
this.generatePoints();
var a = this.options, c = a.slicedOffset, p = c + (a.borderWidth || 0), i = v(a.startAngle, a.endAngle), h = this.startAngleRad = i.start;
i = (this.endAngleRad = i.end) - h;
var o = this.points, t = a.dataLabels.distance;
a = a.ignoreHiddenPoint;
var s = o.length, n, A = 0;
for (x || (this.center = x = this.getCenter()), n = 0; n < s; n++) {
var _ = o[n], D = h + A * i;
!_.isValid() || a && !_.visible || (A += _.percentage / 100);
var W = h + A * i, P = { x: x[0], y: x[1], r: x[2] / 2, innerR: x[3] / 2, start: Math.round(1e3 * D) / 1e3, end: Math.round(1e3 * W) / 1e3 };
_.shapeType = "arc", _.shapeArgs = P, _.labelDistance = B(_.options.dataLabels && _.options.dataLabels.distance, t), _.labelDistance = C(_.labelDistance, P.r), this.maxLabelDistance = Math.max(this.maxLabelDistance || 0, _.labelDistance), W = (W + D) / 2, W > 1.5 * Math.PI ? W -= 2 * Math.PI : W < -Math.PI / 2 && (W += 2 * Math.PI), _.slicedTranslation = { translateX: Math.round(Math.cos(W) * c), translateY: Math.round(Math.sin(W) * c) }, P = Math.cos(W) * x[2] / 2;
var X = Math.sin(W) * x[2] / 2;
_.tooltipPos = [x[0] + 0.7 * P, x[1] + 0.7 * X], _.half = W < -Math.PI / 2 || W > Math.PI / 2 ? 1 : 0, _.angle = W, D = Math.min(p, _.labelDistance / 5), _.labelPosition = { natural: { x: x[0] + P + Math.cos(W) * _.labelDistance, y: x[1] + X + Math.sin(W) * _.labelDistance }, final: {}, alignment: 0 > _.labelDistance ? "center" : _.half ? "right" : "left", connectorPosition: { breakAt: { x: x[0] + P + Math.cos(W) * D, y: x[1] + X + Math.sin(W) * D }, touchingSliceAt: { x: x[0] + P, y: x[1] + X } } };
}
T(this, "afterTranslate");
}, w.prototype.updateTotals = function() {
var x = this.points, a = x.length, c = this.options.ignoreHiddenPoint, p, i = 0;
for (p = 0; p < a; p++) {
var h = x[p];
!h.isValid() || c && !h.visible || (i += h.y);
}
for (this.total = i, p = 0; p < a; p++)
h = x[p], h.percentage = 0 < i && (h.visible || !c) ? h.y / i * 100 : 0, h.total = i;
}, w.defaultOptions = O(U.defaultOptions, {
center: [null, null],
clip: !1,
colorByPoint: !0,
dataLabels: { allowOverlap: !0, connectorPadding: 5, connectorShape: "fixedOffset", crookDistance: "70%", distance: 30, enabled: !0, formatter: function() {
return this.point.isNull ? void 0 : this.point.name;
}, softConnector: !0, x: 0 },
fillColor: void 0,
ignoreHiddenPoint: !0,
inactiveOtherPoints: !0,
legendType: "point",
marker: null,
size: null,
showInLegend: !1,
slicedOffset: 10,
stickyTracking: !1,
tooltip: { followPointer: !0 },
borderColor: "#ffffff",
borderWidth: 1,
lineWidth: void 0,
states: { hover: { brightness: 0.1 } }
}), w;
}(U), u(R.prototype, { axisTypes: [], directTouch: !0, drawGraph: void 0, drawLegendSymbol: Z.drawRectangle, drawTracker: j.prototype.drawTracker, getCenter: y.getCenter, getSymbol: I, isCartesian: !1, noSharedTooltip: !0, pointAttribs: j.prototype.pointAttribs, pointClass: H, requireSorting: !1, searchPoint: I, trackerGroups: ["group", "dataLabelsGroup"] }), F.registerSeriesType("pie", R), R;
}), E(l, "Series/Pie/PieDataLabel.js", [
l["Core/Series/DataLabel.js"],
l["Core/Globals.js"],
l["Core/Renderer/RendererUtilities.js"],
l["Core/Series/SeriesRegistry.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z, H) {
var U = j.noop, F = I.distribute, N = Z.series, R = H.arrayMax, S = H.clamp, v = H.defined, d = H.merge, u = H.pick, T = H.relativeLength, O;
return function(B) {
function C() {
var c = this, p = c.data, i = c.chart, h = c.options.dataLabels || {}, o = h.connectorPadding, t = i.plotWidth, s = i.plotHeight, n = i.plotLeft, A = Math.round(i.chartWidth / 3), _ = c.center, D = _[2] / 2, W = _[1], P = [[], []], X = [0, 0, 0, 0], g = c.dataLabelPositioners, m, L, Y, V, Q, k, G, z, $, q, it, et;
c.visible && (h.enabled || c._hasPointLabels) && (p.forEach(function(nt) {
nt.dataLabel && nt.visible && nt.dataLabel.shortened && (nt.dataLabel.attr({ width: "auto" }).css({ width: "auto", textOverflow: "clip" }), nt.dataLabel.shortened = !1);
}), N.prototype.drawDataLabels.apply(c), p.forEach(function(nt) {
nt.dataLabel && (nt.visible ? (P[nt.half].push(nt), nt.dataLabel._pos = null, !v(h.style.width) && !v(nt.options.dataLabels && nt.options.dataLabels.style && nt.options.dataLabels.style.width) && nt.dataLabel.getBBox().width > A && (nt.dataLabel.css({ width: Math.round(0.7 * A) + "px" }), nt.dataLabel.shortened = !0)) : (nt.dataLabel = nt.dataLabel.destroy(), nt.dataLabels && nt.dataLabels.length === 1 && delete nt.dataLabels));
}), P.forEach(function(nt, rt) {
var ct = nt.length, gt = [], dt;
if (ct) {
if (c.sortByAngle(nt, rt - 0.5), 0 < c.maxLabelDistance) {
var ht = Math.max(0, W - D - c.maxLabelDistance), at = Math.min(W + D + c.maxLabelDistance, i.plotHeight);
nt.forEach(function(J) {
0 < J.labelDistance && J.dataLabel && (J.top = Math.max(0, W - D - J.labelDistance), J.bottom = Math.min(W + D + J.labelDistance, i.plotHeight), dt = J.dataLabel.getBBox().height || 21, J.distributeBox = { target: J.labelPosition.natural.y - J.top + dt / 2, size: dt, rank: J.y }, gt.push(J.distributeBox));
}), ht = at + dt - ht, F(gt, ht, ht / 5);
}
for (it = 0; it < ct; it++) {
if (m = nt[it], k = m.labelPosition, V = m.dataLabel, q = m.visible === !1 ? "hidden" : "inherit", $ = ht = k.natural.y, gt && v(m.distributeBox) && (typeof m.distributeBox.pos > "u" ? q = "hidden" : (G = m.distributeBox.size, $ = g.radialDistributionY(m))), delete m.positionIndex, h.justify)
z = g.justify(m, D, _);
else
switch (h.alignTo) {
case "connectors":
z = g.alignToConnectors(nt, rt, t, n);
break;
case "plotEdges":
z = g.alignToPlotEdges(V, rt, t, n);
break;
default:
z = g.radialDistributionX(c, m, $, ht);
}
V._attr = { visibility: q, align: k.alignment }, et = m.options.dataLabels || {}, V._pos = { x: z + u(et.x, h.x) + ({ left: o, right: -o }[k.alignment] || 0), y: $ + u(et.y, h.y) - 10 }, k.final.x = z, k.final.y = $, u(h.crop, !0) && (Q = V.getBBox().width, ht = null, z - Q < o && rt === 1 ? (ht = Math.round(Q - z + o), X[3] = Math.max(ht, X[3])) : z + Q > t - o && rt === 0 && (ht = Math.round(z + Q - t + o), X[1] = Math.max(ht, X[1])), 0 > $ - G / 2 ? X[0] = Math.max(Math.round(-$ + G / 2), X[0]) : $ + G / 2 > s && (X[2] = Math.max(Math.round($ + G / 2 - s), X[2])), V.sideOverflow = ht);
}
}
}), R(X) === 0 || this.verifyDataLabelOverflow(X)) && (this.placeDataLabels(), this.points.forEach(function(nt) {
if (et = d(h, nt.options.dataLabels), L = u(et.connectorWidth, 1)) {
var rt;
Y = nt.connector, (V = nt.dataLabel) && V._pos && nt.visible && 0 < nt.labelDistance ? (q = V._attr.visibility, (rt = !Y) && (nt.connector = Y = i.renderer.path().addClass("highcharts-data-label-connector highcharts-color-" + nt.colorIndex + (nt.className ? " " + nt.className : "")).add(c.dataLabelsGroup), i.styledMode || Y.attr({ "stroke-width": L, stroke: et.connectorColor || nt.color || "#666666" })), Y[rt ? "attr" : "animate"]({ d: nt.getConnectorPath() }), Y.attr("visibility", q)) : Y && (nt.connector = Y.destroy());
}
}));
}
function b() {
this.points.forEach(function(c) {
var p = c.dataLabel, i;
p && c.visible && ((i = p._pos) ? (p.sideOverflow && (p._attr.width = Math.max(p.getBBox().width - p.sideOverflow, 0), p.css({ width: p._attr.width + "px", textOverflow: (this.options.dataLabels.style || {}).textOverflow || "ellipsis" }), p.shortened = !0), p.attr(p._attr), p[p.moved ? "animate" : "attr"](i), p.moved = !0) : p && p.attr({ y: -9999 })), delete c.distributeBox;
}, this);
}
function w(c) {
var p = this.center, i = this.options, h = i.center, o = i.minSize || 80, t = i.size !== null;
if (!t) {
if (h[0] !== null)
var s = Math.max(p[2] - Math.max(c[1], c[3]), o);
else
s = Math.max(p[2] - c[1] - c[3], o), p[0] += (c[3] - c[1]) / 2;
h[1] !== null ? s = S(s, o, p[2] - Math.max(c[0], c[2])) : (s = S(s, o, p[2] - c[0] - c[2]), p[1] += (c[0] - c[2]) / 2), s < p[2] ? (p[2] = s, p[3] = Math.min(T(i.innerSize || 0, s), s), this.translate(p), this.drawDataLabels && this.drawDataLabels()) : t = !0;
}
return t;
}
var x = [], a = { radialDistributionY: function(c) {
return c.top + c.distributeBox.pos;
}, radialDistributionX: function(c, p, i, h) {
return c.getX(i < p.top + 2 || i > p.bottom - 2 ? h : i, p.half, p);
}, justify: function(c, p, i) {
return i[0] + (c.half ? -1 : 1) * (p + c.labelDistance);
}, alignToPlotEdges: function(c, p, i, h) {
return c = c.getBBox().width, p ? c + h : i - c - h;
}, alignToConnectors: function(c, p, i, h) {
var o = 0, t;
return c.forEach(function(s) {
t = s.dataLabel.getBBox().width, t > o && (o = t);
}), p ? o + h : i - o - h;
} };
B.compose = function(c) {
y.compose(N), x.indexOf(c) === -1 && (x.push(c), c = c.prototype, c.dataLabelPositioners = a, c.alignDataLabel = U, c.drawDataLabels = C, c.placeDataLabels = b, c.verifyDataLabelOverflow = w);
};
}(O || (O = {})), O;
}), E(l, "Extensions/OverlappingDataLabels.js", [l["Core/Chart/Chart.js"], l["Core/Utilities.js"]], function(y, j) {
function I(S, v) {
var d = !1;
if (S) {
var u = S.newOpacity;
S.oldOpacity !== u && (S.alignAttr && S.placed ? (S[u ? "removeClass" : "addClass"]("highcharts-data-label-hidden"), d = !0, S.alignAttr.opacity = u, S[S.isOld ? "animate" : "attr"](S.alignAttr, null, function() {
v.styledMode || S.css({ pointerEvents: u ? "auto" : "none" });
}), H(v, "afterHideOverlappingLabel")) : S.attr({ opacity: u })), S.isOld = !0;
}
return d;
}
var Z = j.addEvent, H = j.fireEvent, U = j.isArray, F = j.isNumber, N = j.objectEach, R = j.pick;
Z(y, "render", function() {
var S = this, v = [];
(this.labelCollectors || []).forEach(function(d) {
v = v.concat(d());
}), (this.yAxis || []).forEach(function(d) {
d.stacking && d.options.stackLabels && !d.options.stackLabels.allowOverlap && N(d.stacking.stacks, function(u) {
N(u, function(T) {
T.label && T.label.visibility !== "hidden" && v.push(T.label);
});
});
}), (this.series || []).forEach(function(d) {
var u = d.options.dataLabels;
d.visible && (u.enabled !== !1 || d._hasPointLabels) && (u = function(T) {
return T.forEach(function(O) {
O.visible && (U(O.dataLabels) ? O.dataLabels : O.dataLabel ? [O.dataLabel] : []).forEach(function(B) {
var C = B.options;
B.labelrank = R(C.labelrank, O.labelrank, O.shapeArgs && O.shapeArgs.height), C.allowOverlap ? (B.oldOpacity = B.opacity, B.newOpacity = 1, I(B, S)) : v.push(B);
});
});
}, u(d.nodes || []), u(d.points));
}), this.hideOverlappingLabels(v);
}), y.prototype.hideOverlappingLabels = function(S) {
var v = this, d = S.length, u = v.renderer, T, O, B, C = !1, b = function(a) {
var c, p = a.box ? 0 : a.padding || 0, i = c = 0, h;
if (a && (!a.alignAttr || a.placed)) {
var o = a.alignAttr || { x: a.attr("x"), y: a.attr("y") }, t = a.parentGroup;
a.width || (c = a.getBBox(), a.width = c.width, a.height = c.height, c = u.fontMetrics(null, a.element).h);
var s = a.width - 2 * p;
return (h = { left: "0", center: "0.5", right: "1" }[a.alignValue]) ? i = +h * s : F(a.x) && Math.round(a.x) !== a.translateX && (i = a.x - a.translateX), { x: o.x + (t.translateX || 0) + p - (i || 0), y: o.y + (t.translateY || 0) + p - c, width: a.width - 2 * p, height: a.height - 2 * p };
}
};
for (O = 0; O < d; O++)
(T = S[O]) && (T.oldOpacity = T.opacity, T.newOpacity = 1, T.absoluteBox = b(T));
for (S.sort(function(a, c) {
return (c.labelrank || 0) - (a.labelrank || 0);
}), O = 0; O < d; O++) {
var w = (b = S[O]) && b.absoluteBox;
for (T = O + 1; T < d; ++T) {
var x = (B = S[T]) && B.absoluteBox;
!w || !x || b === B || b.newOpacity === 0 || B.newOpacity === 0 || x.x >= w.x + w.width || x.x + x.width <= w.x || x.y >= w.y + w.height || x.y + x.height <= w.y || ((b.labelrank < B.labelrank ? b : B).newOpacity = 0);
}
}
S.forEach(function(a) {
I(a, v) && (C = !0);
}), C && H(v, "afterHideAllOverlappingLabels");
};
}), E(
l,
"Core/Responsive.js",
[l["Core/Utilities.js"]],
function(y) {
var j = y.extend, I = y.find, Z = y.isArray, H = y.isObject, U = y.merge, F = y.objectEach, N = y.pick, R = y.splat, S = y.uniqueKey, v;
return function(d) {
var u = [];
d.compose = function(O) {
return u.indexOf(O) === -1 && (u.push(O), j(O.prototype, T.prototype)), O;
};
var T = function() {
function O() {
}
return O.prototype.currentOptions = function(B) {
function C(x, a, c, p) {
var i;
F(x, function(h, o) {
if (!p && -1 < b.collectionsWithUpdate.indexOf(o) && a[o])
for (h = R(h), c[o] = [], i = 0; i < Math.max(h.length, a[o].length); i++)
a[o][i] && (h[i] === void 0 ? c[o][i] = a[o][i] : (c[o][i] = {}, C(h[i], a[o][i], c[o][i], p + 1)));
else
H(h) ? (c[o] = Z(h) ? [] : {}, C(h, a[o] || {}, c[o], p + 1)) : c[o] = typeof a[o] > "u" ? null : a[o];
});
}
var b = this, w = {};
return C(B, this.options, w, 0), w;
}, O.prototype.matchResponsiveRule = function(B, C) {
var b = B.condition;
(b.callback || function() {
return this.chartWidth <= N(b.maxWidth, Number.MAX_VALUE) && this.chartHeight <= N(b.maxHeight, Number.MAX_VALUE) && this.chartWidth >= N(b.minWidth, 0) && this.chartHeight >= N(b.minHeight, 0);
}).call(this) && C.push(B._id);
}, O.prototype.setResponsive = function(B, C) {
var b = this, w = this.options.responsive, x = this.currentResponsive, a = [];
!C && w && w.rules && w.rules.forEach(function(c) {
typeof c._id > "u" && (c._id = S()), b.matchResponsiveRule(c, a);
}, this), C = U.apply(void 0, a.map(function(c) {
return I((w || {}).rules || [], function(p) {
return p._id === c;
});
}).map(function(c) {
return c && c.chartOptions;
})), C.isResponsiveOptions = !0, a = a.toString() || void 0, a !== (x && x.ruleIds) && (x && this.update(x.undoOptions, B, !0), a ? (x = this.currentOptions(C), x.isResponsiveOptions = !0, this.currentResponsive = { ruleIds: a, mergedOptions: C, undoOptions: x }, this.update(C, B, !0)) : this.currentResponsive = void 0);
}, O;
}();
}(v || (v = {})), v;
}
), E(l, "masters/highcharts.src.js", [
l["Core/Globals.js"],
l["Core/Utilities.js"],
l["Core/DefaultOptions.js"],
l["Core/Animation/Fx.js"],
l["Core/Animation/AnimationUtilities.js"],
l["Core/Renderer/HTML/AST.js"],
l["Core/FormatUtilities.js"],
l["Core/Renderer/RendererUtilities.js"],
l["Core/Renderer/SVG/SVGElement.js"],
l["Core/Renderer/SVG/SVGRenderer.js"],
l["Core/Renderer/HTML/HTMLElement.js"],
l["Core/Renderer/HTML/HTMLRenderer.js"],
l["Core/Axis/Axis.js"],
l["Core/Axis/DateTimeAxis.js"],
l["Core/Axis/LogarithmicAxis.js"],
l["Core/Axis/PlotLineOrBand/PlotLineOrBand.js"],
l["Core/Axis/Tick.js"],
l["Core/Tooltip.js"],
l["Core/Series/Point.js"],
l["Core/Pointer.js"],
l["Core/MSPointer.js"],
l["Core/Legend/Legend.js"],
l["Core/Chart/Chart.js"],
l["Core/Series/Series.js"],
l["Core/Series/SeriesRegistry.js"],
l["Series/Column/ColumnSeries.js"],
l["Series/Column/ColumnDataLabel.js"],
l["Series/Pie/PieSeries.js"],
l["Series/Pie/PieDataLabel.js"],
l["Core/Series/DataLabel.js"],
l["Core/Responsive.js"],
l["Core/Color/Color.js"],
l["Core/Time.js"]
], function(y, j, I, Z, H, U, F, N, R, S, v, d, u, T, O, B, C, b, w, x, a, c, p, i, h, o, t, s, n, A, _, D, W) {
return y.animate = H.animate, y.animObject = H.animObject, y.getDeferredAnimation = H.getDeferredAnimation, y.setAnimation = H.setAnimation, y.stop = H.stop, y.timers = Z.timers, y.AST = U, y.Axis = u, y.Chart = p, y.chart = p.chart, y.Fx = Z, y.Legend = c, y.PlotLineOrBand = B, y.Point = w, y.Pointer = a.isRequired() ? a : x, y.Series = i, y.SVGElement = R, y.SVGRenderer = S, y.Tick = C, y.Time = W, y.Tooltip = b, y.Color = D, y.color = D.parse, d.compose(S), v.compose(R), y.defaultOptions = I.defaultOptions, y.getOptions = I.getOptions, y.time = I.defaultTime, y.setOptions = I.setOptions, y.dateFormat = F.dateFormat, y.format = F.format, y.numberFormat = F.numberFormat, y.addEvent = j.addEvent, y.arrayMax = j.arrayMax, y.arrayMin = j.arrayMin, y.attr = j.attr, y.clearTimeout = j.clearTimeout, y.correctFloat = j.correctFloat, y.createElement = j.createElement, y.css = j.css, y.defined = j.defined, y.destroyObjectProperties = j.destroyObjectProperties, y.discardElement = j.discardElement, y.distribute = N.distribute, y.erase = j.erase, y.error = j.error, y.extend = j.extend, y.extendClass = j.extendClass, y.find = j.find, y.fireEvent = j.fireEvent, y.getMagnitude = j.getMagnitude, y.getStyle = j.getStyle, y.inArray = j.inArray, y.isArray = j.isArray, y.isClass = j.isClass, y.isDOMElement = j.isDOMElement, y.isFunction = j.isFunction, y.isNumber = j.isNumber, y.isObject = j.isObject, y.isString = j.isString, y.keys = j.keys, y.merge = j.merge, y.normalizeTickInterval = j.normalizeTickInterval, y.objectEach = j.objectEach, y.offset = j.offset, y.pad = j.pad, y.pick = j.pick, y.pInt = j.pInt, y.relativeLength = j.relativeLength, y.removeEvent = j.removeEvent, y.seriesType = h.seriesType, y.splat = j.splat, y.stableSort = j.stableSort, y.syncTimeout = j.syncTimeout, y.timeUnits = j.timeUnits, y.uniqueKey = j.uniqueKey, y.useSerialIds = j.useSerialIds, y.wrap = j.wrap, t.compose(o), A.compose(i), T.compose(u), O.compose(u), n.compose(s), B.compose(u), _.compose(p), y;
}), E(l, "Core/Axis/OrdinalAxis.js", [
l["Core/Axis/Axis.js"],
l["Core/Globals.js"],
l["Core/Series/Series.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z) {
var H = Z.addEvent, U = Z.correctFloat, F = Z.css, N = Z.defined, R = Z.error, S = Z.pick, v = Z.timeUnits, d = [], u;
return function(T) {
function O(t, s, n, A, _, D, W) {
_ === void 0 && (_ = []), D === void 0 && (D = 0);
var P = {}, X = this.options.tickPixelInterval, g = this.chart.time, m = [], L, Y, V = 0, Q = [], k = -Number.MAX_VALUE;
if (!this.options.ordinal && !this.options.breaks || !_ || 3 > _.length || typeof s > "u")
return g.getTimeTicks.apply(g, arguments);
var G = _.length;
for (L = 0; L < G; L++) {
var z = L && _[L - 1] > n;
if (_[L] < s && (V = L), L === G - 1 || _[L + 1] - _[L] > 5 * D || z) {
if (_[L] > k) {
for (Y = g.getTimeTicks(t, _[V], _[L], A); Y.length && Y[0] <= k; )
Y.shift();
Y.length && (k = Y[Y.length - 1]), m.push(Q.length), Q = Q.concat(Y);
}
V = L + 1;
}
if (z)
break;
}
if (Y) {
if (Y = Y.info, W && Y.unitRange <= v.hour) {
for (L = Q.length - 1, V = 1; V < L; V++)
if (g.dateFormat("%d", Q[V]) !== g.dateFormat("%d", Q[V - 1])) {
P[Q[V]] = "day";
var $ = !0;
}
$ && (P[Q[0]] = "day"), Y.higherRanks = P;
}
Y.segmentStarts = m, Q.info = Y;
} else
R(12, !1, this.chart);
if (W && N(X)) {
for (Y = Q.length, g = [], V = [], L = void 0, $ = Y; $--; )
m = this.translate(Q[$]), L && (V[$] = L - m), g[$] = L = m;
for (V.sort(), V = V[Math.floor(V.length / 2)], V < 0.6 * X && (V = null), $ = Q[Y - 1] > n ? Y - 1 : Y, L = void 0; $--; )
m = g[$], Y = Math.abs(L - m), L && Y < 0.8 * X && (V === null || Y < 0.8 * V) ? (P[Q[$]] && !P[Q[$ + 1]] ? (Y = $ + 1, L = m) : Y = $, Q.splice(Y, 1)) : L = m;
}
return Q;
}
function B(t) {
var s = this.ordinal.positions;
if (!s)
return t;
var n = s.length - 1;
if (0 > t)
t = s[0];
else if (t > n)
t = s[n];
else {
n = Math.floor(t);
var A = t - n;
}
return typeof A < "u" && typeof s[n] < "u" ? s[n] + (A ? A * (s[n + 1] - s[n]) : 0) : t;
}
function C(t) {
var s = this.ordinal, n = s.positions;
if (!n)
return t;
var A = (t - (this.old ? this.old.min : this.min)) * (this.old ? this.old.transA : this.transA) + this.minPixelPadding;
if (0 < A && A < this.left + this.len || (s.extendedOrdinalPositions || (s.extendedOrdinalPositions = s.getExtendedPositions()), n = s.extendedOrdinalPositions), n && n.length) {
if (t = s.getIndexOfPoint(A, n), s = U(t % 1), 0 <= t && t < n.length - 1)
return n[Math.floor(t)] + s * (n[Math.ceil(t)] - n[Math.floor(t)]);
s = n.length, A = n[0], n = n[s - 1];
var _ = (n - A) / (s - 1);
return 0 > t ? A + _ * t : n + _ * (t - s);
}
return t;
}
function b(t, s) {
var n = T.Additions.findIndexOf(t, s, !0);
return t[n] === s ? n : n + (s - t[n]) / (t[n + 1] - t[n]);
}
function w() {
this.ordinal || (this.ordinal = new T.Additions(this));
}
function x() {
this.isXAxis && N(this.options.overscroll) && this.max === this.dataMax && (!this.chart.mouseIsDown || this.isInternal) && (!this.eventArgs || this.eventArgs && this.eventArgs.trigger !== "navigator") && (this.max += this.options.overscroll, !this.isInternal && N(this.userMin) && (this.min += this.options.overscroll));
}
function a() {
this.horiz && !this.isDirty && (this.isDirty = this.isOrdinal && this.chart.navigator && !this.chart.navigator.adaptToUpdatedData);
}
function c() {
this.ordinal && (this.ordinal.beforeSetTickPositions(), this.tickInterval = this.ordinal.postProcessTickInterval(this.tickInterval));
}
function p(t) {
var s = this.xAxis[0], n = s.options.overscroll, A = t.originalEvent.chartX, _ = this.options.chart.panning, D = !1;
if (_ && _.type !== "y" && s.options.ordinal && s.series.length) {
var W = this.mouseDownX, P = s.getExtremes(), X = P.dataMax, g = P.min, m = P.max, L = this.hoverPoints, Y = s.closestPointRange || s.ordinal && s.ordinal.overscrollPointsRange;
W = (W - A) / (s.translationSlope * (s.ordinal.slope || Y)), Y = { ordinal: { positions: s.ordinal.getExtendedPositions() } };
var V = s.index2val, Q = s.val2lin, k = void 0, G = k = void 0, z = void 0;
Y.ordinal.positions ? 1 < Math.abs(W) && (L && L.forEach(function($) {
$.setState();
}), 0 > W ? (G = Y, z = s.ordinal.positions ? s : Y) : (G = s.ordinal.positions ? s : Y, z = Y), k = z.ordinal.positions, X > k[k.length - 1] && k.push(X), this.fixedRange = m - g, k = s.navigatorAxis.toFixedRange(void 0, void 0, V.apply(G, [Q.apply(G, [g, !0]) + W]), V.apply(z, [Q.apply(z, [m, !0]) + W])), k.min >= Math.min(
P.dataMin,
g
) && k.max <= Math.max(X, m) + n && s.setExtremes(k.min, k.max, !0, !1, { trigger: "pan" }), this.mouseDownX = A, F(this.container, { cursor: "move" })) : D = !0;
} else
D = !0;
D || _ && /y/.test(_.type) ? n && (s.max = s.dataMax + n) : t.preventDefault();
}
function i() {
var t = this.xAxis;
t && t.options.ordinal && (delete t.ordinal.index, delete t.ordinal.extendedOrdinalPositions);
}
function h(t, s) {
var n = this.ordinal, A = n.positions, _ = n.slope, D = n.extendedOrdinalPositions;
if (!A)
return t;
var W = A.length;
if (A[0] <= t && A[W - 1] >= t)
t = b(A, t);
else {
if (D || (D = n.getExtendedPositions && n.getExtendedPositions(), n.extendedOrdinalPositions = D), !D || !D.length)
return t;
W = D.length, _ || (_ = (D[W - 1] - D[0]) / W), A = b(D, A[0]), t >= D[0] && t <= D[W - 1] ? t = b(D, t) - A : t < D[0] ? (t = D[0] - t, t = -A - t / _) : (t -= D[W - 1], t = t / _ + W - A);
}
return s ? t : _ * (t || 0) + n.offset;
}
T.compose = function(t, s, n) {
if (d.indexOf(t) === -1) {
d.push(t);
var A = t.prototype;
A.getTimeTicks = O, A.index2val = B, A.lin2val = C, A.val2lin = h, A.ordinal2lin = A.val2lin, H(t, "afterInit", w), H(t, "foundExtremes", x), H(t, "afterSetScale", a), H(t, "initialAxisTranslation", c);
}
return d.indexOf(n) === -1 && (d.push(n), H(n, "pan", p)), d.indexOf(s) === -1 && (d.push(s), H(s, "updatedData", i)), t;
};
var o = function() {
function t(s) {
this.index = {}, this.axis = s;
}
return t.prototype.beforeSetTickPositions = function() {
var s = this.axis, n = s.ordinal, A = s.getExtremes(), _ = A.min, D = A.max, W = s.isXAxis && !!s.options.breaks;
A = s.options.ordinal;
var P = s.chart.options.chart.ignoreHiddenSeries, X, g, m = [], L = Number.MAX_VALUE, Y = !1;
if (A || W) {
s.series.forEach(function(k, G) {
if (X = [], !(P && k.visible === !1 || k.takeOrdinalPosition === !1 && !W) && (m = m.concat(k.processedXData), V = m.length, m.sort(function(z, $) {
return z - $;
}), L = Math.min(L, S(k.closestPointRange, L)), V)) {
for (G = 0; G < V - 1; )
m[G] !== m[G + 1] && X.push(m[G + 1]), G++;
X[0] !== m[0] && X.unshift(m[0]), m = X;
}
});
var V = m.length;
if (2 < V) {
var Q = m[1] - m[0];
for (g = V - 1; g-- && !Y; )
m[g + 1] - m[g] !== Q && (Y = !0);
!s.options.keepOrdinalPadding && (m[0] - _ > Q || D - m[m.length - 1] > Q) && (Y = !0);
} else
s.options.overscroll && (V === 2 ? L = m[1] - m[0] : V === 1 ? (L = s.options.overscroll, m = [m[0], m[0] + L]) : L = n.overscrollPointsRange);
Y || s.forceOrdinal ? (s.options.overscroll && (n.overscrollPointsRange = L, m = m.concat(n.getOverscrollPositions())), n.positions = m, Q = s.ordinal2lin(Math.max(_, m[0]), !0), g = Math.max(s.ordinal2lin(Math.min(D, m[m.length - 1]), !0), 1), n.slope = D = (D - _) / (g - Q), n.offset = _ - Q * D) : (n.overscrollPointsRange = S(s.closestPointRange, n.overscrollPointsRange), n.positions = s.ordinal.slope = n.offset = void 0);
}
s.isOrdinal = A && Y, n.groupIntervalFactor = null;
}, t.findIndexOf = function(s, n, A) {
for (var _ = 0, D = s.length - 1, W; _ < D; )
W = Math.ceil((_ + D) / 2), s[W] <= n ? _ = W : D = W - 1;
return s[_] === n || A ? _ : -1;
}, t.prototype.getExtendedPositions = function() {
var s = this, n = s.axis, A = n.constructor.prototype, _ = n.chart, D = n.series[0].currentDataGrouping, W = D ? D.count + D.unitName : "raw", P = n.options.overscroll, X = n.getExtremes(), g = void 0, m = s.index;
if (m || (m = s.index = {}), !m[W]) {
var L = {
series: [],
chart: _,
forceOrdinal: !1,
getExtremes: function() {
return { min: X.dataMin, max: X.dataMax + P };
},
getGroupPixelWidth: A.getGroupPixelWidth,
getTimeTicks: A.getTimeTicks,
options: { ordinal: !0 },
ordinal: { getGroupIntervalFactor: this.getGroupIntervalFactor },
ordinal2lin: A.ordinal2lin,
getIndexOfPoint: A.getIndexOfPoint,
val2lin: A.val2lin
};
L.ordinal.axis = L, n.series.forEach(function(Y) {
g = { xAxis: L, xData: Y.xData.slice(), chart: _, destroyGroupedData: j.noop, getProcessedData: I.prototype.getProcessedData, applyGrouping: I.prototype.applyGrouping }, g.xData = g.xData.concat(s.getOverscrollPositions()), g.options = { dataGrouping: D ? { firstAnchor: "firstPoint", anchor: "middle", lastAnchor: "lastPoint", enabled: !0, forced: !0, approximation: "open", units: [[D.unitName, [D.count]]] } : { enabled: !1 } }, L.series.push(g), Y.processData.apply(g);
}), g.closestPointRange !== g.basePointRange && g.currentDataGrouping && (L.forceOrdinal = !0), n.ordinal.beforeSetTickPositions.apply({ axis: L }), m[W] = L.ordinal.positions;
}
return m[W];
}, t.prototype.getGroupIntervalFactor = function(s, n, A) {
A = A.processedXData;
var _ = A.length, D = [], W = this.groupIntervalFactor;
if (!W) {
for (W = 0; W < _ - 1; W++)
D[W] = A[W + 1] - A[W];
D.sort(function(P, X) {
return P - X;
}), D = D[Math.floor(_ / 2)], s = Math.max(s, A[0]), n = Math.min(n, A[_ - 1]), this.groupIntervalFactor = W = _ * D / (n - s);
}
return W;
}, t.prototype.getIndexOfPoint = function(s, n) {
var A = this.axis, _ = this.positions ? this.positions[0] : 0, D = A.series[0].points && A.series[0].points[0] && A.series[0].points[0].plotX || A.minPixelPadding;
return 1 < A.series.length && A.series.forEach(function(W) {
W.points && N(W.points[0]) && N(W.points[0].plotX) && W.points[0].plotX < D && (D = W.points[0].plotX);
}), s = (s - D) / (A.translationSlope * (this.slope || A.closestPointRange || this.overscrollPointsRange)), t.findIndexOf(n, _) + s;
}, t.prototype.getOverscrollPositions = function() {
var s = this.axis, n = s.options.overscroll, A = this.overscrollPointsRange, _ = [], D = s.dataMax;
if (N(A))
for (; D <= s.dataMax + n; )
D += A, _.push(D);
return _;
}, t.prototype.postProcessTickInterval = function(s) {
var n = this.axis, A = this.slope;
return A ? n.options.breaks ? n.closestPointRange || s : s / (A / n.closestPointRange) : s;
}, t;
}();
T.Additions = o;
}(u || (u = {})), u;
}), E(l, "Series/DataModifyComposition.js", [l["Core/Axis/Axis.js"], l["Core/Series/Point.js"], l["Core/Series/Series.js"], l["Core/Utilities.js"]], function(y, j, I, Z) {
var H = j.prototype.tooltipFormatter, U = Z.addEvent, F = Z.arrayMax, N = Z.arrayMin, R = Z.correctFloat, S = Z.defined, v = Z.isArray, d = Z.isNumber, u = Z.isString, T = Z.pick, O;
return function(B) {
function C(s, n, A) {
this.isXAxis || (this.series.forEach(function(_) {
s === "compare" && typeof n != "boolean" ? _.setCompare(n, !1) : s !== "cumulative" || u(n) || _.setCumulative(n, !1);
}), T(A, !0) && this.chart.redraw());
}
function b(s) {
var n = this, A = n.series.chart.numberFormatter, _ = function(D) {
s = s.replace("{point." + D + "}", (0 < n[D] && D === "change" ? "+" : "") + A(n[D], T(n.series.tooltipOptions.changeDecimals, 2)));
};
return S(n.change) && _("change"), S(n.cumulativeSum) && _("cumulativeSum"), H.apply(this, [s]);
}
function w() {
var s = this.options.compare;
if (s === "percent" || s === "value" || this.options.cumulative) {
var n = new t(this);
s === "percent" || s === "value" ? n.initCompare(s) : n.initCumulative();
}
this.dataModify = n;
}
function x(s) {
s = s.dataExtremes;
var n = s.activeYData;
if (this.dataModify && s) {
var A = void 0;
this.options.compare ? A = [this.dataModify.modifyValue(s.dataMin), this.dataModify.modifyValue(s.dataMax)] : this.options.cumulative && v(n) && 2 <= n.length && (A = t.getCumulativeExtremes(n)), A && (s.dataMin = N(A), s.dataMax = F(A));
}
}
function a(s, n) {
this.options.compare = this.userOptions.compare = s, this.update({}, T(n, !0)), !this.dataModify || s !== "value" && s !== "percent" ? this.points.forEach(function(A) {
delete A.change;
}) : this.dataModify.initCompare(s);
}
function c() {
if (this.xAxis && this.processedYData && this.dataModify) {
var s = this.processedXData, n = this.processedYData, A = n.length, _ = this.options.compareStart === !0 ? 0 : 1, D = -1, W;
for (this.pointArrayMap && (D = this.pointArrayMap.indexOf(this.options.pointValKey || this.pointValKey || "y")), W = 0; W < A - _; W++) {
var P = n[W] && -1 < D ? n[W][D] : n[W];
if (d(P) && P !== 0 && s[W + _] >= (this.xAxis.min || 0)) {
this.dataModify.compareValue = P;
break;
}
}
}
}
function p(s, n) {
this.setModifier("compare", s, n);
}
function i(s, n) {
s = T(s, !1), this.options.cumulative = this.userOptions.cumulative = s, this.update({}, T(n, !0)), this.dataModify ? this.dataModify.initCumulative() : this.points.forEach(function(A) {
delete A.cumulativeSum;
});
}
function h(s, n) {
this.setModifier("cumulative", s, n);
}
var o = [];
B.compose = function(s, n, A) {
if (o.indexOf(s) === -1) {
o.push(s);
var _ = s.prototype;
_.setCompare = a, _.setCumulative = i, U(s, "afterInit", w), U(s, "afterGetExtremes", x), U(s, "afterProcessData", c);
}
return o.indexOf(n) === -1 && (o.push(n), n = n.prototype, n.setCompare = p, n.setModifier = C, n.setCumulative = h), o.indexOf(A) === -1 && (o.push(A), A.prototype.tooltipFormatter = b), s;
};
var t = function() {
function s(n) {
this.series = n;
}
return s.prototype.modifyValue = function() {
return 0;
}, s.getCumulativeExtremes = function(n) {
var A = 1 / 0, _ = -1 / 0;
return n.reduce(function(D, W) {
return W = D + W, A = Math.min(A, W, D), _ = Math.max(
_,
W,
D
), W;
}), [A, _];
}, s.prototype.initCompare = function(n) {
this.modifyValue = function(A, _) {
A === null && (A = 0);
var D = this.compareValue;
return typeof A < "u" && typeof D < "u" ? (A = n === "value" ? A - D : A / D * 100 - (this.series.options.compareBase === 100 ? 0 : 100), typeof _ < "u" && (_ = this.series.points[_]) && (_.change = A), A) : 0;
};
}, s.prototype.initCumulative = function() {
this.modifyValue = function(n, A) {
if (n === null && (n = 0), n !== void 0 && A !== void 0) {
var _ = 0 < A ? this.series.points[A - 1] : null;
return _ && _.cumulativeSum && (n = R(_.cumulativeSum + n)), (A = this.series.points[A]) && (A.cumulativeSum = n), n;
}
return 0;
};
}, s;
}();
B.Additions = t;
}(O || (O = {})), O;
}), E(l, "Core/Axis/BrokenAxis.js", [l["Extensions/Stacking.js"], l["Core/Utilities.js"]], function(y, j) {
var I = j.addEvent, Z = j.find, H = j.fireEvent, U = j.isArray, F = j.isNumber, N = j.pick, R;
return function(S) {
function v() {
typeof this.brokenAxis < "u" && this.brokenAxis.setBreaks(this.options.breaks, !1);
}
function d() {
this.brokenAxis && this.brokenAxis.hasBreaks && (this.options.ordinal = !1);
}
function u() {
var a = this.brokenAxis;
if (a && a.hasBreaks) {
for (var c = this.tickPositions, p = this.tickPositions.info, i = [], h = 0; h < c.length; h++)
a.isInAnyBreak(c[h]) || i.push(c[h]);
this.tickPositions = i, this.tickPositions.info = p;
}
}
function T() {
this.brokenAxis || (this.brokenAxis = new x(this));
}
function O() {
var a = this.options.connectNulls, c = this.points, p = this.xAxis, i = this.yAxis;
if (this.isDirty)
for (var h = c.length; h--; ) {
var o = c[h], t = !(o.y === null && a === !1) && (p && p.brokenAxis && p.brokenAxis.isInAnyBreak(o.x, !0) || i && i.brokenAxis && i.brokenAxis.isInAnyBreak(o.y, !0));
o.visible = t ? !1 : o.options.visible !== !1;
}
}
function B() {
this.drawBreaks(this.xAxis, ["x"]), this.drawBreaks(this.yAxis, N(this.pointArrayMap, ["y"]));
}
function C(a, c) {
var p = this, i = p.points, h, o, t, s;
if (a && a.brokenAxis && a.brokenAxis.hasBreaks) {
var n = a.brokenAxis;
c.forEach(function(A) {
h = n && n.breakArray || [], o = a.isXAxis ? a.min : N(p.options.threshold, a.min), i.forEach(function(_) {
s = N(_["stack" + A.toUpperCase()], _[A]), h.forEach(function(D) {
F(o) && F(s) && (t = !1, o < D.from && s > D.to || o > D.from && s < D.from ? t = "pointBreak" : (o < D.from && s > D.from && s < D.to || o > D.from && s > D.to && s < D.from) && (t = "pointInBreak"), t && H(a, t, { point: _, brk: D }));
});
});
});
}
}
function b() {
var a = this.currentDataGrouping, c = a && a.gapSize;
a = this.points.slice();
var p = this.yAxis, i = this.options.gapSize, h = a.length - 1, o;
if (i && 0 < h)
for (this.options.gapUnit !== "value" && (i *= this.basePointRange), c && c > i && c >= this.basePointRange && (i = c), o = void 0; h--; )
o && o.visible !== !1 || (o = a[h + 1]), c = a[h], o.visible !== !1 && c.visible !== !1 && (o.x - c.x > i && (o = (c.x + o.x) / 2, a.splice(h + 1, 0, { isNull: !0, x: o }), p.stacking && this.options.stacking && (o = p.stacking.stacks[this.stackKey][o] = new y(p, p.options.stackLabels, !1, o, this.stack), o.total = 0)), o = c);
return this.getGraphPath(a);
}
var w = [];
S.compose = function(a, c) {
if (w.indexOf(a) === -1 && (w.push(a), a.keepProps.push("brokenAxis"), I(a, "init", T), I(a, "afterInit", v), I(a, "afterSetTickPositions", u), I(a, "afterSetOptions", d)), w.indexOf(c) === -1) {
w.push(c);
var p = c.prototype;
p.drawBreaks = C, p.gappedPath = b, I(c, "afterGeneratePoints", O), I(
c,
"afterRender",
B
);
}
return a;
};
var x = function() {
function a(c) {
this.hasBreaks = !1, this.axis = c;
}
return a.isInBreak = function(c, p) {
var i = c.repeat || 1 / 0, h = c.from, o = c.to - c.from;
return p = p >= h ? (p - h) % i : i - (h - p) % i, c.inclusive ? p <= o : p < o && p !== 0;
}, a.lin2Val = function(c) {
var p = this.brokenAxis;
if (p = p && p.breakArray, !p || !F(c))
return c;
var i;
for (i = 0; i < p.length; i++) {
var h = p[i];
if (h.from >= c)
break;
(h.to < c || a.isInBreak(h, c)) && (c += h.len);
}
return c;
}, a.val2Lin = function(c) {
var p = this.brokenAxis;
if (p = p && p.breakArray, !p || !F(c))
return c;
var i = c, h;
for (h = 0; h < p.length; h++) {
var o = p[h];
if (o.to <= c)
i -= o.len;
else {
if (o.from >= c)
break;
if (a.isInBreak(o, c)) {
i -= c - o.from;
break;
}
}
}
return i;
}, a.prototype.findBreakAt = function(c, p) {
return Z(p, function(i) {
return i.from < c && c < i.to;
});
}, a.prototype.isInAnyBreak = function(c, p) {
var i = this.axis, h = i.options.breaks || [], o = h.length, t;
if (o && F(c)) {
for (; o--; )
if (a.isInBreak(h[o], c)) {
var s = !0;
t || (t = N(h[o].showPoints, !i.isXAxis));
}
var n = s && p ? s && !t : s;
}
return n;
}, a.prototype.setBreaks = function(c, p) {
var i = this, h = i.axis, o = U(c) && !!c.length;
h.isDirty = i.hasBreaks !== o, i.hasBreaks = o, h.options.breaks = h.userOptions.breaks = c, h.forceRedraw = !0, h.series.forEach(function(t) {
t.isDirty = !0;
}), o || h.val2lin !== a.val2Lin || (delete h.val2lin, delete h.lin2val), o && (h.userOptions.ordinal = !1, h.lin2val = a.lin2Val, h.val2lin = a.val2Lin, h.setExtremes = function(t, s, n, A, _) {
if (i.hasBreaks) {
for (var D = this.options.breaks || [], W; W = i.findBreakAt(t, D); )
t = W.to;
for (; W = i.findBreakAt(s, D); )
s = W.from;
s < t && (s = t);
}
h.constructor.prototype.setExtremes.call(this, t, s, n, A, _);
}, h.setAxisTranslation = function() {
if (h.constructor.prototype.setAxisTranslation.call(this), i.unitLength = void 0, i.hasBreaks) {
var t = h.options.breaks || [], s = [], n = [], A = N(h.pointRangePadding, 0), _ = 0, D, W = h.userMin || h.min, P = h.userMax || h.max, X;
t.forEach(function(L) {
D = L.repeat || 1 / 0, F(W) && F(P) && (a.isInBreak(L, W) && (W += L.to % D - W % D), a.isInBreak(L, P) && (P -= P % D - L.from % D));
}), t.forEach(function(L) {
if (m = L.from, D = L.repeat || 1 / 0, F(W) && F(P)) {
for (; m - D > W; )
m -= D;
for (; m < W; )
m += D;
for (X = m; X < P; X += D)
s.push({ value: X, move: "in" }), s.push({ value: X + L.to - L.from, move: "out", size: L.breakSize });
}
}), s.sort(function(L, Y) {
return L.value === Y.value ? (L.move === "in" ? 0 : 1) - (Y.move === "in" ? 0 : 1) : L.value - Y.value;
});
var g = 0, m = W;
s.forEach(function(L) {
g += L.move === "in" ? 1 : -1, g === 1 && L.move === "in" && (m = L.value), g === 0 && F(m) && (n.push({ from: m, to: L.value, len: L.value - m - (L.size || 0) }), _ += L.value - m - (L.size || 0));
}), i.breakArray = n, F(W) && F(P) && F(h.min) && (i.unitLength = P - W - _ + A, H(h, "afterBreaks"), h.staticScale ? h.transA = h.staticScale : i.unitLength && (h.transA *= (P - h.min + A) / i.unitLength), A && (h.minPixelPadding = h.transA * (h.minPointOffset || 0)), h.min = W, h.max = P);
}
}), N(p, !0) && h.chart.redraw();
}, a;
}();
S.Additions = x;
}(R || (R = {})), R;
}), E(l, "masters/modules/broken-axis.src.js", [l["Core/Globals.js"], l["Core/Axis/BrokenAxis.js"]], function(y, j) {
j.compose(y.Axis, y.Series);
}), E(l, "Extensions/DataGrouping.js", [
l["Core/Axis/Axis.js"],
l["Core/Axis/DateTimeAxis.js"],
l["Core/FormatUtilities.js"],
l["Core/Globals.js"],
l["Core/Series/Point.js"],
l["Core/Series/Series.js"],
l["Core/Tooltip.js"],
l["Core/DefaultOptions.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z, H, U, F, N, R) {
var S = I.format, v = U.prototype;
I = R.addEvent;
var d = R.arrayMax, u = R.arrayMin, T = R.correctFloat, O = R.defined, B = R.error, C = R.extend, b = R.isNumber, w = R.merge, x = R.pick, a = Z.approximations = {
sum: function(t) {
var s = t.length;
if (!s && t.hasNulls)
var n = null;
else if (s)
for (n = 0; s--; )
n += t[s];
return n;
},
average: function(t) {
var s = t.length;
return t = a.sum(t), b(t) && s && (t = T(t / s)), t;
},
averages: function() {
var t = [];
return [].forEach.call(arguments, function(s) {
t.push(a.average(s));
}), typeof t[0] > "u" ? void 0 : t;
},
open: function(t) {
return t.length ? t[0] : t.hasNulls ? null : void 0;
},
high: function(t) {
return t.length ? d(t) : t.hasNulls ? null : void 0;
},
low: function(t) {
return t.length ? u(t) : t.hasNulls ? null : void 0;
},
close: function(t) {
return t.length ? t[t.length - 1] : t.hasNulls ? null : void 0;
},
hlc: function(t, s, n) {
if (t = a.high(t), s = a.low(s), n = a.close(n), b(t) || b(s) || b(n))
return [t, s, n];
},
ohlc: function(t, s, n, A) {
if (t = a.open(t), s = a.high(s), n = a.low(n), A = a.close(A), b(t) || b(s) || b(n) || b(A))
return [t, s, n, A];
},
range: function(t, s) {
if (t = a.low(t), s = a.high(s), b(t) || b(s))
return [t, s];
if (t === null && s === null)
return null;
}
};
R = function(t, s, n, A) {
var _ = this, D = _.data, W = _.options && _.options.data, P = [], X = [], g = [], m = t.length, L = !!s, Y = [], V = _.pointArrayMap, Q = V && V.length, k = ["x"].concat(V || ["y"]), G = this.options.dataGrouping && this.options.dataGrouping.groupAll, z = 0, $ = 0, q;
A = typeof A == "function" ? A : a[A] ? a[A] : a[_.getDGApproximation && _.getDGApproximation() || "average"], Q ? V.forEach(function() {
Y.push([]);
}) : Y.push([]);
var it = Q || 1;
for (q = 0; q <= m && !(t[q] >= n[0]); q++)
;
for (q; q <= m; q++) {
for (; typeof n[z + 1] < "u" && t[q] >= n[z + 1] || q === m; ) {
var et = n[z];
_.dataGroupInfo = { start: G ? $ : _.cropStart + $, length: Y[0].length };
var nt = A.apply(_, Y);
for (_.pointClass && !O(_.dataGroupInfo.options) && (_.dataGroupInfo.options = w(_.pointClass.prototype.optionsToObject.call({ series: _ }, _.options.data[_.cropStart + $])), k.forEach(function(ct) {
delete _.dataGroupInfo.options[ct];
})), typeof nt < "u" && (P.push(et), X.push(nt), g.push(_.dataGroupInfo)), $ = q, et = 0; et < it; et++)
Y[et].length = 0, Y[et].hasNulls = !1;
if (z += 1, q === m)
break;
}
if (q === m)
break;
if (V) {
et = _.options.dataGrouping && _.options.dataGrouping.groupAll ? q : _.cropStart + q, nt = D && D[et] || _.pointClass.prototype.applyOptions.apply({ series: _ }, [W[et]]);
var rt = void 0;
for (et = 0; et < Q; et++)
rt = nt[V[et]], b(rt) ? Y[et].push(rt) : rt === null && (Y[et].hasNulls = !0);
} else
et = L ? s[q] : null, b(et) ? Y[0].push(et) : et === null && (Y[0].hasNulls = !0);
}
return { groupedXData: P, groupedYData: X, groupMap: g };
};
var c = { approximations: a, groupData: R }, p = v.generatePoints, i = { groupPixelWidth: 2, dateTimeLabelFormats: { millisecond: [
"%A, %b %e, %H:%M:%S.%L",
"%A, %b %e, %H:%M:%S.%L",
"-%H:%M:%S.%L"
], second: ["%A, %b %e, %H:%M:%S", "%A, %b %e, %H:%M:%S", "-%H:%M:%S"], minute: ["%A, %b %e, %H:%M", "%A, %b %e, %H:%M", "-%H:%M"], hour: ["%A, %b %e, %H:%M", "%A, %b %e, %H:%M", "-%H:%M"], day: ["%A, %b %e, %Y", "%A, %b %e", "-%A, %b %e, %Y"], week: ["Week from %A, %b %e, %Y", "%A, %b %e", "-%A, %b %e, %Y"], month: ["%B %Y", "%B", "-%B %Y"], year: ["%Y", "%Y", "-%Y"] } }, h = {
line: {},
spline: {},
area: {},
areaspline: {},
arearange: {},
column: { groupPixelWidth: 10 },
columnrange: { groupPixelWidth: 10 },
candlestick: { groupPixelWidth: 10 },
ohlc: { groupPixelWidth: 5 },
hlc: { groupPixelWidth: 5 },
heikinashi: { groupPixelWidth: 10 }
}, o = Z.defaultDataGroupingUnits = [["millisecond", [1, 2, 5, 10, 20, 25, 50, 100, 200, 500]], ["second", [1, 2, 5, 10, 15, 30]], ["minute", [1, 2, 5, 10, 15, 30]], ["hour", [1, 2, 3, 4, 6, 8, 12]], ["day", [1]], ["week", [1]], ["month", [1, 3, 6]], ["year", null]];
return v.getDGApproximation = function() {
return this.is("arearange") ? "range" : this.is("ohlc") ? "ohlc" : this.is("hlc") ? "hlc" : this.is("column") ? "sum" : "average";
}, v.groupData = R, v.applyGrouping = function(t) {
var s = this.chart, n = this.options.dataGrouping, A = this.allowDG !== !1 && n && x(n.enabled, s.options.isStock), _ = this.visible || !s.options.chart.ignoreHiddenSeries, D, W = this.currentDataGrouping, P = !1;
if (A && !this.requireSorting && (this.requireSorting = P = !0), t = !!(this.isCartesian && !this.isDirty && !this.xAxis.isDirty && !this.yAxis.isDirty && !t) || !A, P && (this.requireSorting = !1), !t) {
this.destroyGroupedData(), A = n.groupAll ? this.xData : this.processedXData;
var X = n.groupAll ? this.yData : this.processedYData;
t = s.plotSizeX, P = this.xAxis;
var g = P.options.ordinal, m = this.groupPixelWidth;
if (m && A && A.length) {
this.isDirty = D = !0, this.points = null;
var L = P.getExtremes(), Y = L.min;
L = L.max, g = g && P.ordinal && P.ordinal.getGroupIntervalFactor(Y, L, this) || 1, t = P.getTimeTicks(j.Additions.prototype.normalizeTimeTickInterval(m * (L - Y) / t * g, n.units || o), Math.min(Y, A[0]), Math.max(L, A[A.length - 1]), P.options.startOfWeek, A, this.closestPointRange), m = v.groupData.apply(this, [A, X, t, n.approximation]), A = m.groupedXData, X = m.groupedYData, g = 0, n && n.smoothed && A.length && (n.firstAnchor = "firstPoint", n.anchor = "middle", n.lastAnchor = "lastPoint", B(32, !1, s, { "dataGrouping.smoothed": "use dataGrouping.anchor" })), s = A;
var V = this.options.dataGrouping;
if (Y = this.currentDataGrouping && this.currentDataGrouping.gapSize, V && this.xData && Y && this.groupMap) {
var Q = s.length - 1, k = V.anchor, G = x(V.firstAnchor, k);
if (V = x(V.lastAnchor, k), k && k !== "start") {
var z = Y * { middle: 0.5, end: 1 }[k];
for (k = s.length - 1; k-- && 0 < k; )
s[k] += z;
}
if (G && G !== "start" && this.xData[0] >= s[0]) {
k = this.groupMap[0].start, z = this.groupMap[0].length;
var $ = void 0;
b(k) && b(z) && ($ = k + (z - 1)), s[0] = { middle: s[0] + 0.5 * Y, end: s[0] + Y, firstPoint: this.xData[0], lastPoint: $ && this.xData[$] }[G];
}
V && V !== "start" && Y && s[Q] >= L - Y && (L = this.groupMap[this.groupMap.length - 1].start, s[Q] = { middle: s[Q] + 0.5 * Y, end: s[Q] + Y, firstPoint: L && this.xData[L], lastPoint: this.xData[this.xData.length - 1] }[V]);
}
for (L = 1; L < t.length; L++)
t.info.segmentStarts && t.info.segmentStarts.indexOf(L) !== -1 || (g = Math.max(t[L] - t[L - 1], g));
L = t.info, L.gapSize = g, this.closestPointRange = t.info.totalRange, this.groupMap = m.groupMap, _ && (_ = A, O(_[0]) && b(P.min) && b(P.dataMin) && _[0] < P.min && ((!O(P.options.min) && P.min <= P.dataMin || P.min === P.dataMin) && (P.min = Math.min(_[0], P.min)), P.dataMin = Math.min(_[0], P.dataMin)), O(_[_.length - 1]) && b(P.max) && b(P.dataMax) && _[_.length - 1] > P.max && ((!O(P.options.max) && b(P.dataMax) && P.max >= P.dataMax || P.max === P.dataMax) && (P.max = Math.max(_[_.length - 1], P.max)), P.dataMax = Math.max(_[_.length - 1], P.dataMax))), n.groupAll && (this.allGroupedData = X, n = this.cropData(A, X, P.min, P.max, 1), A = n.xData, X = n.yData, this.cropStart = n.start), this.processedXData = A, this.processedYData = X;
} else
this.groupMap = null;
this.hasGroupedData = D, this.currentDataGrouping = L, this.preventGraphAnimation = (W && W.totalRange) !== (L && L.totalRange);
}
}, v.destroyGroupedData = function() {
this.groupedData && (this.groupedData.forEach(function(t, s) {
t && (this.groupedData[s] = t.destroy ? t.destroy() : null);
}, this), this.groupedData.length = 0);
}, v.generatePoints = function() {
p.apply(this), this.destroyGroupedData(), this.groupedData = this.hasGroupedData ? this.points : null;
}, y.prototype.applyGrouping = function(t) {
var s = this;
s.series.forEach(function(n) {
n.groupPixelWidth = void 0, n.groupPixelWidth = s.getGroupPixelWidth && s.getGroupPixelWidth(), n.groupPixelWidth && (n.hasProcessed = !0), n.applyGrouping(!!t.hasExtemesChanged);
});
}, y.prototype.getGroupPixelWidth = function() {
var t = this.series, s = t.length, n, A = 0, _ = !1, D;
for (n = s; n--; )
(D = t[n].options.dataGrouping) && (A = Math.max(A, x(D.groupPixelWidth, i.groupPixelWidth)));
for (n = s; n--; )
(D = t[n].options.dataGrouping) && (s = (t[n].processedXData || t[n].data).length, (t[n].groupPixelWidth || s > this.chart.plotSizeX / A || s && D.forced) && (_ = !0));
return _ ? A : 0;
}, y.prototype.setDataGrouping = function(t, s) {
var n;
if (s = x(s, !0), t || (t = { forced: !1, units: null }), this instanceof y)
for (n = this.series.length; n--; )
this.series[n].update({ dataGrouping: t }, !1);
else
this.chart.options.series.forEach(function(A) {
A.dataGrouping = t;
}, !1);
this.ordinal && (this.ordinal.slope = void 0), s && this.chart.redraw();
}, I(y, "postProcessData", y.prototype.applyGrouping), I(H, "update", function() {
if (this.dataGroup)
return B(
24,
!1,
this.series.chart
), !1;
}), I(F, "headerFormatter", function(t) {
var s = this.chart, n = s.time, A = t.labelConfig, _ = A.series, D = _.tooltipOptions, W = _.options.dataGrouping, P = D.xDateFormat, X = _.xAxis, g = D[t.isFooter ? "footerFormat" : "headerFormat"];
if (X && X.options.type === "datetime" && W && b(A.key)) {
var m = _.currentDataGrouping;
if (W = W.dateTimeLabelFormats || i.dateTimeLabelFormats, m)
if (D = W[m.unitName], m.count === 1)
P = D[0];
else {
P = D[1];
var L = D[2];
}
else
!P && W && X.dateTime && (P = X.dateTime.getXDateFormat(A.x, D.dateTimeLabelFormats));
P = n.dateFormat(P, A.key), L && (P += n.dateFormat(L, A.key + m.totalRange - 1)), _.chart.styledMode && (g = this.styledModeFormat(g)), t.text = S(g, { point: C(A.point, { key: P }), series: _ }, s), t.preventDefault();
}
}), I(U, "destroy", v.destroyGroupedData), I(U, "afterSetOptions", function(t) {
t = t.options;
var s = this.type, n = this.chart.options.plotOptions, A = N.defaultOptions.plotOptions[s].dataGrouping, _ = this.useCommonDataGrouping && i;
if (n && (h[s] || _)) {
A || (A = w(i, h[s]));
var D = this.chart.rangeSelector;
t.dataGrouping = w(
_,
A,
n.series && n.series.dataGrouping,
n[s].dataGrouping,
this.userOptions.dataGrouping,
!t.isInternal && D && b(D.selected) && D.buttonOptions[D.selected].dataGrouping
);
}
}), I(y, "afterSetScale", function() {
this.series.forEach(function(t) {
t.hasProcessed = !1;
});
}), Z.dataGrouping = c, c;
}), E(l, "Series/HLC/HLCPoint.js", [l["Core/Series/SeriesRegistry.js"]], function(y) {
var j = this && this.__extends || function() {
var I = function(Z, H) {
return I = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(U, F) {
U.__proto__ = F;
} || function(U, F) {
for (var N in F)
F.hasOwnProperty(N) && (U[N] = F[N]);
}, I(Z, H);
};
return function(Z, H) {
function U() {
this.constructor = Z;
}
I(Z, H), Z.prototype = H === null ? Object.create(H) : (U.prototype = H.prototype, new U());
};
}();
return function(I) {
function Z() {
var H = I !== null && I.apply(this, arguments) || this;
return H.close = void 0, H.high = void 0, H.low = void 0, H.options = void 0, H.plotClose = void 0, H.series = void 0, H;
}
return j(Z, I), Z;
}(y.seriesTypes.column.prototype.pointClass);
}), E(
l,
"Series/HLC/HLCSeries.js",
[l["Series/HLC/HLCPoint.js"], l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]],
function(y, j, I) {
var Z = this && this.__extends || function() {
var N = function(R, S) {
return N = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(v, d) {
v.__proto__ = d;
} || function(v, d) {
for (var u in d)
d.hasOwnProperty(u) && (v[u] = d[u]);
}, N(R, S);
};
return function(R, S) {
function v() {
this.constructor = R;
}
N(R, S), R.prototype = S === null ? Object.create(S) : (v.prototype = S.prototype, new v());
};
}(), H = j.seriesTypes.column, U = I.extend, F = I.merge;
return I = function(N) {
function R() {
var S = N !== null && N.apply(this, arguments) || this;
return S.data = void 0, S.options = void 0, S.points = void 0, S.yData = void 0, S;
}
return Z(R, N), R.prototype.extendStem = function(S, v, d) {
var u = S[0];
S = S[1], typeof u[2] == "number" && (u[2] = Math.max(d + v, u[2])), typeof S[2] == "number" && (S[2] = Math.min(d - v, S[2]));
}, R.prototype.getPointPath = function(S, v) {
v = v.strokeWidth();
var d = S.series, u = v % 2 / 2, T = Math.round(S.plotX) - u, O = Math.round(S.shapeArgs.width / 2), B = [["M", T, Math.round(S.yBottom)], ["L", T, Math.round(S.plotHigh)]];
return S.close !== null && (S = Math.round(S.plotClose) + u, B.push(["M", T, S], ["L", T + O, S]), d.extendStem(B, v / 2, S)), B;
}, R.prototype.drawSinglePoint = function(S) {
var v = S.series, d = v.chart, u = S.graphic, T = !u;
typeof S.plotY < "u" && (u || (S.graphic = u = d.renderer.path().add(v.group)), d.styledMode || u.attr(v.pointAttribs(S, S.selected && "select")), v = v.getPointPath(S, u), u[T ? "attr" : "animate"]({ d: v }).addClass(S.getClassName(), !0));
}, R.prototype.drawPoints = function() {
this.points.forEach(this.drawSinglePoint);
}, R.prototype.init = function() {
N.prototype.init.apply(this, arguments), this.options.stacking = void 0;
}, R.prototype.pointAttribs = function(S, v) {
return S = N.prototype.pointAttribs.call(this, S, v), delete S.fill, S;
}, R.prototype.toYData = function(S) {
return [S.high, S.low, S.close];
}, R.prototype.translate = function() {
var S = this, v = S.yAxis, d = this.pointArrayMap && this.pointArrayMap.slice() || [], u = d.map(function(T) {
return "plot" + (T.charAt(0).toUpperCase() + T.slice(1));
});
u.push("yBottom"), d.push("low"), N.prototype.translate.apply(S), S.points.forEach(function(T) {
d.forEach(function(O, B) {
O = T[O], O !== null && (S.dataModify && (O = S.dataModify.modifyValue(O)), T[u[B]] = v.toPixels(O, !0));
}), T.tooltipPos[1] = T.plotHigh + v.pos - S.chart.plotTop;
});
}, R.defaultOptions = F(H.defaultOptions, { lineWidth: 1, tooltip: { pointFormat: '● {series.name}
High: {point.high}
Low: {point.low}
Close: {point.close}
' }, threshold: null, states: { hover: { lineWidth: 3 } }, stickyTracking: !0 }), R;
}(H), U(I.prototype, { animate: null, directTouch: !1, pointArrayMap: ["high", "low", "close"], pointAttrToOptions: {
stroke: "color",
"stroke-width": "lineWidth"
}, pointValKey: "close" }), I.prototype.pointClass = y, j.registerSeriesType("hlc", I), I;
}
), E(l, "Series/OHLC/OHLCPoint.js", [l["Core/Series/SeriesRegistry.js"]], function(y) {
var j = this && this.__extends || function() {
var I = function(Z, H) {
return I = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(U, F) {
U.__proto__ = F;
} || function(U, F) {
for (var N in F)
F.hasOwnProperty(N) && (U[N] = F[N]);
}, I(Z, H);
};
return function(Z, H) {
function U() {
this.constructor = Z;
}
I(Z, H), Z.prototype = H === null ? Object.create(H) : (U.prototype = H.prototype, new U());
};
}();
return function(I) {
function Z() {
var H = I !== null && I.apply(this, arguments) || this;
return H.open = void 0, H.options = void 0, H.plotOpen = void 0, H.series = void 0, H;
}
return j(Z, I), Z.prototype.getClassName = function() {
return I.prototype.getClassName.call(this) + (this.open < this.close ? " highcharts-point-up" : " highcharts-point-down");
}, Z.prototype.resolveUpColor = function() {
this.open < this.close && !this.options.color && this.series.options.upColor && (this.color = this.series.options.upColor);
}, Z.prototype.resolveColor = function() {
I.prototype.resolveColor.call(this), this.resolveUpColor();
}, Z.prototype.getZone = function() {
var H = I.prototype.getZone.call(this);
return this.resolveUpColor(), H;
}, Z.prototype.applyOptions = function() {
return I.prototype.applyOptions.apply(this, arguments), this.resolveColor && this.resolveColor(), this;
}, Z;
}(y.seriesTypes.hlc.prototype.pointClass);
}), E(
l,
"Series/OHLC/OHLCSeries.js",
[l["Series/OHLC/OHLCPoint.js"], l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]],
function(y, j, I) {
var Z = this && this.__extends || function() {
var v = function(d, u) {
return v = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(T, O) {
T.__proto__ = O;
} || function(T, O) {
for (var B in O)
O.hasOwnProperty(B) && (T[B] = O[B]);
}, v(d, u);
};
return function(d, u) {
function T() {
this.constructor = d;
}
v(d, u), d.prototype = u === null ? Object.create(u) : (T.prototype = u.prototype, new T());
};
}(), H = j.series, U = j.seriesTypes.hlc, F = I.addEvent, N = I.extend, R = I.merge, S = function(v) {
function d() {
var u = v !== null && v.apply(this, arguments) || this;
return u.data = void 0, u.options = void 0, u.points = void 0, u;
}
return Z(d, v), d.prototype.getPointPath = function(u, T) {
var O = v.prototype.getPointPath.call(this, u, T);
T = T.strokeWidth();
var B = T % 2 / 2, C = Math.round(u.plotX) - B, b = Math.round(u.shapeArgs.width / 2);
return u.open !== null && (u = Math.round(u.plotOpen) + B, O.push(["M", C, u], ["L", C - b, u]), v.prototype.extendStem.call(this, O, T / 2, u)), O;
}, d.prototype.pointAttribs = function(u, T) {
T = v.prototype.pointAttribs.call(this, u, T);
var O = this.options;
return delete T.fill, !u.options.color && O.upColor && u.open < u.close && (T.stroke = O.upColor), T;
}, d.prototype.toYData = function(u) {
return [u.open, u.high, u.low, u.close];
}, d.defaultOptions = R(U.defaultOptions, { tooltip: { pointFormat: '● {series.name}
Open: {point.open}
High: {point.high}
Low: {point.low}
Close: {point.close}
' } }), d;
}(U);
return N(S.prototype, { pointArrayMap: ["open", "high", "low", "close"] }), S.prototype.pointClass = y, j.registerSeriesType("ohlc", S), F(H, "init", function(v) {
v = v.options, v.useOhlcData && v.id !== "highcharts-navigator-series" && N(this, { pointValKey: S.prototype.pointValKey, pointArrayMap: S.prototype.pointArrayMap, toYData: S.prototype.toYData });
}), F(H, "afterSetOptions", function(v) {
v = v.options;
var d = v.dataGrouping;
d && v.useOhlcData && v.id !== "highcharts-navigator-series" && (d.approximation = "ohlc");
}), S;
}
), E(l, "Series/Candlestick/CandlestickSeries.js", [l["Core/DefaultOptions.js"], l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = this && this.__extends || function() {
var R = function(S, v) {
return R = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(d, u) {
d.__proto__ = u;
} || function(d, u) {
for (var T in u)
u.hasOwnProperty(T) && (d[T] = u[T]);
}, R(S, v);
};
return function(S, v) {
function d() {
this.constructor = S;
}
R(S, v), S.prototype = v === null ? Object.create(v) : (d.prototype = v.prototype, new d());
};
}(), H = y.defaultOptions;
y = j.seriesTypes;
var U = y.column, F = y.ohlc, N = I.merge;
return I = function(R) {
function S() {
var v = R !== null && R.apply(this, arguments) || this;
return v.data = void 0, v.options = void 0, v.points = void 0, v;
}
return Z(S, R), S.prototype.pointAttribs = function(v, d) {
var u = U.prototype.pointAttribs.call(this, v, d), T = this.options, O = v.open < v.close, B = T.lineColor || this.color, C = v.color || this.color;
return u["stroke-width"] = T.lineWidth, u.fill = v.options.color || O && T.upColor || C, u.stroke = v.options.lineColor || O && T.upLineColor || B, d && (v = T.states[d], u.fill = v.color || u.fill, u.stroke = v.lineColor || u.stroke, u["stroke-width"] = v.lineWidth || u["stroke-width"]), u;
}, S.prototype.drawPoints = function() {
var v = this, d = v.chart, u = v.yAxis.reversed;
v.points.forEach(function(T) {
var O = T.graphic, B = !O;
if (typeof T.plotY < "u") {
O || (T.graphic = O = d.renderer.path().add(v.group)), v.chart.styledMode || O.attr(v.pointAttribs(T, T.selected && "select")).shadow(v.options.shadow);
var C = O.strokeWidth() % 2 / 2, b = Math.round(T.plotX) - C, w = T.plotOpen, x = T.plotClose, a = Math.min(w, x);
w = Math.max(w, x);
var c = Math.round(T.shapeArgs.width / 2);
x = u ? w !== T.yBottom : Math.round(a) !== Math.round(T.plotHigh);
var p = u ? Math.round(a) !== Math.round(T.plotHigh) : w !== T.yBottom;
a = Math.round(a) + C, w = Math.round(w) + C, C = [], C.push(["M", b - c, w], ["L", b - c, a], ["L", b + c, a], ["L", b + c, w], ["Z"], ["M", b, a], ["L", b, x ? Math.round(u ? T.yBottom : T.plotHigh) : a], ["M", b, w], ["L", b, p ? Math.round(u ? T.plotHigh : T.yBottom) : w]), O[B ? "attr" : "animate"]({ d: C }).addClass(T.getClassName(), !0);
}
});
}, S.defaultOptions = N(F.defaultOptions, H.plotOptions, { states: { hover: { lineWidth: 2 } }, tooltip: H.plotOptions.ohlc.tooltip, threshold: null, lineColor: "#000000", lineWidth: 1, upColor: "#ffffff", stickyTracking: !0 }), S;
}(F), j.registerSeriesType("candlestick", I), I;
}), E(l, "Series/Flags/FlagsPoint.js", [l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]], function(y, j) {
var I = this && this.__extends || function() {
var H = function(U, F) {
return H = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(N, R) {
N.__proto__ = R;
} || function(N, R) {
for (var S in R)
R.hasOwnProperty(S) && (N[S] = R[S]);
}, H(U, F);
};
return function(U, F) {
function N() {
this.constructor = U;
}
H(U, F), U.prototype = F === null ? Object.create(F) : (N.prototype = F.prototype, new N());
};
}(), Z = j.isNumber;
return function(H) {
function U() {
var F = H !== null && H.apply(this, arguments) || this;
return F.options = void 0, F.series = void 0, F;
}
return I(U, H), U.prototype.isValid = function() {
return Z(this.y) || typeof this.y > "u";
}, U.prototype.hasNewShapeType = function() {
var F = this.options.shape || this.series.options.shape;
return this.graphic && F && F !== this.graphic.symbolKey;
}, U;
}(y.seriesTypes.column.prototype.pointClass);
}), E(l, "Series/OnSeriesComposition.js", [
l["Series/Column/ColumnSeries.js"],
l["Core/Series/Series.js"],
l["Core/Utilities.js"]
], function(y, j, I) {
var Z = y.prototype, H = j.prototype, U = I.defined, F = I.stableSort, N;
return function(R) {
function S() {
return H.getPlotBox.call(this.options.onSeries && this.chart.get(this.options.onSeries) || this);
}
function v() {
Z.translate.apply(this);
var u = this, T = u.options, O = u.chart, B = u.points, C = T.onSeries, b = (C = C && O.get(C)) && C.options.step, w = C && C.points, x = O.inverted, a = u.xAxis, c = u.yAxis;
O = B.length - 1;
var p;
T = T.onKey || "y";
var i = w && w.length, h = 0, o;
if (C && C.visible && i) {
h = (C.pointXOffset || 0) + (C.barW || 0) / 2;
var t = C.currentDataGrouping, s = w[i - 1].x + (t ? t.totalRange : 0);
for (F(B, function(_, D) {
return _.x - D.x;
}), T = "plot" + T[0].toUpperCase() + T.substr(1); i-- && B[O]; ) {
var n = w[i];
if (t = B[O], t.y = n.y, n.x <= t.x && typeof n[T] < "u") {
if (t.x <= s && (t.plotY = n[T], n.x < t.x && !b && (o = w[i + 1]) && typeof o[T] < "u")) {
var A = (t.x - n.x) / (o.x - n.x);
t.plotY += A * (o[T] - n[T]), t.y += A * (o.y - n.y);
}
if (O--, i++, 0 > O)
break;
}
}
}
B.forEach(function(_, D) {
if (_.plotX += h, (typeof _.plotY > "u" || x) && (0 <= _.plotX && _.plotX <= a.len ? x ? (_.plotY = a.translate(_.x, 0, 1, 0, 1), _.plotX = U(_.y) ? c.translate(_.y, 0, 0, 0, 1) : 0) : _.plotY = (a.opposite ? 0 : u.yAxis.len) + a.offset : _.shapeArgs = {}), (p = B[D - 1]) && p.plotX === _.plotX) {
typeof p.stackIndex > "u" && (p.stackIndex = 0);
var W = p.stackIndex + 1;
}
_.stackIndex = W;
}), this.onSeries = C;
}
var d = [];
R.compose = function(u) {
if (d.indexOf(u) === -1) {
d.push(u);
var T = u.prototype;
T.getPlotBox = S, T.translate = v;
}
return u;
}, R.getPlotBox = S, R.translate = v;
}(N || (N = {})), N;
}), E(
l,
"Series/Flags/FlagsSymbols.js",
[l["Core/Renderer/RendererRegistry.js"], l["Core/Renderer/SVG/SVGRenderer.js"]],
function(y, j) {
function I(H) {
Z[H + "pin"] = function(U, F, N, R, S) {
var v = S && S.anchorX;
S = S && S.anchorY, H === "circle" && R > N && (U -= Math.round((R - N) / 2), N = R);
var d = Z[H](U, F, N, R);
if (v && S) {
var u = v;
H === "circle" ? u = U + N / 2 : (U = d[0], N = d[1], U[0] === "M" && N[0] === "L" && (u = (U[1] + N[1]) / 2)), d.push(["M", u, F > S ? F : F + R], ["L", v, S]), d = d.concat(Z.circle(v - 1, S - 1, 2, 2));
}
return d;
};
}
var Z = j.prototype.symbols;
return Z.flag = function(H, U, F, N, R) {
var S = R && R.anchorX || H;
R = R && R.anchorY || U;
var v = Z.circle(S - 1, R - 1, 2, 2);
return v.push(["M", S, R], ["L", H, U + N], ["L", H, U], ["L", H + F, U], ["L", H + F, U + N], ["L", H, U + N], ["Z"]), v;
}, I("circle"), I("square"), y = y.getRendererType(), y !== j && (y.prototype.symbols.circlepin = Z.circlepin, y.prototype.symbols.flag = Z.flag, y.prototype.symbols.squarepin = Z.squarepin), Z;
}
), E(l, "Series/Flags/FlagsSeries.js", [
l["Series/Flags/FlagsPoint.js"],
l["Core/Globals.js"],
l["Series/OnSeriesComposition.js"],
l["Core/Renderer/RendererUtilities.js"],
l["Core/Series/SeriesRegistry.js"],
l["Core/Renderer/SVG/SVGElement.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z, H, U, F) {
var N = this && this.__extends || function() {
var C = function(b, w) {
return C = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(x, a) {
x.__proto__ = a;
} || function(x, a) {
for (var c in a)
a.hasOwnProperty(c) && (x[c] = a[c]);
}, C(b, w);
};
return function(b, w) {
function x() {
this.constructor = b;
}
C(b, w), b.prototype = w === null ? Object.create(w) : (x.prototype = w.prototype, new x());
};
}();
j = j.noop;
var R = Z.distribute, S = H.series, v = H.seriesTypes.column, d = F.addEvent, u = F.defined;
Z = F.extend;
var T = F.merge, O = F.objectEach, B = F.wrap;
return F = function(C) {
function b() {
var w = C !== null && C.apply(this, arguments) || this;
return w.data = void 0, w.options = void 0, w.points = void 0, w;
}
return N(b, C), b.prototype.animate = function(w) {
w && this.setClip();
}, b.prototype.drawPoints = function() {
var w = this.points, x = this.chart, a = x.renderer, c = x.inverted, p = this.options, i = p.y, h, o = this.yAxis, t = {}, s = [];
for (h = w.length; h--; ) {
var n = w[h], A = (c ? n.plotY : n.plotX) > this.xAxis.len, _ = n.plotX, D = n.stackIndex, W = n.options.shape || p.shape, P = n.plotY;
typeof P < "u" && (P = n.plotY + i - (typeof D < "u" && D * p.stackDistance)), n.anchorX = D ? void 0 : n.plotX;
var X = D ? void 0 : n.plotY, g = W !== "flag";
D = n.graphic, typeof P < "u" && 0 <= _ && !A ? (D && n.hasNewShapeType() && (D = D.destroy()), D || (D = n.graphic = a.label("", null, null, W, null, null, p.useHTML).addClass("highcharts-point").add(this.markerGroup), n.graphic.div && (n.graphic.div.point = n), D.isNew = !0), D.attr({
align: g ? "center" : "left",
width: p.width,
height: p.height,
"text-align": p.textAlign
}), x.styledMode || D.attr(this.pointAttribs(n)).css(T(p.style, n.style)).shadow(p.shadow), 0 < _ && (_ -= D.strokeWidth() % 2), W = { y: P, anchorY: X }, p.allowOverlapX && (W.x = _, W.anchorX = n.anchorX), D.attr({ text: n.options.title || p.title || "A" })[D.isNew ? "attr" : "animate"](W), p.allowOverlapX || (t[n.plotX] ? t[n.plotX].size = Math.max(t[n.plotX].size, D.width) : t[n.plotX] = { align: g ? 0.5 : 0, size: D.width, target: _, anchorX: _ }), n.tooltipPos = [_, P + o.pos - x.plotTop]) : D && (n.graphic = D.destroy());
}
if (!p.allowOverlapX) {
var m = 100;
O(t, function(L) {
L.plotX = L.anchorX, s.push(L), m = Math.max(L.size, m);
}), R(s, c ? o.len : this.xAxis.len, m), w.forEach(function(L) {
var Y = L.graphic && t[L.plotX];
Y && (L.graphic[L.graphic.isNew ? "attr" : "animate"]({ x: Y.pos + Y.align * Y.size, anchorX: L.anchorX }), u(Y.pos) ? L.graphic.isNew = !1 : (L.graphic.attr({ x: -9999, anchorX: -9999 }), L.graphic.isNew = !0));
});
}
p.useHTML && B(this.markerGroup, "on", function(L) {
return U.prototype.on.apply(L.apply(this, [].slice.call(arguments, 1)), [].slice.call(arguments, 1));
});
}, b.prototype.drawTracker = function() {
var w = this.points;
C.prototype.drawTracker.call(this), w.forEach(function(x) {
var a = x.graphic;
a && (x.unbindMouseOver && x.unbindMouseOver(), x.unbindMouseOver = d(a.element, "mouseover", function() {
0 < x.stackIndex && !x.raised && (x._y = a.y, a.attr({ y: x._y - 8 }), x.raised = !0), w.forEach(function(c) {
c !== x && c.raised && c.graphic && (c.graphic.attr({ y: c._y }), c.raised = !1);
});
}));
});
}, b.prototype.pointAttribs = function(w, x) {
var a = this.options, c = w && w.color || this.color, p = a.lineColor, i = w && w.lineWidth;
return w = w && w.fillColor || a.fillColor, x && (w = a.states[x].fillColor, p = a.states[x].lineColor, i = a.states[x].lineWidth), { fill: w || c, stroke: p || c, "stroke-width": i || a.lineWidth || 0 };
}, b.prototype.setClip = function() {
S.prototype.setClip.apply(this, arguments), this.options.clip !== !1 && this.sharedClipKey && this.markerGroup && this.markerGroup.clip(this.chart.sharedClips[this.sharedClipKey]);
}, b.defaultOptions = T(v.defaultOptions, {
pointRange: 0,
allowOverlapX: !1,
shape: "flag",
stackDistance: 12,
textAlign: "center",
tooltip: { pointFormat: "{point.text}" },
threshold: null,
y: -30,
fillColor: "#ffffff",
lineWidth: 1,
states: { hover: { lineColor: "#000000", fillColor: "#ccd6eb" } },
style: { fontSize: "11px", fontWeight: "bold" }
}), b;
}(v), I.compose(F), Z(F.prototype, { allowDG: !1, forceCrop: !0, invertible: !1, noSharedTooltip: !0, pointClass: y, sorted: !1, takeOrdinalPosition: !1, trackerGroups: ["markerGroup"], buildKDTree: j, init: S.prototype.init, invertGroups: j }), H.registerSeriesType("flags", F), F;
}), E(l, "Core/Axis/ScrollbarAxis.js", [l["Core/Utilities.js"]], function(y) {
var j = y.addEvent, I = y.defined, Z = y.pick;
return function() {
function H() {
}
return H.compose = function(U, F) {
if (H.composed.indexOf(U) === -1)
H.composed.push(U);
else
return U;
var N = function(R) {
var S = Z(R.options && R.options.min, R.min), v = Z(R.options && R.options.max, R.max);
return { axisMin: S, axisMax: v, scrollMin: I(R.dataMin) ? Math.min(S, R.min, R.dataMin, Z(R.threshold, 1 / 0)) : S, scrollMax: I(R.dataMax) ? Math.max(v, R.max, R.dataMax, Z(R.threshold, -1 / 0)) : v };
};
return j(U, "afterInit", function() {
var R = this;
R.options && R.options.scrollbar && R.options.scrollbar.enabled && (R.options.scrollbar.vertical = !R.horiz, R.options.startOnTick = R.options.endOnTick = !1, R.scrollbar = new F(R.chart.renderer, R.options.scrollbar, R.chart), j(R.scrollbar, "changed", function(S) {
var v = N(R), d = v.axisMax, u = v.scrollMin, T = v.scrollMax - u;
I(v.axisMin) && I(d) && (R.horiz && !R.reversed || !R.horiz && R.reversed ? (v = u + T * this.to, u += T * this.from) : (v = u + T * (1 - this.from), u += T * (1 - this.to)), this.shouldUpdateExtremes(S.DOMType) ? R.setExtremes(u, v, !0, S.DOMType !== "mousemove" && S.DOMType !== "touchmove", S) : this.setRange(
this.from,
this.to
));
}));
}), j(U, "afterRender", function() {
var R = N(this), S = R.scrollMin, v = R.scrollMax;
R = this.scrollbar;
var d = this.axisTitleMargin + (this.titleOffset || 0), u = this.chart.scrollbarsOffsets, T = this.options.margin || 0;
R && (this.horiz ? (this.opposite || (u[1] += d), R.position(this.left, this.top + this.height + 2 + u[1] - (this.opposite ? T : 0), this.width, this.height), this.opposite || (u[1] += T), d = 1) : (this.opposite && (u[0] += d), R.position(
R.options.opposite ? this.left + this.width + 2 + u[0] - (this.opposite ? 0 : T) : this.opposite ? 0 : T,
this.top,
this.width,
this.height
), this.opposite && (u[0] += T), d = 0), u[d] += R.size + R.options.margin, isNaN(S) || isNaN(v) || !I(this.min) || !I(this.max) || this.min === this.max ? R.setRange(0, 1) : (u = (this.min - S) / (v - S), S = (this.max - S) / (v - S), this.horiz && !this.reversed || !this.horiz && this.reversed ? R.setRange(u, S) : R.setRange(1 - S, 1 - u)));
}), j(U, "afterGetOffset", function() {
var R = this.scrollbar && !this.scrollbar.options.opposite;
R = this.horiz ? 2 : R ? 3 : 1;
var S = this.scrollbar;
S && (this.chart.scrollbarsOffsets = [0, 0], this.chart.axisOffset[R] += S.size + S.options.margin);
}), U;
}, H.composed = [], H;
}();
}), E(l, "Core/ScrollbarDefaults.js", [l["Core/Globals.js"]], function(y) {
return {
height: y.isTouchDevice ? 20 : 14,
barBorderRadius: 0,
buttonBorderRadius: 0,
liveRedraw: void 0,
margin: 10,
minWidth: 6,
opposite: !0,
step: 0.2,
zIndex: 3,
barBackgroundColor: "#cccccc",
barBorderWidth: 1,
barBorderColor: "#cccccc",
buttonArrowColor: "#333333",
buttonBackgroundColor: "#e6e6e6",
buttonBorderColor: "#cccccc",
buttonBorderWidth: 1,
rifleColor: "#333333",
trackBackgroundColor: "#f2f2f2",
trackBorderColor: "#f2f2f2",
trackBorderWidth: 1
};
}), E(l, "Core/Scrollbar.js", [l["Core/DefaultOptions.js"], l["Core/Globals.js"], l["Core/Axis/ScrollbarAxis.js"], l["Core/ScrollbarDefaults.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H) {
var U = y.defaultOptions, F = H.addEvent, N = H.correctFloat, R = H.defined, S = H.destroyObjectProperties, v = H.fireEvent, d = H.merge, u = H.pick, T = H.removeEvent;
return y = function() {
function O(B, C, b) {
this._events = [], this.chart = void 0, this.from = this.chartY = this.chartX = 0, this.scrollbar = this.renderer = this.options = this.group = void 0, this.scrollbarButtons = [], this.scrollbarGroup = void 0, this.scrollbarLeft = 0, this.scrollbarRifles = void 0, this.scrollbarStrokeWidth = 1, this.to = this.size = this.scrollbarTop = 0, this.track = void 0, this.trackBorderWidth = 1, this.userOptions = void 0, this.y = this.x = 0, this.init(B, C, b);
}
return O.compose = function(B) {
I.compose(B, O);
}, O.swapXY = function(B, C) {
return C && B.forEach(function(b) {
for (var w = b.length, x, a = 0; a < w; a += 2)
x = b[a + 1], typeof x == "number" && (b[a + 1] = b[a + 2], b[a + 2] = x);
}), B;
}, O.prototype.addEvents = function() {
var B = this.options.inverted ? [1, 0] : [0, 1], C = this.scrollbarButtons, b = this.scrollbarGroup.element, w = this.track.element, x = this.mouseDownHandler.bind(this), a = this.mouseMoveHandler.bind(this), c = this.mouseUpHandler.bind(this);
B = [[C[B[0]].element, "click", this.buttonToMinClick.bind(this)], [C[B[1]].element, "click", this.buttonToMaxClick.bind(this)], [w, "click", this.trackClick.bind(this)], [b, "mousedown", x], [b.ownerDocument, "mousemove", a], [b.ownerDocument, "mouseup", c]], j.hasTouch && B.push(
[b, "touchstart", x],
[b.ownerDocument, "touchmove", a],
[b.ownerDocument, "touchend", c]
), B.forEach(function(p) {
F.apply(null, p);
}), this._events = B;
}, O.prototype.buttonToMaxClick = function(B) {
var C = (this.to - this.from) * u(this.options.step, 0.2);
this.updatePosition(this.from + C, this.to + C), v(this, "changed", { from: this.from, to: this.to, trigger: "scrollbar", DOMEvent: B });
}, O.prototype.buttonToMinClick = function(B) {
var C = N(this.to - this.from) * u(this.options.step, 0.2);
this.updatePosition(N(this.from - C), N(this.to - C)), v(this, "changed", {
from: this.from,
to: this.to,
trigger: "scrollbar",
DOMEvent: B
});
}, O.prototype.cursorToScrollbarPosition = function(B) {
var C = this.options;
return C = C.minWidth > this.calculatedWidth ? C.minWidth : 0, { chartX: (B.chartX - this.x - this.xOffset) / (this.barWidth - C), chartY: (B.chartY - this.y - this.yOffset) / (this.barWidth - C) };
}, O.prototype.destroy = function() {
var B = this, C = B.chart.scroller;
B.removeEvents(), ["track", "scrollbarRifles", "scrollbar", "scrollbarGroup", "group"].forEach(function(b) {
B[b] && B[b].destroy && (B[b] = B[b].destroy());
}), C && B === C.scrollbar && (C.scrollbar = null, S(C.scrollbarButtons));
}, O.prototype.drawScrollbarButton = function(B) {
var C = this.renderer, b = this.scrollbarButtons, w = this.options, x = this.size, a = C.g().add(this.group);
b.push(a), a = C.rect().addClass("highcharts-scrollbar-button").add(a), this.chart.styledMode || a.attr({ stroke: w.buttonBorderColor, "stroke-width": w.buttonBorderWidth, fill: w.buttonBackgroundColor }), a.attr(a.crisp({ x: -0.5, y: -0.5, width: x + 1, height: x + 1, r: w.buttonBorderRadius }, a.strokeWidth())), a = C.path(O.swapXY([["M", x / 2 + (B ? -1 : 1), x / 2 - 3], ["L", x / 2 + (B ? -1 : 1), x / 2 + 3], ["L", x / 2 + (B ? 2 : -2), x / 2]], w.vertical)).addClass("highcharts-scrollbar-arrow").add(b[B]), this.chart.styledMode || a.attr({ fill: w.buttonArrowColor });
}, O.prototype.init = function(B, C, b) {
this.scrollbarButtons = [], this.renderer = B, this.userOptions = C, this.options = d(Z, U.scrollbar, C), this.chart = b, this.size = u(this.options.size, this.options.height), C.enabled && (this.render(), this.addEvents());
}, O.prototype.mouseDownHandler = function(B) {
B = this.chart.pointer.normalize(B), B = this.cursorToScrollbarPosition(B), this.chartX = B.chartX, this.chartY = B.chartY, this.initPositions = [this.from, this.to], this.grabbedCenter = !0;
}, O.prototype.mouseMoveHandler = function(B) {
var C = this.chart.pointer.normalize(B), b = this.options.vertical ? "chartY" : "chartX", w = this.initPositions || [];
!this.grabbedCenter || B.touches && B.touches[0][b] === 0 || (C = this.cursorToScrollbarPosition(C)[b], b = this[b], b = C - b, this.hasDragged = !0, this.updatePosition(w[0] + b, w[1] + b), this.hasDragged && v(this, "changed", { from: this.from, to: this.to, trigger: "scrollbar", DOMType: B.type, DOMEvent: B }));
}, O.prototype.mouseUpHandler = function(B) {
this.hasDragged && v(this, "changed", { from: this.from, to: this.to, trigger: "scrollbar", DOMType: B.type, DOMEvent: B }), this.grabbedCenter = this.hasDragged = this.chartX = this.chartY = null;
}, O.prototype.position = function(B, C, b, w) {
var x = this.options.vertical, a = this.rendered ? "animate" : "attr", c = 0;
this.x = B, this.y = C + this.trackBorderWidth, this.width = b, this.xOffset = this.height = w, this.yOffset = c, x ? (this.width = this.yOffset = b = c = this.size, this.xOffset = C = 0, this.barWidth = w - 2 * b, this.x = B += this.options.margin) : (this.height = this.xOffset = w = C = this.size, this.barWidth = b - 2 * w, this.y += this.options.margin), this.group[a]({ translateX: B, translateY: this.y }), this.track[a]({ width: b, height: w }), this.scrollbarButtons[1][a]({ translateX: x ? 0 : b - C, translateY: x ? w - c : 0 });
}, O.prototype.removeEvents = function() {
this._events.forEach(function(B) {
T.apply(null, B);
}), this._events.length = 0;
}, O.prototype.render = function() {
var B = this.renderer, C = this.options, b = this.size, w = this.chart.styledMode, x = B.g("scrollbar").attr({ zIndex: C.zIndex, translateY: -99999 }).add();
this.group = x, this.track = B.rect().addClass("highcharts-scrollbar-track").attr({ x: 0, r: C.trackBorderRadius || 0, height: b, width: b }).add(x), w || this.track.attr({ fill: C.trackBackgroundColor, stroke: C.trackBorderColor, "stroke-width": C.trackBorderWidth }), this.trackBorderWidth = this.track.strokeWidth(), this.track.attr({ y: -this.trackBorderWidth % 2 / 2 }), this.scrollbarGroup = B.g().add(x), this.scrollbar = B.rect().addClass("highcharts-scrollbar-thumb").attr({ height: b, width: b, r: C.barBorderRadius || 0 }).add(this.scrollbarGroup), this.scrollbarRifles = B.path(O.swapXY([["M", -3, b / 4], ["L", -3, 2 * b / 3], ["M", 0, b / 4], ["L", 0, 2 * b / 3], ["M", 3, b / 4], ["L", 3, 2 * b / 3]], C.vertical)).addClass("highcharts-scrollbar-rifles").add(this.scrollbarGroup), w || (this.scrollbar.attr({ fill: C.barBackgroundColor, stroke: C.barBorderColor, "stroke-width": C.barBorderWidth }), this.scrollbarRifles.attr({ stroke: C.rifleColor, "stroke-width": 1 })), this.scrollbarStrokeWidth = this.scrollbar.strokeWidth(), this.scrollbarGroup.translate(-this.scrollbarStrokeWidth % 2 / 2, -this.scrollbarStrokeWidth % 2 / 2), this.drawScrollbarButton(0), this.drawScrollbarButton(1);
}, O.prototype.setRange = function(B, C) {
var b = this.options, w = b.vertical, x = b.minWidth, a = this.barWidth, c = !this.rendered || this.hasDragged || this.chart.navigator && this.chart.navigator.hasDragged ? "attr" : "animate";
if (R(a)) {
var p = a * Math.min(C, 1);
B = Math.max(B, 0);
var i = Math.ceil(a * B);
this.calculatedWidth = p = N(p - i), p < x && (i = (a - x + p) * B, p = x), x = Math.floor(i + this.xOffset + this.yOffset), a = p / 2 - 0.5, this.from = B, this.to = C, w ? (this.scrollbarGroup[c]({ translateY: x }), this.scrollbar[c]({ height: p }), this.scrollbarRifles[c]({ translateY: a }), this.scrollbarTop = x, this.scrollbarLeft = 0) : (this.scrollbarGroup[c]({ translateX: x }), this.scrollbar[c]({ width: p }), this.scrollbarRifles[c]({ translateX: a }), this.scrollbarLeft = x, this.scrollbarTop = 0), 12 >= p ? this.scrollbarRifles.hide() : this.scrollbarRifles.show(!0), b.showFull === !1 && (0 >= B && 1 <= C ? this.group.hide() : this.group.show()), this.rendered = !0;
}
}, O.prototype.shouldUpdateExtremes = function(B) {
return u(this.options.liveRedraw, j.svg && !j.isTouchDevice && !this.chart.isBoosting) || B === "mouseup" || B === "touchend" || !R(B);
}, O.prototype.trackClick = function(B) {
var C = this.chart.pointer.normalize(B), b = this.to - this.from, w = this.y + this.scrollbarTop, x = this.x + this.scrollbarLeft;
this.options.vertical && C.chartY > w || !this.options.vertical && C.chartX > x ? this.updatePosition(this.from + b, this.to + b) : this.updatePosition(this.from - b, this.to - b), v(this, "changed", { from: this.from, to: this.to, trigger: "scrollbar", DOMEvent: B });
}, O.prototype.update = function(B) {
this.destroy(), this.init(this.chart.renderer, d(
!0,
this.options,
B
), this.chart);
}, O.prototype.updatePosition = function(B, C) {
1 < C && (B = N(1 - N(C - B)), C = 1), 0 > B && (C = N(C - B), B = 0), this.from = B, this.to = C;
}, O.defaultOptions = Z, O;
}(), U.scrollbar = d(!0, y.defaultOptions, U.scrollbar), y;
}), E(l, "Core/Axis/NavigatorAxis.js", [l["Core/Globals.js"], l["Core/Utilities.js"]], function(y, j) {
var I = y.isTouchDevice, Z = j.addEvent, H = j.correctFloat, U = j.defined, F = j.isNumber, N = j.pick, R = function() {
function S(v) {
this.axis = v;
}
return S.prototype.destroy = function() {
this.axis = void 0;
}, S.prototype.toFixedRange = function(v, d, u, T) {
var O = this.axis, B = O.chart;
B = B && B.fixedRange;
var C = (O.pointRange || 0) / 2;
return v = N(u, O.translate(v, !0, !O.horiz)), d = N(T, O.translate(d, !0, !O.horiz)), O = B && (d - v) / B, U(u) || (v = H(v + C)), U(T) || (d = H(d - C)), 0.7 < O && 1.3 > O && (T ? v = d - B : d = v + B), F(v) && F(d) || (v = d = void 0), { min: v, max: d };
}, S;
}();
return function() {
function S() {
}
return S.compose = function(v) {
v.keepProps.push("navigatorAxis"), Z(v, "init", function() {
this.navigatorAxis || (this.navigatorAxis = new R(this));
}), Z(v, "zoom", function(d) {
var u = this.chart.options, T = u.navigator, O = this.navigatorAxis, B = u.chart.pinchType, C = u.rangeSelector;
u = u.chart.zoomType, this.isXAxis && (T && T.enabled || C && C.enabled) && (u === "y" ? d.zoomed = !1 : (!I && u === "xy" || I && B === "xy") && this.options.range && (T = O.previousZoom, U(d.newMin) ? O.previousZoom = [this.min, this.max] : T && (d.newMin = T[0], d.newMax = T[1], O.previousZoom = void 0))), typeof d.zoomed < "u" && d.preventDefault();
});
}, S.AdditionsClass = R, S;
}();
}), E(l, "Core/Navigator.js", [
l["Core/Axis/Axis.js"],
l["Core/Chart/Chart.js"],
l["Core/Color/Color.js"],
l["Core/Globals.js"],
l["Core/Axis/NavigatorAxis.js"],
l["Core/DefaultOptions.js"],
l["Core/Renderer/RendererRegistry.js"],
l["Core/Scrollbar.js"],
l["Core/Series/Series.js"],
l["Core/Series/SeriesRegistry.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z, H, U, F, N, R, S, v) {
I = I.parse;
var d = Z.hasTouch, u = Z.isTouchDevice, T = U.defaultOptions, O = v.addEvent, B = v.clamp, C = v.correctFloat, b = v.defined, w = v.destroyObjectProperties, x = v.erase, a = v.extend, c = v.find, p = v.isArray, i = v.isNumber, h = v.merge, o = v.pick, t = v.removeEvent, s = v.splat, n = function(_) {
for (var D = [], W = 1; W < arguments.length; W++)
D[W - 1] = arguments[W];
if (D = [].filter.call(D, i), D.length)
return Math[_].apply(0, D);
};
U = typeof S.seriesTypes.areaspline > "u" ? "line" : "areaspline", a(T, { navigator: { height: 40, margin: 25, maskInside: !0, handles: { width: 7, height: 15, symbols: ["navigator-handle", "navigator-handle"], enabled: !0, lineWidth: 1, backgroundColor: "#f2f2f2", borderColor: "#999999" }, maskFill: I("#6685c2").setOpacity(0.3).get(), outlineColor: "#cccccc", outlineWidth: 1, series: {
type: U,
fillOpacity: 0.05,
lineWidth: 1,
compare: null,
dataGrouping: { approximation: "average", enabled: !0, groupPixelWidth: 2, firstAnchor: "firstPoint", anchor: "middle", lastAnchor: "lastPoint", units: [["millisecond", [1, 2, 5, 10, 20, 25, 50, 100, 200, 500]], ["second", [1, 2, 5, 10, 15, 30]], ["minute", [1, 2, 5, 10, 15, 30]], ["hour", [1, 2, 3, 4, 6, 8, 12]], ["day", [1, 2, 3, 4]], ["week", [1, 2, 3]], ["month", [1, 3, 6]], ["year", null]] },
dataLabels: { enabled: !1, zIndex: 2 },
id: "highcharts-navigator-series",
className: "highcharts-navigator-series",
lineColor: null,
marker: { enabled: !1 },
threshold: null
}, xAxis: { overscroll: 0, className: "highcharts-navigator-xaxis", tickLength: 0, lineWidth: 0, gridLineColor: "#e6e6e6", gridLineWidth: 1, tickPixelInterval: 200, labels: { align: "left", style: { color: "#999999" }, x: 3, y: -4 }, crosshair: !1 }, yAxis: { className: "highcharts-navigator-yaxis", gridLineWidth: 0, startOnTick: !1, endOnTick: !1, minPadding: 0.1, maxPadding: 0.1, labels: { enabled: !1 }, crosshair: !1, title: { text: null }, tickLength: 0, tickWidth: 0 } } }), F.getRendererType().prototype.symbols["navigator-handle"] = function(_, D, W, P, X) {
return _ = (X && X.width || 0) / 2, D = Math.round(_ / 3) + 0.5, X = X && X.height || 0, [["M", -_ - 1, 0.5], ["L", _, 0.5], ["L", _, X + 0.5], ["L", -_ - 1, X + 0.5], ["L", -_ - 1, 0.5], ["M", -D, 4], ["L", -D, X - 3], ["M", D - 1, 4], ["L", D - 1, X - 3]];
};
var A = function() {
function _(D) {
this.zoomedMin = this.zoomedMax = this.yAxis = this.xAxis = this.top = this.size = this.shades = this.rendered = this.range = this.outlineHeight = this.outline = this.opposite = this.navigatorSize = this.navigatorSeries = this.navigatorOptions = this.navigatorGroup = this.navigatorEnabled = this.left = this.height = this.handles = this.chart = this.baseSeries = void 0, this.init(D);
}
return _.prototype.drawHandle = function(D, W, P, X) {
var g = this.navigatorOptions.handles.height;
this.handles[W][X](P ? { translateX: Math.round(this.left + this.height / 2), translateY: Math.round(this.top + parseInt(D, 10) + 0.5 - g) } : { translateX: Math.round(this.left + parseInt(D, 10)), translateY: Math.round(this.top + this.height / 2 - g / 2 - 1) });
}, _.prototype.drawOutline = function(D, W, P, X) {
var g = this.navigatorOptions.maskInside, m = this.outline.strokeWidth(), L = m / 2, Y = m % 2 / 2;
m = this.outlineHeight;
var V = this.scrollbarHeight || 0, Q = this.size, k = this.left - V, G = this.top;
P ? (k -= L, P = G + W + Y, W = G + D + Y, Y = [["M", k + m, G - V - Y], ["L", k + m, P], ["L", k, P], ["L", k, W], ["L", k + m, W], ["L", k + m, G + Q + V]], g && Y.push(["M", k + m, P - L], ["L", k + m, W + L])) : (D += k + V - Y, W += k + V - Y, G += L, Y = [["M", k, G], ["L", D, G], ["L", D, G + m], ["L", W, G + m], ["L", W, G], ["L", k + Q + 2 * V, G]], g && Y.push(["M", D - L, G], ["L", W + L, G])), this.outline[X]({ d: Y });
}, _.prototype.drawMasks = function(D, W, P, X) {
var g = this.left, m = this.top, L = this.height;
if (P)
var Y = [g, g, g], V = [m, m + D, m + W], Q = [L, L, L], k = [D, W - D, this.size - W];
else
Y = [g, g + D, g + W], V = [m, m, m], Q = [D, W - D, this.size - W], k = [L, L, L];
this.shades.forEach(function(G, z) {
G[X]({ x: Y[z], y: V[z], width: Q[z], height: k[z] });
});
}, _.prototype.renderElements = function() {
var D = this, W = D.navigatorOptions, P = W.maskInside, X = D.chart, g = X.renderer, m, L = { cursor: X.inverted ? "ns-resize" : "ew-resize" };
D.navigatorGroup = m = g.g("navigator").attr({ zIndex: 8, visibility: "hidden" }).add(), [!P, P, !P].forEach(function(Y, V) {
D.shades[V] = g.rect().addClass("highcharts-navigator-mask" + (V === 1 ? "-inside" : "-outside")).add(m), X.styledMode || D.shades[V].attr({ fill: Y ? W.maskFill : "rgba(0,0,0,0)" }).css(V === 1 && L);
}), D.outline = g.path().addClass("highcharts-navigator-outline").add(m), X.styledMode || D.outline.attr({ "stroke-width": W.outlineWidth, stroke: W.outlineColor }), W.handles.enabled && [0, 1].forEach(function(Y) {
if (W.handles.inverted = X.inverted, D.handles[Y] = g.symbol(W.handles.symbols[Y], -W.handles.width / 2 - 1, 0, W.handles.width, W.handles.height, W.handles), D.handles[Y].attr({ zIndex: 7 - Y }).addClass("highcharts-navigator-handle highcharts-navigator-handle-" + ["left", "right"][Y]).add(m), !X.styledMode) {
var V = W.handles;
D.handles[Y].attr({ fill: V.backgroundColor, stroke: V.borderColor, "stroke-width": V.lineWidth }).css(L);
}
});
}, _.prototype.update = function(D) {
(this.series || []).forEach(function(W) {
W.baseSeries && delete W.baseSeries.navigatorSeries;
}), this.destroy(), h(!0, this.chart.options.navigator, this.options, D), this.init(this.chart);
}, _.prototype.render = function(D, W, P, X) {
var g = this.chart, m = this.scrollbarHeight, L, Y = this.xAxis, V = Y.pointRange || 0, Q = Y.navigatorAxis.fake ? g.xAxis[0] : Y, k = this.navigatorEnabled, G, z = this.rendered, $ = g.inverted, q = g.xAxis[0].minRange, it = g.xAxis[0].options.maxRange;
if (!this.hasDragged || b(P)) {
if (D = C(D - V / 2), W = C(W + V / 2), !i(D) || !i(W))
if (z)
P = 0, X = o(Y.width, Q.width);
else
return;
this.left = o(Y.left, g.plotLeft + m + ($ ? g.plotWidth : 0)), this.size = G = L = o(Y.len, ($ ? g.plotHeight : g.plotWidth) - 2 * m), g = $ ? m : L + 2 * m, P = o(P, Y.toPixels(D, !0)), X = o(X, Y.toPixels(W, !0)), i(P) && Math.abs(P) !== 1 / 0 || (P = 0, X = g), D = Y.toValue(P, !0), W = Y.toValue(X, !0);
var et = Math.abs(C(W - D));
et < q ? this.grabbedLeft ? P = Y.toPixels(W - q - V, !0) : this.grabbedRight && (X = Y.toPixels(D + q + V, !0)) : b(it) && C(et - V) > it && (this.grabbedLeft ? P = Y.toPixels(W - it - V, !0) : this.grabbedRight && (X = Y.toPixels(D + it + V, !0))), this.zoomedMax = B(Math.max(P, X), 0, G), this.zoomedMin = B(this.fixedWidth ? this.zoomedMax - this.fixedWidth : Math.min(P, X), 0, G), this.range = this.zoomedMax - this.zoomedMin, G = Math.round(this.zoomedMax), P = Math.round(this.zoomedMin), k && (this.navigatorGroup.attr({ visibility: "visible" }), z = z && !this.hasDragged ? "animate" : "attr", this.drawMasks(P, G, $, z), this.drawOutline(P, G, $, z), this.navigatorOptions.handles.enabled && (this.drawHandle(P, 0, $, z), this.drawHandle(G, 1, $, z))), this.scrollbar && ($ ? ($ = this.top - m, Q = this.left - m + (k || !Q.opposite ? 0 : (Q.titleOffset || 0) + Q.axisTitleMargin), m = L + 2 * m) : ($ = this.top + (k ? this.height : -m), Q = this.left - m), this.scrollbar.position(Q, $, g, m), this.scrollbar.setRange(this.zoomedMin / (L || 1), this.zoomedMax / (L || 1))), this.rendered = !0;
}
}, _.prototype.addMouseEvents = function() {
var D = this, W = D.chart, P = W.container, X = [], g, m;
D.mouseMoveHandler = g = function(L) {
D.onMouseMove(L);
}, D.mouseUpHandler = m = function(L) {
D.onMouseUp(L);
}, X = D.getPartsEvents("mousedown"), X.push(O(W.renderTo, "mousemove", g), O(P.ownerDocument, "mouseup", m)), d && (X.push(O(W.renderTo, "touchmove", g), O(P.ownerDocument, "touchend", m)), X.concat(D.getPartsEvents("touchstart"))), D.eventsToUnbind = X, D.series && D.series[0] && X.push(O(D.series[0].xAxis, "foundExtremes", function() {
W.navigator.modifyNavigatorAxisExtremes();
}));
}, _.prototype.getPartsEvents = function(D) {
var W = this, P = [];
return ["shades", "handles"].forEach(function(X) {
W[X].forEach(function(g, m) {
P.push(O(g.element, D, function(L) {
W[X + "Mousedown"](L, m);
}));
});
}), P;
}, _.prototype.shadesMousedown = function(D, W) {
D = this.chart.pointer.normalize(D);
var P = this.chart, X = this.xAxis, g = this.zoomedMin, m = this.left, L = this.size, Y = this.range, V = D.chartX;
if (P.inverted && (V = D.chartY, m = this.top), W === 1)
this.grabbedCenter = V, this.fixedWidth = Y, this.dragOffset = V - g;
else {
if (D = V - m - Y / 2, W === 0)
D = Math.max(0, D);
else if (W === 2 && D + Y >= L)
if (D = L - Y, this.reversedExtremes) {
D -= Y;
var Q = this.getUnionExtremes().dataMin;
} else
var k = this.getUnionExtremes().dataMax;
D !== g && (this.fixedWidth = Y, W = X.navigatorAxis.toFixedRange(D, D + Y, Q, k), b(W.min) && P.xAxis[0].setExtremes(Math.min(W.min, W.max), Math.max(W.min, W.max), !0, null, { trigger: "navigator" }));
}
}, _.prototype.handlesMousedown = function(D, W) {
this.chart.pointer.normalize(D), D = this.chart;
var P = D.xAxis[0], X = this.reversedExtremes;
W === 0 ? (this.grabbedLeft = !0, this.otherHandlePos = this.zoomedMax, this.fixedExtreme = X ? P.min : P.max) : (this.grabbedRight = !0, this.otherHandlePos = this.zoomedMin, this.fixedExtreme = X ? P.max : P.min), D.fixedRange = null;
}, _.prototype.onMouseMove = function(D) {
var W = this, P = W.chart, X = W.left, g = W.navigatorSize, m = W.range, L = W.dragOffset, Y = P.inverted;
D.touches && D.touches[0].pageX === 0 || (D = P.pointer.normalize(D), P = D.chartX, Y && (X = W.top, P = D.chartY), W.grabbedLeft ? (W.hasDragged = !0, W.render(0, 0, P - X, W.otherHandlePos)) : W.grabbedRight ? (W.hasDragged = !0, W.render(0, 0, W.otherHandlePos, P - X)) : W.grabbedCenter && (W.hasDragged = !0, P < L ? P = L : P > g + L - m && (P = g + L - m), W.render(0, 0, P - L, P - L + m)), W.hasDragged && W.scrollbar && o(W.scrollbar.options.liveRedraw, Z.svg && !u && !this.chart.isBoosting) && (D.DOMType = D.type, setTimeout(function() {
W.onMouseUp(D);
}, 0)));
}, _.prototype.onMouseUp = function(D) {
var W = this.chart, P = this.xAxis, X = this.scrollbar, g = D.DOMEvent || D, m = W.inverted, L = this.rendered && !this.hasDragged ? "animate" : "attr";
if (this.hasDragged && (!X || !X.hasDragged) || D.trigger === "scrollbar") {
if (X = this.getUnionExtremes(), this.zoomedMin === this.otherHandlePos)
var Y = this.fixedExtreme;
else if (this.zoomedMax === this.otherHandlePos)
var V = this.fixedExtreme;
this.zoomedMax === this.size && (V = this.reversedExtremes ? X.dataMin : X.dataMax), this.zoomedMin === 0 && (Y = this.reversedExtremes ? X.dataMax : X.dataMin), P = P.navigatorAxis.toFixedRange(this.zoomedMin, this.zoomedMax, Y, V), b(P.min) && W.xAxis[0].setExtremes(Math.min(P.min, P.max), Math.max(P.min, P.max), !0, this.hasDragged ? !1 : null, { trigger: "navigator", triggerOp: "navigator-drag", DOMEvent: g });
}
D.DOMType !== "mousemove" && D.DOMType !== "touchmove" && (this.grabbedLeft = this.grabbedRight = this.grabbedCenter = this.fixedWidth = this.fixedExtreme = this.otherHandlePos = this.hasDragged = this.dragOffset = null), this.navigatorEnabled && i(this.zoomedMin) && i(this.zoomedMax) && (W = Math.round(this.zoomedMin), D = Math.round(this.zoomedMax), this.shades && this.drawMasks(W, D, m, L), this.outline && this.drawOutline(W, D, m, L), this.navigatorOptions.handles.enabled && Object.keys(this.handles).length === this.handles.length && (this.drawHandle(W, 0, m, L), this.drawHandle(D, 1, m, L)));
}, _.prototype.removeEvents = function() {
this.eventsToUnbind && (this.eventsToUnbind.forEach(function(D) {
D();
}), this.eventsToUnbind = void 0), this.removeBaseSeriesEvents();
}, _.prototype.removeBaseSeriesEvents = function() {
var D = this.baseSeries || [];
this.navigatorEnabled && D[0] && (this.navigatorOptions.adaptToUpdatedData !== !1 && D.forEach(function(W) {
t(W, "updatedData", this.updatedDataHandler);
}, this), D[0].xAxis && t(D[0].xAxis, "foundExtremes", this.modifyBaseAxisExtremes));
}, _.prototype.init = function(D) {
var W = D.options, P = W.navigator, X = P.enabled, g = W.scrollbar, m = g.enabled;
W = X ? P.height : 0;
var L = m ? g.height : 0;
this.handles = [], this.shades = [], this.chart = D, this.setBaseSeries(), this.height = W, this.scrollbarHeight = L, this.scrollbarEnabled = m, this.navigatorEnabled = X, this.navigatorOptions = P, this.scrollbarOptions = g, this.outlineHeight = W + L, this.opposite = o(P.opposite, !(X || !D.inverted));
var Y = this;
X = Y.baseSeries, g = D.xAxis.length, m = D.yAxis.length;
var V = X && X[0] && X[0].xAxis || D.xAxis[0] || { options: {} };
D.isDirtyBox = !0, Y.navigatorEnabled ? (Y.xAxis = new y(D, h(
{ breaks: V.options.breaks, ordinal: V.options.ordinal },
P.xAxis,
{ id: "navigator-x-axis", yAxis: "navigator-y-axis", isX: !0, type: "datetime", index: g, isInternal: !0, offset: 0, keepOrdinalPadding: !0, startOnTick: !1, endOnTick: !1, minPadding: 0, maxPadding: 0, zoomEnabled: !1 },
D.inverted ? { offsets: [L, 0, -L, 0], width: W } : { offsets: [0, -L, 0, L], height: W }
)), Y.yAxis = new y(D, h(P.yAxis, { id: "navigator-y-axis", alignTicks: !1, offset: 0, index: m, isInternal: !0, reversed: o(P.yAxis && P.yAxis.reversed, D.yAxis[0] && D.yAxis[0].reversed, !1), zoomEnabled: !1 }, D.inverted ? { width: W } : { height: W })), X || P.series.data ? Y.updateNavigatorSeries(!1) : D.series.length === 0 && (Y.unbindRedraw = O(D, "beforeRedraw", function() {
0 < D.series.length && !Y.series && (Y.setBaseSeries(), Y.unbindRedraw());
})), Y.reversedExtremes = D.inverted && !Y.xAxis.reversed || !D.inverted && Y.xAxis.reversed, Y.renderElements(), Y.addMouseEvents()) : (Y.xAxis = {
chart: D,
navigatorAxis: { fake: !0 },
translate: function(Q, k) {
var G = D.xAxis[0], z = G.getExtremes(), $ = G.len - 2 * L, q = n("min", G.options.min, z.dataMin);
return G = n("max", G.options.max, z.dataMax) - q, k ? Q * G / $ + q : $ * (Q - q) / G;
},
toPixels: function(Q) {
return this.translate(Q);
},
toValue: function(Q) {
return this.translate(Q, !0);
}
}, Y.xAxis.navigatorAxis.axis = Y.xAxis, Y.xAxis.navigatorAxis.toFixedRange = H.AdditionsClass.prototype.toFixedRange.bind(Y.xAxis.navigatorAxis)), D.options.scrollbar.enabled && (D.scrollbar = Y.scrollbar = new N(D.renderer, h(D.options.scrollbar, { margin: Y.navigatorEnabled ? 0 : 10, vertical: D.inverted }), D), O(Y.scrollbar, "changed", function(Q) {
var k = Y.size, G = k * this.to;
k *= this.from, Y.hasDragged = Y.scrollbar.hasDragged, Y.render(0, 0, k, G), this.shouldUpdateExtremes(Q.DOMType) && setTimeout(function() {
Y.onMouseUp(Q);
});
})), Y.addBaseSeriesEvents(), Y.addChartEvents();
}, _.prototype.getUnionExtremes = function(D) {
var W = this.chart.xAxis[0], P = this.xAxis, X = P.options, g = W.options, m;
return D && W.dataMin === null || (m = { dataMin: o(X && X.min, n("min", g.min, W.dataMin, P.dataMin, P.min)), dataMax: o(X && X.max, n("max", g.max, W.dataMax, P.dataMax, P.max)) }), m;
}, _.prototype.setBaseSeries = function(D, W) {
var P = this.chart, X = this.baseSeries = [];
D = D || P.options && P.options.navigator.baseSeries || (P.series.length ? c(
P.series,
function(g) {
return !g.options.isInternal;
}
).index : 0), (P.series || []).forEach(function(g, m) {
g.options.isInternal || !g.options.showInNavigator && (m !== D && g.options.id !== D || g.options.showInNavigator === !1) || X.push(g);
}), this.xAxis && !this.xAxis.navigatorAxis.fake && this.updateNavigatorSeries(!0, W);
}, _.prototype.updateNavigatorSeries = function(D, W) {
var P = this, X = P.chart, g = P.baseSeries, m, L, Y = P.navigatorOptions.series, V, Q = {
enableMouseTracking: !1,
index: null,
linkedTo: null,
group: "nav",
padXAxis: !1,
xAxis: "navigator-x-axis",
yAxis: "navigator-y-axis",
showInLegend: !1,
stacking: void 0,
isInternal: !0,
states: { inactive: { opacity: 1 } }
}, k = P.series = (P.series || []).filter(function(G) {
var z = G.baseSeries;
return 0 > g.indexOf(z) ? (z && (t(z, "updatedData", P.updatedDataHandler), delete z.navigatorSeries), G.chart && G.destroy(), !1) : !0;
});
g && g.length && g.forEach(function(G) {
var z = G.navigatorSeries, $ = a({ color: G.color, visible: G.visible }, p(Y) ? T.navigator.series : Y);
z && P.navigatorOptions.adaptToUpdatedData === !1 || (Q.name = "Navigator " + g.length, m = G.options || {}, V = m.navigatorOptions || {}, $.dataLabels = s($.dataLabels), L = h(m, Q, $, V), L.pointRange = o($.pointRange, V.pointRange, T.plotOptions[L.type || "line"].pointRange), $ = V.data || $.data, P.hasNavigatorData = P.hasNavigatorData || !!$, L.data = $ || m.data && m.data.slice(0), z && z.options ? z.update(L, W) : (G.navigatorSeries = X.initSeries(L), G.navigatorSeries.baseSeries = G, k.push(G.navigatorSeries)));
}), (Y.data && (!g || !g.length) || p(Y)) && (P.hasNavigatorData = !1, Y = s(Y), Y.forEach(function(G, z) {
Q.name = "Navigator " + (k.length + 1), L = h(
T.navigator.series,
{ color: X.series[z] && !X.series[z].options.isInternal && X.series[z].color || X.options.colors[z] || X.options.colors[0] },
Q,
G
), L.data = G.data, L.data && (P.hasNavigatorData = !0, k.push(X.initSeries(L)));
})), D && this.addBaseSeriesEvents();
}, _.prototype.addBaseSeriesEvents = function() {
var D = this, W = D.baseSeries || [];
W[0] && W[0].xAxis && W[0].eventsToUnbind.push(O(W[0].xAxis, "foundExtremes", this.modifyBaseAxisExtremes)), W.forEach(function(P) {
P.eventsToUnbind.push(O(P, "show", function() {
this.navigatorSeries && this.navigatorSeries.setVisible(
!0,
!1
);
})), P.eventsToUnbind.push(O(P, "hide", function() {
this.navigatorSeries && this.navigatorSeries.setVisible(!1, !1);
})), this.navigatorOptions.adaptToUpdatedData !== !1 && P.xAxis && P.eventsToUnbind.push(O(P, "updatedData", this.updatedDataHandler)), P.eventsToUnbind.push(O(P, "remove", function() {
this.navigatorSeries && (x(D.series, this.navigatorSeries), b(this.navigatorSeries.options) && this.navigatorSeries.remove(!1), delete this.navigatorSeries);
}));
}, this);
}, _.prototype.getBaseSeriesMin = function(D) {
return this.baseSeries.reduce(function(W, P) {
return Math.min(W, P.xData ? P.xData[0] : W);
}, D);
}, _.prototype.modifyNavigatorAxisExtremes = function() {
var D = this.xAxis, W;
typeof D.getExtremes < "u" && (!(W = this.getUnionExtremes(!0)) || W.dataMin === D.min && W.dataMax === D.max || (D.min = W.dataMin, D.max = W.dataMax));
}, _.prototype.modifyBaseAxisExtremes = function() {
var D = this.chart.navigator, W = this.getExtremes(), P = W.dataMin, X = W.dataMax;
W = W.max - W.min;
var g = D.stickToMin, m = D.stickToMax, L = o(this.options.overscroll, 0), Y = D.series && D.series[0], V = !!this.setExtremes;
if (!this.eventArgs || this.eventArgs.trigger !== "rangeSelectorButton") {
if (g)
var Q = P, k = Q + W;
m && (k = X + L, g || (Q = Math.max(P, k - W, D.getBaseSeriesMin(Y && Y.xData ? Y.xData[0] : -Number.MAX_VALUE)))), V && (g || m) && i(Q) && (this.min = this.userMin = Q, this.max = this.userMax = k);
}
D.stickToMin = D.stickToMax = null;
}, _.prototype.updatedDataHandler = function() {
var D = this.chart.navigator, W = this.navigatorSeries;
D.stickToMax = D.reversedExtremes ? Math.round(D.zoomedMin) === 0 : Math.round(D.zoomedMax) >= Math.round(D.size), D.stickToMin = D.shouldStickToMin(
this,
D
), W && !D.hasNavigatorData && (W.options.pointStart = this.xData[0], W.setData(this.options.data, !1, null, !1));
}, _.prototype.shouldStickToMin = function(D, W) {
W = W.getBaseSeriesMin(D.xData[0]);
var P = D.xAxis;
D = P.max;
var X = P.min;
return P = P.options.range, i(D) && i(X) ? P && 0 < D - W ? D - W < P : X <= W : !1;
}, _.prototype.addChartEvents = function() {
this.eventsToUnbind || (this.eventsToUnbind = []), this.eventsToUnbind.push(O(this.chart, "redraw", function() {
var D = this.navigator, W = D && (D.baseSeries && D.baseSeries[0] && D.baseSeries[0].xAxis || this.xAxis[0]);
W && D.render(W.min, W.max);
}), O(this.chart, "getMargins", function() {
var D = this.navigator, W = D.opposite ? "plotTop" : "marginBottom";
this.inverted && (W = D.opposite ? "marginRight" : "plotLeft"), this[W] = (this[W] || 0) + (D.navigatorEnabled || !this.inverted ? D.outlineHeight : 0) + D.navigatorOptions.margin;
}));
}, _.prototype.destroy = function() {
this.removeEvents(), this.xAxis && (x(this.chart.xAxis, this.xAxis), x(this.chart.axes, this.xAxis)), this.yAxis && (x(this.chart.yAxis, this.yAxis), x(this.chart.axes, this.yAxis)), (this.series || []).forEach(function(D) {
D.destroy && D.destroy();
}), "series xAxis yAxis shades outline scrollbarTrack scrollbarRifles scrollbarGroup scrollbar navigatorGroup rendered".split(" ").forEach(function(D) {
this[D] && this[D].destroy && this[D].destroy(), this[D] = null;
}, this), [this.handles].forEach(function(D) {
w(D);
}, this);
}, _;
}();
return Z.Navigator || (Z.Navigator = A, H.compose(y), O(j, "beforeShowResetZoom", function() {
var _ = this.options, D = _.navigator, W = _.rangeSelector;
if ((D && D.enabled || W && W.enabled) && (!u && _.chart.zoomType === "x" || u && _.chart.pinchType === "x"))
return !1;
}), O(j, "beforeRender", function() {
var _ = this.options;
(_.navigator.enabled || _.scrollbar.enabled) && (this.scroller = this.navigator = new A(this));
}), O(j, "afterSetChartSize", function() {
var _ = this.legend, D = this.navigator;
if (D) {
var W = _ && _.options, P = D.xAxis, X = D.yAxis, g = D.scrollbarHeight;
this.inverted ? (D.left = D.opposite ? this.chartWidth - g - D.height : this.spacing[3] + g, D.top = this.plotTop + g) : (D.left = o(P.left, this.plotLeft + g), D.top = D.navigatorOptions.top || this.chartHeight - D.height - g - this.spacing[2] - (this.rangeSelector && this.extraBottomMargin ? this.rangeSelector.getHeight() : 0) - (W && W.verticalAlign === "bottom" && W.layout !== "proximate" && W.enabled && !W.floating ? _.legendHeight + o(W.margin, 10) : 0) - (this.titleOffset ? this.titleOffset[2] : 0)), P && X && (this.inverted ? P.options.left = X.options.left = D.left : P.options.top = X.options.top = D.top, P.setAxisSize(), X.setAxisSize());
}
}), O(j, "update", function(_) {
var D = _.options.navigator || {}, W = _.options.scrollbar || {};
this.navigator || this.scroller || !D.enabled && !W.enabled || (h(
!0,
this.options.navigator,
D
), h(!0, this.options.scrollbar, W), delete _.options.navigator, delete _.options.scrollbar);
}), O(j, "afterUpdate", function(_) {
this.navigator || this.scroller || !this.options.navigator.enabled && !this.options.scrollbar.enabled || (this.scroller = this.navigator = new A(this), o(_.redraw, !0) && this.redraw(_.animation));
}), O(j, "afterAddSeries", function() {
this.navigator && this.navigator.setBaseSeries(null, !1);
}), O(R, "afterUpdate", function() {
this.chart.navigator && !this.options.isInternal && this.chart.navigator.setBaseSeries(
null,
!1
);
}), j.prototype.callbacks.push(function(_) {
var D = _.navigator;
D && _.xAxis[0] && (_ = _.xAxis[0].getExtremes(), D.render(_.min, _.max));
})), Z.Navigator = A, Z.Navigator;
}), E(l, "Extensions/RangeSelector.js", [l["Core/Axis/Axis.js"], l["Core/Chart/Chart.js"], l["Core/Globals.js"], l["Core/DefaultOptions.js"], l["Core/Renderer/SVG/SVGElement.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H, U) {
function F(s) {
if (s.indexOf("%L") !== -1)
return "text";
var n = "aAdewbBmoyY".split("").some(function(_) {
return s.indexOf("%" + _) !== -1;
}), A = "HkIlMS".split("").some(function(_) {
return s.indexOf("%" + _) !== -1;
});
return n && A ? "datetime-local" : n ? "date" : A ? "time" : "text";
}
var N = Z.defaultOptions, R = U.addEvent, S = U.createElement, v = U.css, d = U.defined, u = U.destroyObjectProperties, T = U.discardElement, O = U.extend, B = U.find, C = U.fireEvent, b = U.isNumber, w = U.merge, x = U.objectEach, a = U.pad, c = U.pick, p = U.pInt, i = U.splat;
O(N, { rangeSelector: { allButtonsEnabled: !1, buttons: void 0, buttonSpacing: 5, dropdown: "responsive", enabled: void 0, verticalAlign: "top", buttonTheme: {
width: 28,
height: 18,
padding: 2,
zIndex: 7
}, floating: !1, x: 0, y: 0, height: void 0, inputBoxBorderColor: "none", inputBoxHeight: 17, inputBoxWidth: void 0, inputDateFormat: "%b %e, %Y", inputDateParser: void 0, inputEditDateFormat: "%Y-%m-%d", inputEnabled: !0, inputPosition: { align: "right", x: 0, y: 0 }, inputSpacing: 5, selected: void 0, buttonPosition: { align: "left", x: 0, y: 0 }, inputStyle: { color: "#335cad", cursor: "pointer" }, labelStyle: { color: "#666666" } } }), O(N.lang, { rangeSelectorZoom: "Zoom", rangeSelectorFrom: "", rangeSelectorTo: "→" });
var h = function() {
function s(n) {
this.buttons = void 0, this.buttonOptions = s.prototype.defaultButtons, this.initialButtonGroupWidth = 0, this.options = void 0, this.chart = n, this.init(n);
}
return s.prototype.clickButton = function(n, A) {
var _ = this.chart, D = this.buttonOptions[n], W = _.xAxis[0], P = _.scroller && _.scroller.getUnionExtremes() || W || {}, X = P.dataMin, g = P.dataMax, m = W && Math.round(Math.min(W.max, c(g, W.max))), L = D.type;
P = D._range;
var Y, V = D.dataGrouping;
if (X !== null && g !== null) {
if (_.fixedRange = P, this.setSelected(n), V && (this.forcedDataGrouping = !0, y.prototype.setDataGrouping.call(W || { chart: this.chart }, V, !1), this.frozenStates = D.preserveDataGrouping), L === "month" || L === "year")
if (W) {
L = { range: D, max: m, chart: _, dataMin: X, dataMax: g };
var Q = W.minFromRange.call(L);
b(L.newMax) && (m = L.newMax);
} else
P = D;
else if (P)
Q = Math.max(m - P, X), m = Math.min(Q + P, g);
else if (L === "ytd")
if (W)
typeof g > "u" && (X = Number.MAX_VALUE, g = Number.MIN_VALUE, _.series.forEach(function($) {
$ = $.xData, X = Math.min($[0], X), g = Math.max($[$.length - 1], g);
}), A = !1), m = this.getYTDExtremes(
g,
X,
_.time.useUTC
), Q = Y = m.min, m = m.max;
else {
this.deferredYTDClick = n;
return;
}
else
L === "all" && W && (_.navigator && _.navigator.baseSeries[0] && (_.navigator.baseSeries[0].xAxis.options.range = void 0), Q = X, m = g);
if (d(Q) && (Q += D._offsetMin), d(m) && (m += D._offsetMax), this.dropdown && (this.dropdown.selectedIndex = n + 1), W)
W.setExtremes(Q, m, c(A, !0), void 0, { trigger: "rangeSelectorButton", rangeSelectorButton: D });
else {
var k = i(_.options.xAxis)[0], G = k.range;
k.range = P;
var z = k.min;
k.min = Y, R(_, "load", function() {
k.range = G, k.min = z;
});
}
C(
this,
"afterBtnClick"
);
}
}, s.prototype.setSelected = function(n) {
this.selected = this.options.selected = n;
}, s.prototype.init = function(n) {
var A = this, _ = n.options.rangeSelector, D = _.buttons || A.defaultButtons.slice(), W = _.selected, P = function() {
var X = A.minInput, g = A.maxInput;
X && X.blur && C(X, "blur"), g && g.blur && C(g, "blur");
};
A.chart = n, A.options = _, A.buttons = [], A.buttonOptions = D, this.eventsToUnbind = [], this.eventsToUnbind.push(R(n.container, "mousedown", P)), this.eventsToUnbind.push(R(n, "resize", P)), D.forEach(A.computeButtonRange), typeof W < "u" && D[W] && this.clickButton(W, !1), this.eventsToUnbind.push(R(n, "load", function() {
n.xAxis && n.xAxis[0] && R(n.xAxis[0], "setExtremes", function(X) {
this.max - this.min !== n.fixedRange && X.trigger !== "rangeSelectorButton" && X.trigger !== "updatedData" && A.forcedDataGrouping && !A.frozenStates && this.setDataGrouping(!1, !1);
});
}));
}, s.prototype.updateButtonStates = function() {
var n = this, A = this.chart, _ = this.dropdown, D = A.xAxis[0], W = Math.round(D.max - D.min), P = !D.hasVisibleSeries, X = A.scroller && A.scroller.getUnionExtremes() || D, g = X.dataMin, m = X.dataMax;
A = n.getYTDExtremes(m, g, A.time.useUTC);
var L = A.min, Y = A.max, V = n.selected, Q = b(V), k = n.options.allButtonsEnabled, G = n.buttons;
n.buttonOptions.forEach(function(z, $) {
var q = z._range, it = z.type, et = z.count || 1, nt = G[$], rt = 0, ct = z._offsetMax - z._offsetMin;
z = $ === V;
var gt = q > m - g, dt = q < D.minRange, ht = !1, at = !1;
q = q === W, (it === "month" || it === "year") && W + 36e5 >= 864e5 * { month: 28, year: 365 }[it] * et - ct && W - 36e5 <= 864e5 * { month: 31, year: 366 }[it] * et + ct ? q = !0 : it === "ytd" ? (q = Y - L + ct === W, ht = !z) : it === "all" && (q = D.max - D.min >= m - g, at = !z && Q && q), it = !k && (gt || dt || at || P), et = z && q || q && !Q && !ht || z && n.frozenStates, it ? rt = 3 : et && (Q = !0, rt = 2), nt.state !== rt && (nt.setState(rt), _ && (_.options[$ + 1].disabled = it, rt === 2 && (_.selectedIndex = $ + 1)), rt === 0 && V === $ && n.setSelected());
});
}, s.prototype.computeButtonRange = function(n) {
var A = n.type, _ = n.count || 1, D = { millisecond: 1, second: 1e3, minute: 6e4, hour: 36e5, day: 864e5, week: 6048e5 };
D[A] ? n._range = D[A] * _ : (A === "month" || A === "year") && (n._range = 864e5 * { month: 30, year: 365 }[A] * _), n._offsetMin = c(n.offsetMin, 0), n._offsetMax = c(n.offsetMax, 0), n._range += n._offsetMax - n._offsetMin;
}, s.prototype.getInputValue = function(n) {
n = n === "min" ? this.minInput : this.maxInput;
var A = this.chart.options.rangeSelector, _ = this.chart.time;
return n ? (n.type === "text" && A.inputDateParser || this.defaultInputDateParser)(n.value, _.useUTC, _) : 0;
}, s.prototype.setInputValue = function(n, A) {
var _ = this.options, D = this.chart.time, W = n === "min" ? this.minInput : this.maxInput;
if (n = n === "min" ? this.minDateBox : this.maxDateBox, W) {
var P = W.getAttribute("data-hc-time");
P = d(P) ? Number(P) : void 0, d(A) && (d(P) && W.setAttribute("data-hc-time-previous", P), W.setAttribute("data-hc-time", A), P = A), W.value = D.dateFormat(this.inputTypeFormats[W.type] || _.inputEditDateFormat, P), n && n.attr({ text: D.dateFormat(_.inputDateFormat, P) });
}
}, s.prototype.setInputExtremes = function(n, A, _) {
if (n = n === "min" ? this.minInput : this.maxInput) {
var D = this.inputTypeFormats[n.type], W = this.chart.time;
D && (A = W.dateFormat(D, A), n.min !== A && (n.min = A), _ = W.dateFormat(D, _), n.max !== _ && (n.max = _));
}
}, s.prototype.showInput = function(n) {
var A = n === "min" ? this.minDateBox : this.maxDateBox;
if ((n = n === "min" ? this.minInput : this.maxInput) && A && this.inputGroup) {
var _ = n.type === "text", D = this.inputGroup, W = D.translateX;
D = D.translateY;
var P = this.options.inputBoxWidth;
v(n, { width: _ ? A.width + (P ? -2 : 20) + "px" : "auto", height: _ ? A.height - 2 + "px" : "auto", border: "2px solid silver" }), _ && P ? v(n, { left: W + A.x + "px", top: D + "px" }) : v(n, { left: Math.min(Math.round(A.x + W - (n.offsetWidth - A.width) / 2), this.chart.chartWidth - n.offsetWidth) + "px", top: D - (n.offsetHeight - A.height) / 2 + "px" });
}
}, s.prototype.hideInput = function(n) {
(n = n === "min" ? this.minInput : this.maxInput) && v(n, { top: "-9999em", border: 0, width: "1px", height: "1px" });
}, s.prototype.defaultInputDateParser = function(n, A, _) {
var D = n.split("/").join("-").split(" ").join("T");
if (D.indexOf("T") === -1 && (D += "T00:00"), A)
D += "Z";
else {
var W;
(W = I.isSafari) && (W = D, W = !(6 < W.length && (W.lastIndexOf("-") === W.length - 6 || W.lastIndexOf("+") === W.length - 6))), W && (W = new Date(D).getTimezoneOffset() / 60, D += 0 >= W ? "+" + a(-W) + ":00" : "-" + a(W) + ":00");
}
return D = Date.parse(D), b(D) || (n = n.split("-"), D = Date.UTC(p(n[0]), p(n[1]) - 1, p(n[2]))), _ && A && b(D) && (D += _.getTimezoneOffset(D)), D;
}, s.prototype.drawInput = function(n) {
function A() {
var k = P.getInputValue(n), G = _.xAxis[0], z = _.scroller && _.scroller.xAxis ? _.scroller.xAxis : G, $ = z.dataMin;
z = z.dataMax;
var q = P.maxInput, it = P.minInput;
k !== Number(V.getAttribute("data-hc-time-previous")) && b(k) && (V.setAttribute("data-hc-time-previous", k), L && q && b($) ? k > Number(q.getAttribute("data-hc-time")) ? k = void 0 : k < $ && (k = $) : it && b(z) && (k < Number(it.getAttribute("data-hc-time")) ? k = void 0 : k > z && (k = z)), typeof k < "u" && G.setExtremes(L ? k : G.min, L ? G.max : k, void 0, void 0, { trigger: "rangeSelectorInput" }));
}
var _ = this.chart, D = this.div, W = this.inputGroup, P = this, X = _.renderer.style || {}, g = _.renderer, m = _.options.rangeSelector, L = n === "min", Y = N.lang[L ? "rangeSelectorFrom" : "rangeSelectorTo"] || "";
Y = g.label(Y, 0).addClass("highcharts-range-label").attr({ padding: Y ? 2 : 0, height: Y ? m.inputBoxHeight : 0 }).add(W), g = g.label("", 0).addClass("highcharts-range-input").attr({ padding: 2, width: m.inputBoxWidth, height: m.inputBoxHeight, "text-align": "center" }).on(
"click",
function() {
P.showInput(n), P[n + "Input"].focus();
}
), _.styledMode || g.attr({ stroke: m.inputBoxBorderColor, "stroke-width": 1 }), g.add(W);
var V = S("input", { name: n, className: "highcharts-range-selector" }, void 0, D);
V.setAttribute("type", F(m.inputDateFormat || "%b %e, %Y")), _.styledMode || (Y.css(w(X, m.labelStyle)), g.css(w({ color: "#333333" }, X, m.inputStyle)), v(V, O({
position: "absolute",
border: 0,
boxShadow: "0 0 15px rgba(0,0,0,0.3)",
width: "1px",
height: "1px",
padding: 0,
textAlign: "center",
fontSize: X.fontSize,
fontFamily: X.fontFamily,
top: "-9999em"
}, m.inputStyle))), V.onfocus = function() {
P.showInput(n);
}, V.onblur = function() {
V === I.doc.activeElement && A(), P.hideInput(n), P.setInputValue(n), V.blur();
};
var Q = !1;
return V.onchange = function() {
Q || (A(), P.hideInput(n), V.blur());
}, V.onkeypress = function(k) {
k.keyCode === 13 && A();
}, V.onkeydown = function(k) {
Q = !0, k.keyCode !== 38 && k.keyCode !== 40 || A();
}, V.onkeyup = function() {
Q = !1;
}, { dateBox: g, input: V, label: Y };
}, s.prototype.getPosition = function() {
var n = this.chart, A = n.options.rangeSelector;
return n = A.verticalAlign === "top" ? n.plotTop - n.axisOffset[0] : 0, { buttonTop: n + A.buttonPosition.y, inputTop: n + A.inputPosition.y - 10 };
}, s.prototype.getYTDExtremes = function(n, A, _) {
var D = this.chart.time, W = new D.Date(n), P = D.get("FullYear", W);
return _ = _ ? D.Date.UTC(P, 0, 1) : +new D.Date(P, 0, 1), A = Math.max(A, _), W = W.getTime(), { max: Math.min(n || W, W), min: A };
}, s.prototype.render = function(n, A) {
var _ = this.chart, D = _.renderer, W = _.container, P = _.options, X = P.rangeSelector, g = c(P.chart.style && P.chart.style.zIndex, 0) + 1;
if (P = X.inputEnabled, X.enabled !== !1) {
if (this.rendered || (this.group = D.g("range-selector-group").attr({ zIndex: 7 }).add(), this.div = S("div", void 0, { position: "relative", height: 0, zIndex: g }), this.buttonOptions.length && this.renderButtons(), W.parentNode && W.parentNode.insertBefore(this.div, W), P && (this.inputGroup = D.g("input-group").add(this.group), D = this.drawInput("min"), this.minDateBox = D.dateBox, this.minLabel = D.label, this.minInput = D.input, D = this.drawInput("max"), this.maxDateBox = D.dateBox, this.maxLabel = D.label, this.maxInput = D.input)), P && (this.setInputValue(
"min",
n
), this.setInputValue("max", A), n = _.scroller && _.scroller.getUnionExtremes() || _.xAxis[0] || {}, d(n.dataMin) && d(n.dataMax) && (_ = _.xAxis[0].minRange || 0, this.setInputExtremes("min", n.dataMin, Math.min(n.dataMax, this.getInputValue("max")) - _), this.setInputExtremes("max", Math.max(n.dataMin, this.getInputValue("min")) + _, n.dataMax)), this.inputGroup)) {
var m = 0;
[this.minLabel, this.minDateBox, this.maxLabel, this.maxDateBox].forEach(function(L) {
if (L) {
var Y = L.getBBox().width;
Y && (L.attr({ x: m }), m += Y + X.inputSpacing);
}
});
}
this.alignElements(), this.rendered = !0;
}
}, s.prototype.renderButtons = function() {
var n = this, A = this.buttons, _ = this.options, D = N.lang, W = this.chart.renderer, P = w(_.buttonTheme), X = P && P.states, g = P.width || 28;
delete P.width, delete P.states, this.buttonGroup = W.g("range-selector-buttons").add(this.group);
var m = this.dropdown = S("select", void 0, { position: "absolute", width: "1px", height: "1px", padding: 0, border: 0, top: "-9999em", cursor: "pointer", opacity: 1e-4 }, this.div);
R(m, "touchstart", function() {
m.style.fontSize = "16px";
}), [[I.isMS ? "mouseover" : "mouseenter"], [I.isMS ? "mouseout" : "mouseleave"], ["change", "click"]].forEach(function(L) {
var Y = L[0], V = L[1];
R(m, Y, function() {
var Q = A[n.currentButtonIndex()];
Q && C(Q.element, V || Y);
});
}), this.zoomText = W.label(D && D.rangeSelectorZoom || "", 0).attr({ padding: _.buttonTheme.padding, height: _.buttonTheme.height, paddingLeft: 0, paddingRight: 0 }).add(this.buttonGroup), this.chart.styledMode || (this.zoomText.css(_.labelStyle), P["stroke-width"] = c(P["stroke-width"], 0)), S(
"option",
{ textContent: this.zoomText.textStr, disabled: !0 },
void 0,
m
), this.buttonOptions.forEach(function(L, Y) {
S("option", { textContent: L.title || L.text }, void 0, m), A[Y] = W.button(L.text, 0, 0, function(V) {
var Q = L.events && L.events.click, k;
Q && (k = Q.call(L, V)), k !== !1 && n.clickButton(Y), n.isActive = !0;
}, P, X && X.hover, X && X.select, X && X.disabled).attr({ "text-align": "center", width: g }).add(n.buttonGroup), L.title && A[Y].attr("title", L.title);
});
}, s.prototype.alignElements = function() {
var n = this, A = this.buttonGroup, _ = this.buttons, D = this.chart, W = this.group, P = this.inputGroup, X = this.options, g = this.zoomText, m = D.options, L = m.exporting && m.exporting.enabled !== !1 && m.navigation && m.navigation.buttonOptions;
m = X.buttonPosition;
var Y = X.inputPosition, V = X.verticalAlign, Q = function($, q) {
return L && n.titleCollision(D) && V === "top" && q.align === "right" && q.y - $.getBBox().height - 12 < (L.y || 0) + (L.height || 0) + D.spacing[0] ? -40 : 0;
}, k = D.plotLeft;
if (W && m && Y) {
var G = m.x - D.spacing[3];
if (A) {
if (this.positionButtons(), !this.initialButtonGroupWidth) {
var z = 0;
g && (z += g.getBBox().width + 5), _.forEach(function($, q) {
z += $.width, q !== _.length - 1 && (z += X.buttonSpacing);
}), this.initialButtonGroupWidth = z;
}
k -= D.spacing[3], this.updateButtonStates(), g = Q(A, m), this.alignButtonGroup(g), W.placed = A.placed = D.hasLoaded;
}
A = 0, P && (A = Q(P, Y), Y.align === "left" ? G = k : Y.align === "right" && (G = -Math.max(D.axisOffset[1], -A)), P.align({ y: Y.y, width: P.getBBox().width, align: Y.align, x: Y.x + G - 2 }, !0, D.spacingBox), P.placed = D.hasLoaded), this.handleCollision(A), W.align({ verticalAlign: V }, !0, D.spacingBox), P = W.alignAttr.translateY, A = W.getBBox().height + 20, Q = 0, V === "bottom" && (Q = (Q = D.legend && D.legend.options) && Q.verticalAlign === "bottom" && Q.enabled && !Q.floating ? D.legend.legendHeight + c(Q.margin, 10) : 0, A = A + Q - 20, Q = P - A - (X.floating ? 0 : X.y) - (D.titleOffset ? D.titleOffset[2] : 0) - 10), V === "top" ? (X.floating && (Q = 0), D.titleOffset && D.titleOffset[0] && (Q = D.titleOffset[0]), Q += D.margin[0] - D.spacing[0] || 0) : V === "middle" && (Y.y === m.y ? Q = P : (Y.y || m.y) && (Q = 0 > Y.y || 0 > m.y ? Q - Math.min(Y.y, m.y) : P - A)), W.translate(X.x, X.y + Math.floor(Q)), m = this.minInput, Y = this.maxInput, P = this.dropdown, X.inputEnabled && m && Y && (m.style.marginTop = W.translateY + "px", Y.style.marginTop = W.translateY + "px"), P && (P.style.marginTop = W.translateY + "px");
}
}, s.prototype.alignButtonGroup = function(n, A) {
var _ = this.chart, D = this.buttonGroup, W = this.options.buttonPosition, P = _.plotLeft - _.spacing[3], X = W.x - _.spacing[3];
W.align === "right" ? X += n - P : W.align === "center" && (X -= P / 2), D && D.align({ y: W.y, width: c(A, this.initialButtonGroupWidth), align: W.align, x: X }, !0, _.spacingBox);
}, s.prototype.positionButtons = function() {
var n = this.buttons, A = this.chart, _ = this.options, D = this.zoomText, W = A.hasLoaded ? "animate" : "attr", P = _.buttonPosition, X = A.plotLeft, g = X;
D && D.visibility !== "hidden" && (D[W]({ x: c(X + P.x, X) }), g += P.x + D.getBBox().width + 5), this.buttonOptions.forEach(function(m, L) {
n[L].visibility !== "hidden" ? (n[L][W]({ x: g }), g += n[L].width + _.buttonSpacing) : n[L][W]({ x: X });
});
}, s.prototype.handleCollision = function(n) {
var A = this, _ = this.chart, D = this.buttonGroup, W = this.inputGroup, P = this.options, X = P.buttonPosition, g = P.dropdown, m = P.inputPosition;
P = function() {
var V = 0;
return A.buttons.forEach(function(Q) {
Q = Q.getBBox(), Q.width > V && (V = Q.width);
}), V;
};
var L = function(V) {
if (W && D) {
var Q = W.alignAttr.translateX + W.alignOptions.x - n + W.getBBox().x + 2, k = W.alignOptions.width, G = D.alignAttr.translateX + D.getBBox().x;
return G + V > Q && Q + k > G && X.y < m.y + W.getBBox().height;
}
return !1;
}, Y = function() {
W && D && W.attr({ translateX: W.alignAttr.translateX + (_.axisOffset[1] >= -n ? 0 : -n), translateY: W.alignAttr.translateY + D.getBBox().height + 10 });
};
if (D) {
if (g === "always") {
this.collapseButtons(n), L(P()) && Y();
return;
}
g === "never" && this.expandButtons();
}
W && D ? m.align === X.align || L(this.initialButtonGroupWidth + 20) ? g === "responsive" ? (this.collapseButtons(n), L(P()) && Y()) : Y() : g === "responsive" && this.expandButtons() : D && g === "responsive" && (this.initialButtonGroupWidth > _.plotWidth ? this.collapseButtons(n) : this.expandButtons());
}, s.prototype.collapseButtons = function(n) {
var A = this.buttons, _ = this.buttonOptions, D = this.chart, W = this.dropdown, P = this.options, X = this.zoomText, g = D.userOptions.rangeSelector && D.userOptions.rangeSelector.buttonTheme || {}, m = function(Y) {
return { text: Y ? Y + " ▾" : "▾", width: "auto", paddingLeft: c(P.buttonTheme.paddingLeft, g.padding, 8), paddingRight: c(P.buttonTheme.paddingRight, g.padding, 8) };
};
X && X.hide();
var L = !1;
_.forEach(function(Y, V) {
V = A[V], V.state !== 2 ? V.hide() : (V.show(), V.attr(m(Y.text)), L = !0);
}), L || (W && (W.selectedIndex = 0), A[0].show(), A[0].attr(m(this.zoomText && this.zoomText.textStr))), _ = P.buttonPosition.align, this.positionButtons(), _ !== "right" && _ !== "center" || this.alignButtonGroup(n, A[this.currentButtonIndex()].getBBox().width), this.showDropdown();
}, s.prototype.expandButtons = function() {
var n = this.buttons, A = this.buttonOptions, _ = this.options, D = this.zoomText;
this.hideDropdown(), D && D.show(), A.forEach(function(W, P) {
P = n[P], P.show(), P.attr({ text: W.text, width: _.buttonTheme.width || 28, paddingLeft: c(_.buttonTheme.paddingLeft, "unset"), paddingRight: c(_.buttonTheme.paddingRight, "unset") }), 2 > P.state && P.setState(0);
}), this.positionButtons();
}, s.prototype.currentButtonIndex = function() {
var n = this.dropdown;
return n && 0 < n.selectedIndex ? n.selectedIndex - 1 : 0;
}, s.prototype.showDropdown = function() {
var n = this.buttonGroup, A = this.buttons, _ = this.chart, D = this.dropdown;
if (n && D) {
var W = n.translateX;
n = n.translateY, A = A[this.currentButtonIndex()].getBBox(), v(D, { left: _.plotLeft + W + "px", top: n + 0.5 + "px", width: A.width + "px", height: A.height + "px" }), this.hasVisibleDropdown = !0;
}
}, s.prototype.hideDropdown = function() {
var n = this.dropdown;
n && (v(n, { top: "-9999em", width: "1px", height: "1px" }), this.hasVisibleDropdown = !1);
}, s.prototype.getHeight = function() {
var n = this.options, A = this.group, _ = n.y, D = n.buttonPosition.y, W = n.inputPosition.y;
return n.height ? n.height : (this.alignElements(), n = A ? A.getBBox(!0).height + 13 + _ : 0, A = Math.min(W, D), (0 > W && 0 > D || 0 < W && 0 < D) && (n += Math.abs(A)), n);
}, s.prototype.titleCollision = function(n) {
return !(n.options.title.text || n.options.subtitle.text);
}, s.prototype.update = function(n) {
var A = this.chart;
w(!0, A.options.rangeSelector, n), this.destroy(), this.init(A), this.render();
}, s.prototype.destroy = function() {
var n = this, A = n.minInput, _ = n.maxInput;
n.eventsToUnbind && (n.eventsToUnbind.forEach(function(D) {
return D();
}), n.eventsToUnbind = void 0), u(n.buttons), A && (A.onfocus = A.onblur = A.onchange = null), _ && (_.onfocus = _.onblur = _.onchange = null), x(n, function(D, W) {
D && W !== "chart" && (D instanceof H ? D.destroy() : D instanceof window.HTMLElement && T(D)), D !== s.prototype[W] && (n[W] = null);
}, this);
}, s;
}();
if (h.prototype.defaultButtons = [
{ type: "month", count: 1, text: "1m", title: "View 1 month" },
{ type: "month", count: 3, text: "3m", title: "View 3 months" },
{ type: "month", count: 6, text: "6m", title: "View 6 months" },
{ type: "ytd", text: "YTD", title: "View year to date" },
{ type: "year", count: 1, text: "1y", title: "View 1 year" },
{ type: "all", text: "All", title: "View all" }
], h.prototype.inputTypeFormats = { "datetime-local": "%Y-%m-%dT%H:%M:%S", date: "%Y-%m-%d", time: "%H:%M:%S" }, y.prototype.minFromRange = function() {
var s = this.range, n = s.type, A = this.max, _ = this.chart.time, D = function(g, m) {
var L = n === "year" ? "FullYear" : "Month", Y = new _.Date(g), V = _.get(L, Y);
return _.set(L, Y, V + m), V === _.get(L, Y) && _.set("Date", Y, 0), Y.getTime() - g;
};
if (b(s))
var W = A - s, P = s;
else
W = A + D(A, -s.count), this.chart && (this.chart.fixedRange = A - W);
var X = c(this.dataMin, Number.MIN_VALUE);
return b(W) || (W = X), W <= X && (W = X, typeof P > "u" && (P = D(W, s.count)), this.newMax = Math.min(W + P, this.dataMax)), b(A) || (W = void 0), W;
}, !I.RangeSelector) {
var o = [], t = function(s) {
function n() {
_ && (A = s.xAxis[0].getExtremes(), D = s.legend, P = _ && _.options.verticalAlign, b(A.min) && _.render(A.min, A.max), D.display && P === "top" && P === D.options.verticalAlign && (W = w(s.spacingBox), W.y = D.options.layout === "vertical" ? s.plotTop : W.y + _.getHeight(), D.group.placed = !1, D.align(W)));
}
var A, _ = s.rangeSelector, D, W, P;
_ && (B(o, function(X) {
return X[0] === s;
}) || o.push([s, [R(s.xAxis[0], "afterSetExtremes", function(X) {
_ && _.render(X.min, X.max);
}), R(s, "redraw", n)]]), n());
};
R(j, "afterGetContainer", function() {
this.options.rangeSelector && this.options.rangeSelector.enabled && (this.rangeSelector = new h(this));
}), R(j, "beforeRender", function() {
var s = this.axes, n = this.rangeSelector;
n && (b(n.deferredYTDClick) && (n.clickButton(n.deferredYTDClick), delete n.deferredYTDClick), s.forEach(function(A) {
A.updateNames(), A.setScale();
}), this.getAxisMargins(), n.render(), s = n.options.verticalAlign, n.options.floating || (s === "bottom" ? this.extraBottomMargin = !0 : s !== "middle" && (this.extraTopMargin = !0)));
}), R(j, "update", function(s) {
var n = s.options.rangeSelector;
s = this.rangeSelector;
var A = this.extraBottomMargin, _ = this.extraTopMargin;
n && n.enabled && !d(s) && this.options.rangeSelector && (this.options.rangeSelector.enabled = !0, this.rangeSelector = s = new h(this)), this.extraTopMargin = this.extraBottomMargin = !1, s && (t(this), n = n && n.verticalAlign || s.options && s.options.verticalAlign, s.options.floating || (n === "bottom" ? this.extraBottomMargin = !0 : n !== "middle" && (this.extraTopMargin = !0)), this.extraBottomMargin !== A || this.extraTopMargin !== _) && (this.isDirtyBox = !0);
}), R(j, "render", function() {
var s = this.rangeSelector;
s && !s.options.floating && (s.render(), s = s.options.verticalAlign, s === "bottom" ? this.extraBottomMargin = !0 : s !== "middle" && (this.extraTopMargin = !0));
}), R(j, "getMargins", function() {
var s = this.rangeSelector;
s && (s = s.getHeight(), this.extraTopMargin && (this.plotTop += s), this.extraBottomMargin && (this.marginBottom += s));
}), j.prototype.callbacks.push(t), R(j, "destroy", function() {
for (var s = 0; s < o.length; s++) {
var n = o[s];
if (n[0] === this) {
n[1].forEach(function(A) {
return A();
}), o.splice(s, 1);
break;
}
}
}), I.RangeSelector = h;
}
return h;
}), E(
l,
"Core/Chart/StockChart.js",
[l["Core/Animation/AnimationUtilities.js"], l["Core/Axis/Axis.js"], l["Core/Chart/Chart.js"], l["Core/FormatUtilities.js"], l["Core/DefaultOptions.js"], l["Core/Series/Series.js"], l["Core/Renderer/SVG/SVGRenderer.js"], l["Core/Utilities.js"]],
function(y, j, I, Z, H, U, F, N) {
function R(p, i) {
return p === "xAxis" ? { minPadding: 0, maxPadding: 0, overscroll: 0, ordinal: !0, title: { text: null }, labels: { overflow: "justify" }, showLastLabel: !0 } : p === "yAxis" ? { labels: { y: -2 }, opposite: a(i.opposite, !0), showLastLabel: !(!i.categories && i.type !== "category"), title: { text: null } } : {};
}
function S(p, i) {
if (p === "xAxis") {
p = u();
var h = { type: "datetime", categories: void 0 };
return a(i.navigator && i.navigator.enabled, p.navigator.enabled, !0) && (h.startOnTick = !1, h.endOnTick = !1), h;
}
return {};
}
var v = this && this.__extends || function() {
var p = function(i, h) {
return p = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(o, t) {
o.__proto__ = t;
} || function(o, t) {
for (var s in t)
t.hasOwnProperty(s) && (o[s] = t[s]);
}, p(i, h);
};
return function(i, h) {
function o() {
this.constructor = i;
}
p(i, h), i.prototype = h === null ? Object.create(h) : (o.prototype = h.prototype, new o());
};
}(), d = Z.format, u = H.getOptions;
y = N.addEvent;
var T = N.clamp, O = N.defined, B = N.extend, C = N.find, b = N.isNumber, w = N.isString, x = N.merge, a = N.pick, c = N.splat;
return N = function(p) {
function i() {
return p !== null && p.apply(this, arguments) || this;
}
return v(i, p), i.prototype.init = function(h, o) {
var t = u(), s = h.xAxis, n = h.yAxis, A = a(h.navigator && h.navigator.enabled, t.navigator.enabled, !0);
h.xAxis = h.yAxis = void 0, A = x({ chart: { panning: { enabled: !0, type: "x" }, pinchType: "x" }, navigator: { enabled: A }, scrollbar: { enabled: a(t.scrollbar && t.scrollbar.enabled, !0) }, rangeSelector: { enabled: a(t.rangeSelector.enabled, !0) }, title: { text: null }, tooltip: { split: a(t.tooltip.split, !0), crosshairs: !0 }, legend: { enabled: !1 } }, h, { isStock: !0 }), h.xAxis = s, h.yAxis = n, A.xAxis = c(h.xAxis || {}).map(function(_, D) {
return x(R("xAxis", _), t.xAxis, t.xAxis && t.xAxis[D], _, S("xAxis", h));
}), A.yAxis = c(h.yAxis || {}).map(function(_, D) {
return x(R("yAxis", _), t.yAxis, t.yAxis && t.yAxis[D], _);
}), p.prototype.init.call(this, A, o);
}, i.prototype.createAxis = function(h, o) {
return o.axis = x(R(h, o.axis), o.axis, S(h, this.userOptions)), p.prototype.createAxis.call(this, h, o);
}, i;
}(I), function(p) {
p.stockChart = function(i, h, o) {
return new p(i, h, o);
};
}(N || (N = {})), y(U, "setOptions", function(p) {
var i;
this.chart.options.isStock && (this.is("column") || this.is("columnrange") ? i = { borderWidth: 0, shadow: !1 } : this.is("scatter") || this.is("sma") || (i = { marker: { enabled: !1, radius: 2 } }), i && (p.plotOptions[this.type] = x(p.plotOptions[this.type], i)));
}), y(j, "autoLabelAlign", function(p) {
var i = this.chart, h = this.options;
i = i._labelPanes = i._labelPanes || {};
var o = this.options.labels;
this.chart.options.isStock && this.coll === "yAxis" && (h = h.top + "," + h.height, !i[h] && o.enabled && (o.x === 15 && (o.x = 0), typeof o.align > "u" && (o.align = "right"), i[h] = this, p.align = "right", p.preventDefault()));
}), y(j, "destroy", function() {
var p = this.chart, i = this.options && this.options.top + "," + this.options.height;
i && p._labelPanes && p._labelPanes[i] === this && delete p._labelPanes[i];
}), y(j, "getPlotLinePath", function(p) {
function i(G) {
var z = G === "xAxis" ? "yAxis" : "xAxis";
return G = h.options[z], b(G) ? [t[z][G]] : w(G) ? [t.get(G)] : o.map(function($) {
return $[z];
});
}
var h = this, o = this.isLinked && !this.series ? this.linkedParent.series : this.series, t = h.chart, s = t.renderer, n = h.left, A = h.top, _, D, W, P, X = [], g = [], m = p.translatedValue, L = p.value, Y = p.force;
if (t.options.isStock && p.acrossPanes !== !1 && h.coll === "xAxis" || h.coll === "yAxis") {
p.preventDefault(), g = i(h.coll);
var V = h.isXAxis ? t.yAxis : t.xAxis;
V.forEach(function(G) {
if (!O(G.options.id) || G.options.id.indexOf("navigator") === -1) {
var z = G.isXAxis ? "yAxis" : "xAxis";
z = O(G.options[z]) ? t[z][G.options[z]] : t[z][0], h === z && g.push(G);
}
});
var Q = g.length ? [] : [h.isXAxis ? t.yAxis[0] : t.xAxis[0]];
g.forEach(function(G) {
Q.indexOf(G) !== -1 || C(Q, function(z) {
return z.pos === G.pos && z.len === G.len;
}) || Q.push(G);
});
var k = a(m, h.translate(L, null, null, p.old));
b(k) && (h.horiz ? Q.forEach(function(G) {
var z;
D = G.pos, P = D + G.len, _ = W = Math.round(k + h.transB), Y !== "pass" && (_ < n || _ > n + h.width) && (Y ? _ = W = T(_, n, n + h.width) : z = !0), z || X.push(["M", _, D], ["L", W, P]);
}) : Q.forEach(function(G) {
var z;
_ = G.pos, W = _ + G.len, D = P = Math.round(A + h.height - k), Y !== "pass" && (D < A || D > A + h.height) && (Y ? D = P = T(D, A, A + h.height) : z = !0), z || X.push(["M", _, D], ["L", W, P]);
})), p.path = 0 < X.length ? s.crispPolyLine(X, p.lineWidth || 1) : null;
}
}), F.prototype.crispPolyLine = function(p, i) {
for (var h = 0; h < p.length; h += 2) {
var o = p[h], t = p[h + 1];
o[1] === t[1] && (o[1] = t[1] = Math.round(o[1]) - i % 2 / 2), o[2] === t[2] && (o[2] = t[2] = Math.round(o[2]) + i % 2 / 2);
}
return p;
}, y(j, "afterHideCrosshair", function() {
this.crossLabel && (this.crossLabel = this.crossLabel.hide());
}), y(j, "afterDrawCrosshair", function(p) {
var i, h;
if (this.crosshair && this.crosshair.label && this.crosshair.label.enabled && this.cross && b(this.min) && b(this.max)) {
var o = this.chart, t = this.logarithmic, s = this.crosshair.label, n = this.horiz, A = this.opposite, _ = this.left, D = this.top, W = this.crossLabel, P = s.format, X = "", g = this.options.tickPosition === "inside", m = this.crosshair.snap !== !1, L = 0, Y = p.e || this.cross && this.cross.e;
p = p.point;
var V = this.min, Q = this.max;
t && (V = t.lin2log(V), Q = t.lin2log(Q)), t = n ? "center" : A ? this.labelAlign === "right" ? "right" : "left" : this.labelAlign === "left" ? "left" : "center", W || (W = this.crossLabel = o.renderer.label("", 0, void 0, s.shape || "callout").addClass("highcharts-crosshair-label highcharts-color-" + (p ? p.series.colorIndex : this.series[0] && this.series[0].colorIndex)).attr({ align: s.align || t, padding: a(s.padding, 8), r: a(s.borderRadius, 3), zIndex: 2 }).add(this.labelGroup), o.styledMode || W.attr({ fill: s.backgroundColor || p && p.series && p.series.color || "#666666", stroke: s.borderColor || "", "stroke-width": s.borderWidth || 0 }).css(B({ color: "#ffffff", fontWeight: "normal", fontSize: "11px", textAlign: "center" }, s.style || {}))), n ? (t = m ? (p.plotX || 0) + _ : Y.chartX, D += A ? 0 : this.height) : (t = A ? this.width + _ : 0, D = m ? (p.plotY || 0) + D : Y.chartY), P || s.formatter || (this.dateTime && (X = "%b %d, %Y"), P = "{value" + (X ? ":" + X : "") + "}"), X = m ? this.isXAxis ? p.x : p.y : this.toValue(n ? Y.chartX : Y.chartY), m = p ? p.series.isPointInside(p) : b(X) && X > V && X < Q, Y = "", P ? Y = d(P, { value: X }, o) : s.formatter && b(X) && (Y = s.formatter.call(this, X)), W.attr({ text: Y, x: t, y: D, visibility: m ? "visible" : "hidden" }), s = W.getBBox(), b(W.y) && (n ? (g && !A || !g && A) && (D = W.y - s.height) : D = W.y - s.height / 2), n ? (i = _ - s.x, h = _ + this.width - s.x) : (i = this.labelAlign === "left" ? _ : 0, h = this.labelAlign === "right" ? _ + this.width : o.chartWidth), W.translateX < i && (L = i - W.translateX), W.translateX + s.width >= h && (L = -(W.translateX + s.width - h)), W.attr({ x: t + L, y: D, anchorX: n ? t : this.opposite ? 0 : o.chartWidth, anchorY: n ? this.opposite ? o.chartHeight : 0 : D + s.height / 2 });
}
}), U.prototype.forceCropping = function() {
var p = this.chart, i = this.options.dataGrouping;
return this.allowDG !== !1 && i && a(i.enabled, p.options.isStock);
}, y(I, "update", function(p) {
p = p.options, "scrollbar" in p && this.navigator && (x(!0, this.options.scrollbar, p.scrollbar), this.navigator.update({}, !1), delete p.scrollbar);
}), N;
}
), E(l, "masters/modules/stock.src.js", [
l["Core/Globals.js"],
l["Core/Axis/OrdinalAxis.js"],
l["Series/DataModifyComposition.js"],
l["Core/Scrollbar.js"],
l["Core/Chart/StockChart.js"]
], function(y, j, I, Z, H) {
y.Scrollbar = Z, y.StockChart = y.stockChart = H.stockChart, Z.compose(y.Axis), j.compose(y.Axis, y.Series, y.Chart), I.compose(y.Series, y.Axis, y.Point);
}), E(l, "masters/highstock.src.js", [l["masters/highcharts.src.js"]], function(y) {
return y.product = "Highstock", y;
}), l["masters/highstock.src.js"]._modules = l, l["masters/highstock.src.js"];
});
})(E0);
const $r = ul;
var dl = {}, O0 = {
get exports() {
return dl;
},
set exports(r) {
dl = r;
}
};
(function(r) {
(function(f, E) {
r.exports ? (E.default = E, r.exports = f.document ? E(f) : E) : (f.Highcharts && f.Highcharts.error(16, !0), f.Highcharts = E(f));
})(typeof window < "u" ? window : Fr, function(f) {
function E(y, j, I, Z) {
y.hasOwnProperty(j) || (y[j] = Z.apply(null, I));
}
var l = {};
return E(l, "Core/Globals.js", [], function() {
var y = typeof f < "u" ? f : typeof window < "u" ? window : {}, j;
return function(I) {
I.SVG_NS = "http://www.w3.org/2000/svg", I.product = "Highcharts", I.version = "9.3.3", I.win = y, I.doc = I.win.document, I.svg = I.doc && I.doc.createElementNS && !!I.doc.createElementNS(I.SVG_NS, "svg").createSVGRect, I.userAgent = I.win.navigator && I.win.navigator.userAgent || "", I.isChrome = I.userAgent.indexOf("Chrome") !== -1, I.isFirefox = I.userAgent.indexOf("Firefox") !== -1, I.isMS = /(edge|msie|trident)/i.test(I.userAgent) && !I.win.opera, I.isSafari = !I.isChrome && I.userAgent.indexOf("Safari") !== -1, I.isTouchDevice = /(Mobile|Android|Windows Phone)/.test(I.userAgent), I.isWebKit = I.userAgent.indexOf("AppleWebKit") !== -1, I.deg2rad = 2 * Math.PI / 360, I.hasBidiBug = I.isFirefox && 4 > parseInt(I.userAgent.split("Firefox/")[1], 10), I.hasTouch = !!I.win.TouchEvent, I.marginNames = ["plotTop", "marginRight", "marginBottom", "plotLeft"], I.noop = function() {
}, I.supportsPassiveEvents = function() {
var Z = !1;
if (!I.isMS) {
var H = Object.defineProperty({}, "passive", { get: function() {
Z = !0;
} });
I.win.addEventListener && I.win.removeEventListener && (I.win.addEventListener(
"testPassive",
I.noop,
H
), I.win.removeEventListener("testPassive", I.noop, H));
}
return Z;
}(), I.charts = [], I.dateFormats = {}, I.seriesTypes = {}, I.symbolSizes = {}, I.chartCount = 0;
}(j || (j = {})), j;
}), E(l, "Core/Utilities.js", [l["Core/Globals.js"]], function(y) {
function j(t, s, n, A) {
var _ = s ? "Highcharts error" : "Highcharts warning";
t === 32 && (t = _ + ": Deprecated member");
var D = S(t), W = D ? _ + " #" + t + ": www.highcharts.com/errors/" + t + "/" : t.toString();
if (typeof A < "u") {
var P = "";
D && (W += "?"), b(A, function(X, g) {
P += `
- ` + g + ": " + X, D && (W += encodeURI(g) + "=" + encodeURI(X));
}), W += P;
}
x(y, "displayError", { chart: n, code: t, message: W, params: A }, function() {
if (s)
throw Error(W);
p.console && j.messages.indexOf(W) === -1 && console.warn(W);
}), j.messages.push(W);
}
function I(t, s) {
var n = {};
return b(t, function(A, _) {
F(t[_], !0) && !t.nodeType && s[_] ? (A = I(t[_], s[_]), Object.keys(A).length && (n[_] = A)) : (F(t[_]) || t[_] !== s[_]) && (n[_] = t[_]);
}), n;
}
function Z(t, s) {
return parseInt(t, s || 10);
}
function H(t) {
return typeof t == "string";
}
function U(t) {
return t = Object.prototype.toString.call(t), t === "[object Array]" || t === "[object Array Iterator]";
}
function F(t, s) {
return !!t && typeof t == "object" && (!s || !U(t));
}
function N(t) {
return F(t) && typeof t.nodeType == "number";
}
function R(t) {
var s = t && t.constructor;
return !(!F(t, !0) || N(t) || !s || !s.name || s.name === "Object");
}
function S(t) {
return typeof t == "number" && !isNaN(t) && 1 / 0 > t && -1 / 0 < t;
}
function v(t) {
return typeof t < "u" && t !== null;
}
function d(t, s, n) {
var A;
return H(s) ? v(n) ? t.setAttribute(s, n) : t && t.getAttribute && ((A = t.getAttribute(s)) || s !== "class" || (A = t.getAttribute(s + "Name"))) : b(s, function(_, D) {
v(_) ? t.setAttribute(D, _) : t.removeAttribute(D);
}), A;
}
function u(t, s) {
var n;
t || (t = {});
for (n in s)
t[n] = s[n];
return t;
}
function T() {
for (var t = arguments, s = t.length, n = 0; n < s; n++) {
var A = t[n];
if (typeof A < "u" && A !== null)
return A;
}
}
function O(t, s) {
y.isMS && !y.svg && s && typeof s.opacity < "u" && (s.filter = "alpha(opacity=" + 100 * s.opacity + ")"), u(t.style, s);
}
function B(t, s) {
return 1e14 < t ? t : parseFloat(t.toPrecision(s || 14));
}
function C(t, s, n) {
var A = y.getStyle || C;
if (s === "width")
return s = Math.min(t.offsetWidth, t.scrollWidth), n = t.getBoundingClientRect && t.getBoundingClientRect().width, n < s && n >= s - 1 && (s = Math.floor(n)), Math.max(0, s - (A(t, "padding-left", !0) || 0) - (A(t, "padding-right", !0) || 0));
if (s === "height")
return Math.max(0, Math.min(t.offsetHeight, t.scrollHeight) - (A(t, "padding-top", !0) || 0) - (A(t, "padding-bottom", !0) || 0));
if (p.getComputedStyle || j(27, !0), t = p.getComputedStyle(t, void 0)) {
var _ = t.getPropertyValue(s);
T(n, s !== "opacity") && (_ = Z(_));
}
return _;
}
function b(t, s, n) {
for (var A in t)
Object.hasOwnProperty.call(t, A) && s.call(n || t[A], t[A], A, t);
}
function w(t, s, n) {
function A(P, X) {
var g = t.removeEventListener || y.removeEventListenerPolyfill;
g && g.call(t, P, X, !1);
}
function _(P) {
var X;
if (t.nodeName) {
if (s) {
var g = {};
g[s] = !0;
} else
g = P;
b(g, function(m, L) {
if (P[L])
for (X = P[L].length; X--; )
A(L, P[L][X].fn);
});
}
}
var D = typeof t == "function" && t.prototype || t;
if (Object.hasOwnProperty.call(D, "hcEvents")) {
var W = D.hcEvents;
s ? (D = W[s] || [], n ? (W[s] = D.filter(function(P) {
return n !== P.fn;
}), A(s, n)) : (_(W), W[s] = [])) : (_(W), delete D.hcEvents);
}
}
function x(t, s, n, A) {
if (n = n || {}, c.createEvent && (t.dispatchEvent || t.fireEvent && t !== y)) {
var _ = c.createEvent("Events");
_.initEvent(s, !0, !0), n = u(_, n), t.dispatchEvent ? t.dispatchEvent(n) : t.fireEvent(s, n);
} else if (t.hcEvents) {
n.target || u(n, { preventDefault: function() {
n.defaultPrevented = !0;
}, target: t, type: s }), _ = [];
for (var D = t, W = !1; D.hcEvents; )
Object.hasOwnProperty.call(D, "hcEvents") && D.hcEvents[s] && (_.length && (W = !0), _.unshift.apply(_, D.hcEvents[s])), D = Object.getPrototypeOf(D);
W && _.sort(function(P, X) {
return P.order - X.order;
}), _.forEach(function(P) {
P.fn.call(t, n) === !1 && n.preventDefault();
});
}
A && !n.defaultPrevented && A.call(t, n);
}
var a = y.charts, c = y.doc, p = y.win;
(j || (j = {})).messages = [], Math.easeInOutSine = function(t) {
return -0.5 * (Math.cos(Math.PI * t) - 1);
};
var i = Array.prototype.find ? function(t, s) {
return t.find(s);
} : function(t, s) {
var n, A = t.length;
for (n = 0; n < A; n++)
if (s(t[n], n))
return t[n];
};
b({ map: "map", each: "forEach", grep: "filter", reduce: "reduce", some: "some" }, function(t, s) {
y[s] = function(n) {
var A;
return j(32, !1, void 0, (A = {}, A["Highcharts." + s] = "use Array." + t, A)), Array.prototype[t].apply(n, [].slice.call(arguments, 1));
};
});
var h, o = function() {
var t = Math.random().toString(36).substring(2, 9) + "-", s = 0;
return function() {
return "highcharts-" + (h ? "" : t) + s++;
};
}();
return p.jQuery && (p.jQuery.fn.highcharts = function() {
var t = [].slice.call(arguments);
if (this[0])
return t[0] ? (new y[H(t[0]) ? t.shift() : "Chart"](this[0], t[0], t[1]), this) : a[d(this[0], "data-highcharts-chart")];
}), i = { addEvent: function(t, s, n, A) {
A === void 0 && (A = {});
var _ = typeof t == "function" && t.prototype || t;
Object.hasOwnProperty.call(_, "hcEvents") || (_.hcEvents = {}), _ = _.hcEvents, y.Point && t instanceof y.Point && t.series && t.series.chart && (t.series.chart.runTrackerClick = !0);
var D = t.addEventListener || y.addEventListenerPolyfill;
return D && D.call(t, s, n, y.supportsPassiveEvents ? { passive: A.passive === void 0 ? s.indexOf("touch") !== -1 : A.passive, capture: !1 } : !1), _[s] || (_[s] = []), _[s].push({ fn: n, order: typeof A.order == "number" ? A.order : 1 / 0 }), _[s].sort(function(W, P) {
return W.order - P.order;
}), function() {
w(t, s, n);
};
}, arrayMax: function(t) {
for (var s = t.length, n = t[0]; s--; )
t[s] > n && (n = t[s]);
return n;
}, arrayMin: function(t) {
for (var s = t.length, n = t[0]; s--; )
t[s] < n && (n = t[s]);
return n;
}, attr: d, clamp: function(t, s, n) {
return t > s ? t < n ? t : n : s;
}, cleanRecursively: I, clearTimeout: function(t) {
v(t) && clearTimeout(t);
}, correctFloat: B, createElement: function(t, s, n, A, _) {
return t = c.createElement(t), s && u(t, s), _ && O(t, { padding: "0", border: "none", margin: "0" }), n && O(t, n), A && A.appendChild(t), t;
}, css: O, defined: v, destroyObjectProperties: function(t, s) {
b(t, function(n, A) {
n && n !== s && n.destroy && n.destroy(), delete t[A];
});
}, discardElement: function(t) {
t && t.parentElement && t.parentElement.removeChild(t);
}, erase: function(t, s) {
for (var n = t.length; n--; )
if (t[n] === s) {
t.splice(n, 1);
break;
}
}, error: j, extend: u, extendClass: function(t, s) {
var n = function() {
};
return n.prototype = new t(), u(n.prototype, s), n;
}, find: i, fireEvent: x, getMagnitude: function(t) {
return Math.pow(10, Math.floor(Math.log(t) / Math.LN10));
}, getNestedProperty: function(t, s) {
for (t = t.split("."); t.length && v(s); ) {
var n = t.shift();
if (typeof n > "u" || n === "__proto__" || (s = s[n], !v(s) || typeof s == "function" || typeof s.nodeType == "number" || s === p))
return;
}
return s;
}, getStyle: C, inArray: function(t, s, n) {
return j(32, !1, void 0, { "Highcharts.inArray": "use Array.indexOf" }), s.indexOf(t, n);
}, isArray: U, isClass: R, isDOMElement: N, isFunction: function(t) {
return typeof t == "function";
}, isNumber: S, isObject: F, isString: H, keys: function(t) {
return j(32, !1, void 0, { "Highcharts.keys": "use Object.keys" }), Object.keys(t);
}, merge: function() {
var t, s = arguments, n = {}, A = function(D, W) {
return typeof D != "object" && (D = {}), b(W, function(P, X) {
X !== "__proto__" && X !== "constructor" && (!F(P, !0) || R(P) || N(P) ? D[X] = W[X] : D[X] = A(D[X] || {}, P));
}), D;
};
s[0] === !0 && (n = s[1], s = Array.prototype.slice.call(s, 2));
var _ = s.length;
for (t = 0; t < _; t++)
n = A(n, s[t]);
return n;
}, normalizeTickInterval: function(t, s, n, A, _) {
var D = t;
n = T(n, 1);
var W = t / n;
for (s || (s = _ ? [1, 1.2, 1.5, 2, 2.5, 3, 4, 5, 6, 8, 10] : [1, 2, 2.5, 5, 10], A === !1 && (n === 1 ? s = s.filter(function(P) {
return P % 1 === 0;
}) : 0.1 >= n && (s = [1 / n]))), A = 0; A < s.length && (D = s[A], !(_ && D * n >= t || !_ && W <= (s[A] + (s[A + 1] || s[A])) / 2)); A++)
;
return D = B(D * n, -Math.round(Math.log(1e-3) / Math.LN10));
}, objectEach: b, offset: function(t) {
var s = c.documentElement;
return t = t.parentElement || t.parentNode ? t.getBoundingClientRect() : { top: 0, left: 0, width: 0, height: 0 }, { top: t.top + (p.pageYOffset || s.scrollTop) - (s.clientTop || 0), left: t.left + (p.pageXOffset || s.scrollLeft) - (s.clientLeft || 0), width: t.width, height: t.height };
}, pad: function(t, s, n) {
return Array((s || 2) + 1 - String(t).replace("-", "").length).join(n || "0") + t;
}, pick: T, pInt: Z, relativeLength: function(t, s, n) {
return /%$/.test(t) ? s * parseFloat(t) / 100 + (n || 0) : parseFloat(t);
}, removeEvent: w, splat: function(t) {
return U(t) ? t : [t];
}, stableSort: function(t, s) {
var n = t.length, A, _;
for (_ = 0; _ < n; _++)
t[_].safeI = _;
for (t.sort(function(D, W) {
return A = s(D, W), A === 0 ? D.safeI - W.safeI : A;
}), _ = 0; _ < n; _++)
delete t[_].safeI;
}, syncTimeout: function(t, s, n) {
return 0 < s ? setTimeout(t, s, n) : (t.call(0, n), -1);
}, timeUnits: {
millisecond: 1,
second: 1e3,
minute: 6e4,
hour: 36e5,
day: 864e5,
week: 6048e5,
month: 24192e5,
year: 314496e5
}, uniqueKey: o, useSerialIds: function(t) {
return h = T(t, h);
}, wrap: function(t, s, n) {
var A = t[s];
t[s] = function() {
var _ = Array.prototype.slice.call(arguments), D = arguments, W = this;
return W.proceed = function() {
A.apply(W, arguments.length ? arguments : D);
}, _.unshift(A), _ = n.apply(this, _), W.proceed = null, _;
};
} }, i;
}), E(l, "Core/Chart/ChartDefaults.js", [], function() {
return { panning: { enabled: !1, type: "x" }, styledMode: !1, borderRadius: 0, colorCount: 10, defaultSeriesType: "line", ignoreHiddenSeries: !0, spacing: [
10,
10,
15,
10
], resetZoomButton: { theme: { zIndex: 6 }, position: { align: "right", x: -10, y: 10 } }, zoomBySingleTouch: !1, width: null, height: null, borderColor: "#335cad", backgroundColor: "#ffffff", plotBorderColor: "#cccccc" };
}), E(l, "Core/Color/Color.js", [l["Core/Globals.js"], l["Core/Utilities.js"]], function(y, j) {
var I = j.isNumber, Z = j.merge, H = j.pInt;
return j = function() {
function U(F) {
this.rgba = [NaN, NaN, NaN, NaN], this.input = F;
var N = y.Color;
if (N && N !== U)
return new N(F);
if (!(this instanceof U))
return new U(F);
this.init(F);
}
return U.parse = function(F) {
return F ? new U(F) : U.None;
}, U.prototype.init = function(F) {
var N;
if (typeof F == "object" && typeof F.stops < "u")
this.stops = F.stops.map(function(d) {
return new U(d[1]);
});
else if (typeof F == "string") {
if (this.input = F = U.names[F.toLowerCase()] || F, F.charAt(0) === "#") {
var R = F.length, S = parseInt(F.substr(1), 16);
R === 7 ? N = [(S & 16711680) >> 16, (S & 65280) >> 8, S & 255, 1] : R === 4 && (N = [(S & 3840) >> 4 | (S & 3840) >> 8, (S & 240) >> 4 | S & 240, (S & 15) << 4 | S & 15, 1]);
}
if (!N)
for (S = U.parsers.length; S-- && !N; ) {
var v = U.parsers[S];
(R = v.regex.exec(F)) && (N = v.parse(R));
}
}
N && (this.rgba = N);
}, U.prototype.get = function(F) {
var N = this.input, R = this.rgba;
if (typeof N == "object" && typeof this.stops < "u") {
var S = Z(N);
return S.stops = [].slice.call(S.stops), this.stops.forEach(function(v, d) {
S.stops[d] = [S.stops[d][0], v.get(F)];
}), S;
}
return R && I(R[0]) ? F === "rgb" || !F && R[3] === 1 ? "rgb(" + R[0] + "," + R[1] + "," + R[2] + ")" : F === "a" ? "" + R[3] : "rgba(" + R.join(",") + ")" : N;
}, U.prototype.brighten = function(F) {
var N = this.rgba;
if (this.stops)
this.stops.forEach(function(S) {
S.brighten(F);
});
else if (I(F) && F !== 0)
for (var R = 0; 3 > R; R++)
N[R] += H(255 * F), 0 > N[R] && (N[R] = 0), 255 < N[R] && (N[R] = 255);
return this;
}, U.prototype.setOpacity = function(F) {
return this.rgba[3] = F, this;
}, U.prototype.tweenTo = function(F, N) {
var R = this.rgba, S = F.rgba;
return !I(R[0]) || !I(S[0]) ? F.input || "none" : (F = S[3] !== 1 || R[3] !== 1, (F ? "rgba(" : "rgb(") + Math.round(S[0] + (R[0] - S[0]) * (1 - N)) + "," + Math.round(S[1] + (R[1] - S[1]) * (1 - N)) + "," + Math.round(S[2] + (R[2] - S[2]) * (1 - N)) + (F ? "," + (S[3] + (R[3] - S[3]) * (1 - N)) : "") + ")");
}, U.names = { white: "#ffffff", black: "#000000" }, U.parsers = [{
regex: /rgba\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]?(?:\.[0-9]+)?)\s*\)/,
parse: function(F) {
return [H(F[1]), H(F[2]), H(F[3]), parseFloat(F[4], 10)];
}
}, { regex: /rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/, parse: function(F) {
return [H(F[1]), H(F[2]), H(F[3]), 1];
} }], U.None = new U(""), U;
}(), j;
}), E(l, "Core/Color/Palettes.js", [], function() {
return { colors: "#7cb5ec #434348 #90ed7d #f7a35c #8085e9 #f15c80 #e4d354 #2b908f #f45b5b #91e8e1".split(" ") };
}), E(l, "Core/Time.js", [l["Core/Globals.js"], l["Core/Utilities.js"]], function(y, j) {
var I = y.win, Z = j.defined, H = j.error, U = j.extend, F = j.isObject, N = j.merge, R = j.objectEach, S = j.pad, v = j.pick, d = j.splat, u = j.timeUnits, T = y.isSafari && I.Intl && I.Intl.DateTimeFormat.prototype.formatRange, O = y.isSafari && I.Intl && !I.Intl.DateTimeFormat.prototype.formatRange;
return j = function() {
function B(C) {
this.options = {}, this.variableTimezone = this.useUTC = !1, this.Date = I.Date, this.getTimezoneOffset = this.timezoneOffsetFunction(), this.update(C);
}
return B.prototype.get = function(C, b) {
if (this.variableTimezone || this.timezoneOffset) {
var w = b.getTime(), x = w - this.getTimezoneOffset(b);
return b.setTime(x), C = b["getUTC" + C](), b.setTime(w), C;
}
return this.useUTC ? b["getUTC" + C]() : b["get" + C]();
}, B.prototype.set = function(C, b, w) {
if (this.variableTimezone || this.timezoneOffset) {
if (C === "Milliseconds" || C === "Seconds" || C === "Minutes" && this.getTimezoneOffset(b) % 36e5 === 0)
return b["setUTC" + C](w);
var x = this.getTimezoneOffset(b);
return x = b.getTime() - x, b.setTime(x), b["setUTC" + C](w), C = this.getTimezoneOffset(b), x = b.getTime() + C, b.setTime(x);
}
return this.useUTC || T && C === "FullYear" ? b["setUTC" + C](w) : b["set" + C](w);
}, B.prototype.update = function(C) {
var b = v(C && C.useUTC, !0);
this.options = C = N(!0, this.options || {}, C), this.Date = C.Date || I.Date || Date, this.timezoneOffset = (this.useUTC = b) && C.timezoneOffset, this.getTimezoneOffset = this.timezoneOffsetFunction(), this.variableTimezone = b && !(!C.getTimezoneOffset && !C.timezone);
}, B.prototype.makeTime = function(C, b, w, x, a, c) {
if (this.useUTC) {
var p = this.Date.UTC.apply(0, arguments), i = this.getTimezoneOffset(p);
p += i;
var h = this.getTimezoneOffset(p);
i !== h ? p += h - i : i - 36e5 !== this.getTimezoneOffset(p - 36e5) || O || (p -= 36e5);
} else
p = new this.Date(C, b, v(w, 1), v(x, 0), v(a, 0), v(c, 0)).getTime();
return p;
}, B.prototype.timezoneOffsetFunction = function() {
var C = this, b = this.options, w = b.getTimezoneOffset, x = b.moment || I.moment;
if (!this.useUTC)
return function(a) {
return 6e4 * new Date(a.toString()).getTimezoneOffset();
};
if (b.timezone) {
if (x)
return function(a) {
return 6e4 * -x.tz(a, b.timezone).utcOffset();
};
H(25);
}
return this.useUTC && w ? function(a) {
return 6e4 * w(a.valueOf());
} : function() {
return 6e4 * (C.timezoneOffset || 0);
};
}, B.prototype.dateFormat = function(C, b, w) {
if (!Z(b) || isNaN(b))
return y.defaultOptions.lang && y.defaultOptions.lang.invalidDate || "";
C = v(C, "%Y-%m-%d %H:%M:%S");
var x = this, a = new this.Date(b), c = this.get("Hours", a), p = this.get("Day", a), i = this.get("Date", a), h = this.get("Month", a), o = this.get("FullYear", a), t = y.defaultOptions.lang, s = t && t.weekdays, n = t && t.shortWeekdays;
return a = U({ a: n ? n[p] : s[p].substr(0, 3), A: s[p], d: S(i), e: S(i, 2, " "), w: p, b: t.shortMonths[h], B: t.months[h], m: S(h + 1), o: h + 1, y: o.toString().substr(2, 2), Y: o, H: S(c), k: c, I: S(c % 12 || 12), l: c % 12 || 12, M: S(this.get("Minutes", a)), p: 12 > c ? "AM" : "PM", P: 12 > c ? "am" : "pm", S: S(a.getSeconds()), L: S(Math.floor(b % 1e3), 3) }, y.dateFormats), R(a, function(A, _) {
for (; C.indexOf("%" + _) !== -1; )
C = C.replace("%" + _, typeof A == "function" ? A.call(x, b) : A);
}), w ? C.substr(0, 1).toUpperCase() + C.substr(1) : C;
}, B.prototype.resolveDTLFormat = function(C) {
return F(C, !0) ? C : (C = d(C), { main: C[0], from: C[1], to: C[2] });
}, B.prototype.getTimeTicks = function(C, b, w, x) {
var a = this, c = [], p = {}, i = new a.Date(b), h = C.unitRange, o = C.count || 1, t;
if (x = v(x, 1), Z(b)) {
if (a.set(
"Milliseconds",
i,
h >= u.second ? 0 : o * Math.floor(a.get("Milliseconds", i) / o)
), h >= u.second && a.set("Seconds", i, h >= u.minute ? 0 : o * Math.floor(a.get("Seconds", i) / o)), h >= u.minute && a.set("Minutes", i, h >= u.hour ? 0 : o * Math.floor(a.get("Minutes", i) / o)), h >= u.hour && a.set("Hours", i, h >= u.day ? 0 : o * Math.floor(a.get("Hours", i) / o)), h >= u.day && a.set("Date", i, h >= u.month ? 1 : Math.max(1, o * Math.floor(a.get("Date", i) / o))), h >= u.month) {
a.set("Month", i, h >= u.year ? 0 : o * Math.floor(a.get("Month", i) / o));
var s = a.get("FullYear", i);
}
h >= u.year && a.set(
"FullYear",
i,
s - s % o
), h === u.week && (s = a.get("Day", i), a.set("Date", i, a.get("Date", i) - s + x + (s < x ? -7 : 0))), s = a.get("FullYear", i), x = a.get("Month", i);
var n = a.get("Date", i), A = a.get("Hours", i);
for (b = i.getTime(), !a.variableTimezone && a.useUTC || !Z(w) || (t = w - b > 4 * u.month || a.getTimezoneOffset(b) !== a.getTimezoneOffset(w)), b = i.getTime(), i = 1; b < w; )
c.push(b), b = h === u.year ? a.makeTime(s + i * o, 0) : h === u.month ? a.makeTime(s, x + i * o) : !t || h !== u.day && h !== u.week ? t && h === u.hour && 1 < o ? a.makeTime(s, x, n, A + i * o) : b + h * o : a.makeTime(s, x, n + i * o * (h === u.day ? 1 : 7)), i++;
c.push(b), h <= u.hour && 1e4 > c.length && c.forEach(function(_) {
_ % 18e5 === 0 && a.dateFormat("%H%M%S%L", _) === "000000000" && (p[_] = "day");
});
}
return c.info = U(C, { higherRanks: p, totalRange: h * o }), c;
}, B.prototype.getDateFormat = function(C, b, w, x) {
var a = this.dateFormat("%m-%d %H:%M:%S.%L", b), c = { millisecond: 15, second: 12, minute: 9, hour: 6, day: 3 }, p = "millisecond";
for (i in u) {
if (C === u.week && +this.dateFormat("%w", b) === w && a.substr(6) === "00:00:00.000") {
var i = "week";
break;
}
if (u[i] > C) {
i = p;
break;
}
if (c[i] && a.substr(c[i]) !== "01-01 00:00:00.000".substr(c[i]))
break;
i !== "week" && (p = i);
}
if (i)
var h = this.resolveDTLFormat(x[i]).main;
return h;
}, B;
}(), j;
}), E(l, "Core/DefaultOptions.js", [l["Core/Chart/ChartDefaults.js"], l["Core/Color/Color.js"], l["Core/Globals.js"], l["Core/Color/Palettes.js"], l["Core/Time.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H, U) {
j = j.parse;
var F = U.merge, N = {
colors: Z.colors,
symbols: ["circle", "diamond", "square", "triangle", "triangle-down"],
lang: {
loading: "Loading...",
months: "January February March April May June July August September October November December".split(" "),
shortMonths: "Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec".split(" "),
weekdays: "Sunday Monday Tuesday Wednesday Thursday Friday Saturday".split(" "),
decimalPoint: ".",
numericSymbols: "kMGTPE".split(""),
resetZoom: "Reset zoom",
resetZoomTitle: "Reset zoom level 1:1",
thousandsSep: " "
},
global: {},
time: { Date: void 0, getTimezoneOffset: void 0, timezone: void 0, timezoneOffset: 0, useUTC: !0 },
chart: y,
title: { text: "Chart title", align: "center", margin: 15, widthAdjust: -44 },
subtitle: { text: "", align: "center", widthAdjust: -44 },
caption: { margin: 15, text: "", align: "left", verticalAlign: "bottom" },
plotOptions: {},
labels: { style: { position: "absolute", color: "#333333" } },
legend: {
enabled: !0,
align: "center",
alignColumns: !0,
className: "highcharts-no-tooltip",
layout: "horizontal",
labelFormatter: function() {
return this.name;
},
borderColor: "#999999",
borderRadius: 0,
navigation: { activeColor: "#003399", inactiveColor: "#cccccc" },
itemStyle: { color: "#333333", cursor: "pointer", fontSize: "12px", fontWeight: "bold", textOverflow: "ellipsis" },
itemHoverStyle: { color: "#000000" },
itemHiddenStyle: { color: "#cccccc" },
shadow: !1,
itemCheckboxStyle: { position: "absolute", width: "13px", height: "13px" },
squareSymbol: !0,
symbolPadding: 5,
verticalAlign: "bottom",
x: 0,
y: 0,
title: { style: { fontWeight: "bold" } }
},
loading: { labelStyle: { fontWeight: "bold", position: "relative", top: "45%" }, style: { position: "absolute", backgroundColor: "#ffffff", opacity: 0.5, textAlign: "center" } },
tooltip: {
enabled: !0,
animation: I.svg,
borderRadius: 3,
dateTimeLabelFormats: {
millisecond: "%A, %b %e, %H:%M:%S.%L",
second: "%A, %b %e, %H:%M:%S",
minute: "%A, %b %e, %H:%M",
hour: "%A, %b %e, %H:%M",
day: "%A, %b %e, %Y",
week: "Week from %A, %b %e, %Y",
month: "%B %Y",
year: "%Y"
},
footerFormat: "",
headerShape: "callout",
hideDelay: 500,
padding: 8,
shape: "callout",
shared: !1,
snap: I.isTouchDevice ? 25 : 10,
headerFormat: '{point.key}
',
pointFormat: '● {series.name}: {point.y}
',
backgroundColor: j("#f7f7f7").setOpacity(0.85).get(),
borderWidth: 1,
shadow: !0,
stickOnContact: !1,
style: { color: "#333333", cursor: "default", fontSize: "12px", whiteSpace: "nowrap" },
useHTML: !1
},
credits: { enabled: !0, href: "https://www.highcharts.com?credits", position: { align: "right", x: -10, verticalAlign: "bottom", y: -5 }, style: { cursor: "pointer", color: "#999999", fontSize: "9px" }, text: "Highcharts.com" }
};
N.chart.styledMode = !1;
var R = new H(F(N.global, N.time));
return y = { defaultOptions: N, defaultTime: R, getOptions: function() {
return N;
}, setOptions: function(S) {
return F(!0, N, S), (S.time || S.global) && (I.time ? I.time.update(F(
N.global,
N.time,
S.global,
S.time
)) : I.time = R), N;
} }, y;
}), E(l, "Core/Animation/Fx.js", [l["Core/Color/Color.js"], l["Core/Globals.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = y.parse, H = j.win, U = I.isNumber, F = I.objectEach;
return function() {
function N(R, S, v) {
this.pos = NaN, this.options = S, this.elem = R, this.prop = v;
}
return N.prototype.dSetter = function() {
var R = this.paths, S = R && R[0];
R = R && R[1];
var v = this.now || 0, d = [];
if (v !== 1 && S && R)
if (S.length === R.length && 1 > v)
for (var u = 0; u < R.length; u++) {
for (var T = S[u], O = R[u], B = [], C = 0; C < O.length; C++) {
var b = T[C], w = O[C];
U(b) && U(w) && (O[0] !== "A" || C !== 4 && C !== 5) ? B[C] = b + v * (w - b) : B[C] = w;
}
d.push(B);
}
else
d = R;
else
d = this.toD || [];
this.elem.attr("d", d, void 0, !0);
}, N.prototype.update = function() {
var R = this.elem, S = this.prop, v = this.now, d = this.options.step;
this[S + "Setter"] ? this[S + "Setter"]() : R.attr ? R.element && R.attr(S, v, null, !0) : R.style[S] = v + this.unit, d && d.call(R, v, this);
}, N.prototype.run = function(R, S, v) {
var d = this, u = d.options, T = function(C) {
return T.stopped ? !1 : d.step(C);
}, O = H.requestAnimationFrame || function(C) {
setTimeout(
C,
13
);
}, B = function() {
for (var C = 0; C < N.timers.length; C++)
N.timers[C]() || N.timers.splice(C--, 1);
N.timers.length && O(B);
};
R !== S || this.elem["forceAnimate:" + this.prop] ? (this.startTime = +/* @__PURE__ */ new Date(), this.start = R, this.end = S, this.unit = v, this.now = this.start, this.pos = 0, T.elem = this.elem, T.prop = this.prop, T() && N.timers.push(T) === 1 && O(B)) : (delete u.curAnim[this.prop], u.complete && Object.keys(u.curAnim).length === 0 && u.complete.call(this.elem));
}, N.prototype.step = function(R) {
var S = +/* @__PURE__ */ new Date(), v = this.options, d = this.elem, u = v.complete, T = v.duration, O = v.curAnim;
if (d.attr && !d.element)
R = !1;
else if (R || S >= T + this.startTime) {
this.now = this.end, this.pos = 1, this.update();
var B = O[this.prop] = !0;
F(O, function(C) {
C !== !0 && (B = !1);
}), B && u && u.call(d), R = !1;
} else
this.pos = v.easing((S - this.startTime) / T), this.now = this.start + (this.end - this.start) * this.pos, this.update(), R = !0;
return R;
}, N.prototype.initPath = function(R, S, v) {
function d(a, c) {
for (; a.length < x; ) {
var p = a[0], i = c[x - a.length];
i && p[0] === "M" && (a[0] = i[0] === "C" ? ["C", p[1], p[2], p[1], p[2], p[1], p[2]] : [
"L",
p[1],
p[2]
]), a.unshift(p), B && (p = a.pop(), a.push(a[a.length - 1], p));
}
}
function u(a, c) {
for (; a.length < x; )
if (c = a[Math.floor(a.length / C) - 1].slice(), c[0] === "C" && (c[1] = c[5], c[2] = c[6]), B) {
var p = a[Math.floor(a.length / C)].slice();
a.splice(a.length / 2, 0, c, p);
} else
a.push(c);
}
var T = R.startX, O = R.endX;
v = v.slice();
var B = R.isArea, C = B ? 2 : 1;
if (S = S && S.slice(), !S)
return [v, v];
if (T && O && O.length) {
for (R = 0; R < T.length; R++)
if (T[R] === O[0]) {
var b = R;
break;
} else if (T[0] === O[O.length - T.length + R]) {
b = R;
var w = !0;
break;
} else if (T[T.length - 1] === O[O.length - T.length + R]) {
b = T.length - R;
break;
}
typeof b > "u" && (S = []);
}
if (S.length && U(b)) {
var x = v.length + b * C;
w ? (d(S, v), u(v, S)) : (d(v, S), u(S, v));
}
return [S, v];
}, N.prototype.fillSetter = function() {
N.prototype.strokeSetter.apply(this, arguments);
}, N.prototype.strokeSetter = function() {
this.elem.attr(this.prop, Z(this.start).tweenTo(Z(this.end), this.pos), void 0, !0);
}, N.timers = [], N;
}();
}), E(l, "Core/Animation/AnimationUtilities.js", [l["Core/Animation/Fx.js"], l["Core/Utilities.js"]], function(y, j) {
function I(u) {
return R(u) ? S({ duration: 500, defer: 0 }, u) : { duration: u ? 500 : 0, defer: 0 };
}
function Z(u, T) {
for (var O = y.timers.length; O--; )
y.timers[O].elem !== u || T && T !== y.timers[O].prop || (y.timers[O].stopped = !0);
}
var H = j.defined, U = j.getStyle, F = j.isArray, N = j.isNumber, R = j.isObject, S = j.merge, v = j.objectEach, d = j.pick;
return { animate: function(u, T, O) {
var B, C = "", b, w;
if (!R(O)) {
var x = arguments;
O = { duration: x[2], easing: x[3], complete: x[4] };
}
N(O.duration) || (O.duration = 400), O.easing = typeof O.easing == "function" ? O.easing : Math[O.easing] || Math.easeInOutSine, O.curAnim = S(T), v(T, function(a, c) {
Z(u, c), w = new y(u, O, c), b = void 0, c === "d" && F(T.d) ? (w.paths = w.initPath(u, u.pathArray, T.d), w.toD = T.d, B = 0, b = 1) : u.attr ? B = u.attr(c) : (B = parseFloat(U(u, c)) || 0, c !== "opacity" && (C = "px")), b || (b = a), typeof b == "string" && b.match("px") && (b = b.replace(/px/g, "")), w.run(B, b, C);
});
}, animObject: I, getDeferredAnimation: function(u, T, O) {
var B = I(T), C = 0, b = 0;
return (O ? [O] : u.series).forEach(function(w) {
w = I(w.options.animation), C = T && H(T.defer) ? B.defer : Math.max(C, w.duration + w.defer), b = Math.min(B.duration, w.duration);
}), u.renderer.forExport && (C = 0), { defer: Math.max(0, C - b), duration: Math.min(C, b) };
}, setAnimation: function(u, T) {
T.renderer.globalAnimation = d(u, T.options.chart.animation, !0);
}, stop: Z };
}), E(l, "Core/Renderer/HTML/AST.js", [l["Core/Globals.js"], l["Core/Utilities.js"]], function(y, j) {
var I = y.SVG_NS, Z = j.attr, H = j.createElement, U = j.error, F = j.isFunction, N = j.isString, R = j.objectEach, S = j.splat, v = (j = y.win.trustedTypes) && F(j.createPolicy) && j.createPolicy("highcharts", { createHTML: function(T) {
return T;
} }), d = v ? v.createHTML("") : "";
try {
var u = !!new DOMParser().parseFromString(d, "text/html");
} catch {
u = !1;
}
return F = function() {
function T(O) {
this.nodes = typeof O == "string" ? this.parseMarkup(O) : O;
}
return T.filterUserAttributes = function(O) {
return R(O, function(B, C) {
var b = !0;
T.allowedAttributes.indexOf(C) === -1 && (b = !1), ["background", "dynsrc", "href", "lowsrc", "src"].indexOf(C) !== -1 && (b = N(B) && T.allowedReferences.some(function(w) {
return B.indexOf(w) === 0;
})), b || (U("Highcharts warning: Invalid attribute '" + C + "' in config"), delete O[C]);
}), O;
}, T.setElementHTML = function(O, B) {
O.innerHTML = T.emptyHTML, B && new T(B).addToDOM(O);
}, T.prototype.addToDOM = function(O) {
function B(C, b) {
var w;
return S(C).forEach(function(x) {
var a = x.tagName, c = x.textContent ? y.doc.createTextNode(x.textContent) : void 0;
if (a)
if (a === "#text")
var p = c;
else if (T.allowedTags.indexOf(a) !== -1) {
a = y.doc.createElementNS(a === "svg" ? I : b.namespaceURI || I, a);
var i = x.attributes || {};
R(x, function(h, o) {
o !== "tagName" && o !== "attributes" && o !== "children" && o !== "textContent" && (i[o] = h);
}), Z(a, T.filterUserAttributes(i)), c && a.appendChild(c), B(x.children || [], a), p = a;
} else
U("Highcharts warning: Invalid tagName " + a + " in config");
p && b.appendChild(p), w = p;
}), w;
}
return B(this.nodes, O);
}, T.prototype.parseMarkup = function(O) {
var B = [];
if (O = O.trim(), u)
O = new DOMParser().parseFromString(v ? v.createHTML(O) : O, "text/html");
else {
var C = H("div");
C.innerHTML = O, O = { body: C };
}
var b = function(w, x) {
var a = w.nodeName.toLowerCase(), c = { tagName: a };
if (a === "#text" && (c.textContent = w.textContent || ""), a = w.attributes) {
var p = {};
[].forEach.call(a, function(h) {
p[h.name] = h.value;
}), c.attributes = p;
}
if (w.childNodes.length) {
var i = [];
[].forEach.call(w.childNodes, function(h) {
b(h, i);
}), i.length && (c.children = i);
}
x.push(c);
};
return [].forEach.call(O.body.childNodes, function(w) {
return b(w, B);
}), B;
}, T.allowedAttributes = "aria-controls aria-describedby aria-expanded aria-haspopup aria-hidden aria-label aria-labelledby aria-live aria-pressed aria-readonly aria-roledescription aria-selected class clip-path color colspan cx cy d dx dy disabled fill height href id in markerHeight markerWidth offset opacity orient padding paddingLeft paddingRight patternUnits r refX refY role scope slope src startOffset stdDeviation stroke stroke-linecap stroke-width style tableValues result rowspan summary target tabindex text-align textAnchor textLength title type valign width x x1 x2 y y1 y2 zIndex".split(" "), T.allowedReferences = "https:// http:// mailto: / ../ ./ #".split(" "), T.allowedTags = "a abbr b br button caption circle clipPath code dd defs div dl dt em feComponentTransfer feFuncA feFuncB feFuncG feFuncR feGaussianBlur feOffset feMerge feMergeNode filter h1 h2 h3 h4 h5 h6 hr i img li linearGradient marker ol p path pattern pre rect small span stop strong style sub sup svg table text thead tbody tspan td th tr u ul #text".split(" "), T.emptyHTML = d, T;
}(), F;
}), E(
l,
"Core/FormatUtilities.js",
[l["Core/DefaultOptions.js"], l["Core/Utilities.js"]],
function(y, j) {
function I(S, v, d, u) {
S = +S || 0, v = +v;
var T = Z.lang, O = (S.toString().split(".")[1] || "").split("e")[0].length, B = S.toString().split("e"), C = v;
if (v === -1)
v = Math.min(O, 20);
else if (!F(v))
v = 2;
else if (v && B[1] && 0 > B[1]) {
var b = v + +B[1];
0 <= b ? (B[0] = (+B[0]).toExponential(b).split("e")[0], v = b) : (B[0] = B[0].split(".")[0] || 0, S = 20 > v ? (B[0] * Math.pow(10, B[1])).toFixed(v) : 0, B[1] = 0);
}
b = (Math.abs(B[1] ? B[0] : S) + Math.pow(10, -Math.max(v, O) - 1)).toFixed(v), O = String(R(b));
var w = 3 < O.length ? O.length % 3 : 0;
return d = N(d, T.decimalPoint), u = N(u, T.thousandsSep), S = (0 > S ? "-" : "") + (w ? O.substr(0, w) + u : ""), S = 0 > +B[1] && !C ? "0" : S + O.substr(w).replace(/(\d{3})(?=\d)/g, "$1" + u), v && (S += d + b.slice(-v)), B[1] && +S != 0 && (S += "e" + B[1]), S;
}
var Z = y.defaultOptions, H = y.defaultTime, U = j.getNestedProperty, F = j.isNumber, N = j.pick, R = j.pInt;
return { dateFormat: function(S, v, d) {
return H.dateFormat(S, v, d);
}, format: function(S, v, d) {
var u = "{", T = !1, O = /f$/, B = /\.([0-9])/, C = Z.lang, b = d && d.time || H;
d = d && d.numberFormatter || I;
for (var w = []; S; ) {
var x = S.indexOf(u);
if (x === -1)
break;
var a = S.slice(0, x);
if (T) {
if (a = a.split(":"), u = U(a.shift() || "", v), a.length && typeof u == "number")
if (a = a.join(":"), O.test(a)) {
var c = parseInt((a.match(B) || ["", "-1"])[1], 10);
u !== null && (u = d(u, c, C.decimalPoint, -1 < a.indexOf(",") ? C.thousandsSep : ""));
} else
u = b.dateFormat(a, u);
w.push(u);
} else
w.push(a);
S = S.slice(x + 1), u = (T = !T) ? "}" : "{";
}
return w.push(S), w.join("");
}, numberFormat: I };
}
), E(l, "Core/Renderer/RendererUtilities.js", [l["Core/Utilities.js"]], function(y) {
var j = y.clamp, I = y.pick, Z = y.stableSort, H;
return function(U) {
function F(N, R, S) {
var v = N, d = v.reducedLen || R, u = function(w, x) {
return (x.rank || 0) - (w.rank || 0);
}, T = function(w, x) {
return w.target - x.target;
}, O, B = !0, C = [], b = 0;
for (O = N.length; O--; )
b += N[O].size;
if (b > d) {
for (Z(N, u), b = O = 0; b <= d; )
b += N[O].size, O++;
C = N.splice(O - 1, N.length);
}
for (Z(N, T), N = N.map(function(w) {
return { size: w.size, targets: [w.target], align: I(w.align, 0.5) };
}); B; ) {
for (O = N.length; O--; )
d = N[O], u = (Math.min.apply(0, d.targets) + Math.max.apply(0, d.targets)) / 2, d.pos = j(
u - d.size * d.align,
0,
R - d.size
);
for (O = N.length, B = !1; O--; )
0 < O && N[O - 1].pos + N[O - 1].size > N[O].pos && (N[O - 1].size += N[O].size, N[O - 1].targets = N[O - 1].targets.concat(N[O].targets), N[O - 1].align = 0.5, N[O - 1].pos + N[O - 1].size > R && (N[O - 1].pos = R - N[O - 1].size), N.splice(O, 1), B = !0);
}
return v.push.apply(v, C), O = 0, N.some(function(w) {
var x = 0;
return (w.targets || []).some(function() {
return v[O].pos = w.pos + x, typeof S < "u" && Math.abs(v[O].pos - v[O].target) > S ? (v.slice(0, O + 1).forEach(function(a) {
return delete a.pos;
}), v.reducedLen = (v.reducedLen || R) - 0.1 * R, v.reducedLen > 0.1 * R && F(v, R, S), !0) : (x += v[O].size, O++, !1);
});
}), Z(v, T), v;
}
U.distribute = F;
}(H || (H = {})), H;
}), E(l, "Core/Renderer/SVG/SVGElement.js", [l["Core/Animation/AnimationUtilities.js"], l["Core/Renderer/HTML/AST.js"], l["Core/Color/Color.js"], l["Core/Globals.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H) {
var U = y.animate, F = y.animObject, N = y.stop, R = Z.deg2rad, S = Z.doc, v = Z.noop, d = Z.svg, u = Z.SVG_NS, T = Z.win, O = H.addEvent, B = H.attr, C = H.createElement, b = H.css, w = H.defined, x = H.erase, a = H.extend, c = H.fireEvent, p = H.isArray, i = H.isFunction, h = H.isNumber, o = H.isString, t = H.merge, s = H.objectEach, n = H.pick, A = H.pInt, _ = H.syncTimeout, D = H.uniqueKey;
return y = function() {
function W() {
this.element = void 0, this.onEvents = {}, this.opacity = 1, this.renderer = void 0, this.SVG_NS = u, this.symbolCustomAttribs = "x y width height r start end innerR anchorX anchorY rounded".split(" ");
}
return W.prototype._defaultGetter = function(P) {
return P = n(this[P + "Value"], this[P], this.element ? this.element.getAttribute(P) : null, 0), /^[\-0-9\.]+$/.test(P) && (P = parseFloat(P)), P;
}, W.prototype._defaultSetter = function(P, X, g) {
g.setAttribute(X, P);
}, W.prototype.add = function(P) {
var X = this.renderer, g = this.element;
if (P && (this.parentGroup = P), this.parentInverted = P && P.inverted, typeof this.textStr < "u" && this.element.nodeName === "text" && X.buildText(this), this.added = !0, !P || P.handleZ || this.zIndex)
var m = this.zIndexSetter();
return m || (P ? P.element : X.box).appendChild(g), this.onAdd && this.onAdd(), this;
}, W.prototype.addClass = function(P, X) {
var g = X ? "" : this.attr("class") || "";
return P = (P || "").split(/ /g).reduce(function(m, L) {
return g.indexOf(L) === -1 && m.push(L), m;
}, g ? [g] : []).join(" "), P !== g && this.attr("class", P), this;
}, W.prototype.afterSetters = function() {
this.doTransform && (this.updateTransform(), this.doTransform = !1);
}, W.prototype.align = function(P, X, g) {
var m = {}, L = this.renderer, Y = L.alignedObjects, V, Q, k;
P ? (this.alignOptions = P, this.alignByTranslate = X, (!g || o(g)) && (this.alignTo = V = g || "renderer", x(Y, this), Y.push(this), g = void 0)) : (P = this.alignOptions, X = this.alignByTranslate, V = this.alignTo), g = n(g, L[V], V === "scrollablePlotBox" ? L.plotBox : void 0, L), V = P.align;
var G = P.verticalAlign;
return L = (g.x || 0) + (P.x || 0), Y = (g.y || 0) + (P.y || 0), V === "right" ? Q = 1 : V === "center" && (Q = 2), Q && (L += (g.width - (P.width || 0)) / Q), m[X ? "translateX" : "x"] = Math.round(L), G === "bottom" ? k = 1 : G === "middle" && (k = 2), k && (Y += (g.height - (P.height || 0)) / k), m[X ? "translateY" : "y"] = Math.round(Y), this[this.placed ? "animate" : "attr"](m), this.placed = !0, this.alignAttr = m, this;
}, W.prototype.alignSetter = function(P) {
var X = { left: "start", center: "middle", right: "end" };
X[P] && (this.alignValue = P, this.element.setAttribute(
"text-anchor",
X[P]
));
}, W.prototype.animate = function(P, X, g) {
var m = this, L = F(n(X, this.renderer.globalAnimation, !0));
return X = L.defer, n(S.hidden, S.msHidden, S.webkitHidden, !1) && (L.duration = 0), L.duration !== 0 ? (g && (L.complete = g), _(function() {
m.element && U(m, P, L);
}, X)) : (this.attr(P, void 0, g), s(P, function(Y, V) {
L.step && L.step.call(this, Y, { prop: V, pos: 1, elem: this });
}, this)), this;
}, W.prototype.applyTextOutline = function(P) {
var X = this.element;
P.indexOf("contrast") !== -1 && (P = P.replace(/contrast/g, this.renderer.getContrast(X.style.fill)));
var g = P.split(" ");
if (P = g[g.length - 1], (g = g[0]) && g !== "none" && Z.svg) {
this.fakeTS = !0, this.ySetter = this.xSetter, g = g.replace(/(^[\d\.]+)(.*?)$/g, function(Y, V, Q) {
return 2 * Number(V) + Q;
}), this.removeTextOutline();
var m = S.createElementNS(u, "tspan");
B(m, { class: "highcharts-text-outline", fill: P, stroke: P, "stroke-width": g, "stroke-linejoin": "round" }), [].forEach.call(X.childNodes, function(Y) {
var V = Y.cloneNode(!0);
V.removeAttribute && ["fill", "stroke", "stroke-width", "stroke"].forEach(function(Q) {
return V.removeAttribute(Q);
}), m.appendChild(V);
});
var L = S.createElementNS(u, "tspan");
L.textContent = "", ["x", "y"].forEach(function(Y) {
var V = X.getAttribute(Y);
V && L.setAttribute(Y, V);
}), m.appendChild(L), X.insertBefore(m, X.firstChild);
}
}, W.prototype.attr = function(P, X, g, m) {
var L = this.element, Y = this.symbolCustomAttribs, V, Q = this, k, G;
if (typeof P == "string" && typeof X < "u") {
var z = P;
P = {}, P[z] = X;
}
return typeof P == "string" ? Q = (this[P + "Getter"] || this._defaultGetter).call(this, P, L) : (s(P, function($, q) {
k = !1, m || N(this, q), this.symbolName && Y.indexOf(q) !== -1 && (V || (this.symbolAttr(P), V = !0), k = !0), !this.rotation || q !== "x" && q !== "y" || (this.doTransform = !0), k || (G = this[q + "Setter"] || this._defaultSetter, G.call(this, $, q, L), !this.styledMode && this.shadows && /^(width|height|visibility|x|y|d|transform|cx|cy|r)$/.test(q) && this.updateShadows(q, $, G));
}, this), this.afterSetters()), g && g.call(this), Q;
}, W.prototype.clip = function(P) {
return this.attr("clip-path", P ? "url(" + this.renderer.url + "#" + P.id + ")" : "none");
}, W.prototype.crisp = function(P, X) {
X = X || P.strokeWidth || 0;
var g = Math.round(X) % 2 / 2;
return P.x = Math.floor(P.x || this.x || 0) + g, P.y = Math.floor(P.y || this.y || 0) + g, P.width = Math.floor((P.width || this.width || 0) - 2 * g), P.height = Math.floor((P.height || this.height || 0) - 2 * g), w(P.strokeWidth) && (P.strokeWidth = X), P;
}, W.prototype.complexColor = function(P, X, g) {
var m = this.renderer, L, Y, V, Q, k, G, z, $, q, it, et = [], nt;
c(this.renderer, "complexColor", { args: arguments }, function() {
if (P.radialGradient ? Y = "radialGradient" : P.linearGradient && (Y = "linearGradient"), Y) {
if (V = P[Y], k = m.gradients, G = P.stops, q = g.radialReference, p(V) && (P[Y] = V = { x1: V[0], y1: V[1], x2: V[2], y2: V[3], gradientUnits: "userSpaceOnUse" }), Y === "radialGradient" && q && !w(V.gradientUnits) && (Q = V, V = t(V, m.getRadialAttr(q, Q), { gradientUnits: "userSpaceOnUse" })), s(V, function(ct, gt) {
gt !== "id" && et.push(gt, ct);
}), s(G, function(ct) {
et.push(ct);
}), et = et.join(","), k[et])
it = k[et].attr("id");
else {
V.id = it = D();
var rt = k[et] = m.createElement(Y).attr(V).add(m.defs);
rt.radAttr = Q, rt.stops = [], G.forEach(function(ct) {
ct[1].indexOf("rgba") === 0 ? (L = I.parse(ct[1]), z = L.get("rgb"), $ = L.get("a")) : (z = ct[1], $ = 1), ct = m.createElement("stop").attr({
offset: ct[0],
"stop-color": z,
"stop-opacity": $
}).add(rt), rt.stops.push(ct);
});
}
nt = "url(" + m.url + "#" + it + ")", g.setAttribute(X, nt), g.gradient = et, P.toString = function() {
return nt;
};
}
});
}, W.prototype.css = function(P) {
var X = this.styles, g = {}, m = this.element, L = ["textOutline", "textOverflow", "width"], Y = "", V = !X;
if (P && P.color && (P.fill = P.color), X && s(P, function(G, z) {
X && X[z] !== G && (g[z] = G, V = !0);
}), V) {
if (X && (P = a(X, g)), P) {
if (P.width === null || P.width === "auto")
delete this.textWidth;
else if (m.nodeName.toLowerCase() === "text" && P.width)
var Q = this.textWidth = A(P.width);
}
if (this.styles = P, Q && !d && this.renderer.forExport && delete P.width, m.namespaceURI === this.SVG_NS) {
var k = function(G, z) {
return "-" + z.toLowerCase();
};
s(P, function(G, z) {
L.indexOf(z) === -1 && (Y += z.replace(/([A-Z])/g, k) + ":" + G + ";");
}), Y && B(m, "style", Y);
} else
b(m, P);
this.added && (this.element.nodeName === "text" && this.renderer.buildText(this), P && P.textOutline && this.applyTextOutline(P.textOutline));
}
return this;
}, W.prototype.dashstyleSetter = function(P) {
var X = this["stroke-width"];
if (X === "inherit" && (X = 1), P = P && P.toLowerCase()) {
var g = P.replace("shortdashdotdot", "3,1,1,1,1,1,").replace("shortdashdot", "3,1,1,1").replace("shortdot", "1,1,").replace("shortdash", "3,1,").replace("longdash", "8,3,").replace(/dot/g, "1,3,").replace("dash", "4,3,").replace(/,$/, "").split(",");
for (P = g.length; P--; )
g[P] = "" + A(g[P]) * n(X, NaN);
P = g.join(",").replace(/NaN/g, "none"), this.element.setAttribute("stroke-dasharray", P);
}
}, W.prototype.destroy = function() {
var P = this, X = P.element || {}, g = P.renderer, m = X.ownerSVGElement, L = g.isSVG && X.nodeName === "SPAN" && P.parentGroup || void 0;
if (X.onclick = X.onmouseout = X.onmouseover = X.onmousemove = X.point = null, N(P), P.clipPath && m) {
var Y = P.clipPath;
[].forEach.call(m.querySelectorAll("[clip-path],[CLIP-PATH]"), function(V) {
-1 < V.getAttribute("clip-path").indexOf(Y.element.id) && V.removeAttribute("clip-path");
}), P.clipPath = Y.destroy();
}
if (P.stops) {
for (m = 0; m < P.stops.length; m++)
P.stops[m].destroy();
P.stops.length = 0, P.stops = void 0;
}
for (P.safeRemoveChild(X), g.styledMode || P.destroyShadows(); L && L.div && L.div.childNodes.length === 0; )
X = L.parentGroup, P.safeRemoveChild(L.div), delete L.div, L = X;
P.alignTo && x(g.alignedObjects, P), s(P, function(V, Q) {
P[Q] && P[Q].parentGroup === P && P[Q].destroy && P[Q].destroy(), delete P[Q];
});
}, W.prototype.destroyShadows = function() {
(this.shadows || []).forEach(function(P) {
this.safeRemoveChild(P);
}, this), this.shadows = void 0;
}, W.prototype.destroyTextPath = function(P, X) {
var g = P.getElementsByTagName("text")[0];
if (g) {
if (g.removeAttribute("dx"), g.removeAttribute("dy"), X.element.setAttribute("id", ""), this.textPathWrapper && g.getElementsByTagName("textPath").length) {
for (P = this.textPathWrapper.element.childNodes; P.length; )
g.appendChild(P[0]);
g.removeChild(this.textPathWrapper.element);
}
} else
(P.getAttribute("dx") || P.getAttribute("dy")) && (P.removeAttribute("dx"), P.removeAttribute("dy"));
this.textPathWrapper && (this.textPathWrapper = this.textPathWrapper.destroy());
}, W.prototype.dSetter = function(P, X, g) {
p(P) && (typeof P[0] == "string" && (P = this.renderer.pathToSegments(P)), this.pathArray = P, P = P.reduce(function(m, L, Y) {
return L && L.join ? (Y ? m + " " : "") + L.join(" ") : (L || "").toString();
}, "")), /(NaN| {2}|^$)/.test(P) && (P = "M 0 0"), this[X] !== P && (g.setAttribute(X, P), this[X] = P);
}, W.prototype.fadeOut = function(P) {
var X = this;
X.animate({ opacity: 0 }, { duration: n(P, 150), complete: function() {
X.attr({ y: -9999 }).hide();
} });
}, W.prototype.fillSetter = function(P, X, g) {
typeof P == "string" ? g.setAttribute(X, P) : P && this.complexColor(P, X, g);
}, W.prototype.getBBox = function(P, X) {
var g = this.renderer, m = this.element, L = this.styles, Y = this.textStr, V = g.cache, Q = g.cacheKeys, k = m.namespaceURI === this.SVG_NS;
X = n(X, this.rotation, 0);
var G = g.styledMode ? m && W.prototype.getStyle.call(m, "font-size") : L && L.fontSize, z;
if (w(Y)) {
var $ = Y.toString();
$.indexOf("<") === -1 && ($ = $.replace(/[0-9]/g, "0")), $ += ["", X, G, this.textWidth, L && L.textOverflow, L && L.fontWeight].join();
}
if ($ && !P && (z = V[$]), !z) {
if (k || g.forExport) {
try {
var q = this.fakeTS && function(it) {
var et = m.querySelector(".highcharts-text-outline");
et && b(et, { display: it });
};
i(q) && q("none"), z = m.getBBox ? a({}, m.getBBox()) : { width: m.offsetWidth, height: m.offsetHeight }, i(q) && q("");
} catch {
}
(!z || 0 > z.width) && (z = {
width: 0,
height: 0
});
} else
z = this.htmlGetBBox();
if (g.isSVG && (P = z.width, g = z.height, k && (z.height = g = { "11px,17": 14, "13px,20": 16 }[(G || "") + "," + Math.round(g)] || g), X && (k = X * R, z.width = Math.abs(g * Math.sin(k)) + Math.abs(P * Math.cos(k)), z.height = Math.abs(g * Math.cos(k)) + Math.abs(P * Math.sin(k)))), $ && (Y === "" || 0 < z.height)) {
for (; 250 < Q.length; )
delete V[Q.shift()];
V[$] || Q.push($), V[$] = z;
}
}
return z;
}, W.prototype.getStyle = function(P) {
return T.getComputedStyle(this.element || this, "").getPropertyValue(P);
}, W.prototype.hasClass = function(P) {
return ("" + this.attr("class")).split(" ").indexOf(P) !== -1;
}, W.prototype.hide = function(P) {
return P ? this.attr({ y: -9999 }) : this.attr({ visibility: "hidden" }), this;
}, W.prototype.htmlGetBBox = function() {
return { height: 0, width: 0, x: 0, y: 0 };
}, W.prototype.init = function(P, X) {
this.element = X === "span" ? C(X) : S.createElementNS(this.SVG_NS, X), this.renderer = P, c(this, "afterInit");
}, W.prototype.invert = function(P) {
return this.inverted = P, this.updateTransform(), this;
}, W.prototype.on = function(P, X) {
var g = this.onEvents;
return g[P] && g[P](), g[P] = O(
this.element,
P,
X
), this;
}, W.prototype.opacitySetter = function(P, X, g) {
this.opacity = P = Number(Number(P).toFixed(3)), g.setAttribute(X, P);
}, W.prototype.removeClass = function(P) {
return this.attr("class", ("" + this.attr("class")).replace(o(P) ? new RegExp("(^| )" + P + "( |$)") : P, " ").replace(/ +/g, " ").trim());
}, W.prototype.removeTextOutline = function() {
var P = this.element.querySelector("tspan.highcharts-text-outline");
P && this.safeRemoveChild(P);
}, W.prototype.safeRemoveChild = function(P) {
var X = P.parentNode;
X && X.removeChild(P);
}, W.prototype.setRadialReference = function(P) {
var X = this.element.gradient && this.renderer.gradients[this.element.gradient];
return this.element.radialReference = P, X && X.radAttr && X.animate(this.renderer.getRadialAttr(P, X.radAttr)), this;
}, W.prototype.setTextPath = function(P, X) {
var g = this.element, m = this.text ? this.text.element : g, L = { textAnchor: "text-anchor" }, Y = !1, V = this.textPathWrapper, Q = !V;
X = t(!0, { enabled: !0, attributes: { dy: -5, startOffset: "50%", textAnchor: "middle" } }, X);
var k = j.filterUserAttributes(X.attributes);
if (P && X && X.enabled) {
V && V.element.parentNode === null ? (Q = !0, V = V.destroy()) : V && this.removeTextOutline.call(V.parentGroup), this.options && this.options.padding && (k.dx = -this.options.padding), V || (this.textPathWrapper = V = this.renderer.createElement("textPath"), Y = !0);
var G = V.element;
if ((X = P.element.getAttribute("id")) || P.element.setAttribute("id", X = D()), Q)
for (m.setAttribute("y", 0), h(k.dx) && m.setAttribute("x", -k.dx), P = [].slice.call(m.childNodes), Q = 0; Q < P.length; Q++) {
var z = P[Q];
z.nodeType !== T.Node.TEXT_NODE && z.nodeName !== "tspan" || G.appendChild(z);
}
Y && V && V.add({ element: m }), G.setAttributeNS("http://www.w3.org/1999/xlink", "href", this.renderer.url + "#" + X), w(k.dy) && (G.parentNode.setAttribute("dy", k.dy), delete k.dy), w(k.dx) && (G.parentNode.setAttribute("dx", k.dx), delete k.dx), s(k, function($, q) {
G.setAttribute(L[q] || q, $);
}), g.removeAttribute("transform"), this.removeTextOutline.call(V), this.text && !this.renderer.styledMode && this.attr({ fill: "none", "stroke-width": 0 }), this.applyTextOutline = this.updateTransform = v;
} else
V && (delete this.updateTransform, delete this.applyTextOutline, this.destroyTextPath(g, P), this.updateTransform(), this.options && this.options.rotation && this.applyTextOutline(this.options.style.textOutline));
return this;
}, W.prototype.shadow = function(P, X, g) {
var m = [], L = this.element, Y = this.oldShadowOptions, V = { color: "#000000", offsetX: this.parentInverted ? -1 : 1, offsetY: this.parentInverted ? -1 : 1, opacity: 0.15, width: 3 }, Q = !1, k;
if (P === !0 ? k = V : typeof P == "object" && (k = a(V, P)), k && (k && Y && s(k, function(it, et) {
it !== Y[et] && (Q = !0);
}), Q && this.destroyShadows(), this.oldShadowOptions = k), !k)
this.destroyShadows();
else if (!this.shadows) {
var G = k.opacity / k.width, z = this.parentInverted ? "translate(" + k.offsetY + ", " + k.offsetX + ")" : "translate(" + k.offsetX + ", " + k.offsetY + ")";
for (V = 1; V <= k.width; V++) {
var $ = L.cloneNode(!1), q = 2 * k.width + 1 - 2 * V;
B($, { stroke: P.color || "#000000", "stroke-opacity": G * V, "stroke-width": q, transform: z, fill: "none" }), $.setAttribute("class", ($.getAttribute("class") || "") + " highcharts-shadow"), g && (B($, "height", Math.max(B($, "height") - q, 0)), $.cutHeight = q), X ? X.element.appendChild($) : L.parentNode && L.parentNode.insertBefore($, L), m.push($);
}
this.shadows = m;
}
return this;
}, W.prototype.show = function(P) {
return this.attr({ visibility: P ? "inherit" : "visible" });
}, W.prototype.strokeSetter = function(P, X, g) {
this[X] = P, this.stroke && this["stroke-width"] ? (W.prototype.fillSetter.call(this, this.stroke, "stroke", g), g.setAttribute("stroke-width", this["stroke-width"]), this.hasStroke = !0) : X === "stroke-width" && P === 0 && this.hasStroke ? (g.removeAttribute("stroke"), this.hasStroke = !1) : this.renderer.styledMode && this["stroke-width"] && (g.setAttribute("stroke-width", this["stroke-width"]), this.hasStroke = !0);
}, W.prototype.strokeWidth = function() {
if (!this.renderer.styledMode)
return this["stroke-width"] || 0;
var P = this.getStyle("stroke-width"), X = 0;
if (P.indexOf("px") === P.length - 2)
X = A(P);
else if (P !== "") {
var g = S.createElementNS(u, "rect");
B(g, { width: P, "stroke-width": 0 }), this.element.parentNode.appendChild(g), X = g.getBBox().width, g.parentNode.removeChild(g);
}
return X;
}, W.prototype.symbolAttr = function(P) {
var X = this;
"x y r start end width height innerR anchorX anchorY clockwise".split(" ").forEach(function(g) {
X[g] = n(P[g], X[g]);
}), X.attr({ d: X.renderer.symbols[X.symbolName](X.x, X.y, X.width, X.height, X) });
}, W.prototype.textSetter = function(P) {
P !== this.textStr && (delete this.textPxLength, this.textStr = P, this.added && this.renderer.buildText(this));
}, W.prototype.titleSetter = function(P) {
var X = this.element, g = X.getElementsByTagName("title")[0] || S.createElementNS(this.SVG_NS, "title");
X.insertBefore ? X.insertBefore(g, X.firstChild) : X.appendChild(g), g.textContent = String(n(P, "")).replace(/<[^>]*>/g, "").replace(/</g, "<").replace(
/>/g,
">"
);
}, W.prototype.toFront = function() {
var P = this.element;
return P.parentNode.appendChild(P), this;
}, W.prototype.translate = function(P, X) {
return this.attr({ translateX: P, translateY: X });
}, W.prototype.updateShadows = function(P, X, g) {
var m = this.shadows;
if (m)
for (var L = m.length; L--; )
g.call(m[L], P === "height" ? Math.max(X - (m[L].cutHeight || 0), 0) : P === "d" ? this.d : X, P, m[L]);
}, W.prototype.updateTransform = function() {
var P = this.scaleX, X = this.scaleY, g = this.inverted, m = this.rotation, L = this.matrix, Y = this.element, V = this.translateX || 0, Q = this.translateY || 0;
g && (V += this.width, Q += this.height), V = ["translate(" + V + "," + Q + ")"], w(L) && V.push("matrix(" + L.join(",") + ")"), g ? V.push("rotate(90) scale(-1,1)") : m && V.push("rotate(" + m + " " + n(this.rotationOriginX, Y.getAttribute("x"), 0) + " " + n(this.rotationOriginY, Y.getAttribute("y") || 0) + ")"), (w(P) || w(X)) && V.push("scale(" + n(P, 1) + " " + n(X, 1) + ")"), V.length && Y.setAttribute("transform", V.join(" "));
}, W.prototype.visibilitySetter = function(P, X, g) {
P === "inherit" ? g.removeAttribute(X) : this[X] !== P && g.setAttribute(
X,
P
), this[X] = P;
}, W.prototype.xGetter = function(P) {
return this.element.nodeName === "circle" && (P === "x" ? P = "cx" : P === "y" && (P = "cy")), this._defaultGetter(P);
}, W.prototype.zIndexSetter = function(P, X) {
var g = this.renderer, m = this.parentGroup, L = (m || g).element || g.box, Y = this.element;
g = L === g.box;
var V = !1, Q = this.added, k;
if (w(P) ? (Y.setAttribute("data-z-index", P), P = +P, this[X] === P && (Q = !1)) : w(this[X]) && Y.removeAttribute("data-z-index"), this[X] = P, Q) {
for ((P = this.zIndex) && m && (m.handleZ = !0), X = L.childNodes, k = X.length - 1; 0 <= k && !V; k--) {
m = X[k], Q = m.getAttribute("data-z-index");
var G = !w(Q);
m !== Y && (0 > P && G && !g && !k ? (L.insertBefore(Y, X[k]), V = !0) : (A(Q) <= P || G && (!w(P) || 0 <= P)) && (L.insertBefore(Y, X[k + 1] || null), V = !0));
}
V || (L.insertBefore(Y, X[g ? 3 : 0] || null), V = !0);
}
return V;
}, W;
}(), y.prototype["stroke-widthSetter"] = y.prototype.strokeSetter, y.prototype.yGetter = y.prototype.xGetter, y.prototype.matrixSetter = y.prototype.rotationOriginXSetter = y.prototype.rotationOriginYSetter = y.prototype.rotationSetter = y.prototype.scaleXSetter = y.prototype.scaleYSetter = y.prototype.translateXSetter = y.prototype.translateYSetter = y.prototype.verticalAlignSetter = function(W, P) {
this[P] = W, this.doTransform = !0;
}, y;
}), E(l, "Core/Renderer/RendererRegistry.js", [l["Core/Globals.js"]], function(y) {
var j;
return function(I) {
I.rendererTypes = {};
var Z;
I.getRendererType = function(H) {
return H === void 0 && (H = Z), I.rendererTypes[H] || I.rendererTypes[Z];
}, I.registerRendererType = function(H, U, F) {
I.rendererTypes[H] = U, (!Z || F) && (Z = H, y.Renderer = U);
};
}(j || (j = {})), j;
}), E(
l,
"Core/Renderer/SVG/SVGLabel.js",
[l["Core/Renderer/SVG/SVGElement.js"], l["Core/Utilities.js"]],
function(y, j) {
var I = this && this.__extends || function() {
var S = function(v, d) {
return S = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(u, T) {
u.__proto__ = T;
} || function(u, T) {
for (var O in T)
T.hasOwnProperty(O) && (u[O] = T[O]);
}, S(v, d);
};
return function(v, d) {
function u() {
this.constructor = v;
}
S(v, d), v.prototype = d === null ? Object.create(d) : (u.prototype = d.prototype, new u());
};
}(), Z = j.defined, H = j.extend, U = j.isNumber, F = j.merge, N = j.pick, R = j.removeEvent;
return function(S) {
function v(d, u, T, O, B, C, b, w, x, a) {
var c = S.call(this) || this;
c.paddingLeftSetter = c.paddingSetter, c.paddingRightSetter = c.paddingSetter, c.init(d, "g"), c.textStr = u, c.x = T, c.y = O, c.anchorX = C, c.anchorY = b, c.baseline = x, c.className = a, c.addClass(a === "button" ? "highcharts-no-tooltip" : "highcharts-label"), a && c.addClass("highcharts-" + a), c.text = d.text(void 0, 0, 0, w).attr({ zIndex: 1 });
var p;
return typeof B == "string" && ((p = /^url\((.*?)\)$/.test(B)) || c.renderer.symbols[B]) && (c.symbolKey = B), c.bBox = v.emptyBBox, c.padding = 3, c.baselineOffset = 0, c.needsBox = d.styledMode || p, c.deferredAttr = {}, c.alignFactor = 0, c;
}
return I(v, S), v.prototype.alignSetter = function(d) {
d = { left: 0, center: 0.5, right: 1 }[d], d !== this.alignFactor && (this.alignFactor = d, this.bBox && U(this.xSetting) && this.attr({ x: this.xSetting }));
}, v.prototype.anchorXSetter = function(d, u) {
this.anchorX = d, this.boxAttr(u, Math.round(d) - this.getCrispAdjust() - this.xSetting);
}, v.prototype.anchorYSetter = function(d, u) {
this.anchorY = d, this.boxAttr(u, d - this.ySetting);
}, v.prototype.boxAttr = function(d, u) {
this.box ? this.box.attr(d, u) : this.deferredAttr[d] = u;
}, v.prototype.css = function(d) {
if (d) {
var u = {};
d = F(d), v.textProps.forEach(function(O) {
typeof d[O] < "u" && (u[O] = d[O], delete d[O]);
}), this.text.css(u);
var T = "width" in u;
"fontSize" in u || "fontWeight" in u ? this.updateTextPadding() : T && this.updateBoxSize();
}
return y.prototype.css.call(this, d);
}, v.prototype.destroy = function() {
R(this.element, "mouseenter"), R(this.element, "mouseleave"), this.text && this.text.destroy(), this.box && (this.box = this.box.destroy()), y.prototype.destroy.call(this);
}, v.prototype.fillSetter = function(d, u) {
d && (this.needsBox = !0), this.fill = d, this.boxAttr(u, d);
}, v.prototype.getBBox = function() {
this.textStr && this.bBox.width === 0 && this.bBox.height === 0 && this.updateBoxSize();
var d = this.padding, u = N(this.paddingLeft, d);
return { width: this.width, height: this.height, x: this.bBox.x - u, y: this.bBox.y - d };
}, v.prototype.getCrispAdjust = function() {
return this.renderer.styledMode && this.box ? this.box.strokeWidth() % 2 / 2 : (this["stroke-width"] ? parseInt(
this["stroke-width"],
10
) : 0) % 2 / 2;
}, v.prototype.heightSetter = function(d) {
this.heightSetting = d;
}, v.prototype.onAdd = function() {
var d = this.textStr;
this.text.add(this), this.attr({ text: Z(d) ? d : "", x: this.x, y: this.y }), this.box && Z(this.anchorX) && this.attr({ anchorX: this.anchorX, anchorY: this.anchorY });
}, v.prototype.paddingSetter = function(d, u) {
U(d) ? d !== this[u] && (this[u] = d, this.updateTextPadding()) : this[u] = void 0;
}, v.prototype.rSetter = function(d, u) {
this.boxAttr(u, d);
}, v.prototype.shadow = function(d) {
return d && !this.renderer.styledMode && (this.updateBoxSize(), this.box && this.box.shadow(d)), this;
}, v.prototype.strokeSetter = function(d, u) {
this.stroke = d, this.boxAttr(u, d);
}, v.prototype["stroke-widthSetter"] = function(d, u) {
d && (this.needsBox = !0), this["stroke-width"] = d, this.boxAttr(u, d);
}, v.prototype["text-alignSetter"] = function(d) {
this.textAlign = d;
}, v.prototype.textSetter = function(d) {
typeof d < "u" && this.text.attr({ text: d }), this.updateTextPadding();
}, v.prototype.updateBoxSize = function() {
var d = this.text.element.style, u = {}, T = this.padding, O = this.bBox = U(this.widthSetting) && U(this.heightSetting) && !this.textAlign || !Z(this.text.textStr) ? v.emptyBBox : this.text.getBBox();
this.width = this.getPaddedWidth(), this.height = (this.heightSetting || O.height || 0) + 2 * T, d = this.renderer.fontMetrics(d && d.fontSize, this.text), this.baselineOffset = T + Math.min((this.text.firstLineMetrics || d).b, O.height || 1 / 0), this.heightSetting && (this.baselineOffset += (this.heightSetting - d.h) / 2), this.needsBox && (this.box || (T = this.box = this.symbolKey ? this.renderer.symbol(this.symbolKey) : this.renderer.rect(), T.addClass((this.className === "button" ? "" : "highcharts-label-box") + (this.className ? " highcharts-" + this.className + "-box" : "")), T.add(this)), T = this.getCrispAdjust(), u.x = T, u.y = (this.baseline ? -this.baselineOffset : 0) + T, u.width = Math.round(this.width), u.height = Math.round(this.height), this.box.attr(H(u, this.deferredAttr)), this.deferredAttr = {});
}, v.prototype.updateTextPadding = function() {
var d = this.text;
this.updateBoxSize();
var u = this.baseline ? 0 : this.baselineOffset, T = N(this.paddingLeft, this.padding);
Z(this.widthSetting) && this.bBox && (this.textAlign === "center" || this.textAlign === "right") && (T += { center: 0.5, right: 1 }[this.textAlign] * (this.widthSetting - this.bBox.width)), (T !== d.x || u !== d.y) && (d.attr("x", T), d.hasBoxWidthChanged && (this.bBox = d.getBBox(!0)), typeof u < "u" && d.attr("y", u)), d.x = T, d.y = u;
}, v.prototype.widthSetter = function(d) {
this.widthSetting = U(d) ? d : void 0;
}, v.prototype.getPaddedWidth = function() {
var d = this.padding, u = N(this.paddingLeft, d);
return d = N(this.paddingRight, d), (this.widthSetting || this.bBox.width || 0) + u + d;
}, v.prototype.xSetter = function(d) {
this.x = d, this.alignFactor && (d -= this.alignFactor * this.getPaddedWidth(), this["forceAnimate:x"] = !0), this.xSetting = Math.round(d), this.attr("translateX", this.xSetting);
}, v.prototype.ySetter = function(d) {
this.ySetting = this.y = Math.round(d), this.attr("translateY", this.ySetting);
}, v.emptyBBox = { width: 0, height: 0, x: 0, y: 0 }, v.textProps = "color direction fontFamily fontSize fontStyle fontWeight lineHeight textAlign textDecoration textOutline textOverflow width".split(" "), v;
}(y);
}
), E(
l,
"Core/Renderer/SVG/Symbols.js",
[l["Core/Utilities.js"]],
function(y) {
function j(N, R, S, v, d) {
var u = [];
if (d) {
var T = d.start || 0, O = F(d.r, S);
S = F(d.r, v || S);
var B = (d.end || 0) - 1e-3;
v = d.innerR;
var C = F(d.open, 1e-3 > Math.abs((d.end || 0) - T - 2 * Math.PI)), b = Math.cos(T), w = Math.sin(T), x = Math.cos(B), a = Math.sin(B);
T = F(d.longArc, 1e-3 > B - T - Math.PI ? 0 : 1), u.push(["M", N + O * b, R + S * w], ["A", O, S, 0, T, F(d.clockwise, 1), N + O * x, R + S * a]), H(v) && u.push(C ? ["M", N + v * x, R + v * a] : ["L", N + v * x, R + v * a], ["A", v, v, 0, T, H(d.clockwise) ? 1 - d.clockwise : 0, N + v * b, R + v * w]), C || u.push(["Z"]);
}
return u;
}
function I(N, R, S, v, d) {
return d && d.r ? Z(N, R, S, v, d) : [["M", N, R], ["L", N + S, R], ["L", N + S, R + v], ["L", N, R + v], ["Z"]];
}
function Z(N, R, S, v, d) {
return d = d && d.r || 0, [["M", N + d, R], ["L", N + S - d, R], ["C", N + S, R, N + S, R, N + S, R + d], ["L", N + S, R + v - d], ["C", N + S, R + v, N + S, R + v, N + S - d, R + v], ["L", N + d, R + v], ["C", N, R + v, N, R + v, N, R + v - d], ["L", N, R + d], ["C", N, R, N, R, N + d, R]];
}
var H = y.defined, U = y.isNumber, F = y.pick;
return { arc: j, callout: function(N, R, S, v, d) {
var u = Math.min(d && d.r || 0, S, v), T = u + 6, O = d && d.anchorX;
d = d && d.anchorY || 0;
var B = Z(N, R, S, v, { r: u });
return U(O) && (N + O >= S ? d > R + T && d < R + v - T ? B.splice(3, 1, ["L", N + S, d - 6], ["L", N + S + 6, d], ["L", N + S, d + 6], ["L", N + S, R + v - u]) : B.splice(3, 1, ["L", N + S, v / 2], ["L", O, d], ["L", N + S, v / 2], ["L", N + S, R + v - u]) : 0 >= N + O ? d > R + T && d < R + v - T ? B.splice(7, 1, ["L", N, d + 6], ["L", N - 6, d], ["L", N, d - 6], ["L", N, R + u]) : B.splice(7, 1, ["L", N, v / 2], ["L", O, d], ["L", N, v / 2], ["L", N, R + u]) : d && d > v && O > N + T && O < N + S - T ? B.splice(5, 1, ["L", O + 6, R + v], ["L", O, R + v + 6], ["L", O - 6, R + v], ["L", N + u, R + v]) : d && 0 > d && O > N + T && O < N + S - T && B.splice(1, 1, ["L", O - 6, R], ["L", O, R - 6], ["L", O + 6, R], ["L", S - u, R])), B;
}, circle: function(N, R, S, v) {
return j(N + S / 2, R + v / 2, S / 2, v / 2, { start: 0.5 * Math.PI, end: 2.5 * Math.PI, open: !1 });
}, diamond: function(N, R, S, v) {
return [["M", N + S / 2, R], ["L", N + S, R + v / 2], ["L", N + S / 2, R + v], ["L", N, R + v / 2], ["Z"]];
}, rect: I, roundedRect: Z, square: I, triangle: function(N, R, S, v) {
return [["M", N + S / 2, R], ["L", N + S, R + v], ["L", N, R + v], ["Z"]];
}, "triangle-down": function(N, R, S, v) {
return [["M", N, R], ["L", N + S, R], ["L", N + S / 2, R + v], ["Z"]];
} };
}
), E(l, "Core/Renderer/SVG/TextBuilder.js", [l["Core/Renderer/HTML/AST.js"], l["Core/Globals.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = j.doc, H = j.SVG_NS, U = j.win, F = I.attr, N = I.isString, R = I.objectEach, S = I.pick;
return function() {
function v(d) {
var u = d.styles;
this.renderer = d.renderer, this.svgElement = d, this.width = d.textWidth, this.textLineHeight = u && u.lineHeight, this.textOutline = u && u.textOutline, this.ellipsis = !(!u || u.textOverflow !== "ellipsis"), this.noWrap = !(!u || u.whiteSpace !== "nowrap"), this.fontSize = u && u.fontSize;
}
return v.prototype.buildSVG = function() {
var d = this.svgElement, u = d.element, T = d.renderer, O = S(d.textStr, "").toString(), B = O.indexOf("<") !== -1, C = u.childNodes;
T = this.width && !d.added && T.box;
var b = //g, w = [O, this.ellipsis, this.noWrap, this.textLineHeight, this.textOutline, this.fontSize, this.width].join();
if (w !== d.textCache) {
for (d.textCache = w, delete d.actualWidth, w = C.length; w--; )
u.removeChild(C[w]);
B || this.ellipsis || this.width || O.indexOf(" ") !== -1 && (!this.noWrap || b.test(O)) ? O !== "" && (T && T.appendChild(u), O = new y(O), this.modifyTree(O.nodes), O.addToDOM(d.element), this.modifyDOM(), this.ellipsis && (u.textContent || "").indexOf("…") !== -1 && d.attr(
"title",
this.unescapeEntities(d.textStr || "", ["<", ">"])
), T && T.removeChild(u)) : u.appendChild(Z.createTextNode(this.unescapeEntities(O))), N(this.textOutline) && d.applyTextOutline && d.applyTextOutline(this.textOutline);
}
}, v.prototype.modifyDOM = function() {
var d = this, u = this.svgElement, T = F(u.element, "x");
u.firstLineMetrics = void 0;
for (var O; (O = u.element.firstChild) && /^[\s\u200B]*$/.test(O.textContent || " "); )
u.element.removeChild(O);
[].forEach.call(u.element.querySelectorAll("tspan.highcharts-br"), function(w, x) {
w.nextSibling && w.previousSibling && (x === 0 && w.previousSibling.nodeType === 1 && (u.firstLineMetrics = u.renderer.fontMetrics(void 0, w.previousSibling)), F(w, { dy: d.getLineHeight(w.nextSibling), x: T }));
});
var B = this.width || 0;
if (B) {
var C = function(w, x) {
var a = w.textContent || "", c = a.replace(/([^\^])-/g, "$1- ").split(" "), p = !d.noWrap && (1 < c.length || 1 < u.element.childNodes.length), i = d.getLineHeight(x), h = 0, o = u.actualWidth;
if (d.ellipsis)
a && d.truncate(w, a, void 0, 0, Math.max(0, B - parseInt(d.fontSize || 12, 10)), function(t, s) {
return t.substring(
0,
s
) + "…";
});
else if (p) {
for (a = [], p = []; x.firstChild && x.firstChild !== w; )
p.push(x.firstChild), x.removeChild(x.firstChild);
for (; c.length; )
c.length && !d.noWrap && 0 < h && (a.push(w.textContent || ""), w.textContent = c.join(" ").replace(/- /g, "-")), d.truncate(w, void 0, c, h === 0 && o || 0, B, function(t, s) {
return c.slice(0, s).join(" ").replace(/- /g, "-");
}), o = u.actualWidth, h++;
p.forEach(function(t) {
x.insertBefore(t, w);
}), a.forEach(function(t) {
x.insertBefore(Z.createTextNode(t), w), t = Z.createElementNS(H, "tspan"), t.textContent = "", F(t, { dy: i, x: T }), x.insertBefore(t, w);
});
}
}, b = function(w) {
[].slice.call(w.childNodes).forEach(function(x) {
x.nodeType === U.Node.TEXT_NODE ? C(x, w) : (x.className.baseVal.indexOf("highcharts-br") !== -1 && (u.actualWidth = 0), b(x));
});
};
b(u.element);
}
}, v.prototype.getLineHeight = function(d) {
var u;
return d = d.nodeType === U.Node.TEXT_NODE ? d.parentElement : d, this.renderer.styledMode || (u = d && /(px|em)$/.test(d.style.fontSize) ? d.style.fontSize : this.fontSize || this.renderer.style.fontSize || 12), this.textLineHeight ? parseInt(
this.textLineHeight.toString(),
10
) : this.renderer.fontMetrics(u, d || this.svgElement.element).h;
}, v.prototype.modifyTree = function(d) {
var u = this, T = function(O, B) {
var C = O.attributes;
C = C === void 0 ? {} : C;
var b = O.children, w = O.tagName, x = u.renderer.styledMode;
w === "b" || w === "strong" ? x ? C.class = "highcharts-strong" : C.style = "font-weight:bold;" + (C.style || "") : (w === "i" || w === "em") && (x ? C.class = "highcharts-emphasized" : C.style = "font-style:italic;" + (C.style || "")), N(C.style) && (C.style = C.style.replace(/(;| |^)color([ :])/, "$1fill$2")), w === "br" ? (C.class = "highcharts-br", O.textContent = "", (B = d[B + 1]) && B.textContent && (B.textContent = B.textContent.replace(/^ +/gm, ""))) : w === "a" && b && b.some(function(a) {
return a.tagName === "#text";
}) && (O.children = [{ children: b, tagName: "tspan" }]), w !== "#text" && w !== "a" && (O.tagName = "tspan"), O.attributes = C, b && b.filter(function(a) {
return a.tagName !== "#text";
}).forEach(T);
};
d.forEach(T);
}, v.prototype.truncate = function(d, u, T, O, B, C) {
var b = this.svgElement, w = b.renderer, x = b.rotation, a = [], c = T ? 1 : 0, p = (u || T || "").length, i = p, h, o = function(s, n) {
n = n || s;
var A = d.parentNode;
if (A && typeof a[n] > "u")
if (A.getSubStringLength)
try {
a[n] = O + A.getSubStringLength(0, T ? n + 1 : n);
} catch {
}
else
w.getSpanWidth && (d.textContent = C(u || T, s), a[n] = O + w.getSpanWidth(b, d));
return a[n];
};
b.rotation = 0;
var t = o(d.textContent.length);
if (O + t > B) {
for (; c <= p; )
i = Math.ceil((c + p) / 2), T && (h = C(T, i)), t = o(i, h && h.length - 1), c === p ? c = p + 1 : t > B ? p = i - 1 : c = i;
p === 0 ? d.textContent = "" : u && p === u.length - 1 || (d.textContent = h || C(u || T, i));
}
T && T.splice(0, i), b.actualWidth = t, b.rotation = x;
}, v.prototype.unescapeEntities = function(d, u) {
return R(this.renderer.escapes, function(T, O) {
u && u.indexOf(T) !== -1 || (d = d.toString().replace(new RegExp(T, "g"), O));
}), d;
}, v;
}();
}), E(l, "Core/Renderer/SVG/SVGRenderer.js", [l["Core/Renderer/HTML/AST.js"], l["Core/Color/Color.js"], l["Core/Globals.js"], l["Core/Renderer/RendererRegistry.js"], l["Core/Renderer/SVG/SVGElement.js"], l["Core/Renderer/SVG/SVGLabel.js"], l["Core/Renderer/SVG/Symbols.js"], l["Core/Renderer/SVG/TextBuilder.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H, U, F, N, R) {
var S = I.charts, v = I.deg2rad, d = I.doc, u = I.isFirefox, T = I.isMS, O = I.isWebKit, B = I.noop, C = I.SVG_NS, b = I.symbolSizes, w = I.win, x = R.addEvent, a = R.attr, c = R.createElement, p = R.css, i = R.defined, h = R.destroyObjectProperties, o = R.extend, t = R.isArray, s = R.isNumber, n = R.isObject, A = R.isString, _ = R.merge, D = R.pick, W = R.pInt, P = R.uniqueKey, X;
return I = function() {
function g(m, L, Y, V, Q, k, G) {
this.width = this.url = this.style = this.isSVG = this.imgCount = this.height = this.gradients = this.globalAnimation = this.defs = this.chartIndex = this.cacheKeys = this.cache = this.boxWrapper = this.box = this.alignedObjects = void 0, this.init(m, L, Y, V, Q, k, G);
}
return g.prototype.init = function(m, L, Y, V, Q, k, G) {
var z = this.createElement("svg").attr({ version: "1.1", class: "highcharts-root" }), $ = z.element;
G || z.css(this.getStyle(V)), m.appendChild($), a(m, "dir", "ltr"), m.innerHTML.indexOf("xmlns") === -1 && a($, "xmlns", this.SVG_NS), this.isSVG = !0, this.box = $, this.boxWrapper = z, this.alignedObjects = [], this.url = this.getReferenceURL(), this.createElement("desc").add().element.appendChild(d.createTextNode("Created with Highcharts 9.3.3")), this.defs = this.createElement("defs").add(), this.allowHTML = k, this.forExport = Q, this.styledMode = G, this.gradients = {}, this.cache = {}, this.cacheKeys = [], this.imgCount = 0, this.setSize(L, Y, !1);
var q;
u && m.getBoundingClientRect && (L = function() {
p(m, { left: 0, top: 0 }), q = m.getBoundingClientRect(), p(m, { left: Math.ceil(q.left) - q.left + "px", top: Math.ceil(q.top) - q.top + "px" });
}, L(), this.unSubPixelFix = x(w, "resize", L));
}, g.prototype.definition = function(m) {
return new y([m]).addToDOM(this.defs.element);
}, g.prototype.getReferenceURL = function() {
if ((u || O) && d.getElementsByTagName("base").length) {
if (!i(X)) {
var m = P();
m = new y([{ tagName: "svg", attributes: { width: 8, height: 8 }, children: [{ tagName: "defs", children: [{ tagName: "clipPath", attributes: { id: m }, children: [{ tagName: "rect", attributes: { width: 4, height: 4 } }] }] }, { tagName: "rect", attributes: { id: "hitme", width: 8, height: 8, "clip-path": "url(#" + m + ")", fill: "rgba(0,0,0,0.001)" } }] }]).addToDOM(d.body), p(m, { position: "fixed", top: 0, left: 0, zIndex: 9e5 });
var L = d.elementFromPoint(6, 6);
X = (L && L.id) === "hitme", d.body.removeChild(m);
}
if (X)
return w.location.href.split("#")[0].replace(/<[^>]*>/g, "").replace(/([\('\)])/g, "\\$1").replace(/ /g, "%20");
}
return "";
}, g.prototype.getStyle = function(m) {
return this.style = o({ fontFamily: '"Lucida Grande", "Lucida Sans Unicode", Arial, Helvetica, sans-serif', fontSize: "12px" }, m);
}, g.prototype.setStyle = function(m) {
this.boxWrapper.css(this.getStyle(m));
}, g.prototype.isHidden = function() {
return !this.boxWrapper.getBBox().width;
}, g.prototype.destroy = function() {
var m = this.defs;
return this.box = null, this.boxWrapper = this.boxWrapper.destroy(), h(this.gradients || {}), this.gradients = null, m && (this.defs = m.destroy()), this.unSubPixelFix && this.unSubPixelFix(), this.alignedObjects = null;
}, g.prototype.createElement = function(m) {
var L = new this.Element();
return L.init(this, m), L;
}, g.prototype.getRadialAttr = function(m, L) {
return { cx: m[0] - m[2] / 2 + (L.cx || 0) * m[2], cy: m[1] - m[2] / 2 + (L.cy || 0) * m[2], r: (L.r || 0) * m[2] };
}, g.prototype.buildText = function(m) {
new N(m).buildSVG();
}, g.prototype.getContrast = function(m) {
return m = j.parse(m).rgba, m[0] *= 1, m[1] *= 1.2, m[2] *= 0.5, 459 < m[0] + m[1] + m[2] ? "#000000" : "#FFFFFF";
}, g.prototype.button = function(m, L, Y, V, Q, k, G, z, $, q) {
var it = this.label(m, L, Y, $, void 0, void 0, q, void 0, "button"), et = this.styledMode, nt = 0, rt = Q ? _(Q) : {};
if (m = rt && rt.style || {}, rt = y.filterUserAttributes(rt), it.attr(_({ padding: 8, r: 2 }, rt)), !et) {
rt = _({ fill: "#f7f7f7", stroke: "#cccccc", "stroke-width": 1, style: { color: "#333333", cursor: "pointer", fontWeight: "normal" } }, { style: m }, rt);
var ct = rt.style;
delete rt.style, k = _(rt, { fill: "#e6e6e6" }, y.filterUserAttributes(k || {}));
var gt = k.style;
delete k.style, G = _(rt, { fill: "#e6ebf5", style: { color: "#000000", fontWeight: "bold" } }, y.filterUserAttributes(G || {}));
var dt = G.style;
delete G.style, z = _(rt, { style: { color: "#cccccc" } }, y.filterUserAttributes(z || {}));
var ht = z.style;
delete z.style;
}
return x(it.element, T ? "mouseover" : "mouseenter", function() {
nt !== 3 && it.setState(1);
}), x(it.element, T ? "mouseout" : "mouseleave", function() {
nt !== 3 && it.setState(nt);
}), it.setState = function(at) {
at !== 1 && (it.state = nt = at), it.removeClass(/highcharts-button-(normal|hover|pressed|disabled)/).addClass("highcharts-button-" + ["normal", "hover", "pressed", "disabled"][at || 0]), et || it.attr([rt, k, G, z][at || 0]).css([ct, gt, dt, ht][at || 0]);
}, et || it.attr(rt).css(o({ cursor: "default" }, ct)), it.on("touchstart", function(at) {
return at.stopPropagation();
}).on("click", function(at) {
nt !== 3 && V.call(it, at);
});
}, g.prototype.crispLine = function(m, L, Y) {
Y === void 0 && (Y = "round");
var V = m[0], Q = m[1];
return i(V[1]) && V[1] === Q[1] && (V[1] = Q[1] = Math[Y](V[1]) - L % 2 / 2), i(V[2]) && V[2] === Q[2] && (V[2] = Q[2] = Math[Y](V[2]) + L % 2 / 2), m;
}, g.prototype.path = function(m) {
var L = this.styledMode ? {} : { fill: "none" };
return t(m) ? L.d = m : n(m) && o(L, m), this.createElement("path").attr(L);
}, g.prototype.circle = function(m, L, Y) {
return m = n(m) ? m : typeof m > "u" ? {} : { x: m, y: L, r: Y }, L = this.createElement("circle"), L.xSetter = L.ySetter = function(V, Q, k) {
k.setAttribute("c" + Q, V);
}, L.attr(m);
}, g.prototype.arc = function(m, L, Y, V, Q, k) {
return n(m) ? (V = m, L = V.y, Y = V.r, m = V.x) : V = { innerR: V, start: Q, end: k }, m = this.symbol("arc", m, L, Y, Y, V), m.r = Y, m;
}, g.prototype.rect = function(m, L, Y, V, Q, k) {
Q = n(m) ? m.r : Q;
var G = this.createElement("rect");
return m = n(m) ? m : typeof m > "u" ? {} : { x: m, y: L, width: Math.max(Y, 0), height: Math.max(V, 0) }, this.styledMode || (typeof k < "u" && (m["stroke-width"] = k, m = G.crisp(m)), m.fill = "none"), Q && (m.r = Q), G.rSetter = function(z, $, q) {
G.r = z, a(q, { rx: z, ry: z });
}, G.rGetter = function() {
return G.r || 0;
}, G.attr(m);
}, g.prototype.setSize = function(m, L, Y) {
this.width = m, this.height = L, this.boxWrapper.animate({ width: m, height: L }, { step: function() {
this.attr({ viewBox: "0 0 " + this.attr("width") + " " + this.attr("height") });
}, duration: D(
Y,
!0
) ? void 0 : 0 }), this.alignElements();
}, g.prototype.g = function(m) {
var L = this.createElement("g");
return m ? L.attr({ class: "highcharts-" + m }) : L;
}, g.prototype.image = function(m, L, Y, V, Q, k) {
var G = { preserveAspectRatio: "none" }, z = function(q, it) {
q.setAttributeNS ? q.setAttributeNS("http://www.w3.org/1999/xlink", "href", it) : q.setAttribute("hc-svg-href", it);
};
s(L) && (G.x = L), s(Y) && (G.y = Y), s(V) && (G.width = V), s(Q) && (G.height = Q);
var $ = this.createElement("image").attr(G);
return L = function(q) {
z($.element, m), k.call($, q);
}, k ? (z(
$.element,
"data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw=="
), Y = new w.Image(), x(Y, "load", L), Y.src = m, Y.complete && L({})) : z($.element, m), $;
}, g.prototype.symbol = function(m, L, Y, V, Q, k) {
var G = this, z = /^url\((.*?)\)$/, $ = z.test(m), q = !$ && (this.symbols[m] ? m : "circle"), it = q && this.symbols[q], et;
if (it) {
typeof L == "number" && (et = it.call(this.symbols, Math.round(L || 0), Math.round(Y || 0), V || 0, Q || 0, k));
var nt = this.path(et);
G.styledMode || nt.attr("fill", "none"), o(nt, { symbolName: q || void 0, x: L, y: Y, width: V, height: Q }), k && o(nt, k);
} else if ($) {
var rt = m.match(z)[1], ct = nt = this.image(rt);
ct.imgwidth = D(b[rt] && b[rt].width, k && k.width), ct.imgheight = D(b[rt] && b[rt].height, k && k.height);
var gt = function(dt) {
return dt.attr({ width: dt.width, height: dt.height });
};
["width", "height"].forEach(function(dt) {
ct[dt + "Setter"] = function(ht, at) {
var J = this["img" + at];
this[at] = ht, i(J) && (k && k.backgroundSize === "within" && this.width && this.height && (J = Math.round(J * Math.min(this.width / this.imgwidth, this.height / this.imgheight))), this.element && this.element.setAttribute(at, J), this.alignByTranslate || (ht = ((this[at] || 0) - J) / 2, this.attr(at === "width" ? { translateX: ht } : { translateY: ht })));
};
}), i(L) && ct.attr({ x: L, y: Y }), ct.isImg = !0, i(ct.imgwidth) && i(ct.imgheight) ? gt(ct) : (ct.attr({ width: 0, height: 0 }), c("img", { onload: function() {
var dt = S[G.chartIndex];
this.width === 0 && (p(this, { position: "absolute", top: "-999em" }), d.body.appendChild(this)), b[rt] = { width: this.width, height: this.height }, ct.imgwidth = this.width, ct.imgheight = this.height, ct.element && gt(ct), this.parentNode && this.parentNode.removeChild(this), G.imgCount--, !G.imgCount && dt && !dt.hasLoaded && dt.onload();
}, src: rt }), this.imgCount++);
}
return nt;
}, g.prototype.clipRect = function(m, L, Y, V) {
var Q = P() + "-", k = this.createElement("clipPath").attr({ id: Q }).add(this.defs);
return m = this.rect(m, L, Y, V, 0).add(k), m.id = Q, m.clipPath = k, m.count = 0, m;
}, g.prototype.text = function(m, L, Y, V) {
var Q = {};
return V && (this.allowHTML || !this.forExport) ? this.html(m, L, Y) : (Q.x = Math.round(L || 0), Y && (Q.y = Math.round(Y)), i(m) && (Q.text = m), m = this.createElement("text").attr(Q), (!V || this.forExport && !this.allowHTML) && (m.xSetter = function(k, G, z) {
for (var $ = z.getElementsByTagName("tspan"), q = z.getAttribute(G), it = 0, et; it < $.length; it++)
et = $[it], et.getAttribute(G) === q && et.setAttribute(G, k);
z.setAttribute(G, k);
}), m);
}, g.prototype.fontMetrics = function(m, L) {
return m = !this.styledMode && /px/.test(m) || !w.getComputedStyle ? m || L && L.style && L.style.fontSize || this.style && this.style.fontSize : L && H.prototype.getStyle.call(L, "font-size"), m = /px/.test(m) ? W(m) : 12, L = 24 > m ? m + 3 : Math.round(1.2 * m), { h: L, b: Math.round(0.8 * L), f: m };
}, g.prototype.rotCorr = function(m, L, Y) {
var V = m;
return L && Y && (V = Math.max(V * Math.cos(L * v), 4)), { x: -m / 3 * Math.sin(L * v), y: V };
}, g.prototype.pathToSegments = function(m) {
for (var L = [], Y = [], V = { A: 8, C: 7, H: 2, L: 3, M: 3, Q: 5, S: 5, T: 3, V: 2 }, Q = 0; Q < m.length; Q++)
A(Y[0]) && s(m[Q]) && Y.length === V[Y[0].toUpperCase()] && m.splice(Q, 0, Y[0].replace("M", "L").replace("m", "l")), typeof m[Q] == "string" && (Y.length && L.push(Y.slice(0)), Y.length = 0), Y.push(m[Q]);
return L.push(Y.slice(0)), L;
}, g.prototype.label = function(m, L, Y, V, Q, k, G, z, $) {
return new U(this, m, L, Y, V, Q, k, G, z, $);
}, g.prototype.alignElements = function() {
this.alignedObjects.forEach(function(m) {
return m.align();
});
}, g;
}(), o(I.prototype, { Element: H, SVG_NS: C, escapes: { "&": "&", "<": "<", ">": ">", "'": "'", '"': """ }, symbols: F, draw: B }), Z.registerRendererType("svg", I, !0), I;
}), E(l, "Core/Renderer/HTML/HTMLElement.js", [l["Core/Globals.js"], l["Core/Renderer/SVG/SVGElement.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = this && this.__extends || function() {
var T = function(O, B) {
return T = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(C, b) {
C.__proto__ = b;
} || function(C, b) {
for (var w in b)
b.hasOwnProperty(w) && (C[w] = b[w]);
}, T(O, B);
};
return function(O, B) {
function C() {
this.constructor = O;
}
T(O, B), O.prototype = B === null ? Object.create(B) : (C.prototype = B.prototype, new C());
};
}(), H = y.isFirefox, U = y.isMS, F = y.isWebKit, N = y.win, R = I.css, S = I.defined, v = I.extend, d = I.pick, u = I.pInt;
return function(T) {
function O() {
return T !== null && T.apply(this, arguments) || this;
}
return Z(O, T), O.compose = function(B) {
if (O.composedClasses.indexOf(B) === -1) {
O.composedClasses.push(B);
var C = O.prototype, b = B.prototype;
b.getSpanCorrection = C.getSpanCorrection, b.htmlCss = C.htmlCss, b.htmlGetBBox = C.htmlGetBBox, b.htmlUpdateTransform = C.htmlUpdateTransform, b.setSpanRotation = C.setSpanRotation;
}
return B;
}, O.prototype.getSpanCorrection = function(B, C, b) {
this.xCorr = -B * b, this.yCorr = -C;
}, O.prototype.htmlCss = function(B) {
var C = this.element.tagName === "SPAN" && B && "width" in B, b = d(C && B.width, void 0);
if (C) {
delete B.width, this.textWidth = b;
var w = !0;
}
return B && B.textOverflow === "ellipsis" && (B.whiteSpace = "nowrap", B.overflow = "hidden"), this.styles = v(this.styles, B), R(this.element, B), w && this.htmlUpdateTransform(), this;
}, O.prototype.htmlGetBBox = function() {
var B = this.element;
return { x: B.offsetLeft, y: B.offsetTop, width: B.offsetWidth, height: B.offsetHeight };
}, O.prototype.htmlUpdateTransform = function() {
if (this.added) {
var B = this.renderer, C = this.element, b = this.translateX || 0, w = this.translateY || 0, x = this.x || 0, a = this.y || 0, c = this.textAlign || "left", p = { left: 0, center: 0.5, right: 1 }[c], i = this.styles;
if (i = i && i.whiteSpace, R(C, { marginLeft: b, marginTop: w }), !B.styledMode && this.shadows && this.shadows.forEach(function(A) {
R(A, { marginLeft: b + 1, marginTop: w + 1 });
}), this.inverted && [].forEach.call(C.childNodes, function(A) {
B.invertChild(A, C);
}), C.tagName === "SPAN") {
var h = this.rotation, o = this.textWidth && u(this.textWidth), t = [h, c, C.innerHTML, this.textWidth, this.textAlign].join(), s = void 0;
if (s = !1, o !== this.oldTextWidth) {
if (this.textPxLength)
var n = this.textPxLength;
else
R(C, { width: "", whiteSpace: i || "nowrap" }), n = C.offsetWidth;
(o > this.oldTextWidth || n > o) && (/[ \-]/.test(C.textContent || C.innerText) || C.style.textOverflow === "ellipsis") && (R(C, { width: n > o || h ? o + "px" : "auto", display: "block", whiteSpace: i || "normal" }), this.oldTextWidth = o, s = !0);
}
this.hasBoxWidthChanged = s, t !== this.cTT && (s = B.fontMetrics(C.style.fontSize, C).b, !S(h) || h === (this.oldRotation || 0) && c === this.oldAlign || this.setSpanRotation(h, p, s), this.getSpanCorrection(!S(h) && this.textPxLength || C.offsetWidth, s, p, h, c)), R(C, { left: x + (this.xCorr || 0) + "px", top: a + (this.yCorr || 0) + "px" }), this.cTT = t, this.oldRotation = h, this.oldAlign = c;
}
} else
this.alignOnAdd = !0;
}, O.prototype.setSpanRotation = function(B, C, b) {
var w = {}, x = U && !/Edge/.test(N.navigator.userAgent) ? "-ms-transform" : F ? "-webkit-transform" : H ? "MozTransform" : N.opera ? "-o-transform" : void 0;
x && (w[x] = w.transform = "rotate(" + B + "deg)", w[x + (H ? "Origin" : "-origin")] = w.transformOrigin = 100 * C + "% " + b + "px", R(this.element, w));
}, O.composedClasses = [], O;
}(j);
}), E(
l,
"Core/Renderer/HTML/HTMLRenderer.js",
[l["Core/Renderer/HTML/AST.js"], l["Core/Renderer/SVG/SVGElement.js"], l["Core/Renderer/SVG/SVGRenderer.js"], l["Core/Utilities.js"]],
function(y, j, I, Z) {
var H = this && this.__extends || function() {
var S = function(v, d) {
return S = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(u, T) {
u.__proto__ = T;
} || function(u, T) {
for (var O in T)
T.hasOwnProperty(O) && (u[O] = T[O]);
}, S(v, d);
};
return function(v, d) {
function u() {
this.constructor = v;
}
S(v, d), v.prototype = d === null ? Object.create(d) : (u.prototype = d.prototype, new u());
};
}(), U = Z.attr, F = Z.createElement, N = Z.extend, R = Z.pick;
return function(S) {
function v() {
return S !== null && S.apply(this, arguments) || this;
}
return H(v, S), v.compose = function(d) {
return v.composedClasses.indexOf(d) === -1 && (v.composedClasses.push(d), d.prototype.html = v.prototype.html), d;
}, v.prototype.html = function(d, u, T) {
var O = this.createElement("span"), B = O.element, C = O.renderer, b = C.isSVG, w = function(x, a) {
["opacity", "visibility"].forEach(function(c) {
x[c + "Setter"] = function(p, i, h) {
var o = x.div ? x.div.style : a;
j.prototype[c + "Setter"].call(this, p, i, h), o && (o[i] = p);
};
}), x.addedSetters = !0;
};
return O.textSetter = function(x) {
x !== this.textStr && (delete this.bBox, delete this.oldTextWidth, y.setElementHTML(this.element, R(x, "")), this.textStr = x, O.doTransform = !0);
}, b && w(O, O.element.style), O.xSetter = O.ySetter = O.alignSetter = O.rotationSetter = function(x, a) {
a === "align" ? O.alignValue = O.textAlign = x : O[a] = x, O.doTransform = !0;
}, O.afterSetters = function() {
this.doTransform && (this.htmlUpdateTransform(), this.doTransform = !1);
}, O.attr({ text: d, x: Math.round(u), y: Math.round(T) }).css({ position: "absolute" }), C.styledMode || O.css({ fontFamily: this.style.fontFamily, fontSize: this.style.fontSize }), B.style.whiteSpace = "nowrap", O.css = O.htmlCss, b && (O.add = function(x) {
var a = C.box.parentNode, c = [];
if (this.parentGroup = x) {
var p = x.div;
if (!p) {
for (; x; )
c.push(x), x = x.parentGroup;
c.reverse().forEach(function(i) {
function h(n, A) {
i[A] = n, A === "translateX" ? s.left = n + "px" : s.top = n + "px", i.doTransform = !0;
}
var o = U(i.element, "class"), t = i.styles || {};
p = i.div = i.div || F("div", o ? { className: o } : void 0, {
position: "absolute",
left: (i.translateX || 0) + "px",
top: (i.translateY || 0) + "px",
display: i.display,
opacity: i.opacity,
cursor: t.cursor,
pointerEvents: t.pointerEvents,
visibility: i.visibility
}, p || a);
var s = p.style;
N(i, { classSetter: function(n) {
return function(A) {
this.element.setAttribute("class", A), n.className = A;
};
}(p), on: function() {
return c[0].div && O.on.apply({ element: c[0].div, onEvents: i.onEvents }, arguments), i;
}, translateXSetter: h, translateYSetter: h }), i.addedSetters || w(i);
});
}
} else
p = a;
return p.appendChild(B), O.added = !0, O.alignOnAdd && O.htmlUpdateTransform(), O;
}), O;
}, v.composedClasses = [], v;
}(I);
}
), E(l, "Core/Axis/AxisDefaults.js", [], function() {
var y;
return function(j) {
j.defaultXAxisOptions = { alignTicks: !0, allowDecimals: void 0, panningEnabled: !0, zIndex: 2, zoomEnabled: !0, dateTimeLabelFormats: { millisecond: { main: "%H:%M:%S.%L", range: !1 }, second: { main: "%H:%M:%S", range: !1 }, minute: { main: "%H:%M", range: !1 }, hour: { main: "%H:%M", range: !1 }, day: { main: "%e. %b" }, week: { main: "%e. %b" }, month: { main: "%b '%y" }, year: { main: "%Y" } }, endOnTick: !1, gridLineDashStyle: "Solid", gridZIndex: 1, labels: {
autoRotation: void 0,
autoRotationLimit: 80,
distance: void 0,
enabled: !0,
indentation: 10,
overflow: "justify",
padding: 5,
reserveSpace: void 0,
rotation: void 0,
staggerLines: 0,
step: 0,
useHTML: !1,
x: 0,
zIndex: 7,
style: { color: "#666666", cursor: "default", fontSize: "11px" }
}, maxPadding: 0.01, minorGridLineDashStyle: "Solid", minorTickLength: 2, minorTickPosition: "outside", minPadding: 0.01, offset: void 0, opposite: !1, reversed: void 0, reversedStacks: !1, showEmpty: !0, showFirstLabel: !0, showLastLabel: !0, startOfWeek: 1, startOnTick: !1, tickLength: 10, tickPixelInterval: 100, tickmarkPlacement: "between", tickPosition: "outside", title: {
align: "middle",
rotation: 0,
useHTML: !1,
x: 0,
y: 0,
style: { color: "#666666" }
}, type: "linear", uniqueNames: !0, visible: !0, minorGridLineColor: "#f2f2f2", minorGridLineWidth: 1, minorTickColor: "#999999", lineColor: "#ccd6eb", lineWidth: 1, gridLineColor: "#e6e6e6", gridLineWidth: void 0, tickColor: "#ccd6eb" }, j.defaultYAxisOptions = { reversedStacks: !0, endOnTick: !0, maxPadding: 0.05, minPadding: 0.05, tickPixelInterval: 72, showLastLabel: !0, labels: { x: -8 }, startOnTick: !0, title: { rotation: 270, text: "Values" }, stackLabels: {
animation: {},
allowOverlap: !1,
enabled: !1,
crop: !0,
overflow: "justify",
formatter: function() {
var I = this.axis.chart.numberFormatter;
return I(this.total, -1);
},
style: { color: "#000000", fontSize: "11px", fontWeight: "bold", textOutline: "1px contrast" }
}, gridLineWidth: 1, lineWidth: 0 }, j.defaultLeftAxisOptions = { labels: { x: -15 }, title: { rotation: 270 } }, j.defaultRightAxisOptions = { labels: { x: 15 }, title: { rotation: 90 } }, j.defaultBottomAxisOptions = { labels: { autoRotation: [-45], x: 0 }, margin: 15, title: { rotation: 0 } }, j.defaultTopAxisOptions = { labels: { autoRotation: [-45], x: 0 }, margin: 15, title: { rotation: 0 } };
}(y || (y = {})), y;
}), E(l, "Core/Foundation.js", [l["Core/Utilities.js"]], function(y) {
var j = y.addEvent, I = y.isFunction, Z = y.objectEach, H = y.removeEvent, U;
return function(F) {
F.registerEventOptions = function(N, R) {
N.eventOptions = N.eventOptions || {}, Z(R.events, function(S, v) {
N.eventOptions[v] !== S && (N.eventOptions[v] && (H(N, v, N.eventOptions[v]), delete N.eventOptions[v]), I(S) && (N.eventOptions[v] = S, j(N, v, S)));
});
};
}(U || (U = {})), U;
}), E(
l,
"Core/Axis/Tick.js",
[l["Core/FormatUtilities.js"], l["Core/Globals.js"], l["Core/Utilities.js"]],
function(y, j, I) {
var Z = j.deg2rad, H = I.clamp, U = I.correctFloat, F = I.defined, N = I.destroyObjectProperties, R = I.extend, S = I.fireEvent, v = I.isNumber, d = I.merge, u = I.objectEach, T = I.pick;
return j = function() {
function O(B, C, b, w, x) {
this.isNewLabel = this.isNew = !0, this.axis = B, this.pos = C, this.type = b || "", this.parameters = x || {}, this.tickmarkOffset = this.parameters.tickmarkOffset, this.options = this.parameters.options, S(this, "init"), b || w || this.addLabel();
}
return O.prototype.addLabel = function() {
var B = this, C = B.axis, b = C.options, w = C.chart, x = C.categories, a = C.logarithmic, c = C.names, p = B.pos, i = T(B.options && B.options.labels, b.labels), h = C.tickPositions, o = p === h[0], t = p === h[h.length - 1], s = (!i.step || i.step === 1) && C.tickInterval === 1;
h = h.info;
var n = B.label, A;
if (x = this.parameters.category || (x ? T(x[p], c[p], p) : p), a && v(x) && (x = U(a.lin2log(x))), C.dateTime)
if (h)
var _ = w.time.resolveDTLFormat(b.dateTimeLabelFormats[!b.grid && h.higherRanks[p] || h.unitName]), D = _.main;
else
v(x) && (D = C.dateTime.getXDateFormat(x, b.dateTimeLabelFormats || {}));
B.isFirst = o, B.isLast = t;
var W = {
axis: C,
chart: w,
dateTimeLabelFormat: D,
isFirst: o,
isLast: t,
pos: p,
tick: B,
tickPositionInfo: h,
value: x
};
S(this, "labelFormat", W);
var P = function(g) {
return i.formatter ? i.formatter.call(g, g) : i.format ? (g.text = C.defaultLabelFormatter.call(g), y.format(i.format, g, w)) : C.defaultLabelFormatter.call(g, g);
};
b = P.call(W, W);
var X = _ && _.list;
B.shortenLabel = X ? function() {
for (A = 0; A < X.length; A++)
if (R(W, { dateTimeLabelFormat: X[A] }), n.attr({ text: P.call(W, W) }), n.getBBox().width < C.getSlotWidth(B) - 2 * i.padding)
return;
n.attr({ text: "" });
} : void 0, s && C._addedPlotLB && B.moveLabel(b, i), F(n) || B.movedLabel ? n && n.textStr !== b && !s && (!n.textWidth || i.style.width || n.styles.width || n.css({ width: null }), n.attr({ text: b }), n.textPxLength = n.getBBox().width) : (B.label = n = B.createLabel({ x: 0, y: 0 }, b, i), B.rotation = 0);
}, O.prototype.createLabel = function(B, C, b) {
var w = this.axis, x = w.chart;
return (B = F(C) && b.enabled ? x.renderer.text(C, B.x, B.y, b.useHTML).add(w.labelGroup) : null) && (x.styledMode || B.css(d(b.style)), B.textPxLength = B.getBBox().width), B;
}, O.prototype.destroy = function() {
N(
this,
this.axis
);
}, O.prototype.getPosition = function(B, C, b, w) {
var x = this.axis, a = x.chart, c = w && a.oldChartHeight || a.chartHeight;
return B = { x: B ? U(x.translate(C + b, null, null, w) + x.transB) : x.left + x.offset + (x.opposite ? (w && a.oldChartWidth || a.chartWidth) - x.right - x.left : 0), y: B ? c - x.bottom + x.offset - (x.opposite ? x.height : 0) : U(c - x.translate(C + b, null, null, w) - x.transB) }, B.y = H(B.y, -1e5, 1e5), S(this, "afterGetPosition", { pos: B }), B;
}, O.prototype.getLabelPosition = function(B, C, b, w, x, a, c, p) {
var i = this.axis, h = i.transA, o = i.isLinked && i.linkedParent ? i.linkedParent.reversed : i.reversed, t = i.staggerLines, s = i.tickRotCorr || { x: 0, y: 0 }, n = w || i.reserveSpaceDefault ? 0 : -i.labelOffset * (i.labelAlign === "center" ? 0.5 : 1), A = {}, _ = x.y;
return F(_) || (_ = i.side === 0 ? b.rotation ? -8 : -b.getBBox().height : i.side === 2 ? s.y + 8 : Math.cos(b.rotation * Z) * (s.y - b.getBBox(!1, 0).height / 2)), B = B + x.x + n + s.x - (a && w ? a * h * (o ? -1 : 1) : 0), C = C + _ - (a && !w ? a * h * (o ? 1 : -1) : 0), t && (b = c / (p || 1) % t, i.opposite && (b = t - b - 1), C += i.labelOffset / t * b), A.x = B, A.y = Math.round(C), S(this, "afterGetLabelPosition", { pos: A, tickmarkOffset: a, index: c }), A;
}, O.prototype.getLabelSize = function() {
return this.label ? this.label.getBBox()[this.axis.horiz ? "height" : "width"] : 0;
}, O.prototype.getMarkPath = function(B, C, b, w, x, a) {
return a.crispLine([["M", B, C], ["L", B + (x ? 0 : -b), C + (x ? b : 0)]], w);
}, O.prototype.handleOverflow = function(B) {
var C = this.axis, b = C.options.labels, w = B.x, x = C.chart.chartWidth, a = C.chart.spacing, c = T(C.labelLeft, Math.min(C.pos, a[3]));
a = T(C.labelRight, Math.max(C.isRadial ? 0 : C.pos + C.len, x - a[1]));
var p = this.label, i = this.rotation, h = { left: 0, center: 0.5, right: 1 }[C.labelAlign || p.attr("align")], o = p.getBBox().width, t = C.getSlotWidth(this), s = {}, n = t, A = 1, _;
i || b.overflow !== "justify" ? 0 > i && w - h * o < c ? _ = Math.round(w / Math.cos(i * Z) - c) : 0 < i && w + h * o > a && (_ = Math.round((x - w) / Math.cos(i * Z))) : (x = w + (1 - h) * o, w - h * o < c ? n = B.x + n * (1 - h) - c : x > a && (n = a - B.x + n * h, A = -1), n = Math.min(t, n), n < t && C.labelAlign === "center" && (B.x += A * (t - n - h * (t - Math.min(o, n)))), (o > n || C.autoRotation && (p.styles || {}).width) && (_ = n)), _ && (this.shortenLabel ? this.shortenLabel() : (s.width = Math.floor(_) + "px", (b.style || {}).textOverflow || (s.textOverflow = "ellipsis"), p.css(s)));
}, O.prototype.moveLabel = function(B, C) {
var b = this, w = b.label, x = b.axis, a = x.reversed, c = !1;
if (w && w.textStr === B ? (b.movedLabel = w, c = !0, delete b.label) : u(x.ticks, function(i) {
c || i.isNew || i === b || !i.label || i.label.textStr !== B || (b.movedLabel = i.label, c = !0, i.labelPos = b.movedLabel.xy, delete i.label);
}), !c && (b.labelPos || w)) {
var p = b.labelPos || w.xy;
w = x.horiz ? a ? 0 : x.width + x.left : p.x, x = x.horiz ? p.y : a ? x.width + x.left : 0, b.movedLabel = b.createLabel({ x: w, y: x }, B, C), b.movedLabel && b.movedLabel.attr({ opacity: 0 });
}
}, O.prototype.render = function(B, C, b) {
var w = this.axis, x = w.horiz, a = this.pos, c = T(this.tickmarkOffset, w.tickmarkOffset);
a = this.getPosition(x, a, c, C), c = a.x;
var p = a.y;
w = x && c === w.pos + w.len || !x && p === w.pos ? -1 : 1, x = T(b, this.label && this.label.newOpacity, 1), b = T(b, 1), this.isActive = !0, this.renderGridLine(C, b, w), this.renderMark(a, b, w), this.renderLabel(a, C, x, B), this.isNew = !1, S(this, "afterRender");
}, O.prototype.renderGridLine = function(B, C, b) {
var w = this.axis, x = w.options, a = {}, c = this.pos, p = this.type, i = T(
this.tickmarkOffset,
w.tickmarkOffset
), h = w.chart.renderer, o = this.gridLine, t = x.gridLineWidth, s = x.gridLineColor, n = x.gridLineDashStyle;
this.type === "minor" && (t = x.minorGridLineWidth, s = x.minorGridLineColor, n = x.minorGridLineDashStyle), o || (w.chart.styledMode || (a.stroke = s, a["stroke-width"] = t || 0, a.dashstyle = n), p || (a.zIndex = 1), B && (C = 0), this.gridLine = o = h.path().attr(a).addClass("highcharts-" + (p ? p + "-" : "") + "grid-line").add(w.gridGroup)), o && (b = w.getPlotLinePath({ value: c + i, lineWidth: o.strokeWidth() * b, force: "pass", old: B })) && o[B || this.isNew ? "attr" : "animate"]({ d: b, opacity: C });
}, O.prototype.renderMark = function(B, C, b) {
var w = this.axis, x = w.options, a = w.chart.renderer, c = this.type, p = w.tickSize(c ? c + "Tick" : "tick"), i = B.x;
B = B.y;
var h = T(x[c !== "minor" ? "tickWidth" : "minorTickWidth"], !c && w.isXAxis ? 1 : 0);
x = x[c !== "minor" ? "tickColor" : "minorTickColor"];
var o = this.mark, t = !o;
p && (w.opposite && (p[0] = -p[0]), o || (this.mark = o = a.path().addClass("highcharts-" + (c ? c + "-" : "") + "tick").add(w.axisGroup), w.chart.styledMode || o.attr({ stroke: x, "stroke-width": h })), o[t ? "attr" : "animate"]({ d: this.getMarkPath(
i,
B,
p[0],
o.strokeWidth() * b,
w.horiz,
a
), opacity: C }));
}, O.prototype.renderLabel = function(B, C, b, w) {
var x = this.axis, a = x.horiz, c = x.options, p = this.label, i = c.labels, h = i.step;
x = T(this.tickmarkOffset, x.tickmarkOffset);
var o = B.x;
B = B.y;
var t = !0;
p && v(o) && (p.xy = B = this.getLabelPosition(o, B, p, a, i, x, w, h), this.isFirst && !this.isLast && !c.showFirstLabel || this.isLast && !this.isFirst && !c.showLastLabel ? t = !1 : !a || i.step || i.rotation || C || b === 0 || this.handleOverflow(B), h && w % h && (t = !1), t && v(B.y) ? (B.opacity = b, p[this.isNewLabel ? "attr" : "animate"](B), this.isNewLabel = !1) : (p.attr("y", -9999), this.isNewLabel = !0));
}, O.prototype.replaceMovedLabel = function() {
var B = this.label, C = this.axis, b = C.reversed;
if (B && !this.isNew) {
var w = C.horiz ? b ? C.left : C.width + C.left : B.xy.x;
b = C.horiz ? B.xy.y : b ? C.width + C.top : C.top, B.animate({ x: w, y: b, opacity: 0 }, void 0, B.destroy), delete this.label;
}
C.isDirty = !0, this.label = this.movedLabel, delete this.movedLabel;
}, O;
}(), j;
}
), E(l, "Core/Axis/Axis.js", [
l["Core/Animation/AnimationUtilities.js"],
l["Core/Axis/AxisDefaults.js"],
l["Core/Color/Color.js"],
l["Core/DefaultOptions.js"],
l["Core/Foundation.js"],
l["Core/Globals.js"],
l["Core/Axis/Tick.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z, H, U, F, N) {
var R = y.animObject, S = Z.defaultOptions, v = H.registerEventOptions, d = U.deg2rad, u = N.arrayMax, T = N.arrayMin, O = N.clamp, B = N.correctFloat, C = N.defined, b = N.destroyObjectProperties, w = N.erase, x = N.error, a = N.extend, c = N.fireEvent, p = N.getMagnitude, i = N.isArray, h = N.isNumber, o = N.isString, t = N.merge, s = N.normalizeTickInterval, n = N.objectEach, A = N.pick, _ = N.relativeLength, D = N.removeEvent, W = N.splat, P = N.syncTimeout;
return y = function() {
function X(g, m) {
this.zoomEnabled = this.width = this.visible = this.userOptions = this.translationSlope = this.transB = this.transA = this.top = this.ticks = this.tickRotCorr = this.tickPositions = this.tickmarkOffset = this.tickInterval = this.tickAmount = this.side = this.series = this.right = this.positiveValuesOnly = this.pos = this.pointRangePadding = this.pointRange = this.plotLinesAndBandsGroups = this.plotLinesAndBands = this.paddedTicks = this.overlap = this.options = this.offset = this.names = this.minPixelPadding = this.minorTicks = this.minorTickInterval = this.min = this.maxLabelLength = this.max = this.len = this.left = this.labelFormatter = this.labelEdge = this.isLinked = this.height = this.hasVisibleSeries = this.hasNames = this.eventOptions = this.coll = this.closestPointRange = this.chart = this.categories = this.bottom = this.alternateBands = void 0, this.init(g, m);
}
return X.prototype.init = function(g, m) {
var L = m.isX;
this.chart = g, this.horiz = g.inverted && !this.isZAxis ? !L : L, this.isXAxis = L, this.coll = this.coll || (L ? "xAxis" : "yAxis"), c(this, "init", { userOptions: m }), this.opposite = A(m.opposite, this.opposite), this.side = A(m.side, this.side, this.horiz ? this.opposite ? 0 : 2 : this.opposite ? 1 : 3), this.setOptions(m);
var Y = this.options, V = Y.labels, Q = Y.type;
this.userOptions = m, this.minPixelPadding = 0, this.reversed = A(Y.reversed, this.reversed), this.visible = Y.visible, this.zoomEnabled = Y.zoomEnabled, this.hasNames = Q === "category" || Y.categories === !0, this.categories = Y.categories || this.hasNames, this.names || (this.names = [], this.names.keys = {}), this.plotLinesAndBandsGroups = {}, this.positiveValuesOnly = !!this.logarithmic, this.isLinked = C(Y.linkedTo), this.ticks = {}, this.labelEdge = [], this.minorTicks = {}, this.plotLinesAndBands = [], this.alternateBands = {}, this.len = 0, this.minRange = this.userMinRange = Y.minRange || Y.maxZoom, this.range = Y.range, this.offset = Y.offset || 0, this.min = this.max = null, m = A(Y.crosshair, W(g.options.tooltip.crosshairs)[L ? 0 : 1]), this.crosshair = m === !0 ? {} : m, g.axes.indexOf(this) === -1 && (L ? g.axes.splice(g.xAxis.length, 0, this) : g.axes.push(this), g[this.coll].push(this)), this.series = this.series || [], g.inverted && !this.isZAxis && L && typeof this.reversed > "u" && (this.reversed = !0), this.labelRotation = h(V.rotation) ? V.rotation : void 0, v(this, Y), c(this, "afterInit");
}, X.prototype.setOptions = function(g) {
this.options = t(j.defaultXAxisOptions, this.coll === "yAxis" && j.defaultYAxisOptions, [j.defaultTopAxisOptions, j.defaultRightAxisOptions, j.defaultBottomAxisOptions, j.defaultLeftAxisOptions][this.side], t(S[this.coll], g)), c(this, "afterSetOptions", { userOptions: g });
}, X.prototype.defaultLabelFormatter = function(g) {
var m = this.axis;
g = this.chart.numberFormatter;
var L = h(this.value) ? this.value : NaN, Y = m.chart.time, V = this.dateTimeLabelFormat, Q = S.lang, k = Q.numericSymbols;
Q = Q.numericSymbolMagnitude || 1e3;
var G = m.logarithmic ? Math.abs(L) : m.tickInterval, z = k && k.length;
if (m.categories)
var $ = "" + this.value;
else if (V)
$ = Y.dateFormat(V, L);
else if (z && 1e3 <= G)
for (; z-- && typeof $ > "u"; )
m = Math.pow(Q, z + 1), G >= m && 10 * L % m === 0 && k[z] !== null && L !== 0 && ($ = g(L / m, -1) + k[z]);
return typeof $ > "u" && ($ = 1e4 <= Math.abs(L) ? g(L, -1) : g(L, -1, void 0, "")), $;
}, X.prototype.getSeriesExtremes = function() {
var g = this, m = g.chart, L;
c(this, "getSeriesExtremes", null, function() {
g.hasVisibleSeries = !1, g.dataMin = g.dataMax = g.threshold = null, g.softThreshold = !g.isXAxis, g.stacking && g.stacking.buildStacks(), g.series.forEach(function(Y) {
if (Y.visible || !m.options.chart.ignoreHiddenSeries) {
var V = Y.options, Q = V.threshold;
if (g.hasVisibleSeries = !0, g.positiveValuesOnly && 0 >= Q && (Q = null), g.isXAxis) {
if (V = Y.xData, V.length) {
V = g.logarithmic ? V.filter(g.validatePositiveValue) : V, L = Y.getXExtremes(V);
var k = L.min, G = L.max;
h(k) || k instanceof Date || (V = V.filter(h), L = Y.getXExtremes(V), k = L.min, G = L.max), V.length && (g.dataMin = Math.min(A(g.dataMin, k), k), g.dataMax = Math.max(A(g.dataMax, G), G));
}
} else
Y = Y.applyExtremes(), h(Y.dataMin) && (k = Y.dataMin, g.dataMin = Math.min(A(g.dataMin, k), k)), h(Y.dataMax) && (G = Y.dataMax, g.dataMax = Math.max(A(g.dataMax, G), G)), C(Q) && (g.threshold = Q), (!V.softThreshold || g.positiveValuesOnly) && (g.softThreshold = !1);
}
});
}), c(this, "afterGetSeriesExtremes");
}, X.prototype.translate = function(g, m, L, Y, V, Q) {
var k = this.linkedParent || this, G = Y && k.old ? k.old.min : k.min, z = k.minPixelPadding;
V = (k.isOrdinal || k.brokenAxis && k.brokenAxis.hasBreaks || k.logarithmic && V) && k.lin2val;
var $ = 1, q = 0;
return Y = Y && k.old ? k.old.transA : k.transA, Y || (Y = k.transA), L && ($ *= -1, q = k.len), k.reversed && ($ *= -1, q -= $ * (k.sector || k.len)), m ? (g = (g * $ + q - z) / Y + G, V && (g = k.lin2val(g))) : (V && (g = k.val2lin(g)), g = h(G) ? $ * (g - G) * Y + q + $ * z + (h(Q) ? Y * Q : 0) : void 0), g;
}, X.prototype.toPixels = function(g, m) {
return this.translate(
g,
!1,
!this.horiz,
null,
!0
) + (m ? 0 : this.pos);
}, X.prototype.toValue = function(g, m) {
return this.translate(g - (m ? 0 : this.pos), !0, !this.horiz, null, !0);
}, X.prototype.getPlotLinePath = function(g) {
function m(at, J, tt) {
return (nt !== "pass" && at < J || at > tt) && (nt ? at = O(at, J, tt) : ht = !0), at;
}
var L = this, Y = L.chart, V = L.left, Q = L.top, k = g.old, G = g.value, z = g.lineWidth, $ = k && Y.oldChartHeight || Y.chartHeight, q = k && Y.oldChartWidth || Y.chartWidth, it = L.transB, et = g.translatedValue, nt = g.force, rt, ct, gt, dt, ht;
return g = {
value: G,
lineWidth: z,
old: k,
force: nt,
acrossPanes: g.acrossPanes,
translatedValue: et
}, c(this, "getPlotLinePath", g, function(at) {
et = A(et, L.translate(G, null, null, k)), et = O(et, -1e5, 1e5), rt = gt = Math.round(et + it), ct = dt = Math.round($ - et - it), h(et) ? L.horiz ? (ct = Q, dt = $ - L.bottom, rt = gt = m(rt, V, V + L.width)) : (rt = V, gt = q - L.right, ct = dt = m(ct, Q, Q + L.height)) : (ht = !0, nt = !1), at.path = ht && !nt ? null : Y.renderer.crispLine([["M", rt, ct], ["L", gt, dt]], z || 1);
}), g.path;
}, X.prototype.getLinearTickPositions = function(g, m, L) {
var Y = B(Math.floor(m / g) * g);
L = B(Math.ceil(L / g) * g);
var V = [], Q;
if (B(Y + g) === Y && (Q = 20), this.single)
return [m];
for (m = Y; m <= L && (V.push(m), m = B(m + g, Q), m !== k); )
var k = m;
return V;
}, X.prototype.getMinorTickInterval = function() {
var g = this.options;
return g.minorTicks === !0 ? A(g.minorTickInterval, "auto") : g.minorTicks === !1 ? null : g.minorTickInterval;
}, X.prototype.getMinorTickPositions = function() {
var g = this.options, m = this.tickPositions, L = this.minorTickInterval, Y = this.pointRangePadding || 0, V = this.min - Y;
Y = this.max + Y;
var Q = Y - V, k = [];
if (Q && Q / L < this.len / 3) {
var G = this.logarithmic;
if (G)
this.paddedTicks.forEach(function(z, $, q) {
$ && k.push.apply(
k,
G.getLogTickPositions(L, q[$ - 1], q[$], !0)
);
});
else if (this.dateTime && this.getMinorTickInterval() === "auto")
k = k.concat(this.getTimeTicks(this.dateTime.normalizeTimeTickInterval(L), V, Y, g.startOfWeek));
else
for (g = V + (m[0] - V) % L; g <= Y && g !== k[0]; g += L)
k.push(g);
}
return k.length !== 0 && this.trimTicks(k), k;
}, X.prototype.adjustForMinRange = function() {
var g = this.options, m = this.logarithmic, L = this.min, Y = this.max, V = 0, Q, k, G, z;
if (this.isXAxis && typeof this.minRange > "u" && !m && (C(g.min) || C(g.max) || C(g.floor) || C(g.ceiling) ? this.minRange = null : (this.series.forEach(function(et) {
if (G = et.xData, z = et.xIncrement ? 1 : G.length - 1, 1 < G.length)
for (Q = z; 0 < Q; Q--)
k = G[Q] - G[Q - 1], (!V || k < V) && (V = k);
}), this.minRange = Math.min(5 * V, this.dataMax - this.dataMin))), Y - L < this.minRange) {
var $ = this.dataMax - this.dataMin >= this.minRange, q = this.minRange, it = (q - Y + L) / 2;
it = [L - it, A(g.min, L - it)], $ && (it[2] = this.logarithmic ? this.logarithmic.log2lin(this.dataMin) : this.dataMin), L = u(it), Y = [L + q, A(g.max, L + q)], $ && (Y[2] = m ? m.log2lin(this.dataMax) : this.dataMax), Y = T(Y), Y - L < q && (it[0] = Y - q, it[1] = A(g.min, Y - q), L = u(it));
}
this.min = L, this.max = Y;
}, X.prototype.getClosest = function() {
var g;
return this.categories ? g = 1 : this.series.forEach(function(m) {
var L = m.closestPointRange, Y = m.visible || !m.chart.options.chart.ignoreHiddenSeries;
!m.noSharedTooltip && C(L) && Y && (g = C(g) ? Math.min(g, L) : L);
}), g;
}, X.prototype.nameToX = function(g) {
var m = i(this.categories), L = m ? this.categories : this.names, Y = g.options.x;
if (g.series.requireSorting = !1, C(Y) || (Y = this.options.uniqueNames ? m ? L.indexOf(g.name) : A(L.keys[g.name], -1) : g.series.autoIncrement()), Y === -1) {
if (!m)
var V = L.length;
} else
V = Y;
return typeof V < "u" && (this.names[V] = g.name, this.names.keys[g.name] = V), V;
}, X.prototype.updateNames = function() {
var g = this, m = this.names;
0 < m.length && (Object.keys(m.keys).forEach(function(L) {
delete m.keys[L];
}), m.length = 0, this.minRange = this.userMinRange, (this.series || []).forEach(function(L) {
L.xIncrement = null, (!L.points || L.isDirtyData) && (g.max = Math.max(g.max, L.xData.length - 1), L.processData(), L.generatePoints()), L.data.forEach(function(Y, V) {
if (Y && Y.options && typeof Y.name < "u") {
var Q = g.nameToX(Y);
typeof Q < "u" && Q !== Y.x && (Y.x = Q, L.xData[V] = Q);
}
});
}));
}, X.prototype.setAxisTranslation = function() {
var g = this, m = g.max - g.min, L = g.linkedParent, Y = !!g.categories, V = g.isXAxis, Q = g.axisPointRange || 0, k = 0, G = 0, z = g.transA;
if (V || Y || Q) {
var $ = g.getClosest();
L ? (k = L.minPointOffset, G = L.pointRangePadding) : g.series.forEach(function(q) {
var it = Y ? 1 : V ? A(q.options.pointRange, $, 0) : g.axisPointRange || 0, et = q.options.pointPlacement;
Q = Math.max(Q, it), (!g.single || Y) && (q = q.is("xrange") ? !V : V, k = Math.max(k, q && o(et) ? 0 : it / 2), G = Math.max(G, q && et === "on" ? 0 : it));
}), L = g.ordinal && g.ordinal.slope && $ ? g.ordinal.slope / $ : 1, g.minPointOffset = k *= L, g.pointRangePadding = G *= L, g.pointRange = Math.min(Q, g.single && Y ? 1 : m), V && (g.closestPointRange = $);
}
g.translationSlope = g.transA = z = g.staticScale || g.len / (m + G || 1), g.transB = g.horiz ? g.left : g.bottom, g.minPixelPadding = z * k, c(this, "afterSetAxisTranslation");
}, X.prototype.minFromRange = function() {
return this.max - this.range;
}, X.prototype.setTickInterval = function(g) {
var m = this.chart, L = this.logarithmic, Y = this.options, V = this.isXAxis, Q = this.isLinked, k = Y.tickPixelInterval, G = this.categories, z = this.softThreshold, $ = Y.maxPadding, q = Y.minPadding, it = h(Y.tickInterval) && 0 <= Y.tickInterval ? Y.tickInterval : void 0, et = h(this.threshold) ? this.threshold : null;
this.dateTime || G || Q || this.getTickAmount();
var nt = A(this.userMin, Y.min), rt = A(this.userMax, Y.max);
if (Q) {
this.linkedParent = m[this.coll][Y.linkedTo];
var ct = this.linkedParent.getExtremes();
this.min = A(ct.min, ct.dataMin), this.max = A(ct.max, ct.dataMax), Y.type !== this.linkedParent.options.type && x(11, 1, m);
} else {
if (z && C(et)) {
if (this.dataMin >= et)
ct = et, q = 0;
else if (this.dataMax <= et) {
var gt = et;
$ = 0;
}
}
this.min = A(nt, ct, this.dataMin), this.max = A(rt, gt, this.dataMax);
}
if (L && (this.positiveValuesOnly && !g && 0 >= Math.min(this.min, A(this.dataMin, this.min)) && x(10, 1, m), this.min = B(L.log2lin(this.min), 16), this.max = B(L.log2lin(this.max), 16)), this.range && C(this.max) && (this.userMin = this.min = nt = Math.max(this.dataMin, this.minFromRange()), this.userMax = rt = this.max, this.range = null), c(this, "foundExtremes"), this.beforePadding && this.beforePadding(), this.adjustForMinRange(), !(G || this.axisPointRange || this.stacking && this.stacking.usePercentage || Q) && C(this.min) && C(this.max) && (m = this.max - this.min) && (!C(nt) && q && (this.min -= m * q), !C(rt) && $ && (this.max += m * $)), h(this.userMin) || (h(Y.softMin) && Y.softMin < this.min && (this.min = nt = Y.softMin), h(Y.floor) && (this.min = Math.max(this.min, Y.floor))), h(this.userMax) || (h(Y.softMax) && Y.softMax > this.max && (this.max = rt = Y.softMax), h(Y.ceiling) && (this.max = Math.min(this.max, Y.ceiling))), z && C(this.dataMin) && (et = et || 0, !C(nt) && this.min < et && this.dataMin >= et ? this.min = this.options.minRange ? Math.min(et, this.max - this.minRange) : et : !C(rt) && this.max > et && this.dataMax <= et && (this.max = this.options.minRange ? Math.max(et, this.min + this.minRange) : et)), h(this.min) && h(this.max) && !this.chart.polar && this.min > this.max && (C(this.options.min) ? this.max = this.min : C(this.options.max) && (this.min = this.max)), this.tickInterval = this.min === this.max || typeof this.min > "u" || typeof this.max > "u" ? 1 : Q && this.linkedParent && !it && k === this.linkedParent.options.tickPixelInterval ? it = this.linkedParent.tickInterval : A(it, this.tickAmount ? (this.max - this.min) / Math.max(this.tickAmount - 1, 1) : void 0, G ? 1 : (this.max - this.min) * k / Math.max(this.len, k)), V && !g) {
var dt = this.min !== (this.old && this.old.min) || this.max !== (this.old && this.old.max);
this.series.forEach(function(ht) {
ht.forceCrop = ht.forceCropping && ht.forceCropping(), ht.processData(dt);
}), c(this, "postProcessData", { hasExtemesChanged: dt });
}
this.setAxisTranslation(), c(this, "initialAxisTranslation"), this.pointRange && !it && (this.tickInterval = Math.max(this.pointRange, this.tickInterval)), g = A(Y.minTickInterval, this.dateTime && !this.series.some(function(ht) {
return ht.noSharedTooltip;
}) ? this.closestPointRange : 0), !it && this.tickInterval < g && (this.tickInterval = g), this.dateTime || this.logarithmic || it || (this.tickInterval = s(this.tickInterval, void 0, p(this.tickInterval), A(Y.allowDecimals, 0.5 > this.tickInterval || this.tickAmount !== void 0), !!this.tickAmount)), this.tickAmount || (this.tickInterval = this.unsquish()), this.setTickPositions();
}, X.prototype.setTickPositions = function() {
var g = this.options, m = g.tickPositions, L = this.getMinorTickInterval(), Y = this.hasVerticalPanning(), V = this.coll === "colorAxis", Q = (V || !Y) && g.startOnTick;
Y = (V || !Y) && g.endOnTick, V = g.tickPositioner, this.tickmarkOffset = this.categories && g.tickmarkPlacement === "between" && this.tickInterval === 1 ? 0.5 : 0, this.minorTickInterval = L === "auto" && this.tickInterval ? this.tickInterval / 5 : L, this.single = this.min === this.max && C(this.min) && !this.tickAmount && (parseInt(this.min, 10) === this.min || g.allowDecimals !== !1), this.tickPositions = L = m && m.slice(), !L && (this.ordinal && this.ordinal.positions || !((this.max - this.min) / this.tickInterval > Math.max(2 * this.len, 200)) ? L = this.dateTime ? this.getTimeTicks(this.dateTime.normalizeTimeTickInterval(this.tickInterval, g.units), this.min, this.max, g.startOfWeek, this.ordinal && this.ordinal.positions, this.closestPointRange, !0) : this.logarithmic ? this.logarithmic.getLogTickPositions(this.tickInterval, this.min, this.max) : this.getLinearTickPositions(
this.tickInterval,
this.min,
this.max
) : (L = [this.min, this.max], x(19, !1, this.chart)), L.length > this.len && (L = [L[0], L.pop()], L[0] === L[1] && (L.length = 1)), this.tickPositions = L, V && (V = V.apply(this, [this.min, this.max]))) && (this.tickPositions = L = V), this.paddedTicks = L.slice(0), this.trimTicks(L, Q, Y), this.isLinked || (this.single && 2 > L.length && !this.categories && !this.series.some(function(k) {
return k.is("heatmap") && k.options.pointPlacement === "between";
}) && (this.min -= 0.5, this.max += 0.5), m || V || this.adjustTickAmount()), c(this, "afterSetTickPositions");
}, X.prototype.trimTicks = function(g, m, L) {
var Y = g[0], V = g[g.length - 1], Q = !this.isOrdinal && this.minPointOffset || 0;
if (c(this, "trimTicks"), !this.isLinked) {
if (m && Y !== -1 / 0)
this.min = Y;
else
for (; this.min - Q > g[0]; )
g.shift();
if (L)
this.max = V;
else
for (; this.max + Q < g[g.length - 1]; )
g.pop();
g.length === 0 && C(Y) && !this.options.tickPositions && g.push((V + Y) / 2);
}
}, X.prototype.alignToOthers = function() {
var g = {}, m = this.options, L;
return this.chart.options.chart.alignTicks !== !1 && m.alignTicks && m.startOnTick !== !1 && m.endOnTick !== !1 && !this.logarithmic && this.chart[this.coll].forEach(function(Y) {
var V = Y.options;
V = [Y.horiz ? V.left : V.top, V.width, V.height, V.pane].join(), Y.series.length && (g[V] ? L = !0 : g[V] = 1);
}), L;
}, X.prototype.getTickAmount = function() {
var g = this.options, m = g.tickPixelInterval, L = g.tickAmount;
!C(g.tickInterval) && !L && this.len < m && !this.isRadial && !this.logarithmic && g.startOnTick && g.endOnTick && (L = 2), !L && this.alignToOthers() && (L = Math.ceil(this.len / m) + 1), 4 > L && (this.finalTickAmt = L, L = 5), this.tickAmount = L;
}, X.prototype.adjustTickAmount = function() {
var g = this.options, m = this.tickInterval, L = this.tickPositions, Y = this.tickAmount, V = this.finalTickAmt, Q = L && L.length, k = A(this.threshold, this.softThreshold ? 0 : null);
if (this.hasData() && h(this.min) && h(this.max)) {
if (Q < Y) {
for (; L.length < Y; )
L.length % 2 || this.min === k ? L.push(B(L[L.length - 1] + m)) : L.unshift(B(L[0] - m));
this.transA *= (Q - 1) / (Y - 1), this.min = g.startOnTick ? L[0] : Math.min(this.min, L[0]), this.max = g.endOnTick ? L[L.length - 1] : Math.max(this.max, L[L.length - 1]);
} else
Q > Y && (this.tickInterval *= 2, this.setTickPositions());
if (C(V)) {
for (m = g = L.length; m--; )
(V === 3 && m % 2 === 1 || 2 >= V && 0 < m && m < g - 1) && L.splice(m, 1);
this.finalTickAmt = void 0;
}
}
}, X.prototype.setScale = function() {
var g = !1, m = !1;
this.series.forEach(function(Y) {
g = g || Y.isDirtyData || Y.isDirty, m = m || Y.xAxis && Y.xAxis.isDirty || !1;
}), this.setAxisSize();
var L = this.len !== (this.old && this.old.len);
L || g || m || this.isLinked || this.forceRedraw || this.userMin !== (this.old && this.old.userMin) || this.userMax !== (this.old && this.old.userMax) || this.alignToOthers() ? (this.stacking && this.stacking.resetStacks(), this.forceRedraw = !1, this.getSeriesExtremes(), this.setTickInterval(), this.isDirty || (this.isDirty = L || this.min !== (this.old && this.old.min) || this.max !== (this.old && this.old.max))) : this.stacking && this.stacking.cleanStacks(), g && this.panningState && (this.panningState.isDirty = !0), c(this, "afterSetScale");
}, X.prototype.setExtremes = function(g, m, L, Y, V) {
var Q = this, k = Q.chart;
L = A(L, !0), Q.series.forEach(function(G) {
delete G.kdTree;
}), V = a(V, { min: g, max: m }), c(Q, "setExtremes", V, function() {
Q.userMin = g, Q.userMax = m, Q.eventArgs = V, L && k.redraw(Y);
});
}, X.prototype.zoom = function(g, m) {
var L = this, Y = this.dataMin, V = this.dataMax, Q = this.options, k = Math.min(Y, A(Q.min, Y)), G = Math.max(V, A(Q.max, V));
return g = { newMin: g, newMax: m }, c(this, "zoom", g, function(z) {
var $ = z.newMin, q = z.newMax;
($ !== L.min || q !== L.max) && (L.allowZoomOutside || (C(Y) && ($ < k && ($ = k), $ > G && ($ = G)), C(V) && (q < k && (q = k), q > G && (q = G))), L.displayBtn = typeof $ < "u" || typeof q < "u", L.setExtremes($, q, !1, void 0, { trigger: "zoom" })), z.zoomed = !0;
}), g.zoomed;
}, X.prototype.setAxisSize = function() {
var g = this.chart, m = this.options, L = m.offsets || [0, 0, 0, 0], Y = this.horiz, V = this.width = Math.round(_(A(m.width, g.plotWidth - L[3] + L[1]), g.plotWidth)), Q = this.height = Math.round(_(A(m.height, g.plotHeight - L[0] + L[2]), g.plotHeight)), k = this.top = Math.round(_(A(m.top, g.plotTop + L[0]), g.plotHeight, g.plotTop));
m = this.left = Math.round(_(A(m.left, g.plotLeft + L[3]), g.plotWidth, g.plotLeft)), this.bottom = g.chartHeight - Q - k, this.right = g.chartWidth - V - m, this.len = Math.max(Y ? V : Q, 0), this.pos = Y ? m : k;
}, X.prototype.getExtremes = function() {
var g = this.logarithmic;
return { min: g ? B(g.lin2log(this.min)) : this.min, max: g ? B(g.lin2log(this.max)) : this.max, dataMin: this.dataMin, dataMax: this.dataMax, userMin: this.userMin, userMax: this.userMax };
}, X.prototype.getThreshold = function(g) {
var m = this.logarithmic, L = m ? m.lin2log(this.min) : this.min;
return m = m ? m.lin2log(this.max) : this.max, g === null || g === -1 / 0 ? g = L : g === 1 / 0 ? g = m : L > g ? g = L : m < g && (g = m), this.translate(g, 0, 1, 0, 1);
}, X.prototype.autoLabelAlign = function(g) {
var m = (A(g, 0) - 90 * this.side + 720) % 360;
return g = { align: "center" }, c(
this,
"autoLabelAlign",
g,
function(L) {
15 < m && 165 > m ? L.align = "right" : 195 < m && 345 > m && (L.align = "left");
}
), g.align;
}, X.prototype.tickSize = function(g) {
var m = this.options, L = A(m[g === "tick" ? "tickWidth" : "minorTickWidth"], g === "tick" && this.isXAxis && !this.categories ? 1 : 0), Y = m[g === "tick" ? "tickLength" : "minorTickLength"];
if (L && Y) {
m[g + "Position"] === "inside" && (Y = -Y);
var V = [Y, L];
}
return g = { tickSize: V }, c(this, "afterTickSize", g), g.tickSize;
}, X.prototype.labelMetrics = function() {
var g = this.tickPositions && this.tickPositions[0] || 0;
return this.chart.renderer.fontMetrics(
this.options.labels.style.fontSize,
this.ticks[g] && this.ticks[g].label
);
}, X.prototype.unsquish = function() {
var g = this.options.labels, m = this.horiz, L = this.tickInterval, Y = this.len / (((this.categories ? 1 : 0) + this.max - this.min) / L), V = g.rotation, Q = this.labelMetrics(), k = Math.max(this.max - this.min, 0), G = function(nt) {
var rt = nt / (Y || 1);
return rt = 1 < rt ? Math.ceil(rt) : 1, rt * L > k && nt !== 1 / 0 && Y !== 1 / 0 && k && (rt = Math.ceil(k / L)), B(rt * L);
}, z = L, $, q, it = Number.MAX_VALUE;
if (m) {
if (!g.staggerLines && !g.step)
if (h(V))
var et = [V];
else
Y < g.autoRotationLimit && (et = g.autoRotation);
et && et.forEach(function(nt) {
if (nt === V || nt && -90 <= nt && 90 >= nt) {
q = G(Math.abs(Q.h / Math.sin(d * nt)));
var rt = q + Math.abs(nt / 360);
rt < it && (it = rt, $ = nt, z = q);
}
});
} else
g.step || (z = G(Q.h));
return this.autoRotation = et, this.labelRotation = A($, h(V) ? V : 0), z;
}, X.prototype.getSlotWidth = function(g) {
var m = this.chart, L = this.horiz, Y = this.options.labels, V = Math.max(this.tickPositions.length - (this.categories ? 0 : 1), 1), Q = m.margin[3];
if (g && h(g.slotWidth))
return g.slotWidth;
if (L && 2 > Y.step)
return Y.rotation ? 0 : (this.staggerLines || 1) * this.len / V;
if (!L) {
if (g = Y.style.width, g !== void 0)
return parseInt(String(g), 10);
if (Q)
return Q - m.spacing[3];
}
return 0.33 * m.chartWidth;
}, X.prototype.renderUnsquish = function() {
var g = this.chart, m = g.renderer, L = this.tickPositions, Y = this.ticks, V = this.options.labels, Q = V.style, k = this.horiz, G = this.getSlotWidth(), z = Math.max(1, Math.round(G - 2 * V.padding)), $ = {}, q = this.labelMetrics(), it = Q.textOverflow, et = 0;
if (o(V.rotation) || ($.rotation = V.rotation || 0), L.forEach(function(gt) {
gt = Y[gt], gt.movedLabel && gt.replaceMovedLabel(), gt && gt.label && gt.label.textPxLength > et && (et = gt.label.textPxLength);
}), this.maxLabelLength = et, this.autoRotation)
et > z && et > q.h ? $.rotation = this.labelRotation : this.labelRotation = 0;
else if (G) {
var nt = z;
if (!it) {
var rt = "clip";
for (z = L.length; !k && z--; ) {
var ct = L[z];
(ct = Y[ct].label) && (ct.styles && ct.styles.textOverflow === "ellipsis" ? ct.css({ textOverflow: "clip" }) : ct.textPxLength > G && ct.css({ width: G + "px" }), ct.getBBox().height > this.len / L.length - (q.h - q.f) && (ct.specificTextOverflow = "ellipsis"));
}
}
}
$.rotation && (nt = et > 0.5 * g.chartHeight ? 0.33 * g.chartHeight : et, it || (rt = "ellipsis")), (this.labelAlign = V.align || this.autoLabelAlign(this.labelRotation)) && ($.align = this.labelAlign), L.forEach(function(gt) {
var dt = (gt = Y[gt]) && gt.label, ht = Q.width, at = {};
dt && (dt.attr($), gt.shortenLabel ? gt.shortenLabel() : nt && !ht && Q.whiteSpace !== "nowrap" && (nt < dt.textPxLength || dt.element.tagName === "SPAN") ? (at.width = nt + "px", it || (at.textOverflow = dt.specificTextOverflow || rt), dt.css(at)) : dt.styles && dt.styles.width && !at.width && !ht && dt.css({ width: null }), delete dt.specificTextOverflow, gt.rotation = $.rotation);
}, this), this.tickRotCorr = m.rotCorr(q.b, this.labelRotation || 0, this.side !== 0);
}, X.prototype.hasData = function() {
return this.series.some(function(g) {
return g.hasData();
}) || this.options.showEmpty && C(this.min) && C(this.max);
}, X.prototype.addTitle = function(g) {
var m = this.chart.renderer, L = this.horiz, Y = this.opposite, V = this.options.title, Q = this.chart.styledMode, k;
this.axisTitle || ((k = V.textAlign) || (k = (L ? { low: "left", middle: "center", high: "right" } : { low: Y ? "right" : "left", middle: "center", high: Y ? "left" : "right" })[V.align]), this.axisTitle = m.text(V.text || "", 0, 0, V.useHTML).attr({ zIndex: 7, rotation: V.rotation, align: k }).addClass("highcharts-axis-title"), Q || this.axisTitle.css(t(V.style)), this.axisTitle.add(this.axisGroup), this.axisTitle.isNew = !0), Q || V.style.width || this.isRadial || this.axisTitle.css({ width: this.len + "px" }), this.axisTitle[g ? "show" : "hide"](g);
}, X.prototype.generateTick = function(g) {
var m = this.ticks;
m[g] ? m[g].addLabel() : m[g] = new F(this, g);
}, X.prototype.getOffset = function() {
var g = this, m = this, L = m.chart, Y = m.horiz, V = m.options, Q = m.side, k = m.ticks, G = m.tickPositions, z = m.coll, $ = m.axisParent, q = L.renderer, it = L.inverted && !m.isZAxis ? [1, 0, 3, 2][Q] : Q, et = m.hasData(), nt = V.title, rt = V.labels, ct = L.axisOffset;
L = L.clipOffset;
var gt = [
-1,
1,
1,
-1
][Q], dt = V.className, ht, at = 0, J = 0, tt = 0;
if (m.showAxis = ht = et || V.showEmpty, m.staggerLines = m.horiz && rt.staggerLines || void 0, !m.axisGroup) {
var ot = function(pt, yt, vt) {
return q.g(pt).attr({ zIndex: vt }).addClass("highcharts-" + z.toLowerCase() + yt + " " + (g.isRadial ? "highcharts-radial-axis" + yt + " " : "") + (dt || "")).add($);
};
m.gridGroup = ot("grid", "-grid", V.gridZIndex), m.axisGroup = ot("axis", "", V.zIndex), m.labelGroup = ot("axis-labels", "-labels", rt.zIndex);
}
if (et || m.isLinked ? (G.forEach(function(pt) {
m.generateTick(pt);
}), m.renderUnsquish(), m.reserveSpaceDefault = Q === 0 || Q === 2 || { 1: "left", 3: "right" }[Q] === m.labelAlign, A(rt.reserveSpace, m.labelAlign === "center" ? !0 : null, m.reserveSpaceDefault) && G.forEach(function(pt) {
tt = Math.max(k[pt].getLabelSize(), tt);
}), m.staggerLines && (tt *= m.staggerLines), m.labelOffset = tt * (m.opposite ? -1 : 1)) : n(k, function(pt, yt) {
pt.destroy(), delete k[yt];
}), nt && nt.text && nt.enabled !== !1 && (m.addTitle(ht), ht && nt.reserveSpace !== !1)) {
m.titleOffset = at = m.axisTitle.getBBox()[Y ? "height" : "width"];
var lt = nt.offset;
J = C(lt) ? 0 : A(nt.margin, Y ? 5 : 10);
}
m.renderLine(), m.offset = gt * A(V.offset, ct[Q] ? ct[Q] + (V.margin || 0) : 0), m.tickRotCorr = m.tickRotCorr || { x: 0, y: 0 }, nt = Q === 0 ? -m.labelMetrics().h : Q === 2 ? m.tickRotCorr.y : 0, et = Math.abs(tt) + J, tt && (et = et - nt + gt * (Y ? A(rt.y, m.tickRotCorr.y + 8 * gt) : rt.x)), m.axisTitleMargin = A(lt, et), m.getMaxLabelDimensions && (m.maxLabelDimensions = m.getMaxLabelDimensions(k, G)), z !== "colorAxis" && (Y = this.tickSize("tick"), ct[Q] = Math.max(ct[Q], (m.axisTitleMargin || 0) + at + gt * m.offset, et, G && G.length && Y ? Y[0] + gt * m.offset : 0), V = !m.axisLine || V.offset ? 0 : 2 * Math.floor(m.axisLine.strokeWidth() / 2), L[it] = Math.max(L[it], V)), c(this, "afterGetOffset");
}, X.prototype.getLinePath = function(g) {
var m = this.chart, L = this.opposite, Y = this.offset, V = this.horiz, Q = this.left + (L ? this.width : 0) + Y;
return Y = m.chartHeight - this.bottom - (L ? this.height : 0) + Y, L && (g *= -1), m.renderer.crispLine([["M", V ? this.left : Q, V ? Y : this.top], ["L", V ? m.chartWidth - this.right : Q, V ? Y : m.chartHeight - this.bottom]], g);
}, X.prototype.renderLine = function() {
this.axisLine || (this.axisLine = this.chart.renderer.path().addClass("highcharts-axis-line").add(this.axisGroup), this.chart.styledMode || this.axisLine.attr({ stroke: this.options.lineColor, "stroke-width": this.options.lineWidth, zIndex: 7 }));
}, X.prototype.getTitlePosition = function() {
var g = this.horiz, m = this.left, L = this.top, Y = this.len, V = this.options.title, Q = g ? m : L, k = this.opposite, G = this.offset, z = V.x, $ = V.y, q = this.axisTitle, it = this.chart.renderer.fontMetrics(V.style.fontSize, q);
return q = Math.max(q.getBBox(null, 0).height - it.h - 1, 0), Y = { low: Q + (g ? 0 : Y), middle: Q + Y / 2, high: Q + (g ? Y : 0) }[V.align], m = (g ? L + this.height : m) + (g ? 1 : -1) * (k ? -1 : 1) * this.axisTitleMargin + [-q, q, it.f, -q][this.side], g = { x: g ? Y + z : m + (k ? this.width : 0) + G + z, y: g ? m + $ - (k ? this.height : 0) + G : Y + $ }, c(this, "afterGetTitlePosition", { titlePosition: g }), g;
}, X.prototype.renderMinorTick = function(g, m) {
var L = this.minorTicks;
L[g] || (L[g] = new F(this, g, "minor")), m && L[g].isNew && L[g].render(null, !0), L[g].render(null, !1, 1);
}, X.prototype.renderTick = function(g, m, L) {
var Y = this.ticks;
(!this.isLinked || g >= this.min && g <= this.max || this.grid && this.grid.isColumn) && (Y[g] || (Y[g] = new F(this, g)), L && Y[g].isNew && Y[g].render(
m,
!0,
-1
), Y[g].render(m));
}, X.prototype.render = function() {
var g = this, m = g.chart, L = g.logarithmic, Y = g.options, V = g.isLinked, Q = g.tickPositions, k = g.axisTitle, G = g.ticks, z = g.minorTicks, $ = g.alternateBands, q = Y.stackLabels, it = Y.alternateGridColor, et = g.tickmarkOffset, nt = g.axisLine, rt = g.showAxis, ct = R(m.renderer.globalAnimation), gt, dt;
if (g.labelEdge.length = 0, g.overlap = !1, [G, z, $].forEach(function(at) {
n(at, function(J) {
J.isActive = !1;
});
}), g.hasData() || V) {
var ht = g.chart.hasRendered && g.old && h(g.old.min);
g.minorTickInterval && !g.categories && g.getMinorTickPositions().forEach(function(at) {
g.renderMinorTick(at, ht);
}), Q.length && (Q.forEach(function(at, J) {
g.renderTick(at, J, ht);
}), et && (g.min === 0 || g.single) && (G[-1] || (G[-1] = new F(g, -1, null, !0)), G[-1].render(-1))), it && Q.forEach(function(at, J) {
dt = typeof Q[J + 1] < "u" ? Q[J + 1] + et : g.max - et, J % 2 === 0 && at < g.max && dt <= g.max + (m.polar ? -et : et) && ($[at] || ($[at] = new U.PlotLineOrBand(g)), gt = at + et, $[at].options = { from: L ? L.lin2log(gt) : gt, to: L ? L.lin2log(dt) : dt, color: it, className: "highcharts-alternate-grid" }, $[at].render(), $[at].isActive = !0);
}), g._addedPlotLB || (g._addedPlotLB = !0, (Y.plotLines || []).concat(Y.plotBands || []).forEach(function(at) {
g.addPlotBandOrLine(at);
}));
}
[G, z, $].forEach(function(at) {
var J = [], tt = ct.duration;
n(at, function(ot, lt) {
ot.isActive || (ot.render(lt, !1, 0), ot.isActive = !1, J.push(lt));
}), P(function() {
for (var ot = J.length; ot--; )
at[J[ot]] && !at[J[ot]].isActive && (at[J[ot]].destroy(), delete at[J[ot]]);
}, at !== $ && m.hasRendered && tt ? tt : 0);
}), nt && (nt[nt.isPlaced ? "animate" : "attr"]({ d: this.getLinePath(nt.strokeWidth()) }), nt.isPlaced = !0, nt[rt ? "show" : "hide"](rt)), k && rt && (Y = g.getTitlePosition(), h(Y.y) ? (k[k.isNew ? "attr" : "animate"](Y), k.isNew = !1) : (k.attr("y", -9999), k.isNew = !0)), q && q.enabled && g.stacking && g.stacking.renderStackTotals(), g.old = { len: g.len, max: g.max, min: g.min, transA: g.transA, userMax: g.userMax, userMin: g.userMin }, g.isDirty = !1, c(this, "afterRender");
}, X.prototype.redraw = function() {
this.visible && (this.render(), this.plotLinesAndBands.forEach(function(g) {
g.render();
})), this.series.forEach(function(g) {
g.isDirty = !0;
});
}, X.prototype.getKeepProps = function() {
return this.keepProps || X.keepProps;
}, X.prototype.destroy = function(g) {
var m = this, L = m.plotLinesAndBands, Y = this.eventOptions;
if (c(this, "destroy", { keepEvents: g }), g || D(m), [m.ticks, m.minorTicks, m.alternateBands].forEach(function(Q) {
b(Q);
}), L)
for (g = L.length; g--; )
L[g].destroy();
"axisLine axisTitle axisGroup gridGroup labelGroup cross scrollbar".split(" ").forEach(function(Q) {
m[Q] && (m[Q] = m[Q].destroy());
});
for (var V in m.plotLinesAndBandsGroups)
m.plotLinesAndBandsGroups[V] = m.plotLinesAndBandsGroups[V].destroy();
n(m, function(Q, k) {
m.getKeepProps().indexOf(k) === -1 && delete m[k];
}), this.eventOptions = Y;
}, X.prototype.drawCrosshair = function(g, m) {
var L = this.crosshair, Y = A(L && L.snap, !0), V = this.chart, Q, k = this.cross;
if (c(this, "drawCrosshair", { e: g, point: m }), g || (g = this.cross && this.cross.e), L && (C(m) || !Y) !== !1) {
if (Y ? C(m) && (Q = A(this.coll !== "colorAxis" ? m.crosshairPos : null, this.isXAxis ? m.plotX : this.len - m.plotY)) : Q = g && (this.horiz ? g.chartX - this.pos : this.len - g.chartY + this.pos), C(Q)) {
var G = { value: m && (this.isXAxis ? m.x : A(m.stackY, m.y)), translatedValue: Q };
V.polar && a(G, { isCrosshair: !0, chartX: g && g.chartX, chartY: g && g.chartY, point: m }), G = this.getPlotLinePath(G) || null;
}
if (!C(G)) {
this.hideCrosshair();
return;
}
Y = this.categories && !this.isRadial, k || (this.cross = k = V.renderer.path().addClass("highcharts-crosshair highcharts-crosshair-" + (Y ? "category " : "thin ") + (L.className || "")).attr({ zIndex: A(L.zIndex, 2) }).add(), V.styledMode || (k.attr({ stroke: L.color || (Y ? I.parse("#ccd6eb").setOpacity(0.25).get() : "#cccccc"), "stroke-width": A(L.width, 1) }).css({ "pointer-events": "none" }), L.dashStyle && k.attr({ dashstyle: L.dashStyle }))), k.show().attr({ d: G }), Y && !L.width && k.attr({ "stroke-width": this.transA }), this.cross.e = g;
} else
this.hideCrosshair();
c(this, "afterDrawCrosshair", { e: g, point: m });
}, X.prototype.hideCrosshair = function() {
this.cross && this.cross.hide(), c(this, "afterHideCrosshair");
}, X.prototype.hasVerticalPanning = function() {
var g = this.chart.options.chart.panning;
return !!(g && g.enabled && /y/.test(g.type));
}, X.prototype.validatePositiveValue = function(g) {
return h(g) && 0 < g;
}, X.prototype.update = function(g, m) {
var L = this.chart;
g = t(this.userOptions, g), this.destroy(!0), this.init(L, g), L.isDirtyBox = !0, A(m, !0) && L.redraw();
}, X.prototype.remove = function(g) {
for (var m = this.chart, L = this.coll, Y = this.series, V = Y.length; V--; )
Y[V] && Y[V].remove(!1);
w(m.axes, this), w(m[L], this), m[L].forEach(function(Q, k) {
Q.options.index = Q.userOptions.index = k;
}), this.destroy(), m.isDirtyBox = !0, A(g, !0) && m.redraw();
}, X.prototype.setTitle = function(g, m) {
this.update({ title: g }, m);
}, X.prototype.setCategories = function(g, m) {
this.update(
{ categories: g },
m
);
}, X.defaultOptions = j.defaultXAxisOptions, X.keepProps = "extKey hcEvents names series userMax userMin".split(" "), X;
}(), y;
}), E(l, "Core/Axis/DateTimeAxis.js", [l["Core/Utilities.js"]], function(y) {
var j = y.addEvent, I = y.getMagnitude, Z = y.normalizeTickInterval, H = y.timeUnits, U;
return function(F) {
function N() {
return this.chart.time.getTimeTicks.apply(this.chart.time, arguments);
}
function R(d) {
d.userOptions.type !== "datetime" ? this.dateTime = void 0 : this.dateTime || (this.dateTime = new v(this));
}
var S = [];
F.compose = function(d) {
return S.indexOf(d) === -1 && (S.push(d), d.keepProps.push("dateTime"), d.prototype.getTimeTicks = N, j(d, "init", R)), d;
};
var v = function() {
function d(u) {
this.axis = u;
}
return d.prototype.normalizeTimeTickInterval = function(u, T) {
var O = T || [["millisecond", [1, 2, 5, 10, 20, 25, 50, 100, 200, 500]], ["second", [1, 2, 5, 10, 15, 30]], ["minute", [1, 2, 5, 10, 15, 30]], ["hour", [1, 2, 3, 4, 6, 8, 12]], ["day", [1, 2]], ["week", [1, 2]], ["month", [1, 2, 3, 4, 6]], ["year", null]];
T = O[O.length - 1];
var B = H[T[0]], C = T[1], b;
for (b = 0; b < O.length && (T = O[b], B = H[T[0]], C = T[1], !(O[b + 1] && u <= (B * C[C.length - 1] + H[O[b + 1][0]]) / 2)); b++)
;
return B === H.year && u < 5 * B && (C = [1, 2, 5]), u = Z(u / B, C, T[0] === "year" ? Math.max(I(u / B), 1) : 1), { unitRange: B, count: u, unitName: T[0] };
}, d.prototype.getXDateFormat = function(u, T) {
var O = this.axis;
return O.closestPointRange ? O.chart.time.getDateFormat(O.closestPointRange, u, O.options.startOfWeek, T) || T.year : T.day;
}, d;
}();
F.Additions = v;
}(U || (U = {})), U;
}), E(l, "Core/Axis/LogarithmicAxis.js", [l["Core/Utilities.js"]], function(y) {
var j = y.addEvent, I = y.getMagnitude, Z = y.normalizeTickInterval, H = y.pick, U;
return function(F) {
function N(d) {
var u = this.logarithmic;
d.userOptions.type !== "logarithmic" ? this.logarithmic = void 0 : u || (this.logarithmic = new v(this));
}
function R() {
var d = this.logarithmic;
d && (this.lin2val = function(u) {
return d.lin2log(u);
}, this.val2lin = function(u) {
return d.log2lin(u);
});
}
var S = [];
F.compose = function(d) {
return S.indexOf(d) === -1 && (S.push(d), d.keepProps.push("logarithmic"), j(d, "init", N), j(d, "afterInit", R)), d;
};
var v = function() {
function d(u) {
this.axis = u;
}
return d.prototype.getLogTickPositions = function(u, T, O, B) {
var C = this.axis, b = C.len, w = C.options, x = [];
if (B || (this.minorAutoInterval = void 0), 0.5 <= u)
u = Math.round(u), x = C.getLinearTickPositions(u, T, O);
else if (0.08 <= u) {
var a = Math.floor(T), c, p = w = void 0;
for (b = 0.3 < u ? [1, 2, 4] : 0.15 < u ? [1, 2, 4, 6, 8] : [1, 2, 3, 4, 5, 6, 7, 8, 9]; a < O + 1 && !p; a++) {
var i = b.length;
for (c = 0; c < i && !p; c++) {
var h = this.log2lin(this.lin2log(a) * b[c]);
h > T && (!B || w <= O) && typeof w < "u" && x.push(w), w > O && (p = !0), w = h;
}
}
} else
T = this.lin2log(T), O = this.lin2log(O), u = B ? C.getMinorTickInterval() : w.tickInterval, u = H(u === "auto" ? null : u, this.minorAutoInterval, w.tickPixelInterval / (B ? 5 : 1) * (O - T) / ((B ? b / C.tickPositions.length : b) || 1)), u = Z(u, void 0, I(u)), x = C.getLinearTickPositions(u, T, O).map(this.log2lin), B || (this.minorAutoInterval = u / 5);
return B || (C.tickInterval = u), x;
}, d.prototype.lin2log = function(u) {
return Math.pow(10, u);
}, d.prototype.log2lin = function(u) {
return Math.log(u) / Math.LN10;
}, d;
}();
F.Additions = v;
}(U || (U = {})), U;
}), E(l, "Core/Axis/PlotLineOrBand/PlotLineOrBandAxis.js", [l["Core/Utilities.js"]], function(y) {
var j = y.erase, I = y.extend, Z = y.isNumber, H;
return function(U) {
var F = [], N;
U.compose = function(S, v) {
return N || (N = S), F.indexOf(v) === -1 && (F.push(v), I(v.prototype, R.prototype)), v;
};
var R = function() {
function S() {
}
return S.prototype.getPlotBandPath = function(v, d, u) {
u === void 0 && (u = this.options);
var T = this.getPlotLinePath({ value: d, force: !0, acrossPanes: u.acrossPanes }), O = [], B = this.horiz;
if (d = !Z(this.min) || !Z(this.max) || v < this.min && d < this.min || v > this.max && d > this.max, v = this.getPlotLinePath({ value: v, force: !0, acrossPanes: u.acrossPanes }), u = 1, v && T) {
if (d) {
var C = v.toString() === T.toString();
u = 0;
}
for (d = 0; d < v.length; d += 2) {
var b = v[d], w = v[d + 1], x = T[d], a = T[d + 1];
b[0] !== "M" && b[0] !== "L" || w[0] !== "M" && w[0] !== "L" || x[0] !== "M" && x[0] !== "L" || a[0] !== "M" && a[0] !== "L" || (B && x[1] === b[1] ? (x[1] += u, a[1] += u) : B || x[2] !== b[2] || (x[2] += u, a[2] += u), O.push(["M", b[1], b[2]], ["L", w[1], w[2]], ["L", a[1], a[2]], ["L", x[1], x[2]], ["Z"])), O.isFlat = C;
}
}
return O;
}, S.prototype.addPlotBand = function(v) {
return this.addPlotBandOrLine(v, "plotBands");
}, S.prototype.addPlotLine = function(v) {
return this.addPlotBandOrLine(
v,
"plotLines"
);
}, S.prototype.addPlotBandOrLine = function(v, d) {
var u = this, T = this.userOptions, O = new N(this, v);
if (this.visible && (O = O.render()), O) {
if (this._addedPlotLB || (this._addedPlotLB = !0, (T.plotLines || []).concat(T.plotBands || []).forEach(function(C) {
u.addPlotBandOrLine(C);
})), d) {
var B = T[d] || [];
B.push(v), T[d] = B;
}
this.plotLinesAndBands.push(O);
}
return O;
}, S.prototype.removePlotBandOrLine = function(v) {
var d = this.plotLinesAndBands, u = this.options, T = this.userOptions;
if (d) {
for (var O = d.length; O--; )
d[O].id === v && d[O].destroy();
[u.plotLines || [], T.plotLines || [], u.plotBands || [], T.plotBands || []].forEach(function(B) {
for (O = B.length; O--; )
(B[O] || {}).id === v && j(B, B[O]);
});
}
}, S.prototype.removePlotBand = function(v) {
this.removePlotBandOrLine(v);
}, S.prototype.removePlotLine = function(v) {
this.removePlotBandOrLine(v);
}, S;
}();
}(H || (H = {})), H;
}), E(l, "Core/Axis/PlotLineOrBand/PlotLineOrBand.js", [l["Core/Axis/PlotLineOrBand/PlotLineOrBandAxis.js"], l["Core/Utilities.js"]], function(y, j) {
var I = j.arrayMax, Z = j.arrayMin, H = j.defined, U = j.destroyObjectProperties, F = j.erase, N = j.fireEvent, R = j.merge, S = j.objectEach, v = j.pick;
return j = function() {
function d(u, T) {
this.axis = u, T && (this.options = T, this.id = T.id);
}
return d.compose = function(u) {
return y.compose(d, u);
}, d.prototype.render = function() {
N(this, "render");
var u = this, T = u.axis, O = T.horiz, B = T.logarithmic, C = u.options, b = C.color, w = v(C.zIndex, 0), x = C.events, a = {}, c = T.chart.renderer, p = C.label, i = u.label, h = C.to, o = C.from, t = C.value, s = u.svgElem, n = [], A = H(o) && H(h);
n = H(t);
var _ = !s, D = { class: "highcharts-plot-" + (A ? "band " : "line ") + (C.className || "") }, W = A ? "bands" : "lines";
if (B && (o = B.log2lin(o), h = B.log2lin(h), t = B.log2lin(t)), T.chart.styledMode || (n ? (D.stroke = b || "#999999", D["stroke-width"] = v(C.width, 1), C.dashStyle && (D.dashstyle = C.dashStyle)) : A && (D.fill = b || "#e6ebf5", C.borderWidth && (D.stroke = C.borderColor, D["stroke-width"] = C.borderWidth))), a.zIndex = w, W += "-" + w, (B = T.plotLinesAndBandsGroups[W]) || (T.plotLinesAndBandsGroups[W] = B = c.g("plot-" + W).attr(a).add()), _ && (u.svgElem = s = c.path().attr(D).add(B)), n)
n = T.getPlotLinePath({
value: t,
lineWidth: s.strokeWidth(),
acrossPanes: C.acrossPanes
});
else if (A)
n = T.getPlotBandPath(o, h, C);
else
return;
return !u.eventsAdded && x && (S(x, function(P, X) {
s.on(X, function(g) {
x[X].apply(u, [g]);
});
}), u.eventsAdded = !0), (_ || !s.d) && n && n.length ? s.attr({ d: n }) : s && (n ? (s.show(!0), s.animate({ d: n })) : s.d && (s.hide(), i && (u.label = i = i.destroy()))), p && (H(p.text) || H(p.formatter)) && n && n.length && 0 < T.width && 0 < T.height && !n.isFlat ? (p = R({ align: O && A && "center", x: O ? !A && 4 : 10, verticalAlign: !O && A && "middle", y: O ? A ? 16 : 10 : A ? 6 : -4, rotation: O && !A && 90 }, p), this.renderLabel(
p,
n,
A,
w
)) : i && i.hide(), u;
}, d.prototype.renderLabel = function(u, T, O, B) {
var C = this.axis, b = C.chart.renderer, w = this.label;
w || (this.label = w = b.text(this.getLabelText(u), 0, 0, u.useHTML).attr({ align: u.textAlign || u.align, rotation: u.rotation, class: "highcharts-plot-" + (O ? "band" : "line") + "-label " + (u.className || ""), zIndex: B }).add(), C.chart.styledMode || w.css(R({ textOverflow: "ellipsis" }, u.style))), B = T.xBounds || [T[0][1], T[1][1], O ? T[2][1] : T[0][1]], T = T.yBounds || [T[0][2], T[1][2], O ? T[2][2] : T[0][2]], O = Z(B), b = Z(T), w.align(
u,
!1,
{ x: O, y: b, width: I(B) - O, height: I(T) - b }
), w.alignValue && w.alignValue !== "left" || w.css({ width: (w.rotation === 90 ? C.height - (w.alignAttr.y - C.top) : C.width - (w.alignAttr.x - C.left)) + "px" }), w.show(!0);
}, d.prototype.getLabelText = function(u) {
return H(u.formatter) ? u.formatter.call(this) : u.text;
}, d.prototype.destroy = function() {
F(this.axis.plotLinesAndBands, this), delete this.axis, U(this);
}, d;
}(), j;
}), E(l, "Core/Tooltip.js", [
l["Core/FormatUtilities.js"],
l["Core/Globals.js"],
l["Core/Renderer/RendererUtilities.js"],
l["Core/Renderer/RendererRegistry.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z, H) {
var U = y.format, F = j.doc, N = I.distribute, R = H.addEvent, S = H.clamp, v = H.css, d = H.defined, u = H.discardElement, T = H.extend, O = H.fireEvent, B = H.isArray, C = H.isNumber, b = H.isString, w = H.merge, x = H.pick, a = H.splat, c = H.syncTimeout;
return y = function() {
function p(i, h) {
this.allowShared = !0, this.container = void 0, this.crosshairs = [], this.distance = 0, this.isHidden = !0, this.isSticky = !1, this.now = {}, this.options = {}, this.outside = !1, this.chart = i, this.init(i, h);
}
return p.prototype.applyFilter = function() {
var i = this.chart;
i.renderer.definition({ tagName: "filter", attributes: { id: "drop-shadow-" + i.index, opacity: 0.5 }, children: [{ tagName: "feGaussianBlur", attributes: { in: "SourceAlpha", stdDeviation: 1 } }, { tagName: "feOffset", attributes: { dx: 1, dy: 1 } }, { tagName: "feComponentTransfer", children: [{ tagName: "feFuncA", attributes: { type: "linear", slope: 0.3 } }] }, { tagName: "feMerge", children: [{ tagName: "feMergeNode" }, { tagName: "feMergeNode", attributes: { in: "SourceGraphic" } }] }] });
}, p.prototype.bodyFormatter = function(i) {
return i.map(function(h) {
var o = h.series.tooltipOptions;
return (o[(h.point.formatPrefix || "point") + "Formatter"] || h.point.tooltipFormatter).call(h.point, o[(h.point.formatPrefix || "point") + "Format"] || "");
});
}, p.prototype.cleanSplit = function(i) {
this.chart.series.forEach(function(h) {
var o = h && h.tt;
o && (!o.isActive || i ? h.tt = o.destroy() : o.isActive = !1);
});
}, p.prototype.defaultFormatter = function(i) {
var h = this.points || a(this), o = [i.tooltipFooterHeaderFormatter(h[0])];
return o = o.concat(i.bodyFormatter(h)), o.push(i.tooltipFooterHeaderFormatter(
h[0],
!0
)), o;
}, p.prototype.destroy = function() {
this.label && (this.label = this.label.destroy()), this.split && this.tt && (this.cleanSplit(!0), this.tt = this.tt.destroy()), this.renderer && (this.renderer = this.renderer.destroy(), u(this.container)), H.clearTimeout(this.hideTimer), H.clearTimeout(this.tooltipTimeout);
}, p.prototype.getAnchor = function(i, h) {
var o = this.chart, t = o.pointer, s = o.inverted, n = o.plotTop, A = o.plotLeft, _, D, W = 0, P = 0;
return i = a(i), this.followPointer && h ? (typeof h.chartX > "u" && (h = t.normalize(h)), t = [h.chartX - A, h.chartY - n]) : i[0].tooltipPos ? t = i[0].tooltipPos : (i.forEach(function(X) {
_ = X.series.yAxis, D = X.series.xAxis, W += X.plotX || 0, P += X.plotLow ? (X.plotLow + (X.plotHigh || 0)) / 2 : X.plotY || 0, D && _ && (s ? (W += n + o.plotHeight - D.len - D.pos, P += A + o.plotWidth - _.len - _.pos) : (W += D.pos - A, P += _.pos - n));
}), W /= i.length, P /= i.length, t = [s ? o.plotWidth - P : W, s ? o.plotHeight - W : P], this.shared && 1 < i.length && h && (s ? t[0] = h.chartX - A : t[1] = h.chartY - n)), t.map(Math.round);
}, p.prototype.getLabel = function() {
var i = this, h = this.chart.styledMode, o = this.options, t = this.split && this.allowShared, s = "tooltip" + (d(o.className) ? " " + o.className : ""), n = o.style.pointerEvents || (!this.followPointer && o.stickOnContact ? "auto" : "none"), A = function() {
i.inContact = !0;
}, _ = function(Y) {
var V = i.chart.hoverSeries;
i.inContact = i.shouldStickOnContact() && i.chart.pointer.inClass(Y.relatedTarget, "highcharts-tooltip"), !i.inContact && V && V.onMouseOut && V.onMouseOut();
}, D, W = this.chart.renderer;
if (i.label) {
var P = !i.label.hasClass("highcharts-label");
(t && !P || !t && P) && i.destroy();
}
if (!this.label) {
if (this.outside) {
P = this.chart.options.chart.style;
var X = Z.getRendererType();
this.container = D = j.doc.createElement("div"), D.className = "highcharts-tooltip-container", v(D, { position: "absolute", top: "1px", pointerEvents: n, zIndex: Math.max(this.options.style.zIndex || 0, (P && P.zIndex || 0) + 3) }), R(D, "mouseenter", A), R(D, "mouseleave", _), j.doc.body.appendChild(D), this.renderer = W = new X(D, 0, 0, P, void 0, void 0, W.styledMode);
}
if (t ? this.label = W.g(s) : (this.label = W.label("", 0, 0, o.shape, void 0, void 0, o.useHTML, void 0, s).attr({ padding: o.padding, r: o.borderRadius }), h || this.label.attr({ fill: o.backgroundColor, "stroke-width": o.borderWidth }).css(o.style).css({ pointerEvents: n }).shadow(o.shadow)), h && o.shadow && (this.applyFilter(), this.label.attr({ filter: "url(#drop-shadow-" + this.chart.index + ")" })), i.outside && !i.split) {
var g = this.label, m = g.xSetter, L = g.ySetter;
g.xSetter = function(Y) {
m.call(g, i.distance), D.style.left = Y + "px";
}, g.ySetter = function(Y) {
L.call(g, i.distance), D.style.top = Y + "px";
};
}
this.label.on("mouseenter", A).on("mouseleave", _).attr({ zIndex: 8 }).add();
}
return this.label;
}, p.prototype.getPosition = function(i, h, o) {
var t = this.chart, s = this.distance, n = {}, A = t.inverted && o.h || 0, _ = this.outside, D = _ ? F.documentElement.clientWidth - 2 * s : t.chartWidth, W = _ ? Math.max(F.body.scrollHeight, F.documentElement.scrollHeight, F.body.offsetHeight, F.documentElement.offsetHeight, F.documentElement.clientHeight) : t.chartHeight, P = t.pointer.getChartPosition(), X = function(z) {
var $ = z === "x";
return [z, $ ? D : W, $ ? i : h].concat(_ ? [$ ? i * P.scaleX : h * P.scaleY, $ ? P.left - s + (o.plotX + t.plotLeft) * P.scaleX : P.top - s + (o.plotY + t.plotTop) * P.scaleY, 0, $ ? D : W] : [$ ? i : h, $ ? o.plotX + t.plotLeft : o.plotY + t.plotTop, $ ? t.plotLeft : t.plotTop, $ ? t.plotLeft + t.plotWidth : t.plotTop + t.plotHeight]);
}, g = X("y"), m = X("x"), L;
X = !!o.negative, !t.polar && t.hoverSeries && t.hoverSeries.yAxis && t.hoverSeries.yAxis.reversed && (X = !X);
var Y = !this.followPointer && x(o.ttBelow, !t.inverted === X), V = function(z, $, q, it, et, nt, rt) {
var ct = _ ? z === "y" ? s * P.scaleY : s * P.scaleX : s, gt = (q - it) / 2, dt = it < et - s, ht = et + s + it < $, at = et - ct - q + gt;
if (et = et + ct - gt, Y && ht)
n[z] = et;
else if (!Y && dt)
n[z] = at;
else if (dt)
n[z] = Math.min(rt - it, 0 > at - A ? at : at - A);
else if (ht)
n[z] = Math.max(nt, et + A + q > $ ? et : et + A);
else
return !1;
}, Q = function(z, $, q, it, et) {
var nt;
return et < s || et > $ - s ? nt = !1 : n[z] = et < q / 2 ? 1 : et > $ - it / 2 ? $ - it - 2 : et - q / 2, nt;
}, k = function(z) {
var $ = g;
g = m, m = $, L = z;
}, G = function() {
V.apply(0, g) !== !1 ? Q.apply(0, m) !== !1 || L || (k(!0), G()) : L ? n.x = n.y = 0 : (k(!0), G());
};
return (t.inverted || 1 < this.len) && k(), G(), n;
}, p.prototype.hide = function(i) {
var h = this;
H.clearTimeout(this.hideTimer), i = x(i, this.options.hideDelay), this.isHidden || (this.hideTimer = c(function() {
h.getLabel().fadeOut(i && void 0), h.isHidden = !0;
}, i));
}, p.prototype.init = function(i, h) {
this.chart = i, this.options = h, this.crosshairs = [], this.now = { x: 0, y: 0 }, this.isHidden = !0, this.split = h.split && !i.inverted && !i.polar, this.shared = h.shared || this.split, this.outside = x(h.outside, !(!i.scrollablePixelsX && !i.scrollablePixelsY));
}, p.prototype.shouldStickOnContact = function() {
return !(this.followPointer || !this.options.stickOnContact);
}, p.prototype.isStickyOnContact = function() {
return !(!this.shouldStickOnContact() || !this.inContact);
}, p.prototype.move = function(i, h, o, t) {
var s = this, n = s.now, A = s.options.animation !== !1 && !s.isHidden && (1 < Math.abs(i - n.x) || 1 < Math.abs(h - n.y)), _ = s.followPointer || 1 < s.len;
T(n, { x: A ? (2 * n.x + i) / 3 : i, y: A ? (n.y + h) / 2 : h, anchorX: _ ? void 0 : A ? (2 * n.anchorX + o) / 3 : o, anchorY: _ ? void 0 : A ? (n.anchorY + t) / 2 : t }), s.getLabel().attr(n), s.drawTracker(), A && (H.clearTimeout(this.tooltipTimeout), this.tooltipTimeout = setTimeout(function() {
s && s.move(i, h, o, t);
}, 32));
}, p.prototype.refresh = function(i, h) {
var o = this.chart, t = this.options, s = a(i), n = s[0], A = [], _ = t.formatter || this.defaultFormatter, D = this.shared, W = o.styledMode, P = {};
if (t.enabled) {
H.clearTimeout(this.hideTimer), this.allowShared = !(!B(i) && i.series && i.series.noSharedTooltip), this.followPointer = !this.split && n.series.tooltipOptions.followPointer, i = this.getAnchor(i, h);
var X = i[0], g = i[1];
if (D && this.allowShared ? (o.pointer.applyInactiveState(s), s.forEach(function(Y) {
Y.setState("hover"), A.push(Y.getLabelConfig());
}), P = { x: n.category, y: n.y }, P.points = A) : P = n.getLabelConfig(), this.len = A.length, _ = _.call(P, this), D = n.series, this.distance = x(
D.tooltipOptions.distance,
16
), _ === !1)
this.hide();
else {
if (this.split && this.allowShared)
this.renderSplit(_, s);
else {
var m = X, L = g;
if (h && o.pointer.isDirectTouch && (m = h.chartX - o.plotLeft, L = h.chartY - o.plotTop), o.polar || D.options.clip === !1 || s.some(function(Y) {
return Y.series.shouldShowTooltip(m, L);
}))
h = this.getLabel(), t.style.width && !W || h.css({ width: this.chart.spacingBox.width + "px" }), h.attr({ text: _ && _.join ? _.join("") : _ }), h.removeClass(/highcharts-color-[\d]+/g).addClass("highcharts-color-" + x(n.colorIndex, D.colorIndex)), W || h.attr({ stroke: t.borderColor || n.color || D.color || "#666666" }), this.updatePosition({ plotX: X, plotY: g, negative: n.negative, ttBelow: n.ttBelow, h: i[2] || 0 });
else {
this.hide();
return;
}
}
this.isHidden && this.label && this.label.attr({ opacity: 1 }).show(), this.isHidden = !1;
}
O(this, "refresh");
}
}, p.prototype.renderSplit = function(i, h) {
function o(ht, at, J, tt, ot) {
return ot === void 0 && (ot = !0), J ? (at = it ? 0 : ct, ht = S(ht - tt / 2, z.left, z.right - tt - (t.outside ? et : 0))) : (at -= nt, ht = ot ? ht - tt - Q : ht + Q, ht = S(ht, ot ? ht : z.left, z.right)), { x: ht, y: at };
}
var t = this, s = t.chart, n = t.chart, A = n.chartWidth, _ = n.chartHeight, D = n.plotHeight, W = n.plotLeft, P = n.plotTop, X = n.pointer, g = n.scrollablePixelsY;
g = g === void 0 ? 0 : g;
var m = n.scrollablePixelsX, L = n.scrollingContainer;
L = L === void 0 ? { scrollLeft: 0, scrollTop: 0 } : L;
var Y = L.scrollLeft;
L = L.scrollTop;
var V = n.styledMode, Q = t.distance, k = t.options, G = t.options.positioner, z = t.outside && typeof m != "number" ? F.documentElement.getBoundingClientRect() : { left: Y, right: Y + A, top: L, bottom: L + _ }, $ = t.getLabel(), q = this.renderer || s.renderer, it = !(!s.xAxis[0] || !s.xAxis[0].opposite);
s = X.getChartPosition();
var et = s.left;
s = s.top;
var nt = P + L, rt = 0, ct = D - g;
b(i) && (i = [!1, i]), i = i.slice(0, h.length + 1).reduce(function(ht, at, J) {
if (at !== !1 && at !== "") {
J = h[J - 1] || { isHeader: !0, plotX: h[0].plotX, plotY: D, series: {} };
var tt = J.isHeader, ot = tt ? t : J.series;
at = at.toString();
var lt = ot.tt, pt = J.isHeader, yt = J.series, vt = "highcharts-color-" + x(J.colorIndex, yt.colorIndex, "none");
if (lt || (lt = { padding: k.padding, r: k.borderRadius }, V || (lt.fill = k.backgroundColor, lt["stroke-width"] = k.borderWidth), lt = q.label("", 0, 0, k[pt ? "headerShape" : "shape"], void 0, void 0, k.useHTML).addClass((pt ? "highcharts-tooltip-header " : "") + "highcharts-tooltip-box " + vt).attr(lt).add($)), lt.isActive = !0, lt.attr({ text: at }), V || lt.css(k.style).shadow(k.shadow).attr({ stroke: k.borderColor || J.color || yt.color || "#333333" }), ot = ot.tt = lt, pt = ot.getBBox(), at = pt.width + ot.strokeWidth(), tt && (rt = pt.height, ct += rt, it && (nt -= rt)), yt = J.plotX, yt = yt === void 0 ? 0 : yt, vt = J.plotY, vt = vt === void 0 ? 0 : vt, lt = J.series, J.isHeader) {
yt = W + yt;
var Ct = P + D / 2;
} else {
var Pt = lt.xAxis, At = lt.yAxis;
yt = Pt.pos + S(yt, -Q, Pt.len + Q), lt.shouldShowTooltip(0, At.pos - P + vt, { ignoreX: !0 }) && (Ct = At.pos + vt);
}
yt = S(
yt,
z.left - Q,
z.right + Q
), typeof Ct == "number" ? (pt = pt.height + 1, vt = G ? G.call(t, at, pt, J) : o(yt, Ct, tt, at), ht.push({ align: G ? 0 : void 0, anchorX: yt, anchorY: Ct, boxWidth: at, point: J, rank: x(vt.rank, tt ? 1 : 0), size: pt, target: vt.y, tt: ot, x: vt.x })) : ot.isActive = !1;
}
return ht;
}, []), !G && i.some(function(ht) {
var at = (t.outside ? et : 0) + ht.anchorX;
return at < z.left && at + ht.boxWidth < z.right ? !0 : at < et - z.left + ht.boxWidth && z.right - at > at;
}) && (i = i.map(function(ht) {
var at = o(ht.anchorX, ht.anchorY, ht.point.isHeader, ht.boxWidth, !1);
return T(ht, { target: at.y, x: at.x });
})), t.cleanSplit(), N(i, ct);
var gt = et, dt = et;
i.forEach(function(ht) {
var at = ht.x, J = ht.boxWidth;
ht = ht.isHeader, ht || (t.outside && et + at < gt && (gt = et + at), !ht && t.outside && gt + J > dt && (dt = et + at));
}), i.forEach(function(ht) {
var at = ht.x, J = ht.anchorX, tt = ht.pos, ot = ht.point.isHeader;
if (tt = { visibility: typeof tt > "u" ? "hidden" : "inherit", x: at, y: tt + nt, anchorX: J, anchorY: ht.anchorY }, t.outside && at < J) {
var lt = et - gt;
0 < lt && (ot || (tt.x = at + lt, tt.anchorX = J + lt), ot && (tt.x = (dt - gt) / 2, tt.anchorX = J + lt));
}
ht.tt.attr(tt);
}), i = t.container, g = t.renderer, t.outside && i && g && (n = $.getBBox(), g.setSize(n.width + n.x, n.height + n.y, !1), i.style.left = gt + "px", i.style.top = s + "px");
}, p.prototype.drawTracker = function() {
if (this.followPointer || !this.options.stickOnContact)
this.tracker && this.tracker.destroy();
else {
var i = this.chart, h = this.label, o = this.shared ? i.hoverPoints : i.hoverPoint;
if (h && o) {
var t = { x: 0, y: 0, width: 0, height: 0 };
o = this.getAnchor(o);
var s = h.getBBox();
o[0] += i.plotLeft - h.translateX, o[1] += i.plotTop - h.translateY, t.x = Math.min(0, o[0]), t.y = Math.min(0, o[1]), t.width = 0 > o[0] ? Math.max(Math.abs(o[0]), s.width - o[0]) : Math.max(
Math.abs(o[0]),
s.width
), t.height = 0 > o[1] ? Math.max(Math.abs(o[1]), s.height - Math.abs(o[1])) : Math.max(Math.abs(o[1]), s.height), this.tracker ? this.tracker.attr(t) : (this.tracker = h.renderer.rect(t).addClass("highcharts-tracker").add(h), i.styledMode || this.tracker.attr({ fill: "rgba(0,0,0,0)" }));
}
}
}, p.prototype.styledModeFormat = function(i) {
return i.replace('style="font-size: 10px"', 'class="highcharts-header"').replace(/style="color:{(point|series)\.color}"/g, 'class="highcharts-color-{$1.colorIndex}"');
}, p.prototype.tooltipFooterHeaderFormatter = function(i, h) {
var o = i.series, t = o.tooltipOptions, s = o.xAxis, n = s && s.dateTime;
s = { isFooter: h, labelConfig: i };
var A = t.xDateFormat, _ = t[h ? "footerFormat" : "headerFormat"];
return O(this, "headerFormatter", s, function(D) {
n && !A && C(i.key) && (A = n.getXDateFormat(i.key, t.dateTimeLabelFormats)), n && A && (i.point && i.point.tooltipDateKeys || ["key"]).forEach(function(W) {
_ = _.replace("{point." + W + "}", "{point." + W + ":" + A + "}");
}), o.chart.styledMode && (_ = this.styledModeFormat(_)), D.text = U(_, { point: i, series: o }, this.chart);
}), s.text;
}, p.prototype.update = function(i) {
this.destroy(), w(!0, this.chart.options.tooltip.userOptions, i), this.init(this.chart, w(!0, this.options, i));
}, p.prototype.updatePosition = function(i) {
var h = this.chart, o = this.options, t = h.pointer, s = this.getLabel();
t = t.getChartPosition();
var n = (o.positioner || this.getPosition).call(this, s.width, s.height, i), A = i.plotX + h.plotLeft;
i = i.plotY + h.plotTop, this.outside && (o = o.borderWidth + 2 * this.distance, this.renderer.setSize(s.width + o, s.height + o, !1), (t.scaleX !== 1 || t.scaleY !== 1) && (v(this.container, { transform: "scale(" + t.scaleX + ", " + t.scaleY + ")" }), A *= t.scaleX, i *= t.scaleY), A += t.left - n.x, i += t.top - n.y), this.move(Math.round(n.x), Math.round(n.y || 0), A, i);
}, p;
}(), y;
}), E(l, "Core/Series/Point.js", [l["Core/Renderer/HTML/AST.js"], l["Core/Animation/AnimationUtilities.js"], l["Core/DefaultOptions.js"], l["Core/FormatUtilities.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H) {
var U = j.animObject, F = I.defaultOptions, N = Z.format, R = H.addEvent, S = H.defined, v = H.erase, d = H.extend, u = H.fireEvent, T = H.getNestedProperty, O = H.isArray, B = H.isFunction, C = H.isNumber, b = H.isObject, w = H.merge, x = H.objectEach, a = H.pick, c = H.syncTimeout, p = H.removeEvent, i = H.uniqueKey;
return j = function() {
function h() {
this.colorIndex = this.category = void 0, this.formatPrefix = "point", this.id = void 0, this.isNull = !1, this.percentage = this.options = this.name = void 0, this.selected = !1, this.total = this.series = void 0, this.visible = !0, this.x = void 0;
}
return h.prototype.animateBeforeDestroy = function() {
var o = this, t = { x: o.startXPos, opacity: 0 }, s = o.getGraphicalProps();
s.singular.forEach(function(n) {
o[n] = o[n].animate(n === "dataLabel" ? { x: o[n].startXPos, y: o[n].startYPos, opacity: 0 } : t);
}), s.plural.forEach(function(n) {
o[n].forEach(function(A) {
A.element && A.animate(d({ x: o.startXPos }, A.startYPos ? { x: A.startXPos, y: A.startYPos } : {}));
});
});
}, h.prototype.applyOptions = function(o, t) {
var s = this.series, n = s.options.pointValKey || s.pointValKey;
return o = h.prototype.optionsToObject.call(this, o), d(this, o), this.options = this.options ? d(this.options, o) : o, o.group && delete this.group, o.dataLabels && delete this.dataLabels, n && (this.y = h.prototype.getNestedProperty.call(
this,
n
)), this.formatPrefix = (this.isNull = a(this.isValid && !this.isValid(), this.x === null || !C(this.y))) ? "null" : "point", this.selected && (this.state = "select"), "name" in this && typeof t > "u" && s.xAxis && s.xAxis.hasNames && (this.x = s.xAxis.nameToX(this)), typeof this.x > "u" && s ? this.x = typeof t > "u" ? s.autoIncrement() : t : C(o.x) && s.options.relativeXValue && (this.x = s.autoIncrement(o.x)), this;
}, h.prototype.destroy = function() {
function o() {
(t.graphic || t.dataLabel || t.dataLabels) && (p(t), t.destroyElements());
for (D in t)
t[D] = null;
}
var t = this, s = t.series, n = s.chart;
s = s.options.dataSorting;
var A = n.hoverPoints, _ = U(t.series.chart.renderer.globalAnimation), D;
t.legendItem && n.legend.destroyItem(t), A && (t.setState(), v(A, t), A.length || (n.hoverPoints = null)), t === n.hoverPoint && t.onMouseOut(), s && s.enabled ? (this.animateBeforeDestroy(), c(o, _.duration)) : o(), n.pointCount--;
}, h.prototype.destroyElements = function(o) {
var t = this;
o = t.getGraphicalProps(o), o.singular.forEach(function(s) {
t[s] = t[s].destroy();
}), o.plural.forEach(function(s) {
t[s].forEach(function(n) {
n.element && n.destroy();
}), delete t[s];
});
}, h.prototype.firePointEvent = function(o, t, s) {
var n = this, A = this.series.options;
(A.point.events[o] || n.options && n.options.events && n.options.events[o]) && n.importEvents(), o === "click" && A.allowPointSelect && (s = function(_) {
n.select && n.select(null, _.ctrlKey || _.metaKey || _.shiftKey);
}), u(n, o, t, s);
}, h.prototype.getClassName = function() {
return "highcharts-point" + (this.selected ? " highcharts-point-select" : "") + (this.negative ? " highcharts-negative" : "") + (this.isNull ? " highcharts-null-point" : "") + (typeof this.colorIndex < "u" ? " highcharts-color-" + this.colorIndex : "") + (this.options.className ? " " + this.options.className : "") + (this.zone && this.zone.className ? " " + this.zone.className.replace("highcharts-negative", "") : "");
}, h.prototype.getGraphicalProps = function(o) {
var t = this, s = [], n = { singular: [], plural: [] }, A;
for (o = o || { graphic: 1, dataLabel: 1 }, o.graphic && s.push("graphic", "upperGraphic", "shadowGroup"), o.dataLabel && s.push("dataLabel", "dataLabelUpper", "connector"), A = s.length; A--; ) {
var _ = s[A];
t[_] && n.singular.push(_);
}
return ["dataLabel", "connector"].forEach(function(D) {
var W = D + "s";
o[D] && t[W] && n.plural.push(W);
}), n;
}, h.prototype.getLabelConfig = function() {
return { x: this.category, y: this.y, color: this.color, colorIndex: this.colorIndex, key: this.name || this.category, series: this.series, point: this, percentage: this.percentage, total: this.total || this.stackTotal };
}, h.prototype.getNestedProperty = function(o) {
if (o)
return o.indexOf("custom.") === 0 ? T(o, this.options) : this[o];
}, h.prototype.getZone = function() {
var o = this.series, t = o.zones;
o = o.zoneAxis || "y";
var s, n = 0;
for (s = t[n]; this[o] >= s.value; )
s = t[++n];
return this.nonZonedColor || (this.nonZonedColor = this.color), this.color = s && s.color && !this.options.color ? s.color : this.nonZonedColor, s;
}, h.prototype.hasNewShapeType = function() {
return (this.graphic && (this.graphic.symbolName || this.graphic.element.nodeName)) !== this.shapeType;
}, h.prototype.init = function(o, t, s) {
return this.series = o, this.applyOptions(t, s), this.id = S(this.id) ? this.id : i(), this.resolveColor(), o.chart.pointCount++, u(this, "afterInit"), this;
}, h.prototype.optionsToObject = function(o) {
var t = this.series, s = t.options.keys, n = s || t.pointArrayMap || ["y"], A = n.length, _ = {}, D = 0, W = 0;
if (C(o) || o === null)
_[n[0]] = o;
else if (O(o))
for (!s && o.length > A && (t = typeof o[0], t === "string" ? _.name = o[0] : t === "number" && (_.x = o[0]), D++); W < A; )
s && typeof o[D] > "u" || (0 < n[W].indexOf(".") ? h.prototype.setNestedProperty(_, o[D], n[W]) : _[n[W]] = o[D]), D++, W++;
else
typeof o == "object" && (_ = o, o.dataLabels && (t._hasPointLabels = !0), o.marker && (t._hasPointMarkers = !0));
return _;
}, h.prototype.resolveColor = function() {
var o = this.series, t = o.chart.styledMode, s = o.chart.options.chart.colorCount;
if (delete this.nonZonedColor, o.options.colorByPoint) {
if (!t) {
s = o.options.colors || o.chart.options.colors;
var n = s[o.colorCounter];
s = s.length;
}
t = o.colorCounter, o.colorCounter++, o.colorCounter === s && (o.colorCounter = 0);
} else
t || (n = o.color), t = o.colorIndex;
this.colorIndex = a(this.options.colorIndex, t), this.color = a(this.options.color, n);
}, h.prototype.setNestedProperty = function(o, t, s) {
return s.split(".").reduce(function(n, A, _, D) {
return n[A] = D.length - 1 === _ ? t : b(n[A], !0) ? n[A] : {}, n[A];
}, o), o;
}, h.prototype.tooltipFormatter = function(o) {
var t = this.series, s = t.tooltipOptions, n = a(s.valueDecimals, ""), A = s.valuePrefix || "", _ = s.valueSuffix || "";
return t.chart.styledMode && (o = t.chart.tooltip.styledModeFormat(o)), (t.pointArrayMap || ["y"]).forEach(function(D) {
D = "{point." + D, (A || _) && (o = o.replace(RegExp(D + "}", "g"), A + D + "}" + _)), o = o.replace(RegExp(D + "}", "g"), D + ":,." + n + "f}");
}), N(o, { point: this, series: this.series }, t.chart);
}, h.prototype.update = function(o, t, s, n) {
function A() {
_.applyOptions(o);
var m = W && _.hasDummyGraphic;
m = _.y === null ? !m : m, W && m && (_.graphic = W.destroy(), delete _.hasDummyGraphic), b(o, !0) && (W && W.element && o && o.marker && typeof o.marker.symbol < "u" && (_.graphic = W.destroy()), o && o.dataLabels && _.dataLabel && (_.dataLabel = _.dataLabel.destroy()), _.connector && (_.connector = _.connector.destroy())), g = _.index, D.updateParallelArrays(_, g), X.data[g] = b(X.data[g], !0) || b(o, !0) ? _.options : a(o, X.data[g]), D.isDirty = D.isDirtyData = !0, !D.fixedBox && D.hasCartesianSeries && (P.isDirtyBox = !0), X.legendType === "point" && (P.isDirtyLegend = !0), t && P.redraw(s);
}
var _ = this, D = _.series, W = _.graphic, P = D.chart, X = D.options, g;
t = a(t, !0), n === !1 ? A() : _.firePointEvent("update", { options: o }, A);
}, h.prototype.remove = function(o, t) {
this.series.removePoint(this.series.data.indexOf(this), o, t);
}, h.prototype.select = function(o, t) {
var s = this, n = s.series, A = n.chart;
this.selectedStaging = o = a(o, !s.selected), s.firePointEvent(o ? "select" : "unselect", { accumulate: t }, function() {
s.selected = s.options.selected = o, n.options.data[n.data.indexOf(s)] = s.options, s.setState(o && "select"), t || A.getSelectedPoints().forEach(function(_) {
var D = _.series;
_.selected && _ !== s && (_.selected = _.options.selected = !1, D.options.data[D.data.indexOf(_)] = _.options, _.setState(A.hoverPoints && D.options.inactiveOtherPoints ? "inactive" : ""), _.firePointEvent("unselect"));
});
}), delete this.selectedStaging;
}, h.prototype.onMouseOver = function(o) {
var t = this.series.chart, s = t.pointer;
o = o ? s.normalize(o) : s.getChartCoordinatesFromPoint(this, t.inverted), s.runPointActions(
o,
this
);
}, h.prototype.onMouseOut = function() {
var o = this.series.chart;
this.firePointEvent("mouseOut"), this.series.options.inactiveOtherPoints || (o.hoverPoints || []).forEach(function(t) {
t.setState();
}), o.hoverPoints = o.hoverPoint = null;
}, h.prototype.importEvents = function() {
if (!this.hasImportedEvents) {
var o = this, t = w(o.series.options.point, o.options).events;
o.events = t, x(t, function(s, n) {
B(s) && R(o, n, s);
}), this.hasImportedEvents = !0;
}
}, h.prototype.setState = function(o, t) {
var s = this.series, n = this.state, A = s.options.states[o || "normal"] || {}, _ = F.plotOptions[s.type].marker && s.options.marker, D = _ && _.enabled === !1, W = _ && _.states && _.states[o || "normal"] || {}, P = W.enabled === !1, X = this.marker || {}, g = s.chart, m = _ && s.markerAttribs, L = s.halo, Y, V = s.stateMarkerGraphic;
if (o = o || "", !(o === this.state && !t || this.selected && o !== "select" || A.enabled === !1 || o && (P || D && W.enabled === !1) || o && X.states && X.states[o] && X.states[o].enabled === !1)) {
if (this.state = o, m && (Y = s.markerAttribs(this, o)), this.graphic && !this.hasDummyGraphic) {
if (n && this.graphic.removeClass("highcharts-point-" + n), o && this.graphic.addClass("highcharts-point-" + o), !g.styledMode) {
var Q = s.pointAttribs(this, o), k = a(g.options.chart.animation, A.animation);
s.options.inactiveOtherPoints && C(Q.opacity) && ((this.dataLabels || []).forEach(function(G) {
G && G.animate({ opacity: Q.opacity }, k);
}), this.connector && this.connector.animate({ opacity: Q.opacity }, k)), this.graphic.animate(Q, k);
}
Y && this.graphic.animate(Y, a(g.options.chart.animation, W.animation, _.animation)), V && V.hide();
} else
o && W && (n = X.symbol || s.symbol, V && V.currentSymbol !== n && (V = V.destroy()), Y && (V ? V[t ? "animate" : "attr"]({ x: Y.x, y: Y.y }) : n && (s.stateMarkerGraphic = V = g.renderer.symbol(n, Y.x, Y.y, Y.width, Y.height).add(s.markerGroup), V.currentSymbol = n)), !g.styledMode && V && this.state !== "inactive" && V.attr(s.pointAttribs(this, o))), V && (V[o && this.isInside ? "show" : "hide"](), V.element.point = this, V.addClass(this.getClassName(), !0));
A = A.halo, Y = (V = this.graphic || V) && V.visibility || "inherit", A && A.size && V && Y !== "hidden" && !this.isCluster ? (L || (s.halo = L = g.renderer.path().add(V.parentGroup)), L.show()[t ? "animate" : "attr"]({ d: this.haloPath(A.size) }), L.attr({ class: "highcharts-halo highcharts-color-" + a(this.colorIndex, s.colorIndex) + (this.className ? " " + this.className : ""), visibility: Y, zIndex: -1 }), L.point = this, g.styledMode || L.attr(d({ fill: this.color || s.color, "fill-opacity": A.opacity }, y.filterUserAttributes(A.attributes || {})))) : L && L.point && L.point.haloPath && L.animate({ d: L.point.haloPath(0) }, null, L.hide), u(this, "afterSetState", { state: o });
}
}, h.prototype.haloPath = function(o) {
return this.series.chart.renderer.symbols.circle(Math.floor(this.plotX) - o, this.plotY - o, 2 * o, 2 * o);
}, h;
}(), j;
}), E(l, "Core/Pointer.js", [l["Core/Color/Color.js"], l["Core/Globals.js"], l["Core/Tooltip.js"], l["Core/Utilities.js"]], function(y, j, I, Z) {
var H = y.parse, U = j.charts, F = j.noop, N = Z.addEvent, R = Z.attr, S = Z.css, v = Z.defined, d = Z.extend, u = Z.find, T = Z.fireEvent, O = Z.isNumber, B = Z.isObject, C = Z.objectEach, b = Z.offset, w = Z.pick, x = Z.splat;
return y = function() {
function a(c, p) {
this.lastValidTouch = {}, this.pinchDown = [], this.runChartClick = !1, this.eventsToUnbind = [], this.chart = c, this.hasDragged = !1, this.options = p, this.init(c, p);
}
return a.prototype.applyInactiveState = function(c) {
var p = [], i;
(c || []).forEach(function(h) {
i = h.series, p.push(i), i.linkedParent && p.push(i.linkedParent), i.linkedSeries && (p = p.concat(i.linkedSeries)), i.navigatorSeries && p.push(i.navigatorSeries);
}), this.chart.series.forEach(function(h) {
p.indexOf(h) === -1 ? h.setState("inactive", !0) : h.options.inactiveOtherPoints && h.setAllPointsToState("inactive");
});
}, a.prototype.destroy = function() {
var c = this;
this.eventsToUnbind.forEach(function(p) {
return p();
}), this.eventsToUnbind = [], j.chartCount || (a.unbindDocumentMouseUp && (a.unbindDocumentMouseUp = a.unbindDocumentMouseUp()), a.unbindDocumentTouchEnd && (a.unbindDocumentTouchEnd = a.unbindDocumentTouchEnd())), clearInterval(c.tooltipTimeout), C(c, function(p, i) {
c[i] = void 0;
});
}, a.prototype.drag = function(c) {
var p = this.chart, i = p.options.chart, h = this.zoomHor, o = this.zoomVert, t = p.plotLeft, s = p.plotTop, n = p.plotWidth, A = p.plotHeight, _ = this.mouseDownX || 0, D = this.mouseDownY || 0, W = B(i.panning) ? i.panning && i.panning.enabled : i.panning, P = i.panKey && c[i.panKey + "Key"], X = c.chartX, g = c.chartY, m = this.selectionMarker;
if ((!m || !m.touch) && (X < t ? X = t : X > t + n && (X = t + n), g < s ? g = s : g > s + A && (g = s + A), this.hasDragged = Math.sqrt(Math.pow(_ - X, 2) + Math.pow(D - g, 2)), 10 < this.hasDragged)) {
var L = p.isInsidePlot(_ - t, D - s, { visiblePlotOnly: !0 });
!p.hasCartesianSeries && !p.mapView || !this.zoomX && !this.zoomY || !L || P || m || (this.selectionMarker = m = p.renderer.rect(t, s, h ? 1 : n, o ? 1 : A, 0).attr({ class: "highcharts-selection-marker", zIndex: 7 }).add(), p.styledMode || m.attr({ fill: i.selectionMarkerFill || H("#335cad").setOpacity(0.25).get() })), m && h && (h = X - _, m.attr({ width: Math.abs(h), x: (0 < h ? 0 : h) + _ })), m && o && (h = g - D, m.attr({ height: Math.abs(h), y: (0 < h ? 0 : h) + D })), L && !m && W && p.pan(c, i.panning);
}
}, a.prototype.dragStart = function(c) {
var p = this.chart;
p.mouseIsDown = c.type, p.cancelClick = !1, p.mouseDownX = this.mouseDownX = c.chartX, p.mouseDownY = this.mouseDownY = c.chartY;
}, a.prototype.drop = function(c) {
var p = this, i = this.chart, h = this.hasPinched;
if (this.selectionMarker) {
var o = this.selectionMarker, t = o.attr ? o.attr("x") : o.x, s = o.attr ? o.attr("y") : o.y, n = o.attr ? o.attr("width") : o.width, A = o.attr ? o.attr("height") : o.height, _ = { originalEvent: c, xAxis: [], yAxis: [], x: t, y: s, width: n, height: A }, D = !!i.mapView;
(this.hasDragged || h) && (i.axes.forEach(function(W) {
if (W.zoomEnabled && v(W.min) && (h || p[{ xAxis: "zoomX", yAxis: "zoomY" }[W.coll]]) && O(t) && O(s)) {
var P = W.horiz, X = c.type === "touchend" ? W.minPixelPadding : 0, g = W.toValue((P ? t : s) + X);
P = W.toValue((P ? t + n : s + A) - X), _[W.coll].push({ axis: W, min: Math.min(g, P), max: Math.max(g, P) }), D = !0;
}
}), D && T(i, "selection", _, function(W) {
i.zoom(d(
W,
h ? { animation: !1 } : null
));
})), O(i.index) && (this.selectionMarker = this.selectionMarker.destroy()), h && this.scaleGroups();
}
i && O(i.index) && (S(i.container, { cursor: i._cursor }), i.cancelClick = 10 < this.hasDragged, i.mouseIsDown = this.hasDragged = this.hasPinched = !1, this.pinchDown = []);
}, a.prototype.findNearestKDPoint = function(c, p, i) {
var h = this.chart, o = h.hoverPoint;
if (h = h.tooltip, o && h && h.isStickyOnContact())
return o;
var t;
return c.forEach(function(s) {
var n = !(s.noSharedTooltip && p) && 0 > s.options.findNearestPointBy.indexOf("y");
if (s = s.searchPoint(i, n), (n = B(s, !0) && s.series) && !(n = !B(t, !0))) {
n = t.distX - s.distX;
var A = t.dist - s.dist, _ = (s.series.group && s.series.group.zIndex) - (t.series.group && t.series.group.zIndex);
n = 0 < (n !== 0 && p ? n : A !== 0 ? A : _ !== 0 ? _ : t.series.index > s.series.index ? -1 : 1);
}
n && (t = s);
}), t;
}, a.prototype.getChartCoordinatesFromPoint = function(c, p) {
var i = c.series, h = i.xAxis;
i = i.yAxis;
var o = c.shapeArgs;
if (h && i) {
var t = w(c.clientX, c.plotX), s = c.plotY || 0;
return c.isNode && o && O(o.x) && O(o.y) && (t = o.x, s = o.y), p ? { chartX: i.len + i.pos - s, chartY: h.len + h.pos - t } : { chartX: t + h.pos, chartY: s + i.pos };
}
if (o && o.x && o.y)
return { chartX: o.x, chartY: o.y };
}, a.prototype.getChartPosition = function() {
if (this.chartPosition)
return this.chartPosition;
var c = this.chart.container, p = b(c);
this.chartPosition = { left: p.left, top: p.top, scaleX: 1, scaleY: 1 };
var i = c.offsetWidth;
return c = c.offsetHeight, 2 < i && 2 < c && (this.chartPosition.scaleX = p.width / i, this.chartPosition.scaleY = p.height / c), this.chartPosition;
}, a.prototype.getCoordinates = function(c) {
var p = { xAxis: [], yAxis: [] };
return this.chart.axes.forEach(function(i) {
p[i.isXAxis ? "xAxis" : "yAxis"].push({ axis: i, value: i.toValue(c[i.horiz ? "chartX" : "chartY"]) });
}), p;
}, a.prototype.getHoverData = function(c, p, i, h, o, t) {
var s = [];
h = !(!h || !c);
var n = { chartX: t ? t.chartX : void 0, chartY: t ? t.chartY : void 0, shared: o };
T(this, "beforeGetHoverData", n);
var A = p && !p.stickyTracking ? [p] : i.filter(function(D) {
return n.filter ? n.filter(D) : D.visible && !(!o && D.directTouch) && w(D.options.enableMouseTracking, !0) && D.stickyTracking;
}), _ = h || !t ? c : this.findNearestKDPoint(A, o, t);
return p = _ && _.series, _ && (o && !p.noSharedTooltip ? (A = i.filter(function(D) {
return n.filter ? n.filter(D) : D.visible && !(!o && D.directTouch) && w(D.options.enableMouseTracking, !0) && !D.noSharedTooltip;
}), A.forEach(function(D) {
var W = u(D.points, function(P) {
return P.x === _.x && !P.isNull;
});
B(W) && (D.chart.isBoosting && (W = D.getPoint(W)), s.push(W));
})) : s.push(_)), n = { hoverPoint: _ }, T(this, "afterGetHoverData", n), { hoverPoint: n.hoverPoint, hoverSeries: p, hoverPoints: s };
}, a.prototype.getPointFromEvent = function(c) {
c = c.target;
for (var p; c && !p; )
p = c.point, c = c.parentNode;
return p;
}, a.prototype.onTrackerMouseOut = function(c) {
c = c.relatedTarget || c.toElement;
var p = this.chart.hoverSeries;
this.isDirectTouch = !1, !p || !c || p.stickyTracking || this.inClass(c, "highcharts-tooltip") || this.inClass(c, "highcharts-series-" + p.index) && this.inClass(c, "highcharts-tracker") || p.onMouseOut();
}, a.prototype.inClass = function(c, p) {
for (var i; c; ) {
if (i = R(c, "class")) {
if (i.indexOf(p) !== -1)
return !0;
if (i.indexOf("highcharts-container") !== -1)
return !1;
}
c = c.parentNode;
}
}, a.prototype.init = function(c, p) {
this.options = p, this.chart = c, this.runChartClick = !(!p.chart.events || !p.chart.events.click), this.pinchDown = [], this.lastValidTouch = {}, I && (c.tooltip = new I(c, p.tooltip), this.followTouchMove = w(p.tooltip.followTouchMove, !0)), this.setDOMEvents();
}, a.prototype.normalize = function(c, p) {
var i = c.touches, h = i ? i.length ? i.item(0) : w(i.changedTouches, c.changedTouches)[0] : c;
return p || (p = this.getChartPosition()), i = h.pageX - p.left, h = h.pageY - p.top, i /= p.scaleX, h /= p.scaleY, d(c, { chartX: Math.round(i), chartY: Math.round(h) });
}, a.prototype.onContainerClick = function(c) {
var p = this.chart, i = p.hoverPoint;
c = this.normalize(c);
var h = p.plotLeft, o = p.plotTop;
p.cancelClick || (i && this.inClass(c.target, "highcharts-tracker") ? (T(i.series, "click", d(c, { point: i })), p.hoverPoint && i.firePointEvent("click", c)) : (d(c, this.getCoordinates(c)), p.isInsidePlot(c.chartX - h, c.chartY - o, { visiblePlotOnly: !0 }) && T(p, "click", c)));
}, a.prototype.onContainerMouseDown = function(c) {
var p = ((c.buttons || c.button) & 1) === 1;
c = this.normalize(c), j.isFirefox && c.button !== 0 && this.onContainerMouseMove(c), (typeof c.button > "u" || p) && (this.zoomOption(c), p && c.preventDefault && c.preventDefault(), this.dragStart(c));
}, a.prototype.onContainerMouseLeave = function(c) {
var p = U[w(a.hoverChartIndex, -1)], i = this.chart.tooltip;
i && i.shouldStickOnContact() && this.inClass(c.relatedTarget, "highcharts-tooltip-container") || (c = this.normalize(c), p && (c.relatedTarget || c.toElement) && (p.pointer.reset(), p.pointer.chartPosition = void 0), i && !i.isHidden && this.reset());
}, a.prototype.onContainerMouseEnter = function(c) {
delete this.chartPosition;
}, a.prototype.onContainerMouseMove = function(c) {
var p = this.chart;
c = this.normalize(c), this.setHoverChartIndex(), c.preventDefault || (c.returnValue = !1), (p.mouseIsDown === "mousedown" || this.touchSelect(c)) && this.drag(c), p.openMenu || !this.inClass(c.target, "highcharts-tracker") && !p.isInsidePlot(c.chartX - p.plotLeft, c.chartY - p.plotTop, { visiblePlotOnly: !0 }) || (this.inClass(c.target, "highcharts-no-tooltip") ? this.reset(!1, 0) : this.runPointActions(c));
}, a.prototype.onDocumentTouchEnd = function(c) {
var p = U[w(
a.hoverChartIndex,
-1
)];
p && p.pointer.drop(c);
}, a.prototype.onContainerTouchMove = function(c) {
this.touchSelect(c) ? this.onContainerMouseMove(c) : this.touch(c);
}, a.prototype.onContainerTouchStart = function(c) {
this.touchSelect(c) ? this.onContainerMouseDown(c) : (this.zoomOption(c), this.touch(c, !0));
}, a.prototype.onDocumentMouseMove = function(c) {
var p = this.chart, i = this.chartPosition;
c = this.normalize(c, i);
var h = p.tooltip;
!i || h && h.isStickyOnContact() || p.isInsidePlot(c.chartX - p.plotLeft, c.chartY - p.plotTop, { visiblePlotOnly: !0 }) || this.inClass(c.target, "highcharts-tracker") || this.reset();
}, a.prototype.onDocumentMouseUp = function(c) {
var p = U[w(a.hoverChartIndex, -1)];
p && p.pointer.drop(c);
}, a.prototype.pinch = function(c) {
var p = this, i = p.chart, h = p.pinchDown, o = c.touches || [], t = o.length, s = p.lastValidTouch, n = p.hasZoom, A = {}, _ = t === 1 && (p.inClass(c.target, "highcharts-tracker") && i.runTrackerClick || p.runChartClick), D = {}, W = p.selectionMarker;
1 < t ? p.initiated = !0 : t === 1 && this.followTouchMove && (p.initiated = !1), n && p.initiated && !_ && c.cancelable !== !1 && c.preventDefault(), [].map.call(o, function(P) {
return p.normalize(P);
}), c.type === "touchstart" ? ([].forEach.call(o, function(P, X) {
h[X] = { chartX: P.chartX, chartY: P.chartY };
}), s.x = [h[0].chartX, h[1] && h[1].chartX], s.y = [h[0].chartY, h[1] && h[1].chartY], i.axes.forEach(function(P) {
if (P.zoomEnabled) {
var X = i.bounds[P.horiz ? "h" : "v"], g = P.minPixelPadding, m = P.toPixels(Math.min(w(P.options.min, P.dataMin), P.dataMin)), L = P.toPixels(Math.max(w(P.options.max, P.dataMax), P.dataMax)), Y = Math.max(m, L);
X.min = Math.min(P.pos, Math.min(
m,
L
) - g), X.max = Math.max(P.pos + P.len, Y + g);
}
}), p.res = !0) : p.followTouchMove && t === 1 ? this.runPointActions(p.normalize(c)) : h.length && (T(i, "touchpan", { originalEvent: c }, function() {
W || (p.selectionMarker = W = d({ destroy: F, touch: !0 }, i.plotBox)), p.pinchTranslate(h, o, A, W, D, s), p.hasPinched = n, p.scaleGroups(A, D);
}), p.res && (p.res = !1, this.reset(!1, 0)));
}, a.prototype.pinchTranslate = function(c, p, i, h, o, t) {
this.zoomHor && this.pinchTranslateDirection(!0, c, p, i, h, o, t), this.zoomVert && this.pinchTranslateDirection(!1, c, p, i, h, o, t);
}, a.prototype.pinchTranslateDirection = function(c, p, i, h, o, t, s, n) {
var A = this.chart, _ = c ? "x" : "y", D = c ? "X" : "Y", W = "chart" + D, P = c ? "width" : "height", X = A["plot" + (c ? "Left" : "Top")], g = A.inverted, m = A.bounds[c ? "h" : "v"], L = p.length === 1, Y = p[0][W], V = !L && p[1][W];
p = function() {
typeof $ == "number" && 20 < Math.abs(Y - V) && (G = n || Math.abs(z - $) / Math.abs(Y - V)), k = (X - z) / G + Y, Q = A["plot" + (c ? "Width" : "Height")] / G;
};
var Q, k, G = n || 1, z = i[0][W], $ = !L && i[1][W];
if (p(), i = k, i < m.min) {
i = m.min;
var q = !0;
} else
i + Q > m.max && (i = m.max - Q, q = !0);
q ? (z -= 0.8 * (z - s[_][0]), typeof $ == "number" && ($ -= 0.8 * ($ - s[_][1])), p()) : s[_] = [z, $], g || (t[_] = k - X, t[P] = Q), t = g ? 1 / G : G, o[P] = Q, o[_] = i, h[g ? c ? "scaleY" : "scaleX" : "scale" + D] = G, h["translate" + D] = t * X + (z - t * Y);
}, a.prototype.reset = function(c, p) {
var i = this.chart, h = i.hoverSeries, o = i.hoverPoint, t = i.hoverPoints, s = i.tooltip, n = s && s.shared ? t : o;
c && n && x(n).forEach(function(A) {
A.series.isCartesian && typeof A.plotX > "u" && (c = !1);
}), c ? s && n && x(n).length && (s.refresh(n), s.shared && t ? t.forEach(function(A) {
A.setState(A.state, !0), A.series.isCartesian && (A.series.xAxis.crosshair && A.series.xAxis.drawCrosshair(
null,
A
), A.series.yAxis.crosshair && A.series.yAxis.drawCrosshair(null, A));
}) : o && (o.setState(o.state, !0), i.axes.forEach(function(A) {
A.crosshair && o.series[A.coll] === A && A.drawCrosshair(null, o);
}))) : (o && o.onMouseOut(), t && t.forEach(function(A) {
A.setState();
}), h && h.onMouseOut(), s && s.hide(p), this.unDocMouseMove && (this.unDocMouseMove = this.unDocMouseMove()), i.axes.forEach(function(A) {
A.hideCrosshair();
}), this.hoverX = i.hoverPoints = i.hoverPoint = null);
}, a.prototype.runPointActions = function(c, p) {
var i = this.chart, h = i.tooltip && i.tooltip.options.enabled ? i.tooltip : void 0, o = h ? h.shared : !1, t = p || i.hoverPoint, s = t && t.series || i.hoverSeries;
p = this.getHoverData(t, s, i.series, (!c || c.type !== "touchmove") && (!!p || s && s.directTouch && this.isDirectTouch), o, c), t = p.hoverPoint, s = p.hoverSeries;
var n = p.hoverPoints;
if (p = s && s.tooltipOptions.followPointer && !s.tooltipOptions.split, o = o && s && !s.noSharedTooltip, t && (t !== i.hoverPoint || h && h.isHidden)) {
if ((i.hoverPoints || []).forEach(function(A) {
n.indexOf(A) === -1 && A.setState();
}), i.hoverSeries !== s && s.onMouseOver(), this.applyInactiveState(n), (n || []).forEach(function(A) {
A.setState("hover");
}), i.hoverPoint && i.hoverPoint.firePointEvent("mouseOut"), !t.series)
return;
i.hoverPoints = n, i.hoverPoint = t, t.firePointEvent("mouseOver"), h && h.refresh(o ? n : t, c);
} else
p && h && !h.isHidden && (t = h.getAnchor([{}], c), i.isInsidePlot(t[0], t[1], { visiblePlotOnly: !0 }) && h.updatePosition({ plotX: t[0], plotY: t[1] }));
this.unDocMouseMove || (this.unDocMouseMove = N(i.container.ownerDocument, "mousemove", function(A) {
var _ = U[a.hoverChartIndex];
_ && _.pointer.onDocumentMouseMove(A);
}), this.eventsToUnbind.push(this.unDocMouseMove)), i.axes.forEach(function(A) {
var _ = w((A.crosshair || {}).snap, !0), D;
_ && ((D = i.hoverPoint) && D.series[A.coll] === A || (D = u(n, function(W) {
return W.series[A.coll] === A;
}))), D || !_ ? A.drawCrosshair(c, D) : A.hideCrosshair();
});
}, a.prototype.scaleGroups = function(c, p) {
var i = this.chart;
i.series.forEach(function(h) {
var o = c || h.getPlotBox();
h.group && (h.xAxis && h.xAxis.zoomEnabled || i.mapView) && (h.group.attr(o), h.markerGroup && (h.markerGroup.attr(o), h.markerGroup.clip(p ? i.clipRect : null)), h.dataLabelsGroup && h.dataLabelsGroup.attr(o));
}), i.clipRect.attr(p || i.clipBox);
}, a.prototype.setDOMEvents = function() {
var c = this, p = this.chart.container, i = p.ownerDocument;
p.onmousedown = this.onContainerMouseDown.bind(this), p.onmousemove = this.onContainerMouseMove.bind(this), p.onclick = this.onContainerClick.bind(this), this.eventsToUnbind.push(N(p, "mouseenter", this.onContainerMouseEnter.bind(this))), this.eventsToUnbind.push(N(p, "mouseleave", this.onContainerMouseLeave.bind(this))), a.unbindDocumentMouseUp || (a.unbindDocumentMouseUp = N(i, "mouseup", this.onDocumentMouseUp.bind(this)));
for (var h = this.chart.renderTo.parentElement; h && h.tagName !== "BODY"; )
this.eventsToUnbind.push(N(h, "scroll", function() {
delete c.chartPosition;
})), h = h.parentElement;
j.hasTouch && (this.eventsToUnbind.push(N(p, "touchstart", this.onContainerTouchStart.bind(this), { passive: !1 })), this.eventsToUnbind.push(N(p, "touchmove", this.onContainerTouchMove.bind(this), { passive: !1 })), a.unbindDocumentTouchEnd || (a.unbindDocumentTouchEnd = N(i, "touchend", this.onDocumentTouchEnd.bind(this), { passive: !1 })));
}, a.prototype.setHoverChartIndex = function() {
var c = this.chart, p = j.charts[w(a.hoverChartIndex, -1)];
p && p !== c && p.pointer.onContainerMouseLeave({ relatedTarget: !0 }), p && p.mouseIsDown || (a.hoverChartIndex = c.index);
}, a.prototype.touch = function(c, p) {
var i = this.chart;
if (this.setHoverChartIndex(), c.touches.length === 1)
if (c = this.normalize(c), i.isInsidePlot(c.chartX - i.plotLeft, c.chartY - i.plotTop, { visiblePlotOnly: !0 }) && !i.openMenu) {
if (p && this.runPointActions(c), c.type === "touchmove") {
p = this.pinchDown;
var h = p[0] ? 4 <= Math.sqrt(Math.pow(p[0].chartX - c.chartX, 2) + Math.pow(p[0].chartY - c.chartY, 2)) : !1;
}
w(h, !0) && this.pinch(c);
} else
p && this.reset();
else
c.touches.length === 2 && this.pinch(c);
}, a.prototype.touchSelect = function(c) {
return !(!this.chart.options.chart.zoomBySingleTouch || !c.touches || c.touches.length !== 1);
}, a.prototype.zoomOption = function(c) {
var p = this.chart, i = p.options.chart;
p = p.inverted;
var h = i.zoomType || "";
/touch/.test(c.type) && (h = w(i.pinchType, h)), this.zoomX = c = /x/.test(h), this.zoomY = i = /y/.test(h), this.zoomHor = c && !p || i && p, this.zoomVert = i && !p || c && p, this.hasZoom = c || i;
}, a;
}(), y;
}), E(l, "Core/MSPointer.js", [l["Core/Globals.js"], l["Core/Pointer.js"], l["Core/Utilities.js"]], function(y, j, I) {
function Z() {
var C = [];
return C.item = function(b) {
return this[b];
}, u(O, function(b) {
C.push({ pageX: b.pageX, pageY: b.pageY, target: b.target });
}), C;
}
function H(C, b, w, x) {
var a = F[j.hoverChartIndex || NaN];
C.pointerType !== "touch" && C.pointerType !== C.MSPOINTER_TYPE_TOUCH || !a || (a = a.pointer, x(C), a[b]({ type: w, target: C.currentTarget, preventDefault: R, touches: Z() }));
}
var U = this && this.__extends || function() {
var C = function(b, w) {
return C = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(x, a) {
x.__proto__ = a;
} || function(x, a) {
for (var c in a)
a.hasOwnProperty(c) && (x[c] = a[c]);
}, C(b, w);
};
return function(b, w) {
function x() {
this.constructor = b;
}
C(b, w), b.prototype = w === null ? Object.create(w) : (x.prototype = w.prototype, new x());
};
}(), F = y.charts, N = y.doc, R = y.noop, S = y.win, v = I.addEvent, d = I.css, u = I.objectEach, T = I.removeEvent, O = {}, B = !!S.PointerEvent;
return function(C) {
function b() {
return C !== null && C.apply(this, arguments) || this;
}
return U(b, C), b.isRequired = function() {
return !(y.hasTouch || !S.PointerEvent && !S.MSPointerEvent);
}, b.prototype.batchMSEvents = function(w) {
w(this.chart.container, B ? "pointerdown" : "MSPointerDown", this.onContainerPointerDown), w(this.chart.container, B ? "pointermove" : "MSPointerMove", this.onContainerPointerMove), w(N, B ? "pointerup" : "MSPointerUp", this.onDocumentPointerUp);
}, b.prototype.destroy = function() {
this.batchMSEvents(T), C.prototype.destroy.call(this);
}, b.prototype.init = function(w, x) {
C.prototype.init.call(this, w, x), this.hasZoom && d(w.container, { "-ms-touch-action": "none", "touch-action": "none" });
}, b.prototype.onContainerPointerDown = function(w) {
H(w, "onContainerTouchStart", "touchstart", function(x) {
O[x.pointerId] = { pageX: x.pageX, pageY: x.pageY, target: x.currentTarget };
});
}, b.prototype.onContainerPointerMove = function(w) {
H(w, "onContainerTouchMove", "touchmove", function(x) {
O[x.pointerId] = {
pageX: x.pageX,
pageY: x.pageY
}, O[x.pointerId].target || (O[x.pointerId].target = x.currentTarget);
});
}, b.prototype.onDocumentPointerUp = function(w) {
H(w, "onDocumentTouchEnd", "touchend", function(x) {
delete O[x.pointerId];
});
}, b.prototype.setDOMEvents = function() {
C.prototype.setDOMEvents.call(this), (this.hasZoom || this.followTouchMove) && this.batchMSEvents(v);
}, b;
}(j);
}), E(l, "Core/Legend/Legend.js", [
l["Core/Animation/AnimationUtilities.js"],
l["Core/FormatUtilities.js"],
l["Core/Globals.js"],
l["Core/Series/Point.js"],
l["Core/Renderer/RendererUtilities.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z, H, U) {
var F = y.animObject, N = y.setAnimation, R = j.format;
y = I.isFirefox;
var S = I.marginNames;
I = I.win;
var v = H.distribute, d = U.addEvent, u = U.createElement, T = U.css, O = U.defined, B = U.discardElement, C = U.find, b = U.fireEvent, w = U.isNumber, x = U.merge, a = U.pick, c = U.relativeLength, p = U.stableSort, i = U.syncTimeout;
return H = U.wrap, U = function() {
function h(o, t) {
this.allItems = [], this.contentGroup = this.box = void 0, this.display = !1, this.group = void 0, this.offsetWidth = this.maxLegendWidth = this.maxItemWidth = this.legendWidth = this.legendHeight = this.lastLineHeight = this.lastItemY = this.itemY = this.itemX = this.itemMarginTop = this.itemMarginBottom = this.itemHeight = this.initialItemY = 0, this.options = {}, this.padding = 0, this.pages = [], this.proximate = !1, this.scrollGroup = void 0, this.widthOption = this.totalItemWidth = this.titleHeight = this.symbolWidth = this.symbolHeight = 0, this.chart = o, this.init(o, t);
}
return h.prototype.init = function(o, t) {
this.chart = o, this.setOptions(t), t.enabled && (this.render(), d(this.chart, "endResize", function() {
this.legend.positionCheckboxes();
}), this.proximate ? this.unchartrender = d(this.chart, "render", function() {
this.legend.proximatePositions(), this.legend.positionItems();
}) : this.unchartrender && this.unchartrender());
}, h.prototype.setOptions = function(o) {
var t = a(o.padding, 8);
this.options = o, this.chart.styledMode || (this.itemStyle = o.itemStyle, this.itemHiddenStyle = x(this.itemStyle, o.itemHiddenStyle)), this.itemMarginTop = o.itemMarginTop || 0, this.itemMarginBottom = o.itemMarginBottom || 0, this.padding = t, this.initialItemY = t - 5, this.symbolWidth = a(
o.symbolWidth,
16
), this.pages = [], this.proximate = o.layout === "proximate" && !this.chart.inverted, this.baseline = void 0;
}, h.prototype.update = function(o, t) {
var s = this.chart;
this.setOptions(x(!0, this.options, o)), this.destroy(), s.isDirtyLegend = s.isDirtyBox = !0, a(t, !0) && s.redraw(), b(this, "afterUpdate");
}, h.prototype.colorizeItem = function(o, t) {
if (o.legendGroup[t ? "removeClass" : "addClass"]("highcharts-legend-item-hidden"), !this.chart.styledMode) {
var s = this.options, n = o.legendItem, A = o.legendLine, _ = o.legendSymbol, D = this.itemHiddenStyle.color;
s = t ? s.itemStyle.color : D;
var W = t && o.color || D, P = o.options && o.options.marker, X = { fill: W };
n && n.css({ fill: s, color: s }), A && A.attr({ stroke: W }), _ && (P && _.isMarker && (X = o.pointAttribs(), t || (X.stroke = X.fill = D)), _.attr(X));
}
b(this, "afterColorizeItem", { item: o, visible: t });
}, h.prototype.positionItems = function() {
this.allItems.forEach(this.positionItem, this), this.chart.isResizing || this.positionCheckboxes();
}, h.prototype.positionItem = function(o) {
var t = this, s = this.options, n = s.symbolPadding, A = !s.rtl, _ = o._legendItemPos;
s = _[0], _ = _[1];
var D = o.checkbox, W = o.legendGroup;
W && W.element && (n = { translateX: A ? s : this.legendWidth - s - 2 * n - 4, translateY: _ }, A = function() {
b(t, "afterPositionItem", { item: o });
}, O(W.translateY) ? W.animate(n, void 0, A) : (W.attr(n), A())), D && (D.x = s, D.y = _);
}, h.prototype.destroyItem = function(o) {
var t = o.checkbox;
["legendItem", "legendLine", "legendSymbol", "legendGroup"].forEach(function(s) {
o[s] && (o[s] = o[s].destroy());
}), t && B(o.checkbox);
}, h.prototype.destroy = function() {
function o(t) {
this[t] && (this[t] = this[t].destroy());
}
this.getAllItems().forEach(function(t) {
[
"legendItem",
"legendGroup"
].forEach(o, t);
}), "clipRect up down pager nav box title group".split(" ").forEach(o, this), this.display = null;
}, h.prototype.positionCheckboxes = function() {
var o = this.group && this.group.alignAttr, t = this.clipHeight || this.legendHeight, s = this.titleHeight;
if (o) {
var n = o.translateY;
this.allItems.forEach(function(A) {
var _ = A.checkbox;
if (_) {
var D = n + s + _.y + (this.scrollOffset || 0) + 3;
T(_, { left: o.translateX + A.checkboxOffset + _.x - 20 + "px", top: D + "px", display: this.proximate || D > n - 6 && D < n + t - 6 ? "" : "none" });
}
}, this);
}
}, h.prototype.renderTitle = function() {
var o = this.options, t = this.padding, s = o.title, n = 0;
s.text && (this.title || (this.title = this.chart.renderer.label(s.text, t - 3, t - 4, null, null, null, o.useHTML, null, "legend-title").attr({ zIndex: 1 }), this.chart.styledMode || this.title.css(s.style), this.title.add(this.group)), s.width || this.title.css({ width: this.maxLegendWidth + "px" }), o = this.title.getBBox(), n = o.height, this.offsetWidth = o.width, this.contentGroup.attr({ translateY: n })), this.titleHeight = n;
}, h.prototype.setText = function(o) {
var t = this.options;
o.legendItem.attr({ text: t.labelFormat ? R(t.labelFormat, o, this.chart) : t.labelFormatter.call(o) });
}, h.prototype.renderItem = function(o) {
var t = this.chart, s = t.renderer, n = this.options, A = this.symbolWidth, _ = n.symbolPadding || 0, D = this.itemStyle, W = this.itemHiddenStyle, P = n.layout === "horizontal" ? a(n.itemDistance, 20) : 0, X = !n.rtl, g = !o.series, m = !g && o.series.drawLegendSymbol ? o.series : o, L = m.options, Y = this.createCheckboxForItem && L && L.showCheckbox, V = n.useHTML, Q = o.options.className, k = o.legendItem;
L = A + _ + P + (Y ? 20 : 0), k || (o.legendGroup = s.g("legend-item").addClass("highcharts-" + m.type + "-series highcharts-color-" + o.colorIndex + (Q ? " " + Q : "") + (g ? " highcharts-series-" + o.index : "")).attr({ zIndex: 1 }).add(this.scrollGroup), o.legendItem = k = s.text("", X ? A + _ : -_, this.baseline || 0, V), t.styledMode || k.css(x(o.visible ? D : W)), k.attr({ align: X ? "left" : "right", zIndex: 2 }).add(o.legendGroup), this.baseline || (this.fontMetrics = s.fontMetrics(t.styledMode ? 12 : D.fontSize, k), this.baseline = this.fontMetrics.f + 3 + this.itemMarginTop, k.attr("y", this.baseline), this.symbolHeight = n.symbolHeight || this.fontMetrics.f, n.squareSymbol && (this.symbolWidth = a(n.symbolWidth, Math.max(this.symbolHeight, 16)), L = this.symbolWidth + _ + P + (Y ? 20 : 0), X && k.attr("x", this.symbolWidth + _))), m.drawLegendSymbol(this, o), this.setItemEvents && this.setItemEvents(o, k, V)), Y && !o.checkbox && this.createCheckboxForItem && this.createCheckboxForItem(o), this.colorizeItem(o, o.visible), !t.styledMode && D.width || k.css({ width: (n.itemWidth || this.widthOption || t.spacingBox.width) - L + "px" }), this.setText(o), t = k.getBBox(), s = this.fontMetrics && this.fontMetrics.h || 0, o.itemWidth = o.checkboxOffset = n.itemWidth || o.legendItemWidth || t.width + L, this.maxItemWidth = Math.max(this.maxItemWidth, o.itemWidth), this.totalItemWidth += o.itemWidth, this.itemHeight = o.itemHeight = Math.round(o.legendItemHeight || (t.height > 1.5 * s ? t.height : s));
}, h.prototype.layoutItem = function(o) {
var t = this.options, s = this.padding, n = t.layout === "horizontal", A = o.itemHeight, _ = this.itemMarginBottom, D = this.itemMarginTop, W = n ? a(t.itemDistance, 20) : 0, P = this.maxLegendWidth;
t = t.alignColumns && this.totalItemWidth > P ? this.maxItemWidth : o.itemWidth, n && this.itemX - s + t > P && (this.itemX = s, this.lastLineHeight && (this.itemY += D + this.lastLineHeight + _), this.lastLineHeight = 0), this.lastItemY = D + this.itemY + _, this.lastLineHeight = Math.max(A, this.lastLineHeight), o._legendItemPos = [this.itemX, this.itemY], n ? this.itemX += t : (this.itemY += D + A + _, this.lastLineHeight = A), this.offsetWidth = this.widthOption || Math.max((n ? this.itemX - s - (o.checkbox ? 0 : W) : t) + s, this.offsetWidth);
}, h.prototype.getAllItems = function() {
var o = [];
return this.chart.series.forEach(function(t) {
var s = t && t.options;
t && a(s.showInLegend, O(s.linkedTo) ? !1 : void 0, !0) && (o = o.concat(t.legendItems || (s.legendType === "point" ? t.data : t)));
}), b(this, "afterGetAllItems", { allItems: o }), o;
}, h.prototype.getAlignment = function() {
var o = this.options;
return this.proximate ? o.align.charAt(0) + "tv" : o.floating ? "" : o.align.charAt(0) + o.verticalAlign.charAt(0) + o.layout.charAt(0);
}, h.prototype.adjustMargins = function(o, t) {
var s = this.chart, n = this.options, A = this.getAlignment();
A && [/(lth|ct|rth)/, /(rtv|rm|rbv)/, /(rbh|cb|lbh)/, /(lbv|lm|ltv)/].forEach(function(_, D) {
_.test(A) && !O(o[D]) && (s[S[D]] = Math.max(s[S[D]], s.legend[(D + 1) % 2 ? "legendHeight" : "legendWidth"] + [1, -1, -1, 1][D] * n[D % 2 ? "x" : "y"] + a(n.margin, 12) + t[D] + (s.titleOffset[D] || 0)));
});
}, h.prototype.proximatePositions = function() {
var o = this.chart, t = [], s = this.options.align === "left";
this.allItems.forEach(function(n) {
var A, _ = s;
if (n.yAxis) {
n.xAxis.options.reversed && (_ = !_), n.points && (A = C(_ ? n.points : n.points.slice(0).reverse(), function(W) {
return w(W.plotY);
})), _ = this.itemMarginTop + n.legendItem.getBBox().height + this.itemMarginBottom;
var D = n.yAxis.top - o.plotTop;
n.visible ? (A = A ? A.plotY : n.yAxis.height, A += D - 0.3 * _) : A = D + n.yAxis.height, t.push({ target: A, size: _, item: n });
}
}, this), v(t, o.plotHeight).forEach(function(n) {
n.item._legendItemPos && (n.item._legendItemPos[1] = o.plotTop - o.spacing[0] + n.pos);
});
}, h.prototype.render = function() {
var o = this.chart, t = o.renderer, s = this.options, n = this.padding, A = this.getAllItems(), _ = this.group, D = this.box;
this.itemX = n, this.itemY = this.initialItemY, this.lastItemY = this.offsetWidth = 0, this.widthOption = c(s.width, o.spacingBox.width - n);
var W = o.spacingBox.width - 2 * n - s.x;
-1 < ["rm", "lm"].indexOf(this.getAlignment().substring(0, 2)) && (W /= 2), this.maxLegendWidth = this.widthOption || W, _ || (this.group = _ = t.g("legend").addClass(s.className || "").attr({ zIndex: 7 }).add(), this.contentGroup = t.g().attr({ zIndex: 1 }).add(_), this.scrollGroup = t.g().add(this.contentGroup)), this.renderTitle(), p(A, function(X, g) {
return (X.options && X.options.legendIndex || 0) - (g.options && g.options.legendIndex || 0);
}), s.reversed && A.reverse(), this.allItems = A, this.display = W = !!A.length, this.itemHeight = this.totalItemWidth = this.maxItemWidth = this.lastLineHeight = 0, A.forEach(this.renderItem, this), A.forEach(this.layoutItem, this), A = (this.widthOption || this.offsetWidth) + n;
var P = this.lastItemY + this.lastLineHeight + this.titleHeight;
P = this.handleOverflow(P), P += n, D || (this.box = D = t.rect().addClass("highcharts-legend-box").attr({ r: s.borderRadius }).add(_), D.isNew = !0), o.styledMode || D.attr({ stroke: s.borderColor, "stroke-width": s.borderWidth || 0, fill: s.backgroundColor || "none" }).shadow(s.shadow), 0 < A && 0 < P && (D[D.isNew ? "attr" : "animate"](D.crisp.call({}, { x: 0, y: 0, width: A, height: P }, D.strokeWidth())), D.isNew = !1), D[W ? "show" : "hide"](), o.styledMode && _.getStyle("display") === "none" && (A = P = 0), this.legendWidth = A, this.legendHeight = P, W && this.align(), this.proximate || this.positionItems(), b(this, "afterRender");
}, h.prototype.align = function(o) {
o === void 0 && (o = this.chart.spacingBox);
var t = this.chart, s = this.options, n = o.y;
/(lth|ct|rth)/.test(this.getAlignment()) && 0 < t.titleOffset[0] ? n += t.titleOffset[0] : /(lbh|cb|rbh)/.test(this.getAlignment()) && 0 < t.titleOffset[2] && (n -= t.titleOffset[2]), n !== o.y && (o = x(o, { y: n })), this.group.align(x(s, { width: this.legendWidth, height: this.legendHeight, verticalAlign: this.proximate ? "top" : s.verticalAlign }), !0, o);
}, h.prototype.handleOverflow = function(o) {
var t = this, s = this.chart, n = s.renderer, A = this.options, _ = A.y, D = A.verticalAlign === "top", W = this.padding, P = A.maxHeight, X = A.navigation, g = a(X.animation, !0), m = X.arrowSize || 12, L = this.pages, Y = this.allItems, V = function(q) {
typeof q == "number" ? $.attr({ height: q }) : $ && (t.clipRect = $.destroy(), t.contentGroup.clip()), t.contentGroup.div && (t.contentGroup.div.style.clip = q ? "rect(" + W + "px,9999px," + (W + q) + "px,0)" : "auto");
}, Q = function(q) {
return t[q] = n.circle(0, 0, 1.3 * m).translate(m / 2, m / 2).add(z), s.styledMode || t[q].attr("fill", "rgba(0,0,0,0.0001)"), t[q];
}, k, G;
_ = s.spacingBox.height + (D ? -_ : _) - W;
var z = this.nav, $ = this.clipRect;
return A.layout !== "horizontal" || A.verticalAlign === "middle" || A.floating || (_ /= 2), P && (_ = Math.min(_, P)), L.length = 0, o && 0 < _ && o > _ && X.enabled !== !1 ? (this.clipHeight = k = Math.max(_ - 20 - this.titleHeight - W, 0), this.currentPage = a(this.currentPage, 1), this.fullHeight = o, Y.forEach(function(q, it) {
var et = q._legendItemPos[1], nt = Math.round(q.legendItem.getBBox().height), rt = L.length;
(!rt || et - L[rt - 1] > k && (G || et) !== L[rt - 1]) && (L.push(G || et), rt++), q.pageIx = rt - 1, G && (Y[it - 1].pageIx = rt - 1), it === Y.length - 1 && et + nt - L[rt - 1] > k && nt <= k && (L.push(et), q.pageIx = rt), et !== G && (G = et);
}), $ || ($ = t.clipRect = n.clipRect(0, W, 9999, 0), t.contentGroup.clip($)), V(k), z || (this.nav = z = n.g().attr({ zIndex: 1 }).add(this.group), this.up = n.symbol("triangle", 0, 0, m, m).add(z), Q("upTracker").on(
"click",
function() {
t.scroll(-1, g);
}
), this.pager = n.text("", 15, 10).addClass("highcharts-legend-navigation"), s.styledMode || this.pager.css(X.style), this.pager.add(z), this.down = n.symbol("triangle-down", 0, 0, m, m).add(z), Q("downTracker").on("click", function() {
t.scroll(1, g);
})), t.scroll(0), o = _) : z && (V(), this.nav = z.destroy(), this.scrollGroup.attr({ translateY: 1 }), this.clipHeight = 0), o;
}, h.prototype.scroll = function(o, t) {
var s = this, n = this.chart, A = this.pages, _ = A.length, D = this.clipHeight, W = this.options.navigation, P = this.pager, X = this.padding, g = this.currentPage + o;
g > _ && (g = _), 0 < g && (typeof t < "u" && N(t, n), this.nav.attr({ translateX: X, translateY: D + this.padding + 7 + this.titleHeight, visibility: "visible" }), [this.up, this.upTracker].forEach(function(m) {
m.attr({ class: g === 1 ? "highcharts-legend-nav-inactive" : "highcharts-legend-nav-active" });
}), P.attr({ text: g + "/" + _ }), [this.down, this.downTracker].forEach(
function(m) {
m.attr({ x: 18 + this.pager.getBBox().width, class: g === _ ? "highcharts-legend-nav-inactive" : "highcharts-legend-nav-active" });
},
this
), n.styledMode || (this.up.attr({ fill: g === 1 ? W.inactiveColor : W.activeColor }), this.upTracker.css({ cursor: g === 1 ? "default" : "pointer" }), this.down.attr({ fill: g === _ ? W.inactiveColor : W.activeColor }), this.downTracker.css({ cursor: g === _ ? "default" : "pointer" })), this.scrollOffset = -A[g - 1] + this.initialItemY, this.scrollGroup.animate({ translateY: this.scrollOffset }), this.currentPage = g, this.positionCheckboxes(), o = F(a(t, n.renderer.globalAnimation, !0)), i(function() {
b(s, "afterScroll", { currentPage: g });
}, o.duration));
}, h.prototype.setItemEvents = function(o, t, s) {
var n = this, A = n.chart.renderer.boxWrapper, _ = o instanceof Z, D = "highcharts-legend-" + (_ ? "point" : "series") + "-active", W = n.chart.styledMode, P = function(X) {
n.allItems.forEach(function(g) {
o !== g && [g].concat(g.linkedSeries || []).forEach(function(m) {
m.setState(X, !_);
});
});
};
(s ? [t, o.legendSymbol] : [o.legendGroup]).forEach(function(X) {
X && X.on("mouseover", function() {
o.visible && P("inactive"), o.setState("hover"), o.visible && A.addClass(D), W || t.css(n.options.itemHoverStyle);
}).on("mouseout", function() {
n.chart.styledMode || t.css(x(o.visible ? n.itemStyle : n.itemHiddenStyle)), P(""), A.removeClass(D), o.setState();
}).on("click", function(g) {
var m = function() {
o.setVisible && o.setVisible(), P(o.visible ? "inactive" : "");
};
A.removeClass(D), g = { browserEvent: g }, o.firePointEvent ? o.firePointEvent("legendItemClick", g, m) : b(o, "legendItemClick", g, m);
});
});
}, h.prototype.createCheckboxForItem = function(o) {
o.checkbox = u(
"input",
{ type: "checkbox", className: "highcharts-legend-checkbox", checked: o.selected, defaultChecked: o.selected },
this.options.itemCheckboxStyle,
this.chart.container
), d(o.checkbox, "click", function(t) {
b(o.series || o, "checkboxClick", { checked: t.target.checked, item: o }, function() {
o.select();
});
});
}, h;
}(), (/Trident\/7\.0/.test(I.navigator && I.navigator.userAgent) || y) && H(U.prototype, "positionItem", function(h, o) {
var t = this, s = function() {
o._legendItemPos && h.call(t, o);
};
s(), t.bubbleLegend || setTimeout(s);
}), U;
}), E(
l,
"Core/Series/SeriesRegistry.js",
[l["Core/Globals.js"], l["Core/DefaultOptions.js"], l["Core/Series/Point.js"], l["Core/Utilities.js"]],
function(y, j, I, Z) {
var H = j.defaultOptions, U = Z.error, F = Z.extendClass, N = Z.merge, R;
return function(S) {
function v(d, u) {
var T = H.plotOptions || {}, O = u.defaultOptions;
u.prototype.pointClass || (u.prototype.pointClass = I), u.prototype.type = d, O && (T[d] = O), S.seriesTypes[d] = u;
}
S.seriesTypes = y.seriesTypes, S.getSeries = function(d, u) {
u === void 0 && (u = {});
var T = d.options.chart;
T = u.type || T.type || T.defaultSeriesType || "";
var O = S.seriesTypes[T];
return S || U(17, !0, d, { missingModuleFor: T }), T = new O(), typeof T.init == "function" && T.init(d, u), T;
}, S.registerSeriesType = v, S.seriesType = function(d, u, T, O, B) {
var C = H.plotOptions || {};
return u = u || "", C[d] = N(C[u], T), v(d, F(S.seriesTypes[u] || function() {
}, O)), S.seriesTypes[d].prototype.type = d, B && (S.seriesTypes[d].prototype.pointClass = F(I, B)), S.seriesTypes[d];
};
}(R || (R = {})), R;
}
), E(l, "Core/Chart/Chart.js", [
l["Core/Animation/AnimationUtilities.js"],
l["Core/Axis/Axis.js"],
l["Core/FormatUtilities.js"],
l["Core/Foundation.js"],
l["Core/Globals.js"],
l["Core/Legend/Legend.js"],
l["Core/MSPointer.js"],
l["Core/DefaultOptions.js"],
l["Core/Pointer.js"],
l["Core/Renderer/RendererRegistry.js"],
l["Core/Series/SeriesRegistry.js"],
l["Core/Renderer/SVG/SVGRenderer.js"],
l["Core/Time.js"],
l["Core/Utilities.js"],
l["Core/Renderer/HTML/AST.js"]
], function(y, j, I, Z, H, U, F, N, R, S, v, d, u, T, O) {
var B = y.animate, C = y.animObject, b = y.setAnimation, w = I.numberFormat, x = Z.registerEventOptions, a = H.charts, c = H.doc, p = H.marginNames, i = H.svg, h = H.win, o = N.defaultOptions, t = N.defaultTime, s = v.seriesTypes, n = T.addEvent, A = T.attr, _ = T.cleanRecursively, D = T.createElement, W = T.css, P = T.defined, X = T.discardElement, g = T.erase, m = T.error, L = T.extend, Y = T.find, V = T.fireEvent, Q = T.getStyle, k = T.isArray, G = T.isNumber, z = T.isObject, $ = T.isString, q = T.merge, it = T.objectEach, et = T.pick, nt = T.pInt, rt = T.relativeLength, ct = T.removeEvent, gt = T.splat, dt = T.syncTimeout, ht = T.uniqueKey;
return y = function() {
function at(J, tt, ot) {
this.series = this.renderTo = this.renderer = this.pointer = this.pointCount = this.plotWidth = this.plotTop = this.plotLeft = this.plotHeight = this.plotBox = this.options = this.numberFormatter = this.margin = this.legend = this.labelCollectors = this.isResizing = this.index = this.eventOptions = this.container = this.colorCounter = this.clipBox = this.chartWidth = this.chartHeight = this.bounds = this.axisOffset = this.axes = void 0, this.sharedClips = {}, this.yAxis = this.xAxis = this.userOptions = this.titleOffset = this.time = this.symbolCounter = this.spacingBox = this.spacing = void 0, this.getArgs(J, tt, ot);
}
return at.chart = function(J, tt, ot) {
return new at(J, tt, ot);
}, at.prototype.getArgs = function(J, tt, ot) {
$(J) || J.nodeName ? (this.renderTo = J, this.init(tt, ot)) : this.init(J, tt);
}, at.prototype.init = function(J, tt) {
var ot = J.plotOptions || {};
V(this, "init", { args: arguments }, function() {
var lt = q(o, J), pt = lt.chart;
it(lt.plotOptions, function(yt, vt) {
z(yt) && (yt.tooltip = ot[vt] && q(ot[vt].tooltip) || void 0);
}), lt.tooltip.userOptions = J.chart && J.chart.forExport && J.tooltip.userOptions || J.tooltip, this.userOptions = J, this.margin = [], this.spacing = [], this.bounds = { h: {}, v: {} }, this.labelCollectors = [], this.callback = tt, this.isResizing = 0, this.options = lt, this.axes = [], this.series = [], this.time = J.time && Object.keys(J.time).length ? new u(J.time) : H.time, this.numberFormatter = pt.numberFormatter || w, this.styledMode = pt.styledMode, this.hasCartesianSeries = pt.showAxes, this.index = a.length, a.push(this), H.chartCount++, x(this, pt), this.xAxis = [], this.yAxis = [], this.pointCount = this.colorCounter = this.symbolCounter = 0, V(this, "afterInit"), this.firstRender();
});
}, at.prototype.initSeries = function(J) {
var tt = this.options.chart;
tt = J.type || tt.type || tt.defaultSeriesType;
var ot = s[tt];
return ot || m(17, !0, this, { missingModuleFor: tt }), tt = new ot(), typeof tt.init == "function" && tt.init(this, J), tt;
}, at.prototype.setSeriesData = function() {
this.getSeriesOrderByLinks().forEach(function(J) {
J.points || J.data || !J.enabledDataSorting || J.setData(J.options.data, !1);
});
}, at.prototype.getSeriesOrderByLinks = function() {
return this.series.concat().sort(function(J, tt) {
return J.linkedSeries.length || tt.linkedSeries.length ? tt.linkedSeries.length - J.linkedSeries.length : 0;
});
}, at.prototype.orderSeries = function(J) {
var tt = this.series;
J = J || 0;
for (var ot = tt.length; J < ot; ++J)
tt[J] && (tt[J].index = J, tt[J].name = tt[J].getName());
}, at.prototype.isInsidePlot = function(J, tt, ot) {
ot === void 0 && (ot = {});
var lt = this.inverted, pt = this.plotBox, yt = this.plotLeft, vt = this.plotTop, Ct = this.scrollablePlotBox, Pt = 0, At = 0;
ot.visiblePlotOnly && this.scrollingContainer && (At = this.scrollingContainer, Pt = At.scrollLeft, At = At.scrollTop);
var St = ot.series;
if (pt = ot.visiblePlotOnly && Ct || pt, Ct = ot.inverted ? tt : J, tt = ot.inverted ? J : tt, J = { x: Ct, y: tt, isInsidePlot: !0 }, !ot.ignoreX) {
var Dt = St && (lt ? St.yAxis : St.xAxis) || { pos: yt, len: 1 / 0 };
Ct = ot.paneCoordinates ? Dt.pos + Ct : yt + Ct, Ct >= Math.max(Pt + yt, Dt.pos) && Ct <= Math.min(Pt + yt + pt.width, Dt.pos + Dt.len) || (J.isInsidePlot = !1);
}
return !ot.ignoreY && J.isInsidePlot && (lt = St && (lt ? St.xAxis : St.yAxis) || { pos: vt, len: 1 / 0 }, ot = ot.paneCoordinates ? lt.pos + tt : vt + tt, ot >= Math.max(At + vt, lt.pos) && ot <= Math.min(At + vt + pt.height, lt.pos + lt.len) || (J.isInsidePlot = !1)), V(this, "afterIsInsidePlot", J), J.isInsidePlot;
}, at.prototype.redraw = function(J) {
V(this, "beforeRedraw");
var tt = this.hasCartesianSeries ? this.axes : this.colorAxis || [], ot = this.series, lt = this.pointer, pt = this.legend, yt = this.userOptions.legend, vt = this.renderer, Ct = vt.isHidden(), Pt = [], At = this.isDirtyBox, St = this.isDirtyLegend;
for (this.setResponsive && this.setResponsive(!1), b(this.hasRendered ? J : !1, this), Ct && this.temporaryDisplay(), this.layOutTitles(), J = ot.length; J--; ) {
var Dt = ot[J];
if (Dt.options.stacking || Dt.options.centerInCategory) {
var Lt = !0;
if (Dt.isDirty) {
var Nt = !0;
break;
}
}
}
if (Nt)
for (J = ot.length; J--; )
Dt = ot[J], Dt.options.stacking && (Dt.isDirty = !0);
ot.forEach(function(Et) {
Et.isDirty && (Et.options.legendType === "point" ? (typeof Et.updateTotals == "function" && Et.updateTotals(), St = !0) : yt && (yt.labelFormatter || yt.labelFormat) && (St = !0)), Et.isDirtyData && V(Et, "updatedData");
}), St && pt && pt.options.enabled && (pt.render(), this.isDirtyLegend = !1), Lt && this.getStacks(), tt.forEach(function(Et) {
Et.updateNames(), Et.setScale();
}), this.getMargins(), tt.forEach(function(Et) {
Et.isDirty && (At = !0);
}), tt.forEach(function(Et) {
var Kt = Et.min + "," + Et.max;
Et.extKey !== Kt && (Et.extKey = Kt, Pt.push(function() {
V(Et, "afterSetExtremes", L(Et.eventArgs, Et.getExtremes())), delete Et.eventArgs;
})), (At || Lt) && Et.redraw();
}), At && this.drawChartBox(), V(this, "predraw"), ot.forEach(function(Et) {
(At || Et.isDirty) && Et.visible && Et.redraw(), Et.isDirtyData = !1;
}), lt && lt.reset(!0), vt.draw(), V(this, "redraw"), V(this, "render"), Ct && this.temporaryDisplay(!0), Pt.forEach(function(Et) {
Et.call();
});
}, at.prototype.get = function(J) {
function tt(yt) {
return yt.id === J || yt.options && yt.options.id === J;
}
for (var ot = this.series, lt = Y(this.axes, tt) || Y(this.series, tt), pt = 0; !lt && pt < ot.length; pt++)
lt = Y(ot[pt].points || [], tt);
return lt;
}, at.prototype.getAxes = function() {
var J = this, tt = this.options, ot = tt.xAxis = gt(tt.xAxis || {});
tt = tt.yAxis = gt(tt.yAxis || {}), V(this, "getAxes"), ot.forEach(function(lt, pt) {
lt.index = pt, lt.isX = !0;
}), tt.forEach(function(lt, pt) {
lt.index = pt;
}), ot.concat(tt).forEach(function(lt) {
new j(J, lt);
}), V(this, "afterGetAxes");
}, at.prototype.getSelectedPoints = function() {
return this.series.reduce(function(J, tt) {
return tt.getPointsCollection().forEach(function(ot) {
et(ot.selectedStaging, ot.selected) && J.push(ot);
}), J;
}, []);
}, at.prototype.getSelectedSeries = function() {
return this.series.filter(function(J) {
return J.selected;
});
}, at.prototype.setTitle = function(J, tt, ot) {
this.applyDescription("title", J), this.applyDescription("subtitle", tt), this.applyDescription(
"caption",
void 0
), this.layOutTitles(ot);
}, at.prototype.applyDescription = function(J, tt) {
var ot = this, lt = J === "title" ? { color: "#333333", fontSize: this.options.isStock ? "16px" : "18px" } : { color: "#666666" };
lt = this.options[J] = q(!this.styledMode && { style: lt }, this.options[J], tt);
var pt = this[J];
pt && tt && (this[J] = pt = pt.destroy()), lt && !pt && (pt = this.renderer.text(lt.text, 0, 0, lt.useHTML).attr({ align: lt.align, class: "highcharts-" + J, zIndex: lt.zIndex || 4 }).add(), pt.update = function(yt) {
ot[{ title: "setTitle", subtitle: "setSubtitle", caption: "setCaption" }[J]](yt);
}, this.styledMode || pt.css(lt.style), this[J] = pt);
}, at.prototype.layOutTitles = function(J) {
var tt = [0, 0, 0], ot = this.renderer, lt = this.spacingBox;
["title", "subtitle", "caption"].forEach(function(yt) {
var vt = this[yt], Ct = this.options[yt], Pt = Ct.verticalAlign || "top";
yt = yt === "title" ? Pt === "top" ? -3 : 0 : Pt === "top" ? tt[0] + 2 : 0;
var At;
if (vt) {
this.styledMode || (At = Ct.style && Ct.style.fontSize), At = ot.fontMetrics(At, vt).b, vt.css({ width: (Ct.width || lt.width + (Ct.widthAdjust || 0)) + "px" });
var St = Math.round(vt.getBBox(Ct.useHTML).height);
vt.align(L({ y: Pt === "bottom" ? At : yt + At, height: St }, Ct), !1, "spacingBox"), Ct.floating || (Pt === "top" ? tt[0] = Math.ceil(tt[0] + St) : Pt === "bottom" && (tt[2] = Math.ceil(tt[2] + St)));
}
}, this), tt[0] && (this.options.title.verticalAlign || "top") === "top" && (tt[0] += this.options.title.margin), tt[2] && this.options.caption.verticalAlign === "bottom" && (tt[2] += this.options.caption.margin);
var pt = !this.titleOffset || this.titleOffset.join(",") !== tt.join(",");
this.titleOffset = tt, V(this, "afterLayOutTitles"), !this.isDirtyBox && pt && (this.isDirtyBox = this.isDirtyLegend = pt, this.hasRendered && et(J, !0) && this.isDirtyBox && this.redraw());
}, at.prototype.getChartSize = function() {
var J = this.options.chart, tt = J.width;
J = J.height;
var ot = this.renderTo;
P(tt) || (this.containerWidth = Q(ot, "width")), P(J) || (this.containerHeight = Q(ot, "height")), this.chartWidth = Math.max(0, tt || this.containerWidth || 600), this.chartHeight = Math.max(0, rt(J, this.chartWidth) || (1 < this.containerHeight ? this.containerHeight : 400));
}, at.prototype.temporaryDisplay = function(J) {
var tt = this.renderTo;
if (J)
for (; tt && tt.style; )
tt.hcOrigStyle && (W(tt, tt.hcOrigStyle), delete tt.hcOrigStyle), tt.hcOrigDetached && (c.body.removeChild(tt), tt.hcOrigDetached = !1), tt = tt.parentNode;
else
for (; tt && tt.style && (c.body.contains(tt) || tt.parentNode || (tt.hcOrigDetached = !0, c.body.appendChild(tt)), (Q(tt, "display", !1) === "none" || tt.hcOricDetached) && (tt.hcOrigStyle = { display: tt.style.display, height: tt.style.height, overflow: tt.style.overflow }, J = { display: "block", overflow: "hidden" }, tt !== this.renderTo && (J.height = 0), W(tt, J), tt.offsetWidth || tt.style.setProperty("display", "block", "important")), tt = tt.parentNode, tt !== c.body); )
;
}, at.prototype.setClassName = function(J) {
this.container.className = "highcharts-container " + (J || "");
}, at.prototype.getContainer = function() {
var J = this.options, tt = J.chart, ot = ht(), lt, pt = this.renderTo;
pt || (this.renderTo = pt = tt.renderTo), $(pt) && (this.renderTo = pt = c.getElementById(pt)), pt || m(13, !0, this);
var yt = nt(A(pt, "data-highcharts-chart"));
G(yt) && a[yt] && a[yt].hasRendered && a[yt].destroy(), A(pt, "data-highcharts-chart", this.index), pt.innerHTML = O.emptyHTML, tt.skipClone || pt.offsetWidth || this.temporaryDisplay(), this.getChartSize(), yt = this.chartWidth;
var vt = this.chartHeight;
if (W(pt, { overflow: "hidden" }), this.styledMode || (lt = L({ position: "relative", overflow: "hidden", width: yt + "px", height: vt + "px", textAlign: "left", lineHeight: "normal", zIndex: 0, "-webkit-tap-highlight-color": "rgba(0,0,0,0)", userSelect: "none", "touch-action": "manipulation", outline: "none" }, tt.style || {})), this.container = ot = D("div", { id: ot }, lt, pt), this._cursor = ot.style.cursor, this.renderer = new (tt.renderer || !i ? S.getRendererType(tt.renderer) : d)(ot, yt, vt, void 0, tt.forExport, J.exporting && J.exporting.allowHTML, this.styledMode), b(
void 0,
this
), this.setClassName(tt.className), this.styledMode)
for (var Ct in J.defs)
this.renderer.definition(J.defs[Ct]);
else
this.renderer.setStyle(tt.style);
this.renderer.chartIndex = this.index, V(this, "afterGetContainer");
}, at.prototype.getMargins = function(J) {
var tt = this.spacing, ot = this.margin, lt = this.titleOffset;
this.resetMargins(), lt[0] && !P(ot[0]) && (this.plotTop = Math.max(this.plotTop, lt[0] + tt[0])), lt[2] && !P(ot[2]) && (this.marginBottom = Math.max(this.marginBottom, lt[2] + tt[2])), this.legend && this.legend.display && this.legend.adjustMargins(
ot,
tt
), V(this, "getMargins"), J || this.getAxisMargins();
}, at.prototype.getAxisMargins = function() {
var J = this, tt = J.axisOffset = [0, 0, 0, 0], ot = J.colorAxis, lt = J.margin, pt = function(yt) {
yt.forEach(function(vt) {
vt.visible && vt.getOffset();
});
};
J.hasCartesianSeries ? pt(J.axes) : ot && ot.length && pt(ot), p.forEach(function(yt, vt) {
P(lt[vt]) || (J[yt] += tt[vt]);
}), J.setChartSize();
}, at.prototype.reflow = function(J) {
var tt = this, ot = tt.options.chart, lt = tt.renderTo, pt = P(ot.width) && P(ot.height), yt = ot.width || Q(lt, "width");
ot = ot.height || Q(lt, "height"), lt = J ? J.target : h, delete tt.pointer.chartPosition, !pt && !tt.isPrinting && yt && ot && (lt === h || lt === c) && ((yt !== tt.containerWidth || ot !== tt.containerHeight) && (T.clearTimeout(tt.reflowTimeout), tt.reflowTimeout = dt(function() {
tt.container && tt.setSize(void 0, void 0, !1);
}, J ? 100 : 0)), tt.containerWidth = yt, tt.containerHeight = ot);
}, at.prototype.setReflow = function(J) {
var tt = this;
J === !1 || this.unbindReflow ? J === !1 && this.unbindReflow && (this.unbindReflow = this.unbindReflow()) : (this.unbindReflow = n(h, "resize", function(ot) {
tt.options && tt.reflow(ot);
}), n(this, "destroy", this.unbindReflow));
}, at.prototype.setSize = function(J, tt, ot) {
var lt = this, pt = lt.renderer;
lt.isResizing += 1, b(ot, lt), ot = pt.globalAnimation, lt.oldChartHeight = lt.chartHeight, lt.oldChartWidth = lt.chartWidth, typeof J < "u" && (lt.options.chart.width = J), typeof tt < "u" && (lt.options.chart.height = tt), lt.getChartSize(), lt.styledMode || (ot ? B : W)(lt.container, { width: lt.chartWidth + "px", height: lt.chartHeight + "px" }, ot), lt.setChartSize(!0), pt.setSize(lt.chartWidth, lt.chartHeight, ot), lt.axes.forEach(function(yt) {
yt.isDirty = !0, yt.setScale();
}), lt.isDirtyLegend = !0, lt.isDirtyBox = !0, lt.layOutTitles(), lt.getMargins(), lt.redraw(ot), lt.oldChartHeight = null, V(lt, "resize"), dt(function() {
lt && V(lt, "endResize", null, function() {
--lt.isResizing;
});
}, C(ot).duration);
}, at.prototype.setChartSize = function(J) {
var tt = this.inverted, ot = this.renderer, lt = this.chartWidth, pt = this.chartHeight, yt = this.options.chart, vt = this.spacing, Ct = this.clipOffset, Pt, At, St, Dt;
this.plotLeft = Pt = Math.round(this.plotLeft), this.plotTop = At = Math.round(this.plotTop), this.plotWidth = St = Math.max(0, Math.round(lt - Pt - this.marginRight)), this.plotHeight = Dt = Math.max(0, Math.round(pt - At - this.marginBottom)), this.plotSizeX = tt ? Dt : St, this.plotSizeY = tt ? St : Dt, this.plotBorderWidth = yt.plotBorderWidth || 0, this.spacingBox = ot.spacingBox = { x: vt[3], y: vt[0], width: lt - vt[3] - vt[1], height: pt - vt[0] - vt[2] }, this.plotBox = ot.plotBox = { x: Pt, y: At, width: St, height: Dt }, tt = 2 * Math.floor(this.plotBorderWidth / 2), lt = Math.ceil(Math.max(tt, Ct[3]) / 2), pt = Math.ceil(Math.max(tt, Ct[0]) / 2), this.clipBox = { x: lt, y: pt, width: Math.floor(this.plotSizeX - Math.max(tt, Ct[1]) / 2 - lt), height: Math.max(0, Math.floor(this.plotSizeY - Math.max(tt, Ct[2]) / 2 - pt)) }, J || (this.axes.forEach(function(Lt) {
Lt.setAxisSize(), Lt.setAxisTranslation();
}), ot.alignElements()), V(this, "afterSetChartSize", { skipAxes: J });
}, at.prototype.resetMargins = function() {
V(this, "resetMargins");
var J = this, tt = J.options.chart;
["margin", "spacing"].forEach(function(ot) {
var lt = tt[ot], pt = z(lt) ? lt : [lt, lt, lt, lt];
["Top", "Right", "Bottom", "Left"].forEach(function(yt, vt) {
J[ot][vt] = et(tt[ot + yt], pt[vt]);
});
}), p.forEach(function(ot, lt) {
J[ot] = et(J.margin[lt], J.spacing[lt]);
}), J.axisOffset = [0, 0, 0, 0], J.clipOffset = [0, 0, 0, 0];
}, at.prototype.drawChartBox = function() {
var J = this.options.chart, tt = this.renderer, ot = this.chartWidth, lt = this.chartHeight, pt = this.styledMode, yt = this.plotBGImage, vt = J.backgroundColor, Ct = J.plotBackgroundColor, Pt = J.plotBackgroundImage, At = this.plotLeft, St = this.plotTop, Dt = this.plotWidth, Lt = this.plotHeight, Nt = this.plotBox, Et = this.clipRect, Kt = this.clipBox, Gt = this.chartBackground, Wt = this.plotBackground, Jt = this.plotBorder, be, zt = "animate";
if (Gt || (this.chartBackground = Gt = tt.rect().addClass("highcharts-background").add(), zt = "attr"), pt)
var Vt = be = Gt.strokeWidth();
else
Vt = J.borderWidth || 0, be = Vt + (J.shadow ? 8 : 0), vt = { fill: vt || "none" }, (Vt || Gt["stroke-width"]) && (vt.stroke = J.borderColor, vt["stroke-width"] = Vt), Gt.attr(vt).shadow(J.shadow);
Gt[zt]({ x: be / 2, y: be / 2, width: ot - be - Vt % 2, height: lt - be - Vt % 2, r: J.borderRadius }), zt = "animate", Wt || (zt = "attr", this.plotBackground = Wt = tt.rect().addClass("highcharts-plot-background").add()), Wt[zt](Nt), pt || (Wt.attr({ fill: Ct || "none" }).shadow(J.plotShadow), Pt && (yt ? (Pt !== yt.attr("href") && yt.attr("href", Pt), yt.animate(Nt)) : this.plotBGImage = tt.image(Pt, At, St, Dt, Lt).add())), Et ? Et.animate({ width: Kt.width, height: Kt.height }) : this.clipRect = tt.clipRect(Kt), zt = "animate", Jt || (zt = "attr", this.plotBorder = Jt = tt.rect().addClass("highcharts-plot-border").attr({ zIndex: 1 }).add()), pt || Jt.attr({ stroke: J.plotBorderColor, "stroke-width": J.plotBorderWidth || 0, fill: "none" }), Jt[zt](Jt.crisp({ x: At, y: St, width: Dt, height: Lt }, -Jt.strokeWidth())), this.isDirtyBox = !1, V(this, "afterDrawChartBox");
}, at.prototype.propFromSeries = function() {
var J = this, tt = J.options.chart, ot = J.options.series, lt, pt, yt;
["inverted", "angular", "polar"].forEach(function(vt) {
for (pt = s[tt.type || tt.defaultSeriesType], yt = tt[vt] || pt && pt.prototype[vt], lt = ot && ot.length; !yt && lt--; )
(pt = s[ot[lt].type]) && pt.prototype[vt] && (yt = !0);
J[vt] = yt;
});
}, at.prototype.linkSeries = function() {
var J = this, tt = J.series;
tt.forEach(function(ot) {
ot.linkedSeries.length = 0;
}), tt.forEach(function(ot) {
var lt = ot.options.linkedTo;
$(lt) && (lt = lt === ":previous" ? J.series[ot.index - 1] : J.get(lt)) && lt.linkedParent !== ot && (lt.linkedSeries.push(ot), ot.linkedParent = lt, lt.enabledDataSorting && ot.setDataSortingOptions(), ot.visible = et(ot.options.visible, lt.options.visible, ot.visible));
}), V(this, "afterLinkSeries");
}, at.prototype.renderSeries = function() {
this.series.forEach(function(J) {
J.translate(), J.render();
});
}, at.prototype.renderLabels = function() {
var J = this, tt = J.options.labels;
tt.items && tt.items.forEach(function(ot) {
var lt = L(tt.style, ot.style), pt = nt(lt.left) + J.plotLeft, yt = nt(lt.top) + J.plotTop + 12;
delete lt.left, delete lt.top, J.renderer.text(ot.html, pt, yt).attr({ zIndex: 2 }).css(lt).add();
});
}, at.prototype.render = function() {
var J = this.axes, tt = this.colorAxis, ot = this.renderer, lt = this.options, pt = function(At) {
At.forEach(function(St) {
St.visible && St.render();
});
}, yt = 0;
this.setTitle(), this.legend = new U(this, lt.legend), this.getStacks && this.getStacks(), this.getMargins(!0), this.setChartSize(), lt = this.plotWidth, J.some(function(At) {
if (At.horiz && At.visible && At.options.labels.enabled && At.series.length)
return yt = 21, !0;
});
var vt = this.plotHeight = Math.max(this.plotHeight - yt, 0);
J.forEach(function(At) {
At.setScale();
}), this.getAxisMargins();
var Ct = 1.1 < lt / this.plotWidth, Pt = 1.05 < vt / this.plotHeight;
(Ct || Pt) && (J.forEach(function(At) {
(At.horiz && Ct || !At.horiz && Pt) && At.setTickInterval(!0);
}), this.getMargins()), this.drawChartBox(), this.hasCartesianSeries ? pt(J) : tt && tt.length && pt(tt), this.seriesGroup || (this.seriesGroup = ot.g("series-group").attr({ zIndex: 3 }).add()), this.renderSeries(), this.renderLabels(), this.addCredits(), this.setResponsive && this.setResponsive(), this.hasRendered = !0;
}, at.prototype.addCredits = function(J) {
var tt = this, ot = q(!0, this.options.credits, J);
ot.enabled && !this.credits && (this.credits = this.renderer.text(ot.text + (this.mapCredits || ""), 0, 0).addClass("highcharts-credits").on("click", function() {
ot.href && (h.location.href = ot.href);
}).attr({ align: ot.position.align, zIndex: 8 }), tt.styledMode || this.credits.css(ot.style), this.credits.add().align(ot.position), this.credits.update = function(lt) {
tt.credits = tt.credits.destroy(), tt.addCredits(lt);
});
}, at.prototype.destroy = function() {
var J = this, tt = J.axes, ot = J.series, lt = J.container, pt = lt && lt.parentNode, yt;
for (V(J, "destroy"), J.renderer.forExport ? g(a, J) : a[J.index] = void 0, H.chartCount--, J.renderTo.removeAttribute("data-highcharts-chart"), ct(J), yt = tt.length; yt--; )
tt[yt] = tt[yt].destroy();
for (this.scroller && this.scroller.destroy && this.scroller.destroy(), yt = ot.length; yt--; )
ot[yt] = ot[yt].destroy();
"title subtitle chartBackground plotBackground plotBGImage plotBorder seriesGroup clipRect credits pointer rangeSelector legend resetZoomButton tooltip renderer".split(" ").forEach(function(vt) {
var Ct = J[vt];
Ct && Ct.destroy && (J[vt] = Ct.destroy());
}), lt && (lt.innerHTML = O.emptyHTML, ct(lt), pt && X(lt)), it(J, function(vt, Ct) {
delete J[Ct];
});
}, at.prototype.firstRender = function() {
var J = this, tt = J.options;
(!J.isReadyToRender || J.isReadyToRender()) && (J.getContainer(), J.resetMargins(), J.setChartSize(), J.propFromSeries(), J.getAxes(), (k(tt.series) ? tt.series : []).forEach(function(ot) {
J.initSeries(ot);
}), J.linkSeries(), J.setSeriesData(), V(J, "beforeRender"), R && (F.isRequired() ? J.pointer = new F(J, tt) : J.pointer = new R(J, tt)), J.render(), J.pointer.getChartPosition(), !J.renderer.imgCount && !J.hasLoaded && J.onload(), J.temporaryDisplay(!0));
}, at.prototype.onload = function() {
this.callbacks.concat([this.callback]).forEach(function(J) {
J && typeof this.index < "u" && J.apply(this, [this]);
}, this), V(this, "load"), V(this, "render"), P(this.index) && this.setReflow(this.options.chart.reflow), this.hasLoaded = !0;
}, at.prototype.addSeries = function(J, tt, ot) {
var lt = this, pt;
return J && (tt = et(tt, !0), V(lt, "addSeries", { options: J }, function() {
pt = lt.initSeries(J), lt.isDirtyLegend = !0, lt.linkSeries(), pt.enabledDataSorting && pt.setData(J.data, !1), V(lt, "afterAddSeries", { series: pt }), tt && lt.redraw(ot);
})), pt;
}, at.prototype.addAxis = function(J, tt, ot, lt) {
return this.createAxis(tt ? "xAxis" : "yAxis", { axis: J, redraw: ot, animation: lt });
}, at.prototype.addColorAxis = function(J, tt, ot) {
return this.createAxis(
"colorAxis",
{ axis: J, redraw: tt, animation: ot }
);
}, at.prototype.createAxis = function(J, tt) {
return J = new j(this, q(tt.axis, { index: this[J].length, isX: J === "xAxis" })), et(tt.redraw, !0) && this.redraw(tt.animation), J;
}, at.prototype.showLoading = function(J) {
var tt = this, ot = tt.options, lt = ot.loading, pt = function() {
yt && W(yt, { left: tt.plotLeft + "px", top: tt.plotTop + "px", width: tt.plotWidth + "px", height: tt.plotHeight + "px" });
}, yt = tt.loadingDiv, vt = tt.loadingSpan;
yt || (tt.loadingDiv = yt = D("div", { className: "highcharts-loading highcharts-loading-hidden" }, null, tt.container)), vt || (tt.loadingSpan = vt = D("span", { className: "highcharts-loading-inner" }, null, yt), n(tt, "redraw", pt)), yt.className = "highcharts-loading", O.setElementHTML(vt, et(J, ot.lang.loading, "")), tt.styledMode || (W(yt, L(lt.style, { zIndex: 10 })), W(vt, lt.labelStyle), tt.loadingShown || (W(yt, { opacity: 0, display: "" }), B(yt, { opacity: lt.style.opacity || 0.5 }, { duration: lt.showDuration || 0 }))), tt.loadingShown = !0, pt();
}, at.prototype.hideLoading = function() {
var J = this.options, tt = this.loadingDiv;
tt && (tt.className = "highcharts-loading highcharts-loading-hidden", this.styledMode || B(tt, { opacity: 0 }, { duration: J.loading.hideDuration || 100, complete: function() {
W(tt, { display: "none" });
} })), this.loadingShown = !1;
}, at.prototype.update = function(J, tt, ot, lt) {
var pt = this, yt = { credits: "addCredits", title: "setTitle", subtitle: "setSubtitle", caption: "setCaption" }, vt = J.isResponsiveOptions, Ct = [], Pt, At;
V(pt, "update", { options: J }), vt || pt.setResponsive(!1, !0), J = _(J, pt.options), pt.userOptions = q(pt.userOptions, J);
var St = J.chart;
if (St) {
if (q(!0, pt.options.chart, St), "className" in St && pt.setClassName(St.className), "reflow" in St && pt.setReflow(St.reflow), "inverted" in St || "polar" in St || "type" in St) {
pt.propFromSeries();
var Dt = !0;
}
"alignTicks" in St && (Dt = !0), "events" in St && x(this, St), it(St, function(Lt, Nt) {
pt.propsRequireUpdateSeries.indexOf("chart." + Nt) !== -1 && (Pt = !0), pt.propsRequireDirtyBox.indexOf(Nt) !== -1 && (pt.isDirtyBox = !0), pt.propsRequireReflow.indexOf(Nt) !== -1 && (vt ? pt.isDirtyBox = !0 : At = !0);
}), !pt.styledMode && St.style && pt.renderer.setStyle(pt.options.chart.style || {});
}
!pt.styledMode && J.colors && (this.options.colors = J.colors), J.time && (this.time === t && (this.time = new u(J.time)), q(
!0,
pt.options.time,
J.time
)), it(J, function(Lt, Nt) {
pt[Nt] && typeof pt[Nt].update == "function" ? pt[Nt].update(Lt, !1) : typeof pt[yt[Nt]] == "function" ? pt[yt[Nt]](Lt) : Nt !== "colors" && pt.collectionsWithUpdate.indexOf(Nt) === -1 && q(!0, pt.options[Nt], J[Nt]), Nt !== "chart" && pt.propsRequireUpdateSeries.indexOf(Nt) !== -1 && (Pt = !0);
}), this.collectionsWithUpdate.forEach(function(Lt) {
if (J[Lt]) {
var Nt = [];
pt[Lt].forEach(function(Et, Kt) {
Et.options.isInternal || Nt.push(et(Et.options.index, Kt));
}), gt(J[Lt]).forEach(function(Et, Kt) {
var Gt = P(Et.id), Wt;
Gt && (Wt = pt.get(Et.id)), !Wt && pt[Lt] && (Wt = pt[Lt][Nt ? Nt[Kt] : Kt]) && Gt && P(Wt.options.id) && (Wt = void 0), Wt && Wt.coll === Lt && (Wt.update(Et, !1), ot && (Wt.touched = !0)), !Wt && ot && pt.collectionsWithInit[Lt] && (pt.collectionsWithInit[Lt][0].apply(pt, [Et].concat(pt.collectionsWithInit[Lt][1] || []).concat([!1])).touched = !0);
}), ot && pt[Lt].forEach(function(Et) {
Et.touched || Et.options.isInternal ? delete Et.touched : Ct.push(Et);
});
}
}), Ct.forEach(function(Lt) {
Lt.chart && Lt.remove && Lt.remove(!1);
}), Dt && pt.axes.forEach(function(Lt) {
Lt.update({}, !1);
}), Pt && pt.getSeriesOrderByLinks().forEach(function(Lt) {
Lt.chart && Lt.update({}, !1);
}, this), Dt = St && St.width, St = St && ($(St.height) ? rt(St.height, Dt || pt.chartWidth) : St.height), At || G(Dt) && Dt !== pt.chartWidth || G(St) && St !== pt.chartHeight ? pt.setSize(Dt, St, lt) : et(tt, !0) && pt.redraw(lt), V(pt, "afterUpdate", { options: J, redraw: tt, animation: lt });
}, at.prototype.setSubtitle = function(J, tt) {
this.applyDescription("subtitle", J), this.layOutTitles(tt);
}, at.prototype.setCaption = function(J, tt) {
this.applyDescription("caption", J), this.layOutTitles(tt);
}, at.prototype.showResetZoom = function() {
function J() {
tt.zoomOut();
}
var tt = this, ot = o.lang, lt = tt.options.chart.resetZoomButton, pt = lt.theme, yt = pt.states, vt = lt.relativeTo === "chart" || lt.relativeTo === "spacingBox" ? null : "scrollablePlotBox";
V(this, "beforeShowResetZoom", null, function() {
tt.resetZoomButton = tt.renderer.button(ot.resetZoom, null, null, J, pt, yt && yt.hover).attr({ align: lt.position.align, title: ot.resetZoomTitle }).addClass("highcharts-reset-zoom").add().align(lt.position, !1, vt);
}), V(this, "afterShowResetZoom");
}, at.prototype.zoomOut = function() {
V(this, "selection", { resetSelection: !0 }, this.zoom);
}, at.prototype.zoom = function(J) {
var tt = this, ot = tt.pointer, lt = tt.inverted ? ot.mouseDownX : ot.mouseDownY, pt = !1, yt;
!J || J.resetSelection ? (tt.axes.forEach(function(Ct) {
yt = Ct.zoom();
}), ot.initiated = !1) : J.xAxis.concat(J.yAxis).forEach(function(Ct) {
var Pt = Ct.axis, At = tt.inverted ? Pt.left : Pt.top, St = tt.inverted ? At + Pt.width : At + Pt.height, Dt = Pt.isXAxis, Lt = !1;
(!Dt && lt >= At && lt <= St || Dt || !P(lt)) && (Lt = !0), ot[Dt ? "zoomX" : "zoomY"] && Lt && (yt = Pt.zoom(Ct.min, Ct.max), Pt.displayBtn && (pt = !0));
});
var vt = tt.resetZoomButton;
pt && !vt ? tt.showResetZoom() : !pt && z(vt) && (tt.resetZoomButton = vt.destroy()), yt && tt.redraw(et(
tt.options.chart.animation,
J && J.animation,
100 > tt.pointCount
));
}, at.prototype.pan = function(J, tt) {
var ot = this, lt = ot.hoverPoints;
tt = typeof tt == "object" ? tt : { enabled: tt, type: "x" };
var pt = ot.options.chart, yt = ot.options.mapNavigation && ot.options.mapNavigation.enabled;
pt && pt.panning && (pt.panning = tt);
var vt = tt.type, Ct;
V(this, "pan", { originalEvent: J }, function() {
lt && lt.forEach(function(St) {
St.setState();
});
var Pt = ot.xAxis;
vt === "xy" ? Pt = Pt.concat(ot.yAxis) : vt === "y" && (Pt = ot.yAxis);
var At = {};
Pt.forEach(function(St) {
if (St.options.panningEnabled && !St.options.isInternal) {
var Dt = St.horiz, Lt = J[Dt ? "chartX" : "chartY"];
Dt = Dt ? "mouseDownX" : "mouseDownY";
var Nt = ot[Dt], Et = St.minPointOffset || 0, Kt = St.reversed && !ot.inverted || !St.reversed && ot.inverted ? -1 : 1, Gt = St.getExtremes(), Wt = St.toValue(Nt - Lt, !0) + Et * Kt, Jt = St.toValue(Nt + St.len - Lt, !0) - (Et * Kt || St.isXAxis && St.pointRangePadding || 0), be = Jt < Wt;
Kt = St.hasVerticalPanning(), Nt = be ? Jt : Wt, Wt = be ? Wt : Jt;
var zt = St.panningState;
!Kt || St.isXAxis || zt && !zt.isDirty || St.series.forEach(function(Vt) {
var Me = Vt.getProcessedData(!0);
Me = Vt.getExtremes(Me.yData, !0), zt || (zt = { startMin: Number.MAX_VALUE, startMax: -Number.MAX_VALUE }), G(Me.dataMin) && G(Me.dataMax) && (zt.startMin = Math.min(et(Vt.options.threshold, 1 / 0), Me.dataMin, zt.startMin), zt.startMax = Math.max(et(Vt.options.threshold, -1 / 0), Me.dataMax, zt.startMax));
}), Kt = Math.min(et(zt && zt.startMin, Gt.dataMin), Et ? Gt.min : St.toValue(St.toPixels(Gt.min) - St.minPixelPadding)), Jt = Math.max(et(zt && zt.startMax, Gt.dataMax), Et ? Gt.max : St.toValue(St.toPixels(Gt.max) + St.minPixelPadding)), St.panningState = zt, St.isOrdinal || (Et = Kt - Nt, 0 < Et && (Wt += Et, Nt = Kt), Et = Wt - Jt, 0 < Et && (Wt = Jt, Nt -= Et), St.series.length && Nt !== Gt.min && Wt !== Gt.max && Nt >= Kt && Wt <= Jt && (St.setExtremes(
Nt,
Wt,
!1,
!1,
{ trigger: "pan" }
), ot.resetZoomButton || yt || Nt === Kt || Wt === Jt || !vt.match("y") || (ot.showResetZoom(), St.displayBtn = !1), Ct = !0), At[Dt] = Lt);
}
}), it(At, function(St, Dt) {
ot[Dt] = St;
}), Ct && ot.redraw(!1), W(ot.container, { cursor: "move" });
});
}, at;
}(), L(y.prototype, {
callbacks: [],
collectionsWithInit: { xAxis: [y.prototype.addAxis, [!0]], yAxis: [y.prototype.addAxis, [!1]], series: [y.prototype.addSeries] },
collectionsWithUpdate: ["xAxis", "yAxis", "series"],
propsRequireDirtyBox: "backgroundColor borderColor borderWidth borderRadius plotBackgroundColor plotBackgroundImage plotBorderColor plotBorderWidth plotShadow shadow".split(" "),
propsRequireReflow: "margin marginTop marginRight marginBottom marginLeft spacing spacingTop spacingRight spacingBottom spacingLeft".split(" "),
propsRequireUpdateSeries: "chart.inverted chart.polar chart.ignoreHiddenSeries chart.type colors plotOptions time tooltip".split(" ")
}), y;
}), E(l, "Core/Legend/LegendSymbol.js", [l["Core/Utilities.js"]], function(y) {
var j = y.merge, I = y.pick, Z;
return function(H) {
H.drawLineMarker = function(U) {
var F = this.options, N = U.symbolWidth, R = U.symbolHeight, S = R / 2, v = this.chart.renderer, d = this.legendGroup;
U = U.baseline - Math.round(0.3 * U.fontMetrics.b);
var u = {}, T = F.marker;
this.chart.styledMode || (u = { "stroke-width": F.lineWidth || 0 }, F.dashStyle && (u.dashstyle = F.dashStyle)), this.legendLine = v.path([["M", 0, U], ["L", N, U]]).addClass("highcharts-graph").attr(u).add(d), T && T.enabled !== !1 && N && (F = Math.min(I(T.radius, S), S), this.symbol.indexOf("url") === 0 && (T = j(T, { width: R, height: R }), F = 0), this.legendSymbol = N = v.symbol(this.symbol, N / 2 - F, U - F, 2 * F, 2 * F, T).addClass("highcharts-point").add(d), N.isMarker = !0);
}, H.drawRectangle = function(U, F) {
var N = U.symbolHeight, R = U.options.squareSymbol;
F.legendSymbol = this.chart.renderer.rect(R ? (U.symbolWidth - N) / 2 : 0, U.baseline - N + 1, R ? N : U.symbolWidth, N, I(U.options.symbolRadius, N / 2)).addClass("highcharts-point").attr({ zIndex: 3 }).add(F.legendGroup);
};
}(Z || (Z = {})), Z;
}), E(l, "Core/Series/SeriesDefaults.js", [], function() {
return { lineWidth: 2, allowPointSelect: !1, crisp: !0, showCheckbox: !1, animation: { duration: 1e3 }, events: {}, marker: { enabledThreshold: 2, lineColor: "#ffffff", lineWidth: 0, radius: 4, states: {
normal: { animation: !0 },
hover: { animation: { duration: 50 }, enabled: !0, radiusPlus: 2, lineWidthPlus: 1 },
select: { fillColor: "#cccccc", lineColor: "#000000", lineWidth: 2 }
} }, point: { events: {} }, dataLabels: { animation: {}, align: "center", defer: !0, formatter: function() {
var y = this.series.chart.numberFormatter;
return typeof this.y != "number" ? "" : y(this.y, -1);
}, padding: 5, style: { fontSize: "11px", fontWeight: "bold", color: "contrast", textOutline: "1px contrast" }, verticalAlign: "bottom", x: 0, y: 0 }, cropThreshold: 300, opacity: 1, pointRange: 0, softThreshold: !0, states: {
normal: { animation: !0 },
hover: { animation: { duration: 50 }, lineWidthPlus: 1, marker: {}, halo: { size: 10, opacity: 0.25 } },
select: { animation: { duration: 0 } },
inactive: { animation: { duration: 50 }, opacity: 0.2 }
}, stickyTracking: !0, turboThreshold: 1e3, findNearestPointBy: "x" };
}), E(l, "Core/Series/Series.js", [
l["Core/Animation/AnimationUtilities.js"],
l["Core/DefaultOptions.js"],
l["Core/Foundation.js"],
l["Core/Globals.js"],
l["Core/Legend/LegendSymbol.js"],
l["Core/Series/Point.js"],
l["Core/Series/SeriesDefaults.js"],
l["Core/Series/SeriesRegistry.js"],
l["Core/Renderer/SVG/SVGElement.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z, H, U, F, N, R, S) {
var v = y.animObject, d = y.setAnimation, u = j.defaultOptions, T = I.registerEventOptions, O = Z.hasTouch, B = Z.svg, C = Z.win, b = N.seriesTypes, w = S.addEvent, x = S.arrayMax, a = S.arrayMin, c = S.clamp, p = S.cleanRecursively, i = S.correctFloat, h = S.defined, o = S.erase, t = S.error, s = S.extend, n = S.find, A = S.fireEvent, _ = S.getNestedProperty, D = S.isArray, W = S.isNumber, P = S.isString, X = S.merge, g = S.objectEach, m = S.pick, L = S.removeEvent, Y = S.splat, V = S.syncTimeout;
return y = function() {
function Q() {
this.zones = this.yAxis = this.xAxis = this.userOptions = this.tooltipOptions = this.processedYData = this.processedXData = this.points = this.options = this.linkedSeries = this.index = this.eventsToUnbind = this.eventOptions = this.data = this.chart = this._i = void 0;
}
return Q.prototype.init = function(k, G) {
A(this, "init", { options: G });
var z = this, $ = k.series;
this.eventsToUnbind = [], z.chart = k, z.options = z.setOptions(G), G = z.options, z.linkedSeries = [], z.bindAxes(), s(z, { name: G.name, state: "", visible: G.visible !== !1, selected: G.selected === !0 }), T(this, G);
var q = G.events;
(q && q.click || G.point && G.point.events && G.point.events.click || G.allowPointSelect) && (k.runTrackerClick = !0), z.getColor(), z.getSymbol(), z.parallelArrays.forEach(function(et) {
z[et + "Data"] || (z[et + "Data"] = []);
}), z.isCartesian && (k.hasCartesianSeries = !0);
var it;
$.length && (it = $[$.length - 1]), z._i = m(it && it._i, -1) + 1, z.opacity = z.options.opacity, k.orderSeries(this.insert($)), G.dataSorting && G.dataSorting.enabled ? z.setDataSortingOptions() : z.points || z.data || z.setData(G.data, !1), A(this, "afterInit");
}, Q.prototype.is = function(k) {
return b[k] && this instanceof b[k];
}, Q.prototype.insert = function(k) {
var G = this.options.index, z;
if (W(G)) {
for (z = k.length; z--; )
if (G >= m(k[z].options.index, k[z]._i)) {
k.splice(z + 1, 0, this);
break;
}
z === -1 && k.unshift(this), z += 1;
} else
k.push(this);
return m(z, k.length - 1);
}, Q.prototype.bindAxes = function() {
var k = this, G = k.options, z = k.chart, $;
A(this, "bindAxes", null, function() {
(k.axisTypes || []).forEach(function(q) {
var it = 0;
z[q].forEach(function(et) {
$ = et.options, (G[q] === it && !$.isInternal || typeof G[q] < "u" && G[q] === $.id || typeof G[q] > "u" && $.index === 0) && (k.insert(et.series), k[q] = et, et.isDirty = !0), $.isInternal || it++;
}), k[q] || k.optionalAxis === q || t(18, !0, z);
});
}), A(this, "afterBindAxes");
}, Q.prototype.updateParallelArrays = function(k, G) {
var z = k.series, $ = arguments, q = W(G) ? function(it) {
var et = it === "y" && z.toYData ? z.toYData(k) : k[it];
z[it + "Data"][G] = et;
} : function(it) {
Array.prototype[G].apply(z[it + "Data"], Array.prototype.slice.call($, 2));
};
z.parallelArrays.forEach(q);
}, Q.prototype.hasData = function() {
return this.visible && typeof this.dataMax < "u" && typeof this.dataMin < "u" || this.visible && this.yData && 0 < this.yData.length;
}, Q.prototype.autoIncrement = function(k) {
var G = this.options, z = G.pointIntervalUnit, $ = G.relativeXValue, q = this.chart.time, it = this.xIncrement, et;
return it = m(it, G.pointStart, 0), this.pointInterval = et = m(this.pointInterval, G.pointInterval, 1), $ && W(k) && (et *= k), z && (G = new q.Date(it), z === "day" ? q.set("Date", G, q.get("Date", G) + et) : z === "month" ? q.set("Month", G, q.get("Month", G) + et) : z === "year" && q.set("FullYear", G, q.get("FullYear", G) + et), et = G.getTime() - it), $ && W(k) ? it + et : (this.xIncrement = it + et, it);
}, Q.prototype.setDataSortingOptions = function() {
var k = this.options;
s(this, { requireSorting: !1, sorted: !1, enabledDataSorting: !0, allowDG: !1 }), h(k.pointRange) || (k.pointRange = 1);
}, Q.prototype.setOptions = function(k) {
var G = this.chart, z = G.options, $ = z.plotOptions, q = G.userOptions || {};
k = X(k), G = G.styledMode;
var it = { plotOptions: $, userOptions: k };
A(this, "setOptions", it);
var et = it.plotOptions[this.type], nt = q.plotOptions || {};
return this.userOptions = it.userOptions, q = X(et, $.series, q.plotOptions && q.plotOptions[this.type], k), this.tooltipOptions = X(u.tooltip, u.plotOptions.series && u.plotOptions.series.tooltip, u.plotOptions[this.type].tooltip, z.tooltip.userOptions, $.series && $.series.tooltip, $[this.type].tooltip, k.tooltip), this.stickyTracking = m(k.stickyTracking, nt[this.type] && nt[this.type].stickyTracking, nt.series && nt.series.stickyTracking, this.tooltipOptions.shared && !this.noSharedTooltip ? !0 : q.stickyTracking), et.marker === null && delete q.marker, this.zoneAxis = q.zoneAxis, $ = this.zones = (q.zones || []).slice(), !q.negativeColor && !q.negativeFillColor || q.zones || (z = { value: q[this.zoneAxis + "Threshold"] || q.threshold || 0, className: "highcharts-negative" }, G || (z.color = q.negativeColor, z.fillColor = q.negativeFillColor), $.push(z)), $.length && h($[$.length - 1].value) && $.push(G ? {} : { color: this.color, fillColor: this.fillColor }), A(this, "afterSetOptions", { options: q }), q;
}, Q.prototype.getName = function() {
return m(this.options.name, "Series " + (this.index + 1));
}, Q.prototype.getCyclic = function(k, G, z) {
var $ = this.chart, q = this.userOptions, it = k + "Index", et = k + "Counter", nt = z ? z.length : m($.options.chart[k + "Count"], $[k + "Count"]);
if (!G) {
var rt = m(q[it], q["_" + it]);
h(rt) || ($.series.length || ($[et] = 0), q["_" + it] = rt = $[et] % nt, $[et] += 1), z && (G = z[rt]);
}
typeof rt < "u" && (this[it] = rt), this[k] = G;
}, Q.prototype.getColor = function() {
this.chart.styledMode ? this.getCyclic("color") : this.options.colorByPoint ? this.color = "#cccccc" : this.getCyclic("color", this.options.color || u.plotOptions[this.type].color, this.chart.options.colors);
}, Q.prototype.getPointsCollection = function() {
return (this.hasGroupedData ? this.points : this.data) || [];
}, Q.prototype.getSymbol = function() {
this.getCyclic("symbol", this.options.marker.symbol, this.chart.options.symbols);
}, Q.prototype.findPointIndex = function(k, G) {
var z = k.id, $ = k.x, q = this.points, it = this.options.dataSorting, et, nt;
if (z)
it = this.chart.get(z), it instanceof U && (et = it);
else if ((this.linkedParent || this.enabledDataSorting || this.options.relativeXValue) && (et = function(ct) {
return !ct.touched && ct.index === k.index;
}, it && it.matchByName ? et = function(ct) {
return !ct.touched && ct.name === k.name;
} : this.options.relativeXValue && (et = function(ct) {
return !ct.touched && ct.options.x === k.x;
}), et = n(q, et), !et))
return;
if (et) {
var rt = et && et.index;
typeof rt < "u" && (nt = !0);
}
return typeof rt > "u" && W($) && (rt = this.xData.indexOf($, G)), rt !== -1 && typeof rt < "u" && this.cropped && (rt = rt >= this.cropStart ? rt - this.cropStart : rt), !nt && W(rt) && q[rt] && q[rt].touched && (rt = void 0), rt;
}, Q.prototype.updateData = function(k, G) {
var z = this.options, $ = z.dataSorting, q = this.points, it = [], et = this.requireSorting, nt = k.length === q.length, rt, ct, gt, dt = !0;
if (this.xIncrement = null, k.forEach(function(ht, at) {
var J = h(ht) && this.pointClass.prototype.optionsToObject.call({ series: this }, ht) || {}, tt = J.x;
J.id || W(tt) ? (J = this.findPointIndex(J, gt), J === -1 || typeof J > "u" ? it.push(ht) : q[J] && ht !== z.data[J] ? (q[J].update(ht, !1, null, !1), q[J].touched = !0, et && (gt = J + 1)) : q[J] && (q[J].touched = !0), (!nt || at !== J || $ && $.enabled || this.hasDerivedData) && (rt = !0)) : it.push(ht);
}, this), rt)
for (k = q.length; k--; )
(ct = q[k]) && !ct.touched && ct.remove && ct.remove(!1, G);
else
!nt || $ && $.enabled ? dt = !1 : (k.forEach(function(ht, at) {
ht !== q[at].y && q[at].update && q[at].update(
ht,
!1,
null,
!1
);
}), it.length = 0);
return q.forEach(function(ht) {
ht && (ht.touched = !1);
}), dt ? (it.forEach(function(ht) {
this.addPoint(ht, !1, null, null, !1);
}, this), this.xIncrement === null && this.xData && this.xData.length && (this.xIncrement = x(this.xData), this.autoIncrement()), !0) : !1;
}, Q.prototype.setData = function(k, G, z, $) {
var q = this, it = q.points, et = it && it.length || 0, nt = q.options, rt = q.chart, ct = nt.dataSorting, gt = q.xAxis, dt = nt.turboThreshold, ht = this.xData, at = this.yData, J = q.pointArrayMap;
J = J && J.length;
var tt = nt.keys, ot, lt = 0, pt = 1, yt = null;
k = k || [];
var vt = k.length;
if (G = m(G, !0), ct && ct.enabled && (k = this.sortData(k)), $ !== !1 && vt && et && !q.cropped && !q.hasGroupedData && q.visible && !q.isSeriesBoosting && (ot = this.updateData(k, z)), !ot) {
if (q.xIncrement = null, q.colorCounter = 0, this.parallelArrays.forEach(function(Ct) {
q[Ct + "Data"].length = 0;
}), dt && vt > dt)
if (yt = q.getFirstValidPoint(k), W(yt))
for (z = 0; z < vt; z++)
ht[z] = this.autoIncrement(), at[z] = k[z];
else if (D(yt))
if (J)
if (yt.length === J)
for (z = 0; z < vt; z++)
ht[z] = this.autoIncrement(), at[z] = k[z];
else
for (z = 0; z < vt; z++)
$ = k[z], ht[z] = $[0], at[z] = $.slice(
1,
J + 1
);
else if (tt && (lt = tt.indexOf("x"), pt = tt.indexOf("y"), lt = 0 <= lt ? lt : 0, pt = 0 <= pt ? pt : 1), yt.length === 1 && (pt = 0), lt === pt)
for (z = 0; z < vt; z++)
ht[z] = this.autoIncrement(), at[z] = k[z][pt];
else
for (z = 0; z < vt; z++)
$ = k[z], ht[z] = $[lt], at[z] = $[pt];
else
t(12, !1, rt);
else
for (z = 0; z < vt; z++)
typeof k[z] < "u" && ($ = { series: q }, q.pointClass.prototype.applyOptions.apply($, [k[z]]), q.updateParallelArrays($, z));
for (at && P(at[0]) && t(14, !0, rt), q.data = [], q.options.data = q.userOptions.data = k, z = et; z--; )
it[z] && it[z].destroy && it[z].destroy();
gt && (gt.minRange = gt.userMinRange), q.isDirty = rt.isDirtyBox = !0, q.isDirtyData = !!it, z = !1;
}
nt.legendType === "point" && (this.processData(), this.generatePoints()), G && rt.redraw(z);
}, Q.prototype.sortData = function(k) {
var G = this, z = G.options.dataSorting.sortKey || "y", $ = function(q, it) {
return h(it) && q.pointClass.prototype.optionsToObject.call({ series: q }, it) || {};
};
return k.forEach(function(q, it) {
k[it] = $(G, q), k[it].index = it;
}, this), k.concat().sort(function(q, it) {
return q = _(z, q), it = _(z, it), it < q ? -1 : it > q ? 1 : 0;
}).forEach(function(q, it) {
q.x = it;
}, this), G.linkedSeries && G.linkedSeries.forEach(function(q) {
var it = q.options, et = it.data;
it.dataSorting && it.dataSorting.enabled || !et || (et.forEach(function(nt, rt) {
et[rt] = $(q, nt), k[rt] && (et[rt].x = k[rt].x, et[rt].index = rt);
}), q.setData(et, !1));
}), k;
}, Q.prototype.getProcessedData = function(k) {
var G = this.xAxis, z = this.options, $ = z.cropThreshold, q = k || this.getExtremesFromAll || z.getExtremesFromAll, it = this.isCartesian;
k = G && G.val2lin, z = !(!G || !G.logarithmic);
var et = 0, nt = this.xData, rt = this.yData, ct = this.requireSorting, gt = !1, dt = nt.length;
if (G) {
gt = G.getExtremes();
var ht = gt.min, at = gt.max;
gt = G.categories && !G.names.length;
}
if (it && this.sorted && !q && (!$ || dt > $ || this.forceCrop)) {
if (nt[dt - 1] < ht || nt[0] > at)
nt = [], rt = [];
else if (this.yData && (nt[0] < ht || nt[dt - 1] > at)) {
var J = this.cropData(this.xData, this.yData, ht, at);
nt = J.xData, rt = J.yData, et = J.start, J = !0;
}
}
for ($ = nt.length || 1; --$; )
if (G = z ? k(nt[$]) - k(nt[$ - 1]) : nt[$] - nt[$ - 1], 0 < G && (typeof tt > "u" || G < tt))
var tt = G;
else
0 > G && ct && !gt && (t(15, !1, this.chart), ct = !1);
return { xData: nt, yData: rt, cropped: J, cropStart: et, closestPointRange: tt };
}, Q.prototype.processData = function(k) {
var G = this.xAxis;
if (this.isCartesian && !this.isDirty && !G.isDirty && !this.yAxis.isDirty && !k)
return !1;
k = this.getProcessedData(), this.cropped = k.cropped, this.cropStart = k.cropStart, this.processedXData = k.xData, this.processedYData = k.yData, this.closestPointRange = this.basePointRange = k.closestPointRange, A(this, "afterProcessData");
}, Q.prototype.cropData = function(k, G, z, $, q) {
var it = k.length, et, nt = 0, rt = it;
for (q = m(q, this.cropShoulder), et = 0; et < it; et++)
if (k[et] >= z) {
nt = Math.max(0, et - q);
break;
}
for (z = et; z < it; z++)
if (k[z] > $) {
rt = z + q;
break;
}
return { xData: k.slice(nt, rt), yData: G.slice(
nt,
rt
), start: nt, end: rt };
}, Q.prototype.generatePoints = function() {
var k = this.options, G = k.data, z = this.processedXData, $ = this.processedYData, q = this.pointClass, it = z.length, et = this.cropStart || 0, nt = this.hasGroupedData, rt = k.keys, ct = [];
k = k.dataGrouping && k.dataGrouping.groupAll ? et : 0;
var gt, dt, ht = this.data;
if (!ht && !nt) {
var at = [];
at.length = G.length, ht = this.data = at;
}
for (rt && nt && (this.options.keys = !1), dt = 0; dt < it; dt++) {
if (at = et + dt, nt) {
var J = new q().init(this, [z[dt]].concat(Y($[dt])));
J.dataGroup = this.groupMap[k + dt], J.dataGroup.options && (J.options = J.dataGroup.options, s(J, J.dataGroup.options), delete J.dataLabels);
} else
(J = ht[at]) || typeof G[at] > "u" || (ht[at] = J = new q().init(this, G[at], z[dt]));
J && (J.index = nt ? k + dt : at, ct[dt] = J);
}
if (this.options.keys = rt, ht && (it !== (gt = ht.length) || nt))
for (dt = 0; dt < gt; dt++)
dt !== et || nt || (dt += it), ht[dt] && (ht[dt].destroyElements(), ht[dt].plotX = void 0);
this.data = ht, this.points = ct, A(this, "afterGeneratePoints");
}, Q.prototype.getXExtremes = function(k) {
return { min: a(k), max: x(k) };
}, Q.prototype.getExtremes = function(k, G) {
var z = this.xAxis, $ = this.yAxis, q = this.processedXData || this.xData, it = [], et = this.requireSorting ? this.cropShoulder : 0;
$ = $ ? $.positiveValuesOnly : !1;
var nt, rt = 0, ct = 0, gt = 0;
k = k || this.stackedYData || this.processedYData || [];
var dt = k.length;
if (z) {
var ht = z.getExtremes();
rt = ht.min, ct = ht.max;
}
for (nt = 0; nt < dt; nt++) {
var at = q[nt];
ht = k[nt];
var J = (W(ht) || D(ht)) && (ht.length || 0 < ht || !$);
if (at = G || this.getExtremesFromAll || this.options.getExtremesFromAll || this.cropped || !z || (q[nt + et] || at) >= rt && (q[nt - et] || at) <= ct, J && at)
if (J = ht.length)
for (; J--; )
W(ht[J]) && (it[gt++] = ht[J]);
else
it[gt++] = ht;
}
return k = { activeYData: it, dataMin: a(it), dataMax: x(it) }, A(this, "afterGetExtremes", { dataExtremes: k }), k;
}, Q.prototype.applyExtremes = function() {
var k = this.getExtremes();
return this.dataMin = k.dataMin, this.dataMax = k.dataMax, k;
}, Q.prototype.getFirstValidPoint = function(k) {
for (var G = k.length, z = 0, $ = null; $ === null && z < G; )
$ = k[z], z++;
return $;
}, Q.prototype.translate = function() {
this.processedXData || this.processData(), this.generatePoints();
var k = this.options, G = k.stacking, z = this.xAxis, $ = z.categories, q = this.enabledDataSorting, it = this.yAxis, et = this.points, nt = et.length, rt = this.pointPlacementToXValue(), ct = !!rt, gt = k.threshold, dt = k.startFromThreshold ? gt : 0, ht = this.zoneAxis || "y", at, J, tt = Number.MAX_VALUE;
for (at = 0; at < nt; at++) {
var ot = et[at], lt = ot.x, pt = void 0, yt = void 0, vt = ot.y, Ct = ot.low, Pt = G && it.stacking && it.stacking.stacks[(this.negStacks && vt < (dt ? 0 : gt) ? "-" : "") + this.stackKey];
if ((it.positiveValuesOnly && !it.validatePositiveValue(vt) || z.positiveValuesOnly && !z.validatePositiveValue(lt)) && (ot.isNull = !0), ot.plotX = J = i(c(z.translate(lt, 0, 0, 0, 1, rt, this.type === "flags"), -1e5, 1e5)), G && this.visible && Pt && Pt[lt]) {
var At = this.getStackIndicator(
At,
lt,
this.index
);
ot.isNull || (pt = Pt[lt], yt = pt.points[At.key]);
}
if (D(yt) && (Ct = yt[0], vt = yt[1], Ct === dt && At.key === Pt[lt].base && (Ct = m(W(gt) && gt, it.min)), it.positiveValuesOnly && 0 >= Ct && (Ct = null), ot.total = ot.stackTotal = pt.total, ot.percentage = pt.total && ot.y / pt.total * 100, ot.stackY = vt, this.irregularWidths || pt.setOffset(this.pointXOffset || 0, this.barW || 0)), ot.yBottom = h(Ct) ? c(it.translate(Ct, 0, 1, 0, 1), -1e5, 1e5) : null, this.dataModify && (vt = this.dataModify.modifyValue(vt, at)), ot.plotY = void 0, W(vt) && (pt = it.translate(vt, !1, !0, !1, !0), typeof pt < "u" && (ot.plotY = c(
pt,
-1e5,
1e5
))), ot.isInside = this.isPointInside(ot), ot.clientX = ct ? i(z.translate(lt, 0, 0, 0, 1, rt)) : J, ot.negative = ot[ht] < (k[ht + "Threshold"] || gt || 0), ot.category = $ && typeof $[ot.x] < "u" ? $[ot.x] : ot.x, !ot.isNull && ot.visible !== !1) {
typeof St < "u" && (tt = Math.min(tt, Math.abs(J - St)));
var St = J;
}
ot.zone = this.zones.length ? ot.getZone() : void 0, !ot.graphic && this.group && q && (ot.isNew = !0);
}
this.closestPointRangePx = tt, A(this, "afterTranslate");
}, Q.prototype.getValidPoints = function(k, G, z) {
var $ = this.chart;
return (k || this.points || []).filter(function(q) {
return G && !$.isInsidePlot(q.plotX, q.plotY, { inverted: $.inverted }) ? !1 : q.visible !== !1 && (z || !q.isNull);
});
}, Q.prototype.getClipBox = function() {
var k = this.chart, G = this.xAxis, z = this.yAxis, $ = X(k.clipBox);
return G && G.len !== k.plotSizeX && ($.width = G.len), z && z.len !== k.plotSizeY && ($.height = z.len), $;
}, Q.prototype.getSharedClipKey = function() {
return this.sharedClipKey = (this.options.xAxis || 0) + "," + (this.options.yAxis || 0);
}, Q.prototype.setClip = function() {
var k = this.chart, G = this.group, z = this.markerGroup, $ = k.sharedClips;
k = k.renderer;
var q = this.getClipBox(), it = this.getSharedClipKey(), et = $[it];
et ? et.animate(q) : $[it] = et = k.clipRect(q), G && G.clip(this.options.clip === !1 ? void 0 : et), z && z.clip();
}, Q.prototype.animate = function(k) {
var G = this.chart, z = this.group, $ = this.markerGroup, q = G.inverted, it = v(this.options.animation), et = [this.getSharedClipKey(), it.duration, it.easing, it.defer].join(), nt = G.sharedClips[et], rt = G.sharedClips[et + "m"];
if (k && z)
it = this.getClipBox(), nt ? nt.attr("height", it.height) : (it.width = 0, q && (it.x = G.plotHeight), nt = G.renderer.clipRect(it), G.sharedClips[et] = nt, rt = G.renderer.clipRect({ x: q ? (G.plotSizeX || 0) + 99 : -99, y: q ? -G.plotLeft : -G.plotTop, width: 99, height: q ? G.chartWidth : G.chartHeight }), G.sharedClips[et + "m"] = rt), z.clip(nt), $ && $.clip(rt);
else if (nt && !nt.hasClass("highcharts-animating")) {
G = this.getClipBox();
var ct = it.step;
$ && $.element.childNodes.length && (it.step = function(gt, dt) {
ct && ct.apply(dt, arguments), rt && rt.element && rt.attr(dt.prop, dt.prop === "width" ? gt + 99 : gt);
}), nt.addClass("highcharts-animating").animate(G, it);
}
}, Q.prototype.afterAnimate = function() {
var k = this;
this.setClip(), g(
this.chart.sharedClips,
function(G, z, $) {
G && !k.chart.container.querySelector('[clip-path="url(#' + G.id + ')"]') && (G.destroy(), delete $[z]);
}
), this.finishedAnimating = !0, A(this, "afterAnimate");
}, Q.prototype.drawPoints = function() {
var k = this.points, G = this.chart, z = this.options.marker, $ = this[this.specialGroup] || this.markerGroup, q = this.xAxis, it = m(z.enabled, !q || q.isRadial ? !0 : null, this.closestPointRangePx >= z.enabledThreshold * z.radius), et, nt;
if (z.enabled !== !1 || this._hasPointMarkers)
for (et = 0; et < k.length; et++) {
var rt = k[et], ct = (nt = rt.graphic) ? "animate" : "attr", gt = rt.marker || {}, dt = !!rt.marker;
if ((it && typeof gt.enabled > "u" || gt.enabled) && !rt.isNull && rt.visible !== !1) {
var ht = m(gt.symbol, this.symbol, "rect"), at = this.markerAttribs(rt, rt.selected && "select");
this.enabledDataSorting && (rt.startXPos = q.reversed ? -(at.width || 0) : q.width);
var J = rt.isInside !== !1;
nt ? nt[J ? "show" : "hide"](J).animate(at) : J && (0 < (at.width || 0) || rt.hasImage) && (rt.graphic = nt = G.renderer.symbol(ht, at.x, at.y, at.width, at.height, dt ? gt : z).add($), this.enabledDataSorting && G.hasRendered && (nt.attr({ x: rt.startXPos }), ct = "animate")), nt && ct === "animate" && nt[J ? "show" : "hide"](J).animate(at), nt && !G.styledMode && nt[ct](this.pointAttribs(rt, rt.selected && "select")), nt && nt.addClass(rt.getClassName(), !0);
} else
nt && (rt.graphic = nt.destroy());
}
}, Q.prototype.markerAttribs = function(k, G) {
var z = this.options, $ = z.marker, q = k.marker || {}, it = q.symbol || $.symbol, et = m(q.radius, $.radius);
return G && ($ = $.states[G], G = q.states && q.states[G], et = m(G && G.radius, $ && $.radius, et + ($ && $.radiusPlus || 0))), k.hasImage = it && it.indexOf("url") === 0, k.hasImage && (et = 0), k = { x: z.crisp ? Math.floor(k.plotX - et) : k.plotX - et, y: k.plotY - et }, et && (k.width = k.height = 2 * et), k;
}, Q.prototype.pointAttribs = function(k, G) {
var z = this.options.marker, $ = k && k.options, q = $ && $.marker || {}, it = $ && $.color, et = k && k.color, nt = k && k.zone && k.zone.color, rt = this.color;
return k = m(q.lineWidth, z.lineWidth), $ = 1, rt = it || nt || et || rt, it = q.fillColor || z.fillColor || rt, et = q.lineColor || z.lineColor || rt, G = G || "normal", z = z.states[G] || {}, G = q.states && q.states[G] || {}, k = m(G.lineWidth, z.lineWidth, k + m(G.lineWidthPlus, z.lineWidthPlus, 0)), it = G.fillColor || z.fillColor || it, et = G.lineColor || z.lineColor || et, $ = m(G.opacity, z.opacity, $), { stroke: et, "stroke-width": k, fill: it, opacity: $ };
}, Q.prototype.destroy = function(k) {
var G = this, z = G.chart, $ = /AppleWebKit\/533/.test(C.navigator.userAgent), q = G.data || [], it, et, nt, rt;
for (A(G, "destroy"), this.removeEvents(k), (G.axisTypes || []).forEach(function(ct) {
(rt = G[ct]) && rt.series && (o(rt.series, G), rt.isDirty = rt.forceRedraw = !0);
}), G.legendItem && G.chart.legend.destroyItem(G), et = q.length; et--; )
(nt = q[et]) && nt.destroy && nt.destroy();
G.clips && G.clips.forEach(function(ct) {
return ct.destroy();
}), S.clearTimeout(G.animationTimeout), g(G, function(ct, gt) {
ct instanceof R && !ct.survive && (it = $ && gt === "group" ? "hide" : "destroy", ct[it]());
}), z.hoverSeries === G && (z.hoverSeries = void 0), o(z.series, G), z.orderSeries(), g(G, function(ct, gt) {
k && gt === "hcEvents" || delete G[gt];
});
}, Q.prototype.applyZones = function() {
var k = this, G = this.chart, z = G.renderer, $ = this.zones, q = this.clips || [], it = this.graph, et = this.area, nt = Math.max(G.chartWidth, G.chartHeight), rt = this[(this.zoneAxis || "y") + "Axis"], ct = G.inverted, gt, dt, ht, at, J, tt, ot, lt, pt = !1;
if ($.length && (it || et) && rt && typeof rt.min < "u") {
var yt = rt.reversed, vt = rt.horiz;
it && !this.showLine && it.hide(), et && et.hide();
var Ct = rt.getExtremes();
$.forEach(function(Pt, At) {
gt = yt ? vt ? G.plotWidth : 0 : vt ? 0 : rt.toPixels(Ct.min) || 0, gt = c(m(dt, gt), 0, nt), dt = c(Math.round(rt.toPixels(m(Pt.value, Ct.max), !0) || 0), 0, nt), pt && (gt = dt = rt.toPixels(Ct.max)), at = Math.abs(gt - dt), J = Math.min(gt, dt), tt = Math.max(gt, dt), rt.isXAxis ? (ht = { x: ct ? tt : J, y: 0, width: at, height: nt }, vt || (ht.x = G.plotHeight - ht.x)) : (ht = { x: 0, y: ct ? tt : J, width: nt, height: at }, vt && (ht.y = G.plotWidth - ht.y)), ct && z.isVML && (ht = rt.isXAxis ? {
x: 0,
y: yt ? J : tt,
height: ht.width,
width: G.chartWidth
} : { x: ht.y - G.plotLeft - G.spacingBox.x, y: 0, width: ht.height, height: G.chartHeight }), q[At] ? q[At].animate(ht) : q[At] = z.clipRect(ht), ot = k["zone-area-" + At], lt = k["zone-graph-" + At], it && lt && lt.clip(q[At]), et && ot && ot.clip(q[At]), pt = Pt.value > Ct.max, k.resetZones && dt === 0 && (dt = void 0);
}), this.clips = q;
} else
k.visible && (it && it.show(!0), et && et.show(!0));
}, Q.prototype.invertGroups = function(k) {
function G() {
["group", "markerGroup"].forEach(function(q) {
z[q] && ($.renderer.isVML && z[q].attr({ width: z.yAxis.len, height: z.xAxis.len }), z[q].width = z.yAxis.len, z[q].height = z.xAxis.len, z[q].invert(z.isRadialSeries ? !1 : k));
});
}
var z = this, $ = z.chart;
z.xAxis && (z.eventsToUnbind.push(w($, "resize", G)), G(), z.invertGroups = G);
}, Q.prototype.plotGroup = function(k, G, z, $, q) {
var it = this[k], et = !it;
return z = { visibility: z, zIndex: $ || 0.1 }, typeof this.opacity > "u" || this.chart.styledMode || this.state === "inactive" || (z.opacity = this.opacity), et && (this[k] = it = this.chart.renderer.g().add(q)), it.addClass("highcharts-" + G + " highcharts-series-" + this.index + " highcharts-" + this.type + "-series " + (h(this.colorIndex) ? "highcharts-color-" + this.colorIndex + " " : "") + (this.options.className || "") + (it.hasClass("highcharts-tracker") ? " highcharts-tracker" : ""), !0), it.attr(z)[et ? "attr" : "animate"](this.getPlotBox()), it;
}, Q.prototype.getPlotBox = function() {
var k = this.chart, G = this.xAxis, z = this.yAxis;
return k.inverted && (G = z, z = this.xAxis), { translateX: G ? G.left : k.plotLeft, translateY: z ? z.top : k.plotTop, scaleX: 1, scaleY: 1 };
}, Q.prototype.removeEvents = function(k) {
k || L(this), this.eventsToUnbind.length && (this.eventsToUnbind.forEach(function(G) {
G();
}), this.eventsToUnbind.length = 0);
}, Q.prototype.render = function() {
var k = this, G = k.chart, z = k.options, $ = v(z.animation), q = k.visible ? "inherit" : "hidden", it = z.zIndex, et = k.hasRendered, nt = G.seriesGroup, rt = G.inverted;
G = !k.finishedAnimating && G.renderer.isSVG ? $.duration : 0, A(this, "render");
var ct = k.plotGroup("group", "series", q, it, nt);
k.markerGroup = k.plotGroup("markerGroup", "markers", q, it, nt), z.clip !== !1 && k.setClip(), k.animate && G && k.animate(!0), ct.inverted = m(k.invertible, k.isCartesian) ? rt : !1, k.drawGraph && (k.drawGraph(), k.applyZones()), k.visible && k.drawPoints(), k.drawDataLabels && k.drawDataLabels(), k.redrawPoints && k.redrawPoints(), k.drawTracker && k.options.enableMouseTracking !== !1 && k.drawTracker(), k.invertGroups(rt), k.animate && G && k.animate(), et || (G && $.defer && (G += $.defer), k.animationTimeout = V(function() {
k.afterAnimate();
}, G || 0)), k.isDirty = !1, k.hasRendered = !0, A(k, "afterRender");
}, Q.prototype.redraw = function() {
var k = this.chart, G = this.isDirty || this.isDirtyData, z = this.group, $ = this.xAxis, q = this.yAxis;
z && (k.inverted && z.attr({
width: k.plotWidth,
height: k.plotHeight
}), z.animate({ translateX: m($ && $.left, k.plotLeft), translateY: m(q && q.top, k.plotTop) })), this.translate(), this.render(), G && delete this.kdTree;
}, Q.prototype.searchPoint = function(k, G) {
var z = this.xAxis, $ = this.yAxis, q = this.chart.inverted;
return this.searchKDTree({ clientX: q ? z.len - k.chartY + z.pos : k.chartX - z.pos, plotY: q ? $.len - k.chartX + $.pos : k.chartY - $.pos }, G, k);
}, Q.prototype.buildKDTree = function(k) {
function G(q, it, et) {
var nt = q && q.length;
if (nt) {
var rt = z.kdAxisArray[it % et];
return q.sort(function(ct, gt) {
return ct[rt] - gt[rt];
}), nt = Math.floor(nt / 2), { point: q[nt], left: G(q.slice(0, nt), it + 1, et), right: G(q.slice(nt + 1), it + 1, et) };
}
}
this.buildingKdTree = !0;
var z = this, $ = -1 < z.options.findNearestPointBy.indexOf("y") ? 2 : 1;
delete z.kdTree, V(function() {
z.kdTree = G(z.getValidPoints(null, !z.directTouch), $, $), z.buildingKdTree = !1;
}, z.options.kdNow || k && k.type === "touchstart" ? 0 : 1);
}, Q.prototype.searchKDTree = function(k, G, z) {
function $(rt, ct, gt, dt) {
var ht = ct.point, at = q.kdAxisArray[gt % dt], J = ht, tt = h(rt[it]) && h(ht[it]) ? Math.pow(rt[it] - ht[it], 2) : null, ot = h(rt[et]) && h(ht[et]) ? Math.pow(rt[et] - ht[et], 2) : null;
return ot = (tt || 0) + (ot || 0), ht.dist = h(ot) ? Math.sqrt(ot) : Number.MAX_VALUE, ht.distX = h(tt) ? Math.sqrt(tt) : Number.MAX_VALUE, at = rt[at] - ht[at], ot = 0 > at ? "left" : "right", tt = 0 > at ? "right" : "left", ct[ot] && (ot = $(rt, ct[ot], gt + 1, dt), J = ot[nt] < J[nt] ? ot : ht), ct[tt] && Math.sqrt(at * at) < J[nt] && (rt = $(rt, ct[tt], gt + 1, dt), J = rt[nt] < J[nt] ? rt : J), J;
}
var q = this, it = this.kdAxisArray[0], et = this.kdAxisArray[1], nt = G ? "distX" : "dist";
if (G = -1 < q.options.findNearestPointBy.indexOf("y") ? 2 : 1, this.kdTree || this.buildingKdTree || this.buildKDTree(z), this.kdTree)
return $(
k,
this.kdTree,
G,
G
);
}, Q.prototype.pointPlacementToXValue = function() {
var k = this.options, G = k.pointRange, z = this.xAxis;
return k = k.pointPlacement, k === "between" && (k = z.reversed ? -0.5 : 0.5), W(k) ? k * (G || z.pointRange) : 0;
}, Q.prototype.isPointInside = function(k) {
var G = this.chart, z = this.xAxis, $ = this.yAxis;
return typeof k.plotY < "u" && typeof k.plotX < "u" && 0 <= k.plotY && k.plotY <= ($ ? $.len : G.plotHeight) && 0 <= k.plotX && k.plotX <= (z ? z.len : G.plotWidth);
}, Q.prototype.drawTracker = function() {
var k = this, G = k.options, z = G.trackByArea, $ = [].concat(z ? k.areaPath : k.graphPath), q = k.chart, it = q.pointer, et = q.renderer, nt = q.options.tooltip.snap, rt = k.tracker, ct = function(dt) {
q.hoverSeries !== k && k.onMouseOver();
}, gt = "rgba(192,192,192," + (B ? 1e-4 : 2e-3) + ")";
rt ? rt.attr({ d: $ }) : k.graph && (k.tracker = et.path($).attr({ visibility: k.visible ? "visible" : "hidden", zIndex: 2 }).addClass(z ? "highcharts-tracker-area" : "highcharts-tracker-line").add(k.group), q.styledMode || k.tracker.attr({ "stroke-linecap": "round", "stroke-linejoin": "round", stroke: gt, fill: z ? gt : "none", "stroke-width": k.graph.strokeWidth() + (z ? 0 : 2 * nt) }), [k.tracker, k.markerGroup, k.dataLabelsGroup].forEach(function(dt) {
dt && (dt.addClass("highcharts-tracker").on("mouseover", ct).on("mouseout", function(ht) {
it.onTrackerMouseOut(ht);
}), G.cursor && !q.styledMode && dt.css({ cursor: G.cursor }), O) && dt.on("touchstart", ct);
})), A(this, "afterDrawTracker");
}, Q.prototype.addPoint = function(k, G, z, $, q) {
var it = this.options, et = this.data, nt = this.chart, rt = this.xAxis;
rt = rt && rt.hasNames && rt.names;
var ct = it.data, gt = this.xData, dt;
G = m(G, !0);
var ht = { series: this };
this.pointClass.prototype.applyOptions.apply(
ht,
[k]
);
var at = ht.x, J = gt.length;
if (this.requireSorting && at < gt[J - 1])
for (dt = !0; J && gt[J - 1] > at; )
J--;
this.updateParallelArrays(ht, "splice", J, 0, 0), this.updateParallelArrays(ht, J), rt && ht.name && (rt[at] = ht.name), ct.splice(J, 0, k), dt && (this.data.splice(J, 0, null), this.processData()), it.legendType === "point" && this.generatePoints(), z && (et[0] && et[0].remove ? et[0].remove(!1) : (et.shift(), this.updateParallelArrays(ht, "shift"), ct.shift())), q !== !1 && A(this, "addPoint", { point: ht }), this.isDirtyData = this.isDirty = !0, G && nt.redraw($);
}, Q.prototype.removePoint = function(k, G, z) {
var $ = this, q = $.data, it = q[k], et = $.points, nt = $.chart, rt = function() {
et && et.length === q.length && et.splice(k, 1), q.splice(k, 1), $.options.data.splice(k, 1), $.updateParallelArrays(it || { series: $ }, "splice", k, 1), it && it.destroy(), $.isDirty = !0, $.isDirtyData = !0, G && nt.redraw();
};
d(z, nt), G = m(G, !0), it ? it.firePointEvent("remove", null, rt) : rt();
}, Q.prototype.remove = function(k, G, z, $) {
function q() {
it.destroy($), et.isDirtyLegend = et.isDirtyBox = !0, et.linkSeries(), m(k, !0) && et.redraw(G);
}
var it = this, et = it.chart;
z !== !1 ? A(
it,
"remove",
null,
q
) : q();
}, Q.prototype.update = function(k, G) {
k = p(k, this.userOptions), A(this, "update", { options: k });
var z = this, $ = z.chart, q = z.userOptions, it = z.initialType || z.type, et = $.options.plotOptions, nt = b[it].prototype, rt = z.finishedAnimating && { animation: !1 }, ct = {}, gt, dt = ["eventOptions", "navigatorSeries", "baseSeries"], ht = k.type || q.type || $.options.chart.type, at = !(this.hasDerivedData || ht && ht !== this.type || typeof k.pointStart < "u" || typeof k.pointInterval < "u" || typeof k.relativeXValue < "u" || z.hasOptionChanged("dataGrouping") || z.hasOptionChanged("pointStart") || z.hasOptionChanged("pointInterval") || z.hasOptionChanged("pointIntervalUnit") || z.hasOptionChanged("keys"));
if (ht = ht || it, at && (dt.push("data", "isDirtyData", "points", "processedXData", "processedYData", "xIncrement", "cropped", "_hasPointMarkers", "_hasPointLabels", "clips", "nodes", "layout", "mapMap", "mapData", "minY", "maxY", "minX", "maxX"), k.visible !== !1 && dt.push("area", "graph"), z.parallelArrays.forEach(function(tt) {
dt.push(tt + "Data");
}), k.data && (k.dataSorting && s(z.options.dataSorting, k.dataSorting), this.setData(k.data, !1))), k = X(q, rt, { index: typeof q.index > "u" ? z.index : q.index, pointStart: m(et && et.series && et.series.pointStart, q.pointStart, z.xData[0]) }, !at && { data: z.options.data }, k), at && k.data && (k.data = z.options.data), dt = ["group", "markerGroup", "dataLabelsGroup", "transformGroup"].concat(dt), dt.forEach(function(tt) {
dt[tt] = z[tt], delete z[tt];
}), et = !1, b[ht]) {
if (et = ht !== z.type, z.remove(!1, !1, !1, !0), et)
if (Object.setPrototypeOf)
Object.setPrototypeOf(z, b[ht].prototype);
else {
rt = Object.hasOwnProperty.call(z, "hcEvents") && z.hcEvents;
for (gt in nt)
z[gt] = void 0;
s(z, b[ht].prototype), rt ? z.hcEvents = rt : delete z.hcEvents;
}
} else
t(17, !0, $, { missingModuleFor: ht });
if (dt.forEach(function(tt) {
z[tt] = dt[tt];
}), z.init($, k), at && this.points) {
var J = z.options;
J.visible === !1 ? (ct.graphic = 1, ct.dataLabel = 1) : z._hasPointLabels || (k = J.marker, nt = J.dataLabels, !k || k.enabled !== !1 && (q.marker && q.marker.symbol) === k.symbol || (ct.graphic = 1), nt && nt.enabled === !1 && (ct.dataLabel = 1)), this.points.forEach(function(tt) {
tt && tt.series && (tt.resolveColor(), Object.keys(ct).length && tt.destroyElements(ct), J.showInLegend === !1 && tt.legendItem && $.legend.destroyItem(tt));
}, this);
}
z.initialType = it, $.linkSeries(), et && z.linkedSeries.length && (z.isDirtyData = !0), A(this, "afterUpdate"), m(G, !0) && $.redraw(at ? void 0 : !1);
}, Q.prototype.setName = function(k) {
this.name = this.options.name = this.userOptions.name = k, this.chart.isDirtyLegend = !0;
}, Q.prototype.hasOptionChanged = function(k) {
var G = this.options[k], z = this.chart.options.plotOptions, $ = this.userOptions[k];
return $ ? G !== $ : G !== m(
z && z[this.type] && z[this.type][k],
z && z.series && z.series[k],
G
);
}, Q.prototype.onMouseOver = function() {
var k = this.chart, G = k.hoverSeries;
k.pointer.setHoverChartIndex(), G && G !== this && G.onMouseOut(), this.options.events.mouseOver && A(this, "mouseOver"), this.setState("hover"), k.hoverSeries = this;
}, Q.prototype.onMouseOut = function() {
var k = this.options, G = this.chart, z = G.tooltip, $ = G.hoverPoint;
G.hoverSeries = null, $ && $.onMouseOut(), this && k.events.mouseOut && A(this, "mouseOut"), !z || this.stickyTracking || z.shared && !this.noSharedTooltip || z.hide(), G.series.forEach(function(q) {
q.setState(
"",
!0
);
});
}, Q.prototype.setState = function(k, G) {
var z = this, $ = z.options, q = z.graph, it = $.inactiveOtherPoints, et = $.states, nt = m(et[k || "normal"] && et[k || "normal"].animation, z.chart.options.chart.animation), rt = $.lineWidth, ct = 0, gt = $.opacity;
if (k = k || "", z.state !== k && ([z.group, z.markerGroup, z.dataLabelsGroup].forEach(function(dt) {
dt && (z.state && dt.removeClass("highcharts-series-" + z.state), k && dt.addClass("highcharts-series-" + k));
}), z.state = k, !z.chart.styledMode)) {
if (et[k] && et[k].enabled === !1)
return;
if (k && (rt = et[k].lineWidth || rt + (et[k].lineWidthPlus || 0), gt = m(et[k].opacity, gt)), q && !q.dashstyle)
for ($ = { "stroke-width": rt }, q.animate($, nt); z["zone-graph-" + ct]; )
z["zone-graph-" + ct].animate($, nt), ct += 1;
it || [z.group, z.markerGroup, z.dataLabelsGroup, z.labelBySeries].forEach(function(dt) {
dt && dt.animate({ opacity: gt }, nt);
});
}
G && it && z.points && z.setAllPointsToState(k || void 0);
}, Q.prototype.setAllPointsToState = function(k) {
this.points.forEach(function(G) {
G.setState && G.setState(k);
});
}, Q.prototype.setVisible = function(k, G) {
var z = this, $ = z.chart, q = z.legendItem, it = $.options.chart.ignoreHiddenSeries, et = z.visible, nt = (z.visible = k = z.options.visible = z.userOptions.visible = typeof k > "u" ? !et : k) ? "show" : "hide";
["group", "dataLabelsGroup", "markerGroup", "tracker", "tt"].forEach(function(rt) {
z[rt] && z[rt][nt]();
}), ($.hoverSeries === z || ($.hoverPoint && $.hoverPoint.series) === z) && z.onMouseOut(), q && $.legend.colorizeItem(z, k), z.isDirty = !0, z.options.stacking && $.series.forEach(function(rt) {
rt.options.stacking && rt.visible && (rt.isDirty = !0);
}), z.linkedSeries.forEach(function(rt) {
rt.setVisible(k, !1);
}), it && ($.isDirtyBox = !0), A(z, nt), G !== !1 && $.redraw();
}, Q.prototype.show = function() {
this.setVisible(!0);
}, Q.prototype.hide = function() {
this.setVisible(!1);
}, Q.prototype.select = function(k) {
this.selected = k = this.options.selected = typeof k > "u" ? !this.selected : k, this.checkbox && (this.checkbox.checked = k), A(this, k ? "select" : "unselect");
}, Q.prototype.shouldShowTooltip = function(k, G, z) {
return z === void 0 && (z = {}), z.series = this, z.visiblePlotOnly = !0, this.chart.isInsidePlot(k, G, z);
}, Q.defaultOptions = F, Q;
}(), s(y.prototype, { axisTypes: [
"xAxis",
"yAxis"
], coll: "series", colorCounter: 0, cropShoulder: 1, directTouch: !1, drawLegendSymbol: H.drawLineMarker, isCartesian: !0, kdAxisArray: ["clientX", "plotY"], parallelArrays: ["x", "y"], pointClass: U, requireSorting: !0, sorted: !0 }), N.series = y, y;
}), E(l, "Extensions/ScrollablePlotArea.js", [l["Core/Animation/AnimationUtilities.js"], l["Core/Axis/Axis.js"], l["Core/Chart/Chart.js"], l["Core/Series/Series.js"], l["Core/Renderer/RendererRegistry.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H, U) {
var F = y.stop, N = U.addEvent, R = U.createElement, S = U.merge, v = U.pick;
N(I, "afterSetChartSize", function(d) {
var u = this.options.chart.scrollablePlotArea, T = u && u.minWidth;
if (u = u && u.minHeight, !this.renderer.forExport) {
if (T) {
if (this.scrollablePixelsX = T = Math.max(0, T - this.chartWidth)) {
this.scrollablePlotBox = this.renderer.scrollablePlotBox = S(this.plotBox), this.plotBox.width = this.plotWidth += T, this.inverted ? this.clipBox.height += T : this.clipBox.width += T;
var O = { 1: { name: "right", value: T } };
}
} else
u && (this.scrollablePixelsY = T = Math.max(
0,
u - this.chartHeight
)) && (this.scrollablePlotBox = this.renderer.scrollablePlotBox = S(this.plotBox), this.plotBox.height = this.plotHeight += T, this.inverted ? this.clipBox.width += T : this.clipBox.height += T, O = { 2: { name: "bottom", value: T } });
O && !d.skipAxes && this.axes.forEach(function(B) {
O[B.side] ? B.getPlotLinePath = function() {
var C = O[B.side].name, b = this[C];
this[C] = b - O[B.side].value;
var w = j.prototype.getPlotLinePath.apply(this, arguments);
return this[C] = b, w;
} : (B.setAxisSize(), B.setAxisTranslation());
});
}
}), N(I, "render", function() {
this.scrollablePixelsX || this.scrollablePixelsY ? (this.setUpScrolling && this.setUpScrolling(), this.applyFixed()) : this.fixedDiv && this.applyFixed();
}), I.prototype.setUpScrolling = function() {
var d = this, u = { WebkitOverflowScrolling: "touch", overflowX: "hidden", overflowY: "hidden" };
this.scrollablePixelsX && (u.overflowX = "auto"), this.scrollablePixelsY && (u.overflowY = "auto"), this.scrollingParent = R("div", { className: "highcharts-scrolling-parent" }, { position: "relative" }, this.renderTo), this.scrollingContainer = R(
"div",
{ className: "highcharts-scrolling" },
u,
this.scrollingParent
), N(this.scrollingContainer, "scroll", function() {
d.pointer && delete d.pointer.chartPosition;
}), this.innerContainer = R("div", { className: "highcharts-inner-container" }, null, this.scrollingContainer), this.innerContainer.appendChild(this.container), this.setUpScrolling = null;
}, I.prototype.moveFixedElements = function() {
var d = this.container, u = this.fixedRenderer, T = ".highcharts-contextbutton .highcharts-credits .highcharts-legend .highcharts-legend-checkbox .highcharts-navigator-series .highcharts-navigator-xaxis .highcharts-navigator-yaxis .highcharts-navigator .highcharts-reset-zoom .highcharts-drillup-button .highcharts-scrollbar .highcharts-subtitle .highcharts-title".split(" "), O;
this.scrollablePixelsX && !this.inverted ? O = ".highcharts-yaxis" : this.scrollablePixelsX && this.inverted || this.scrollablePixelsY && !this.inverted ? O = ".highcharts-xaxis" : this.scrollablePixelsY && this.inverted && (O = ".highcharts-yaxis"), O && T.push(O + ":not(.highcharts-radial-axis)", O + "-labels:not(.highcharts-radial-axis-labels)"), T.forEach(function(B) {
[].forEach.call(d.querySelectorAll(B), function(C) {
(C.namespaceURI === u.SVG_NS ? u.box : u.box.parentNode).appendChild(C), C.style.pointerEvents = "auto";
});
});
}, I.prototype.applyFixed = function() {
var d = !this.fixedDiv, u = this.options.chart, T = u.scrollablePlotArea, O = H.getRendererType();
d ? (this.fixedDiv = R("div", { className: "highcharts-fixed" }, { position: "absolute", overflow: "hidden", pointerEvents: "none", zIndex: (u.style && u.style.zIndex || 0) + 2, top: 0 }, null, !0), this.scrollingContainer && this.scrollingContainer.parentNode.insertBefore(this.fixedDiv, this.scrollingContainer), this.renderTo.style.overflow = "visible", this.fixedRenderer = u = new O(
this.fixedDiv,
this.chartWidth,
this.chartHeight,
this.options.chart.style
), this.scrollableMask = u.path().attr({ fill: this.options.chart.backgroundColor || "#fff", "fill-opacity": v(T.opacity, 0.85), zIndex: -1 }).addClass("highcharts-scrollable-mask").add(), N(this, "afterShowResetZoom", this.moveFixedElements), N(this, "afterDrilldown", this.moveFixedElements), N(this, "afterLayOutTitles", this.moveFixedElements)) : this.fixedRenderer.setSize(this.chartWidth, this.chartHeight), (this.scrollableDirty || d) && (this.scrollableDirty = !1, this.moveFixedElements()), u = this.chartWidth + (this.scrollablePixelsX || 0), O = this.chartHeight + (this.scrollablePixelsY || 0), F(this.container), this.container.style.width = u + "px", this.container.style.height = O + "px", this.renderer.boxWrapper.attr({ width: u, height: O, viewBox: [0, 0, u, O].join(" ") }), this.chartBackground.attr({ width: u, height: O }), this.scrollingContainer.style.height = this.chartHeight + "px", d && (T.scrollPositionX && (this.scrollingContainer.scrollLeft = this.scrollablePixelsX * T.scrollPositionX), T.scrollPositionY && (this.scrollingContainer.scrollTop = this.scrollablePixelsY * T.scrollPositionY)), O = this.axisOffset, d = this.plotTop - O[0] - 1, T = this.plotLeft - O[3] - 1, u = this.plotTop + this.plotHeight + O[2] + 1, O = this.plotLeft + this.plotWidth + O[1] + 1;
var B = this.plotLeft + this.plotWidth - (this.scrollablePixelsX || 0), C = this.plotTop + this.plotHeight - (this.scrollablePixelsY || 0);
d = this.scrollablePixelsX ? [["M", 0, d], ["L", this.plotLeft - 1, d], ["L", this.plotLeft - 1, u], ["L", 0, u], ["Z"], ["M", B, d], ["L", this.chartWidth, d], ["L", this.chartWidth, u], ["L", B, u], ["Z"]] : this.scrollablePixelsY ? [["M", T, 0], ["L", T, this.plotTop - 1], ["L", O, this.plotTop - 1], ["L", O, 0], ["Z"], ["M", T, C], ["L", T, this.chartHeight], ["L", O, this.chartHeight], ["L", O, C], ["Z"]] : [["M", 0, 0]], this.redrawTrigger !== "adjustHeight" && this.scrollableMask.attr({ d });
}, N(j, "afterInit", function() {
this.chart.scrollableDirty = !0;
}), N(Z, "show", function() {
this.chart.scrollableDirty = !0;
});
}), E(l, "Core/Axis/StackingAxis.js", [l["Core/Animation/AnimationUtilities.js"], l["Core/Axis/Axis.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = y.getDeferredAnimation, H = I.addEvent, U = I.destroyObjectProperties, F = I.fireEvent, N = I.isNumber, R = I.objectEach, S;
return function(v) {
function d() {
var B = this.stacking;
if (B) {
var C = B.stacks;
R(C, function(b, w) {
U(b), C[w] = null;
}), B && B.stackTotalGroup && B.stackTotalGroup.destroy();
}
}
function u() {
this.stacking || (this.stacking = new O(this));
}
var T = [];
v.compose = function(B) {
return T.indexOf(B) === -1 && (T.push(B), H(B, "init", u), H(B, "destroy", d)), B;
};
var O = function() {
function B(C) {
this.oldStacks = {}, this.stacks = {}, this.stacksTouched = 0, this.axis = C;
}
return B.prototype.buildStacks = function() {
var C = this.axis, b = C.series, w = C.options.reversedStacks, x = b.length, a;
if (!C.isXAxis) {
for (this.usePercentage = !1, a = x; a--; ) {
var c = b[w ? a : x - a - 1];
c.setStackedPoints(), c.setGroupedPoints();
}
for (a = 0; a < x; a++)
b[a].modifyStacks();
F(C, "afterBuildStacks");
}
}, B.prototype.cleanStacks = function() {
if (!this.axis.isXAxis) {
if (this.oldStacks)
var C = this.stacks = this.oldStacks;
R(C, function(b) {
R(b, function(w) {
w.cumulative = w.total;
});
});
}
}, B.prototype.resetStacks = function() {
var C = this, b = C.stacks;
C.axis.isXAxis || R(b, function(w) {
R(
w,
function(x, a) {
N(x.touched) && x.touched < C.stacksTouched ? (x.destroy(), delete w[a]) : (x.total = null, x.cumulative = null);
}
);
});
}, B.prototype.renderStackTotals = function() {
var C = this.axis, b = C.chart, w = b.renderer, x = this.stacks;
C = Z(b, C.options.stackLabels && C.options.stackLabels.animation || !1);
var a = this.stackTotalGroup = this.stackTotalGroup || w.g("stack-labels").attr({ visibility: "visible", zIndex: 6, opacity: 0 }).add();
a.translate(b.plotLeft, b.plotTop), R(x, function(c) {
R(c, function(p) {
p.render(a);
});
}), a.animate(
{ opacity: 1 },
C
);
}, B;
}();
v.Additions = O;
}(S || (S = {})), S;
}), E(l, "Extensions/Stacking.js", [l["Core/Axis/Axis.js"], l["Core/Chart/Chart.js"], l["Core/FormatUtilities.js"], l["Core/Globals.js"], l["Core/Series/Series.js"], l["Core/Axis/StackingAxis.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H, U, F) {
var N = I.format, R = F.correctFloat, S = F.defined, v = F.destroyObjectProperties, d = F.isArray, u = F.isNumber, T = F.objectEach, O = F.pick, B = function() {
function C(b, w, x, a, c) {
var p = b.chart.inverted;
this.axis = b, this.isNegative = x, this.options = w = w || {}, this.x = a, this.total = null, this.points = {}, this.hasValidPoints = !1, this.stack = c, this.rightCliff = this.leftCliff = 0, this.alignOptions = { align: w.align || (p ? x ? "left" : "right" : "center"), verticalAlign: w.verticalAlign || (p ? "middle" : x ? "bottom" : "top"), y: w.y, x: w.x }, this.textAlign = w.textAlign || (p ? x ? "right" : "left" : "center");
}
return C.prototype.destroy = function() {
v(this, this.axis);
}, C.prototype.render = function(b) {
var w = this.axis.chart, x = this.options, a = x.format;
a = a ? N(a, this, w) : x.formatter.call(this), this.label ? this.label.attr({
text: a,
visibility: "hidden"
}) : (this.label = w.renderer.label(a, null, null, x.shape, null, null, x.useHTML, !1, "stack-labels"), a = { r: x.borderRadius || 0, text: a, rotation: x.rotation, padding: O(x.padding, 5), visibility: "hidden" }, w.styledMode || (a.fill = x.backgroundColor, a.stroke = x.borderColor, a["stroke-width"] = x.borderWidth, this.label.css(x.style)), this.label.attr(a), this.label.added || this.label.add(b)), this.label.labelrank = w.plotSizeY;
}, C.prototype.setOffset = function(b, w, x, a, c) {
var p = this.axis, i = p.chart;
a = p.translate(p.stacking.usePercentage ? 100 : a || this.total, 0, 0, 0, 1), x = p.translate(x || 0), x = S(a) && Math.abs(a - x), b = O(c, i.xAxis[0].translate(this.x)) + b, p = S(a) && this.getStackBox(i, this, b, a, w, x, p), w = this.label, x = this.isNegative, b = O(this.options.overflow, "justify") === "justify";
var h = this.textAlign;
w && p && (c = w.getBBox(), a = w.padding, h = h === "left" ? i.inverted ? -a : a : h === "right" ? c.width : i.inverted && h === "center" ? c.width / 2 : i.inverted ? x ? c.width + a : -a : c.width / 2, x = i.inverted ? c.height / 2 : x ? -a : c.height, this.alignOptions.x = O(this.options.x, 0), this.alignOptions.y = O(this.options.y, 0), p.x -= h, p.y -= x, w.align(this.alignOptions, null, p), i.isInsidePlot(w.alignAttr.x + h - this.alignOptions.x, w.alignAttr.y + x - this.alignOptions.y) ? w.show() : (w.alignAttr.y = -9999, b = !1), b && H.prototype.justifyDataLabel.call(this.axis, w, this.alignOptions, w.alignAttr, c, p), w.attr({ x: w.alignAttr.x, y: w.alignAttr.y }), O(!b && this.options.crop, !0) && ((i = u(w.x) && u(w.y) && i.isInsidePlot(w.x - a + w.width, w.y) && i.isInsidePlot(w.x + a, w.y)) || w.hide()));
}, C.prototype.getStackBox = function(b, w, x, a, c, p, i) {
var h = w.axis.reversed, o = b.inverted, t = i.height + i.pos - (o ? b.plotLeft : b.plotTop);
return w = w.isNegative && !h || !w.isNegative && h, { x: o ? w ? a - i.right : a - p + i.pos - b.plotLeft : x + b.xAxis[0].transB - b.plotLeft, y: o ? i.height - x - c : w ? t - a - p : t - a, width: o ? p : c, height: o ? c : p };
}, C;
}();
return j.prototype.getStacks = function() {
var C = this, b = C.inverted;
C.yAxis.forEach(function(w) {
w.stacking && w.stacking.stacks && w.hasVisibleSeries && (w.stacking.oldStacks = w.stacking.stacks);
}), C.series.forEach(function(w) {
var x = w.xAxis && w.xAxis.options || {};
!w.options.stacking || w.visible !== !0 && C.options.chart.ignoreHiddenSeries !== !1 || (w.stackKey = [w.type, O(w.options.stack, ""), b ? x.top : x.left, b ? x.height : x.width].join());
});
}, U.compose(y), H.prototype.setGroupedPoints = function() {
var C = this.yAxis.stacking;
this.options.centerInCategory && (this.is("column") || this.is("columnrange")) && !this.options.stacking && 1 < this.chart.series.length ? H.prototype.setStackedPoints.call(this, "group") : C && T(C.stacks, function(b, w) {
w.slice(-5) === "group" && (T(b, function(x) {
return x.destroy();
}), delete C.stacks[w]);
});
}, H.prototype.setStackedPoints = function(C) {
var b = C || this.options.stacking;
if (b && (this.visible === !0 || this.chart.options.chart.ignoreHiddenSeries === !1)) {
var w = this.processedXData, x = this.processedYData, a = [], c = x.length, p = this.options, i = p.threshold, h = O(p.startFromThreshold && i, 0);
p = p.stack, C = C ? this.type + "," + b : this.stackKey;
var o = "-" + C, t = this.negStacks, s = this.yAxis, n = s.stacking.stacks, A = s.stacking.oldStacks, _, D;
for (s.stacking.stacksTouched += 1, D = 0; D < c; D++) {
var W = w[D], P = x[D], X = this.getStackIndicator(
X,
W,
this.index
), g = X.key, m = (_ = t && P < (h ? 0 : i)) ? o : C;
n[m] || (n[m] = {}), n[m][W] || (A[m] && A[m][W] ? (n[m][W] = A[m][W], n[m][W].total = null) : n[m][W] = new B(s, s.options.stackLabels, _, W, p)), m = n[m][W], P !== null ? (m.points[g] = m.points[this.index] = [O(m.cumulative, h)], S(m.cumulative) || (m.base = g), m.touched = s.stacking.stacksTouched, 0 < X.index && this.singleStacks === !1 && (m.points[g][0] = m.points[this.index + "," + W + ",0"][0])) : m.points[g] = m.points[this.index] = null, b === "percent" ? (_ = _ ? C : o, t && n[_] && n[_][W] ? (_ = n[_][W], m.total = _.total = Math.max(_.total, m.total) + Math.abs(P) || 0) : m.total = R(m.total + (Math.abs(P) || 0))) : b === "group" ? (d(P) && (P = P[0]), P !== null && (m.total = (m.total || 0) + 1)) : m.total = R(m.total + (P || 0)), m.cumulative = b === "group" ? (m.total || 1) - 1 : O(m.cumulative, h) + (P || 0), P !== null && (m.points[g].push(m.cumulative), a[D] = m.cumulative, m.hasValidPoints = !0);
}
b === "percent" && (s.stacking.usePercentage = !0), b !== "group" && (this.stackedYData = a), s.stacking.oldStacks = {};
}
}, H.prototype.modifyStacks = function() {
var C = this, b = C.stackKey, w = C.yAxis.stacking.stacks, x = C.processedXData, a, c = C.options.stacking;
C[c + "Stacker"] && [b, "-" + b].forEach(function(p) {
for (var i = x.length, h, o; i--; )
h = x[i], a = C.getStackIndicator(a, h, C.index, p), (o = (h = w[p] && w[p][h]) && h.points[a.key]) && C[c + "Stacker"](o, h, i);
});
}, H.prototype.percentStacker = function(C, b, w) {
b = b.total ? 100 / b.total : 0, C[0] = R(C[0] * b), C[1] = R(C[1] * b), this.stackedYData[w] = C[1];
}, H.prototype.getStackIndicator = function(C, b, w, x) {
return !S(C) || C.x !== b || x && C.key !== x ? C = { x: b, index: 0, key: x } : C.index++, C.key = [w, b, C.index].join(), C;
}, Z.StackItem = B, Z.StackItem;
}), E(l, "Series/Line/LineSeries.js", [l["Core/Series/Series.js"], l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = this && this.__extends || function() {
var F = function(N, R) {
return F = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(S, v) {
S.__proto__ = v;
} || function(S, v) {
for (var d in v)
v.hasOwnProperty(d) && (S[d] = v[d]);
}, F(N, R);
};
return function(N, R) {
function S() {
this.constructor = N;
}
F(N, R), N.prototype = R === null ? Object.create(R) : (S.prototype = R.prototype, new S());
};
}(), H = I.defined, U = I.merge;
return I = function(F) {
function N() {
var R = F !== null && F.apply(this, arguments) || this;
return R.data = void 0, R.options = void 0, R.points = void 0, R;
}
return Z(N, F), N.prototype.drawGraph = function() {
var R = this, S = this.options, v = (this.gappedPath || this.getGraphPath).call(this), d = this.chart.styledMode, u = [["graph", "highcharts-graph"]];
d || u[0].push(S.lineColor || this.color || "#cccccc", S.dashStyle), u = R.getZonesGraphs(u), u.forEach(function(T, O) {
var B = T[0], C = R[B], b = C ? "animate" : "attr";
C ? (C.endX = R.preventGraphAnimation ? null : v.xMap, C.animate({ d: v })) : v.length && (R[B] = C = R.chart.renderer.path(v).addClass(T[1]).attr({ zIndex: 1 }).add(R.group)), C && !d && (B = { stroke: T[2], "stroke-width": S.lineWidth, fill: R.fillGraph && R.color || "none" }, T[3] ? B.dashstyle = T[3] : S.linecap !== "square" && (B["stroke-linecap"] = B["stroke-linejoin"] = "round"), C[b](B).shadow(2 > O && S.shadow)), C && (C.startX = v.xMap, C.isArea = v.isArea);
});
}, N.prototype.getGraphPath = function(R, S, v) {
var d = this, u = d.options, T = [], O = [], B, C = u.step;
R = R || d.points;
var b = R.reversed;
return b && R.reverse(), (C = { right: 1, center: 2 }[C] || C && 3) && b && (C = 4 - C), R = this.getValidPoints(R, !1, !(u.connectNulls && !S && !v)), R.forEach(function(w, x) {
var a = w.plotX, c = w.plotY, p = R[x - 1];
(w.leftCliff || p && p.rightCliff) && !v && (B = !0), w.isNull && !H(S) && 0 < x ? B = !u.connectNulls : w.isNull && !S ? B = !0 : (x === 0 || B ? x = [["M", w.plotX, w.plotY]] : d.getPointSpline ? x = [d.getPointSpline(R, w, x)] : C ? (x = C === 1 ? [["L", p.plotX, c]] : C === 2 ? [["L", (p.plotX + a) / 2, p.plotY], ["L", (p.plotX + a) / 2, c]] : [["L", a, p.plotY]], x.push(["L", a, c])) : x = [["L", a, c]], O.push(w.x), C && (O.push(w.x), C === 2 && O.push(w.x)), T.push.apply(T, x), B = !1);
}), T.xMap = O, d.graphPath = T;
}, N.prototype.getZonesGraphs = function(R) {
return this.zones.forEach(function(S, v) {
v = ["zone-graph-" + v, "highcharts-graph highcharts-zone-graph-" + v + " " + (S.className || "")], this.chart.styledMode || v.push(S.color || this.color, S.dashStyle || this.options.dashStyle), R.push(v);
}, this), R;
}, N.defaultOptions = U(y.defaultOptions, {}), N;
}(y), j.registerSeriesType("line", I), I;
}), E(l, "Series/Area/AreaSeries.js", [
l["Core/Color/Color.js"],
l["Core/Legend/LegendSymbol.js"],
l["Core/Series/SeriesRegistry.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z) {
var H = this && this.__extends || function() {
var v = function(d, u) {
return v = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(T, O) {
T.__proto__ = O;
} || function(T, O) {
for (var B in O)
O.hasOwnProperty(B) && (T[B] = O[B]);
}, v(d, u);
};
return function(d, u) {
function T() {
this.constructor = d;
}
v(d, u), d.prototype = u === null ? Object.create(u) : (T.prototype = u.prototype, new T());
};
}(), U = y.parse, F = I.seriesTypes.line;
y = Z.extend;
var N = Z.merge, R = Z.objectEach, S = Z.pick;
return Z = function(v) {
function d() {
var u = v !== null && v.apply(this, arguments) || this;
return u.data = void 0, u.options = void 0, u.points = void 0, u;
}
return H(d, v), d.prototype.drawGraph = function() {
this.areaPath = [], v.prototype.drawGraph.apply(this);
var u = this, T = this.areaPath, O = this.options, B = [["area", "highcharts-area", this.color, O.fillColor]];
this.zones.forEach(function(C, b) {
B.push(["zone-area-" + b, "highcharts-area highcharts-zone-area-" + b + " " + C.className, C.color || u.color, C.fillColor || O.fillColor]);
}), B.forEach(function(C) {
var b = C[0], w = u[b], x = w ? "animate" : "attr", a = {};
w ? (w.endX = u.preventGraphAnimation ? null : T.xMap, w.animate({ d: T })) : (a.zIndex = 0, w = u[b] = u.chart.renderer.path(T).addClass(C[1]).add(u.group), w.isArea = !0), u.chart.styledMode || (a.fill = S(C[3], U(C[2]).setOpacity(S(O.fillOpacity, 0.75)).get())), w[x](a), w.startX = T.xMap, w.shiftUnit = O.step ? 2 : 1;
});
}, d.prototype.getGraphPath = function(u) {
var T = F.prototype.getGraphPath, O = this.options, B = O.stacking, C = this.yAxis, b, w = [], x = [], a = this.index, c = C.stacking.stacks[this.stackKey], p = O.threshold, i = Math.round(C.getThreshold(O.threshold));
O = S(O.connectNulls, B === "percent");
var h = function(n, A, _) {
var D = u[n];
n = B && c[D.x].points[a];
var W = D[_ + "Null"] || 0;
if (_ = D[_ + "Cliff"] || 0, D = !0, _ || W) {
var P = (W ? n[0] : n[1]) + _, X = n[0] + _;
D = !!W;
} else
!B && u[A] && u[A].isNull && (P = X = p);
typeof P < "u" && (x.push({ plotX: t, plotY: P === null ? i : C.getThreshold(P), isNull: D, isCliff: !0 }), w.push({ plotX: t, plotY: X === null ? i : C.getThreshold(X), doCurve: !1 }));
};
for (u = u || this.points, B && (u = this.getStackPoints(u)), b = 0; b < u.length; b++) {
B || (u[b].leftCliff = u[b].rightCliff = u[b].leftNull = u[b].rightNull = void 0);
var o = u[b].isNull, t = S(u[b].rectPlotX, u[b].plotX), s = B ? S(u[b].yBottom, i) : i;
(!o || O) && (O || h(b, b - 1, "left"), o && !B && O || (x.push(u[b]), w.push({ x: b, plotX: t, plotY: s })), O || h(b, b + 1, "right"));
}
return b = T.call(this, x, !0, !0), w.reversed = !0, o = T.call(this, w, !0, !0), (s = o[0]) && s[0] === "M" && (o[0] = ["L", s[1], s[2]]), o = b.concat(o), o.length && o.push(["Z"]), T = T.call(this, x, !1, O), o.xMap = b.xMap, this.areaPath = o, T;
}, d.prototype.getStackPoints = function(u) {
var T = this, O = [], B = [], C = this.xAxis, b = this.yAxis, w = b.stacking.stacks[this.stackKey], x = {}, a = b.series, c = a.length, p = b.options.reversedStacks ? 1 : -1, i = a.indexOf(T);
if (u = u || this.points, this.options.stacking) {
for (var h = 0; h < u.length; h++)
u[h].leftNull = u[h].rightNull = void 0, x[u[h].x] = u[h];
R(w, function(t, s) {
t.total !== null && B.push(s);
}), B.sort(function(t, s) {
return t - s;
});
var o = a.map(function(t) {
return t.visible;
});
B.forEach(function(t, s) {
var n = 0, A, _;
if (x[t] && !x[t].isNull)
O.push(x[t]), [-1, 1].forEach(function(W) {
var P = W === 1 ? "rightNull" : "leftNull", X = 0, g = w[B[s + W]];
if (g)
for (var m = i; 0 <= m && m < c; ) {
var L = a[m].index;
A = g.points[L], A || (L === T.index ? x[t][P] = !0 : o[m] && (_ = w[t].points[L]) && (X -= _[1] - _[0])), m += p;
}
x[t][W === 1 ? "rightCliff" : "leftCliff"] = X;
});
else {
for (var D = i; 0 <= D && D < c; ) {
if (A = w[t].points[a[D].index]) {
n = A[1];
break;
}
D += p;
}
n = S(n, 0), n = b.translate(n, 0, 1, 0, 1), O.push({ isNull: !0, plotX: C.translate(t, 0, 0, 0, 1), x: t, plotY: n, yBottom: n });
}
});
}
return O;
}, d.defaultOptions = N(F.defaultOptions, { threshold: 0 }), d;
}(F), y(Z.prototype, {
singleStacks: !1,
drawLegendSymbol: j.drawRectangle
}), I.registerSeriesType("area", Z), Z;
}), E(l, "Series/Spline/SplineSeries.js", [l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]], function(y, j) {
var I = this && this.__extends || function() {
var F = function(N, R) {
return F = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(S, v) {
S.__proto__ = v;
} || function(S, v) {
for (var d in v)
v.hasOwnProperty(d) && (S[d] = v[d]);
}, F(N, R);
};
return function(N, R) {
function S() {
this.constructor = N;
}
F(N, R), N.prototype = R === null ? Object.create(R) : (S.prototype = R.prototype, new S());
};
}(), Z = y.seriesTypes.line, H = j.merge, U = j.pick;
return j = function(F) {
function N() {
var R = F !== null && F.apply(this, arguments) || this;
return R.data = void 0, R.options = void 0, R.points = void 0, R;
}
return I(N, F), N.prototype.getPointSpline = function(R, S, v) {
var d = S.plotX || 0, u = S.plotY || 0, T = R[v - 1];
if (v = R[v + 1], T && !T.isNull && T.doCurve !== !1 && !S.isCliff && v && !v.isNull && v.doCurve !== !1 && !S.isCliff) {
R = T.plotY || 0;
var O = v.plotX || 0;
v = v.plotY || 0;
var B = 0, C = (1.5 * d + (T.plotX || 0)) / 2.5, b = (1.5 * u + R) / 2.5;
O = (1.5 * d + O) / 2.5;
var w = (1.5 * u + v) / 2.5;
O !== C && (B = (w - b) * (O - d) / (O - C) + u - w), b += B, w += B, b > R && b > u ? (b = Math.max(R, u), w = 2 * u - b) : b < R && b < u && (b = Math.min(R, u), w = 2 * u - b), w > v && w > u ? (w = Math.max(v, u), b = 2 * u - w) : w < v && w < u && (w = Math.min(v, u), b = 2 * u - w), S.rightContX = O, S.rightContY = w;
}
return S = ["C", U(T.rightContX, T.plotX, 0), U(T.rightContY, T.plotY, 0), U(C, d, 0), U(b, u, 0), d, u], T.rightContX = T.rightContY = void 0, S;
}, N.defaultOptions = H(Z.defaultOptions), N;
}(Z), y.registerSeriesType("spline", j), j;
}), E(
l,
"Series/AreaSpline/AreaSplineSeries.js",
[l["Series/Area/AreaSeries.js"], l["Series/Spline/SplineSeries.js"], l["Core/Legend/LegendSymbol.js"], l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]],
function(y, j, I, Z, H) {
var U = this && this.__extends || function() {
var S = function(v, d) {
return S = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(u, T) {
u.__proto__ = T;
} || function(u, T) {
for (var O in T)
T.hasOwnProperty(O) && (u[O] = T[O]);
}, S(v, d);
};
return function(v, d) {
function u() {
this.constructor = v;
}
S(v, d), v.prototype = d === null ? Object.create(d) : (u.prototype = d.prototype, new u());
};
}(), F = y.prototype, N = H.extend, R = H.merge;
return H = function(S) {
function v() {
var d = S !== null && S.apply(this, arguments) || this;
return d.data = void 0, d.points = void 0, d.options = void 0, d;
}
return U(v, S), v.defaultOptions = R(j.defaultOptions, y.defaultOptions), v;
}(j), N(H.prototype, { getGraphPath: F.getGraphPath, getStackPoints: F.getStackPoints, drawGraph: F.drawGraph, drawLegendSymbol: I.drawRectangle }), Z.registerSeriesType("areaspline", H), H;
}
), E(l, "Series/Column/ColumnSeries.js", [
l["Core/Animation/AnimationUtilities.js"],
l["Core/Color/Color.js"],
l["Core/Globals.js"],
l["Core/Legend/LegendSymbol.js"],
l["Core/Series/Series.js"],
l["Core/Series/SeriesRegistry.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z, H, U, F) {
var N = this && this.__extends || function() {
var c = function(p, i) {
return c = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(h, o) {
h.__proto__ = o;
} || function(h, o) {
for (var t in o)
o.hasOwnProperty(t) && (h[t] = o[t]);
}, c(p, i);
};
return function(p, i) {
function h() {
this.constructor = p;
}
c(p, i), p.prototype = i === null ? Object.create(i) : (h.prototype = i.prototype, new h());
};
}(), R = y.animObject, S = j.parse, v = I.hasTouch;
y = I.noop;
var d = F.clamp, u = F.css, T = F.defined, O = F.extend, B = F.fireEvent, C = F.isArray, b = F.isNumber, w = F.merge, x = F.pick, a = F.objectEach;
return F = function(c) {
function p() {
var i = c !== null && c.apply(this, arguments) || this;
return i.borderWidth = void 0, i.data = void 0, i.group = void 0, i.options = void 0, i.points = void 0, i;
}
return N(p, c), p.prototype.animate = function(i) {
var h = this, o = this.yAxis, t = h.options, s = this.chart.inverted, n = {}, A = s ? "translateX" : "translateY";
if (i)
n.scaleY = 1e-3, i = d(o.toPixels(t.threshold), o.pos, o.pos + o.len), s ? n.translateX = i - o.len : n.translateY = i, h.clipBox && h.setClip(), h.group.attr(n);
else {
var _ = Number(h.group.attr(A));
h.group.animate({ scaleY: 1 }, O(R(h.options.animation), { step: function(D, W) {
h.group && (n[A] = _ + W.pos * (o.pos - _), h.group.attr(n));
} }));
}
}, p.prototype.init = function(i, h) {
c.prototype.init.apply(this, arguments);
var o = this;
i = o.chart, i.hasRendered && i.series.forEach(function(t) {
t.type === o.type && (t.isDirty = !0);
});
}, p.prototype.getColumnMetrics = function() {
var i = this, h = i.options, o = i.xAxis, t = i.yAxis, s = o.options.reversedStacks;
s = o.reversed && !s || !o.reversed && s;
var n = {}, A, _ = 0;
h.grouping === !1 ? _ = 1 : i.chart.series.forEach(function(X) {
var g = X.yAxis, m = X.options;
if (X.type === i.type && (X.visible || !i.chart.options.chart.ignoreHiddenSeries) && t.len === g.len && t.pos === g.pos) {
if (m.stacking && m.stacking !== "group") {
A = X.stackKey, typeof n[A] > "u" && (n[A] = _++);
var L = n[A];
} else
m.grouping !== !1 && (L = _++);
X.columnIndex = L;
}
});
var D = Math.min(Math.abs(o.transA) * (o.ordinal && o.ordinal.slope || h.pointRange || o.closestPointRange || o.tickInterval || 1), o.len), W = D * h.groupPadding, P = (D - 2 * W) / (_ || 1);
return h = Math.min(h.maxPointWidth || o.len, x(h.pointWidth, P * (1 - 2 * h.pointPadding))), i.columnMetrics = { width: h, offset: (P - h) / 2 + (W + ((i.columnIndex || 0) + (s ? 1 : 0)) * P - D / 2) * (s ? -1 : 1), paddedWidth: P, columnCount: _ }, i.columnMetrics;
}, p.prototype.crispCol = function(i, h, o, t) {
var s = this.chart, n = this.borderWidth, A = -(n % 2 ? 0.5 : 0);
return n = n % 2 ? 0.5 : 1, s.inverted && s.renderer.isVML && (n += 1), this.options.crisp && (o = Math.round(i + o) + A, i = Math.round(i) + A, o -= i), t = Math.round(h + t) + n, A = 0.5 >= Math.abs(h) && 0.5 < t, h = Math.round(h) + n, t -= h, A && t && (--h, t += 1), { x: i, y: h, width: o, height: t };
}, p.prototype.adjustForMissingColumns = function(i, h, o, t) {
var s = this, n = this.options.stacking;
if (!o.isNull && 1 < t.columnCount) {
var A = 0, _ = 0;
a(this.yAxis.stacking && this.yAxis.stacking.stacks, function(D) {
if (typeof o.x == "number" && (D = D[o.x.toString()])) {
var W = D.points[s.index], P = D.total;
n ? (W && (A = _), D.hasValidPoints && _++) : C(W) && (A = W[1], _ = P || 0);
}
}), i = (o.plotX || 0) + ((_ - 1) * t.paddedWidth + h) / 2 - h - A * t.paddedWidth;
}
return i;
}, p.prototype.translate = function() {
var i = this, h = i.chart, o = i.options, t = i.dense = 2 > i.closestPointRange * i.xAxis.transA;
t = i.borderWidth = x(o.borderWidth, t ? 0 : 1);
var s = i.xAxis, n = i.yAxis, A = o.threshold, _ = i.translatedThreshold = n.getThreshold(A), D = x(o.minPointLength, 5), W = i.getColumnMetrics(), P = W.width, X = i.pointXOffset = W.offset, g = i.dataMin, m = i.dataMax, L = i.barW = Math.max(P, 1 + 2 * t);
h.inverted && (_ -= 0.5), o.pointPadding && (L = Math.ceil(L)), H.prototype.translate.apply(i), i.points.forEach(function(Y) {
var V = x(Y.yBottom, _), Q = 999 + Math.abs(V), k = Y.plotX || 0;
Q = d(Y.plotY, -Q, n.len + Q);
var G = Math.min(Q, V), z = Math.max(Q, V) - G, $ = P, q = k + X, it = L;
D && Math.abs(z) < D && (z = D, k = !n.reversed && !Y.negative || n.reversed && Y.negative, b(A) && b(m) && Y.y === A && m <= A && (n.min || 0) < A && (g !== m || (n.max || 0) <= A) && (k = !k), G = Math.abs(G - _) > D ? V - D : _ - (k ? D : 0)), T(Y.options.pointWidth) && ($ = it = Math.ceil(Y.options.pointWidth), q -= Math.round(($ - P) / 2)), o.centerInCategory && (q = i.adjustForMissingColumns(q, $, Y, W)), Y.barX = q, Y.pointWidth = $, Y.tooltipPos = h.inverted ? [d(n.len + n.pos - h.plotLeft - Q, n.pos - h.plotLeft, n.len + n.pos - h.plotLeft), s.len + s.pos - h.plotTop - q - it / 2, z] : [s.left - h.plotLeft + q + it / 2, d(Q + n.pos - h.plotTop, n.pos - h.plotTop, n.len + n.pos - h.plotTop), z], Y.shapeType = i.pointClass.prototype.shapeType || "rect", Y.shapeArgs = i.crispCol.apply(i, Y.isNull ? [q, _, it, 0] : [q, G, it, z]);
});
}, p.prototype.drawGraph = function() {
this.group[this.dense ? "addClass" : "removeClass"]("highcharts-dense-data");
}, p.prototype.pointAttribs = function(i, h) {
var o = this.options, t = this.pointAttrToOptions || {}, s = t.stroke || "borderColor", n = t["stroke-width"] || "borderWidth", A = i && i.color || this.color, _ = i && i[s] || o[s] || A;
t = i && i.options.dashStyle || o.dashStyle;
var D = i && i[n] || o[n] || this[n] || 0, W = x(i && i.opacity, o.opacity, 1);
if (i && this.zones.length) {
var P = i.getZone();
A = i.options.color || P && (P.color || i.nonZonedColor) || this.color, P && (_ = P.borderColor || _, t = P.dashStyle || t, D = P.borderWidth || D);
}
return h && i && (i = w(o.states[h], i.options.states && i.options.states[h] || {}), h = i.brightness, A = i.color || typeof h < "u" && S(A).brighten(i.brightness).get() || A, _ = i[s] || _, D = i[n] || D, t = i.dashStyle || t, W = x(i.opacity, W)), s = { fill: A, stroke: _, "stroke-width": D, opacity: W }, t && (s.dashstyle = t), s;
}, p.prototype.drawPoints = function() {
var i = this, h = this.chart, o = i.options, t = h.renderer, s = o.animationLimit || 250, n;
i.points.forEach(function(A) {
var _ = A.graphic, D = !!_, W = _ && h.pointCount < s ? "animate" : "attr";
b(A.plotY) && A.y !== null ? (n = A.shapeArgs, _ && A.hasNewShapeType() && (_ = _.destroy()), i.enabledDataSorting && (A.startXPos = i.xAxis.reversed ? -(n && n.width || 0) : i.xAxis.width), _ || (A.graphic = _ = t[A.shapeType](n).add(A.group || i.group)) && i.enabledDataSorting && h.hasRendered && h.pointCount < s && (_.attr({ x: A.startXPos }), D = !0, W = "animate"), _ && D && _[W](w(n)), o.borderRadius && _[W]({ r: o.borderRadius }), h.styledMode || _[W](i.pointAttribs(A, A.selected && "select")).shadow(A.allowShadow !== !1 && o.shadow, null, o.stacking && !o.borderRadius), _ && (_.addClass(A.getClassName(), !0), _.attr({ visibility: A.visible ? "inherit" : "hidden" }))) : _ && (A.graphic = _.destroy());
});
}, p.prototype.drawTracker = function() {
var i = this, h = i.chart, o = h.pointer, t = function(n) {
var A = o.getPointFromEvent(n);
typeof A < "u" && (o.isDirectTouch = !0, A.onMouseOver(n));
}, s;
i.points.forEach(function(n) {
s = C(n.dataLabels) ? n.dataLabels : n.dataLabel ? [n.dataLabel] : [], n.graphic && (n.graphic.element.point = n), s.forEach(function(A) {
A.div ? A.div.point = n : A.element.point = n;
});
}), i._hasTracking || (i.trackerGroups.forEach(function(n) {
i[n] && (i[n].addClass("highcharts-tracker").on("mouseover", t).on("mouseout", function(A) {
o.onTrackerMouseOut(A);
}), v && i[n].on(
"touchstart",
t
), !h.styledMode && i.options.cursor && i[n].css(u).css({ cursor: i.options.cursor }));
}), i._hasTracking = !0), B(this, "afterDrawTracker");
}, p.prototype.remove = function() {
var i = this, h = i.chart;
h.hasRendered && h.series.forEach(function(o) {
o.type === i.type && (o.isDirty = !0);
}), H.prototype.remove.apply(i, arguments);
}, p.defaultOptions = w(H.defaultOptions, { borderRadius: 0, centerInCategory: !1, groupPadding: 0.2, marker: null, pointPadding: 0.1, minPointLength: 0, cropThreshold: 50, pointRange: null, states: {
hover: { halo: !1, brightness: 0.1 },
select: { color: "#cccccc", borderColor: "#000000" }
}, dataLabels: { align: void 0, verticalAlign: void 0, y: void 0 }, startFromThreshold: !0, stickyTracking: !1, tooltip: { distance: 6 }, threshold: 0, borderColor: "#ffffff" }), p;
}(H), O(F.prototype, { cropShoulder: 0, directTouch: !0, drawLegendSymbol: Z.drawRectangle, getSymbol: y, negStacks: !0, trackerGroups: ["group", "dataLabelsGroup"] }), U.registerSeriesType("column", F), F;
}), E(l, "Core/Series/DataLabel.js", [
l["Core/Animation/AnimationUtilities.js"],
l["Core/FormatUtilities.js"],
l["Core/Utilities.js"]
], function(y, j, I) {
var Z = y.getDeferredAnimation, H = j.format, U = I.defined, F = I.extend, N = I.fireEvent, R = I.isArray, S = I.merge, v = I.objectEach, d = I.pick, u = I.splat, T;
return function(O) {
function B(p, i, h, o, t) {
var s = this, n = this.chart, A = this.isCartesian && n.inverted, _ = this.enabledDataSorting, D = d(p.dlBox && p.dlBox.centerX, p.plotX, -9999), W = d(p.plotY, -9999), P = i.getBBox(), X = h.rotation, g = h.align, m = n.isInsidePlot(D, Math.round(W), { inverted: A, paneCoordinates: !0, series: s }), L = function(k) {
_ && s.xAxis && !Y && s.setDataLabelStartPos(
p,
i,
t,
m,
k
);
}, Y = d(h.overflow, _ ? "none" : "justify") === "justify", V = this.visible && p.visible !== !1 && (p.series.forceDL || _ && !Y || m || d(h.inside, !!this.options.stacking) && o && n.isInsidePlot(D, A ? o.x + 1 : o.y + o.height - 1, { inverted: A, paneCoordinates: !0, series: s }));
if (V) {
var Q = n.renderer.fontMetrics(n.styledMode ? void 0 : h.style.fontSize, i).b;
o = F({ x: A ? this.yAxis.len - W : D, y: Math.round(A ? this.xAxis.len - D : W), width: 0, height: 0 }, o), F(h, { width: P.width, height: P.height }), X ? (Y = !1, D = n.renderer.rotCorr(Q, X), D = { x: o.x + (h.x || 0) + o.width / 2 + D.x, y: o.y + (h.y || 0) + { top: 0, middle: 0.5, bottom: 1 }[h.verticalAlign] * o.height }, L(D), i[t ? "attr" : "animate"](D).attr({ align: g }), L = (X + 720) % 360, L = 180 < L && 360 > L, g === "left" ? D.y -= L ? P.height : 0 : g === "center" ? (D.x -= P.width / 2, D.y -= P.height / 2) : g === "right" && (D.x -= P.width, D.y -= L ? 0 : P.height), i.placed = !0, i.alignAttr = D) : (L(o), i.align(h, void 0, o), D = i.alignAttr), Y && 0 <= o.height ? this.justifyDataLabel(i, h, D, P, o, t) : d(h.crop, !0) && (V = n.isInsidePlot(D.x, D.y, { paneCoordinates: !0, series: s }) && n.isInsidePlot(D.x + P.width, D.y + P.height, {
paneCoordinates: !0,
series: s
})), h.shape && !X && i[t ? "attr" : "animate"]({ anchorX: A ? n.plotWidth - p.plotY : p.plotX, anchorY: A ? n.plotHeight - p.plotX : p.plotY });
}
t && _ && (i.placed = !1), V || _ && !Y || (i.hide(!0), i.placed = !1);
}
function C(p, i) {
var h = i.filter;
return h ? (i = h.operator, p = p[h.property], h = h.value, i === ">" && p > h || i === "<" && p < h || i === ">=" && p >= h || i === "<=" && p <= h || i === "==" && p == h || i === "===" && p === h) : !0;
}
function b() {
var p = this, i = p.chart, h = p.options, o = p.points, t = p.hasRendered || 0, s = i.renderer, n = h.dataLabels, A, _ = n.animation;
if (_ = n.defer ? Z(
i,
_,
p
) : { defer: 0, duration: 0 }, n = x(x(i.options.plotOptions && i.options.plotOptions.series && i.options.plotOptions.series.dataLabels, i.options.plotOptions && i.options.plotOptions[p.type] && i.options.plotOptions[p.type].dataLabels), n), N(this, "drawDataLabels"), R(n) || n.enabled || p._hasPointLabels) {
var D = p.plotGroup("dataLabelsGroup", "data-labels", t ? "inherit" : "hidden", n.zIndex || 6);
D.attr({ opacity: +t }), !t && (t = p.dataLabelsGroup) && (p.visible && D.show(!0), t[h.animation ? "animate" : "attr"]({ opacity: 1 }, _)), o.forEach(function(W) {
A = u(x(n, W.dlOptions || W.options && W.options.dataLabels)), A.forEach(function(P, X) {
var g = P.enabled && (!W.isNull || W.dataLabelOnNull) && C(W, P), m = W.connectors ? W.connectors[X] : W.connector, L = W.dataLabels ? W.dataLabels[X] : W.dataLabel, Y = d(P.distance, W.labelDistance), V = !L;
if (g) {
var Q = W.getLabelConfig(), k = d(P[W.formatPrefix + "Format"], P.format);
Q = U(k) ? H(k, Q, i) : (P[W.formatPrefix + "Formatter"] || P.formatter).call(Q, P), k = P.style;
var G = P.rotation;
i.styledMode || (k.color = d(P.color, k.color, p.color, "#000000"), k.color === "contrast" ? (W.contrastColor = s.getContrast(W.color || p.color), k.color = !U(Y) && P.inside || 0 > Y || h.stacking ? W.contrastColor : "#000000") : delete W.contrastColor, h.cursor && (k.cursor = h.cursor));
var z = { r: P.borderRadius || 0, rotation: G, padding: P.padding, zIndex: 1 };
i.styledMode || (z.fill = P.backgroundColor, z.stroke = P.borderColor, z["stroke-width"] = P.borderWidth), v(z, function($, q) {
typeof $ > "u" && delete z[q];
});
}
!L || g && U(Q) && !!L.div == !!P.useHTML || (W.dataLabel = L = W.dataLabel && W.dataLabel.destroy(), W.dataLabels && (W.dataLabels.length === 1 ? delete W.dataLabels : delete W.dataLabels[X]), X || delete W.dataLabel, m && (W.connector = W.connector.destroy(), W.connectors && (W.connectors.length === 1 ? delete W.connectors : delete W.connectors[X]))), g && U(Q) && (L ? z.text = Q : (W.dataLabels = W.dataLabels || [], L = W.dataLabels[X] = G ? s.text(Q, 0, -9999, P.useHTML).addClass("highcharts-data-label") : s.label(Q, 0, -9999, P.shape, null, null, P.useHTML, null, "data-label"), X || (W.dataLabel = L), L.addClass(" highcharts-data-label-color-" + W.colorIndex + " " + (P.className || "") + (P.useHTML ? " highcharts-tracker" : ""))), L.options = P, L.attr(z), i.styledMode || L.css(k).shadow(P.shadow), L.added || L.add(D), P.textPath && !P.useHTML && (L.setTextPath(W.getDataLabelPath && W.getDataLabelPath(L) || W.graphic, P.textPath), W.dataLabelPath && !P.textPath.enabled && (W.dataLabelPath = W.dataLabelPath.destroy())), p.alignDataLabel(W, L, P, null, V));
});
});
}
N(this, "afterDrawDataLabels");
}
function w(p, i, h, o, t, s) {
var n = this.chart, A = i.align, _ = i.verticalAlign, D = p.box ? 0 : p.padding || 0, W = i.x;
W = W === void 0 ? 0 : W;
var P = i.y;
P = P === void 0 ? 0 : P;
var X = (h.x || 0) + D;
if (0 > X) {
A === "right" && 0 <= W ? (i.align = "left", i.inside = !0) : W -= X;
var g = !0;
}
return X = (h.x || 0) + o.width - D, X > n.plotWidth && (A === "left" && 0 >= W ? (i.align = "right", i.inside = !0) : W += n.plotWidth - X, g = !0), X = h.y + D, 0 > X && (_ === "bottom" && 0 <= P ? (i.verticalAlign = "top", i.inside = !0) : P -= X, g = !0), X = (h.y || 0) + o.height - D, X > n.plotHeight && (_ === "top" && 0 >= P ? (i.verticalAlign = "bottom", i.inside = !0) : P += n.plotHeight - X, g = !0), g && (i.x = W, i.y = P, p.placed = !s, p.align(i, void 0, t)), g;
}
function x(p, i) {
var h = [], o;
if (R(p) && !R(i))
h = p.map(function(t) {
return S(t, i);
});
else if (R(i) && !R(p))
h = i.map(function(t) {
return S(p, t);
});
else if (R(p) || R(i))
for (o = Math.max(p.length, i.length); o--; )
h[o] = S(p[o], i[o]);
else
h = S(p, i);
return h;
}
function a(p, i, h, o, t) {
var s = this.chart, n = s.inverted, A = this.xAxis, _ = A.reversed, D = n ? i.height / 2 : i.width / 2;
p = (p = p.pointWidth) ? p / 2 : 0, i.startXPos = n ? t.x : _ ? -D - p : A.width - D + p, i.startYPos = n ? _ ? this.yAxis.height - D + p : -D - p : t.y, o ? i.visibility === "hidden" && (i.show(), i.attr({ opacity: 0 }).animate({ opacity: 1 })) : i.attr({ opacity: 1 }).animate(
{ opacity: 0 },
void 0,
i.hide
), s.hasRendered && (h && i.attr({ x: i.startXPos, y: i.startYPos }), i.placed = !0);
}
var c = [];
O.compose = function(p) {
if (c.indexOf(p) === -1) {
var i = p.prototype;
c.push(p), i.alignDataLabel = B, i.drawDataLabels = b, i.justifyDataLabel = w, i.setDataLabelStartPos = a;
}
};
}(T || (T = {})), T;
}), E(l, "Series/Column/ColumnDataLabel.js", [l["Core/Series/DataLabel.js"], l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = j.series, H = I.merge, U = I.pick, F;
return function(N) {
function R(v, d, u, T, O) {
var B = this.chart.inverted, C = v.series, b = (C.xAxis ? C.xAxis.len : this.chart.plotSizeX) || 0;
C = (C.yAxis ? C.yAxis.len : this.chart.plotSizeY) || 0;
var w = v.dlBox || v.shapeArgs, x = U(v.below, v.plotY > U(this.translatedThreshold, C)), a = U(u.inside, !!this.options.stacking);
w && (T = H(w), 0 > T.y && (T.height += T.y, T.y = 0), w = T.y + T.height - C, 0 < w && w < T.height && (T.height -= w), B && (T = { x: C - T.y - T.height, y: b - T.x - T.width, width: T.height, height: T.width }), a || (B ? (T.x += x ? 0 : T.width, T.width = 0) : (T.y += x ? T.height : 0, T.height = 0))), u.align = U(u.align, !B || a ? "center" : x ? "right" : "left"), u.verticalAlign = U(u.verticalAlign, B || a ? "middle" : x ? "top" : "bottom"), Z.prototype.alignDataLabel.call(this, v, d, u, T, O), u.inside && v.contrastColor && d.css({ color: v.contrastColor });
}
var S = [];
N.compose = function(v) {
y.compose(Z), S.indexOf(v) === -1 && (S.push(v), v.prototype.alignDataLabel = R);
};
}(F || (F = {})), F;
}), E(l, "Series/Bar/BarSeries.js", [l["Series/Column/ColumnSeries.js"], l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = this && this.__extends || function() {
var F = function(N, R) {
return F = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(S, v) {
S.__proto__ = v;
} || function(S, v) {
for (var d in v)
v.hasOwnProperty(d) && (S[d] = v[d]);
}, F(N, R);
};
return function(N, R) {
function S() {
this.constructor = N;
}
F(N, R), N.prototype = R === null ? Object.create(R) : (S.prototype = R.prototype, new S());
};
}(), H = I.extend, U = I.merge;
return I = function(F) {
function N() {
var R = F !== null && F.apply(this, arguments) || this;
return R.data = void 0, R.options = void 0, R.points = void 0, R;
}
return Z(N, F), N.defaultOptions = U(
y.defaultOptions,
{}
), N;
}(y), H(I.prototype, { inverted: !0 }), j.registerSeriesType("bar", I), I;
}), E(l, "Series/Scatter/ScatterSeries.js", [l["Series/Column/ColumnSeries.js"], l["Series/Line/LineSeries.js"], l["Core/Series/SeriesRegistry.js"], l["Core/Utilities.js"]], function(y, j, I, Z) {
var H = this && this.__extends || function() {
var R = function(S, v) {
return R = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(d, u) {
d.__proto__ = u;
} || function(d, u) {
for (var T in u)
u.hasOwnProperty(T) && (d[T] = u[T]);
}, R(S, v);
};
return function(S, v) {
function d() {
this.constructor = S;
}
R(S, v), S.prototype = v === null ? Object.create(v) : (d.prototype = v.prototype, new d());
};
}(), U = Z.addEvent, F = Z.extend, N = Z.merge;
return Z = function(R) {
function S() {
var v = R !== null && R.apply(this, arguments) || this;
return v.data = void 0, v.options = void 0, v.points = void 0, v;
}
return H(S, R), S.prototype.applyJitter = function() {
var v = this, d = this.options.jitter, u = this.points.length;
d && this.points.forEach(function(T, O) {
["x", "y"].forEach(function(B, C) {
var b = "plot" + B.toUpperCase();
if (d[B] && !T.isNull) {
var w = v[B + "Axis"], x = d[B] * w.transA;
if (w && !w.isLog) {
var a = Math.max(0, T[b] - x);
w = Math.min(w.len, T[b] + x), C = 1e4 * Math.sin(O + C * u), T[b] = a + (w - a) * (C - Math.floor(C)), B === "x" && (T.clientX = T.plotX);
}
}
});
});
}, S.prototype.drawGraph = function() {
this.options.lineWidth ? R.prototype.drawGraph.call(this) : this.graph && (this.graph = this.graph.destroy());
}, S.defaultOptions = N(j.defaultOptions, { lineWidth: 0, findNearestPointBy: "xy", jitter: { x: 0, y: 0 }, marker: { enabled: !0 }, tooltip: {
headerFormat: '● {series.name}
',
pointFormat: "x: {point.x}
y: {point.y}
"
} }), S;
}(j), F(Z.prototype, { drawTracker: y.prototype.drawTracker, sorted: !1, requireSorting: !1, noSharedTooltip: !0, trackerGroups: ["group", "markerGroup", "dataLabelsGroup"], takeOrdinalPosition: !1 }), U(Z, "afterTranslate", function() {
this.applyJitter();
}), I.registerSeriesType("scatter", Z), Z;
}), E(l, "Series/CenteredUtilities.js", [l["Core/Globals.js"], l["Core/Series/Series.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = y.deg2rad, H = I.isNumber, U = I.pick, F = I.relativeLength, N;
return function(R) {
R.getCenter = function() {
var S = this.options, v = this.chart, d = 2 * (S.slicedOffset || 0), u = v.plotWidth - 2 * d, T = v.plotHeight - 2 * d, O = S.center, B = Math.min(u, T), C = S.size, b = S.innerSize || 0;
for (typeof C == "string" && (C = parseFloat(C)), typeof b == "string" && (b = parseFloat(b)), S = [U(O[0], "50%"), U(O[1], "50%"), U(C && 0 > C ? void 0 : S.size, "100%"), U(b && 0 > b ? void 0 : S.innerSize || 0, "0%")], !v.angular || this instanceof j || (S[3] = 0), O = 0; 4 > O; ++O)
C = S[O], v = 2 > O || O === 2 && /%$/.test(C), S[O] = F(C, [u, T, B, S[2]][O]) + (v ? d : 0);
return S[3] > S[2] && (S[3] = S[2]), S;
}, R.getStartAndEndRadians = function(S, v) {
return S = H(S) ? S : 0, v = H(v) && v > S && 360 > v - S ? v : S + 360, { start: Z * (S + -90), end: Z * (v + -90) };
};
}(N || (N = {})), N;
}), E(l, "Series/Pie/PiePoint.js", [l["Core/Animation/AnimationUtilities.js"], l["Core/Series/Point.js"], l["Core/Utilities.js"]], function(y, j, I) {
var Z = this && this.__extends || function() {
var v = function(d, u) {
return v = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(T, O) {
T.__proto__ = O;
} || function(T, O) {
for (var B in O)
O.hasOwnProperty(B) && (T[B] = O[B]);
}, v(d, u);
};
return function(d, u) {
function T() {
this.constructor = d;
}
v(d, u), d.prototype = u === null ? Object.create(u) : (T.prototype = u.prototype, new T());
};
}(), H = y.setAnimation, U = I.addEvent, F = I.defined;
y = I.extend;
var N = I.isNumber, R = I.pick, S = I.relativeLength;
return j = function(v) {
function d() {
var u = v !== null && v.apply(this, arguments) || this;
return u.labelDistance = void 0, u.options = void 0, u.series = void 0, u;
}
return Z(d, v), d.prototype.getConnectorPath = function() {
var u = this.labelPosition, T = this.series.options.dataLabels, O = this.connectorShapes, B = T.connectorShape;
return O[B] && (B = O[B]), B.call(this, { x: u.final.x, y: u.final.y, alignment: u.alignment }, u.connectorPosition, T);
}, d.prototype.getTranslate = function() {
return this.sliced ? this.slicedTranslation : { translateX: 0, translateY: 0 };
}, d.prototype.haloPath = function(u) {
var T = this.shapeArgs;
return this.sliced || !this.visible ? [] : this.series.chart.renderer.symbols.arc(T.x, T.y, T.r + u, T.r + u, { innerR: T.r - 1, start: T.start, end: T.end });
}, d.prototype.init = function() {
var u = this;
v.prototype.init.apply(
this,
arguments
), this.name = R(this.name, "Slice");
var T = function(O) {
u.slice(O.type === "select");
};
return U(this, "select", T), U(this, "unselect", T), this;
}, d.prototype.isValid = function() {
return N(this.y) && 0 <= this.y;
}, d.prototype.setVisible = function(u, T) {
var O = this, B = this.series, C = B.chart, b = B.options.ignoreHiddenPoint;
T = R(T, b), u !== this.visible && (this.visible = this.options.visible = u = typeof u > "u" ? !this.visible : u, B.options.data[B.data.indexOf(this)] = this.options, ["graphic", "dataLabel", "connector", "shadowGroup"].forEach(function(w) {
O[w] && O[w][u ? "show" : "hide"](u);
}), this.legendItem && C.legend.colorizeItem(this, u), u || this.state !== "hover" || this.setState(""), b && (B.isDirty = !0), T && C.redraw());
}, d.prototype.slice = function(u, T, O) {
var B = this.series;
H(O, B.chart), R(T, !0), this.sliced = this.options.sliced = F(u) ? u : !this.sliced, B.options.data[B.data.indexOf(this)] = this.options, this.graphic && this.graphic.animate(this.getTranslate()), this.shadowGroup && this.shadowGroup.animate(this.getTranslate());
}, d;
}(j), y(j.prototype, { connectorShapes: { fixedOffset: function(v, d, u) {
var T = d.breakAt;
return d = d.touchingSliceAt, [["M", v.x, v.y], u.softConnector ? ["C", v.x + (v.alignment === "left" ? -5 : 5), v.y, 2 * T.x - d.x, 2 * T.y - d.y, T.x, T.y] : ["L", T.x, T.y], ["L", d.x, d.y]];
}, straight: function(v, d) {
return d = d.touchingSliceAt, [["M", v.x, v.y], ["L", d.x, d.y]];
}, crookedLine: function(v, d, u) {
d = d.touchingSliceAt;
var T = this.series, O = T.center[0], B = T.chart.plotWidth, C = T.chart.plotLeft;
T = v.alignment;
var b = this.shapeArgs.r;
return u = S(u.crookDistance, 1), B = T === "left" ? O + b + (B + C - O - b) * (1 - u) : C + (O - b) * u, u = ["L", B, v.y], O = !0, (T === "left" ? B > v.x || B < d.x : B < v.x || B > d.x) && (O = !1), v = [["M", v.x, v.y]], O && v.push(u), v.push(["L", d.x, d.y]), v;
} } }), j;
}), E(l, "Series/Pie/PieSeries.js", [l["Series/CenteredUtilities.js"], l["Series/Column/ColumnSeries.js"], l["Core/Globals.js"], l["Core/Legend/LegendSymbol.js"], l["Series/Pie/PiePoint.js"], l["Core/Series/Series.js"], l["Core/Series/SeriesRegistry.js"], l["Core/Renderer/SVG/Symbols.js"], l["Core/Utilities.js"]], function(y, j, I, Z, H, U, F, N, R) {
var S = this && this.__extends || function() {
var b = function(w, x) {
return b = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(a, c) {
a.__proto__ = c;
} || function(a, c) {
for (var p in c)
c.hasOwnProperty(p) && (a[p] = c[p]);
}, b(w, x);
};
return function(w, x) {
function a() {
this.constructor = w;
}
b(w, x), w.prototype = x === null ? Object.create(x) : (a.prototype = x.prototype, new a());
};
}(), v = y.getStartAndEndRadians;
I = I.noop;
var d = R.clamp, u = R.extend, T = R.fireEvent, O = R.merge, B = R.pick, C = R.relativeLength;
return R = function(b) {
function w() {
var x = b !== null && b.apply(this, arguments) || this;
return x.center = void 0, x.data = void 0, x.maxLabelDistance = void 0, x.options = void 0, x.points = void 0, x;
}
return S(w, b), w.prototype.animate = function(x) {
var a = this, c = a.points, p = a.startAngleRad;
x || c.forEach(function(i) {
var h = i.graphic, o = i.shapeArgs;
h && o && (h.attr({ r: B(i.startR, a.center && a.center[3] / 2), start: p, end: p }), h.animate({ r: o.r, start: o.start, end: o.end }, a.options.animation));
});
}, w.prototype.drawEmpty = function() {
var x = this.startAngleRad, a = this.endAngleRad, c = this.options;
if (this.total === 0 && this.center) {
var p = this.center[0], i = this.center[1];
this.graph || (this.graph = this.chart.renderer.arc(p, i, this.center[1] / 2, 0, x, a).addClass("highcharts-empty-series").add(this.group)), this.graph.attr({ d: N.arc(p, i, this.center[2] / 2, 0, { start: x, end: a, innerR: this.center[3] / 2 }) }), this.chart.styledMode || this.graph.attr({ "stroke-width": c.borderWidth, fill: c.fillColor || "none", stroke: c.color || "#cccccc" });
} else
this.graph && (this.graph = this.graph.destroy());
}, w.prototype.drawPoints = function() {
var x = this.chart.renderer;
this.points.forEach(function(a) {
a.graphic && a.hasNewShapeType() && (a.graphic = a.graphic.destroy()), a.graphic || (a.graphic = x[a.shapeType](a.shapeArgs).add(a.series.group), a.delayedRendering = !0);
});
}, w.prototype.generatePoints = function() {
b.prototype.generatePoints.call(this), this.updateTotals();
}, w.prototype.getX = function(x, a, c) {
var p = this.center, i = this.radii ? this.radii[c.index] || 0 : p[2] / 2;
return x = Math.asin(d((x - p[1]) / (i + c.labelDistance), -1, 1)), p[0] + (a ? -1 : 1) * Math.cos(x) * (i + c.labelDistance) + (0 < c.labelDistance ? (a ? -1 : 1) * this.options.dataLabels.padding : 0);
}, w.prototype.hasData = function() {
return !!this.processedXData.length;
}, w.prototype.redrawPoints = function() {
var x = this, a = x.chart, c = a.renderer, p = x.options.shadow, i, h, o, t;
this.drawEmpty(), !p || x.shadowGroup || a.styledMode || (x.shadowGroup = c.g("shadow").attr({ zIndex: -1 }).add(x.group)), x.points.forEach(function(s) {
var n = {};
if (h = s.graphic, !s.isNull && h) {
var A = void 0;
t = s.shapeArgs, i = s.getTranslate(), a.styledMode || (A = s.shadowGroup, p && !A && (A = s.shadowGroup = c.g("shadow").add(x.shadowGroup)), A && A.attr(i), o = x.pointAttribs(s, s.selected && "select")), s.delayedRendering ? (h.setRadialReference(x.center).attr(t).attr(i), a.styledMode || h.attr(o).attr({ "stroke-linejoin": "round" }).shadow(p, A), s.delayedRendering = !1) : (h.setRadialReference(x.center), a.styledMode || O(!0, n, o), O(!0, n, t, i), h.animate(n)), h.attr({ visibility: s.visible ? "inherit" : "hidden" }), h.addClass(s.getClassName(), !0);
} else
h && (s.graphic = h.destroy());
});
}, w.prototype.sortByAngle = function(x, a) {
x.sort(function(c, p) {
return typeof c.angle < "u" && (p.angle - c.angle) * a;
});
}, w.prototype.translate = function(x) {
this.generatePoints();
var a = this.options, c = a.slicedOffset, p = c + (a.borderWidth || 0), i = v(a.startAngle, a.endAngle), h = this.startAngleRad = i.start;
i = (this.endAngleRad = i.end) - h;
var o = this.points, t = a.dataLabels.distance;
a = a.ignoreHiddenPoint;
var s = o.length, n, A = 0;
for (x || (this.center = x = this.getCenter()), n = 0; n < s; n++) {
var _ = o[n], D = h + A * i;
!_.isValid() || a && !_.visible || (A += _.percentage / 100);
var W = h + A * i, P = { x: x[0], y: x[1], r: x[2] / 2, innerR: x[3] / 2, start: Math.round(1e3 * D) / 1e3, end: Math.round(1e3 * W) / 1e3 };
_.shapeType = "arc", _.shapeArgs = P, _.labelDistance = B(_.options.dataLabels && _.options.dataLabels.distance, t), _.labelDistance = C(_.labelDistance, P.r), this.maxLabelDistance = Math.max(this.maxLabelDistance || 0, _.labelDistance), W = (W + D) / 2, W > 1.5 * Math.PI ? W -= 2 * Math.PI : W < -Math.PI / 2 && (W += 2 * Math.PI), _.slicedTranslation = { translateX: Math.round(Math.cos(W) * c), translateY: Math.round(Math.sin(W) * c) }, P = Math.cos(W) * x[2] / 2;
var X = Math.sin(W) * x[2] / 2;
_.tooltipPos = [x[0] + 0.7 * P, x[1] + 0.7 * X], _.half = W < -Math.PI / 2 || W > Math.PI / 2 ? 1 : 0, _.angle = W, D = Math.min(p, _.labelDistance / 5), _.labelPosition = { natural: { x: x[0] + P + Math.cos(W) * _.labelDistance, y: x[1] + X + Math.sin(W) * _.labelDistance }, final: {}, alignment: 0 > _.labelDistance ? "center" : _.half ? "right" : "left", connectorPosition: { breakAt: { x: x[0] + P + Math.cos(W) * D, y: x[1] + X + Math.sin(W) * D }, touchingSliceAt: { x: x[0] + P, y: x[1] + X } } };
}
T(this, "afterTranslate");
}, w.prototype.updateTotals = function() {
var x = this.points, a = x.length, c = this.options.ignoreHiddenPoint, p, i = 0;
for (p = 0; p < a; p++) {
var h = x[p];
!h.isValid() || c && !h.visible || (i += h.y);
}
for (this.total = i, p = 0; p < a; p++)
h = x[p], h.percentage = 0 < i && (h.visible || !c) ? h.y / i * 100 : 0, h.total = i;
}, w.defaultOptions = O(U.defaultOptions, {
center: [null, null],
clip: !1,
colorByPoint: !0,
dataLabels: { allowOverlap: !0, connectorPadding: 5, connectorShape: "fixedOffset", crookDistance: "70%", distance: 30, enabled: !0, formatter: function() {
return this.point.isNull ? void 0 : this.point.name;
}, softConnector: !0, x: 0 },
fillColor: void 0,
ignoreHiddenPoint: !0,
inactiveOtherPoints: !0,
legendType: "point",
marker: null,
size: null,
showInLegend: !1,
slicedOffset: 10,
stickyTracking: !1,
tooltip: { followPointer: !0 },
borderColor: "#ffffff",
borderWidth: 1,
lineWidth: void 0,
states: { hover: { brightness: 0.1 } }
}), w;
}(U), u(R.prototype, { axisTypes: [], directTouch: !0, drawGraph: void 0, drawLegendSymbol: Z.drawRectangle, drawTracker: j.prototype.drawTracker, getCenter: y.getCenter, getSymbol: I, isCartesian: !1, noSharedTooltip: !0, pointAttribs: j.prototype.pointAttribs, pointClass: H, requireSorting: !1, searchPoint: I, trackerGroups: ["group", "dataLabelsGroup"] }), F.registerSeriesType("pie", R), R;
}), E(l, "Series/Pie/PieDataLabel.js", [
l["Core/Series/DataLabel.js"],
l["Core/Globals.js"],
l["Core/Renderer/RendererUtilities.js"],
l["Core/Series/SeriesRegistry.js"],
l["Core/Utilities.js"]
], function(y, j, I, Z, H) {
var U = j.noop, F = I.distribute, N = Z.series, R = H.arrayMax, S = H.clamp, v = H.defined, d = H.merge, u = H.pick, T = H.relativeLength, O;
return function(B) {
function C() {
var c = this, p = c.data, i = c.chart, h = c.options.dataLabels || {}, o = h.connectorPadding, t = i.plotWidth, s = i.plotHeight, n = i.plotLeft, A = Math.round(i.chartWidth / 3), _ = c.center, D = _[2] / 2, W = _[1], P = [[], []], X = [0, 0, 0, 0], g = c.dataLabelPositioners, m, L, Y, V, Q, k, G, z, $, q, it, et;
c.visible && (h.enabled || c._hasPointLabels) && (p.forEach(function(nt) {
nt.dataLabel && nt.visible && nt.dataLabel.shortened && (nt.dataLabel.attr({ width: "auto" }).css({ width: "auto", textOverflow: "clip" }), nt.dataLabel.shortened = !1);
}), N.prototype.drawDataLabels.apply(c), p.forEach(function(nt) {
nt.dataLabel && (nt.visible ? (P[nt.half].push(nt), nt.dataLabel._pos = null, !v(h.style.width) && !v(nt.options.dataLabels && nt.options.dataLabels.style && nt.options.dataLabels.style.width) && nt.dataLabel.getBBox().width > A && (nt.dataLabel.css({ width: Math.round(0.7 * A) + "px" }), nt.dataLabel.shortened = !0)) : (nt.dataLabel = nt.dataLabel.destroy(), nt.dataLabels && nt.dataLabels.length === 1 && delete nt.dataLabels));
}), P.forEach(function(nt, rt) {
var ct = nt.length, gt = [], dt;
if (ct) {
if (c.sortByAngle(nt, rt - 0.5), 0 < c.maxLabelDistance) {
var ht = Math.max(0, W - D - c.maxLabelDistance), at = Math.min(W + D + c.maxLabelDistance, i.plotHeight);
nt.forEach(function(J) {
0 < J.labelDistance && J.dataLabel && (J.top = Math.max(0, W - D - J.labelDistance), J.bottom = Math.min(W + D + J.labelDistance, i.plotHeight), dt = J.dataLabel.getBBox().height || 21, J.distributeBox = { target: J.labelPosition.natural.y - J.top + dt / 2, size: dt, rank: J.y }, gt.push(J.distributeBox));
}), ht = at + dt - ht, F(gt, ht, ht / 5);
}
for (it = 0; it < ct; it++) {
if (m = nt[it], k = m.labelPosition, V = m.dataLabel, q = m.visible === !1 ? "hidden" : "inherit", $ = ht = k.natural.y, gt && v(m.distributeBox) && (typeof m.distributeBox.pos > "u" ? q = "hidden" : (G = m.distributeBox.size, $ = g.radialDistributionY(m))), delete m.positionIndex, h.justify)
z = g.justify(m, D, _);
else
switch (h.alignTo) {
case "connectors":
z = g.alignToConnectors(nt, rt, t, n);
break;
case "plotEdges":
z = g.alignToPlotEdges(V, rt, t, n);
break;
default:
z = g.radialDistributionX(c, m, $, ht);
}
V._attr = { visibility: q, align: k.alignment }, et = m.options.dataLabels || {}, V._pos = { x: z + u(et.x, h.x) + ({ left: o, right: -o }[k.alignment] || 0), y: $ + u(et.y, h.y) - 10 }, k.final.x = z, k.final.y = $, u(h.crop, !0) && (Q = V.getBBox().width, ht = null, z - Q < o && rt === 1 ? (ht = Math.round(Q - z + o), X[3] = Math.max(ht, X[3])) : z + Q > t - o && rt === 0 && (ht = Math.round(z + Q - t + o), X[1] = Math.max(ht, X[1])), 0 > $ - G / 2 ? X[0] = Math.max(Math.round(-$ + G / 2), X[0]) : $ + G / 2 > s && (X[2] = Math.max(Math.round($ + G / 2 - s), X[2])), V.sideOverflow = ht);
}
}
}), R(X) === 0 || this.verifyDataLabelOverflow(X)) && (this.placeDataLabels(), this.points.forEach(function(nt) {
if (et = d(h, nt.options.dataLabels), L = u(et.connectorWidth, 1)) {
var rt;
Y = nt.connector, (V = nt.dataLabel) && V._pos && nt.visible && 0 < nt.labelDistance ? (q = V._attr.visibility, (rt = !Y) && (nt.connector = Y = i.renderer.path().addClass("highcharts-data-label-connector highcharts-color-" + nt.colorIndex + (nt.className ? " " + nt.className : "")).add(c.dataLabelsGroup), i.styledMode || Y.attr({ "stroke-width": L, stroke: et.connectorColor || nt.color || "#666666" })), Y[rt ? "attr" : "animate"]({ d: nt.getConnectorPath() }), Y.attr("visibility", q)) : Y && (nt.connector = Y.destroy());
}
}));
}
function b() {
this.points.forEach(function(c) {
var p = c.dataLabel, i;
p && c.visible && ((i = p._pos) ? (p.sideOverflow && (p._attr.width = Math.max(p.getBBox().width - p.sideOverflow, 0), p.css({ width: p._attr.width + "px", textOverflow: (this.options.dataLabels.style || {}).textOverflow || "ellipsis" }), p.shortened = !0), p.attr(p._attr), p[p.moved ? "animate" : "attr"](i), p.moved = !0) : p && p.attr({ y: -9999 })), delete c.distributeBox;
}, this);
}
function w(c) {
var p = this.center, i = this.options, h = i.center, o = i.minSize || 80, t = i.size !== null;
if (!t) {
if (h[0] !== null)
var s = Math.max(p[2] - Math.max(c[1], c[3]), o);
else
s = Math.max(p[2] - c[1] - c[3], o), p[0] += (c[3] - c[1]) / 2;
h[1] !== null ? s = S(s, o, p[2] - Math.max(c[0], c[2])) : (s = S(s, o, p[2] - c[0] - c[2]), p[1] += (c[0] - c[2]) / 2), s < p[2] ? (p[2] = s, p[3] = Math.min(T(i.innerSize || 0, s), s), this.translate(p), this.drawDataLabels && this.drawDataLabels()) : t = !0;
}
return t;
}
var x = [], a = { radialDistributionY: function(c) {
return c.top + c.distributeBox.pos;
}, radialDistributionX: function(c, p, i, h) {
return c.getX(i < p.top + 2 || i > p.bottom - 2 ? h : i, p.half, p);
}, justify: function(c, p, i) {
return i[0] + (c.half ? -1 : 1) * (p + c.labelDistance);
}, alignToPlotEdges: function(c, p, i, h) {
return c = c.getBBox().width, p ? c + h : i - c - h;
}, alignToConnectors: function(c, p, i, h) {
var o = 0, t;
return c.forEach(function(s) {
t = s.dataLabel.getBBox().width, t > o && (o = t);
}), p ? o + h : i - o - h;
} };
B.compose = function(c) {
y.compose(N), x.indexOf(c) === -1 && (x.push(c), c = c.prototype, c.dataLabelPositioners = a, c.alignDataLabel = U, c.drawDataLabels = C, c.placeDataLabels = b, c.verifyDataLabelOverflow = w);
};
}(O || (O = {})), O;
}), E(l, "Extensions/OverlappingDataLabels.js", [l["Core/Chart/Chart.js"], l["Core/Utilities.js"]], function(y, j) {
function I(S, v) {
var d = !1;
if (S) {
var u = S.newOpacity;
S.oldOpacity !== u && (S.alignAttr && S.placed ? (S[u ? "removeClass" : "addClass"]("highcharts-data-label-hidden"), d = !0, S.alignAttr.opacity = u, S[S.isOld ? "animate" : "attr"](S.alignAttr, null, function() {
v.styledMode || S.css({ pointerEvents: u ? "auto" : "none" });
}), H(v, "afterHideOverlappingLabel")) : S.attr({ opacity: u })), S.isOld = !0;
}
return d;
}
var Z = j.addEvent, H = j.fireEvent, U = j.isArray, F = j.isNumber, N = j.objectEach, R = j.pick;
Z(y, "render", function() {
var S = this, v = [];
(this.labelCollectors || []).forEach(function(d) {
v = v.concat(d());
}), (this.yAxis || []).forEach(function(d) {
d.stacking && d.options.stackLabels && !d.options.stackLabels.allowOverlap && N(d.stacking.stacks, function(u) {
N(u, function(T) {
T.label && T.label.visibility !== "hidden" && v.push(T.label);
});
});
}), (this.series || []).forEach(function(d) {
var u = d.options.dataLabels;
d.visible && (u.enabled !== !1 || d._hasPointLabels) && (u = function(T) {
return T.forEach(function(O) {
O.visible && (U(O.dataLabels) ? O.dataLabels : O.dataLabel ? [O.dataLabel] : []).forEach(function(B) {
var C = B.options;
B.labelrank = R(C.labelrank, O.labelrank, O.shapeArgs && O.shapeArgs.height), C.allowOverlap ? (B.oldOpacity = B.opacity, B.newOpacity = 1, I(B, S)) : v.push(B);
});
});
}, u(d.nodes || []), u(d.points));
}), this.hideOverlappingLabels(v);
}), y.prototype.hideOverlappingLabels = function(S) {
var v = this, d = S.length, u = v.renderer, T, O, B, C = !1, b = function(a) {
var c, p = a.box ? 0 : a.padding || 0, i = c = 0, h;
if (a && (!a.alignAttr || a.placed)) {
var o = a.alignAttr || { x: a.attr("x"), y: a.attr("y") }, t = a.parentGroup;
a.width || (c = a.getBBox(), a.width = c.width, a.height = c.height, c = u.fontMetrics(null, a.element).h);
var s = a.width - 2 * p;
return (h = { left: "0", center: "0.5", right: "1" }[a.alignValue]) ? i = +h * s : F(a.x) && Math.round(a.x) !== a.translateX && (i = a.x - a.translateX), { x: o.x + (t.translateX || 0) + p - (i || 0), y: o.y + (t.translateY || 0) + p - c, width: a.width - 2 * p, height: a.height - 2 * p };
}
};
for (O = 0; O < d; O++)
(T = S[O]) && (T.oldOpacity = T.opacity, T.newOpacity = 1, T.absoluteBox = b(T));
for (S.sort(function(a, c) {
return (c.labelrank || 0) - (a.labelrank || 0);
}), O = 0; O < d; O++) {
var w = (b = S[O]) && b.absoluteBox;
for (T = O + 1; T < d; ++T) {
var x = (B = S[T]) && B.absoluteBox;
!w || !x || b === B || b.newOpacity === 0 || B.newOpacity === 0 || x.x >= w.x + w.width || x.x + x.width <= w.x || x.y >= w.y + w.height || x.y + x.height <= w.y || ((b.labelrank < B.labelrank ? b : B).newOpacity = 0);
}
}
S.forEach(function(a) {
I(a, v) && (C = !0);
}), C && H(v, "afterHideAllOverlappingLabels");
};
}), E(
l,
"Core/Responsive.js",
[l["Core/Utilities.js"]],
function(y) {
var j = y.extend, I = y.find, Z = y.isArray, H = y.isObject, U = y.merge, F = y.objectEach, N = y.pick, R = y.splat, S = y.uniqueKey, v;
return function(d) {
var u = [];
d.compose = function(O) {
return u.indexOf(O) === -1 && (u.push(O), j(O.prototype, T.prototype)), O;
};
var T = function() {
function O() {
}
return O.prototype.currentOptions = function(B) {
function C(x, a, c, p) {
var i;
F(x, function(h, o) {
if (!p && -1 < b.collectionsWithUpdate.indexOf(o) && a[o])
for (h = R(h), c[o] = [], i = 0; i < Math.max(h.length, a[o].length); i++)
a[o][i] && (h[i] === void 0 ? c[o][i] = a[o][i] : (c[o][i] = {}, C(h[i], a[o][i], c[o][i], p + 1)));
else
H(h) ? (c[o] = Z(h) ? [] : {}, C(h, a[o] || {}, c[o], p + 1)) : c[o] = typeof a[o] > "u" ? null : a[o];
});
}
var b = this, w = {};
return C(B, this.options, w, 0), w;
}, O.prototype.matchResponsiveRule = function(B, C) {
var b = B.condition;
(b.callback || function() {
return this.chartWidth <= N(b.maxWidth, Number.MAX_VALUE) && this.chartHeight <= N(b.maxHeight, Number.MAX_VALUE) && this.chartWidth >= N(b.minWidth, 0) && this.chartHeight >= N(b.minHeight, 0);
}).call(this) && C.push(B._id);
}, O.prototype.setResponsive = function(B, C) {
var b = this, w = this.options.responsive, x = this.currentResponsive, a = [];
!C && w && w.rules && w.rules.forEach(function(c) {
typeof c._id > "u" && (c._id = S()), b.matchResponsiveRule(c, a);
}, this), C = U.apply(void 0, a.map(function(c) {
return I((w || {}).rules || [], function(p) {
return p._id === c;
});
}).map(function(c) {
return c && c.chartOptions;
})), C.isResponsiveOptions = !0, a = a.toString() || void 0, a !== (x && x.ruleIds) && (x && this.update(x.undoOptions, B, !0), a ? (x = this.currentOptions(C), x.isResponsiveOptions = !0, this.currentResponsive = { ruleIds: a, mergedOptions: C, undoOptions: x }, this.update(C, B, !0)) : this.currentResponsive = void 0);
}, O;
}();
}(v || (v = {})), v;
}
), E(l, "masters/highcharts.src.js", [
l["Core/Globals.js"],
l["Core/Utilities.js"],
l["Core/DefaultOptions.js"],
l["Core/Animation/Fx.js"],
l["Core/Animation/AnimationUtilities.js"],
l["Core/Renderer/HTML/AST.js"],
l["Core/FormatUtilities.js"],
l["Core/Renderer/RendererUtilities.js"],
l["Core/Renderer/SVG/SVGElement.js"],
l["Core/Renderer/SVG/SVGRenderer.js"],
l["Core/Renderer/HTML/HTMLElement.js"],
l["Core/Renderer/HTML/HTMLRenderer.js"],
l["Core/Axis/Axis.js"],
l["Core/Axis/DateTimeAxis.js"],
l["Core/Axis/LogarithmicAxis.js"],
l["Core/Axis/PlotLineOrBand/PlotLineOrBand.js"],
l["Core/Axis/Tick.js"],
l["Core/Tooltip.js"],
l["Core/Series/Point.js"],
l["Core/Pointer.js"],
l["Core/MSPointer.js"],
l["Core/Legend/Legend.js"],
l["Core/Chart/Chart.js"],
l["Core/Series/Series.js"],
l["Core/Series/SeriesRegistry.js"],
l["Series/Column/ColumnSeries.js"],
l["Series/Column/ColumnDataLabel.js"],
l["Series/Pie/PieSeries.js"],
l["Series/Pie/PieDataLabel.js"],
l["Core/Series/DataLabel.js"],
l["Core/Responsive.js"],
l["Core/Color/Color.js"],
l["Core/Time.js"]
], function(y, j, I, Z, H, U, F, N, R, S, v, d, u, T, O, B, C, b, w, x, a, c, p, i, h, o, t, s, n, A, _, D, W) {
return y.animate = H.animate, y.animObject = H.animObject, y.getDeferredAnimation = H.getDeferredAnimation, y.setAnimation = H.setAnimation, y.stop = H.stop, y.timers = Z.timers, y.AST = U, y.Axis = u, y.Chart = p, y.chart = p.chart, y.Fx = Z, y.Legend = c, y.PlotLineOrBand = B, y.Point = w, y.Pointer = a.isRequired() ? a : x, y.Series = i, y.SVGElement = R, y.SVGRenderer = S, y.Tick = C, y.Time = W, y.Tooltip = b, y.Color = D, y.color = D.parse, d.compose(S), v.compose(R), y.defaultOptions = I.defaultOptions, y.getOptions = I.getOptions, y.time = I.defaultTime, y.setOptions = I.setOptions, y.dateFormat = F.dateFormat, y.format = F.format, y.numberFormat = F.numberFormat, y.addEvent = j.addEvent, y.arrayMax = j.arrayMax, y.arrayMin = j.arrayMin, y.attr = j.attr, y.clearTimeout = j.clearTimeout, y.correctFloat = j.correctFloat, y.createElement = j.createElement, y.css = j.css, y.defined = j.defined, y.destroyObjectProperties = j.destroyObjectProperties, y.discardElement = j.discardElement, y.distribute = N.distribute, y.erase = j.erase, y.error = j.error, y.extend = j.extend, y.extendClass = j.extendClass, y.find = j.find, y.fireEvent = j.fireEvent, y.getMagnitude = j.getMagnitude, y.getStyle = j.getStyle, y.inArray = j.inArray, y.isArray = j.isArray, y.isClass = j.isClass, y.isDOMElement = j.isDOMElement, y.isFunction = j.isFunction, y.isNumber = j.isNumber, y.isObject = j.isObject, y.isString = j.isString, y.keys = j.keys, y.merge = j.merge, y.normalizeTickInterval = j.normalizeTickInterval, y.objectEach = j.objectEach, y.offset = j.offset, y.pad = j.pad, y.pick = j.pick, y.pInt = j.pInt, y.relativeLength = j.relativeLength, y.removeEvent = j.removeEvent, y.seriesType = h.seriesType, y.splat = j.splat, y.stableSort = j.stableSort, y.syncTimeout = j.syncTimeout, y.timeUnits = j.timeUnits, y.uniqueKey = j.uniqueKey, y.useSerialIds = j.useSerialIds, y.wrap = j.wrap, t.compose(o), A.compose(i), T.compose(u), O.compose(u), n.compose(s), B.compose(u), _.compose(p), y;
}), l["masters/highcharts.src.js"]._modules = l, l["masters/highcharts.src.js"];
});
})(O0);
const Qn = dl;
var fl = {}, L0 = {
get exports() {
return fl;
},
set exports(r) {
fl = r;
}
};
(function(r) {
(function(f) {
r.exports ? (f.default = f, r.exports = f) : f(typeof Highcharts < "u" ? Highcharts : void 0);
})(function(f) {
function E(l, y, j, I) {
l.hasOwnProperty(y) || (l[y] = I.apply(null, j));
}
f = f ? f._modules : {}, E(f, "Extensions/Pane.js", [
f["Core/Chart/Chart.js"],
f["Series/CenteredUtilities.js"],
f["Core/Globals.js"],
f["Core/Pointer.js"],
f["Core/Utilities.js"]
], function(l, y, j, I, Z) {
function H(v, d, u) {
return Math.sqrt(Math.pow(v - u[0], 2) + Math.pow(d - u[1], 2)) <= u[2] / 2;
}
var U = Z.addEvent, F = Z.extend, N = Z.merge, R = Z.pick, S = Z.splat;
return l.prototype.collectionsWithUpdate.push("pane"), Z = function() {
function v(d, u) {
this.options = this.chart = this.center = this.background = void 0, this.coll = "pane", this.defaultOptions = { center: ["50%", "50%"], size: "85%", innerSize: "0%", startAngle: 0 }, this.defaultBackgroundOptions = { shape: "circle", borderWidth: 1, borderColor: "#cccccc", backgroundColor: { linearGradient: {
x1: 0,
y1: 0,
x2: 0,
y2: 1
}, stops: [[0, "#ffffff"], [1, "#e6e6e6"]] }, from: -Number.MAX_VALUE, innerRadius: 0, to: Number.MAX_VALUE, outerRadius: "105%" }, this.init(d, u);
}
return v.prototype.init = function(d, u) {
this.chart = u, this.background = [], u.pane.push(this), this.setOptions(d);
}, v.prototype.setOptions = function(d) {
this.options = N(this.defaultOptions, this.chart.angular ? { background: {} } : void 0, d);
}, v.prototype.render = function() {
var d = this.options, u = this.options.background, T = this.chart.renderer;
if (this.group || (this.group = T.g("pane-group").attr({ zIndex: d.zIndex || 0 }).add()), this.updateCenter(), u)
for (u = S(u), d = Math.max(u.length, this.background.length || 0), T = 0; T < d; T++)
u[T] && this.axis ? this.renderBackground(N(this.defaultBackgroundOptions, u[T]), T) : this.background[T] && (this.background[T] = this.background[T].destroy(), this.background.splice(T, 1));
}, v.prototype.renderBackground = function(d, u) {
var T = "animate", O = { class: "highcharts-pane " + (d.className || "") };
this.chart.styledMode || F(O, { fill: d.backgroundColor, stroke: d.borderColor, "stroke-width": d.borderWidth }), this.background[u] || (this.background[u] = this.chart.renderer.path().add(this.group), T = "attr"), this.background[u][T]({ d: this.axis.getPlotBandPath(d.from, d.to, d) }).attr(O);
}, v.prototype.updateCenter = function(d) {
this.center = (d || this.axis || {}).center = y.getCenter.call(this);
}, v.prototype.update = function(d, u) {
N(!0, this.options, d), this.setOptions(this.options), this.render(), this.chart.axes.forEach(function(T) {
T.pane === this && (T.pane = null, T.update({}, u));
}, this);
}, v;
}(), l.prototype.getHoverPane = function(v) {
var d = this, u;
return v && d.pane.forEach(function(T) {
var O = v.chartX - d.plotLeft, B = v.chartY - d.plotTop;
H(d.inverted ? B : O, d.inverted ? O : B, T.center) && (u = T);
}), u;
}, U(l, "afterIsInsidePlot", function(v) {
this.polar && (v.isInsidePlot = this.pane.some(function(d) {
return H(v.x, v.y, d.center);
}));
}), U(I, "beforeGetHoverData", function(v) {
var d = this.chart;
d.polar ? (d.hoverPane = d.getHoverPane(v), v.filter = function(u) {
return u.visible && !(!v.shared && u.directTouch) && R(u.options.enableMouseTracking, !0) && (!d.hoverPane || u.xAxis.pane === d.hoverPane);
}) : d.hoverPane = void 0;
}), U(
I,
"afterGetHoverData",
function(v) {
var d = this.chart;
v.hoverPoint && v.hoverPoint.plotX && v.hoverPoint.plotY && d.hoverPane && !H(v.hoverPoint.plotX, v.hoverPoint.plotY, d.hoverPane.center) && (v.hoverPoint = void 0);
}
), j.Pane = Z, j.Pane;
}), E(f, "Core/Axis/RadialAxis.js", [f["Core/Axis/AxisDefaults.js"], f["Core/DefaultOptions.js"], f["Core/Globals.js"], f["Core/Utilities.js"]], function(l, y, j, I) {
var Z = y.defaultOptions, H = j.noop, U = I.addEvent, F = I.correctFloat, N = I.defined, R = I.extend, S = I.fireEvent, v = I.merge, d = I.pick, u = I.relativeLength, T = I.wrap, O;
return function(B) {
function C() {
this.autoConnect = this.isCircular && typeof d(this.userMax, this.options.max) > "u" && F(this.endAngleRad - this.startAngleRad) === F(2 * Math.PI), !this.isCircular && this.chart.inverted && this.max++, this.autoConnect && (this.max += this.categories && 1 || this.pointRange || this.closestPointRange || 0);
}
function b() {
var $ = this;
return function() {
if ($.isRadial && $.tickPositions && $.options.labels && $.options.labels.allowOverlap !== !0)
return $.tickPositions.map(function(q) {
return $.ticks[q] && $.ticks[q].label;
}).filter(function(q) {
return !!q;
});
};
}
function w() {
return H;
}
function x($, q, it) {
var et = this.pane.center, nt = $.value;
if (this.isCircular) {
if (N(nt))
$.point && (rt = $.point.shapeArgs || {}, rt.start && (nt = this.chart.inverted ? this.translate($.point.rectPlotY, !0) : $.point.x));
else {
var rt = $.chartX || 0, ct = $.chartY || 0;
nt = this.translate(Math.atan2(ct - it, rt - q) - this.startAngleRad, !0);
}
$ = this.getPosition(nt), rt = $.x, ct = $.y;
} else
N(nt) || (rt = $.chartX, ct = $.chartY), N(rt) && N(ct) && (it = et[1] + this.chart.plotTop, nt = this.translate(Math.min(Math.sqrt(Math.pow(rt - q, 2) + Math.pow(ct - it, 2)), et[2] / 2) - et[3] / 2, !0));
return [nt, rt || 0, ct || 0];
}
function a($, q, it) {
$ = this.pane.center;
var et = this.chart, nt = this.left || 0, rt = this.top || 0, ct = d(q, $[2] / 2 - this.offset);
return typeof it > "u" && (it = this.horiz ? 0 : this.center && -this.center[3] / 2), it && (ct += it), this.isCircular || typeof q < "u" ? (q = this.chart.renderer.symbols.arc(nt + $[0], rt + $[1], ct, ct, { start: this.startAngleRad, end: this.endAngleRad, open: !0, innerR: 0 }), q.xBounds = [nt + $[0]], q.yBounds = [rt + $[1] - ct]) : (q = this.postTranslate(this.angleRad, ct), q = [["M", this.center[0] + et.plotLeft, this.center[1] + et.plotTop], ["L", q.x, q.y]]), q;
}
function c() {
this.constructor.prototype.getOffset.call(this), this.chart.axisOffset[this.side] = 0;
}
function p($, q, it) {
var et = this.chart, nt = function(yt) {
if (typeof yt == "string") {
var vt = parseInt(yt, 10);
return J.test(yt) && (vt = vt * gt / 100), vt;
}
return yt;
}, rt = this.center, ct = this.startAngleRad, gt = rt[2] / 2, dt = Math.min(this.offset, 0), ht = this.left || 0, at = this.top || 0, J = /%$/, tt = this.isCircular, ot = d(nt(it.outerRadius), gt), lt = nt(it.innerRadius);
if (nt = d(nt(it.thickness), 10), this.options.gridLineInterpolation === "polygon")
dt = this.getPlotLinePath({ value: $ }).concat(this.getPlotLinePath({ value: q, reverse: !0 }));
else {
if ($ = Math.max($, this.min), q = Math.min(q, this.max), $ = this.translate($), q = this.translate(q), tt || (ot = $ || 0, lt = q || 0), it.shape !== "circle" && tt)
it = ct + ($ || 0), ct += q || 0;
else {
it = -Math.PI / 2, ct = 1.5 * Math.PI;
var pt = !0;
}
ot -= dt, dt = et.renderer.symbols.arc(ht + rt[0], at + rt[1], ot, ot, { start: Math.min(it, ct), end: Math.max(it, ct), innerR: d(lt, ot - (nt - dt)), open: pt }), tt && (tt = (ct + it) / 2, ht = ht + rt[0] + rt[2] / 2 * Math.cos(tt), dt.xBounds = tt > -Math.PI / 2 && tt < Math.PI / 2 ? [ht, et.plotWidth] : [0, ht], dt.yBounds = [at + rt[1] + rt[2] / 2 * Math.sin(tt)], dt.yBounds[0] += tt > -Math.PI && 0 > tt || tt > Math.PI ? -10 : 10);
}
return dt;
}
function i($) {
var q = this, it = this.pane.center, et = this.chart, nt = et.inverted, rt = $.reverse, ct = this.pane.options.background ? this.pane.options.background[0] || this.pane.options.background : {}, gt = ct.innerRadius || "0%", dt = ct.outerRadius || "100%", ht = it[0] + et.plotLeft, at = it[1] + et.plotTop, J = this.height, tt = $.isCrosshair;
ct = it[3] / 2;
var ot = $.value, lt, pt = this.getPosition(ot), yt = pt.x;
if (pt = pt.y, tt && (pt = this.getCrosshairPosition($, ht, at), ot = pt[0], yt = pt[1], pt = pt[2]), this.isCircular)
ot = Math.sqrt(Math.pow(yt - ht, 2) + Math.pow(pt - at, 2)), rt = typeof gt == "string" ? u(gt, 1) : gt / ot, et = typeof dt == "string" ? u(dt, 1) : dt / ot, it && ct && (ct /= ot, rt < ct && (rt = ct), et < ct && (et = ct)), it = [["M", ht + rt * (yt - ht), at - rt * (at - pt)], ["L", yt - (1 - et) * (yt - ht), pt + (1 - et) * (at - pt)]];
else if ((ot = this.translate(ot)) && (0 > ot || ot > J) && (ot = 0), this.options.gridLineInterpolation === "circle")
it = this.getLinePath(0, ot, ct);
else if (it = [], et[nt ? "yAxis" : "xAxis"].forEach(function(vt) {
vt.pane === q.pane && (lt = vt);
}), lt)
for (ht = lt.tickPositions, lt.autoConnect && (ht = ht.concat([ht[0]])), rt && (ht = ht.slice().reverse()), ot && (ot += ct), at = 0; at < ht.length; at++)
ct = lt.getPosition(ht[at], ot), it.push(at ? ["L", ct.x, ct.y] : ["M", ct.x, ct.y]);
return it;
}
function h($, q) {
return $ = this.translate($), this.postTranslate(this.isCircular ? $ : this.angleRad, d(this.isCircular ? q : 0 > $ ? 0 : $, this.center[2] / 2) - this.offset);
}
function o() {
var $ = this.center, q = this.chart, it = this.options.title;
return { x: q.plotLeft + $[0] + (it.x || 0), y: q.plotTop + $[1] - { high: 0.5, middle: 0.25, low: 0 }[it.align] * $[2] + (it.y || 0) };
}
function t($) {
$.beforeSetTickPositions = C, $.createLabelCollector = b, $.getCrosshairPosition = x, $.getLinePath = a, $.getOffset = c, $.getPlotBandPath = p, $.getPlotLinePath = i, $.getPosition = h, $.getTitlePosition = o, $.postTranslate = X, $.setAxisSize = m, $.setAxisTranslation = L, $.setOptions = Y;
}
function s() {
var $ = this.chart, q = this.options, it = this.pane, et = it && it.options;
$.angular && this.isXAxis || !it || !$.angular && !$.polar || (this.angleRad = (q.angle || 0) * Math.PI / 180, this.startAngleRad = (et.startAngle - 90) * Math.PI / 180, this.endAngleRad = (d(et.endAngle, et.startAngle + 360) - 90) * Math.PI / 180, this.offset = q.offset || 0);
}
function n($) {
this.isRadial && ($.align = void 0, $.preventDefault());
}
function A() {
if (this.chart && this.chart.labelCollectors) {
var $ = this.labelCollector ? this.chart.labelCollectors.indexOf(this.labelCollector) : -1;
0 <= $ && this.chart.labelCollectors.splice($, 1);
}
}
function _($) {
var q = this.chart, it = q.inverted, et = q.angular, nt = q.polar, rt = this.isXAxis, ct = this.coll, gt = et && rt, dt = q.options;
$ = $.userOptions.pane || 0, $ = this.pane = q.pane && q.pane[$];
var ht;
ct === "colorAxis" ? this.isRadial = !1 : (et ? (gt ? (this.isHidden = !0, this.createLabelCollector = w, this.getOffset = H, this.render = this.redraw = g, this.setTitle = this.setCategories = this.setScale = H) : t(this), (ht = !rt) && (this.defaultPolarOptions = G)) : nt && (t(this), this.defaultPolarOptions = (ht = this.horiz) ? k : v(ct === "xAxis" ? l.defaultXAxisOptions : l.defaultYAxisOptions, z), it && ct === "yAxis" && (this.defaultPolarOptions.stackLabels = l.defaultYAxisOptions.stackLabels, this.defaultPolarOptions.reversedStacks = !0)), et || nt ? (this.isRadial = !0, dt.chart.zoomType = null, this.labelCollector || (this.labelCollector = this.createLabelCollector()), this.labelCollector && q.labelCollectors.push(this.labelCollector)) : this.isRadial = !1, $ && ht && ($.axis = this), this.isCircular = ht);
}
function D() {
this.isRadial && this.beforeSetTickPositions();
}
function W($) {
var q = this.label;
if (q) {
var it = this.axis, et = q.getBBox(), nt = it.options.labels, rt = (it.translate(this.pos) + it.startAngleRad + Math.PI / 2) / Math.PI * 180 % 360, ct = Math.round(rt), gt = N(nt.y) ? 0 : 0.3 * -et.height, dt = nt.y, ht = 20, at = nt.align, J = "end", tt = 0 > ct ? ct + 360 : ct, ot = tt, lt = 0, pt = 0;
if (it.isRadial) {
var yt = it.getPosition(this.pos, it.center[2] / 2 + u(d(nt.distance, -25), it.center[2] / 2, -it.center[2] / 2));
nt.rotation === "auto" ? q.attr({ rotation: rt }) : N(dt) || (dt = it.chart.renderer.fontMetrics(q.styles && q.styles.fontSize).b - et.height / 2), N(at) || (it.isCircular ? (et.width > it.len * it.tickInterval / (it.max - it.min) && (ht = 0), at = rt > ht && rt < 180 - ht ? "left" : rt > 180 + ht && rt < 360 - ht ? "right" : "center") : at = "center", q.attr({ align: at })), at === "auto" && it.tickPositions.length === 2 && it.isCircular && (90 < tt && 180 > tt ? tt = 180 - tt : 270 < tt && 360 >= tt && (tt = 540 - tt), 180 < ot && 360 >= ot && (ot = 360 - ot), (it.pane.options.startAngle === ct || it.pane.options.startAngle === ct + 360 || it.pane.options.startAngle === ct - 360) && (J = "start"), at = -90 <= ct && 90 >= ct || -360 <= ct && -270 >= ct || 270 <= ct && 360 >= ct ? J === "start" ? "right" : "left" : J === "start" ? "left" : "right", 70 < ot && 110 > ot && (at = "center"), 15 > tt || 180 <= tt && 195 > tt ? lt = 0.3 * et.height : 15 <= tt && 35 >= tt ? lt = J === "start" ? 0 : 0.75 * et.height : 195 <= tt && 215 >= tt ? lt = J === "start" ? 0.75 * et.height : 0 : 35 < tt && 90 >= tt ? lt = J === "start" ? 0.25 * -et.height : et.height : 215 < tt && 270 >= tt && (lt = J === "start" ? et.height : 0.25 * -et.height), 15 > ot ? pt = J === "start" ? 0.15 * -et.height : 0.15 * et.height : 165 < ot && 180 >= ot && (pt = J === "start" ? 0.15 * et.height : 0.15 * -et.height), q.attr({ align: at }), q.translate(
pt,
lt + gt
)), $.pos.x = yt.x + (nt.x || 0), $.pos.y = yt.y + (dt || 0);
}
}
}
function P($) {
this.axis.getPosition && R($.pos, this.axis.getPosition(this.pos));
}
function X($, q) {
var it = this.chart, et = this.center;
return $ = this.startAngleRad + $, { x: it.plotLeft + et[0] + Math.cos($) * q, y: it.plotTop + et[1] + Math.sin($) * q };
}
function g() {
this.isDirty = !1;
}
function m() {
if (this.constructor.prototype.setAxisSize.call(this), this.isRadial) {
this.pane.updateCenter(this);
var $ = this.center = this.pane.center.slice();
if (this.isCircular)
this.sector = this.endAngleRad - this.startAngleRad;
else {
var q = this.postTranslate(this.angleRad, $[3] / 2);
$[0] = q.x - this.chart.plotLeft, $[1] = q.y - this.chart.plotTop;
}
this.len = this.width = this.height = ($[2] - $[3]) * d(this.sector, 1) / 2;
}
}
function L() {
this.constructor.prototype.setAxisTranslation.call(this), this.center && (this.transA = this.isCircular ? (this.endAngleRad - this.startAngleRad) / (this.max - this.min || 1) : (this.center[2] - this.center[3]) / 2 / (this.max - this.min || 1), this.minPixelPadding = this.isXAxis ? this.transA * this.minPointOffset : 0);
}
function Y($) {
$ = this.options = v(this.constructor.defaultOptions, this.defaultPolarOptions, Z[this.coll], $), $.plotBands || ($.plotBands = []), S(this, "afterSetOptions");
}
function V($, q, it, et, nt, rt, ct) {
var gt = this.axis;
return gt.isRadial ? ($ = gt.getPosition(this.pos, gt.center[2] / 2 + et), q = ["M", q, it, "L", $.x, $.y]) : q = $.call(this, q, it, et, nt, rt, ct), q;
}
var Q = [], k = { gridLineWidth: 1, labels: { align: void 0, distance: 15, x: 0, y: void 0, style: { textOverflow: "none" } }, maxPadding: 0, minPadding: 0, showLastLabel: !1, tickLength: 0 }, G = {
labels: { align: "center", x: 0, y: void 0 },
minorGridLineWidth: 0,
minorTickInterval: "auto",
minorTickLength: 10,
minorTickPosition: "inside",
minorTickWidth: 1,
tickLength: 10,
tickPosition: "inside",
tickWidth: 2,
title: { rotation: 0 },
zIndex: 2
}, z = { gridLineInterpolation: "circle", gridLineWidth: 1, labels: { align: "right", x: -3, y: -2 }, showLastLabel: !1, title: { x: 4, text: null, rotation: 90 } };
B.compose = function($, q) {
return Q.indexOf($) === -1 && (Q.push($), U($, "afterInit", s), U($, "autoLabelAlign", n), U($, "destroy", A), U($, "init", _), U($, "initialAxisTranslation", D)), Q.indexOf(q) === -1 && (Q.push(q), U(
q,
"afterGetLabelPosition",
W
), U(q, "afterGetPosition", P), T(q.prototype, "getMarkPath", V)), $;
};
}(O || (O = {})), O;
}), E(f, "Series/AreaRange/AreaRangePoint.js", [f["Series/Area/AreaSeries.js"], f["Core/Series/Point.js"], f["Core/Utilities.js"]], function(l, y, j) {
var I = this && this.__extends || function() {
var F = function(N, R) {
return F = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(S, v) {
S.__proto__ = v;
} || function(S, v) {
for (var d in v)
v.hasOwnProperty(d) && (S[d] = v[d]);
}, F(N, R);
};
return function(N, R) {
function S() {
this.constructor = N;
}
F(N, R), N.prototype = R === null ? Object.create(R) : (S.prototype = R.prototype, new S());
};
}(), Z = y.prototype, H = j.defined, U = j.isNumber;
return function(F) {
function N() {
var R = F !== null && F.apply(this, arguments) || this;
return R.high = void 0, R.low = void 0, R.options = void 0, R.plotHigh = void 0, R.plotLow = void 0, R.plotHighX = void 0, R.plotLowX = void 0, R.plotX = void 0, R.series = void 0, R;
}
return I(N, F), N.prototype.setState = function() {
var R = this.state, S = this.series, v = S.chart.polar;
H(this.plotHigh) || (this.plotHigh = S.yAxis.toPixels(
this.high,
!0
)), H(this.plotLow) || (this.plotLow = this.plotY = S.yAxis.toPixels(this.low, !0)), S.stateMarkerGraphic && (S.lowerStateMarkerGraphic = S.stateMarkerGraphic, S.stateMarkerGraphic = S.upperStateMarkerGraphic), this.graphic = this.upperGraphic, this.plotY = this.plotHigh, v && (this.plotX = this.plotHighX), Z.setState.apply(this, arguments), this.state = R, this.plotY = this.plotLow, this.graphic = this.lowerGraphic, v && (this.plotX = this.plotLowX), S.stateMarkerGraphic && (S.upperStateMarkerGraphic = S.stateMarkerGraphic, S.stateMarkerGraphic = S.lowerStateMarkerGraphic, S.lowerStateMarkerGraphic = void 0), Z.setState.apply(this, arguments);
}, N.prototype.haloPath = function() {
var R = this.series.chart.polar, S = [];
return this.plotY = this.plotLow, R && (this.plotX = this.plotLowX), this.isInside && (S = Z.haloPath.apply(this, arguments)), this.plotY = this.plotHigh, R && (this.plotX = this.plotHighX), this.isTopInside && (S = S.concat(Z.haloPath.apply(this, arguments))), S;
}, N.prototype.isValid = function() {
return U(this.low) && U(this.high);
}, N;
}(l.prototype.pointClass);
}), E(
f,
"Series/AreaRange/AreaRangeSeries.js",
[f["Series/AreaRange/AreaRangePoint.js"], f["Series/Area/AreaSeries.js"], f["Series/Column/ColumnSeries.js"], f["Core/Globals.js"], f["Core/Series/Series.js"], f["Core/Series/SeriesRegistry.js"], f["Core/Utilities.js"]],
function(l, y, j, I, Z, H, U) {
var F = this && this.__extends || function() {
var B = function(C, b) {
return B = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(w, x) {
w.__proto__ = x;
} || function(w, x) {
for (var a in x)
x.hasOwnProperty(a) && (w[a] = x[a]);
}, B(C, b);
};
return function(C, b) {
function w() {
this.constructor = C;
}
B(C, b), C.prototype = b === null ? Object.create(b) : (w.prototype = b.prototype, new w());
};
}(), N = y.prototype, R = j.prototype;
j = I.noop;
var S = Z.prototype, v = U.defined, d = U.extend, u = U.isArray, T = U.pick, O = U.merge;
return Z = function(B) {
function C() {
var b = B !== null && B.apply(this, arguments) || this;
return b.data = void 0, b.options = void 0, b.points = void 0, b.lowerStateMarkerGraphic = void 0, b.xAxis = void 0, b;
}
return F(C, B), C.prototype.toYData = function(b) {
return [b.low, b.high];
}, C.prototype.highToXY = function(b) {
var w = this.chart, x = this.xAxis.postTranslate(b.rectPlotX || 0, this.yAxis.len - b.plotHigh);
b.plotHighX = x.x - w.plotLeft, b.plotHigh = x.y - w.plotTop, b.plotLowX = b.plotX;
}, C.prototype.translate = function() {
var b = this, w = b.yAxis;
N.translate.apply(b), b.points.forEach(function(x) {
var a = x.high, c = x.plotY;
x.isNull ? x.plotY = null : (x.plotLow = c, x.plotHigh = w.translate(b.dataModify ? b.dataModify.modifyValue(a) : a, 0, 1, 0, 1), b.dataModify && (x.yBottom = x.plotHigh));
}), this.chart.polar && this.points.forEach(function(x) {
b.highToXY(x), x.tooltipPos = [(x.plotHighX + x.plotLowX) / 2, (x.plotHigh + x.plotLow) / 2];
});
}, C.prototype.getGraphPath = function(b) {
var w = [], x = [], a, c = N.getGraphPath, p = this.options, i = this.chart.polar, h = i && p.connectEnds !== !1, o = p.connectNulls, t = p.step;
for (b = b || this.points, a = b.length; a--; ) {
var s = b[a], n = i ? { plotX: s.rectPlotX, plotY: s.yBottom, doCurve: !1 } : { plotX: s.plotX, plotY: s.plotY, doCurve: !1 };
s.isNull || h || o || b[a + 1] && !b[a + 1].isNull || x.push(n);
var A = { polarPlotY: s.polarPlotY, rectPlotX: s.rectPlotX, yBottom: s.yBottom, plotX: T(
s.plotHighX,
s.plotX
), plotY: s.plotHigh, isNull: s.isNull };
x.push(A), w.push(A), s.isNull || h || o || b[a - 1] && !b[a - 1].isNull || x.push(n);
}
return b = c.call(this, b), t && (t === !0 && (t = "left"), p.step = { left: "right", center: "center", right: "left" }[t]), w = c.call(this, w), x = c.call(this, x), p.step = t, p = [].concat(b, w), !this.chart.polar && x[0] && x[0][0] === "M" && (x[0] = ["L", x[0][1], x[0][2]]), this.graphPath = p, this.areaPath = b.concat(x), p.isArea = !0, p.xMap = b.xMap, this.areaPath.xMap = b.xMap, p;
}, C.prototype.drawDataLabels = function() {
var b = this.points, w = b.length, x, a = [], c = this.options.dataLabels, p, i = this.chart.inverted;
if (c) {
if (u(c))
var h = c[0] || { enabled: !1 }, o = c[1] || { enabled: !1 };
else
h = d({}, c), h.x = c.xHigh, h.y = c.yHigh, o = d({}, c), o.x = c.xLow, o.y = c.yLow;
if (h.enabled || this._hasPointLabels) {
for (x = w; x--; )
if (p = b[x]) {
var t = h.inside ? p.plotHigh < p.plotLow : p.plotHigh > p.plotLow;
p.y = p.high, p._plotY = p.plotY, p.plotY = p.plotHigh, a[x] = p.dataLabel, p.dataLabel = p.dataLabelUpper, p.below = t, i ? h.align || (h.align = t ? "right" : "left") : h.verticalAlign || (h.verticalAlign = t ? "top" : "bottom");
}
for (this.options.dataLabels = h, S.drawDataLabels && S.drawDataLabels.apply(this, arguments), x = w; x--; )
(p = b[x]) && (p.dataLabelUpper = p.dataLabel, p.dataLabel = a[x], delete p.dataLabels, p.y = p.low, p.plotY = p._plotY);
}
if (o.enabled || this._hasPointLabels) {
for (x = w; x--; )
(p = b[x]) && (t = o.inside ? p.plotHigh < p.plotLow : p.plotHigh > p.plotLow, p.below = !t, i ? o.align || (o.align = t ? "left" : "right") : o.verticalAlign || (o.verticalAlign = t ? "bottom" : "top"));
this.options.dataLabels = o, S.drawDataLabels && S.drawDataLabels.apply(this, arguments);
}
if (h.enabled)
for (x = w; x--; )
(p = b[x]) && (p.dataLabels = [p.dataLabelUpper, p.dataLabel].filter(function(s) {
return !!s;
}));
this.options.dataLabels = c;
}
}, C.prototype.alignDataLabel = function() {
R.alignDataLabel.apply(this, arguments);
}, C.prototype.drawPoints = function() {
var b = this.points.length, w;
for (S.drawPoints.apply(this, arguments), w = 0; w < b; ) {
var x = this.points[w];
x.origProps = { plotY: x.plotY, plotX: x.plotX, isInside: x.isInside, negative: x.negative, zone: x.zone, y: x.y }, x.lowerGraphic = x.graphic, x.graphic = x.upperGraphic, x.plotY = x.plotHigh, v(x.plotHighX) && (x.plotX = x.plotHighX), x.y = T(x.high, x.origProps.y), x.negative = x.y < (this.options.threshold || 0), this.zones.length && (x.zone = x.getZone()), this.chart.polar || (x.isInside = x.isTopInside = typeof x.plotY < "u" && 0 <= x.plotY && x.plotY <= this.yAxis.len && 0 <= x.plotX && x.plotX <= this.xAxis.len), w++;
}
for (S.drawPoints.apply(this, arguments), w = 0; w < b; )
x = this.points[w], x.upperGraphic = x.graphic, x.graphic = x.lowerGraphic, x.origProps && (d(x, x.origProps), delete x.origProps), w++;
}, C.defaultOptions = O(y.defaultOptions, {
lineWidth: 1,
threshold: null,
tooltip: { pointFormat: '● {series.name}: {point.low} - {point.high}
' },
trackByArea: !0,
dataLabels: { align: void 0, verticalAlign: void 0, xLow: 0, xHigh: 0, yLow: 0, yHigh: 0 }
}), C;
}(y), d(Z.prototype, { pointArrayMap: ["low", "high"], pointValKey: "low", deferTranslatePolar: !0, pointClass: l, setStackedPoints: j }), H.registerSeriesType("arearange", Z), Z;
}
), E(f, "Series/AreaSplineRange/AreaSplineRangeSeries.js", [
f["Series/AreaRange/AreaRangeSeries.js"],
f["Core/Series/SeriesRegistry.js"],
f["Core/Utilities.js"]
], function(l, y, j) {
var I = this && this.__extends || function() {
var F = function(N, R) {
return F = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(S, v) {
S.__proto__ = v;
} || function(S, v) {
for (var d in v)
v.hasOwnProperty(d) && (S[d] = v[d]);
}, F(N, R);
};
return function(N, R) {
function S() {
this.constructor = N;
}
F(N, R), N.prototype = R === null ? Object.create(R) : (S.prototype = R.prototype, new S());
};
}(), Z = y.seriesTypes.spline, H = j.merge;
j = j.extend;
var U = function(F) {
function N() {
var R = F !== null && F.apply(this, arguments) || this;
return R.options = void 0, R.data = void 0, R.points = void 0, R;
}
return I(N, F), N.defaultOptions = H(l.defaultOptions), N;
}(l);
return j(U.prototype, { getPointSpline: Z.prototype.getPointSpline }), y.registerSeriesType("areasplinerange", U), U;
}), E(f, "Series/BoxPlot/BoxPlotSeries.js", [f["Series/Column/ColumnSeries.js"], f["Core/Globals.js"], f["Core/Series/SeriesRegistry.js"], f["Core/Utilities.js"]], function(l, y, j, I) {
var Z = this && this.__extends || function() {
var N = function(R, S) {
return N = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(v, d) {
v.__proto__ = d;
} || function(v, d) {
for (var u in d)
d.hasOwnProperty(u) && (v[u] = d[u]);
}, N(R, S);
};
return function(R, S) {
function v() {
this.constructor = R;
}
N(R, S), R.prototype = S === null ? Object.create(S) : (v.prototype = S.prototype, new v());
};
}();
y = y.noop;
var H = I.extend, U = I.merge, F = I.pick;
return I = function(N) {
function R() {
var S = N !== null && N.apply(this, arguments) || this;
return S.data = void 0, S.options = void 0, S.points = void 0, S;
}
return Z(R, N), R.prototype.pointAttribs = function() {
return {};
}, R.prototype.translate = function() {
var S = this.yAxis, v = this.pointArrayMap;
N.prototype.translate.apply(this), this.points.forEach(function(d) {
v.forEach(function(u) {
d[u] !== null && (d[u + "Plot"] = S.translate(d[u], 0, 1, 0, 1));
}), d.plotHigh = d.highPlot;
});
}, R.prototype.drawPoints = function() {
var S = this, v = S.options, d = S.chart, u = d.renderer, T, O, B, C, b, w, x = 0, a, c, p, i, h = S.doQuartiles !== !1, o, t = S.options.whiskerLength;
S.points.forEach(function(s) {
var n = s.graphic, A = n ? "animate" : "attr", _ = s.shapeArgs, D = {}, W = {}, P = {}, X = {}, g = s.color || S.color;
typeof s.plotY < "u" && (a = Math.round(_.width), c = Math.floor(_.x), p = c + a, i = Math.round(a / 2), T = Math.floor(h ? s.q1Plot : s.lowPlot), O = Math.floor(h ? s.q3Plot : s.lowPlot), B = Math.floor(s.highPlot), C = Math.floor(s.lowPlot), n || (s.graphic = n = u.g("point").add(S.group), s.stem = u.path().addClass("highcharts-boxplot-stem").add(n), t && (s.whiskers = u.path().addClass("highcharts-boxplot-whisker").add(n)), h && (s.box = u.path(void 0).addClass("highcharts-boxplot-box").add(n)), s.medianShape = u.path(void 0).addClass("highcharts-boxplot-median").add(n)), d.styledMode || (W.stroke = s.stemColor || v.stemColor || g, W["stroke-width"] = F(s.stemWidth, v.stemWidth, v.lineWidth), W.dashstyle = s.stemDashStyle || v.stemDashStyle || v.dashStyle, s.stem.attr(W), t && (P.stroke = s.whiskerColor || v.whiskerColor || g, P["stroke-width"] = F(s.whiskerWidth, v.whiskerWidth, v.lineWidth), P.dashstyle = s.whiskerDashStyle || v.whiskerDashStyle || v.dashStyle, s.whiskers.attr(P)), h && (D.fill = s.fillColor || v.fillColor || g, D.stroke = v.lineColor || g, D["stroke-width"] = v.lineWidth || 0, D.dashstyle = s.boxDashStyle || v.boxDashStyle || v.dashStyle, s.box.attr(D)), X.stroke = s.medianColor || v.medianColor || g, X["stroke-width"] = F(s.medianWidth, v.medianWidth, v.lineWidth), X.dashstyle = s.medianDashStyle || v.medianDashStyle || v.dashStyle, s.medianShape.attr(X)), w = s.stem.strokeWidth() % 2 / 2, x = c + i + w, n = [["M", x, O], ["L", x, B], ["M", x, T], ["L", x, C]], s.stem[A]({ d: n }), h && (w = s.box.strokeWidth() % 2 / 2, T = Math.floor(T) + w, O = Math.floor(O) + w, c += w, p += w, n = [["M", c, O], ["L", c, T], ["L", p, T], ["L", p, O], ["L", c, O], ["Z"]], s.box[A]({ d: n })), t && (w = s.whiskers.strokeWidth() % 2 / 2, B += w, C += w, o = /%$/.test(t) ? i * parseFloat(t) / 100 : t / 2, n = [["M", x - o, B], ["L", x + o, B], ["M", x - o, C], ["L", x + o, C]], s.whiskers[A]({ d: n })), b = Math.round(s.medianPlot), w = s.medianShape.strokeWidth() % 2 / 2, b += w, n = [["M", c, b], ["L", p, b]], s.medianShape[A]({ d: n }));
});
}, R.prototype.toYData = function(S) {
return [S.low, S.q1, S.median, S.q3, S.high];
}, R.defaultOptions = U(l.defaultOptions, {
threshold: null,
tooltip: { pointFormat: '● {series.name}
Maximum: {point.high}
Upper quartile: {point.q3}
Median: {point.median}
Lower quartile: {point.q1}
Minimum: {point.low}
' },
whiskerLength: "50%",
fillColor: "#ffffff",
lineWidth: 1,
medianWidth: 2,
whiskerWidth: 2
}), R;
}(l), H(I.prototype, { pointArrayMap: ["low", "q1", "median", "q3", "high"], pointValKey: "high", drawDataLabels: y, setStackedPoints: y }), j.registerSeriesType("boxplot", I), I;
}), E(f, "Series/Bubble/BubbleLegendDefaults.js", [], function() {
return { borderColor: void 0, borderWidth: 2, className: void 0, color: void 0, connectorClassName: void 0, connectorColor: void 0, connectorDistance: 60, connectorWidth: 1, enabled: !1, labels: {
className: void 0,
allowOverlap: !1,
format: "",
formatter: void 0,
align: "right",
style: { fontSize: "10px", color: "#000000" },
x: 0,
y: 0
}, maxSize: 60, minSize: 10, legendIndex: 0, ranges: { value: void 0, borderColor: void 0, color: void 0, connectorColor: void 0 }, sizeBy: "area", sizeByAbsoluteValue: !1, zIndex: 1, zThreshold: 0 };
}), E(f, "Series/Bubble/BubbleLegendItem.js", [f["Core/Color/Color.js"], f["Core/FormatUtilities.js"], f["Core/Globals.js"], f["Core/Utilities.js"]], function(l, y, j, I) {
var Z = l.parse, H = j.noop, U = I.arrayMax, F = I.arrayMin, N = I.isNumber, R = I.merge, S = I.pick, v = I.stableSort;
return function() {
function d(u, T) {
this.options = this.symbols = this.visible = this.selected = this.ranges = this.movementX = this.maxLabel = this.legendSymbol = this.legendItemWidth = this.legendItemHeight = this.legendItem = this.legendGroup = this.legend = this.fontMetrics = this.chart = void 0, this.setState = H, this.init(u, T);
}
return d.prototype.init = function(u, T) {
this.options = u, this.visible = !0, this.chart = T.chart, this.legend = T;
}, d.prototype.addToLegend = function(u) {
u.splice(
this.options.legendIndex,
0,
this
);
}, d.prototype.drawLegendSymbol = function(u) {
var T = this.chart, O = this.options, B = S(u.options.itemDistance, 20), C = O.ranges, b = O.connectorDistance;
this.fontMetrics = T.renderer.fontMetrics(O.labels.style.fontSize), C && C.length && N(C[0].value) ? (v(C, function(w, x) {
return x.value - w.value;
}), this.ranges = C, this.setOptions(), this.render(), u = this.getMaxLabelSize(), C = this.ranges[0].radius, T = 2 * C, b = b - C + u.width, b = 0 < b ? b : 0, this.maxLabel = u, this.movementX = O.labels.align === "left" ? b : 0, this.legendItemWidth = T + b + B, this.legendItemHeight = T + this.fontMetrics.h / 2) : u.options.bubbleLegend.autoRanges = !0;
}, d.prototype.setOptions = function() {
var u = this.ranges, T = this.options, O = this.chart.series[T.seriesIndex], B = this.legend.baseline, C = { zIndex: T.zIndex, "stroke-width": T.borderWidth }, b = { zIndex: T.zIndex, "stroke-width": T.connectorWidth }, w = { align: this.legend.options.rtl || T.labels.align === "left" ? "right" : "left", zIndex: T.zIndex }, x = O.options.marker.fillOpacity, a = this.chart.styledMode;
u.forEach(function(c, p) {
a || (C.stroke = S(c.borderColor, T.borderColor, O.color), C.fill = S(c.color, T.color, x !== 1 ? Z(O.color).setOpacity(x).get("rgba") : O.color), b.stroke = S(c.connectorColor, T.connectorColor, O.color)), u[p].radius = this.getRangeRadius(c.value), u[p] = R(u[p], { center: u[0].radius - u[p].radius + B }), a || R(!0, u[p], { bubbleAttribs: R(C), connectorAttribs: R(b), labelAttribs: w });
}, this);
}, d.prototype.getRangeRadius = function(u) {
var T = this.options;
return this.chart.series[this.options.seriesIndex].getRadius.call(
this,
T.ranges[T.ranges.length - 1].value,
T.ranges[0].value,
T.minSize,
T.maxSize,
u
);
}, d.prototype.render = function() {
var u = this.chart.renderer, T = this.options.zThreshold;
this.symbols || (this.symbols = { connectors: [], bubbleItems: [], labels: [] }), this.legendSymbol = u.g("bubble-legend"), this.legendItem = u.g("bubble-legend-item"), this.legendSymbol.translateX = 0, this.legendSymbol.translateY = 0, this.ranges.forEach(function(O) {
O.value >= T && this.renderRange(O);
}, this), this.legendSymbol.add(this.legendItem), this.legendItem.add(this.legendGroup), this.hideOverlappingLabels();
}, d.prototype.renderRange = function(u) {
var T = this.options, O = T.labels, B = this.chart, C = B.series[T.seriesIndex], b = B.renderer, w = this.symbols;
B = w.labels;
var x = u.center, a = Math.abs(u.radius), c = T.connectorDistance || 0, p = O.align, i = T.connectorWidth, h = this.ranges[0].radius || 0, o = x - a - T.borderWidth / 2 + i / 2, t = this.fontMetrics;
t = t.f / 2 - (t.h - t.f) / 2;
var s = b.styledMode;
c = this.legend.options.rtl || p === "left" ? -c : c, p === "center" && (c = 0, T.connectorDistance = 0, u.labelAttribs.align = "center"), p = o + T.labels.y;
var n = h + c + T.labels.x;
w.bubbleItems.push(b.circle(
h,
x + ((o % 1 ? 1 : 0.5) - (i % 2 ? 0 : 0.5)),
a
).attr(s ? {} : u.bubbleAttribs).addClass((s ? "highcharts-color-" + C.colorIndex + " " : "") + "highcharts-bubble-legend-symbol " + (T.className || "")).add(this.legendSymbol)), w.connectors.push(b.path(b.crispLine([["M", h, o], ["L", h + c, o]], T.connectorWidth)).attr(s ? {} : u.connectorAttribs).addClass((s ? "highcharts-color-" + this.options.seriesIndex + " " : "") + "highcharts-bubble-legend-connectors " + (T.connectorClassName || "")).add(this.legendSymbol)), u = b.text(this.formatLabel(u), n, p + t).attr(s ? {} : u.labelAttribs).css(s ? {} : O.style).addClass("highcharts-bubble-legend-labels " + (T.labels.className || "")).add(this.legendSymbol), B.push(u), u.placed = !0, u.alignAttr = { x: n, y: p + t };
}, d.prototype.getMaxLabelSize = function() {
var u, T;
return this.symbols.labels.forEach(function(O) {
T = O.getBBox(!0), u = u ? T.width > u.width ? T : u : T;
}), u || {};
}, d.prototype.formatLabel = function(u) {
var T = this.options, O = T.labels.formatter;
T = T.labels.format;
var B = this.chart.numberFormatter;
return T ? y.format(T, u) : O ? O.call(u) : B(u.value, 1);
}, d.prototype.hideOverlappingLabels = function() {
var u = this.chart, T = this.symbols;
!this.options.labels.allowOverlap && T && (u.hideOverlappingLabels(T.labels), T.labels.forEach(function(O, B) {
O.newOpacity ? O.newOpacity !== O.oldOpacity && T.connectors[B].show() : T.connectors[B].hide();
}));
}, d.prototype.getRanges = function() {
var u = this.legend.bubbleLegend, T = u.options.ranges, O, B = Number.MAX_VALUE, C = -Number.MAX_VALUE;
u.chart.series.forEach(function(w) {
w.isBubble && !w.ignoreSeries && (O = w.zData.filter(N), O.length && (B = S(w.options.zMin, Math.min(B, Math.max(
F(O),
w.options.displayNegative === !1 ? w.options.zThreshold : -Number.MAX_VALUE
))), C = S(w.options.zMax, Math.max(C, U(O)))));
});
var b = B === C ? [{ value: C }] : [{ value: B }, { value: (B + C) / 2 }, { value: C, autoRanges: !0 }];
return T.length && T[0].radius && b.reverse(), b.forEach(function(w, x) {
T && T[x] && (b[x] = R(T[x], w));
}), b;
}, d.prototype.predictBubbleSizes = function() {
var u = this.chart, T = this.fontMetrics, O = u.legend.options, B = O.floating, C = (O = O.layout === "horizontal") ? u.legend.lastLineHeight : 0, b = u.plotSizeX, w = u.plotSizeY, x = u.series[this.options.seriesIndex], a = x.getPxExtremes();
u = Math.ceil(a.minPxSize), a = Math.ceil(a.maxPxSize);
var c = Math.min(w, b);
return x = x.options.maxSize, B || !/%$/.test(x) ? T = a : (x = parseFloat(x), T = (c + C - T.h / 2) * x / 100 / (x / 100 + 1), (O && w - T >= b || !O && b - T >= w) && (T = a)), [u, Math.ceil(T)];
}, d.prototype.updateRanges = function(u, T) {
var O = this.legend.options.bubbleLegend;
O.minSize = u, O.maxSize = T, O.ranges = this.getRanges();
}, d.prototype.correctSizes = function() {
var u = this.legend, T = this.chart.series[this.options.seriesIndex].getPxExtremes();
1 < Math.abs(Math.ceil(T.maxPxSize) - this.options.maxSize) && (this.updateRanges(this.options.minSize, T.maxPxSize), u.render());
}, d;
}();
}), E(f, "Series/Bubble/BubbleLegendComposition.js", [f["Series/Bubble/BubbleLegendDefaults.js"], f["Series/Bubble/BubbleLegendItem.js"], f["Core/DefaultOptions.js"], f["Core/Utilities.js"]], function(l, y, j, I) {
var Z = j.setOptions, H = I.addEvent, U = I.objectEach, F = I.wrap, N;
return function(R) {
function S(C, b, w) {
var x = this.legend, a = 0 <= v(this);
if (x && x.options.enabled && x.bubbleLegend && x.options.bubbleLegend.autoRanges && a) {
var c = x.bubbleLegend.options;
a = x.bubbleLegend.predictBubbleSizes(), x.bubbleLegend.updateRanges(a[0], a[1]), c.placed || (x.group.placed = !1, x.allItems.forEach(function(p) {
p.legendGroup.translateY = null;
})), x.render(), this.getMargins(), this.axes.forEach(function(p) {
p.visible && p.render(), c.placed || (p.setScale(), p.updateNames(), U(p.ticks, function(i) {
i.isNew = !0, i.isNewLabel = !0;
}));
}), c.placed = !0, this.getMargins(), C.call(this, b, w), x.bubbleLegend.correctSizes(), O(x, d(x));
} else
C.call(this, b, w), x && x.options.enabled && x.bubbleLegend && (x.render(), O(x, d(x)));
}
function v(C) {
C = C.series;
for (var b = 0; b < C.length; ) {
if (C[b] && C[b].isBubble && C[b].visible && C[b].zData.length)
return b;
b++;
}
return -1;
}
function d(C) {
C = C.allItems;
var b = [], w = C.length, x, a = 0;
for (x = 0; x < w; x++)
if (C[x].legendItemHeight && (C[x].itemHeight = C[x].legendItemHeight), C[x] === C[w - 1] || C[x + 1] && C[x]._legendItemPos[1] !== C[x + 1]._legendItemPos[1]) {
b.push({ height: 0 });
var c = b[b.length - 1];
for (a; a <= x; a++)
C[a].itemHeight > c.height && (c.height = C[a].itemHeight);
c.step = x;
}
return b;
}
function u(C) {
var b = this.bubbleLegend, w = this.options, x = w.bubbleLegend, a = v(this.chart);
b && b.ranges && b.ranges.length && (x.ranges.length && (x.autoRanges = !!x.ranges[0].autoRanges), this.destroyItem(b)), 0 <= a && w.enabled && x.enabled && (x.seriesIndex = a, this.bubbleLegend = new y(x, this), this.bubbleLegend.addToLegend(C.allItems));
}
function T() {
var C = this.chart, b = this.visible, w = this.chart.legend;
w && w.bubbleLegend && (this.visible = !b, this.ignoreSeries = b, C = 0 <= v(C), w.bubbleLegend.visible !== C && (w.update({ bubbleLegend: { enabled: C } }), w.bubbleLegend.visible = C), this.visible = b);
}
function O(C, b) {
var w = C.options.rtl, x, a, c, p = 0;
C.allItems.forEach(function(i, h) {
x = i.legendGroup.translateX, a = i._legendItemPos[1], ((c = i.movementX) || w && i.ranges) && (c = w ? x - i.options.maxSize / 2 : x + c, i.legendGroup.attr({ translateX: c })), h > b[p].step && p++, i.legendGroup.attr({ translateY: Math.round(a + b[p].height / 2) }), i._legendItemPos[1] = a + b[p].height / 2;
});
}
var B = [];
R.compose = function(C, b, w) {
B.indexOf(C) === -1 && (B.push(C), Z({ legend: { bubbleLegend: l } }), F(C.prototype, "drawChartBox", S)), B.indexOf(b) === -1 && (B.push(b), H(b, "afterGetAllItems", u)), B.indexOf(w) === -1 && (B.push(w), H(w, "legendItemClick", T));
};
}(N || (N = {})), N;
}), E(f, "Series/Bubble/BubblePoint.js", [f["Core/Series/Point.js"], f["Core/Series/SeriesRegistry.js"], f["Core/Utilities.js"]], function(l, y, j) {
var I = this && this.__extends || function() {
var Z = function(H, U) {
return Z = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(F, N) {
F.__proto__ = N;
} || function(F, N) {
for (var R in N)
N.hasOwnProperty(R) && (F[R] = N[R]);
}, Z(H, U);
};
return function(H, U) {
function F() {
this.constructor = H;
}
Z(H, U), H.prototype = U === null ? Object.create(U) : (F.prototype = U.prototype, new F());
};
}();
return j = j.extend, y = function(Z) {
function H() {
var U = Z !== null && Z.apply(this, arguments) || this;
return U.options = void 0, U.series = void 0, U;
}
return I(H, Z), H.prototype.haloPath = function(U) {
return l.prototype.haloPath.call(this, U === 0 ? 0 : (this.marker && this.marker.radius || 0) + U);
}, H;
}(y.seriesTypes.scatter.prototype.pointClass), j(y.prototype, { ttBelow: !1 }), y;
}), E(f, "Series/Bubble/BubbleSeries.js", [
f["Core/Axis/Axis.js"],
f["Series/Bubble/BubbleLegendComposition.js"],
f["Series/Bubble/BubblePoint.js"],
f["Core/Color/Color.js"],
f["Core/Globals.js"],
f["Core/Series/Series.js"],
f["Core/Series/SeriesRegistry.js"],
f["Core/Utilities.js"]
], function(l, y, j, I, Z, H, U, F) {
var N = this && this.__extends || function() {
var w = function(x, a) {
return w = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(c, p) {
c.__proto__ = p;
} || function(c, p) {
for (var i in p)
p.hasOwnProperty(i) && (c[i] = p[i]);
}, w(x, a);
};
return function(x, a) {
function c() {
this.constructor = x;
}
w(x, a), x.prototype = a === null ? Object.create(a) : (c.prototype = a.prototype, new c());
};
}(), R = I.parse;
I = Z.noop;
var S = U.seriesTypes;
Z = S.column;
var v = S.scatter;
S = F.addEvent;
var d = F.arrayMax, u = F.arrayMin, T = F.clamp, O = F.extend, B = F.isNumber, C = F.merge, b = F.pick;
return F = function(w) {
function x() {
var a = w !== null && w.apply(this, arguments) || this;
return a.data = void 0, a.maxPxSize = void 0, a.minPxSize = void 0, a.options = void 0, a.points = void 0, a.radii = void 0, a.yData = void 0, a.zData = void 0, a;
}
return N(x, w), x.prototype.animate = function(a) {
!a && this.points.length < this.options.animationLimit && this.points.forEach(function(c) {
var p = c.graphic;
p && p.width && (this.hasRendered || p.attr({ x: c.plotX, y: c.plotY, width: 1, height: 1 }), p.animate(this.markerAttribs(c), this.options.animation));
}, this);
}, x.prototype.getRadii = function() {
var a = this, c = this.zData, p = this.yData, i = [], h = this.chart.bubbleZExtremes, o = this.getPxExtremes(), t = o.minPxSize, s = o.maxPxSize;
if (!h) {
var n = Number.MAX_VALUE, A = -Number.MAX_VALUE, _;
this.chart.series.forEach(function(P) {
P.bubblePadding && (P.visible || !a.chart.options.chart.ignoreHiddenSeries) && (P = P.getZExtremes()) && (n = Math.min(n || P.zMin, P.zMin), A = Math.max(A || P.zMax, P.zMax), _ = !0);
}), _ ? (h = { zMin: n, zMax: A }, this.chart.bubbleZExtremes = h) : h = { zMin: 0, zMax: 0 };
}
var D = 0;
for (o = c.length; D < o; D++) {
var W = c[D];
i.push(this.getRadius(h.zMin, h.zMax, t, s, W, p[D]));
}
this.radii = i;
}, x.prototype.getRadius = function(a, c, p, i, h, o) {
var t = this.options, s = t.sizeBy !== "width", n = t.zThreshold, A = c - a, _ = 0.5;
if (o === null || h === null)
return null;
if (B(h)) {
if (t.sizeByAbsoluteValue && (h = Math.abs(h - n), A = Math.max(c - n, Math.abs(a - n)), a = 0), h < a)
return p / 2 - 1;
0 < A && (_ = (h - a) / A);
}
return s && 0 <= _ && (_ = Math.sqrt(_)), Math.ceil(p + _ * (i - p)) / 2;
}, x.prototype.hasData = function() {
return !!this.processedXData.length;
}, x.prototype.pointAttribs = function(a, c) {
var p = this.options.marker.fillOpacity;
return a = H.prototype.pointAttribs.call(this, a, c), p !== 1 && (a.fill = R(a.fill).setOpacity(p).get("rgba")), a;
}, x.prototype.translate = function() {
w.prototype.translate.call(this), this.getRadii(), this.translateBubble();
}, x.prototype.translateBubble = function() {
for (var a = this.data, c = this.radii, p = this.getPxExtremes().minPxSize, i = a.length; i--; ) {
var h = a[i], o = c ? c[i] : 0;
B(o) && o >= p / 2 ? (h.marker = O(h.marker, { radius: o, width: 2 * o, height: 2 * o }), h.dlBox = { x: h.plotX - o, y: h.plotY - o, width: 2 * o, height: 2 * o }) : h.shapeArgs = h.plotY = h.dlBox = void 0;
}
}, x.prototype.getPxExtremes = function() {
var a = Math.min(this.chart.plotWidth, this.chart.plotHeight), c = function(i) {
if (typeof i == "string") {
var h = /%$/.test(i);
i = parseInt(i, 10);
}
return h ? a * i / 100 : i;
}, p = c(b(this.options.minSize, 8));
return c = Math.max(c(b(this.options.maxSize, "20%")), p), {
minPxSize: p,
maxPxSize: c
};
}, x.prototype.getZExtremes = function() {
var a = this.options, c = (this.zData || []).filter(B);
if (c.length) {
var p = b(a.zMin, T(u(c), a.displayNegative === !1 ? a.zThreshold || 0 : -Number.MAX_VALUE, Number.MAX_VALUE));
if (a = b(a.zMax, d(c)), B(p) && B(a))
return { zMin: p, zMax: a };
}
}, x.compose = y.compose, x.defaultOptions = C(v.defaultOptions, { dataLabels: { formatter: function() {
var a = this.series.chart.numberFormatter, c = this.point.z;
return B(c) ? a(c, -1) : "";
}, inside: !0, verticalAlign: "middle" }, animationLimit: 250, marker: {
lineColor: null,
lineWidth: 1,
fillOpacity: 0.5,
radius: null,
states: { hover: { radiusPlus: 0 } },
symbol: "circle"
}, minSize: 8, maxSize: "20%", softThreshold: !1, states: { hover: { halo: { size: 5 } } }, tooltip: { pointFormat: "({point.x}, {point.y}), Size: {point.z}" }, turboThreshold: 0, zThreshold: 0, zoneAxis: "z" }), x;
}(v), O(F.prototype, {
alignDataLabel: Z.prototype.alignDataLabel,
applyZones: I,
bubblePadding: !0,
buildKDTree: I,
directTouch: !0,
isBubble: !0,
pointArrayMap: ["y", "z"],
pointClass: j,
parallelArrays: ["x", "y", "z"],
trackerGroups: ["group", "dataLabelsGroup"],
specialGroup: "group",
zoneAxis: "z"
}), S(F, "updatedData", function(w) {
delete w.target.chart.bubbleZExtremes;
}), l.prototype.beforePadding = function() {
var w = this, x = this.len, a = this.chart, c = 0, p = x, i = this.isXAxis, h = i ? "xData" : "yData", o = this.min, t = this.max - o, s = x / t, n;
this.series.forEach(function(A) {
if (A.bubblePadding && (A.visible || !a.options.chart.ignoreHiddenSeries)) {
n = w.allowZoomOutside = !0;
var _ = A[h];
if (i && A.getRadii(0, 0, A), 0 < t) {
for (var D = _.length; D--; )
if (B(_[D]) && w.dataMin <= _[D] && _[D] <= w.max) {
var W = A.radii && A.radii[D] || 0;
c = Math.min((_[D] - o) * s - W, c), p = Math.max((_[D] - o) * s + W, p);
}
}
}
}), n && 0 < t && !this.logarithmic && (p -= x, s *= (x + Math.max(0, c) - Math.min(p, x)) / x, [["min", "userMin", c], ["max", "userMax", p]].forEach(function(A) {
typeof b(w.options[A[0]], w[A[1]]) > "u" && (w[A[0]] += A[2] / s);
}));
}, U.registerSeriesType("bubble", F), F;
}), E(f, "Series/ColumnRange/ColumnRangePoint.js", [f["Core/Series/SeriesRegistry.js"], f["Core/Utilities.js"]], function(l, y) {
var j = this && this.__extends || function() {
var U = function(F, N) {
return U = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(R, S) {
R.__proto__ = S;
} || function(R, S) {
for (var v in S)
S.hasOwnProperty(v) && (R[v] = S[v]);
}, U(F, N);
};
return function(F, N) {
function R() {
this.constructor = F;
}
U(F, N), F.prototype = N === null ? Object.create(N) : (R.prototype = N.prototype, new R());
};
}(), I = l.seriesTypes;
l = I.column.prototype.pointClass;
var Z = y.extend, H = y.isNumber;
return y = function(U) {
function F() {
var N = U !== null && U.apply(this, arguments) || this;
return N.series = void 0, N.options = void 0, N.barX = void 0, N.pointWidth = void 0, N.shapeType = void 0, N;
}
return j(F, U), F.prototype.isValid = function() {
return H(this.low);
}, F;
}(I.arearange.prototype.pointClass), Z(y.prototype, { setState: l.prototype.setState }), y;
}), E(f, "Series/ColumnRange/ColumnRangeSeries.js", [f["Series/ColumnRange/ColumnRangePoint.js"], f["Core/Globals.js"], f["Core/Series/SeriesRegistry.js"], f["Core/Utilities.js"]], function(l, y, j, I) {
var Z = this && this.__extends || function() {
var T = function(O, B) {
return T = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(C, b) {
C.__proto__ = b;
} || function(C, b) {
for (var w in b)
b.hasOwnProperty(w) && (C[w] = b[w]);
}, T(O, B);
};
return function(O, B) {
function C() {
this.constructor = O;
}
T(O, B), O.prototype = B === null ? Object.create(B) : (C.prototype = B.prototype, new C());
};
}();
y = y.noop;
var H = j.seriesTypes, U = H.arearange, F = H.column, N = F.prototype, R = U.prototype, S = I.clamp, v = I.merge, d = I.pick;
I = I.extend;
var u = { pointRange: null, marker: null, states: { hover: { halo: !1 } } };
return H = function(T) {
function O() {
var B = T !== null && T.apply(this, arguments) || this;
return B.data = void 0, B.points = void 0, B.options = void 0, B;
}
return Z(O, T), O.prototype.setOptions = function() {
return v(!0, arguments[0], { stacking: void 0 }), R.setOptions.apply(this, arguments);
}, O.prototype.translate = function() {
var B = this, C = B.yAxis, b = B.xAxis, w = b.startAngleRad, x, a = B.chart, c = B.xAxis.isRadial, p = Math.max(a.chartWidth, a.chartHeight) + 999, i;
N.translate.apply(B), B.points.forEach(function(h) {
var o = h.shapeArgs || {}, t = B.options.minPointLength;
h.plotHigh = i = S(C.translate(h.high, 0, 1, 0, 1), -p, p), h.plotLow = S(h.plotY, -p, p);
var s = i, n = d(
h.rectPlotY,
h.plotY
) - i;
Math.abs(n) < t ? (t -= n, n += t, s -= t / 2) : 0 > n && (n *= -1, s -= n), c ? (x = h.barX + w, h.shapeType = "arc", h.shapeArgs = B.polarArc(s + n, s, x, x + h.pointWidth)) : (o.height = n, o.y = s, t = o.x, t = t === void 0 ? 0 : t, o = o.width, o = o === void 0 ? 0 : o, h.tooltipPos = a.inverted ? [C.len + C.pos - a.plotLeft - s - n / 2, b.len + b.pos - a.plotTop - t - o / 2, n] : [b.left - a.plotLeft + t + o / 2, C.pos - a.plotTop + s + n / 2, n]);
});
}, O.prototype.crispCol = function() {
return N.crispCol.apply(this, arguments);
}, O.prototype.drawPoints = function() {
return N.drawPoints.apply(this, arguments);
}, O.prototype.drawTracker = function() {
return N.drawTracker.apply(this, arguments);
}, O.prototype.getColumnMetrics = function() {
return N.getColumnMetrics.apply(this, arguments);
}, O.prototype.pointAttribs = function() {
return N.pointAttribs.apply(this, arguments);
}, O.prototype.adjustForMissingColumns = function() {
return N.adjustForMissingColumns.apply(this, arguments);
}, O.prototype.animate = function() {
return N.animate.apply(this, arguments);
}, O.prototype.translate3dPoints = function() {
return N.translate3dPoints.apply(this, arguments);
}, O.prototype.translate3dShapes = function() {
return N.translate3dShapes.apply(this, arguments);
}, O.defaultOptions = v(F.defaultOptions, U.defaultOptions, u), O;
}(U), I(H.prototype, { directTouch: !0, trackerGroups: ["group", "dataLabelsGroup"], drawGraph: y, getSymbol: y, polarArc: function() {
return N.polarArc.apply(this, arguments);
}, pointClass: l }), j.registerSeriesType("columnrange", H), H;
}), E(f, "Series/ColumnPyramid/ColumnPyramidSeries.js", [f["Series/Column/ColumnSeries.js"], f["Core/Series/SeriesRegistry.js"], f["Core/Utilities.js"]], function(l, y, j) {
var I = this && this.__extends || function() {
var N = function(R, S) {
return N = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(v, d) {
v.__proto__ = d;
} || function(v, d) {
for (var u in d)
d.hasOwnProperty(u) && (v[u] = d[u]);
}, N(R, S);
};
return function(R, S) {
function v() {
this.constructor = R;
}
N(R, S), R.prototype = S === null ? Object.create(S) : (v.prototype = S.prototype, new v());
};
}(), Z = l.prototype, H = j.clamp, U = j.merge, F = j.pick;
return j = function(N) {
function R() {
var S = N !== null && N.apply(this, arguments) || this;
return S.data = void 0, S.options = void 0, S.points = void 0, S;
}
return I(R, N), R.prototype.translate = function() {
var S = this, v = S.chart, d = S.options, u = S.dense = 2 > S.closestPointRange * S.xAxis.transA;
u = S.borderWidth = F(d.borderWidth, u ? 0 : 1);
var T = S.yAxis, O = d.threshold, B = S.translatedThreshold = T.getThreshold(O), C = F(d.minPointLength, 5), b = S.getColumnMetrics(), w = b.width, x = S.barW = Math.max(w, 1 + 2 * u), a = S.pointXOffset = b.offset;
v.inverted && (B -= 0.5), d.pointPadding && (x = Math.ceil(x)), Z.translate.apply(S), S.points.forEach(function(c) {
var p = F(c.yBottom, B), i = 999 + Math.abs(p), h = H(c.plotY, -i, T.len + i);
i = c.plotX + a;
var o = x / 2, t = Math.min(h, p);
p = Math.max(h, p) - t;
var s;
c.barX = i, c.pointWidth = w, c.tooltipPos = v.inverted ? [T.len + T.pos - v.plotLeft - h, S.xAxis.len - i - o, p] : [i + o, h + T.pos - v.plotTop, p], h = O + (c.total || c.y), d.stacking === "percent" && (h = O + (0 > c.y) ? -100 : 100), h = T.toPixels(h, !0);
var n = (s = v.plotHeight - h - (v.plotHeight - B)) ? o * (t - h) / s : 0, A = s ? o * (t + p - h) / s : 0;
s = i - n + o, n = i + n + o;
var _ = i + A + o;
A = i - A + o;
var D = t - C, W = t + p;
0 > c.y && (D = t, W = t + p + C), v.inverted && (_ = T.width - t, s = h - (T.width - B), n = o * (h - _) / s, A = o * (h - (_ - p)) / s, s = i + o + n, n = s - 2 * n, _ = i - A + o, A = i + A + o, D = t, W = t + p - C, 0 > c.y && (W = t + p + C)), c.shapeType = "path", c.shapeArgs = { x: s, y: D, width: n - s, height: p, d: [["M", s, D], ["L", n, D], ["L", _, W], ["L", A, W], ["Z"]] };
});
}, R.defaultOptions = U(l.defaultOptions, {}), R;
}(l), y.registerSeriesType("columnpyramid", j), j;
}), E(f, "Series/ErrorBar/ErrorBarSeries.js", [f["Series/BoxPlot/BoxPlotSeries.js"], f["Series/Column/ColumnSeries.js"], f["Core/Series/SeriesRegistry.js"], f["Core/Utilities.js"]], function(l, y, j, I) {
var Z = this && this.__extends || function() {
var N = function(R, S) {
return N = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(v, d) {
v.__proto__ = d;
} || function(v, d) {
for (var u in d)
d.hasOwnProperty(u) && (v[u] = d[u]);
}, N(R, S);
};
return function(R, S) {
function v() {
this.constructor = R;
}
N(R, S), R.prototype = S === null ? Object.create(S) : (v.prototype = S.prototype, new v());
};
}(), H = j.seriesTypes.arearange, U = I.merge;
I = I.extend;
var F = function(N) {
function R() {
var S = N !== null && N.apply(this, arguments) || this;
return S.data = void 0, S.options = void 0, S.points = void 0, S;
}
return Z(R, N), R.prototype.getColumnMetrics = function() {
return this.linkedParent && this.linkedParent.columnMetrics || y.prototype.getColumnMetrics.call(this);
}, R.prototype.drawDataLabels = function() {
var S = this.pointValKey;
H && (H.prototype.drawDataLabels.call(this), this.data.forEach(function(v) {
v.y = v[S];
}));
}, R.prototype.toYData = function(S) {
return [S.low, S.high];
}, R.defaultOptions = U(l.defaultOptions, {
color: "#000000",
grouping: !1,
linkedTo: ":previous",
tooltip: { pointFormat: '● {series.name}: {point.low} - {point.high}
' },
whiskerWidth: null
}), R;
}(l);
return I(F.prototype, { pointArrayMap: ["low", "high"], pointValKey: "high", doQuartiles: !1 }), j.registerSeriesType("errorbar", F), F;
}), E(f, "Series/Gauge/GaugePoint.js", [f["Core/Series/SeriesRegistry.js"]], function(l) {
var y = this && this.__extends || function() {
var j = function(I, Z) {
return j = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(H, U) {
H.__proto__ = U;
} || function(H, U) {
for (var F in U)
U.hasOwnProperty(F) && (H[F] = U[F]);
}, j(I, Z);
};
return function(I, Z) {
function H() {
this.constructor = I;
}
j(I, Z), I.prototype = Z === null ? Object.create(Z) : (H.prototype = Z.prototype, new H());
};
}();
return function(j) {
function I() {
var Z = j !== null && j.apply(this, arguments) || this;
return Z.options = void 0, Z.series = void 0, Z.shapeArgs = void 0, Z;
}
return y(I, j), I.prototype.setState = function(Z) {
this.state = Z;
}, I;
}(l.series.prototype.pointClass);
}), E(f, "Series/Gauge/GaugeSeries.js", [f["Series/Gauge/GaugePoint.js"], f["Core/Globals.js"], f["Core/Series/SeriesRegistry.js"], f["Core/Utilities.js"]], function(l, y, j, I) {
var Z = this && this.__extends || function() {
var u = function(T, O) {
return u = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(B, C) {
B.__proto__ = C;
} || function(B, C) {
for (var b in C)
C.hasOwnProperty(b) && (B[b] = C[b]);
}, u(T, O);
};
return function(T, O) {
function B() {
this.constructor = T;
}
u(T, O), T.prototype = O === null ? Object.create(O) : (B.prototype = O.prototype, new B());
};
}();
y = y.noop;
var H = j.series, U = j.seriesTypes.column, F = I.clamp, N = I.isNumber, R = I.extend, S = I.merge, v = I.pick, d = I.pInt;
return I = function(u) {
function T() {
var O = u !== null && u.apply(this, arguments) || this;
return O.data = void 0, O.points = void 0, O.options = void 0, O.yAxis = void 0, O;
}
return Z(T, u), T.prototype.translate = function() {
var O = this.yAxis, B = this.options, C = O.center;
this.generatePoints(), this.points.forEach(function(b) {
var w = S(B.dial, b.dial), x = d(v(w.radius, "80%")) * C[2] / 200, a = d(v(w.baseLength, "70%")) * x / 100, c = d(v(w.rearLength, "10%")) * x / 100, p = w.baseWidth || 3, i = w.topWidth || 1, h = B.overshoot, o = O.startAngleRad + O.translate(b.y, null, null, null, !0);
(N(h) || B.wrap === !1) && (h = N(h) ? h / 180 * Math.PI : 0, o = F(
o,
O.startAngleRad - h,
O.endAngleRad + h
)), o = 180 * o / Math.PI, b.shapeType = "path", b.shapeArgs = { d: w.path || [["M", -c, -p / 2], ["L", a, -p / 2], ["L", x, -i / 2], ["L", x, i / 2], ["L", a, p / 2], ["L", -c, p / 2], ["Z"]], translateX: C[0], translateY: C[1], rotation: o }, b.plotX = C[0], b.plotY = C[1];
});
}, T.prototype.drawPoints = function() {
var O = this, B = O.chart, C = O.yAxis.center, b = O.pivot, w = O.options, x = w.pivot, a = B.renderer;
O.points.forEach(function(c) {
var p = c.graphic, i = c.shapeArgs, h = i.d, o = S(w.dial, c.dial);
p ? (p.animate(i), i.d = h) : c.graphic = a[c.shapeType](i).attr({
rotation: i.rotation,
zIndex: 1
}).addClass("highcharts-dial").add(O.group), B.styledMode || c.graphic[p ? "animate" : "attr"]({ stroke: o.borderColor || "none", "stroke-width": o.borderWidth || 0, fill: o.backgroundColor || "#000000" });
}), b ? b.animate({ translateX: C[0], translateY: C[1] }) : (O.pivot = a.circle(0, 0, v(x.radius, 5)).attr({ zIndex: 2 }).addClass("highcharts-pivot").translate(C[0], C[1]).add(O.group), B.styledMode || O.pivot.attr({ "stroke-width": x.borderWidth || 0, stroke: x.borderColor || "#cccccc", fill: x.backgroundColor || "#000000" }));
}, T.prototype.animate = function(O) {
var B = this;
O || B.points.forEach(function(C) {
var b = C.graphic;
b && (b.attr({ rotation: 180 * B.yAxis.startAngleRad / Math.PI }), b.animate({ rotation: C.shapeArgs.rotation }, B.options.animation));
});
}, T.prototype.render = function() {
this.group = this.plotGroup("group", "series", this.visible ? "visible" : "hidden", this.options.zIndex, this.chart.seriesGroup), H.prototype.render.call(this), this.group.clip(this.chart.clipRect);
}, T.prototype.setData = function(O, B) {
H.prototype.setData.call(this, O, !1), this.processData(), this.generatePoints(), v(B, !0) && this.chart.redraw();
}, T.prototype.hasData = function() {
return !!this.points.length;
}, T.defaultOptions = S(H.defaultOptions, { dataLabels: { borderColor: "#cccccc", borderRadius: 3, borderWidth: 1, crop: !1, defer: !1, enabled: !0, verticalAlign: "top", y: 15, zIndex: 2 }, dial: {}, pivot: {}, tooltip: { headerFormat: "" }, showInLegend: !1 }), T;
}(H), R(I.prototype, { angular: !0, directTouch: !0, drawGraph: y, drawTracker: U.prototype.drawTracker, fixedBox: !0, forceDL: !0, noSharedTooltip: !0, pointClass: l, trackerGroups: [
"group",
"dataLabelsGroup"
] }), j.registerSeriesType("gauge", I), I;
}), E(f, "Series/PackedBubble/PackedBubblePoint.js", [f["Core/Chart/Chart.js"], f["Core/Series/Point.js"], f["Core/Series/SeriesRegistry.js"]], function(l, y, j) {
var I = this && this.__extends || function() {
var Z = function(H, U) {
return Z = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(F, N) {
F.__proto__ = N;
} || function(F, N) {
for (var R in N)
N.hasOwnProperty(R) && (F[R] = N[R]);
}, Z(H, U);
};
return function(H, U) {
function F() {
this.constructor = H;
}
Z(H, U), H.prototype = U === null ? Object.create(U) : (F.prototype = U.prototype, new F());
};
}();
return function(Z) {
function H() {
var U = Z !== null && Z.apply(this, arguments) || this;
return U.degree = NaN, U.mass = NaN, U.radius = NaN, U.options = void 0, U.series = void 0, U.value = null, U;
}
return I(H, Z), H.prototype.destroy = function() {
return this.series.layout && this.series.layout.removeElementFromCollection(this, this.series.layout.nodes), y.prototype.destroy.apply(this, arguments);
}, H.prototype.firePointEvent = function() {
var U = this.series.options;
if (this.isParentNode && U.parentNode) {
var F = U.allowPointSelect;
U.allowPointSelect = U.parentNode.allowPointSelect, y.prototype.firePointEvent.apply(this, arguments), U.allowPointSelect = F;
} else
y.prototype.firePointEvent.apply(this, arguments);
}, H.prototype.select = function() {
var U = this.series.chart;
this.isParentNode ? (U.getSelectedPoints = U.getSelectedParentNodes, y.prototype.select.apply(this, arguments), U.getSelectedPoints = l.prototype.getSelectedPoints) : y.prototype.select.apply(this, arguments);
}, H;
}(j.seriesTypes.bubble.prototype.pointClass);
}), E(f, "Series/Networkgraph/DraggableNodes.js", [f["Core/Chart/Chart.js"], f["Core/Globals.js"], f["Core/Utilities.js"]], function(l, y, j) {
var I = j.addEvent;
y.dragNodesMixin = { onMouseDown: function(Z, H) {
H = this.chart.pointer.normalize(H), Z.fixedPosition = { chartX: H.chartX, chartY: H.chartY, plotX: Z.plotX, plotY: Z.plotY }, Z.inDragMode = !0;
}, onMouseMove: function(Z, H) {
if (Z.fixedPosition && Z.inDragMode) {
var U = this.chart, F = U.pointer.normalize(H);
H = Z.fixedPosition.chartX - F.chartX, F = Z.fixedPosition.chartY - F.chartY;
var N = void 0, R = void 0, S = U.graphLayoutsLookup;
(5 < Math.abs(H) || 5 < Math.abs(F)) && (N = Z.fixedPosition.plotX - H, R = Z.fixedPosition.plotY - F, U.isInsidePlot(N, R) && (Z.plotX = N, Z.plotY = R, Z.hasDragged = !0, this.redrawHalo(Z), S.forEach(function(v) {
v.restartSimulation();
})));
}
}, onMouseUp: function(Z, H) {
Z.fixedPosition && (Z.hasDragged && (this.layout.enableSimulation ? this.layout.start() : this.chart.redraw()), Z.inDragMode = Z.hasDragged = !1, this.options.fixedDraggable || delete Z.fixedPosition);
}, redrawHalo: function(Z) {
Z && this.halo && this.halo.attr({ d: Z.haloPath(this.options.states.hover.halo.size) });
} }, I(l, "load", function() {
var Z = this, H, U, F;
Z.container && (H = I(Z.container, "mousedown", function(N) {
var R = Z.hoverPoint;
R && R.series && R.series.hasDraggableNodes && R.series.options.draggable && (R.series.onMouseDown(R, N), U = I(Z.container, "mousemove", function(S) {
return R && R.series && R.series.onMouseMove(R, S);
}), F = I(Z.container.ownerDocument, "mouseup", function(S) {
return U(), F(), R && R.series && R.series.onMouseUp(R, S);
}));
})), I(Z, "destroy", function() {
H();
});
});
}), E(
f,
"Series/Networkgraph/Integrations.js",
[f["Core/Globals.js"]],
function(l) {
l.networkgraphIntegrations = { verlet: { attractiveForceFunction: function(y, j) {
return (j - y) / y;
}, repulsiveForceFunction: function(y, j) {
return (j - y) / y * (j > y ? 1 : 0);
}, barycenter: function() {
var y = this.options.gravitationalConstant, j = this.barycenter.xFactor, I = this.barycenter.yFactor;
j = (j - (this.box.left + this.box.width) / 2) * y, I = (I - (this.box.top + this.box.height) / 2) * y, this.nodes.forEach(function(Z) {
Z.fixedPosition || (Z.plotX -= j / Z.mass / Z.degree, Z.plotY -= I / Z.mass / Z.degree);
});
}, repulsive: function(y, j, I) {
j = j * this.diffTemperature / y.mass / y.degree, y.fixedPosition || (y.plotX += I.x * j, y.plotY += I.y * j);
}, attractive: function(y, j, I) {
var Z = y.getMass(), H = -I.x * j * this.diffTemperature;
j = -I.y * j * this.diffTemperature, y.fromNode.fixedPosition || (y.fromNode.plotX -= H * Z.fromNode / y.fromNode.degree, y.fromNode.plotY -= j * Z.fromNode / y.fromNode.degree), y.toNode.fixedPosition || (y.toNode.plotX += H * Z.toNode / y.toNode.degree, y.toNode.plotY += j * Z.toNode / y.toNode.degree);
}, integrate: function(y, j) {
var I = -y.options.friction, Z = y.options.maxSpeed, H = (j.plotX + j.dispX - j.prevX) * I;
I *= j.plotY + j.dispY - j.prevY;
var U = Math.abs, F = U(H) / (H || 1);
U = U(I) / (I || 1), H = F * Math.min(Z, Math.abs(H)), I = U * Math.min(Z, Math.abs(I)), j.prevX = j.plotX + j.dispX, j.prevY = j.plotY + j.dispY, j.plotX += H, j.plotY += I, j.temperature = y.vectorLength({ x: H, y: I });
}, getK: function(y) {
return Math.pow(y.box.width * y.box.height / y.nodes.length, 0.5);
} }, euler: { attractiveForceFunction: function(y, j) {
return y * y / j;
}, repulsiveForceFunction: function(y, j) {
return j * j / y;
}, barycenter: function() {
var y = this.options.gravitationalConstant, j = this.barycenter.xFactor, I = this.barycenter.yFactor;
this.nodes.forEach(function(Z) {
if (!Z.fixedPosition) {
var H = Z.getDegree();
H *= 1 + H / 2, Z.dispX += (j - Z.plotX) * y * H / Z.degree, Z.dispY += (I - Z.plotY) * y * H / Z.degree;
}
});
}, repulsive: function(y, j, I, Z) {
y.dispX += I.x / Z * j / y.degree, y.dispY += I.y / Z * j / y.degree;
}, attractive: function(y, j, I, Z) {
var H = y.getMass(), U = I.x / Z * j;
j *= I.y / Z, y.fromNode.fixedPosition || (y.fromNode.dispX -= U * H.fromNode / y.fromNode.degree, y.fromNode.dispY -= j * H.fromNode / y.fromNode.degree), y.toNode.fixedPosition || (y.toNode.dispX += U * H.toNode / y.toNode.degree, y.toNode.dispY += j * H.toNode / y.toNode.degree);
}, integrate: function(y, j) {
j.dispX += j.dispX * y.options.friction, j.dispY += j.dispY * y.options.friction;
var I = j.temperature = y.vectorLength({ x: j.dispX, y: j.dispY });
I !== 0 && (j.plotX += j.dispX / I * Math.min(Math.abs(j.dispX), y.temperature), j.plotY += j.dispY / I * Math.min(Math.abs(j.dispY), y.temperature));
}, getK: function(y) {
return Math.pow(y.box.width * y.box.height / y.nodes.length, 0.3);
} } };
}
), E(
f,
"Series/Networkgraph/QuadTree.js",
[f["Core/Globals.js"], f["Core/Utilities.js"]],
function(l, y) {
y = y.extend;
var j = l.QuadTreeNode = function(I) {
this.box = I, this.boxSize = Math.min(I.width, I.height), this.nodes = [], this.body = this.isInternal = !1, this.isEmpty = !0;
};
y(j.prototype, { insert: function(I, Z) {
this.isInternal ? this.nodes[this.getBoxPosition(I)].insert(I, Z - 1) : (this.isEmpty = !1, this.body ? Z ? (this.isInternal = !0, this.divideBox(), this.body !== !0 && (this.nodes[this.getBoxPosition(this.body)].insert(this.body, Z - 1), this.body = !0), this.nodes[this.getBoxPosition(I)].insert(I, Z - 1)) : (Z = new j({
top: I.plotX,
left: I.plotY,
width: 0.1,
height: 0.1
}), Z.body = I, Z.isInternal = !1, this.nodes.push(Z)) : (this.isInternal = !1, this.body = I));
}, updateMassAndCenter: function() {
var I = 0, Z = 0, H = 0;
this.isInternal ? (this.nodes.forEach(function(U) {
U.isEmpty || (I += U.mass, Z += U.plotX * U.mass, H += U.plotY * U.mass);
}), Z /= I, H /= I) : this.body && (I = this.body.mass, Z = this.body.plotX, H = this.body.plotY), this.mass = I, this.plotX = Z, this.plotY = H;
}, divideBox: function() {
var I = this.box.width / 2, Z = this.box.height / 2;
this.nodes[0] = new j({
left: this.box.left,
top: this.box.top,
width: I,
height: Z
}), this.nodes[1] = new j({ left: this.box.left + I, top: this.box.top, width: I, height: Z }), this.nodes[2] = new j({ left: this.box.left + I, top: this.box.top + Z, width: I, height: Z }), this.nodes[3] = new j({ left: this.box.left, top: this.box.top + Z, width: I, height: Z });
}, getBoxPosition: function(I) {
var Z = I.plotY < this.box.top + this.box.height / 2;
return I.plotX < this.box.left + this.box.width / 2 ? Z ? 0 : 3 : Z ? 1 : 2;
} }), l = l.QuadTree = function(I, Z, H, U) {
this.box = { left: I, top: Z, width: H, height: U }, this.maxDepth = 25, this.root = new j(
this.box,
"0"
), this.root.isInternal = !0, this.root.isRoot = !0, this.root.divideBox();
}, y(l.prototype, { insertNodes: function(I) {
I.forEach(function(Z) {
this.root.insert(Z, this.maxDepth);
}, this);
}, visitNodeRecursive: function(I, Z, H) {
var U;
I || (I = this.root), I === this.root && Z && (U = Z(I)), U !== !1 && (I.nodes.forEach(function(F) {
if (F.isInternal) {
if (Z && (U = Z(F)), U === !1)
return;
this.visitNodeRecursive(F, Z, H);
} else
F.body && Z && Z(F.body);
H && H(F);
}, this), I === this.root && H && H(I));
}, calculateMassAndCenter: function() {
this.visitNodeRecursive(
null,
null,
function(I) {
I.updateMassAndCenter();
}
);
} });
}
), E(f, "Series/Networkgraph/Layouts.js", [f["Core/Chart/Chart.js"], f["Core/Animation/AnimationUtilities.js"], f["Core/Globals.js"], f["Core/Utilities.js"]], function(l, y, j, I) {
var Z = y.setAnimation;
y = I.addEvent;
var H = I.clamp, U = I.defined, F = I.extend, N = I.isFunction, R = I.pick;
j.layouts = { "reingold-fruchterman": function() {
} }, F(j.layouts["reingold-fruchterman"].prototype, {
init: function(S) {
this.options = S, this.nodes = [], this.links = [], this.series = [], this.box = {
x: 0,
y: 0,
width: 0,
height: 0
}, this.setInitialRendering(!0), this.integration = j.networkgraphIntegrations[S.integration], this.enableSimulation = S.enableSimulation, this.attractiveForce = R(S.attractiveForce, this.integration.attractiveForceFunction), this.repulsiveForce = R(S.repulsiveForce, this.integration.repulsiveForceFunction), this.approximation = S.approximation;
},
updateSimulation: function(S) {
this.enableSimulation = R(S, this.options.enableSimulation);
},
start: function() {
var S = this.series, v = this.options;
this.currentStep = 0, this.forces = S[0] && S[0].forces || [], this.chart = S[0] && S[0].chart, this.initialRendering && (this.initPositions(), S.forEach(function(d) {
d.finishedAnimating = !0, d.render();
})), this.setK(), this.resetSimulation(v), this.enableSimulation && this.step();
},
step: function() {
var S = this, v = this.series;
S.currentStep++, S.approximation === "barnes-hut" && (S.createQuadTree(), S.quadTree.calculateMassAndCenter()), S.forces.forEach(function(d) {
S[d + "Forces"](S.temperature);
}), S.applyLimits(S.temperature), S.temperature = S.coolDown(
S.startTemperature,
S.diffTemperature,
S.currentStep
), S.prevSystemTemperature = S.systemTemperature, S.systemTemperature = S.getSystemTemperature(), S.enableSimulation && (v.forEach(function(d) {
d.chart && d.render();
}), S.maxIterations-- && isFinite(S.temperature) && !S.isStable() ? (S.simulation && j.win.cancelAnimationFrame(S.simulation), S.simulation = j.win.requestAnimationFrame(function() {
S.step();
})) : S.simulation = !1);
},
stop: function() {
this.simulation && j.win.cancelAnimationFrame(this.simulation);
},
setArea: function(S, v, d, u) {
this.box = {
left: S,
top: v,
width: d,
height: u
};
},
setK: function() {
this.k = this.options.linkLength || this.integration.getK(this);
},
addElementsToCollection: function(S, v) {
S.forEach(function(d) {
v.indexOf(d) === -1 && v.push(d);
});
},
removeElementFromCollection: function(S, v) {
S = v.indexOf(S), S !== -1 && v.splice(S, 1);
},
clear: function() {
this.nodes.length = 0, this.links.length = 0, this.series.length = 0, this.resetSimulation();
},
resetSimulation: function() {
this.forcedStop = !1, this.systemTemperature = 0, this.setMaxIterations(), this.setTemperature(), this.setDiffTemperature();
},
restartSimulation: function() {
this.simulation ? this.resetSimulation() : (this.setInitialRendering(!1), this.enableSimulation ? this.start() : this.setMaxIterations(1), this.chart && this.chart.redraw(), this.setInitialRendering(!0));
},
setMaxIterations: function(S) {
this.maxIterations = R(S, this.options.maxIterations);
},
setTemperature: function() {
this.temperature = this.startTemperature = Math.sqrt(this.nodes.length);
},
setDiffTemperature: function() {
this.diffTemperature = this.startTemperature / (this.options.maxIterations + 1);
},
setInitialRendering: function(S) {
this.initialRendering = S;
},
createQuadTree: function() {
this.quadTree = new j.QuadTree(this.box.left, this.box.top, this.box.width, this.box.height), this.quadTree.insertNodes(this.nodes);
},
initPositions: function() {
var S = this.options.initialPositions;
N(S) ? (S.call(this), this.nodes.forEach(function(v) {
U(v.prevX) || (v.prevX = v.plotX), U(v.prevY) || (v.prevY = v.plotY), v.dispX = 0, v.dispY = 0;
})) : S === "circle" ? this.setCircularPositions() : this.setRandomPositions();
},
setCircularPositions: function() {
function S(b) {
b.linksFrom.forEach(function(w) {
B[w.toNode.id] || (B[w.toNode.id] = !0, O.push(w.toNode), S(w.toNode));
});
}
var v = this.box, d = this.nodes, u = 2 * Math.PI / (d.length + 1), T = d.filter(function(b) {
return b.linksTo.length === 0;
}), O = [], B = {}, C = this.options.initialPositionRadius;
T.forEach(function(b) {
O.push(b), S(b);
}), O.length ? d.forEach(function(b) {
O.indexOf(b) === -1 && O.push(b);
}) : O = d, O.forEach(function(b, w) {
b.plotX = b.prevX = R(b.plotX, v.width / 2 + C * Math.cos(w * u)), b.plotY = b.prevY = R(b.plotY, v.height / 2 + C * Math.sin(w * u)), b.dispX = 0, b.dispY = 0;
});
},
setRandomPositions: function() {
function S(T) {
return T = T * T / Math.PI, T -= Math.floor(T);
}
var v = this.box, d = this.nodes, u = d.length + 1;
d.forEach(function(T, O) {
T.plotX = T.prevX = R(T.plotX, v.width * S(O)), T.plotY = T.prevY = R(T.plotY, v.height * S(u + O)), T.dispX = 0, T.dispY = 0;
});
},
force: function(S) {
this.integration[S].apply(this, Array.prototype.slice.call(arguments, 1));
},
barycenterForces: function() {
this.getBarycenter(), this.force("barycenter");
},
getBarycenter: function() {
var S = 0, v = 0, d = 0;
return this.nodes.forEach(function(u) {
v += u.plotX * u.mass, d += u.plotY * u.mass, S += u.mass;
}), this.barycenter = { x: v, y: d, xFactor: v / S, yFactor: d / S };
},
barnesHutApproximation: function(S, v) {
var d = this.getDistXY(S, v), u = this.vectorLength(d);
if (S !== v && u !== 0)
if (v.isInternal)
if (v.boxSize / u < this.options.theta && u !== 0) {
var T = this.repulsiveForce(u, this.k);
this.force("repulsive", S, T * v.mass, d, u);
var O = !1;
} else
O = !0;
else
T = this.repulsiveForce(u, this.k), this.force("repulsive", S, T * v.mass, d, u);
return O;
},
repulsiveForces: function() {
var S = this;
S.approximation === "barnes-hut" ? S.nodes.forEach(function(v) {
S.quadTree.visitNodeRecursive(
null,
function(d) {
return S.barnesHutApproximation(v, d);
}
);
}) : S.nodes.forEach(function(v) {
S.nodes.forEach(function(d) {
if (v !== d && !v.fixedPosition) {
var u = S.getDistXY(v, d), T = S.vectorLength(u);
if (T !== 0) {
var O = S.repulsiveForce(T, S.k);
S.force("repulsive", v, O * d.mass, u, T);
}
}
});
});
},
attractiveForces: function() {
var S = this, v, d, u;
S.links.forEach(function(T) {
T.fromNode && T.toNode && (v = S.getDistXY(T.fromNode, T.toNode), d = S.vectorLength(v), d !== 0 && (u = S.attractiveForce(d, S.k), S.force("attractive", T, u, v, d)));
});
},
applyLimits: function() {
var S = this;
S.nodes.forEach(function(v) {
v.fixedPosition || (S.integration.integrate(S, v), S.applyLimitBox(v, S.box), v.dispX = 0, v.dispY = 0);
});
},
applyLimitBox: function(S, v) {
var d = S.radius;
S.plotX = H(S.plotX, v.left + d, v.width - d), S.plotY = H(S.plotY, v.top + d, v.height - d);
},
coolDown: function(S, v, d) {
return S - v * d;
},
isStable: function() {
return 1e-5 > Math.abs(this.systemTemperature - this.prevSystemTemperature) || 0 >= this.temperature;
},
getSystemTemperature: function() {
return this.nodes.reduce(function(S, v) {
return S + v.temperature;
}, 0);
},
vectorLength: function(S) {
return Math.sqrt(S.x * S.x + S.y * S.y);
},
getDistR: function(S, v) {
return S = this.getDistXY(S, v), this.vectorLength(S);
},
getDistXY: function(S, v) {
var d = S.plotX - v.plotX;
return S = S.plotY - v.plotY, { x: d, y: S, absX: Math.abs(d), absY: Math.abs(S) };
}
}), y(l, "predraw", function() {
this.graphLayoutsLookup && this.graphLayoutsLookup.forEach(function(S) {
S.stop();
});
}), y(l, "render", function() {
function S(u) {
u.maxIterations-- && isFinite(u.temperature) && !u.isStable() && !u.enableSimulation && (u.beforeStep && u.beforeStep(), u.step(), d = !1, v = !0);
}
var v = !1;
if (this.graphLayoutsLookup) {
for (Z(!1, this), this.graphLayoutsLookup.forEach(function(u) {
u.start();
}); !d; ) {
var d = !0;
this.graphLayoutsLookup.forEach(S);
}
v && this.series.forEach(function(u) {
u && u.layout && u.render();
});
}
}), y(l, "beforePrint", function() {
this.graphLayoutsLookup && (this.graphLayoutsLookup.forEach(function(S) {
S.updateSimulation(!1);
}), this.redraw());
}), y(l, "afterPrint", function() {
this.graphLayoutsLookup && this.graphLayoutsLookup.forEach(function(S) {
S.updateSimulation();
}), this.redraw();
});
}), E(f, "Series/PackedBubble/PackedBubbleComposition.js", [f["Core/Chart/Chart.js"], f["Core/Globals.js"], f["Core/Utilities.js"]], function(l, y, j) {
var I = y.layouts["reingold-fruchterman"], Z = j.addEvent, H = j.extendClass, U = j.pick;
l.prototype.getSelectedParentNodes = function() {
var F = [];
return this.series.forEach(function(N) {
N.parentNode && N.parentNode.selected && F.push(N.parentNode);
}), F;
}, y.networkgraphIntegrations.packedbubble = { repulsiveForceFunction: function(F, N, R, S) {
return Math.min(F, (R.marker.radius + S.marker.radius) / 2);
}, barycenter: function() {
var F = this, N = F.options.gravitationalConstant, R = F.box, S = F.nodes, v, d;
S.forEach(function(u) {
F.options.splitSeries && !u.isParentNode ? (v = u.series.parentNode.plotX, d = u.series.parentNode.plotY) : (v = R.width / 2, d = R.height / 2), u.fixedPosition || (u.plotX -= (u.plotX - v) * N / (u.mass * Math.sqrt(S.length)), u.plotY -= (u.plotY - d) * N / (u.mass * Math.sqrt(S.length)));
});
}, repulsive: function(F, N, R, S) {
var v = N * this.diffTemperature / F.mass / F.degree;
N = R.x * v, R = R.y * v, F.fixedPosition || (F.plotX += N, F.plotY += R), S.fixedPosition || (S.plotX -= N, S.plotY -= R);
}, integrate: y.networkgraphIntegrations.verlet.integrate, getK: y.noop }, y.layouts.packedbubble = H(I, { beforeStep: function() {
this.options.marker && this.series.forEach(function(F) {
F && F.calculateParentRadius();
});
}, isStable: function() {
var F = Math.abs(this.prevSystemTemperature - this.systemTemperature);
return 1 > Math.abs(10 * this.systemTemperature / Math.sqrt(this.nodes.length)) && 1e-5 > F || 0 >= this.temperature;
}, setCircularPositions: function() {
var F = this, N = F.box, R = F.nodes, S = 2 * Math.PI / (R.length + 1), v, d, u = F.options.initialPositionRadius;
R.forEach(function(T, O) {
F.options.splitSeries && !T.isParentNode ? (v = T.series.parentNode.plotX, d = T.series.parentNode.plotY) : (v = N.width / 2, d = N.height / 2), T.plotX = T.prevX = U(T.plotX, v + u * Math.cos(T.index || O * S)), T.plotY = T.prevY = U(T.plotY, d + u * Math.sin(T.index || O * S)), T.dispX = 0, T.dispY = 0;
});
}, repulsiveForces: function() {
var F = this, N, R, S, v = F.options.bubblePadding;
F.nodes.forEach(function(d) {
d.degree = d.mass, d.neighbours = 0, F.nodes.forEach(function(u) {
N = 0, d === u || d.fixedPosition || !F.options.seriesInteraction && d.series !== u.series || (S = F.getDistXY(d, u), R = F.vectorLength(S) - (d.marker.radius + u.marker.radius + v), 0 > R && (d.degree += 0.01, d.neighbours++, N = F.repulsiveForce(-R / Math.sqrt(d.neighbours), F.k, d, u)), F.force("repulsive", d, N * u.mass, S, u, R));
});
});
}, applyLimitBox: function(F) {
if (this.options.splitSeries && !F.isParentNode && this.options.parentNodeLimit) {
var N = this.getDistXY(F, F.series.parentNode), R = F.series.parentNodeRadius - F.marker.radius - this.vectorLength(N);
0 > R && R > -2 * F.marker.radius && (F.plotX -= 0.01 * N.x, F.plotY -= 0.01 * N.y);
}
I.prototype.applyLimitBox.apply(this, arguments);
} }), Z(l, "beforeRedraw", function() {
this.allDataPoints && delete this.allDataPoints;
});
}), E(f, "Series/PackedBubble/PackedBubbleSeries.js", [f["Core/Color/Color.js"], f["Core/Globals.js"], f["Series/PackedBubble/PackedBubblePoint.js"], f["Core/Series/SeriesRegistry.js"], f["Core/Utilities.js"]], function(l, y, j, I, Z) {
var H = this && this.__extends || function() {
var w = function(x, a) {
return w = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(c, p) {
c.__proto__ = p;
} || function(c, p) {
for (var i in p)
p.hasOwnProperty(i) && (c[i] = p[i]);
}, w(x, a);
};
return function(x, a) {
function c() {
this.constructor = x;
}
w(x, a), x.prototype = a === null ? Object.create(a) : (c.prototype = a.prototype, new c());
};
}(), U = l.parse, F = I.series, N = I.seriesTypes.bubble, R = Z.addEvent, S = Z.clamp, v = Z.defined, d = Z.extend, u = Z.fireEvent, T = Z.isArray, O = Z.isNumber, B = Z.merge, C = Z.pick, b = y.dragNodesMixin;
return l = function(w) {
function x() {
var a = w !== null && w.apply(this, arguments) || this;
return a.chart = void 0, a.data = void 0, a.layout = void 0, a.options = void 0, a.points = void 0, a.xData = void 0, a;
}
return H(x, w), x.prototype.accumulateAllPoints = function(a) {
var c = a.chart, p = [], i, h;
for (i = 0; i < c.series.length; i++)
if (a = c.series[i], a.is("packedbubble") && a.visible || !c.options.chart.ignoreHiddenSeries)
for (h = 0; h < a.yData.length; h++)
p.push([null, null, a.yData[h], a.index, h, { id: h, marker: { radius: 0 } }]);
return p;
}, x.prototype.addLayout = function() {
var a = this.options.layoutAlgorithm, c = this.chart.graphLayoutsStorage, p = this.chart.graphLayoutsLookup, i = this.chart.options.chart;
c || (this.chart.graphLayoutsStorage = c = {}, this.chart.graphLayoutsLookup = p = []);
var h = c[a.type];
h || (a.enableSimulation = v(i.forExport) ? !i.forExport : a.enableSimulation, c[a.type] = h = new y.layouts[a.type](), h.init(a), p.splice(h.index, 0, h)), this.layout = h, this.points.forEach(function(o) {
o.mass = 2, o.degree = 1, o.collisionNmb = 1;
}), h.setArea(0, 0, this.chart.plotWidth, this.chart.plotHeight), h.addElementsToCollection([this], h.series), h.addElementsToCollection(this.points, h.nodes);
}, x.prototype.addSeriesLayout = function() {
var a = this.options.layoutAlgorithm, c = this.chart.graphLayoutsStorage, p = this.chart.graphLayoutsLookup, i = B(a, a.parentNodeOptions, { enableSimulation: this.layout.options.enableSimulation }), h = c[a.type + "-series"];
h || (c[a.type + "-series"] = h = new y.layouts[a.type](), h.init(i), p.splice(h.index, 0, h)), this.parentNodeLayout = h, this.createParentNodes();
}, x.prototype.calculateParentRadius = function() {
var a = this.seriesBox();
this.parentNodeRadius = S(Math.sqrt(2 * this.parentNodeMass / Math.PI) + 20, 20, a ? Math.max(Math.sqrt(Math.pow(
a.width,
2
) + Math.pow(a.height, 2)) / 2 + 20, 20) : Math.sqrt(2 * this.parentNodeMass / Math.PI) + 20), this.parentNode && (this.parentNode.marker.radius = this.parentNode.radius = this.parentNodeRadius);
}, x.prototype.calculateZExtremes = function() {
var a = this.options.zMin, c = this.options.zMax, p = 1 / 0, i = -1 / 0;
return a && c ? [a, c] : (this.chart.series.forEach(function(h) {
h.yData.forEach(function(o) {
v(o) && (o > i && (i = o), o < p && (p = o));
});
}), a = C(a, p), c = C(c, i), [a, c]);
}, x.prototype.checkOverlap = function(a, c) {
var p = a[0] - c[0], i = a[1] - c[1];
return -1e-3 > Math.sqrt(p * p + i * i) - Math.abs(a[2] + c[2]);
}, x.prototype.createParentNodes = function() {
var a = this, c = a.chart, p = a.parentNodeLayout, i, h = a.parentNode, o = a.pointClass, t = a.layout.options, s = { radius: a.parentNodeRadius, lineColor: a.color, fillColor: U(a.color).brighten(0.4).get() };
t.parentNodeOptions && (s = B(t.parentNodeOptions.marker || {}, s)), a.parentNodeMass = 0, a.points.forEach(function(n) {
a.parentNodeMass += Math.PI * Math.pow(n.marker.radius, 2);
}), a.calculateParentRadius(), p.nodes.forEach(function(n) {
n.seriesIndex === a.index && (i = !0);
}), p.setArea(0, 0, c.plotWidth, c.plotHeight), i || (h || (h = new o().init(this, { mass: a.parentNodeRadius / 2, marker: s, dataLabels: { inside: !1 }, states: { normal: { marker: s }, hover: { marker: s } }, dataLabelOnNull: !0, degree: a.parentNodeRadius, isParentNode: !0, seriesIndex: a.index })), a.parentNode && (h.plotX = a.parentNode.plotX, h.plotY = a.parentNode.plotY), a.parentNode = h, p.addElementsToCollection([a], p.series), p.addElementsToCollection([h], p.nodes));
}, x.prototype.deferLayout = function() {
var a = this.options.layoutAlgorithm;
this.visible && (this.addLayout(), a.splitSeries && this.addSeriesLayout());
}, x.prototype.destroy = function() {
this.chart.graphLayoutsLookup && this.chart.graphLayoutsLookup.forEach(function(a) {
a.removeElementFromCollection(this, a.series);
}, this), this.parentNode && this.parentNodeLayout && (this.parentNodeLayout.removeElementFromCollection(this.parentNode, this.parentNodeLayout.nodes), this.parentNode.dataLabel && (this.parentNode.dataLabel = this.parentNode.dataLabel.destroy())), F.prototype.destroy.apply(this, arguments);
}, x.prototype.drawDataLabels = function() {
var a = this.options.dataLabels.textPath, c = this.points;
F.prototype.drawDataLabels.apply(this, arguments), this.parentNode && (this.parentNode.formatPrefix = "parentNode", this.points = [this.parentNode], this.options.dataLabels.textPath = this.options.dataLabels.parentNodeTextPath, F.prototype.drawDataLabels.apply(this, arguments), this.points = c, this.options.dataLabels.textPath = a);
}, x.prototype.drawGraph = function() {
if (this.layout && this.layout.options.splitSeries) {
var a = this.chart, c = this.layout.options.parentNodeOptions.marker, p = { fill: c.fillColor || U(this.color).brighten(0.4).get(), opacity: c.fillOpacity, stroke: c.lineColor || this.color, "stroke-width": C(c.lineWidth, this.options.lineWidth) };
this.parentNodesGroup || (this.parentNodesGroup = this.plotGroup("parentNodesGroup", "parentNode", this.visible ? "inherit" : "hidden", 0.1, a.seriesGroup), this.group.attr({ zIndex: 2 })), this.calculateParentRadius(), c = B({
x: this.parentNode.plotX - this.parentNodeRadius,
y: this.parentNode.plotY - this.parentNodeRadius,
width: 2 * this.parentNodeRadius,
height: 2 * this.parentNodeRadius
}, p), this.parentNode.graphic || (this.graph = this.parentNode.graphic = a.renderer.symbol(p.symbol).add(this.parentNodesGroup)), this.parentNode.graphic.attr(c);
}
}, x.prototype.drawTracker = function() {
var a = this.parentNode;
if (w.prototype.drawTracker.call(this), a) {
var c = T(a.dataLabels) ? a.dataLabels : a.dataLabel ? [a.dataLabel] : [];
a.graphic && (a.graphic.element.point = a), c.forEach(function(p) {
p.div ? p.div.point = a : p.element.point = a;
});
}
}, x.prototype.getPointRadius = function() {
var a = this, c = a.chart, p = a.options, i = p.useSimulation, h = Math.min(c.plotWidth, c.plotHeight), o = {}, t = [], s = c.allDataPoints, n, A, _, D;
["minSize", "maxSize"].forEach(function(P) {
var X = parseInt(p[P], 10), g = /%$/.test(p[P]);
o[P] = g ? h * X / 100 : X * Math.sqrt(s.length);
}), c.minRadius = n = o.minSize / Math.sqrt(s.length), c.maxRadius = A = o.maxSize / Math.sqrt(s.length);
var W = i ? a.calculateZExtremes() : [n, A];
(s || []).forEach(function(P, X) {
_ = i ? S(P[2], W[0], W[1]) : P[2], D = a.getRadius(W[0], W[1], n, A, _), D === 0 && (D = null), s[X][2] = D, t.push(D);
}), a.radii = t;
}, x.prototype.init = function() {
return F.prototype.init.apply(this, arguments), this.eventsToUnbind.push(R(this, "updatedData", function() {
this.chart.series.forEach(function(a) {
a.type === this.type && (a.isDirty = !0);
}, this);
})), this;
}, x.prototype.onMouseUp = function(a) {
if (a.fixedPosition && !a.removed) {
var c, p, i = this.layout, h = this.parentNodeLayout;
h && i.options.dragBetweenSeries && h.nodes.forEach(function(o) {
a && a.marker && o !== a.series.parentNode && (c = i.getDistXY(a, o), p = i.vectorLength(c) - o.marker.radius - a.marker.radius, 0 > p && (o.series.addPoint(B(a.options, { plotX: a.plotX, plotY: a.plotY }), !1), i.removeElementFromCollection(a, i.nodes), a.remove()));
}), b.onMouseUp.apply(this, arguments);
}
}, x.prototype.placeBubbles = function(a) {
var c = this.checkOverlap, p = this.positionBubble, i = [], h = 1, o = 0, t = 0, s = [], n;
if (a = a.sort(function(A, _) {
return _[2] - A[2];
}), a.length) {
if (i.push([[0, 0, a[0][2], a[0][3], a[0][4]]]), 1 < a.length)
for (i.push([[0, 0 - a[1][2] - a[0][2], a[1][2], a[1][3], a[1][4]]]), n = 2; n < a.length; n++)
a[n][2] = a[n][2] || 1, s = p(i[h][o], i[h - 1][t], a[n]), c(s, i[h][0]) ? (i.push([]), t = 0, i[h + 1].push(p(i[h][o], i[h][0], a[n])), h++, o = 0) : 1 < h && i[h - 1][t + 1] && c(s, i[h - 1][t + 1]) ? (t++, i[h].push(p(i[h][o], i[h - 1][t], a[n])), o++) : (o++, i[h].push(s));
this.chart.stages = i, this.chart.rawPositions = [].concat.apply([], i), this.resizeRadius(), s = this.chart.rawPositions;
}
return s;
}, x.prototype.pointAttribs = function(a, c) {
var p = this.options, i = p.marker;
return a && a.isParentNode && p.layoutAlgorithm && p.layoutAlgorithm.parentNodeOptions && (i = p.layoutAlgorithm.parentNodeOptions.marker), p = i.fillOpacity, a = F.prototype.pointAttribs.call(this, a, c), p !== 1 && (a["fill-opacity"] = p), a;
}, x.prototype.positionBubble = function(a, c, p) {
var i = Math.sqrt, h = Math.asin, o = Math.acos, t = Math.pow, s = Math.abs;
return i = i(t(a[0] - c[0], 2) + t(a[1] - c[1], 2)), o = o((t(i, 2) + t(p[2] + c[2], 2) - t(p[2] + a[2], 2)) / (2 * (p[2] + c[2]) * i)), h = h(s(a[0] - c[0]) / i), a = (0 > a[1] - c[1] ? 0 : Math.PI) + o + h * (0 > (a[0] - c[0]) * (a[1] - c[1]) ? 1 : -1), [c[0] + (c[2] + p[2]) * Math.sin(a), c[1] - (c[2] + p[2]) * Math.cos(a), p[2], p[3], p[4]];
}, x.prototype.render = function() {
var a = [];
F.prototype.render.apply(this, arguments), this.options.dataLabels.allowOverlap || (this.data.forEach(function(c) {
T(c.dataLabels) && c.dataLabels.forEach(function(p) {
a.push(p);
});
}), this.options.useSimulation && this.chart.hideOverlappingLabels(a));
}, x.prototype.resizeRadius = function() {
var a = this.chart, c = a.rawPositions, p = Math.min, i = Math.max, h = a.plotLeft, o = a.plotTop, t = a.plotHeight, s = a.plotWidth, n, A, _, D = n = Number.POSITIVE_INFINITY, W = A = Number.NEGATIVE_INFINITY;
for (_ = 0; _ < c.length; _++) {
var P = c[_][2];
D = p(
D,
c[_][0] - P
), W = i(W, c[_][0] + P), n = p(n, c[_][1] - P), A = i(A, c[_][1] + P);
}
if (_ = [W - D, A - n], p = p.apply([], [(s - h) / _[0], (t - o) / _[1]]), 1e-10 < Math.abs(p - 1)) {
for (_ = 0; _ < c.length; _++)
c[_][2] *= p;
this.placeBubbles(c);
} else
a.diffY = t / 2 + o - n - (A - n) / 2, a.diffX = s / 2 + h - D - (W - D) / 2;
}, x.prototype.seriesBox = function() {
var a = this.chart, c = Math.max, p = Math.min, i, h = [a.plotLeft, a.plotLeft + a.plotWidth, a.plotTop, a.plotTop + a.plotHeight];
return this.data.forEach(function(o) {
v(o.plotX) && v(o.plotY) && o.marker.radius && (i = o.marker.radius, h[0] = p(h[0], o.plotX - i), h[1] = c(h[1], o.plotX + i), h[2] = p(h[2], o.plotY - i), h[3] = c(h[3], o.plotY + i));
}), O(h.width / h.height) ? h : null;
}, x.prototype.setVisible = function() {
var a = this;
F.prototype.setVisible.apply(a, arguments), a.parentNodeLayout && a.graph ? a.visible ? (a.graph.show(), a.parentNode.dataLabel && a.parentNode.dataLabel.show()) : (a.graph.hide(), a.parentNodeLayout.removeElementFromCollection(a.parentNode, a.parentNodeLayout.nodes), a.parentNode.dataLabel && a.parentNode.dataLabel.hide()) : a.layout && (a.visible ? a.layout.addElementsToCollection(
a.points,
a.layout.nodes
) : a.points.forEach(function(c) {
a.layout.removeElementFromCollection(c, a.layout.nodes);
}));
}, x.prototype.translate = function() {
var a = this.chart, c = this.data, p = this.index, i, h = this.options.useSimulation;
if (this.processedXData = this.xData, this.generatePoints(), v(a.allDataPoints) || (a.allDataPoints = this.accumulateAllPoints(this), this.getPointRadius()), h)
var o = a.allDataPoints;
else
o = this.placeBubbles(a.allDataPoints), this.options.draggable = !1;
for (i = 0; i < o.length; i++)
if (o[i][3] === p) {
var t = c[o[i][4]], s = C(o[i][2], void 0);
h || (t.plotX = o[i][0] - a.plotLeft + a.diffX, t.plotY = o[i][1] - a.plotTop + a.diffY), O(s) && (t.marker = d(t.marker, { radius: s, width: 2 * s, height: 2 * s }), t.radius = s);
}
h && this.deferLayout(), u(this, "afterTranslate");
}, x.defaultOptions = B(N.defaultOptions, { minSize: "10%", maxSize: "50%", sizeBy: "area", zoneAxis: "y", crisp: !1, tooltip: { pointFormat: "Value: {point.value}" }, draggable: !0, useSimulation: !0, parentNode: { allowPointSelect: !1 }, dataLabels: { formatter: function() {
var a = this.series.chart.numberFormatter, c = this.point.value;
return O(c) ? a(c, -1) : "";
}, parentNodeFormatter: function() {
return this.name;
}, parentNodeTextPath: { enabled: !0 }, padding: 0, style: { transition: "opacity 2000ms" } }, layoutAlgorithm: { initialPositions: "circle", initialPositionRadius: 20, bubblePadding: 5, parentNodeLimit: !1, seriesInteraction: !0, dragBetweenSeries: !1, parentNodeOptions: { maxIterations: 400, gravitationalConstant: 0.03, maxSpeed: 50, initialPositionRadius: 100, seriesInteraction: !0, marker: {
fillColor: null,
fillOpacity: 1,
lineWidth: null,
lineColor: null,
symbol: "circle"
} }, enableSimulation: !0, type: "packedbubble", integration: "packedbubble", maxIterations: 1e3, splitSeries: !1, maxSpeed: 5, gravitationalConstant: 0.01, friction: -0.981 } }), x;
}(N), d(l.prototype, {
alignDataLabel: F.prototype.alignDataLabel,
axisTypes: [],
directTouch: !0,
forces: ["barycenter", "repulsive"],
hasDraggableNodes: !0,
isCartesian: !1,
noSharedTooltip: !0,
onMouseDown: b.onMouseDown,
onMouseMove: b.onMouseMove,
pointArrayMap: ["value"],
pointClass: j,
pointValKey: "value",
redrawHalo: b.redrawHalo,
requireSorting: !1,
searchPoint: y.noop,
trackerGroups: ["group", "dataLabelsGroup", "parentNodesGroup"]
}), I.registerSeriesType("packedbubble", l), l;
}), E(f, "Series/Polygon/PolygonSeries.js", [f["Core/Globals.js"], f["Core/Legend/LegendSymbol.js"], f["Core/Series/SeriesRegistry.js"], f["Core/Utilities.js"]], function(l, y, j, I) {
var Z = this && this.__extends || function() {
var v = function(d, u) {
return v = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(T, O) {
T.__proto__ = O;
} || function(T, O) {
for (var B in O)
O.hasOwnProperty(B) && (T[B] = O[B]);
}, v(d, u);
};
return function(d, u) {
function T() {
this.constructor = d;
}
v(d, u), d.prototype = u === null ? Object.create(u) : (T.prototype = u.prototype, new T());
};
}();
l = l.noop;
var H = j.series, U = j.seriesTypes, F = U.area, N = U.line, R = U.scatter;
U = I.extend;
var S = I.merge;
return I = function(v) {
function d() {
var u = v !== null && v.apply(this, arguments) || this;
return u.data = void 0, u.options = void 0, u.points = void 0, u;
}
return Z(d, v), d.prototype.getGraphPath = function() {
for (var u = N.prototype.getGraphPath.call(this), T = u.length + 1; T--; )
(T === u.length || u[T][0] === "M") && 0 < T && u.splice(T, 0, ["Z"]);
return this.areaPath = u;
}, d.prototype.drawGraph = function() {
this.options.fillColor = this.color, F.prototype.drawGraph.call(this);
}, d.defaultOptions = S(R.defaultOptions, { marker: { enabled: !1, states: { hover: { enabled: !1 } } }, stickyTracking: !1, tooltip: { followPointer: !0, pointFormat: "" }, trackByArea: !0 }), d;
}(R), U(I.prototype, { type: "polygon", drawLegendSymbol: y.drawRectangle, drawTracker: H.prototype.drawTracker, setStackedPoints: l }), j.registerSeriesType("polygon", I), I;
}), E(f, "Core/Axis/WaterfallAxis.js", [f["Extensions/Stacking.js"], f["Core/Utilities.js"]], function(l, y) {
var j = y.addEvent, I = y.objectEach, Z;
return function(H) {
function U() {
var v = this.waterfall.stacks;
v && (v.changed = !1, delete v.alreadyChanged);
}
function F() {
var v = this.options.stackLabels;
v && v.enabled && this.waterfall.stacks && this.waterfall.renderStackTotals();
}
function N() {
for (var v = this.axes, d = this.series, u = d.length; u--; )
d[u].options.stacking && (v.forEach(function(T) {
T.isXAxis || (T.waterfall.stacks.changed = !0);
}), u = 0);
}
function R() {
this.waterfall || (this.waterfall = new S(this));
}
var S = function() {
function v(d) {
this.axis = d, this.stacks = { changed: !1 };
}
return v.prototype.renderStackTotals = function() {
var d = this.axis, u = d.waterfall.stacks, T = d.stacking && d.stacking.stackTotalGroup, O = new l(d, d.options.stackLabels, !1, 0, void 0);
this.dummyStackItem = O, I(u, function(B) {
I(B, function(C) {
O.total = C.stackTotal, C.label && (O.label = C.label), l.prototype.render.call(O, T), C.label = O.label, delete O.label;
});
}), O.total = null;
}, v;
}();
H.Composition = S, H.compose = function(v, d) {
j(v, "init", R), j(v, "afterBuildStacks", U), j(v, "afterRender", F), j(d, "beforeRedraw", N);
};
}(Z || (Z = {})), Z;
}), E(f, "Series/Waterfall/WaterfallPoint.js", [f["Series/Column/ColumnSeries.js"], f["Core/Series/Point.js"], f["Core/Utilities.js"]], function(l, y, j) {
var I = this && this.__extends || function() {
var H = function(U, F) {
return H = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(N, R) {
N.__proto__ = R;
} || function(N, R) {
for (var S in R)
R.hasOwnProperty(S) && (N[S] = R[S]);
}, H(U, F);
};
return function(U, F) {
function N() {
this.constructor = U;
}
H(U, F), U.prototype = F === null ? Object.create(F) : (N.prototype = F.prototype, new N());
};
}(), Z = j.isNumber;
return function(H) {
function U() {
var F = H !== null && H.apply(this, arguments) || this;
return F.options = void 0, F.series = void 0, F;
}
return I(U, H), U.prototype.getClassName = function() {
var F = y.prototype.getClassName.call(this);
return this.isSum ? F += " highcharts-sum" : this.isIntermediateSum && (F += " highcharts-intermediate-sum"), F;
}, U.prototype.isValid = function() {
return Z(this.y) || this.isSum || !!this.isIntermediateSum;
}, U;
}(l.prototype.pointClass);
}), E(f, "Series/Waterfall/WaterfallSeries.js", [f["Core/Axis/Axis.js"], f["Core/Chart/Chart.js"], f["Core/Series/SeriesRegistry.js"], f["Core/Utilities.js"], f["Core/Axis/WaterfallAxis.js"], f["Series/Waterfall/WaterfallPoint.js"]], function(l, y, j, I, Z, H) {
var U = this && this.__extends || function() {
var C = function(b, w) {
return C = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(x, a) {
x.__proto__ = a;
} || function(x, a) {
for (var c in a)
a.hasOwnProperty(c) && (x[c] = a[c]);
}, C(b, w);
};
return function(b, w) {
function x() {
this.constructor = b;
}
C(b, w), b.prototype = w === null ? Object.create(w) : (x.prototype = w.prototype, new x());
};
}(), F = j.seriesTypes, N = F.column, R = F.line, S = I.arrayMax, v = I.arrayMin, d = I.correctFloat;
F = I.extend;
var u = I.isNumber, T = I.merge, O = I.objectEach, B = I.pick;
return I = function(C) {
function b() {
var w = C !== null && C.apply(this, arguments) || this;
return w.chart = void 0, w.data = void 0, w.options = void 0, w.points = void 0, w.stackedYNeg = void 0, w.stackedYPos = void 0, w.stackKey = void 0, w.xData = void 0, w.yAxis = void 0, w.yData = void 0, w;
}
return U(b, C), b.prototype.generatePoints = function() {
var w;
N.prototype.generatePoints.apply(this);
var x = 0;
for (w = this.points.length; x < w; x++) {
var a = this.points[x], c = this.processedYData[x];
(a.isIntermediateSum || a.isSum) && (a.y = d(c));
}
}, b.prototype.translate = function() {
var w = this.options, x = this.yAxis, a = B(w.minPointLength, 5), c = a / 2, p = w.threshold || 0, i = p, h = p;
w = w.stacking;
var o = x.waterfall.stacks[this.stackKey];
N.prototype.translate.apply(this);
for (var t = this.points, s = 0; s < t.length; s++) {
var n = t[s], A = this.processedYData[s], _ = n.shapeArgs;
if (_ && u(A)) {
var D = [0, A], W = n.y;
if (w) {
if (o) {
if (D = o[s], w === "overlap") {
var P = D.stackState[D.stateIndex--];
P = 0 <= W ? P : P - W, Object.hasOwnProperty.call(D, "absolutePos") && delete D.absolutePos, Object.hasOwnProperty.call(D, "absoluteNeg") && delete D.absoluteNeg;
} else
0 <= W ? (P = D.threshold + D.posTotal, D.posTotal -= W) : (P = D.threshold + D.negTotal, D.negTotal -= W, P -= W), !D.posTotal && Object.hasOwnProperty.call(D, "absolutePos") && (D.posTotal = D.absolutePos, delete D.absolutePos), !D.negTotal && Object.hasOwnProperty.call(D, "absoluteNeg") && (D.negTotal = D.absoluteNeg, delete D.absoluteNeg);
n.isSum || (D.connectorThreshold = D.threshold + D.stackTotal), x.reversed ? (A = 0 <= W ? P - W : P + W, W = P) : (A = P, W = P - W), n.below = A <= p, _.y = x.translate(A, !1, !0, !1, !0) || 0, _.height = Math.abs(_.y - (x.translate(W, !1, !0, !1, !0) || 0)), (W = x.waterfall.dummyStackItem) && (W.x = s, W.label = o[s].label, W.setOffset(this.pointXOffset || 0, this.barW || 0, this.stackedYNeg[s], this.stackedYPos[s]));
}
} else
P = Math.max(i, i + W) + D[0], _.y = x.translate(
P,
!1,
!0,
!1,
!0
) || 0, n.isSum ? (_.y = x.translate(D[1], !1, !0, !1, !0) || 0, _.height = Math.min(x.translate(D[0], !1, !0, !1, !0) || 0, x.len) - _.y, n.below = D[1] <= p) : n.isIntermediateSum ? (0 <= W ? (A = D[1] + h, W = h) : (A = h, W = D[1] + h), x.reversed && (A ^= W, W ^= A, A ^= W), _.y = x.translate(A, !1, !0, !1, !0) || 0, _.height = Math.abs(_.y - Math.min(x.translate(W, !1, !0, !1, !0) || 0, x.len)), h += D[1], n.below = A <= p) : (_.height = 0 < A ? (x.translate(i, !1, !0, !1, !0) || 0) - _.y : (x.translate(i, !1, !0, !1, !0) || 0) - (x.translate(i - A, !1, !0, !1, !0) || 0), i += A, n.below = i < p), 0 > _.height && (_.y += _.height, _.height *= -1);
n.plotY = _.y = Math.round(_.y || 0) - this.borderWidth % 2 / 2, _.height = Math.max(Math.round(_.height || 0), 1e-3), n.yBottom = _.y + _.height, _.height <= a && !n.isNull ? (_.height = a, _.y -= c, n.plotY = _.y, n.minPointLengthOffset = 0 > n.y ? -c : c) : (n.isNull && (_.width = 0), n.minPointLengthOffset = 0), W = n.plotY + (n.negative ? _.height : 0), n.below && (n.plotY += _.height), n.tooltipPos && (this.chart.inverted ? n.tooltipPos[0] = x.len - W : n.tooltipPos[1] = W);
}
}
}, b.prototype.processData = function(w) {
var x = this.options, a = this.yData, c = x.data, p = a.length, i = x.threshold || 0, h, o, t, s, n;
for (n = o = h = t = s = 0; n < p; n++) {
var A = a[n], _ = c && c[n] ? c[n] : {};
A === "sum" || _.isSum ? a[n] = d(o) : A === "intermediateSum" || _.isIntermediateSum ? (a[n] = d(h), h = 0) : (o += A, h += A), t = Math.min(o, t), s = Math.max(o, s);
}
C.prototype.processData.call(this, w), x.stacking || (this.dataMin = t + i, this.dataMax = s);
}, b.prototype.toYData = function(w) {
return w.isSum ? "sum" : w.isIntermediateSum ? "intermediateSum" : w.y;
}, b.prototype.updateParallelArrays = function(w, x) {
C.prototype.updateParallelArrays.call(this, w, x), (this.yData[0] === "sum" || this.yData[0] === "intermediateSum") && (this.yData[0] = null);
}, b.prototype.pointAttribs = function(w, x) {
var a = this.options.upColor;
return a && !w.options.color && (w.color = 0 < w.y ? a : null), w = N.prototype.pointAttribs.call(this, w, x), delete w.dashstyle, w;
}, b.prototype.getGraphPath = function() {
return [["M", 0, 0]];
}, b.prototype.getCrispPath = function() {
var w = this.data, x = this.yAxis, a = w.length, c = Math.round(this.graph.strokeWidth()) % 2 / 2, p = Math.round(this.borderWidth) % 2 / 2, i = this.xAxis.reversed, h = this.yAxis.reversed, o = this.options.stacking, t = [], s;
for (s = 1; s < a; s++) {
var n = w[s].shapeArgs, A = w[s - 1], _ = w[s - 1].shapeArgs, D = x.waterfall.stacks[this.stackKey], W = 0 < A.y ? -_.height : 0;
D && _ && n && (D = D[s - 1], o ? (D = D.connectorThreshold, W = Math.round(x.translate(D, 0, 1, 0, 1) + (h ? W : 0)) - c) : W = _.y + A.minPointLengthOffset + p - c, t.push(["M", (_.x || 0) + (i ? 0 : _.width || 0), W], ["L", (n.x || 0) + (i && n.width || 0), W])), _ && t.length && (!o && 0 > A.y && !h || 0 < A.y && h) && ((A = t[t.length - 2]) && typeof A[2] == "number" && (A[2] += _.height || 0), (A = t[t.length - 1]) && typeof A[2] == "number" && (A[2] += _.height || 0));
}
return t;
}, b.prototype.drawGraph = function() {
R.prototype.drawGraph.call(this), this.graph.attr({ d: this.getCrispPath() });
}, b.prototype.setStackedPoints = function() {
function w(V, Q, k, G) {
if (Y)
for (k; k < Y; k++)
X.stackState[k] += G;
else
X.stackState[0] = V, Y = X.stackState.length;
X.stackState.push(X.stackState[Y - 1] + Q);
}
var x = this.options, a = this.yAxis.waterfall.stacks, c = x.threshold, p = c || 0, i = p, h = this.stackKey, o = this.xData, t = o.length, s, n, A;
this.yAxis.stacking.usePercentage = !1;
var _ = n = A = p;
if (this.visible || !this.chart.options.chart.ignoreHiddenSeries) {
var D = a.changed;
(s = a.alreadyChanged) && 0 > s.indexOf(h) && (D = !0), a[h] || (a[h] = {}), s = a[h];
for (var W = 0; W < t; W++) {
var P = o[W];
(!s[P] || D) && (s[P] = { negTotal: 0, posTotal: 0, stackTotal: 0, threshold: 0, stateIndex: 0, stackState: [], label: D && s[P] ? s[P].label : void 0 });
var X = s[P], g = this.yData[W];
0 <= g ? X.posTotal += g : X.negTotal += g;
var m = x.data[W];
P = X.absolutePos = X.posTotal;
var L = X.absoluteNeg = X.negTotal;
X.stackTotal = P + L;
var Y = X.stackState.length;
m && m.isIntermediateSum ? (w(A, n, 0, A), A = n, n = c, p ^= i, i ^= p, p ^= i) : m && m.isSum ? (w(c, _, Y), p = c) : (w(p, g, 0, _), m && (_ += g, n += g)), X.stateIndex++, X.threshold = p, p += X.stackTotal;
}
a.changed = !1, a.alreadyChanged || (a.alreadyChanged = []), a.alreadyChanged.push(h);
}
}, b.prototype.getExtremes = function() {
var w = this.options.stacking;
if (w) {
var x = this.yAxis;
x = x.waterfall.stacks;
var a = this.stackedYNeg = [], c = this.stackedYPos = [];
return w === "overlap" ? O(x[this.stackKey], function(p) {
a.push(v(p.stackState)), c.push(S(p.stackState));
}) : O(x[this.stackKey], function(p) {
a.push(p.negTotal + p.threshold), c.push(p.posTotal + p.threshold);
}), { dataMin: v(a), dataMax: S(c) };
}
return { dataMin: this.dataMin, dataMax: this.dataMax };
}, b.defaultOptions = T(N.defaultOptions, { dataLabels: { inside: !0 }, lineWidth: 1, lineColor: "#333333", dashStyle: "Dot", borderColor: "#333333", states: { hover: { lineWidthPlus: 0 } } }), b;
}(N), F(I.prototype, { getZonesGraphs: R.prototype.getZonesGraphs, pointValKey: "y", showLine: !0, pointClass: H }), j.registerSeriesType("waterfall", I), Z.compose(l, y), I;
}), E(f, "Extensions/Polar.js", [
f["Core/Animation/AnimationUtilities.js"],
f["Core/Chart/Chart.js"],
f["Core/Globals.js"],
f["Extensions/Pane.js"],
f["Core/Pointer.js"],
f["Core/Series/Series.js"],
f["Core/Series/SeriesRegistry.js"],
f["Core/Renderer/SVG/SVGRenderer.js"],
f["Core/Utilities.js"]
], function(l, y, j, I, Z, H, U, F, N) {
var R = l.animObject;
U = U.seriesTypes;
var S = N.addEvent, v = N.defined, d = N.find, u = N.isNumber, T = N.pick, O = N.splat, B = N.uniqueKey;
l = N.wrap;
var C = H.prototype;
Z = Z.prototype, C.searchPointByAngle = function(x) {
var a = this.chart, c = this.xAxis.pane.center;
return this.searchKDTree({ clientX: 180 + -180 / Math.PI * Math.atan2(x.chartX - c[0] - a.plotLeft, x.chartY - c[1] - a.plotTop) });
}, C.getConnectors = function(x, a, c, p) {
var i = p ? 1 : 0, h = 0 <= a && a <= x.length - 1 ? a : 0 > a ? x.length - 1 + a : 0;
a = 0 > h - 1 ? x.length - (1 + i) : h - 1, i = h + 1 > x.length - 1 ? i : h + 1;
var o = x[a];
i = x[i];
var t = o.plotX;
o = o.plotY;
var s = i.plotX, n = i.plotY;
i = x[h].plotX, h = x[h].plotY, t = (1.5 * i + t) / 2.5, o = (1.5 * h + o) / 2.5, s = (1.5 * i + s) / 2.5;
var A = (1.5 * h + n) / 2.5;
n = Math.sqrt(Math.pow(t - i, 2) + Math.pow(o - h, 2));
var _ = Math.sqrt(Math.pow(s - i, 2) + Math.pow(A - h, 2));
return t = Math.atan2(o - h, t - i), A = Math.PI / 2 + (t + Math.atan2(A - h, s - i)) / 2, Math.abs(t - A) > Math.PI / 2 && (A -= Math.PI), t = i + Math.cos(A) * n, o = h + Math.sin(A) * n, s = i + Math.cos(Math.PI + A) * _, A = h + Math.sin(Math.PI + A) * _, i = { rightContX: s, rightContY: A, leftContX: t, leftContY: o, plotX: i, plotY: h }, c && (i.prevPointCont = this.getConnectors(x, a, !1, p)), i;
}, C.toXY = function(x) {
var a = this.chart, c = this.xAxis, p = this.yAxis, i = x.plotX, h = x.plotY, o = x.series, t = a.inverted, s = x.y, n = t ? i : p.len - h;
t && o && !o.isRadialBar && (x.plotY = h = typeof s == "number" && p.translate(s) || 0), x.rectPlotX = i, x.rectPlotY = h, p.center && (n += p.center[3] / 2), u(h) && (p = t ? p.postTranslate(h, n) : c.postTranslate(i, n), x.plotX = x.polarPlotX = p.x - a.plotLeft, x.plotY = x.polarPlotY = p.y - a.plotTop), this.kdByAngle ? (a = (i / Math.PI * 180 + c.pane.options.startAngle) % 360, 0 > a && (a += 360), x.clientX = a) : x.clientX = x.plotX;
}, U.spline && (l(U.spline.prototype, "getPointSpline", function(x, a, c, p) {
return this.chart.polar ? p ? (x = this.getConnectors(a, p, !0, this.connectEnds), a = x.prevPointCont && x.prevPointCont.rightContX, c = x.prevPointCont && x.prevPointCont.rightContY, x = ["C", u(a) ? a : x.plotX, u(c) ? c : x.plotY, u(x.leftContX) ? x.leftContX : x.plotX, u(x.leftContY) ? x.leftContY : x.plotY, x.plotX, x.plotY]) : x = ["M", c.plotX, c.plotY] : x = x.call(this, a, c, p), x;
}), U.areasplinerange && (U.areasplinerange.prototype.getPointSpline = U.spline.prototype.getPointSpline)), S(H, "afterTranslate", function() {
var x = this.chart;
if (x.polar && this.xAxis) {
if ((this.kdByAngle = x.tooltip && x.tooltip.shared) ? this.searchPoint = this.searchPointByAngle : this.options.findNearestPointBy = "xy", !this.preventPostTranslate)
for (var a = this.points, c = a.length; c--; )
this.toXY(a[c]), !x.hasParallelCoordinates && !this.yAxis.reversed && a[c].y < this.yAxis.min && (a[c].isNull = !0);
this.hasClipCircleSetter || (this.hasClipCircleSetter = !!this.eventsToUnbind.push(S(this, "afterRender", function() {
if (x.polar) {
var p = this.yAxis.pane.center;
this.clipCircle ? this.clipCircle.animate({ x: p[0], y: p[1], r: p[2] / 2, innerR: p[3] / 2 }) : this.clipCircle = x.renderer.clipCircle(p[0], p[1], p[2] / 2, p[3] / 2), this.group.clip(this.clipCircle), this.setClip = j.noop;
}
})));
}
}, { order: 2 }), l(
U.line.prototype,
"getGraphPath",
function(x, a) {
var c = this, p;
if (this.chart.polar) {
for (a = a || this.points, p = 0; p < a.length; p++)
if (!a[p].isNull) {
var i = p;
break;
}
if (this.options.connectEnds !== !1 && typeof i < "u") {
this.connectEnds = !0, a.splice(a.length, 0, a[i]);
var h = !0;
}
a.forEach(function(o) {
typeof o.polarPlotY > "u" && c.toXY(o);
});
}
return p = x.apply(this, [].slice.call(arguments, 1)), h && a.pop(), p;
}
);
var b = function(x, a) {
var c = this, p = this.chart, i = this.options.animation, h = this.group, o = this.markerGroup, t = this.xAxis && this.xAxis.center, s = p.plotLeft, n = p.plotTop, A, _, D, W;
if (p.polar) {
if (c.isRadialBar)
a || (c.startAngleRad = T(c.translatedThreshold, c.xAxis.startAngleRad), j.seriesTypes.pie.prototype.animate.call(c, a));
else if (p.renderer.isSVG)
if (i = R(i), c.is("column")) {
if (!a) {
var P = t[3] / 2;
c.points.forEach(function(X) {
A = X.graphic, D = (_ = X.shapeArgs) && _.r, W = _ && _.innerR, A && _ && (A.attr({ r: P, innerR: P }), A.animate({ r: D, innerR: W }, c.options.animation));
});
}
} else
a ? (x = { translateX: t[0] + s, translateY: t[1] + n, scaleX: 1e-3, scaleY: 1e-3 }, h.attr(x), o && o.attr(x)) : (x = { translateX: s, translateY: n, scaleX: 1, scaleY: 1 }, h.animate(x, i), o && o.animate(x, i));
} else
x.call(this, a);
};
if (l(C, "animate", b), U.column) {
var w = U.arearange.prototype;
U = U.column.prototype, U.polarArc = function(x, a, c, p) {
var i = this.xAxis.center, h = this.yAxis.len, o = i[3] / 2;
return a = h - a + o, x = h - T(x, h) + o, this.yAxis.reversed && (0 > a && (a = o), 0 > x && (x = o)), { x: i[0], y: i[1], r: a, innerR: x, start: c, end: p };
}, l(U, "animate", b), l(U, "translate", function(x) {
var a = this.options, c = a.stacking, p = this.chart, i = this.xAxis, h = this.yAxis, o = h.reversed, t = h.center, s = i.startAngleRad, n = i.endAngleRad - s;
if (this.preventPostTranslate = !0, x.call(this), i.isRadial) {
x = this.points, i = x.length;
var A = h.translate(h.min), _ = h.translate(h.max);
if (a = a.threshold || 0, p.inverted && u(a)) {
var D = h.translate(a);
v(D) && (0 > D ? D = 0 : D > n && (D = n), this.translatedThreshold = D + s);
}
for (; i--; ) {
a = x[i];
var W = a.barX, P = a.x, X = a.y;
if (a.shapeType = "arc", p.inverted) {
if (a.plotY = h.translate(X), c && h.stacking) {
if (X = h.stacking.stacks[(0 > X ? "-" : "") + this.stackKey], this.visible && X && X[P] && !a.isNull) {
var g = X[P].points[this.getStackIndicator(void 0, P, this.index).key], m = h.translate(g[0]);
g = h.translate(g[1]), v(m) && (m = N.clamp(m, 0, n));
}
} else
m = D, g = a.plotY;
m > g && (g = [m, m = g][0]), o ? g > A ? g = A : m < _ ? m = _ : (m > A || g < _) && (m = g = n) : m < A ? m = A : g > _ ? g = _ : (g < A || m > _) && (m = g = 0), h.min > h.max && (m = g = o ? n : 0), m += s, g += s, t && (a.barX = W += t[3] / 2), P = Math.max(W, 0), X = Math.max(W + a.pointWidth, 0), a.shapeArgs = { x: t && t[0], y: t && t[1], r: X, innerR: P, start: m, end: g }, a.opacity = m === g ? 0 : void 0, a.plotY = (v(this.translatedThreshold) && (m < this.translatedThreshold ? m : g)) - s;
} else
m = W + s, a.shapeArgs = this.polarArc(a.yBottom, a.plotY, m, m + a.pointWidth);
this.toXY(a), p.inverted ? (W = h.postTranslate(a.rectPlotY, W + a.pointWidth / 2), a.tooltipPos = [W.x - p.plotLeft, W.y - p.plotTop]) : a.tooltipPos = [a.plotX, a.plotY], t && (a.ttBelow = a.plotY > t[1]);
}
}
}), U.findAlignments = function(x, a) {
return a.align === null && (a.align = 20 < x && 160 > x ? "left" : 200 < x && 340 > x ? "right" : "center"), a.verticalAlign === null && (a.verticalAlign = 45 > x || 315 < x ? "bottom" : 135 < x && 225 > x ? "top" : "middle"), a;
}, w && (w.findAlignments = U.findAlignments), l(U, "alignDataLabel", function(x, a, c, p, i, h) {
var o = this.chart, t = T(p.inside, !!this.options.stacking);
o.polar ? (x = a.rectPlotX / Math.PI * 180, o.inverted ? (this.forceDL = o.isInsidePlot(a.plotX, Math.round(a.plotY)), t && a.shapeArgs ? (i = a.shapeArgs, i = this.yAxis.postTranslate(((i.start || 0) + (i.end || 0)) / 2 - this.xAxis.startAngleRad, a.barX + a.pointWidth / 2), i = { x: i.x - o.plotLeft, y: i.y - o.plotTop }) : a.tooltipPos && (i = { x: a.tooltipPos[0], y: a.tooltipPos[1] }), p.align = T(p.align, "center"), p.verticalAlign = T(
p.verticalAlign,
"middle"
)) : this.findAlignments && (p = this.findAlignments(x, p)), C.alignDataLabel.call(this, a, c, p, i, h), this.isRadialBar && a.shapeArgs && a.shapeArgs.start === a.shapeArgs.end && c.hide(!0)) : x.call(this, a, c, p, i, h);
});
}
l(Z, "getCoordinates", function(x, a) {
var c = this.chart, p = { xAxis: [], yAxis: [] };
return c.polar ? c.axes.forEach(function(i) {
var h = i.isXAxis, o = i.center;
if (i.coll !== "colorAxis") {
var t = a.chartX - o[0] - c.plotLeft;
o = a.chartY - o[1] - c.plotTop, p[h ? "xAxis" : "yAxis"].push({ axis: i, value: i.translate(h ? Math.PI - Math.atan2(t, o) : Math.sqrt(Math.pow(
t,
2
) + Math.pow(o, 2)), !0) });
}
}) : p = x.call(this, a), p;
}), F.prototype.clipCircle = function(x, a, c, p) {
var i = B(), h = this.createElement("clipPath").attr({ id: i }).add(this.defs);
return x = p ? this.arc(x, a, c, p, 0, 2 * Math.PI).add(h) : this.circle(x, a, c).add(h), x.id = i, x.clipPath = h, x;
}, S(y, "getAxes", function() {
this.pane || (this.pane = []), this.options.pane = O(this.options.pane), this.options.pane.forEach(function(x) {
new I(x, this);
}, this);
}), S(y, "afterDrawChartBox", function() {
this.pane.forEach(function(x) {
x.render();
});
}), S(
H,
"afterInit",
function() {
var x = this.chart;
x.inverted && x.polar && (this.isRadialSeries = !0, this.is("column") && (this.isRadialBar = !0));
}
), l(y.prototype, "get", function(x, a) {
return d(this.pane || [], function(c) {
return c.options.id === a;
}) || x.call(this, a);
});
}), E(f, "masters/highcharts-more.src.js", [f["Core/Globals.js"], f["Core/Axis/RadialAxis.js"], f["Series/Bubble/BubbleSeries.js"]], function(l, y, j) {
y.compose(l.Axis, l.Tick), j.compose(l.Chart, l.Legend, l.Series);
});
});
})(L0);
const _0 = fl;
var gl = {}, D0 = {
get exports() {
return gl;
},
set exports(r) {
gl = r;
}
};
(function(r) {
(function(f) {
r.exports ? (f.default = f, r.exports = f) : f(typeof Highcharts < "u" ? Highcharts : void 0);
})(function(f) {
function E(l, y, j, I) {
l.hasOwnProperty(y) || (l[y] = I.apply(null, j));
}
f = f ? f._modules : {}, E(
f,
"Extensions/FullScreen.js",
[f["Core/Chart/Chart.js"], f["Core/Globals.js"], f["Core/Renderer/HTML/AST.js"], f["Core/Utilities.js"]],
function(l, y, j, I) {
var Z = I.addEvent;
return I = function() {
function H(U) {
this.chart = U, this.isOpen = !1, U = U.renderTo, this.browserProps || (typeof U.requestFullscreen == "function" ? this.browserProps = { fullscreenChange: "fullscreenchange", requestFullscreen: "requestFullscreen", exitFullscreen: "exitFullscreen" } : U.mozRequestFullScreen ? this.browserProps = { fullscreenChange: "mozfullscreenchange", requestFullscreen: "mozRequestFullScreen", exitFullscreen: "mozCancelFullScreen" } : U.webkitRequestFullScreen ? this.browserProps = {
fullscreenChange: "webkitfullscreenchange",
requestFullscreen: "webkitRequestFullScreen",
exitFullscreen: "webkitExitFullscreen"
} : U.msRequestFullscreen && (this.browserProps = { fullscreenChange: "MSFullscreenChange", requestFullscreen: "msRequestFullscreen", exitFullscreen: "msExitFullscreen" }));
}
return H.prototype.close = function() {
var U = this.chart, F = U.options.chart;
this.isOpen && this.browserProps && U.container.ownerDocument instanceof Document && U.container.ownerDocument[this.browserProps.exitFullscreen](), this.unbindFullscreenEvent && (this.unbindFullscreenEvent = this.unbindFullscreenEvent()), U.setSize(this.origWidth, this.origHeight, !1), this.origHeight = this.origWidth = void 0, F.width = this.origWidthOption, F.height = this.origHeightOption, this.origHeightOption = this.origWidthOption = void 0, this.isOpen = !1, this.setButtonText();
}, H.prototype.open = function() {
var U = this, F = U.chart, N = F.options.chart;
if (N && (U.origWidthOption = N.width, U.origHeightOption = N.height), U.origWidth = F.chartWidth, U.origHeight = F.chartHeight, U.browserProps) {
var R = Z(
F.container.ownerDocument,
U.browserProps.fullscreenChange,
function() {
U.isOpen ? (U.isOpen = !1, U.close()) : (F.setSize(null, null, !1), U.isOpen = !0, U.setButtonText());
}
), S = Z(F, "destroy", R);
U.unbindFullscreenEvent = function() {
R(), S();
}, (N = F.renderTo[U.browserProps.requestFullscreen]()) && N.catch(function() {
alert("Full screen is not supported inside a frame.");
});
}
}, H.prototype.setButtonText = function() {
var U = this.chart, F = U.exportDivElements, N = U.options.exporting, R = N && N.buttons && N.buttons.contextButton.menuItems;
U = U.options.lang, N && N.menuItemDefinitions && U && U.exitFullscreen && U.viewFullscreen && R && F && (F = F[R.indexOf("viewFullscreen")]) && j.setElementHTML(F, this.isOpen ? U.exitFullscreen : N.menuItemDefinitions.viewFullscreen.text || U.viewFullscreen);
}, H.prototype.toggle = function() {
this.isOpen ? this.close() : this.open();
}, H;
}(), y.Fullscreen = I, Z(l, "beforeRender", function() {
this.fullscreen = new y.Fullscreen(this);
}), y.Fullscreen;
}
), E(f, "Core/Chart/ChartNavigationComposition.js", [], function() {
var l;
return function(y) {
y.compose = function(I) {
return I.navigation || (I.navigation = new j(I)), I;
};
var j = function() {
function I(Z) {
this.updates = [], this.chart = Z;
}
return I.prototype.addUpdate = function(Z) {
this.chart.navigation.updates.push(Z);
}, I.prototype.update = function(Z, H) {
var U = this;
this.updates.forEach(function(F) {
F.call(U.chart, Z, H);
});
}, I;
}();
y.Additions = j;
}(l || (l = {})), l;
}), E(f, "Extensions/Exporting/ExportingDefaults.js", [f["Core/Globals.js"]], function(l) {
return { exporting: { type: "image/png", url: "https://export.highcharts.com/", printMaxWidth: 780, scale: 2, buttons: { contextButton: {
className: "highcharts-contextbutton",
menuClassName: "highcharts-contextmenu",
symbol: "menu",
titleKey: "contextButtonTitle",
menuItems: "viewFullscreen printChart separator downloadPNG downloadJPEG downloadPDF downloadSVG".split(" ")
} }, menuItemDefinitions: { viewFullscreen: { textKey: "viewFullscreen", onclick: function() {
this.fullscreen.toggle();
} }, printChart: { textKey: "printChart", onclick: function() {
this.print();
} }, separator: { separator: !0 }, downloadPNG: { textKey: "downloadPNG", onclick: function() {
this.exportChart();
} }, downloadJPEG: {
textKey: "downloadJPEG",
onclick: function() {
this.exportChart({ type: "image/jpeg" });
}
}, downloadPDF: { textKey: "downloadPDF", onclick: function() {
this.exportChart({ type: "application/pdf" });
} }, downloadSVG: { textKey: "downloadSVG", onclick: function() {
this.exportChart({ type: "image/svg+xml" });
} } } }, lang: {
viewFullscreen: "View in full screen",
exitFullscreen: "Exit from full screen",
printChart: "Print chart",
downloadPNG: "Download PNG image",
downloadJPEG: "Download JPEG image",
downloadPDF: "Download PDF document",
downloadSVG: "Download SVG vector image",
contextButtonTitle: "Chart context menu"
}, navigation: { buttonOptions: { symbolSize: 14, symbolX: 12.5, symbolY: 10.5, align: "right", buttonSpacing: 3, height: 22, verticalAlign: "top", width: 24, symbolFill: "#666666", symbolStroke: "#666666", symbolStrokeWidth: 3, theme: { padding: 5 } }, menuStyle: { border: "1px solid #999999", background: "#ffffff", padding: "5px 0" }, menuItemStyle: { padding: "0.5em 1em", color: "#333333", background: "none", fontSize: l.isTouchDevice ? "14px" : "11px", transition: "background 250ms, color 250ms" }, menuItemHoverStyle: {
background: "#335cad",
color: "#ffffff"
} } };
}), E(f, "Extensions/Exporting/ExportingSymbols.js", [], function() {
var l;
return function(y) {
function j(H, U, F, N) {
return [["M", H, U + 2.5], ["L", H + F, U + 2.5], ["M", H, U + N / 2 + 0.5], ["L", H + F, U + N / 2 + 0.5], ["M", H, U + N - 1.5], ["L", H + F, U + N - 1.5]];
}
function I(H, U, F, N) {
return H = N / 3 - 2, N = [], N = N.concat(this.circle(F - H, U, H, H), this.circle(F - H, U + H + 4, H, H), this.circle(F - H, U + 2 * (H + 4), H, H));
}
var Z = [];
y.compose = function(H) {
Z.indexOf(H) === -1 && (Z.push(H), H = H.prototype.symbols, H.menu = j, H.menuball = I.bind(H));
};
}(l || (l = {})), l;
}), E(f, "Core/HttpUtilities.js", [f["Core/Globals.js"], f["Core/Utilities.js"]], function(l, y) {
var j = l.doc, I = y.createElement, Z = y.discardElement, H = y.merge, U = y.objectEach, F = { ajax: function(N) {
var R = H(!0, { url: !1, type: "get", dataType: "json", success: !1, error: !1, data: !1, headers: {} }, N);
N = { json: "application/json", xml: "application/xml", text: "text/plain", octet: "application/octet-stream" };
var S = new XMLHttpRequest();
if (!R.url)
return !1;
S.open(R.type.toUpperCase(), R.url, !0), R.headers["Content-Type"] || S.setRequestHeader(
"Content-Type",
N[R.dataType] || N.text
), U(R.headers, function(v, d) {
S.setRequestHeader(d, v);
}), S.onreadystatechange = function() {
if (S.readyState === 4) {
if (S.status === 200) {
var v = S.responseText;
if (R.dataType === "json")
try {
v = JSON.parse(v);
} catch (d) {
R.error && R.error(S, d);
return;
}
return R.success && R.success(v);
}
R.error && R.error(S, S.responseText);
}
};
try {
R.data = JSON.stringify(R.data);
} catch {
}
S.send(R.data || !0);
}, getJSON: function(N, R) {
F.ajax({ url: N, success: R, dataType: "json", headers: { "Content-Type": "text/plain" } });
}, post: function(N, R, S) {
var v = I("form", H({ method: "post", action: N, enctype: "multipart/form-data" }, S), { display: "none" }, j.body);
U(R, function(d, u) {
I("input", { type: "hidden", name: u, value: d }, null, v);
}), v.submit(), Z(v);
} };
return F;
}), E(f, "Extensions/Exporting/Exporting.js", [
f["Core/Renderer/HTML/AST.js"],
f["Core/Chart/Chart.js"],
f["Core/Chart/ChartNavigationComposition.js"],
f["Core/DefaultOptions.js"],
f["Extensions/Exporting/ExportingDefaults.js"],
f["Extensions/Exporting/ExportingSymbols.js"],
f["Core/Globals.js"],
f["Core/HttpUtilities.js"],
f["Core/Utilities.js"]
], function(l, y, j, I, Z, H, U, F, N) {
y = I.defaultOptions;
var R = U.doc, S = U.win, v = N.addEvent, d = N.css, u = N.createElement, T = N.discardElement, O = N.extend, B = N.find, C = N.fireEvent, b = N.isObject, w = N.merge, x = N.objectEach, a = N.pick, c = N.removeEvent, p = N.uniqueKey, i;
return function(h) {
function o(nt) {
var rt = this, ct = rt.renderer, gt = w(rt.options.navigation.buttonOptions, nt), dt = gt.onclick, ht = gt.menuItems, at = gt.symbolSize || 12;
if (rt.btnCount || (rt.btnCount = 0), rt.exportDivElements || (rt.exportDivElements = [], rt.exportSVGElements = []), gt.enabled !== !1 && gt.theme) {
var J = gt.theme, tt = J.states, ot = tt && tt.hover;
tt = tt && tt.select;
var lt;
rt.styledMode || (J.fill = a(J.fill, "#ffffff"), J.stroke = a(J.stroke, "none")), delete J.states, dt ? lt = function(vt) {
vt && vt.stopPropagation(), dt.call(rt, vt);
} : ht && (lt = function(vt) {
vt && vt.stopPropagation(), rt.contextMenu(pt.menuClassName, ht, pt.translateX, pt.translateY, pt.width, pt.height, pt), pt.setState(2);
}), gt.text && gt.symbol ? J.paddingLeft = a(J.paddingLeft, 30) : gt.text || O(J, { width: gt.width, height: gt.height, padding: 0 }), rt.styledMode || (J["stroke-linecap"] = "round", J.fill = a(J.fill, "#ffffff"), J.stroke = a(J.stroke, "none"));
var pt = ct.button(gt.text, 0, 0, lt, J, ot, tt).addClass(nt.className).attr({ title: a(rt.options.lang[gt._titleKey || gt.titleKey], "") });
if (pt.menuClassName = nt.menuClassName || "highcharts-menu-" + rt.btnCount++, gt.symbol) {
var yt = ct.symbol(gt.symbol, gt.symbolX - at / 2, gt.symbolY - at / 2, at, at, { width: at, height: at }).addClass("highcharts-button-symbol").attr({ zIndex: 1 }).add(pt);
rt.styledMode || yt.attr({ stroke: gt.symbolStroke, fill: gt.symbolFill, "stroke-width": gt.symbolStrokeWidth || 1 });
}
pt.add(rt.exportingGroup).align(O(
gt,
{ width: pt.width, x: a(gt.x, rt.buttonOffset) }
), !0, "spacingBox"), rt.buttonOffset += (pt.width + gt.buttonSpacing) * (gt.align === "right" ? -1 : 1), rt.exportSVGElements.push(pt, yt);
}
}
function t() {
if (this.printReverseInfo) {
var nt = this.printReverseInfo, rt = nt.childNodes, ct = nt.origDisplay;
nt = nt.resetParams, this.moveContainers(this.renderTo), [].forEach.call(rt, function(gt, dt) {
gt.nodeType === 1 && (gt.style.display = ct[dt] || "");
}), this.isPrinting = !1, nt && this.setSize.apply(this, nt), delete this.printReverseInfo, et = void 0, C(this, "afterPrint");
}
}
function s() {
var nt = R.body, rt = this.options.exporting.printMaxWidth, ct = { childNodes: nt.childNodes, origDisplay: [], resetParams: void 0 };
this.isPrinting = !0, this.pointer.reset(null, 0), C(this, "beforePrint"), rt && this.chartWidth > rt && (ct.resetParams = [this.options.chart.width, void 0, !1], this.setSize(rt, void 0, !1)), [].forEach.call(ct.childNodes, function(gt, dt) {
gt.nodeType === 1 && (ct.origDisplay[dt] = gt.style.display, gt.style.display = "none");
}), this.moveContainers(nt), this.printReverseInfo = ct;
}
function n(nt) {
nt.renderExporting(), v(nt, "redraw", nt.renderExporting), v(nt, "destroy", nt.destroyExport);
}
function A(nt, rt, ct, gt, dt, ht, at) {
var J = this, tt = J.options.navigation, ot = J.chartWidth, lt = J.chartHeight, pt = "cache-" + nt, yt = Math.max(dt, ht), vt = J[pt];
if (!vt) {
J.exportContextMenu = J[pt] = vt = u("div", { className: nt }, { position: "absolute", zIndex: 1e3, padding: yt + "px", pointerEvents: "auto" }, J.fixedDiv || J.container);
var Ct = u("ul", { className: "highcharts-menu" }, { listStyle: "none", margin: 0, padding: 0 }, vt);
J.styledMode || d(Ct, O(
{ MozBoxShadow: "3px 3px 10px #888", WebkitBoxShadow: "3px 3px 10px #888", boxShadow: "3px 3px 10px #888" },
tt.menuStyle
)), vt.hideMenu = function() {
d(vt, { display: "none" }), at && at.setState(0), J.openMenu = !1, d(J.renderTo, { overflow: "hidden" }), d(J.container, { overflow: "hidden" }), N.clearTimeout(vt.hideTimer), C(J, "exportMenuHidden");
}, J.exportEvents.push(v(vt, "mouseleave", function() {
vt.hideTimer = S.setTimeout(vt.hideMenu, 500);
}), v(vt, "mouseenter", function() {
N.clearTimeout(vt.hideTimer);
}), v(R, "mouseup", function(Pt) {
J.pointer.inClass(Pt.target, nt) || vt.hideMenu();
}), v(vt, "click", function() {
J.openMenu && vt.hideMenu();
})), rt.forEach(function(Pt) {
if (typeof Pt == "string" && (Pt = J.options.exporting.menuItemDefinitions[Pt]), b(Pt, !0)) {
var At = void 0;
Pt.separator ? At = u("hr", void 0, void 0, Ct) : (Pt.textKey === "viewData" && J.isDataTableVisible && (Pt.textKey = "hideData"), At = u("li", { className: "highcharts-menu-item", onclick: function(St) {
St && St.stopPropagation(), vt.hideMenu(), Pt.onclick && Pt.onclick.apply(J, arguments);
} }, void 0, Ct), l.setElementHTML(At, Pt.text || J.options.lang[Pt.textKey]), J.styledMode || (At.onmouseover = function() {
d(this, tt.menuItemHoverStyle);
}, At.onmouseout = function() {
d(this, tt.menuItemStyle);
}, d(At, O({ cursor: "pointer" }, tt.menuItemStyle)))), J.exportDivElements.push(At);
}
}), J.exportDivElements.push(Ct, vt), J.exportMenuWidth = vt.offsetWidth, J.exportMenuHeight = vt.offsetHeight;
}
rt = { display: "block" }, ct + J.exportMenuWidth > ot ? rt.right = ot - ct - dt - yt + "px" : rt.left = ct - yt + "px", gt + ht + J.exportMenuHeight > lt && at.alignOptions.verticalAlign !== "top" ? rt.bottom = lt - gt - yt + "px" : rt.top = gt + ht - yt + "px", d(vt, rt), d(J.renderTo, { overflow: "" }), d(J.container, { overflow: "" }), J.openMenu = !0, C(J, "exportMenuShown");
}
function _(nt) {
var rt = nt ? nt.target : this, ct = rt.exportSVGElements, gt = rt.exportDivElements;
nt = rt.exportEvents;
var dt;
ct && (ct.forEach(function(ht, at) {
ht && (ht.onclick = ht.ontouchstart = null, dt = "cache-" + ht.menuClassName, rt[dt] && delete rt[dt], ct[at] = ht.destroy());
}), ct.length = 0), rt.exportingGroup && (rt.exportingGroup.destroy(), delete rt.exportingGroup), gt && (gt.forEach(function(ht, at) {
ht && (N.clearTimeout(ht.hideTimer), c(ht, "mouseleave"), gt[at] = ht.onmouseout = ht.onmouseover = ht.ontouchstart = ht.onclick = null, T(ht));
}), gt.length = 0), nt && (nt.forEach(function(ht) {
ht();
}), nt.length = 0);
}
function D(nt, rt) {
rt = this.getSVGForExport(nt, rt), nt = w(this.options.exporting, nt), F.post(nt.url, { filename: nt.filename ? nt.filename.replace(/\//g, "-") : this.getFilename(), type: nt.type, width: nt.width || 0, scale: nt.scale, svg: rt }, nt.formAttributes);
}
function W() {
return this.styledMode && this.inlineStyles(), this.container.innerHTML;
}
function P() {
var nt = this.userOptions.title && this.userOptions.title.text, rt = this.options.exporting.filename;
return rt ? rt.replace(/\//g, "-") : (typeof nt == "string" && (rt = nt.toLowerCase().replace(/<\/?[^>]+(>|$)/g, "").replace(/[\s_]+/g, "-").replace(
/[^a-z0-9\-]/g,
""
).replace(/^[\-]+/g, "").replace(/[\-]+/g, "-").substr(0, 24).replace(/[\-]+$/g, "")), (!rt || 5 > rt.length) && (rt = "chart"), rt);
}
function X(nt) {
var rt, ct = w(this.options, nt);
ct.plotOptions = w(this.userOptions.plotOptions, nt && nt.plotOptions), ct.time = w(this.userOptions.time, nt && nt.time);
var gt = u("div", null, { position: "absolute", top: "-9999em", width: this.chartWidth + "px", height: this.chartHeight + "px" }, R.body), dt = this.renderTo.style.width, ht = this.renderTo.style.height;
dt = ct.exporting.sourceWidth || ct.chart.width || /px$/.test(dt) && parseInt(dt, 10) || (ct.isGantt ? 800 : 600), ht = ct.exporting.sourceHeight || ct.chart.height || /px$/.test(ht) && parseInt(ht, 10) || 400, O(ct.chart, { animation: !1, renderTo: gt, forExport: !0, renderer: "SVGRenderer", width: dt, height: ht }), ct.exporting.enabled = !1, delete ct.data, ct.series = [], this.series.forEach(function(tt) {
rt = w(tt.userOptions, { animation: !1, enableMouseTracking: !1, showCheckbox: !1, visible: tt.visible }), rt.isInternal || ct.series.push(rt);
});
var at = {};
this.axes.forEach(function(tt) {
tt.userOptions.internalKey || (tt.userOptions.internalKey = p()), tt.options.isInternal || (at[tt.coll] || (at[tt.coll] = !0, ct[tt.coll] = []), ct[tt.coll].push(w(tt.userOptions, { visible: tt.visible })));
});
var J = new this.constructor(ct, this.callback);
return nt && ["xAxis", "yAxis", "series"].forEach(function(tt) {
var ot = {};
nt[tt] && (ot[tt] = nt[tt], J.update(ot));
}), this.axes.forEach(function(tt) {
var ot = B(J.axes, function(yt) {
return yt.options.internalKey === tt.userOptions.internalKey;
}), lt = tt.getExtremes(), pt = lt.userMin;
lt = lt.userMax, ot && (typeof pt < "u" && pt !== ot.min || typeof lt < "u" && lt !== ot.max) && ot.setExtremes(
pt,
lt,
!0,
!1
);
}), ht = J.getChartHTML(), C(this, "getSVG", { chartCopy: J }), ht = this.sanitizeSVG(ht, ct), ct = null, J.destroy(), T(gt), ht;
}
function g(nt, rt) {
var ct = this.options.exporting;
return this.getSVG(w({ chart: { borderRadius: 0 } }, ct.chartOptions, rt, { exporting: { sourceWidth: nt && nt.sourceWidth || ct.sourceWidth, sourceHeight: nt && nt.sourceHeight || ct.sourceHeight } }));
}
function m(nt) {
return nt.replace(/([A-Z])/g, function(rt, ct) {
return "-" + ct.toLowerCase();
});
}
function L() {
function nt(J) {
function tt(St, Dt) {
if (lt = pt = !1, ct.length) {
for (yt = ct.length; yt-- && !pt; )
pt = ct[yt].test(Dt);
lt = !pt;
}
for (Dt === "transform" && St === "none" && (lt = !0), yt = rt.length; yt-- && !lt; )
lt = rt[yt].test(Dt) || typeof St == "function";
lt || Ct[Dt] === St && J.nodeName !== "svg" || gt[J.nodeName][Dt] === St || (q && q.indexOf(Dt) === -1 ? ot += m(Dt) + ":" + St + ";" : St && J.setAttribute(m(Dt), St));
}
var ot = "", lt, pt, yt;
if (J.nodeType === 1 && it.indexOf(J.nodeName) === -1) {
var vt = S.getComputedStyle(J, null), Ct = J.nodeName === "svg" ? {} : S.getComputedStyle(J.parentNode, null);
if (!gt[J.nodeName]) {
dt = at.getElementsByTagName("svg")[0];
var Pt = at.createElementNS(J.namespaceURI, J.nodeName);
dt.appendChild(Pt), gt[J.nodeName] = w(S.getComputedStyle(Pt, null)), J.nodeName === "text" && delete gt.text.fill, dt.removeChild(Pt);
}
if (U.isFirefox || U.isMS)
for (var At in vt)
tt(vt[At], At);
else
x(vt, tt);
ot && (vt = J.getAttribute("style"), J.setAttribute("style", (vt ? vt + ";" : "") + ot)), J.nodeName === "svg" && J.setAttribute("stroke-width", "1px"), J.nodeName !== "text" && [].forEach.call(J.children || J.childNodes, nt);
}
}
var rt = $, ct = h.inlineWhitelist, gt = {}, dt, ht = R.createElement("iframe");
d(ht, { width: "1px", height: "1px", visibility: "hidden" }), R.body.appendChild(ht);
var at = ht.contentWindow.document;
at.open(), at.write(''), at.close(), nt(this.container.querySelector("svg")), dt.parentNode.removeChild(dt), ht.parentNode.removeChild(ht);
}
function Y(nt) {
(this.fixedDiv ? [this.fixedDiv, this.scrollingContainer] : [this.container]).forEach(function(rt) {
nt.appendChild(rt);
});
}
function V() {
var nt = this;
nt.exporting = { update: function(rt, ct) {
nt.isDirtyExporting = !0, w(!0, nt.options.exporting, rt), a(ct, !0) && nt.redraw();
} }, j.compose(nt).navigation.addUpdate(function(rt, ct) {
nt.isDirtyExporting = !0, w(!0, nt.options.navigation, rt), a(ct, !0) && nt.redraw();
});
}
function Q() {
var nt = this;
nt.isPrinting || (et = nt, U.isSafari || nt.beforePrint(), setTimeout(function() {
S.focus(), S.print(), U.isSafari || setTimeout(function() {
nt.afterPrint();
}, 1e3);
}, 1));
}
function k() {
var nt = this, rt = nt.options.exporting, ct = rt.buttons, gt = nt.isDirtyExporting || !nt.exportSVGElements;
nt.buttonOffset = 0, nt.isDirtyExporting && nt.destroyExport(), gt && rt.enabled !== !1 && (nt.exportEvents = [], nt.exportingGroup = nt.exportingGroup || nt.renderer.g("exporting-group").attr({ zIndex: 3 }).add(), x(ct, function(dt) {
nt.addButton(dt);
}), nt.isDirtyExporting = !1);
}
function G(nt, rt) {
var ct = nt.indexOf("") + 6, gt = nt.substr(ct);
return nt = nt.substr(0, ct), rt && rt.exporting && rt.exporting.allowHTML && gt && (gt = '' + gt.replace(/(<(?:img|br).*?(?=>))>/g, "$1 />") + "", nt = nt.replace("", gt + "")), nt = nt.replace(/zIndex="[^"]+"/g, "").replace(/symbolName="[^"]+"/g, "").replace(
/jQuery[0-9]+="[^"]+"/g,
""
).replace(/url\(("|")(.*?)("|");?\)/g, "url($2)").replace(/url\([^#]+#/g, "url(#").replace(/