!/**
 * Highmaps JS v12.6.0 (2026-04-13)
 * @module highcharts/modules/tilemap
 * @requires highcharts
 * @requires highcharts/modules/map
 *
 * Tilemap module
 *
 * (c) 2010-2026 Highsoft AS
 *
 * A commercial license may be required depending on use.
 * See www.highcharts.com/license
 */function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(t._Highcharts,t._Highcharts.SeriesRegistry,t._Highcharts.Color):"function"==typeof define&&define.amd?define("highcharts/modules/tilemap",["highcharts/highcharts"],function(t){return e(t,t.SeriesRegistry,t.Color)}):"object"==typeof exports?exports["highcharts/modules/tilemap"]=e(t._Highcharts,t._Highcharts.SeriesRegistry,t._Highcharts.Color):t.Highcharts=e(t.Highcharts,t.Highcharts.SeriesRegistry,t.Highcharts.Color)}("u"<typeof window?this:window,function(t,e,r){return function(){"use strict";var o,n,i,a={512:function(t){t.exports=e},620:function(t){t.exports=r},944:function(e){e.exports=t}},s={};function l(t){var e=s[t];if(void 0!==e)return e.exports;var r=s[t]={exports:{}};return a[t](r,r.exports,l),r.exports}l.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return l.d(e,{a:e}),e},l.d=function(t,e){for(var r in e)l.o(e,r)&&!l.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},l.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)};var p={};l.d(p,{default:function(){return K}});var c=l(944),h=l.n(c),u=l(512),f=l.n(u),d=l(620),y=l.n(d),g=function(t,e,r){if(r||2==arguments.length)for(var o,n=0,i=e.length;n<i;n++)!o&&n in e||(o||(o=Array.prototype.slice.call(e,0,n)),o[n]=e[n]);return t.concat(o||Array.prototype.slice.call(e))};function v(t,e,r,o){void 0===o&&(o={});var n="function"==typeof t&&t.prototype||t;Object.hasOwnProperty.call(n,"hcEvents")||(n.hcEvents={});var i=n.hcEvents;h().Point&&t instanceof h().Point&&t.series&&t.series.chart&&(t.series.chart.runTrackerClick=!0);var a=t.addEventListener;a&&a.call(t,e,r,!!h().supportsPassiveEvents&&{passive:void 0===o.passive?-1!==e.indexOf("touch"):o.passive,capture:!1}),i[e]||(i[e]=[]);var s={fn:r,order:"number"==typeof o.order?o.order:1/0};return i[e].push(s),i[e].sort(function(t,e){return t.order-e.order}),function(){!function(t,e,r){function o(e,r){var o=t.removeEventListener;o&&o.call(t,e,r,!1)}function n(r){var n,i;t.nodeName&&(e?(n={})[e]=!0:n=r,L(n,function(t,e){if(r[e])for(i=r[e].length;i--;)o(e,r[e][i].fn)}))}var i="function"==typeof t&&t.prototype||t;if(Object.hasOwnProperty.call(i,"hcEvents")){var a=i.hcEvents;if(e){var s=a[e]||[];r?(a[e]=s.filter(function(t){return r!==t.fn}),o(e,r)):(n(a),a[e]=[])}else n(a),delete i.hcEvents}}(t,e,r)}}function x(t,e,r){return t>e?t<r?t:r:e}function b(t,e){var r;for(r in t||(t={}),e)t[r]=e[r];return t}function m(t){return P(t)&&"number"==typeof t.nodeType}function A(t){var e=Object.prototype.toString.call(t);return"[object Array]"===e||"[object Array Iterator]"===e}function P(t,e){return!!t&&"object"==typeof t&&(!e||!A(t))}function M(t){for(var e=[],r=1;r<arguments.length;r++)e[r-1]=arguments[r];var o,n=g([t],e,!0),i={},a=function(t,e){return"object"!=typeof t&&(t={}),L(e,function(r,o){if("__proto__"!==o&&"constructor"!==o){var n;!P(r,!0)||(n=null==r?void 0:r.constructor,P(r,!0)&&!m(r)&&(null==n?void 0:n.name)&&"Object"!==n.name)||m(r)?t[o]=e[o]:t[o]=a(t[o]||{},r)}}),t};!0===t&&(i=n[1],n=Array.prototype.slice.call(n,2));var s=n.length;for(o=0;o<s;o++)i=a(i,n[o]);return i}function L(t,e,r){for(var o in t)Object.hasOwnProperty.call(t,o)&&e.call(r||t[o],t[o],o,t)}function S(){for(var t=arguments,e=t.length,r=0;r<e;r++){var o=t[r];if(null!=o)return o}}h().doc,h().win,Array.prototype.find;var w=y().parse;!function(t){var e;function r(){var t,r=this,o=this.userOptions;this.colorAxis=[],o.colorAxis&&(o.colorAxis=A(t=o.colorAxis)?t:[t],o.colorAxis.map(function(t){return new e(r,t)}))}function o(t){var e,r,o=this,n=this.chart.colorAxis||[],i=function(e){var r=t.allItems.indexOf(e);-1!==r&&(o.destroyItem(t.allItems[r]),t.allItems.splice(r,1))},a=[];for(n.forEach(function(t){(null==(e=t.options)?void 0:e.showInLegend)&&(e.dataClasses&&e.visible?a=a.concat(t.getDataClassLegendSymbols()):e.visible&&a.push(t),t.series.forEach(function(t){(!t.options.showInLegend||e.dataClasses)&&("point"===t.options.legendType?t.points.forEach(function(t){i(t)}):i(t))}))}),r=a.length;r--;)t.allItems.unshift(a[r])}function n(t){t.visible&&t.item.legendColor&&t.item.legendItem.symbol.attr({fill:t.item.legendColor})}function i(t){var e;null==(e=this.chart.colorAxis)||e.forEach(function(e){e.update({},t.redraw)})}function a(){var t;((null==(t=this.chart.colorAxis)?void 0:t.length)||this.colorAttribs)&&this.translateColors()}function s(){var t=this.axisTypes;t?-1===t.indexOf("colorAxis")&&t.push("colorAxis"):this.axisTypes=["colorAxis"]}function l(t){var e=this,r=t?"show":"hide";e.visible=e.options.visible=!!t,["graphic","dataLabel"].forEach(function(t){e[t]&&e[t][r]()}),this.series.buildKDTree()}function p(){var t=this,e=this.getPointsCollection(),r=this.options.nullColor,o=this.colorAxis,n=this.colorKey;e.forEach(function(e){var i=e.getNestedProperty(n),a=e.options.color||(e.isNull||null===e.value?r:o&&void 0!==i?o.toColor(i,e):e.color||t.color);a&&e.color!==a&&(e.color=a,"point"===t.options.legendType&&e.legendItem&&e.legendItem.label&&t.chart.legend.colorizeItem(e,e.visible))})}function c(){this.elem.attr("fill",w(this.start).tweenTo(w(this.end),this.pos),void 0,!0)}function h(){this.elem.attr("stroke",w(this.start).tweenTo(w(this.end),this.pos),void 0,!0)}t.compose=function(t,u,f,d,y){var g,x,m=u.prototype,A=f.prototype,P=y.prototype;m.collectionsWithUpdate.includes("colorAxis")||(e=t,m.collectionsWithUpdate.push("colorAxis"),m.collectionsWithInit.colorAxis=[m.addColorAxis],v(u,"afterCreateAxes",r),x=(g=u).prototype.createAxis,g.prototype.createAxis=function(t,r){if("colorAxis"!==t)return x.apply(this,arguments);var o=new e(this,M(r.axis,{index:this[t].length,isX:!1}));return this.isDirtyLegend=!0,this.axes.forEach(function(t){t.series=[]}),this.series.forEach(function(t){t.bindAxes(),t.isDirtyData=!0}),S(r.redraw,!0)&&this.redraw(r.animation),o},A.fillSetter=c,A.strokeSetter=h,v(d,"afterGetAllItems",o),v(d,"afterColorizeItem",n),v(d,"afterUpdate",i),b(P,{optionalAxis:"colorAxis",translateColors:p}),b(P.pointClass.prototype,{setVisible:l}),v(y,"afterTranslate",a,{order:1}),v(y,"bindAxes",s))},t.pointSetVisible=l}(i||(i={}));var O=i,C=(o=function(t,e){return(o=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(t,e)},function(t,e){function r(){this.constructor=t}o(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)}),_=f().series.prototype.pointClass,T=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return C(e,t),e.prototype.haloPath=function(){return this.series.tileShape.haloPath.apply(this,arguments)},e}(f().seriesTypes.heatmap.prototype.pointClass);b(T.prototype,{setState:_.prototype.setState,setVisible:O.pointSetVisible});var E={marker:null,states:{hover:{halo:{enabled:!0,size:2,opacity:.5,attributes:{zIndex:3}}}},pointPadding:2,tileShape:"hexagon"},j=h().noop,I=f().seriesTypes,D=I.heatmap,z=I.scatter;function H(t,e,r){var o=t.options;return{xPad:-((o.colsize||1)/e),yPad:-((o.rowsize||1)/r)}}var X={hexagon:{alignDataLabel:z.prototype.alignDataLabel,getSeriesPadding:function(t){return H(t,3,2)},haloPath:function(t){if(!t)return[];var e=this.tileEdges;return[["M",e.x2-t,e.y1+t],["L",e.x3+t,e.y1+t],["L",e.x4+1.5*t,e.y2],["L",e.x3+t,e.y3-t],["L",e.x2-t,e.y3-t],["L",e.x1-1.5*t,e.y2],["Z"]]},translate:function(){var t,e,r=this.options,o=this.xAxis,n=this.yAxis,i=r.pointPadding||0,a=(r.colsize||1)/3,s=(r.rowsize||1)/2;this.generatePoints();for(var l=0,p=this.points;l<p.length;l++){var c=p[l],h=x(Math.floor(o.len-o.translate(c.x-2*a,0,1,0,1)),-o.len,2*o.len),u=x(Math.floor(o.len-o.translate(c.x-a,0,1,0,1)),-o.len,2*o.len),f=x(Math.floor(o.len-o.translate(c.x+a,0,1,0,1)),-o.len,2*o.len),d=x(Math.floor(o.len-o.translate(c.x+2*a,0,1,0,1)),-o.len,2*o.len),y=x(Math.floor(n.translate(c.y-s,0,1,0,1)),-n.len,2*n.len),g=x(Math.floor(n.translate(c.y,0,1,0,1)),-n.len,2*n.len),v=x(Math.floor(n.translate(c.y+s,0,1,0,1)),-n.len,2*n.len),b=null!=(t=c.pointPadding)?t:i,m=b*Math.abs(u-h)/Math.abs(v-g),A=o.reversed?-m:m,P=o.reversed?-b:b,M=n.reversed?-b:b;c.x%2&&(e=e||Math.round(Math.abs(v-y)/2)*(n.reversed?-1:1),y+=e,g+=e,v+=e),c.plotX=c.clientX=(u+f)/2,c.plotY=g,c.tileEdges={x1:h+=A+P,x2:u+=P,x3:f-=P,x4:d-=A+P,y1:y-=M,y2:g,y3:v+=M},c.shapeType="path",c.shapeArgs={d:[["M",u,y],["L",f,y],["L",d,g],["L",f,v],["L",u,v],["L",h,g],["Z"]]}}this.translateColors()}},diamond:{alignDataLabel:z.prototype.alignDataLabel,getSeriesPadding:function(t){return H(t,2,2)},haloPath:function(t){if(!t)return[];var e=this.tileEdges;return[["M",e.x2,e.y1+t],["L",e.x3+t,e.y2],["L",e.x2,e.y3-t],["L",e.x1-t,e.y2],["Z"]]},translate:function(){var t,e=this.options,r=this.xAxis,o=this.yAxis,n=e.pointPadding||0,i=e.colsize||1,a=(e.rowsize||1)/2;this.generatePoints();for(var s=0,l=this.points;s<l.length;s++){var p=l[s],c=x(Math.round(r.len-r.translate(p.x-i,0,1,0,0)),-r.len,2*r.len),h=x(Math.round(r.len-r.translate(p.x+i,0,1,0,0)),-r.len,2*r.len),u=x(Math.round(o.translate(p.y-a,0,1,0,0)),-o.len,2*o.len),f=x(Math.round(o.translate(p.y,0,1,0,0)),-o.len,2*o.len),d=x(Math.round(o.translate(p.y+a,0,1,0,0)),-o.len,2*o.len),y=x(Math.round(r.len-r.translate(p.x,0,1,0,0)),-r.len,2*r.len),g=S(p.pointPadding,n),v=g*Math.abs(y-c)/Math.abs(d-f),b=r.reversed?-v:v,m=o.reversed?-g:g;p.x%2&&(t=Math.abs(d-u)/2*(o.reversed?-1:1),u+=t,f+=t,d+=t),p.plotX=p.clientX=y,p.plotY=f,p.tileEdges={x1:c+=b,x2:y,x3:h-=b,y1:u-=m,y2:f,y3:d+=m},p.shapeType="path",p.shapeArgs={d:[["M",y,u],["L",h,f],["L",y,d],["L",c,f],["Z"]]}}this.translateColors()}},circle:{alignDataLabel:z.prototype.alignDataLabel,getSeriesPadding:function(t){return H(t,2,2)},haloPath:function(t){return z.prototype.pointClass.prototype.haloPath.call(this,t+(t&&this.radius))},translate:function(){var t,e,r,o,n=this.options,i=this.xAxis,a=this.yAxis,s=n.pointPadding||0,l=(n.rowsize||1)/2,p=n.colsize||1,c=!1;this.generatePoints();for(var h=0,u=this.points;h<u.length;h++){var f=u[h],d=x(Math.round(i.len-i.translate(f.x,0,1,0,0)),-i.len,2*i.len),y=s,g=!1,v=x(Math.round(a.translate(f.y,0,1,0,0)),-a.len,2*a.len);void 0!==f.pointPadding&&(y=f.pointPadding,g=!0,c=!0),(!o||c)&&(r=Math.floor(Math.sqrt((t=Math.abs(x(Math.floor(i.len-i.translate(f.x+p,0,1,0,0)),-i.len,2*i.len)-d))*t+(e=Math.abs(x(Math.floor(a.translate(f.y+l,0,1,0,0)),-a.len,2*a.len)-v))*e)/2),o=Math.min(t,r,e)-y,c&&!g&&(c=!1)),f.x%2&&(v+=e*(a.reversed?-1:1)),f.plotX=f.clientX=d,f.plotY=v,f.radius=o,f.shapeType="circle",f.shapeArgs={x:d,y:v,r:o}}this.translateColors()}},square:{alignDataLabel:D.prototype.alignDataLabel,translate:D.prototype.translate,getSeriesPadding:j,haloPath:D.prototype.pointClass.prototype.haloPath}},k=(n=function(t,e){return(n=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw TypeError("Class extends value "+String(e)+" is not a constructor or null");function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)}),F=h().composed,R=h().noop,V=f().seriesTypes,Z=V.column,N=V.heatmap,U=V.scatter;function W(){if(!this.recomputingForTilemap&&"colorAxis"!==this.coll){var t=this,e=t.series.map(function(e){return e.getSeriesPixelPadding&&e.getSeriesPixelPadding(t)}).reduce(function(t,e){return(t&&t.padding)>(e&&e.padding)?t:e},void 0)||{padding:0,axisLengthFactor:1},r=Math.round(e.padding*e.axisLengthFactor);e.padding&&(t.len-=r,t.recomputingForTilemap=!0,t.setAxisTranslation(),delete t.recomputingForTilemap,t.minPixelPadding+=e.padding,t.len+=r)}}var Y=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return k(e,t),e.compose=function(t){0>F.indexOf("TilemapSeries")&&F.push("TilemapSeries")&&v(t,"afterSetAxisTranslation",W)},e.prototype.alignDataLabel=function(){return this.tileShape.alignDataLabel.apply(this,arguments)},e.prototype.drawPoints=function(){Z.prototype.drawPoints.call(this);for(var t=0,e=this.points;t<e.length;t++){var r=e[t];r.graphic&&r.graphic[this.chart.styledMode?"css":"animate"](this.colorAttribs(r))}},e.prototype.getSeriesPixelPadding=function(t){var e=t.isXAxis,r=this.tileShape.getSeriesPadding(this);if(!r)return{padding:0,axisLengthFactor:1};var o=Math.round(t.translate(e?2*r.xPad:r.yPad,0,1,0,1)),n=Math.round(t.translate(e?r.xPad:0,0,1,0,1));return{padding:(t.single?Math.abs(o-n)/2:Math.abs(o-n))||0,axisLengthFactor:e?2:1.1}},e.prototype.setOptions=function(){var e=t.prototype.setOptions.apply(this,arguments);return this.tileShape=X[e.tileShape],e},e.prototype.translate=function(){return this.tileShape.translate.apply(this,arguments)},e.defaultOptions=M(N.defaultOptions,E),e}(N);b(Y.prototype,{getSymbol:R,markerAttribs:U.prototype.markerAttribs,pointAttribs:Z.prototype.pointAttribs,pointClass:T}),f().registerSeriesType("tilemap",Y);var q=h();Y.compose(q.Axis);var K=h();return p.default}()});