cosmic-ai-genius 0.3.54 → 0.3.55

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -105,7 +105,7 @@ Please report this to https://github.com/markedjs/marked.`,t){const r="<p>An err
105
105
  `,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:T,table:h,tableCell:m,tableRow:p}};function h(k,C,G,ne){return v(x(k,G,ne),k.align)}function p(k,C,G,ne){const $=_(k,G,ne),L=v([$]);return L.slice(0,L.indexOf(`
106
106
  `))}function m(k,C,G,ne){const $=G.enter("tableCell"),L=G.enter("phrasing"),B=G.containerPhrasing(k,{...ne,before:u,after:u});return L(),$(),B}function v(k,C){return qO(k,{align:C,alignDelimiters:r,padding:a,stringLength:c})}function x(k,C,G){const ne=k.children;let $=-1;const L=[],B=C.enter("table");for(;++$<ne.length;)L[$]=_(ne[$],C,G);return B(),L}function _(k,C,G){const ne=k.children;let $=-1;const L=[],B=C.enter("tableRow");for(;++$<ne.length;)L[$]=m(ne[$],k,C,G);return B(),L}function T(k,C,G){let ne=A3.inlineCode(k,C,G);return G.stack.includes("tableCell")&&(ne=ne.replace(/\|/g,"\\$&")),ne}}function Lj(){return{exit:{taskListCheckValueChecked:M3,taskListCheckValueUnchecked:M3,paragraph:Nj}}}function Rj(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:zj}}}function M3(t){const n=this.stack[this.stack.length-2];n.type,n.checked=t.type==="taskListCheckValueChecked"}function Nj(t){const n=this.stack[this.stack.length-2];if(n&&n.type==="listItem"&&typeof n.checked=="boolean"){const a=this.stack[this.stack.length-1];a.type;const r=a.children[0];if(r&&r.type==="text"){const c=n.children;let u=-1,h;for(;++u<c.length;){const p=c[u];if(p.type==="paragraph"){h=p;break}}h===a&&(r.value=r.value.slice(1),r.value.length===0?a.children.shift():a.position&&r.position&&typeof r.position.start.offset=="number"&&(r.position.start.column++,r.position.start.offset++,a.position.start=Object.assign({},r.position.start)))}}this.exit(t)}function zj(t,n,a,r){const c=t.children[0],u=typeof t.checked=="boolean"&&c&&c.type==="paragraph",h="["+(t.checked?"x":" ")+"] ",p=a.createTracker(r);u&&p.move(h);let m=A3.listItem(t,n,a,{...r,...p.current()});return u&&(m=m.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,v)),m;function v(x){return x+h}}function Bj(){return[gO(),zO(),HO(),Tj(),Lj()]}function Uj(t){return{extensions:[mO(),BO(t),IO(),jj(t),Rj()]}}const Pj={tokenize:Fj,partial:!0},D3={tokenize:qj,partial:!0},O3={tokenize:Yj,partial:!0},j3={tokenize:Xj,partial:!0},Hj={tokenize:Wj,partial:!0},L3={name:"wwwAutolink",tokenize:Vj,previous:N3},R3={name:"protocolAutolink",tokenize:$j,previous:z3},dc={name:"emailAutolink",tokenize:Gj,previous:B3},gl={};function Ij(){return{text:gl}}let Zd=48;for(;Zd<123;)gl[Zd]=dc,Zd++,Zd===58?Zd=65:Zd===91&&(Zd=97);gl[43]=dc,gl[45]=dc,gl[46]=dc,gl[95]=dc,gl[72]=[dc,R3],gl[104]=[dc,R3],gl[87]=[dc,L3],gl[119]=[dc,L3];function Gj(t,n,a){const r=this;let c,u;return h;function h(_){return!mS(_)||!B3.call(r,r.previous)||yS(r.events)?a(_):(t.enter("literalAutolink"),t.enter("literalAutolinkEmail"),p(_))}function p(_){return mS(_)?(t.consume(_),p):_===64?(t.consume(_),m):a(_)}function m(_){return _===46?t.check(Hj,x,v)(_):_===45||_===95||ts(_)?(u=!0,t.consume(_),m):x(_)}function v(_){return t.consume(_),c=!0,m}function x(_){return u&&c&&xs(r.previous)?(t.exit("literalAutolinkEmail"),t.exit("literalAutolink"),n(_)):a(_)}}function Vj(t,n,a){const r=this;return c;function c(h){return h!==87&&h!==119||!N3.call(r,r.previous)||yS(r.events)?a(h):(t.enter("literalAutolink"),t.enter("literalAutolinkWww"),t.check(Pj,t.attempt(D3,t.attempt(O3,u),a),a)(h))}function u(h){return t.exit("literalAutolinkWww"),t.exit("literalAutolink"),n(h)}}function $j(t,n,a){const r=this;let c="",u=!1;return h;function h(_){return(_===72||_===104)&&z3.call(r,r.previous)&&!yS(r.events)?(t.enter("literalAutolink"),t.enter("literalAutolinkHttp"),c+=String.fromCodePoint(_),t.consume(_),p):a(_)}function p(_){if(xs(_)&&c.length<5)return c+=String.fromCodePoint(_),t.consume(_),p;if(_===58){const T=c.toLowerCase();if(T==="http"||T==="https")return t.consume(_),m}return a(_)}function m(_){return _===47?(t.consume(_),u?v:(u=!0,m)):a(_)}function v(_){return _===null||ub(_)||yi(_)||Wd(_)||db(_)?a(_):t.attempt(D3,t.attempt(O3,x),a)(_)}function x(_){return t.exit("literalAutolinkHttp"),t.exit("literalAutolink"),n(_)}}function Fj(t,n,a){let r=0;return c;function c(h){return(h===87||h===119)&&r<3?(r++,t.consume(h),c):h===46&&r===3?(t.consume(h),u):a(h)}function u(h){return h===null?a(h):n(h)}}function qj(t,n,a){let r,c,u;return h;function h(v){return v===46||v===95?t.check(j3,m,p)(v):v===null||yi(v)||Wd(v)||v!==45&&db(v)?m(v):(u=!0,t.consume(v),h)}function p(v){return v===95?r=!0:(c=r,r=void 0),t.consume(v),h}function m(v){return c||r||!u?a(v):n(v)}}function Yj(t,n){let a=0,r=0;return c;function c(h){return h===40?(a++,t.consume(h),c):h===41&&r<a?u(h):h===33||h===34||h===38||h===39||h===41||h===42||h===44||h===46||h===58||h===59||h===60||h===63||h===93||h===95||h===126?t.check(j3,n,u)(h):h===null||yi(h)||Wd(h)?n(h):(t.consume(h),c)}function u(h){return h===41&&r++,t.consume(h),c}}function Xj(t,n,a){return r;function r(p){return p===33||p===34||p===39||p===41||p===42||p===44||p===46||p===58||p===59||p===63||p===95||p===126?(t.consume(p),r):p===38?(t.consume(p),u):p===93?(t.consume(p),c):p===60||p===null||yi(p)||Wd(p)?n(p):a(p)}function c(p){return p===null||p===40||p===91||yi(p)||Wd(p)?n(p):r(p)}function u(p){return xs(p)?h(p):a(p)}function h(p){return p===59?(t.consume(p),r):xs(p)?(t.consume(p),h):a(p)}}function Wj(t,n,a){return r;function r(u){return t.consume(u),c}function c(u){return ts(u)?a(u):n(u)}}function N3(t){return t===null||t===40||t===42||t===95||t===91||t===93||t===126||yi(t)}function z3(t){return!xs(t)}function B3(t){return!(t===47||mS(t))}function mS(t){return t===43||t===45||t===46||t===95||ts(t)}function yS(t){let n=t.length,a=!1;for(;n--;){const r=t[n][1];if((r.type==="labelLink"||r.type==="labelImage")&&!r._balanced){a=!0;break}if(r._gfmAutolinkLiteralWalkedInto){a=!1;break}}return t.length>0&&!a&&(t[t.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),a}const Zj={tokenize:aL,partial:!0};function Qj(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:tL,continuation:{tokenize:nL},exit:iL}},text:{91:{name:"gfmFootnoteCall",tokenize:eL},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:Kj,resolveTo:Jj}}}}function Kj(t,n,a){const r=this;let c=r.events.length;const u=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let h;for(;c--;){const m=r.events[c][1];if(m.type==="labelImage"){h=m;break}if(m.type==="gfmFootnoteCall"||m.type==="labelLink"||m.type==="label"||m.type==="image"||m.type==="link")break}return p;function p(m){if(!h||!h._balanced)return a(m);const v=Oo(r.sliceSerialize({start:h.end,end:r.now()}));return v.codePointAt(0)!==94||!u.includes(v.slice(1))?a(m):(t.enter("gfmFootnoteCallLabelMarker"),t.consume(m),t.exit("gfmFootnoteCallLabelMarker"),n(m))}}function Jj(t,n){let a=t.length;for(;a--;)if(t[a][1].type==="labelImage"&&t[a][0]==="enter"){t[a][1];break}t[a+1][1].type="data",t[a+3][1].type="gfmFootnoteCallLabelMarker";const r={type:"gfmFootnoteCall",start:Object.assign({},t[a+3][1].start),end:Object.assign({},t[t.length-1][1].end)},c={type:"gfmFootnoteCallMarker",start:Object.assign({},t[a+3][1].end),end:Object.assign({},t[a+3][1].end)};c.end.column++,c.end.offset++,c.end._bufferIndex++;const u={type:"gfmFootnoteCallString",start:Object.assign({},c.end),end:Object.assign({},t[t.length-1][1].start)},h={type:"chunkString",contentType:"string",start:Object.assign({},u.start),end:Object.assign({},u.end)},p=[t[a+1],t[a+2],["enter",r,n],t[a+3],t[a+4],["enter",c,n],["exit",c,n],["enter",u,n],["enter",h,n],["exit",h,n],["exit",u,n],t[t.length-2],t[t.length-1],["exit",r,n]];return t.splice(a,t.length-a+1,...p),t}function eL(t,n,a){const r=this,c=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let u=0,h;return p;function p(_){return t.enter("gfmFootnoteCall"),t.enter("gfmFootnoteCallLabelMarker"),t.consume(_),t.exit("gfmFootnoteCallLabelMarker"),m}function m(_){return _!==94?a(_):(t.enter("gfmFootnoteCallMarker"),t.consume(_),t.exit("gfmFootnoteCallMarker"),t.enter("gfmFootnoteCallString"),t.enter("chunkString").contentType="string",v)}function v(_){if(u>999||_===93&&!h||_===null||_===91||yi(_))return a(_);if(_===93){t.exit("chunkString");const T=t.exit("gfmFootnoteCallString");return c.includes(Oo(r.sliceSerialize(T)))?(t.enter("gfmFootnoteCallLabelMarker"),t.consume(_),t.exit("gfmFootnoteCallLabelMarker"),t.exit("gfmFootnoteCall"),n):a(_)}return yi(_)||(h=!0),u++,t.consume(_),_===92?x:v}function x(_){return _===91||_===92||_===93?(t.consume(_),u++,v):v(_)}}function tL(t,n,a){const r=this,c=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let u,h=0,p;return m;function m(C){return t.enter("gfmFootnoteDefinition")._container=!0,t.enter("gfmFootnoteDefinitionLabel"),t.enter("gfmFootnoteDefinitionLabelMarker"),t.consume(C),t.exit("gfmFootnoteDefinitionLabelMarker"),v}function v(C){return C===94?(t.enter("gfmFootnoteDefinitionMarker"),t.consume(C),t.exit("gfmFootnoteDefinitionMarker"),t.enter("gfmFootnoteDefinitionLabelString"),t.enter("chunkString").contentType="string",x):a(C)}function x(C){if(h>999||C===93&&!p||C===null||C===91||yi(C))return a(C);if(C===93){t.exit("chunkString");const G=t.exit("gfmFootnoteDefinitionLabelString");return u=Oo(r.sliceSerialize(G)),t.enter("gfmFootnoteDefinitionLabelMarker"),t.consume(C),t.exit("gfmFootnoteDefinitionLabelMarker"),t.exit("gfmFootnoteDefinitionLabel"),T}return yi(C)||(p=!0),h++,t.consume(C),C===92?_:x}function _(C){return C===91||C===92||C===93?(t.consume(C),h++,x):x(C)}function T(C){return C===58?(t.enter("definitionMarker"),t.consume(C),t.exit("definitionMarker"),c.includes(u)||c.push(u),$n(t,k,"gfmFootnoteDefinitionWhitespace")):a(C)}function k(C){return n(C)}}function nL(t,n,a){return t.check($m,n,t.attempt(Zj,n,a))}function iL(t){t.exit("gfmFootnoteDefinition")}function aL(t,n,a){const r=this;return $n(t,c,"gfmFootnoteDefinitionIndent",5);function c(u){const h=r.events[r.events.length-1];return h&&h[1].type==="gfmFootnoteDefinitionIndent"&&h[2].sliceSerialize(h[1],!0).length===4?n(u):a(u)}}function sL(t){let a=(t||{}).singleTilde;const r={name:"strikethrough",tokenize:u,resolveAll:c};return a==null&&(a=!0),{text:{126:r},insideSpan:{null:[r]},attentionMarkers:{null:[126]}};function c(h,p){let m=-1;for(;++m<h.length;)if(h[m][0]==="enter"&&h[m][1].type==="strikethroughSequenceTemporary"&&h[m][1]._close){let v=m;for(;v--;)if(h[v][0]==="exit"&&h[v][1].type==="strikethroughSequenceTemporary"&&h[v][1]._open&&h[m][1].end.offset-h[m][1].start.offset===h[v][1].end.offset-h[v][1].start.offset){h[m][1].type="strikethroughSequence",h[v][1].type="strikethroughSequence";const x={type:"strikethrough",start:Object.assign({},h[v][1].start),end:Object.assign({},h[m][1].end)},_={type:"strikethroughText",start:Object.assign({},h[v][1].end),end:Object.assign({},h[m][1].start)},T=[["enter",x,p],["enter",h[v][1],p],["exit",h[v][1],p],["enter",_,p]],k=p.parser.constructs.insideSpan.null;k&&hr(T,T.length,0,hb(k,h.slice(v+1,m),p)),hr(T,T.length,0,[["exit",_,p],["enter",h[m][1],p],["exit",h[m][1],p],["exit",x,p]]),hr(h,v-1,m-v+3,T),m=v+T.length-2;break}}for(m=-1;++m<h.length;)h[m][1].type==="strikethroughSequenceTemporary"&&(h[m][1].type="data");return h}function u(h,p,m){const v=this.previous,x=this.events;let _=0;return T;function T(C){return v===126&&x[x.length-1][1].type!=="characterEscape"?m(C):(h.enter("strikethroughSequenceTemporary"),k(C))}function k(C){const G=Jf(v);if(C===126)return _>1?m(C):(h.consume(C),_++,k);if(_<2&&!a)return m(C);const ne=h.exit("strikethroughSequenceTemporary"),$=Jf(C);return ne._open=!$||$===2&&!!G,ne._close=!G||G===2&&!!$,p(C)}}}class rL{constructor(){this.map=[]}add(n,a,r){oL(this,n,a,r)}consume(n){if(this.map.sort(function(u,h){return u[0]-h[0]}),this.map.length===0)return;let a=this.map.length;const r=[];for(;a>0;)a-=1,r.push(n.slice(this.map[a][0]+this.map[a][1]),this.map[a][2]),n.length=this.map[a][0];r.push(n.slice()),n.length=0;let c=r.pop();for(;c;){for(const u of c)n.push(u);c=r.pop()}this.map.length=0}}function oL(t,n,a,r){let c=0;if(!(a===0&&r.length===0)){for(;c<t.map.length;){if(t.map[c][0]===n){t.map[c][1]+=a,t.map[c][2].push(...r);return}c+=1}t.map.push([n,a,r])}}function lL(t,n){let a=!1;const r=[];for(;n<t.length;){const c=t[n];if(a){if(c[0]==="enter")c[1].type==="tableContent"&&r.push(t[n+1][1].type==="tableDelimiterMarker"?"left":"none");else if(c[1].type==="tableContent"){if(t[n-1][1].type==="tableDelimiterMarker"){const u=r.length-1;r[u]=r[u]==="left"?"center":"right"}}else if(c[1].type==="tableDelimiterRow")break}else c[0]==="enter"&&c[1].type==="tableDelimiterRow"&&(a=!0);n+=1}return r}function cL(){return{flow:{null:{name:"table",tokenize:uL,resolveAll:dL}}}}function uL(t,n,a){const r=this;let c=0,u=0,h;return p;function p(I){let H=r.events.length-1;for(;H>-1;){const E=r.events[H][1].type;if(E==="lineEnding"||E==="linePrefix")H--;else break}const Q=H>-1?r.events[H][1].type:null,F=Q==="tableHead"||Q==="tableRow"?U:m;return F===U&&r.parser.lazy[r.now().line]?a(I):F(I)}function m(I){return t.enter("tableHead"),t.enter("tableRow"),v(I)}function v(I){return I===124||(h=!0,u+=1),x(I)}function x(I){return I===null?a(I):tn(I)?u>1?(u=0,r.interrupt=!0,t.exit("tableRow"),t.enter("lineEnding"),t.consume(I),t.exit("lineEnding"),k):a(I):Rn(I)?$n(t,x,"whitespace")(I):(u+=1,h&&(h=!1,c+=1),I===124?(t.enter("tableCellDivider"),t.consume(I),t.exit("tableCellDivider"),h=!0,x):(t.enter("data"),_(I)))}function _(I){return I===null||I===124||yi(I)?(t.exit("data"),x(I)):(t.consume(I),I===92?T:_)}function T(I){return I===92||I===124?(t.consume(I),_):_(I)}function k(I){return r.interrupt=!1,r.parser.lazy[r.now().line]?a(I):(t.enter("tableDelimiterRow"),h=!1,Rn(I)?$n(t,C,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(I):C(I))}function C(I){return I===45||I===58?ne(I):I===124?(h=!0,t.enter("tableCellDivider"),t.consume(I),t.exit("tableCellDivider"),G):X(I)}function G(I){return Rn(I)?$n(t,ne,"whitespace")(I):ne(I)}function ne(I){return I===58?(u+=1,h=!0,t.enter("tableDelimiterMarker"),t.consume(I),t.exit("tableDelimiterMarker"),$):I===45?(u+=1,$(I)):I===null||tn(I)?Y(I):X(I)}function $(I){return I===45?(t.enter("tableDelimiterFiller"),L(I)):X(I)}function L(I){return I===45?(t.consume(I),L):I===58?(h=!0,t.exit("tableDelimiterFiller"),t.enter("tableDelimiterMarker"),t.consume(I),t.exit("tableDelimiterMarker"),B):(t.exit("tableDelimiterFiller"),B(I))}function B(I){return Rn(I)?$n(t,Y,"whitespace")(I):Y(I)}function Y(I){return I===124?C(I):I===null||tn(I)?!h||c!==u?X(I):(t.exit("tableDelimiterRow"),t.exit("tableHead"),n(I)):X(I)}function X(I){return a(I)}function U(I){return t.enter("tableRow"),Z(I)}function Z(I){return I===124?(t.enter("tableCellDivider"),t.consume(I),t.exit("tableCellDivider"),Z):I===null||tn(I)?(t.exit("tableRow"),n(I)):Rn(I)?$n(t,Z,"whitespace")(I):(t.enter("data"),ce(I))}function ce(I){return I===null||I===124||yi(I)?(t.exit("data"),Z(I)):(t.consume(I),I===92?se:ce)}function se(I){return I===92||I===124?(t.consume(I),ce):ce(I)}}function dL(t,n){let a=-1,r=!0,c=0,u=[0,0,0,0],h=[0,0,0,0],p=!1,m=0,v,x,_;const T=new rL;for(;++a<t.length;){const k=t[a],C=k[1];k[0]==="enter"?C.type==="tableHead"?(p=!1,m!==0&&(U3(T,n,m,v,x),x=void 0,m=0),v={type:"table",start:Object.assign({},C.start),end:Object.assign({},C.end)},T.add(a,0,[["enter",v,n]])):C.type==="tableRow"||C.type==="tableDelimiterRow"?(r=!0,_=void 0,u=[0,0,0,0],h=[0,a+1,0,0],p&&(p=!1,x={type:"tableBody",start:Object.assign({},C.start),end:Object.assign({},C.end)},T.add(a,0,[["enter",x,n]])),c=C.type==="tableDelimiterRow"?2:x?3:1):c&&(C.type==="data"||C.type==="tableDelimiterMarker"||C.type==="tableDelimiterFiller")?(r=!1,h[2]===0&&(u[1]!==0&&(h[0]=h[1],_=wb(T,n,u,c,void 0,_),u=[0,0,0,0]),h[2]=a)):C.type==="tableCellDivider"&&(r?r=!1:(u[1]!==0&&(h[0]=h[1],_=wb(T,n,u,c,void 0,_)),u=h,h=[u[1],a,0,0])):C.type==="tableHead"?(p=!0,m=a):C.type==="tableRow"||C.type==="tableDelimiterRow"?(m=a,u[1]!==0?(h[0]=h[1],_=wb(T,n,u,c,a,_)):h[1]!==0&&(_=wb(T,n,h,c,a,_)),c=0):c&&(C.type==="data"||C.type==="tableDelimiterMarker"||C.type==="tableDelimiterFiller")&&(h[3]=a)}for(m!==0&&U3(T,n,m,v,x),T.consume(n.events),a=-1;++a<n.events.length;){const k=n.events[a];k[0]==="enter"&&k[1].type==="table"&&(k[1]._align=lL(n.events,a))}return t}function wb(t,n,a,r,c,u){const h=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",p="tableContent";a[0]!==0&&(u.end=Object.assign({},tp(n.events,a[0])),t.add(a[0],0,[["exit",u,n]]));const m=tp(n.events,a[1]);if(u={type:h,start:Object.assign({},m),end:Object.assign({},m)},t.add(a[1],0,[["enter",u,n]]),a[2]!==0){const v=tp(n.events,a[2]),x=tp(n.events,a[3]),_={type:p,start:Object.assign({},v),end:Object.assign({},x)};if(t.add(a[2],0,[["enter",_,n]]),r!==2){const T=n.events[a[2]],k=n.events[a[3]];if(T[1].end=Object.assign({},k[1].end),T[1].type="chunkText",T[1].contentType="text",a[3]>a[2]+1){const C=a[2]+1,G=a[3]-a[2]-1;t.add(C,G,[])}}t.add(a[3]+1,0,[["exit",_,n]])}return c!==void 0&&(u.end=Object.assign({},tp(n.events,c)),t.add(c,0,[["exit",u,n]]),u=void 0),u}function U3(t,n,a,r,c){const u=[],h=tp(n.events,a);c&&(c.end=Object.assign({},h),u.push(["exit",c,n])),r.end=Object.assign({},h),u.push(["exit",r,n]),t.add(a+1,0,u)}function tp(t,n){const a=t[n],r=a[0]==="enter"?"start":"end";return a[1][r]}const hL={name:"tasklistCheck",tokenize:pL};function fL(){return{text:{91:hL}}}function pL(t,n,a){const r=this;return c;function c(m){return r.previous!==null||!r._gfmTasklistFirstContentOfListItem?a(m):(t.enter("taskListCheck"),t.enter("taskListCheckMarker"),t.consume(m),t.exit("taskListCheckMarker"),u)}function u(m){return yi(m)?(t.enter("taskListCheckValueUnchecked"),t.consume(m),t.exit("taskListCheckValueUnchecked"),h):m===88||m===120?(t.enter("taskListCheckValueChecked"),t.consume(m),t.exit("taskListCheckValueChecked"),h):a(m)}function h(m){return m===93?(t.enter("taskListCheckMarker"),t.consume(m),t.exit("taskListCheckMarker"),t.exit("taskListCheck"),p):a(m)}function p(m){return tn(m)?n(m):Rn(m)?t.check({tokenize:gL},n,a)(m):a(m)}}function gL(t,n,a){return $n(t,r,"whitespace");function r(c){return c===null?a(c):n(c)}}function mL(t){return bk([Ij(),Qj(),sL(t),cL(),fL()])}const yL={};function P3(t){const n=this,a=t||yL,r=n.data(),c=r.micromarkExtensions||(r.micromarkExtensions=[]),u=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),h=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);c.push(mL(a)),u.push(Bj()),h.push(Uj(a))}const nt={"genius-dashboard-backdrop":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-backdrop___1dyxh",visible:"genius-sdk__GeniusChatbotDashboard-module__visible___ojnlM","genius-dashboard-container":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-container___PGPHW",expanded:"genius-sdk__GeniusChatbotDashboard-module__expanded___ngt3H","genius-dashboard-input-container":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-input-container___UTRzH","single-line":"genius-sdk__GeniusChatbotDashboard-module__single-line___VKYFP","genius-dashboard-input":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-input___IImk1","genius-dashboard-top-bar":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-top-bar___3z76Q","genius-dashboard-icons-left":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-icons-left___22uJz","genius-dashboard-icons-right":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-icons-right___C5UjC","genius-dashboard-icon-container":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-icon-container___4dRqI","with-text":"genius-sdk__GeniusChatbotDashboard-module__with-text___skVCO","genius-dashboard-back-text":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-back-text___Od1bW","genius-dashboard-body":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-body___EdY34","genius-dashboard-conversation":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-conversation___JTOaq","genius-dashboard-branding":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-branding___7PzdS","genius-dashboard-logo-container":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-logo-container___zHKb3","genius-dashboard-logo":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-logo___oWWc4","genius-dashboard-welcome":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-welcome___ee72M","genius-dashboard-suggestions":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-suggestions___ZcAU8","genius-dashboard-suggestion":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-suggestion___JFR-a","genius-dashboard-input-area":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-input-area___ofUbJ","genius-dashboard-input-actions":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-input-actions___YK8kC","genius-dashboard-attachment-button":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-attachment-button___pbzwc","genius-dashboard-voice-container":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-voice-container___B-AOf","genius-dashboard-microphone-button":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-microphone-button___lZ7h0","genius-dashboard-send-button":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-send-button___fLXEm","genius-dashboard-cancel-button":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-cancel-button___kn9Lg","genius-dashboard-retry-button":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-retry-button___5oreu","genius-dashboard-send-retry-container":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-send-retry-container___yxRGt","genius-dashboard-security-info":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-security-info___VwRHO","genius-dashboard-messages-container":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-messages-container___8m6PY","genius-dashboard-scroll-button":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-scroll-button___YMYFi","genius-dashboard-message":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-message___CaZzW",user:"genius-sdk__GeniusChatbotDashboard-module__user___5X16B","genius-dashboard-message-bubble":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-message-bubble___Dq5Eg","genius-dashboard-message-content":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-message-content___oTid5",assistant:"genius-sdk__GeniusChatbotDashboard-module__assistant___t65-b","genius-dashboard-thinking":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-thinking___ceEhk","genius-dashboard-assistant-icon":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-assistant-icon___urK-s",ellipsis:"genius-sdk__GeniusChatbotDashboard-module__ellipsis___kKDif","genius-dashboard-markdown-content":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-markdown-content___ibLAo","genius-dashboard-table-wrapper":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-table-wrapper___zVypd","genius-dashboard-markdown-table":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-markdown-table___C1je4","genius-dashboard-voice-wrapper":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-voice-wrapper___n9Jj1","genius-dashboard-voice-recording-container":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-voice-recording-container___GiftZ","genius-dashboard-voice-button":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-voice-button___-NShR","genius-dashboard-voice-controls":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-voice-controls___P235l","voice-active":"genius-sdk__GeniusChatbotDashboard-module__voice-active___qB2ym","genius-dashboard-history-overlay":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-history-overlay___zDkbs","genius-dashboard-history-container":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-history-container___ecQs7","genius-dashboard-history-header":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-history-header___zjLS-","genius-dashboard-history-header-left":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-history-header-left___mWOQO","genius-dashboard-history-back":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-history-back___ELQ0K","genius-dashboard-history-actions":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-history-actions___lqL15","genius-dashboard-history-action":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-history-action___-ug8n","genius-dashboard-history-list":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-history-list___7jHy4","genius-dashboard-history-item":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-history-item___XW2rl","genius-dashboard-history-item-content":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-history-item-content___feueq","genius-dashboard-history-item-title":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-history-item-title___YJNj8","genius-dashboard-history-item-date":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-history-item-date___dlGyR","genius-dashboard-single-stat-card":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-single-stat-card___v4WS2","genius-dashboard-single-stat-title":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-single-stat-title___yod6C","genius-dashboard-single-stat-value":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-single-stat-value___Hyo-h","genius-dashboard-table-container":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-table-container___FxxTR","genius-dashboard-table":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-table___wpMRb","genius-dashboard-table-head":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-table-head___rdA-0","genius-dashboard-table-head-row":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-table-head-row___VpPSu","genius-dashboard-table-head-cell":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-table-head-cell___8eVeo","genius-dashboard-table-head-content":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-table-head-content___CwrnG","genius-dashboard-table-body":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-table-body___bElU6","genius-dashboard-table-row":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-table-row___ko-q1","genius-dashboard-table-cell":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-table-cell___7wz17","genius-dashboard-table-cell-content":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-table-cell-content___5Wdi8","genius-dashboard-pagination":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-pagination___Saw-v","genius-dashboard-pagination-info":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-pagination-info___G6snm","genius-dashboard-page-controls":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-page-controls___Cyqw8","genius-dashboard-page-button":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-page-button___1YLi8",active:"genius-sdk__GeniusChatbotDashboard-module__active___odK6T","genius-dashboard-pagination-dots":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-pagination-dots___lYvds","genius-dashboard-chart-container":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-chart-container___JDX-b","genius-dashboard-single-stat-wrapper":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-single-stat-wrapper___70ycH","genius-dashboard-table-wrapper-container":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-table-wrapper-container___plSHR","genius-dashboard-single-stat":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-single-stat___LF3B2","genius-dashboard-description":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-description___u0ZbF","genius-dashboard-value-pill":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-value-pill___JXBgS","genius-dashboard-history-loading":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-history-loading___GoUb2","genius-dashboard-history-empty":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-history-empty___yZcdH","genius-dashboard-history-item-delete":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-history-item-delete___H2xQq","single-line-input":"genius-sdk__GeniusChatbotDashboard-module__single-line-input___KZ0ag","genius-dashboard-message-content-wrapper":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-message-content-wrapper___xUicT","genius-dashboard-retry-button-inline":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-retry-button-inline___ynxrN","genius-dashboard-action-buttons":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-action-buttons___bHBgd","genius-dashboard-like-button-inline":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-like-button-inline___qxDXm","genius-dashboard-dislike-button-inline":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-dislike-button-inline___tnM54","genius-dashboard-feedback-overlay":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-overlay___DDtOF","genius-dashboard-feedback-container":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-container___-v-cr","genius-dashboard-feedback-header":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-header___ePdx4","genius-dashboard-feedback-icons-left":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-icons-left___5weo7","genius-dashboard-feedback-icons-right":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-icons-right___A-hiJ","genius-dashboard-feedback-icon-container":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-icon-container___WCKoK","genius-dashboard-feedback-body":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-body___vGLbY","genius-dashboard-feedback-content":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-content___s2-PA","genius-dashboard-feedback-icon":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-icon___QOTA1","genius-dashboard-feedback-title":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-title___ttd2-","genius-dashboard-feedback-options":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-options___sTDuz","genius-dashboard-feedback-option":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-option___1tKP5",selected:"genius-sdk__GeniusChatbotDashboard-module__selected___rX0Dk","genius-dashboard-feedback-textarea-container":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-textarea-container___7V-Y8","genius-dashboard-feedback-label":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-label___CCyHp","genius-dashboard-feedback-textarea":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-textarea___aE0kA","genius-dashboard-feedback-error":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-error___TC-hH","genius-dashboard-feedback-submit":"genius-sdk__GeniusChatbotDashboard-module__genius-dashboard-feedback-submit___-XcUM","voice-connecting-bar":"genius-sdk__GeniusChatbotDashboard-module__voice-connecting-bar___Xy8LB","voice-connecting-bar-1":"genius-sdk__GeniusChatbotDashboard-module__voice-connecting-bar-1___H5h9a",fluidWave1:"genius-sdk__GeniusChatbotDashboard-module__fluidWave1___fI9GU","voice-connecting-bar-2":"genius-sdk__GeniusChatbotDashboard-module__voice-connecting-bar-2___fq2Ss",fluidWave2:"genius-sdk__GeniusChatbotDashboard-module__fluidWave2___G5nZM","voice-connecting-bar-3":"genius-sdk__GeniusChatbotDashboard-module__voice-connecting-bar-3___N2Ejq",fluidWave3:"genius-sdk__GeniusChatbotDashboard-module__fluidWave3___V1nF5","voice-connecting-bar-4":"genius-sdk__GeniusChatbotDashboard-module__voice-connecting-bar-4___kH-hV",fluidWave4:"genius-sdk__GeniusChatbotDashboard-module__fluidWave4___RjM9P","voice-connecting-bar-5":"genius-sdk__GeniusChatbotDashboard-module__voice-connecting-bar-5___W7Poa",fluidWave5:"genius-sdk__GeniusChatbotDashboard-module__fluidWave5___QDxGW","voice-connecting-bar-6":"genius-sdk__GeniusChatbotDashboard-module__voice-connecting-bar-6___h-Ip7",fluidWave6:"genius-sdk__GeniusChatbotDashboard-module__fluidWave6___NJN6-"},bL=({text:t,onUpdate:n,onTypingComplete:a})=>{const[r,c]=Re.useState(0),u=Re.useRef(null),h=t.split(/(\s+)/),p=h.slice(0,r).join(""),m=()=>Math.max(10,Math.min(40,40));return Re.useEffect(()=>{n&&n()},[r,n]),Re.useEffect(()=>{if(r>=h.length)return;const v=m(),x=setTimeout(()=>{c(_=>{const T=_+1;return T>=h.length&&a&&a(),T})},v);return()=>clearTimeout(x)},[r,h.length,a]),Re.useEffect(()=>{c(0)},[t]),q.jsx("div",{ref:u,children:q.jsx(l3,{className:nt["genius-dashboard-markdown-content"],remarkPlugins:[P3],components:{table:({children:v})=>q.jsx("div",{className:nt["genius-dashboard-table-wrapper"],children:q.jsx("table",{className:nt["genius-dashboard-markdown-table"],children:v})}),a:({href:v,children:x,..._})=>q.jsx("a",{href:v,target:"_blank",rel:"noopener noreferrer",..._,children:x})},children:p})})};var Cb={exports:{}},vL=Cb.exports,H3;function xL(){return H3||(H3=1,function(t){(function(n,a){t.exports?(a.default=a,t.exports=n&&n.document?a(n):a):(n.Highcharts&&n.Highcharts.error(16,!0),n.Highcharts=a(n))})(typeof window<"u"?window:vL,function(n){var a={};function r(c,u,h,p){!c.hasOwnProperty(u)&&(c[u]=p.apply(null,h),n&&typeof CustomEvent=="function"&&n.dispatchEvent(new CustomEvent("HighchartsModuleLoaded",{detail:{path:u,module:c[u]}})))}return r(a,"Core/Globals.js",[],function(){var c,u;return(u=c||(c={})).SVG_NS="http://www.w3.org/2000/svg",u.product="Highcharts",u.version="11.4.8",u.win=n!==void 0?n:{},u.doc=u.win.document,u.svg=u.doc&&u.doc.createElementNS&&!!u.doc.createElementNS(u.SVG_NS,"svg").createSVGRect,u.userAgent=u.win.navigator&&u.win.navigator.userAgent||"",u.isChrome=u.win.chrome,u.isFirefox=u.userAgent.indexOf("Firefox")!==-1,u.isMS=/(edge|msie|trident)/i.test(u.userAgent)&&!u.win.opera,u.isSafari=!u.isChrome&&u.userAgent.indexOf("Safari")!==-1,u.isTouchDevice=/(Mobile|Android|Windows Phone)/.test(u.userAgent),u.isWebKit=u.userAgent.indexOf("AppleWebKit")!==-1,u.deg2rad=2*Math.PI/360,u.hasBidiBug=u.isFirefox&&4>parseInt(u.userAgent.split("Firefox/")[1],10),u.marginNames=["plotTop","marginRight","marginBottom","plotLeft"],u.noop=function(){},u.supportsPassiveEvents=function(){let h=!1;if(!u.isMS){let p=Object.defineProperty({},"passive",{get:function(){h=!0}});u.win.addEventListener&&u.win.removeEventListener&&(u.win.addEventListener("testPassive",u.noop,p),u.win.removeEventListener("testPassive",u.noop,p))}return h}(),u.charts=[],u.composed=[],u.dateFormats={},u.seriesTypes={},u.symbolSizes={},u.chartCount=0,c}),r(a,"Core/Utilities.js",[a["Core/Globals.js"]],function(c){let u,{charts:h,doc:p,win:m}=c;function v(E,M,R,V){let ae=M?"Highcharts error":"Highcharts warning";E===32&&(E=`${ae}: Deprecated member`);let oe=ne(E),A=oe?`${ae} #${E}: www.highcharts.com/errors/${E}/`:E.toString();if(V!==void 0){let ue="";oe&&(A+="?"),I(V,function(me,g){ue+=`
107
107
  - ${g}: ${me}`,oe&&(A+=encodeURI(g)+"="+encodeURI(me))}),A+=ue}Q(c,"displayError",{chart:R,code:E,message:A,params:V},function(){if(M)throw Error(A);m.console&&v.messages.indexOf(A)===-1&&console.warn(A)}),v.messages.push(A)}function x(E,M){return parseInt(E,M||10)}function _(E){return typeof E=="string"}function T(E){let M=Object.prototype.toString.call(E);return M==="[object Array]"||M==="[object Array Iterator]"}function k(E,M){return!!E&&typeof E=="object"&&(!M||!T(E))}function C(E){return k(E)&&typeof E.nodeType=="number"}function G(E){let M=E&&E.constructor;return!!(k(E,!0)&&!C(E)&&M&&M.name&&M.name!=="Object")}function ne(E){return typeof E=="number"&&!isNaN(E)&&E<1/0&&E>-1/0}function $(E){return E!=null}function L(E,M,R){let V,ae=_(M)&&!$(R),oe=(A,ue)=>{$(A)?E.setAttribute(ue,A):ae?(V=E.getAttribute(ue))||ue!=="class"||(V=E.getAttribute(ue+"Name")):E.removeAttribute(ue)};return _(M)?oe(R,M):I(M,oe),V}function B(E){return T(E)?E:[E]}function Y(E,M){let R;for(R in E||(E={}),M)E[R]=M[R];return E}function X(){let E=arguments,M=E.length;for(let R=0;R<M;R++){let V=E[R];if(V!=null)return V}}function U(E,M){Y(E.style,M)}function Z(E){return Math.pow(10,Math.floor(Math.log(E)/Math.LN10))}function ce(E,M){return E>1e14?E:parseFloat(E.toPrecision(M||14))}(v||(v={})).messages=[],Math.easeInOutSine=function(E){return-.5*(Math.cos(Math.PI*E)-1)};let se=Array.prototype.find?function(E,M){return E.find(M)}:function(E,M){let R,V=E.length;for(R=0;R<V;R++)if(M(E[R],R))return E[R]};function I(E,M,R){for(let V in E)Object.hasOwnProperty.call(E,V)&&M.call(R||E[V],E[V],V,E)}function H(E,M,R){function V(A,ue){let me=E.removeEventListener;me&&me.call(E,A,ue,!1)}function ae(A){let ue,me;E.nodeName&&(M?(ue={})[M]=!0:ue=A,I(ue,function(g,D){if(A[D])for(me=A[D].length;me--;)V(D,A[D][me].fn)}))}let oe=typeof E=="function"&&E.prototype||E;if(Object.hasOwnProperty.call(oe,"hcEvents")){let A=oe.hcEvents;if(M){let ue=A[M]||[];R?(A[M]=ue.filter(function(me){return R!==me.fn}),V(M,R)):(ae(A),A[M]=[])}else ae(A),delete oe.hcEvents}}function Q(E,M,R,V){if(R=R||{},p.createEvent&&(E.dispatchEvent||E.fireEvent&&E!==c)){let ae=p.createEvent("Events");ae.initEvent(M,!0,!0),R=Y(ae,R),E.dispatchEvent?E.dispatchEvent(R):E.fireEvent(M,R)}else if(E.hcEvents){R.target||Y(R,{preventDefault:function(){R.defaultPrevented=!0},target:E,type:M});let ae=[],oe=E,A=!1;for(;oe.hcEvents;)Object.hasOwnProperty.call(oe,"hcEvents")&&oe.hcEvents[M]&&(ae.length&&(A=!0),ae.unshift.apply(ae,oe.hcEvents[M])),oe=Object.getPrototypeOf(oe);A&&ae.sort((ue,me)=>ue.order-me.order),ae.forEach(ue=>{ue.fn.call(E,R)===!1&&R.preventDefault()})}V&&!R.defaultPrevented&&V.call(E,R)}I({map:"map",each:"forEach",grep:"filter",reduce:"reduce",some:"some"},function(E,M){c[M]=function(R){return v(32,!1,void 0,{[`Highcharts.${M}`]:`use Array.${E}`}),Array.prototype[E].apply(R,[].slice.call(arguments,1))}});let F=function(){let E=Math.random().toString(36).substring(2,9)+"-",M=0;return function(){return"highcharts-"+(u?"":E)+M++}}();return m.jQuery&&(m.jQuery.fn.highcharts=function(){let E=[].slice.call(arguments);if(this[0])return E[0]?(new c[_(E[0])?E.shift():"Chart"](this[0],E[0],E[1]),this):h[L(this[0],"data-highcharts-chart")]}),{addEvent:function(E,M,R,V={}){let ae=typeof E=="function"&&E.prototype||E;Object.hasOwnProperty.call(ae,"hcEvents")||(ae.hcEvents={});let oe=ae.hcEvents;c.Point&&E instanceof c.Point&&E.series&&E.series.chart&&(E.series.chart.runTrackerClick=!0);let A=E.addEventListener;A&&A.call(E,M,R,!!c.supportsPassiveEvents&&{passive:V.passive===void 0?M.indexOf("touch")!==-1:V.passive,capture:!1}),oe[M]||(oe[M]=[]);let ue={fn:R,order:typeof V.order=="number"?V.order:1/0};return oe[M].push(ue),oe[M].sort((me,g)=>me.order-g.order),function(){H(E,M,R)}},arrayMax:function(E){let M=E.length,R=E[0];for(;M--;)E[M]>R&&(R=E[M]);return R},arrayMin:function(E){let M=E.length,R=E[0];for(;M--;)E[M]<R&&(R=E[M]);return R},attr:L,clamp:function(E,M,R){return E>M?E<R?E:R:M},clearTimeout:function(E){$(E)&&clearTimeout(E)},correctFloat:ce,createElement:function(E,M,R,V,ae){let oe=p.createElement(E);return M&&Y(oe,M),ae&&U(oe,{padding:"0",border:"none",margin:"0"}),R&&U(oe,R),V&&V.appendChild(oe),oe},crisp:(E,M=0,R)=>{let V=M%2/2,ae=R?-1:1;return(Math.round(E*ae-V)+V)*ae},css:U,defined:$,destroyObjectProperties:function(E,M,R){I(E,function(V,ae){V!==M&&(V!=null&&V.destroy)&&V.destroy(),(V!=null&&V.destroy||!R)&&delete E[ae]})},diffObjects:function(E,M,R,V){let ae={};return function oe(A,ue,me,g){let D=R?ue:A;I(A,function(j,K){if(!g&&V&&V.indexOf(K)>-1&&ue[K]){j=B(j),me[K]=[];for(let te=0;te<Math.max(j.length,ue[K].length);te++)ue[K][te]&&(j[te]===void 0?me[K][te]=ue[K][te]:(me[K][te]={},oe(j[te],ue[K][te],me[K][te],g+1)))}else k(j,!0)&&!j.nodeType?(me[K]=T(j)?[]:{},oe(j,ue[K]||{},me[K],g+1),Object.keys(me[K]).length!==0||K==="colorAxis"&&g===0||delete me[K]):(A[K]!==ue[K]||K in A&&!(K in ue))&&K!=="__proto__"&&K!=="constructor"&&(me[K]=D[K])})}(E,M,ae,0),ae},discardElement:function(E){E&&E.parentElement&&E.parentElement.removeChild(E)},erase:function(E,M){let R=E.length;for(;R--;)if(E[R]===M){E.splice(R,1);break}},error:v,extend:Y,extendClass:function(E,M){let R=function(){};return R.prototype=new E,Y(R.prototype,M),R},find:se,fireEvent:Q,getClosestDistance:function(E,M){let R,V,ae,oe=!M;return E.forEach(A=>{if(A.length>1)for(ae=A.length-1;ae>0;ae--)(V=A[ae]-A[ae-1])<0&&!oe?(M==null||M(),M=void 0):V&&(R===void 0||V<R)&&(R=V)}),R},getMagnitude:Z,getNestedProperty:function(E,M){let R=E.split(".");for(;R.length&&$(M);){let V=R.shift();if(V===void 0||V==="__proto__")return;if(V==="this"){let oe;return k(M)&&(oe=M["@this"]),oe??M}let ae=M[V];if(!$(ae)||typeof ae=="function"||typeof ae.nodeType=="number"||ae===m)return;M=ae}return M},getStyle:function E(M,R,V){let ae;if(R==="width"){let A=Math.min(M.offsetWidth,M.scrollWidth),ue=M.getBoundingClientRect&&M.getBoundingClientRect().width;return ue<A&&ue>=A-1&&(A=Math.floor(ue)),Math.max(0,A-(E(M,"padding-left",!0)||0)-(E(M,"padding-right",!0)||0))}if(R==="height")return Math.max(0,Math.min(M.offsetHeight,M.scrollHeight)-(E(M,"padding-top",!0)||0)-(E(M,"padding-bottom",!0)||0));let oe=m.getComputedStyle(M,void 0);return oe&&(ae=oe.getPropertyValue(R),X(V,R!=="opacity")&&(ae=x(ae))),ae},inArray:function(E,M,R){return v(32,!1,void 0,{"Highcharts.inArray":"use Array.indexOf"}),M.indexOf(E,R)},insertItem:function(E,M){let R,V=E.options.index,ae=M.length;for(R=E.options.isInternal?ae:0;R<ae+1;R++)if(!M[R]||ne(V)&&V<X(M[R].options.index,M[R]._i)||M[R].options.isInternal){M.splice(R,0,E);break}return R},isArray:T,isClass:G,isDOMElement:C,isFunction:function(E){return typeof E=="function"},isNumber:ne,isObject:k,isString:_,keys:function(E){return v(32,!1,void 0,{"Highcharts.keys":"use Object.keys"}),Object.keys(E)},merge:function(){let E,M=arguments,R={},V=function(oe,A){return typeof oe!="object"&&(oe={}),I(A,function(ue,me){me!=="__proto__"&&me!=="constructor"&&(!k(ue,!0)||G(ue)||C(ue)?oe[me]=A[me]:oe[me]=V(oe[me]||{},ue))}),oe};M[0]===!0&&(R=M[1],M=Array.prototype.slice.call(M,2));let ae=M.length;for(E=0;E<ae;E++)R=V(R,M[E]);return R},normalizeTickInterval:function(E,M,R,V,ae){let oe,A=E;R=X(R,Z(E));let ue=E/R;for(!M&&(M=ae?[1,1.2,1.5,2,2.5,3,4,5,6,8,10]:[1,2,2.5,5,10],V===!1&&(R===1?M=M.filter(function(me){return me%1==0}):R<=.1&&(M=[1/R]))),oe=0;oe<M.length&&(A=M[oe],(!ae||!(A*R>=E))&&(ae||!(ue<=(M[oe]+(M[oe+1]||M[oe]))/2)));oe++);return ce(A*R,-Math.round(Math.log(.001)/Math.LN10))},objectEach:I,offset:function(E){let M=p.documentElement,R=E.parentElement||E.parentNode?E.getBoundingClientRect():{top:0,left:0,width:0,height:0};return{top:R.top+(m.pageYOffset||M.scrollTop)-(M.clientTop||0),left:R.left+(m.pageXOffset||M.scrollLeft)-(M.clientLeft||0),width:R.width,height:R.height}},pad:function(E,M,R){return Array((M||2)+1-String(E).replace("-","").length).join(R||"0")+E},pick:X,pInt:x,pushUnique:function(E,M){return 0>E.indexOf(M)&&!!E.push(M)},relativeLength:function(E,M,R){return/%$/.test(E)?M*parseFloat(E)/100+(R||0):parseFloat(E)},removeEvent:H,replaceNested:function(E,...M){let R,V;do for(V of(R=E,M))E=E.replace(V[0],V[1]);while(E!==R);return E},splat:B,stableSort:function(E,M){let R,V,ae=E.length;for(V=0;V<ae;V++)E[V].safeI=V;for(E.sort(function(oe,A){return(R=M(oe,A))===0?oe.safeI-A.safeI:R}),V=0;V<ae;V++)delete E[V].safeI},syncTimeout:function(E,M,R){return M>0?setTimeout(E,M,R):(E.call(0,R),-1)},timeUnits:{millisecond:1,second:1e3,minute:6e4,hour:36e5,day:864e5,week:6048e5,month:24192e5,year:314496e5},uniqueKey:F,useSerialIds:function(E){return u=X(E,u)},wrap:function(E,M,R){let V=E[M];E[M]=function(){let ae=arguments,oe=this;return R.apply(this,[function(){return V.apply(oe,arguments.length?arguments:ae)}].concat([].slice.call(arguments)))}}}}),r(a,"Core/Chart/ChartDefaults.js",[],function(){return{alignThresholds:!1,panning:{enabled:!1,type:"x"},styledMode:!1,borderRadius:0,colorCount:10,allowMutatingData:!0,ignoreHiddenSeries:!0,spacing:[10,10,15,10],resetZoomButton:{theme:{},position:{}},reflow:!0,type:"line",zooming:{singleTouch:!1,resetButton:{theme:{zIndex:6},position:{align:"right",x:-10,y:10}}},width:null,height:null,borderColor:"#334eff",backgroundColor:"#ffffff",plotBorderColor:"#cccccc"}}),r(a,"Core/Color/Palettes.js",[],function(){return{colors:["#2caffe","#544fc5","#00e272","#fe6a35","#6b8abc","#d568fb","#2ee0ca","#fa4b42","#feb56a","#91e8e1"]}}),r(a,"Core/Time.js",[a["Core/Globals.js"],a["Core/Utilities.js"]],function(c,u){let{win:h}=c,{defined:p,error:m,extend:v,isNumber:x,isObject:_,merge:T,objectEach:k,pad:C,pick:G,splat:ne,timeUnits:$}=u,L=c.isSafari&&h.Intl&&h.Intl.DateTimeFormat.prototype.formatRange,B=c.isSafari&&h.Intl&&!h.Intl.DateTimeFormat.prototype.formatRange;class Y{constructor(U){this.options={},this.useUTC=!1,this.variableTimezone=!1,this.Date=h.Date,this.getTimezoneOffset=this.timezoneOffsetFunction(),this.update(U)}get(U,Z){if(this.variableTimezone||this.timezoneOffset){let ce=Z.getTime(),se=ce-this.getTimezoneOffset(Z);Z.setTime(se);let I=Z["getUTC"+U]();return Z.setTime(ce),I}return this.useUTC?Z["getUTC"+U]():Z["get"+U]()}set(U,Z,ce){if(this.variableTimezone||this.timezoneOffset){if(U==="Milliseconds"||U==="Seconds"||U==="Minutes"&&this.getTimezoneOffset(Z)%36e5==0)return Z["setUTC"+U](ce);let se=this.getTimezoneOffset(Z),I=Z.getTime()-se;Z.setTime(I),Z["setUTC"+U](ce);let H=this.getTimezoneOffset(Z);return I=Z.getTime()+H,Z.setTime(I)}return this.useUTC||L&&U==="FullYear"?Z["setUTC"+U](ce):Z["set"+U](ce)}update(U={}){let Z=G(U.useUTC,!0);this.options=U=T(!0,this.options,U),this.Date=U.Date||h.Date||Date,this.useUTC=Z,this.timezoneOffset=Z&&U.timezoneOffset||void 0,this.getTimezoneOffset=this.timezoneOffsetFunction(),this.variableTimezone=Z&&!!(U.getTimezoneOffset||U.timezone)}makeTime(U,Z,ce,se,I,H){let Q,F,E;return this.useUTC?(Q=this.Date.UTC.apply(0,arguments),F=this.getTimezoneOffset(Q),Q+=F,F!==(E=this.getTimezoneOffset(Q))?Q+=E-F:F-36e5!==this.getTimezoneOffset(Q-36e5)||B||(Q-=36e5)):Q=new this.Date(U,Z,G(ce,1),G(se,0),G(I,0),G(H,0)).getTime(),Q}timezoneOffsetFunction(){let U=this,Z=this.options,ce=Z.getTimezoneOffset;return this.useUTC?Z.timezone?se=>{try{let I=`shortOffset,${Z.timezone||""}`,[H,Q,F,E,M=0]=(Y.formatCache[I]=Y.formatCache[I]||Intl.DateTimeFormat("en",{timeZone:Z.timezone,timeZoneName:"shortOffset"})).format(se).split(/(GMT|:)/).map(Number),R=-(36e5*(F+M/60));if(x(R))return R}catch{m(34)}return 0}:this.useUTC&&ce?se=>6e4*ce(se.valueOf()):()=>6e4*(U.timezoneOffset||0):se=>6e4*new Date(se.toString()).getTimezoneOffset()}dateFormat(U,Z,ce){if(!p(Z)||isNaN(Z))return c.defaultOptions.lang&&c.defaultOptions.lang.invalidDate||"";U=G(U,"%Y-%m-%d %H:%M:%S");let se=this,I=new this.Date(Z),H=this.get("Hours",I),Q=this.get("Day",I),F=this.get("Date",I),E=this.get("Month",I),M=this.get("FullYear",I),R=c.defaultOptions.lang,V=R&&R.weekdays,ae=R&&R.shortWeekdays;return k(v({a:ae?ae[Q]:V[Q].substr(0,3),A:V[Q],d:C(F),e:C(F,2," "),w:Q,b:R.shortMonths[E],B:R.months[E],m:C(E+1),o:E+1,y:M.toString().substr(2,2),Y:M,H:C(H),k:H,I:C(H%12||12),l:H%12||12,M:C(this.get("Minutes",I)),p:H<12?"AM":"PM",P:H<12?"am":"pm",S:C(this.get("Seconds",I)),L:C(Math.floor(Z%1e3),3)},c.dateFormats),function(oe,A){for(;U.indexOf("%"+A)!==-1;)U=U.replace("%"+A,typeof oe=="function"?oe.call(se,Z):oe)}),ce?U.substr(0,1).toUpperCase()+U.substr(1):U}resolveDTLFormat(U){return _(U,!0)?U:{main:(U=ne(U))[0],from:U[1],to:U[2]}}getTimeTicks(U,Z,ce,se){let I,H,Q,F,E=this,M=E.Date,R=[],V={},ae=new M(Z),oe=U.unitRange,A=U.count||1;if(se=G(se,1),p(Z)){E.set("Milliseconds",ae,oe>=$.second?0:A*Math.floor(E.get("Milliseconds",ae)/A)),oe>=$.second&&E.set("Seconds",ae,oe>=$.minute?0:A*Math.floor(E.get("Seconds",ae)/A)),oe>=$.minute&&E.set("Minutes",ae,oe>=$.hour?0:A*Math.floor(E.get("Minutes",ae)/A)),oe>=$.hour&&E.set("Hours",ae,oe>=$.day?0:A*Math.floor(E.get("Hours",ae)/A)),oe>=$.day&&E.set("Date",ae,oe>=$.month?1:Math.max(1,A*Math.floor(E.get("Date",ae)/A))),oe>=$.month&&(E.set("Month",ae,oe>=$.year?0:A*Math.floor(E.get("Month",ae)/A)),H=E.get("FullYear",ae)),oe>=$.year&&(H-=H%A,E.set("FullYear",ae,H)),oe===$.week&&(F=E.get("Day",ae),E.set("Date",ae,E.get("Date",ae)-F+se+(F<se?-7:0))),H=E.get("FullYear",ae);let ue=E.get("Month",ae),me=E.get("Date",ae),g=E.get("Hours",ae);Z=ae.getTime(),(E.variableTimezone||!E.useUTC)&&p(ce)&&(Q=ce-Z>4*$.month||E.getTimezoneOffset(Z)!==E.getTimezoneOffset(ce));let D=ae.getTime();for(I=1;D<ce;)R.push(D),oe===$.year?D=E.makeTime(H+I*A,0):oe===$.month?D=E.makeTime(H,ue+I*A):Q&&(oe===$.day||oe===$.week)?D=E.makeTime(H,ue,me+I*A*(oe===$.day?1:7)):Q&&oe===$.hour&&A>1?D=E.makeTime(H,ue,me,g+I*A):D+=oe*A,I++;R.push(D),oe<=$.hour&&R.length<1e4&&R.forEach(function(j){j%18e5==0&&E.dateFormat("%H%M%S%L",j)==="000000000"&&(V[j]="day")})}return R.info=v(U,{higherRanks:V,totalRange:oe*A}),R}getDateFormat(U,Z,ce,se){let I=this.dateFormat("%m-%d %H:%M:%S.%L",Z),H="01-01 00:00:00.000",Q={millisecond:15,second:12,minute:9,hour:6,day:3},F="millisecond",E=F;for(F in $){if(U===$.week&&+this.dateFormat("%w",Z)===ce&&I.substr(6)===H.substr(6)){F="week";break}if($[F]>U){F=E;break}if(Q[F]&&I.substr(Q[F])!==H.substr(Q[F]))break;F!=="week"&&(E=F)}return this.resolveDTLFormat(se[F]).main}}return Y.formatCache={},Y}),r(a,"Core/Defaults.js",[a["Core/Chart/ChartDefaults.js"],a["Core/Globals.js"],a["Core/Color/Palettes.js"],a["Core/Time.js"],a["Core/Utilities.js"]],function(c,u,h,p,m){let{isTouchDevice:v}=u,{fireEvent:x,merge:_}=m,T={colors:h.colors,symbols:["circle","diamond","square","triangle","triangle-down"],lang:{loading:"Loading...",months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],weekdays:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],decimalPoint:".",numericSymbols:["k","M","G","T","P","E"],resetZoom:"Reset zoom",resetZoomTitle:"Reset zoom level 1:1",thousandsSep:" "},global:{buttonTheme:{fill:"#f7f7f7",padding:8,r:2,stroke:"#cccccc","stroke-width":1,style:{color:"#333333",cursor:"pointer",fontSize:"0.8em",fontWeight:"normal"},states:{hover:{fill:"#e6e6e6"},select:{fill:"#e6e9ff",style:{color:"#000000",fontWeight:"bold"}},disabled:{style:{color:"#cccccc"}}}}},time:{Date:void 0,getTimezoneOffset:void 0,timezone:void 0,timezoneOffset:0,useUTC:!0},chart:c,title:{style:{color:"#333333",fontWeight:"bold"},text:"Chart title",align:"center",margin:15,widthAdjust:-44},subtitle:{style:{color:"#666666",fontSize:"0.8em"},text:"",align:"center",widthAdjust:-44},caption:{margin:15,style:{color:"#666666",fontSize:"0.8em"},text:"",align:"left",verticalAlign:"bottom"},plotOptions:{},legend:{enabled:!0,align:"center",alignColumns:!0,className:"highcharts-no-tooltip",events:{},layout:"horizontal",itemMarginBottom:2,itemMarginTop:2,labelFormatter:function(){return this.name},borderColor:"#999999",borderRadius:0,navigation:{style:{fontSize:"0.8em"},activeColor:"#0022ff",inactiveColor:"#cccccc"},itemStyle:{color:"#333333",cursor:"pointer",fontSize:"0.8em",textDecoration:"none",textOverflow:"ellipsis"},itemHoverStyle:{color:"#000000"},itemHiddenStyle:{color:"#666666",textDecoration:"line-through"},shadow:!1,itemCheckboxStyle:{position:"absolute",width:"13px",height:"13px"},squareSymbol:!0,symbolPadding:5,verticalAlign:"bottom",x:0,y:0,title:{style:{fontSize:"0.8em",fontWeight:"bold"}}},loading:{labelStyle:{fontWeight:"bold",position:"relative",top:"45%"},style:{position:"absolute",backgroundColor:"#ffffff",opacity:.5,textAlign:"center"}},tooltip:{enabled:!0,animation:{duration:300,easing:C=>Math.sqrt(1-Math.pow(C-1,2))},borderRadius:3,dateTimeLabelFormats:{millisecond:"%A, %e %b, %H:%M:%S.%L",second:"%A, %e %b, %H:%M:%S",minute:"%A, %e %b, %H:%M",hour:"%A, %e %b, %H:%M",day:"%A, %e %b %Y",week:"Week from %A, %e %b %Y",month:"%B %Y",year:"%Y"},footerFormat:"",headerShape:"callout",hideDelay:500,padding:8,shape:"callout",shared:!1,snap:v?25:10,headerFormat:'<span style="font-size: 0.8em">{point.key}</span><br/>',pointFormat:'<span style="color:{point.color}">●</span> {series.name}: <b>{point.y}</b><br/>',backgroundColor:"#ffffff",borderWidth:void 0,shadow:!0,stickOnContact:!1,style:{color:"#333333",cursor:"default",fontSize:"0.8em"},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:"0.6em"},text:"Highcharts.com"}};T.chart.styledMode=!1;let k=new p(T.time);return{defaultOptions:T,defaultTime:k,getOptions:function(){return T},setOptions:function(C){return x(u,"setOptions",{options:C}),_(!0,T,C),(C.time||C.global)&&(u.time?u.time.update(_(T.global,T.time,C.global,C.time)):u.time=k),T}}}),r(a,"Core/Color/Color.js",[a["Core/Globals.js"],a["Core/Utilities.js"]],function(c,u){let{isNumber:h,merge:p,pInt:m}=u;class v{static parse(_){return _?new v(_):v.None}constructor(_){let T,k,C,G;this.rgba=[NaN,NaN,NaN,NaN],this.input=_;let ne=c.Color;if(ne&&ne!==v)return new ne(_);if(typeof _=="object"&&_.stops!==void 0)this.stops=_.stops.map($=>new v($[1]));else if(typeof _=="string"){if(this.input=_=v.names[_.toLowerCase()]||_,_.charAt(0)==="#"){let $=_.length,L=parseInt(_.substr(1),16);$===7?k=[(16711680&L)>>16,(65280&L)>>8,255&L,1]:$===4&&(k=[(3840&L)>>4|(3840&L)>>8,(240&L)>>4|240&L,(15&L)<<4|15&L,1])}if(!k)for(C=v.parsers.length;C--&&!k;)(T=(G=v.parsers[C]).regex.exec(_))&&(k=G.parse(T))}k&&(this.rgba=k)}get(_){let T=this.input,k=this.rgba;if(typeof T=="object"&&this.stops!==void 0){let C=p(T);return C.stops=[].slice.call(C.stops),this.stops.forEach((G,ne)=>{C.stops[ne]=[C.stops[ne][0],G.get(_)]}),C}return k&&h(k[0])?_!=="rgb"&&(_||k[3]!==1)?_==="a"?`${k[3]}`:"rgba("+k.join(",")+")":"rgb("+k[0]+","+k[1]+","+k[2]+")":T}brighten(_){let T=this.rgba;if(this.stops)this.stops.forEach(function(k){k.brighten(_)});else if(h(_)&&_!==0)for(let k=0;k<3;k++)T[k]+=m(255*_),T[k]<0&&(T[k]=0),T[k]>255&&(T[k]=255);return this}setOpacity(_){return this.rgba[3]=_,this}tweenTo(_,T){let k=this.rgba,C=_.rgba;if(!h(k[0])||!h(C[0]))return _.input||"none";let G=C[3]!==1||k[3]!==1;return(G?"rgba(":"rgb(")+Math.round(C[0]+(k[0]-C[0])*(1-T))+","+Math.round(C[1]+(k[1]-C[1])*(1-T))+","+Math.round(C[2]+(k[2]-C[2])*(1-T))+(G?","+(C[3]+(k[3]-C[3])*(1-T)):"")+")"}}return v.names={white:"#ffffff",black:"#000000"},v.parsers=[{regex:/rgba\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d?(?:\.\d+)?)\s*\)/,parse:function(x){return[m(x[1]),m(x[2]),m(x[3]),parseFloat(x[4],10)]}},{regex:/rgb\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*\)/,parse:function(x){return[m(x[1]),m(x[2]),m(x[3]),1]}}],v.None=new v(""),v}),r(a,"Core/Animation/Fx.js",[a["Core/Color/Color.js"],a["Core/Globals.js"],a["Core/Utilities.js"]],function(c,u,h){let{parse:p}=c,{win:m}=u,{isNumber:v,objectEach:x}=h;class _{constructor(k,C,G){this.pos=NaN,this.options=C,this.elem=k,this.prop=G}dSetter(){let k=this.paths,C=k&&k[0],G=k&&k[1],ne=this.now||0,$=[];if(ne!==1&&C&&G)if(C.length===G.length&&ne<1)for(let L=0;L<G.length;L++){let B=C[L],Y=G[L],X=[];for(let U=0;U<Y.length;U++){let Z=B[U],ce=Y[U];v(Z)&&v(ce)&&!(Y[0]==="A"&&(U===4||U===5))?X[U]=Z+ne*(ce-Z):X[U]=ce}$.push(X)}else $=G;else $=this.toD||[];this.elem.attr("d",$,void 0,!0)}update(){let k=this.elem,C=this.prop,G=this.now,ne=this.options.step;this[C+"Setter"]?this[C+"Setter"]():k.attr?k.element&&k.attr(C,G,null,!0):k.style[C]=G+this.unit,ne&&ne.call(k,G,this)}run(k,C,G){let ne=this,$=ne.options,L=function(X){return!L.stopped&&ne.step(X)},B=m.requestAnimationFrame||function(X){setTimeout(X,13)},Y=function(){for(let X=0;X<_.timers.length;X++)_.timers[X]()||_.timers.splice(X--,1);_.timers.length&&B(Y)};k!==C||this.elem["forceAnimate:"+this.prop]?(this.startTime=+new Date,this.start=k,this.end=C,this.unit=G,this.now=this.start,this.pos=0,L.elem=this.elem,L.prop=this.prop,L()&&_.timers.push(L)===1&&B(Y)):(delete $.curAnim[this.prop],$.complete&&Object.keys($.curAnim).length===0&&$.complete.call(this.elem))}step(k){let C,G,ne=+new Date,$=this.options,L=this.elem,B=$.complete,Y=$.duration,X=$.curAnim;return L.attr&&!L.element?C=!1:k||ne>=Y+this.startTime?(this.now=this.end,this.pos=1,this.update(),X[this.prop]=!0,G=!0,x(X,function(U){U!==!0&&(G=!1)}),G&&B&&B.call(L),C=!1):(this.pos=$.easing((ne-this.startTime)/Y),this.now=this.start+(this.end-this.start)*this.pos,this.update(),C=!0),C}initPath(k,C,G){let ne=k.startX,$=k.endX,L=G.slice(),B=k.isArea,Y=B?2:1,X=C&&G.length>C.length&&G.hasStackedCliffs,U,Z,ce,se,I=C&&C.slice();if(!I||X)return[L,L];function H(F,E){for(;F.length<Z;){let M=F[0],R=E[Z-F.length];if(R&&M[0]==="M"&&(R[0]==="C"?F[0]=["C",M[1],M[2],M[1],M[2],M[1],M[2]]:F[0]=["L",M[1],M[2]]),F.unshift(M),B){let V=F.pop();F.push(F[F.length-1],V)}}}function Q(F){for(;F.length<Z;){let E=F[Math.floor(F.length/Y)-1].slice();if(E[0]==="C"&&(E[1]=E[5],E[2]=E[6]),B){let M=F[Math.floor(F.length/Y)].slice();F.splice(F.length/2,0,E,M)}else F.push(E)}}if(ne&&$&&$.length){for(ce=0;ce<ne.length;ce++){if(ne[ce]===$[0]){U=ce;break}if(ne[0]===$[$.length-ne.length+ce]){U=ce,se=!0;break}if(ne[ne.length-1]===$[$.length-ne.length+ce]){U=ne.length-ce;break}}U===void 0&&(I=[])}return I.length&&v(U)&&(Z=L.length+U*Y,se?(H(I,L),Q(L)):(H(L,I),Q(I))),[I,L]}fillSetter(){_.prototype.strokeSetter.apply(this,arguments)}strokeSetter(){this.elem.attr(this.prop,p(this.start).tweenTo(p(this.end),this.pos),void 0,!0)}}return _.timers=[],_}),r(a,"Core/Animation/AnimationUtilities.js",[a["Core/Animation/Fx.js"],a["Core/Utilities.js"]],function(c,u){let{defined:h,getStyle:p,isArray:m,isNumber:v,isObject:x,merge:_,objectEach:T,pick:k}=u;function C(ne){return x(ne)?_({duration:500,defer:0},ne):{duration:ne?500:0,defer:0}}function G(ne,$){let L=c.timers.length;for(;L--;)c.timers[L].elem!==ne||$&&$!==c.timers[L].prop||(c.timers[L].stopped=!0)}return{animate:function(ne,$,L){let B,Y="",X,U,Z;x(L)||(Z=arguments,L={duration:Z[2],easing:Z[3],complete:Z[4]}),v(L.duration)||(L.duration=400),L.easing=typeof L.easing=="function"?L.easing:Math[L.easing]||Math.easeInOutSine,L.curAnim=_($),T($,function(ce,se){G(ne,se),U=new c(ne,L,se),X=void 0,se==="d"&&m($.d)?(U.paths=U.initPath(ne,ne.pathArray,$.d),U.toD=$.d,B=0,X=1):ne.attr?B=ne.attr(se):(B=parseFloat(p(ne,se))||0,se!=="opacity"&&(Y="px")),X||(X=ce),typeof X=="string"&&X.match("px")&&(X=X.replace(/px/g,"")),U.run(B,X,Y)})},animObject:C,getDeferredAnimation:function(ne,$,L){let B=C($),Y=L?[L]:ne.series,X=0,U=0;return Y.forEach(Z=>{let ce=C(Z.options.animation);X=x($)&&h($.defer)?B.defer:Math.max(X,ce.duration+ce.defer),U=Math.min(B.duration,ce.duration)}),ne.renderer.forExport&&(X=0),{defer:Math.max(0,X-U),duration:Math.min(X,U)}},setAnimation:function(ne,$){$.renderer.globalAnimation=k(ne,$.options.chart.animation,!0)},stop:G}}),r(a,"Core/Renderer/HTML/AST.js",[a["Core/Globals.js"],a["Core/Utilities.js"]],function(c,u){let{SVG_NS:h,win:p}=c,{attr:m,createElement:v,css:x,error:_,isFunction:T,isString:k,objectEach:C,splat:G}=u,{trustedTypes:ne}=p,$=ne&&T(ne.createPolicy)&&ne.createPolicy("highcharts",{createHTML:X=>X}),L=$?$.createHTML(""):"",B=function(){try{return!!new DOMParser().parseFromString(L,"text/html")}catch{return!1}}();class Y{static filterUserAttributes(U){return C(U,(Z,ce)=>{let se=!0;Y.allowedAttributes.indexOf(ce)===-1&&(se=!1),["background","dynsrc","href","lowsrc","src"].indexOf(ce)!==-1&&(se=k(Z)&&Y.allowedReferences.some(I=>Z.indexOf(I)===0)),se||(_(33,!1,void 0,{"Invalid attribute in config":`${ce}`}),delete U[ce]),k(Z)&&U[ce]&&(U[ce]=Z.replace(/</g,"&lt;"))}),U}static parseStyle(U){return U.split(";").reduce((Z,ce)=>{let se=ce.split(":").map(H=>H.trim()),I=se.shift();return I&&se.length&&(Z[I.replace(/-([a-z])/g,H=>H[1].toUpperCase())]=se.join(":")),Z},{})}static setElementHTML(U,Z){U.innerHTML=Y.emptyHTML,Z&&new Y(Z).addToDOM(U)}constructor(U){this.nodes=typeof U=="string"?this.parseMarkup(U):U}addToDOM(U){return function Z(ce,se){let I;return G(ce).forEach(function(H){let Q,F=H.tagName,E=H.textContent?c.doc.createTextNode(H.textContent):void 0,M=Y.bypassHTMLFiltering;if(F)if(F==="#text")Q=E;else if(Y.allowedTags.indexOf(F)!==-1||M){let R=F==="svg"?h:se.namespaceURI||h,V=c.doc.createElementNS(R,F),ae=H.attributes||{};C(H,function(oe,A){A!=="tagName"&&A!=="attributes"&&A!=="children"&&A!=="style"&&A!=="textContent"&&(ae[A]=oe)}),m(V,M?ae:Y.filterUserAttributes(ae)),H.style&&x(V,H.style),E&&V.appendChild(E),Z(H.children||[],V),Q=V}else _(33,!1,void 0,{"Invalid tagName in config":F});Q&&se.appendChild(Q),I=Q}),I}(this.nodes,U)}parseMarkup(U){let Z,ce=[];if(U=U.trim().replace(/ style=(["'])/g," data-style=$1"),B)Z=new DOMParser().parseFromString($?$.createHTML(U):U,"text/html");else{let I=v("div");I.innerHTML=U,Z={body:I}}let se=(I,H)=>{let Q=I.nodeName.toLowerCase(),F={tagName:Q};Q==="#text"&&(F.textContent=I.textContent||"");let E=I.attributes;if(E){let M={};[].forEach.call(E,R=>{R.name==="data-style"?F.style=Y.parseStyle(R.value):M[R.name]=R.value}),F.attributes=M}if(I.childNodes.length){let M=[];[].forEach.call(I.childNodes,R=>{se(R,M)}),M.length&&(F.children=M)}H.push(F)};return[].forEach.call(Z.body.childNodes,I=>se(I,ce)),ce}}return Y.allowedAttributes=["alt","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","filterUnits","flood-color","flood-opacity","height","href","id","in","in2","markerHeight","markerWidth","offset","opacity","operator","orient","padding","paddingLeft","paddingRight","patternUnits","r","radius","refX","refY","role","scope","slope","src","startOffset","stdDeviation","stroke","stroke-linecap","stroke-width","style","tableValues","result","rowspan","summary","target","tabindex","text-align","text-anchor","textAnchor","textLength","title","type","valign","width","x","x1","x2","xlink:href","y","y1","y2","zIndex"],Y.allowedReferences=["https://","http://","mailto:","/","../","./","#"],Y.allowedTags=["a","abbr","b","br","button","caption","circle","clipPath","code","dd","defs","div","dl","dt","em","feComponentTransfer","feComposite","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feMorphology","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","textPath","thead","title","tbody","tspan","td","th","tr","u","ul","#text"],Y.emptyHTML=L,Y.bypassHTMLFiltering=!1,Y}),r(a,"Core/Templating.js",[a["Core/Defaults.js"],a["Core/Utilities.js"]],function(c,u){let{defaultOptions:h,defaultTime:p}=c,{extend:m,getNestedProperty:v,isArray:x,isNumber:_,isObject:T,pick:k,pInt:C}=u,G={add:(L,B)=>L+B,divide:(L,B)=>B!==0?L/B:"",eq:(L,B)=>L==B,each:function(L){let B=arguments[arguments.length-1];return!!x(L)&&L.map((Y,X)=>ne(B.body,m(T(Y)?Y:{"@this":Y},{"@index":X,"@first":X===0,"@last":X===L.length-1}))).join("")},ge:(L,B)=>L>=B,gt:(L,B)=>L>B,if:L=>!!L,le:(L,B)=>L<=B,lt:(L,B)=>L<B,multiply:(L,B)=>L*B,ne:(L,B)=>L!=B,subtract:(L,B)=>L-B,unless:L=>!L};function ne(L="",B,Y){let X=/\{([\w\:\.\,;\-\/<>%@"'’= #\(\)]+)\}/g,U=/\(([\w\:\.\,;\-\/<>%@"'= ]+)\)/g,Z=[],ce=/f$/,se=/\.(\d)/,I=h.lang,H=Y&&Y.time||p,Q=Y&&Y.numberFormatter||$,F=(ae="")=>{let oe;return ae==="true"||ae!=="false"&&((oe=Number(ae)).toString()===ae?oe:v(ae,B))},E,M,R=0,V;for(;(E=X.exec(L))!==null;){let ae=U.exec(E[1]);ae&&(E=ae,V=!0),M&&M.isBlock||(M={ctx:B,expression:E[1],find:E[0],isBlock:E[1].charAt(0)==="#",start:E.index,startInner:E.index+E[0].length,length:E[0].length});let oe=E[1].split(" ")[0].replace("#","");G[oe]&&(M.isBlock&&oe===M.fn&&R++,M.fn||(M.fn=oe));let A=E[1]==="else";if(M.isBlock&&M.fn&&(E[1]===`/${M.fn}`||A))if(R)!A&&R--;else{let ue=M.startInner,me=L.substr(ue,E.index-ue);M.body===void 0?(M.body=me,M.startInner=E.index+E[0].length):M.elseBody=me,M.find+=me+E[0],A||(Z.push(M),M=void 0)}else M.isBlock||Z.push(M);if(ae&&!(M!=null&&M.isBlock))break}return Z.forEach(ae=>{let oe,A,{body:ue,elseBody:me,expression:g,fn:D}=ae;if(D){let j=[ae],K=g.split(" ");for(A=G[D].length;A--;)j.unshift(F(K[A+1]));oe=G[D].apply(B,j),ae.isBlock&&typeof oe=="boolean"&&(oe=ne(oe?ue:me,B,Y))}else{let j=g.split(":");if(oe=F(j.shift()||""),j.length&&typeof oe=="number"){let K=j.join(":");if(ce.test(K)){let te=parseInt((K.match(se)||["","-1"])[1],10);oe!==null&&(oe=Q(oe,te,I.decimalPoint,K.indexOf(",")>-1?I.thousandsSep:""))}else oe=H.dateFormat(K,oe)}}L=L.replace(ae.find,k(oe,""))}),V?ne(L,B,Y):L}function $(L,B,Y,X){let U,Z;L=+L||0,B=+B;let ce=h.lang,se=(L.toString().split(".")[1]||"").split("e")[0].length,I=L.toString().split("e"),H=B;B===-1?B=Math.min(se,20):_(B)?B&&I[1]&&I[1]<0&&((Z=B+ +I[1])>=0?(I[0]=(+I[0]).toExponential(Z).split("e")[0],B=Z):(I[0]=I[0].split(".")[0]||0,L=B<20?(I[0]*Math.pow(10,I[1])).toFixed(B):0,I[1]=0)):B=2;let Q=(Math.abs(I[1]?I[0]:L)+Math.pow(10,-Math.max(B,se)-1)).toFixed(B),F=String(C(Q)),E=F.length>3?F.length%3:0;return Y=k(Y,ce.decimalPoint),X=k(X,ce.thousandsSep),U=(L<0?"-":"")+(E?F.substr(0,E)+X:""),0>+I[1]&&!H?U="0":U+=F.substr(E).replace(/(\d{3})(?=\d)/g,"$1"+X),B?U+=Y+Q.slice(-B):+U==0&&(U="0"),I[1]&&+U!=0&&(U+="e"+I[1]),U}return{dateFormat:function(L,B,Y){return p.dateFormat(L,B,Y)},format:ne,helpers:G,numberFormat:$}}),r(a,"Core/Renderer/RendererRegistry.js",[a["Core/Globals.js"]],function(c){var u,h;let p;return(h=u||(u={})).rendererTypes={},h.getRendererType=function(m=p){return h.rendererTypes[m]||h.rendererTypes[p]},h.registerRendererType=function(m,v,x){h.rendererTypes[m]=v,(!p||x)&&(p=m,c.Renderer=v)},u}),r(a,"Core/Renderer/RendererUtilities.js",[a["Core/Utilities.js"]],function(c){var u;let{clamp:h,pick:p,pushUnique:m,stableSort:v}=c;return(u||(u={})).distribute=function x(_,T,k){let C=_,G=C.reducedLen||T,ne=(F,E)=>F.target-E.target,$=[],L=_.length,B=[],Y=$.push,X,U,Z,ce=!0,se,I,H=0,Q;for(X=L;X--;)H+=_[X].size;if(H>G){for(v(_,(F,E)=>(E.rank||0)-(F.rank||0)),Z=(Q=_[0].rank===_[_.length-1].rank)?L/2:-1,U=Q?Z:L-1;Z&&H>G;)se=_[X=Math.floor(U)],m(B,X)&&(H-=se.size),U+=Z,Q&&U>=_.length&&(Z/=2,U=Z);B.sort((F,E)=>E-F).forEach(F=>Y.apply($,_.splice(F,1)))}for(v(_,ne),_=_.map(F=>({size:F.size,targets:[F.target],align:p(F.align,.5)}));ce;){for(X=_.length;X--;)se=_[X],I=(Math.min.apply(0,se.targets)+Math.max.apply(0,se.targets))/2,se.pos=h(I-se.size*se.align,0,T-se.size);for(X=_.length,ce=!1;X--;)X>0&&_[X-1].pos+_[X-1].size>_[X].pos&&(_[X-1].size+=_[X].size,_[X-1].targets=_[X-1].targets.concat(_[X].targets),_[X-1].align=.5,_[X-1].pos+_[X-1].size>T&&(_[X-1].pos=T-_[X-1].size),_.splice(X,1),ce=!0)}return Y.apply(C,$),X=0,_.some(F=>{let E=0;return(F.targets||[]).some(()=>(C[X].pos=F.pos+E,k!==void 0&&Math.abs(C[X].pos-C[X].target)>k?(C.slice(0,X+1).forEach(M=>delete M.pos),C.reducedLen=(C.reducedLen||T)-.1*T,C.reducedLen>.1*T&&x(C,T,k),!0):(E+=C[X].size,X++,!1)))}),v(C,ne),C},u}),r(a,"Core/Renderer/SVG/SVGElement.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Color/Color.js"],a["Core/Globals.js"],a["Core/Utilities.js"]],function(c,u,h,p){let{animate:m,animObject:v,stop:x}=c,{deg2rad:_,doc:T,svg:k,SVG_NS:C,win:G}=h,{addEvent:ne,attr:$,createElement:L,crisp:B,css:Y,defined:X,erase:U,extend:Z,fireEvent:ce,isArray:se,isFunction:I,isObject:H,isString:Q,merge:F,objectEach:E,pick:M,pInt:R,pushUnique:V,replaceNested:ae,syncTimeout:oe,uniqueKey:A}=p;class ue{_defaultGetter(g){let D=M(this[g+"Value"],this[g],this.element?this.element.getAttribute(g):null,0);return/^-?[\d\.]+$/.test(D)&&(D=parseFloat(D)),D}_defaultSetter(g,D,j){j.setAttribute(D,g)}add(g){let D,j=this.renderer,K=this.element;return g&&(this.parentGroup=g),this.textStr!==void 0&&this.element.nodeName==="text"&&j.buildText(this),this.added=!0,(!g||g.handleZ||this.zIndex)&&(D=this.zIndexSetter()),D||(g?g.element:j.box).appendChild(K),this.onAdd&&this.onAdd(),this}addClass(g,D){let j=D?"":this.attr("class")||"";return(g=(g||"").split(/ /g).reduce(function(K,te){return j.indexOf(te)===-1&&K.push(te),K},j?[j]:[]).join(" "))!==j&&this.attr("class",g),this}afterSetters(){this.doTransform&&(this.updateTransform(),this.doTransform=!1)}align(g,D,j,K=!0){let te,O,z,W,de={},P=this.renderer,ee=P.alignedObjects,J=!!g;g?(this.alignOptions=g,this.alignByTranslate=D,this.alignTo=j):(g=this.alignOptions||{},D=this.alignByTranslate,j=this.alignTo);let le=!j||Q(j)?j||"renderer":void 0;le&&(J&&V(ee,this),j=void 0);let re=M(j,P[le],P),ge=g.align,ve=g.verticalAlign;return te=(re.x||0)+(g.x||0),O=(re.y||0)+(g.y||0),ge==="right"?z=1:ge==="center"&&(z=2),z&&(te+=((re.width||0)-(g.width||0))/z),de[D?"translateX":"x"]=Math.round(te),ve==="bottom"?W=1:ve==="middle"&&(W=2),W&&(O+=((re.height||0)-(g.height||0))/W),de[D?"translateY":"y"]=Math.round(O),K&&(this[this.placed?"animate":"attr"](de),this.placed=!0),this.alignAttr=de,this}alignSetter(g){let D={left:"start",center:"middle",right:"end"};D[g]&&(this.alignValue=g,this.element.setAttribute("text-anchor",D[g]))}animate(g,D,j){let K=v(M(D,this.renderer.globalAnimation,!0)),te=K.defer;return T.hidden&&(K.duration=0),K.duration!==0?(j&&(K.complete=j),oe(()=>{this.element&&m(this,g,K)},te)):(this.attr(g,void 0,j||K.complete),E(g,function(O,z){K.step&&K.step.call(this,O,{prop:z,pos:1,elem:this})},this)),this}applyTextOutline(g){let D=this.element;g.indexOf("contrast")!==-1&&(g=g.replace(/contrast/g,this.renderer.getContrast(D.style.fill)));let j=g.split(" "),K=j[j.length-1],te=j[0];if(te&&te!=="none"&&h.svg){this.fakeTS=!0,te=te.replace(/(^[\d\.]+)(.*?)$/g,function(P,ee,J){return 2*Number(ee)+J}),this.removeTextOutline();let O=T.createElementNS(C,"tspan");$(O,{class:"highcharts-text-outline",fill:K,stroke:K,"stroke-width":te,"stroke-linejoin":"round"});let z=D.querySelector("textPath")||D;[].forEach.call(z.childNodes,P=>{let ee=P.cloneNode(!0);ee.removeAttribute&&["fill","stroke","stroke-width","stroke"].forEach(J=>ee.removeAttribute(J)),O.appendChild(ee)});let W=0;[].forEach.call(z.querySelectorAll("text tspan"),P=>{W+=Number(P.getAttribute("dy"))});let de=T.createElementNS(C,"tspan");de.textContent="​",$(de,{x:Number(D.getAttribute("x")),dy:-W}),O.appendChild(de),z.insertBefore(O,z.firstChild)}}attr(g,D,j,K){let{element:te}=this,O=ue.symbolCustomAttribs,z,W,de=this,P;return typeof g=="string"&&D!==void 0&&(z=g,(g={})[z]=D),typeof g=="string"?de=(this[g+"Getter"]||this._defaultGetter).call(this,g,te):(E(g,function(ee,J){P=!1,K||x(this,J),this.symbolName&&O.indexOf(J)!==-1&&(W||(this.symbolAttr(g),W=!0),P=!0),this.rotation&&(J==="x"||J==="y")&&(this.doTransform=!0),P||(this[J+"Setter"]||this._defaultSetter).call(this,ee,J,te)},this),this.afterSetters()),j&&j.call(this),de}clip(g){if(g&&!g.clipPath){let D=A()+"-",j=this.renderer.createElement("clipPath").attr({id:D}).add(this.renderer.defs);Z(g,{clipPath:j,id:D,count:0}),g.add(j)}return this.attr("clip-path",g?`url(${this.renderer.url}#${g.id})`:"none")}crisp(g,D){D=Math.round(D||g.strokeWidth||0);let j=g.x||this.x||0,K=g.y||this.y||0,te=(g.width||this.width||0)+j,O=(g.height||this.height||0)+K,z=B(j,D),W=B(K,D);return Z(g,{x:z,y:W,width:B(te,D)-z,height:B(O,D)-W}),X(g.strokeWidth)&&(g.strokeWidth=D),g}complexColor(g,D,j){let K=this.renderer,te,O,z,W,de,P,ee,J,le,re,ge=[],ve;ce(this.renderer,"complexColor",{args:arguments},function(){if(g.radialGradient?O="radialGradient":g.linearGradient&&(O="linearGradient"),O){if(z=g[O],de=K.gradients,P=g.stops,le=j.radialReference,se(z)&&(g[O]=z={x1:z[0],y1:z[1],x2:z[2],y2:z[3],gradientUnits:"userSpaceOnUse"}),O==="radialGradient"&&le&&!X(z.gradientUnits)&&(W=z,z=F(z,K.getRadialAttr(le,W),{gradientUnits:"userSpaceOnUse"})),E(z,function(we,Ce){Ce!=="id"&&ge.push(Ce,we)}),E(P,function(we){ge.push(we)}),de[ge=ge.join(",")])re=de[ge].attr("id");else{z.id=re=A();let we=de[ge]=K.createElement(O).attr(z).add(K.defs);we.radAttr=W,we.stops=[],P.forEach(function(Ce){Ce[1].indexOf("rgba")===0?(ee=(te=u.parse(Ce[1])).get("rgb"),J=te.get("a")):(ee=Ce[1],J=1);let Me=K.createElement("stop").attr({offset:Ce[0],"stop-color":ee,"stop-opacity":J}).add(we);we.stops.push(Me)})}ve="url("+K.url+"#"+re+")",j.setAttribute(D,ve),j.gradient=ge,g.toString=function(){return ve}}})}css(g){let D=this.styles,j={},K=this.element,te,O=!D;if(D&&E(g,function(z,W){D&&D[W]!==z&&(j[W]=z,O=!0)}),O){D&&(g=Z(D,j)),g.width===null||g.width==="auto"?delete this.textWidth:K.nodeName.toLowerCase()==="text"&&g.width&&(te=this.textWidth=R(g.width)),Z(this.styles,g),te&&!k&&this.renderer.forExport&&delete g.width;let z=F(g);K.namespaceURI===this.SVG_NS&&(["textOutline","textOverflow","width"].forEach(W=>z&&delete z[W]),z.color&&(z.fill=z.color)),Y(K,z)}return this.added&&(this.element.nodeName==="text"&&this.renderer.buildText(this),g.textOutline&&this.applyTextOutline(g.textOutline)),this}dashstyleSetter(g){let D,j=this["stroke-width"];if(j==="inherit"&&(j=1),g=g&&g.toLowerCase()){let K=g.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(D=K.length;D--;)K[D]=""+R(K[D])*M(j,NaN);g=K.join(",").replace(/NaN/g,"none"),this.element.setAttribute("stroke-dasharray",g)}}destroy(){var W;let g=this,D=g.element||{},j=g.renderer,K=D.ownerSVGElement,te=D.nodeName==="SPAN"&&g.parentGroup||void 0,O,z;if(D.onclick=D.onmouseout=D.onmouseover=D.onmousemove=D.point=null,x(g),g.clipPath&&K){let de=g.clipPath;[].forEach.call(K.querySelectorAll("[clip-path],[CLIP-PATH]"),function(P){P.getAttribute("clip-path").indexOf(de.element.id)>-1&&P.removeAttribute("clip-path")}),g.clipPath=de.destroy()}if(g.connector=(W=g.connector)==null?void 0:W.destroy(),g.stops){for(z=0;z<g.stops.length;z++)g.stops[z].destroy();g.stops.length=0,g.stops=void 0}for(g.safeRemoveChild(D);te&&te.div&&te.div.childNodes.length===0;)O=te.parentGroup,g.safeRemoveChild(te.div),delete te.div,te=O;g.alignOptions&&U(j.alignedObjects,g),E(g,function(de,P){g[P]&&g[P].parentGroup===g&&g[P].destroy&&g[P].destroy(),delete g[P]})}dSetter(g,D,j){se(g)&&(typeof g[0]=="string"&&(g=this.renderer.pathToSegments(g)),this.pathArray=g,g=g.reduce((K,te,O)=>te&&te.join?(O?K+" ":"")+te.join(" "):(te||"").toString(),"")),/(NaN| {2}|^$)/.test(g)&&(g="M 0 0"),this[D]!==g&&(j.setAttribute(D,g),this[D]=g)}fillSetter(g,D,j){typeof g=="string"?j.setAttribute(D,g):g&&this.complexColor(g,D,j)}hrefSetter(g,D,j){j.setAttributeNS("http://www.w3.org/1999/xlink",D,g)}getBBox(g,D){let j,K,te,O,{alignValue:z,element:W,renderer:de,styles:P,textStr:ee}=this,{cache:J,cacheKeys:le}=de,re=W.namespaceURI===this.SVG_NS,ge=M(D,this.rotation,0),ve=de.styledMode?W&&ue.prototype.getStyle.call(W,"font-size"):P.fontSize;if(X(ee)&&((O=ee.toString()).indexOf("<")===-1&&(O=O.replace(/\d/g,"0")),O+=["",de.rootFontSize,ve,ge,this.textWidth,z,P.textOverflow,P.fontWeight].join(",")),O&&!g&&(j=J[O]),!j||j.polygon){if(re||de.forExport){try{te=this.fakeTS&&function(Ce){let Me=W.querySelector(".highcharts-text-outline");Me&&Y(Me,{display:Ce})},I(te)&&te("none"),j=W.getBBox?Z({},W.getBBox()):{width:W.offsetWidth,height:W.offsetHeight,x:0,y:0},I(te)&&te("")}catch{}(!j||j.width<0)&&(j={x:0,y:0,width:0,height:0})}else j=this.htmlGetBBox();K=j.height,re&&(j.height=K={"11px,17":14,"13px,20":16}[`${ve||""},${Math.round(K)}`]||K),ge&&(j=this.getRotatedBox(j,ge));let we={bBox:j};ce(this,"afterGetBBox",we),j=we.bBox}if(O&&(ee===""||j.height>0)){for(;le.length>250;)delete J[le.shift()];J[O]||le.push(O),J[O]=j}return j}getRotatedBox(g,D){let{x:j,y:K,width:te,height:O}=g,{alignValue:z,translateY:W,rotationOriginX:de=0,rotationOriginY:P=0}=this,ee={right:1,center:.5}[z||0]||0,J=Number(this.element.getAttribute("y")||0)-(W?0:K),le=D*_,re=(D-90)*_,ge=Math.cos(le),ve=Math.sin(le),we=te*ge,Ce=te*ve,Me=Math.cos(re),De=Math.sin(re),[[be,ye],[xe,pe]]=[de,P].map(Pt=>[Pt-Pt*ge,Pt*ve]),Se=j+ee*(te-we)+be+pe+J*Me,Ae=Se+we,Te=Ae-O*Me,Oe=Te-we,ze=K+J-ee*Ce-ye+xe+J*De,Ge=ze+Ce,Ve=Ge-O*De,qe=Ve-Ce,ot=Math.min(Se,Ae,Te,Oe),ft=Math.min(ze,Ge,Ve,qe),dt=Math.max(Se,Ae,Te,Oe)-ot,et=Math.max(ze,Ge,Ve,qe)-ft;return{x:ot,y:ft,width:dt,height:et,polygon:[[Se,ze],[Ae,Ge],[Te,Ve],[Oe,qe]]}}getStyle(g){return G.getComputedStyle(this.element||this,"").getPropertyValue(g)}hasClass(g){return(""+this.attr("class")).split(" ").indexOf(g)!==-1}hide(){return this.attr({visibility:"hidden"})}htmlGetBBox(){return{height:0,width:0,x:0,y:0}}constructor(g,D){this.onEvents={},this.opacity=1,this.SVG_NS=C,this.element=D==="span"||D==="body"?L(D):T.createElementNS(this.SVG_NS,D),this.renderer=g,this.styles={},ce(this,"afterInit")}on(g,D){let{onEvents:j}=this;return j[g]&&j[g](),j[g]=ne(this.element,g,D),this}opacitySetter(g,D,j){let K=Number(Number(g).toFixed(3));this.opacity=K,j.setAttribute(D,K)}reAlign(){var g;(g=this.alignOptions)!=null&&g.width&&this.alignOptions.align!=="left"&&(this.alignOptions.width=this.getBBox().width,this.placed=!1,this.align())}removeClass(g){return this.attr("class",(""+this.attr("class")).replace(Q(g)?RegExp(`(^| )${g}( |$)`):g," ").replace(/ +/g," ").trim())}removeTextOutline(){let g=this.element.querySelector("tspan.highcharts-text-outline");g&&this.safeRemoveChild(g)}safeRemoveChild(g){let D=g.parentNode;D&&D.removeChild(g)}setRadialReference(g){let D=this.element.gradient&&this.renderer.gradients[this.element.gradient];return this.element.radialReference=g,D&&D.radAttr&&D.animate(this.renderer.getRadialAttr(g,D.radAttr)),this}shadow(g){var te;let{renderer:D}=this,j=F(((te=this.parentGroup)==null?void 0:te.rotation)===90?{offsetX:-1,offsetY:-1}:{},H(g)?g:{}),K=D.shadowDefinition(j);return this.attr({filter:g?`url(${D.url}#${K})`:"none"})}show(g=!0){return this.attr({visibility:g?"inherit":"visible"})}"stroke-widthSetter"(g,D,j){this[D]=g,j.setAttribute(D,g)}strokeWidth(){if(!this.renderer.styledMode)return this["stroke-width"]||0;let g=this.getStyle("stroke-width"),D=0,j;return/px$/.test(g)?D=R(g):g!==""&&($(j=T.createElementNS(C,"rect"),{width:g,"stroke-width":0}),this.element.parentNode.appendChild(j),D=j.getBBox().width,j.parentNode.removeChild(j)),D}symbolAttr(g){let D=this;ue.symbolCustomAttribs.forEach(function(j){D[j]=M(g[j],D[j])}),D.attr({d:D.renderer.symbols[D.symbolName](D.x,D.y,D.width,D.height,D)})}textSetter(g){g!==this.textStr&&(delete this.textPxLength,this.textStr=g,this.added&&this.renderer.buildText(this),this.reAlign())}titleSetter(g){let D=this.element,j=D.getElementsByTagName("title")[0]||T.createElementNS(this.SVG_NS,"title");D.insertBefore?D.insertBefore(j,D.firstChild):D.appendChild(j),j.textContent=ae(M(g,""),[/<[^>]*>/g,""]).replace(/&lt;/g,"<").replace(/&gt;/g,">")}toFront(){let g=this.element;return g.parentNode.appendChild(g),this}translate(g,D){return this.attr({translateX:g,translateY:D})}updateTransform(g="transform"){var J;let{element:D,matrix:j,rotation:K=0,rotationOriginX:te,rotationOriginY:O,scaleX:z,scaleY:W,translateX:de=0,translateY:P=0}=this,ee=["translate("+de+","+P+")"];X(j)&&ee.push("matrix("+j.join(",")+")"),K&&(ee.push("rotate("+K+" "+M(te,D.getAttribute("x"),0)+" "+M(O,D.getAttribute("y")||0)+")"),((J=this.text)==null?void 0:J.element.tagName)==="SPAN"&&this.text.attr({rotation:K,rotationOriginX:(te||0)-this.padding,rotationOriginY:(O||0)-this.padding})),(X(z)||X(W))&&ee.push("scale("+M(z,1)+" "+M(W,1)+")"),ee.length&&!(this.text||this).textPath&&D.setAttribute(g,ee.join(" "))}visibilitySetter(g,D,j){g==="inherit"?j.removeAttribute(D):this[D]!==g&&j.setAttribute(D,g),this[D]=g}xGetter(g){return this.element.nodeName==="circle"&&(g==="x"?g="cx":g==="y"&&(g="cy")),this._defaultGetter(g)}zIndexSetter(g,D){let j=this.renderer,K=this.parentGroup,te=(K||j).element||j.box,O=this.element,z=te===j.box,W,de,P,ee=!1,J,le=this.added,re;if(X(g)?(O.setAttribute("data-z-index",g),g=+g,this[D]===g&&(le=!1)):X(this[D])&&O.removeAttribute("data-z-index"),this[D]=g,le){for((g=this.zIndex)&&K&&(K.handleZ=!0),re=(W=te.childNodes).length-1;re>=0&&!ee;re--)J=!X(P=(de=W[re]).getAttribute("data-z-index")),de!==O&&(g<0&&J&&!z&&!re?(te.insertBefore(O,W[re]),ee=!0):(R(P)<=g||J&&(!X(g)||g>=0))&&(te.insertBefore(O,W[re+1]),ee=!0));ee||(te.insertBefore(O,W[z?3:0]),ee=!0)}return ee}}return ue.symbolCustomAttribs=["anchorX","anchorY","clockwise","end","height","innerR","r","start","width","x","y"],ue.prototype.strokeSetter=ue.prototype.fillSetter,ue.prototype.yGetter=ue.prototype.xGetter,ue.prototype.matrixSetter=ue.prototype.rotationOriginXSetter=ue.prototype.rotationOriginYSetter=ue.prototype.rotationSetter=ue.prototype.scaleXSetter=ue.prototype.scaleYSetter=ue.prototype.translateXSetter=ue.prototype.translateYSetter=ue.prototype.verticalAlignSetter=function(me,g){this[g]=me,this.doTransform=!0},ue}),r(a,"Core/Renderer/SVG/SVGLabel.js",[a["Core/Renderer/SVG/SVGElement.js"],a["Core/Utilities.js"]],function(c,u){let{defined:h,extend:p,isNumber:m,merge:v,pick:x,removeEvent:_}=u;class T extends c{constructor(C,G,ne,$,L,B,Y,X,U,Z){let ce;super(C,"g"),this.paddingLeftSetter=this.paddingSetter,this.paddingRightSetter=this.paddingSetter,this.doUpdate=!1,this.textStr=G,this.x=ne,this.y=$,this.anchorX=B,this.anchorY=Y,this.baseline=U,this.className=Z,this.addClass(Z==="button"?"highcharts-no-tooltip":"highcharts-label"),Z&&this.addClass("highcharts-"+Z),this.text=C.text(void 0,0,0,X).attr({zIndex:1}),typeof L=="string"&&((ce=/^url\((.*?)\)$/.test(L))||this.renderer.symbols[L])&&(this.symbolKey=L),this.bBox=T.emptyBBox,this.padding=3,this.baselineOffset=0,this.needsBox=C.styledMode||ce,this.deferredAttr={},this.alignFactor=0}alignSetter(C){let G={left:0,center:.5,right:1}[C];G!==this.alignFactor&&(this.alignFactor=G,this.bBox&&m(this.xSetting)&&this.attr({x:this.xSetting}))}anchorXSetter(C,G){this.anchorX=C,this.boxAttr(G,Math.round(C)-this.getCrispAdjust()-this.xSetting)}anchorYSetter(C,G){this.anchorY=C,this.boxAttr(G,C-this.ySetting)}boxAttr(C,G){this.box?this.box.attr(C,G):this.deferredAttr[C]=G}css(C){if(C){let G={};C=v(C),T.textProps.forEach(ne=>{C[ne]!==void 0&&(G[ne]=C[ne],delete C[ne])}),this.text.css(G),"fontSize"in G||"fontWeight"in G?this.updateTextPadding():("width"in G||"textOverflow"in G)&&this.updateBoxSize()}return c.prototype.css.call(this,C)}destroy(){_(this.element,"mouseenter"),_(this.element,"mouseleave"),this.text&&this.text.destroy(),this.box&&(this.box=this.box.destroy()),c.prototype.destroy.call(this)}fillSetter(C,G){C&&(this.needsBox=!0),this.fill=C,this.boxAttr(G,C)}getBBox(C,G){this.textStr&&this.bBox.width===0&&this.bBox.height===0&&this.updateBoxSize();let{padding:ne,height:$=0,translateX:L=0,translateY:B=0,width:Y=0}=this,X=x(this.paddingLeft,ne),U=G??(this.rotation||0),Z={width:Y,height:$,x:L+this.bBox.x-X,y:B+this.bBox.y-ne+this.baselineOffset};return U&&(Z=this.getRotatedBox(Z,U)),Z}getCrispAdjust(){return(this.renderer.styledMode&&this.box?this.box.strokeWidth():this["stroke-width"]?parseInt(this["stroke-width"],10):0)%2/2}heightSetter(C){this.heightSetting=C,this.doUpdate=!0}afterSetters(){super.afterSetters(),this.doUpdate&&(this.updateBoxSize(),this.doUpdate=!1)}onAdd(){this.text.add(this),this.attr({text:x(this.textStr,""),x:this.x||0,y:this.y||0}),this.box&&h(this.anchorX)&&this.attr({anchorX:this.anchorX,anchorY:this.anchorY})}paddingSetter(C,G){m(C)?C!==this[G]&&(this[G]=C,this.updateTextPadding()):this[G]=void 0}rSetter(C,G){this.boxAttr(G,C)}strokeSetter(C,G){this.stroke=C,this.boxAttr(G,C)}"stroke-widthSetter"(C,G){C&&(this.needsBox=!0),this["stroke-width"]=C,this.boxAttr(G,C)}"text-alignSetter"(C){this.textAlign=C}textSetter(C){C!==void 0&&this.text.attr({text:C}),this.updateTextPadding(),this.reAlign()}updateBoxSize(){let C,G=this.text,ne={},$=this.padding,L=this.bBox=(!m(this.widthSetting)||!m(this.heightSetting)||this.textAlign)&&h(G.textStr)?G.getBBox(void 0,0):T.emptyBBox;this.width=this.getPaddedWidth(),this.height=(this.heightSetting||L.height||0)+2*$;let B=this.renderer.fontMetrics(G);if(this.baselineOffset=$+Math.min((this.text.firstLineMetrics||B).b,L.height||1/0),this.heightSetting&&(this.baselineOffset+=(this.heightSetting-B.h)/2),this.needsBox&&!G.textPath){if(!this.box){let Y=this.box=this.symbolKey?this.renderer.symbol(this.symbolKey):this.renderer.rect();Y.addClass((this.className==="button"?"":"highcharts-label-box")+(this.className?" highcharts-"+this.className+"-box":"")),Y.add(this)}C=this.getCrispAdjust(),ne.x=C,ne.y=(this.baseline?-this.baselineOffset:0)+C,ne.width=Math.round(this.width),ne.height=Math.round(this.height),this.box.attr(p(ne,this.deferredAttr)),this.deferredAttr={}}}updateTextPadding(){let C=this.text;if(!C.textPath){this.updateBoxSize();let G=this.baseline?0:this.baselineOffset,ne=x(this.paddingLeft,this.padding);h(this.widthSetting)&&this.bBox&&(this.textAlign==="center"||this.textAlign==="right")&&(ne+={center:.5,right:1}[this.textAlign]*(this.widthSetting-this.bBox.width)),(ne!==C.x||G!==C.y)&&(C.attr("x",ne),C.hasBoxWidthChanged&&(this.bBox=C.getBBox(!0)),G!==void 0&&C.attr("y",G)),C.x=ne,C.y=G}}widthSetter(C){this.widthSetting=m(C)?C:void 0,this.doUpdate=!0}getPaddedWidth(){let C=this.padding,G=x(this.paddingLeft,C),ne=x(this.paddingRight,C);return(this.widthSetting||this.bBox.width||0)+G+ne}xSetter(C){this.x=C,this.alignFactor&&(C-=this.alignFactor*this.getPaddedWidth(),this["forceAnimate:x"]=!0),this.xSetting=Math.round(C),this.attr("translateX",this.xSetting)}ySetter(C){this.ySetting=this.y=Math.round(C),this.attr("translateY",this.ySetting)}}return T.emptyBBox={width:0,height:0,x:0,y:0},T.textProps=["color","direction","fontFamily","fontSize","fontStyle","fontWeight","lineHeight","textAlign","textDecoration","textOutline","textOverflow","whiteSpace","width"],T}),r(a,"Core/Renderer/SVG/Symbols.js",[a["Core/Utilities.js"]],function(c){let{defined:u,isNumber:h,pick:p}=c;function m(_,T,k,C,G){let ne=[];if(G){let $=G.start||0,L=p(G.r,k),B=p(G.r,C||k),Y=2e-4/(G.borderRadius?1:Math.max(L,1)),X=Math.abs((G.end||0)-$-2*Math.PI)<Y,U=(G.end||0)-(X?Y:0),Z=G.innerR,ce=p(G.open,X),se=Math.cos($),I=Math.sin($),H=Math.cos(U),Q=Math.sin(U),F=p(G.longArc,U-$-Math.PI<Y?0:1),E=["A",L,B,0,F,p(G.clockwise,1),_+L*H,T+B*Q];E.params={start:$,end:U,cx:_,cy:T},ne.push(["M",_+L*se,T+B*I],E),u(Z)&&((E=["A",Z,Z,0,F,u(G.clockwise)?1-G.clockwise:0,_+Z*se,T+Z*I]).params={start:U,end:$,cx:_,cy:T},ne.push(ce?["M",_+Z*H,T+Z*Q]:["L",_+Z*H,T+Z*Q],E)),ce||ne.push(["Z"])}return ne}function v(_,T,k,C,G){return G&&G.r?x(_,T,k,C,G):[["M",_,T],["L",_+k,T],["L",_+k,T+C],["L",_,T+C],["Z"]]}function x(_,T,k,C,G){let ne=(G==null?void 0:G.r)||0;return[["M",_+ne,T],["L",_+k-ne,T],["A",ne,ne,0,0,1,_+k,T+ne],["L",_+k,T+C-ne],["A",ne,ne,0,0,1,_+k-ne,T+C],["L",_+ne,T+C],["A",ne,ne,0,0,1,_,T+C-ne],["L",_,T+ne],["A",ne,ne,0,0,1,_+ne,T],["Z"]]}return{arc:m,callout:function(_,T,k,C,G){let ne=Math.min(G&&G.r||0,k,C),$=ne+6,L=G&&G.anchorX,B=G&&G.anchorY||0,Y=x(_,T,k,C,{r:ne});if(!h(L)||L<k&&L>0&&B<C&&B>0)return Y;if(_+L>k-$)if(B>T+$&&B<T+C-$)Y.splice(3,1,["L",_+k,B-6],["L",_+k+6,B],["L",_+k,B+6],["L",_+k,T+C-ne]);else if(L<k){let X=B<T+$,U=X?T:T+C;Y.splice(X?2:5,0,["L",L,B],["L",_+k-ne,U])}else Y.splice(3,1,["L",_+k,C/2],["L",L,B],["L",_+k,C/2],["L",_+k,T+C-ne]);else if(_+L<$)if(B>T+$&&B<T+C-$)Y.splice(7,1,["L",_,B+6],["L",_-6,B],["L",_,B-6],["L",_,T+ne]);else if(L>0){let X=B<T+$,U=X?T:T+C;Y.splice(X?1:6,0,["L",L,B],["L",_+ne,U])}else Y.splice(7,1,["L",_,C/2],["L",L,B],["L",_,C/2],["L",_,T+ne]);else B>C&&L<k-$?Y.splice(5,1,["L",L+6,T+C],["L",L,T+C+6],["L",L-6,T+C],["L",_+ne,T+C]):B<0&&L>$&&Y.splice(1,1,["L",L-6,T],["L",L,T-6],["L",L+6,T],["L",k-ne,T]);return Y},circle:function(_,T,k,C){return m(_+k/2,T+C/2,k/2,C/2,{start:.5*Math.PI,end:2.5*Math.PI,open:!1})},diamond:function(_,T,k,C){return[["M",_+k/2,T],["L",_+k,T+C/2],["L",_+k/2,T+C],["L",_,T+C/2],["Z"]]},rect:v,roundedRect:x,square:v,triangle:function(_,T,k,C){return[["M",_+k/2,T],["L",_+k,T+C],["L",_,T+C],["Z"]]},"triangle-down":function(_,T,k,C){return[["M",_,T],["L",_+k,T],["L",_+k/2,T+C],["Z"]]}}}),r(a,"Core/Renderer/SVG/TextBuilder.js",[a["Core/Renderer/HTML/AST.js"],a["Core/Globals.js"],a["Core/Utilities.js"]],function(c,u,h){let{doc:p,SVG_NS:m,win:v}=u,{attr:x,extend:_,fireEvent:T,isString:k,objectEach:C,pick:G}=h;return class{constructor(ne){let $=ne.styles;this.renderer=ne.renderer,this.svgElement=ne,this.width=ne.textWidth,this.textLineHeight=$&&$.lineHeight,this.textOutline=$&&$.textOutline,this.ellipsis=!!($&&$.textOverflow==="ellipsis"),this.noWrap=!!($&&$.whiteSpace==="nowrap")}buildSVG(){let ne=this.svgElement,$=ne.element,L=ne.renderer,B=G(ne.textStr,"").toString(),Y=B.indexOf("<")!==-1,X=$.childNodes,U=!ne.added&&L.box,Z=[B,this.ellipsis,this.noWrap,this.textLineHeight,this.textOutline,ne.getStyle("font-size"),this.width].join(",");if(Z!==ne.textCache){ne.textCache=Z,delete ne.actualWidth;for(let ce=X.length;ce--;)$.removeChild(X[ce]);if(Y||this.ellipsis||this.width||ne.textPath||B.indexOf(" ")!==-1&&(!this.noWrap||/<br.*?>/g.test(B))){if(B!==""){U&&U.appendChild($);let ce=new c(B);this.modifyTree(ce.nodes),ce.addToDOM($),this.modifyDOM(),this.ellipsis&&($.textContent||"").indexOf("…")!==-1&&ne.attr("title",this.unescapeEntities(ne.textStr||"",["&lt;","&gt;"])),U&&U.removeChild($)}}else $.appendChild(p.createTextNode(this.unescapeEntities(B)));k(this.textOutline)&&ne.applyTextOutline&&ne.applyTextOutline(this.textOutline)}}modifyDOM(){let ne,$=this.svgElement,L=x($.element,"x");for($.firstLineMetrics=void 0;(ne=$.element.firstChild)&&/^[\s\u200B]*$/.test(ne.textContent||" ");)$.element.removeChild(ne);[].forEach.call($.element.querySelectorAll("tspan.highcharts-br"),(U,Z)=>{U.nextSibling&&U.previousSibling&&(Z===0&&U.previousSibling.nodeType===1&&($.firstLineMetrics=$.renderer.fontMetrics(U.previousSibling)),x(U,{dy:this.getLineHeight(U.nextSibling),x:L}))});let B=this.width||0;if(!B)return;let Y=(U,Z)=>{let ce=U.textContent||"",se=ce.replace(/([^\^])-/g,"$1- ").split(" "),I=!this.noWrap&&(se.length>1||$.element.childNodes.length>1),H=this.getLineHeight(Z),Q=0,F=$.actualWidth;if(this.ellipsis)ce&&this.truncate(U,ce,void 0,0,Math.max(0,B-.8*H),(E,M)=>E.substring(0,M)+"…");else if(I){let E=[],M=[];for(;Z.firstChild&&Z.firstChild!==U;)M.push(Z.firstChild),Z.removeChild(Z.firstChild);for(;se.length;)se.length&&!this.noWrap&&Q>0&&(E.push(U.textContent||""),U.textContent=se.join(" ").replace(/- /g,"-")),this.truncate(U,void 0,se,Q===0&&F||0,B,(R,V)=>se.slice(0,V).join(" ").replace(/- /g,"-")),F=$.actualWidth,Q++;M.forEach(R=>{Z.insertBefore(R,U)}),E.forEach(R=>{Z.insertBefore(p.createTextNode(R),U);let V=p.createElementNS(m,"tspan");V.textContent="​",x(V,{dy:H,x:L}),Z.insertBefore(V,U)})}},X=U=>{[].slice.call(U.childNodes).forEach(Z=>{Z.nodeType===v.Node.TEXT_NODE?Y(Z,U):(Z.className.baseVal.indexOf("highcharts-br")!==-1&&($.actualWidth=0),X(Z))})};X($.element)}getLineHeight(ne){let $=ne.nodeType===v.Node.TEXT_NODE?ne.parentElement:ne;return this.textLineHeight?parseInt(this.textLineHeight.toString(),10):this.renderer.fontMetrics($||this.svgElement.element).h}modifyTree(ne){let $=(L,B)=>{let{attributes:Y={},children:X,style:U={},tagName:Z}=L,ce=this.renderer.styledMode;if(Z==="b"||Z==="strong"?ce?Y.class="highcharts-strong":U.fontWeight="bold":(Z==="i"||Z==="em")&&(ce?Y.class="highcharts-emphasized":U.fontStyle="italic"),U&&U.color&&(U.fill=U.color),Z==="br"){Y.class="highcharts-br",L.textContent="​";let se=ne[B+1];se&&se.textContent&&(se.textContent=se.textContent.replace(/^ +/gm,""))}else Z==="a"&&X&&X.some(se=>se.tagName==="#text")&&(L.children=[{children:X,tagName:"tspan"}]);Z!=="#text"&&Z!=="a"&&(L.tagName="tspan"),_(L,{attributes:Y,style:U}),X&&X.filter(se=>se.tagName!=="#text").forEach($)};ne.forEach($),T(this.svgElement,"afterModifyTree",{nodes:ne})}truncate(ne,$,L,B,Y,X){let U,Z,ce=this.svgElement,{rotation:se}=ce,I=[],H=L?1:0,Q=($||L||"").length,F=Q,E=function(M,R){let V=R||M,ae=ne.parentNode;if(ae&&I[V]===void 0&&ae.getSubStringLength)try{I[V]=B+ae.getSubStringLength(0,L?V+1:V)}catch{}return I[V]};if(ce.rotation=0,B+(Z=E(ne.textContent.length))>Y){for(;H<=Q;)F=Math.ceil((H+Q)/2),L&&(U=X(L,F)),Z=E(F,U&&U.length-1),H===Q?H=Q+1:Z>Y?Q=F-1:H=F;Q===0?ne.textContent="":$&&Q===$.length-1||(ne.textContent=U||X($||L,F))}L&&L.splice(0,F),ce.actualWidth=Z,ce.rotation=se}unescapeEntities(ne,$){return C(this.renderer.escapes,function(L,B){$&&$.indexOf(L)!==-1||(ne=ne.toString().replace(RegExp(L,"g"),B))}),ne}}}),r(a,"Core/Renderer/SVG/SVGRenderer.js",[a["Core/Renderer/HTML/AST.js"],a["Core/Defaults.js"],a["Core/Color/Color.js"],a["Core/Globals.js"],a["Core/Renderer/RendererRegistry.js"],a["Core/Renderer/SVG/SVGElement.js"],a["Core/Renderer/SVG/SVGLabel.js"],a["Core/Renderer/SVG/Symbols.js"],a["Core/Renderer/SVG/TextBuilder.js"],a["Core/Utilities.js"]],function(c,u,h,p,m,v,x,_,T,k){let C,{defaultOptions:G}=u,{charts:ne,deg2rad:$,doc:L,isFirefox:B,isMS:Y,isWebKit:X,noop:U,SVG_NS:Z,symbolSizes:ce,win:se}=p,{addEvent:I,attr:H,createElement:Q,crisp:F,css:E,defined:M,destroyObjectProperties:R,extend:V,isArray:ae,isNumber:oe,isObject:A,isString:ue,merge:me,pick:g,pInt:D,replaceNested:j,uniqueKey:K}=k;class te{constructor(z,W,de,P,ee,J,le){let re,ge,ve=this.createElement("svg").attr({version:"1.1",class:"highcharts-root"}),we=ve.element;le||ve.css(this.getStyle(P||{})),z.appendChild(we),H(z,"dir","ltr"),z.innerHTML.indexOf("xmlns")===-1&&H(we,"xmlns",this.SVG_NS),this.box=we,this.boxWrapper=ve,this.alignedObjects=[],this.url=this.getReferenceURL(),this.createElement("desc").add().element.appendChild(L.createTextNode("Created with Highcharts 11.4.8")),this.defs=this.createElement("defs").add(),this.allowHTML=J,this.forExport=ee,this.styledMode=le,this.gradients={},this.cache={},this.cacheKeys=[],this.imgCount=0,this.rootFontSize=ve.getStyle("font-size"),this.setSize(W,de,!1),B&&z.getBoundingClientRect&&((re=function(){E(z,{left:0,top:0}),ge=z.getBoundingClientRect(),E(z,{left:Math.ceil(ge.left)-ge.left+"px",top:Math.ceil(ge.top)-ge.top+"px"})})(),this.unSubPixelFix=I(se,"resize",re))}definition(z){return new c([z]).addToDOM(this.defs.element)}getReferenceURL(){if((B||X)&&L.getElementsByTagName("base").length){if(!M(C)){let z=K(),W=new c([{tagName:"svg",attributes:{width:8,height:8},children:[{tagName:"defs",children:[{tagName:"clipPath",attributes:{id:z},children:[{tagName:"rect",attributes:{width:4,height:4}}]}]},{tagName:"rect",attributes:{id:"hitme",width:8,height:8,"clip-path":`url(#${z})`,fill:"rgba(0,0,0,0.001)"}}]}]).addToDOM(L.body);E(W,{position:"fixed",top:0,left:0,zIndex:9e5});let de=L.elementFromPoint(6,6);C=(de&&de.id)==="hitme",L.body.removeChild(W)}if(C)return j(se.location.href.split("#")[0],[/<[^>]*>/g,""],[/([\('\)])/g,"\\$1"],[/ /g,"%20"])}return""}getStyle(z){return this.style=V({fontFamily:"Helvetica, Arial, sans-serif",fontSize:"1rem"},z),this.style}setStyle(z){this.boxWrapper.css(this.getStyle(z))}isHidden(){return!this.boxWrapper.getBBox().width}destroy(){let z=this.defs;return this.box=null,this.boxWrapper=this.boxWrapper.destroy(),R(this.gradients||{}),this.gradients=null,this.defs=z.destroy(),this.unSubPixelFix&&this.unSubPixelFix(),this.alignedObjects=null,null}createElement(z){return new this.Element(this,z)}getRadialAttr(z,W){return{cx:z[0]-z[2]/2+(W.cx||0)*z[2],cy:z[1]-z[2]/2+(W.cy||0)*z[2],r:(W.r||0)*z[2]}}shadowDefinition(z){let W=[`highcharts-drop-shadow-${this.chartIndex}`,...Object.keys(z).map(P=>`${P}-${z[P]}`)].join("-").toLowerCase().replace(/[^a-z\d\-]/g,""),de=me({color:"#000000",offsetX:1,offsetY:1,opacity:.15,width:5},z);return this.defs.element.querySelector(`#${W}`)||this.definition({tagName:"filter",attributes:{id:W,filterUnits:de.filterUnits},children:this.getShadowFilterContent(de)}),W}getShadowFilterContent(z){return[{tagName:"feDropShadow",attributes:{dx:z.offsetX,dy:z.offsetY,"flood-color":z.color,"flood-opacity":Math.min(5*z.opacity,1),stdDeviation:z.width/2}}]}buildText(z){new T(z).buildSVG()}getContrast(z){let W=h.parse(z).rgba.map(P=>{let ee=P/255;return ee<=.03928?ee/12.92:Math.pow((ee+.055)/1.055,2.4)}),de=.2126*W[0]+.7152*W[1]+.0722*W[2];return 1.05/(de+.05)>(de+.05)/.05?"#FFFFFF":"#000000"}button(z,W,de,P,ee={},J,le,re,ge,ve){let we=this.label(z,W,de,ge,void 0,void 0,ve,void 0,"button"),Ce=this.styledMode,Me=arguments,De=0;ee=me(G.global.buttonTheme,ee),Ce&&(delete ee.fill,delete ee.stroke,delete ee["stroke-width"]);let be=ee.states||{},ye=ee.style||{};delete ee.states,delete ee.style;let xe=[c.filterUserAttributes(ee)],pe=[ye];return Ce||["hover","select","disabled"].forEach((Se,Ae)=>{xe.push(me(xe[0],c.filterUserAttributes(Me[Ae+5]||be[Se]||{}))),pe.push(xe[Ae+1].style),delete xe[Ae+1].style}),I(we.element,Y?"mouseover":"mouseenter",function(){De!==3&&we.setState(1)}),I(we.element,Y?"mouseout":"mouseleave",function(){De!==3&&we.setState(De)}),we.setState=(Se=0)=>{if(Se!==1&&(we.state=De=Se),we.removeClass(/highcharts-button-(normal|hover|pressed|disabled)/).addClass("highcharts-button-"+["normal","hover","pressed","disabled"][Se]),!Ce){we.attr(xe[Se]);let Ae=pe[Se];A(Ae)&&we.css(Ae)}},we.attr(xe[0]),!Ce&&(we.css(V({cursor:"default"},ye)),ve&&we.text.css({pointerEvents:"none"})),we.on("touchstart",Se=>Se.stopPropagation()).on("click",function(Se){De!==3&&P.call(we,Se)})}crispLine(z,W){let[de,P]=z;return M(de[1])&&de[1]===P[1]&&(de[1]=P[1]=F(de[1],W)),M(de[2])&&de[2]===P[2]&&(de[2]=P[2]=F(de[2],W)),z}path(z){let W=this.styledMode?{}:{fill:"none"};return ae(z)?W.d=z:A(z)&&V(W,z),this.createElement("path").attr(W)}circle(z,W,de){let P=A(z)?z:z===void 0?{}:{x:z,y:W,r:de},ee=this.createElement("circle");return ee.xSetter=ee.ySetter=function(J,le,re){re.setAttribute("c"+le,J)},ee.attr(P)}arc(z,W,de,P,ee,J){let le;A(z)?(W=(le=z).y,de=le.r,P=le.innerR,ee=le.start,J=le.end,z=le.x):le={innerR:P,start:ee,end:J};let re=this.symbol("arc",z,W,de,de,le);return re.r=de,re}rect(z,W,de,P,ee,J){let le=A(z)?z:z===void 0?{}:{x:z,y:W,r:ee,width:Math.max(de||0,0),height:Math.max(P||0,0)},re=this.createElement("rect");return this.styledMode||(J!==void 0&&(le["stroke-width"]=J,V(le,re.crisp(le))),le.fill="none"),re.rSetter=function(ge,ve,we){re.r=ge,H(we,{rx:ge,ry:ge})},re.rGetter=function(){return re.r||0},re.attr(le)}roundedRect(z){return this.symbol("roundedRect").attr(z)}setSize(z,W,de){this.width=z,this.height=W,this.boxWrapper.animate({width:z,height:W},{step:function(){this.attr({viewBox:"0 0 "+this.attr("width")+" "+this.attr("height")})},duration:g(de,!0)?void 0:0}),this.alignElements()}g(z){let W=this.createElement("g");return z?W.attr({class:"highcharts-"+z}):W}image(z,W,de,P,ee,J){let le={preserveAspectRatio:"none"};oe(W)&&(le.x=W),oe(de)&&(le.y=de),oe(P)&&(le.width=P),oe(ee)&&(le.height=ee);let re=this.createElement("image").attr(le),ge=function(ve){re.attr({href:z}),J.call(re,ve)};if(J){re.attr({href:"data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw=="});let ve=new se.Image;I(ve,"load",ge),ve.src=z,ve.complete&&ge({})}else re.attr({href:z});return re}symbol(z,W,de,P,ee,J){let le,re,ge,ve,we=this,Ce=/^url\((.*?)\)$/,Me=Ce.test(z),De=!Me&&(this.symbols[z]?z:"circle"),be=De&&this.symbols[De];if(be)typeof W=="number"&&(re=be.call(this.symbols,W||0,de||0,P||0,ee||0,J)),le=this.path(re),we.styledMode||le.attr("fill","none"),V(le,{symbolName:De||void 0,x:W,y:de,width:P,height:ee}),J&&V(le,J);else if(Me){ge=z.match(Ce)[1];let ye=le=this.image(ge);ye.imgwidth=g(J&&J.width,ce[ge]&&ce[ge].width),ye.imgheight=g(J&&J.height,ce[ge]&&ce[ge].height),ve=xe=>xe.attr({width:xe.width,height:xe.height}),["width","height"].forEach(xe=>{ye[`${xe}Setter`]=function(pe,Se){this[Se]=pe;let{alignByTranslate:Ae,element:Te,width:Oe,height:ze,imgwidth:Ge,imgheight:Ve}=this,qe=Se==="width"?Ge:Ve,ot=1;J&&J.backgroundSize==="within"&&Oe&&ze&&Ge&&Ve?(ot=Math.min(Oe/Ge,ze/Ve),H(Te,{width:Math.round(Ge*ot),height:Math.round(Ve*ot)})):Te&&qe&&Te.setAttribute(Se,qe),!Ae&&Ge&&Ve&&this.translate(((Oe||0)-Ge*ot)/2,((ze||0)-Ve*ot)/2)}}),M(W)&&ye.attr({x:W,y:de}),ye.isImg=!0,ye.symbolUrl=z,M(ye.imgwidth)&&M(ye.imgheight)?ve(ye):(ye.attr({width:0,height:0}),Q("img",{onload:function(){let xe=ne[we.chartIndex];this.width===0&&(E(this,{position:"absolute",top:"-999em"}),L.body.appendChild(this)),ce[ge]={width:this.width,height:this.height},ye.imgwidth=this.width,ye.imgheight=this.height,ye.element&&ve(ye),this.parentNode&&this.parentNode.removeChild(this),we.imgCount--,we.imgCount||!xe||xe.hasLoaded||xe.onload()},src:ge}),this.imgCount++)}return le}clipRect(z,W,de,P){return this.rect(z,W,de,P,0)}text(z,W,de,P){let ee={};if(P&&(this.allowHTML||!this.forExport))return this.html(z,W,de);ee.x=Math.round(W||0),de&&(ee.y=Math.round(de)),M(z)&&(ee.text=z);let J=this.createElement("text").attr(ee);return P&&(!this.forExport||this.allowHTML)||(J.xSetter=function(le,re,ge){let ve=ge.getElementsByTagName("tspan"),we=ge.getAttribute(re);for(let Ce=0,Me;Ce<ve.length;Ce++)(Me=ve[Ce]).getAttribute(re)===we&&Me.setAttribute(re,le);ge.setAttribute(re,le)}),J}fontMetrics(z){let W=D(v.prototype.getStyle.call(z,"font-size")||0),de=W<24?W+3:Math.round(1.2*W),P=Math.round(.8*de);return{h:de,b:P,f:W}}rotCorr(z,W,de){let P=z;return W&&de&&(P=Math.max(P*Math.cos(W*$),4)),{x:-z/3*Math.sin(W*$),y:P}}pathToSegments(z){let W=[],de=[],P={A:8,C:7,H:2,L:3,M:3,Q:5,S:5,T:3,V:2};for(let ee=0;ee<z.length;ee++)ue(de[0])&&oe(z[ee])&&de.length===P[de[0].toUpperCase()]&&z.splice(ee,0,de[0].replace("M","L").replace("m","l")),typeof z[ee]=="string"&&(de.length&&W.push(de.slice(0)),de.length=0),de.push(z[ee]);return W.push(de.slice(0)),W}label(z,W,de,P,ee,J,le,re,ge){return new x(this,z,W,de,P,ee,J,le,re,ge)}alignElements(){this.alignedObjects.forEach(z=>z.align())}}return V(te.prototype,{Element:v,SVG_NS:Z,escapes:{"&":"&amp;","<":"&lt;",">":"&gt;","'":"&#39;",'"':"&quot;"},symbols:_,draw:U}),m.registerRendererType("svg",te,!0),te}),r(a,"Core/Renderer/HTML/HTMLElement.js",[a["Core/Renderer/HTML/AST.js"],a["Core/Globals.js"],a["Core/Renderer/SVG/SVGElement.js"],a["Core/Utilities.js"]],function(c,u,h,p){let{composed:m}=u,{attr:v,css:x,createElement:_,defined:T,extend:k,pInt:C,pushUnique:G}=p;function ne(Y,X,U){var ce;let Z=((ce=this.div)==null?void 0:ce.style)||U.style;h.prototype[`${X}Setter`].call(this,Y,X,U),Z&&(Z[X]=Y)}let $=(Y,X)=>{var U;if(!Y.div){let Z=v(Y.element,"class"),ce=Y.css,se=_("div",Z?{className:Z}:void 0,{position:"absolute",left:`${Y.translateX||0}px`,top:`${Y.translateY||0}px`,...Y.styles,display:Y.display,opacity:Y.opacity,visibility:Y.visibility},((U=Y.parentGroup)==null?void 0:U.div)||X);Y.classSetter=(I,H,Q)=>{Q.setAttribute("class",I),se.className=I},Y.translateXSetter=Y.translateYSetter=(I,H)=>{Y[H]=I,se.style[H==="translateX"?"left":"top"]=`${I}px`,Y.doTransform=!0},Y.opacitySetter=Y.visibilitySetter=ne,Y.css=I=>(ce.call(Y,I),I.cursor&&(se.style.cursor=I.cursor),I.pointerEvents&&(se.style.pointerEvents=I.pointerEvents),Y),Y.on=function(){return h.prototype.on.apply({element:se,onEvents:Y.onEvents},arguments),Y},Y.div=se}return Y.div};class L extends h{static compose(X){G(m,this.compose)&&(X.prototype.html=function(U,Z,ce){return new L(this,"span").attr({text:U,x:Math.round(Z),y:Math.round(ce)})})}constructor(X,U){super(X,U),this.css({position:"absolute",...X.styledMode?{}:{fontFamily:X.style.fontFamily,fontSize:X.style.fontSize}}),this.element.style.whiteSpace="nowrap"}getSpanCorrection(X,U,Z){this.xCorr=-X*Z,this.yCorr=-U}css(X){let U,{element:Z}=this,ce=Z.tagName==="SPAN"&&X&&"width"in X,se=ce&&X.width;return ce&&(delete X.width,this.textWidth=C(se)||void 0,U=!0),(X==null?void 0:X.textOverflow)==="ellipsis"&&(X.whiteSpace="nowrap",X.overflow="hidden"),k(this.styles,X),x(Z,X),U&&this.updateTransform(),this}htmlGetBBox(){let{element:X}=this;return{x:X.offsetLeft,y:X.offsetTop,width:X.offsetWidth,height:X.offsetHeight}}updateTransform(){var oe;if(!this.added){this.alignOnAdd=!0;return}let{element:X,renderer:U,rotation:Z,rotationOriginX:ce,rotationOriginY:se,styles:I,textAlign:H="left",textWidth:Q,translateX:F=0,translateY:E=0,x:M=0,y:R=0}=this,V={left:0,center:.5,right:1}[H],ae=I.whiteSpace;if(x(X,{marginLeft:`${F}px`,marginTop:`${E}px`}),X.tagName==="SPAN"){let A=[Z,H,X.innerHTML,Q,this.textAlign].join(","),ue=-(((oe=this.parentGroup)==null?void 0:oe.padding)*1)||0,me,g=!1;if(Q!==this.oldTextWidth){let O=this.textPxLength?this.textPxLength:(x(X,{width:"",whiteSpace:ae||"nowrap"}),X.offsetWidth),z=Q||0;(z>this.oldTextWidth||O>z)&&(/[ \-]/.test(X.textContent||X.innerText)||X.style.textOverflow==="ellipsis")&&(x(X,{width:O>z||Z?Q+"px":"auto",display:"block",whiteSpace:ae||"normal"}),this.oldTextWidth=Q,g=!0)}this.hasBoxWidthChanged=g,A!==this.cTT&&(me=U.fontMetrics(X).b,T(Z)&&(Z!==(this.oldRotation||0)||H!==this.oldAlign)&&this.setSpanRotation(Z,ue,ue),this.getSpanCorrection(!T(Z)&&this.textPxLength||X.offsetWidth,me,V));let{xCorr:D=0,yCorr:j=0}=this,K=(ce??M)-D-M-ue,te=(se??R)-j-R-ue;x(X,{left:`${M+D}px`,top:`${R+j}px`,transformOrigin:`${K}px ${te}px`}),this.cTT=A,this.oldRotation=Z,this.oldAlign=H}}setSpanRotation(X,U,Z){x(this.element,{transform:`rotate(${X}deg)`,transformOrigin:`${U}% ${Z}px`})}add(X){let U,Z=this.renderer.box.parentNode,ce=[];if(this.parentGroup=X,X&&!(U=X.div)){let se=X;for(;se;)ce.push(se),se=se.parentGroup;for(let I of ce.reverse())U=$(I,Z)}return(U||Z).appendChild(this.element),this.added=!0,this.alignOnAdd&&this.updateTransform(),this}textSetter(X){X!==this.textStr&&(delete this.bBox,delete this.oldTextWidth,c.setElementHTML(this.element,X??""),this.textStr=X,this.doTransform=!0)}alignSetter(X){this.alignValue=this.textAlign=X,this.doTransform=!0}xSetter(X,U){this[U]=X,this.doTransform=!0}}let B=L.prototype;return B.visibilitySetter=B.opacitySetter=ne,B.ySetter=B.rotationSetter=B.rotationOriginXSetter=B.rotationOriginYSetter=B.xSetter,L}),r(a,"Core/Axis/AxisDefaults.js",[],function(){var c,u;return(u=c||(c={})).xAxis={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:{autoRotationLimit:80,distance:15,enabled:!0,indentation:10,overflow:"justify",reserveSpace:void 0,rotation:void 0,staggerLines:0,step:0,useHTML:!1,zIndex:7,style:{color:"#333333",cursor:"default",fontSize:"0.8em"}},maxPadding:.01,minorGridLineDashStyle:"Solid",minorTickLength:2,minorTickPosition:"outside",minorTicksPerMajor:5,minPadding:.01,offset:void 0,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",useHTML:!1,x:0,y:0,style:{color:"#666666",fontSize:"0.8em"}},visible:!0,minorGridLineColor:"#f2f2f2",minorGridLineWidth:1,minorTickColor:"#999999",lineColor:"#333333",lineWidth:1,gridLineColor:"#e6e6e6",gridLineWidth:void 0,tickColor:"#333333"},u.yAxis={reversedStacks:!0,endOnTick:!0,maxPadding:.05,minPadding:.05,tickPixelInterval:72,showLastLabel:!0,labels:{x:void 0},startOnTick:!0,title:{text:"Values"},stackLabels:{animation:{},allowOverlap:!1,enabled:!1,crop:!0,overflow:"justify",formatter:function(){let{numberFormatter:h}=this.axis.chart;return h(this.total||0,-1)},style:{color:"#000000",fontSize:"0.7em",fontWeight:"bold",textOutline:"1px contrast"}},gridLineWidth:1,lineWidth:0},c}),r(a,"Core/Foundation.js",[a["Core/Utilities.js"]],function(c){var u;let{addEvent:h,isFunction:p,objectEach:m,removeEvent:v}=c;return(u||(u={})).registerEventOptions=function(x,_){x.eventOptions=x.eventOptions||{},m(_.events,function(T,k){x.eventOptions[k]!==T&&(x.eventOptions[k]&&(v(x,k,x.eventOptions[k]),delete x.eventOptions[k]),p(T)&&(x.eventOptions[k]=T,h(x,k,T,{order:0})))})},u}),r(a,"Core/Axis/Tick.js",[a["Core/Templating.js"],a["Core/Globals.js"],a["Core/Utilities.js"]],function(c,u,h){let{deg2rad:p}=u,{clamp:m,correctFloat:v,defined:x,destroyObjectProperties:_,extend:T,fireEvent:k,isNumber:C,merge:G,objectEach:ne,pick:$}=h;return class{constructor(L,B,Y,X,U){this.isNew=!0,this.isNewLabel=!0,this.axis=L,this.pos=B,this.type=Y||"",this.parameters=U||{},this.tickmarkOffset=this.parameters.tickmarkOffset,this.options=this.parameters.options,k(this,"init"),Y||X||this.addLabel()}addLabel(){let L=this,B=L.axis,Y=B.options,X=B.chart,U=B.categories,Z=B.logarithmic,ce=B.names,se=L.pos,I=$(L.options&&L.options.labels,Y.labels),H=B.tickPositions,Q=se===H[0],F=se===H[H.length-1],E=(!I.step||I.step===1)&&B.tickInterval===1,M=H.info,R=L.label,V,ae,oe,A=this.parameters.category||(U?$(U[se],ce[se],se):se);Z&&C(A)&&(A=v(Z.lin2log(A))),B.dateTime&&(M?V=(ae=X.time.resolveDTLFormat(Y.dateTimeLabelFormats[!Y.grid&&M.higherRanks[se]||M.unitName])).main:C(A)&&(V=B.dateTime.getXDateFormat(A,Y.dateTimeLabelFormats||{}))),L.isFirst=Q,L.isLast=F;let ue={axis:B,chart:X,dateTimeLabelFormat:V,isFirst:Q,isLast:F,pos:se,tick:L,tickPositionInfo:M,value:A};k(this,"labelFormat",ue);let me=j=>I.formatter?I.formatter.call(j,j):I.format?(j.text=B.defaultLabelFormatter.call(j),c.format(I.format,j,X)):B.defaultLabelFormatter.call(j),g=me.call(ue,ue),D=ae&&ae.list;D?L.shortenLabel=function(){for(oe=0;oe<D.length;oe++)if(T(ue,{dateTimeLabelFormat:D[oe]}),R.attr({text:me.call(ue,ue)}),R.getBBox().width<B.getSlotWidth(L)-2*(I.padding||0))return;R.attr({text:""})}:L.shortenLabel=void 0,E&&B._addedPlotLB&&L.moveLabel(g,I),x(R)||L.movedLabel?R&&R.textStr!==g&&!E&&(!R.textWidth||I.style.width||R.styles.width||R.css({width:null}),R.attr({text:g}),R.textPxLength=R.getBBox().width):(L.label=R=L.createLabel(g,I),L.rotation=0)}createLabel(L,B,Y){let X=this.axis,U=X.chart,Z=x(L)&&B.enabled?U.renderer.text(L,Y==null?void 0:Y.x,Y==null?void 0:Y.y,B.useHTML).add(X.labelGroup):void 0;return Z&&(U.styledMode||Z.css(G(B.style)),Z.textPxLength=Z.getBBox().width),Z}destroy(){_(this,this.axis)}getPosition(L,B,Y,X){let U=this.axis,Z=U.chart,ce=X&&Z.oldChartHeight||Z.chartHeight,se={x:L?v(U.translate(B+Y,void 0,void 0,X)+U.transB):U.left+U.offset+(U.opposite?(X&&Z.oldChartWidth||Z.chartWidth)-U.right-U.left:0),y:L?ce-U.bottom+U.offset-(U.opposite?U.height:0):v(ce-U.translate(B+Y,void 0,void 0,X)-U.transB)};return se.y=m(se.y,-1e9,1e9),k(this,"afterGetPosition",{pos:se}),se}getLabelPosition(L,B,Y,X,U,Z,ce,se){let I,H,Q=this.axis,F=Q.transA,E=Q.isLinked&&Q.linkedParent?Q.linkedParent.reversed:Q.reversed,M=Q.staggerLines,R=Q.tickRotCorr||{x:0,y:0},V=X||Q.reserveSpaceDefault?0:-Q.labelOffset*(Q.labelAlign==="center"?.5:1),ae=U.distance,oe={};return I=Q.side===0?Y.rotation?-ae:-Y.getBBox().height:Q.side===2?R.y+ae:Math.cos(Y.rotation*p)*(R.y-Y.getBBox(!1,0).height/2),x(U.y)&&(I=Q.side===0&&Q.horiz?U.y+I:U.y),L=L+$(U.x,[0,1,0,-1][Q.side]*ae)+V+R.x-(Z&&X?Z*F*(E?-1:1):0),B=B+I-(Z&&!X?Z*F*(E?1:-1):0),M&&(H=ce/(se||1)%M,Q.opposite&&(H=M-H-1),B+=H*(Q.labelOffset/M)),oe.x=L,oe.y=Math.round(B),k(this,"afterGetLabelPosition",{pos:oe,tickmarkOffset:Z,index:ce}),oe}getLabelSize(){return this.label?this.label.getBBox()[this.axis.horiz?"height":"width"]:0}getMarkPath(L,B,Y,X,U=!1,Z){return Z.crispLine([["M",L,B],["L",L+(U?0:-Y),B+(U?Y:0)]],X)}handleOverflow(L){let B=this.axis,Y=B.options.labels,X=L.x,U=B.chart.chartWidth,Z=B.chart.spacing,ce=$(B.labelLeft,Math.min(B.pos,Z[3])),se=$(B.labelRight,Math.max(B.isRadial?0:B.pos+B.len,U-Z[1])),I=this.label,H=this.rotation,Q={left:0,center:.5,right:1}[B.labelAlign||I.attr("align")],F=I.getBBox().width,E=B.getSlotWidth(this),M={},R=E,V=1,ae,oe,A;H||Y.overflow!=="justify"?H<0&&X-Q*F<ce?A=Math.round(X/Math.cos(H*p)-ce):H>0&&X+Q*F>se&&(A=Math.round((U-X)/Math.cos(H*p))):(ae=X-Q*F,oe=X+(1-Q)*F,ae<ce?R=L.x+R*(1-Q)-ce:oe>se&&(R=se-L.x+R*Q,V=-1),(R=Math.min(E,R))<E&&B.labelAlign==="center"&&(L.x+=V*(E-R-Q*(E-Math.min(F,R)))),(F>R||B.autoRotation&&(I.styles||{}).width)&&(A=R)),A&&(this.shortenLabel?this.shortenLabel():(M.width=Math.floor(A)+"px",(Y.style||{}).textOverflow||(M.textOverflow="ellipsis"),I.css(M)))}moveLabel(L,B){let Y=this,X=Y.label,U=Y.axis,Z=!1,ce;X&&X.textStr===L?(Y.movedLabel=X,Z=!0,delete Y.label):ne(U.ticks,function(se){Z||se.isNew||se===Y||!se.label||se.label.textStr!==L||(Y.movedLabel=se.label,Z=!0,se.labelPos=Y.movedLabel.xy,delete se.label)}),!Z&&(Y.labelPos||X)&&(ce=Y.labelPos||X.xy,Y.movedLabel=Y.createLabel(L,B,ce),Y.movedLabel&&Y.movedLabel.attr({opacity:0}))}render(L,B,Y){let X=this.axis,U=X.horiz,Z=this.pos,ce=$(this.tickmarkOffset,X.tickmarkOffset),se=this.getPosition(U,Z,ce,B),I=se.x,H=se.y,Q=X.pos,F=Q+X.len,E=U?I:H;!X.chart.polar&&this.isNew&&(v(E)<Q||E>F)&&(Y=0);let M=$(Y,this.label&&this.label.newOpacity,1);Y=$(Y,1),this.isActive=!0,this.renderGridLine(B,Y),this.renderMark(se,Y),this.renderLabel(se,B,M,L),this.isNew=!1,k(this,"afterRender")}renderGridLine(L,B){let Y=this.axis,X=Y.options,U={},Z=this.pos,ce=this.type,se=$(this.tickmarkOffset,Y.tickmarkOffset),I=Y.chart.renderer,H=this.gridLine,Q,F=X.gridLineWidth,E=X.gridLineColor,M=X.gridLineDashStyle;this.type==="minor"&&(F=X.minorGridLineWidth,E=X.minorGridLineColor,M=X.minorGridLineDashStyle),H||(Y.chart.styledMode||(U.stroke=E,U["stroke-width"]=F||0,U.dashstyle=M),ce||(U.zIndex=1),L&&(B=0),this.gridLine=H=I.path().attr(U).addClass("highcharts-"+(ce?ce+"-":"")+"grid-line").add(Y.gridGroup)),H&&(Q=Y.getPlotLinePath({value:Z+se,lineWidth:H.strokeWidth(),force:"pass",old:L,acrossPanes:!1}))&&H[L||this.isNew?"attr":"animate"]({d:Q,opacity:B})}renderMark(L,B){let Y=this.axis,X=Y.options,U=Y.chart.renderer,Z=this.type,ce=Y.tickSize(Z?Z+"Tick":"tick"),se=L.x,I=L.y,H=$(X[Z!=="minor"?"tickWidth":"minorTickWidth"],!Z&&Y.isXAxis?1:0),Q=X[Z!=="minor"?"tickColor":"minorTickColor"],F=this.mark,E=!F;ce&&(Y.opposite&&(ce[0]=-ce[0]),F||(this.mark=F=U.path().addClass("highcharts-"+(Z?Z+"-":"")+"tick").add(Y.axisGroup),Y.chart.styledMode||F.attr({stroke:Q,"stroke-width":H})),F[E?"attr":"animate"]({d:this.getMarkPath(se,I,ce[0],F.strokeWidth(),Y.horiz,U),opacity:B}))}renderLabel(L,B,Y,X){let U=this.axis,Z=U.horiz,ce=U.options,se=this.label,I=ce.labels,H=I.step,Q=$(this.tickmarkOffset,U.tickmarkOffset),F=L.x,E=L.y,M=!0;se&&C(F)&&(se.xy=L=this.getLabelPosition(F,E,se,Z,I,Q,X,H),(!this.isFirst||this.isLast||ce.showFirstLabel)&&(!this.isLast||this.isFirst||ce.showLastLabel)?!Z||I.step||I.rotation||B||Y===0||this.handleOverflow(L):M=!1,H&&X%H&&(M=!1),M&&C(L.y)?(L.opacity=Y,se[this.isNewLabel?"attr":"animate"](L).show(!0),this.isNewLabel=!1):(se.hide(),this.isNewLabel=!0))}replaceMovedLabel(){let L=this.label,B=this.axis;L&&!this.isNew&&(L.animate({opacity:0},void 0,L.destroy),delete this.label),B.isDirty=!0,this.label=this.movedLabel,delete this.movedLabel}}}),r(a,"Core/Axis/Axis.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Axis/AxisDefaults.js"],a["Core/Color/Color.js"],a["Core/Defaults.js"],a["Core/Foundation.js"],a["Core/Globals.js"],a["Core/Axis/Tick.js"],a["Core/Utilities.js"]],function(c,u,h,p,m,v,x,_){let{animObject:T}=c,{xAxis:k,yAxis:C}=u,{defaultOptions:G}=p,{registerEventOptions:ne}=m,{deg2rad:$}=v,{arrayMax:L,arrayMin:B,clamp:Y,correctFloat:X,defined:U,destroyObjectProperties:Z,erase:ce,error:se,extend:I,fireEvent:H,getClosestDistance:Q,insertItem:F,isArray:E,isNumber:M,isString:R,merge:V,normalizeTickInterval:ae,objectEach:oe,pick:A,relativeLength:ue,removeEvent:me,splat:g,syncTimeout:D}=_,j=(te,O)=>ae(O,void 0,void 0,A(te.options.allowDecimals,O<.5||te.tickAmount!==void 0),!!te.tickAmount);I(G,{xAxis:k,yAxis:V(k,C)});class K{constructor(O,z,W){this.init(O,z,W)}init(O,z,W=this.coll){let de=W==="xAxis",P=this.isZAxis||(O.inverted?!de:de);this.chart=O,this.horiz=P,this.isXAxis=de,this.coll=W,H(this,"init",{userOptions:z}),this.opposite=A(z.opposite,this.opposite),this.side=A(z.side,this.side,P?this.opposite?0:2:this.opposite?1:3),this.setOptions(z);let ee=this.options,J=ee.labels;this.type??(this.type=ee.type||"linear"),this.uniqueNames??(this.uniqueNames=ee.uniqueNames??!0),H(this,"afterSetType"),this.userOptions=z,this.minPixelPadding=0,this.reversed=A(ee.reversed,this.reversed),this.visible=ee.visible,this.zoomEnabled=ee.zoomEnabled,this.hasNames=this.type==="category"||ee.categories===!0,this.categories=E(ee.categories)&&ee.categories||(this.hasNames?[]:void 0),this.names||(this.names=[],this.names.keys={}),this.plotLinesAndBandsGroups={},this.positiveValuesOnly=!!this.logarithmic,this.isLinked=U(ee.linkedTo),this.ticks={},this.labelEdge=[],this.minorTicks={},this.plotLinesAndBands=[],this.alternateBands={},this.len??(this.len=0),this.minRange=this.userMinRange=ee.minRange||ee.maxZoom,this.range=ee.range,this.offset=ee.offset||0,this.max=void 0,this.min=void 0;let le=A(ee.crosshair,g(O.options.tooltip.crosshairs)[de?0:1]);this.crosshair=le===!0?{}:le,O.axes.indexOf(this)===-1&&(de?O.axes.splice(O.xAxis.length,0,this):O.axes.push(this),F(this,O[this.coll])),O.orderItems(this.coll),this.series=this.series||[],O.inverted&&!this.isZAxis&&de&&!U(this.reversed)&&(this.reversed=!0),this.labelRotation=M(J.rotation)?J.rotation:void 0,ne(this,ee),H(this,"afterInit")}setOptions(O){let z=this.horiz?{labels:{autoRotation:[-45],padding:4},margin:15}:{labels:{padding:1},title:{rotation:90*this.side}};this.options=V(z,G[this.coll],O),H(this,"afterSetOptions",{userOptions:O})}defaultLabelFormatter(){let O=this.axis,{numberFormatter:z}=this.chart,W=M(this.value)?this.value:NaN,de=O.chart.time,P=O.categories,ee=this.dateTimeLabelFormat,J=G.lang,le=J.numericSymbols,re=J.numericSymbolMagnitude||1e3,ge=O.logarithmic?Math.abs(W):O.tickInterval,ve=le&&le.length,we,Ce;if(P)Ce=`${this.value}`;else if(ee)Ce=de.dateFormat(ee,W);else if(ve&&le&&ge>=1e3)for(;ve--&&Ce===void 0;)ge>=(we=Math.pow(re,ve+1))&&10*W%we==0&&le[ve]!==null&&W!==0&&(Ce=z(W/we,-1)+le[ve]);return Ce===void 0&&(Ce=Math.abs(W)>=1e4?z(W,-1):z(W,-1,void 0,"")),Ce}getSeriesExtremes(){let O,z=this;H(this,"getSeriesExtremes",null,function(){z.hasVisibleSeries=!1,z.dataMin=z.dataMax=z.threshold=void 0,z.softThreshold=!z.isXAxis,z.series.forEach(W=>{if(W.reserveSpace()){let de=W.options,P,ee=de.threshold,J,le;if(z.hasVisibleSeries=!0,z.positiveValuesOnly&&0>=(ee||0)&&(ee=void 0),z.isXAxis)(P=W.xData)&&P.length&&(P=z.logarithmic?P.filter(re=>re>0):P,J=(O=W.getXExtremes(P)).min,le=O.max,M(J)||J instanceof Date||(P=P.filter(M),J=(O=W.getXExtremes(P)).min,le=O.max),P.length&&(z.dataMin=Math.min(A(z.dataMin,J),J),z.dataMax=Math.max(A(z.dataMax,le),le)));else{let re=W.applyExtremes();M(re.dataMin)&&(J=re.dataMin,z.dataMin=Math.min(A(z.dataMin,J),J)),M(re.dataMax)&&(le=re.dataMax,z.dataMax=Math.max(A(z.dataMax,le),le)),U(ee)&&(z.threshold=ee),(!de.softThreshold||z.positiveValuesOnly)&&(z.softThreshold=!1)}}})}),H(this,"afterGetSeriesExtremes")}translate(O,z,W,de,P,ee){var De;let J=this.linkedParent||this,le=de&&J.old?J.old.min:J.min;if(!M(le))return NaN;let re=J.minPixelPadding,ge=(J.isOrdinal||((De=J.brokenAxis)==null?void 0:De.hasBreaks)||J.logarithmic&&P)&&J.lin2val,ve=1,we=0,Ce=de&&J.old?J.old.transA:J.transA,Me=0;return Ce||(Ce=J.transA),W&&(ve*=-1,we=J.len),J.reversed&&(ve*=-1,we-=ve*(J.sector||J.len)),z?(Me=(O=O*ve+we-re)/Ce+le,ge&&(Me=J.lin2val(Me))):(ge&&(O=J.val2lin(O)),Me=ve*(O-le)*Ce+we+ve*re+(M(ee)?Ce*ee:0),J.isRadial||(Me=X(Me))),Me}toPixels(O,z){return this.translate(O,!1,!this.horiz,void 0,!0)+(z?0:this.pos)}toValue(O,z){return this.translate(O-(z?0:this.pos),!0,!this.horiz,void 0,!0)}getPlotLinePath(O){let z=this,W=z.chart,de=z.left,P=z.top,ee=O.old,J=O.value,le=O.lineWidth,re=ee&&W.oldChartHeight||W.chartHeight,ge=ee&&W.oldChartWidth||W.chartWidth,ve=z.transB,we=O.translatedValue,Ce=O.force,Me,De,be,ye,xe;function pe(Ae,Te,Oe){return Ce!=="pass"&&(Ae<Te||Ae>Oe)&&(Ce?Ae=Y(Ae,Te,Oe):xe=!0),Ae}let Se={value:J,lineWidth:le,old:ee,force:Ce,acrossPanes:O.acrossPanes,translatedValue:we};return H(this,"getPlotLinePath",Se,function(Ae){Me=be=(we=Y(we=A(we,z.translate(J,void 0,void 0,ee)),-1e9,1e9))+ve,De=ye=re-we-ve,M(we)?z.horiz?(De=P,ye=re-z.bottom+(z.options.isInternal?0:W.scrollablePixelsY||0),Me=be=pe(Me,de,de+z.width)):(Me=de,be=ge-z.right+(W.scrollablePixelsX||0),De=ye=pe(De,P,P+z.height)):(xe=!0,Ce=!1),Ae.path=xe&&!Ce?void 0:W.renderer.crispLine([["M",Me,De],["L",be,ye]],le||1)}),Se.path}getLinearTickPositions(O,z,W){let de,P,ee,J=X(Math.floor(z/O)*O),le=X(Math.ceil(W/O)*O),re=[];if(X(J+O)===J&&(ee=20),this.single)return[z];for(de=J;de<=le&&(re.push(de),(de=X(de+O,ee))!==P);)P=de;return re}getMinorTickInterval(){let{minorTicks:O,minorTickInterval:z}=this.options;return O===!0?A(z,"auto"):O!==!1?z:void 0}getMinorTickPositions(){let O=this.options,z=this.tickPositions,W=this.minorTickInterval,de=this.pointRangePadding||0,P=(this.min||0)-de,ee=(this.max||0)+de,J=ee-P,le=[],re;if(J&&J/W<this.len/3){let ge=this.logarithmic;if(ge)this.paddedTicks.forEach(function(ve,we,Ce){we&&le.push.apply(le,ge.getLogTickPositions(W,Ce[we-1],Ce[we],!0))});else if(this.dateTime&&this.getMinorTickInterval()==="auto")le=le.concat(this.getTimeTicks(this.dateTime.normalizeTimeTickInterval(W),P,ee,O.startOfWeek));else for(re=P+(z[0]-P)%W;re<=ee&&re!==le[0];re+=W)le.push(re)}return le.length!==0&&this.trimTicks(le),le}adjustForMinRange(){let O=this.options,z=this.logarithmic,{max:W,min:de,minRange:P}=this,ee,J,le,re;this.isXAxis&&P===void 0&&!z&&(P=U(O.min)||U(O.max)||U(O.floor)||U(O.ceiling)?null:Math.min(5*(Q(this.series.map(ge=>{var ve;return(ge.xIncrement?(ve=ge.xData)==null?void 0:ve.slice(0,2):ge.xData)||[]}))||0),this.dataMax-this.dataMin)),M(W)&&M(de)&&M(P)&&W-de<P&&(J=this.dataMax-this.dataMin>=P,ee=(P-W+de)/2,le=[de-ee,A(O.min,de-ee)],J&&(le[2]=z?z.log2lin(this.dataMin):this.dataMin),re=[(de=L(le))+P,A(O.max,de+P)],J&&(re[2]=z?z.log2lin(this.dataMax):this.dataMax),(W=B(re))-de<P&&(le[0]=W-P,le[1]=A(O.min,W-P),de=L(le))),this.minRange=P,this.min=de,this.max=W}getClosest(){let O,z;if(this.categories)z=1;else{let W=[];this.series.forEach(function(de){var ee;let P=de.closestPointRange;((ee=de.xData)==null?void 0:ee.length)===1?W.push(de.xData[0]):!de.noSharedTooltip&&U(P)&&de.reserveSpace()&&(z=U(z)?Math.min(z,P):P)}),W.length&&(W.sort((de,P)=>de-P),O=Q([W]))}return O&&z?Math.min(O,z):O||z}nameToX(O){let z=E(this.options.categories),W=z?this.categories:this.names,de=O.options.x,P;return O.series.requireSorting=!1,U(de)||(de=this.uniqueNames&&W?z?W.indexOf(O.name):A(W.keys[O.name],-1):O.series.autoIncrement()),de===-1?!z&&W&&(P=W.length):P=de,P!==void 0?(this.names[P]=O.name,this.names.keys[O.name]=P):O.x&&(P=O.x),P}updateNames(){let O=this,z=this.names;z.length>0&&(Object.keys(z.keys).forEach(function(W){delete z.keys[W]}),z.length=0,this.minRange=this.userMinRange,(this.series||[]).forEach(W=>{W.xIncrement=null,(!W.points||W.isDirtyData)&&(O.max=Math.max(O.max,W.xData.length-1),W.processData(),W.generatePoints()),W.data.forEach(function(de,P){let ee;de!=null&&de.options&&de.name!==void 0&&(ee=O.nameToX(de))!==void 0&&ee!==de.x&&(de.x=ee,W.xData[P]=ee)})}))}setAxisTranslation(){let O=this,z=O.max-O.min,W=O.linkedParent,de=!!O.categories,P=O.isXAxis,ee=O.axisPointRange||0,J,le=0,re=0,ge,ve=O.transA;(P||de||ee)&&(J=O.getClosest(),W?(le=W.minPointOffset,re=W.pointRangePadding):O.series.forEach(function(we){let Ce=de?1:P?A(we.options.pointRange,J,0):O.axisPointRange||0,Me=we.options.pointPlacement;if(ee=Math.max(ee,Ce),!O.single||de){let De=we.is("xrange")?!P:P;le=Math.max(le,De&&R(Me)?0:Ce/2),re=Math.max(re,De&&Me==="on"?0:Ce)}}),ge=O.ordinal&&O.ordinal.slope&&J?O.ordinal.slope/J:1,O.minPointOffset=le*=ge,O.pointRangePadding=re*=ge,O.pointRange=Math.min(ee,O.single&&de?1:z),P&&J&&(O.closestPointRange=J)),O.translationSlope=O.transA=ve=O.staticScale||O.len/(z+re||1),O.transB=O.horiz?O.left:O.bottom,O.minPixelPadding=ve*le,H(this,"afterSetAxisTranslation")}minFromRange(){let{max:O,min:z}=this;return M(O)&&M(z)&&O-z||void 0}setTickInterval(O){var dt,et,Pt,Ie;let{categories:z,chart:W,dataMax:de,dataMin:P,dateTime:ee,isXAxis:J,logarithmic:le,options:re,softThreshold:ge}=this,ve=M(this.threshold)?this.threshold:void 0,we=this.minRange||0,{ceiling:Ce,floor:Me,linkedTo:De,softMax:be,softMin:ye}=re,xe=M(De)&&((dt=W[this.coll])==null?void 0:dt[De]),pe=re.tickPixelInterval,Se=re.maxPadding,Ae=re.minPadding,Te=0,Oe,ze=M(re.tickInterval)&&re.tickInterval>=0?re.tickInterval:void 0,Ge,Ve,qe,ot;if(ee||z||xe||this.getTickAmount(),qe=A(this.userMin,re.min),ot=A(this.userMax,re.max),xe?(this.linkedParent=xe,Oe=xe.getExtremes(),this.min=A(Oe.min,Oe.dataMin),this.max=A(Oe.max,Oe.dataMax),this.type!==xe.type&&se(11,!0,W)):(ge&&U(ve)&&M(de)&&M(P)&&(P>=ve?(Ge=ve,Ae=0):de<=ve&&(Ve=ve,Se=0)),this.min=A(qe,Ge,P),this.max=A(ot,Ve,de)),M(this.max)&&M(this.min)&&(le&&(this.positiveValuesOnly&&!O&&0>=Math.min(this.min,A(P,this.min))&&se(10,!0,W),this.min=X(le.log2lin(this.min),16),this.max=X(le.log2lin(this.max),16)),this.range&&M(P)&&(this.userMin=this.min=qe=Math.max(P,this.minFromRange()||0),this.userMax=ot=this.max,this.range=void 0)),H(this,"foundExtremes"),this.adjustForMinRange(),M(this.min)&&M(this.max)){if(!M(this.userMin)&&M(ye)&&ye<this.min&&(this.min=qe=ye),!M(this.userMax)&&M(be)&&be>this.max&&(this.max=ot=be),z||this.axisPointRange||(et=this.stacking)!=null&&et.usePercentage||xe||!(Te=this.max-this.min)||(!U(qe)&&Ae&&(this.min-=Te*Ae),U(ot)||!Se||(this.max+=Te*Se)),!M(this.userMin)&&M(Me)&&(this.min=Math.max(this.min,Me)),!M(this.userMax)&&M(Ce)&&(this.max=Math.min(this.max,Ce)),ge&&M(P)&&M(de)){let gt=ve||0;!U(qe)&&this.min<gt&&P>=gt?this.min=re.minRange?Math.min(gt,this.max-we):gt:!U(ot)&&this.max>gt&&de<=gt&&(this.max=re.minRange?Math.max(gt,this.min+we):gt)}!W.polar&&this.min>this.max&&(U(re.min)?this.max=this.min:U(re.max)&&(this.min=this.max)),Te=this.max-this.min}if(this.min!==this.max&&M(this.min)&&M(this.max)?xe&&!ze&&pe===xe.options.tickPixelInterval?this.tickInterval=ze=xe.tickInterval:this.tickInterval=A(ze,this.tickAmount?Te/Math.max(this.tickAmount-1,1):void 0,z?1:Te*pe/Math.max(this.len,pe)):this.tickInterval=1,J&&!O){let gt=this.min!==((Pt=this.old)==null?void 0:Pt.min)||this.max!==((Ie=this.old)==null?void 0:Ie.max);this.series.forEach(function(Tt){var at;Tt.forceCrop=(at=Tt.forceCropping)==null?void 0:at.call(Tt),Tt.processData(gt)}),H(this,"postProcessData",{hasExtremesChanged:gt})}this.setAxisTranslation(),H(this,"initialAxisTranslation"),this.pointRange&&!ze&&(this.tickInterval=Math.max(this.pointRange,this.tickInterval));let ft=A(re.minTickInterval,ee&&!this.series.some(gt=>gt.noSharedTooltip)?this.closestPointRange:0);!ze&&this.tickInterval<ft&&(this.tickInterval=ft),ee||le||ze||(this.tickInterval=j(this,this.tickInterval)),this.tickAmount||(this.tickInterval=this.unsquish()),this.setTickPositions()}setTickPositions(){var ge,ve;let O=this.options,z=O.tickPositions,W=O.tickPositioner,de=this.getMinorTickInterval(),P=!this.isPanning,ee=P&&O.startOnTick,J=P&&O.endOnTick,le=[],re;if(this.tickmarkOffset=this.categories&&O.tickmarkPlacement==="between"&&this.tickInterval===1?.5:0,this.single=this.min===this.max&&U(this.min)&&!this.tickAmount&&(this.min%1==0||O.allowDecimals!==!1),z)le=z.slice();else if(M(this.min)&&M(this.max)){if(!((ge=this.ordinal)!=null&&ge.positions)&&(this.max-this.min)/this.tickInterval>Math.max(2*this.len,200))le=[this.min,this.max],se(19,!1,this.chart);else if(this.dateTime)le=this.getTimeTicks(this.dateTime.normalizeTimeTickInterval(this.tickInterval,O.units),this.min,this.max,O.startOfWeek,(ve=this.ordinal)==null?void 0:ve.positions,this.closestPointRange,!0);else if(this.logarithmic)le=this.logarithmic.getLogTickPositions(this.tickInterval,this.min,this.max);else{let we=this.tickInterval,Ce=we;for(;Ce<=2*we&&(le=this.getLinearTickPositions(this.tickInterval,this.min,this.max),this.tickAmount&&le.length>this.tickAmount);)this.tickInterval=j(this,Ce*=1.1)}le.length>this.len&&(le=[le[0],le[le.length-1]])[0]===le[1]&&(le.length=1),W&&(this.tickPositions=le,(re=W.apply(this,[this.min,this.max]))&&(le=re))}this.tickPositions=le,this.minorTickInterval=de==="auto"&&this.tickInterval?this.tickInterval/O.minorTicksPerMajor:de,this.paddedTicks=le.slice(0),this.trimTicks(le,ee,J),!this.isLinked&&M(this.min)&&M(this.max)&&(this.single&&le.length<2&&!this.categories&&!this.series.some(we=>we.is("heatmap")&&we.options.pointPlacement==="between")&&(this.min-=.5,this.max+=.5),z||re||this.adjustTickAmount()),H(this,"afterSetTickPositions")}trimTicks(O,z,W){let de=O[0],P=O[O.length-1],ee=!this.isOrdinal&&this.minPointOffset||0;if(H(this,"trimTicks"),!this.isLinked){if(z&&de!==-1/0)this.min=de;else for(;this.min-ee>O[0];)O.shift();if(W)this.max=P;else for(;this.max+ee<O[O.length-1];)O.pop();O.length===0&&U(de)&&!this.options.tickPositions&&O.push((P+de)/2)}}alignToOthers(){let O,z=this,W=z.chart,de=[this],P=z.options,ee=W.options.chart,J=this.coll==="yAxis"&&ee.alignThresholds,le=[];if(z.thresholdAlignment=void 0,(ee.alignTicks!==!1&&P.alignTicks||J)&&P.startOnTick!==!1&&P.endOnTick!==!1&&!z.logarithmic){let re=ve=>{let{horiz:we,options:Ce}=ve;return[we?Ce.left:Ce.top,Ce.width,Ce.height,Ce.pane].join(",")},ge=re(this);W[this.coll].forEach(function(ve){let{series:we}=ve;we.length&&we.some(Ce=>Ce.visible)&&ve!==z&&re(ve)===ge&&(O=!0,de.push(ve))})}if(O&&J){de.forEach(ge=>{let ve=ge.getThresholdAlignment(z);M(ve)&&le.push(ve)});let re=le.length>1?le.reduce((ge,ve)=>ge+=ve,0)/le.length:void 0;de.forEach(ge=>{ge.thresholdAlignment=re})}return O}getThresholdAlignment(O){if((!M(this.dataMin)||this!==O&&this.series.some(z=>z.isDirty||z.isDirtyData))&&this.getSeriesExtremes(),M(this.threshold)){let z=Y((this.threshold-(this.dataMin||0))/((this.dataMax||0)-(this.dataMin||0)),0,1);return this.options.reversed&&(z=1-z),z}}getTickAmount(){let O=this.options,z=O.tickPixelInterval,W=O.tickAmount;U(O.tickInterval)||W||!(this.len<z)||this.isRadial||this.logarithmic||!O.startOnTick||!O.endOnTick||(W=2),!W&&this.alignToOthers()&&(W=Math.ceil(this.len/z)+1),W<4&&(this.finalTickAmt=W,W=5),this.tickAmount=W}adjustTickAmount(){let O=this,{finalTickAmt:z,max:W,min:de,options:P,tickPositions:ee,tickAmount:J,thresholdAlignment:le}=O,re=ee==null?void 0:ee.length,ge=A(O.threshold,O.softThreshold?0:null),ve,we,Ce=O.tickInterval,Me,De=()=>ee.push(X(ee[ee.length-1]+Ce)),be=()=>ee.unshift(X(ee[0]-Ce));if(M(le)&&(Me=le<.5?Math.ceil(le*(J-1)):Math.floor(le*(J-1)),P.reversed&&(Me=J-1-Me)),O.hasData()&&M(de)&&M(W)){let ye=()=>{O.transA*=(re-1)/(J-1),O.min=P.startOnTick?ee[0]:Math.min(de,ee[0]),O.max=P.endOnTick?ee[ee.length-1]:Math.max(W,ee[ee.length-1])};if(M(Me)&&M(O.threshold)){for(;ee[Me]!==ge||ee.length!==J||ee[0]>de||ee[ee.length-1]<W;){for(ee.length=0,ee.push(O.threshold);ee.length<J;)ee[Me]===void 0||ee[Me]>O.threshold?be():De();if(Ce>8*O.tickInterval)break;Ce*=2}ye()}else if(re<J){for(;ee.length<J;)ee.length%2||de===ge?De():be();ye()}if(U(z)){for(we=ve=ee.length;we--;)(z===3&&we%2==1||z<=2&&we>0&&we<ve-1)&&ee.splice(we,1);O.finalTickAmt=void 0}}}setScale(){var ee,J;let{coll:O,stacking:z}=this,W=!1,de=!1;this.series.forEach(le=>{W=W||le.isDirtyData||le.isDirty,de=de||le.xAxis&&le.xAxis.isDirty||!1}),this.setAxisSize();let P=this.len!==(this.old&&this.old.len);P||W||de||this.isLinked||this.forceRedraw||this.userMin!==(this.old&&this.old.userMin)||this.userMax!==(this.old&&this.old.userMax)||this.alignToOthers()?(z&&O==="yAxis"&&z.buildStacks(),this.forceRedraw=!1,this.userMinRange||(this.minRange=void 0),this.getSeriesExtremes(),this.setTickInterval(),z&&O==="xAxis"&&z.buildStacks(),this.isDirty||(this.isDirty=P||this.min!==((ee=this.old)==null?void 0:ee.min)||this.max!==((J=this.old)==null?void 0:J.max))):z&&z.cleanStacks(),W&&delete this.allExtremes,H(this,"afterSetScale")}setExtremes(O,z,W=!0,de,P){this.series.forEach(ee=>{delete ee.kdTree}),H(this,"setExtremes",P=I(P,{min:O,max:z}),ee=>{this.userMin=ee.min,this.userMax=ee.max,this.eventArgs=ee,W&&this.chart.redraw(de)})}setAxisSize(){let O=this.chart,z=this.options,W=z.offsets||[0,0,0,0],de=this.horiz,P=this.width=Math.round(ue(A(z.width,O.plotWidth-W[3]+W[1]),O.plotWidth)),ee=this.height=Math.round(ue(A(z.height,O.plotHeight-W[0]+W[2]),O.plotHeight)),J=this.top=Math.round(ue(A(z.top,O.plotTop+W[0]),O.plotHeight,O.plotTop)),le=this.left=Math.round(ue(A(z.left,O.plotLeft+W[3]),O.plotWidth,O.plotLeft));this.bottom=O.chartHeight-ee-J,this.right=O.chartWidth-P-le,this.len=Math.max(de?P:ee,0),this.pos=de?le:J}getExtremes(){let O=this.logarithmic;return{min:O?X(O.lin2log(this.min)):this.min,max:O?X(O.lin2log(this.max)):this.max,dataMin:this.dataMin,dataMax:this.dataMax,userMin:this.userMin,userMax:this.userMax}}getThreshold(O){let z=this.logarithmic,W=z?z.lin2log(this.min):this.min,de=z?z.lin2log(this.max):this.max;return O===null||O===-1/0?O=W:O===1/0?O=de:W>O?O=W:de<O&&(O=de),this.translate(O,0,1,0,1)}autoLabelAlign(O){let z=(A(O,0)-90*this.side+720)%360,W={align:"center"};return H(this,"autoLabelAlign",W,function(de){z>15&&z<165?de.align="right":z>195&&z<345&&(de.align="left")}),W.align}tickSize(O){let z=this.options,W=A(z[O==="tick"?"tickWidth":"minorTickWidth"],O==="tick"&&this.isXAxis&&!this.categories?1:0),de=z[O==="tick"?"tickLength":"minorTickLength"],P;W&&de&&(z[O+"Position"]==="inside"&&(de=-de),P=[de,W]);let ee={tickSize:P};return H(this,"afterTickSize",ee),ee.tickSize}labelMetrics(){let O=this.chart.renderer,z=this.ticks,W=z[Object.keys(z)[0]]||{};return this.chart.renderer.fontMetrics(W.label||W.movedLabel||O.box)}unsquish(){let O=this.options.labels,z=O.padding||0,W=this.horiz,de=this.tickInterval,P=this.len/(((this.categories?1:0)+this.max-this.min)/de),ee=O.rotation,J=X(.8*this.labelMetrics().h),le=Math.max(this.max-this.min,0),re=function(Me){let De=(Me+2*z)/(P||1);return(De=De>1?Math.ceil(De):1)*de>le&&Me!==1/0&&P!==1/0&&le&&(De=Math.ceil(le/de)),X(De*de)},ge=de,ve,we=Number.MAX_VALUE,Ce;if(W){if(!O.staggerLines&&(M(ee)?Ce=[ee]:P<O.autoRotationLimit&&(Ce=O.autoRotation)),Ce){let Me,De;for(let be of Ce)(be===ee||be&&be>=-90&&be<=90)&&(De=(Me=re(Math.abs(J/Math.sin($*be))))+Math.abs(be/360))<we&&(we=De,ve=be,ge=Me)}}else ge=re(.75*J);return this.autoRotation=Ce,this.labelRotation=A(ve,M(ee)?ee:0),O.step?de:ge}getSlotWidth(O){let z=this.chart,W=this.horiz,de=this.options.labels,P=Math.max(this.tickPositions.length-(this.categories?0:1),1),ee=z.margin[3];if(O&&M(O.slotWidth))return O.slotWidth;if(W&&de.step<2)return de.rotation?0:(this.staggerLines||1)*this.len/P;if(!W){let J=de.style.width;if(J!==void 0)return parseInt(String(J),10);if(ee)return ee-z.spacing[3]}return .33*z.chartWidth}renderUnsquish(){let O=this.chart,z=O.renderer,W=this.tickPositions,de=this.ticks,P=this.options.labels,ee=P.style,J=this.horiz,le=this.getSlotWidth(),re=Math.max(1,Math.round(le-(J?2*(P.padding||0):P.distance||0))),ge={},ve=this.labelMetrics(),we=ee.textOverflow,Ce,Me,De=0,be,ye;if(R(P.rotation)||(ge.rotation=P.rotation||0),W.forEach(function(xe){let pe=de[xe];pe.movedLabel&&pe.replaceMovedLabel(),pe&&pe.label&&pe.label.textPxLength>De&&(De=pe.label.textPxLength)}),this.maxLabelLength=De,this.autoRotation)De>re&&De>ve.h?ge.rotation=this.labelRotation:this.labelRotation=0;else if(le&&(Ce=re,!we))for(Me="clip",ye=W.length;!J&&ye--;)(be=de[W[ye]].label)&&(be.styles.textOverflow==="ellipsis"?be.css({textOverflow:"clip"}):be.textPxLength>le&&be.css({width:le+"px"}),be.getBBox().height>this.len/W.length-(ve.h-ve.f)&&(be.specificTextOverflow="ellipsis"));ge.rotation&&(Ce=De>.5*O.chartHeight?.33*O.chartHeight:De,we||(Me="ellipsis")),this.labelAlign=P.align||this.autoLabelAlign(this.labelRotation),this.labelAlign&&(ge.align=this.labelAlign),W.forEach(function(xe){let pe=de[xe],Se=pe&&pe.label,Ae=ee.width,Te={};Se&&(Se.attr(ge),pe.shortenLabel?pe.shortenLabel():Ce&&!Ae&&ee.whiteSpace!=="nowrap"&&(Ce<Se.textPxLength||Se.element.tagName==="SPAN")?(Te.width=Ce+"px",we||(Te.textOverflow=Se.specificTextOverflow||Me),Se.css(Te)):!Se.styles.width||Te.width||Ae||Se.css({width:null}),delete Se.specificTextOverflow,pe.rotation=ge.rotation)},this),this.tickRotCorr=z.rotCorr(ve.b,this.labelRotation||0,this.side!==0)}hasData(){return this.series.some(function(O){return O.hasData()})||this.options.showEmpty&&U(this.min)&&U(this.max)}addTitle(O){let z,W=this.chart.renderer,de=this.horiz,P=this.opposite,ee=this.options.title,J=this.chart.styledMode;this.axisTitle||((z=ee.textAlign)||(z=(de?{low:"left",middle:"center",high:"right"}:{low:P?"right":"left",middle:"center",high:P?"left":"right"})[ee.align]),this.axisTitle=W.text(ee.text||"",0,0,ee.useHTML).attr({zIndex:7,rotation:ee.rotation||0,align:z}).addClass("highcharts-axis-title"),J||this.axisTitle.css(V(ee.style)),this.axisTitle.add(this.axisGroup),this.axisTitle.isNew=!0),J||ee.style.width||this.isRadial||this.axisTitle.css({width:this.len+"px"}),this.axisTitle[O?"show":"hide"](O)}generateTick(O){let z=this.ticks;z[O]?z[O].addLabel():z[O]=new x(this,O)}createGroups(){let{axisParent:O,chart:z,coll:W,options:de}=this,P=z.renderer,ee=(J,le,re)=>P.g(J).attr({zIndex:re}).addClass(`highcharts-${W.toLowerCase()}${le} `+(this.isRadial?`highcharts-radial-axis${le} `:"")+(de.className||"")).add(O);this.axisGroup||(this.gridGroup=ee("grid","-grid",de.gridZIndex),this.axisGroup=ee("axis","",de.zIndex),this.labelGroup=ee("axis-labels","-labels",de.labels.zIndex))}getOffset(){let O=this,{chart:z,horiz:W,options:de,side:P,ticks:ee,tickPositions:J,coll:le}=O,re=z.inverted&&!O.isZAxis?[1,0,3,2][P]:P,ge=O.hasData(),ve=de.title,we=de.labels,Ce=M(de.crossing),Me=z.axisOffset,De=z.clipOffset,be=[-1,1,1,-1][P],ye,xe=0,pe,Se=0,Ae=0,Te,Oe;if(O.showAxis=ye=ge||de.showEmpty,O.staggerLines=O.horiz&&we.staggerLines||void 0,O.createGroups(),ge||O.isLinked?(J.forEach(function(ze){O.generateTick(ze)}),O.renderUnsquish(),O.reserveSpaceDefault=P===0||P===2||{1:"left",3:"right"}[P]===O.labelAlign,A(we.reserveSpace,!Ce&&null,O.labelAlign==="center"||null,O.reserveSpaceDefault)&&J.forEach(function(ze){Ae=Math.max(ee[ze].getLabelSize(),Ae)}),O.staggerLines&&(Ae*=O.staggerLines),O.labelOffset=Ae*(O.opposite?-1:1)):oe(ee,function(ze,Ge){ze.destroy(),delete ee[Ge]}),ve!=null&&ve.text&&ve.enabled!==!1&&(O.addTitle(ye),ye&&!Ce&&ve.reserveSpace!==!1&&(O.titleOffset=xe=O.axisTitle.getBBox()[W?"height":"width"],Se=U(pe=ve.offset)?0:A(ve.margin,W?5:10))),O.renderLine(),O.offset=be*A(de.offset,Me[P]?Me[P]+(de.margin||0):0),O.tickRotCorr=O.tickRotCorr||{x:0,y:0},Oe=P===0?-O.labelMetrics().h:P===2?O.tickRotCorr.y:0,Te=Math.abs(Ae)+Se,Ae&&(Te-=Oe,Te+=be*(W?A(we.y,O.tickRotCorr.y+be*we.distance):A(we.x,be*we.distance))),O.axisTitleMargin=A(pe,Te),O.getMaxLabelDimensions&&(O.maxLabelDimensions=O.getMaxLabelDimensions(ee,J)),le!=="colorAxis"&&De){let ze=this.tickSize("tick");Me[P]=Math.max(Me[P],(O.axisTitleMargin||0)+xe+be*O.offset,Te,J&&J.length&&ze?ze[0]+be*O.offset:0);let Ge=!O.axisLine||de.offset?0:O.axisLine.strokeWidth()/2;De[re]=Math.max(De[re],Ge)}H(this,"afterGetOffset")}getLinePath(O){let z=this.chart,W=this.opposite,de=this.offset,P=this.horiz,ee=this.left+(W?this.width:0)+de,J=z.chartHeight-this.bottom-(W?this.height:0)+de;return W&&(O*=-1),z.renderer.crispLine([["M",P?this.left:ee,P?J:this.top],["L",P?z.chartWidth-this.right:ee,P?J:z.chartHeight-this.bottom]],O)}renderLine(){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}))}getTitlePosition(O){let z=this.horiz,W=this.left,de=this.top,P=this.len,ee=this.options.title,J=z?W:de,le=this.opposite,re=this.offset,ge=ee.x,ve=ee.y,we=this.chart.renderer.fontMetrics(O),Ce=O?Math.max(O.getBBox(!1,0).height-we.h-1,0):0,Me={low:J+(z?0:P),middle:J+P/2,high:J+(z?P:0)}[ee.align],De=(z?de+this.height:W)+(z?1:-1)*(le?-1:1)*(this.axisTitleMargin||0)+[-Ce,Ce,we.f,-Ce][this.side],be={x:z?Me+ge:De+(le?this.width:0)+re+ge,y:z?De+ve-(le?this.height:0)+re:Me+ve};return H(this,"afterGetTitlePosition",{titlePosition:be}),be}renderMinorTick(O,z){let W=this.minorTicks;W[O]||(W[O]=new x(this,O,"minor")),z&&W[O].isNew&&W[O].render(null,!0),W[O].render(null,!1,1)}renderTick(O,z,W){let de=this.isLinked,P=this.ticks;(!de||O>=this.min&&O<=this.max||this.grid&&this.grid.isColumn)&&(P[O]||(P[O]=new x(this,O)),W&&P[O].isNew&&P[O].render(z,!0,-1),P[O].render(z))}render(){let O,z,W=this,de=W.chart,P=W.logarithmic,ee=de.renderer,J=W.options,le=W.isLinked,re=W.tickPositions,ge=W.axisTitle,ve=W.ticks,we=W.minorTicks,Ce=W.alternateBands,Me=J.stackLabels,De=J.alternateGridColor,be=J.crossing,ye=W.tickmarkOffset,xe=W.axisLine,pe=W.showAxis,Se=T(ee.globalAnimation);if(W.labelEdge.length=0,W.overlap=!1,[ve,we,Ce].forEach(function(Ae){oe(Ae,function(Te){Te.isActive=!1})}),M(be)){let Ae=this.isXAxis?de.yAxis[0]:de.xAxis[0],Te=[1,-1,-1,1][this.side];if(Ae){let Oe=Ae.toPixels(be,!0);W.horiz&&(Oe=Ae.len-Oe),W.offset=Te*Oe}}if(W.hasData()||le){let Ae=W.chart.hasRendered&&W.old&&M(W.old.min);W.minorTickInterval&&!W.categories&&W.getMinorTickPositions().forEach(function(Te){W.renderMinorTick(Te,Ae)}),re.length&&(re.forEach(function(Te,Oe){W.renderTick(Te,Oe,Ae)}),ye&&(W.min===0||W.single)&&(ve[-1]||(ve[-1]=new x(W,-1,null,!0)),ve[-1].render(-1))),De&&re.forEach(function(Te,Oe){z=re[Oe+1]!==void 0?re[Oe+1]+ye:W.max-ye,Oe%2==0&&Te<W.max&&z<=W.max+(de.polar?-ye:ye)&&(Ce[Te]||(Ce[Te]=new v.PlotLineOrBand(W,{})),O=Te+ye,Ce[Te].options={from:P?P.lin2log(O):O,to:P?P.lin2log(z):z,color:De,className:"highcharts-alternate-grid"},Ce[Te].render(),Ce[Te].isActive=!0)}),W._addedPlotLB||(W._addedPlotLB=!0,(J.plotLines||[]).concat(J.plotBands||[]).forEach(function(Te){W.addPlotBandOrLine(Te)}))}[ve,we,Ce].forEach(function(Ae){let Te=[],Oe=Se.duration;oe(Ae,function(ze,Ge){ze.isActive||(ze.render(Ge,!1,0),ze.isActive=!1,Te.push(Ge))}),D(function(){let ze=Te.length;for(;ze--;)Ae[Te[ze]]&&!Ae[Te[ze]].isActive&&(Ae[Te[ze]].destroy(),delete Ae[Te[ze]])},Ae!==Ce&&de.hasRendered&&Oe?Oe:0)}),xe&&(xe[xe.isPlaced?"animate":"attr"]({d:this.getLinePath(xe.strokeWidth())}),xe.isPlaced=!0,xe[pe?"show":"hide"](pe)),ge&&pe&&(ge[ge.isNew?"attr":"animate"](W.getTitlePosition(ge)),ge.isNew=!1),Me&&Me.enabled&&W.stacking&&W.stacking.renderStackTotals(),W.old={len:W.len,max:W.max,min:W.min,transA:W.transA,userMax:W.userMax,userMin:W.userMin},W.isDirty=!1,H(this,"afterRender")}redraw(){this.visible&&(this.render(),this.plotLinesAndBands.forEach(function(O){O.render()})),this.series.forEach(function(O){O.isDirty=!0})}getKeepProps(){return this.keepProps||K.keepProps}destroy(O){let z=this,W=z.plotLinesAndBands,de=this.eventOptions;if(H(this,"destroy",{keepEvents:O}),O||me(z),[z.ticks,z.minorTicks,z.alternateBands].forEach(function(P){Z(P)}),W){let P=W.length;for(;P--;)W[P].destroy()}for(let P in["axisLine","axisTitle","axisGroup","gridGroup","labelGroup","cross","scrollbar"].forEach(function(ee){z[ee]&&(z[ee]=z[ee].destroy())}),z.plotLinesAndBandsGroups)z.plotLinesAndBandsGroups[P]=z.plotLinesAndBandsGroups[P].destroy();oe(z,function(P,ee){z.getKeepProps().indexOf(ee)===-1&&delete z[ee]}),this.eventOptions=de}drawCrosshair(O,z){let W=this.crosshair,de=A(W&&W.snap,!0),P=this.chart,ee,J,le,re=this.cross,ge;if(H(this,"drawCrosshair",{e:O,point:z}),O||(O=this.cross&&this.cross.e),W&&(U(z)||!de)!==!1){if(de?U(z)&&(J=A(this.coll!=="colorAxis"?z.crosshairPos:null,this.isXAxis?z.plotX:this.len-z.plotY)):J=O&&(this.horiz?O.chartX-this.pos:this.len-O.chartY+this.pos),U(J)&&(ge={value:z&&(this.isXAxis?z.x:A(z.stackY,z.y)),translatedValue:J},P.polar&&I(ge,{isCrosshair:!0,chartX:O&&O.chartX,chartY:O&&O.chartY,point:z}),ee=this.getPlotLinePath(ge)||null),!U(ee)){this.hideCrosshair();return}le=this.categories&&!this.isRadial,re||(this.cross=re=P.renderer.path().addClass("highcharts-crosshair highcharts-crosshair-"+(le?"category ":"thin ")+(W.className||"")).attr({zIndex:A(W.zIndex,2)}).add(),!P.styledMode&&(re.attr({stroke:W.color||(le?h.parse("#ccd3ff").setOpacity(.25).get():"#cccccc"),"stroke-width":A(W.width,1)}).css({"pointer-events":"none"}),W.dashStyle&&re.attr({dashstyle:W.dashStyle}))),re.show().attr({d:ee}),le&&!W.width&&re.attr({"stroke-width":this.transA}),this.cross.e=O}else this.hideCrosshair();H(this,"afterDrawCrosshair",{e:O,point:z})}hideCrosshair(){this.cross&&this.cross.hide(),H(this,"afterHideCrosshair")}update(O,z){let W=this.chart;O=V(this.userOptions,O),this.destroy(!0),this.init(W,O),W.isDirtyBox=!0,A(z,!0)&&W.redraw()}remove(O){let z=this.chart,W=this.coll,de=this.series,P=de.length;for(;P--;)de[P]&&de[P].remove(!1);ce(z.axes,this),ce(z[W]||[],this),z.orderItems(W),this.destroy(),z.isDirtyBox=!0,A(O,!0)&&z.redraw()}setTitle(O,z){this.update({title:O},z)}setCategories(O,z){this.update({categories:O},z)}}return K.keepProps=["coll","extKey","hcEvents","len","names","series","userMax","userMin"],K}),r(a,"Core/Axis/DateTimeAxis.js",[a["Core/Utilities.js"]],function(c){var u;let{addEvent:h,getMagnitude:p,normalizeTickInterval:m,timeUnits:v}=c;return function(x){function _(){return this.chart.time.getTimeTicks.apply(this.chart.time,arguments)}function T(){if(this.type!=="datetime"){this.dateTime=void 0;return}this.dateTime||(this.dateTime=new k(this))}x.compose=function(C){return C.keepProps.includes("dateTime")||(C.keepProps.push("dateTime"),C.prototype.getTimeTicks=_,h(C,"afterSetType",T)),C};class k{constructor(G){this.axis=G}normalizeTimeTickInterval(G,ne){let $=ne||[["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]],L=$[$.length-1],B=v[L[0]],Y=L[1],X;for(X=0;X<$.length&&(B=v[(L=$[X])[0]],Y=L[1],!$[X+1]||!(G<=(B*Y[Y.length-1]+v[$[X+1][0]])/2));X++);B===v.year&&G<5*B&&(Y=[1,2,5]);let U=m(G/B,Y,L[0]==="year"?Math.max(p(G/B),1):1);return{unitRange:B,count:U,unitName:L[0]}}getXDateFormat(G,ne){let{axis:$}=this,L=$.chart.time;return $.closestPointRange?L.getDateFormat($.closestPointRange,G,$.options.startOfWeek,ne)||L.resolveDTLFormat(ne.year).main:L.resolveDTLFormat(ne.day).main}}x.Additions=k}(u||(u={})),u}),r(a,"Core/Axis/LogarithmicAxis.js",[a["Core/Utilities.js"]],function(c){var u;let{addEvent:h,normalizeTickInterval:p,pick:m}=c;return function(v){function x(){this.type!=="logarithmic"?this.logarithmic=void 0:this.logarithmic??(this.logarithmic=new T(this))}function _(){let k=this.logarithmic;k&&(this.lin2val=function(C){return k.lin2log(C)},this.val2lin=function(C){return k.log2lin(C)})}v.compose=function(k){return k.keepProps.includes("logarithmic")||(k.keepProps.push("logarithmic"),h(k,"afterSetType",x),h(k,"afterInit",_)),k};class T{constructor(C){this.axis=C}getLogTickPositions(C,G,ne,$){let L=this.axis,B=L.len,Y=L.options,X=[];if($||(this.minorAutoInterval=void 0),C>=.5)C=Math.round(C),X=L.getLinearTickPositions(C,G,ne);else if(C>=.08){let U,Z,ce,se,I,H,Q,F=Math.floor(G);for(U=C>.3?[1,2,4]:C>.15?[1,2,4,6,8]:[1,2,3,4,5,6,7,8,9],Z=F;Z<ne+1&&!Q;Z++)for(ce=0,se=U.length;ce<se&&!Q;ce++)(I=this.log2lin(this.lin2log(Z)*U[ce]))>G&&(!$||H<=ne)&&H!==void 0&&X.push(H),H>ne&&(Q=!0),H=I}else{let U=this.lin2log(G),Z=this.lin2log(ne),ce=$?L.getMinorTickInterval():Y.tickInterval,se=Y.tickPixelInterval/($?5:1),I=$?B/L.tickPositions.length:B;C=p(C=m(ce==="auto"?null:ce,this.minorAutoInterval,(Z-U)*se/(I||1))),X=L.getLinearTickPositions(C,U,Z).map(this.log2lin),$||(this.minorAutoInterval=C/5)}return $||(L.tickInterval=C),X}lin2log(C){return Math.pow(10,C)}log2lin(C){return Math.log(C)/Math.LN10}}v.Additions=T}(u||(u={})),u}),r(a,"Core/Axis/PlotLineOrBand/PlotLineOrBandAxis.js",[a["Core/Utilities.js"]],function(c){var u;let{erase:h,extend:p,isNumber:m}=c;return function(v){let x;function _(L){return this.addPlotBandOrLine(L,"plotBands")}function T(L,B){let Y=this.userOptions,X=new x(this,L);if(this.visible&&(X=X.render()),X){if(this._addedPlotLB||(this._addedPlotLB=!0,(Y.plotLines||[]).concat(Y.plotBands||[]).forEach(U=>{this.addPlotBandOrLine(U)})),B){let U=Y[B]||[];U.push(L),Y[B]=U}this.plotLinesAndBands.push(X)}return X}function k(L){return this.addPlotBandOrLine(L,"plotLines")}function C(L,B,Y){Y=Y||this.options;let X=this.getPlotLinePath({value:B,force:!0,acrossPanes:Y.acrossPanes}),U=[],Z=this.horiz,ce=!m(this.min)||!m(this.max)||L<this.min&&B<this.min||L>this.max&&B>this.max,se=this.getPlotLinePath({value:L,force:!0,acrossPanes:Y.acrossPanes}),I,H=1,Q;if(se&&X)for(ce&&(Q=se.toString()===X.toString(),H=0),I=0;I<se.length;I+=2){let F=se[I],E=se[I+1],M=X[I],R=X[I+1];(F[0]==="M"||F[0]==="L")&&(E[0]==="M"||E[0]==="L")&&(M[0]==="M"||M[0]==="L")&&(R[0]==="M"||R[0]==="L")&&(Z&&M[1]===F[1]?(M[1]+=H,R[1]+=H):Z||M[2]!==F[2]||(M[2]+=H,R[2]+=H),U.push(["M",F[1],F[2]],["L",E[1],E[2]],["L",R[1],R[2]],["L",M[1],M[2]],["Z"])),U.isFlat=Q}return U}function G(L){this.removePlotBandOrLine(L)}function ne(L){let B=this.plotLinesAndBands,Y=this.options,X=this.userOptions;if(B){let U=B.length;for(;U--;)B[U].id===L&&B[U].destroy();[Y.plotLines||[],X.plotLines||[],Y.plotBands||[],X.plotBands||[]].forEach(function(Z){for(U=Z.length;U--;)(Z[U]||{}).id===L&&h(Z,Z[U])})}}function $(L){this.removePlotBandOrLine(L)}v.compose=function(L,B){let Y=B.prototype;return Y.addPlotBand||(x=L,p(Y,{addPlotBand:_,addPlotLine:k,addPlotBandOrLine:T,getPlotBandPath:C,removePlotBand:G,removePlotLine:$,removePlotBandOrLine:ne})),B}}(u||(u={})),u}),r(a,"Core/Axis/PlotLineOrBand/PlotLineOrBand.js",[a["Core/Axis/PlotLineOrBand/PlotLineOrBandAxis.js"],a["Core/Utilities.js"]],function(c,u){let{addEvent:h,arrayMax:p,arrayMin:m,defined:v,destroyObjectProperties:x,erase:_,fireEvent:T,merge:k,objectEach:C,pick:G}=u;class ne{static compose(L,B){return h(L,"afterInit",function(){this.labelCollectors.push(()=>{var X;let Y=[];for(let U of this.axes)for(let{label:Z,options:ce}of U.plotLinesAndBands)Z&&!((X=ce==null?void 0:ce.label)!=null&&X.allowOverlap)&&Y.push(Z);return Y})}),c.compose(ne,B)}constructor(L,B){this.axis=L,this.options=B,this.id=B.id}render(){T(this,"render");let{axis:L,options:B}=this,{horiz:Y,logarithmic:X}=L,{color:U,events:Z,zIndex:ce=0}=B,se={},I=L.chart.renderer,H=B.to,Q=B.from,F=B.value,E=B.borderWidth,M=B.label,{label:R,svgElem:V}=this,ae=[],oe,A=v(Q)&&v(H),ue=v(F),me=!V,g={class:"highcharts-plot-"+(A?"band ":"line ")+(B.className||"")},D=A?"bands":"lines";if(!L.chart.styledMode&&(ue?(g.stroke=U||"#999999",g["stroke-width"]=G(B.width,1),B.dashStyle&&(g.dashstyle=B.dashStyle)):A&&(g.fill=U||"#e6e9ff",E&&(g.stroke=B.borderColor,g["stroke-width"]=E))),se.zIndex=ce,D+="-"+ce,(oe=L.plotLinesAndBandsGroups[D])||(L.plotLinesAndBandsGroups[D]=oe=I.g("plot-"+D).attr(se).add()),V||(this.svgElem=V=I.path().attr(g).add(oe)),v(F))ae=L.getPlotLinePath({value:(X==null?void 0:X.log2lin(F))??F,lineWidth:V.strokeWidth(),acrossPanes:B.acrossPanes});else{if(!(v(Q)&&v(H)))return;ae=L.getPlotBandPath((X==null?void 0:X.log2lin(Q))??Q,(X==null?void 0:X.log2lin(H))??H,B)}return!this.eventsAdded&&Z&&(C(Z,(j,K)=>{V==null||V.on(K,te=>{Z[K].apply(this,[te])})}),this.eventsAdded=!0),(me||!V.d)&&(ae!=null&&ae.length)?V.attr({d:ae}):V&&(ae?(V.show(),V.animate({d:ae})):V.d&&(V.hide(),R&&(this.label=R=R.destroy()))),M&&(v(M.text)||v(M.formatter))&&(ae!=null&&ae.length)&&L.width>0&&L.height>0&&!ae.isFlat?(M=k({align:Y&&A?"center":void 0,x:Y?!A&&4:10,verticalAlign:!Y&&A?"middle":void 0,y:Y?A?16:10:A?6:-4,rotation:Y&&!A?90:0,...A?{inside:!0}:{}},M),this.renderLabel(M,ae,A,ce)):R&&R.hide(),this}renderLabel(L,B,Y,X){var M;let U=this.axis,Z=U.chart.renderer,ce=L.inside,se=this.label;se||(this.label=se=Z.text(this.getLabelText(L),0,0,L.useHTML).attr({align:L.textAlign||L.align,rotation:L.rotation,class:"highcharts-plot-"+(Y?"band":"line")+"-label "+(L.className||""),zIndex:X}),U.chart.styledMode||se.css(k({fontSize:"0.8em",textOverflow:Y&&!ce?"":"ellipsis"},L.style)),se.add());let I=B.xBounds||[B[0][1],B[1][1],Y?B[2][1]:B[0][1]],H=B.yBounds||[B[0][2],B[1][2],Y?B[2][2]:B[0][2]],Q=m(I),F=m(H),E=p(I)-Q;se.align(L,!1,{x:Q,y:F,width:E,height:p(H)-F}),(!se.alignValue||se.alignValue==="left"||v(ce))&&se.css({width:(((M=L.style)==null?void 0:M.width)||(Y&&ce?E:se.rotation===90?U.height-(se.alignAttr.y-U.top):(L.clip?U.width:U.chart.chartWidth)-(se.alignAttr.x-U.left)))+"px"}),se.show(!0)}getLabelText(L){return v(L.formatter)?L.formatter.call(this):L.text}destroy(){_(this.axis.plotLinesAndBands,this),delete this.axis,x(this)}}return ne}),r(a,"Core/Tooltip.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Templating.js"],a["Core/Globals.js"],a["Core/Renderer/RendererUtilities.js"],a["Core/Renderer/RendererRegistry.js"],a["Core/Utilities.js"]],function(c,u,h,p,m,v){var x;let{animObject:_}=c,{format:T}=u,{composed:k,doc:C,isSafari:G}=h,{distribute:ne}=p,{addEvent:$,clamp:L,css:B,discardElement:Y,extend:X,fireEvent:U,isArray:Z,isNumber:ce,isString:se,merge:I,pick:H,pushUnique:Q,splat:F,syncTimeout:E}=v;class M{constructor(V,ae,oe){this.allowShared=!0,this.crosshairs=[],this.distance=0,this.isHidden=!0,this.isSticky=!1,this.options={},this.outside=!1,this.chart=V,this.init(V,ae),this.pointer=oe}bodyFormatter(V){return V.map(function(ae){let oe=ae.series.tooltipOptions;return(oe[(ae.point.formatPrefix||"point")+"Formatter"]||ae.point.tooltipFormatter).call(ae.point,oe[(ae.point.formatPrefix||"point")+"Format"]||"")})}cleanSplit(V){this.chart.series.forEach(function(ae){let oe=ae&&ae.tt;oe&&(!oe.isActive||V?ae.tt=oe.destroy():oe.isActive=!1)})}defaultFormatter(V){let ae,oe=this.points||F(this);return(ae=(ae=[V.tooltipFooterHeaderFormatter(oe[0])]).concat(V.bodyFormatter(oe))).push(V.tooltipFooterHeaderFormatter(oe[0],!0)),ae}destroy(){this.label&&(this.label=this.label.destroy()),this.split&&(this.cleanSplit(!0),this.tt&&(this.tt=this.tt.destroy())),this.renderer&&(this.renderer=this.renderer.destroy(),Y(this.container)),v.clearTimeout(this.hideTimer)}getAnchor(V,ae){let oe,{chart:A,pointer:ue}=this,me=A.inverted,g=A.plotTop,D=A.plotLeft;if((V=F(V))[0].series&&V[0].series.yAxis&&!V[0].series.yAxis.options.reversedStacks&&(V=V.slice().reverse()),this.followPointer&&ae)ae.chartX===void 0&&(ae=ue.normalize(ae)),oe=[ae.chartX-D,ae.chartY-g];else if(V[0].tooltipPos)oe=V[0].tooltipPos;else{let j=0,K=0;V.forEach(function(te){let O=te.pos(!0);O&&(j+=O[0],K+=O[1])}),j/=V.length,K/=V.length,this.shared&&V.length>1&&ae&&(me?j=ae.chartX:K=ae.chartY),oe=[j-D,K-g]}return oe.map(Math.round)}getClassName(V,ae,oe){let A=this.options,ue=V.series,me=ue.options;return[A.className,"highcharts-label",oe&&"highcharts-tooltip-header",ae?"highcharts-tooltip-box":"highcharts-tooltip",!oe&&"highcharts-color-"+H(V.colorIndex,ue.colorIndex),me&&me.className].filter(se).join(" ")}getLabel({anchorX:V,anchorY:ae}={anchorX:0,anchorY:0}){let oe=this,A=this.chart.styledMode,ue=this.options,me=this.split&&this.allowShared,g=this.container,D=this.chart.renderer;if(this.label){let j=!this.label.hasClass("highcharts-label");(!me&&j||me&&!j)&&this.destroy()}if(!this.label){if(this.outside){let j=this.chart.options.chart.style,K=m.getRendererType();this.container=g=h.doc.createElement("div"),g.className="highcharts-tooltip-container",B(g,{position:"absolute",top:"1px",pointerEvents:"none",zIndex:Math.max(this.options.style.zIndex||0,(j&&j.zIndex||0)+3)}),this.renderer=D=new K(g,0,0,j,void 0,void 0,D.styledMode)}if(me?this.label=D.g("tooltip"):(this.label=D.label("",V,ae,ue.shape,void 0,void 0,ue.useHTML,void 0,"tooltip").attr({padding:ue.padding,r:ue.borderRadius}),A||this.label.attr({fill:ue.backgroundColor,"stroke-width":ue.borderWidth||0}).css(ue.style).css({pointerEvents:ue.style.pointerEvents||(this.shouldStickOnContact()?"auto":"none")})),oe.outside){let j=this.label;[j.xSetter,j.ySetter].forEach((K,te)=>{j[te?"ySetter":"xSetter"]=O=>{K.call(j,oe.distance),j[te?"y":"x"]=O,g&&(g.style[te?"top":"left"]=`${O}px`)}})}this.label.attr({zIndex:8}).shadow(ue.shadow).add()}return g&&!g.parentElement&&h.doc.body.appendChild(g),this.label}getPlayingField(){let{body:V,documentElement:ae}=C,{chart:oe,distance:A,outside:ue}=this;return{width:ue?Math.max(V.scrollWidth,ae.scrollWidth,V.offsetWidth,ae.offsetWidth,ae.clientWidth)-2*A:oe.chartWidth,height:ue?Math.max(V.scrollHeight,ae.scrollHeight,V.offsetHeight,ae.offsetHeight,ae.clientHeight):oe.chartHeight}}getPosition(V,ae,oe){var Se,Ae;let{distance:A,chart:ue,outside:me,pointer:g}=this,{inverted:D,plotLeft:j,plotTop:K,polar:te}=ue,{plotX:O=0,plotY:z=0}=oe,W={},de=D&&oe.h||0,{height:P,width:ee}=this.getPlayingField(),J=g.getChartPosition(),le=Te=>Te*J.scaleX,re=Te=>Te*J.scaleY,ge=Te=>{let Oe=Te==="x";return[Te,Oe?ee:P,Oe?V:ae].concat(me?[Oe?le(V):re(ae),Oe?J.left-A+le(O+j):J.top-A+re(z+K),0,Oe?ee:P]:[Oe?V:ae,Oe?O+j:z+K,Oe?j:K,Oe?j+ue.plotWidth:K+ue.plotHeight])},ve=ge("y"),we=ge("x"),Ce,Me=!!oe.negative;!te&&((Ae=(Se=ue.hoverSeries)==null?void 0:Se.yAxis)!=null&&Ae.reversed)&&(Me=!Me);let De=!this.followPointer&&H(oe.ttBelow,!te&&!D===Me),be=function(Te,Oe,ze,Ge,Ve,qe,ot){let ft=me?Te==="y"?re(A):le(A):A,dt=(ze-Ge)/2,et=Ge<Ve-A,Pt=Ve+A+Ge<Oe,Ie=Ve-ft-ze+dt,gt=Ve+ft-dt;if(De&&Pt)W[Te]=gt;else if(!De&&et)W[Te]=Ie;else if(et)W[Te]=Math.min(ot-Ge,Ie-de<0?Ie:Ie-de);else{if(!Pt)return!1;W[Te]=Math.max(qe,gt+de+ze>Oe?gt:gt+de)}},ye=function(Te,Oe,ze,Ge,Ve){if(Ve<A||Ve>Oe-A)return!1;Ve<ze/2?W[Te]=1:Ve>Oe-Ge/2?W[Te]=Oe-Ge-2:W[Te]=Ve-ze/2},xe=function(Te){[ve,we]=[we,ve],Ce=Te},pe=()=>{be.apply(0,ve)!==!1?ye.apply(0,we)!==!1||Ce||(xe(!0),pe()):Ce?W.x=W.y=0:(xe(!0),pe())};return(D&&!te||this.len>1)&&xe(),pe(),W}hide(V){let ae=this;v.clearTimeout(this.hideTimer),V=H(V,this.options.hideDelay),this.isHidden||(this.hideTimer=E(function(){let oe=ae.getLabel();ae.getLabel().animate({opacity:0},{duration:V&&150,complete:()=>{oe.hide(),ae.container&&ae.container.remove()}}),ae.isHidden=!0},V))}init(V,ae){this.chart=V,this.options=ae,this.crosshairs=[],this.isHidden=!0,this.split=ae.split&&!V.inverted&&!V.polar,this.shared=ae.shared||this.split,this.outside=H(ae.outside,!!(V.scrollablePixelsX||V.scrollablePixelsY))}shouldStickOnContact(V){return!!(!this.followPointer&&this.options.stickOnContact&&(!V||this.pointer.inClass(V.target,"highcharts-tooltip")))}move(V,ae,oe,A){let ue=this,me=_(!ue.isHidden&&ue.options.animation),g=ue.followPointer||(ue.len||0)>1,D={x:V,y:ae};g||(D.anchorX=oe,D.anchorY=A),me.step=()=>ue.drawTracker(),ue.getLabel().animate(D,me)}refresh(V,ae){let{chart:oe,options:A,pointer:ue,shared:me}=this,g=F(V),D=g[0],j=[],K=A.format,te=A.formatter||this.defaultFormatter,O=oe.styledMode,z={},W=this.allowShared;if(!A.enabled||!D.series)return;v.clearTimeout(this.hideTimer),this.allowShared=!(!Z(V)&&V.series&&V.series.noSharedTooltip),W=W&&!this.allowShared,this.followPointer=!this.split&&D.series.tooltipOptions.followPointer;let de=this.getAnchor(V,ae),P=de[0],ee=de[1];me&&this.allowShared?(ue.applyInactiveState(g),g.forEach(function(re){re.setState("hover"),j.push(re.getLabelConfig())}),(z=D.getLabelConfig()).points=j):z=D.getLabelConfig(),this.len=j.length;let J=se(K)?T(K,z,oe):te.call(z,this),le=D.series;if(this.distance=H(le.tooltipOptions.distance,16),J===!1)this.hide();else{if(this.split&&this.allowShared)this.renderSplit(J,g);else{let re=P,ge=ee;if(ae&&ue.isDirectTouch&&(re=ae.chartX-oe.plotLeft,ge=ae.chartY-oe.plotTop),oe.polar||le.options.clip===!1||g.some(ve=>ue.isDirectTouch||ve.series.shouldShowTooltip(re,ge))){let ve=this.getLabel(W&&this.tt||{});(!A.style.width||O)&&ve.css({width:(this.outside?this.getPlayingField():oe.spacingBox).width+"px"}),ve.attr({class:this.getClassName(D),text:J&&J.join?J.join(""):J}),this.outside&&ve.attr({x:L(ve.x||0,0,this.getPlayingField().width-(ve.width||0))}),O||ve.attr({stroke:A.borderColor||D.color||le.color||"#666666"}),this.updatePosition({plotX:P,plotY:ee,negative:D.negative,ttBelow:D.ttBelow,h:de[2]||0})}else{this.hide();return}}this.isHidden&&this.label&&this.label.attr({opacity:1}).show(),this.isHidden=!1}U(this,"refresh")}renderSplit(V,ae){var Oe;let oe=this,{chart:A,chart:{chartWidth:ue,chartHeight:me,plotHeight:g,plotLeft:D,plotTop:j,scrollablePixelsY:K=0,scrollablePixelsX:te,styledMode:O},distance:z,options:W,options:{positioner:de},pointer:P}=oe,{scrollLeft:ee=0,scrollTop:J=0}=((Oe=A.scrollablePlotArea)==null?void 0:Oe.scrollingContainer)||{},le=oe.outside&&typeof te!="number"?C.documentElement.getBoundingClientRect():{left:ee,right:ee+ue},re=oe.getLabel(),ge=this.renderer||A.renderer,ve=!!(A.xAxis[0]&&A.xAxis[0].opposite),{left:we,top:Ce}=P.getChartPosition(),Me=j+J,De=0,be=g-K;function ye(ze,Ge,Ve,qe,ot=!0){let ft,dt;return Ve?(ft=ve?0:be,dt=L(ze-qe/2,le.left,le.right-qe-(oe.outside?we:0))):(ft=Ge-Me,dt=L(dt=ot?ze-qe-z:ze+z,ot?dt:le.left,le.right)),{x:dt,y:ft}}se(V)&&(V=[!1,V]);let xe=V.slice(0,ae.length+1).reduce(function(ze,Ge,Ve){if(Ge!==!1&&Ge!==""){let qe=ae[Ve-1]||{isHeader:!0,plotX:ae[0].plotX,plotY:g,series:{}},ot=qe.isHeader,ft=ot?oe:qe.series,dt=ft.tt=function(Tt,at,Pe){let Qe=Tt,{isHeader:it,series:lt}=at;if(!Qe){let Lt={padding:W.padding,r:W.borderRadius};O||(Lt.fill=W.backgroundColor,Lt["stroke-width"]=W.borderWidth??1),Qe=ge.label("",0,0,W[it?"headerShape":"shape"],void 0,void 0,W.useHTML).addClass(oe.getClassName(at,!0,it)).attr(Lt).add(re)}return Qe.isActive=!0,Qe.attr({text:Pe}),O||Qe.css(W.style).attr({stroke:W.borderColor||at.color||lt.color||"#333333"}),Qe}(ft.tt,qe,Ge.toString()),et=dt.getBBox(),Pt=et.width+dt.strokeWidth();ot&&(De=et.height,be+=De,ve&&(Me-=De));let{anchorX:Ie,anchorY:gt}=function(Tt){let at,Pe,{isHeader:Qe,plotX:it=0,plotY:lt=0,series:Lt}=Tt;if(Qe)at=Math.max(D+it,D),Pe=j+g/2;else{let{xAxis:It,yAxis:Mt}=Lt;at=It.pos+L(it,-z,It.len+z),Lt.shouldShowTooltip(0,Mt.pos-j+lt,{ignoreX:!0})&&(Pe=Mt.pos+lt)}return{anchorX:at=L(at,le.left-z,le.right+z),anchorY:Pe}}(qe);if(typeof gt=="number"){let Tt=et.height+1,at=de?de.call(oe,Pt,Tt,qe):ye(Ie,gt,ot,Pt);ze.push({align:de?0:void 0,anchorX:Ie,anchorY:gt,boxWidth:Pt,point:qe,rank:H(at.rank,ot?1:0),size:Tt,target:at.y,tt:dt,x:at.x})}else dt.isActive=!1}return ze},[]);!de&&xe.some(ze=>{let{outside:Ge}=oe,Ve=(Ge?we:0)+ze.anchorX;return Ve<le.left&&Ve+ze.boxWidth<le.right||Ve<we-le.left+ze.boxWidth&&le.right-Ve>Ve})&&(xe=xe.map(ze=>{let{x:Ge,y:Ve}=ye(ze.anchorX,ze.anchorY,ze.point.isHeader,ze.boxWidth,!1);return X(ze,{target:Ve,x:Ge})})),oe.cleanSplit(),ne(xe,be);let pe={left:we,right:we};xe.forEach(function(ze){let{x:Ge,boxWidth:Ve,isHeader:qe}=ze;!qe&&(oe.outside&&we+Ge<pe.left&&(pe.left=we+Ge),!qe&&oe.outside&&pe.left+Ve>pe.right&&(pe.right=we+Ge))}),xe.forEach(function(ze){let{x:Ge,anchorX:Ve,anchorY:qe,pos:ot,point:{isHeader:ft}}=ze,dt={visibility:ot===void 0?"hidden":"inherit",x:Ge,y:(ot||0)+Me,anchorX:Ve,anchorY:qe};if(oe.outside&&Ge<Ve){let et=we-pe.left;et>0&&(ft||(dt.x=Ge+et,dt.anchorX=Ve+et),ft&&(dt.x=(pe.right-pe.left)/2,dt.anchorX=Ve+et))}ze.tt.attr(dt)});let{container:Se,outside:Ae,renderer:Te}=oe;if(Ae&&Se&&Te){let{width:ze,height:Ge,x:Ve,y:qe}=re.getBBox();Te.setSize(ze+Ve,Ge+qe,!1),Se.style.left=pe.left+"px",Se.style.top=Ce+"px"}G&&re.attr({opacity:re.opacity===1?.999:1})}drawTracker(){if(!this.shouldStickOnContact()){this.tracker&&(this.tracker=this.tracker.destroy());return}let V=this.chart,ae=this.label,oe=this.shared?V.hoverPoints:V.hoverPoint;if(!ae||!oe)return;let A={x:0,y:0,width:0,height:0},ue=this.getAnchor(oe),me=ae.getBBox();ue[0]+=V.plotLeft-(ae.translateX||0),ue[1]+=V.plotTop-(ae.translateY||0),A.x=Math.min(0,ue[0]),A.y=Math.min(0,ue[1]),A.width=ue[0]<0?Math.max(Math.abs(ue[0]),me.width-ue[0]):Math.max(Math.abs(ue[0]),me.width),A.height=ue[1]<0?Math.max(Math.abs(ue[1]),me.height-Math.abs(ue[1])):Math.max(Math.abs(ue[1]),me.height),this.tracker?this.tracker.attr(A):(this.tracker=ae.renderer.rect(A).addClass("highcharts-tracker").add(ae),V.styledMode||this.tracker.attr({fill:"rgba(0,0,0,0)"}))}styledModeFormat(V){return V.replace('style="font-size: 0.8em"','class="highcharts-header"').replace(/style="color:{(point|series)\.color}"/g,'class="highcharts-color-{$1.colorIndex} {series.options.className} {point.options.className}"')}tooltipFooterHeaderFormatter(V,ae){let oe=V.series,A=oe.tooltipOptions,ue=oe.xAxis,me=ue&&ue.dateTime,g={isFooter:ae,labelConfig:V},D=A.xDateFormat,j=A[ae?"footerFormat":"headerFormat"];return U(this,"headerFormatter",g,function(K){me&&!D&&ce(V.key)&&(D=me.getXDateFormat(V.key,A.dateTimeLabelFormats)),me&&D&&(V.point&&V.point.tooltipDateKeys||["key"]).forEach(function(te){j=j.replace("{point."+te+"}","{point."+te+":"+D+"}")}),oe.chart.styledMode&&(j=this.styledModeFormat(j)),K.text=T(j,{point:V,series:oe},this.chart)}),g.text}update(V){this.destroy(),this.init(this.chart,I(!0,this.options,V))}updatePosition(V){let{chart:ae,container:oe,distance:A,options:ue,pointer:me,renderer:g}=this,{height:D=0,width:j=0}=this.getLabel(),{left:K,top:te,scaleX:O,scaleY:z}=me.getChartPosition(),W=(ue.positioner||this.getPosition).call(this,j,D,V),de=(V.plotX||0)+ae.plotLeft,P=(V.plotY||0)+ae.plotTop,ee;g&&oe&&(ue.positioner&&(W.x+=K-A,W.y+=te-A),ee=(ue.borderWidth||0)+2*A+2,g.setSize(j+ee,D+ee,!1),(O!==1||z!==1)&&(B(oe,{transform:`scale(${O}, ${z})`}),de*=O,P*=z),de+=K-W.x,P+=te-W.y),this.move(Math.round(W.x),Math.round(W.y||0),de,P)}}return(x=M||(M={})).compose=function(R){Q(k,"Core.Tooltip")&&$(R,"afterInit",function(){let V=this.chart;V.options.tooltip&&(V.tooltip=new x(V,V.options.tooltip,this))})},M}),r(a,"Core/Series/Point.js",[a["Core/Renderer/HTML/AST.js"],a["Core/Animation/AnimationUtilities.js"],a["Core/Defaults.js"],a["Core/Templating.js"],a["Core/Utilities.js"]],function(c,u,h,p,m){let{animObject:v}=u,{defaultOptions:x}=h,{format:_}=p,{addEvent:T,crisp:k,erase:C,extend:G,fireEvent:ne,getNestedProperty:$,isArray:L,isFunction:B,isNumber:Y,isObject:X,merge:U,pick:Z,syncTimeout:ce,removeEvent:se,uniqueKey:I}=m;class H{animateBeforeDestroy(){let F=this,E={x:F.startXPos,opacity:0},M=F.getGraphicalProps();M.singular.forEach(function(R){F[R]=F[R].animate(R==="dataLabel"?{x:F[R].startXPos,y:F[R].startYPos,opacity:0}:E)}),M.plural.forEach(function(R){F[R].forEach(function(V){V.element&&V.animate(G({x:F.startXPos},V.startYPos?{x:V.startXPos,y:V.startYPos}:{}))})})}applyOptions(F,E){let M=this.series,R=M.options.pointValKey||M.pointValKey;return G(this,F=H.prototype.optionsToObject.call(this,F)),this.options=this.options?G(this.options,F):F,F.group&&delete this.group,F.dataLabels&&delete this.dataLabels,R&&(this.y=H.prototype.getNestedProperty.call(this,R)),this.selected&&(this.state="select"),"name"in this&&E===void 0&&M.xAxis&&M.xAxis.hasNames&&(this.x=M.xAxis.nameToX(this)),this.x===void 0&&M?this.x=E??M.autoIncrement():Y(F.x)&&M.options.relativeXValue&&(this.x=M.autoIncrement(F.x)),this.isNull=this.isValid&&!this.isValid(),this.formatPrefix=this.isNull?"null":"point",this}destroy(){if(!this.destroyed){let F=this,E=F.series,M=E.chart,R=E.options.dataSorting,V=M.hoverPoints,ae=v(F.series.chart.renderer.globalAnimation),oe=()=>{for(let A in(F.graphic||F.graphics||F.dataLabel||F.dataLabels)&&(se(F),F.destroyElements()),F)delete F[A]};F.legendItem&&M.legend.destroyItem(F),V&&(F.setState(),C(V,F),V.length||(M.hoverPoints=null)),F===M.hoverPoint&&F.onMouseOut(),R&&R.enabled?(this.animateBeforeDestroy(),ce(oe,ae.duration)):oe(),M.pointCount--}this.destroyed=!0}destroyElements(F){let E=this,M=E.getGraphicalProps(F);M.singular.forEach(function(R){E[R]=E[R].destroy()}),M.plural.forEach(function(R){E[R].forEach(function(V){V&&V.element&&V.destroy()}),delete E[R]})}firePointEvent(F,E,M){let R=this,V=this.series.options;R.manageEvent(F),F==="click"&&V.allowPointSelect&&(M=function(ae){!R.destroyed&&R.select&&R.select(null,ae.ctrlKey||ae.metaKey||ae.shiftKey)}),ne(R,F,E,M)}getClassName(){return"highcharts-point"+(this.selected?" highcharts-point-select":"")+(this.negative?" highcharts-negative":"")+(this.isNull?" highcharts-null-point":"")+(this.colorIndex!==void 0?" highcharts-color-"+this.colorIndex:"")+(this.options.className?" "+this.options.className:"")+(this.zone&&this.zone.className?" "+this.zone.className.replace("highcharts-negative",""):"")}getGraphicalProps(F){let E,M,R=this,V=[],ae={singular:[],plural:[]};for((F=F||{graphic:1,dataLabel:1}).graphic&&V.push("graphic","connector"),F.dataLabel&&V.push("dataLabel","dataLabelPath","dataLabelUpper"),M=V.length;M--;)R[E=V[M]]&&ae.singular.push(E);return["graphic","dataLabel"].forEach(function(oe){let A=oe+"s";F[oe]&&R[A]&&ae.plural.push(A)}),ae}getLabelConfig(){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}}getNestedProperty(F){return F?F.indexOf("custom.")===0?$(F,this.options):this[F]:void 0}getZone(){let F=this.series,E=F.zones,M=F.zoneAxis||"y",R,V=0;for(R=E[0];this[M]>=R.value;)R=E[++V];return this.nonZonedColor||(this.nonZonedColor=this.color),R&&R.color&&!this.options.color?this.color=R.color:this.color=this.nonZonedColor,R}hasNewShapeType(){return(this.graphic&&(this.graphic.symbolName||this.graphic.element.nodeName))!==this.shapeType}constructor(F,E,M){this.formatPrefix="point",this.visible=!0,this.series=F,this.applyOptions(E,M),this.id??(this.id=I()),this.resolveColor(),F.chart.pointCount++,ne(this,"afterInit")}isValid(){return(Y(this.x)||this.x instanceof Date)&&Y(this.y)}optionsToObject(F){let E=this.series,M=E.options.keys,R=M||E.pointArrayMap||["y"],V=R.length,ae={},oe,A=0,ue=0;if(Y(F)||F===null)ae[R[0]]=F;else if(L(F))for(!M&&F.length>V&&((oe=typeof F[0])=="string"?ae.name=F[0]:oe==="number"&&(ae.x=F[0]),A++);ue<V;)M&&F[A]===void 0||(R[ue].indexOf(".")>0?H.prototype.setNestedProperty(ae,F[A],R[ue]):ae[R[ue]]=F[A]),A++,ue++;else typeof F=="object"&&(ae=F,F.dataLabels&&(E.hasDataLabels=()=>!0),F.marker&&(E._hasPointMarkers=!0));return ae}pos(F,E=this.plotY){if(!this.destroyed){let{plotX:M,series:R}=this,{chart:V,xAxis:ae,yAxis:oe}=R,A=0,ue=0;if(Y(M)&&Y(E))return F&&(A=ae?ae.pos:V.plotLeft,ue=oe?oe.pos:V.plotTop),V.inverted&&ae&&oe?[oe.len-E+ue,ae.len-M+A]:[M+A,E+ue]}}resolveColor(){let F=this.series,E=F.chart.options.chart,M=F.chart.styledMode,R,V,ae=E.colorCount,oe;delete this.nonZonedColor,F.options.colorByPoint?(M||(R=(V=F.options.colors||F.chart.options.colors)[F.colorCounter],ae=V.length),oe=F.colorCounter,F.colorCounter++,F.colorCounter===ae&&(F.colorCounter=0)):(M||(R=F.color),oe=F.colorIndex),this.colorIndex=Z(this.options.colorIndex,oe),this.color=Z(this.options.color,R)}setNestedProperty(F,E,M){return M.split(".").reduce(function(R,V,ae,oe){let A=oe.length-1===ae;return R[V]=A?E:X(R[V],!0)?R[V]:{},R[V]},F),F}shouldDraw(){return!this.isNull}tooltipFormatter(F){let E=this.series,M=E.tooltipOptions,R=Z(M.valueDecimals,""),V=M.valuePrefix||"",ae=M.valueSuffix||"";return E.chart.styledMode&&(F=E.chart.tooltip.styledModeFormat(F)),(E.pointArrayMap||["y"]).forEach(function(oe){oe="{point."+oe,(V||ae)&&(F=F.replace(RegExp(oe+"}","g"),V+oe+"}"+ae)),F=F.replace(RegExp(oe+"}","g"),oe+":,."+R+"f}")}),_(F,{point:this,series:this.series},E.chart)}update(F,E,M,R){let V,ae=this,oe=ae.series,A=ae.graphic,ue=oe.chart,me=oe.options;function g(){ae.applyOptions(F);let D=A&&ae.hasMockGraphic,j=ae.y===null?!D:D;A&&j&&(ae.graphic=A.destroy(),delete ae.hasMockGraphic),X(F,!0)&&(A&&A.element&&F&&F.marker&&F.marker.symbol!==void 0&&(ae.graphic=A.destroy()),F!=null&&F.dataLabels&&ae.dataLabel&&(ae.dataLabel=ae.dataLabel.destroy())),V=ae.index,oe.updateParallelArrays(ae,V),me.data[V]=X(me.data[V],!0)||X(F,!0)?ae.options:Z(F,me.data[V]),oe.isDirty=oe.isDirtyData=!0,!oe.fixedBox&&oe.hasCartesianSeries&&(ue.isDirtyBox=!0),me.legendType==="point"&&(ue.isDirtyLegend=!0),E&&ue.redraw(M)}E=Z(E,!0),R===!1?g():ae.firePointEvent("update",{options:F},g)}remove(F,E){this.series.removePoint(this.series.data.indexOf(this),F,E)}select(F,E){let M=this,R=M.series,V=R.chart;F=Z(F,!M.selected),this.selectedStaging=F,M.firePointEvent(F?"select":"unselect",{accumulate:E},function(){M.selected=M.options.selected=F,R.options.data[R.data.indexOf(M)]=M.options,M.setState(F&&"select"),E||V.getSelectedPoints().forEach(function(ae){let oe=ae.series;ae.selected&&ae!==M&&(ae.selected=ae.options.selected=!1,oe.options.data[oe.data.indexOf(ae)]=ae.options,ae.setState(V.hoverPoints&&oe.options.inactiveOtherPoints?"inactive":""),ae.firePointEvent("unselect"))})}),delete this.selectedStaging}onMouseOver(F){let{inverted:E,pointer:M}=this.series.chart;M&&(F=F?M.normalize(F):M.getChartCoordinatesFromPoint(this,E),M.runPointActions(F,this))}onMouseOut(){let F=this.series.chart;this.firePointEvent("mouseOut"),this.series.options.inactiveOtherPoints||(F.hoverPoints||[]).forEach(function(E){E.setState()}),F.hoverPoints=F.hoverPoint=null}manageEvent(F){var R,V,ae,oe,A,ue;let E=U(this.series.options.point,this.options),M=(R=E.events)==null?void 0:R[F];B(M)&&(!((V=this.hcEvents)!=null&&V[F])||((oe=(ae=this.hcEvents)==null?void 0:ae[F])==null?void 0:oe.map(me=>me.fn).indexOf(M))===-1)?((A=this.importedUserEvent)==null||A.call(this),this.importedUserEvent=T(this,F,M)):this.importedUserEvent&&!M&&((ue=this.hcEvents)!=null&&ue[F])&&(se(this,F),delete this.hcEvents[F],Object.keys(this.hcEvents)||delete this.importedUserEvent)}setState(F,E){var J;let M=this.series,R=this.state,V=M.options.states[F||"normal"]||{},ae=x.plotOptions[M.type].marker&&M.options.marker,oe=ae&&ae.enabled===!1,A=ae&&ae.states&&ae.states[F||"normal"]||{},ue=A.enabled===!1,me=this.marker||{},g=M.chart,D=ae&&M.markerAttribs,j=M.halo,K,te,O,z=M.stateMarkerGraphic,W;if((F=F||"")===this.state&&!E||this.selected&&F!=="select"||V.enabled===!1||F&&(ue||oe&&A.enabled===!1)||F&&me.states&&me.states[F]&&me.states[F].enabled===!1)return;if(this.state=F,D&&(K=M.markerAttribs(this,F)),this.graphic&&!this.hasMockGraphic){if(R&&this.graphic.removeClass("highcharts-point-"+R),F&&this.graphic.addClass("highcharts-point-"+F),!g.styledMode){te=M.pointAttribs(this,F),O=Z(g.options.chart.animation,V.animation);let le=te.opacity;M.options.inactiveOtherPoints&&Y(le)&&(this.dataLabels||[]).forEach(function(re){re&&!re.hasClass("highcharts-data-label-hidden")&&(re.animate({opacity:le},O),re.connector&&re.connector.animate({opacity:le},O))}),this.graphic.animate(te,O)}K&&this.graphic.animate(K,Z(g.options.chart.animation,A.animation,ae.animation)),z&&z.hide()}else F&&A&&(W=me.symbol||M.symbol,z&&z.currentSymbol!==W&&(z=z.destroy()),K&&(z?z[E?"animate":"attr"]({x:K.x,y:K.y}):W&&(M.stateMarkerGraphic=z=g.renderer.symbol(W,K.x,K.y,K.width,K.height).add(M.markerGroup),z.currentSymbol=W)),!g.styledMode&&z&&this.state!=="inactive"&&z.attr(M.pointAttribs(this,F))),z&&(z[F&&this.isInside?"show":"hide"](),z.element.point=this,z.addClass(this.getClassName(),!0));let de=V.halo,P=this.graphic||z,ee=P&&P.visibility||"inherit";de&&de.size&&P&&ee!=="hidden"&&!this.isCluster?(j||(M.halo=j=g.renderer.path().add(P.parentGroup)),j.show()[E?"animate":"attr"]({d:this.haloPath(de.size)}),j.attr({class:"highcharts-halo highcharts-color-"+Z(this.colorIndex,M.colorIndex)+(this.className?" "+this.className:""),visibility:ee,zIndex:-1}),j.point=this,g.styledMode||j.attr(G({fill:this.color||M.color,"fill-opacity":de.opacity},c.filterUserAttributes(de.attributes||{})))):(J=j==null?void 0:j.point)!=null&&J.haloPath&&!j.point.destroyed&&j.animate({d:j.point.haloPath(0)},null,j.hide),ne(this,"afterSetState",{state:F})}haloPath(F){let E=this.pos();return E?this.series.chart.renderer.symbols.circle(k(E[0],1)-F,E[1]-F,2*F,2*F):[]}}return H}),r(a,"Core/Pointer.js",[a["Core/Color/Color.js"],a["Core/Globals.js"],a["Core/Utilities.js"]],function(c,u,h){var p;let{parse:m}=c,{charts:v,composed:x,isTouchDevice:_}=u,{addEvent:T,attr:k,css:C,extend:G,find:ne,fireEvent:$,isNumber:L,isObject:B,objectEach:Y,offset:X,pick:U,pushUnique:Z,splat:ce}=h;class se{applyInactiveState(H){let Q=[],F;(H||[]).forEach(function(E){F=E.series,Q.push(F),F.linkedParent&&Q.push(F.linkedParent),F.linkedSeries&&(Q=Q.concat(F.linkedSeries)),F.navigatorSeries&&Q.push(F.navigatorSeries)}),this.chart.series.forEach(function(E){Q.indexOf(E)===-1?E.setState("inactive",!0):E.options.inactiveOtherPoints&&E.setAllPointsToState("inactive")})}destroy(){let H=this;this.eventsToUnbind.forEach(Q=>Q()),this.eventsToUnbind=[],!u.chartCount&&(se.unbindDocumentMouseUp&&se.unbindDocumentMouseUp.forEach(Q=>Q()),se.unbindDocumentTouchEnd&&(se.unbindDocumentTouchEnd=se.unbindDocumentTouchEnd())),clearInterval(H.tooltipTimeout),Y(H,function(Q,F){H[F]=void 0})}getSelectionMarkerAttrs(H,Q){let F={args:{chartX:H,chartY:Q},attrs:{},shapeType:"rect"};return $(this,"getSelectionMarkerAttrs",F,E=>{let M,{chart:R,zoomHor:V,zoomVert:ae}=this,{mouseDownX:oe=0,mouseDownY:A=0}=R,ue=E.attrs;ue.x=R.plotLeft,ue.y=R.plotTop,ue.width=V?1:R.plotWidth,ue.height=ae?1:R.plotHeight,V&&(M=H-oe,ue.width=Math.max(1,Math.abs(M)),ue.x=(M>0?0:M)+oe),ae&&(M=Q-A,ue.height=Math.max(1,Math.abs(M)),ue.y=(M>0?0:M)+A)}),F}drag(H){let{chart:Q}=this,{mouseDownX:F=0,mouseDownY:E=0}=Q,{panning:M,panKey:R,selectionMarkerFill:V}=Q.options.chart,ae=Q.plotLeft,oe=Q.plotTop,A=Q.plotWidth,ue=Q.plotHeight,me=B(M)?M.enabled:M,g=R&&H[`${R}Key`],D=H.chartX,j=H.chartY,K,te=this.selectionMarker;if((!te||!te.touch)&&(D<ae?D=ae:D>ae+A&&(D=ae+A),j<oe?j=oe:j>oe+ue&&(j=oe+ue),this.hasDragged=Math.sqrt(Math.pow(F-D,2)+Math.pow(E-j,2)),this.hasDragged>10)){K=Q.isInsidePlot(F-ae,E-oe,{visiblePlotOnly:!0});let{shapeType:O,attrs:z}=this.getSelectionMarkerAttrs(D,j);(Q.hasCartesianSeries||Q.mapView)&&this.hasZoom&&K&&!g&&!te&&(this.selectionMarker=te=Q.renderer[O](),te.attr({class:"highcharts-selection-marker",zIndex:7}).add(),Q.styledMode||te.attr({fill:V||m("#334eff").setOpacity(.25).get()})),te&&te.attr(z),K&&!te&&me&&Q.pan(H,M)}}dragStart(H){let Q=this.chart;Q.mouseIsDown=H.type,Q.cancelClick=!1,Q.mouseDownX=H.chartX,Q.mouseDownY=H.chartY}getSelectionBox(H){let Q={args:{marker:H},result:H.getBBox()};return $(this,"getSelectionBox",Q),Q.result}drop(H){let Q,{chart:F,selectionMarker:E}=this;for(let M of F.axes)M.isPanning&&(M.isPanning=!1,(M.options.startOnTick||M.options.endOnTick||M.series.some(R=>R.boosted))&&(M.forceRedraw=!0,M.setExtremes(M.userMin,M.userMax,!1),Q=!0));if(Q&&F.redraw(),E&&H){if(this.hasDragged){let M=this.getSelectionBox(E);F.transform({axes:F.axes.filter(R=>R.zoomEnabled&&(R.coll==="xAxis"&&this.zoomX||R.coll==="yAxis"&&this.zoomY)),selection:{originalEvent:H,xAxis:[],yAxis:[],...M},from:M})}L(F.index)&&(this.selectionMarker=E.destroy())}F&&L(F.index)&&(C(F.container,{cursor:F._cursor}),F.cancelClick=this.hasDragged>10,F.mouseIsDown=!1,this.hasDragged=0,this.pinchDown=[])}findNearestKDPoint(H,Q,F){let E;return H.forEach(function(M){let R=!(M.noSharedTooltip&&Q)&&0>M.options.findNearestPointBy.indexOf("y"),V=M.searchPoint(F,R);B(V,!0)&&V.series&&(!B(E,!0)||function(ae,oe){var g,D;let A=ae.distX-oe.distX,ue=ae.dist-oe.dist,me=((g=oe.series.group)==null?void 0:g.zIndex)-((D=ae.series.group)==null?void 0:D.zIndex);return A!==0&&Q?A:ue!==0?ue:me!==0?me:ae.series.index>oe.series.index?-1:1}(E,V)>0)&&(E=V)}),E}getChartCoordinatesFromPoint(H,Q){let{xAxis:F,yAxis:E}=H.series,M=H.shapeArgs;if(F&&E){let R=H.clientX??H.plotX??0,V=H.plotY||0;return H.isNode&&M&&L(M.x)&&L(M.y)&&(R=M.x,V=M.y),Q?{chartX:E.len+E.pos-V,chartY:F.len+F.pos-R}:{chartX:R+F.pos,chartY:V+E.pos}}if(M&&M.x&&M.y)return{chartX:M.x,chartY:M.y}}getChartPosition(){if(this.chartPosition)return this.chartPosition;let{container:H}=this.chart,Q=X(H);this.chartPosition={left:Q.left,top:Q.top,scaleX:1,scaleY:1};let{offsetHeight:F,offsetWidth:E}=H;return E>2&&F>2&&(this.chartPosition.scaleX=Q.width/E,this.chartPosition.scaleY=Q.height/F),this.chartPosition}getCoordinates(H){let Q={xAxis:[],yAxis:[]};for(let F of this.chart.axes)Q[F.isXAxis?"xAxis":"yAxis"].push({axis:F,value:F.toValue(H[F.horiz?"chartX":"chartY"])});return Q}getHoverData(H,Q,F,E,M,R){let V=[],ae=function(g){return g.visible&&!(!M&&g.directTouch)&&U(g.options.enableMouseTracking,!0)},oe=Q,A,ue={chartX:R?R.chartX:void 0,chartY:R?R.chartY:void 0,shared:M};$(this,"beforeGetHoverData",ue),A=oe&&!oe.stickyTracking?[oe]:F.filter(g=>g.stickyTracking&&(ue.filter||ae)(g));let me=E&&H||!R?H:this.findNearestKDPoint(A,M,R);return oe=me&&me.series,me&&(M&&!oe.noSharedTooltip?(A=F.filter(function(g){return ue.filter?ue.filter(g):ae(g)&&!g.noSharedTooltip})).forEach(function(g){let D=ne(g.points,function(j){return j.x===me.x&&!j.isNull});B(D)&&(g.boosted&&g.boost&&(D=g.boost.getPoint(D)),V.push(D))}):V.push(me)),$(this,"afterGetHoverData",ue={hoverPoint:me}),{hoverPoint:ue.hoverPoint,hoverSeries:oe,hoverPoints:V}}getPointFromEvent(H){let Q=H.target,F;for(;Q&&!F;)F=Q.point,Q=Q.parentNode;return F}onTrackerMouseOut(H){let Q=this.chart,F=H.relatedTarget,E=Q.hoverSeries;this.isDirectTouch=!1,!E||!F||E.stickyTracking||this.inClass(F,"highcharts-tooltip")||this.inClass(F,"highcharts-series-"+E.index)&&this.inClass(F,"highcharts-tracker")||E.onMouseOut()}inClass(H,Q){let F=H,E;for(;F;){if(E=k(F,"class")){if(E.indexOf(Q)!==-1)return!0;if(E.indexOf("highcharts-container")!==-1)return!1}F=F.parentElement}}constructor(H,Q){var F;this.hasDragged=0,this.pointerCaptureEventsToUnbind=[],this.eventsToUnbind=[],this.options=Q,this.chart=H,this.runChartClick=!!((F=Q.chart.events)!=null&&F.click),this.pinchDown=[],this.setDOMEvents(),$(this,"afterInit")}normalize(H,Q){let F=H.touches,E=F?F.length?F.item(0):U(F.changedTouches,H.changedTouches)[0]:H;Q||(Q=this.getChartPosition());let M=E.pageX-Q.left,R=E.pageY-Q.top;return G(H,{chartX:Math.round(M/=Q.scaleX),chartY:Math.round(R/=Q.scaleY)})}onContainerClick(H){let Q=this.chart,F=Q.hoverPoint,E=this.normalize(H),M=Q.plotLeft,R=Q.plotTop;!Q.cancelClick&&(F&&this.inClass(E.target,"highcharts-tracker")?($(F.series,"click",G(E,{point:F})),Q.hoverPoint&&F.firePointEvent("click",E)):(G(E,this.getCoordinates(E)),Q.isInsidePlot(E.chartX-M,E.chartY-R,{visiblePlotOnly:!0})&&$(Q,"click",E)))}onContainerMouseDown(H){var F;let Q=(1&(H.buttons||H.button))==1;H=this.normalize(H),u.isFirefox&&H.button!==0&&this.onContainerMouseMove(H),(H.button===void 0||Q)&&(this.zoomOption(H),Q&&((F=H.preventDefault)==null||F.call(H)),this.dragStart(H))}onContainerMouseLeave(H){let{pointer:Q}=v[U(se.hoverChartIndex,-1)]||{};H=this.normalize(H),this.onContainerMouseMove(H),Q&&!this.inClass(H.relatedTarget,"highcharts-tooltip")&&(Q.reset(),Q.chartPosition=void 0)}onContainerMouseEnter(){delete this.chartPosition}onContainerMouseMove(H){let Q=this.chart,F=Q.tooltip,E=this.normalize(H);this.setHoverChartIndex(H),(Q.mouseIsDown==="mousedown"||this.touchSelect(E))&&this.drag(E),!Q.openMenu&&(this.inClass(E.target,"highcharts-tracker")||Q.isInsidePlot(E.chartX-Q.plotLeft,E.chartY-Q.plotTop,{visiblePlotOnly:!0}))&&!(F&&F.shouldStickOnContact(E))&&(this.inClass(E.target,"highcharts-no-tooltip")?this.reset(!1,0):this.runPointActions(E))}onDocumentTouchEnd(H){this.onDocumentMouseUp(H)}onContainerTouchMove(H){this.touchSelect(H)?this.onContainerMouseMove(H):this.touch(H)}onContainerTouchStart(H){this.touchSelect(H)?this.onContainerMouseDown(H):(this.zoomOption(H),this.touch(H,!0))}onDocumentMouseMove(H){let Q=this.chart,F=Q.tooltip,E=this.chartPosition,M=this.normalize(H,E);!E||Q.isInsidePlot(M.chartX-Q.plotLeft,M.chartY-Q.plotTop,{visiblePlotOnly:!0})||F&&F.shouldStickOnContact(M)||M.target!==Q.container.ownerDocument&&this.inClass(M.target,"highcharts-tracker")||this.reset()}onDocumentMouseUp(H){var Q,F;(F=(Q=v[U(se.hoverChartIndex,-1)])==null?void 0:Q.pointer)==null||F.drop(H)}pinch(H){let Q=this,{chart:F,hasZoom:E,lastTouches:M}=Q,R=[].map.call(H.touches||[],ue=>Q.normalize(ue)),V=R.length,ae=V===1&&(Q.inClass(H.target,"highcharts-tracker")&&F.runTrackerClick||Q.runChartClick),oe=F.tooltip,A=V===1&&U(oe==null?void 0:oe.options.followTouchMove,!0);V>1?Q.initiated=!0:A&&(Q.initiated=!1),E&&Q.initiated&&!ae&&H.cancelable!==!1&&H.preventDefault(),H.type==="touchstart"?(Q.pinchDown=R,Q.res=!0,F.mouseDownX=H.chartX):A?this.runPointActions(Q.normalize(H)):M&&($(F,"touchpan",{originalEvent:H,touches:R},()=>{let ue=me=>{let g=me[0],D=me[1]||g;return{x:g.chartX,y:g.chartY,width:D.chartX-g.chartX,height:D.chartY-g.chartY}};F.transform({axes:F.axes.filter(me=>me.zoomEnabled&&(this.zoomHor&&me.horiz||this.zoomVert&&!me.horiz)),to:ue(R),from:ue(M),trigger:H.type})}),Q.res&&(Q.res=!1,this.reset(!1,0))),Q.lastTouches=R}reset(H,Q){let F=this.chart,E=F.hoverSeries,M=F.hoverPoint,R=F.hoverPoints,V=F.tooltip,ae=V&&V.shared?R:M;H&&ae&&ce(ae).forEach(function(oe){oe.series.isCartesian&&oe.plotX===void 0&&(H=!1)}),H?V&&ae&&ce(ae).length&&(V.refresh(ae),V.shared&&R?R.forEach(function(oe){oe.setState(oe.state,!0),oe.series.isCartesian&&(oe.series.xAxis.crosshair&&oe.series.xAxis.drawCrosshair(null,oe),oe.series.yAxis.crosshair&&oe.series.yAxis.drawCrosshair(null,oe))}):M&&(M.setState(M.state,!0),F.axes.forEach(function(oe){oe.crosshair&&M.series[oe.coll]===oe&&oe.drawCrosshair(null,M)}))):(M&&M.onMouseOut(),R&&R.forEach(function(oe){oe.setState()}),E&&E.onMouseOut(),V&&V.hide(Q),this.unDocMouseMove&&(this.unDocMouseMove=this.unDocMouseMove()),F.axes.forEach(function(oe){oe.hideCrosshair()}),F.hoverPoints=F.hoverPoint=void 0)}runPointActions(H,Q,F){let E=this.chart,M=E.series,R=E.tooltip&&E.tooltip.options.enabled?E.tooltip:void 0,V=!!R&&R.shared,ae=Q||E.hoverPoint,oe=ae&&ae.series||E.hoverSeries,A=(!H||H.type!=="touchmove")&&(!!Q||oe&&oe.directTouch&&this.isDirectTouch),ue=this.getHoverData(ae,oe,M,A,V,H);ae=ue.hoverPoint,oe=ue.hoverSeries;let me=ue.hoverPoints,g=oe&&oe.tooltipOptions.followPointer&&!oe.tooltipOptions.split,D=V&&oe&&!oe.noSharedTooltip;if(ae&&(F||ae!==E.hoverPoint||R&&R.isHidden)){if((E.hoverPoints||[]).forEach(function(j){me.indexOf(j)===-1&&j.setState()}),E.hoverSeries!==oe&&oe.onMouseOver(),this.applyInactiveState(me),(me||[]).forEach(function(j){j.setState("hover")}),E.hoverPoint&&E.hoverPoint.firePointEvent("mouseOut"),!ae.series)return;E.hoverPoints=me,E.hoverPoint=ae,ae.firePointEvent("mouseOver",void 0,()=>{R&&ae&&R.refresh(D?me:ae,H)})}else if(g&&R&&!R.isHidden){let j=R.getAnchor([{}],H);E.isInsidePlot(j[0],j[1],{visiblePlotOnly:!0})&&R.updatePosition({plotX:j[0],plotY:j[1]})}this.unDocMouseMove||(this.unDocMouseMove=T(E.container.ownerDocument,"mousemove",j=>{var K,te;return(te=(K=v[se.hoverChartIndex??-1])==null?void 0:K.pointer)==null?void 0:te.onDocumentMouseMove(j)}),this.eventsToUnbind.push(this.unDocMouseMove)),E.axes.forEach(function(j){let K,te=U((j.crosshair||{}).snap,!0);!te||(K=E.hoverPoint)&&K.series[j.coll]===j||(K=ne(me,O=>O.series&&O.series[j.coll]===j)),K||!te?j.drawCrosshair(H,K):j.hideCrosshair()})}setDOMEvents(){let H=this.chart.container,Q=H.ownerDocument;H.onmousedown=this.onContainerMouseDown.bind(this),H.onmousemove=this.onContainerMouseMove.bind(this),H.onclick=this.onContainerClick.bind(this),this.eventsToUnbind.push(T(H,"mouseenter",this.onContainerMouseEnter.bind(this)),T(H,"mouseleave",this.onContainerMouseLeave.bind(this))),se.unbindDocumentMouseUp||(se.unbindDocumentMouseUp=[]),se.unbindDocumentMouseUp.push(T(Q,"mouseup",this.onDocumentMouseUp.bind(this)));let F=this.chart.renderTo.parentElement;for(;F&&F.tagName!=="BODY";)this.eventsToUnbind.push(T(F,"scroll",()=>{delete this.chartPosition})),F=F.parentElement;this.eventsToUnbind.push(T(H,"touchstart",this.onContainerTouchStart.bind(this),{passive:!1}),T(H,"touchmove",this.onContainerTouchMove.bind(this),{passive:!1})),se.unbindDocumentTouchEnd||(se.unbindDocumentTouchEnd=T(Q,"touchend",this.onDocumentTouchEnd.bind(this),{passive:!1})),this.setPointerCapture(),T(this.chart,"redraw",this.setPointerCapture.bind(this))}setPointerCapture(){var M,R;if(!_)return;let H=this.pointerCaptureEventsToUnbind,Q=this.chart,F=Q.container,E=U((M=Q.options.tooltip)==null?void 0:M.followTouchMove,!0)&&Q.series.some(V=>V.options.findNearestPointBy.indexOf("y")>-1);!this.hasPointerCapture&&E?(H.push(T(F,"pointerdown",V=>{var ae,oe;(ae=V.target)!=null&&ae.hasPointerCapture(V.pointerId)&&((oe=V.target)==null||oe.releasePointerCapture(V.pointerId))}),T(F,"pointermove",V=>{var ae,oe;(oe=(ae=Q.pointer)==null?void 0:ae.getPointFromEvent(V))==null||oe.onMouseOver(V)})),Q.styledMode||C(F,{"touch-action":"none"}),F.className+=" highcharts-no-touch-action",this.hasPointerCapture=!0):this.hasPointerCapture&&!E&&(H.forEach(V=>V()),H.length=0,Q.styledMode||C(F,{"touch-action":U((R=Q.options.chart.style)==null?void 0:R["touch-action"],"manipulation")}),F.className=F.className.replace(" highcharts-no-touch-action",""),this.hasPointerCapture=!1)}setHoverChartIndex(H){var E;let Q=this.chart,F=u.charts[U(se.hoverChartIndex,-1)];if(F&&F!==Q){let M={relatedTarget:Q.container};H&&!(H!=null&&H.relatedTarget)&&(H={...M,...H}),(E=F.pointer)==null||E.onContainerMouseLeave(H||M)}F&&F.mouseIsDown||(se.hoverChartIndex=Q.index)}touch(H,Q){let F,{chart:E,pinchDown:M=[]}=this;this.setHoverChartIndex(),(H=this.normalize(H)).touches.length===1?E.isInsidePlot(H.chartX-E.plotLeft,H.chartY-E.plotTop,{visiblePlotOnly:!0})&&!E.openMenu?(Q&&this.runPointActions(H),H.type==="touchmove"&&(F=!!M[0]&&Math.pow(M[0].chartX-H.chartX,2)+Math.pow(M[0].chartY-H.chartY,2)>=16),U(F,!0)&&this.pinch(H)):Q&&this.reset():H.touches.length===2&&this.pinch(H)}touchSelect(H){return!!(this.chart.zooming.singleTouch&&H.touches&&H.touches.length===1)}zoomOption(H){let Q=this.chart,F=Q.inverted,E=Q.zooming.type||"",M,R;/touch/.test(H.type)&&(E=U(Q.zooming.pinchType,E)),this.zoomX=M=/x/.test(E),this.zoomY=R=/y/.test(E),this.zoomHor=M&&!F||R&&F,this.zoomVert=R&&!F||M&&F,this.hasZoom=M||R}}return(p=se||(se={})).compose=function(I){Z(x,"Core.Pointer")&&T(I,"beforeRender",function(){this.pointer=new p(this,this.options)})},se}),r(a,"Core/Legend/LegendSymbol.js",[a["Core/Utilities.js"]],function(c){var u;let{extend:h,merge:p,pick:m}=c;return function(v){function x(_,T,k){var F,E;let C=this.legendItem=this.legendItem||{},{chart:G,options:ne}=this,{baseline:$=0,symbolWidth:L,symbolHeight:B}=_,Y=this.symbol||"circle",X=B/2,U=G.renderer,Z=C.group,ce=$-Math.round((((F=_.fontMetrics)==null?void 0:F.b)||B)*(k?.4:.3)),se={},I,H=ne.marker,Q=0;if(G.styledMode||(se["stroke-width"]=Math.min(ne.lineWidth||0,24),ne.dashStyle?se.dashstyle=ne.dashStyle:ne.linecap==="square"||(se["stroke-linecap"]="round")),C.line=U.path().addClass("highcharts-graph").attr(se).add(Z),k&&(C.area=U.path().addClass("highcharts-area").add(Z)),se["stroke-linecap"]&&(Q=Math.min(C.line.strokeWidth(),L)/2),L){let M=[["M",Q,ce],["L",L-Q,ce]];C.line.attr({d:M}),(E=C.area)==null||E.attr({d:[...M,["L",L-Q,$],["L",Q,$]]})}if(H&&H.enabled!==!1&&L){let M=Math.min(m(H.radius,X),X);Y.indexOf("url")===0&&(H=p(H,{width:B,height:B}),M=0),C.symbol=I=U.symbol(Y,L/2-M,ce-M,2*M,2*M,h({context:"legend"},H)).addClass("highcharts-point").add(Z),I.isMarker=!0}}v.areaMarker=function(_,T){x.call(this,_,T,!0)},v.lineMarker=x,v.rectangle=function(_,T){let k=T.legendItem||{},C=_.options,G=_.symbolHeight,ne=C.squareSymbol,$=ne?G:_.symbolWidth;k.symbol=this.chart.renderer.rect(ne?(_.symbolWidth-G)/2:0,_.baseline-G+1,$,G,m(_.options.symbolRadius,G/2)).addClass("highcharts-point").attr({zIndex:3}).add(k.group)}}(u||(u={})),u}),r(a,"Core/Series/SeriesDefaults.js",[],function(){return{lineWidth:2,allowPointSelect:!1,crisp:!0,showCheckbox:!1,animation:{duration:1e3},enableMouseTracking:!0,events:{},marker:{enabledThreshold:2,lineColor:"#ffffff",lineWidth:0,radius:4,states:{normal:{animation:!0},hover:{animation:{duration:150},enabled:!0,radiusPlus:2,lineWidthPlus:1},select:{fillColor:"#cccccc",lineColor:"#000000",lineWidth:2}}},point:{events:{}},dataLabels:{animation:{},align:"center",borderWidth:0,defer:!0,formatter:function(){let{numberFormatter:c}=this.series.chart;return typeof this.y!="number"?"":c(this.y,-1)},padding:5,style:{fontSize:"0.7em",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:150},lineWidthPlus:1,marker:{},halo:{size:10,opacity:.25}},select:{animation:{duration:0}},inactive:{animation:{duration:150},opacity:.2}},stickyTracking:!0,turboThreshold:1e3,findNearestPointBy:"x"}}),r(a,"Core/Series/SeriesRegistry.js",[a["Core/Globals.js"],a["Core/Defaults.js"],a["Core/Series/Point.js"],a["Core/Utilities.js"]],function(c,u,h,p){var m;let{defaultOptions:v}=u,{extend:x,extendClass:_,merge:T}=p;return function(k){function C(G,ne){let $=v.plotOptions||{},L=ne.defaultOptions,B=ne.prototype;return B.type=G,B.pointClass||(B.pointClass=h),!k.seriesTypes[G]&&(L&&($[G]=L),k.seriesTypes[G]=ne,!0)}k.seriesTypes=c.seriesTypes,k.registerSeriesType=C,k.seriesType=function(G,ne,$,L,B){let Y=v.plotOptions||{};if(ne=ne||"",Y[G]=T(Y[ne],$),delete k.seriesTypes[G],C(G,_(k.seriesTypes[ne]||function(){},L)),k.seriesTypes[G].prototype.type=G,B){class X extends h{}x(X.prototype,B),k.seriesTypes[G].prototype.pointClass=X}return k.seriesTypes[G]}}(m||(m={})),m}),r(a,"Core/Series/Series.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Defaults.js"],a["Core/Foundation.js"],a["Core/Globals.js"],a["Core/Legend/LegendSymbol.js"],a["Core/Series/Point.js"],a["Core/Series/SeriesDefaults.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Renderer/SVG/SVGElement.js"],a["Core/Utilities.js"]],function(c,u,h,p,m,v,x,_,T,k){let{animObject:C,setAnimation:G}=c,{defaultOptions:ne}=u,{registerEventOptions:$}=h,{svg:L,win:B}=p,{seriesTypes:Y}=_,{arrayMax:X,arrayMin:U,clamp:Z,correctFloat:ce,crisp:se,defined:I,destroyObjectProperties:H,diffObjects:Q,erase:F,error:E,extend:M,find:R,fireEvent:V,getClosestDistance:ae,getNestedProperty:oe,insertItem:A,isArray:ue,isNumber:me,isString:g,merge:D,objectEach:j,pick:K,removeEvent:te,splat:O,syncTimeout:z}=k;class W{constructor(){this.zoneAxis="y"}init(P,ee){let J;V(this,"init",{options:ee});let le=this,re=P.series;this.eventsToUnbind=[],le.chart=P,le.options=le.setOptions(ee);let ge=le.options,ve=ge.visible!==!1;le.linkedSeries=[],le.bindAxes(),M(le,{name:ge.name,state:"",visible:ve,selected:ge.selected===!0}),$(this,ge);let we=ge.events;(we&&we.click||ge.point&&ge.point.events&&ge.point.events.click||ge.allowPointSelect)&&(P.runTrackerClick=!0),le.getColor(),le.getSymbol(),le.parallelArrays.forEach(function(Ce){le[Ce+"Data"]||(le[Ce+"Data"]=[])}),le.isCartesian&&(P.hasCartesianSeries=!0),re.length&&(J=re[re.length-1]),le._i=K(J&&J._i,-1)+1,le.opacity=le.options.opacity,P.orderItems("series",A(this,re)),ge.dataSorting&&ge.dataSorting.enabled?le.setDataSortingOptions():le.points||le.data||le.setData(ge.data,!1),V(this,"afterInit")}is(P){return Y[P]&&this instanceof Y[P]}bindAxes(){let P,ee=this,J=ee.options,le=ee.chart;V(this,"bindAxes",null,function(){(ee.axisTypes||[]).forEach(function(re){(le[re]||[]).forEach(function(ge){P=ge.options,(K(J[re],0)===ge.index||J[re]!==void 0&&J[re]===P.id)&&(A(ee,ge.series),ee[re]=ge,ge.isDirty=!0)}),ee[re]||ee.optionalAxis===re||E(18,!0,le)})}),V(this,"afterBindAxes")}updateParallelArrays(P,ee,J){let le=P.series,re=me(ee)?function(ge){let ve=ge==="y"&&le.toYData?le.toYData(P):P[ge];le[ge+"Data"][ee]=ve}:function(ge){Array.prototype[ee].apply(le[ge+"Data"],J)};le.parallelArrays.forEach(re)}hasData(){return this.visible&&this.dataMax!==void 0&&this.dataMin!==void 0||this.visible&&this.yData&&this.yData.length>0}hasMarkerChanged(P,ee){let J=P.marker,le=ee.marker||{};return J&&(le.enabled&&!J.enabled||le.symbol!==J.symbol||le.height!==J.height||le.width!==J.width)}autoIncrement(P){let ee=this.options,J=ee.pointIntervalUnit,le=ee.relativeXValue,re=this.chart.time,ge=this.xIncrement,ve,we;return ge=K(ge,ee.pointStart,0),this.pointInterval=we=K(this.pointInterval,ee.pointInterval,1),le&&me(P)&&(we*=P),J&&(ve=new re.Date(ge),J==="day"?re.set("Date",ve,re.get("Date",ve)+we):J==="month"?re.set("Month",ve,re.get("Month",ve)+we):J==="year"&&re.set("FullYear",ve,re.get("FullYear",ve)+we),we=ve.getTime()-ge),le&&me(P)?ge+we:(this.xIncrement=ge+we,ge)}setDataSortingOptions(){let P=this.options;M(this,{requireSorting:!1,sorted:!1,enabledDataSorting:!0,allowDG:!1}),I(P.pointRange)||(P.pointRange=1)}setOptions(P){var Se,Ae;let ee,J=this.chart,le=J.options.plotOptions,re=J.userOptions||{},ge=D(P),ve=J.styledMode,we={plotOptions:le,userOptions:ge};V(this,"setOptions",we);let Ce=we.plotOptions[this.type],Me=re.plotOptions||{},De=Me.series||{},be=ne.plotOptions[this.type]||{},ye=Me[this.type]||{};this.userOptions=we.userOptions;let xe=D(Ce,le.series,ye,ge);this.tooltipOptions=D(ne.tooltip,(Se=ne.plotOptions.series)==null?void 0:Se.tooltip,be==null?void 0:be.tooltip,J.userOptions.tooltip,(Ae=Me.series)==null?void 0:Ae.tooltip,ye.tooltip,ge.tooltip),this.stickyTracking=K(ge.stickyTracking,ye.stickyTracking,De.stickyTracking,!!this.tooltipOptions.shared&&!this.noSharedTooltip||xe.stickyTracking),Ce.marker===null&&delete xe.marker,this.zoneAxis=xe.zoneAxis||"y";let pe=this.zones=(xe.zones||[]).map(Te=>({...Te}));return(xe.negativeColor||xe.negativeFillColor)&&!xe.zones&&(ee={value:xe[this.zoneAxis+"Threshold"]||xe.threshold||0,className:"highcharts-negative"},ve||(ee.color=xe.negativeColor,ee.fillColor=xe.negativeFillColor),pe.push(ee)),pe.length&&I(pe[pe.length-1].value)&&pe.push(ve?{}:{color:this.color,fillColor:this.fillColor}),V(this,"afterSetOptions",{options:xe}),xe}getName(){return K(this.options.name,"Series "+(this.index+1))}getCyclic(P,ee,J){let le,re,ge=this.chart,ve=`${P}Index`,we=`${P}Counter`,Ce=(J==null?void 0:J.length)||ge.options.chart.colorCount;!ee&&(I(re=K(P==="color"?this.options.colorIndex:void 0,this[ve]))?le=re:(ge.series.length||(ge[we]=0),le=ge[we]%Ce,ge[we]+=1),J&&(ee=J[le])),le!==void 0&&(this[ve]=le),this[P]=ee}getColor(){this.chart.styledMode?this.getCyclic("color"):this.options.colorByPoint?this.color="#cccccc":this.getCyclic("color",this.options.color||ne.plotOptions[this.type].color,this.chart.options.colors)}getPointsCollection(){return(this.hasGroupedData?this.points:this.data)||[]}getSymbol(){let P=this.options.marker;this.getCyclic("symbol",P.symbol,this.chart.options.symbols)}findPointIndex(P,ee){let J,le,re,ge=P.id,ve=P.x,we=this.points,Ce=this.options.dataSorting;if(ge){let Me=this.chart.get(ge);Me instanceof v&&(J=Me)}else if(this.linkedParent||this.enabledDataSorting||this.options.relativeXValue){let Me=De=>!De.touched&&De.index===P.index;if(Ce&&Ce.matchByName?Me=De=>!De.touched&&De.name===P.name:this.options.relativeXValue&&(Me=De=>!De.touched&&De.options.x===P.x),!(J=R(we,Me)))return}return J&&(re=J&&J.index)!==void 0&&(le=!0),re===void 0&&me(ve)&&(re=this.xData.indexOf(ve,ee)),re!==-1&&re!==void 0&&this.cropped&&(re=re>=this.cropStart?re-this.cropStart:re),!le&&me(re)&&we[re]&&we[re].touched&&(re=void 0),re}updateData(P,ee){let J=this.options,le=J.dataSorting,re=this.points,ge=[],ve=this.requireSorting,we=P.length===re.length,Ce,Me,De,be,ye=!0;if(this.xIncrement=null,P.forEach(function(xe,pe){let Se,Ae=I(xe)&&this.pointClass.prototype.optionsToObject.call({series:this},xe)||{},Te=Ae.x;Ae.id||me(Te)?((Se=this.findPointIndex(Ae,be))===-1||Se===void 0?ge.push(xe):re[Se]&&xe!==J.data[Se]?(re[Se].update(xe,!1,null,!1),re[Se].touched=!0,ve&&(be=Se+1)):re[Se]&&(re[Se].touched=!0),(!we||pe!==Se||le&&le.enabled||this.hasDerivedData)&&(Ce=!0)):ge.push(xe)},this),Ce)for(Me=re.length;Me--;)(De=re[Me])&&!De.touched&&De.remove&&De.remove(!1,ee);else!we||le&&le.enabled?ye=!1:(P.forEach(function(xe,pe){xe===re[pe].y||re[pe].destroyed||re[pe].update(xe,!1,null,!1)}),ge.length=0);return re.forEach(function(xe){xe&&(xe.touched=!1)}),!!ye&&(ge.forEach(function(xe){this.addPoint(xe,!1,null,null,!1)},this),this.xIncrement===null&&this.xData&&this.xData.length&&(this.xIncrement=X(this.xData),this.autoIncrement()),!0)}setData(P,ee=!0,J,le){var ft;let re=this,ge=re.points,ve=ge&&ge.length||0,we=re.options,Ce=re.chart,Me=we.dataSorting,De=re.xAxis,be=we.turboThreshold,ye=this.xData,xe=this.yData,pe=re.pointArrayMap,Se=pe&&pe.length,Ae=we.keys,Te,Oe,ze,Ge=0,Ve=1,qe;Ce.options.chart.allowMutatingData||(we.data&&delete re.options.data,re.userOptions.data&&delete re.userOptions.data,qe=D(!0,P));let ot=(P=qe||P||[]).length;if(Me&&Me.enabled&&(P=this.sortData(P)),Ce.options.chart.allowMutatingData&&le!==!1&&ot&&ve&&!re.cropped&&!re.hasGroupedData&&re.visible&&!re.boosted&&(ze=this.updateData(P,J)),!ze){re.xIncrement=null,re.colorCounter=0,this.parallelArrays.forEach(function(et){re[et+"Data"].length=0});let dt=be&&ot>be;if(dt){let et=re.getFirstValidPoint(P),Pt=re.getFirstValidPoint(P,ot-1,-1),Ie=gt=>!!(ue(gt)&&(Ae||me(gt[0])));if(me(et)&&me(Pt))for(Te=0;Te<ot;Te++)ye[Te]=this.autoIncrement(),xe[Te]=P[Te];else if(Ie(et)&&Ie(Pt))if(Se)if(et.length===Se)for(Te=0;Te<ot;Te++)ye[Te]=this.autoIncrement(),xe[Te]=P[Te];else for(Te=0;Te<ot;Te++)Oe=P[Te],ye[Te]=Oe[0],xe[Te]=Oe.slice(1,Se+1);else if(Ae&&(Ge=Ae.indexOf("x"),Ve=Ae.indexOf("y"),Ge=Ge>=0?Ge:0,Ve=Ve>=0?Ve:1),et.length===1&&(Ve=0),Ge===Ve)for(Te=0;Te<ot;Te++)ye[Te]=this.autoIncrement(),xe[Te]=P[Te][Ve];else for(Te=0;Te<ot;Te++)Oe=P[Te],ye[Te]=Oe[Ge],xe[Te]=Oe[Ve];else dt=!1}if(!dt)for(Te=0;Te<ot;Te++)Oe={series:re},re.pointClass.prototype.applyOptions.apply(Oe,[P[Te]]),re.updateParallelArrays(Oe,Te);for(xe&&g(xe[0])&&E(14,!0,Ce),re.data=[],re.options.data=re.userOptions.data=P,Te=ve;Te--;)(ft=ge[Te])==null||ft.destroy();De&&(De.minRange=De.userMinRange),re.isDirty=Ce.isDirtyBox=!0,re.isDirtyData=!!ge,J=!1}we.legendType==="point"&&(this.processData(),this.generatePoints()),ee&&Ce.redraw(J)}sortData(P){let ee=this,J=ee.options.dataSorting.sortKey||"y",le=function(re,ge){return I(ge)&&re.pointClass.prototype.optionsToObject.call({series:re},ge)||{}};return P.forEach(function(re,ge){P[ge]=le(ee,re),P[ge].index=ge},this),P.concat().sort((re,ge)=>{let ve=oe(J,re),we=oe(J,ge);return we<ve?-1:we>ve?1:0}).forEach(function(re,ge){re.x=ge},this),ee.linkedSeries&&ee.linkedSeries.forEach(function(re){let ge=re.options,ve=ge.data;ge.dataSorting&&ge.dataSorting.enabled||!ve||(ve.forEach(function(we,Ce){ve[Ce]=le(re,we),P[Ce]&&(ve[Ce].x=P[Ce].x,ve[Ce].index=Ce)}),re.setData(ve,!1))}),P}getProcessedData(P){let ee=this,J=ee.xAxis,le=ee.options.cropThreshold,re=J==null?void 0:J.logarithmic,ge=ee.isCartesian,ve,we,Ce=0,Me,De,be,ye=ee.xData,xe=ee.yData,pe=!1,Se=ye.length;J&&(De=(Me=J.getExtremes()).min,be=Me.max,pe=!!(J.categories&&!J.names.length)),ge&&ee.sorted&&!P&&(!le||Se>le||ee.forceCrop)&&(ye[Se-1]<De||ye[0]>be?(ye=[],xe=[]):ee.yData&&(ye[0]<De||ye[Se-1]>be)&&(ye=(ve=this.cropData(ee.xData,ee.yData,De,be)).xData,xe=ve.yData,Ce=ve.start,we=!0));let Ae=ae([re?ye.map(re.log2lin):ye],()=>ee.requireSorting&&!pe&&E(15,!1,ee.chart));return{xData:ye,yData:xe,cropped:we,cropStart:Ce,closestPointRange:Ae}}processData(P){let ee=this.xAxis;if(this.isCartesian&&!this.isDirty&&!ee.isDirty&&!this.yAxis.isDirty&&!P)return!1;let J=this.getProcessedData();this.cropped=J.cropped,this.cropStart=J.cropStart,this.processedXData=J.xData,this.processedYData=J.yData,this.closestPointRange=this.basePointRange=J.closestPointRange,V(this,"afterProcessData")}cropData(P,ee,J,le){let re=P.length,ge,ve,we=0,Ce=re;for(ge=0;ge<re;ge++)if(P[ge]>=J){we=Math.max(0,ge-1);break}for(ve=ge;ve<re;ve++)if(P[ve]>le){Ce=ve+1;break}return{xData:P.slice(we,Ce),yData:ee.slice(we,Ce),start:we,end:Ce}}generatePoints(){let P=this.options,ee=this.processedData||P.data,J=this.processedXData,le=this.processedYData,re=this.pointClass,ge=J.length,ve=this.cropStart||0,we=this.hasGroupedData,Ce=P.keys,Me=[],De=P.dataGrouping&&P.dataGrouping.groupAll?ve:0,be,ye,xe,pe,Se=this.data;if(!Se&&!we){let Ae=[];Ae.length=ee.length,Se=this.data=Ae}for(Ce&&we&&(this.options.keys=!1),pe=0;pe<ge;pe++)ye=ve+pe,we?((xe=new re(this,[J[pe]].concat(O(le[pe])))).dataGroup=this.groupMap[De+pe],xe.dataGroup.options&&(xe.options=xe.dataGroup.options,M(xe,xe.dataGroup.options),delete xe.dataLabels)):(xe=Se[ye])||ee[ye]===void 0||(Se[ye]=xe=new re(this,ee[ye],J[pe])),xe&&(xe.index=we?De+pe:ye,Me[pe]=xe);if(this.options.keys=Ce,Se&&(ge!==(be=Se.length)||we))for(pe=0;pe<be;pe++)pe!==ve||we||(pe+=ge),Se[pe]&&(Se[pe].destroyElements(),Se[pe].plotX=void 0);this.data=Se,this.points=Me,V(this,"afterGeneratePoints")}getXExtremes(P){return{min:U(P),max:X(P)}}getExtremes(P,ee){let J=this.xAxis,le=this.yAxis,re=[],ge=this.requireSorting&&!this.is("column")?1:0,ve=!!le&&le.positiveValuesOnly,we=ee||this.getExtremesFromAll||this.options.getExtremesFromAll,{processedXData:Ce,processedYData:Me}=this,De,be,ye,xe,pe,Se,Ae,Te=0,Oe=0,ze=0;if(this.cropped&&we){let ot=this.getProcessedData(!0);Ce=ot.xData,Me=ot.yData}let Ge=(P=P||this.stackedYData||Me||[]).length,Ve=Ce||this.xData;for(J&&(Te=(De=J.getExtremes()).min,Oe=De.max),Se=0;Se<Ge;Se++)if(xe=Ve[Se],be=(me(pe=P[Se])||ue(pe))&&((me(pe)?pe>0:pe.length)||!ve),ye=ee||this.getExtremesFromAll||this.options.getExtremesFromAll||this.cropped||!J||(Ve[Se+ge]||xe)>=Te&&(Ve[Se-ge]||xe)<=Oe,be&&ye)if(Ae=pe.length)for(;Ae--;)me(pe[Ae])&&(re[ze++]=pe[Ae]);else re[ze++]=pe;let qe={activeYData:re,dataMin:U(re),dataMax:X(re)};return V(this,"afterGetExtremes",{dataExtremes:qe}),qe}applyExtremes(){let P=this.getExtremes();return this.dataMin=P.dataMin,this.dataMax=P.dataMax,P}getFirstValidPoint(P,ee=0,J=1){let le=P.length,re=ee;for(;re>=0&&re<le;){if(I(P[re]))return P[re];re+=J}}translate(){var Oe;this.processedXData||this.processData(),this.generatePoints();let P=this.options,ee=P.stacking,J=this.xAxis,le=J.categories,re=this.enabledDataSorting,ge=this.yAxis,ve=this.points,we=ve.length,Ce=this.pointPlacementToXValue(),Me=!!Ce,De=P.threshold,be=P.startFromThreshold?De:0,ye,xe,pe,Se,Ae=Number.MAX_VALUE;function Te(ze){return Z(ze,-1e9,1e9)}for(ye=0;ye<we;ye++){let ze,Ge=ve[ye],Ve=Ge.x,qe,ot,ft=Ge.y,dt=Ge.low,et=ee&&((Oe=ge.stacking)==null?void 0:Oe.stacks[(this.negStacks&&ft<(be?0:De)?"-":"")+this.stackKey]);xe=J.translate(Ve,!1,!1,!1,!0,Ce),Ge.plotX=me(xe)?ce(Te(xe)):void 0,ee&&this.visible&&et&&et[Ve]&&(Se=this.getStackIndicator(Se,Ve,this.index),!Ge.isNull&&Se.key&&(ot=(qe=et[Ve]).points[Se.key]),qe&&ue(ot)&&(dt=ot[0],ft=ot[1],dt===be&&Se.key===et[Ve].base&&(dt=K(me(De)?De:ge.min)),ge.positiveValuesOnly&&I(dt)&&dt<=0&&(dt=void 0),Ge.total=Ge.stackTotal=K(qe.total),Ge.percentage=I(Ge.y)&&qe.total?Ge.y/qe.total*100:void 0,Ge.stackY=ft,this.irregularWidths||qe.setOffset(this.pointXOffset||0,this.barW||0,void 0,void 0,void 0,this.xAxis))),Ge.yBottom=I(dt)?Te(ge.translate(dt,!1,!0,!1,!0)):void 0,this.dataModify&&(ft=this.dataModify.modifyValue(ft,ye)),me(ft)&&Ge.plotX!==void 0&&(ze=me(ze=ge.translate(ft,!1,!0,!1,!0))?Te(ze):void 0),Ge.plotY=ze,Ge.isInside=this.isPointInside(Ge),Ge.clientX=Me?ce(J.translate(Ve,!1,!1,!1,!0,Ce)):xe,Ge.negative=(Ge.y||0)<(De||0),Ge.category=K(le&&le[Ge.x],Ge.x),Ge.isNull||Ge.visible===!1||(pe!==void 0&&(Ae=Math.min(Ae,Math.abs(xe-pe))),pe=xe),Ge.zone=this.zones.length?Ge.getZone():void 0,!Ge.graphic&&this.group&&re&&(Ge.isNew=!0)}this.closestPointRangePx=Ae,V(this,"afterTranslate")}getValidPoints(P,ee,J){let le=this.chart;return(P||this.points||[]).filter(function(re){let{plotX:ge,plotY:ve}=re;return!!((J||!re.isNull&&me(ve))&&(!ee||le.isInsidePlot(ge,ve,{inverted:le.inverted})))&&re.visible!==!1})}getClipBox(){let{chart:P,xAxis:ee,yAxis:J}=this,{x:le,y:re,width:ge,height:ve}=D(P.clipBox);return ee&&ee.len!==P.plotSizeX&&(ge=ee.len),J&&J.len!==P.plotSizeY&&(ve=J.len),P.inverted&&!this.invertible&&([ge,ve]=[ve,ge]),{x:le,y:re,width:ge,height:ve}}getSharedClipKey(){return this.sharedClipKey=(this.options.xAxis||0)+","+(this.options.yAxis||0),this.sharedClipKey}setClip(){let{chart:P,group:ee,markerGroup:J}=this,le=P.sharedClips,re=P.renderer,ge=this.getClipBox(),ve=this.getSharedClipKey(),we=le[ve];we?we.animate(ge):le[ve]=we=re.clipRect(ge),ee&&ee.clip(this.options.clip===!1?void 0:we),J&&J.clip()}animate(P){let{chart:ee,group:J,markerGroup:le}=this,re=ee.inverted,ge=C(this.options.animation),ve=[this.getSharedClipKey(),ge.duration,ge.easing,ge.defer].join(","),we=ee.sharedClips[ve],Ce=ee.sharedClips[ve+"m"];if(P&&J){let Me=this.getClipBox();if(we)we.attr("height",Me.height);else{Me.width=0,re&&(Me.x=ee.plotHeight),we=ee.renderer.clipRect(Me),ee.sharedClips[ve]=we;let De={x:-99,y:-99,width:re?ee.plotWidth+199:99,height:re?99:ee.plotHeight+199};Ce=ee.renderer.clipRect(De),ee.sharedClips[ve+"m"]=Ce}J.clip(we),le==null||le.clip(Ce)}else if(we&&!we.hasClass("highcharts-animating")){let Me=this.getClipBox(),De=ge.step;(le!=null&&le.element.childNodes.length||ee.series.length>1)&&(ge.step=function(be,ye){De&&De.apply(ye,arguments),ye.prop==="width"&&(Ce!=null&&Ce.element)&&Ce.attr(re?"height":"width",be+99)}),we.addClass("highcharts-animating").animate(Me,ge)}}afterAnimate(){this.setClip(),j(this.chart.sharedClips,(P,ee,J)=>{P&&!this.chart.container.querySelector(`[clip-path="url(#${P.id})"]`)&&(P.destroy(),delete J[ee])}),this.finishedAnimating=!0,V(this,"afterAnimate")}drawPoints(P=this.points){let ee,J,le,re,ge,ve,we,Ce=this.chart,Me=Ce.styledMode,{colorAxis:De,options:be}=this,ye=be.marker,xe=this[this.specialGroup||"markerGroup"],pe=this.xAxis,Se=K(ye.enabled,!pe||!!pe.isRadial||null,this.closestPointRangePx>=ye.enabledThreshold*ye.radius);if(ye.enabled!==!1||this._hasPointMarkers)for(ee=0;ee<P.length;ee++)if(re=(le=(J=P[ee]).graphic)?"animate":"attr",ge=J.marker||{},ve=!!J.marker,(Se&&ge.enabled===void 0||ge.enabled)&&!J.isNull&&J.visible!==!1){let Ae=K(ge.symbol,this.symbol,"rect");we=this.markerAttribs(J,J.selected&&"select"),this.enabledDataSorting&&(J.startXPos=pe.reversed?-(we.width||0):pe.width);let Te=J.isInside!==!1;if(!le&&Te&&((we.width||0)>0||J.hasImage)&&(J.graphic=le=Ce.renderer.symbol(Ae,we.x,we.y,we.width,we.height,ve?ge:ye).add(xe),this.enabledDataSorting&&Ce.hasRendered&&(le.attr({x:J.startXPos}),re="animate")),le&&re==="animate"&&le[Te?"show":"hide"](Te).animate(we),le){let Oe=this.pointAttribs(J,Me||!J.selected?void 0:"select");Me?De&&le.css({fill:Oe.fill}):le[re](Oe)}le&&le.addClass(J.getClassName(),!0)}else le&&(J.graphic=le.destroy())}markerAttribs(P,ee){let J=this.options,le=J.marker,re=P.marker||{},ge=re.symbol||le.symbol,ve={},we,Ce,Me=K(re.radius,le&&le.radius);ee&&(we=le.states[ee],Me=K((Ce=re.states&&re.states[ee])&&Ce.radius,we&&we.radius,Me&&Me+(we&&we.radiusPlus||0))),P.hasImage=ge&&ge.indexOf("url")===0,P.hasImage&&(Me=0);let De=P.pos();return me(Me)&&De&&(J.crisp&&(De[0]=se(De[0],P.hasImage?0:ge==="rect"?(le==null?void 0:le.lineWidth)||0:1)),ve.x=De[0]-Me,ve.y=De[1]-Me),Me&&(ve.width=ve.height=2*Me),ve}pointAttribs(P,ee){let J=this.options.marker,le=P&&P.options,re=le&&le.marker||{},ge=le&&le.color,ve=P&&P.color,we=P&&P.zone&&P.zone.color,Ce,Me,De=this.color,be,ye,xe=K(re.lineWidth,J.lineWidth),pe=1;return De=ge||we||ve||De,be=re.fillColor||J.fillColor||De,ye=re.lineColor||J.lineColor||De,ee=ee||"normal",Ce=J.states[ee]||{},xe=K((Me=re.states&&re.states[ee]||{}).lineWidth,Ce.lineWidth,xe+K(Me.lineWidthPlus,Ce.lineWidthPlus,0)),be=Me.fillColor||Ce.fillColor||be,{stroke:ye=Me.lineColor||Ce.lineColor||ye,"stroke-width":xe,fill:be,opacity:pe=K(Me.opacity,Ce.opacity,pe)}}destroy(P){let ee,J,le,re=this,ge=re.chart,ve=/AppleWebKit\/533/.test(B.navigator.userAgent),we=re.data||[];for(V(re,"destroy",{keepEventsForUpdate:P}),this.removeEvents(P),(re.axisTypes||[]).forEach(function(Ce){(le=re[Ce])&&le.series&&(F(le.series,re),le.isDirty=le.forceRedraw=!0)}),re.legendItem&&re.chart.legend.destroyItem(re),ee=we.length;ee--;)(J=we[ee])&&J.destroy&&J.destroy();for(let Ce of re.zones)H(Ce,void 0,!0);k.clearTimeout(re.animationTimeout),j(re,function(Ce,Me){Ce instanceof T&&!Ce.survive&&Ce[ve&&Me==="group"?"hide":"destroy"]()}),ge.hoverSeries===re&&(ge.hoverSeries=void 0),F(ge.series,re),ge.orderItems("series"),j(re,function(Ce,Me){P&&Me==="hcEvents"||delete re[Me]})}applyZones(){let{area:P,chart:ee,graph:J,zones:le,points:re,xAxis:ge,yAxis:ve,zoneAxis:we}=this,{inverted:Ce,renderer:Me}=ee,De=this[`${we}Axis`],{isXAxis:be,len:ye=0}=De||{},xe=((J==null?void 0:J.strokeWidth())||0)/2+1,pe=(Se,Ae=0,Te=0)=>{Ce&&(Te=ye-Te);let{translated:Oe=0,lineClip:ze}=Se,Ge=Te-Oe;ze==null||ze.push(["L",Ae,Math.abs(Ge)<xe?Te-xe*(Ge<=0?-1:1):Oe])};if(le.length&&(J||P)&&De&&me(De.min)){let Se=De.getExtremes().max,Ae=ze=>{ze.forEach((Ge,Ve)=>{(Ge[0]==="M"||Ge[0]==="L")&&(ze[Ve]=[Ge[0],be?ye-Ge[1]:Ge[1],be?Ge[2]:ye-Ge[2]])})};if(le.forEach(ze=>{ze.lineClip=[],ze.translated=Z(De.toPixels(K(ze.value,Se),!0)||0,0,ye)}),J&&!this.showLine&&J.hide(),P&&P.hide(),we==="y"&&re.length<ge.len)for(let ze of re){let{plotX:Ge,plotY:Ve,zone:qe}=ze,ot=qe&&le[le.indexOf(qe)-1];qe&&pe(qe,Ge,Ve),ot&&pe(ot,Ge,Ve)}let Te=[],Oe=De.toPixels(De.getExtremes().min,!0);le.forEach(ze=>{var Tt,at;let Ge=ze.lineClip||[],Ve=Math.round(ze.translated||0);ge.reversed&&Ge.reverse();let{clip:qe,simpleClip:ot}=ze,ft=0,dt=0,et=ge.len,Pt=ve.len;be?(ft=Ve,et=Oe):(dt=Ve,Pt=Oe);let Ie=[["M",ft,dt],["L",et,dt],["L",et,Pt],["L",ft,Pt],["Z"]],gt=[Ie[0],...Ge,Ie[1],Ie[2],...Te,Ie[3],Ie[4]];Te=Ge.reverse(),Oe=Ve,Ce&&(Ae(gt),P&&Ae(Ie)),qe?(qe.animate({d:gt}),ot==null||ot.animate({d:Ie})):(qe=ze.clip=Me.path(gt),P&&(ot=ze.simpleClip=Me.path(Ie))),J&&((Tt=ze.graph)==null||Tt.clip(qe)),P&&((at=ze.area)==null||at.clip(ot))})}else this.visible&&(J&&J.show(),P&&P.show())}plotGroup(P,ee,J,le,re){let ge=this[P],ve=!ge,we={visibility:J,zIndex:le||.1};return I(this.opacity)&&!this.chart.styledMode&&this.state!=="inactive"&&(we.opacity=this.opacity),ge||(this[P]=ge=this.chart.renderer.g().add(re)),ge.addClass("highcharts-"+ee+" highcharts-series-"+this.index+" highcharts-"+this.type+"-series "+(I(this.colorIndex)?"highcharts-color-"+this.colorIndex+" ":"")+(this.options.className||"")+(ge.hasClass("highcharts-tracker")?" highcharts-tracker":""),!0),ge.attr(we)[ve?"attr":"animate"](this.getPlotBox(ee)),ge}getPlotBox(P){let ee=this.xAxis,J=this.yAxis,le=this.chart,re=le.inverted&&!le.polar&&ee&&this.invertible&&P==="series";return le.inverted&&(ee=J,J=this.xAxis),{translateX:ee?ee.left:le.plotLeft,translateY:J?J.top:le.plotTop,rotation:re?90:0,rotationOriginX:re?(ee.len-J.len)/2:0,rotationOriginY:re?(ee.len+J.len)/2:0,scaleX:re?-1:1,scaleY:1}}removeEvents(P){let{eventsToUnbind:ee}=this;P||te(this),ee.length&&(ee.forEach(J=>{J()}),ee.length=0)}render(){var Me,De,be,ye,xe;let P=this,{chart:ee,options:J,hasRendered:le}=P,re=C(J.animation),ge=P.visible?"inherit":"hidden",ve=J.zIndex,we=ee.seriesGroup,Ce=P.finishedAnimating?0:re.duration;V(this,"render"),P.plotGroup("group","series",ge,ve,we),P.markerGroup=P.plotGroup("markerGroup","markers",ge,ve,we),J.clip!==!1&&P.setClip(),Ce&&((Me=P.animate)==null||Me.call(P,!0)),P.drawGraph&&(P.drawGraph(),P.applyZones()),P.visible&&P.drawPoints(),(De=P.drawDataLabels)==null||De.call(P),(be=P.redrawPoints)==null||be.call(P),J.enableMouseTracking&&((ye=P.drawTracker)==null||ye.call(P)),Ce&&((xe=P.animate)==null||xe.call(P)),le||(Ce&&re.defer&&(Ce+=re.defer),P.animationTimeout=z(()=>{P.afterAnimate()},Ce||0)),P.isDirty=!1,P.hasRendered=!0,V(P,"afterRender")}redraw(){let P=this.isDirty||this.isDirtyData;this.translate(),this.render(),P&&delete this.kdTree}reserveSpace(){return this.visible||!this.chart.options.chart.ignoreHiddenSeries}searchPoint(P,ee){let{xAxis:J,yAxis:le}=this,re=this.chart.inverted;return this.searchKDTree({clientX:re?J.len-P.chartY+J.pos:P.chartX-J.pos,plotY:re?le.len-P.chartX+le.pos:P.chartY-le.pos},ee,P)}buildKDTree(P){this.buildingKdTree=!0;let ee=this,J=ee.options.findNearestPointBy.indexOf("y")>-1?2:1;delete ee.kdTree,z(function(){ee.kdTree=function le(re,ge,ve){let we,Ce,Me=re==null?void 0:re.length;if(Me)return we=ee.kdAxisArray[ge%ve],re.sort((De,be)=>(De[we]||0)-(be[we]||0)),{point:re[Ce=Math.floor(Me/2)],left:le(re.slice(0,Ce),ge+1,ve),right:le(re.slice(Ce+1),ge+1,ve)}}(ee.getValidPoints(void 0,!ee.directTouch),J,J),ee.buildingKdTree=!1},ee.options.kdNow||(P==null?void 0:P.type)==="touchstart"?0:1)}searchKDTree(P,ee,J){let le=this,[re,ge]=this.kdAxisArray,ve=ee?"distX":"dist",we=(le.options.findNearestPointBy||"").indexOf("y")>-1?2:1,Ce=!!le.isBubble;if(this.kdTree||this.buildingKdTree||this.buildKDTree(J),this.kdTree)return function Me(De,be,ye,xe){var qe;let pe=be.point,Se=le.kdAxisArray[ye%xe],Ae,Te,Oe=pe;(function(ot,ft){var Pe;let dt=ot[re],et=ft[re],Pt=I(dt)&&I(et)?dt-et:null,Ie=ot[ge],gt=ft[ge],Tt=I(Ie)&&I(gt)?Ie-gt:0,at=Ce&&((Pe=ft.marker)==null?void 0:Pe.radius)||0;ft.dist=Math.sqrt((Pt&&Pt*Pt||0)+Tt*Tt)-at,ft.distX=I(Pt)?Math.abs(Pt)-at:Number.MAX_VALUE})(De,pe);let ze=(De[Se]||0)-(pe[Se]||0)+(Ce&&((qe=pe.marker)==null?void 0:qe.radius)||0),Ge=ze<0?"left":"right",Ve=ze<0?"right":"left";return be[Ge]&&(Oe=(Ae=Me(De,be[Ge],ye+1,xe))[ve]<Oe[ve]?Ae:pe),be[Ve]&&Math.sqrt(ze*ze)<Oe[ve]&&(Oe=(Te=Me(De,be[Ve],ye+1,xe))[ve]<Oe[ve]?Te:Oe),Oe}(P,this.kdTree,we,we)}pointPlacementToXValue(){let{options:P,xAxis:ee}=this,J=P.pointPlacement;return J==="between"&&(J=ee.reversed?-.5:.5),me(J)?J*(P.pointRange||ee.pointRange):0}isPointInside(P){let{chart:ee,xAxis:J,yAxis:le}=this,{plotX:re=-1,plotY:ge=-1}=P;return ge>=0&&ge<=(le?le.len:ee.plotHeight)&&re>=0&&re<=(J?J.len:ee.plotWidth)}drawTracker(){var be;let P=this,ee=P.options,J=ee.trackByArea,le=[].concat((J?P.areaPath:P.graphPath)||[]),re=P.chart,ge=re.pointer,ve=re.renderer,we=((be=re.options.tooltip)==null?void 0:be.snap)||0,Ce=()=>{ee.enableMouseTracking&&re.hoverSeries!==P&&P.onMouseOver()},Me="rgba(192,192,192,"+(L?1e-4:.002)+")",De=P.tracker;De?De.attr({d:le}):P.graph&&(P.tracker=De=ve.path(le).attr({visibility:P.visible?"inherit":"hidden",zIndex:2}).addClass(J?"highcharts-tracker-area":"highcharts-tracker-line").add(P.group),re.styledMode||De.attr({"stroke-linecap":"round","stroke-linejoin":"round",stroke:Me,fill:J?Me:"none","stroke-width":P.graph.strokeWidth()+(J?0:2*we)}),[P.tracker,P.markerGroup,P.dataLabelsGroup].forEach(ye=>{ye&&(ye.addClass("highcharts-tracker").on("mouseover",Ce).on("mouseout",xe=>{ge==null||ge.onTrackerMouseOut(xe)}),ee.cursor&&!re.styledMode&&ye.css({cursor:ee.cursor}),ye.on("touchstart",Ce))})),V(this,"afterDrawTracker")}addPoint(P,ee,J,le,re){let ge,ve,we=this.options,Ce=this.data,Me=this.chart,De=this.xAxis,be=De&&De.hasNames&&De.names,ye=we.data,xe=this.xData;ee=K(ee,!0);let pe={series:this};this.pointClass.prototype.applyOptions.apply(pe,[P]);let Se=pe.x;if(ve=xe.length,this.requireSorting&&Se<xe[ve-1])for(ge=!0;ve&&xe[ve-1]>Se;)ve--;this.updateParallelArrays(pe,"splice",[ve,0,0]),this.updateParallelArrays(pe,ve),be&&pe.name&&(be[Se]=pe.name),ye.splice(ve,0,P),(ge||this.processedData)&&(this.data.splice(ve,0,null),this.processData()),we.legendType==="point"&&this.generatePoints(),J&&(Ce[0]&&Ce[0].remove?Ce[0].remove(!1):(Ce.shift(),this.updateParallelArrays(pe,"shift"),ye.shift())),re!==!1&&V(this,"addPoint",{point:pe}),this.isDirty=!0,this.isDirtyData=!0,ee&&Me.redraw(le)}removePoint(P,ee,J){let le=this,re=le.data,ge=re[P],ve=le.points,we=le.chart,Ce=function(){ve&&ve.length===re.length&&ve.splice(P,1),re.splice(P,1),le.options.data.splice(P,1),le.updateParallelArrays(ge||{series:le},"splice",[P,1]),ge&&ge.destroy(),le.isDirty=!0,le.isDirtyData=!0,ee&&we.redraw()};G(J,we),ee=K(ee,!0),ge?ge.firePointEvent("remove",null,Ce):Ce()}remove(P,ee,J,le){let re=this,ge=re.chart;function ve(){re.destroy(le),ge.isDirtyLegend=ge.isDirtyBox=!0,ge.linkSeries(le),K(P,!0)&&ge.redraw(ee)}J!==!1?V(re,"remove",null,ve):ve()}update(P,ee){var Ae,Te,Oe;V(this,"update",{options:P=Q(P,this.userOptions)});let J=this,le=J.chart,re=J.userOptions,ge=J.initialType||J.type,ve=le.options.plotOptions,we=Y[ge].prototype,Ce=J.finishedAnimating&&{animation:!1},Me={},De,be,ye=["colorIndex","eventOptions","navigatorSeries","symbolIndex","baseSeries"],xe=P.type||re.type||le.options.chart.type,pe=!(this.hasDerivedData||xe&&xe!==this.type||P.pointStart!==void 0||P.pointInterval!==void 0||P.relativeXValue!==void 0||P.joinBy||P.mapData||["dataGrouping","pointStart","pointInterval","pointIntervalUnit","keys"].some(ze=>J.hasOptionChanged(ze)));xe=xe||ge,pe&&(ye.push("data","isDirtyData","isDirtyCanvas","points","processedData","processedXData","processedYData","xIncrement","cropped","_hasPointMarkers","hasDataLabels","nodes","layout","level","mapMap","mapData","minY","maxY","minX","maxX","transformGroups"),P.visible!==!1&&ye.push("area","graph"),J.parallelArrays.forEach(function(ze){ye.push(ze+"Data")}),P.data&&(P.dataSorting&&M(J.options.dataSorting,P.dataSorting),this.setData(P.data,!1))),P=D(re,{index:re.index===void 0?J.index:re.index,pointStart:((Ae=ve==null?void 0:ve.series)==null?void 0:Ae.pointStart)??re.pointStart??((Te=J.xData)==null?void 0:Te[0])},!pe&&{data:J.options.data},P,Ce),pe&&P.data&&(P.data=J.options.data),(ye=["group","markerGroup","dataLabelsGroup","transformGroup"].concat(ye)).forEach(function(ze){ye[ze]=J[ze],delete J[ze]});let Se=!1;if(Y[xe]){if(Se=xe!==J.type,J.remove(!1,!1,!1,!0),Se)if(le.propFromSeries(),Object.setPrototypeOf)Object.setPrototypeOf(J,Y[xe].prototype);else{let ze=Object.hasOwnProperty.call(J,"hcEvents")&&J.hcEvents;for(be in we)J[be]=void 0;M(J,Y[xe].prototype),ze?J.hcEvents=ze:delete J.hcEvents}}else E(17,!0,le,{missingModuleFor:xe});if(ye.forEach(function(ze){J[ze]=ye[ze]}),J.init(le,P),pe&&this.points)for(let ze of((De=J.options).visible===!1?(Me.graphic=1,Me.dataLabel=1):(this.hasMarkerChanged(De,re)&&(Me.graphic=1),(Oe=J.hasDataLabels)!=null&&Oe.call(J)||(Me.dataLabel=1)),this.points))ze&&ze.series&&(ze.resolveColor(),Object.keys(Me).length&&ze.destroyElements(Me),De.showInLegend===!1&&ze.legendItem&&le.legend.destroyItem(ze));J.initialType=ge,le.linkSeries(),le.setSortedData(),Se&&J.linkedSeries.length&&(J.isDirtyData=!0),V(this,"afterUpdate"),K(ee,!0)&&le.redraw(!!pe&&void 0)}setName(P){this.name=this.options.name=this.userOptions.name=P,this.chart.isDirtyLegend=!0}hasOptionChanged(P){var ve,we;let ee=this.chart,J=this.options[P],le=ee.options.plotOptions,re=this.userOptions[P],ge=K((ve=le==null?void 0:le[this.type])==null?void 0:ve[P],(we=le==null?void 0:le.series)==null?void 0:we[P]);return re&&!I(ge)?J!==re:J!==K(ge,J)}onMouseOver(){let P=this.chart,ee=P.hoverSeries,J=P.pointer;J==null||J.setHoverChartIndex(),ee&&ee!==this&&ee.onMouseOut(),this.options.events.mouseOver&&V(this,"mouseOver"),this.setState("hover"),P.hoverSeries=this}onMouseOut(){let P=this.options,ee=this.chart,J=ee.tooltip,le=ee.hoverPoint;ee.hoverSeries=null,le&&le.onMouseOut(),this&&P.events.mouseOut&&V(this,"mouseOut"),J&&!this.stickyTracking&&(!J.shared||this.noSharedTooltip)&&J.hide(),ee.series.forEach(function(re){re.setState("",!0)})}setState(P,ee){let J=this,le=J.options,re=J.graph,ge=le.inactiveOtherPoints,ve=le.states,we=K(ve[P||"normal"]&&ve[P||"normal"].animation,J.chart.options.chart.animation),Ce=le.lineWidth,Me=le.opacity;if(P=P||"",J.state!==P&&([J.group,J.markerGroup,J.dataLabelsGroup].forEach(function(De){De&&(J.state&&De.removeClass("highcharts-series-"+J.state),P&&De.addClass("highcharts-series-"+P))}),J.state=P,!J.chart.styledMode)){if(ve[P]&&ve[P].enabled===!1)return;if(P&&(Ce=ve[P].lineWidth||Ce+(ve[P].lineWidthPlus||0),Me=K(ve[P].opacity,Me)),re&&!re.dashstyle&&me(Ce))for(let De of[re,...this.zones.map(be=>be.graph)])De==null||De.animate({"stroke-width":Ce},we);ge||[J.group,J.markerGroup,J.dataLabelsGroup,J.labelBySeries].forEach(function(De){De&&De.animate({opacity:Me},we)})}ee&&ge&&J.points&&J.setAllPointsToState(P||void 0)}setAllPointsToState(P){this.points.forEach(function(ee){ee.setState&&ee.setState(P)})}setVisible(P,ee){var we;let J=this,le=J.chart,re=le.options.chart.ignoreHiddenSeries,ge=J.visible;J.visible=P=J.options.visible=J.userOptions.visible=P===void 0?!ge:P;let ve=P?"show":"hide";["group","dataLabelsGroup","markerGroup","tracker","tt"].forEach(Ce=>{var Me;(Me=J[Ce])==null||Me[ve]()}),(le.hoverSeries===J||((we=le.hoverPoint)==null?void 0:we.series)===J)&&J.onMouseOut(),J.legendItem&&le.legend.colorizeItem(J,P),J.isDirty=!0,J.options.stacking&&le.series.forEach(Ce=>{Ce.options.stacking&&Ce.visible&&(Ce.isDirty=!0)}),J.linkedSeries.forEach(Ce=>{Ce.setVisible(P,!1)}),re&&(le.isDirtyBox=!0),V(J,ve),ee!==!1&&le.redraw()}show(){this.setVisible(!0)}hide(){this.setVisible(!1)}select(P){this.selected=P=this.options.selected=P===void 0?!this.selected:P,this.checkbox&&(this.checkbox.checked=P),V(this,P?"select":"unselect")}shouldShowTooltip(P,ee,J={}){return J.series=this,J.visiblePlotOnly=!0,this.chart.isInsidePlot(P,ee,J)}drawLegendSymbol(P,ee){var J;(J=m[this.options.legendSymbol||"rectangle"])==null||J.call(this,P,ee)}}return W.defaultOptions=x,W.types=_.seriesTypes,W.registerType=_.registerSeriesType,M(W.prototype,{axisTypes:["xAxis","yAxis"],coll:"series",colorCounter:0,directTouch:!1,invertible:!0,isCartesian:!0,kdAxisArray:["clientX","plotY"],parallelArrays:["x","y"],pointClass:v,requireSorting:!0,sorted:!0}),_.series=W,W}),r(a,"Core/Legend/Legend.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Foundation.js"],a["Core/Globals.js"],a["Core/Series/Series.js"],a["Core/Series/Point.js"],a["Core/Renderer/RendererUtilities.js"],a["Core/Templating.js"],a["Core/Utilities.js"]],function(c,u,h,p,m,v,x,_){var T;let{animObject:k,setAnimation:C}=c,{registerEventOptions:G}=u,{composed:ne,marginNames:$}=h,{distribute:L}=v,{format:B}=x,{addEvent:Y,createElement:X,css:U,defined:Z,discardElement:ce,find:se,fireEvent:I,isNumber:H,merge:Q,pick:F,pushUnique:E,relativeLength:M,stableSort:R,syncTimeout:V}=_;class ae{constructor(A,ue){this.allItems=[],this.initialItemY=0,this.itemHeight=0,this.itemMarginBottom=0,this.itemMarginTop=0,this.itemX=0,this.itemY=0,this.lastItemY=0,this.lastLineHeight=0,this.legendHeight=0,this.legendWidth=0,this.maxItemWidth=0,this.maxLegendWidth=0,this.offsetWidth=0,this.padding=0,this.pages=[],this.symbolHeight=0,this.symbolWidth=0,this.titleHeight=0,this.totalItemWidth=0,this.widthOption=0,this.chart=A,this.setOptions(ue),ue.enabled&&(this.render(),G(this,ue),Y(this.chart,"endResize",function(){this.legend.positionCheckboxes()})),Y(this.chart,"render",()=>{this.options.enabled&&this.proximate&&(this.proximatePositions(),this.positionItems())})}setOptions(A){let ue=F(A.padding,8);this.options=A,this.chart.styledMode||(this.itemStyle=A.itemStyle,this.itemHiddenStyle=Q(this.itemStyle,A.itemHiddenStyle)),this.itemMarginTop=A.itemMarginTop,this.itemMarginBottom=A.itemMarginBottom,this.padding=ue,this.initialItemY=ue-5,this.symbolWidth=F(A.symbolWidth,16),this.pages=[],this.proximate=A.layout==="proximate"&&!this.chart.inverted,this.baseline=void 0}update(A,ue){let me=this.chart;this.setOptions(Q(!0,this.options,A)),"events"in this.options&&G(this,this.options),this.destroy(),me.isDirtyLegend=me.isDirtyBox=!0,F(ue,!0)&&me.redraw(),I(this,"afterUpdate",{redraw:ue})}colorizeItem(A,ue){let{area:me,group:g,label:D,line:j,symbol:K}=A.legendItem||{};if(g==null||g[ue?"removeClass":"addClass"]("highcharts-legend-item-hidden"),!this.chart.styledMode){let{itemHiddenStyle:te={}}=this,O=te.color,{fillColor:z,fillOpacity:W,lineColor:de,marker:P}=A.options,ee=J=>(!ue&&(J.fill&&(J.fill=O),J.stroke&&(J.stroke=O)),J);D==null||D.css(Q(ue?this.itemStyle:te)),j==null||j.attr(ee({stroke:de||A.color})),K&&K.attr(ee(P&&K.isMarker?A.pointAttribs():{fill:A.color})),me==null||me.attr(ee({fill:z||A.color,"fill-opacity":z?1:W??.75}))}I(this,"afterColorizeItem",{item:A,visible:ue})}positionItems(){this.allItems.forEach(this.positionItem,this),this.chart.isResizing||this.positionCheckboxes()}positionItem(A){let{group:ue,x:me=0,y:g=0}=A.legendItem||{},D=this.options,j=D.symbolPadding,K=!D.rtl,te=A.checkbox;if(ue&&ue.element){let O={translateX:K?me:this.legendWidth-me-2*j-4,translateY:g};ue[Z(ue.translateY)?"animate":"attr"](O,void 0,()=>{I(this,"afterPositionItem",{item:A})})}te&&(te.x=me,te.y=g)}destroyItem(A){let ue=A.checkbox,me=A.legendItem||{};for(let g of["group","label","line","symbol"])me[g]&&(me[g]=me[g].destroy());ue&&ce(ue),A.legendItem=void 0}destroy(){for(let A of this.getAllItems())this.destroyItem(A);for(let A of["clipRect","up","down","pager","nav","box","title","group"])this[A]&&(this[A]=this[A].destroy());this.display=null}positionCheckboxes(){let A,ue=this.group&&this.group.alignAttr,me=this.clipHeight||this.legendHeight,g=this.titleHeight;ue&&(A=ue.translateY,this.allItems.forEach(function(D){let j,K=D.checkbox;K&&(j=A+g+K.y+(this.scrollOffset||0)+3,U(K,{left:ue.translateX+D.checkboxOffset+K.x-20+"px",top:j+"px",display:this.proximate||j>A-6&&j<A+me-6?"":"none"}))},this))}renderTitle(){let A=this.options,ue=this.padding,me=A.title,g,D=0;me.text&&(this.title||(this.title=this.chart.renderer.label(me.text,ue-3,ue-4,void 0,void 0,void 0,A.useHTML,void 0,"legend-title").attr({zIndex:1}),this.chart.styledMode||this.title.css(me.style),this.title.add(this.group)),me.width||this.title.css({width:this.maxLegendWidth+"px"}),D=(g=this.title.getBBox()).height,this.offsetWidth=g.width,this.contentGroup.attr({translateY:D})),this.titleHeight=D}setText(A){let ue=this.options;A.legendItem.label.attr({text:ue.labelFormat?B(ue.labelFormat,A,this.chart):ue.labelFormatter.call(A)})}renderItem(A){let ue=A.legendItem=A.legendItem||{},me=this.chart,g=me.renderer,D=this.options,j=D.layout==="horizontal",K=this.symbolWidth,te=D.symbolPadding||0,O=this.itemStyle,z=this.itemHiddenStyle,W=j?F(D.itemDistance,20):0,de=!D.rtl,P=!A.series,ee=!P&&A.series.drawLegendSymbol?A.series:A,J=ee.options,le=!!this.createCheckboxForItem&&J&&J.showCheckbox,re=D.useHTML,ge=A.options.className,ve=ue.label,we=K+te+W+(le?20:0);!ve&&(ue.group=g.g("legend-item").addClass("highcharts-"+ee.type+"-series highcharts-color-"+A.colorIndex+(ge?" "+ge:"")+(P?" highcharts-series-"+A.index:"")).attr({zIndex:1}).add(this.scrollGroup),ue.label=ve=g.text("",de?K+te:-te,this.baseline||0,re),me.styledMode||ve.css(Q(A.visible?O:z)),ve.attr({align:de?"left":"right",zIndex:2}).add(ue.group),!this.baseline&&(this.fontMetrics=g.fontMetrics(ve),this.baseline=this.fontMetrics.f+3+this.itemMarginTop,ve.attr("y",this.baseline),this.symbolHeight=F(D.symbolHeight,this.fontMetrics.f),D.squareSymbol&&(this.symbolWidth=F(D.symbolWidth,Math.max(this.symbolHeight,16)),we=this.symbolWidth+te+W+(le?20:0),de&&ve.attr("x",this.symbolWidth+te))),ee.drawLegendSymbol(this,A),this.setItemEvents&&this.setItemEvents(A,ve,re)),le&&!A.checkbox&&this.createCheckboxForItem&&this.createCheckboxForItem(A),this.colorizeItem(A,A.visible),(me.styledMode||!O.width)&&ve.css({width:(D.itemWidth||this.widthOption||me.spacingBox.width)-we+"px"}),this.setText(A);let Ce=ve.getBBox(),Me=this.fontMetrics&&this.fontMetrics.h||0;A.itemWidth=A.checkboxOffset=D.itemWidth||ue.labelWidth||Ce.width+we,this.maxItemWidth=Math.max(this.maxItemWidth,A.itemWidth),this.totalItemWidth+=A.itemWidth,this.itemHeight=A.itemHeight=Math.round(ue.labelHeight||(Ce.height>1.5*Me?Ce.height:Me))}layoutItem(A){let ue=this.options,me=this.padding,g=ue.layout==="horizontal",D=A.itemHeight,j=this.itemMarginBottom,K=this.itemMarginTop,te=g?F(ue.itemDistance,20):0,O=this.maxLegendWidth,z=ue.alignColumns&&this.totalItemWidth>O?this.maxItemWidth:A.itemWidth,W=A.legendItem||{};g&&this.itemX-me+z>O&&(this.itemX=me,this.lastLineHeight&&(this.itemY+=K+this.lastLineHeight+j),this.lastLineHeight=0),this.lastItemY=K+this.itemY+j,this.lastLineHeight=Math.max(D,this.lastLineHeight),W.x=this.itemX,W.y=this.itemY,g?this.itemX+=z:(this.itemY+=K+D+j,this.lastLineHeight=D),this.offsetWidth=this.widthOption||Math.max((g?this.itemX-me-(A.checkbox?0:te):z)+me,this.offsetWidth)}getAllItems(){let A=[];return this.chart.series.forEach(function(ue){let me=ue&&ue.options;ue&&F(me.showInLegend,!Z(me.linkedTo)&&void 0,!0)&&(A=A.concat((ue.legendItem||{}).labels||(me.legendType==="point"?ue.data:ue)))}),I(this,"afterGetAllItems",{allItems:A}),A}getAlignment(){let A=this.options;return this.proximate?A.align.charAt(0)+"tv":A.floating?"":A.align.charAt(0)+A.verticalAlign.charAt(0)+A.layout.charAt(0)}adjustMargins(A,ue){let me=this.chart,g=this.options,D=this.getAlignment();D&&[/(lth|ct|rth)/,/(rtv|rm|rbv)/,/(rbh|cb|lbh)/,/(lbv|lm|ltv)/].forEach(function(j,K){j.test(D)&&!Z(A[K])&&(me[$[K]]=Math.max(me[$[K]],me.legend[(K+1)%2?"legendHeight":"legendWidth"]+[1,-1,-1,1][K]*g[K%2?"x":"y"]+F(g.margin,12)+ue[K]+(me.titleOffset[K]||0)))})}proximatePositions(){let A,ue=this.chart,me=[],g=this.options.align==="left";for(let D of(this.allItems.forEach(function(j){let K,te,O=g,z,W;j.yAxis&&(j.xAxis.options.reversed&&(O=!O),j.points&&(K=se(O?j.points:j.points.slice(0).reverse(),function(de){return H(de.plotY)})),te=this.itemMarginTop+j.legendItem.label.getBBox().height+this.itemMarginBottom,W=j.yAxis.top-ue.plotTop,z=j.visible?(K?K.plotY:j.yAxis.height)+(W-.3*te):W+j.yAxis.height,me.push({target:z,size:te,item:j}))},this),L(me,ue.plotHeight)))A=D.item.legendItem||{},H(D.pos)&&(A.y=ue.plotTop-ue.spacing[0]+D.pos)}render(){let A=this.chart,ue=A.renderer,me=this.options,g=this.padding,D=this.getAllItems(),j,K,te,O=this.group,z,W=this.box;this.itemX=g,this.itemY=this.initialItemY,this.offsetWidth=0,this.lastItemY=0,this.widthOption=M(me.width,A.spacingBox.width-g),z=A.spacingBox.width-2*g-me.x,["rm","lm"].indexOf(this.getAlignment().substring(0,2))>-1&&(z/=2),this.maxLegendWidth=this.widthOption||z,O||(this.group=O=ue.g("legend").addClass(me.className||"").attr({zIndex:7}).add(),this.contentGroup=ue.g().attr({zIndex:1}).add(O),this.scrollGroup=ue.g().add(this.contentGroup)),this.renderTitle(),R(D,(de,P)=>(de.options&&de.options.legendIndex||0)-(P.options&&P.options.legendIndex||0)),me.reversed&&D.reverse(),this.allItems=D,this.display=j=!!D.length,this.lastLineHeight=0,this.maxItemWidth=0,this.totalItemWidth=0,this.itemHeight=0,D.forEach(this.renderItem,this),D.forEach(this.layoutItem,this),K=(this.widthOption||this.offsetWidth)+g,te=this.lastItemY+this.lastLineHeight+this.titleHeight,te=this.handleOverflow(te)+g,W||(this.box=W=ue.rect().addClass("highcharts-legend-box").attr({r:me.borderRadius}).add(O)),A.styledMode||W.attr({stroke:me.borderColor,"stroke-width":me.borderWidth||0,fill:me.backgroundColor||"none"}).shadow(me.shadow),K>0&&te>0&&W[W.placed?"animate":"attr"](W.crisp.call({},{x:0,y:0,width:K,height:te},W.strokeWidth())),O[j?"show":"hide"](),A.styledMode&&O.getStyle("display")==="none"&&(K=te=0),this.legendWidth=K,this.legendHeight=te,j&&this.align(),this.proximate||this.positionItems(),I(this,"afterRender")}align(A=this.chart.spacingBox){let ue=this.chart,me=this.options,g=A.y;/(lth|ct|rth)/.test(this.getAlignment())&&ue.titleOffset[0]>0?g+=ue.titleOffset[0]:/(lbh|cb|rbh)/.test(this.getAlignment())&&ue.titleOffset[2]>0&&(g-=ue.titleOffset[2]),g!==A.y&&(A=Q(A,{y:g})),ue.hasRendered||(this.group.placed=!1),this.group.align(Q(me,{width:this.legendWidth,height:this.legendHeight,verticalAlign:this.proximate?"top":me.verticalAlign}),!0,A)}handleOverflow(A){let ue=this,me=this.chart,g=me.renderer,D=this.options,j=D.y,K=D.verticalAlign==="top",te=this.padding,O=D.maxHeight,z=D.navigation,W=F(z.animation,!0),de=z.arrowSize||12,P=this.pages,ee=this.allItems,J=function(De){typeof De=="number"?Me.attr({height:De}):Me&&(ue.clipRect=Me.destroy(),ue.contentGroup.clip()),ue.contentGroup.div&&(ue.contentGroup.div.style.clip=De?"rect("+te+"px,9999px,"+(te+De)+"px,0)":"auto")},le=function(De){return ue[De]=g.circle(0,0,1.3*de).translate(de/2,de/2).add(Ce),me.styledMode||ue[De].attr("fill","rgba(0,0,0,0.0001)"),ue[De]},re,ge,ve,we=me.spacingBox.height+(K?-j:j)-te,Ce=this.nav,Me=this.clipRect;return D.layout!=="horizontal"||D.verticalAlign==="middle"||D.floating||(we/=2),O&&(we=Math.min(we,O)),P.length=0,A&&we>0&&A>we&&z.enabled!==!1?(this.clipHeight=re=Math.max(we-20-this.titleHeight-te,0),this.currentPage=F(this.currentPage,1),this.fullHeight=A,ee.forEach((De,be)=>{let ye=(ve=De.legendItem||{}).y||0,xe=Math.round(ve.label.getBBox().height),pe=P.length;(!pe||ye-P[pe-1]>re&&(ge||ye)!==P[pe-1])&&(P.push(ge||ye),pe++),ve.pageIx=pe-1,ge&&((ee[be-1].legendItem||{}).pageIx=pe-1),be===ee.length-1&&ye+xe-P[pe-1]>re&&ye>P[pe-1]&&(P.push(ye),ve.pageIx=pe),ye!==ge&&(ge=ye)}),Me||(Me=ue.clipRect=g.clipRect(0,te-2,9999,0),ue.contentGroup.clip(Me)),J(re),Ce||(this.nav=Ce=g.g().attr({zIndex:1}).add(this.group),this.up=g.symbol("triangle",0,0,de,de).add(Ce),le("upTracker").on("click",function(){ue.scroll(-1,W)}),this.pager=g.text("",15,10).addClass("highcharts-legend-navigation"),!me.styledMode&&z.style&&this.pager.css(z.style),this.pager.add(Ce),this.down=g.symbol("triangle-down",0,0,de,de).add(Ce),le("downTracker").on("click",function(){ue.scroll(1,W)})),ue.scroll(0),A=we):Ce&&(J(),this.nav=Ce.destroy(),this.scrollGroup.attr({translateY:1}),this.clipHeight=0),A}scroll(A,ue){let me=this.chart,g=this.pages,D=g.length,j=this.clipHeight,K=this.options.navigation,te=this.pager,O=this.padding,z=this.currentPage+A;z>D&&(z=D),z>0&&(ue!==void 0&&C(ue,me),this.nav.attr({translateX:O,translateY:j+this.padding+7+this.titleHeight,visibility:"inherit"}),[this.up,this.upTracker].forEach(function(W){W.attr({class:z===1?"highcharts-legend-nav-inactive":"highcharts-legend-nav-active"})}),te.attr({text:z+"/"+D}),[this.down,this.downTracker].forEach(function(W){W.attr({x:18+this.pager.getBBox().width,class:z===D?"highcharts-legend-nav-inactive":"highcharts-legend-nav-active"})},this),me.styledMode||(this.up.attr({fill:z===1?K.inactiveColor:K.activeColor}),this.upTracker.css({cursor:z===1?"default":"pointer"}),this.down.attr({fill:z===D?K.inactiveColor:K.activeColor}),this.downTracker.css({cursor:z===D?"default":"pointer"})),this.scrollOffset=-g[z-1]+this.initialItemY,this.scrollGroup.animate({translateY:this.scrollOffset}),this.currentPage=z,this.positionCheckboxes(),V(()=>{I(this,"afterScroll",{currentPage:z})},k(F(ue,me.renderer.globalAnimation,!0)).duration))}setItemEvents(A,ue,me){let g=this,D=A.legendItem||{},j=g.chart.renderer.boxWrapper,K=A instanceof m,te=A instanceof p,O="highcharts-legend-"+(K?"point":"series")+"-active",z=g.chart.styledMode,W=me?[ue,D.symbol]:[D.group],de=P=>{g.allItems.forEach(ee=>{A!==ee&&[ee].concat(ee.linkedSeries||[]).forEach(J=>{J.setState(P,!K)})})};for(let P of W)P&&P.on("mouseover",function(){A.visible&&de("inactive"),A.setState("hover"),A.visible&&j.addClass(O),z||ue.css(g.options.itemHoverStyle)}).on("mouseout",function(){g.chart.styledMode||ue.css(Q(A.visible?g.itemStyle:g.itemHiddenStyle)),de(""),j.removeClass(O),A.setState()}).on("click",function(ee){let J=function(){A.setVisible&&A.setVisible(),de(A.visible?"inactive":"")};j.removeClass(O),I(g,"itemClick",{browserEvent:ee,legendItem:A},J),K?A.firePointEvent("legendItemClick",{browserEvent:ee}):te&&I(A,"legendItemClick",{browserEvent:ee})})}createCheckboxForItem(A){A.checkbox=X("input",{type:"checkbox",className:"highcharts-legend-checkbox",checked:A.selected,defaultChecked:A.selected},this.options.itemCheckboxStyle,this.chart.container),Y(A.checkbox,"click",function(ue){let me=ue.target;I(A.series||A,"checkboxClick",{checked:me.checked,item:A},function(){A.select()})})}}return(T=ae||(ae={})).compose=function(oe){E(ne,"Core.Legend")&&Y(oe,"beforeMargins",function(){this.legend=new T(this,this.options.legend)})},ae}),r(a,"Core/Chart/Chart.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Axis/Axis.js"],a["Core/Defaults.js"],a["Core/Templating.js"],a["Core/Foundation.js"],a["Core/Globals.js"],a["Core/Renderer/RendererRegistry.js"],a["Core/Series/Series.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Renderer/SVG/SVGRenderer.js"],a["Core/Time.js"],a["Core/Utilities.js"],a["Core/Renderer/HTML/AST.js"],a["Core/Axis/Tick.js"]],function(c,u,h,p,m,v,x,_,T,k,C,G,ne,$){let{animate:L,animObject:B,setAnimation:Y}=c,{defaultOptions:X,defaultTime:U}=h,{numberFormat:Z}=p,{registerEventOptions:ce}=m,{charts:se,doc:I,marginNames:H,svg:Q,win:F}=v,{seriesTypes:E}=T,{addEvent:M,attr:R,createElement:V,css:ae,defined:oe,diffObjects:A,discardElement:ue,erase:me,error:g,extend:D,find:j,fireEvent:K,getStyle:te,isArray:O,isNumber:z,isObject:W,isString:de,merge:P,objectEach:ee,pick:J,pInt:le,relativeLength:re,removeEvent:ge,splat:ve,syncTimeout:we,uniqueKey:Ce}=G;class Me{static chart(be,ye,xe){return new Me(be,ye,xe)}constructor(be,ye,xe){this.sharedClips={};let pe=[...arguments];(de(be)||be.nodeName)&&(this.renderTo=pe.shift()),this.init(pe[0],pe[1])}setZoomOptions(){let be=this.options.chart,ye=be.zooming;this.zooming={...ye,type:J(be.zoomType,ye.type),key:J(be.zoomKey,ye.key),pinchType:J(be.pinchType,ye.pinchType),singleTouch:J(be.zoomBySingleTouch,ye.singleTouch,!1),resetButton:P(ye.resetButton,be.resetZoomButton)}}init(be,ye){K(this,"init",{args:arguments},function(){let xe=P(X,be),pe=xe.chart;this.userOptions=D({},be),this.margin=[],this.spacing=[],this.labelCollectors=[],this.callback=ye,this.isResizing=0,this.options=xe,this.axes=[],this.series=[],this.time=be.time&&Object.keys(be.time).length?new C(be.time):v.time,this.numberFormatter=pe.numberFormatter||Z,this.styledMode=pe.styledMode,this.hasCartesianSeries=pe.showAxes,this.index=se.length,se.push(this),v.chartCount++,ce(this,pe),this.xAxis=[],this.yAxis=[],this.pointCount=this.colorCounter=this.symbolCounter=0,this.setZoomOptions(),K(this,"afterInit"),this.firstRender()})}initSeries(be){let ye=this.options.chart,xe=be.type||ye.type,pe=E[xe];pe||g(17,!0,this,{missingModuleFor:xe});let Se=new pe;return typeof Se.init=="function"&&Se.init(this,be),Se}setSortedData(){this.getSeriesOrderByLinks().forEach(function(be){be.points||be.data||!be.enabledDataSorting||be.setData(be.options.data,!1)})}getSeriesOrderByLinks(){return this.series.concat().sort(function(be,ye){return be.linkedSeries.length||ye.linkedSeries.length?ye.linkedSeries.length-be.linkedSeries.length:0})}orderItems(be,ye=0){let xe=this[be],pe=this.options[be]=ve(this.options[be]).slice(),Se=this.userOptions[be]=this.userOptions[be]?ve(this.userOptions[be]).slice():[];if(this.hasRendered&&(pe.splice(ye),Se.splice(ye)),xe)for(let Ae=ye,Te=xe.length;Ae<Te;++Ae){let Oe=xe[Ae];Oe&&(Oe.index=Ae,Oe instanceof _&&(Oe.name=Oe.getName()),Oe.options.isInternal||(pe[Ae]=Oe.options,Se[Ae]=Oe.userOptions))}}isInsidePlot(be,ye,xe={}){var et;let{inverted:pe,plotBox:Se,plotLeft:Ae,plotTop:Te,scrollablePlotBox:Oe}=this,{scrollLeft:ze=0,scrollTop:Ge=0}=xe.visiblePlotOnly&&((et=this.scrollablePlotArea)==null?void 0:et.scrollingContainer)||{},Ve=xe.series,qe=xe.visiblePlotOnly&&Oe||Se,ot=xe.inverted?ye:be,ft=xe.inverted?be:ye,dt={x:ot,y:ft,isInsidePlot:!0,options:xe};if(!xe.ignoreX){let Pt=Ve&&(pe&&!this.polar?Ve.yAxis:Ve.xAxis)||{pos:Ae,len:1/0},Ie=xe.paneCoordinates?Pt.pos+ot:Ae+ot;Ie>=Math.max(ze+Ae,Pt.pos)&&Ie<=Math.min(ze+Ae+qe.width,Pt.pos+Pt.len)||(dt.isInsidePlot=!1)}if(!xe.ignoreY&&dt.isInsidePlot){let Pt=!pe&&xe.axis&&!xe.axis.isXAxis&&xe.axis||Ve&&(pe?Ve.xAxis:Ve.yAxis)||{pos:Te,len:1/0},Ie=xe.paneCoordinates?Pt.pos+ft:Te+ft;Ie>=Math.max(Ge+Te,Pt.pos)&&Ie<=Math.min(Ge+Te+qe.height,Pt.pos+Pt.len)||(dt.isInsidePlot=!1)}return K(this,"afterIsInsidePlot",dt),dt.isInsidePlot}redraw(be){K(this,"beforeRedraw");let ye=this.hasCartesianSeries?this.axes:this.colorAxis||[],xe=this.series,pe=this.pointer,Se=this.legend,Ae=this.userOptions.legend,Te=this.renderer,Oe=Te.isHidden(),ze=[],Ge,Ve,qe,ot=this.isDirtyBox,ft=this.isDirtyLegend,dt;for(Te.rootFontSize=Te.boxWrapper.getStyle("font-size"),this.setResponsive&&this.setResponsive(!1),Y(!!this.hasRendered&&be,this),Oe&&this.temporaryDisplay(),this.layOutTitles(!1),qe=xe.length;qe--;)if(((dt=xe[qe]).options.stacking||dt.options.centerInCategory)&&(Ve=!0,dt.isDirty)){Ge=!0;break}if(Ge)for(qe=xe.length;qe--;)(dt=xe[qe]).options.stacking&&(dt.isDirty=!0);xe.forEach(function(et){et.isDirty&&(et.options.legendType==="point"?(typeof et.updateTotals=="function"&&et.updateTotals(),ft=!0):Ae&&(Ae.labelFormatter||Ae.labelFormat)&&(ft=!0)),et.isDirtyData&&K(et,"updatedData")}),ft&&Se&&Se.options.enabled&&(Se.render(),this.isDirtyLegend=!1),Ve&&this.getStacks(),ye.forEach(function(et){et.updateNames(),et.setScale()}),this.getMargins(),ye.forEach(function(et){et.isDirty&&(ot=!0)}),ye.forEach(function(et){let Pt=et.min+","+et.max;et.extKey!==Pt&&(et.extKey=Pt,ze.push(function(){K(et,"afterSetExtremes",D(et.eventArgs,et.getExtremes())),delete et.eventArgs})),(ot||Ve)&&et.redraw()}),ot&&this.drawChartBox(),K(this,"predraw"),xe.forEach(function(et){(ot||et.isDirty)&&et.visible&&et.redraw(),et.isDirtyData=!1}),pe&&pe.reset(!0),Te.draw(),K(this,"redraw"),K(this,"render"),Oe&&this.temporaryDisplay(!0),ze.forEach(function(et){et.call()})}get(be){let ye=this.series;function xe(Se){return Se.id===be||Se.options&&Se.options.id===be}let pe=j(this.axes,xe)||j(this.series,xe);for(let Se=0;!pe&&Se<ye.length;Se++)pe=j(ye[Se].points||[],xe);return pe}getAxes(){let be=this.userOptions;for(let ye of(K(this,"getAxes"),["xAxis","yAxis"]))for(let xe of be[ye]=ve(be[ye]||{}))new u(this,xe,ye);K(this,"afterGetAxes")}getSelectedPoints(){return this.series.reduce((be,ye)=>(ye.getPointsCollection().forEach(xe=>{J(xe.selectedStaging,xe.selected)&&be.push(xe)}),be),[])}getSelectedSeries(){return this.series.filter(function(be){return be.selected})}setTitle(be,ye,xe){this.applyDescription("title",be),this.applyDescription("subtitle",ye),this.applyDescription("caption",void 0),this.layOutTitles(xe)}applyDescription(be,ye){let xe=this,pe=this.options[be]=P(this.options[be],ye),Se=this[be];Se&&ye&&(this[be]=Se=Se.destroy()),pe&&!Se&&((Se=this.renderer.text(pe.text,0,0,pe.useHTML).attr({align:pe.align,class:"highcharts-"+be,zIndex:pe.zIndex||4}).add()).update=function(Ae,Te){xe.applyDescription(be,Ae),xe.layOutTitles(Te)},this.styledMode||Se.css(D(be==="title"?{fontSize:this.options.isStock?"1em":"1.2em"}:{},pe.style)),this[be]=Se)}layOutTitles(be=!0){let ye=[0,0,0],xe=this.renderer,pe=this.spacingBox;["title","subtitle","caption"].forEach(function(Ae){let Te=this[Ae],Oe=this.options[Ae],ze=Oe.verticalAlign||"top",Ge=Ae==="title"?ze==="top"?-3:0:ze==="top"?ye[0]+2:0;if(Te){Te.css({width:(Oe.width||pe.width+(Oe.widthAdjust||0))+"px"});let Ve=xe.fontMetrics(Te).b,qe=Math.round(Te.getBBox(Oe.useHTML).height);Te.align(D({y:ze==="bottom"?Ve:Ge+Ve,height:qe},Oe),!1,"spacingBox"),Oe.floating||(ze==="top"?ye[0]=Math.ceil(ye[0]+qe):ze==="bottom"&&(ye[2]=Math.ceil(ye[2]+qe)))}},this),ye[0]&&(this.options.title.verticalAlign||"top")==="top"&&(ye[0]+=this.options.title.margin),ye[2]&&this.options.caption.verticalAlign==="bottom"&&(ye[2]+=this.options.caption.margin);let Se=!this.titleOffset||this.titleOffset.join(",")!==ye.join(",");this.titleOffset=ye,K(this,"afterLayOutTitles"),!this.isDirtyBox&&Se&&(this.isDirtyBox=this.isDirtyLegend=Se,this.hasRendered&&be&&this.isDirtyBox&&this.redraw())}getContainerBox(){let be=[].map.call(this.renderTo.children,xe=>{if(xe!==this.container){let pe=xe.style.display;return xe.style.display="none",[xe,pe]}}),ye={width:te(this.renderTo,"width",!0)||0,height:te(this.renderTo,"height",!0)||0};return be.filter(Boolean).forEach(([xe,pe])=>{xe.style.display=pe}),ye}getChartSize(){var Ae;let be=this.options.chart,ye=be.width,xe=be.height,pe=this.getContainerBox(),Se=pe.height>1&&!(!((Ae=this.renderTo.parentElement)!=null&&Ae.style.height)&&this.renderTo.style.height==="100%");this.chartWidth=Math.max(0,ye||pe.width||600),this.chartHeight=Math.max(0,re(xe,this.chartWidth)||(Se?pe.height:400)),this.containerBox=pe}temporaryDisplay(be){let ye=this.renderTo,xe;if(be)for(;ye&&ye.style;)ye.hcOrigStyle&&(ae(ye,ye.hcOrigStyle),delete ye.hcOrigStyle),ye.hcOrigDetached&&(I.body.removeChild(ye),ye.hcOrigDetached=!1),ye=ye.parentNode;else for(;ye&&ye.style&&(I.body.contains(ye)||ye.parentNode||(ye.hcOrigDetached=!0,I.body.appendChild(ye)),(te(ye,"display",!1)==="none"||ye.hcOricDetached)&&(ye.hcOrigStyle={display:ye.style.display,height:ye.style.height,overflow:ye.style.overflow},xe={display:"block",overflow:"hidden"},ye!==this.renderTo&&(xe.height=0),ae(ye,xe),ye.offsetWidth||ye.style.setProperty("display","block","important")),(ye=ye.parentNode)!==I.body););}setClassName(be){this.container.className="highcharts-container "+(be||"")}getContainer(){var qe;let be=this.options,ye=be.chart,xe="data-highcharts-chart",pe=Ce(),Se,Ae=this.renderTo;Ae||(this.renderTo=Ae=ye.renderTo),de(Ae)&&(this.renderTo=Ae=I.getElementById(Ae)),Ae||g(13,!0,this);let Te=le(R(Ae,xe));z(Te)&&se[Te]&&se[Te].hasRendered&&se[Te].destroy(),R(Ae,xe,this.index),Ae.innerHTML=ne.emptyHTML,ye.skipClone||Ae.offsetWidth||this.temporaryDisplay(),this.getChartSize();let Oe=this.chartHeight,ze=this.chartWidth;ae(Ae,{overflow:"hidden"}),this.styledMode||(Se=D({position:"relative",overflow:"hidden",width:ze+"px",height:Oe+"px",textAlign:"left",lineHeight:"normal",zIndex:0,"-webkit-tap-highlight-color":"rgba(0,0,0,0)",userSelect:"none","touch-action":"manipulation",outline:"none",padding:"0px"},ye.style||{}));let Ge=V("div",{id:pe},Se,Ae);this.container=Ge,this.getChartSize(),ze===this.chartWidth||(ze=this.chartWidth,this.styledMode||ae(Ge,{width:J((qe=ye.style)==null?void 0:qe.width,ze+"px")})),this.containerBox=this.getContainerBox(),this._cursor=Ge.style.cursor;let Ve=ye.renderer||!Q?x.getRendererType(ye.renderer):k;if(this.renderer=new Ve(Ge,ze,Oe,void 0,ye.forExport,be.exporting&&be.exporting.allowHTML,this.styledMode),Y(void 0,this),this.setClassName(ye.className),this.styledMode)for(let ot in be.defs)this.renderer.definition(be.defs[ot]);else this.renderer.setStyle(ye.style);this.renderer.chartIndex=this.index,K(this,"afterGetContainer")}getMargins(be){let{spacing:ye,margin:xe,titleOffset:pe}=this;this.resetMargins(),pe[0]&&!oe(xe[0])&&(this.plotTop=Math.max(this.plotTop,pe[0]+ye[0])),pe[2]&&!oe(xe[2])&&(this.marginBottom=Math.max(this.marginBottom,pe[2]+ye[2])),this.legend&&this.legend.display&&this.legend.adjustMargins(xe,ye),K(this,"getMargins"),be||this.getAxisMargins()}getAxisMargins(){let be=this,ye=be.axisOffset=[0,0,0,0],xe=be.colorAxis,pe=be.margin,Se=function(Ae){Ae.forEach(function(Te){Te.visible&&Te.getOffset()})};be.hasCartesianSeries?Se(be.axes):xe&&xe.length&&Se(xe),H.forEach(function(Ae,Te){oe(pe[Te])||(be[Ae]+=ye[Te])}),be.setChartSize()}getOptions(){return A(this.userOptions,X)}reflow(be){var Se;let ye=this,xe=ye.containerBox,pe=ye.getContainerBox();(Se=ye.pointer)==null||delete Se.chartPosition,!ye.isPrinting&&!ye.isResizing&&xe&&pe.width&&((pe.width!==xe.width||pe.height!==xe.height)&&(G.clearTimeout(ye.reflowTimeout),ye.reflowTimeout=we(function(){ye.container&&ye.setSize(void 0,void 0,!1)},be?100:0)),ye.containerBox=pe)}setReflow(){let be=this,ye=xe=>{var pe;(pe=be.options)!=null&&pe.chart.reflow&&be.hasLoaded&&be.reflow(xe)};if(typeof ResizeObserver=="function")new ResizeObserver(ye).observe(be.renderTo);else{let xe=M(F,"resize",ye);M(this,"destroy",xe)}}setSize(be,ye,xe){let pe=this,Se=pe.renderer;pe.isResizing+=1,Y(xe,pe);let Ae=Se.globalAnimation;pe.oldChartHeight=pe.chartHeight,pe.oldChartWidth=pe.chartWidth,be!==void 0&&(pe.options.chart.width=be),ye!==void 0&&(pe.options.chart.height=ye),pe.getChartSize();let{chartWidth:Te,chartHeight:Oe,scrollablePixelsX:ze=0,scrollablePixelsY:Ge=0}=pe;(pe.isDirtyBox||Te!==pe.oldChartWidth||Oe!==pe.oldChartHeight)&&(pe.styledMode||(Ae?L:ae)(pe.container,{width:`${Te+ze}px`,height:`${Oe+Ge}px`},Ae),pe.setChartSize(!0),Se.setSize(Te,Oe,Ae),pe.axes.forEach(function(Ve){Ve.isDirty=!0,Ve.setScale()}),pe.isDirtyLegend=!0,pe.isDirtyBox=!0,pe.layOutTitles(),pe.getMargins(),pe.redraw(Ae),pe.oldChartHeight=void 0,K(pe,"resize"),setTimeout(()=>{pe&&K(pe,"endResize")},B(Ae).duration)),pe.isResizing-=1}setChartSize(be){let ye,xe,pe,Se,{chartHeight:Ae,chartWidth:Te,inverted:Oe,spacing:ze,renderer:Ge}=this,Ve=this.clipOffset,qe=Math[Oe?"floor":"round"];this.plotLeft=ye=Math.round(this.plotLeft),this.plotTop=xe=Math.round(this.plotTop),this.plotWidth=pe=Math.max(0,Math.round(Te-ye-this.marginRight)),this.plotHeight=Se=Math.max(0,Math.round(Ae-xe-this.marginBottom)),this.plotSizeX=Oe?Se:pe,this.plotSizeY=Oe?pe:Se,this.spacingBox=Ge.spacingBox={x:ze[3],y:ze[0],width:Te-ze[3]-ze[1],height:Ae-ze[0]-ze[2]},this.plotBox=Ge.plotBox={x:ye,y:xe,width:pe,height:Se},Ve&&(this.clipBox={x:qe(Ve[3]),y:qe(Ve[0]),width:qe(this.plotSizeX-Ve[1]-Ve[3]),height:qe(this.plotSizeY-Ve[0]-Ve[2])}),be||(this.axes.forEach(function(ot){ot.setAxisSize(),ot.setAxisTranslation()}),Ge.alignElements()),K(this,"afterSetChartSize",{skipAxes:be})}resetMargins(){K(this,"resetMargins");let be=this,ye=be.options.chart,xe=ye.plotBorderWidth||0,pe=xe/2;["margin","spacing"].forEach(function(Se){let Ae=ye[Se],Te=W(Ae)?Ae:[Ae,Ae,Ae,Ae];["Top","Right","Bottom","Left"].forEach(function(Oe,ze){be[Se][ze]=J(ye[Se+Oe],Te[ze])})}),H.forEach(function(Se,Ae){be[Se]=J(be.margin[Ae],be.spacing[Ae])}),be.axisOffset=[0,0,0,0],be.clipOffset=[pe,pe,pe,pe],be.plotBorderWidth=xe}drawChartBox(){let be=this.options.chart,ye=this.renderer,xe=this.chartWidth,pe=this.chartHeight,Se=this.styledMode,Ae=this.plotBGImage,Te=be.backgroundColor,Oe=be.plotBackgroundColor,ze=be.plotBackgroundImage,Ge=this.plotLeft,Ve=this.plotTop,qe=this.plotWidth,ot=this.plotHeight,ft=this.plotBox,dt=this.clipRect,et=this.clipBox,Pt=this.chartBackground,Ie=this.plotBackground,gt=this.plotBorder,Tt,at,Pe,Qe="animate";Pt||(this.chartBackground=Pt=ye.rect().addClass("highcharts-background").add(),Qe="attr"),Se?Tt=at=Pt.strokeWidth():(at=(Tt=be.borderWidth||0)+(be.shadow?8:0),Pe={fill:Te||"none"},(Tt||Pt["stroke-width"])&&(Pe.stroke=be.borderColor,Pe["stroke-width"]=Tt),Pt.attr(Pe).shadow(be.shadow)),Pt[Qe]({x:at/2,y:at/2,width:xe-at-Tt%2,height:pe-at-Tt%2,r:be.borderRadius}),Qe="animate",Ie||(Qe="attr",this.plotBackground=Ie=ye.rect().addClass("highcharts-plot-background").add()),Ie[Qe](ft),!Se&&(Ie.attr({fill:Oe||"none"}).shadow(be.plotShadow),ze&&(Ae?(ze!==Ae.attr("href")&&Ae.attr("href",ze),Ae.animate(ft)):this.plotBGImage=ye.image(ze,Ge,Ve,qe,ot).add())),dt?dt.animate({width:et.width,height:et.height}):this.clipRect=ye.clipRect(et),Qe="animate",gt||(Qe="attr",this.plotBorder=gt=ye.rect().addClass("highcharts-plot-border").attr({zIndex:1}).add()),Se||gt.attr({stroke:be.plotBorderColor,"stroke-width":be.plotBorderWidth||0,fill:"none"}),gt[Qe](gt.crisp({x:Ge,y:Ve,width:qe,height:ot},-gt.strokeWidth())),this.isDirtyBox=!1,K(this,"afterDrawChartBox")}propFromSeries(){let be,ye,xe,pe=this,Se=pe.options.chart,Ae=pe.options.series;["inverted","angular","polar"].forEach(function(Te){for(ye=E[Se.type],xe=Se[Te]||ye&&ye.prototype[Te],be=Ae&&Ae.length;!xe&&be--;)(ye=E[Ae[be].type])&&ye.prototype[Te]&&(xe=!0);pe[Te]=xe})}linkSeries(be){let ye=this,xe=ye.series;xe.forEach(function(pe){pe.linkedSeries.length=0}),xe.forEach(function(pe){let{linkedTo:Se}=pe.options;if(de(Se)){let Ae;(Ae=Se===":previous"?ye.series[pe.index-1]:ye.get(Se))&&Ae.linkedParent!==pe&&(Ae.linkedSeries.push(pe),pe.linkedParent=Ae,Ae.enabledDataSorting&&pe.setDataSortingOptions(),pe.visible=J(pe.options.visible,Ae.options.visible,pe.visible))}}),K(this,"afterLinkSeries",{isUpdating:be})}renderSeries(){this.series.forEach(function(be){be.translate(),be.render()})}render(){var Ge;let be=this.axes,ye=this.colorAxis,xe=this.renderer,pe=this.options.chart.axisLayoutRuns||2,Se=Ve=>{Ve.forEach(qe=>{qe.visible&&qe.render()})},Ae=0,Te=!0,Oe,ze=0;for(let Ve of(this.setTitle(),K(this,"beforeMargins"),(Ge=this.getStacks)==null||Ge.call(this),this.getMargins(!0),this.setChartSize(),be)){let{options:qe}=Ve,{labels:ot}=qe;if(this.hasCartesianSeries&&Ve.horiz&&Ve.visible&&ot.enabled&&Ve.series.length&&Ve.coll!=="colorAxis"&&!this.polar){Ae=qe.tickLength,Ve.createGroups();let ft=new $(Ve,0,"",!0),dt=ft.createLabel("x",ot);if(ft.destroy(),dt&&J(ot.reserveSpace,!z(qe.crossing))&&(Ae=dt.getBBox().height+ot.distance+Math.max(qe.offset||0,0)),Ae){dt==null||dt.destroy();break}}}for(this.plotHeight=Math.max(this.plotHeight-Ae,0);(Te||Oe||pe>1)&&ze<pe;){let Ve=this.plotWidth,qe=this.plotHeight;for(let ot of be)ze===0?ot.setScale():(ot.horiz&&Te||!ot.horiz&&Oe)&&ot.setTickInterval(!0);ze===0?this.getAxisMargins():this.getMargins(),Te=Ve/this.plotWidth>(ze?1:1.1),Oe=qe/this.plotHeight>(ze?1:1.05),ze++}this.drawChartBox(),this.hasCartesianSeries?Se(be):ye&&ye.length&&Se(ye),this.seriesGroup||(this.seriesGroup=xe.g("series-group").attr({zIndex:3}).shadow(this.options.chart.seriesGroupShadow).add()),this.renderSeries(),this.addCredits(),this.setResponsive&&this.setResponsive(),this.hasRendered=!0}addCredits(be){let ye=this,xe=P(!0,this.options.credits,be);xe.enabled&&!this.credits&&(this.credits=this.renderer.text(xe.text+(this.mapCredits||""),0,0).addClass("highcharts-credits").on("click",function(){xe.href&&(F.location.href=xe.href)}).attr({align:xe.position.align,zIndex:8}),ye.styledMode||this.credits.css(xe.style),this.credits.add().align(xe.position),this.credits.update=function(pe){ye.credits=ye.credits.destroy(),ye.addCredits(pe)})}destroy(){let be,ye=this,xe=ye.axes,pe=ye.series,Se=ye.container,Ae=Se&&Se.parentNode;for(K(ye,"destroy"),ye.renderer.forExport?me(se,ye):se[ye.index]=void 0,v.chartCount--,ye.renderTo.removeAttribute("data-highcharts-chart"),ge(ye),be=xe.length;be--;)xe[be]=xe[be].destroy();for(this.scroller&&this.scroller.destroy&&this.scroller.destroy(),be=pe.length;be--;)pe[be]=pe[be].destroy();["title","subtitle","chartBackground","plotBackground","plotBGImage","plotBorder","seriesGroup","clipRect","credits","pointer","rangeSelector","legend","resetZoomButton","tooltip","renderer"].forEach(function(Te){let Oe=ye[Te];Oe&&Oe.destroy&&(ye[Te]=Oe.destroy())}),Se&&(Se.innerHTML=ne.emptyHTML,ge(Se),Ae&&ue(Se)),ee(ye,function(Te,Oe){delete ye[Oe]})}firstRender(){var pe;let be=this,ye=be.options;be.getContainer(),be.resetMargins(),be.setChartSize(),be.propFromSeries(),be.getAxes();let xe=O(ye.series)?ye.series:[];ye.series=[],xe.forEach(function(Se){be.initSeries(Se)}),be.linkSeries(),be.setSortedData(),K(be,"beforeRender"),be.render(),(pe=be.pointer)==null||pe.getChartPosition(),be.renderer.imgCount||be.hasLoaded||be.onload(),be.temporaryDisplay(!0)}onload(){this.callbacks.concat([this.callback]).forEach(function(be){be&&this.index!==void 0&&be.apply(this,[this])},this),K(this,"load"),K(this,"render"),oe(this.index)&&this.setReflow(),this.warnIfA11yModuleNotLoaded(),this.hasLoaded=!0}warnIfA11yModuleNotLoaded(){let{options:be,title:ye}=this;!be||this.accessibility||(this.renderer.boxWrapper.attr({role:"img","aria-label":(ye&&ye.element.textContent||"").replace(/</g,"&lt;")}),be.accessibility&&be.accessibility.enabled===!1||g('Highcharts warning: Consider including the "accessibility.js" module to make your chart more usable for people with disabilities. Set the "accessibility.enabled" option to false to remove this warning. See https://www.highcharts.com/docs/accessibility/accessibility-module.',!1,this))}addSeries(be,ye,xe){let pe,Se=this;return be&&(ye=J(ye,!0),K(Se,"addSeries",{options:be},function(){pe=Se.initSeries(be),Se.isDirtyLegend=!0,Se.linkSeries(),pe.enabledDataSorting&&pe.setData(be.data,!1),K(Se,"afterAddSeries",{series:pe}),ye&&Se.redraw(xe)})),pe}addAxis(be,ye,xe,pe){return this.createAxis(ye?"xAxis":"yAxis",{axis:be,redraw:xe,animation:pe})}addColorAxis(be,ye,xe){return this.createAxis("colorAxis",{axis:be,redraw:ye,animation:xe})}createAxis(be,ye){let xe=new u(this,ye.axis,be);return J(ye.redraw,!0)&&this.redraw(ye.animation),xe}showLoading(be){let ye=this,xe=ye.options,pe=xe.loading,Se=function(){Ae&&ae(Ae,{left:ye.plotLeft+"px",top:ye.plotTop+"px",width:ye.plotWidth+"px",height:ye.plotHeight+"px"})},Ae=ye.loadingDiv,Te=ye.loadingSpan;Ae||(ye.loadingDiv=Ae=V("div",{className:"highcharts-loading highcharts-loading-hidden"},null,ye.container)),Te||(ye.loadingSpan=Te=V("span",{className:"highcharts-loading-inner"},null,Ae),M(ye,"redraw",Se)),Ae.className="highcharts-loading",ne.setElementHTML(Te,J(be,xe.lang.loading,"")),ye.styledMode||(ae(Ae,D(pe.style,{zIndex:10})),ae(Te,pe.labelStyle),ye.loadingShown||(ae(Ae,{opacity:0,display:""}),L(Ae,{opacity:pe.style.opacity||.5},{duration:pe.showDuration||0}))),ye.loadingShown=!0,Se()}hideLoading(){let be=this.options,ye=this.loadingDiv;ye&&(ye.className="highcharts-loading highcharts-loading-hidden",this.styledMode||L(ye,{opacity:0},{duration:be.loading.hideDuration||100,complete:function(){ae(ye,{display:"none"})}})),this.loadingShown=!1}update(be,ye,xe,pe){let Se,Ae,Te,Oe=this,ze={credits:"addCredits",title:"setTitle",subtitle:"setSubtitle",caption:"setCaption"},Ge=be.isResponsiveOptions,Ve=[];K(Oe,"update",{options:be}),Ge||Oe.setResponsive(!1,!0),be=A(be,Oe.options),Oe.userOptions=P(Oe.userOptions,be);let qe=be.chart;qe&&(P(!0,Oe.options.chart,qe),this.setZoomOptions(),"className"in qe&&Oe.setClassName(qe.className),("inverted"in qe||"polar"in qe||"type"in qe)&&(Oe.propFromSeries(),Se=!0),"alignTicks"in qe&&(Se=!0),"events"in qe&&ce(this,qe),ee(qe,function(dt,et){Oe.propsRequireUpdateSeries.indexOf("chart."+et)!==-1&&(Ae=!0),Oe.propsRequireDirtyBox.indexOf(et)!==-1&&(Oe.isDirtyBox=!0),Oe.propsRequireReflow.indexOf(et)===-1||(Oe.isDirtyBox=!0,Ge||(Te=!0))}),!Oe.styledMode&&qe.style&&Oe.renderer.setStyle(Oe.options.chart.style||{})),!Oe.styledMode&&be.colors&&(this.options.colors=be.colors),be.time&&(this.time===U&&(this.time=new C(be.time)),P(!0,Oe.options.time,be.time)),ee(be,function(dt,et){Oe[et]&&typeof Oe[et].update=="function"?Oe[et].update(dt,!1):typeof Oe[ze[et]]=="function"?Oe[ze[et]](dt):et!=="colors"&&Oe.collectionsWithUpdate.indexOf(et)===-1&&P(!0,Oe.options[et],be[et]),et!=="chart"&&Oe.propsRequireUpdateSeries.indexOf(et)!==-1&&(Ae=!0)}),this.collectionsWithUpdate.forEach(function(dt){be[dt]&&(ve(be[dt]).forEach(function(et,Pt){let Ie,gt=oe(et.id);gt&&(Ie=Oe.get(et.id)),!Ie&&Oe[dt]&&(Ie=Oe[dt][J(et.index,Pt)])&&(gt&&oe(Ie.options.id)||Ie.options.isInternal)&&(Ie=void 0),Ie&&Ie.coll===dt&&(Ie.update(et,!1),xe&&(Ie.touched=!0)),!Ie&&xe&&Oe.collectionsWithInit[dt]&&(Oe.collectionsWithInit[dt][0].apply(Oe,[et].concat(Oe.collectionsWithInit[dt][1]||[]).concat([!1])).touched=!0)}),xe&&Oe[dt].forEach(function(et){et.touched||et.options.isInternal?delete et.touched:Ve.push(et)}))}),Ve.forEach(function(dt){dt.chart&&dt.remove&&dt.remove(!1)}),Se&&Oe.axes.forEach(function(dt){dt.update({},!1)}),Ae&&Oe.getSeriesOrderByLinks().forEach(function(dt){dt.chart&&dt.update({},!1)},this);let ot=qe&&qe.width,ft=qe&&(de(qe.height)?re(qe.height,ot||Oe.chartWidth):qe.height);Te||z(ot)&&ot!==Oe.chartWidth||z(ft)&&ft!==Oe.chartHeight?Oe.setSize(ot,ft,pe):J(ye,!0)&&Oe.redraw(pe),K(Oe,"afterUpdate",{options:be,redraw:ye,animation:pe})}setSubtitle(be,ye){this.applyDescription("subtitle",be),this.layOutTitles(ye)}setCaption(be,ye){this.applyDescription("caption",be),this.layOutTitles(ye)}showResetZoom(){let be=this,ye=X.lang,xe=be.zooming.resetButton,pe=xe.theme,Se=xe.relativeTo==="chart"||xe.relativeTo==="spacingBox"?null:"plotBox";function Ae(){be.zoomOut()}K(this,"beforeShowResetZoom",null,function(){be.resetZoomButton=be.renderer.button(ye.resetZoom,null,null,Ae,pe).attr({align:xe.position.align,title:ye.resetZoomTitle}).addClass("highcharts-reset-zoom").add().align(xe.position,!1,Se)}),K(this,"afterShowResetZoom")}zoomOut(){K(this,"selection",{resetSelection:!0},()=>this.transform({reset:!0,trigger:"zoom"}))}pan(be,ye){let xe=this,pe=typeof ye=="object"?ye:{enabled:ye,type:"x"},Se=pe.type,Ae=Se&&xe[{x:"xAxis",xy:"axes",y:"yAxis"}[Se]].filter(Oe=>Oe.options.panningEnabled&&!Oe.options.isInternal),Te=xe.options.chart;Te!=null&&Te.panning&&(Te.panning=pe),K(this,"pan",{originalEvent:be},()=>{xe.transform({axes:Ae,event:be,to:{x:be.chartX-(xe.mouseDownX||0),y:be.chartY-(xe.mouseDownY||0)},trigger:"pan"}),ae(xe.container,{cursor:"move"})})}transform(be){var ot;let{axes:ye=this.axes,event:xe,from:pe={},reset:Se,selection:Ae,to:Te={},trigger:Oe}=be,{inverted:ze}=this,Ge=!1,Ve,qe;for(let ft of((ot=this.hoverPoints)==null||ot.forEach(dt=>dt.setState()),ye)){let{horiz:dt,len:et,minPointOffset:Pt=0,options:Ie,reversed:gt}=ft,Tt=dt?"width":"height",at=dt?"x":"y",Pe=J(Te[Tt],ft.len),Qe=J(pe[Tt],ft.len),it=10>Math.abs(Pe)?1:Pe/Qe,lt=(pe[at]||0)+Qe/2-ft.pos,Lt=lt-((Te[at]??ft.pos)+Pe/2-ft.pos)/it,It=gt&&!ze||!gt&&ze?-1:1;if(!Se&&(lt<0||lt>ft.len))continue;let Mt=ft.toValue(Lt,!0)+(Ae||ft.isOrdinal?0:Pt*It),Ot=ft.toValue(Lt+et/it,!0)-(Ae||ft.isOrdinal?0:Pt*It||0),Yt=ft.allExtremes;if(Mt>Ot&&([Mt,Ot]=[Ot,Mt]),it===1&&!Se&&ft.coll==="yAxis"&&!Yt){for(let bt of ft.series){let pt=bt.getExtremes(bt.getProcessedData(!0).yData,!0);Yt??(Yt={dataMin:Number.MAX_VALUE,dataMax:-Number.MAX_VALUE}),z(pt.dataMin)&&z(pt.dataMax)&&(Yt.dataMin=Math.min(pt.dataMin,Yt.dataMin),Yt.dataMax=Math.max(pt.dataMax,Yt.dataMax))}ft.allExtremes=Yt}let{dataMin:Xt,dataMax:sn,min:Wt,max:_n}=D(ft.getExtremes(),Yt||{}),ti=Xt??Ie.min,St=sn??Ie.max,oi=Ot-Mt,on=ft.categories?0:Math.min(oi,St-ti),ln=ti-on*(oe(Ie.min)?0:Ie.minPadding),Kt=St+on*(oe(Ie.max)?0:Ie.maxPadding),Nt=ft.allowZoomOutside||it===1||Oe!=="zoom"&&it>1,yt=Math.min(Ie.min??ln,ln,Nt?Wt:ln),At=Math.max(Ie.max??Kt,Kt,Nt?_n:Kt);(!ft.isOrdinal||ft.options.overscroll||it!==1||Se)&&(Mt<yt&&(Mt=yt,it>=1&&(Ot=Mt+oi)),Ot>At&&(Ot=At,it>=1&&(Mt=Ot-oi)),(Se||ft.series.length&&(Mt!==Wt||Ot!==_n)&&Mt>=yt&&Ot<=At)&&(Ae?Ae[ft.coll].push({axis:ft,min:Mt,max:Ot}):(ft.isPanning=Oe!=="zoom",ft.isPanning&&(qe=!0),ft.setExtremes(Se?void 0:Mt,Se?void 0:Ot,!1,!1,{move:Lt,trigger:Oe,scale:it}),!Se&&(Mt>yt||Ot<At)&&Oe!=="mousewheel"&&(Ve=!0)),Ge=!0),xe&&(this[dt?"mouseDownX":"mouseDownY"]=xe[dt?"chartX":"chartY"]))}return Ge&&(Ae?K(this,"selection",Ae,()=>{delete be.selection,be.trigger="zoom",this.transform(be)}):(!Ve||qe||this.resetZoomButton?!Ve&&this.resetZoomButton&&(this.resetZoomButton=this.resetZoomButton.destroy()):this.showResetZoom(),this.redraw(Oe==="zoom"&&(this.options.chart.animation??this.pointCount<100)))),Ge}}return D(Me.prototype,{callbacks:[],collectionsWithInit:{xAxis:[Me.prototype.addAxis,[!0]],yAxis:[Me.prototype.addAxis,[!1]],series:[Me.prototype.addSeries]},collectionsWithUpdate:["xAxis","yAxis","series"],propsRequireDirtyBox:["backgroundColor","borderColor","borderWidth","borderRadius","plotBackgroundColor","plotBackgroundImage","plotBorderColor","plotBorderWidth","plotShadow","shadow"],propsRequireReflow:["margin","marginTop","marginRight","marginBottom","marginLeft","spacing","spacingTop","spacingRight","spacingBottom","spacingLeft"],propsRequireUpdateSeries:["chart.inverted","chart.polar","chart.ignoreHiddenSeries","chart.type","colors","plotOptions","time","tooltip"]}),Me}),r(a,"Extensions/ScrollablePlotArea.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Globals.js"],a["Core/Renderer/RendererRegistry.js"],a["Core/Utilities.js"]],function(c,u,h,p){let{stop:m}=c,{composed:v}=u,{addEvent:x,createElement:_,css:T,defined:k,merge:C,pushUnique:G}=p;function ne(){let B=this.scrollablePlotArea;(this.scrollablePixelsX||this.scrollablePixelsY)&&!B&&(this.scrollablePlotArea=B=new L(this)),B==null||B.applyFixed()}function $(){this.chart.scrollablePlotArea&&(this.chart.scrollablePlotArea.isDirty=!0)}class L{static compose(Y,X,U){G(v,this.compose)&&(x(Y,"afterInit",$),x(X,"afterSetChartSize",Z=>this.afterSetSize(Z.target,Z)),x(X,"render",ne),x(U,"show",$))}static afterSetSize(Y,X){let U,Z,ce,{minWidth:se,minHeight:I}=Y.options.chart.scrollablePlotArea||{},{clipBox:H,plotBox:Q,inverted:F,renderer:E}=Y;if(!E.forExport&&(se?(Y.scrollablePixelsX=U=Math.max(0,se-Y.chartWidth),U&&(Y.scrollablePlotBox=C(Y.plotBox),Q.width=Y.plotWidth+=U,H[F?"height":"width"]+=U,ce=!0)):I&&(Y.scrollablePixelsY=Z=Math.max(0,I-Y.chartHeight),k(Z)&&(Y.scrollablePlotBox=C(Y.plotBox),Q.height=Y.plotHeight+=Z,H[F?"width":"height"]+=Z,ce=!1)),k(ce)&&!X.skipAxes))for(let M of Y.axes)M.horiz===ce&&(M.setAxisSize(),M.setAxisTranslation())}constructor(Y){var R;let X,U=Y.options.chart,Z=h.getRendererType(),ce=U.scrollablePlotArea||{},se=this.moveFixedElements.bind(this),I={WebkitOverflowScrolling:"touch",overflowX:"hidden",overflowY:"hidden"};Y.scrollablePixelsX&&(I.overflowX="auto"),Y.scrollablePixelsY&&(I.overflowY="auto"),this.chart=Y;let H=this.parentDiv=_("div",{className:"highcharts-scrolling-parent"},{position:"relative"},Y.renderTo),Q=this.scrollingContainer=_("div",{className:"highcharts-scrolling"},I,H),F=this.innerContainer=_("div",{className:"highcharts-inner-container"},void 0,Q),E=this.fixedDiv=_("div",{className:"highcharts-fixed"},{position:"absolute",overflow:"hidden",pointerEvents:"none",zIndex:(((R=U.style)==null?void 0:R.zIndex)||0)+2,top:0},void 0,!0),M=this.fixedRenderer=new Z(E,Y.chartWidth,Y.chartHeight,U.style);this.mask=M.path().attr({fill:U.backgroundColor||"#fff","fill-opacity":ce.opacity??.85,zIndex:-1}).addClass("highcharts-scrollable-mask").add(),Q.parentNode.insertBefore(E,Q),T(Y.renderTo,{overflow:"visible"}),x(Y,"afterShowResetZoom",se),x(Y,"afterApplyDrilldown",se),x(Y,"afterLayOutTitles",se),x(Q,"scroll",()=>{let{pointer:V,hoverPoint:ae}=Y;V&&(delete V.chartPosition,ae&&(X=ae),V.runPointActions(void 0,X,!0))}),F.appendChild(Y.container)}applyFixed(){var z;let{chart:Y,fixedRenderer:X,isDirty:U,scrollingContainer:Z}=this,{axisOffset:ce,chartWidth:se,chartHeight:I,container:H,plotHeight:Q,plotLeft:F,plotTop:E,plotWidth:M,scrollablePixelsX:R=0,scrollablePixelsY:V=0}=Y,{scrollPositionX:ae=0,scrollPositionY:oe=0}=Y.options.chart.scrollablePlotArea||{},A=se+R,ue=I+V;X.setSize(se,I),(U??!0)&&(this.isDirty=!1,this.moveFixedElements()),m(Y.container),T(H,{width:`${A}px`,height:`${ue}px`}),Y.renderer.boxWrapper.attr({width:A,height:ue,viewBox:[0,0,A,ue].join(" ")}),(z=Y.chartBackground)==null||z.attr({width:A,height:ue}),T(Z,{width:`${se}px`,height:`${I}px`}),k(U)||(Z.scrollLeft=R*ae,Z.scrollTop=V*oe);let me=E-ce[0]-1,g=F-ce[3]-1,D=E+Q+ce[2]+1,j=F+M+ce[1]+1,K=F+M-R,te=E+Q-V,O=[["M",0,0]];R?O=[["M",0,me],["L",F-1,me],["L",F-1,D],["L",0,D],["Z"],["M",K,me],["L",se,me],["L",se,D],["L",K,D],["Z"]]:V&&(O=[["M",g,0],["L",g,E-1],["L",j,E-1],["L",j,0],["Z"],["M",g,te],["L",g,I],["L",j,I],["L",j,te],["Z"]]),Y.redrawTrigger!=="adjustHeight"&&this.mask.attr({d:O})}moveFixedElements(){let Y,{container:X,inverted:U,scrollablePixelsX:Z,scrollablePixelsY:ce}=this.chart,se=this.fixedRenderer,I=L.fixedSelectors;for(let H of(Z&&!U?Y=".highcharts-yaxis":Z&&U||ce&&!U?Y=".highcharts-xaxis":ce&&U&&(Y=".highcharts-yaxis"),Y&&I.push(`${Y}:not(.highcharts-radial-axis)`,`${Y}-labels:not(.highcharts-radial-axis-labels)`),I))[].forEach.call(X.querySelectorAll(H),Q=>{(Q.namespaceURI===se.SVG_NS?se.box:se.box.parentNode).appendChild(Q),Q.style.pointerEvents="auto"})}}return L.fixedSelectors=[".highcharts-breadcrumbs-group",".highcharts-contextbutton",".highcharts-caption",".highcharts-credits",".highcharts-drillup-button",".highcharts-legend",".highcharts-legend-checkbox",".highcharts-navigator-series",".highcharts-navigator-xaxis",".highcharts-navigator-yaxis",".highcharts-navigator",".highcharts-range-selector-group",".highcharts-reset-zoom",".highcharts-scrollbar",".highcharts-subtitle",".highcharts-title"],L}),r(a,"Core/Axis/Stacking/StackItem.js",[a["Core/Templating.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(c,u,h){let{format:p}=c,{series:m}=u,{destroyObjectProperties:v,fireEvent:x,isNumber:_,pick:T}=h;return class{constructor(k,C,G,ne,$){let L=k.chart.inverted,B=k.reversed;this.axis=k;let Y=this.isNegative=!!G!=!!B;this.options=C=C||{},this.x=ne,this.total=null,this.cumulative=null,this.points={},this.hasValidPoints=!1,this.stack=$,this.leftCliff=0,this.rightCliff=0,this.alignOptions={align:C.align||(L?Y?"left":"right":"center"),verticalAlign:C.verticalAlign||(L?"middle":Y?"bottom":"top"),y:C.y,x:C.x},this.textAlign=C.textAlign||(L?Y?"right":"left":"center")}destroy(){v(this,this.axis)}render(k){let C=this.axis.chart,G=this.options,ne=G.format,$=ne?p(ne,this,C):G.formatter.call(this);if(this.label)this.label.attr({text:$,visibility:"hidden"});else{this.label=C.renderer.label($,null,void 0,G.shape,void 0,void 0,G.useHTML,!1,"stack-labels");let L={r:G.borderRadius||0,text:$,padding:T(G.padding,5),visibility:"hidden"};C.styledMode||(L.fill=G.backgroundColor,L.stroke=G.borderColor,L["stroke-width"]=G.borderWidth,this.label.css(G.style||{})),this.label.attr(L),this.label.added||this.label.add(k)}this.label.labelrank=C.plotSizeY,x(this,"afterRender")}setOffset(k,C,G,ne,$,L){let{alignOptions:B,axis:Y,label:X,options:U,textAlign:Z}=this,ce=Y.chart,se=this.getStackBox({xOffset:k,width:C,boxBottom:G,boxTop:ne,defaultX:$,xAxis:L}),{verticalAlign:I}=B;if(X&&se){let H=X.getBBox(void 0,0),Q=X.padding,F=T(U.overflow,"justify")==="justify",E;B.x=U.x||0,B.y=U.y||0;let{x:M,y:R}=this.adjustStackPosition({labelBox:H,verticalAlign:I,textAlign:Z});se.x-=M,se.y-=R,X.align(B,!1,se),(E=ce.isInsidePlot(X.alignAttr.x+B.x+M,X.alignAttr.y+B.y+R))||(F=!1),F&&m.prototype.justifyDataLabel.call(Y,X,B,X.alignAttr,H,se),X.attr({x:X.alignAttr.x,y:X.alignAttr.y,rotation:U.rotation,rotationOriginX:H.width*{left:0,center:.5,right:1}[U.textAlign||"center"],rotationOriginY:H.height/2}),T(!F&&U.crop,!0)&&(E=_(X.x)&&_(X.y)&&ce.isInsidePlot(X.x-Q+(X.width||0),X.y)&&ce.isInsidePlot(X.x+Q,X.y)),X[E?"show":"hide"]()}x(this,"afterSetOffset",{xOffset:k,width:C})}adjustStackPosition({labelBox:k,verticalAlign:C,textAlign:G}){let ne={bottom:0,middle:1,top:2,right:1,center:0,left:-1},$=ne[C],L=ne[G];return{x:k.width/2+k.width/2*L,y:k.height/2*$}}getStackBox(k){let C=this.axis,G=C.chart,{boxTop:ne,defaultX:$,xOffset:L,width:B,boxBottom:Y}=k,X=C.stacking.usePercentage?100:T(ne,this.total,0),U=C.toPixels(X),Z=k.xAxis||G.xAxis[0],ce=T($,Z.translate(this.x))+L,se=Math.abs(U-C.toPixels(Y||_(C.min)&&C.logarithmic&&C.logarithmic.lin2log(C.min)||0)),I=G.inverted,H=this.isNegative;return I?{x:(H?U:U-se)-G.plotLeft,y:Z.height-ce-B+Z.top-G.plotTop,width:se,height:B}:{x:ce+Z.transB-G.plotLeft,y:(H?U-se:U)-G.plotTop,width:B,height:se}}}}),r(a,"Core/Axis/Stacking/StackingAxis.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Axis/Axis.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Axis/Stacking/StackItem.js"],a["Core/Utilities.js"]],function(c,u,h,p,m){var v;let{getDeferredAnimation:x}=c,{series:{prototype:_}}=h,{addEvent:T,correctFloat:k,defined:C,destroyObjectProperties:G,fireEvent:ne,isArray:$,isNumber:L,objectEach:B,pick:Y}=m;function X(){let E=this.inverted;this.axes.forEach(M=>{M.stacking&&M.stacking.stacks&&M.hasVisibleSeries&&(M.stacking.oldStacks=M.stacking.stacks)}),this.series.forEach(M=>{let R=M.xAxis&&M.xAxis.options||{};M.options.stacking&&M.reserveSpace()&&(M.stackKey=[M.type,Y(M.options.stack,""),E?R.top:R.left,E?R.height:R.width].join(","))})}function U(){var M;let E=this.stacking;if(E){let R=E.stacks;B(R,(V,ae)=>{G(V),delete R[ae]}),(M=E.stackTotalGroup)==null||M.destroy()}}function Z(){this.stacking||(this.stacking=new F(this))}function ce(E,M,R,V){return!C(E)||E.x!==M||V&&E.stackKey!==V?E={x:M,index:0,key:V,stackKey:V}:E.index++,E.key=[R,M,E.index].join(","),E}function se(){let E,M=this,R=M.yAxis,V=M.stackKey||"",ae=R.stacking.stacks,oe=M.processedXData,A=M.options.stacking,ue=M[A+"Stacker"];ue&&[V,"-"+V].forEach(me=>{var te;let g=oe.length,D,j,K;for(;g--;)D=oe[g],E=M.getStackIndicator(E,D,M.index,me),j=(te=ae[me])==null?void 0:te[D],(K=j==null?void 0:j.points[E.key||""])&&ue.call(M,K,j,g)})}function I(E,M,R){let V=M.total?100/M.total:0;E[0]=k(E[0]*V),E[1]=k(E[1]*V),this.stackedYData[R]=E[1]}function H(E){(this.is("column")||this.is("columnrange"))&&(this.options.centerInCategory&&!this.options.stacking&&this.chart.series.length>1?_.setStackedPoints.call(this,E,"group"):E.stacking.resetStacks())}function Q(E,M){var Ce,Me;let R,V,ae,oe,A,ue,me,g,D,j=M||this.options.stacking;if(!j||!this.reserveSpace()||({group:"xAxis"}[j]||"yAxis")!==E.coll)return;let K=this.processedXData,te=this.processedYData,O=[],z=te.length,W=this.options,de=W.threshold||0,P=W.startFromThreshold?de:0,ee=W.stack,J=M?`${this.type},${j}`:this.stackKey||"",le="-"+J,re=this.negStacks,ge=E.stacking,ve=ge.stacks,we=ge.oldStacks;for(ge.stacksTouched+=1,me=0;me<z;me++){g=K[me],D=te[me],ue=(R=this.getStackIndicator(R,g,this.index)).key||"",ve[A=(V=re&&D<(P?0:de))?le:J]||(ve[A]={}),ve[A][g]||((Ce=we[A])!=null&&Ce[g]?(ve[A][g]=we[A][g],ve[A][g].total=null):ve[A][g]=new p(E,E.options.stackLabels,!!V,g,ee)),ae=ve[A][g],D!==null?(ae.points[ue]=ae.points[this.index]=[Y(ae.cumulative,P)],C(ae.cumulative)||(ae.base=ue),ae.touched=ge.stacksTouched,R.index>0&&this.singleStacks===!1&&(ae.points[ue][0]=ae.points[this.index+","+g+",0"][0])):(delete ae.points[ue],delete ae.points[this.index]);let De=ae.total||0;j==="percent"?(oe=V?J:le,De=re&&((Me=ve[oe])!=null&&Me[g])?(oe=ve[oe][g]).total=Math.max(oe.total||0,De)+Math.abs(D)||0:k(De+(Math.abs(D)||0))):j==="group"?($(D)&&(D=D[0]),D!==null&&De++):De=k(De+(D||0)),j==="group"?ae.cumulative=(De||1)-1:ae.cumulative=k(Y(ae.cumulative,P)+(D||0)),ae.total=De,D!==null&&(ae.points[ue].push(ae.cumulative),O[me]=ae.cumulative,ae.hasValidPoints=!0)}j==="percent"&&(ge.usePercentage=!0),j!=="group"&&(this.stackedYData=O),ge.oldStacks={}}class F{constructor(M){this.oldStacks={},this.stacks={},this.stacksTouched=0,this.axis=M}buildStacks(){let M,R,V=this.axis,ae=V.series,oe=V.coll==="xAxis",A=V.options.reversedStacks,ue=ae.length;for(this.resetStacks(),this.usePercentage=!1,R=ue;R--;)M=ae[A?R:ue-R-1],oe&&M.setGroupedPoints(V),M.setStackedPoints(V);if(!oe)for(R=0;R<ue;R++)ae[R].modifyStacks();ne(V,"afterBuildStacks")}cleanStacks(){this.oldStacks&&(this.stacks=this.oldStacks,B(this.stacks,M=>{B(M,R=>{R.cumulative=R.total})}))}resetStacks(){B(this.stacks,M=>{B(M,(R,V)=>{L(R.touched)&&R.touched<this.stacksTouched?(R.destroy(),delete M[V]):(R.total=null,R.cumulative=null)})})}renderStackTotals(){var ue;let M=this.axis,R=M.chart,V=R.renderer,ae=this.stacks,oe=x(R,((ue=M.options.stackLabels)==null?void 0:ue.animation)||!1),A=this.stackTotalGroup=this.stackTotalGroup||V.g("stack-labels").attr({zIndex:6,opacity:0}).add();A.translate(R.plotLeft,R.plotTop),B(ae,me=>{B(me,g=>{g.render(A)})}),A.animate({opacity:1},oe)}}return(v||(v={})).compose=function(E,M,R){let V=M.prototype,ae=R.prototype;V.getStacks||(T(E,"init",Z),T(E,"destroy",U),V.getStacks=X,ae.getStackIndicator=ce,ae.modifyStacks=se,ae.percentStacker=I,ae.setGroupedPoints=H,ae.setStackedPoints=Q)},v}),r(a,"Series/Line/LineSeries.js",[a["Core/Series/Series.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(c,u,h){let{defined:p,merge:m,isObject:v}=h;class x extends c{drawGraph(){let T=this.options,k=(this.gappedPath||this.getGraphPath).call(this),C=this.chart.styledMode;[this,...this.zones].forEach((G,ne)=>{let $,L=G.graph,B=L?"animate":"attr",Y=G.dashStyle||T.dashStyle;L?(L.endX=this.preventGraphAnimation?null:k.xMap,L.animate({d:k})):k.length&&(G.graph=L=this.chart.renderer.path(k).addClass("highcharts-graph"+(ne?` highcharts-zone-graph-${ne-1} `:" ")+(ne&&G.className||"")).attr({zIndex:1}).add(this.group)),L&&!C&&($={stroke:!ne&&T.lineColor||G.color||this.color||"#cccccc","stroke-width":T.lineWidth||0,fill:this.fillGraph&&this.color||"none"},Y?$.dashstyle=Y:T.linecap!=="square"&&($["stroke-linecap"]=$["stroke-linejoin"]="round"),L[B]($).shadow(ne<2&&T.shadow&&m({filterUnits:"userSpaceOnUse"},v(T.shadow)?T.shadow:{}))),L&&(L.startX=k.xMap,L.isArea=k.isArea)})}getGraphPath(T,k,C){let G=this,ne=G.options,$=[],L=[],B,Y=ne.step,X=(T=T||G.points).reversed;return X&&T.reverse(),(Y={right:1,center:2}[Y]||Y&&3)&&X&&(Y=4-Y),(T=this.getValidPoints(T,!1,!(ne.connectNulls&&!k&&!C))).forEach(function(U,Z){let ce,se=U.plotX,I=U.plotY,H=T[Z-1],Q=U.isNull||typeof I!="number";(U.leftCliff||H&&H.rightCliff)&&!C&&(B=!0),Q&&!p(k)&&Z>0?B=!ne.connectNulls:Q&&!k?B=!0:(Z===0||B?ce=[["M",U.plotX,U.plotY]]:G.getPointSpline?ce=[G.getPointSpline(T,U,Z)]:Y?(ce=Y===1?[["L",H.plotX,I]]:Y===2?[["L",(H.plotX+se)/2,H.plotY],["L",(H.plotX+se)/2,I]]:[["L",se,H.plotY]]).push(["L",se,I]):ce=[["L",se,I]],L.push(U.x),Y&&(L.push(U.x),Y===2&&L.push(U.x)),$.push.apply($,ce),B=!1)}),$.xMap=L,G.graphPath=$,$}}return x.defaultOptions=m(c.defaultOptions,{legendSymbol:"lineMarker"}),u.registerSeriesType("line",x),x}),r(a,"Series/Area/AreaSeriesDefaults.js",[],function(){return{threshold:0,legendSymbol:"areaMarker"}}),r(a,"Series/Area/AreaSeries.js",[a["Series/Area/AreaSeriesDefaults.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(c,u,h){let{seriesTypes:{line:p}}=u,{extend:m,merge:v,objectEach:x,pick:_}=h;class T extends p{drawGraph(){this.areaPath=[],super.drawGraph.apply(this);let{areaPath:C,options:G}=this;[this,...this.zones].forEach((ne,$)=>{let L={},B=ne.fillColor||G.fillColor,Y=ne.area,X=Y?"animate":"attr";Y?(Y.endX=this.preventGraphAnimation?null:C.xMap,Y.animate({d:C})):(L.zIndex=0,(Y=ne.area=this.chart.renderer.path(C).addClass("highcharts-area"+($?` highcharts-zone-area-${$-1} `:" ")+($&&ne.className||"")).add(this.group)).isArea=!0),this.chart.styledMode||(L.fill=B||ne.color||this.color,L["fill-opacity"]=B?1:G.fillOpacity??.75,Y.css({pointerEvents:this.stickyTracking?"none":"auto"})),Y[X](L),Y.startX=C.xMap,Y.shiftUnit=G.step?2:1})}getGraphPath(C){let G,ne,$,L=p.prototype.getGraphPath,B=this.options,Y=B.stacking,X=this.yAxis,U=[],Z=[],ce=this.index,se=X.stacking.stacks[this.stackKey],I=B.threshold,H=Math.round(X.getThreshold(B.threshold)),Q=_(B.connectNulls,Y==="percent"),F=function(oe,A,ue){let me=C[oe],g=Y&&se[me.x].points[ce],D=me[ue+"Null"]||0,j=me[ue+"Cliff"]||0,K,te,O=!0;j||D?(K=(D?g[0]:g[1])+j,te=g[0]+j,O=!!D):!Y&&C[A]&&C[A].isNull&&(K=te=I),K!==void 0&&(Z.push({plotX:G,plotY:K===null?H:X.getThreshold(K),isNull:O,isCliff:!0}),U.push({plotX:G,plotY:te===null?H:X.getThreshold(te),doCurve:!1}))};C=C||this.points,Y&&(C=this.getStackPoints(C));for(let oe=0,A=C.length;oe<A;++oe)Y||(C[oe].leftCliff=C[oe].rightCliff=C[oe].leftNull=C[oe].rightNull=void 0),ne=C[oe].isNull,G=_(C[oe].rectPlotX,C[oe].plotX),$=Y?_(C[oe].yBottom,H):H,ne&&!Q||(Q||F(oe,oe-1,"left"),ne&&!Y&&Q||(Z.push(C[oe]),U.push({x:oe,plotX:G,plotY:$})),Q||F(oe,oe+1,"right"));let E=L.call(this,Z,!0,!0);U.reversed=!0;let M=L.call(this,U,!0,!0),R=M[0];R&&R[0]==="M"&&(M[0]=["L",R[1],R[2]]);let V=E.concat(M);V.length&&V.push(["Z"]);let ae=L.call(this,Z,!1,Q);return this.chart.series.length>1&&Y&&Z.some(oe=>oe.isCliff)&&(V.hasStackedCliffs=ae.hasStackedCliffs=!0),V.xMap=E.xMap,this.areaPath=V,ae}getStackPoints(C){let G=this,ne=[],$=[],L=this.xAxis,B=this.yAxis,Y=B.stacking.stacks[this.stackKey],X={},U=B.series,Z=U.length,ce=B.options.reversedStacks?1:-1,se=U.indexOf(G);if(C=C||this.points,this.options.stacking){for(let H=0;H<C.length;H++)C[H].leftNull=C[H].rightNull=void 0,X[C[H].x]=C[H];x(Y,function(H,Q){H.total!==null&&$.push(Q)}),$.sort(function(H,Q){return H-Q});let I=U.map(H=>H.visible);$.forEach(function(H,Q){let F=0,E,M;if(X[H]&&!X[H].isNull)ne.push(X[H]),[-1,1].forEach(function(R){let V=R===1?"rightNull":"leftNull",ae=Y[$[Q+R]],oe=0;if(ae){let A=se;for(;A>=0&&A<Z;){let ue=U[A].index;!(E=ae.points[ue])&&(ue===G.index?X[H][V]=!0:I[A]&&(M=Y[H].points[ue])&&(oe-=M[1]-M[0])),A+=ce}}X[H][R===1?"rightCliff":"leftCliff"]=oe});else{let R=se;for(;R>=0&&R<Z;){let V=U[R].index;if(E=Y[H].points[V]){F=E[1];break}R+=ce}F=_(F,0),F=B.translate(F,0,1,0,1),ne.push({isNull:!0,plotX:L.translate(H,0,0,0,1),x:H,plotY:F,yBottom:F})}})}return ne}}return T.defaultOptions=v(p.defaultOptions,c),m(T.prototype,{singleStacks:!1}),u.registerSeriesType("area",T),T}),r(a,"Series/Spline/SplineSeries.js",[a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(c,u){let{line:h}=c.seriesTypes,{merge:p,pick:m}=u;class v extends h{getPointSpline(_,T,k){let C,G,ne,$,L=T.plotX||0,B=T.plotY||0,Y=_[k-1],X=_[k+1];function U(ce){return ce&&!ce.isNull&&ce.doCurve!==!1&&!T.isCliff}if(U(Y)&&U(X)){let ce=Y.plotX||0,se=Y.plotY||0,I=X.plotX||0,H=X.plotY||0,Q=0;C=(1.5*L+ce)/2.5,G=(1.5*B+se)/2.5,ne=(1.5*L+I)/2.5,$=(1.5*B+H)/2.5,ne!==C&&(Q=($-G)*(ne-L)/(ne-C)+B-$),G+=Q,$+=Q,G>se&&G>B?(G=Math.max(se,B),$=2*B-G):G<se&&G<B&&(G=Math.min(se,B),$=2*B-G),$>H&&$>B?($=Math.max(H,B),G=2*B-$):$<H&&$<B&&($=Math.min(H,B),G=2*B-$),T.rightContX=ne,T.rightContY=$,T.controlPoints={low:[C,G],high:[ne,$]}}let Z=["C",m(Y.rightContX,Y.plotX,0),m(Y.rightContY,Y.plotY,0),m(C,L,0),m(G,B,0),L,B];return Y.rightContX=Y.rightContY=void 0,Z}}return v.defaultOptions=p(h.defaultOptions),c.registerSeriesType("spline",v),v}),r(a,"Series/AreaSpline/AreaSplineSeries.js",[a["Series/Spline/SplineSeries.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(c,u,h){let{area:p,area:{prototype:m}}=u.seriesTypes,{extend:v,merge:x}=h;class _ extends c{}return _.defaultOptions=x(c.defaultOptions,p.defaultOptions),v(_.prototype,{getGraphPath:m.getGraphPath,getStackPoints:m.getStackPoints,drawGraph:m.drawGraph}),u.registerSeriesType("areaspline",_),_}),r(a,"Series/Column/ColumnSeriesDefaults.js",[],function(){return{borderRadius:3,centerInCategory:!1,groupPadding:.2,marker:null,pointPadding:.1,minPointLength:0,cropThreshold:50,pointRange:null,states:{hover:{halo:!1,brightness:.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"}}),r(a,"Series/Column/ColumnSeries.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Color/Color.js"],a["Series/Column/ColumnSeriesDefaults.js"],a["Core/Globals.js"],a["Core/Series/Series.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(c,u,h,p,m,v,x){let{animObject:_}=c,{parse:T}=u,{noop:k}=p,{clamp:C,crisp:G,defined:ne,extend:$,fireEvent:L,isArray:B,isNumber:Y,merge:X,pick:U,objectEach:Z}=x;class ce extends m{animate(I){let H,Q,F=this,E=this.yAxis,M=E.pos,R=E.reversed,V=F.options,{clipOffset:ae,inverted:oe}=this.chart,A={},ue=oe?"translateX":"translateY";I&&ae?(A.scaleY=.001,Q=C(E.toPixels(V.threshold),M,M+E.len),oe?(Q+=R?-Math.floor(ae[0]):Math.ceil(ae[2]),A.translateX=Q-E.len):(Q+=R?Math.ceil(ae[0]):-Math.floor(ae[2]),A.translateY=Q),F.clipBox&&F.setClip(),F.group.attr(A)):(H=Number(F.group.attr(ue)),F.group.animate({scaleY:1},$(_(F.options.animation),{step:function(me,g){F.group&&(A[ue]=H+g.pos*(M-H),F.group.attr(A))}})))}init(I,H){super.init.apply(this,arguments);let Q=this;(I=Q.chart).hasRendered&&I.series.forEach(function(F){F.type===Q.type&&(F.isDirty=!0)})}getColumnMetrics(){var D,j;let I=this,H=I.options,Q=I.xAxis,F=I.yAxis,E=Q.options.reversedStacks,M=Q.reversed&&!E||!Q.reversed&&E,R={},V,ae=0;H.grouping===!1?ae=1:I.chart.series.forEach(function(K){let te,O=K.yAxis,z=K.options;K.type===I.type&&K.reserveSpace()&&F.len===O.len&&F.pos===O.pos&&(z.stacking&&z.stacking!=="group"?(R[V=K.stackKey]===void 0&&(R[V]=ae++),te=R[V]):z.grouping!==!1&&(te=ae++),K.columnIndex=te)});let oe=Math.min(Math.abs(Q.transA)*(!((D=Q.brokenAxis)!=null&&D.hasBreaks)&&((j=Q.ordinal)==null?void 0:j.slope)||H.pointRange||Q.closestPointRange||Q.tickInterval||1),Q.len),A=oe*H.groupPadding,ue=(oe-2*A)/(ae||1),me=Math.min(H.maxPointWidth||Q.len,U(H.pointWidth,ue*(1-2*H.pointPadding))),g=(I.columnIndex||0)+(M?1:0);return I.columnMetrics={width:me,offset:(ue-me)/2+(A+g*ue-oe/2)*(M?-1:1),paddedWidth:ue,columnCount:ae},I.columnMetrics}crispCol(I,H,Q,F){let E=this.borderWidth,M=this.chart.inverted;return F=G(H+F,E,M)-(H=G(H,E,M)),this.options.crisp&&(Q=G(I+Q,E)-(I=G(I,E))),{x:I,y:H,width:Q,height:F}}adjustForMissingColumns(I,H,Q,F){var E;if(!Q.isNull&&F.columnCount>1){let M=this.xAxis.series.filter(oe=>oe.visible).map(oe=>oe.index),R=0,V=0;Z((E=this.xAxis.stacking)==null?void 0:E.stacks,oe=>{if(typeof Q.x=="number"){let A=oe[Q.x.toString()];if(A&&B(A.points[this.index])){let ue=Object.keys(A.points).filter(me=>!me.match(",")&&A.points[me]&&A.points[me].length>1).map(parseFloat).filter(me=>M.indexOf(me)!==-1).sort((me,g)=>g-me);R=ue.indexOf(this.index),V=ue.length}}}),R=this.xAxis.reversed?V-1-R:R;let ae=(V-1)*F.paddedWidth+H;I=(Q.plotX||0)+ae/2-H-R*F.paddedWidth}return I}translate(){let I=this,H=I.chart,Q=I.options,F=I.dense=I.closestPointRange*I.xAxis.transA<2,E=I.borderWidth=U(Q.borderWidth,F?0:1),M=I.xAxis,R=I.yAxis,V=Q.threshold,ae=U(Q.minPointLength,5),oe=I.getColumnMetrics(),A=oe.width,ue=I.pointXOffset=oe.offset,me=I.dataMin,g=I.dataMax,D=I.translatedThreshold=R.getThreshold(V),j=I.barW=Math.max(A,1+2*E);Q.pointPadding&&(j=Math.ceil(j)),m.prototype.translate.apply(I),I.points.forEach(function(K){let te=U(K.yBottom,D),O=999+Math.abs(te),z=K.plotX||0,W=C(K.plotY,-O,R.len+O),de,P=Math.min(W,te),ee=Math.max(W,te)-P,J=A,le=z+ue,re=j;ae&&Math.abs(ee)<ae&&(ee=ae,de=!R.reversed&&!K.negative||R.reversed&&K.negative,Y(V)&&Y(g)&&K.y===V&&g<=V&&(R.min||0)<V&&(me!==g||(R.max||0)<=V)&&(de=!de,K.negative=!K.negative),P=Math.abs(P-D)>ae?te-ae:D-(de?ae:0)),ne(K.options.pointWidth)&&(le-=Math.round(((J=re=Math.ceil(K.options.pointWidth))-A)/2)),Q.centerInCategory&&!Q.stacking&&(le=I.adjustForMissingColumns(le,J,K,oe)),K.barX=le,K.pointWidth=J,K.tooltipPos=H.inverted?[C(R.len+R.pos-H.plotLeft-W,R.pos-H.plotLeft,R.len+R.pos-H.plotLeft),M.len+M.pos-H.plotTop-le-re/2,ee]:[M.left-H.plotLeft+le+re/2,C(W+R.pos-H.plotTop,R.pos-H.plotTop,R.len+R.pos-H.plotTop),ee],K.shapeType=I.pointClass.prototype.shapeType||"roundedRect",K.shapeArgs=I.crispCol(le,K.isNull?D:P,re,K.isNull?0:ee)}),L(this,"afterColumnTranslate")}drawGraph(){this.group[this.dense?"addClass":"removeClass"]("highcharts-dense-data")}pointAttribs(I,H){let Q=this.options,F=this.pointAttrToOptions||{},E=F.stroke||"borderColor",M=F["stroke-width"]||"borderWidth",R,V,ae,oe=I&&I.color||this.color,A=I&&I[E]||Q[E]||oe,ue=I&&I.options.dashStyle||Q.dashStyle,me=I&&I[M]||Q[M]||this[M]||0,g=U(I&&I.opacity,Q.opacity,1);I&&this.zones.length&&(V=I.getZone(),oe=I.options.color||V&&(V.color||I.nonZonedColor)||this.color,V&&(A=V.borderColor||A,ue=V.dashStyle||ue,me=V.borderWidth||me)),H&&I&&(ae=(R=X(Q.states[H],I.options.states&&I.options.states[H]||{})).brightness,oe=R.color||ae!==void 0&&T(oe).brighten(R.brightness).get()||oe,A=R[E]||A,me=R[M]||me,ue=R.dashStyle||ue,g=U(R.opacity,g));let D={fill:oe,stroke:A,"stroke-width":me,opacity:g};return ue&&(D.dashstyle=ue),D}drawPoints(I=this.points){let H,Q=this,F=this.chart,E=Q.options,M=F.renderer,R=E.animationLimit||250;I.forEach(function(V){let ae=V.plotY,oe=V.graphic,A=!!oe,ue=oe&&F.pointCount<R?"animate":"attr";Y(ae)&&V.y!==null?(H=V.shapeArgs,oe&&V.hasNewShapeType()&&(oe=oe.destroy()),Q.enabledDataSorting&&(V.startXPos=Q.xAxis.reversed?-(H&&H.width||0):Q.xAxis.width),!oe&&(V.graphic=oe=M[V.shapeType](H).add(V.group||Q.group),oe&&Q.enabledDataSorting&&F.hasRendered&&F.pointCount<R&&(oe.attr({x:V.startXPos}),A=!0,ue="animate")),oe&&A&&oe[ue](X(H)),F.styledMode||oe[ue](Q.pointAttribs(V,V.selected&&"select")).shadow(V.allowShadow!==!1&&E.shadow),oe&&(oe.addClass(V.getClassName(),!0),oe.attr({visibility:V.visible?"inherit":"hidden"}))):oe&&(V.graphic=oe.destroy())})}drawTracker(I=this.points){let H,Q=this,F=Q.chart,E=F.pointer,M=function(R){let V=E==null?void 0:E.getPointFromEvent(R);E&&V&&Q.options.enableMouseTracking&&(E.isDirectTouch=!0,V.onMouseOver(R))};I.forEach(function(R){H=B(R.dataLabels)?R.dataLabels:R.dataLabel?[R.dataLabel]:[],R.graphic&&(R.graphic.element.point=R),H.forEach(function(V){(V.div||V.element).point=R})}),Q._hasTracking||(Q.trackerGroups.forEach(function(R){Q[R]&&(Q[R].addClass("highcharts-tracker").on("mouseover",M).on("mouseout",function(V){E==null||E.onTrackerMouseOut(V)}).on("touchstart",M),!F.styledMode&&Q.options.cursor&&Q[R].css({cursor:Q.options.cursor}))}),Q._hasTracking=!0),L(this,"afterDrawTracker")}remove(){let I=this,H=I.chart;H.hasRendered&&H.series.forEach(function(Q){Q.type===I.type&&(Q.isDirty=!0)}),m.prototype.remove.apply(I,arguments)}}return ce.defaultOptions=X(m.defaultOptions,h),$(ce.prototype,{directTouch:!0,getSymbol:k,negStacks:!0,trackerGroups:["group","dataLabelsGroup"]}),v.registerSeriesType("column",ce),ce}),r(a,"Core/Series/DataLabel.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Templating.js"],a["Core/Utilities.js"]],function(c,u,h){var p;let{getDeferredAnimation:m}=c,{format:v}=u,{defined:x,extend:_,fireEvent:T,isArray:k,isString:C,merge:G,objectEach:ne,pick:$,pInt:L,splat:B}=h;return function(Y){function X(){return Q(this).some(E=>E==null?void 0:E.enabled)}function U(E,M,R,V,ae){var W;let{chart:oe,enabledDataSorting:A}=this,ue=this.isCartesian&&oe.inverted,me=E.plotX,g=E.plotY,D=R.rotation||0,j=x(me)&&x(g)&&oe.isInsidePlot(me,Math.round(g),{inverted:ue,paneCoordinates:!0,series:this}),K=D===0&&$(R.overflow,A?"none":"justify")==="justify",te=this.visible&&E.visible!==!1&&x(me)&&(E.series.forceDL||A&&!K||j||$(R.inside,!!this.options.stacking)&&V&&oe.isInsidePlot(me,ue?V.x+1:V.y+V.height-1,{inverted:ue,paneCoordinates:!0,series:this})),O=E.pos();if(te&&O){var z;let de=M.getBBox(),P=M.getBBox(void 0,0),ee={right:1,center:.5}[R.align||0]||0,J={bottom:1,middle:.5}[R.verticalAlign||0]||0;if(V=_({x:O[0],y:Math.round(O[1]),width:0,height:0},V||{}),R.alignTo==="plotEdges"&&this.isCartesian&&(V[ue?"x":"y"]=0,V[ue?"width":"height"]=((W=this.yAxis)==null?void 0:W.len)||0),_(R,{width:de.width,height:de.height}),z=V,A&&this.xAxis&&!K&&this.setDataLabelStartPos(E,M,ae,j,z),M.align(G(R,{width:P.width,height:P.height}),!1,V,!1),M.alignAttr.x+=ee*(P.width-de.width),M.alignAttr.y+=J*(P.height-de.height),M[M.placed?"animate":"attr"]({x:M.alignAttr.x+(de.width-P.width)/2,y:M.alignAttr.y+(de.height-P.height)/2,rotationOriginX:(M.width||0)/2,rotationOriginY:(M.height||0)/2}),K&&V.height>=0)this.justifyDataLabel(M,R,M.alignAttr,de,V,ae);else if($(R.crop,!0)){let{x:le,y:re}=M.alignAttr;te=oe.isInsidePlot(le,re,{paneCoordinates:!0,series:this})&&oe.isInsidePlot(le+de.width-1,re+de.height-1,{paneCoordinates:!0,series:this})}R.shape&&!D&&M[ae?"attr":"animate"]({anchorX:O[0],anchorY:O[1]})}ae&&A&&(M.placed=!1),te||A&&!K?(M.show(),M.placed=!0):(M.hide(),M.placed=!1)}function Z(){return this.plotGroup("dataLabelsGroup","data-labels",this.hasRendered?"inherit":"hidden",this.options.dataLabels.zIndex||6)}function ce(E){let M=this.hasRendered||0,R=this.initDataLabelsGroup().attr({opacity:+M});return!M&&R&&(this.visible&&R.show(),this.options.animation?R.animate({opacity:1},E):R.attr({opacity:1})),R}function se(E){var te;let M;E=E||this.points;let R=this,V=R.chart,ae=R.options,oe=V.renderer,{backgroundColor:A,plotBackgroundColor:ue}=V.options.chart,me=oe.getContrast(C(ue)&&ue||C(A)&&A||"#000000"),g=Q(R),{animation:D,defer:j}=g[0],K=j?m(V,D,R):{defer:0,duration:0};T(this,"drawDataLabels"),(te=R.hasDataLabels)!=null&&te.call(R)&&(M=this.initDataLabels(K),E.forEach(O=>{var de,P;let z=O.dataLabels||[];B(H(g,O.dlOptions||((de=O.options)==null?void 0:de.dataLabels))).forEach((ee,J)=>{let le=ee.enabled&&(O.visible||O.dataLabelOnHidden)&&(!O.isNull||O.dataLabelOnNull)&&function(Ae,Te){let Oe=Te.filter;if(Oe){let ze=Oe.operator,Ge=Ae[Oe.property],Ve=Oe.value;return ze===">"&&Ge>Ve||ze==="<"&&Ge<Ve||ze===">="&&Ge>=Ve||ze==="<="&&Ge<=Ve||ze==="=="&&Ge==Ve||ze==="==="&&Ge===Ve||ze==="!="&&Ge!=Ve||ze==="!=="&&Ge!==Ve}return!0}(O,ee),{backgroundColor:re,borderColor:ge,distance:ve,style:we={}}=ee,Ce,Me,De,be,ye={},xe=z[J],pe=!xe,Se;le&&(Me=$(ee[O.formatPrefix+"Format"],ee.format),Ce=O.getLabelConfig(),De=x(Me)?v(Me,Ce,V):(ee[O.formatPrefix+"Formatter"]||ee.formatter).call(Ce,ee),be=ee.rotation,!V.styledMode&&(we.color=$(ee.color,we.color,C(R.color)?R.color:void 0,"#000000"),we.color==="contrast"?(re!=="none"&&(Se=re),O.contrastColor=oe.getContrast(Se!=="auto"&&Se||O.color||R.color),we.color=Se||!x(ve)&&ee.inside||0>L(ve||0)||ae.stacking?O.contrastColor:me):delete O.contrastColor,ae.cursor&&(we.cursor=ae.cursor)),ye={r:ee.borderRadius||0,rotation:be,padding:ee.padding,zIndex:1},V.styledMode||(ye.fill=re==="auto"?O.color:re,ye.stroke=ge==="auto"?O.color:ge,ye["stroke-width"]=ee.borderWidth),ne(ye,(Ae,Te)=>{Ae===void 0&&delete ye[Te]})),!xe||le&&x(De)&&!!xe.div==!!ee.useHTML&&(xe.rotation&&ee.rotation||xe.rotation===ee.rotation)||(xe=void 0,pe=!0),le&&x(De)&&(xe?ye.text=De:(xe=oe.label(De,0,0,ee.shape,void 0,void 0,ee.useHTML,void 0,"data-label")).addClass(" highcharts-data-label-color-"+O.colorIndex+" "+(ee.className||"")+(ee.useHTML?" highcharts-tracker":"")),xe&&(xe.options=ee,xe.attr(ye),V.styledMode?we.width&&xe.css({width:we.width,textOverflow:we.textOverflow}):xe.css(we).shadow(ee.shadow),T(xe,"beforeAddingDataLabel",{labelOptions:ee,point:O}),xe.added||xe.add(M),R.alignDataLabel(O,xe,ee,void 0,pe),xe.isActive=!0,z[J]&&z[J]!==xe&&z[J].destroy(),z[J]=xe))});let W=z.length;for(;W--;)z[W]&&z[W].isActive?z[W].isActive=!1:((P=z[W])==null||P.destroy(),z.splice(W,1));O.dataLabel=z[0],O.dataLabels=z})),T(this,"afterDrawDataLabels")}function I(E,M,R,V,ae,oe){let A=this.chart,ue=M.align,me=M.verticalAlign,g=E.box?0:E.padding||0,D=A.inverted?this.yAxis:this.xAxis,j=D?D.left-A.plotLeft:0,K=A.inverted?this.xAxis:this.yAxis,te=K?K.top-A.plotTop:0,{x:O=0,y:z=0}=M,W,de;return(W=(R.x||0)+g+j)<0&&(ue==="right"&&O>=0?(M.align="left",M.inside=!0):O-=W,de=!0),(W=(R.x||0)+V.width-g+j)>A.plotWidth&&(ue==="left"&&O<=0?(M.align="right",M.inside=!0):O+=A.plotWidth-W,de=!0),(W=R.y+g+te)<0&&(me==="bottom"&&z>=0?(M.verticalAlign="top",M.inside=!0):z-=W,de=!0),(W=(R.y||0)+V.height-g+te)>A.plotHeight&&(me==="top"&&z<=0?(M.verticalAlign="bottom",M.inside=!0):z+=A.plotHeight-W,de=!0),de&&(M.x=O,M.y=z,E.placed=!oe,E.align(M,void 0,ae)),de}function H(E,M){let R=[],V;if(k(E)&&!k(M))R=E.map(function(ae){return G(ae,M)});else if(k(M)&&!k(E))R=M.map(function(ae){return G(E,ae)});else if(k(E)||k(M)){if(k(E)&&k(M))for(V=Math.max(E.length,M.length);V--;)R[V]=G(E[V],M[V])}else R=G(E,M);return R}function Q(E){var R,V;let M=E.chart.options.plotOptions;return B(H(H((R=M==null?void 0:M.series)==null?void 0:R.dataLabels,(V=M==null?void 0:M[E.type])==null?void 0:V.dataLabels),E.options.dataLabels))}function F(E,M,R,V,ae){let oe=this.chart,A=oe.inverted,ue=this.xAxis,me=ue.reversed,g=((A?M.height:M.width)||0)/2,D=E.pointWidth,j=D?D/2:0;M.startXPos=A?ae.x:me?-g-j:ue.width-g+j,M.startYPos=A?me?this.yAxis.height-g+j:-g-j:ae.y,V?M.visibility==="hidden"&&(M.show(),M.attr({opacity:0}).animate({opacity:1})):M.attr({opacity:1}).animate({opacity:0},void 0,M.hide),oe.hasRendered&&(R&&M.attr({x:M.startXPos,y:M.startYPos}),M.placed=!0)}Y.compose=function(E){let M=E.prototype;M.initDataLabels||(M.initDataLabels=ce,M.initDataLabelsGroup=Z,M.alignDataLabel=U,M.drawDataLabels=se,M.justifyDataLabel=I,M.setDataLabelStartPos=F,M.hasDataLabels=X)}}(p||(p={})),p}),r(a,"Series/Column/ColumnDataLabel.js",[a["Core/Series/DataLabel.js"],a["Core/Globals.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(c,u,h,p){var m;let{composed:v}=u,{series:x}=h,{merge:_,pick:T,pushUnique:k}=p;return function(C){function G(ne,$,L,B,Y){let X=this.chart.inverted,U=ne.series,Z=(U.xAxis?U.xAxis.len:this.chart.plotSizeX)||0,ce=(U.yAxis?U.yAxis.len:this.chart.plotSizeY)||0,se=ne.dlBox||ne.shapeArgs,I=T(ne.below,ne.plotY>T(this.translatedThreshold,ce)),H=T(L.inside,!!this.options.stacking);if(se){if(B=_(se),!(L.overflow==="allow"&&L.crop===!1)){B.y<0&&(B.height+=B.y,B.y=0);let Q=B.y+B.height-ce;Q>0&&Q<B.height-1&&(B.height-=Q)}X&&(B={x:ce-B.y-B.height,y:Z-B.x-B.width,width:B.height,height:B.width}),H||(X?(B.x+=I?0:B.width,B.width=0):(B.y+=I?B.height:0,B.height=0))}L.align=T(L.align,!X||H?"center":I?"right":"left"),L.verticalAlign=T(L.verticalAlign,X||H?"middle":I?"top":"bottom"),x.prototype.alignDataLabel.call(this,ne,$,L,B,Y),L.inside&&ne.contrastColor&&$.css({color:ne.contrastColor})}C.compose=function(ne){c.compose(x),k(v,"ColumnDataLabel")&&(ne.prototype.alignDataLabel=G)}}(m||(m={})),m}),r(a,"Series/Bar/BarSeries.js",[a["Series/Column/ColumnSeries.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(c,u,h){let{extend:p,merge:m}=h;class v extends c{}return v.defaultOptions=m(c.defaultOptions,{}),p(v.prototype,{inverted:!0}),u.registerSeriesType("bar",v),v}),r(a,"Series/Scatter/ScatterSeriesDefaults.js",[],function(){return{lineWidth:0,findNearestPointBy:"xy",jitter:{x:0,y:0},marker:{enabled:!0},tooltip:{headerFormat:'<span style="color:{point.color}">●</span> <span style="font-size: 0.8em"> {series.name}</span><br/>',pointFormat:"x: <b>{point.x}</b><br/>y: <b>{point.y}</b><br/>"}}}),r(a,"Series/Scatter/ScatterSeries.js",[a["Series/Scatter/ScatterSeriesDefaults.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(c,u,h){let{column:p,line:m}=u.seriesTypes,{addEvent:v,extend:x,merge:_}=h;class T extends m{applyJitter(){let C=this,G=this.options.jitter,ne=this.points.length;G&&this.points.forEach(function($,L){["x","y"].forEach(function(B,Y){if(G[B]&&!$.isNull){let X=`plot${B.toUpperCase()}`,U=C[`${B}Axis`],Z=G[B]*U.transA;if(U&&!U.logarithmic){let ce=Math.max(0,($[X]||0)-Z),se=Math.min(U.len,($[X]||0)+Z);$[X]=ce+(se-ce)*function(I){let H=1e4*Math.sin(I);return H-Math.floor(H)}(L+Y*ne),B==="x"&&($.clientX=$.plotX)}}})})}drawGraph(){this.options.lineWidth?super.drawGraph():this.graph&&(this.graph=this.graph.destroy())}}return T.defaultOptions=_(m.defaultOptions,c),x(T.prototype,{drawTracker:p.prototype.drawTracker,sorted:!1,requireSorting:!1,noSharedTooltip:!0,trackerGroups:["group","markerGroup","dataLabelsGroup"]}),v(T,"afterTranslate",function(){this.applyJitter()}),u.registerSeriesType("scatter",T),T}),r(a,"Series/CenteredUtilities.js",[a["Core/Globals.js"],a["Core/Series/Series.js"],a["Core/Utilities.js"]],function(c,u,h){var p,m;let{deg2rad:v}=c,{fireEvent:x,isNumber:_,pick:T,relativeLength:k}=h;return(m=p||(p={})).getCenter=function(){let C=this.options,G=this.chart,ne=2*(C.slicedOffset||0),$=G.plotWidth-2*ne,L=G.plotHeight-2*ne,B=C.center,Y=Math.min($,L),X=C.thickness,U,Z=C.size,ce=C.innerSize||0,se,I;typeof Z=="string"&&(Z=parseFloat(Z)),typeof ce=="string"&&(ce=parseFloat(ce));let H=[T(B[0],"50%"),T(B[1],"50%"),T(Z&&Z<0?void 0:C.size,"100%"),T(ce&&ce<0?void 0:C.innerSize||0,"0%")];for(!G.angular||this instanceof u||(H[3]=0),se=0;se<4;++se)I=H[se],U=se<2||se===2&&/%$/.test(I),H[se]=k(I,[$,L,Y,H[2]][se])+(U?ne:0);return H[3]>H[2]&&(H[3]=H[2]),_(X)&&2*X<H[2]&&X>0&&(H[3]=H[2]-2*X),x(this,"afterGetCenter",{positions:H}),H},m.getStartAndEndRadians=function(C,G){let ne=_(C)?C:0,$=_(G)&&G>ne&&G-ne<360?G:ne+360;return{start:v*(ne+-90),end:v*($+-90)}},p}),r(a,"Series/Pie/PiePoint.js",[a["Core/Animation/AnimationUtilities.js"],a["Core/Series/Point.js"],a["Core/Utilities.js"]],function(c,u,h){let{setAnimation:p}=c,{addEvent:m,defined:v,extend:x,isNumber:_,pick:T,relativeLength:k}=h;class C extends u{getConnectorPath(ne){let $=ne.dataLabelPosition,L=ne.options||{},B=L.connectorShape,Y=this.connectorShapes[B]||B;return $&&Y.call(this,{...$.computed,alignment:$.alignment},$.connectorPosition,L)||[]}getTranslate(){return this.sliced&&this.slicedTranslation||{translateX:0,translateY:0}}haloPath(ne){let $=this.shapeArgs;return this.sliced||!this.visible?[]:this.series.chart.renderer.symbols.arc($.x,$.y,$.r+ne,$.r+ne,{innerR:$.r-1,start:$.start,end:$.end,borderRadius:$.borderRadius})}constructor(ne,$,L){super(ne,$,L),this.half=0,this.name??(this.name="Slice");let B=Y=>{this.slice(Y.type==="select")};m(this,"select",B),m(this,"unselect",B)}isValid(){return _(this.y)&&this.y>=0}setVisible(ne,$=!0){ne!==this.visible&&this.update({visible:ne??!this.visible},$,void 0,!1)}slice(ne,$,L){let B=this.series;p(L,B.chart),$=T($,!0),this.sliced=this.options.sliced=ne=v(ne)?ne:!this.sliced,B.options.data[B.data.indexOf(this)]=this.options,this.graphic&&this.graphic.animate(this.getTranslate())}}return x(C.prototype,{connectorShapes:{fixedOffset:function(G,ne,$){let L=ne.breakAt,B=ne.touchingSliceAt,Y=$.softConnector?["C",G.x+(G.alignment==="left"?-5:5),G.y,2*L.x-B.x,2*L.y-B.y,L.x,L.y]:["L",L.x,L.y];return[["M",G.x,G.y],Y,["L",B.x,B.y]]},straight:function(G,ne){let $=ne.touchingSliceAt;return[["M",G.x,G.y],["L",$.x,$.y]]},crookedLine:function(G,ne,$){let{breakAt:L,touchingSliceAt:B}=ne,{series:Y}=this,[X,U,Z]=Y.center,ce=Z/2,{plotLeft:se,plotWidth:I}=Y.chart,H=G.alignment==="left",{x:Q,y:F}=G,E=L.x;if($.crookDistance){let R=k($.crookDistance,1);E=H?X+ce+(I+se-X-ce)*(1-R):se+(X-ce)*R}else E=X+(U-F)*Math.tan((this.angle||0)-Math.PI/2);let M=[["M",Q,F]];return(H?E<=Q&&E>=L.x:E>=Q&&E<=L.x)&&M.push(["L",E,F]),M.push(["L",L.x,L.y],["L",B.x,B.y]),M}}}),C}),r(a,"Series/Pie/PieSeriesDefaults.js",[],function(){return{borderRadius:3,center:[null,null],clip:!1,colorByPoint:!0,dataLabels:{connectorPadding:5,connectorShape:"crookedLine",crookDistance:void 0,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:.1}}}}),r(a,"Series/Pie/PieSeries.js",[a["Series/CenteredUtilities.js"],a["Series/Column/ColumnSeries.js"],a["Core/Globals.js"],a["Series/Pie/PiePoint.js"],a["Series/Pie/PieSeriesDefaults.js"],a["Core/Series/Series.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Renderer/SVG/Symbols.js"],a["Core/Utilities.js"]],function(c,u,h,p,m,v,x,_,T){let{getStartAndEndRadians:k}=c,{noop:C}=h,{clamp:G,extend:ne,fireEvent:$,merge:L,pick:B}=T;class Y extends v{animate(U){let Z=this,ce=Z.points,se=Z.startAngleRad;U||ce.forEach(function(I){let H=I.graphic,Q=I.shapeArgs;H&&Q&&(H.attr({r:B(I.startR,Z.center&&Z.center[3]/2),start:se,end:se}),H.animate({r:Q.r,start:Q.start,end:Q.end},Z.options.animation))})}drawEmpty(){let U,Z,ce=this.startAngleRad,se=this.endAngleRad,I=this.options;this.total===0&&this.center?(U=this.center[0],Z=this.center[1],this.graph||(this.graph=this.chart.renderer.arc(U,Z,this.center[1]/2,0,ce,se).addClass("highcharts-empty-series").add(this.group)),this.graph.attr({d:_.arc(U,Z,this.center[2]/2,0,{start:ce,end:se,innerR:this.center[3]/2})}),this.chart.styledMode||this.graph.attr({"stroke-width":I.borderWidth,fill:I.fillColor||"none",stroke:I.color||"#cccccc"})):this.graph&&(this.graph=this.graph.destroy())}drawPoints(){let U=this.chart.renderer;this.points.forEach(function(Z){Z.graphic&&Z.hasNewShapeType()&&(Z.graphic=Z.graphic.destroy()),Z.graphic||(Z.graphic=U[Z.shapeType](Z.shapeArgs).add(Z.series.group),Z.delayedRendering=!0)})}generatePoints(){super.generatePoints(),this.updateTotals()}getX(U,Z,ce,se){let I=this.center,H=this.radii?this.radii[ce.index]||0:I[2]/2,Q=se.dataLabelPosition,F=(Q==null?void 0:Q.distance)||0,E=Math.asin(G((U-I[1])/(H+F),-1,1));return I[0]+Math.cos(E)*(H+F)*(Z?-1:1)+(F>0?(Z?-1:1)*(se.padding||0):0)}hasData(){return!!this.processedXData.length}redrawPoints(){let U,Z,ce,se,I=this,H=I.chart;this.drawEmpty(),I.group&&!H.styledMode&&I.group.shadow(I.options.shadow),I.points.forEach(function(Q){let F={};Z=Q.graphic,!Q.isNull&&Z?(se=Q.shapeArgs,U=Q.getTranslate(),H.styledMode||(ce=I.pointAttribs(Q,Q.selected&&"select")),Q.delayedRendering?(Z.setRadialReference(I.center).attr(se).attr(U),H.styledMode||Z.attr(ce).attr({"stroke-linejoin":"round"}),Q.delayedRendering=!1):(Z.setRadialReference(I.center),H.styledMode||L(!0,F,ce),L(!0,F,se,U),Z.animate(F)),Z.attr({visibility:Q.visible?"inherit":"hidden"}),Z.addClass(Q.getClassName(),!0)):Z&&(Q.graphic=Z.destroy())})}sortByAngle(U,Z){U.sort(function(ce,se){return ce.angle!==void 0&&(se.angle-ce.angle)*Z})}translate(U){$(this,"translate"),this.generatePoints();let Z=this.options,ce=Z.slicedOffset,se=k(Z.startAngle,Z.endAngle),I=this.startAngleRad=se.start,H=(this.endAngleRad=se.end)-I,Q=this.points,F=Z.ignoreHiddenPoint,E=Q.length,M,R,V,ae,oe,A,ue,me=0;for(U||(this.center=U=this.getCenter()),A=0;A<E;A++){ue=Q[A],M=I+me*H,ue.isValid()&&(!F||ue.visible)&&(me+=ue.percentage/100),R=I+me*H;let g={x:U[0],y:U[1],r:U[2]/2,innerR:U[3]/2,start:Math.round(1e3*M)/1e3,end:Math.round(1e3*R)/1e3};ue.shapeType="arc",ue.shapeArgs=g,(V=(R+M)/2)>1.5*Math.PI?V-=2*Math.PI:V<-Math.PI/2&&(V+=2*Math.PI),ue.slicedTranslation={translateX:Math.round(Math.cos(V)*ce),translateY:Math.round(Math.sin(V)*ce)},ae=Math.cos(V)*U[2]/2,oe=Math.sin(V)*U[2]/2,ue.tooltipPos=[U[0]+.7*ae,U[1]+.7*oe],ue.half=V<-Math.PI/2||V>Math.PI/2?1:0,ue.angle=V}$(this,"afterTranslate")}updateTotals(){let U=this.points,Z=U.length,ce=this.options.ignoreHiddenPoint,se,I,H=0;for(se=0;se<Z;se++)(I=U[se]).isValid()&&(!ce||I.visible)&&(H+=I.y);for(se=0,this.total=H;se<Z;se++)(I=U[se]).percentage=H>0&&(I.visible||!ce)?I.y/H*100:0,I.total=H}}return Y.defaultOptions=L(v.defaultOptions,m),ne(Y.prototype,{axisTypes:[],directTouch:!0,drawGraph:void 0,drawTracker:u.prototype.drawTracker,getCenter:c.getCenter,getSymbol:C,invertible:!1,isCartesian:!1,noSharedTooltip:!0,pointAttribs:u.prototype.pointAttribs,pointClass:p,requireSorting:!1,searchPoint:C,trackerGroups:["group","dataLabelsGroup"]}),x.registerSeriesType("pie",Y),Y}),r(a,"Series/Pie/PieDataLabel.js",[a["Core/Series/DataLabel.js"],a["Core/Globals.js"],a["Core/Renderer/RendererUtilities.js"],a["Core/Series/SeriesRegistry.js"],a["Core/Utilities.js"]],function(c,u,h,p,m){var v;let{composed:x,noop:_}=u,{distribute:T}=h,{series:k}=p,{arrayMax:C,clamp:G,defined:ne,pick:$,pushUnique:L,relativeLength:B}=m;return function(Y){let X={radialDistributionY:function(I,H){var Q;return(((Q=H.dataLabelPosition)==null?void 0:Q.top)||0)+I.distributeBox.pos},radialDistributionX:function(I,H,Q,F,E){let M=E.dataLabelPosition;return I.getX(Q<((M==null?void 0:M.top)||0)+2||Q>((M==null?void 0:M.bottom)||0)-2?F:Q,H.half,H,E)},justify:function(I,H,Q,F){var E;return F[0]+(I.half?-1:1)*(Q+(((E=H.dataLabelPosition)==null?void 0:E.distance)||0))},alignToPlotEdges:function(I,H,Q,F){let E=I.getBBox().width;return H?E+F:Q-E-F},alignToConnectors:function(I,H,Q,F){let E=0,M;return I.forEach(function(R){(M=R.dataLabel.getBBox().width)>E&&(E=M)}),H?E+F:Q-E-F}};function U(I,H){let{center:Q,options:F}=this,E=Q[2]/2,M=I.angle||0,R=Math.cos(M),V=Math.sin(M),ae=Q[0]+R*E,oe=Q[1]+V*E,A=Math.min((F.slicedOffset||0)+(F.borderWidth||0),H/5);return{natural:{x:ae+R*H,y:oe+V*H},computed:{},alignment:H<0?"center":I.half?"right":"left",connectorPosition:{breakAt:{x:ae+R*A,y:oe+V*A},touchingSliceAt:{x:ae,y:oe}},distance:H}}function Z(){var te;let I=this,H=I.points,Q=I.chart,F=Q.plotWidth,E=Q.plotHeight,M=Q.plotLeft,R=Math.round(Q.chartWidth/3),V=I.center,ae=V[2]/2,oe=V[1],A=[[],[]],ue=[0,0,0,0],me=I.dataLabelPositioners,g,D,j,K=0;I.visible&&((te=I.hasDataLabels)!=null&&te.call(I))&&(H.forEach(O=>{(O.dataLabels||[]).forEach(z=>{z.shortened&&(z.attr({width:"auto"}).css({width:"auto",textOverflow:"clip"}),z.shortened=!1)})}),k.prototype.drawDataLabels.apply(I),H.forEach(O=>{(O.dataLabels||[]).forEach((z,W)=>{var J;let de=V[2]/2,P=z.options,ee=B((P==null?void 0:P.distance)||0,de);W===0&&A[O.half].push(O),!ne((J=P==null?void 0:P.style)==null?void 0:J.width)&&z.getBBox().width>R&&(z.css({width:Math.round(.7*R)+"px"}),z.shortened=!0),z.dataLabelPosition=this.getDataLabelPosition(O,ee),K=Math.max(K,ee)})}),A.forEach((O,z)=>{let W=O.length,de=[],P,ee,J=0,le;W&&(I.sortByAngle(O,z-.5),K>0&&(P=Math.max(0,oe-ae-K),ee=Math.min(oe+ae+K,Q.plotHeight),O.forEach(re=>{(re.dataLabels||[]).forEach(ge=>{var we;let ve=ge.dataLabelPosition;ve&&ve.distance>0&&(ve.top=Math.max(0,oe-ae-ve.distance),ve.bottom=Math.min(oe+ae+ve.distance,Q.plotHeight),J=ge.getBBox().height||21,ge.lineHeight=Q.renderer.fontMetrics(ge.text||ge).h+2*ge.padding,re.distributeBox={target:(((we=ge.dataLabelPosition)==null?void 0:we.natural.y)||0)-ve.top+ge.lineHeight/2,size:J,rank:re.y},de.push(re.distributeBox))})}),T(de,le=ee+J-P,le/5)),O.forEach(re=>{(re.dataLabels||[]).forEach(ge=>{let ve=ge.options||{},we=re.distributeBox,Ce=ge.dataLabelPosition,Me=(Ce==null?void 0:Ce.natural.y)||0,De=ve.connectorPadding||0,be=ge.lineHeight||21,ye=(be-ge.getBBox().height)/2,xe=0,pe=Me,Se="inherit";if(Ce){if(de&&ne(we)&&Ce.distance>0&&(we.pos===void 0?Se="hidden":(j=we.size,pe=me.radialDistributionY(re,ge))),ve.justify)xe=me.justify(re,ge,ae,V);else switch(ve.alignTo){case"connectors":xe=me.alignToConnectors(O,z,F,M);break;case"plotEdges":xe=me.alignToPlotEdges(ge,z,F,M);break;default:xe=me.radialDistributionX(I,re,pe-ye,Me,ge)}if(Ce.attribs={visibility:Se,align:Ce.alignment},Ce.posAttribs={x:xe+(ve.x||0)+({left:De,right:-De}[Ce.alignment]||0),y:pe+(ve.y||0)-be/2},Ce.computed.x=xe,Ce.computed.y=pe-ye,$(ve.crop,!0)){let Ae;xe-(D=ge.getBBox().width)<De&&z===1?(Ae=Math.round(D-xe+De),ue[3]=Math.max(Ae,ue[3])):xe+D>F-De&&z===0&&(Ae=Math.round(xe+D-F+De),ue[1]=Math.max(Ae,ue[1])),pe-j/2<0?ue[0]=Math.max(Math.round(-pe+j/2),ue[0]):pe+j/2>E&&(ue[2]=Math.max(Math.round(pe+j/2-E),ue[2])),Ce.sideOverflow=Ae}}})}))}),(C(ue)===0||this.verifyDataLabelOverflow(ue))&&(this.placeDataLabels(),this.points.forEach(O=>{(O.dataLabels||[]).forEach(z=>{var ee;let{connectorColor:W,connectorWidth:de=1}=z.options||{},P=z.dataLabelPosition;if(de){let J;g=z.connector,P&&P.distance>0?(J=!g,g||(z.connector=g=Q.renderer.path().addClass("highcharts-data-label-connector highcharts-color-"+O.colorIndex+(O.className?" "+O.className:"")).add(I.dataLabelsGroup)),Q.styledMode||g.attr({"stroke-width":de,stroke:W||O.color||"#666666"}),g[J?"attr":"animate"]({d:O.getConnectorPath(z)}),g.attr({visibility:(ee=P.attribs)==null?void 0:ee.visibility})):g&&(z.connector=g.destroy())}})})))}function ce(){this.points.forEach(I=>{(I.dataLabels||[]).forEach(H=>{var F;let Q=H.dataLabelPosition;Q?(Q.sideOverflow&&(H.css({width:Math.max(H.getBBox().width-Q.sideOverflow,0)+"px",textOverflow:(((F=H.options)==null?void 0:F.style)||{}).textOverflow||"ellipsis"}),H.shortened=!0),H.attr(Q.attribs),H[H.moved?"animate":"attr"](Q.posAttribs),H.moved=!0):H&&H.attr({y:-9999})}),delete I.distributeBox},this)}function se(I){let H=this.center,Q=this.options,F=Q.center,E=Q.minSize||80,M=E,R=Q.size!==null;return!R&&(F[0]!==null?M=Math.max(H[2]-Math.max(I[1],I[3]),E):(M=Math.max(H[2]-I[1]-I[3],E),H[0]+=(I[3]-I[1])/2),F[1]!==null?M=G(M,E,H[2]-Math.max(I[0],I[2])):(M=G(M,E,H[2]-I[0]-I[2]),H[1]+=(I[0]-I[2])/2),M<H[2]?(H[2]=M,H[3]=Math.min(Q.thickness?Math.max(0,M-2*Q.thickness):Math.max(0,B(Q.innerSize||0,M)),M),this.translate(H),this.drawDataLabels&&this.drawDataLabels()):R=!0),R}Y.compose=function(I){if(c.compose(k),L(x,"PieDataLabel")){let H=I.prototype;H.dataLabelPositioners=X,H.alignDataLabel=_,H.drawDataLabels=Z,H.getDataLabelPosition=U,H.placeDataLabels=ce,H.verifyDataLabelOverflow=se}}}(v||(v={})),v}),r(a,"Core/Geometry/GeometryUtilities.js",[],function(){var c,u;return(u=c||(c={})).getCenterOfPoints=function(h){let p=h.reduce((m,v)=>(m.x+=v.x,m.y+=v.y,m),{x:0,y:0});return{x:p.x/h.length,y:p.y/h.length}},u.getDistanceBetweenPoints=function(h,p){return Math.sqrt(Math.pow(p.x-h.x,2)+Math.pow(p.y-h.y,2))},u.getAngleBetweenPoints=function(h,p){return Math.atan2(p.x-h.x,p.y-h.y)},u.pointInPolygon=function({x:h,y:p},m){let v=m.length,x,_,T=!1;for(x=0,_=v-1;x<v;_=x++){let[k,C]=m[x],[G,ne]=m[_];C>p!=ne>p&&h<(G-k)*(p-C)/(ne-C)+k&&(T=!T)}return T},c}),r(a,"Extensions/OverlappingDataLabels.js",[a["Core/Geometry/GeometryUtilities.js"],a["Core/Utilities.js"]],function(c,u){let{pointInPolygon:h}=c,{addEvent:p,fireEvent:m,objectEach:v,pick:x}=u;function _(C){let G=C.length,ne=(ce,se)=>!(se.x>=ce.x+ce.width||se.x+se.width<=ce.x||se.y>=ce.y+ce.height||se.y+se.height<=ce.y),$=(ce,se)=>{for(let I of ce)if(h({x:I[0],y:I[1]},se))return!0;return!1},L,B,Y,X,U,Z=!1;for(let ce=0;ce<G;ce++)(L=C[ce])&&(L.oldOpacity=L.opacity,L.newOpacity=1,L.absoluteBox=function(se){var I,H;if(se&&(!se.alignAttr||se.placed)){let Q=se.box?0:se.padding||0,F=se.alignAttr||{x:se.attr("x"),y:se.attr("y")},E=se.getBBox();return se.width=E.width,se.height=E.height,{x:F.x+(((I=se.parentGroup)==null?void 0:I.translateX)||0)+Q,y:F.y+(((H=se.parentGroup)==null?void 0:H.translateY)||0)+Q,width:(se.width||0)-2*Q,height:(se.height||0)-2*Q,polygon:E==null?void 0:E.polygon}}}(L));C.sort((ce,se)=>(se.labelrank||0)-(ce.labelrank||0));for(let ce=0;ce<G;++ce){X=(B=C[ce])&&B.absoluteBox;let se=X==null?void 0:X.polygon;for(let I=ce+1;I<G;++I){U=(Y=C[I])&&Y.absoluteBox;let H=!1;if(X&&U&&B!==Y&&B.newOpacity!==0&&Y.newOpacity!==0&&B.visibility!=="hidden"&&Y.visibility!=="hidden"){let Q=U.polygon;if(se&&Q&&se!==Q?$(se,Q)&&(H=!0):ne(X,U)&&(H=!0),H){let F=B.labelrank<Y.labelrank?B:Y,E=F.text;F.newOpacity=0,E!=null&&E.element.querySelector("textPath")&&E.hide()}}}}for(let ce of C)T(ce,this)&&(Z=!0);Z&&m(this,"afterHideAllOverlappingLabels")}function T(C,G){let ne,$,L=!1;return C&&($=C.newOpacity,C.oldOpacity!==$&&(C.hasClass("highcharts-data-label")?(C[$?"removeClass":"addClass"]("highcharts-data-label-hidden"),ne=function(){G.styledMode||C.css({pointerEvents:$?"auto":"none"})},L=!0,C[C.isOld?"animate":"attr"]({opacity:$},void 0,ne),m(G,"afterHideOverlappingLabel")):C.attr({opacity:$})),C.isOld=!0),L}function k(){var ne;let C=this,G=[];for(let $ of C.labelCollectors||[])G=G.concat($());for(let $ of C.yAxis||[])$.stacking&&$.options.stackLabels&&!$.options.stackLabels.allowOverlap&&v($.stacking.stacks,L=>{v(L,B=>{B.label&&G.push(B.label)})});for(let $ of C.series||[])if($.visible&&((ne=$.hasDataLabels)!=null&&ne.call($))){let L=B=>{for(let Y of B)Y.visible&&(Y.dataLabels||[]).forEach(X=>{var Z;let U=X.options||{};X.labelrank=x(U.labelrank,Y.labelrank,(Z=Y.shapeArgs)==null?void 0:Z.height),U.allowOverlap??Number(U.distance)>0?(X.oldOpacity=X.opacity,X.newOpacity=1,T(X,C)):G.push(X)})};L($.nodes||[]),L($.points)}this.hideOverlappingLabels(G)}return{compose:function(C){let G=C.prototype;G.hideOverlappingLabels||(G.hideOverlappingLabels=_,p(C,"render",k))}}}),r(a,"Extensions/BorderRadius.js",[a["Core/Defaults.js"],a["Core/Globals.js"],a["Core/Utilities.js"]],function(c,u,h){let{defaultOptions:p}=c,{noop:m}=u,{addEvent:v,extend:x,isObject:_,merge:T,relativeLength:k}=h,C={radius:0,scope:"stack",where:void 0},G=m,ne=m;function $(U,Z,ce,se,I={}){let H=G(U,Z,ce,se,I),{innerR:Q=0,r:F=ce,start:E=0,end:M=0}=I;if(I.open||!I.borderRadius)return H;let R=M-E,V=Math.sin(R/2),ae=Math.max(Math.min(k(I.borderRadius||0,F-Q),(F-Q)/2,F*V/(1+V)),0),oe=Math.min(ae,R/Math.PI*2*Q),A=H.length-1;for(;A--;)(function(ue,me,g){let D,j,K,te=ue[me],O=ue[me+1];if(O[0]==="Z"&&(O=ue[0]),(te[0]==="M"||te[0]==="L")&&O[0]==="A"?(D=te,j=O,K=!0):te[0]==="A"&&(O[0]==="M"||O[0]==="L")&&(D=O,j=te),D&&j&&j.params){let z=j[1],W=j[5],de=j.params,{start:P,end:ee,cx:J,cy:le}=de,re=W?z-g:z+g,ge=re?Math.asin(g/re):0,ve=W?ge:-ge,we=Math.cos(ge)*re;K?(de.start=P+ve,D[1]=J+we*Math.cos(P),D[2]=le+we*Math.sin(P),ue.splice(me+1,0,["A",g,g,0,0,1,J+z*Math.cos(de.start),le+z*Math.sin(de.start)])):(de.end=ee-ve,j[6]=J+z*Math.cos(de.end),j[7]=le+z*Math.sin(de.end),ue.splice(me+1,0,["A",g,g,0,0,1,J+we*Math.cos(ee),le+we*Math.sin(ee)])),j[4]=Math.abs(de.end-de.start)<Math.PI?0:1}})(H,A,A>1?oe:ae);return H}function L(){var U,Z;if(this.options.borderRadius&&!(this.chart.is3d&&this.chart.is3d())){let{options:ce,yAxis:se}=this,I=ce.stacking==="percent",H=(Z=(U=p.plotOptions)==null?void 0:U[this.type])==null?void 0:Z.borderRadius,Q=B(ce.borderRadius,_(H)?H:{}),F=se.options.reversed;for(let E of this.points){let{shapeArgs:M}=E;if(E.shapeType==="roundedRect"&&M){let{width:R=0,height:V=0,y:ae=0}=M,oe=ae,A=V;if(Q.scope==="stack"&&E.stackTotal){let D=se.translate(I?100:E.stackTotal,!1,!0,!1,!0),j=se.translate(ce.threshold||0,!1,!0,!1,!0),K=this.crispCol(0,Math.min(D,j),0,Math.abs(D-j));oe=K.y,A=K.height}let ue=(E.negative?-1:1)*(F?-1:1)==-1,me=Q.where;!me&&this.is("waterfall")&&Math.abs((E.yBottom||0)-(this.translatedThreshold||0))>this.borderWidth&&(me="all"),me||(me="end");let g=Math.min(k(Q.radius,R),R/2,me==="all"?V/2:1/0)||0;me==="end"&&(ue&&(oe-=g),A+=g),x(M,{brBoxHeight:A,brBoxY:oe,r:g})}}}}function B(U,Z){return _(U)||(U={radius:U||0}),T(C,Z,U)}function Y(){let U=B(this.options.borderRadius);for(let Z of this.points){let ce=Z.shapeArgs;ce&&(ce.borderRadius=k(U.radius,(ce.r||0)-(ce.innerR||0)))}}function X(U,Z,ce,se,I={}){let H=ne(U,Z,ce,se,I),{r:Q=0,brBoxHeight:F=se,brBoxY:E=Z}=I,M=Z-E,R=E+F-(Z+se),V=M-Q>-.1?0:Q,ae=R-Q>-.1?0:Q,oe=Math.max(V&&M,0),A=Math.max(ae&&R,0),ue=[U+V,Z],me=[U+ce-V,Z],g=[U+ce,Z+V],D=[U+ce,Z+se-ae],j=[U+ce-ae,Z+se],K=[U+ae,Z+se],te=[U,Z+se-ae],O=[U,Z+V],z=(W,de)=>Math.sqrt(Math.pow(W,2)-Math.pow(de,2));if(oe){let W=z(V,V-oe);ue[0]-=W,me[0]+=W,g[1]=O[1]=Z+V-oe}if(se<V-oe){let W=z(V,V-oe-se);g[0]=D[0]=U+ce-V+W,j[0]=Math.min(g[0],j[0]),K[0]=Math.max(D[0],K[0]),te[0]=O[0]=U+V-W,g[1]=O[1]=Z+se}if(A){let W=z(ae,ae-A);j[0]+=W,K[0]-=W,D[1]=te[1]=Z+se-ae+A}if(se<ae-A){let W=z(ae,ae-A-se);g[0]=D[0]=U+ce-ae+W,me[0]=Math.min(g[0],me[0]),ue[0]=Math.max(D[0],ue[0]),te[0]=O[0]=U+ae-W,D[1]=te[1]=Z}return H.length=0,H.push(["M",...ue],["L",...me],["A",V,V,0,0,1,...g],["L",...D],["A",ae,ae,0,0,1,...j],["L",...K],["A",ae,ae,0,0,1,...te],["L",...O],["A",V,V,0,0,1,...ue],["Z"]),H}return{compose:function(U,Z,ce){let se=U.types.pie;if(!Z.symbolCustomAttribs.includes("borderRadius")){let I=ce.prototype.symbols;v(U,"afterColumnTranslate",L,{order:9}),v(se,"afterTranslate",Y),Z.symbolCustomAttribs.push("borderRadius","brBoxHeight","brBoxY"),G=I.arc,ne=I.roundedRect,I.arc=$,I.roundedRect=X}},optionsToObject:B}}),r(a,"Core/Responsive.js",[a["Core/Utilities.js"]],function(c){var u;let{diffObjects:h,extend:p,find:m,merge:v,pick:x,uniqueKey:_}=c;return function(T){function k(G,ne){let $=G.condition;($.callback||function(){return this.chartWidth<=x($.maxWidth,Number.MAX_VALUE)&&this.chartHeight<=x($.maxHeight,Number.MAX_VALUE)&&this.chartWidth>=x($.minWidth,0)&&this.chartHeight>=x($.minHeight,0)}).call(this)&&ne.push(G._id)}function C(G,ne){let $=this.options.responsive,L=this.currentResponsive,B=[],Y;!ne&&$&&$.rules&&$.rules.forEach(Z=>{Z._id===void 0&&(Z._id=_()),this.matchResponsiveRule(Z,B)},this);let X=v(...B.map(Z=>m(($||{}).rules||[],ce=>ce._id===Z)).map(Z=>Z&&Z.chartOptions));X.isResponsiveOptions=!0,B=B.toString()||void 0;let U=L&&L.ruleIds;B===U||(L&&(this.currentResponsive=void 0,this.updatingResponsive=!0,this.update(L.undoOptions,G,!0),this.updatingResponsive=!1),B?((Y=h(X,this.options,!0,this.collectionsWithUpdate)).isResponsiveOptions=!0,this.currentResponsive={ruleIds:B,mergedOptions:X,undoOptions:Y},this.updatingResponsive||this.update(X,G,!0)):this.currentResponsive=void 0)}T.compose=function(G){let ne=G.prototype;return ne.matchResponsiveRule||p(ne,{matchResponsiveRule:k,setResponsive:C}),G}}(u||(u={})),u}),r(a,"masters/highcharts.src.js",[a["Core/Globals.js"],a["Core/Utilities.js"],a["Core/Defaults.js"],a["Core/Animation/Fx.js"],a["Core/Animation/AnimationUtilities.js"],a["Core/Renderer/HTML/AST.js"],a["Core/Templating.js"],a["Core/Renderer/RendererRegistry.js"],a["Core/Renderer/RendererUtilities.js"],a["Core/Renderer/SVG/SVGElement.js"],a["Core/Renderer/SVG/SVGRenderer.js"],a["Core/Renderer/HTML/HTMLElement.js"],a["Core/Axis/Axis.js"],a["Core/Axis/DateTimeAxis.js"],a["Core/Axis/LogarithmicAxis.js"],a["Core/Axis/PlotLineOrBand/PlotLineOrBand.js"],a["Core/Axis/Tick.js"],a["Core/Tooltip.js"],a["Core/Series/Point.js"],a["Core/Pointer.js"],a["Core/Legend/Legend.js"],a["Core/Legend/LegendSymbol.js"],a["Core/Chart/Chart.js"],a["Extensions/ScrollablePlotArea.js"],a["Core/Axis/Stacking/StackingAxis.js"],a["Core/Axis/Stacking/StackItem.js"],a["Core/Series/Series.js"],a["Core/Series/SeriesRegistry.js"],a["Series/Column/ColumnDataLabel.js"],a["Series/Pie/PieDataLabel.js"],a["Core/Series/DataLabel.js"],a["Extensions/OverlappingDataLabels.js"],a["Extensions/BorderRadius.js"],a["Core/Responsive.js"],a["Core/Color/Color.js"],a["Core/Time.js"]],function(c,u,h,p,m,v,x,_,T,k,C,G,ne,$,L,B,Y,X,U,Z,ce,se,I,H,Q,F,E,M,R,V,ae,oe,A,ue,me,g){return c.AST=v,c.Axis=ne,c.Chart=I,c.Color=me,c.DataLabel=ae,c.Fx=p,c.HTMLElement=G,c.Legend=ce,c.LegendSymbol=se,c.OverlappingDataLabels=c.OverlappingDataLabels||oe,c.PlotLineOrBand=B,c.Point=U,c.Pointer=Z,c.RendererRegistry=_,c.Series=E,c.SeriesRegistry=M,c.StackItem=F,c.SVGElement=k,c.SVGRenderer=C,c.Templating=x,c.Tick=Y,c.Time=g,c.Tooltip=X,c.animate=m.animate,c.animObject=m.animObject,c.chart=I.chart,c.color=me.parse,c.dateFormat=x.dateFormat,c.defaultOptions=h.defaultOptions,c.distribute=T.distribute,c.format=x.format,c.getDeferredAnimation=m.getDeferredAnimation,c.getOptions=h.getOptions,c.numberFormat=x.numberFormat,c.seriesType=M.seriesType,c.setAnimation=m.setAnimation,c.setOptions=h.setOptions,c.stop=m.stop,c.time=h.defaultTime,c.timers=p.timers,A.compose(c.Series,c.SVGElement,c.SVGRenderer),R.compose(c.Series.types.column),ae.compose(c.Series),$.compose(c.Axis),G.compose(c.SVGRenderer),ce.compose(c.Chart),L.compose(c.Axis),oe.compose(c.Chart),V.compose(c.Series.types.pie),B.compose(c.Chart,c.Axis),Z.compose(c.Chart),ue.compose(c.Chart),H.compose(c.Axis,c.Chart,c.Series),Q.compose(c.Axis,c.Chart,c.Series),X.compose(c.Pointer),u.extend(c,u),c}),a["masters/highcharts.src.js"]._modules=a,a["masters/highcharts.src.js"]})}(Cb)),Cb.exports}var _L=xL();const Qm=Fd(_L);var kb={exports:{}},SL=kb.exports,I3;function wL(){return I3||(I3=1,function(t,n){(function(a,r){t.exports=r(Re)})(typeof self<"u"?self:SL,function(a){return function(r){function c(h){if(u[h])return u[h].exports;var p=u[h]={i:h,l:!1,exports:{}};return r[h].call(p.exports,p,p.exports,c),p.l=!0,p.exports}var u={};return c.m=r,c.c=u,c.d=function(h,p,m){c.o(h,p)||Object.defineProperty(h,p,{configurable:!1,enumerable:!0,get:m})},c.n=function(h){var p=h&&h.__esModule?function(){return h.default}:function(){return h};return c.d(p,"a",p),p},c.o=function(h,p){return Object.prototype.hasOwnProperty.call(h,p)},c.p="",c(c.s=0)}([function(r,c,u){function h(){return h=Object.assign?Object.assign.bind():function(L){for(var B=1;B<arguments.length;B++){var Y=arguments[B];for(var X in Y)Object.prototype.hasOwnProperty.call(Y,X)&&(L[X]=Y[X])}return L},h.apply(this,arguments)}function p(L){return _(L)||x(L)||v(L)||m()}function m(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
108
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function v(L,B){if(L){if(typeof L=="string")return T(L,B);var Y=Object.prototype.toString.call(L).slice(8,-1);return Y==="Object"&&L.constructor&&(Y=L.constructor.name),Y==="Map"||Y==="Set"?Array.from(L):Y==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Y)?T(L,B):void 0}}function x(L){if(typeof Symbol<"u"&&L[Symbol.iterator]!=null||L["@@iterator"]!=null)return Array.from(L)}function _(L){if(Array.isArray(L))return T(L)}function T(L,B){(B==null||B>L.length)&&(B=L.length);for(var Y=0,X=new Array(B);Y<B;Y++)X[Y]=L[Y];return X}function k(L){"@babel/helpers - typeof";return(k=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(B){return typeof B}:function(B){return B&&typeof Symbol=="function"&&B.constructor===Symbol&&B!==Symbol.prototype?"symbol":typeof B})(L)}Object.defineProperty(c,"__esModule",{value:!0}),u.d(c,"HighchartsReact",function(){return $});var C=u(1),G=u.n(C),ne=typeof window<"u"?C.useLayoutEffect:C.useEffect,$=Object(C.memo)(Object(C.forwardRef)(function(L,B){var Y=Object(C.useRef)(),X=Object(C.useRef)(),U=Object(C.useRef)(L.constructorType),Z=Object(C.useRef)(L.highcharts);return ne(function(){function ce(){var I=L.highcharts||(typeof window>"u"?"undefined":k(window))==="object"&&window.Highcharts,H=L.constructorType||"chart";I?I[H]?L.options?X.current=I[H](Y.current,L.options,L.callback):console.warn('The "options" property was not passed.'):console.warn('The "constructorType" property is incorrect or some required module is not imported.'):console.warn('The "highcharts" property was not passed.')}if(X.current){if(L.allowChartUpdate!==!1)if(L.constructorType!==U.current||L.highcharts!==Z.current)U.current=L.constructorType,Z.current=L.highcharts,ce();else if(!L.immutable&&X.current){var se;(se=X.current).update.apply(se,[L.options].concat(p(L.updateArgs||[!0,!0])))}else ce()}else ce()},[L.options,L.allowChartUpdate,L.updateArgs,L.containerProps,L.highcharts,L.constructorType]),ne(function(){return function(){X.current&&(X.current.destroy(),X.current=null)}},[]),Object(C.useImperativeHandle)(B,function(){return{get chart(){return X.current},container:Y}},[]),G.a.createElement("div",h({},L.containerProps,{ref:Y}))}));c.default=$},function(r,c){r.exports=a}])})}(kb)),kb.exports}var CL=wL();const kL=Fd(CL),Qd=t=>{console.log("🔍 DEBUG Raw input date string:",t);let n;try{if(t.includes(" at ")){console.log('🔍 DEBUG Detected "at" format - using special parsing logic');const C=/^(\d{1,2})\s+(\w{3})\s+at\s+(\d{1,2}):(\d{2})\s+(AM|PM)$/i,G=t.match(C);if(G){console.log("🔍 DEBUG Regex match found:",G);const[,ne,$,L,B,Y]=G;console.log("🔍 DEBUG Extracted components:",{dayStr:ne,monthStr:$,hourStr:L,minuteStr:B,ampmStr:Y});const X={Jan:0,Feb:1,Mar:2,Apr:3,May:4,Jun:5,Jul:6,Aug:7,Sep:8,Oct:9,Nov:10,Dec:11},U=parseInt(ne,10),Z=X[$];let ce=parseInt(L,10);const se=parseInt(B,10);console.log("🔍 DEBUG Parsed values (before 12h conversion):",{day:U,monthIndex:Z,hours:ce,minutes:se}),Y.toUpperCase()==="PM"&&ce!==12?ce+=12:Y.toUpperCase()==="AM"&&ce===12&&(ce=0),console.log("🔍 DEBUG Hours after 12h to 24h conversion:",ce);const I=new Date().getFullYear();console.log("🔍 DEBUG Using current year:",I),Z!==void 0&&!isNaN(U)&&!isNaN(ce)&&!isNaN(se)?(n=new Date(I,Z,U,ce,se),console.log('🔍 DEBUG Successfully created Date object for "at" format:',n)):(console.log('🔍 DEBUG Failed to parse "at" format components, falling back to direct parsing'),n=new Date(t))}else console.log('🔍 DEBUG "at" format regex did not match, falling back to direct parsing'),n=new Date(t)}else if(t.includes("T"))console.log("🔍 DEBUG Using ISO format parsing"),n=new Date(t);else if(t.includes("/"))console.log("🔍 DEBUG Using slash format parsing"),n=new Date(t);else if(t.includes("-")){const C=t.replace(/-/g,"/");console.log("🔍 DEBUG Converting dash to slash format:",t,"->",C),n=new Date(C)}else console.log("🔍 DEBUG Using direct parsing"),n=new Date(t);console.log("🔍 DEBUG Raw Date object:",n),console.log("🔍 DEBUG Raw time value:",n.getTime()),console.log("🔍 DEBUG Date toString():",n.toString()),console.log("🔍 DEBUG Date toISOString():",n.toISOString())}catch(C){return console.error("🔍 DEBUG Date parsing error:",C instanceof Error?C.message:"Unknown error"),"Date Parsing Error"}if(isNaN(n.getTime()))return console.warn("❌ Invalid date format detected:",{input:t,dateObj:n,userAgent:navigator.userAgent}),"Invalid Date";const a=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],r=["January","February","March","April","May","June","July","August","September","October","November","December"],c=n.getDay(),u=n.getDate(),h=n.getMonth(),p=n.getFullYear();let m=n.getHours();const v=n.getMinutes();if(isNaN(c)||isNaN(u)||isNaN(h)||isNaN(p)||isNaN(m)||isNaN(v))return console.warn("Date parsing returned NaN values:",{dayIndex:c,day:u,monthIndex:h,year:p,hours:m,minutes:v}),"Invalid Date";const x=a[c]||"Invalid",_=r[h]||"Invalid",T=m>=12?"PM":"AM";m=m%12,m=m||12;const k=v<10?"0"+v:v.toString();return`${x}, ${u} ${_}, ${p} ${m}:${k} ${T}`},bS=(t,n)=>{if(!t)return n.toString();const{metric_type:a}=t;switch(a){case"Rate":return n<=1?`${(n*100).toFixed(2)}%`:`${n.toFixed(2)}%`;case"Volume":case"Count":return n>=1e7?`${(n/1e7).toFixed(1)} Cr`:n>=1e5?`${(n/1e5).toFixed(1)} L`:n>=1e3?`${(n/1e3).toFixed(1)} K`:n.toLocaleString("en-IN");case"Amount":return n>=1e7?`${(n/1e7).toFixed(1)} Cr`:n>=1e5?`${(n/1e5).toFixed(1)} L`:n>=1e3?`${(n/1e3).toFixed(1)} K`:n.toLocaleString("en-IN");case"Latency":return`${n.toFixed(2)} s`;default:return n.toString()}},ml=(t,n=!1)=>{console.log("🔍 truncateText called:",{text:t,isMobile:n,textLength:t.length});const a=n?8:10;if(t.length<=a)return console.log("🔍 truncateText result (no truncation needed):",t),t;const r=t.substring(0,a)+"..";return console.log("🔍 truncateText result (truncated):",{original:t,truncated:r,maxLength:a}),r},G3=t=>t&&t.split(/[_\s]+/).map(n=>n&&n.charAt(0).toUpperCase()+n.slice(1).toLowerCase()).join(" "),hc={customDropdown:"genius-sdk__CustomDropdown-module__customDropdown___PF-Jr",dropdownTrigger:"genius-sdk__CustomDropdown-module__dropdownTrigger___oTT8t",open:"genius-sdk__CustomDropdown-module__open___ghWoC",dropdownValue:"genius-sdk__CustomDropdown-module__dropdownValue___GRfHp",dropdownArrow:"genius-sdk__CustomDropdown-module__dropdownArrow___EBas6",rotated:"genius-sdk__CustomDropdown-module__rotated___TeDYS",dropdownOptions:"genius-sdk__CustomDropdown-module__dropdownOptions___TmntB",dropdownOption:"genius-sdk__CustomDropdown-module__dropdownOption___jjWGO",selected:"genius-sdk__CustomDropdown-module__selected___E7cpP"},vS=({value:t,onChange:n,options:a,className:r=""})=>{const[c,u]=Re.useState(!1),h=Re.useRef(null),p=a.find(x=>x.value===t);Re.useEffect(()=>{const x=_=>{h.current&&!h.current.contains(_.target)&&u(!1)};return document.addEventListener("mousedown",x),()=>{document.removeEventListener("mousedown",x)}},[]);const m=x=>{n(x),u(!1)},v=x=>{x.key==="Enter"||x.key===" "?(x.preventDefault(),u(!c)):x.key==="Escape"&&u(!1)};return q.jsxs("div",{ref:h,className:`${hc.customDropdown} ${r}`,onKeyDown:v,children:[q.jsxs("div",{className:`${hc.dropdownTrigger} ${c?hc.open:""}`,onClick:()=>u(!c),role:"button",tabIndex:0,"aria-haspopup":"listbox","aria-expanded":c,children:[q.jsx("span",{className:hc.dropdownValue,children:(p==null?void 0:p.label)||"Select..."}),q.jsx("span",{className:`${hc.dropdownArrow} ${c?hc.rotated:""}`,children:q.jsx("svg",{width:"12",height:"8",viewBox:"0 0 12 8",fill:"none",children:q.jsx("path",{d:"M1 1.5L6 6.5L11 1.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})})]}),c&&q.jsx("div",{className:hc.dropdownOptions,role:"listbox",children:a.map(x=>q.jsx("div",{className:`${hc.dropdownOption} ${x.value===t?hc.selected:""}`,onClick:()=>m(x.value),role:"option","aria-selected":x.value===t,children:x.label},x.value))})]})},zt={"highchart-wrapper":"genius-sdk__Highchart-module__highchart-wrapper___sM-hD","legend-container":"genius-sdk__Highchart-module__legend-container___PF9Kl","legend-item":"genius-sdk__Highchart-module__legend-item___S61g8","legend-bullet":"genius-sdk__Highchart-module__legend-bullet___iqmNl","legend-table":"genius-sdk__Highchart-module__legend-table___sQOwt",mobile:"genius-sdk__Highchart-module__mobile___DAaPf",noBorderChart:"genius-sdk__Highchart-module__noBorderChart___4UsC9","highcharts-container":"genius-sdk__Highchart-module__highcharts-container___ygpjY","highcharts-title":"genius-sdk__Highchart-module__highcharts-title___vYLWj","highcharts-legend-item":"genius-sdk__Highchart-module__highcharts-legend-item___QKt2l","highcharts-axis-labels":"genius-sdk__Highchart-module__highcharts-axis-labels___0y1KO","highcharts-yaxis-labels":"genius-sdk__Highchart-module__highcharts-yaxis-labels___ZcIXe","highcharts-grid-line":"genius-sdk__Highchart-module__highcharts-grid-line___gITcn","highcharts-point":"genius-sdk__Highchart-module__highcharts-point___5Wqsl","highcharts-plot-background":"genius-sdk__Highchart-module__highcharts-plot-background___XvssF","custom-legend":"genius-sdk__Highchart-module__custom-legend___8txpT","custom-legend-item":"genius-sdk__Highchart-module__custom-legend-item___nUPlX","custom-legend-bullet":"genius-sdk__Highchart-module__custom-legend-bullet___3hLh2","custom-legend-text":"genius-sdk__Highchart-module__custom-legend-text___Ja4cM","custom-legend-value":"genius-sdk__Highchart-module__custom-legend-value___sMiwT","flex-row":"genius-sdk__Highchart-module__flex-row___qsVq8","volume-renderer-container":"genius-sdk__Highchart-module__volume-renderer-container___05bp2",volumeGranularitySelect:"genius-sdk__Highchart-module__volumeGranularitySelect___0a4VT",cardinalityControlContainer:"genius-sdk__Highchart-module__cardinalityControlContainer___wXwZ4","highchart-loading":"genius-sdk__Highchart-module__highchart-loading___XW7h3",spin:"genius-sdk__Highchart-module__spin___H-wRz"},V3=t=>t.includes("rate")?"Rate":t.includes("volume")?"Volume":t.includes("amount")||t.includes("ticket")?"Amount":t.includes("latency")?"Latency":"Count";Qm.setOptions({credits:{enabled:!1},colors:["#7856FF","#FEBBB2","#72BEF4","#1E90FF","#E377C2","#7FE1D8","#CB80DC","#5CB7AF","#1F77B4","#9467BD","#0F7EA0","#17BECF","#7F7F7F","#BCBD22","#A0872C","#006400","#B3596E","#4B0082","#4B6D8C"]});const TL=({granularity:t,onGranularityChange:n})=>q.jsx("div",{className:zt.cardinalityControlContainer,children:q.jsx(vS,{value:t,onChange:a=>n(a),options:[{value:"top5",label:"Top 5"},{value:"top10",label:"Top 10"}],className:""})}),AL=({text:t,maxLength:n=30,className:a="w-full"})=>t.length>n?q.jsxs("div",{className:`${zt["whitespace-pre"]} ${zt["text-ellipsis"]} ${zt["overflow-hidden"]} ${zt[a]}`,title:t,children:[t.slice(0,n),"..."]}):q.jsx("div",{className:`${zt["whitespace-pre"]} ${zt[a]}`,children:t}),EL=({item:t,isSelected:n,isHovered:a=!1,onClick:r,onMouseEnter:c,onMouseLeave:u,showValue:h=!1,maxWidth:p=200})=>{const m=n?zt["opacity-100"]:zt["opacity-60"],v=a?zt["bg-gray-100"]:"";return q.jsxs("div",{className:`${zt.flex} ${zt["items-center"]} ${zt["gap-2"]} ${zt["cursor-pointer"]} ${zt["select-none"]} ${zt["transition-all"]} ${zt["duration-200"]} ${m} ${v} ${zt["font-medium"]} ${zt["p-1"]} ${zt.rounded}`,onClick:()=>r(t),onMouseEnter:()=>c(t),onMouseLeave:u,style:{maxWidth:`${p}px`},children:[q.jsx("div",{className:`${zt["w-3"]} ${zt["h-3"]} ${zt["rounded-sm"]}`,style:{backgroundColor:t.color}}),q.jsx(AL,{text:t.name,maxLength:p/8,className:zt["flex-1"]}),h&&t.overallValue&&q.jsxs(q.Fragment,{children:[q.jsx("div",{className:`${zt["w-px"]} ${zt["h-2.5"]} ${zt["bg-gray-300"]}`}),q.jsx("div",{className:`${zt["text-xs"]} ${zt["font-medium"]} ${zt["text-gray-600"]}`,children:t.overallValue})]})]})},Tb=({legendData:t,selectedRows:n,hoveredItem:a,onItemClick:r,onItemHover:c,legendType:u,position:h,maxItems:p=10,responsive:m=!0})=>{const[v,x]=Re.useState(!1),_=m&&window.innerWidth<=768,T=v?t:t.slice(0,p),k=t.length>p,C=Re.useCallback(B=>{r(B)},[r]),G=Re.useCallback(B=>{c(B)},[c]),$=h==="top"||h==="bottom"?`${zt["flex-row"]} ${zt["flex-wrap"]}`:zt["flex-col"],L=`${zt.flex} ${$} ${zt["gap-4"]} ${zt["p-4"]}`;return u==="Table"?q.jsx("div",{className:L,children:q.jsxs("div",{className:zt["w-full"],children:[q.jsxs("table",{className:`${zt["w-full"]} ${zt["text-sm"]}`,children:[q.jsx("thead",{children:q.jsxs("tr",{className:zt["border-b"],children:[q.jsx("th",{className:`${zt["text-left"]} ${zt["p-2"]}`,children:"Series"}),q.jsx("th",{className:`${zt["text-right"]} ${zt["p-2"]}`,children:"Value"})]})}),q.jsx("tbody",{children:T.map(B=>q.jsxs("tr",{className:`${zt["cursor-pointer"]} ${zt["hover:bg-gray-50"]} ${n.includes(B.name)?zt["bg-blue-50"]:""} ${(a==null?void 0:a.name)===B.name?zt["bg-gray-100"]:""}`,onClick:()=>C(B),onMouseEnter:()=>G(B),onMouseLeave:()=>G(null),children:[q.jsx("td",{className:zt["p-2"],children:q.jsxs("div",{className:`${zt.flex} ${zt["items-center"]} ${zt["gap-2"]}`,children:[q.jsx("div",{className:`${zt["w-3"]} ${zt["h-3"]} ${zt["rounded-sm"]}`,style:{backgroundColor:B.color}}),q.jsx("span",{children:B.name})]})}),q.jsx("td",{className:`${zt["p-2"]} ${zt["text-right"]}`,children:B.overallValue||B.value||"-"})]},B.name))})]}),k&&q.jsx("button",{className:`${zt["mt-2"]} ${zt["text-blue-600"]} ${zt["hover:text-blue-800"]} ${zt["text-sm"]}`,onClick:()=>x(!v),children:v?"Show less":`+${t.length-p} more`})]})}):q.jsxs("div",{className:L,children:[T.map(B=>q.jsx(EL,{item:B,isSelected:n.length===0||n.includes(B.name),isHovered:(a==null?void 0:a.name)===B.name,onClick:C,onMouseEnter:G,onMouseLeave:()=>G(null),showValue:!0,maxWidth:_?150:200},B.name)),k&&q.jsx("button",{className:`${zt["text-blue-600"]} ${zt["hover:text-blue-800"]} ${zt["text-sm"]} ${zt["px-2"]} ${zt["py-1"]} ${zt.rounded}`,onClick:()=>x(!v),children:v?"Show less":`+${t.length-p} more`})]})},$3=(t,n)=>{const a=new Set;return t.forEach(r=>{const c=String(r[n]||"");c&&a.add(c)}),Array.from(a)},ML=t=>{switch(t){case"TOP_3":return 3;case"TOP_5":return 5;case"TOP_10":return 10;case"TOP_15":return 15;case"TOP_20":return 20;default:return 5}},DL=t=>{switch(t){case"top5":return"TOP_5";case"top10":return"TOP_10";default:return"TOP_5"}},OL=(t,n,a,r)=>{if(n.length===0)return t;const c=n[0],u=$3(t,c),h=ML(r),m=u.map(v=>{const x=t.filter(T=>String(T[c])===v),_=a.reduce((T,k)=>{const C=x.reduce((G,ne)=>G+Number(ne[k]||0),0);return T+C},0);return{groupbyValue:v,total:_}}).sort((v,x)=>x.total-v.total).slice(0,h).map(v=>v.groupbyValue);return t.filter(v=>m.includes(String(v[c])))},jL=t=>{if(t.length<2)return"auto";const n=t.map(m=>new Date(m).getTime()).sort((m,v)=>m-v),a=[];for(let m=1;m<n.length;m++)a.push(n[m]-n[m-1]);const r=a.reduce((m,v)=>m+v,0)/a.length,c=60*60*1e3,u=24*c,h=7*u,p=30*u;return r<=c*2?"hourly":r<=u*2?"daily":r<=h*2?"weekly":r<=p*2?"monthly":"yearly"},LL=(t,n)=>{const a=new Date(t);switch(n){case"hourly":return a.toLocaleString("en-US",{hour:"2-digit",minute:"2-digit"});case"daily":return a.toLocaleString("en-US",{month:"short",day:"numeric"});case"weekly":case"monthly":return a.toLocaleString("en-US",{month:"short",day:"numeric"});case"yearly":return a.getFullYear().toString();default:return Qd(t)}},F3=(t,n=!1)=>{const a=t.length,r=t[0]||"",c=/\d{1,2}:\d{2}/.test(r),u=/\d{1,2}\.\s*[A-Za-z]{3}/.test(r);let h;return n?a>20?h=6:a>12?h=4:a<=6?h=1:h=c||u?3:2:a>20?h=3:a>12?h=2:a<=8?h=1:h=c||u?2:1,console.log("📊 Intelligent Step Calculation:",{dataPointCount:a,sampleCategory:r,isDateHourPattern:c,isMonthDayPattern:u,isMobile:n,calculatedStep:h,categories:t.slice(0,5)}),h},RL=(t,n,a,r,c)=>{const u=Qm.getOptions().colors||[],h=[],m=[...new Set(t.map(_=>String(_[n])))].sort((_,T)=>{const k=new Date(_).getTime(),C=new Date(T).getTime();return k-C}),v=jL(m),x=m.map(_=>LL(_,v));if(a.length===0)r.forEach((_,T)=>{const k=new Map;t.forEach($=>{k.set(String($[n]),Number($[_]||0))});const C=m.map($=>{const L=k.get($);return L!==void 0?L:null}),G=c?c(_):q3(_),ne=u[T%u.length];h.push({type:"line",name:G,data:C,color:ne,connectNulls:!0,marker:{enabled:!1,states:{hover:{enabled:!0}}}})});else{const _=a[0],T=$3(t,_);r.length===1?T.forEach((k,C)=>{const G=t.filter(Y=>String(Y[_])===k),ne=new Map;G.forEach(Y=>{ne.set(String(Y[n]),Number(Y[r[0]]||0))});const $=m.map(Y=>{const X=ne.get(Y);return X!==void 0?X:null}),L=c?c(k):k,B=u[C%u.length];h.push({type:"line",name:L,data:$,color:B,connectNulls:!0,marker:{enabled:!1,states:{hover:{enabled:!0}}}})}):T.forEach((k,C)=>{r.forEach((G,ne)=>{const $=t.filter(se=>String(se[_])===k),L=new Map;$.forEach(se=>{L.set(String(se[n]),Number(se[G]||0))});const B=m.map(se=>{const I=L.get(se);return I!==void 0?I:null}),Y=c?c(k):k,X=c?c(G):q3(G),U=`${Y} - ${X}`,Z=(C*r.length+ne)%u.length,ce=u[Z];h.push({type:"line",name:U,data:B,color:ce,connectNulls:!0,marker:{enabled:!1,states:{hover:{enabled:!0}}}})})})}return{series:h,categories:x,originalTimestamps:m}},NL=t=>t.split(" ").map(n=>n.charAt(0).toUpperCase()+n.slice(1).toLowerCase()).join(" "),q3=t=>t.split("_").map(n=>n.charAt(0).toUpperCase()+n.slice(1).toLowerCase()).join(" "),Kd=({options:t,showLegend:n=!1,legendType:a="Points",legendPosition:r="bottom",legendData:c=[],selectedRows:u=[],onLegendItemClick:h=()=>{},onLegendItemHover:p=()=>{},className:m="",chartRef:v,responsive:x=!0,maxLegendItems:_=10,rawChartData:T=[],groupbyConfig:k,selectedMetrics:C,enableGroupby:G=!1,dimensionLabelMapper:ne=B=>B,showCardinalityControl:$=!1,isMobile:L=!1})=>{console.log("chart data",t);const[B,Y]=Re.useState([]),[X,U]=Re.useState(null),[Z,ce]=Re.useState("top5"),se=Re.useRef(null),I=v||se,H=g=>!g.series||g.series.length<=1?!1:g.series.every(j=>{const te=j.name;return te&&!isNaN(Number(te))}),Q=g=>{var te,O;if(!g.series||g.series.length<=1)return g;const D=[],j=g.xAxis&&typeof g.xAxis=="object"&&"categories"in g.xAxis?g.xAxis.categories:[];g.series.forEach(z=>{const W=z;W.data&&Array.isArray(W.data)&&W.data.forEach((de,P)=>{if(de!=null){let ee,J;Array.isArray(de)?(ee=de[0],J=de[1]):(ee=P,J=Number(de)),!isNaN(ee)&&!isNaN(J)&&D.push([ee,J])}})}),D.sort((z,W)=>z[0]-W[0]);const K=[{type:"line",name:((te=g.title)==null?void 0:te.text)||"",data:D,color:((O=Qm.getOptions().colors)==null?void 0:O[0])||"#7856FF",marker:{enabled:!1,states:{hover:{enabled:!0}}}}];return{...g,series:K,xAxis:{...g.xAxis,type:j.length>0?"category":"linear"}}},F=Re.useMemo(()=>{if(!G||!T.length||!k)return H(t)?Q(t):t;const{groupbyKeys:g,timeColumn:D,metricColumns:j,showCardinality:K=!0}=k;let te=T;const O=$?DL(Z):k.cardinality||"TOP_5";K&&g.length>0&&(te=OL(T,g,j,O));const{series:z,categories:W,originalTimestamps:de}=RL(te,D,g,j,ne);return{...t,chart:{type:"line"},title:{text:""},credits:{enabled:!1},xAxis:{categories:W,gridLineWidth:0,labels:{step:F3(W,L),formatter:function(){const ee=String(this.value);return ml(ee,L)},style:{color:"#9aa0a6"},rotation:0,align:"center"}},yAxis:{title:{text:""},gridLineColor:"#e0e0e0",gridLineDashStyle:"Dash",max:(C==null?void 0:C.metric_type)==="Rate"?100:void 0,labels:{formatter:function(){var re;if(C)return bS(C,Number(this.value));const ee=((re=this.chart.options.title)==null?void 0:re.text)||"",J=V3(ee.replace(/ /g,"_")),le={metric_name_db:ee.replace(/ /g,"_"),metric_type:J};return bS(le,Number(this.value))},style:{color:"#9aa0a6"}}},legend:{enabled:!0,align:"left",verticalAlign:"bottom",layout:"horizontal",y:10,...L?{maxHeight:100}:{},itemStyle:{fontSize:"12px"},symbolRadius:0,symbolHeight:0,symbolWidth:0,useHTML:!0,labelFormatter:function(){const ee=this.color||"#000",J="name"in this?this.name:"";return'<span style="display: inline-flex; align-items: center;"><span style="background-color: '+ee+'; width: 12px; height: 12px; border-radius: 3px; display: inline-block; margin-right: 5px;"></span>'+J+"</span>"}},plotOptions:{series:{marker:{enabled:!1,symbol:"circle",radius:4,states:{hover:{enabled:!0,radius:5}}},states:{hover:{lineWidthPlus:1}}}},tooltip:{shared:!1,useHTML:!0,backgroundColor:"rgba(255, 255, 255, 0)",borderWidth:0,shadow:!1,style:{padding:"0px"},formatter:function(){var xe,pe,Se;let ee=j[0],J=ee;if(j.length>1&&((xe=this.series)!=null&&xe.name)){const Te=this.series.name.split(" - ");if(Te.length>1){const Oe=Te[Te.length-1],ze=j.find(Ge=>Ge.replace(/_/g," ").replace(/\b\w/g,qe=>qe.toUpperCase())===Oe);ze&&(ee=ze,J=Oe)}}else j.length===1&&(J=(C==null?void 0:C.metric_label)||ee.replace(/_/g," ").replace(/\b\w/g,Ae=>Ae.toUpperCase()));const re={metric_type:V3(ee)},ge=Ae=>Ae.replace(/_/g," ").replace(/\b\w/g,Te=>Te.toUpperCase());let ve='<div style="border-radius: 12px; border: 1px solid #EAECF0; background: #FFF; box-shadow: 0px 6px 15px 0px rgba(0, 0, 0, 0.15), 0px 3px 2px -5px rgba(0, 0, 0, 0.04); padding: 16px;">';ve+='<div style="display: flex; font-family: Inter, sans-serif; gap: 16px; align-items: stretch;">';const we=this.color||"#7856FF";ve+=`<div style="background:${we}; width: 4px; flex-shrink: 0; border-radius: 4px; align-self: stretch;"></div>`,ve+='<div style="display: flex; flex-direction: column; gap: 12px;">',ve+='<div style="display: flex; flex-direction: column; gap: 4px;">',ve+=`<div style="color: #525252; font-feature-settings: 'clig' off, 'liga' off; font-family: Inter; font-size: 12px; font-style: normal; font-weight: 600; line-height: 18px;">${ge(J)}</div>`,ve+="</div>",ve+='<div class="flex flex-col gap-1" style="display: flex; flex-direction: column; gap: 6px;">';const Ce=bS(re,this.y||0),Me=((pe=this.series)==null?void 0:pe.name)==="Overall",De=Me?"#E8E8E8":"#D4F4E5",be=Me?"#424242":"#008242";ve+='<div class="flex items-center" style="display: flex; align-items: center;">',ve+=`<div class="rounded p-1 font-semibold mr-1.5 my-1" style="background-color: ${De}; color: ${be}; border-radius: 4px; padding: 4px 8px; font-weight: 600; margin-right: 8px; font-size: 12px;">${Ce}</div>`,ve+=`<div class="text-jp-2-gray-200 font-medium" style="color: #70747E; font-weight: 500; font-size: 12px;">${((Se=this.series)==null?void 0:Se.name)||""}</div>`,ve+="</div>";let ye="";if(this.x!==void 0&&this.x!==null){const Ae=typeof this.x=="number"?this.x:W.indexOf(String(this.x));if(Ae>=0&&Ae<de.length){const Te=de[Ae];try{ye=Qd(Te)}catch{ye=String(this.x)}}else ye=String(this.x)}return ve+=`<div class="font-medium text-jp-2-gray-300" style="font-weight: 500; color: #9AA0A6; font-size: 12px; margin-top: 4px;">${ye}</div>`,ve+="</div>",ve+="</div>",ve+="</div>",ve+="</div>",ve},xDateFormat:"%a, %d %B, %Y %H:%M"},series:z}},[t,G,T,k,C,ne,$,Z,L]),E=u.length>0?u:B,M=Re.useCallback(g=>{var K;const D=E.includes(g.name)?E.filter(te=>te!==g.name):[...E,g.name],j=D.length===c.length?[]:D;if(Y(j),(K=I.current)!=null&&K.chart){const te=I.current.chart;te.series.forEach(O=>{j.length===0?O.setVisible(!0,!1):O.setVisible(j.includes(O.name||""),!1)}),te.redraw()}h==null||h(g)},[E,c,I,h]),R=Re.useCallback(g=>{U(g),p==null||p(g)},[p]),V=Re.useMemo(()=>{var z,W;const g=F,D=typeof g.xAxis=="object"&&"labels"in g.xAxis?g.xAxis.labels:{},j=D&&typeof D=="object"&&"step"in D?D.step:null,K=typeof g.xAxis=="object"&&"categories"in g.xAxis?g.xAxis.categories:[],te=j!==null?j:F3(K,L),O={...g,xAxis:{...g.xAxis,type:"category",labels:{...D,rotation:0,step:te,style:{textOverflow:"none",color:"#9aa0a6",fontSize:"10px"},formatter:function(){const de=String(this.value);return ml(de,L)}},lineColor:"#9aa0a6",gridLineWidth:0,gridLineColor:"#e5e5e5",gridLineDashStyle:"Solid",tickAmount:6,crosshair:!1,tickmarkPlacement:"on",alignTicks:!0},legend:{enabled:n&&a==="Points",align:"left",verticalAlign:"bottom",layout:"horizontal",...L?{maxHeight:100}:{},itemStyle:{fontSize:"12px"},x:0,floating:!1,...g.legend},yAxis:{...g.yAxis,gridLineWidth:1,gridLineColor:"#e5e5e5",gridLineDashStyle:"Dash",max:(C==null?void 0:C.metric_type)==="Rate"?100:typeof g.yAxis=="object"&&"max"in g.yAxis?g.yAxis.max:void 0,labels:{...typeof g.yAxis=="object"&&"labels"in g.yAxis?g.yAxis.labels:{},style:{fontSize:"10px",color:"#9aa0a6",...typeof g.yAxis=="object"&&"labels"in g.yAxis&&g.yAxis.labels&&typeof g.yAxis.labels=="object"&&"style"in g.yAxis.labels?g.yAxis.labels.style:{}}}},tooltip:{...g.tooltip,shared:!1,xDateFormat:"%a, %d %B, %Y %H:%M"}};return(z=g.title)!=null&&z.text?{...O,title:{...g.title,text:NL(g.title.text),style:{...(W=g.title)==null?void 0:W.style,padding:"12px"}}}:O},[F,n,a,r,L]),ae=Re.useMemo(()=>{if(c.length>0)return c;const g=V;return g.series?g.series.map((D,j)=>{const K=D,te=K.color,O=Qm.getOptions().colors||[],z=typeof te=="string"?te:O[j%O.length];return{name:K.name||`Series ${j+1}`,color:z,visible:K.visible!==!1,data:K.data||[],value:Array.isArray(K.data)&&K.data.length>0?K.data[K.data.length-1]:void 0}}):[]},[c,V]),oe=r==="left"||r==="right",A=x&&window.innerWidth<=768,ue=`${zt["highchart-wrapper"]} ${A?zt.mobile:""} ${m} ${oe?`${zt.flex} ${zt["flex-row"]}`:`${zt.flex} ${zt["flex-col"]}`}`,me=$&&G&&k&&k.groupbyKeys.length>0&&T.length>0;return q.jsx(oc,{children:q.jsxs("div",{className:ue,children:[me&&q.jsx(TL,{granularity:Z,onGranularityChange:ce}),n&&r==="top"&&q.jsx(Tb,{legendData:ae,selectedRows:E,hoveredItem:X,onItemClick:M,onItemHover:R,legendType:a,position:r,maxItems:_,responsive:x}),q.jsx("div",{className:`${oe?zt["flex-1"]:zt["w-full"]} ${n&&r==="left"?zt["order-2"]:""}`,children:q.jsx(kL,{highcharts:Qm,options:V,ref:I})}),n&&r==="right"&&q.jsx(Tb,{legendData:ae,selectedRows:E,hoveredItem:X,onItemClick:M,onItemHover:R,legendType:a,position:r,maxItems:_,responsive:x}),n&&r==="left"&&q.jsx(Tb,{legendData:ae,selectedRows:E,hoveredItem:X,onItemClick:M,onItemHover:R,legendType:a,position:r,maxItems:_,responsive:x}),n&&r==="bottom"&&q.jsx(Tb,{legendData:ae,selectedRows:E,hoveredItem:X,onItemClick:M,onItemHover:R,legendType:a,position:r,maxItems:_,responsive:x})]})})},zL=t=>t?t.replace(/_/g," ").split(" ").map(a=>a.charAt(0).toUpperCase()+a.slice(1).toLowerCase()).join(" "):"Unknown",BL=(t,n)=>{if(n==null||n==="")return"N/A";let a;if(typeof n=="string"){const c=n.replace(/[^0-9.-]/g,"");a=parseFloat(c)}else a=n;if(isNaN(a))return String(n);const r=t.toLowerCase();return r.includes("rate")||r.includes("percentage")||r.includes("percent")?`${a}%`:r.includes("latency")||r.includes("time")||r.includes("duration")?`${a}S`:r.includes("volume")||r.includes("count")||r.includes("amount")||r.includes("total")||r.includes("transaction")||r.includes("order")||r.includes("number")||r.includes("quantity")?a>=1e7?`${(a/1e7).toFixed(1)} Cr`:a>=1e5?`${(a/1e5).toFixed(1)} L`:a>=1e3?`${(a/1e3).toFixed(1)} K`:a%1!==0?a.toFixed(2):a.toLocaleString("en-IN"):String(a)},Ab=({metric:t,value:n})=>q.jsxs("div",{className:nt["genius-dashboard-single-stat-card"],children:[q.jsx("div",{className:nt["genius-dashboard-single-stat-title"],children:zL(t)}),q.jsx("div",{className:nt["genius-dashboard-single-stat-value"],children:BL(t,n)})]}),xS=({data:t})=>{const[n,a]=Re.useState(1),r=5;if(!t||t.length===0)return null;const c=Object.keys(t[0]),u=[],h=[];c.forEach(G=>{var $;typeof(($=t.find(L=>L[G]!==null&&L[G]!==void 0))==null?void 0:$[G])=="string"||G.toLowerCase().includes("name")||G.toLowerCase().includes("id")?u.push(G):h.push(G)});const p=[...u,...h],m=n*r,v=m-r,x=t.slice(v,m),_=Math.ceil(t.length/r),T=G=>{a(G)},k=()=>{const ne=[],$=[];let L;ne.push(1);for(let B=n-1;B<=n+1;B++)B>1&&B<_&&ne.push(B);return _>1&&ne.push(_),ne.forEach(B=>{L!==void 0&&typeof B=="number"&&(B-L===2?$.push(L+1):B-L!==1&&$.push("...")),$.push(B),L=typeof B=="number"?B:L}),$},C=(G,ne)=>{if(G==null||G==="")return"N/A";const $=typeof G=="string"?parseFloat(G):G;if(isNaN($))return String(G);const L=ne.toLowerCase();if(L.includes("rate")||L.includes("percentage")||L.includes("percent"))return`${$}%`;if(L.includes("latency")||L.includes("time")||L.includes("duration"))return`${$}S`;if(L.includes("volume")||L.includes("count")||L.includes("amount")||L.includes("total")){if($>=1e7)return`${($/1e7).toFixed(1)}Cr`;if($>=1e5)return`${($/1e5).toFixed(1)}L`;if($>=1e3)return`${($/1e3).toFixed(1)}K`}return L.includes("price")||L.includes("cost")?new Intl.NumberFormat("en-US",{style:"currency",currency:"USD",minimumFractionDigits:2,maximumFractionDigits:2}).format($):L.includes("quantity")?new Intl.NumberFormat("en-US").format($):typeof G=="number"?new Intl.NumberFormat("en-US").format(G):G.toString()};return q.jsxs("div",{className:nt["genius-dashboard-table-container"],"data-loaded-table":"genius-table",children:[q.jsx("div",{className:nt["genius-dashboard-table-wrapper"],children:q.jsxs("table",{className:nt["genius-dashboard-table"],children:[q.jsx("thead",{className:nt["genius-dashboard-table-head"],children:q.jsx("tr",{className:nt["genius-dashboard-table-head-row"],children:p.map(G=>q.jsx("th",{className:`${nt["genius-dashboard-table-head-cell"]} ${nt["text-left"]}`,children:q.jsx("div",{className:nt["genius-dashboard-table-head-content"],children:G.replace(/_/g," ")})},G))})}),q.jsx("tbody",{className:nt["genius-dashboard-table-body"],children:x.map((G,ne)=>q.jsx("tr",{className:nt["genius-dashboard-table-row"],children:p.map($=>q.jsx("td",{className:nt["genius-dashboard-table-cell"],children:q.jsx("div",{className:nt["genius-dashboard-table-cell-content"],children:C(G[$],$)})},$))},ne))})]})}),t.length>r&&q.jsxs("div",{className:nt["genius-dashboard-pagination"],children:[q.jsxs("span",{className:nt["genius-dashboard-pagination-info"],children:["Showing ",v+1," - ",Math.min(m,t.length)," of ",t.length]}),q.jsxs("div",{className:nt["genius-dashboard-page-controls"],children:[q.jsx("button",{onClick:()=>T(n-1),disabled:n===1,className:nt["genius-dashboard-page-button"],children:"←"}),k().map((G,ne)=>G==="..."?q.jsx("span",{className:nt["genius-dashboard-pagination-dots"],children:"..."},`dots-${ne}`):q.jsx("button",{onClick:()=>T(G),className:`${nt["genius-dashboard-page-button"]} ${n===G?nt.active:""}`,children:G},G)),q.jsx("button",{onClick:()=>T(n+1),disabled:n===_,className:nt["genius-dashboard-page-button"],children:"→"})]})]})]})},Yi={volumeChartWrapper:"genius-sdk__VolumeChartRenderer-module__volumeChartWrapper___kiY8A",volumeRendererContainer:"genius-sdk__VolumeChartRenderer-module__volumeRendererContainer___Q6LiY",volumeGranularitySelect:"genius-sdk__VolumeChartRenderer-module__volumeGranularitySelect___oyuer",volumeChartToggle:"genius-sdk__VolumeChartRenderer-module__volumeChartToggle___VVP1y",volumeToggleButton:"genius-sdk__VolumeChartRenderer-module__volumeToggleButton___HlQp6",active:"genius-sdk__VolumeChartRenderer-module__active___ztxmP",volumeToggleIcon:"genius-sdk__VolumeChartRenderer-module__volumeToggleIcon___S97MZ",volumeChartContainer:"genius-sdk__VolumeChartRenderer-module__volumeChartContainer___qji65",noBorderChart:"genius-sdk__VolumeChartRenderer-module__noBorderChart___wqVTM",volumeNoData:"genius-sdk__VolumeChartRenderer-module__volumeNoData___fNbeP"},_S=(t,n)=>{const a=typeof n=="string"?parseFloat(n):n;return isNaN(a)?String(n):t.toLowerCase().includes("rate")||t.toLowerCase().includes("percentage")?`${a.toFixed(2)}%`:t.toLowerCase().includes("latency")||t.toLowerCase().includes("time")?`${a.toFixed(2)}S`:a>=1e7?`${(a/1e7).toFixed(1)}Cr`:a>=1e5?`${(a/1e5).toFixed(1)}L`:a>=1e3?`${(a/1e3).toFixed(1)}K`:a.toLocaleString("en-IN")},UL=({granularity:t,onGranularityChange:n})=>q.jsx("div",{className:Yi.volumeRendererContainer,children:q.jsx(vS,{value:t,onChange:a=>n(a),options:[{value:"top5",label:"Top 5"},{value:"top10",label:"Top 10"}],className:Yi.volumeGranularitySelect})}),PL=(t,n,a,r="all")=>{if(!t||t.length===0)return[];const c=t.reduce((h,p)=>{const m=String(p[n]||"Unknown"),v=p[a],x=typeof v=="number"?v:parseFloat(String(v))||0;if(x>0){const _=h[m]||0;h[m]=_+x}return h},{});let u=Object.entries(c).filter(([,h])=>h>0).map(([h,p])=>({name:h,value:Number(p)})).sort((h,p)=>p.value-h.value);return r==="top5"?u=u.slice(0,5):r==="top10"&&(u=u.slice(0,10)),u},HL=(t,n,a=!1,r=!0)=>{console.log("createBarChartOptions data:","isMobile:",a,"isHorizontalBar:",r);const c=t.map(h=>({name:h.name,y:h.value})),u=t.map(h=>h.name);return console.log("HighBarChart1D categories:",{categories:u}),{chart:{type:r?"bar":"column",backgroundColor:"white",height:a?300:400,marginTop:a?15:60,marginBottom:a?25:60,marginLeft:r?a?80:100:a?40:80,marginRight:a?20:40,borderWidth:0,...a&&{spacingTop:0}},title:{text:"",margin:50,style:{fontFamily:"Inter",fontSize:"14px",fontWeight:"600",color:"#111111"}},tooltip:{shared:!1,enabled:!0,useHTML:!0,hideDelay:0,outside:!a,padding:0,backgroundColor:"transparent",borderWidth:0,shadow:!1,style:{zIndex:9999},positioner:a?function(h,p,m){const v=this.chart,{plotLeft:x,plotTop:_,plotWidth:T}=v;let k=m.plotX+x-h/2,C=m.plotY+_-p-10;return k<x&&(k=x+5),k+h>x+T&&(k=x+T-h-5),C<_&&(C=m.plotY+_+10),{x:k,y:C}}:void 0,formatter:function(){var T;const h=this.y??0,p=_S(n.metric_type||"volume",h),m=((T=this.point)==null?void 0:T.name)||this.key||this.x;return`<div style="background: white; border-radius: 6px; box-shadow: 0 2px 8px rgba(0,0,0,0.1); display: flex; align-items: stretch; padding: ${a?"6px 6px 4px 6px":"10px 10px 6px 10px"}; max-width: ${a?"250px":"300px"}; min-width: ${a?"180px":"220px"};">
108
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function v(L,B){if(L){if(typeof L=="string")return T(L,B);var Y=Object.prototype.toString.call(L).slice(8,-1);return Y==="Object"&&L.constructor&&(Y=L.constructor.name),Y==="Map"||Y==="Set"?Array.from(L):Y==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Y)?T(L,B):void 0}}function x(L){if(typeof Symbol<"u"&&L[Symbol.iterator]!=null||L["@@iterator"]!=null)return Array.from(L)}function _(L){if(Array.isArray(L))return T(L)}function T(L,B){(B==null||B>L.length)&&(B=L.length);for(var Y=0,X=new Array(B);Y<B;Y++)X[Y]=L[Y];return X}function k(L){"@babel/helpers - typeof";return(k=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(B){return typeof B}:function(B){return B&&typeof Symbol=="function"&&B.constructor===Symbol&&B!==Symbol.prototype?"symbol":typeof B})(L)}Object.defineProperty(c,"__esModule",{value:!0}),u.d(c,"HighchartsReact",function(){return $});var C=u(1),G=u.n(C),ne=typeof window<"u"?C.useLayoutEffect:C.useEffect,$=Object(C.memo)(Object(C.forwardRef)(function(L,B){var Y=Object(C.useRef)(),X=Object(C.useRef)(),U=Object(C.useRef)(L.constructorType),Z=Object(C.useRef)(L.highcharts);return ne(function(){function ce(){var I=L.highcharts||(typeof window>"u"?"undefined":k(window))==="object"&&window.Highcharts,H=L.constructorType||"chart";I?I[H]?L.options?X.current=I[H](Y.current,L.options,L.callback):console.warn('The "options" property was not passed.'):console.warn('The "constructorType" property is incorrect or some required module is not imported.'):console.warn('The "highcharts" property was not passed.')}if(X.current){if(L.allowChartUpdate!==!1)if(L.constructorType!==U.current||L.highcharts!==Z.current)U.current=L.constructorType,Z.current=L.highcharts,ce();else if(!L.immutable&&X.current){var se;(se=X.current).update.apply(se,[L.options].concat(p(L.updateArgs||[!0,!0])))}else ce()}else ce()},[L.options,L.allowChartUpdate,L.updateArgs,L.containerProps,L.highcharts,L.constructorType]),ne(function(){return function(){X.current&&(X.current.destroy(),X.current=null)}},[]),Object(C.useImperativeHandle)(B,function(){return{get chart(){return X.current},container:Y}},[]),G.a.createElement("div",h({},L.containerProps,{ref:Y}))}));c.default=$},function(r,c){r.exports=a}])})}(kb)),kb.exports}var CL=wL();const kL=Fd(CL),Qd=t=>{console.log("🔍 DEBUG Raw input date string:",t);let n;try{if(t.includes(" at ")){console.log('🔍 DEBUG Detected "at" format - using special parsing logic');const C=/^(\d{1,2})\s+(\w{3})\s+at\s+(\d{1,2}):(\d{2})\s+(AM|PM)$/i,G=t.match(C);if(G){console.log("🔍 DEBUG Regex match found:",G);const[,ne,$,L,B,Y]=G;console.log("🔍 DEBUG Extracted components:",{dayStr:ne,monthStr:$,hourStr:L,minuteStr:B,ampmStr:Y});const X={Jan:0,Feb:1,Mar:2,Apr:3,May:4,Jun:5,Jul:6,Aug:7,Sep:8,Oct:9,Nov:10,Dec:11},U=parseInt(ne,10),Z=X[$];let ce=parseInt(L,10);const se=parseInt(B,10);console.log("🔍 DEBUG Parsed values (before 12h conversion):",{day:U,monthIndex:Z,hours:ce,minutes:se}),Y.toUpperCase()==="PM"&&ce!==12?ce+=12:Y.toUpperCase()==="AM"&&ce===12&&(ce=0),console.log("🔍 DEBUG Hours after 12h to 24h conversion:",ce);const I=new Date().getFullYear();console.log("🔍 DEBUG Using current year:",I),Z!==void 0&&!isNaN(U)&&!isNaN(ce)&&!isNaN(se)?(n=new Date(I,Z,U,ce,se),console.log('🔍 DEBUG Successfully created Date object for "at" format:',n)):(console.log('🔍 DEBUG Failed to parse "at" format components, falling back to direct parsing'),n=new Date(t))}else console.log('🔍 DEBUG "at" format regex did not match, falling back to direct parsing'),n=new Date(t)}else if(t.includes("T"))console.log("🔍 DEBUG Using ISO format parsing"),n=new Date(t);else if(t.includes("/"))console.log("🔍 DEBUG Using slash format parsing"),n=new Date(t);else if(t.includes("-")){const C=t.replace(/-/g,"/");console.log("🔍 DEBUG Converting dash to slash format:",t,"->",C),n=new Date(C)}else console.log("🔍 DEBUG Using direct parsing"),n=new Date(t);console.log("🔍 DEBUG Raw Date object:",n),console.log("🔍 DEBUG Raw time value:",n.getTime()),console.log("🔍 DEBUG Date toString():",n.toString()),console.log("🔍 DEBUG Date toISOString():",n.toISOString())}catch(C){return console.error("🔍 DEBUG Date parsing error:",C instanceof Error?C.message:"Unknown error"),"Date Parsing Error"}if(isNaN(n.getTime()))return console.warn("❌ Invalid date format detected:",{input:t,dateObj:n,userAgent:navigator.userAgent}),"Invalid Date";const a=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],r=["January","February","March","April","May","June","July","August","September","October","November","December"],c=n.getDay(),u=n.getDate(),h=n.getMonth(),p=n.getFullYear();let m=n.getHours();const v=n.getMinutes();if(isNaN(c)||isNaN(u)||isNaN(h)||isNaN(p)||isNaN(m)||isNaN(v))return console.warn("Date parsing returned NaN values:",{dayIndex:c,day:u,monthIndex:h,year:p,hours:m,minutes:v}),"Invalid Date";const x=a[c]||"Invalid",_=r[h]||"Invalid",T=m>=12?"PM":"AM";m=m%12,m=m||12;const k=v<10?"0"+v:v.toString();return`${x}, ${u} ${_}, ${p} ${m}:${k} ${T}`},bS=(t,n)=>{if(!t)return n.toString();const{metric_type:a}=t;switch(a){case"Rate":return n<=1?`${(n*100).toFixed(2)}%`:`${n.toFixed(2)}%`;case"Volume":case"Count":return n>=1e7?`${(n/1e7).toFixed(1)} Cr`:n>=1e5?`${(n/1e5).toFixed(1)} L`:n>=1e3?`${(n/1e3).toFixed(1)} K`:n.toLocaleString("en-IN");case"Amount":return n>=1e7?`${(n/1e7).toFixed(1)} Cr`:n>=1e5?`${(n/1e5).toFixed(1)} L`:n>=1e3?`${(n/1e3).toFixed(1)} K`:n.toLocaleString("en-IN");case"Latency":return`${n.toFixed(2)} s`;default:return n.toString()}},ml=(t,n=!1)=>{console.log("🔍 truncateText called:",{text:t,isMobile:n,textLength:t.length});const a=n?8:10;if(t.length<=a)return console.log("🔍 truncateText result (no truncation needed):",t),t;const r=t.substring(0,a)+"..";return console.log("🔍 truncateText result (truncated):",{original:t,truncated:r,maxLength:a}),r},G3=t=>t&&t.split(/[_\s]+/).map(n=>n&&n.charAt(0).toUpperCase()+n.slice(1).toLowerCase()).join(" "),hc={customDropdown:"genius-sdk__CustomDropdown-module__customDropdown___PF-Jr",dropdownTrigger:"genius-sdk__CustomDropdown-module__dropdownTrigger___oTT8t",open:"genius-sdk__CustomDropdown-module__open___ghWoC",dropdownValue:"genius-sdk__CustomDropdown-module__dropdownValue___GRfHp",dropdownArrow:"genius-sdk__CustomDropdown-module__dropdownArrow___EBas6",rotated:"genius-sdk__CustomDropdown-module__rotated___TeDYS",dropdownOptions:"genius-sdk__CustomDropdown-module__dropdownOptions___TmntB",dropdownOption:"genius-sdk__CustomDropdown-module__dropdownOption___jjWGO",selected:"genius-sdk__CustomDropdown-module__selected___E7cpP"},vS=({value:t,onChange:n,options:a,className:r=""})=>{const[c,u]=Re.useState(!1),h=Re.useRef(null),p=a.find(x=>x.value===t);Re.useEffect(()=>{const x=_=>{h.current&&!h.current.contains(_.target)&&u(!1)};return document.addEventListener("mousedown",x),()=>{document.removeEventListener("mousedown",x)}},[]);const m=x=>{n(x),u(!1)},v=x=>{x.key==="Enter"||x.key===" "?(x.preventDefault(),u(!c)):x.key==="Escape"&&u(!1)};return q.jsxs("div",{ref:h,className:`${hc.customDropdown} ${r}`,onKeyDown:v,children:[q.jsxs("div",{className:`${hc.dropdownTrigger} ${c?hc.open:""}`,onClick:()=>u(!c),role:"button",tabIndex:0,"aria-haspopup":"listbox","aria-expanded":c,children:[q.jsx("span",{className:hc.dropdownValue,children:(p==null?void 0:p.label)||"Select..."}),q.jsx("span",{className:`${hc.dropdownArrow} ${c?hc.rotated:""}`,children:q.jsx("svg",{width:"12",height:"8",viewBox:"0 0 12 8",fill:"none",children:q.jsx("path",{d:"M1 1.5L6 6.5L11 1.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})})]}),c&&q.jsx("div",{className:hc.dropdownOptions,role:"listbox",children:a.map(x=>q.jsx("div",{className:`${hc.dropdownOption} ${x.value===t?hc.selected:""}`,onClick:()=>m(x.value),role:"option","aria-selected":x.value===t,children:x.label},x.value))})]})},zt={"highchart-wrapper":"genius-sdk__Highchart-module__highchart-wrapper___sM-hD","legend-container":"genius-sdk__Highchart-module__legend-container___PF9Kl","legend-item":"genius-sdk__Highchart-module__legend-item___S61g8","legend-bullet":"genius-sdk__Highchart-module__legend-bullet___iqmNl","legend-table":"genius-sdk__Highchart-module__legend-table___sQOwt",mobile:"genius-sdk__Highchart-module__mobile___DAaPf",noBorderChart:"genius-sdk__Highchart-module__noBorderChart___4UsC9","highcharts-container":"genius-sdk__Highchart-module__highcharts-container___ygpjY","highcharts-title":"genius-sdk__Highchart-module__highcharts-title___vYLWj","highcharts-legend-item":"genius-sdk__Highchart-module__highcharts-legend-item___QKt2l","highcharts-axis-labels":"genius-sdk__Highchart-module__highcharts-axis-labels___0y1KO","highcharts-yaxis-labels":"genius-sdk__Highchart-module__highcharts-yaxis-labels___ZcIXe","highcharts-grid-line":"genius-sdk__Highchart-module__highcharts-grid-line___gITcn","highcharts-point":"genius-sdk__Highchart-module__highcharts-point___5Wqsl","highcharts-plot-background":"genius-sdk__Highchart-module__highcharts-plot-background___XvssF","custom-legend":"genius-sdk__Highchart-module__custom-legend___8txpT","custom-legend-item":"genius-sdk__Highchart-module__custom-legend-item___nUPlX","custom-legend-bullet":"genius-sdk__Highchart-module__custom-legend-bullet___3hLh2","custom-legend-text":"genius-sdk__Highchart-module__custom-legend-text___Ja4cM","custom-legend-value":"genius-sdk__Highchart-module__custom-legend-value___sMiwT","flex-row":"genius-sdk__Highchart-module__flex-row___qsVq8","volume-renderer-container":"genius-sdk__Highchart-module__volume-renderer-container___05bp2",volumeGranularitySelect:"genius-sdk__Highchart-module__volumeGranularitySelect___0a4VT",cardinalityControlContainer:"genius-sdk__Highchart-module__cardinalityControlContainer___wXwZ4","highchart-loading":"genius-sdk__Highchart-module__highchart-loading___XW7h3",spin:"genius-sdk__Highchart-module__spin___H-wRz"},V3=t=>t.includes("rate")?"Rate":t.includes("volume")?"Volume":t.includes("amount")||t.includes("ticket")?"Amount":t.includes("latency")?"Latency":"Count";Qm.setOptions({credits:{enabled:!1},colors:["#7856FF","#FEBBB2","#72BEF4","#1E90FF","#E377C2","#7FE1D8","#CB80DC","#5CB7AF","#1F77B4","#9467BD","#0F7EA0","#17BECF","#7F7F7F","#BCBD22","#A0872C","#006400","#B3596E","#4B0082","#4B6D8C"]});const TL=({granularity:t,onGranularityChange:n})=>q.jsx("div",{className:zt.cardinalityControlContainer,children:q.jsx(vS,{value:t,onChange:a=>n(a),options:[{value:"top5",label:"Top 5"},{value:"top10",label:"Top 10"}],className:""})}),AL=({text:t,maxLength:n=30,className:a="w-full"})=>t.length>n?q.jsxs("div",{className:`${zt["whitespace-pre"]} ${zt["text-ellipsis"]} ${zt["overflow-hidden"]} ${zt[a]}`,title:t,children:[t.slice(0,n),"..."]}):q.jsx("div",{className:`${zt["whitespace-pre"]} ${zt[a]}`,children:t}),EL=({item:t,isSelected:n,isHovered:a=!1,onClick:r,onMouseEnter:c,onMouseLeave:u,showValue:h=!1,maxWidth:p=200})=>{const m=n?zt["opacity-100"]:zt["opacity-60"],v=a?zt["bg-gray-100"]:"";return q.jsxs("div",{className:`${zt.flex} ${zt["items-center"]} ${zt["gap-2"]} ${zt["cursor-pointer"]} ${zt["select-none"]} ${zt["transition-all"]} ${zt["duration-200"]} ${m} ${v} ${zt["font-medium"]} ${zt["p-1"]} ${zt.rounded}`,onClick:()=>r(t),onMouseEnter:()=>c(t),onMouseLeave:u,style:{maxWidth:`${p}px`},children:[q.jsx("div",{className:`${zt["w-3"]} ${zt["h-3"]} ${zt["rounded-sm"]}`,style:{backgroundColor:t.color}}),q.jsx(AL,{text:t.name,maxLength:p/8,className:zt["flex-1"]}),h&&t.overallValue&&q.jsxs(q.Fragment,{children:[q.jsx("div",{className:`${zt["w-px"]} ${zt["h-2.5"]} ${zt["bg-gray-300"]}`}),q.jsx("div",{className:`${zt["text-xs"]} ${zt["font-medium"]} ${zt["text-gray-600"]}`,children:t.overallValue})]})]})},Tb=({legendData:t,selectedRows:n,hoveredItem:a,onItemClick:r,onItemHover:c,legendType:u,position:h,maxItems:p=10,responsive:m=!0})=>{const[v,x]=Re.useState(!1),_=m&&window.innerWidth<=768,T=v?t:t.slice(0,p),k=t.length>p,C=Re.useCallback(B=>{r(B)},[r]),G=Re.useCallback(B=>{c(B)},[c]),$=h==="top"||h==="bottom"?`${zt["flex-row"]} ${zt["flex-wrap"]}`:zt["flex-col"],L=`${zt.flex} ${$} ${zt["gap-4"]} ${zt["p-4"]}`;return u==="Table"?q.jsx("div",{className:L,children:q.jsxs("div",{className:zt["w-full"],children:[q.jsxs("table",{className:`${zt["w-full"]} ${zt["text-sm"]}`,children:[q.jsx("thead",{children:q.jsxs("tr",{className:zt["border-b"],children:[q.jsx("th",{className:`${zt["text-left"]} ${zt["p-2"]}`,children:"Series"}),q.jsx("th",{className:`${zt["text-right"]} ${zt["p-2"]}`,children:"Value"})]})}),q.jsx("tbody",{children:T.map(B=>q.jsxs("tr",{className:`${zt["cursor-pointer"]} ${zt["hover:bg-gray-50"]} ${n.includes(B.name)?zt["bg-blue-50"]:""} ${(a==null?void 0:a.name)===B.name?zt["bg-gray-100"]:""}`,onClick:()=>C(B),onMouseEnter:()=>G(B),onMouseLeave:()=>G(null),children:[q.jsx("td",{className:zt["p-2"],children:q.jsxs("div",{className:`${zt.flex} ${zt["items-center"]} ${zt["gap-2"]}`,children:[q.jsx("div",{className:`${zt["w-3"]} ${zt["h-3"]} ${zt["rounded-sm"]}`,style:{backgroundColor:B.color}}),q.jsx("span",{children:B.name})]})}),q.jsx("td",{className:`${zt["p-2"]} ${zt["text-right"]}`,children:B.overallValue||B.value||"-"})]},B.name))})]}),k&&q.jsx("button",{className:`${zt["mt-2"]} ${zt["text-blue-600"]} ${zt["hover:text-blue-800"]} ${zt["text-sm"]}`,onClick:()=>x(!v),children:v?"Show less":`+${t.length-p} more`})]})}):q.jsxs("div",{className:L,children:[T.map(B=>q.jsx(EL,{item:B,isSelected:n.length===0||n.includes(B.name),isHovered:(a==null?void 0:a.name)===B.name,onClick:C,onMouseEnter:G,onMouseLeave:()=>G(null),showValue:!0,maxWidth:_?150:200},B.name)),k&&q.jsx("button",{className:`${zt["text-blue-600"]} ${zt["hover:text-blue-800"]} ${zt["text-sm"]} ${zt["px-2"]} ${zt["py-1"]} ${zt.rounded}`,onClick:()=>x(!v),children:v?"Show less":`+${t.length-p} more`})]})},$3=(t,n)=>{const a=new Set;return t.forEach(r=>{const c=String(r[n]||"");c&&a.add(c)}),Array.from(a)},ML=t=>{switch(t){case"TOP_3":return 3;case"TOP_5":return 5;case"TOP_10":return 10;case"TOP_15":return 15;case"TOP_20":return 20;default:return 5}},DL=t=>{switch(t){case"top5":return"TOP_5";case"top10":return"TOP_10";default:return"TOP_5"}},OL=(t,n,a,r)=>{if(n.length===0)return t;const c=n[0],u=$3(t,c),h=ML(r),m=u.map(v=>{const x=t.filter(T=>String(T[c])===v),_=a.reduce((T,k)=>{const C=x.reduce((G,ne)=>G+Number(ne[k]||0),0);return T+C},0);return{groupbyValue:v,total:_}}).sort((v,x)=>x.total-v.total).slice(0,h).map(v=>v.groupbyValue);return t.filter(v=>m.includes(String(v[c])))},jL=t=>{if(t.length<2)return"auto";const n=t.map(m=>new Date(m).getTime()).sort((m,v)=>m-v),a=[];for(let m=1;m<n.length;m++)a.push(n[m]-n[m-1]);const r=a.reduce((m,v)=>m+v,0)/a.length,c=60*60*1e3,u=24*c,h=7*u,p=30*u;return r<=c*2?"hourly":r<=u*2?"daily":r<=h*2?"weekly":r<=p*2?"monthly":"yearly"},LL=(t,n)=>{const a=new Date(t);switch(n){case"hourly":return a.toLocaleString("en-US",{hour:"2-digit",minute:"2-digit"});case"daily":return a.toLocaleString("en-US",{month:"short",day:"numeric"});case"weekly":case"monthly":return a.toLocaleString("en-US",{month:"short",day:"numeric"});case"yearly":return a.getFullYear().toString();default:return Qd(t)}},F3=(t,n=!1)=>{const a=t.length,r=t[0]||"",c=/\d{1,2}:\d{2}/.test(r),u=/\d{1,2}\.\s*[A-Za-z]{3}/.test(r);let h;return n?a>20?h=6:a>12?h=4:a<=6?h=1:h=c||u?3:2:a>20?h=3:a>12?h=2:a<=8?h=1:h=c||u?2:1,console.log("📊 Intelligent Step Calculation:",{dataPointCount:a,sampleCategory:r,isDateHourPattern:c,isMonthDayPattern:u,isMobile:n,calculatedStep:h,categories:t.slice(0,5)}),h},RL=(t,n,a,r,c)=>{const u=Qm.getOptions().colors||[],h=[],m=[...new Set(t.map(_=>String(_[n])))].sort((_,T)=>{const k=new Date(_).getTime(),C=new Date(T).getTime();return k-C}),v=jL(m),x=m.map(_=>LL(_,v));if(a.length===0)r.forEach((_,T)=>{const k=new Map;t.forEach($=>{k.set(String($[n]),Number($[_]||0))});const C=m.map($=>{const L=k.get($);return L!==void 0?L:null}),G=c?c(_):q3(_),ne=u[T%u.length];h.push({type:"line",name:G,data:C,color:ne,connectNulls:!0,marker:{enabled:!1,states:{hover:{enabled:!0}}}})});else{const _=a[0],T=$3(t,_);r.length===1?T.forEach((k,C)=>{const G=t.filter(Y=>String(Y[_])===k),ne=new Map;G.forEach(Y=>{ne.set(String(Y[n]),Number(Y[r[0]]||0))});const $=m.map(Y=>{const X=ne.get(Y);return X!==void 0?X:null}),L=c?c(k):k,B=u[C%u.length];h.push({type:"line",name:L,data:$,color:B,connectNulls:!0,marker:{enabled:!1,states:{hover:{enabled:!0}}}})}):T.forEach((k,C)=>{r.forEach((G,ne)=>{const $=t.filter(se=>String(se[_])===k),L=new Map;$.forEach(se=>{L.set(String(se[n]),Number(se[G]||0))});const B=m.map(se=>{const I=L.get(se);return I!==void 0?I:null}),Y=c?c(k):k,X=c?c(G):q3(G),U=`${Y} - ${X}`,Z=(C*r.length+ne)%u.length,ce=u[Z];h.push({type:"line",name:U,data:B,color:ce,connectNulls:!0,marker:{enabled:!1,states:{hover:{enabled:!0}}}})})})}return{series:h,categories:x,originalTimestamps:m}},NL=t=>t.split(" ").map(n=>n.charAt(0).toUpperCase()+n.slice(1).toLowerCase()).join(" "),q3=t=>t.split("_").map(n=>n.charAt(0).toUpperCase()+n.slice(1).toLowerCase()).join(" "),Kd=({options:t,showLegend:n=!1,legendType:a="Points",legendPosition:r="bottom",legendData:c=[],selectedRows:u=[],onLegendItemClick:h=()=>{},onLegendItemHover:p=()=>{},className:m="",chartRef:v,responsive:x=!0,maxLegendItems:_=10,rawChartData:T=[],groupbyConfig:k,selectedMetrics:C,enableGroupby:G=!1,dimensionLabelMapper:ne=B=>B,showCardinalityControl:$=!1,isMobile:L=!1})=>{console.log("chart data",t);const[B,Y]=Re.useState([]),[X,U]=Re.useState(null),[Z,ce]=Re.useState("top5"),se=Re.useRef(null),I=v||se,H=g=>!g.series||g.series.length<=1?!1:g.series.every(j=>{const te=j.name;return te&&!isNaN(Number(te))}),Q=g=>{var te,O;if(!g.series||g.series.length<=1)return g;const D=[],j=g.xAxis&&typeof g.xAxis=="object"&&"categories"in g.xAxis?g.xAxis.categories:[];g.series.forEach(z=>{const W=z;W.data&&Array.isArray(W.data)&&W.data.forEach((de,P)=>{if(de!=null){let ee,J;Array.isArray(de)?(ee=de[0],J=de[1]):(ee=P,J=Number(de)),!isNaN(ee)&&!isNaN(J)&&D.push([ee,J])}})}),D.sort((z,W)=>z[0]-W[0]);const K=[{type:"line",name:((te=g.title)==null?void 0:te.text)||"",data:D,color:((O=Qm.getOptions().colors)==null?void 0:O[0])||"#7856FF",marker:{enabled:!1,states:{hover:{enabled:!0}}}}];return{...g,series:K,xAxis:{...g.xAxis,type:j.length>0?"category":"linear"}}},F=Re.useMemo(()=>{if(!G||!T.length||!k)return H(t)?Q(t):t;const{groupbyKeys:g,timeColumn:D,metricColumns:j,showCardinality:K=!0}=k;let te=T;const O=$?DL(Z):k.cardinality||"TOP_5";K&&g.length>0&&(te=OL(T,g,j,O));const{series:z,categories:W,originalTimestamps:de}=RL(te,D,g,j,ne);return{...t,chart:{type:"line"},title:{text:""},credits:{enabled:!1},xAxis:{categories:W,gridLineWidth:0,labels:{step:F3(W,L),formatter:function(){const ee=String(this.value);return ml(ee,L)},style:{color:"#9aa0a6"},rotation:0,align:"center"}},yAxis:{title:{text:""},gridLineColor:"#e0e0e0",gridLineDashStyle:"Dash",max:(C==null?void 0:C.metric_type)==="Rate"?100:void 0,...(C==null?void 0:C.metric_type)==="Rate"?{min:0,tickInterval:20,minTickInterval:20}:{},labels:{formatter:function(){var re;if(C)return bS(C,Number(this.value));const ee=((re=this.chart.options.title)==null?void 0:re.text)||"",J=V3(ee.replace(/ /g,"_")),le={metric_name_db:ee.replace(/ /g,"_"),metric_type:J};return bS(le,Number(this.value))},style:{color:"#9aa0a6"}}},legend:{enabled:!0,align:"left",verticalAlign:"bottom",layout:"horizontal",y:10,...L?{maxHeight:100}:{},itemStyle:{fontSize:"12px"},symbolRadius:0,symbolHeight:0,symbolWidth:0,useHTML:!0,labelFormatter:function(){const ee=this.color||"#000",J="name"in this?this.name:"";return'<span style="display: inline-flex; align-items: center;"><span style="background-color: '+ee+'; width: 12px; height: 12px; border-radius: 3px; display: inline-block; margin-right: 5px;"></span>'+J+"</span>"}},plotOptions:{series:{marker:{enabled:!1,symbol:"circle",radius:4,states:{hover:{enabled:!0,radius:5}}},states:{hover:{lineWidthPlus:1}}}},tooltip:{shared:!1,useHTML:!0,backgroundColor:"rgba(255, 255, 255, 0)",borderWidth:0,shadow:!1,style:{padding:"0px"},formatter:function(){var xe,pe,Se;let ee=j[0],J=ee;if(j.length>1&&((xe=this.series)!=null&&xe.name)){const Te=this.series.name.split(" - ");if(Te.length>1){const Oe=Te[Te.length-1],ze=j.find(Ge=>Ge.replace(/_/g," ").replace(/\b\w/g,qe=>qe.toUpperCase())===Oe);ze&&(ee=ze,J=Oe)}}else j.length===1&&(J=(C==null?void 0:C.metric_label)||ee.replace(/_/g," ").replace(/\b\w/g,Ae=>Ae.toUpperCase()));const re={metric_type:V3(ee)},ge=Ae=>Ae.replace(/_/g," ").replace(/\b\w/g,Te=>Te.toUpperCase());let ve='<div style="border-radius: 12px; border: 1px solid #EAECF0; background: #FFF; box-shadow: 0px 6px 15px 0px rgba(0, 0, 0, 0.15), 0px 3px 2px -5px rgba(0, 0, 0, 0.04); padding: 16px;">';ve+='<div style="display: flex; font-family: Inter, sans-serif; gap: 16px; align-items: stretch;">';const we=this.color||"#7856FF";ve+=`<div style="background:${we}; width: 4px; flex-shrink: 0; border-radius: 4px; align-self: stretch;"></div>`,ve+='<div style="display: flex; flex-direction: column; gap: 12px;">',ve+='<div style="display: flex; flex-direction: column; gap: 4px;">',ve+=`<div style="color: #525252; font-feature-settings: 'clig' off, 'liga' off; font-family: Inter; font-size: 12px; font-style: normal; font-weight: 600; line-height: 18px;">${ge(J)}</div>`,ve+="</div>",ve+='<div class="flex flex-col gap-1" style="display: flex; flex-direction: column; gap: 6px;">';const Ce=bS(re,this.y||0),Me=((pe=this.series)==null?void 0:pe.name)==="Overall",De=Me?"#E8E8E8":"#D4F4E5",be=Me?"#424242":"#008242";ve+='<div class="flex items-center" style="display: flex; align-items: center;">',ve+=`<div class="rounded p-1 font-semibold mr-1.5 my-1" style="background-color: ${De}; color: ${be}; border-radius: 4px; padding: 4px 8px; font-weight: 600; margin-right: 8px; font-size: 12px;">${Ce}</div>`,ve+=`<div class="text-jp-2-gray-200 font-medium" style="color: #70747E; font-weight: 500; font-size: 12px;">${((Se=this.series)==null?void 0:Se.name)||""}</div>`,ve+="</div>";let ye="";if(this.x!==void 0&&this.x!==null){const Ae=typeof this.x=="number"?this.x:W.indexOf(String(this.x));if(Ae>=0&&Ae<de.length){const Te=de[Ae];try{ye=Qd(Te)}catch{ye=String(this.x)}}else ye=String(this.x)}return ve+=`<div class="font-medium text-jp-2-gray-300" style="font-weight: 500; color: #9AA0A6; font-size: 12px; margin-top: 4px;">${ye}</div>`,ve+="</div>",ve+="</div>",ve+="</div>",ve+="</div>",ve},xDateFormat:"%a, %d %B, %Y %H:%M"},series:z}},[t,G,T,k,C,ne,$,Z,L]),E=u.length>0?u:B,M=Re.useCallback(g=>{var K;const D=E.includes(g.name)?E.filter(te=>te!==g.name):[...E,g.name],j=D.length===c.length?[]:D;if(Y(j),(K=I.current)!=null&&K.chart){const te=I.current.chart;te.series.forEach(O=>{j.length===0?O.setVisible(!0,!1):O.setVisible(j.includes(O.name||""),!1)}),te.redraw()}h==null||h(g)},[E,c,I,h]),R=Re.useCallback(g=>{U(g),p==null||p(g)},[p]),V=Re.useMemo(()=>{var z,W;const g=F,D=typeof g.xAxis=="object"&&"labels"in g.xAxis?g.xAxis.labels:{},j=D&&typeof D=="object"&&"step"in D?D.step:null,K=typeof g.xAxis=="object"&&"categories"in g.xAxis?g.xAxis.categories:[],te=j!==null?j:F3(K,L),O={...g,xAxis:{...g.xAxis,type:"category",labels:{...D,rotation:0,step:te,style:{textOverflow:"none",color:"#9aa0a6",fontSize:"10px"},formatter:function(){const de=String(this.value);return ml(de,L)}},lineColor:"#9aa0a6",gridLineWidth:0,gridLineColor:"#e5e5e5",gridLineDashStyle:"Solid",tickAmount:6,crosshair:!1,tickmarkPlacement:"on",alignTicks:!0},legend:{enabled:n&&a==="Points",align:"left",verticalAlign:"bottom",layout:"horizontal",...L?{maxHeight:100}:{},itemStyle:{fontSize:"12px"},x:0,floating:!1,...g.legend},yAxis:{...g.yAxis,gridLineWidth:1,gridLineColor:"#e5e5e5",gridLineDashStyle:"Dash",max:(C==null?void 0:C.metric_type)==="Rate"?100:typeof g.yAxis=="object"&&"max"in g.yAxis?g.yAxis.max:void 0,...(C==null?void 0:C.metric_type)==="Rate"?{min:0,tickInterval:20,minTickInterval:20}:{},labels:{...typeof g.yAxis=="object"&&"labels"in g.yAxis?g.yAxis.labels:{},style:{fontSize:"10px",color:"#9aa0a6",...typeof g.yAxis=="object"&&"labels"in g.yAxis&&g.yAxis.labels&&typeof g.yAxis.labels=="object"&&"style"in g.yAxis.labels?g.yAxis.labels.style:{}}}},tooltip:{...g.tooltip,shared:!1,xDateFormat:"%a, %d %B, %Y %H:%M"}};return(z=g.title)!=null&&z.text?{...O,title:{...g.title,text:NL(g.title.text),style:{...(W=g.title)==null?void 0:W.style,padding:"12px"}}}:O},[F,n,a,r,L]),ae=Re.useMemo(()=>{if(c.length>0)return c;const g=V;return g.series?g.series.map((D,j)=>{const K=D,te=K.color,O=Qm.getOptions().colors||[],z=typeof te=="string"?te:O[j%O.length];return{name:K.name||`Series ${j+1}`,color:z,visible:K.visible!==!1,data:K.data||[],value:Array.isArray(K.data)&&K.data.length>0?K.data[K.data.length-1]:void 0}}):[]},[c,V]),oe=r==="left"||r==="right",A=x&&window.innerWidth<=768,ue=`${zt["highchart-wrapper"]} ${A?zt.mobile:""} ${m} ${oe?`${zt.flex} ${zt["flex-row"]}`:`${zt.flex} ${zt["flex-col"]}`}`,me=$&&G&&k&&k.groupbyKeys.length>0&&T.length>0;return q.jsx(oc,{children:q.jsxs("div",{className:ue,children:[me&&q.jsx(TL,{granularity:Z,onGranularityChange:ce}),n&&r==="top"&&q.jsx(Tb,{legendData:ae,selectedRows:E,hoveredItem:X,onItemClick:M,onItemHover:R,legendType:a,position:r,maxItems:_,responsive:x}),q.jsx("div",{className:`${oe?zt["flex-1"]:zt["w-full"]} ${n&&r==="left"?zt["order-2"]:""}`,children:q.jsx(kL,{highcharts:Qm,options:V,ref:I})}),n&&r==="right"&&q.jsx(Tb,{legendData:ae,selectedRows:E,hoveredItem:X,onItemClick:M,onItemHover:R,legendType:a,position:r,maxItems:_,responsive:x}),n&&r==="left"&&q.jsx(Tb,{legendData:ae,selectedRows:E,hoveredItem:X,onItemClick:M,onItemHover:R,legendType:a,position:r,maxItems:_,responsive:x}),n&&r==="bottom"&&q.jsx(Tb,{legendData:ae,selectedRows:E,hoveredItem:X,onItemClick:M,onItemHover:R,legendType:a,position:r,maxItems:_,responsive:x})]})})},zL=t=>t?t.replace(/_/g," ").split(" ").map(a=>a.charAt(0).toUpperCase()+a.slice(1).toLowerCase()).join(" "):"Unknown",BL=(t,n)=>{if(n==null||n==="")return"N/A";let a;if(typeof n=="string"){const c=n.replace(/[^0-9.-]/g,"");a=parseFloat(c)}else a=n;if(isNaN(a))return String(n);const r=t.toLowerCase();return r.includes("rate")||r.includes("percentage")||r.includes("percent")?`${a}%`:r.includes("latency")||r.includes("time")||r.includes("duration")?`${a}S`:r.includes("volume")||r.includes("count")||r.includes("amount")||r.includes("total")||r.includes("transaction")||r.includes("order")||r.includes("number")||r.includes("quantity")?a>=1e7?`${(a/1e7).toFixed(1)} Cr`:a>=1e5?`${(a/1e5).toFixed(1)} L`:a>=1e3?`${(a/1e3).toFixed(1)} K`:a%1!==0?a.toFixed(2):a.toLocaleString("en-IN"):String(a)},Ab=({metric:t,value:n})=>q.jsxs("div",{className:nt["genius-dashboard-single-stat-card"],children:[q.jsx("div",{className:nt["genius-dashboard-single-stat-title"],children:zL(t)}),q.jsx("div",{className:nt["genius-dashboard-single-stat-value"],children:BL(t,n)})]}),xS=({data:t})=>{const[n,a]=Re.useState(1),r=5;if(!t||t.length===0)return null;const c=Object.keys(t[0]),u=[],h=[];c.forEach(G=>{var $;typeof(($=t.find(L=>L[G]!==null&&L[G]!==void 0))==null?void 0:$[G])=="string"||G.toLowerCase().includes("name")||G.toLowerCase().includes("id")?u.push(G):h.push(G)});const p=[...u,...h],m=n*r,v=m-r,x=t.slice(v,m),_=Math.ceil(t.length/r),T=G=>{a(G)},k=()=>{const ne=[],$=[];let L;ne.push(1);for(let B=n-1;B<=n+1;B++)B>1&&B<_&&ne.push(B);return _>1&&ne.push(_),ne.forEach(B=>{L!==void 0&&typeof B=="number"&&(B-L===2?$.push(L+1):B-L!==1&&$.push("...")),$.push(B),L=typeof B=="number"?B:L}),$},C=(G,ne)=>{if(G==null||G==="")return"N/A";const $=typeof G=="string"?parseFloat(G):G;if(isNaN($))return String(G);const L=ne.toLowerCase();if(L.includes("rate")||L.includes("percentage")||L.includes("percent"))return`${$}%`;if(L.includes("latency")||L.includes("time")||L.includes("duration"))return`${$}S`;if(L.includes("volume")||L.includes("count")||L.includes("amount")||L.includes("total")){if($>=1e7)return`${($/1e7).toFixed(1)}Cr`;if($>=1e5)return`${($/1e5).toFixed(1)}L`;if($>=1e3)return`${($/1e3).toFixed(1)}K`}return L.includes("price")||L.includes("cost")?new Intl.NumberFormat("en-US",{style:"currency",currency:"USD",minimumFractionDigits:2,maximumFractionDigits:2}).format($):L.includes("quantity")?new Intl.NumberFormat("en-US").format($):typeof G=="number"?new Intl.NumberFormat("en-US").format(G):G.toString()};return q.jsxs("div",{className:nt["genius-dashboard-table-container"],"data-loaded-table":"genius-table",children:[q.jsx("div",{className:nt["genius-dashboard-table-wrapper"],children:q.jsxs("table",{className:nt["genius-dashboard-table"],children:[q.jsx("thead",{className:nt["genius-dashboard-table-head"],children:q.jsx("tr",{className:nt["genius-dashboard-table-head-row"],children:p.map(G=>q.jsx("th",{className:`${nt["genius-dashboard-table-head-cell"]} ${nt["text-left"]}`,children:q.jsx("div",{className:nt["genius-dashboard-table-head-content"],children:G.replace(/_/g," ")})},G))})}),q.jsx("tbody",{className:nt["genius-dashboard-table-body"],children:x.map((G,ne)=>q.jsx("tr",{className:nt["genius-dashboard-table-row"],children:p.map($=>q.jsx("td",{className:nt["genius-dashboard-table-cell"],children:q.jsx("div",{className:nt["genius-dashboard-table-cell-content"],children:C(G[$],$)})},$))},ne))})]})}),t.length>r&&q.jsxs("div",{className:nt["genius-dashboard-pagination"],children:[q.jsxs("span",{className:nt["genius-dashboard-pagination-info"],children:[v+1," - ",Math.min(m,t.length)," of ",t.length]}),q.jsxs("div",{className:nt["genius-dashboard-page-controls"],children:[q.jsx("button",{onClick:()=>T(n-1),disabled:n===1,className:nt["genius-dashboard-page-button"],children:"←"}),k().map((G,ne)=>G==="..."?q.jsx("span",{className:nt["genius-dashboard-pagination-dots"],children:"..."},`dots-${ne}`):q.jsx("button",{onClick:()=>T(G),className:`${nt["genius-dashboard-page-button"]} ${n===G?nt.active:""}`,children:G},G)),q.jsx("button",{onClick:()=>T(n+1),disabled:n===_,className:nt["genius-dashboard-page-button"],children:"→"})]})]})]})},Yi={volumeChartWrapper:"genius-sdk__VolumeChartRenderer-module__volumeChartWrapper___kiY8A",volumeRendererContainer:"genius-sdk__VolumeChartRenderer-module__volumeRendererContainer___Q6LiY",volumeGranularitySelect:"genius-sdk__VolumeChartRenderer-module__volumeGranularitySelect___oyuer",volumeChartToggle:"genius-sdk__VolumeChartRenderer-module__volumeChartToggle___VVP1y",volumeToggleButton:"genius-sdk__VolumeChartRenderer-module__volumeToggleButton___HlQp6",active:"genius-sdk__VolumeChartRenderer-module__active___ztxmP",volumeToggleIcon:"genius-sdk__VolumeChartRenderer-module__volumeToggleIcon___S97MZ",volumeChartContainer:"genius-sdk__VolumeChartRenderer-module__volumeChartContainer___qji65",noBorderChart:"genius-sdk__VolumeChartRenderer-module__noBorderChart___wqVTM",volumeNoData:"genius-sdk__VolumeChartRenderer-module__volumeNoData___fNbeP"},_S=(t,n)=>{const a=typeof n=="string"?parseFloat(n):n;return isNaN(a)?String(n):t.toLowerCase().includes("rate")||t.toLowerCase().includes("percentage")?`${a.toFixed(2)}%`:t.toLowerCase().includes("latency")||t.toLowerCase().includes("time")?`${a.toFixed(2)}S`:a>=1e7?`${(a/1e7).toFixed(1)}Cr`:a>=1e5?`${(a/1e5).toFixed(1)}L`:a>=1e3?`${(a/1e3).toFixed(1)}K`:a.toLocaleString("en-IN")},UL=({granularity:t,onGranularityChange:n})=>q.jsx("div",{className:Yi.volumeRendererContainer,children:q.jsx(vS,{value:t,onChange:a=>n(a),options:[{value:"top5",label:"Top 5"},{value:"top10",label:"Top 10"}],className:Yi.volumeGranularitySelect})}),PL=(t,n,a,r="all")=>{if(!t||t.length===0)return[];const c=t.reduce((h,p)=>{const m=String(p[n]||"Unknown"),v=p[a],x=typeof v=="number"?v:parseFloat(String(v))||0;if(x>0){const _=h[m]||0;h[m]=_+x}return h},{});let u=Object.entries(c).filter(([,h])=>h>0).map(([h,p])=>({name:h,value:Number(p)})).sort((h,p)=>p.value-h.value);return r==="top5"?u=u.slice(0,5):r==="top10"&&(u=u.slice(0,10)),u},HL=(t,n,a=!1,r=!0)=>{console.log("createBarChartOptions data:","isMobile:",a,"isHorizontalBar:",r);const c=t.map(h=>({name:h.name,y:h.value})),u=t.map(h=>h.name);return console.log("HighBarChart1D categories:",{categories:u}),{chart:{type:r?"bar":"column",backgroundColor:"white",height:a?300:400,marginTop:a?15:60,marginBottom:a?25:60,marginLeft:r?a?80:100:a?40:80,marginRight:a?20:40,borderWidth:0,...a&&{spacingTop:0}},title:{text:"",margin:50,style:{fontFamily:"Inter",fontSize:"14px",fontWeight:"600",color:"#111111"}},tooltip:{shared:!1,enabled:!0,useHTML:!0,hideDelay:0,outside:!a,padding:0,backgroundColor:"transparent",borderWidth:0,shadow:!1,style:{zIndex:9999},positioner:a?function(h,p,m){const v=this.chart,{plotLeft:x,plotTop:_,plotWidth:T}=v;let k=m.plotX+x-h/2,C=m.plotY+_-p-10;return k<x&&(k=x+5),k+h>x+T&&(k=x+T-h-5),C<_&&(C=m.plotY+_+10),{x:k,y:C}}:void 0,formatter:function(){var T;const h=this.y??0,p=_S(n.metric_type||"volume",h),m=((T=this.point)==null?void 0:T.name)||this.key||this.x;return`<div style="background: white; border-radius: 6px; box-shadow: 0 2px 8px rgba(0,0,0,0.1); display: flex; align-items: stretch; padding: ${a?"6px 6px 4px 6px":"10px 10px 6px 10px"}; max-width: ${a?"250px":"300px"}; min-width: ${a?"180px":"220px"};">
109
109
  <div style="width: 3px; background-color: #1B85FF; border-radius: 3px; flex-shrink: 0;"></div>
110
110
  <div style="padding-left: ${a?"6px":"10px"}; padding-right: ${a?"4px":"8px"}; flex: 1; min-width: 0;">
111
111
  <div style="font-weight: 600; color: #374151; margin-bottom: 4px; font-size: ${a?"11px":"12px"}; word-wrap: break-word; white-space: normal; line-height: 1.3;">${m}</div>